/* NEXA FONT LOADED VIA CDN IN HTML HEAD */

/* FontAwesome Legacy Compatibility */
.fa, .fas, .far, .fab {
    font-family: "Font Awesome 6 Free" !important;
}

:root {
    --bg-dark: #0E131F;
    --bg-card: rgba(11, 27, 61, 0.4);
    --bg-sidebar: #070a14;
    --accent-cyan: #01E4C1;
    --accent-teal: #04CBBE;
    --accent-blue: #313664;
    --text-primary: #F8FBFC;
    --text-secondary: #94a3b8;
    --text-muted: #53647a;
    --glass-border: rgba(1, 228, 193, 0.1);
    
    --sidebar-width: 260px;
    --header-height: 70px;
    --radius-lg: 20px;
    --radius-md: 14px;
    --radius-sm: 10px;
    --shadow-glow: 0 0 20px rgba(1, 228, 193, 0.15);
    --glass-bg: rgba(15, 23, 42, 0.85);
}

/* Ocultar "Trocar senha" e "Atualizar dados" em todos os menus */
a[href*="trocar_senha.hhvm"],
a[href*="atualizar_dados.hhvm"],
.submenu-item[href*="trocar_senha.hhvm"],
.submenu-item[href*="atualizar_dados.hhvm"],
.dropdown-link[href*="trocar_senha.hhvm"],
.dropdown-link[href*="atualizar_dados.hhvm"] {
    display: none !important;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Nexa', sans-serif;
    background-color: var(--bg-dark);
    background-image: 
        radial-gradient(circle at 100% 0%, rgba(1, 228, 193, 0.12) 0%, transparent 50%),
        radial-gradient(circle at 0% 100%, rgba(4, 203, 190, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 50% 50%, rgba(49, 54, 100, 0.2) 0%, transparent 100%);
    background-attachment: fixed;
    color: var(--text-primary);
    min-height: 100dvh;
    width: 100%;
}

/* --- SCROLLBAR --- */
::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 10px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.2);
}



/* --- LAYOUT STRUCTURE --- */

.app-container {
    display: flex;
    min-height: 100dvh;
    width: 100%;
}

/* SIDEBAR */
.sidebar {
    width: var(--sidebar-width);
    background: var(--bg-sidebar);
    border-right: 1px solid var(--glass-border);
    position: fixed;
    height: 100vh;
    display: flex;
    flex-direction: column;
    z-index: 1000;
}

.sidebar-brand {
    padding: 32px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.brand-logo {
    width: 52px;
    height: 52px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 14px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--glass-border);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
    transition: all 0.3s ease;
    flex-shrink: 0; /* Impede que o texto esmague a logo */
}

.brand-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.brand-name {
    font-weight: 800;
    font-size: 22px;
    line-height: 1.1;
    letter-spacing: 2px;
    color: var(--text-primary);
    text-transform: uppercase;
    font-family: 'Nexa', sans-serif;
}

.nav-menu {
    flex: 1;
    padding: 20px 16px;
}

.nav-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    border-radius: var(--radius-sm);
    margin-bottom: 4px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
    cursor: pointer;
}

.nav-item:hover, .nav-item.active {
    background: rgba(1, 228, 193, 0.05);
    color: var(--accent-cyan);
}

.nav-item.active {
    border-left: 3px solid var(--accent-cyan);
    background: linear-gradient(90deg, rgba(1, 228, 193, 0.1) 0%, transparent 100%);
}

.nav-item-content {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-item i.toggle-icon {
    font-size: 10px;
    transition: transform 0.3s;
}

.submenu {
    display: none;
    padding-left: 48px;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 12px;
    overflow: hidden;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}

.submenu.active {
    display: flex;
}

.submenu-item {
    display: block;
    padding: 8px 12px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 13px;
    border-radius: 6px;
    transition: all 0.2s;
}

.submenu-item:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.03);
}

.nav-item.has-submenu.open i.toggle-icon {
    transform: rotate(180deg);
}

.nav-item.active::before {
    content: '';
    position: absolute;
    left: -16px;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 24px;
    background: var(--accent-cyan);
    border-radius: 0 4px 4px 0;
    box-shadow: var(--shadow-glow);
}

.sidebar-footer {
    padding: 32px 16px;
}

.logout-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #ff4b5c;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.2s;
}

.logout-btn:hover {
    background: rgba(255, 75, 92, 0.1);
    border-radius: var(--radius-sm);
}

/* MAIN AREA */
.main-wrapper {
    flex: 1;
    margin-left: var(--sidebar-width);
    display: flex;
    flex-direction: column;
}

/* HEADER */
.header {
    height: auto !important;
    min-height: 85px !important;
    padding: 20px 32px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    background: var(--glass-bg);
    backdrop-filter: blur(15px);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 20px;
}

.header-action {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-main);
    cursor: pointer;
    position: relative;
    transition: all 0.3s ease;
}

.header-action:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-2px);
}

.notification-badge {
    position: absolute;
    top: -2px;
    right: -2px;
    background: #ef4444;
    color: white;
    font-size: 9px;
    font-weight: 800;
    min-width: 18px;
    height: 18px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 2px solid #0E131F;
}

.notification-dropdown {
    position: absolute;
    top: 50px;
    right: 0;
    width: 300px;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.4);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s ease;
}

