/* ============================================
   NAVBAR SUPERIOR MODERNO - ESTILO MICROSOFT
   Design Profissional e Clean
   ============================================ */

.top-navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1002;
    background: rgba(0, 0, 0, 0.98);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.5);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    height: 64px;
}

/* ============================================
   TEMA LIGHT — NAVBAR
   ============================================ */
[data-theme="light"] .top-navbar {
    background: rgba(255, 255, 255, 0.97);
    border-bottom-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .top-navbar.scrolled {
    border-bottom-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1), 0 1px 0 rgba(99, 102, 241, 0.1) inset;
}

[data-theme="light"] .navbar-item {
    color: rgba(15, 23, 42, 0.75);
}

[data-theme="light"] .navbar-item:hover {
    color: #0f172a;
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .navbar-item.active {
    color: #6366f1;
    background: rgba(99, 102, 241, 0.08);
}

[data-theme="light"] .user-profile {
    background: rgba(0, 0, 0, 0.04);
    border-color: rgba(0, 0, 0, 0.1);
    color: #0f172a;
}

[data-theme="light"] .user-profile:hover {
    background: rgba(99, 102, 241, 0.08);
    border-color: rgba(99, 102, 241, 0.3);
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.1);
}

[data-theme="light"] .user-name { color: #0f172a; }
[data-theme="light"] .user-role { color: rgba(15, 23, 42, 0.5); }
[data-theme="light"] #navbar-userrole[data-plan="free"] { color: rgba(15, 23, 42, 0.4); }

[data-theme="light"] .dropdown-menu {
    background: rgba(255, 255, 255, 0.98);
    border-color: rgba(0, 0, 0, 0.08);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.12);
}

[data-theme="light"] .dropdown-item {
    color: rgba(15, 23, 42, 0.8);
}

[data-theme="light"] .dropdown-item:hover {
    background: rgba(0, 0, 0, 0.04);
    color: #0f172a;
}

[data-theme="light"] .dropdown-divider {
    background: rgba(0, 0, 0, 0.06);
}

[data-theme="light"] .dropdown-item.text-red { color: #dc2626; }
[data-theme="light"] .dropdown-item.text-red:hover {
    background: rgba(220, 38, 38, 0.06);
    color: #b91c1c;
}

[data-theme="light"] .navbar-mobile-toggle { color: rgba(15, 23, 42, 0.75); }
[data-theme="light"] .navbar-mobile-toggle:hover {
    background: rgba(0, 0, 0, 0.06);
    color: #0f172a;
}

/* Logo e marca — pílula escura para contrastar logo branca no fundo claro */
[data-theme="light"] .navbar-brand {
    background: rgba(8, 8, 20, 0.88);
    border-radius: 10px;
    padding: 5px 12px;
    border: 1px solid rgba(99, 102, 241, 0.2);
    color: #ffffff;
}

[data-theme="light"] .navbar-brand:hover {
    background: rgba(8, 8, 20, 0.95);
    border-color: rgba(99, 102, 241, 0.4);
    opacity: 1;
}

[data-theme="light"] .navbar-title {
    color: #ffffff;
}

/* ============================================
   BOTÃO DE TOGGLE DE TEMA
   ============================================ */
.theme-toggle-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    background: rgba(255, 255, 255, 0.06);
    color: rgba(255, 255, 255, 0.7);
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
    margin-right: 8px;
    position: relative;
    overflow: hidden;
}

.theme-toggle-btn:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    transform: rotate(15deg);
}

.theme-toggle-btn svg {
    width: 18px;
    height: 18px;
    position: absolute;
    transition: opacity 0.2s ease, transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.theme-toggle-btn .icon-sun {
    opacity: 0;
    transform: scale(0.7) rotate(-30deg);
}

.theme-toggle-btn .icon-moon {
    opacity: 1;
    transform: scale(1) rotate(0deg);
}

/* Quando está no tema light, mostrar ícone de lua (para voltar ao dark) */
[data-theme="light"] .theme-toggle-btn .icon-sun {
    opacity: 1;
    transform: scale(1) rotate(0deg);
}

[data-theme="light"] .theme-toggle-btn .icon-moon {
    opacity: 0;
    transform: scale(0.7) rotate(30deg);
}

[data-theme="light"] .theme-toggle-btn {
    border-color: rgba(0, 0, 0, 0.1);
    background: rgba(0, 0, 0, 0.04);
    color: rgba(15, 23, 42, 0.6);
}

[data-theme="light"] .theme-toggle-btn:hover {
    background: rgba(99, 102, 241, 0.08);
    border-color: rgba(99, 102, 241, 0.3);
    color: #6366f1;
    transform: rotate(15deg);
}

/* ============================================
   DRAWER MOBILE — TEMA LIGHT
   ============================================ */
[data-theme="light"] .navbar-menu {
    background: rgba(240, 244, 248, 0.99);
    border-right-color: rgba(0, 0, 0, 0.08);
}

[data-theme="light"] .navbar-mobile-overlay {
    background: rgba(0, 0, 0, 0.3);
}

[data-theme="light"] .mobile-profile-entry {
    background: linear-gradient(180deg, rgba(255,255,255,0.7), rgba(255,255,255,0.5));
    border-color: rgba(0, 0, 0, 0.06);
}

.top-navbar.scrolled {
    border-bottom-color: rgba(96, 165, 250, 0.18);
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.6), 0 1px 0 rgba(96, 165, 250, 0.1) inset;
}

