/* ══════════════════════════════════════════════════════════════════════
   LICENSE MODULE — CSS Styles
   PMOS Enterprise v1.0 — Fase 5
   Trial + Pagos + Panel Super Admin + Popup Pago Pendiente
   ══════════════════════════════════════════════════════════════════════ */

/* === HEADER BUTTON & CHIP === */
.license-header-wrap {
    display: flex;
    align-items: center;
    gap: 10px;
}

.license-selector-btn {
    font-size: 0.82rem;
    font-weight: 600;
    padding: 8px 18px;
    border-radius: 10px;
    cursor: pointer;
    border: 1px solid rgba(255, 255, 255, 0.15);
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.08), rgba(255, 255, 255, 0.04));
    color: #fff;
    transition: all 0.25s ease;
    backdrop-filter: blur(6px);
}
.license-selector-btn:hover {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.15), rgba(255, 255, 255, 0.08));
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
}

.license-selector-chip {
    font-size: 0.7rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    letter-spacing: 0.3px;
    white-space: nowrap;
}
.license-selector-chip--active { background: #d1fae5; color: #065f46; }
.license-selector-chip--warn { background: #fef3c7; color: #92400e; }
.license-selector-chip--expired { background: #fee2e2; color: #991b1b; }
.license-selector-chip--none { background: #f1f5f9; color: #64748b; }
.license-selector-chip--superadmin { background: linear-gradient(135deg, #eef2ff, #e0e7ff); color: #4338ca; border: 1px solid #c7d2fe; }

/* === MODAL OVERLAY === */
.license-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(6px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 50000;
    padding: 20px;
}
.license-modal-overlay.active {
    display: flex;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* === MODAL BOX === */
.license-modal {
    background: #ffffff;
    border-radius: 20px;
    width: 100%;
    max-width: 820px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.25);
    animation: slideUp 0.3s ease;
    display: flex;
    flex-direction: column;
}

@keyframes slideUp {
    from { transform: translateY(30px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

/* Header */
.license-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 28px;
    border-bottom: 1px solid #e2e8f0;
    flex-shrink: 0;
}
.license-modal-header-content {
    display: flex;
    align-items: center;
    gap: 10px;
}
.license-modal-icon {
    font-size: 1.5rem;
}
.license-modal-header h3 {
    margin: 0;
    font-size: 1.3rem;
    font-weight: 700;
    color: #1e293b;
}
.license-modal-close {
    background: none;
    border: none;
    font-size: 1.6rem;
    color: #94a3b8;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 8px;
    transition: all 0.15s;
}
.license-modal-close:hover {
    background: #f1f5f9;
    color: #1e293b;
}

/* Body */
.license-modal-body {
    padding: 20px 28px;
    flex-grow: 1;
    overflow-y: auto;
}

/* Footer */
.license-modal-footer {
    padding: 14px 28px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
    flex-shrink: 0;
}
.license-footer-btn {
    padding: 8px 24px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: #fff;
    color: #475569;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.15s;
}
.license-footer-btn:hover {
    background: #f1f5f9;
}

/* Section titles */
.license-section-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* === STATUS PANEL === */
.license-status-panel {
    margin-bottom: 20px;
}
.license-status-loading {
    padding: 20px;
    text-align: center;
    color: #94a3b8;
    font-size: 0.9rem;
}
.license-status-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 20px;
    border-radius: 14px;
    border: 1px solid #e2e8f0;
}
.license-status-card--active { background: linear-gradient(135deg, #ecfdf5, #d1fae5); border-color: #a7f3d0; }
.license-status-card--trial  { background: linear-gradient(135deg, #fefce8, #fef9c3); border-color: #fde68a; }
.license-status-card--warn   { background: linear-gradient(135deg, #fffbeb, #fef3c7); border-color: #fde68a; }
.license-status-card--expired { background: linear-gradient(135deg, #fef2f2, #fee2e2); border-color: #fecaca; }
.license-status-card--superadmin { background: linear-gradient(135deg, #eef2ff, #e0e7ff); border-color: #c7d2fe; }
.license-status-card--none   { background: #f8fafc; border-color: #e2e8f0; }

.license-status-icon { font-size: 1.6rem; flex-shrink: 0; }
.license-status-info { flex: 1; }
.license-status-title { font-size: 0.95rem; font-weight: 700; color: #1e293b; margin: 0; }
.license-status-sub { font-size: 0.78rem; color: #64748b; margin: 2px 0 0 0; }
.license-status-limits { font-size: 0.72rem; color: #94a3b8; margin: 4px 0 0 0; }

.license-status-badge {
    font-size: 0.68rem;
    font-weight: 700;
    padding: 4px 12px;
    border-radius: 20px;
    letter-spacing: 0.5px;
    white-space: nowrap;
}
.license-status-badge--active { background: #d1fae5; color: #065f46; }
.license-status-badge--warn { background: #fef3c7; color: #92400e; }
.license-status-badge--expired { background: #fee2e2; color: #991b1b; }
.license-status-badge--none { background: #f1f5f9; color: #94a3b8; }

/* === SUPER ADMIN PANEL === */
.license-admin-panel {
    background: linear-gradient(135deg, #f5f3ff, #ede9fe);
    border: 1px solid #c4b5fd;
    border-radius: 14px;
    padding: 0;
    margin-bottom: 24px;
    overflow: hidden;
}

.license-admin-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    border-bottom: 1px solid rgba(139, 92, 246, 0.15);
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.08), transparent);
}
.license-admin-header-icon { font-size: 1.3rem; }
.license-admin-header-title { font-size: 0.95rem; font-weight: 700; color: #4c1d95; }
.license-admin-header-sub { font-size: 0.75rem; color: #7c3aed; }

.license-admin-form {
    padding: 16px 20px;
}

.license-admin-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 14px;
}

.license-admin-field label {
    display: block;
    font-size: 0.7rem;
    font-weight: 600;
    color: #6d28d9;
    margin-bottom: 4px;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.license-admin-select,
.license-admin-input {
    width: 100%;
    padding: 8px 10px;
    border: 1px solid #c4b5fd;
    border-radius: 8px;
    font-size: 0.82rem;
    color: #1e293b;
    background: #fff;
    transition: border-color 0.15s;
    box-sizing: border-box;
}
.license-admin-select:focus,
.license-admin-input:focus {
    border-color: #8b5cf6;
    outline: none;
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.1);
}

.license-admin-generate-btn {
    width: 100%;
    padding: 12px;
    border-radius: 10px;
    border: none;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    background: linear-gradient(135deg, #7c3aed, #6d28d9);
    color: white;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.license-admin-generate-btn:hover {
    background: linear-gradient(135deg, #8b5cf6, #7c3aed);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(124, 58, 237, 0.3);
}
.license-admin-generate-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}
.license-admin-generate-icon { font-size: 1.1rem; }

/* Generated code result */
.license-generated-code {
    background: #fff;
    border-top: 1px solid rgba(139, 92, 246, 0.15);
    padding: 16px 20px;
}
.license-generated-label {
    font-size: 0.8rem;
    color: #4c1d95;
    font-weight: 600;
    margin-bottom: 8px;
}
.license-generated-value {
    font-size: 1.5rem;
    font-weight: 800;
    color: #7c3aed;
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
    text-align: center;
    padding: 10px;
    background: linear-gradient(135deg, #f5f3ff, #ede9fe);
    border-radius: 10px;
    margin-bottom: 10px;
    border: 1px dashed #c4b5fd;
}
.license-generated-meta {
    font-size: 0.75rem;
    color: #64748b;
    text-align: center;
    margin-bottom: 8px;
}
.license-generated-hint {
    font-size: 0.72rem;
    color: #94a3b8;
    text-align: center;
    margin-bottom: 12px;
}

/* Share buttons */
.license-admin-share-buttons {
    display: flex;
    gap: 8px;
    justify-content: center;
    flex-wrap: wrap;
}
.license-share-btn {
    font-size: 0.75rem;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    background: #fff;
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    gap: 4px;
    color: #475569;
}
.license-share-btn:hover {
    background: #f1f5f9;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}
.license-share-whatsapp:hover { background: #dcfce7; border-color: #86efac; color: #166534; }
.license-share-email:hover { background: #dbeafe; border-color: #93c5fd; color: #1e40af; }
.license-share-teams:hover { background: #ede9fe; border-color: #c4b5fd; color: #6d28d9; }

/* === PLANS SECTION === */
.license-plans-section {
    margin-bottom: 20px;
}

.license-plans-launch-banner {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border: 1px solid #f59e0b;
    border-radius: 10px;
    padding: 10px 16px;
    text-align: center;
    margin-bottom: 16px;
    font-size: 0.82rem;
    font-weight: 600;
    color: #92400e;
}
.license-plans-launch-banner small {
    display: block;
    font-size: 0.7rem;
    font-weight: 500;
    color: #a16207;
    margin-top: 2px;
}

.license-plans-cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

/* Plan card */
.license-plan-card {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 18px 14px;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    transition: all 0.25s ease;
}
.license-plan-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}
.license-plan-card.highlighted {
    border-color: #0066cc;
    box-shadow: 0 0 0 1px #0066cc, 0 4px 20px rgba(0, 102, 204, 0.1);
}
.license-plan-card.current-plan {
    border-color: #059669;
    background: linear-gradient(180deg, #ecfdf5 0%, #fff 40%);
}

/* Plan badge */
.license-plan-badge {
    position: absolute;
    top: -10px;
    font-size: 0.65rem;
    font-weight: 700;
    padding: 3px 12px;
    border-radius: 20px;
    background: #0066cc;
    color: white;
    letter-spacing: 0.3px;
    white-space: nowrap;
}
.license-plan-badge.current {
    background: #059669;
}

.license-plan-icon { font-size: 2rem; margin: 4px 0 6px; }
.license-plan-name { font-size: 1.1rem; font-weight: 800; color: #1e293b; }
.license-plan-tagline { font-size: 0.72rem; color: #94a3b8; margin: 2px 0 10px; }

/* Price */
.license-plan-price {
    display: flex;
    align-items: baseline;
    gap: 4px;
    margin-bottom: 2px;
}
.price-original {
    text-decoration: line-through;
    color: #94a3b8;
    font-size: 0.85rem;
}
.price-amount {
    font-size: 1.5rem;
    font-weight: 800;
    color: #1e293b;
}
.price-period {
    font-size: 0.7rem;
    color: #64748b;
}
.license-plan-yearly {
    font-size: 0.72rem;
    color: #475569;
    margin-top: -2px;
}
.yearly-savings {
    color: #059669;
    font-weight: 700;
}

/* Features list */
.license-plan-features {
    list-style: none;
    margin: 8px 0;
    padding: 0;
    text-align: left;
    width: 100%;
}
.license-plan-features li {
    font-size: 0.72rem;
    color: #475569;
    padding: 3px 0;
    display: flex;
    align-items: flex-start;
    gap: 6px;
    line-height: 1.4;
}
.feature-check {
    color: #059669;
    font-weight: 800;
    flex-shrink: 0;
    font-size: 0.75rem;
}

/* CTA Buttons Group */
.license-plan-cta-group {
    width: 100%;
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: auto;
}

/* CTA Button */
.license-plan-cta {
    width: 100%;
    padding: 9px 12px;
    border-radius: 8px;
    border: none;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.2s;
}
.license-plan-cta.cta-primary {
    background: linear-gradient(135deg, #0066cc, #0055aa);
    color: white;
}
.license-plan-cta.cta-primary:hover {
    background: linear-gradient(135deg, #0077ee, #0066cc);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 102, 204, 0.3);
}
.license-plan-cta.cta-secondary {
    background: #1e293b;
    color: white;
}
.license-plan-cta.cta-secondary:hover {
    background: #334155;
    transform: translateY(-1px);
}
.license-plan-cta.cta-disabled {
    background: #e2e8f0;
    color: #94a3b8;
    cursor: default;
}
.license-plan-cta.cta-trial {
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    color: #92400e;
    border: 1px solid #f59e0b;
}
.license-plan-cta.cta-trial:hover {
    background: linear-gradient(135deg, #fde68a, #fbbf24);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.25);
}

/* === REDEEM SECTION === */
.license-redeem-section {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #e2e8f0;
}
.license-code-row {
    display: flex;
    gap: 8px;
}
.license-code-input {
    flex: 1;
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid #cbd5e1;
    font-size: 1rem;
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
    text-transform: uppercase;
    color: #1e293b;
    text-align: center;
}
.license-code-input:focus {
    border-color: #0066cc;
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}
.license-redeem-btn {
    padding: 10px 24px;
    border-radius: 10px;
    border: none;
    font-size: 0.9rem;
    font-weight: 700;
    cursor: pointer;
    background: linear-gradient(135deg, #059669, #047857);
    color: white;
    transition: all 0.2s;
    white-space: nowrap;
}
.license-redeem-btn:hover {
    background: linear-gradient(135deg, #10b981, #059669);
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(5, 150, 105, 0.3);
}
.license-redeem-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}
.license-hint {
    font-size: 0.72rem;
    color: #94a3b8;
    margin: 6px 0 0;
}

/* === CONTACT POPUP === */
.license-contact-popup-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    border-radius: 0 0 16px 16px;
    backdrop-filter: blur(4px);
}
.license-contact-popup-content {
    padding: 24px;
    text-align: center;
    max-width: 420px;
}
.license-contact-popup h4 {
    font-size: 1.2rem;
    color: #1e293b;
    margin: 0 0 8px 0;
}
.license-contact-popup p {
    font-size: 0.9rem;
    color: #475569;
    margin: 0 0 16px 0;
}
.license-contact-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-bottom: 20px;
}
.license-contact-option {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    text-align: left;
}
.contact-icon { font-size: 1.4rem; flex-shrink: 0; }
.license-contact-option strong { display: block; font-size: 0.85rem; color: #1e293b; margin-bottom: 2px; }
.license-contact-option a, .license-contact-option span { font-size: 0.8rem; color: #0066cc; }
.license-contact-option span { color: #64748b; }

/* === PAYMENT MODAL === */
.license-payment-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 60000;
    padding: 20px;
    animation: fadeIn 0.2s ease;
}

.license-payment-modal {
    background: #fff;
    border-radius: 20px;
    width: 100%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.3);
    animation: slideUp 0.3s ease;
    position: relative;
}

.license-payment-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 24px;
    border-bottom: 1px solid #e2e8f0;
}
.license-payment-header h3 {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 700;
    color: #1e293b;
}

.license-payment-body {
    padding: 20px 24px;
}

.license-payment-plan-summary {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: linear-gradient(135deg, #f0f9ff, #e0f2fe);
    border-radius: 12px;
    border: 1px solid #bae6fd;
}
.payment-plan-icon { font-size: 1.5rem; }
.license-payment-plan-summary strong { display: block; font-size: 0.95rem; color: #0c4a6e; }
.payment-plan-tagline { display: block; font-size: 0.75rem; color: #0284c7; }

/* Period selector */
.license-pay-periods {
    display: flex;
    flex-direction: column;
    gap: 6px;
}
.license-pay-period {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    cursor: pointer;
    transition: all 0.15s;
}
.license-pay-period:hover { border-color: #93c5fd; background: #f0f9ff; }
.license-pay-period.active { border-color: #0066cc; background: #eff6ff; box-shadow: 0 0 0 1px #0066cc; }
.license-pay-period input[type="radio"] { display: none; }
.period-info { display: flex; flex-direction: column; }
.period-label { font-size: 0.85rem; font-weight: 600; color: #1e293b; }
.period-price { font-size: 0.75rem; color: #64748b; }
.period-savings {
    font-size: 0.7rem;
    font-weight: 700;
    color: #059669;
    background: #dcfce7;
    padding: 2px 8px;
    border-radius: 12px;
}

/* Payment methods */
.license-pay-methods {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
    margin-bottom: 14px;
}
.license-pay-method {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    padding: 10px 8px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    cursor: pointer;
    font-size: 0.75rem;
    font-weight: 600;
    color: #64748b;
    transition: all 0.15s;
    text-align: center;
}
.license-pay-method:hover { border-color: #93c5fd; background: #f0f9ff; }
.license-pay-method.active { border-color: #0066cc; background: #eff6ff; color: #0c4a6e; }
.license-pay-method input[type="radio"] { display: none; }
.method-icon { font-size: 1.3rem; }

/* Card form */
.license-pay-card-form {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 14px;
}
.license-pay-input {
    padding: 10px 14px;
    border-radius: 8px;
    border: 1px solid #cbd5e1;
    font-size: 0.88rem;
    color: #1e293b;
    width: 100%;
    box-sizing: border-box;
}
.license-pay-input:focus {
    border-color: #0066cc;
    outline: none;
    box-shadow: 0 0 0 3px rgba(0, 102, 204, 0.1);
}
.license-pay-card-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px;
}

/* Total & submit */
.license-pay-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 14px 0;
    border-top: 1px solid #e2e8f0;
    margin-bottom: 12px;
    font-size: 0.95rem;
    color: #1e293b;
}
.license-pay-total strong {
    font-size: 1.2rem;
    font-weight: 800;
    color: #059669;
}

.license-pay-submit-btn {
    width: 100%;
    padding: 14px;
    border-radius: 12px;
    border: none;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    background: linear-gradient(135deg, #059669, #047857);
    color: white;
    transition: all 0.2s;
}
.license-pay-submit-btn:hover {
    background: linear-gradient(135deg, #10b981, #059669);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(5, 150, 105, 0.3);
}
.license-pay-submit-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.license-pay-disclaimer {
    font-size: 0.68rem;
    color: #94a3b8;
    text-align: center;
    margin: 10px 0 0;
    line-height: 1.4;
}

/* === LOADING OVERLAY === */
.license-payment-loading-overlay {
    position: absolute;
    inset: 0;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    border-radius: 20px;
}
.license-payment-loading-content {
    text-align: center;
}
.license-payment-loading-content p {
    font-size: 0.95rem;
    font-weight: 600;
    color: #1e293b;
    margin: 14px 0 4px;
}
.license-payment-loading-content small {
    font-size: 0.75rem;
    color: #94a3b8;
}

/* Spinner */
.license-payment-spinner {
    width: 44px;
    height: 44px;
    border: 4px solid #e2e8f0;
    border-top-color: #059669;
    border-radius: 50%;
    margin: 0 auto;
    animation: spin 0.8s linear infinite;
}
@keyframes spin {
    to { transform: rotate(360deg); }
}

/* === PAYMENT SUCCESS OVERLAY === */
.license-payment-success-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 70000;
    padding: 20px;
    animation: fadeIn 0.2s ease;
}
.license-payment-success-content {
    background: #fff;
    border-radius: 24px;
    padding: 40px 32px;
    text-align: center;
    max-width: 440px;
    width: 100%;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.2);
    animation: slideUp 0.3s ease;
}
.payment-success-icon { font-size: 3rem; margin-bottom: 8px; }
.license-payment-success-content h3 {
    font-size: 1.4rem;
    font-weight: 800;
    color: #059669;
    margin: 0 0 6px;
}
.license-payment-success-content p {
    font-size: 0.9rem;
    color: #475569;
    margin: 0 0 18px;
}
.payment-success-code {
    background: linear-gradient(135deg, #ecfdf5, #d1fae5);
    border: 1px dashed #34d399;
    border-radius: 12px;
    padding: 14px;
    margin-bottom: 18px;
}
.payment-success-code-label {
    display: block;
    font-size: 0.72rem;
    color: #065f46;
    margin-bottom: 6px;
}
.payment-success-code-value {
    display: block;
    font-size: 1.4rem;
    font-weight: 800;
    color: #047857;
    font-family: 'Courier New', monospace;
    letter-spacing: 2px;
}
.payment-success-details {
    text-align: left;
    font-size: 0.8rem;
    color: #475569;
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-bottom: 20px;
    padding: 12px 16px;
    background: #f8fafc;
    border-radius: 10px;
}
.payment-success-details strong { color: #1e293b; }

/* === PAYMENT REMINDER POPUP === */
.license-payment-reminder {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 80000;
    animation: slideUp 0.4s ease;
    max-width: 520px;
    width: calc(100% - 40px);
}
.payment-reminder-content {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 20px;
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    border: 1px solid #f59e0b;
    border-radius: 14px;
    box-shadow: 0 8px 32px rgba(245, 158, 11, 0.3);
}
.payment-reminder-icon { font-size: 1.5rem; flex-shrink: 0; }
.payment-reminder-text { flex: 1; }
.payment-reminder-text strong {
    display: block;
    font-size: 0.85rem;
    color: #92400e;
    margin-bottom: 2px;
}
.payment-reminder-text span {
    font-size: 0.75rem;
    color: #a16207;
}
.payment-reminder-btn {
    padding: 8px 18px;
    border-radius: 8px;
    border: none;
    font-size: 0.8rem;
    font-weight: 700;
    cursor: pointer;
    background: #f59e0b;
    color: #fff;
    white-space: nowrap;
    transition: all 0.15s;
}
.payment-reminder-btn:hover {
    background: #d97706;
    transform: translateY(-1px);
}
.payment-reminder-dismiss {
    background: none;
    border: none;
    font-size: 1.3rem;
    color: #a16207;
    cursor: pointer;
    padding: 2px 6px;
    flex-shrink: 0;
}

/* === RESPONSIVE === */
@media (max-width: 640px) {
    .license-plans-cards {
        grid-template-columns: 1fr;
    }
    .license-modal {
        max-width: 95% !important;
    }
    .license-admin-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    .license-pay-methods {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 641px) and (max-width: 900px) {
    .license-plans-cards {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ══════════════════════════════════════════════════════════════════════
   SIDEBAR ACCOUNT BADGE — Cápsula de rol en el footer del sidebar
   Estilo ChatGPT: pill compacto con ícono y texto sobre fondo oscuro
   ══════════════════════════════════════════════════════════════════════ */
.sidebar-account-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 10px;
    margin-bottom: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.08);
}
.sidebar-account-badge:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-1px);
}

.sidebar-account-icon {
    flex-shrink: 0;
    opacity: 0.7;
}

.sidebar-account-label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    color: rgba(255, 255, 255, 0.65);
    transition: opacity 0.2s ease;
}

/* ── Variantes de color por rol ── */
.sidebar-account-badge--superadmin {
    background: linear-gradient(135deg, rgba(139, 92, 246, 0.18), rgba(124, 58, 237, 0.12));
    border-color: rgba(139, 92, 246, 0.3);
}
.sidebar-account-badge--superadmin .sidebar-account-label {
    color: #c4b5fd;
}
.sidebar-account-badge--superadmin .sidebar-account-icon {
    stroke: #c4b5fd;
    opacity: 1;
}

.sidebar-account-badge--owner {
    background: linear-gradient(135deg, rgba(34, 197, 94, 0.15), rgba(5, 150, 105, 0.1));
    border-color: rgba(34, 197, 94, 0.25);
}
.sidebar-account-badge--owner .sidebar-account-label {
    color: #86efac;
}
.sidebar-account-badge--owner .sidebar-account-icon {
    stroke: #86efac;
    opacity: 1;
}

.sidebar-account-badge--editor {
    background: linear-gradient(135deg, rgba(0, 173, 239, 0.15), rgba(0, 145, 234, 0.1));
    border-color: rgba(0, 173, 239, 0.25);
}
.sidebar-account-badge--editor .sidebar-account-label {
    color: #7dd3fc;
}
.sidebar-account-badge--editor .sidebar-account-icon {
    stroke: #7dd3fc;
    opacity: 1;
}

.sidebar-account-badge--viewer {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.15), rgba(217, 119, 6, 0.1));
    border-color: rgba(245, 158, 11, 0.25);
}
.sidebar-account-badge--viewer .sidebar-account-label {
    color: #fde68a;
}
.sidebar-account-badge--viewer .sidebar-account-icon {
    stroke: #fde68a;
    opacity: 1;
}

/* ── Cuando el sidebar está colapsado ── */
#app-sidebar.collapsed .sidebar-account-badge {
    justify-content: center;
    padding: 8px;
}
#app-sidebar.collapsed .sidebar-account-label {
    opacity: 0;
    width: 0;
    pointer-events: none;
}

/* ══════════════════════════════════════════════════════════════════════
   INTRO BANNER — Banner de periodo de introducción / trial expirado
   Se muestra en "Mis Proyectos" sobre fondo #003366 oscuro.
   Diseño: capsule con gradiente, borde visible, texto contrastante.
   ══════════════════════════════════════════════════════════════════════ */
.intro-banner {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 20px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(0, 173, 239, 0.15), rgba(0, 145, 234, 0.08));
    border: 1px solid rgba(0, 173, 239, 0.35);
    backdrop-filter: blur(4px);
    margin: 0;
    animation: fadeIn 0.3s ease;
}

.intro-banner.expired {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.18), rgba(217, 119, 6, 0.08));
    border-color: rgba(245, 158, 11, 0.4);
}

.intro-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
    line-height: 1;
}

.intro-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.intro-text strong {
    font-size: 0.88rem;
    font-weight: 700;
    color: #ffffff;
    line-height: 1.3;
}

.intro-text span {
    font-size: 0.78rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.3;
}

.intro-banner.expired .intro-text strong {
    color: #fde68a;
}

.intro-banner.expired .intro-text span {
    color: rgba(253, 230, 138, 0.7);
}

.intro-upgrade-btn {
    padding: 8px 20px;
    border-radius: 8px;
    border: none;
    font-size: 0.82rem;
    font-weight: 700;
    cursor: pointer;
    background: linear-gradient(135deg, #00ADEF, #0091ea);
    color: #ffffff;
    white-space: nowrap;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(0, 173, 239, 0.3);
    flex-shrink: 0;
}
.intro-upgrade-btn:hover {
    background: linear-gradient(135deg, #33c0f5, #00ADEF);
    transform: translateY(-1px);
    box-shadow: 0 4px 16px rgba(0, 173, 239, 0.4);
}

.intro-upgrade-btn.pulse {
    animation: pulse-glow 2s ease-in-out infinite;
}
@keyframes pulse-glow {
    0%, 100% { box-shadow: 0 2px 8px rgba(0, 173, 239, 0.3); }
    50% { box-shadow: 0 4px 24px rgba(0, 173, 239, 0.6); }
}

.intro-banner.expired .intro-upgrade-btn {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.3);
}
.intro-banner.expired .intro-upgrade-btn:hover {
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    box-shadow: 0 4px 16px rgba(245, 158, 11, 0.5);
}

/* ── Plan info banner container ── */
#plan-info-banner {
    margin: 8px 0;
    padding: 0;
}

/* ── Responsive ── */
@media (max-width: 640px) {
    .intro-banner {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
        padding: 12px 16px;
    }
    .intro-upgrade-btn {
        width: 100%;
        text-align: center;
    }
}