.notification-btn:hover .notification-dropdown {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-header {
    padding: 16px;
    font-weight: 700;
}

.dropdown-list {
    max-height: 300px;
    overflow-y: auto;
}

.notification-item {
    padding: 12px 16px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
    text-decoration: none;
    color: var(--text-secondary);
    transition: background 0.2s;
}

.notification-item:hover {
    background: rgba(255,255,255,0.05);
    color: var(--text-main);
}

.notification-item i {
    margin-top: 3px;
    color: var(--accent-cyan);
}

.company-badge {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 10px 0;
    background: transparent !important;
    border: none !important;
    transition: all 0.3s ease;
    cursor: default;
    box-shadow: none !important;
}

/* --- HEADER BRANDING LOGIC --- */

/* Desktop: Mostrar apenas ícone e Central Assinante */
.header-icon-desktop {
    display: flex !important;
}

.header-text-desktop {
    display: inline-block !important;
    font-size: 14px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    color: #ffffff;
    font-family: 'Nexa', sans-serif;
}

.header-text-desktop span {
    margin-left: 2px; /* Espaço reduzido entre as palavras */
}

.mobile-logo-header, 
.header-text-mobile {
    display: none !important;
}

/* Mobile: Mostrar apenas Logo e Gaspar Telecom */
@media (max-width: 1024px) {
    .header-icon-desktop, 
    .header-text-desktop {
        display: none !important;
    }
    
    .mobile-logo-header {
        display: block !important;
        width: 38px !important;
        height: 38px !important;
        object-fit: contain;
        border-radius: 8px;
        filter: drop-shadow(0 0 8px rgba(1, 228, 193, 0.3));
    }
    
    .header-text-mobile {
        display: block !important;
        font-size: 16px !important;
        font-weight: 800 !important;
        color: #ffffff !important;
        text-transform: uppercase;
        letter-spacing: 1px;
    }
}

.company-badge:hover {
    transform: translateY(-2px);
}

.company-badge i {
    font-size: 18px;
    color: var(--accent-cyan);
    background: rgba(1, 228, 193, 0.1);
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    border: 1px solid rgba(1, 228, 193, 0.2);
    filter: drop-shadow(0 0 10px rgba(1, 228, 193, 0.3));
    transition: all 0.3s ease;
}

.company-badge:hover i {
    background: transparent;
    color: var(--accent-cyan);
    transform: rotate(-10deg) scale(1.1);
    filter: drop-shadow(0 0 15px rgba(1, 228, 193, 0.6));
}

.company-badge span {
    font-size: 14px;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    background: linear-gradient(to right, #ffffff, #cbd5e1);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    font-family: 'Nexa', sans-serif;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 24px;
}

.notification-bell {
    position: relative;
    cursor: pointer;
    color: var(--text-secondary);
    font-size: 20px;
    transition: color 0.2s;
}

.notification-bell:hover {
    color: var(--text-primary);
}

.bell-badge {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 16px;
    height: 16px;
    background: #ff4b5c;
    border: 2px solid var(--bg-dark);
    border-radius: 50%;
    font-size: 9px;
    font-weight: 800;
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-section {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 40px;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
    color: inherit;
    line-height: normal;
}

.profile-section:hover {
    background: rgba(255, 255, 255, 0.08);
}

.user-name {
    font-size: 13px;
    font-weight: 600;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding-top: 2px; /* Compensação visual para a fonte Nexa */
}

.user-avatar {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, var(--accent-teal), var(--accent-cyan));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 13px;
    color: white;
}

/* BANNERS DE ALERTA E SISTEMA */
.alert-banner-wrapper { margin-bottom: 24px; width: 100%; }
.alert-banner {
    display: flex; align-items: center; gap: 20px; padding: 20px 24px;
    border-radius: 20px; border: 1px solid rgba(239, 68, 68, 0.2);
    background: rgba(239, 68, 68, 0.08); backdrop-filter: blur(15px);
    color: white; line-height: 1.4;
}
.alert-banner.danger i { font-size: 28px; color: #f87171; filter: drop-shadow(0 0 10px rgba(239, 68, 68, 0.4)); }
.alert-content { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.alert-title { font-weight: 800; color: #f87171; font-size: 13px; text-transform: uppercase; letter-spacing: 1px; }
.alert-text { font-size: 14px; color: rgba(255,255,255,0.9); }
.alert-text a { color: white; font-weight: 800; text-decoration: underline; transition: 0.2s; }
.alert-text a:hover { color: #f87171; }

@media (max-width: 640px) {
    .alert-banner { flex-direction: column; text-align: center; padding: 24px 16px; gap: 12px; }
    .alert-content { flex-direction: column; gap: 6px; }
    .alert-banner i { font-size: 36px; }
    .alert-title { font-size: 15px; }
}

/* CONTENT */
.content-body {
    padding: 40px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.section-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 40px;
}

/* SUMMARY CARDS */
.stat-card {
    position: relative;
    padding: 24px;
    border-radius: var(--radius-lg);
    border: 1px solid var(--glass-border);
    overflow: hidden;
    transition: transform 0.3s;
    min-height: 145px;
}

.stat-card:hover {
    transform: translateY(-5px);
}

/* Solid/Transparent Colors */
.stat-card:nth-child(1) {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(1, 228, 193, 0.15);
}

.stat-card:nth-child(2) {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(4, 203, 190, 0.15);
}

.stat-card:nth-child(3) {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid rgba(84, 160, 255, 0.15);
}

.stat-card .bg-icon {
    position: absolute;
    right: -15px;
    top: -15px;
    font-size: 90px;
    opacity: 0.1;
    color: white;
}

.stat-label {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-secondary);
    letter-spacing: 0.5px;
    margin-bottom: 8px;
    text-transform: uppercase;
}

.stat-value {
    font-size: 36px;
    font-weight: 800;
    margin-top: 4px;
    margin-bottom: 12px;
}

.stat-action {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.6);
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    line-height: 1;
    transition: all 0.3s ease;
    border-radius: 10px;
    padding: 0 16px;
    height: 42px;
}

.stat-action:hover {
    color: white;
    background: rgba(255, 255, 255, 0.05);
}

.stat-action-success {
    background: rgba(1, 228, 193, 0.1);
    color: var(--accent-cyan);
    border: 1px solid rgba(1, 228, 193, 0.2);
}

.stat-action-success:hover {
    background: var(--accent-cyan) !important;
    color: #0f172a !important;
    box-shadow: 0 0 15px rgba(1, 228, 193, 0.4);
    transform: translateY(-2px);
}

.stat-action-danger {
    background: rgba(255, 75, 92, 0.1);
    color: #ff4b5c;
    border: 1px solid rgba(255, 75, 92, 0.2);
}

.stat-action-danger:hover {
    background: #ff4b5c !important;
    color: #fff !important;
    box-shadow: 0 0 15px rgba(255, 75, 92, 0.4);
    transform: translateY(-2px);
}

.stat-action-purple {
    background: rgba(168, 85, 247, 0.1);
    color: #a855f7;
    border: 1px solid rgba(168, 85, 247, 0.2);
}

.stat-action-purple:hover {
    background: #a855f7 !important;
    color: #fff !important;
    box-shadow: 0 0 15px rgba(168, 85, 247, 0.4);
    transform: translateY(-2px);
}


/* MODERN CARDS & TABLES */
.modern-card {
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.03) 0%, rgba(255, 255, 255, 0.01) 100%);
    backdrop-filter: blur(25px);
    border: 1px solid rgba(255, 255, 255, 0.08); /* Borda de cristal */
    border-radius: var(--radius-lg);
    overflow: hidden;
    margin-bottom: 24px;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.3), inset 0 1px 1px rgba(255, 255, 255, 0.05); /* Efeito de brilho interno superior */
    transition: border-color 0.4s ease;
}

.modern-card:hover {
    border-color: rgba(1, 228, 193, 0.2);
}

.card-header {
    padding: 24px 32px;
    background: rgba(255, 255, 255, 0.02);
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

.table-wrapper {
    width: 100%;
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
}

.data-table th {
    background: rgba(0, 0, 0, 0.1);
    padding: 20px 32px;
    text-align: left;
    font-size: 11px;
    font-weight: 800;
    text-transform: uppercase;
    color: var(--accent-cyan);
    letter-spacing: 2px;
    font-family: 'Nexa', sans-serif;
}

.data-table td {
    padding: 20px 32px;
    font-size: 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
    color: rgba(255, 255, 255, 0.75);
    transition: all 0.3s ease;
}

.data-table tbody tr:hover {
    background: rgba(1, 228, 193, 0.03);
    box-shadow: inset 4px 0 0 var(--accent-cyan);
}

.data-table tbody tr:hover td {
    padding-left: 6px; /* Sutil push para desktop */
}

@media (max-width: 768px) {
    .data-table tbody tr:hover td {
        padding-left: 0 !important;
    }
}

@media (max-width: 768px) {
    .data-table, .data-table thead, .data-table tbody, .data-table th, .data-table td, .data-table tr {
        display: block;
        width: 100%;
    }

    .data-table thead {
        display: none; /* Hide headers on mobile */
    }

    .data-table tr {
        background: rgba(255, 255, 255, 0.02) !important;
        border: 1px solid rgba(255, 255, 255, 0.05) !important;
        border-radius: 18px;
        padding: 16px;
        margin-bottom: 16px !important;
        box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
        display: block;
        transition: all 0.3s ease;
    }

    .data-table tr:hover {
        background: rgba(1, 228, 193, 0.04) !important;
        border-color: rgba(1, 228, 193, 0.15) !important;
    }

    .data-table td {
        border-bottom: none;
        padding: 10px 0;
        display: flex;
        justify-content: space-between;
        align-items: center;
        text-align: right;
        font-size: 14px;
        color: var(--text-primary);
    }

    .data-table td:last-child {
        border-bottom: none;
        padding-bottom: 0;
        margin-top: 12px;
    }

    .data-table td::before {
        content: attr(data-label);
        font-weight: 700;
        font-size: 10px;
        text-transform: uppercase;
        color: var(--text-secondary);
        opacity: 0.6;
        text-align: left;
        letter-spacing: 1px;
    }

    /* Ajuste para o badge de tráfego no mobile */
    .data-table td[data-label="TRÁFEGO"] {
        margin-top: 8px;
        padding-top: 12px;
        border-top: 1px solid rgba(255, 255, 255, 0.03);
    }

    .data-table td div {
        display: flex;
        align-items: center;
        gap: 8px;
    }
}

/* PAYMENT ACTIONS */
.payment-actions {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    width: 100%;
}

.pix-container { display: inline-block; }
/* Style the auto-generated MK-AUTH PIX link */
.pix-container a,
.pix-container {
    text-decoration: none;
}

.pix-container a i::after, 
.pix-container i.fa-qrcode::after {
    content: "PIX";
    font-family: inherit;
    font-weight: 800;
    font-size: 13px;
    font-style: normal;
    letter-spacing: 0px;
}

.pix-container a i, 
.pix-container i.fa-qrcode {
    padding: 0 16px;
    height: 42px;
    border-radius: 10px;
    background: rgba(6, 182, 212, 0.1);
    color: var(--accent-cyan);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: all 0.3s ease;
    border: 1px solid rgba(6, 182, 212, 0.2);
    gap: 8px;
    box-sizing: border-box;
}

.pix-container a:hover i {
    background: var(--accent-cyan);
    color: #000;
    box-shadow: 0 0 15px rgba(6, 182, 212, 0.4);
}

@media (max-width: 640px) {
    /* Célula de ações adaptativa */
    .data-table td.payment-cell {
        flex-direction: column !important;
        align-items: center !important;
        padding: 20px 10px !important;
    }
    .data-table td.payment-cell::before {
        display: none !important;
    }
    
    .payment-actions {
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        gap: 8px !important;
        width: 100% !important;
        margin: 0 !important;
        padding: 0 !important;
        border: none !important;
    }
    
    /* Botões com largura controlada e flexíveis */
    .payment-actions a, .payment-actions .stat-action, .pix-container, .pix-container a, .pix_copy, .btn-pix {
        flex: 1 !important;
        max-width: 120px !important; /* Tamanho perfeito para 3 em linha */
        height: 50px !important;
        min-width: 0 !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        margin: 0 !important;
        border-radius: 12px !important;
    }
}

@media (max-width: 640px) {
    .page-header {
        text-align: center;
        margin-bottom: 24px !important;
    }
}

.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: 30px;
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(4px);
}

.badge i {
    font-size: 11px;
}

.badge-open, .badge-success {
    background: rgba(1, 228, 193, 0.15);
    color: #07ffda; /* Versão ultra-brilhante do ciano */
    border: 1px solid rgba(1, 228, 193, 0.3);
}

.badge-overdue, .badge-danger {
    background: rgba(255, 71, 87, 0.15);
    color: #ff5e6c; /* Vermelho mais vibrante */
    border: 1px solid rgba(255, 71, 87, 0.3);
}

.badge-pending, .badge-warning {
    background: rgba(255, 159, 67, 0.15);
    color: #ffb167; /* Ambar mais visível */
    border: 1px solid rgba(255, 159, 67, 0.3);
}

.badge-info {
    background: rgba(84, 160, 255, 0.15);
    color: #70b1ff; /* Azul mais claro */
    border: 1px solid rgba(84, 160, 255, 0.3);
}

/* SECONDARY PANELS */
.info-grid {
    display: grid;
    grid-template-columns: 1fr 340px;
    gap: 24px;
}

.empty-state {
    padding: 40px;
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
}

.notice-board {
    padding: 24px;
}

.notice-item {
    margin-bottom: 20px;
}

.notice-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 12px;
    display: block;
}