.navbar-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 24px;
    max-width: 100%;
    height: 100%;
    margin: 0 auto;
}

/* ============================================
   LOGO E MARCA - ESTILO MICROSOFT
   ============================================ */
.navbar-brand {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: #ffffff;
    cursor: pointer;
    transition: opacity 0.2s ease;
}

.navbar-brand:hover {
    opacity: 0.9;
}

.navbar-logo {
    height: 48px;
    width: auto;
    object-fit: contain;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.navbar-brand:hover .navbar-logo {
    transform: scale(1.05);
}

.navbar-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: #ffffff;
    letter-spacing: -0.015em;
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ============================================
   MENU PRINCIPAL - ESTILO MICROSOFT
   ============================================ */
.navbar-menu {
    display: flex;
    align-items: center;
    gap: 4px;
}

.navbar-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 16px;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 0.875rem;
    font-weight: 500;
    border-radius: 4px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    border: none;
    background: transparent;
    cursor: pointer;
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
}

.navbar-item:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

.navbar-item.active {
    color: #60a5fa;
    background: rgba(96, 165, 250, 0.1);
}

.navbar-item.active::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 16px;
    right: 16px;
    height: 2px;
    background: linear-gradient(90deg, transparent, #60a5fa 30%, #93c5fd 70%, transparent);
    border-radius: 2px 2px 0 0;
    box-shadow: 0 0 10px rgba(96, 165, 250, 0.6);
}

.navbar-item svg {
    width: 16px;
    height: 16px;
    opacity: 0.9;
}

/* ============================================
   DROPDOWNS - ESTILO MICROSOFT
   ============================================ */
.navbar-dropdown {
    position: relative;
}

.dropdown-trigger {
    background: none;
    border: none;
    cursor: pointer;
    pointer-events: auto;
    z-index: 1;
    position: relative;
}

.dropdown-arrow {
    width: 16px;
    height: 16px;
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0.7;
    pointer-events: none; /* Não bloquear clique, passar para o botão pai */
}

.navbar-dropdown:hover .dropdown-arrow {
    transform: rotate(180deg);
}

/* Área invisível que conecta o botão ao menu para manter hover ativo */
.navbar-dropdown::before {
    content: '';
    position: absolute;
    top: 100%;
    left: -10px;
    right: -10px;
    height: 30px;
    z-index: 1000;
}

.dropdown-menu {
    position: absolute;
    top: calc(100% + 8px);
    left: -10px;
    min-width: 240px;
    background: rgba(0, 0, 0, 0.98);
    backdrop-filter: blur(30px);
    -webkit-backdrop-filter: blur(30px);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px);
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1001;
    padding: 8px;
    pointer-events: none;
}

.dropdown-menu-right {
    left: auto;
    right: -10px;
}

/* Manter dropdown aberto quando mouse está sobre ele */
.navbar-dropdown:hover .dropdown-menu,
.dropdown-menu:hover {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}



.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    color: rgba(255, 255, 255, 0.85);
    text-decoration: none;
    font-size: 0.875rem;
    border-radius: 4px;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    position: relative;
    overflow: hidden;
}

.dropdown-item:hover {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.08);
}