.progress-track {
    height: 8px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 4px;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--accent-blue), var(--accent-cyan));
    width: 30%;
    border-radius: 4px;
    box-shadow: var(--shadow-glow);
}

/* FOOTER */
.main-footer {
    margin-top: auto;
    padding: 60px 0 40px;
    text-align: center;
}

.social-links {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
}

.social-links a {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255,255,255,0.05);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    font-size: 20px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background: var(--accent-gradient);
    color: white;
    transform: scale(1.1);
}

.footer-info {
    font-size: 13px;
    color: var(--text-muted);
}

/* ALERTS */
.alert-glass {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    border-radius: 20px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    backdrop-filter: blur(10px);
    gap: 20px;
}

.alert-content {
    display: flex;
    align-items: center;
    gap: 16px;
    color: var(--text-main);
}

.alert-content i {
    font-size: 24px;
    color: var(--accent-danger);
}

.alert-content strong {
    display: block;
    margin-bottom: 2px;
}

.alert-content p {
    font-size: 13px;
    color: var(--text-secondary);
    margin: 0;
}

.alert-action {
    padding: 10px 20px;
    background: var(--accent-danger);
    color: white;
    text-decoration: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 13px;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.alert-action:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(239, 68, 68, 0.4);
}
.mobile-toggle {
    display: none;
    font-size: 24px;
    cursor: pointer;
}

/* --- MOBILE APP-LIKE UI --- */
.bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 65px;
    background: rgba(10, 14, 26, 0.85);
    backdrop-filter: blur(20px);
    z-index: 2000;
    justify-content: space-around;
    align-items: center;
    padding: 0 10px;
}

.bottom-nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 10px;
    font-weight: 600;
    transition: all 0.2s;
}

.bottom-nav-item i {
    font-size: 20px;
}

.bottom-nav-item.active {
    color: var(--accent-cyan);
}

.bottom-nav-item.active i {
    text-shadow: 0 0 10px rgba(0, 242, 255, 0.5);
}

@media (max-width: 1024px) {
    .bottom-nav {
        display: flex;
    }
    
    .header {
        height: auto !important;
        min-height: 75px !important;
        padding-top: env(safe-area-inset-top, 15px) !important;
        padding-bottom: 5px !important;
        padding-left: 20px !important;
        padding-right: 20px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: space-between !important;
        box-sizing: border-box !important;
    }
    
    .main-wrapper {
        margin-left: 0 !important;
        width: 100%;
        min-width: 0;
    }
    
    .content-body {
        padding: 24px 20px 100px !important;
        flex: 1;
        display: flex;
        flex-direction: column;
    }

    .page-header {
        text-align: center !important;
        margin-bottom: 24px !important;
    }
    
    .page-header h1 {
        font-size: 24px !important;
        margin-bottom: 4px !important;
    }
    
    .page-header p {
        margin: 0 auto;
    }
    
    .sidebar {
        display: none !important;
    }
    
    .section-grid {
        grid-template-columns: 1fr;
    }
    
    .info-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .mobile-toggle {
        display: none !important;
    }
    
    .header-actions {
        gap: 12px;
    }
}