/* Barra vertical de destaque no hover */
.dropdown-item::before {
    content: '';
    position: absolute;
    left: 0;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: #60a5fa;
    border-radius: 0 2px 2px 0;
    transform: scaleY(0);
    transform-origin: center;
    transition: transform 0.15s cubic-bezier(0.4, 0, 0.2, 1);
}
.dropdown-item:hover::before,
.dropdown-item.active::before {
    transform: scaleY(1);
}
.dropdown-item.active {
    color: #93c5fd;
    background: rgba(96, 165, 250, 0.08);
}
.dropdown-item.text-red::before { background: #ef4444; }

.dropdown-item svg {
    width: 16px;
    height: 16px;
    opacity: 0.8;
}

.dropdown-item.text-red {
    color: #f87171;
}

.dropdown-item.text-red:hover {
    color: #ffffff;
    background: rgba(239, 68, 68, 0.1);
}

.dropdown-divider {
    height: 1px;
    background: rgba(255, 255, 255, 0.08);
    margin: 8px 0;
}

/* ============================================
   MENU DO USUÁRIO - ESTILO MICROSOFT
   ============================================ */
.navbar-user {
    margin-left: 0;
    display: flex;
    align-items: center;
}

/* Agrupa sino + usuário à direita */
.navbar-right {
    margin-left: auto;
    display: flex;
    align-items: center;
    gap: 8px;
}

.user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 12px 6px 6px;
    background: rgba(255, 255, 255, 0.06);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 32px;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    color: #ffffff;
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
}

.user-profile:hover {
    background: rgba(96, 165, 250, 0.12);
    border-color: rgba(96, 165, 250, 0.35);
    box-shadow: 0 2px 8px rgba(96, 165, 250, 0.15);
}

/* Wrapper do avatar — permite o status dot "vazar" acima do overflow:hidden */
.user-avatar-wrapper {
    position: relative;
    flex-shrink: 0;
    width: 40px;
    height: 40px;
}

.user-avatar {
    width: 40px;
    height: 40px;
    min-width: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0078d4 0%, #60a5fa 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    box-shadow: 0 2px 8px rgba(0, 120, 212, 0.4);
    flex-shrink: 0;
    position: relative;
    overflow: hidden;
}

.user-avatar svg {
    width: 20px;
    height: 20px;
    stroke-width: 2;
}

/* Iniciais do usuário dentro do avatar */
.user-initials {
    font-size: 14px;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: #ffffff;
    user-select: none;
    line-height: 1;
    text-transform: uppercase;
}

/* Indicador de sessão ativa */
.user-status-dot {
    position: absolute;
    bottom: 0;
    right: 0;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: #22c55e;
    border: 2px solid #000000;
    z-index: 2;
    animation: vex-status-pulse 2.8s ease-in-out infinite;
}

@keyframes vex-status-pulse {
    0%, 100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.5); }
    50%       { box-shadow: 0 0 0 4px rgba(34, 197, 94, 0); }
}

/* Cor do badge de plano */
#navbar-userrole[data-plan="free"]         { color: rgba(255, 255, 255, 0.50); }
#navbar-userrole[data-plan="professional"] { color: #60a5fa; }
#navbar-userrole[data-plan="business"]     { color: #f59e0b; }
#navbar-userrole[data-plan="admin"]        { color: #f87171; }

.user-info {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 0;
    min-width: 80px;
}

.user-name {
    font-size: 14px;
    font-weight: 600;
    color: #ffffff;
    line-height: 1.4;
    white-space: nowrap;
}

.user-role {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.6);
    line-height: 1.3;
    white-space: nowrap;
}

.dropdown-arrow-user {
    width: 16px;
    height: 16px;
    transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0.7;
    margin-left: 4px;
}

.navbar-dropdown:hover .dropdown-arrow-user {
    transform: rotate(180deg);
    opacity: 1;
}

/* ============================================
   MOBILE MENU
   ============================================ */

/* Botão hambúrguer — oculto no desktop, visível no mobile */
.navbar-mobile-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.85);
    cursor: pointer;
    border-radius: 4px;
    transition: background 0.2s ease, color 0.2s ease;
}

.navbar-mobile-toggle:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #ffffff;
}

.navbar-mobile-toggle svg {
    width: 20px;
    height: 20px;
}

/* Overlay escuro ao abrir o drawer */
.navbar-mobile-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.55);
    z-index: 1001;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.navbar-mobile-overlay.active {
    opacity: 1;
    visibility: visible;
}

/* ============================================
   ESPAÇAMENTO DO CONTEÚDO
   ============================================ */
.top-navbar {
    height: 64px;
}

.main-content {
    padding-top: 64px;
    min-height: calc(100vh - 64px);
}

.page-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 24px;
}

/* ============================================
   RESPONSIVE — TABLET (max-width: 1024px)
   ============================================ */
@media (max-width: 1024px) {
    .navbar-container {
        padding: 0 20px;
    }
}

/* ============================================
    RESPONSIVE — COMPACT NAVBAR (max-width: 1437px)
    Quando a largura cair até ~1437px, o navbar entra em modo "hamburger"
    para evitar cortes do menu principal em larguras médias.
    ============================================ */
@media (max-width: 1437px) {

    /* --- Container --- */
    .navbar-container {
        padding: 0 16px;
    }

    .navbar-logo {
        height: 40px;
        width: auto;
    }

    .navbar-title {
        font-size: 20px;
    }

    /* --- Mostrar botão hambúrguer --- */
    .navbar-mobile-toggle {
        display: flex;
    }

    /* --- Drawer: slide pela esquerda, fechado por padrão --- */
    .navbar-menu {
        position: fixed;
        top: 0;
        left: 0;
        height: 100vh;
        width: 300px;
        max-width: 85vw;
        background: #0c1020;
        border-right: 1px solid rgba(255, 255, 255, 0.07);
        flex-direction: column;
        align-items: stretch;
        gap: 2px;
        padding: 4.5rem 1rem 1.5rem;
        transform: translateX(-100%);
        transition: transform 0.28s cubic-bezier(0.2, 0.8, 0.2, 1);
        z-index: 1002;
        box-shadow: 6px 0 32px rgba(0, 0, 0, 0.55);
        overflow-y: auto;
        display: flex;
    }

    /* Drawer aberto pelo JS via .active */
    .navbar-menu.active {
        transform: translateX(0);
    }

    /* --- Itens do menu --- */
    .navbar-item {
        width: 100%;
        justify-content: flex-start;
        padding: 12px 16px;
        border-radius: 8px;
        margin-bottom: 2px;
    }

    .navbar-item:hover {
        background: rgba(96, 165, 250, 0.1);
    }

    /* --- Dropdowns dentro do drawer — estáticos --- */
    .navbar-dropdown {
        width: 100%;
    }

    .dropdown-menu {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        background: rgba(255, 255, 255, 0.04);
        border: none;
        border-left: 3px solid #60a5fa;
        border-radius: 6px;
        box-shadow: none;
        margin: 4px 0 8px 8px;
        padding: 4px 0;
        max-height: 0;
        overflow: hidden;
        pointer-events: none;
        transition: max-height 0.3s ease;
    }

    /* Dropdown aberto: controlado exclusivamente pelo JS via classe .open */
    .navbar-dropdown.open > .dropdown-menu {
        max-height: 400px;
        pointer-events: auto;
    }

    /* Seta gira apenas quando o dropdown está aberto — desabilitar hover no drawer */
    .navbar-dropdown .dropdown-arrow,
    .navbar-dropdown:hover .dropdown-arrow {
        transform: rotate(0deg);
    }
    .navbar-dropdown.open > .dropdown-trigger .dropdown-arrow {
        transform: rotate(180deg) !important;
    }

    .dropdown-item {
        padding: 10px 16px;
        border-radius: 4px;
    }

    /* --- Ocultar botão de perfil desktop no modo hamburger ---
       O perfil aparece no rodapé do drawer via .mobile-profile-entry (criado pelo JS) */
    .navbar-user {
        display: none !important;
    }

    /* --- Sino de notificações: sempre visível no mobile (fora de .navbar-user) --- */
    .nav-bell-wrap {
        display: flex;
        align-items: center;
        margin-left: auto;
        margin-right: 4px;
    }

    /* --- Dropdown de notificações: position fixed no mobile para aparecer acima de tudo --- */
    .nav-bell-dropdown.open {
        position: fixed;
        top: 64px;
        right: 12px;
        left: 12px;
        width: auto;
        max-width: 400px;
        margin: 0 auto;
    }

    /* --- Bloco de perfil clonado pelo JS dentro do drawer --- */
    .mobile-navbar-user {
        order: -1;
        margin-top: 0;
        margin-bottom: 1rem;
        align-self: stretch;
    }

    .mobile-navbar-user .user-profile {
        display: flex;
        align-items: center;
        gap: 12px;
        width: 100%;
        padding: 10px 12px;
        border-radius: 10px;
        background: rgba(255, 255, 255, 0.04);
        border: 1px solid rgba(255, 255, 255, 0.06);
    }

    .mobile-navbar-user .user-info {
        display: flex;
        flex-direction: column;
        align-items: flex-start;
        gap: 2px;
    }

    .mobile-navbar-user .user-name {
        color: #dbeafe;
        font-weight: 700;
        font-size: 0.96rem;
    }

    .mobile-navbar-user .user-role {
        color: rgba(219, 234, 254, 0.75);
        font-size: 0.82rem;
    }

    .mobile-navbar-user .user-avatar {
        width: 44px;
        height: 44px;
        min-width: 44px;
    }

    .mobile-navbar-user .dropdown-arrow-user {
        display: none;
    }

    /* --- Entrada de perfil fallback (.mobile-profile-entry) --- */
    .mobile-profile-entry {
        display: flex;
        align-items: center;
        gap: 12px;
        padding: 12px 14px;
        border-radius: 12px;
        background: linear-gradient(180deg, rgba(255,255,255,0.03), rgba(255,255,255,0.01));
        border: 1px solid rgba(255, 255, 255, 0.05);
        box-shadow: 0 6px 18px rgba(2, 6, 23, 0.55);
        transition: transform 0.14s ease, box-shadow 0.14s ease, background 0.14s ease;
        width: 100%;
        margin-bottom: 0.75rem;
    }

    .mobile-profile-entry:hover,
    .mobile-profile-entry:focus-within {
        transform: translateY(-2px);
        box-shadow: 0 10px 28px rgba(2, 6, 23, 0.65);
        background: linear-gradient(180deg, rgba(255,255,255,0.04), rgba(255,255,255,0.02));
        outline: none;
    }

    .mobile-profile-entry .mobile-profile-link {
        display: flex;
        align-items: center;
        gap: 12px;
        color: #cfe8ff;
        text-decoration: none;
        width: 100%;
    }

    .mobile-profile-entry .user-avatar {
        width: 46px;
        height: 46px;
        min-width: 46px;
        border-radius: 50%;
        background: linear-gradient(135deg, #0ea5a8 0%, #3b82f6 100%);
        display: flex;
        align-items: center;
        justify-content: center;
        box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
    }

    .mobile-profile-entry .mobile-profile-name {
        font-weight: 700;
        color: #dbeafe;
        font-size: 0.96rem;
        line-height: 1.1;
    }

    .mobile-profile-entry .mobile-profile-sub {
        display: block;
        font-size: 0.8rem;
        color: rgba(219, 234, 254, 0.75);
        margin-top: 2px;
    }

    .page-container {
        padding: 1.5rem 1rem;
    }
}

/* ============================================
   RESPONSIVE — SMALL PHONES (max-width: 480px)
   ============================================ */
@media (max-width: 480px) {
    .top-navbar {
        height: 56px;
    }

    .main-content {
        padding-top: 56px;
    }

    .navbar-menu {
        padding-top: 4.5rem;
    }

    .navbar-user {
        margin-left: 6px;
    }

    .nav-bell-dropdown.open {
        top: 56px;
    }
}

/* Keyframe usado internamente (não conflita com drawer) */
@keyframes slideDown {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ============================================
   SEPARADORES VERTICAIS
   ============================================ */
.navbar-vsep {
    width: 1px;
    height: 28px;
    background: rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
    margin: 0 8px;
}

.navbar-vsep-sm {
    width: 1px;
    height: 24px;
    background: rgba(255, 255, 255, 0.1);
    flex-shrink: 0;
    margin: 0 8px;
}

/* ============================================
   INDICADOR DE STATUS PQC
   ============================================ */
.nav-pqc-status {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 20px;
    background: rgba(34, 197, 94, 0.08);
    border: 1px solid rgba(34, 197, 94, 0.2);
    cursor: default;
    flex-shrink: 0;
    transition: opacity 0.2s ease;
}

.nav-pqc-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #22c55e;
    flex-shrink: 0;
    animation: vex-status-pulse 2.8s ease-in-out infinite;
}

.nav-pqc-label {
    font-size: 0.7rem;
    font-weight: 700;
    color: #22c55e;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
}

/* ============================================
   SINO DE NOTIFICAÇÕES
   ============================================ */
.nav-bell-wrap {
    position: relative;
    flex-shrink: 0;
}

.nav-bell-btn {
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    background: transparent;
    border: 1px solid rgba(255,255,255,.07);
    color: rgba(255,255,255,.55);
    cursor: pointer;
    transition: background .15s, color .15s, border-color .15s;
    padding: 0;
}

.nav-bell-btn:hover {
    background: rgba(99,102,241,.1);
    border-color: rgba(99,102,241,.3);
    color: #a5b4fc;
}

.nav-bell-badge {
    position: absolute;
    top: -5px;
    right: -5px;
    min-width: 16px;
    height: 16px;
    border-radius: 99px;
    background: #ef4444;
    color: #fff;
    font-size: .62rem;
    font-weight: 700;
    line-height: 16px;
    text-align: center;
    padding: 0 4px;
    border: 2px solid #000;
    pointer-events: none;
    font-family: 'Space Grotesk', system-ui, sans-serif;
}

/* Dropdown de notificações */
.nav-bell-dropdown {
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    width: 340px;
    max-height: 440px;
    background: #111113;
    border: 1px solid #27272a;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0,0,0,.8), 0 0 0 1px rgba(99,102,241,.05);
    display: none;
    flex-direction: column;
    overflow: hidden;
    z-index: 9999;
    animation: bellDropIn .18s cubic-bezier(.34,1.56,.64,1);
}

.nav-bell-dropdown.open {
    display: flex;
}

@keyframes bellDropIn {
    from { opacity:0; transform:translateY(-8px) scale(.96); }
    to   { opacity:1; transform:translateY(0) scale(1); }
}

.nav-bell-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px 10px;
    border-bottom: 1px solid #27272a;
    flex-shrink: 0;
}