/* --- AVATAR FIX --- */
.user-avatar {
    width: 42px;
    height: 42px;
    background: linear-gradient(135deg, var(--accent-teal), var(--accent-cyan));
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px; /* Slightly larger */
    color: white;
    flex-shrink: 0;
    overflow: hidden; /* Ensure content doesn't bleed */
}

.profile-section {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 4px 12px; /* Tighter padding */
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 40px;
    cursor: pointer;
    transition: all 0.2s;
    max-width: 180px; /* Prevent it from exploding if name is too long */
}

.user-name {
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100px;
}


/* --- FORMS --- */
.form-card {
    padding: 32px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.input-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.field-label {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary); /* Changed from muted to secondary for more contrast */
    padding-left: 4px;
}

body {
    background-color: #0b1120;
    color: var(--text-primary);
    font-family: 'Nexa', sans-serif;
    margin: 0;
    padding: 0;
    line-height: 1.5;
}

.field-input,
.field-input-static {
    width: 100%;
    background: rgba(255, 255, 255, 0.02);
    border: 2px solid var(--glass-border);
    border-radius: 12px;
    padding: 14px 16px;
    color: white;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s;
    outline: none;
    display: block;
    min-height: 48px;
    box-sizing: border-box;
}

.field-input:focus {
    border-color: var(--accent-cyan);
    background: rgba(1, 228, 193, 0.05);
    box-shadow: 0 0 15px rgba(1, 228, 193, 0.1);
}

/* AUTOFILL OVERRIDE (Forçar tema dark no preenchimento automático do navegador) */
.field-input:-webkit-autofill,
.field-input:-webkit-autofill:hover, 
.field-input:-webkit-autofill:focus, 
.field-input:-webkit-autofill:active {
    -webkit-text-fill-color: white !important;
    -webkit-box-shadow: 0 0 0px 1000px #0b1120 inset !important;
    box-shadow: 0 0 0px 1000px #0b1120 inset !important;
    transition: background-color 5000s ease-in-out 0s;
}

/* FILE UPLOAD STYLING */
input[type="file"].field-input {
    padding: 60px 20px;
    border: 2px dashed var(--glass-border);
    background: rgba(255, 255, 255, 0.01);
    text-align: center;
    cursor: pointer;
    position: relative;
    color: var(--text-secondary);
}

input[type="file"].field-input:hover {
    border-color: var(--accent-cyan);
    background: rgba(1, 228, 193, 0.03);
}

input[type="file"].field-input::-webkit-file-upload-button {
    display: none;
}

input[type="file"].field-input::file-selector-button {
    display: none;
}

.field-input-static {
    background: rgba(255, 255, 255, 0.01);
    color: var(--text-secondary);
    cursor: default;
    display: flex;
    align-items: center;
}

.field-input:focus {
    outline: none;
    border-color: var(--accent-cyan);
    background: rgba(0, 242, 255, 0.03);
    box-shadow: 0 0 15px rgba(0, 242, 255, 0.05);
}

select.field-input {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #ffffff !important;
    cursor: pointer;
}

select.field-input option {
    background-color: #0f172a;
    color: #ffffff;
}

.field-input:read-only,
.field-input:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.btn-submit, 
.stat-action,
.logout-btn,
.pagination a,
.btn-primary {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 24px;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.2s ease-in-out;
    border: none;
    text-decoration: none;
    background: var(--accent-cyan) !important;
    color: #0E131F !important;
    font-family: 'Nexa', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    width: auto;
    min-width: 120px;
    pointer-events: auto !important;
}

/* Ensure native selects are fully clickable */
select.field-input, select {
    pointer-events: auto !important;
    z-index: 10 !important;
    cursor: pointer !important;
    -webkit-tap-highlight-color: transparent;
}

.stat-action-danger {
    background: #ff4757 !important;
    color: white !important;
}

.stat-action-purple {
    background: #7c4dff !important;
    color: white !important;
}

.btn-submit:hover, 
.stat-action:hover,
.logout-btn:hover,
.pagination a:hover {
    filter: brightness(1.1);
    transform: translateY(-2px);
}

.login-btn-full {
    width: 100% !important;
}

/* Icon adjustments inside standard buttons */
.btn-submit i, .stat-action i, .logout-btn i {
    font-size: 16px;
    display: inline-flex;
    align-items: center;
    margin-top: -1px; /* Optical adjustment */
}

@media (max-width: 768px) {
    .form-grid {
        grid-template-columns: 1fr;
    }
}

/* --- LOGIN PAGE PREMIUM DESIGN --- */
.login-body {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    background: var(--bg-dark);
    padding: 20px;
    position: relative;
    overflow: hidden;
}

.login-body::before {
    display: none;
}

.login-body::after {
    display: none;
}

.login-wrapper-grid {
    width: 100%;
    max-width: 900px;
    z-index: 2;
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.25);
    display: grid;
    grid-template-columns: 1fr 400px;
    overflow: hidden;
    position: relative;
}

.login-info-side {
    padding: 60px 40px;
    background: rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    justify-content: center;
    border-right: 1px solid var(--glass-border);
}