.nav-bell-title {
    font-size: .85rem;
    font-weight: 600;
    color: #f4f4f5;
    font-family: 'Space Grotesk', system-ui, sans-serif;
}

.nav-bell-readall {
    background: none;
    border: none;
    color: #6366f1;
    font-size: .72rem;
    font-weight: 600;
    cursor: pointer;
    padding: 0;
    transition: color .15s;
}

.nav-bell-readall:hover { color: #a5b4fc; }

.nav-bell-list {
    overflow-y: auto;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: #27272a transparent;
}

.nav-bell-empty {
    padding: 32px 16px;
    text-align: center;
    font-size: .82rem;
    color: #52525b;
    font-family: 'Space Grotesk', system-ui, sans-serif;
}

.nav-bell-item {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 12px 16px;
    border-bottom: 1px solid rgba(255,255,255,.04);
    cursor: pointer;
    transition: background .12s;
    text-decoration: none;
}

.nav-bell-item:hover { background: rgba(255,255,255,.03); }

.nav-bell-item.unread { background: rgba(99,102,241,.05); }

.nav-bell-dot {
    flex-shrink: 0;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #6366f1;
    margin-top: 5px;
}

.nav-bell-item.read .nav-bell-dot { background: transparent; border: 1px solid #3f3f46; }

.nav-bell-content { flex: 1; min-width: 0; }

.nav-bell-ntitle {
    font-size: .82rem;
    font-weight: 600;
    color: #e4e4e7;
    margin: 0 0 3px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: 'Space Grotesk', system-ui, sans-serif;
}

.nav-bell-nmsg {
    font-size: .75rem;
    color: #71717a;
    margin: 0 0 4px;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    font-family: system-ui, sans-serif;
}

.nav-bell-ndate {
    font-size: .65rem;
    color: #3f3f46;
}

[data-theme="light"] .nav-bell-btn {
    border-color: rgba(0,0,0,.1);
    color: rgba(0,0,0,.5);
}
[data-theme="light"] .nav-bell-btn:hover {
    background: rgba(99,102,241,.08);
    border-color: rgba(99,102,241,.2);
    color: #6366f1;
}
[data-theme="light"] .nav-bell-dropdown {
    background: #fff;
    border-color: #e5e7eb;
    box-shadow: 0 12px 40px rgba(0,0,0,.15);
}
[data-theme="light"] .nav-bell-header { border-bottom-color: #f3f4f6; }
[data-theme="light"] .nav-bell-title { color: #111827; }
[data-theme="light"] .nav-bell-ntitle { color: #374151; }
[data-theme="light"] .nav-bell-nmsg { color: #6b7280; }
[data-theme="light"] .nav-bell-item.unread { background: rgba(99,102,241,.04); }
[data-theme="light"] .nav-bell-item { border-bottom-color: rgba(0,0,0,.04); }
[data-theme="light"] .nav-bell-badge { border-color: #fff; }

/* ============================================
   CABEÇALHOS DE SEÇÃO NOS DROPDOWNS
   ============================================ */
.dropdown-section-header {
    font-size: 0.675rem;
    font-weight: 700;
    color: rgba(255, 255, 255, 0.3);
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 8px 12px 4px;
    margin-top: 2px;
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    pointer-events: none;
    user-select: none;
}

.dropdown-section-header:first-child {
    margin-top: 0;
}

/* ============================================
   CABEÇALHO RICO DO DROPDOWN DO USUÁRIO
   ============================================ */
.dropdown-user-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 12px;
    background: rgba(255, 255, 255, 0.03);
    border-radius: 6px;
    margin-bottom: 2px;
    border: 1px solid rgba(255, 255, 255, 0.04);
}

.dropdown-user-avatar-sm {
    width: 36px;
    height: 36px;
    min-width: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
    font-weight: 700;
    color: #ffffff;
    flex-shrink: 0;
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.35);
}

.dropdown-user-meta {
    display: flex;
    flex-direction: column;
    gap: 3px;
    min-width: 0;
    flex: 1;
}

.dropdown-user-name-lg {
    font-size: 0.875rem;
    font-weight: 600;
    color: #ffffff;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    line-height: 1.2;
}

.dropdown-user-plan-badge {
    font-size: 0.675rem;
    font-weight: 700;
    padding: 2px 7px;
    border-radius: 10px;
    display: inline-flex;
    align-items: center;
    width: fit-content;
    background: rgba(255, 255, 255, 0.08);
    color: rgba(255, 255, 255, 0.45);
    letter-spacing: 0.04em;
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    text-transform: uppercase;
}

.dropdown-user-plan-badge[data-plan="professional"] {
    background: rgba(96, 165, 250, 0.15);
    color: #60a5fa;
}

.dropdown-user-plan-badge[data-plan="business"] {
    background: rgba(245, 158, 11, 0.15);
    color: #f59e0b;
}

.dropdown-user-plan-badge[data-plan="admin"] {
    background: rgba(248, 113, 113, 0.15);
    color: #f87171;
}

/* ============================================
   LIGHT MODE — NOVOS ELEMENTOS
   ============================================ */
[data-theme="light"] .navbar-vsep,
[data-theme="light"] .navbar-vsep-sm {
    background: rgba(0, 0, 0, 0.1);
}

[data-theme="light"] .nav-pqc-status {
    background: rgba(21, 128, 61, 0.06);
    border-color: rgba(21, 128, 61, 0.2);
}

[data-theme="light"] .nav-pqc-label {
    color: #15803d;
}

[data-theme="light"] .nav-pqc-dot {
    background: #16a34a;
}

[data-theme="light"] .dropdown-section-header {
    color: rgba(15, 23, 42, 0.35);
}

[data-theme="light"] .dropdown-user-header {
    background: rgba(0, 0, 0, 0.03);
    border-color: rgba(0, 0, 0, 0.05);
}

[data-theme="light"] .dropdown-user-name-lg {
    color: #0f172a;
}

[data-theme="light"] .dropdown-user-plan-badge {
    background: rgba(0, 0, 0, 0.06);
    color: rgba(15, 23, 42, 0.45);
}

[data-theme="light"] .dropdown-user-plan-badge[data-plan="professional"] {
    background: rgba(99, 102, 241, 0.1);
    color: #4f46e5;
}

[data-theme="light"] .dropdown-user-plan-badge[data-plan="business"] {
    background: rgba(217, 119, 6, 0.1);
    color: #b45309;
}

[data-theme="light"] .dropdown-user-plan-badge[data-plan="admin"] {
    background: rgba(220, 38, 38, 0.1);
    color: #dc2626;
}

/* ============================================
   MOBILE — OCULTAR ELEMENTOS ADICIONAIS
   ============================================ */
@media (max-width: 1437px) {
    .nav-pqc-status { display: none; }
    .navbar-vsep-sm { display: none; }
    .navbar-vsep    { display: none; }
}

/* ============================================
   MOBILE DRAWER — HEADER RICO
   ============================================ */
.mobile-drawer-header {
    padding: 0 0 0.75rem;
    border-bottom: 1px solid rgba(255,255,255,0.06);
    margin-bottom: 0.5rem;
    flex-shrink: 0;
}

.mobile-drawer-profile {
    margin-bottom: 8px;
}

.mobile-drawer-profile-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-radius: 12px;
    background: linear-gradient(135deg, rgba(20,184,166,0.08), rgba(20,184,166,0.03));
    border: 1px solid rgba(20,184,166,0.12);
    text-decoration: none;
    transition: background 0.2s ease, border-color 0.2s ease;
    cursor: pointer;
}

.mobile-drawer-profile-link:hover {
    background: linear-gradient(135deg, rgba(20,184,166,0.14), rgba(20,184,166,0.06));
    border-color: rgba(20,184,166,0.22);
}

.mobile-drawer-avatar {
    width: 48px;
    height: 48px;
    min-width: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #0ea5a8 0%, #3b82f6 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    box-shadow: 0 4px 14px rgba(14,165,168,0.28);
    flex-shrink: 0;
}

.mobile-drawer-initials {
    color: white;
    font-weight: 700;
    font-size: 1.05rem;
    font-family: 'Segoe UI', -apple-system, sans-serif;
}

.mobile-drawer-online {
    position: absolute;
    bottom: 1px;
    right: 1px;
    width: 11px;
    height: 11px;
    border-radius: 50%;
    background: #22c55e;
    border: 2.5px solid #0f1628;
    box-shadow: 0 0 6px rgba(34,197,94,0.5);
}

.mobile-drawer-info {
    flex: 1;
    min-width: 0;
}

.mobile-drawer-name {
    color: #e2e8f0;
    font-weight: 700;
    font-size: 0.95rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.2;
}

.mobile-drawer-plan {
    font-size: 0.73rem;
    margin-top: 3px;
    border-radius: 4px;
    display: inline-block;
    padding: 1px 6px;
    font-weight: 600;
    letter-spacing: 0.02em;
}

.mobile-drawer-plan[data-plan="free"]         { color: rgba(148,163,184,0.85); }
.mobile-drawer-plan[data-plan="professional"] { color: #818cf8; background: rgba(129,140,248,0.12); }
.mobile-drawer-plan[data-plan="business"]     { color: #34d399; background: rgba(52,211,153,0.12); }
.mobile-drawer-plan[data-plan="admin"]        { color: #fb923c; background: rgba(251,146,60,0.12); }
.mobile-drawer-plan[data-plan="enterprise"]   { color: #facc15; background: rgba(250,204,21,0.12); }

/* Quick action buttons */
.mobile-drawer-quick {
    display: flex;
    gap: 8px;
}

.mobile-drawer-quick-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 9px;
    border-radius: 10px;
    background: rgba(255,255,255,0.04);
    border: 1px solid rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.55);
    cursor: pointer;
    position: relative;
    transition: background 0.18s ease, color 0.18s ease, border-color 0.18s ease;
    text-decoration: none;
}

.mobile-drawer-quick-btn:hover,
.mobile-drawer-quick-btn:focus-visible {
    background: rgba(255,255,255,0.09);
    color: rgba(255,255,255,0.9);
    border-color: rgba(255,255,255,0.12);
    outline: none;
}

.mobile-notif-badge {
    position: absolute;
    top: 4px;
    right: 4px;
    min-width: 16px;
    height: 16px;
    border-radius: 8px;
    background: #ef4444;
    color: white;
    font-size: 0.6rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 3px;
    border: 1.5px solid #0f1628;
}

/* ============================================
   MOBILE DRAWER — FOOTER
   ============================================ */
.mobile-drawer-footer {
    padding: 0.75rem 0 0;
    border-top: 1px solid rgba(255,255,255,0.06);
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex-shrink: 0;
}

.mobile-drawer-footer-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 8px;
    color: rgba(255,255,255,0.6);
    font-size: 0.875rem;
    font-weight: 500;
    text-decoration: none;
    transition: background 0.15s ease, color 0.15s ease;
    background: none;
    border: none;
    cursor: pointer;
    width: 100%;
    text-align: left;
    font-family: inherit;
}

.mobile-drawer-footer-item:hover {
    background: rgba(255,255,255,0.06);
    color: rgba(255,255,255,0.9);
}

.mobile-drawer-logout {
    color: rgba(239,68,68,0.8);
}

.mobile-drawer-logout:hover {
    background: rgba(239,68,68,0.08);
    color: #f87171;
}

/* Light theme adjustments */
[data-theme="light"] .mobile-drawer-profile-link {
    background: linear-gradient(135deg, rgba(20,184,166,0.08), rgba(20,184,166,0.04));
    border-color: rgba(20,184,166,0.18);
}
[data-theme="light"] .mobile-drawer-quick-btn {
    background: rgba(0,0,0,0.04);
    border-color: rgba(0,0,0,0.08);
    color: rgba(15,23,42,0.6);
}
[data-theme="light"] .mobile-drawer-quick-btn:hover {
    background: rgba(0,0,0,0.07);
    color: #0f172a;
}
[data-theme="light"] .mobile-drawer-footer-item {
    color: rgba(15,23,42,0.65);
}
[data-theme="light"] .mobile-drawer-footer-item:hover {
    background: rgba(0,0,0,0.05);
    color: #0f172a;
}
[data-theme="light"] .mobile-drawer-header {
    border-bottom-color: rgba(0,0,0,0.08);
}
[data-theme="light"] .mobile-drawer-footer {
    border-top-color: rgba(0,0,0,0.08);
}
[data-theme="light"] .mobile-drawer-name { color: #0f172a; }
[data-theme="light"] .mobile-drawer-logout { color: rgba(220,38,38,0.85); }
[data-theme="light"] .mobile-drawer-logout:hover { background: rgba(220,38,38,0.07); color: #dc2626; }