.login-container {
    width: 100%;
    padding: 60px 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.login-mobile-logo {
    display: none;
}

.login-logo {
    width: 80px;
    height: 80px;
    margin: 0 auto 28px;
    padding: 12px;
    background: var(--bg-card);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-glow);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.login-logo img {
    width: 100%;
    height: 100%;
    object-fit: contain;
    border-radius: var(--radius-sm);
}

.login-header-text {
    text-align: center;
    margin-bottom: 32px;
}

.login-header-text h1 {
    font-size: 24px;
    font-weight: 800;
    letter-spacing: -0.5px;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.login-header-text p {
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 400;
}

.login-card {
    width: 100%;
}

@media (max-width: 860px) {
    .login-body {
        padding: 0;
        background: #0b1120 !important;
    }

    .login-wrapper-grid {
        grid-template-columns: 1fr;
        max-width: 100%;
        min-height: 100vh;
        border-radius: 0;
        border: none;
        backdrop-filter: none;
        background: transparent;
    }

    .login-info-side {
        display: none;
    }

    .login-container {
        padding: 60px 24px;
        min-height: 100vh;
        justify-content: flex-start;
        padding-top: 15vh;
        background: radial-gradient(circle at top right, rgba(1, 228, 193, 0.05), transparent 40%),
                    radial-gradient(circle at bottom left, rgba(84, 160, 255, 0.05), transparent 40%);
    }

    .login-mobile-logo {
        display: flex;
        align-items: center;
        justify-content: center;
        width: 80px;
        height: 80px;
        margin: 0 auto 32px;
        background: rgba(255, 255, 255, 0.03);
        border: 1px solid var(--glass-border);
        border-radius: 20px;
        padding: 10px;
        box-shadow: 0 10px 20px rgba(0,0,0,0.2);
    }

    .login-mobile-logo img {
        width: 100%;
        height: 100%;
        object-fit: contain;
        border-radius: 12px;
    }

    .login-header-text h1 {
        font-size: 28px;
    }

    .login-card {
        margin-top: 20px;
    }
}

.login-alert {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 16px 20px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    border-radius: 16px;
    margin-bottom: 24px;
    animation: shake 0.5s cubic-bezier(.36,.07,.19,.97) both;
}

@keyframes shake {
  10%, 90% { transform: translate3d(-1px, 0, 0); }
  20%, 80% { transform: translate3d(2px, 0, 0); }
  30%, 50%, 70% { transform: translate3d(-4px, 0, 0); }
  40%, 60% { transform: translate3d(4px, 0, 0); }
}

.login-alert i {
    font-size: 20px;
    color: #f87171;
}

.alert-msg-wrapper {
    display: flex;
    flex-direction: column;
}

.alert-msg-wrapper strong {
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: #f87171;
    margin-bottom: 2px;
}

.alert-msg-wrapper span {
    font-size: 13px;
    color: rgba(255,255,255,0.9);
}

/* LOGIN BUTTON */
.login-btn-full {
    width: 100%;
    height: 56px;
    background: var(--accent-cyan) !important;
    color: var(--bg-dark) !important;
    border: none;
    border-radius: 16px;
    font-size: 15px;
    font-weight: 800;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    display: flex;
    align-items: center;
    justify-content: center;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    margin-top: 12px;
    box-shadow: 0 10px 20px rgba(1, 228, 193, 0.15);
}

.login-btn-full:hover {
    filter: brightness(1.15);
    box-shadow: 0 8px 24px rgba(1, 228, 193, 0.2);
    transform: translateY(-2px);
}

.login-btn-full i {
    font-size: 16px;
    margin-left: 10px;
    transition: transform 0.25s ease;
}

.login-btn-full:hover i {
    transform: translateX(6px);
}

/* LOGIN INPUT FIELDS */
.login-icon {
    position: absolute;
    left: 16px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-muted);
    font-size: 16px;
    transition: color 0.25s ease;
    z-index: 10;
    background: none !important;
    border: none !important;
    width: auto !important;
    height: auto !important;
    display: block !important;
    border-radius: 0 !important;
}

.field-input.login-input {
    background: rgba(255, 255, 255, 0.03) !important;
    border: 1px solid rgba(255, 255, 255, 0.08) !important;
    padding: 14px 16px 14px 46px !important;
    font-size: 14px !important;
    font-weight: 500 !important;
    border-radius: var(--radius-md) !important;
    color: var(--text-primary) !important;
    transition: all 0.25s ease !important;
    height: 50px !important;
    width: 100% !important;
    color-scheme: dark; /* Força o autofill moderno para Dark Mode */
}

/* Força esmagadora sobre o login autofill */
.field-input.login-input:-webkit-autofill,
.field-input.login-input:-webkit-autofill:hover, 
.field-input.login-input:-webkit-autofill:focus, 
.field-input.login-input:-webkit-autofill:active {
    -webkit-text-fill-color: white !important;
    -webkit-box-shadow: 0 0 0px 1000px #0b1120 inset !important;
    box-shadow: 0 0 0px 1000px #0b1120 inset !important;
    background-color: transparent !important;
    transition: background-color 5000s ease-in-out 0s !important;
}

.field-input.login-input::placeholder {
    color: var(--text-muted) !important;
    font-weight: 400 !important;
}

.field-input.login-input:focus {
    border-color: var(--accent-cyan) !important;
    background: rgba(1, 228, 193, 0.03) !important;
    box-shadow: 0 0 0 3px rgba(1, 228, 193, 0.08) !important;
    outline: none !important;
}

.input-field:focus-within .login-icon {
    color: var(--accent-cyan);
}

.input-field {
    margin-bottom: 20px;
    position: relative;
}

/* PROFILE DROPDOWN */
.profile-wrapper {
    position: relative;
}

.profile-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 200px;
    background: rgba(15, 23, 42, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 16px;
    padding: 8px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 1000;
}

.profile-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.dropdown-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 13px;
    font-weight: 600;
    border-radius: 10px;
    transition: all 0.2s;
}

.dropdown-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: white;
}

.dropdown-link.logout {
    color: #ff4b5c !important;
}

.dropdown-link.logout:hover {
    background: rgba(255, 75, 92, 0.1) !important;
}

.dropdown-link i {
    width: 20px;
    text-align: center;
    color: var(--accent-cyan);
}

/* PHOTO PAGE RESPONSIVENESS */
.photo-container {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 40px;
    align-items: start;
}

.photo-side {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
}

.photo-divider {
    width: 1px;
    background: linear-gradient(to bottom, transparent, var(--glass-border), transparent);
    height: 100%;
    min-height: 200px;
}

@media (max-width: 768px) {
    .photo-container {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    .photo-divider {
        width: 100%;
        height: 1px;
        min-height: 1px;
        background: linear-gradient(to right, transparent, var(--glass-border), transparent);
    }
}

.dropdown-link.logout:hover {
    background: rgba(255, 75, 92, 0.1);
}

.forgot-link {
    color: var(--accent-cyan);
    text-decoration: none;
    font-size: 11px;
    font-weight: 600;
    transition: all 0.2s;
    opacity: 0.8;
}

.forgot-link:hover {
    opacity: 1;
    text-decoration: underline;
}

.input-field {
    margin-bottom: 20px;
}


/* MOBILE RESPONSIVE TWEAKS */
@media (max-width: 768px) {
    .header {
        padding: 0 16px;
    }
    
    .company-badge span {
        font-size: 13px;
        max-width: 140px;
        line-height: 1.1;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .header-right {
        gap: 12px;
    }

    .profile-section .user-name {
        display: none;
    }

    .profile-section {
        padding: 4px;
        background: transparent;
        border: none;
    }

    .alert-glass {
        flex-direction: column;
        text-align: center;
        align-items: center;
        padding: 24px;
        gap: 16px;
    }

    .alert-content i {
        font-size: 42px;
        margin-bottom: 8px;
    }

    .alert-content strong {
        font-size: 18px;
    }

    .alert-action {
        width: 100%;
        text-align: center;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
}

/* PWA INSTALL BANNER */
.pwa-banner {
    position: fixed;
    bottom: -100px;
    left: 20px;
    right: 20px;
    background: rgba(15, 23, 42, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    padding: 16px;
    display: flex;
    align-items: center;
    gap: 16px;
    z-index: 10000;
    transition: all 0.5s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

@media (min-width: 1024px) {
    .pwa-banner {
        display: none !important;
    }
}

.pwa-banner.show {
    bottom: 20px;
}

.pwa-icon {
    width: 48px;
    height: 48px;
    background: var(--accent-cyan);
    color: #0f172a;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    flex-shrink: 0;
}

.pwa-info {
    flex-grow: 1;
}

.pwa-title {
    color: white;
    font-size: 14px;
    font-weight: 700;
}

.pwa-desc {
    color: var(--text-secondary);
    font-size: 12px;
}

.pwa-close {
    color: var(--text-secondary);
    background: none;
    border: none;
    padding: 8px;
    cursor: pointer;
}

.pwa-install-btn {
    background: var(--accent-cyan);
    color: #0f172a;
    border: none;
    padding: 8px 16px;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
}

/* PLAN SELECTION GRID in SUPPORT */
.plan-selection-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 12px;
    width: 100%;
}

.plan-option {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 10px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    text-align: center;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 4px;
}

.plan-option:hover {
    background: rgba(1, 228, 193, 0.05);
    border-color: rgba(1, 228, 193, 0.2);
    transform: translateY(-2px);
}

.plan-option.active {
    background: rgba(1, 228, 193, 0.1);
    border-color: var(--accent-cyan);
    box-shadow: 0 0 15px rgba(1, 228, 193, 0.2);
}

.plan-option.active::after {
    content: '\f058';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    position: absolute;
    top: 8px;
    right: 8px;
    color: var(--accent-cyan);
    font-size: 14px;
}

.plan-label {
    display: block;
    font-size: 13px;
    font-weight: 800;
    color: white;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.plan-price {
    display: block;
    font-size: 14px;
    color: var(--accent-cyan);
    font-weight: 800;
}

.plan-sub {
    font-size: 10px;
    color: var(--text-secondary);
    font-weight: 400;
}

@media (max-width: 640px) {
    .plan-selection-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    /* Ajuste para 6 itens na barra inferior */
    .bottom-nav {
        gap: 0;
        padding: 0 4px;
    }
    .bottom-nav-item {
        min-width: 0;
        flex: 1;
        padding: 8px 2px;
    }
    .bottom-nav-item span {
        font-size: 9px;
        letter-spacing: -0.5px;
        white-space: nowrap;
    }
    .bottom-nav-item i {
        font-size: 16px;
    }
}

/* ==========================================================================
   APPENDIX: PREMIUM INVOICE & COMPACT ELEMENTS (PRIORITY)
   ========================================================================== */

/* --- INVOICE CARDS REFACTOR (PRIORITY BALANCED) --- */
.invoice-main-info {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 8px;
}

.invoice-icon {
    width: 56px;
    height: 56px;
    background: rgba(1, 228, 193, 0.1);
    border: 1px solid rgba(1, 228, 193, 0.2);
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-cyan);
    font-size: 24px;
    flex-shrink: 0;
}

.invoice-amount {
    font-size: 24px;
    font-weight: 800;
    color: var(--accent-cyan); /* Cor de destaque para o valor */
    letter-spacing: -0.5px;
}

.invoice-date {
    display: flex;
    align-items: center;
    gap: 8px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 14px;
    font-weight: 500;
    margin-left: 2px;
}

.invoice-date i {
    color: var(--accent-cyan);
    font-size: 14px;
}

.payment-group {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 0;
}

.pay-btn {
    width: 180px;
    height: 48px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    font-weight: 800;
    font-size: 13px;
    text-transform: uppercase;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.pay-btn-boleto {
    background: var(--accent-cyan) !important;
    color: #0d121f !important;
    box-shadow: 0 4px 15px rgba(1, 228, 193, 0.2);
}

/* Prevenir o override do browser em links visitados/ativos */
.pay-btn-boleto:visited,
.pay-btn-boleto:active {
    background: var(--accent-cyan) !important;
    color: #0d121f !important;
    text-decoration: none !important;
}

.pay-btn-boleto:hover {
    background: #ffffff !important;
    color: #0d121f !important;
    transform: translateY(-2px) !important;
}

.pay-btn-card {
    background: rgba(255, 255, 255, 0.05);
    color: #fff;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

.pay-btn-card:visited,
.pay-btn-card:active {
    background: rgba(255, 255, 255, 0.05) !important;
    color: #fff !important;
    text-decoration: none !important;
}

/* Pix COMPACT OVERRIDE - FORÇANDO ESTILO DE BOTÃO */
.pix-wrapper-compact, .pix-wrapper-compact form { 
    display: inline-flex !important; 
    margin: 0 !important; 
}

.pix-wrapper-compact input[type="submit"], 
.pix-wrapper-compact button, 
.pix-wrapper-compact .btn_pix,
.pix-wrapper-compact a {
    width: 180px !important; /* Mesma largura do boleto */
    height: 48px !important;
    margin: 0 !important;
    padding: 0 24px !important;
    border-radius: 14px !important;
    background: #313664 !important; /* Cor da Paleta Original */
    border: 1px solid rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    font-size: 13px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 12px !important;
    cursor: pointer !important;
    text-transform: uppercase !important;
    text-decoration: none !important;
    transition: all 0.3s ease !important;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2) !important;
}

/* Adicionando texto "PIX" já que o elemento a só vem com o ícone default */
.pix-wrapper-compact a::after {
    content: "PIX";
}

.pix-wrapper-compact input[type="submit"]:hover, 
.pix-wrapper-compact button:hover,
.pix-wrapper-compact .btn_pix:hover,
.pix-wrapper-compact a:hover {
    background: #04CBBE !important; /* Cor Teal da Paleta */
    border-color: #04CBBE !important;
    color: #0E131F !important;
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 20px rgba(4, 203, 190, 0.4) !important;
}

/* MOBILE REFINEMENT — INVOICE CARDS */
@media (max-width: 768px) {

    /* Override the generic data-table td layout for invoice cells */
    .data-table td[data-label="FATURA"],
    .data-table td[data-label="VENCIMENTO"],
    .data-table td[data-label="PAGAMENTO"] {
        display: block !important;        /* Empilha verticalmente */
        justify-content: unset !important;
        text-align: left !important;
        padding: 6px 0 !important;
    }

    /* Remove os rótulos flutuantes gerados pelo ::before */
    .data-table td[data-label="FATURA"]::before,
    .data-table td[data-label="VENCIMENTO"]::before,
    .data-table td[data-label="PAGAMENTO"]::before {
        display: none !important;
        content: "" !important;
    }

    /* Espaçamento do card e separador de botões */
    .data-table tr {
        padding: 24px !important;
    }

    /* Ícone + valor lado a lado, não empilhados */
    .invoice-main-info {
        flex-direction: row !important;
        align-items: center !important;
        text-align: left !important;
        gap: 16px !important;
        width: 100% !important;
    }

    /* Valor em destaque — ciano e grande */
    .invoice-amount {
        font-size: 26px !important;
        line-height: 1.2 !important;
    }

    /* Label "Valor do Título" fica pequeno acima */
    .invoice-label {
        font-size: 10px !important;
        display: block !important;
    }

    /* Data alinhada à esquerda */
    .invoice-date {
        justify-content: flex-start !important;
        margin: 8px 0 0 0 !important;
        font-size: 14px !important;
    }

    /* Botões empilhados e largura total */
    .payment-group {
        display: flex !important;
        flex-direction: column !important;
        gap: 10px !important;
        margin-top: 20px !important;
        padding-top: 20px !important;
        border-top: 1px solid rgba(255,255,255,0.06) !important;
        width: 100% !important;
    }

    .pay-btn {
        width: 100% !important;
        height: 52px !important;
        font-size: 14px !important;
    }

    .pix-wrapper-compact,
    .pix-wrapper-compact a,
    .pix-wrapper-compact input,
    .pix-wrapper-compact button {
        width: 100% !important;
        height: 52px !important;
        font-size: 14px !important;
    }
}
