/**
 * TPA Help Desk - Estilos Customizados e Design System
 * Modern UI / UX com Bootstrap 5 & Inter Typography
 */

:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --primary-accent: #f08800;
    --dark-bg: #0f172a;
    --dark-surface: #1e293b;
    --sidebar-width: 260px;
    --topbar-height: 68px;
    --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body.app-body {
    font-family: var(--font-sans);
    background-color: #f8fafc;
    color: #334155;
    margin: 0;
    padding: 0;
    min-height: 100vh;
}

/* ========================================================
   BARRA FIXA SUPERIOR (TOP NAVBAR)
   ======================================================== */
.top-navbar {
    background-color: #334155;
    border-bottom: 1px solid #1e293b;
    height: var(--topbar-height);
    position: sticky;
    top: 0;
    z-index: 1030;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.12) !important;
}

.brand-icon-wrapper {
    width: 36px;
    height: 36px;
    min-width: 36px;
    min-height: 36px;
    background: #ffffff !important;
    border-radius: 50% !important;
    overflow: hidden !important;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    border: 2px solid rgba(255, 255, 255, 0.35);
    flex-shrink: 0;
    transition: all 0.2s ease;
}

.brand-icon-wrapper img {
    width: 22px;
    height: 22px;
    border-radius: 50%;
    object-fit: contain;
    display: block;
}

[data-bs-theme="light"] .brand-icon-wrapper {
    background: #ffffff !important;
    border: 2px solid #cbd5e1 !important;
    box-shadow: 0 2px 6px rgba(15, 23, 42, 0.12) !important;
}

[data-bs-theme="dark"] .brand-icon-wrapper {
    background: #ffffff !important;
    border: 2px solid rgba(255, 255, 255, 0.3) !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35) !important;
}

[data-nav-style="gray"] .brand-icon-wrapper,
[data-theme-setting="gray"] .brand-icon-wrapper {
    background: #ffffff !important;
    border: 2px solid rgba(255, 255, 255, 0.35) !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2) !important;
}

.brand-title {
    font-size: 1.25rem;
    letter-spacing: -0.02em;
    font-weight: 700;
    line-height: 1;
    display: inline-flex;
    align-items: center;
}

.brand-title .brand-prefix {
    /* Três primeiras letras: branco em fundo escuro */
    color: #ffffff;
    transition: color 0.2s ease;
}

.brand-title .brand-suffix {
    /* Restante da palavra: da mesma cor da logomarca */
    color: var(--primary-accent, #f08800);
}

/* Quando o fundo for claro, as três primeiras letras ficam pretas */
.top-navbar.navbar-light .brand-title .brand-prefix,
.top-navbar.bg-light .brand-title .brand-prefix,
.top-navbar.bg-white .brand-title .brand-prefix,
.top-navbar-light .brand-title .brand-prefix,
[data-bs-theme="light"] .top-navbar .brand-title .brand-prefix,
[data-theme="light"] .top-navbar .brand-title .brand-prefix,
.navbar-light .brand-title .brand-prefix,
.bg-light .brand-title .brand-prefix,
.bg-white .brand-title .brand-prefix {
    color: #000000;
}

/* Alto contraste na palavra 'TPA' (brand-prefix) nos temas Dark e Blue */
[data-bs-theme="dark"] .brand-title .brand-prefix,
[data-theme-setting="dark"] .brand-title .brand-prefix,
[data-theme-setting="blue"] .brand-title .brand-prefix,
[data-nav-style="blue"] .brand-title .brand-prefix,
[data-bs-theme="dark"] .top-navbar .brand-title .brand-prefix,
[data-theme-setting="dark"] .top-navbar .brand-title .brand-prefix,
[data-theme-setting="blue"] .top-navbar .brand-title .brand-prefix,
[data-nav-style="blue"] .top-navbar .brand-title .brand-prefix {
    color: #ffffff !important;
    font-weight: 800 !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6) !important;
    letter-spacing: 0.02em;
}

.text-primary-accent {
    color: var(--primary-accent) !important;
}

.company-badge-box {
    background: rgba(15, 23, 42, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 8px;
    padding: 6px 12px;
}

.company-name {
    font-size: 0.88rem;
    letter-spacing: -0.01em;
}

.company-header-badge {
    background: rgba(15, 23, 42, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff;
    user-select: none;
    transition: all 0.2s ease;
}

[data-bs-theme="light"] .top-navbar .company-header-badge {
    background: rgba(15, 23, 42, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

[data-bs-theme="dark"] .top-navbar .company-header-badge {
    background: rgba(15, 23, 42, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

[data-nav-style="gray"] .top-navbar .company-header-badge,
[data-theme-setting="gray"] .top-navbar .company-header-badge {
    background: rgba(15, 23, 42, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

/* Badge de Usuários Conectados */
.online-users-badge {
    background: rgba(15, 23, 42, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: #ffffff;
    height: 38px;
    transition: all 0.2s ease;
}

.online-users-badge:hover {
    background: rgba(15, 23, 42, 0.35);
    border-color: rgba(255, 255, 255, 0.2);
}

.pulse-indicator {
    width: 8px;
    height: 8px;
    background-color: #22c55e;
    border-radius: 50%;
    display: inline-block;
    box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    animation: pulse-green 2s infinite;
}

@keyframes pulse-green {
    0% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
    }
    70% {
        box-shadow: 0 0 0 6px rgba(34, 197, 94, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(34, 197, 94, 0);
    }
}

.btn-user-profile {
    background: rgba(15, 23, 42, 0.22);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.2s ease;
}

.btn-user-profile:hover,
.btn-user-profile:focus {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
}

.user-avatar-circle {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    color: #ffffff;
    font-weight: 700;
    font-size: 0.85rem;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.status-indicator-online {
    width: 9px;
    height: 9px;
    border-radius: 50%;
    background-color: #22c55e;
    position: absolute;
    bottom: -1px;
    right: -1px;
    border: 2px solid #334155;
    box-shadow: 0 0 6px #22c55e;
}

.user-name-label {
    font-size: 0.88rem;
}

.user-dropdown-card {
    min-width: 240px;
    border-radius: 12px;
}

/* ========================================================
   MENUS DROPDOWN HELPDESK, USUÁRIOS E NOTIFICAÇÕES (TOP NAVBAR)
   Modo Claro com as MESMAS cores de fundo, fontes e linhas
   dos temas Dark Blue e Modo Escuro
   ======================================================== */
.top-navbar .dropdown-menu,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
.top-navbar .user-dropdown-card,
[data-bs-theme="light"] .top-navbar .dropdown-menu,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-bs-theme="light"] .top-navbar .user-dropdown-card,
[data-theme-setting="light"] .top-navbar .dropdown-menu,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-theme-setting="light"] .top-navbar .user-dropdown-card,
[data-bs-theme="dark"] .top-navbar .dropdown-menu,
[data-bs-theme="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-bs-theme="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-bs-theme="dark"] .top-navbar .user-dropdown-card,
[data-theme-setting="dark"] .top-navbar .dropdown-menu,
[data-theme-setting="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-theme-setting="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-theme-setting="dark"] .top-navbar .user-dropdown-card,
[data-theme-setting="gray"] .top-navbar .dropdown-menu,
[data-theme-setting="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-theme-setting="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-theme-setting="gray"] .top-navbar .user-dropdown-card,
[data-nav-style="gray"] .top-navbar .dropdown-menu,
[data-nav-style="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-nav-style="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-nav-style="gray"] .top-navbar .user-dropdown-card {
    background-color: #0F172A !important;
    border: 1px solid #1E293B !important;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5) !important;
    color: #F8FAFC !important;
    --bs-dropdown-bg: #0F172A !important;
    --bs-dropdown-color: #F8FAFC !important;
    --bs-dropdown-border-color: #1E293B !important;
    --bs-dropdown-link-color: #E2E8F0 !important;
    --bs-dropdown-link-hover-color: #FFFFFF !important;
    --bs-dropdown-link-hover-bg: #1E293B !important;
}

/* Tema Dark Blue específico (fundo azul marinho escuro) */
[data-theme-setting="blue"] .top-navbar .dropdown-menu,
[data-theme-setting="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-theme-setting="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-theme-setting="blue"] .top-navbar .user-dropdown-card,
[data-nav-style="blue"] .top-navbar .dropdown-menu,
[data-nav-style="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-nav-style="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-nav-style="blue"] .top-navbar .user-dropdown-card {
    background-color: #0E1B3D !important;
    border: 1px solid #1D3368 !important;
    box-shadow: 0 10px 25px rgba(2, 6, 23, 0.6) !important;
    color: #F8FAFC !important;
    --bs-dropdown-bg: #0E1B3D !important;
    --bs-dropdown-color: #F8FAFC !important;
    --bs-dropdown-border-color: #1D3368 !important;
    --bs-dropdown-link-color: #E2E8F0 !important;
    --bs-dropdown-link-hover-color: #FFFFFF !important;
    --bs-dropdown-link-hover-bg: #1E293B !important;
}

/* Cores das fontes dos itens nos Menus em TODOS os temas (incluindo Modo Claro) */
.top-navbar .dropdown-menu .dropdown-item,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
.top-navbar .user-dropdown-card .dropdown-item,
[data-bs-theme="light"] .top-navbar .dropdown-menu .dropdown-item,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .dropdown-item,
[data-theme-setting="light"] .top-navbar .dropdown-menu .dropdown-item,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .dropdown-item,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .dropdown-item,
[data-bs-theme="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-bs-theme="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .dropdown-item,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .dropdown-item,
[data-theme-setting="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-theme-setting="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .dropdown-item,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .dropdown-item,
[data-theme-setting="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-theme-setting="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .dropdown-item,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .dropdown-item,
[data-theme-setting="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-theme-setting="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .dropdown-item {
    color: #E2E8F0 !important;
    background-color: transparent !important;
}

.top-navbar .dropdown-menu .dropdown-item:hover,
.top-navbar .dropdown-menu .dropdown-item:focus,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:hover,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:focus,
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:hover,
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:focus,
.top-navbar .user-dropdown-card .dropdown-item:hover,
.top-navbar .user-dropdown-card .dropdown-item:focus,
[data-bs-theme="light"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-bs-theme="light"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:hover,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:focus,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:hover,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:focus,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-theme-setting="light"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-theme-setting="light"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:hover,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:focus,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:hover,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:focus,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .dropdown-item:focus {
    color: #FFFFFF !important;
    background-color: #1E293B !important;
}

/* Divisores e Linhas em TODOS os temas (incluindo Modo Claro) */
.top-navbar .dropdown-menu .dropdown-divider,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-divider,
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-divider,
.top-navbar .user-dropdown-card .dropdown-divider,
.top-navbar .user-dropdown-card .border-bottom,
.top-navbar .user-dropdown-card .border-top,
.top-navbar .user-dropdown-card .border-light,
[data-bs-theme="light"] .top-navbar .dropdown-menu .dropdown-divider,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-divider,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-divider,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .border-bottom,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .border-top,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .border-light,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .dropdown-divider,
[data-theme-setting="light"] .top-navbar .dropdown-menu .dropdown-divider,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-divider,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-divider,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .border-bottom,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .border-top,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .border-light,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .dropdown-divider,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .dropdown-divider,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .border-bottom,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .border-top,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .border-light,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .dropdown-divider,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .dropdown-divider,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .border-bottom,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .border-top,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .border-light,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .dropdown-divider,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .dropdown-divider,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .border-bottom,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .border-top,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .border-light,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .dropdown-divider {
    border-color: #1E293B !important;
}

/* Textos em Destaque (Títulos / Nomes / text-dark) em TODOS os temas (incluindo Modo Claro) */
.top-navbar .dropdown-menu .text-dark,
.top-navbar .user-dropdown-card .text-dark,
[data-bs-theme="light"] .top-navbar .dropdown-menu .text-dark,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .text-dark,
[data-theme-setting="light"] .top-navbar .dropdown-menu .text-dark,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .text-dark,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .text-dark,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .text-dark,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .text-dark,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .text-dark,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .text-dark,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .text-dark,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .text-dark,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .text-dark {
    color: #FFFFFF !important;
}

/* Textos Secundários / Muted em TODOS os temas (incluindo Modo Claro) */
.top-navbar .dropdown-menu .text-secondary,
.top-navbar .dropdown-menu .text-muted,
.top-navbar .user-dropdown-card .text-secondary,
.top-navbar .user-dropdown-card .text-muted,
[data-bs-theme="light"] .top-navbar .dropdown-menu .text-secondary,
[data-bs-theme="light"] .top-navbar .dropdown-menu .text-muted,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .text-secondary,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .text-muted,
[data-theme-setting="light"] .top-navbar .dropdown-menu .text-secondary,
[data-theme-setting="light"] .top-navbar .dropdown-menu .text-muted,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .text-secondary,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .text-muted,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .text-secondary,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .text-muted,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .text-secondary,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .text-muted,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .text-secondary,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .text-muted,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .text-secondary,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .text-muted,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .text-secondary,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .text-muted,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .text-secondary,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .text-muted,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .text-secondary,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .text-muted,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .text-secondary,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .text-muted {
    color: #94A3B8 !important;
}

/* Código de Login */
.top-navbar .user-dropdown-card code.text-primary,
[data-bs-theme="light"] .top-navbar .user-dropdown-card code.text-primary,
[data-theme-setting="light"] .top-navbar .user-dropdown-card code.text-primary {
    color: #38BDF8 !important;
    background-color: rgba(56, 189, 248, 0.12) !important;
    padding: 2px 6px;
    border-radius: 4px;
}

/* Item e Botões de Seleção de Tema no Menu de Usuário */
.top-navbar .user-dropdown-card .dropdown-item-theme {
    padding-top: 4px !important;
    padding-bottom: 4px !important;
}

.top-navbar .user-dropdown-card .theme-btn-group {
    height: 24px;
}

.top-navbar .user-dropdown-card .theme-choice-btn {
    height: 24px !important;
    min-width: 40px !important;
    padding: 0 12px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-color: #334155 !important;
    background-color: #1E293B !important;
    color: #E2E8F0 !important;
    line-height: 1 !important;
    transition: all 0.15s ease-in-out;
}

.top-navbar .user-dropdown-card .theme-choice-btn i {
    font-size: 0.72rem !important;
    line-height: 1 !important;
    display: inline-block;
}

.top-navbar .user-dropdown-card .theme-choice-btn:hover {
    background-color: #334155 !important;
    color: #FFFFFF !important;
}

.top-navbar .user-dropdown-card .theme-choice-btn.active {
    background-color: #334155 !important;
    border-color: #38BDF8 !important;
    box-shadow: inset 0 0 0 1px #38BDF8 !important;
    color: #FFFFFF !important;
}

/* ========================================================
   SIDEBAR LATERAL ESQUERDA
   ======================================================== */
.app-wrapper {
    display: flex;
    min-height: calc(100vh - var(--topbar-height));
    position: relative;
}

.app-sidebar {
    width: var(--sidebar-width);
    background-color: #334155;
    border-right: 1px solid #1e293b;
    flex-shrink: 0;
    transition: width 0.25s ease, transform 0.25s ease;
    z-index: 1020;
    box-shadow: 2px 0 12px rgba(15, 23, 42, 0.1);
    position: sticky;
    top: var(--topbar-height);
    height: calc(100vh - var(--topbar-height));
    align-self: flex-start;
}

.sidebar-user-brief {
    background: rgba(15, 23, 42, 0.22);
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.sidebar-user-brief .text-dark {
    color: #f8fafc !important;
}

.sidebar-user-brief .badge {
    background: rgba(59, 130, 246, 0.22) !important;
    color: #93c5fd !important;
    border: 1px solid rgba(59, 130, 246, 0.35) !important;
}

.sidebar-brand-link {
    color: rgba(255, 255, 255, 0.6) !important;
    transition: color 0.2s ease, text-decoration 0.2s ease;
}

.sidebar-brand-link:hover {
    color: #ffffff !important;
    text-decoration: underline !important;
}

.sidebar-avatar {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sidebar-heading {
    color: #94a3b8 !important;
}

.sidebar-nav {
    overflow-y: auto;
    overflow-x: hidden;
}

.sidebar-nav::-webkit-scrollbar {
    width: 4px;
}

.sidebar-nav::-webkit-scrollbar-track {
    background: transparent;
}

.sidebar-nav::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.15);
    border-radius: 4px;
}

.sidebar-nav::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.3);
}

.sidebar-nav .nav-link {
    display: flex;
    align-items: center;
    padding: 10px 14px;
    color: #e2e8f0;
    font-size: 0.92rem;
    font-weight: 500;
    border-radius: 8px;
    margin: 3px 6px;
    transition: all 0.15s ease-in-out;
}

.sidebar-nav .nav-icon-wrapper {
    width: 24px;
    font-size: 1.15rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 10px;
    color: #94a3b8;
    transition: color 0.15s ease;
}

.sidebar-nav .nav-link:hover {
    color: #ffffff;
    background-color: rgba(255, 255, 255, 0.09);
}

.sidebar-nav .nav-link:hover .nav-icon-wrapper {
    color: #38bdf8;
}

.sidebar-nav .nav-link.active {
    color: #ffffff;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35);
}

.sidebar-nav .nav-link.active .nav-icon-wrapper {
    color: #ffffff;
}

.sidebar-nav .action-link {
    color: #38bdf8 !important;
}

.sidebar-nav .action-link .nav-icon-wrapper {
    color: #38bdf8 !important;
}

.sidebar-nav .action-link:hover {
    background-color: rgba(56, 189, 248, 0.12) !important;
    color: #7dd3fc !important;
}

.sidebar-divider {
    border-color: rgba(255, 255, 255, 0.1) !important;
}

.sidebar-badge {
    font-size: 0.72rem;
    padding: 0.3em 0.65em;
    font-weight: 600;
}

.sidebar-badge-construcao {
    font-size: 0.58rem;
    font-weight: 600;
    letter-spacing: 0.03rem;
    padding: 1.5px 6px;
    border-radius: 9999px;
    background: rgba(245, 158, 11, 0.16);
    color: #fbbf24 !important;
    border: 1px solid rgba(245, 158, 11, 0.35);
    line-height: 1.2;
    text-transform: uppercase;
    display: inline-flex;
    align-items: center;
    gap: 3px;
    user-select: none;
    pointer-events: none;
}

.sidebar-nav .nav-link.em-construcao {
    opacity: 0.72;
    cursor: pointer;
}

.sidebar-nav .nav-link.em-construcao:hover {
    opacity: 1;
    background-color: rgba(255, 255, 255, 0.06) !important;
}

.sidebar-chevron {
    transition: transform 0.2s ease-in-out;
    font-size: 0.72rem;
    color: #94a3b8;
}

.nav-link.collapsed .sidebar-chevron {
    transform: rotate(-90deg);
}

.sidebar-nav .nav-link:hover .sidebar-chevron {
    color: #ffffff;
}

.sidebar-submenu {
    padding-left: 0.75rem;
    margin-left: 0.85rem;
    border-left: 1px solid rgba(255, 255, 255, 0.12);
}

.sidebar-submenu .nav-link {
    font-size: 0.88rem;
    padding: 8px 12px;
    margin: 2px 4px;
}

/* Correção de visibilidade e transição do Bootstrap Collapse em submenus */
.collapse {
    visibility: visible !important;
}
.collapse:not(.show) {
    display: none !important;
}
.collapsing {
    position: relative;
    height: 0;
    overflow: hidden;
    transition: height 0.25s ease !important;
    visibility: visible !important;
}
.collapse.show {
    display: block !important;
    visibility: visible !important;
}

.sidebar-footer {
    flex-shrink: 0;
    background: rgba(15, 23, 42, 0.28) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}

.sidebar-footer .text-secondary {
    color: #e2e8f0 !important;
}

.sidebar-footer .text-muted {
    color: #94a3b8 !important;
}

.sidebar-footer .text-dark {
    color: #ffffff !important;
}

/* ========================================================
   CONTEÚDO PRINCIPAL (APP CONTENT)
   ======================================================== */
.app-content {
    flex-grow: 1;
    min-width: 0; /* Previne estouro horizontal de tabelas */
    background-color: #f8fafc;
}

/* ========================================================
   BARRA DE TÍTULO FIXA DAS TELAS (STICKY SCREEN HEADER)
   ======================================================== */
.page-header-sticky {
    position: sticky;
    top: var(--topbar-height);
    z-index: 1010;
    background-color: #f8fafc;
    padding: 0.85rem 1rem;
    margin: -1rem -1rem 1.5rem -1rem;
    border-bottom: 1px solid #e2e8f0;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.04);
}

.flash-messages-wrapper + .page-header-sticky,
.flash-messages-wrapper ~ .page-header-sticky {
    margin-top: 0;
}

@media (min-width: 992px) {
    .page-header-sticky {
        padding: 1rem 1.5rem;
        margin: -1.5rem -1.5rem 1.5rem -1.5rem;
    }
}

/* ========================================================
   KPIS E CARDS DO DASHBOARD
   ======================================================== */
.kpi-card {
    border-radius: 12px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.kpi-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.06) !important;
}

.kpi-icon-wrapper {
    width: 52px;
    height: 52px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ========================================================
   TELA DE LOGIN
   ======================================================== */
.login-body {
    background: radial-gradient(circle at top left, #f8fafc 0%, #e2e8f0 100%);
    font-family: var(--font-sans);
}

.login-card {
    border-radius: 18px;
    background: #ffffff;
    box-shadow: 0 20px 40px rgba(15, 23, 42, 0.08), 0 4px 12px rgba(15, 23, 42, 0.04) !important;
    border: 1px solid rgba(226, 232, 240, 0.8) !important;
}

.login-header {
    background-color: #334155;
}

.login-logo-circle,
.login-header .login-logo-circle,
[data-bs-theme="dark"] .login-logo-circle,
[data-bs-theme="dark"] .login-header .login-logo-circle,
[data-theme-setting="blue"] .login-logo-circle,
[data-theme-setting="blue"] .login-header .login-logo-circle,
[data-theme-setting="dark"] .login-logo-circle,
[data-theme-setting="dark"] .login-header .login-logo-circle {
    width: 72px;
    height: 72px;
    border-radius: 50% !important;
    background-color: #ffffff !important;
    background: #ffffff !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25) !important;
}

.login-logo-circle img {
    width: 44px;
    height: 44px;
    object-fit: contain;
    display: block;
}

.btn-login {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    border: none;
    padding: 12px;
    border-radius: 10px;
    transition: all 0.2s ease;
}

.btn-login:hover {
    background: linear-gradient(135deg, #1d4ed8 0%, #1e40af 100%);
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(37, 99, 235, 0.35);
}

.status-dot-active {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background-color: #22c55e;
    display: inline-block;
}

/* ========================================================
   RESPONSIVIDADE E TOGGLE DA SIDEBAR
   ======================================================== */
@media (max-width: 991.98px) {
    .app-sidebar {
        position: fixed;
        top: var(--topbar-height);
        bottom: 0;
        left: 0;
        transform: translateX(-100%);
        box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    }

    .app-sidebar.show {
        transform: translateX(0);
    }
}

.app-sidebar.sidebar-preload,
.app-sidebar.sidebar-preload * {
    transition: none !important;
}

@media (min-width: 992px) {
    html.sidebar-is-collapsed .app-sidebar,
    .app-sidebar.collapsed {
        width: 74px !important;
    }

    html.sidebar-is-collapsed .app-sidebar .sidebar-heading,
    html.sidebar-is-collapsed .app-sidebar .nav-label,
    html.sidebar-is-collapsed .app-sidebar .sidebar-badge,
    html.sidebar-is-collapsed .app-sidebar .sidebar-chevron,
    html.sidebar-is-collapsed .app-sidebar .sidebar-user-brief,
    html.sidebar-is-collapsed .app-sidebar .sidebar-footer,
    .app-sidebar.collapsed .sidebar-heading,
    .app-sidebar.collapsed .nav-label,
    .app-sidebar.collapsed .sidebar-badge,
    .app-sidebar.collapsed .sidebar-chevron,
    .app-sidebar.collapsed .sidebar-user-brief,
    .app-sidebar.collapsed .sidebar-footer {
        display: none !important;
    }

    html.sidebar-is-collapsed .app-sidebar .sidebar-submenu,
    .app-sidebar.collapsed .sidebar-submenu {
        padding-left: 0 !important;
        margin-left: 0 !important;
        border-left: none !important;
    }

    html.sidebar-is-collapsed .app-sidebar .nav-link,
    .app-sidebar.collapsed .nav-link {
        justify-content: center;
        padding: 12px 0;
    }

    html.sidebar-is-collapsed .app-sidebar .nav-icon-wrapper,
    .app-sidebar.collapsed .nav-icon-wrapper {
        margin-right: 0;
    }
}

/* ========================================================
   SISTEMA DE TEMAS INTELIGENTE (LIGHT & DARK MODES)
   ======================================================== */
.theme-toggle-btn {
    width: 36px;
    height: 36px;
    transition: all 0.2s ease, transform 0.2s ease;
}

.theme-toggle-btn:hover {
    transform: scale(1.05);
}

.theme-icon-active {
    transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.theme-choice-btn.active {
    font-weight: 600;
}

/* Transições suaves ao alternar o tema */
body.app-body,
.top-navbar,
.app-sidebar,
.page-header-sticky,
.card,
.modal-content,
.dropdown-menu,
.form-control,
.form-select,
.table {
    transition: background-color 0.25s ease, color 0.25s ease, border-color 0.25s ease, box-shadow 0.25s ease !important;
}

/* TEMA CLARO (LIGHT MODE) */
[data-bs-theme="light"] {
    --bs-body-bg: #f8fafc;
    --bs-body-color: #334155;
    --bs-border-color: #e2e8f0;
}

[data-bs-theme="light"] body.app-body {
    background-color: #f8fafc;
    color: #334155;
}

[data-bs-theme="light"] .top-navbar {
    background-color: #334155 !important;
    border-bottom: 1px solid #1e293b !important;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.12) !important;
}

[data-bs-theme="light"] .top-navbar #sidebarToggle {
    color: #ffffff !important;
}

[data-bs-theme="light"] .top-navbar #sidebarToggle:hover {
    background-color: rgba(255, 255, 255, 0.1) !important;
}

[data-bs-theme="light"] .top-navbar .vr {
    color: rgba(255, 255, 255, 0.25) !important;
}

[data-bs-theme="light"] .top-navbar .btn-user-profile {
    background: rgba(15, 23, 42, 0.22);
    border-color: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}

[data-bs-theme="light"] .top-navbar .btn-user-profile:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: rgba(255, 255, 255, 0.25);
}

[data-bs-theme="light"] .top-navbar .company-name {
    color: #ffffff !important;
}

[data-bs-theme="light"] .top-navbar .user-name-label {
    color: #ffffff !important;
}

[data-bs-theme="light"] .top-navbar .user-role-label {
    color: rgba(255, 255, 255, 0.7) !important;
}

[data-bs-theme="light"] .top-navbar .btn-outline-light {
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.3) !important;
}

[data-bs-theme="light"] .top-navbar .btn-outline-light:hover {
    background-color: rgba(255, 255, 255, 0.15) !important;
    color: #ffffff !important;
}

[data-bs-theme="light"] .top-navbar .online-users-badge {
    background: #f0fdf4;
    border-color: #bbf7d0;
    color: #166534;
}

[data-bs-theme="light"] .top-navbar .online-users-badge .text-white {
    color: #166534 !important;
}

[data-bs-theme="light"] .top-navbar .online-users-badge .text-white-50 {
    color: #15803d !important;
}

/* Sidebar no Modo Claro: mantém o mesmo visual do tema Dark Blue (estilo base) */

[data-bs-theme="light"] .page-header-sticky {
    background-color: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
}

/* TEMA ESCURO (DARK MODE) */
[data-bs-theme="dark"] {
    --bs-body-bg: #f8fafc;
    --bs-body-color: #334155;
    --bs-border-color: #1e293b;
}

[data-bs-theme="dark"] body.app-body,
[data-bs-theme="dark"] .app-wrapper,
[data-bs-theme="dark"] .app-content,
[data-bs-theme="dark"] #mainContent {
    background-color: #f8fafc !important;
    color: #334155;
}

[data-bs-theme="dark"] .top-navbar {
    background-color: #0f172a !important;
    border-bottom: 1px solid #1e293b !important;
}

[data-bs-theme="dark"] .app-sidebar {
    background-color: #0f172a !important;
    border-right: 1px solid #1e293b !important;
}

[data-bs-theme="dark"] .sidebar-footer {
    background: rgba(0, 0, 0, 0.3) !important;
    border-top: 1px solid #1e293b !important;
}

[data-bs-theme="dark"] .page-header-sticky {
    background-color: rgba(11, 17, 32, 0.95);
    border-bottom: 1px solid #1e293b;
}

/* ========================================================
   CORES DE FONTES NO TEMA ESCURO (DARK MODE)
   ======================================================== */
[data-bs-theme="dark"],
[data-bs-theme="dark"] body {
    color: #f1f5f9;
}

/* Todos os textos escuros viram branco/cinza claro no modo escuro */
[data-bs-theme="dark"] .text-dark,
[data-bs-theme="dark"] * .text-dark,
[data-bs-theme="dark"] .page-header-sticky .text-dark,
[data-bs-theme="dark"] .card-title.text-dark,
[data-bs-theme="dark"] .display-1.text-dark,
[data-bs-theme="dark"] .display-2.text-dark,
[data-bs-theme="dark"] .display-3.text-dark,
[data-bs-theme="dark"] .display-4.text-dark,
[data-bs-theme="dark"] .display-5.text-dark,
[data-bs-theme="dark"] .display-6.text-dark,
[data-bs-theme="dark"] h1, [data-bs-theme="dark"] h2,
[data-bs-theme="dark"] h3, [data-bs-theme="dark"] h4,
[data-bs-theme="dark"] h5, [data-bs-theme="dark"] h6,
[data-bs-theme="dark"] .h1, [data-bs-theme="dark"] .h2,
[data-bs-theme="dark"] .h3, [data-bs-theme="dark"] .h4,
[data-bs-theme="dark"] .h5, [data-bs-theme="dark"] .h6 {
    color: #ffffff !important;
}

/* Textos secundários e muted com legibilidade perfeita */
[data-bs-theme="dark"] .text-muted,
[data-bs-theme="dark"] * .text-muted,
[data-bs-theme="dark"] small.text-muted {
    color: #94a3b8 !important;
}

[data-bs-theme="dark"] .text-secondary,
[data-bs-theme="dark"] * .text-secondary {
    color: #cbd5e1 !important;
}

[data-bs-theme="dark"] .text-body {
    color: #f8fafc !important;
}

/* Rótulos de formulário */
[data-bs-theme="dark"] label,
[data-bs-theme="dark"] .form-label,
[data-bs-theme="dark"] .form-check-label {
    color: #e2e8f0 !important;
}

[data-bs-theme="dark"] .card {
    background-color: #1e293b;
    border-color: #334155;
    color: #f8fafc;
}

[data-bs-theme="dark"] .card-header {
    background-color: rgba(15, 23, 42, 0.6);
    border-bottom-color: #334155;
    color: #f8fafc;
}

[data-bs-theme="dark"] .card-header.bg-white,
[data-bs-theme="dark"] .card-header.bg-light {
    background-color: #1e293b !important;
    border-bottom-color: #334155 !important;
    color: #f8fafc !important;
}

[data-bs-theme="dark"] .card-header .text-primary {
    color: #60a5fa !important;
}

[data-bs-theme="dark"] .card-footer {
    background-color: rgba(15, 23, 42, 0.4);
    border-top-color: #334155;
}

[data-bs-theme="dark"] .bg-light,
[data-bs-theme="dark"] .bg-white {
    background-color: #1e293b !important;
}

[data-bs-theme="dark"] .user-dropdown-card {
    background-color: #1e293b;
    border: 1px solid #334155 !important;
    color: #f8fafc;
}

[data-bs-theme="dark"] .user-dropdown-card .border-bottom,
[data-bs-theme="dark"] .user-dropdown-card .border-top {
    border-color: #334155 !important;
}

[data-bs-theme="dark"] .user-dropdown-card .text-dark {
    color: #f8fafc !important;
}

[data-bs-theme="dark"] .modal-content {
    background-color: #1e293b;
    border-color: #334155;
    color: #f8fafc;
}

[data-bs-theme="dark"] .modal-header,
[data-bs-theme="dark"] .modal-footer {
    border-color: #334155;
}

[data-bs-theme="dark"] .modal-body.bg-light {
    background-color: #0f172a !important;
}

/* Campos de entrada e seleção */
[data-bs-theme="dark"] .form-control,
[data-bs-theme="dark"] .form-select,
[data-bs-theme="dark"] textarea.form-control {
    background-color: #0f172a !important;
    border-color: #334155 !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}

[data-bs-theme="dark"] .form-control:focus,
[data-bs-theme="dark"] .form-select:focus {
    background-color: #0f172a !important;
    border-color: #3b82f6 !important;
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}

[data-bs-theme="dark"] .form-control[readonly],
[data-bs-theme="dark"] .form-control:disabled,
[data-bs-theme="dark"] .form-select:disabled,
[data-bs-theme="dark"] textarea.form-control[readonly],
[data-bs-theme="dark"] textarea.form-control:disabled {
    background-color: rgba(15, 23, 42, 0.75) !important;
    border-color: #334155 !important;
    color: #f8fafc !important;
    -webkit-text-fill-color: #f8fafc !important;
    opacity: 1 !important;
}

[data-bs-theme="dark"] .form-control::placeholder,
[data-bs-theme="dark"] textarea.form-control::placeholder {
    color: #64748b !important;
    opacity: 1 !important;
}

/* Ícones e caixas anexas de input */
[data-bs-theme="dark"] .input-group-text {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    color: #cbd5e1 !important;
}

[data-bs-theme="dark"] .input-group-text i {
    color: #cbd5e1 !important;
}

/* Abas de navegação */
[data-bs-theme="dark"] .nav-pills.bg-white,
[data-bs-theme="dark"] .nav-tabs.bg-white {
    background-color: #0f172a !important;
    border-color: #334155 !important;
}

[data-bs-theme="dark"] .nav-pills .nav-link:not(.active),
[data-bs-theme="dark"] .nav-tabs .nav-link:not(.active) {
    color: #cbd5e1 !important;
}

[data-bs-theme="dark"] .badge.bg-light {
    background-color: #334155 !important;
    color: #f8fafc !important;
    border-color: #475569 !important;
}

[data-bs-theme="dark"] .badge.bg-secondary-subtle {
    background-color: rgba(148, 163, 184, 0.15) !important;
    color: #e2e8f0 !important;
    border-color: rgba(148, 163, 184, 0.3) !important;
}

[data-bs-theme="dark"] .table {
    --bs-table-bg: transparent;
    --bs-table-color: #e2e8f0;
    --bs-table-border-color: #334155;
}

[data-bs-theme="dark"] .table-light,
[data-bs-theme="dark"] .table thead.table-light th {
    background-color: #0f172a !important;
    color: #94a3b8 !important;
    border-color: #334155 !important;
}

/* ========================================================
   CRUD DE CADASTROS - TEMA ESCURO (LINHAS E TEXTOS BRANCOS)
   ======================================================== */
[data-bs-theme="dark"] #modalPesquisaClientes,
[data-bs-theme="dark"] #modalDetalhesCliente,
[data-bs-theme="dark"] #modalNovoCadastro,
[data-bs-theme="dark"] #modalFormEndereco,
[data-bs-theme="dark"] #modalFormContato {
    color: #ffffff;
}

[data-bs-theme="dark"] #modalPesquisaClientes .modal-header,
[data-bs-theme="dark"] #modalDetalhesCliente .modal-header,
[data-bs-theme="dark"] #modalNovoCadastro .modal-header,
[data-bs-theme="dark"] #modalFormEndereco .modal-header,
[data-bs-theme="dark"] #modalFormContato .modal-header {
    background-color: #0f172a !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2) !important;
}

[data-bs-theme="dark"] #modalPesquisaClientes .modal-body,
[data-bs-theme="dark"] #modalDetalhesCliente .modal-body,
[data-bs-theme="dark"] #modalNovoCadastro .modal-body,
[data-bs-theme="dark"] #modalFormEndereco .modal-body,
[data-bs-theme="dark"] #modalFormContato .modal-body {
    background-color: #0f172a !important;
}

[data-bs-theme="dark"] #modalPesquisaClientes .modal-footer,
[data-bs-theme="dark"] #modalDetalhesCliente .modal-footer,
[data-bs-theme="dark"] #modalNovoCadastro .modal-footer,
[data-bs-theme="dark"] #modalFormEndereco .modal-footer,
[data-bs-theme="dark"] #modalFormContato .modal-footer {
    background-color: #1e293b !important;
    border-top: 1px solid rgba(255, 255, 255, 0.2) !important;
}

[data-bs-theme="dark"] #modalPesquisaClientes .card,
[data-bs-theme="dark"] #modalDetalhesCliente .card,
[data-bs-theme="dark"] #modalNovoCadastro .card,
[data-bs-theme="dark"] #modalFormEndereco .card,
[data-bs-theme="dark"] #modalFormContato .card {
    background-color: #1e293b !important;
    border: 1px solid rgba(255, 255, 255, 0.15) !important;
}

[data-bs-theme="dark"] #modalPesquisaClientes .modal-title,
[data-bs-theme="dark"] #modalDetalhesCliente .modal-title,
[data-bs-theme="dark"] #modalNovoCadastro .modal-title,
[data-bs-theme="dark"] #modalFormEndereco .modal-title,
[data-bs-theme="dark"] #modalFormContato .modal-title,
[data-bs-theme="dark"] #modalPesquisaClientes .form-label,
[data-bs-theme="dark"] #modalDetalhesCliente .form-label,
[data-bs-theme="dark"] #modalNovoCadastro .form-label,
[data-bs-theme="dark"] #modalFormEndereco .form-label,
[data-bs-theme="dark"] #modalFormContato .form-label,
[data-bs-theme="dark"] #modalPesquisaClientes .text-dark,
[data-bs-theme="dark"] #modalDetalhesCliente .text-dark,
[data-bs-theme="dark"] #modalNovoCadastro .text-dark,
[data-bs-theme="dark"] #modalFormEndereco .text-dark,
[data-bs-theme="dark"] #modalFormContato .text-dark {
    color: #ffffff !important;
}

/* Tabelas do CRUD de Cadastros (Pesquisa, Endereços, Contatos) */
[data-bs-theme="dark"] #tabelaClientesModal,
[data-bs-theme="dark"] #tabelaEnderecosCliente,
[data-bs-theme="dark"] #tabelaContatosCliente {
    --bs-table-color: #ffffff !important;
    --bs-table-bg: transparent !important;
    --bs-table-hover-color: #ffffff !important;
    --bs-table-hover-bg: rgba(255, 255, 255, 0.08) !important;
    --bs-table-border-color: rgba(255, 255, 255, 0.35) !important;
    border-color: rgba(255, 255, 255, 0.35) !important;
}

/* Cabeçalho da tabela com títulos brancos e linha divisória branca */
[data-bs-theme="dark"] #tabelaClientesModal thead th,
[data-bs-theme="dark"] #tabelaEnderecosCliente thead th,
[data-bs-theme="dark"] #tabelaContatosCliente thead th {
    background-color: #0f172a !important;
    color: #ffffff !important;
    border-bottom: 2px solid #ffffff !important;
    border-top: 1px solid rgba(255, 255, 255, 0.2) !important;
}

[data-bs-theme="dark"] #tabelaClientesModal thead th i,
[data-bs-theme="dark"] #tabelaClientesModal thead th span {
    color: #ffffff !important;
}

/* LINHAS DA TABELA (TR E TD): TEXTO BRANCO E LINHAS DIVISÓRIAS BRANCAS */
[data-bs-theme="dark"] #tabelaClientesModal tbody tr,
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody tr,
[data-bs-theme="dark"] #tabelaContatosCliente tbody tr {
    color: #ffffff !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.35) !important;
}

[data-bs-theme="dark"] #tabelaClientesModal tbody td,
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody td,
[data-bs-theme="dark"] #tabelaContatosCliente tbody td {
    color: #ffffff !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.35) !important;
}

/* Conteúdo interno das linhas da tabela */
[data-bs-theme="dark"] #tabelaClientesModal tbody tr td div,
[data-bs-theme="dark"] #tabelaClientesModal tbody tr td span:not(.badge),
[data-bs-theme="dark"] #tabelaClientesModal tbody tr td small,
[data-bs-theme="dark"] #tabelaClientesModal tbody tr td strong,
[data-bs-theme="dark"] #tabelaClientesModal tbody tr td a,
[data-bs-theme="dark"] #tabelaClientesModal tbody tr td .text-dark,
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody tr td div,
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody tr td span:not(.badge),
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody tr td small,
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody tr td strong,
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody tr td .text-dark,
[data-bs-theme="dark"] #tabelaContatosCliente tbody tr td div,
[data-bs-theme="dark"] #tabelaContatosCliente tbody tr td span:not(.badge),
[data-bs-theme="dark"] #tabelaContatosCliente tbody tr td small,
[data-bs-theme="dark"] #tabelaContatosCliente tbody tr td strong,
[data-bs-theme="dark"] #tabelaContatosCliente tbody tr td a,
[data-bs-theme="dark"] #tabelaContatosCliente tbody tr td .text-dark {
    color: #ffffff !important;
}

/* Cidade/UF e textos auxiliares nas linhas */
[data-bs-theme="dark"] #tabelaClientesModal tbody tr td small.text-muted,
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody tr td small.text-muted {
    color: #cbd5e1 !important;
}

/* CNPJ/CPF em fonte mono nas linhas */
[data-bs-theme="dark"] #tabelaClientesModal tbody tr td span.font-monospace {
    color: #e2e8f0 !important;
}

/* Hover da linha da tabela */
[data-bs-theme="dark"] #tabelaClientesModal tbody tr:hover,
[data-bs-theme="dark"] #tabelaClientesModal tbody tr:hover td,
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody tr:hover,
[data-bs-theme="dark"] #tabelaEnderecosCliente tbody tr:hover td,
[data-bs-theme="dark"] #tabelaContatosCliente tbody tr:hover,
[data-bs-theme="dark"] #tabelaContatosCliente tbody tr:hover td {
    background-color: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}

/* Linha selecionada */
[data-bs-theme="dark"] #tabelaClientesModal tbody tr.table-primary,
[data-bs-theme="dark"] #tabelaClientesModal tbody tr.table-primary td {
    background-color: #1d4ed8 !important;
    color: #ffffff !important;
    border-bottom: 1px solid #ffffff !important;
}

[data-bs-theme="dark"] #tabelaClientesModal tbody tr.table-primary td div,
[data-bs-theme="dark"] #tabelaClientesModal tbody tr.table-primary td small,
[data-bs-theme="dark"] #tabelaClientesModal tbody tr.table-primary td span:not(.badge) {
    color: #ffffff !important;
}

/* Abas e paginação */
[data-bs-theme="dark"] #pillsTabDetalhes {
    background-color: #0f172a !important;
    border-color: rgba(255, 255, 255, 0.2) !important;
}

[data-bs-theme="dark"] #pillsTabDetalhes .nav-link:not(.active) {
    color: #e2e8f0 !important;
}

[data-bs-theme="dark"] #infoPaginacaoClientes,
[data-bs-theme="dark"] #infoPaginacaoClientes strong {
    color: #ffffff !important;
}

[data-bs-theme="dark"] .list-group-item {
    background-color: #1e293b;
    border-color: #334155;
    color: #e2e8f0;
}

/* ========================================================
   ESTILO GRAY PARA HEADER E SIDEBAR (PAINÉIS CONFORME TEMA)
   ======================================================== */
[data-nav-style="gray"] .top-navbar,
[data-theme-setting="gray"] .top-navbar {
    background-color: #334155 !important;
    border-bottom: 1px solid #1e293b !important;
    box-shadow: 0 4px 12px rgba(15, 23, 42, 0.12) !important;
}

[data-nav-style="gray"] .top-navbar #sidebarToggle,
[data-theme-setting="gray"] .top-navbar #sidebarToggle {
    color: #ffffff !important;
}

[data-nav-style="gray"] .top-navbar #sidebarToggle:hover,
[data-theme-setting="gray"] .top-navbar #sidebarToggle:hover {
    background-color: rgba(255, 255, 255, 0.1) !important;
}

[data-nav-style="gray"] .top-navbar .vr,
[data-theme-setting="gray"] .top-navbar .vr {
    color: rgba(255, 255, 255, 0.25) !important;
}

[data-nav-style="gray"] .top-navbar .btn-user-profile,
[data-theme-setting="gray"] .top-navbar .btn-user-profile {
    background: rgba(15, 23, 42, 0.22) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}

[data-nav-style="gray"] .top-navbar .btn-user-profile:hover,
[data-theme-setting="gray"] .top-navbar .btn-user-profile:hover {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: rgba(255, 255, 255, 0.25) !important;
}

[data-nav-style="gray"] .top-navbar .company-name,
[data-theme-setting="gray"] .top-navbar .company-name {
    color: #ffffff !important;
}

[data-nav-style="gray"] .top-navbar .user-name-label,
[data-theme-setting="gray"] .top-navbar .user-name-label {
    color: #ffffff !important;
}

[data-nav-style="gray"] .top-navbar .user-role-label,
[data-theme-setting="gray"] .top-navbar .user-role-label {
    color: rgba(255, 255, 255, 0.7) !important;
}

[data-nav-style="gray"] .top-navbar .btn-outline-light,
[data-theme-setting="gray"] .top-navbar .btn-outline-light {
    color: #ffffff !important;
    border-color: rgba(255, 255, 255, 0.3) !important;
}

[data-nav-style="gray"] .top-navbar .btn-outline-light:hover,
[data-theme-setting="gray"] .top-navbar .btn-outline-light:hover {
    background-color: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}

[data-nav-style="gray"] .top-navbar .online-users-badge,
[data-theme-setting="gray"] .top-navbar .online-users-badge {
    background: rgba(15, 23, 42, 0.22) !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #ffffff !important;
}

[data-nav-style="gray"] .top-navbar .online-users-badge .text-white,
[data-theme-setting="gray"] .top-navbar .online-users-badge .text-white {
    color: #ffffff !important;
}

[data-nav-style="gray"] .top-navbar .online-users-badge .text-white-50,
[data-theme-setting="gray"] .top-navbar .online-users-badge .text-white-50 {
    color: rgba(255, 255, 255, 0.6) !important;
}

[data-nav-style="gray"] .brand-title .brand-prefix,
[data-theme-setting="gray"] .brand-title .brand-prefix {
    color: #ffffff !important;
}

[data-nav-style="gray"] .brand-title .brand-suffix,
[data-theme-setting="gray"] .brand-title .brand-suffix {
    color: var(--primary-accent, #f08800) !important;
}

[data-nav-style="gray"] .app-sidebar,
[data-theme-setting="gray"] .app-sidebar {
    background-color: #334155 !important;
    border-right: 1px solid #1e293b !important;
    box-shadow: 2px 0 12px rgba(15, 23, 42, 0.1) !important;
}

[data-nav-style="gray"] .sidebar-heading,
[data-theme-setting="gray"] .sidebar-heading {
    color: #94a3b8 !important;
}

[data-nav-style="gray"] .sidebar-nav .nav-link,
[data-theme-setting="gray"] .sidebar-nav .nav-link {
    color: #e2e8f0 !important;
}

[data-nav-style="gray"] .sidebar-nav .nav-link:hover,
[data-theme-setting="gray"] .sidebar-nav .nav-link:hover {
    color: #ffffff !important;
    background-color: rgba(255, 255, 255, 0.09) !important;
}

[data-nav-style="gray"] .sidebar-nav .nav-icon-wrapper,
[data-theme-setting="gray"] .sidebar-nav .nav-icon-wrapper {
    color: #94a3b8 !important;
}

[data-nav-style="gray"] .sidebar-nav .nav-link:hover .nav-icon-wrapper,
[data-theme-setting="gray"] .sidebar-nav .nav-link:hover .nav-icon-wrapper {
    color: #38bdf8 !important;
}

[data-nav-style="gray"] .sidebar-nav .nav-link.active,
[data-theme-setting="gray"] .sidebar-nav .nav-link.active {
    color: #ffffff !important;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35) !important;
}

[data-nav-style="gray"] .sidebar-nav .nav-link.active .nav-icon-wrapper,
[data-theme-setting="gray"] .sidebar-nav .nav-link.active .nav-icon-wrapper {
    color: #ffffff !important;
}

[data-nav-style="gray"] .sidebar-divider,
[data-theme-setting="gray"] .sidebar-divider {
    border-color: rgba(255, 255, 255, 0.1) !important;
}

[data-nav-style="gray"] .sidebar-footer,
[data-theme-setting="gray"] .sidebar-footer {
    background: rgba(15, 23, 42, 0.28) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}

[data-nav-style="gray"] .sidebar-brand-link,
[data-theme-setting="gray"] .sidebar-brand-link {
    color: rgba(255, 255, 255, 0.6) !important;
}

[data-nav-style="gray"] .sidebar-brand-link:hover,
[data-theme-setting="gray"] .sidebar-brand-link:hover {
    color: #ffffff !important;
}

[data-nav-style="gray"] .sidebar-footer .text-white-50,
[data-theme-setting="gray"] .sidebar-footer .text-white-50 {
    color: rgba(255, 255, 255, 0.5) !important;
}






/* ========================================================
   TEMA: DARK BLUE
   Aplicado a todos os painéis e telas (menos o sidebar)
   ======================================================== */
[data-nav-style="blue"] .top-navbar,
[data-theme-setting="blue"] .top-navbar {
    background-color: #0b1633 !important; /* Dark Blue Navbar */
    border-bottom: 1px solid #1d3368 !important;
}

[data-nav-style="blue"] .top-navbar .company-header-badge,
[data-nav-style="blue"] .top-navbar .online-users-badge,
[data-nav-style="blue"] .top-navbar .btn-user-profile,
[data-theme-setting="blue"] .top-navbar .company-header-badge,
[data-theme-setting="blue"] .top-navbar .online-users-badge,
[data-theme-setting="blue"] .top-navbar .btn-user-profile {
    background: rgba(29, 51, 104, 0.5) !important;
    border: 1px solid #1d3368 !important;
    color: #ffffff !important;
}

[data-nav-style="blue"] .top-navbar .btn-outline-light,
[data-theme-setting="blue"] .top-navbar .btn-outline-light {
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.3);
}

[data-nav-style="blue"] .top-navbar .btn-outline-light:hover,
[data-theme-setting="blue"] .top-navbar .btn-outline-light:hover {
    background-color: rgba(255, 255, 255, 0.15);
    border-color: rgba(255, 255, 255, 0.4);
}

[data-nav-style="blue"] .brand-title .brand-prefix,
[data-theme-setting="blue"] .brand-title .brand-prefix {
    color: #38bdf8 !important;
    font-weight: 800 !important;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.6) !important;
}

[data-nav-style="blue"] .brand-icon-wrapper,
[data-theme-setting="blue"] .brand-icon-wrapper {
    background: #0e1b3d !important;
    border: 2px solid #2563eb !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.35) !important;
}

/* ========================================================
   MENUS DROPDOWN HELPDESK E USUÁRIOS
   Background com a mesma cor da Sidebar em cada tema
   ======================================================== */
/* ========================================================
   MENUS DROPDOWN HELPDESK, USUÁRIOS E NOTIFICAÇÕES (TOP NAVBAR)
   Modo Claro com as MESMAS cores de fundo, fontes e linhas
   dos temas Dark Blue e Modo Escuro
   ======================================================== */
/* Fundo, borda e sombra unificados para TODOS os temas (incluindo Modo Claro) */
.top-navbar .dropdown-menu,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
.top-navbar .user-dropdown-card,
[data-bs-theme="light"] .top-navbar .dropdown-menu,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-bs-theme="light"] .top-navbar .user-dropdown-card,
[data-theme-setting="light"] .top-navbar .dropdown-menu,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-theme-setting="light"] .top-navbar .user-dropdown-card,
[data-bs-theme="dark"] .top-navbar .dropdown-menu,
[data-bs-theme="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-bs-theme="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-bs-theme="dark"] .top-navbar .user-dropdown-card,
[data-theme-setting="dark"] .top-navbar .dropdown-menu,
[data-theme-setting="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-theme-setting="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-theme-setting="dark"] .top-navbar .user-dropdown-card,
[data-theme-setting="gray"] .top-navbar .dropdown-menu,
[data-theme-setting="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-theme-setting="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-theme-setting="gray"] .top-navbar .user-dropdown-card,
[data-nav-style="gray"] .top-navbar .dropdown-menu,
[data-nav-style="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-nav-style="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-nav-style="gray"] .top-navbar .user-dropdown-card {
    background-color: #0F172A !important;
    border: 1px solid #1E293B !important;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5) !important;
    color: #F8FAFC !important;
}

/* Tema Dark Blue específico (fundo azul marinho escuro) */
[data-theme-setting="blue"] .top-navbar .dropdown-menu,
[data-theme-setting="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-theme-setting="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-theme-setting="blue"] .top-navbar .user-dropdown-card,
[data-nav-style="blue"] .top-navbar .dropdown-menu,
[data-nav-style="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"],
[data-nav-style="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"],
[data-nav-style="blue"] .top-navbar .user-dropdown-card {
    background-color: #0E1B3D !important;
    border: 1px solid #1D3368 !important;
    box-shadow: 0 10px 25px rgba(2, 6, 23, 0.6) !important;
    color: #F8FAFC !important;
}

/* Cores das fontes dos itens nos Menus em TODOS os temas (incluindo Modo Claro) */
.top-navbar .dropdown-menu .dropdown-item,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
.top-navbar .user-dropdown-card .dropdown-item,
[data-bs-theme="light"] .top-navbar .dropdown-menu .dropdown-item,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .dropdown-item,
[data-theme-setting="light"] .top-navbar .dropdown-menu .dropdown-item,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .dropdown-item,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .dropdown-item,
[data-bs-theme="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-bs-theme="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .dropdown-item,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .dropdown-item,
[data-theme-setting="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-theme-setting="dark"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .dropdown-item,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .dropdown-item,
[data-theme-setting="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-theme-setting="gray"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .dropdown-item,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .dropdown-item,
[data-theme-setting="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item,
[data-theme-setting="blue"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .dropdown-item {
    color: #E2E8F0 !important;
    background-color: transparent !important;
}

.top-navbar .dropdown-menu .dropdown-item:hover,
.top-navbar .dropdown-menu .dropdown-item:focus,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:hover,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:focus,
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:hover,
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:focus,
.top-navbar .user-dropdown-card .dropdown-item:hover,
.top-navbar .user-dropdown-card .dropdown-item:focus,
[data-bs-theme="light"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-bs-theme="light"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:hover,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:focus,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:hover,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:focus,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-theme-setting="light"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-theme-setting="light"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:hover,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-item:focus,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:hover,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-item:focus,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .dropdown-item:focus,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .dropdown-item:hover,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .dropdown-item:focus,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .dropdown-item:hover,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .dropdown-item:focus {
    color: #FFFFFF !important;
    background-color: #1E293B !important;
}

/* Divisores e Linhas em TODOS os temas (incluindo Modo Claro) */
.top-navbar .dropdown-menu .dropdown-divider,
.top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-divider,
.top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-divider,
.top-navbar .user-dropdown-card .dropdown-divider,
.top-navbar .user-dropdown-card .border-bottom,
.top-navbar .user-dropdown-card .border-top,
.top-navbar .user-dropdown-card .border-light,
[data-bs-theme="light"] .top-navbar .dropdown-menu .dropdown-divider,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-divider,
[data-bs-theme="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-divider,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .border-bottom,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .border-top,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .border-light,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .dropdown-divider,
[data-theme-setting="light"] .top-navbar .dropdown-menu .dropdown-divider,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownHelpDeskHeader"] .dropdown-divider,
[data-theme-setting="light"] .top-navbar .dropdown-menu[aria-labelledby="dropdownNotificacoesHeader"] .dropdown-divider,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .border-bottom,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .border-top,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .border-light,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .dropdown-divider,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .dropdown-divider,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .border-bottom,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .border-top,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .border-light,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .dropdown-divider,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .dropdown-divider,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .border-bottom,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .border-top,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .border-light,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .dropdown-divider,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .dropdown-divider,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .border-bottom,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .border-top,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .border-light,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .dropdown-divider {
    border-color: #1E293B !important;
}

/* Textos em Destaque (Títulos / Nomes / text-dark) em TODOS os temas (incluindo Modo Claro) */
.top-navbar .dropdown-menu .text-dark,
.top-navbar .user-dropdown-card .text-dark,
[data-bs-theme="light"] .top-navbar .dropdown-menu .text-dark,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .text-dark,
[data-theme-setting="light"] .top-navbar .dropdown-menu .text-dark,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .text-dark,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .text-dark,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .text-dark,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .text-dark,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .text-dark,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .text-dark,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .text-dark,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .text-dark,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .text-dark {
    color: #FFFFFF !important;
}

/* Textos Secundários / Muted em TODOS os temas (incluindo Modo Claro) */
.top-navbar .dropdown-menu .text-secondary,
.top-navbar .dropdown-menu .text-muted,
.top-navbar .user-dropdown-card .text-secondary,
.top-navbar .user-dropdown-card .text-muted,
[data-bs-theme="light"] .top-navbar .dropdown-menu .text-secondary,
[data-bs-theme="light"] .top-navbar .dropdown-menu .text-muted,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .text-secondary,
[data-bs-theme="light"] .top-navbar .user-dropdown-card .text-muted,
[data-theme-setting="light"] .top-navbar .dropdown-menu .text-secondary,
[data-theme-setting="light"] .top-navbar .dropdown-menu .text-muted,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .text-secondary,
[data-theme-setting="light"] .top-navbar .user-dropdown-card .text-muted,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .text-secondary,
[data-bs-theme="dark"] .top-navbar .dropdown-menu .text-muted,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .text-secondary,
[data-bs-theme="dark"] .top-navbar .user-dropdown-card .text-muted,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .text-secondary,
[data-theme-setting="dark"] .top-navbar .dropdown-menu .text-muted,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .text-secondary,
[data-theme-setting="dark"] .top-navbar .user-dropdown-card .text-muted,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .text-secondary,
[data-theme-setting="blue"] .top-navbar .dropdown-menu .text-muted,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .text-secondary,
[data-theme-setting="blue"] .top-navbar .user-dropdown-card .text-muted,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .text-secondary,
[data-theme-setting="gray"] .top-navbar .dropdown-menu .text-muted,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .text-secondary,
[data-theme-setting="gray"] .top-navbar .user-dropdown-card .text-muted {
    color: #94A3B8 !important;
}

/* Código de Login */
.top-navbar .user-dropdown-card code.text-primary,
[data-bs-theme="light"] .top-navbar .user-dropdown-card code.text-primary,
[data-theme-setting="light"] .top-navbar .user-dropdown-card code.text-primary {
    color: #38BDF8 !important;
    background-color: rgba(56, 189, 248, 0.12) !important;
    padding: 2px 6px;
    border-radius: 4px;
}

/* Botões de Seleção de Tema no Menu de Usuário */
.top-navbar .user-dropdown-card .theme-choice-btn {
    height: 24px !important;
    min-width: 40px !important;
    padding: 0 12px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    border-color: #334155 !important;
    background-color: #1E293B !important;
    color: #E2E8F0 !important;
    line-height: 1 !important;
    transition: all 0.15s ease-in-out;
}

.top-navbar .user-dropdown-card .theme-choice-btn i {
    font-size: 0.72rem !important;
    line-height: 1 !important;
    display: inline-block;
}

.top-navbar .user-dropdown-card .theme-choice-btn:hover {
    background-color: #334155 !important;
    color: #FFFFFF !important;
}

.top-navbar .user-dropdown-card .theme-choice-btn.active {
    background-color: #334155 !important;
    border-color: #38BDF8 !important;
    box-shadow: inset 0 0 0 1px #38BDF8 !important;
    color: #FFFFFF !important;
}

/* ========================================================
   SIDEBAR: MANTÉM ESTILO PADRÃO (MENOS O SIDEBAR)
   ======================================================== */
[data-theme-setting="blue"] .app-sidebar,
[data-nav-style="blue"] .app-sidebar {
    background-color: #334155 !important;
    border-right: 1px solid #1e293b !important;
}

[data-theme-setting="blue"] .sidebar-user-brief,
[data-nav-style="blue"] .sidebar-user-brief {
    background: rgba(15, 23, 42, 0.22) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
}

[data-theme-setting="blue"] .sidebar-nav .nav-link,
[data-nav-style="blue"] .sidebar-nav .nav-link {
    color: #e2e8f0 !important;
    background-color: transparent !important;
}

[data-theme-setting="blue"] .sidebar-nav .nav-link:hover,
[data-nav-style="blue"] .sidebar-nav .nav-link:hover {
    color: #ffffff !important;
    background-color: rgba(255, 255, 255, 0.09) !important;
}

[data-theme-setting="blue"] .sidebar-nav .nav-icon-wrapper,
[data-nav-style="blue"] .sidebar-nav .nav-icon-wrapper {
    color: #94a3b8 !important;
    background: transparent !important;
}

[data-theme-setting="blue"] .sidebar-nav .nav-link:hover .nav-icon-wrapper,
[data-nav-style="blue"] .sidebar-nav .nav-link:hover .nav-icon-wrapper {
    color: #38bdf8 !important;
}

[data-theme-setting="blue"] .sidebar-nav .nav-link.active,
[data-nav-style="blue"] .sidebar-nav .nav-link.active {
    color: #ffffff !important;
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
    box-shadow: 0 4px 12px rgba(37, 99, 235, 0.35) !important;
    border-left: none !important;
}

[data-theme-setting="blue"] .sidebar-nav .nav-link.active .nav-icon-wrapper,
[data-nav-style="blue"] .sidebar-nav .nav-link.active .nav-icon-wrapper {
    color: #ffffff !important;
    background: transparent !important;
    box-shadow: none !important;
}

[data-theme-setting="blue"] .sidebar-footer,
[data-nav-style="blue"] .sidebar-footer {
    background-color: rgba(15, 23, 42, 0.22) !important;
    border-top: 1px solid rgba(255, 255, 255, 0.08) !important;
}

/* ========================================================
   APLICAÇÃO DO TEMA DARK BLUE - FUNDO DA PÁGINA #f8fafc
   ======================================================== */
[data-theme-setting="blue"] body.app-body,
[data-theme-setting="blue"] .app-wrapper,
[data-theme-setting="blue"] .app-content,
[data-theme-setting="blue"] #mainContent,
[data-nav-style="blue"] body.app-body,
[data-nav-style="blue"] .app-wrapper,
[data-nav-style="blue"] .app-content,
[data-nav-style="blue"] #mainContent {
    background-color: #f8fafc !important;
    color: #334155;
}

/* Cabeçalho Fixo */
[data-theme-setting="blue"] .page-header-sticky {
    background-color: rgba(11, 22, 51, 0.92) !important;
    backdrop-filter: blur(8px) !important;
    border-bottom: 1px solid #1d3368 !important;
    color: #ffffff !important;
}
[data-theme-setting="blue"] .page-header-sticky h1,
[data-theme-setting="blue"] .page-header-sticky h2,
[data-theme-setting="blue"] .page-header-sticky h3,
[data-theme-setting="blue"] .page-header-sticky .text-dark {
    color: #ffffff !important;
}

/* Painéis e Cards */
[data-theme-setting="blue"] .card,
[data-theme-setting="blue"] .kpi-card {
    background-color: #0e1b3d !important;
    border: 1px solid #1d3368 !important;
    color: #f1f5f9 !important;
    box-shadow: 0 4px 16px rgba(4, 10, 30, 0.5) !important;
}

[data-theme-setting="blue"] .card-header,
[data-theme-setting="blue"] .card-header.bg-white,
[data-theme-setting="blue"] .card-header.bg-light {
    background-color: #0b1633 !important;
    border-bottom: 1px solid #1d3368 !important;
    color: #ffffff !important;
}

[data-theme-setting="blue"] .card-footer {
    background-color: #0b1633 !important;
    border-top: 1px solid #1d3368 !important;
    color: #94a3b8 !important;
}

[data-theme-setting="blue"] .kpi-icon-wrapper {
    background-color: rgba(30, 58, 138, 0.45) !important;
    color: #60a5fa !important;
}

/* Textos e Rótulos nos Painéis */
[data-theme-setting="blue"] h1, [data-theme-setting="blue"] h2,
[data-theme-setting="blue"] h3, [data-theme-setting="blue"] h4,
[data-theme-setting="blue"] h5, [data-theme-setting="blue"] h6,
[data-theme-setting="blue"] .h1, [data-theme-setting="blue"] .h2,
[data-theme-setting="blue"] .h3, [data-theme-setting="blue"] .h4,
[data-theme-setting="blue"] .h5, [data-theme-setting="blue"] .h6,
[data-theme-setting="blue"] .text-dark,
[data-theme-setting="blue"] * .text-dark {
    color: #ffffff !important;
}

[data-theme-setting="blue"] .text-muted,
[data-theme-setting="blue"] * .text-muted,
[data-theme-setting="blue"] small.text-muted {
    color: #93c5fd !important;
}

[data-theme-setting="blue"] .text-secondary,
[data-theme-setting="blue"] * .text-secondary {
    color: #bfdbfe !important;
}

[data-theme-setting="blue"] label,
[data-theme-setting="blue"] .form-label,
[data-theme-setting="blue"] .form-check-label {
    color: #cbd5e1 !important;
}

/* Tabelas nos Painéis */
[data-theme-setting="blue"] .table {
    --bs-table-bg: #0e1b3d !important;
    --bs-table-color: #f1f5f9 !important;
    --bs-table-border-color: #1d3368 !important;
    color: #f1f5f9 !important;
}

[data-theme-setting="blue"] .table thead,
[data-theme-setting="blue"] .table thead th,
[data-theme-setting="blue"] .table-light {
    background-color: #0b1633 !important;
    color: #93c5fd !important;
    border-bottom: 1px solid #1d3368 !important;
}

[data-theme-setting="blue"] .table tbody tr:hover > * {
    --bs-table-hover-bg: #152754 !important;
    color: #ffffff !important;
}

[data-theme-setting="blue"] .table td,
[data-theme-setting="blue"] .table th {
    border-color: #1d3368 !important;
}

/* Formulários nos Painéis */
[data-theme-setting="blue"] .form-control,
[data-theme-setting="blue"] .form-select {
    background-color: #0b1633 !important;
    border: 1px solid #1d3368 !important;
    color: #ffffff !important;
}

[data-theme-setting="blue"] .form-control:focus,
[data-theme-setting="blue"] .form-select:focus {
    background-color: #0e1b3d !important;
    border-color: #3b82f6 !important;
    color: #ffffff !important;
    box-shadow: 0 0 0 0.25rem rgba(59, 130, 246, 0.25) !important;
}

[data-theme-setting="blue"] .input-group-text {
    background-color: #0b1633 !important;
    border: 1px solid #1d3368 !important;
    color: #93c5fd !important;
}

/* Modais e Dropdowns */
[data-theme-setting="blue"] .modal-content,
[data-theme-setting="blue"] .dropdown-menu,
[data-theme-setting="blue"] .user-dropdown-card {
    background-color: #0e1b3d !important;
    border: 1px solid #1d3368 !important;
    color: #f1f5f9 !important;
    box-shadow: 0 10px 25px rgba(2, 6, 23, 0.6) !important;
}

[data-theme-setting="blue"] .modal-header,
[data-theme-setting="blue"] .modal-footer {
    background-color: #0b1633 !important;
    border-color: #1d3368 !important;
}

[data-theme-setting="blue"] .dropdown-item {
    color: #e2e8f0 !important;
}

[data-theme-setting="blue"] .dropdown-item:hover,
[data-theme-setting="blue"] .dropdown-item:focus {
    background-color: #152754 !important;
    color: #ffffff !important;
}

[data-theme-setting="blue"] .dropdown-divider {
    border-color: #1d3368 !important;
}

/* ========================================================
   ABAS DA TELA DE CHAMADOS & NAV-PILLS (ALTO CONTRASTE)
   Suporte aprimorado para telas Azuis e Escuras (Dark Mode)
   ======================================================== */
.tickets-nav-pills,
.nav-pills.tickets-nav-pills {
    display: flex;
    flex-wrap: wrap;
    gap: 0.6rem;
    margin-bottom: 1.25rem;
    padding: 0.25rem 0;
}

.tickets-nav-pills .nav-link {
    display: inline-flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.6rem 1.15rem;
    border-radius: 0.75rem;
    font-size: 0.88rem;
    font-weight: 600;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    background-color: #ffffff;
    color: #334155;
    border: 1px solid #cbd5e1;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.tickets-nav-pills .nav-link:hover {
    background-color: #f8fafc;
    color: #0f172a;
    border-color: #94a3b8;
    transform: translateY(-1px);
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.08);
}

.tickets-nav-pills .nav-link.active {
    background: linear-gradient(135deg, #0284c7 0%, #0369a1 100%) !important;
    color: #ffffff !important;
    border: 1px solid #0284c7 !important;
    box-shadow: 0 4px 12px rgba(2, 132, 199, 0.35) !important;
}

.tickets-nav-pills .nav-link.active i {
    color: #ffffff !important;
}

.tickets-nav-pills .nav-link.active .badge,
.tickets-nav-pills .nav-link.active .ticket-badge {
    background-color: #ffffff !important;
    color: #0369a1 !important;
    border: none !important;
    font-weight: 800 !important;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2) !important;
}

/* Badges padrão (tema claro) */
.tickets-nav-pills .nav-link:not(.active) .ticket-badge-total {
    background-color: #f1f5f9;
    color: #475569;
    border: 1px solid #cbd5e1;
    font-weight: 700;
}
.tickets-nav-pills .nav-link:not(.active) .ticket-badge-aguardando {
    background-color: #fef3c7;
    color: #92400e;
    border: 1px solid #fde68a;
    font-weight: 700;
}
.tickets-nav-pills .nav-link:not(.active) .ticket-badge-atendimento {
    background-color: #e0f2fe;
    color: #0369a1;
    border: 1px solid #bae6fd;
    font-weight: 700;
}
.tickets-nav-pills .nav-link:not(.active) .ticket-badge-meus {
    background-color: #ede9fe;
    color: #6d28d9;
    border: 1px solid #ddd6fe;
    font-weight: 700;
}
.tickets-nav-pills .nav-link:not(.active) .ticket-badge-concluido {
    background-color: #dcfce7;
    color: #166534;
    border: 1px solid #bbf7d0;
    font-weight: 700;
}

/* --------------------------------------------------------
   CONTRASTE NO TEMA ESCURO (DARK MODE / TELA ESCURA)
   -------------------------------------------------------- */
[data-bs-theme="dark"] .tickets-nav-pills .nav-link:not(.active),
[data-theme-setting="dark"] .tickets-nav-pills .nav-link:not(.active) {
    background-color: #1e293b !important;
    border: 1.5px solid #475569 !important;
    color: #ffffff !important;
    font-weight: 700 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35) !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link:not(.active) i,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link:not(.active) i {
    color: #60a5fa !important;
    font-size: 1.05rem !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link:not(.active):hover,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link:not(.active):hover {
    background-color: #334155 !important;
    border-color: #93c5fd !important;
    color: #ffffff !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.5) !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link:not(.active):hover i,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link:not(.active):hover i {
    color: #93c5fd !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link.active,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link.active {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%) !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    border: 2px solid #93c5fd !important;
    box-shadow: 0 4px 18px rgba(37, 99, 235, 0.6) !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link.active i,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link.active i {
    color: #ffffff !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link.active .badge,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link.active .ticket-badge {
    background-color: #ffffff !important;
    color: #1e3a8a !important;
    border: none !important;
    font-weight: 800 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3) !important;
}

/* Badges nas abas inativas sob tema escuro */
[data-bs-theme="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-total,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-total {
    background-color: #334155 !important;
    color: #ffffff !important;
    border: 1px solid #64748b !important;
    font-weight: 700 !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-aguardando,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-aguardando {
    background-color: #f59e0b !important;
    color: #000000 !important;
    border: 1px solid #d97706 !important;
    font-weight: 800 !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-atendimento,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-atendimento {
    background-color: #06b6d4 !important;
    color: #000000 !important;
    border: 1px solid #0891b2 !important;
    font-weight: 800 !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-meus,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-meus {
    background-color: #8b5cf6 !important;
    color: #ffffff !important;
    border: 1px solid #7c3aed !important;
    font-weight: 800 !important;
}

[data-bs-theme="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-concluido,
[data-theme-setting="dark"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-concluido {
    background-color: #10b981 !important;
    color: #ffffff !important;
    border: 1px solid #059669 !important;
    font-weight: 800 !important;
}

/* --------------------------------------------------------
   CONTRASTE NO TEMA AZUL (BLUE THEME / TELA AZUL)
   -------------------------------------------------------- */
[data-theme-setting="blue"] .tickets-nav-pills .nav-link:not(.active),
[data-nav-style="blue"] .tickets-nav-pills .nav-link:not(.active) {
    background-color: #ffffff !important;
    border: 2px solid #93c5fd !important;
    color: #0f172a !important;
    font-weight: 700 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08) !important;
}

[data-theme-setting="blue"] .tickets-nav-pills .nav-link:not(.active) i,
[data-nav-style="blue"] .tickets-nav-pills .nav-link:not(.active) i {
    color: #2563eb !important;
    font-size: 1.05rem !important;
}

[data-theme-setting="blue"] .tickets-nav-pills .nav-link:not(.active):hover,
[data-nav-style="blue"] .tickets-nav-pills .nav-link:not(.active):hover {
    background-color: #eff6ff !important;
    border-color: #2563eb !important;
    color: #1d4ed8 !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 10px rgba(37, 99, 235, 0.2) !important;
}

[data-theme-setting="blue"] .tickets-nav-pills .nav-link.active,
[data-nav-style="blue"] .tickets-nav-pills .nav-link.active {
    background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 100%) !important;
    color: #ffffff !important;
    font-weight: 800 !important;
    border: 2px solid #38bdf8 !important;
    box-shadow: 0 4px 16px rgba(15, 23, 42, 0.45) !important;
}

[data-theme-setting="blue"] .tickets-nav-pills .nav-link.active i,
[data-nav-style="blue"] .tickets-nav-pills .nav-link.active i {
    color: #38bdf8 !important;
}

[data-theme-setting="blue"] .tickets-nav-pills .nav-link.active .badge,
[data-nav-style="blue"] .tickets-nav-pills .nav-link.active .ticket-badge {
    background-color: #38bdf8 !important;
    color: #0f172a !important;
    border: none !important;
    font-weight: 800 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25) !important;
}

/* Badges nas abas inativas sob tema azul */
[data-theme-setting="blue"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-total,
[data-nav-style="blue"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-total {
    background-color: #dbeafe !important;
    color: #1e40af !important;
    border: 1px solid #93c5fd !important;
    font-weight: 700 !important;
}

[data-theme-setting="blue"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-aguardando,
[data-nav-style="blue"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-aguardando {
    background-color: #fef3c7 !important;
    color: #92400e !important;
    border: 1px solid #fde68a !important;
    font-weight: 800 !important;
}

[data-theme-setting="blue"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-atendimento,
[data-nav-style="blue"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-atendimento {
    background-color: #e0f2fe !important;
    color: #0369a1 !important;
    border: 1px solid #bae6fd !important;
    font-weight: 800 !important;
}

[data-theme-setting="blue"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-concluido,
[data-nav-style="blue"] .tickets-nav-pills .nav-link:not(.active) .ticket-badge-concluido {
    background-color: #dcfce7 !important;
    color: #166534 !important;
    border: 1px solid #bbf7d0 !important;
    font-weight: 800 !important;
}

/* ========================================================
   ABAS DE CHAMADOS NO MOBILE (APENAS ÍCONES E QUANTIDADES)
   ======================================================== */
@media (max-width: 767.98px) {
    .tickets-nav-pills {
        gap: 0.35rem !important;
        flex-wrap: wrap !important;
    }
    .tickets-nav-pills .nav-link {
        padding: 0.45rem 0.65rem !important;
        gap: 0.35rem !important;
        font-size: 0.82rem !important;
    }
    .tickets-nav-pills .nav-link .ticket-tab-text,
    .tickets-nav-pills .nav-link > span:not(.badge):not(.ticket-badge) {
        display: none !important;
    }
    .tickets-nav-pills .nav-link .badge,
    .tickets-nav-pills .nav-link .ticket-badge {
        margin-left: 0 !important;
        font-size: 0.72rem !important;
        padding: 0.2em 0.5em !important;
    }
}

/* --- REGRAS GERAIS PARA QUALQUER NAV-PILLS NO MODO ESCURO E AZUL --- */
[data-bs-theme="dark"] .nav-pills:not(.tickets-nav-pills) .nav-link:not(.active),
[data-theme-setting="dark"] .nav-pills:not(.tickets-nav-pills) .nav-link:not(.active) {
    background-color: #1e293b !important;
    border: 1px solid #475569 !important;
    color: #ffffff !important;
}

[data-theme-setting="blue"] .nav-pills:not(.tickets-nav-pills) .nav-link:not(.active),
[data-nav-style="blue"] .nav-pills:not(.tickets-nav-pills) .nav-link:not(.active) {
    background-color: #ffffff !important;
    border: 1.5px solid #93c5fd !important;
    color: #0f172a !important;
}

/* ==========================================================================
   ALTO CONTRASTE CRUD CHAMADOS TPA (CÓDIGO, DEPARTAMENTO E CABEÇALHOS ORDENÁVEIS)
   ========================================================================== */
.ticket-code-badge {
    background-color: #0f172a !important;
    color: #38bdf8 !important;
    font-weight: 700 !important;
    letter-spacing: 0.5px;
    padding: 0.35rem 0.65rem;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    text-decoration: none !important;
    border: 1px solid #334155 !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
    transition: all 0.15s ease-in-out;
}
.ticket-code-badge:hover {
    background-color: #1e293b !important;
    color: #7dd3fc !important;
    border-color: #0284c7 !important;
    box-shadow: 0 2px 6px rgba(56, 189, 248, 0.3);
    transform: translateY(-1px);
}
[data-bs-theme="dark"] .ticket-code-badge,
[data-theme-setting="dark"] .ticket-code-badge {
    background-color: #0284c7 !important;
    color: #ffffff !important;
    border: 1px solid #38bdf8 !important;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4);
}
[data-bs-theme="dark"] .ticket-code-badge:hover,
[data-theme-setting="dark"] .ticket-code-badge:hover {
    background-color: #0369a1 !important;
    color: #ffffff !important;
    box-shadow: 0 2px 8px rgba(56, 189, 248, 0.5);
}
[data-nav-style="blue"] .ticket-code-badge,
[data-theme-setting="blue"] .ticket-code-badge {
    background-color: #0f172a !important;
    color: #38bdf8 !important;
    border: 1px solid #0284c7 !important;
}

/* Badges de Departamentos em Alto Contraste */
.dept-badge-primary {
    background-color: #0284c7 !important;
    color: #ffffff !important;
    border: 1px solid #0369a1 !important;
}
.dept-badge-success {
    background-color: #16a34a !important;
    color: #ffffff !important;
    border: 1px solid #15803d !important;
}
.dept-badge-danger {
    background-color: #dc2626 !important;
    color: #ffffff !important;
    border: 1px solid #b91c1c !important;
}
.dept-badge-default {
    background-color: #475569 !important;
    color: #ffffff !important;
    border: 1px solid #334155 !important;
}
[data-bs-theme="dark"] .dept-badge-primary,
[data-theme-setting="dark"] .dept-badge-primary {
    background-color: #2563eb !important;
    color: #ffffff !important;
    border-color: #60a5fa !important;
}
[data-bs-theme="dark"] .dept-badge-success,
[data-theme-setting="dark"] .dept-badge-success {
    background-color: #16a34a !important;
    color: #ffffff !important;
    border-color: #4ade80 !important;
}
[data-bs-theme="dark"] .dept-badge-danger,
[data-theme-setting="dark"] .dept-badge-danger {
    background-color: #dc2626 !important;
    color: #ffffff !important;
    border-color: #f87171 !important;
}

/* Ordenação por clique nas colunas */
.sort-header {
    cursor: pointer;
    user-select: none;
    transition: color 0.15s ease-in-out;
}
.sort-header:hover {
    color: #0d6efd !important;
}
.sort-header:hover i {
    opacity: 1 !important;
}
[data-bs-theme="dark"] .sort-header,
[data-theme-setting="dark"] .sort-header {
    color: #e2e8f0 !important;
}
[data-bs-theme="dark"] .sort-header:hover,
[data-theme-setting="dark"] .sort-header:hover {
    color: #38bdf8 !important;
}

/* ==========================================================================
   COLUNA FIXA: CÓDIGO NO CRUD DE CHAMADOS TPA
   ========================================================================== */
.table-responsive .col-sticky-code {
    position: sticky;
    left: 0;
    z-index: 10;
    background-color: #ffffff !important;
    white-space: nowrap;
    border-right: 1px solid #e2e8f0 !important;
    box-shadow: none !important;
}

.table-responsive thead th.col-sticky-code {
    z-index: 20;
    background-color: #f8f9fa !important;
    border-right: 1px solid #e2e8f0 !important;
    box-shadow: none !important;
}

.table-hover > tbody > tr:hover > td.col-sticky-code {
    background-color: #f8f9fa !important;
}

/* Modo Claro (mesma cor das demais colunas do tema claro) */
[data-bs-theme="light"] .table-responsive .col-sticky-code,
[data-theme-setting="light"] .table-responsive .col-sticky-code,
[data-theme-setting="gray"] .table-responsive .col-sticky-code {
    background-color: #ffffff !important;
    border-right: 1px solid #e2e8f0 !important;
    box-shadow: none !important;
}

[data-bs-theme="light"] .table-responsive thead th.col-sticky-code,
[data-theme-setting="light"] .table-responsive thead th.col-sticky-code,
[data-theme-setting="gray"] .table-responsive thead th.col-sticky-code {
    background-color: #f8f9fa !important;
    border-right: 1px solid #e2e8f0 !important;
    box-shadow: none !important;
}

[data-bs-theme="light"] .table-hover > tbody > tr:hover > td.col-sticky-code,
[data-theme-setting="light"] .table-hover > tbody > tr:hover > td.col-sticky-code,
[data-theme-setting="gray"] .table-hover > tbody > tr:hover > td.col-sticky-code {
    background-color: #f8f9fa !important;
}

/* Modo Escuro */
[data-bs-theme="dark"] .table-responsive .col-sticky-code,
[data-theme-setting="dark"] .table-responsive .col-sticky-code {
    background-color: #0f172a !important;
    border-right-color: #334155 !important;
    box-shadow: 4px 0 10px -2px rgba(0, 0, 0, 0.5);
}

[data-bs-theme="dark"] .table-responsive thead th.col-sticky-code,
[data-theme-setting="dark"] .table-responsive thead th.col-sticky-code {
    background-color: #1e293b !important;
}

[data-bs-theme="dark"] .table-hover > tbody > tr:hover > td.col-sticky-code,
[data-theme-setting="dark"] .table-hover > tbody > tr:hover > td.col-sticky-code {
    background-color: #1e293b !important;
}

/* Modo Dark Blue */
[data-nav-style="blue"] .table-responsive .col-sticky-code,
[data-theme-setting="blue"] .table-responsive .col-sticky-code {
    background-color: #0e1b3d !important;
    border-right-color: #1d3368 !important;
    box-shadow: 4px 0 10px -2px rgba(4, 10, 30, 0.6);
}

[data-nav-style="blue"] .table-responsive thead th.col-sticky-code,
[data-theme-setting="blue"] .table-responsive thead th.col-sticky-code {
    background-color: #0b1633 !important;
}

[data-nav-style="blue"] .table-hover > tbody > tr:hover > td.col-sticky-code,
[data-theme-setting="blue"] .table-hover > tbody > tr:hover > td.col-sticky-code {
    background-color: #152754 !important;
}

/* ========================================================
   PADRONIZAÇÃO DAS FONTES DO HEADER (IGUAIS AO MODO ESCURO)
   ======================================================== */
.top-navbar .company-name,
[data-bs-theme="light"] .top-navbar .company-name,
[data-bs-theme="dark"] .top-navbar .company-name,
[data-theme-setting="gray"] .top-navbar .company-name,
[data-theme-setting="blue"] .top-navbar .company-name,
[data-nav-style="gray"] .top-navbar .company-name,
[data-nav-style="blue"] .top-navbar .company-name {
    color: #ffffff !important;
}

.top-navbar .company-header-badge,
[data-bs-theme="light"] .top-navbar .company-header-badge,
[data-bs-theme="dark"] .top-navbar .company-header-badge,
[data-theme-setting="gray"] .top-navbar .company-header-badge,
[data-theme-setting="blue"] .top-navbar .company-header-badge,
[data-nav-style="gray"] .top-navbar .company-header-badge,
[data-nav-style="blue"] .top-navbar .company-header-badge {
    color: #ffffff !important;
}

.top-navbar #dropdownHelpDeskHeader,
.top-navbar #dropdownHelpDeskHeader span,
[data-bs-theme="light"] .top-navbar #dropdownHelpDeskHeader,
[data-bs-theme="light"] .top-navbar #dropdownHelpDeskHeader span,
[data-bs-theme="dark"] .top-navbar #dropdownHelpDeskHeader,
[data-bs-theme="dark"] .top-navbar #dropdownHelpDeskHeader span,
[data-theme-setting="gray"] .top-navbar #dropdownHelpDeskHeader,
[data-theme-setting="gray"] .top-navbar #dropdownHelpDeskHeader span,
[data-theme-setting="blue"] .top-navbar #dropdownHelpDeskHeader,
[data-theme-setting="blue"] .top-navbar #dropdownHelpDeskHeader span,
[data-nav-style="gray"] .top-navbar #dropdownHelpDeskHeader,
[data-nav-style="gray"] .top-navbar #dropdownHelpDeskHeader span,
[data-nav-style="blue"] .top-navbar #dropdownHelpDeskHeader,
[data-nav-style="blue"] .top-navbar #dropdownHelpDeskHeader span {
    color: #ffffff !important;
}

.top-navbar #dropdownHelpDeskHeader i,
[data-bs-theme="light"] .top-navbar #dropdownHelpDeskHeader i,
[data-bs-theme="dark"] .top-navbar #dropdownHelpDeskHeader i {
    color: #f59e0b !important;
}

.top-navbar #dropdownHelpDeskHeader::after,
[data-bs-theme="light"] .top-navbar #dropdownHelpDeskHeader::after,
[data-bs-theme="dark"] .top-navbar #dropdownHelpDeskHeader::after {
    border-top-color: #ffffff !important;
    color: #ffffff !important;
}

.top-navbar #dropdownHelpDeskHeader:hover,
.top-navbar #dropdownHelpDeskHeader:focus,
.top-navbar #dropdownHelpDeskHeader:active,
.top-navbar #dropdownHelpDeskHeader.show,
[data-bs-theme="light"] .top-navbar #dropdownHelpDeskHeader:hover,
[data-bs-theme="light"] .top-navbar #dropdownHelpDeskHeader:focus,
[data-bs-theme="light"] .top-navbar #dropdownHelpDeskHeader:active,
[data-bs-theme="light"] .top-navbar #dropdownHelpDeskHeader.show {
    color: #ffffff !important;
    background-color: rgba(255, 255, 255, 0.15) !important;
    border-color: rgba(255, 255, 255, 0.35) !important;
}

.top-navbar .btn-user-profile,
[data-bs-theme="light"] .top-navbar .btn-user-profile,
[data-bs-theme="dark"] .top-navbar .btn-user-profile,
[data-theme-setting="gray"] .top-navbar .btn-user-profile,
[data-theme-setting="blue"] .top-navbar .btn-user-profile,
[data-nav-style="gray"] .top-navbar .btn-user-profile,
[data-nav-style="blue"] .top-navbar .btn-user-profile {
    color: #ffffff !important;
}

.top-navbar .btn-user-profile::after,
[data-bs-theme="light"] .top-navbar .btn-user-profile::after,
[data-bs-theme="dark"] .top-navbar .btn-user-profile::after {
    border-top-color: #ffffff !important;
    color: #ffffff !important;
}

.top-navbar .btn-user-profile .user-name-label,
[data-bs-theme="light"] .top-navbar .btn-user-profile .user-name-label,
[data-bs-theme="dark"] .top-navbar .btn-user-profile .user-name-label,
[data-theme-setting="gray"] .top-navbar .btn-user-profile .user-name-label,
[data-theme-setting="blue"] .top-navbar .btn-user-profile .user-name-label,
[data-nav-style="gray"] .top-navbar .btn-user-profile .user-name-label,
[data-nav-style="blue"] .top-navbar .btn-user-profile .user-name-label,
[data-bs-theme="light"] .top-navbar .user-name-label,
[data-bs-theme="dark"] .top-navbar .user-name-label {
    color: #ffffff !important;
}

.top-navbar .btn-user-profile .user-role-label,
[data-bs-theme="light"] .top-navbar .btn-user-profile .user-role-label,
[data-bs-theme="dark"] .top-navbar .btn-user-profile .user-role-label,
[data-theme-setting="gray"] .top-navbar .btn-user-profile .user-role-label,
[data-theme-setting="blue"] .top-navbar .btn-user-profile .user-role-label,
[data-nav-style="gray"] .top-navbar .btn-user-profile .user-role-label,
[data-nav-style="blue"] .top-navbar .btn-user-profile .user-role-label,
[data-bs-theme="light"] .top-navbar .user-role-label,
[data-bs-theme="dark"] .top-navbar .user-role-label {
    color: rgba(255, 255, 255, 0.7) !important;
}

.top-navbar .btn-user-profile:hover,
.top-navbar .btn-user-profile:focus,
.top-navbar .btn-user-profile:active,
.top-navbar .btn-user-profile.show,
[data-bs-theme="light"] .top-navbar .btn-user-profile:hover,
[data-bs-theme="light"] .top-navbar .btn-user-profile:focus,
[data-bs-theme="light"] .top-navbar .btn-user-profile:active,
[data-bs-theme="light"] .top-navbar .btn-user-profile.show {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: rgba(255, 255, 255, 0.25) !important;
}

.top-navbar .btn-user-profile:hover .user-name-label,
.top-navbar .btn-user-profile:focus .user-name-label,
.top-navbar .btn-user-profile.show .user-name-label {
    color: #ffffff !important;
}

.top-navbar .btn-user-profile:hover .user-role-label,
.top-navbar .btn-user-profile:focus .user-role-label,
.top-navbar .btn-user-profile.show .user-role-label {
    color: rgba(255, 255, 255, 0.7) !important;
}

/* ========================================================
   HISTÓRICO DO ATENDIMENTO & MENSAGENS (TIMELINE)
   ======================================================== */
.timeline-section-title,
.movto-section-title {
    color: #000000;
    letter-spacing: -0.01em;
}
.timeline-title-icon {
    color: #000000 !important;
}
.movto-title-icon {
    color: #000000 !important;
}
.timeline-counter-badge {
    background-color: #f1f5f9;
    color: #000000;
    border-color: #cbd5e1;
    font-weight: 600;
}
.timeline-empty-card {
    background-color: #ffffff;
    border: 1px solid #e2e8f0 !important;
}

/* Operação do Atendente */
.timeline-op-card {
    background-color: #f8fafc;
    border: 1px solid #e2e8f0 !important;
    border-left: 4px solid #0ea5e9 !important;
}
.badge-op-attendant {
    background-color: #e0f2fe;
    color: #0369a1;
    border-color: #bae6fd;
}
.timeline-op-user {
    color: #0f172a;
}
.timeline-op-text {
    color: #334155;
}
.timeline-timestamp {
    color: #64748b;
}

/* Mensagens */
.timeline-item-card {
    border: 1px solid #e2e8f0 !important;
}
.timeline-msg-staff {
    background-color: #ffffff;
    border-left: 4px solid #2563eb !important;
}
.badge-staff-msg {
    background-color: #2563eb;
    color: #ffffff;
    border-color: #1d4ed8;
}
.timeline-msg-client {
    background-color: #ffffff;
    border-left: 4px solid #64748b !important;
}
.badge-client-msg {
    background-color: #64748b;
    color: #ffffff;
    border-color: #475569;
}
.timeline-msg-internal {
    background-color: #ffffff;
    border-left: 4px solid #64748b !important;
}
.badge-internal-note {
    background-color: #64748b;
    color: #ffffff;
    border-color: #475569;
}
.timeline-msg-header {
    background-color: transparent;
    border-bottom: 1px solid #f1f5f9;
}
.timeline-msg-author {
    color: #0f172a;
}
.timeline-msg-text {
    color: #1e293b;
}
.timeline-attachments-border {
    border-color: #f1f5f9 !important;
}
.timeline-attachments-label {
    color: #64748b;
}
.timeline-attachment-pill {
    background-color: #f8fafc;
    color: #0284c7;
    border-color: #e2e8f0;
}
.timeline-attachment-pill:hover {
    background-color: #f1f5f9;
    color: #0369a1;
}
.internal-note-box {
    background-color: #f8fafc;
    border-color: #e2e8f0 !important;
}
.internal-note-box-label {
    color: #1e293b;
}

/* ========================================================
   TÍTULOS DO HISTÓRICO E LINHA DO TEMPO
   ======================================================== */
.timeline-section-title,
.movto-section-title {
    color: #0f172a;
    letter-spacing: -0.01em;
}

.timeline-title-icon,
.movto-title-icon,
.timeline-section-title i,
.movto-section-title i {
    color: #2563eb;
}

.timeline-counter-badge {
    background-color: #f1f5f9;
    color: #334155;
    border-color: #cbd5e1;
    font-weight: 600;
}

/* MODO ESCURO E TEMA BLUE - ALTO CONTRASTE */
[data-bs-theme="dark"] .timeline-section-title,
[data-theme-setting="dark"] .timeline-section-title,
[data-theme-setting="blue"] .timeline-section-title,
[data-nav-style="blue"] .timeline-section-title,
[data-theme="dark"] .timeline-section-title,
.dark .timeline-section-title,
html[data-theme-setting="blue"] .timeline-section-title,
html[data-nav-style="blue"] .timeline-section-title,
[data-bs-theme="dark"] .movto-section-title,
[data-theme-setting="dark"] .movto-section-title,
[data-theme-setting="blue"] .movto-section-title,
[data-nav-style="blue"] .movto-section-title,
[data-theme="dark"] .movto-section-title,
.dark .movto-section-title,
html[data-theme-setting="blue"] .movto-section-title,
html[data-nav-style="blue"] .movto-section-title {
    color: #ffffff !important;
    letter-spacing: -0.01em;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.7) !important;
}

[data-bs-theme="dark"] .timeline-title-icon,
[data-theme-setting="dark"] .timeline-title-icon,
[data-theme-setting="blue"] .timeline-title-icon,
[data-nav-style="blue"] .timeline-title-icon,
[data-theme="dark"] .timeline-title-icon,
.dark .timeline-title-icon,
html[data-theme-setting="blue"] .timeline-title-icon,
html[data-nav-style="blue"] .timeline-title-icon,
[data-bs-theme="dark"] .timeline-section-title i,
[data-theme-setting="dark"] .timeline-section-title i,
[data-theme-setting="blue"] .timeline-section-title i,
[data-nav-style="blue"] .timeline-section-title i,
[data-theme="dark"] .timeline-section-title i,
.dark .timeline-section-title i,
html[data-theme-setting="blue"] .timeline-section-title i,
html[data-nav-style="blue"] .timeline-section-title i,
[data-bs-theme="dark"] .movto-title-icon,
[data-theme-setting="dark"] .movto-title-icon,
[data-theme-setting="blue"] .movto-title-icon,
[data-nav-style="blue"] .movto-title-icon,
[data-theme="dark"] .movto-title-icon,
.dark .movto-title-icon,
html[data-theme-setting="blue"] .movto-title-icon,
html[data-nav-style="blue"] .movto-title-icon,
[data-bs-theme="dark"] .movto-section-title i,
[data-theme-setting="dark"] .movto-section-title i,
[data-theme-setting="blue"] .movto-section-title i,
[data-nav-style="blue"] .movto-section-title i,
[data-theme="dark"] .movto-section-title i,
.dark .movto-section-title i,
html[data-theme-setting="blue"] .movto-section-title i,
html[data-nav-style="blue"] .movto-section-title i {
    color: #38bdf8 !important;
    filter: drop-shadow(0 0 6px rgba(56, 189, 248, 0.45)) !important;
}

[data-bs-theme="dark"] .timeline-counter-badge,
[data-theme-setting="dark"] .timeline-counter-badge,
[data-theme-setting="blue"] .timeline-counter-badge,
[data-nav-style="blue"] .timeline-counter-badge,
[data-theme="dark"] .timeline-counter-badge,
.dark .timeline-counter-badge,
html[data-theme-setting="blue"] .timeline-counter-badge,
html[data-nav-style="blue"] .timeline-counter-badge {
    background-color: rgba(30, 41, 59, 0.85) !important;
    color: #f8fafc !important;
    border-color: #334155 !important;
    font-weight: 600;
}
[data-bs-theme="dark"] .timeline-empty-card,
[data-theme-setting="dark"] .timeline-empty-card,
[data-theme-setting="blue"] .timeline-empty-card {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    color: #94a3b8 !important;
}

/* Operação do Atendente no Tema Escuro */
[data-bs-theme="dark"] .timeline-op-card,
[data-theme-setting="dark"] .timeline-op-card,
[data-theme-setting="blue"] .timeline-op-card {
    background-color: #0f172a !important;
    border: 1px solid #1e293b !important;
    border-left: 4px solid #38bdf8 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.3) !important;
}
[data-bs-theme="dark"] .badge-op-attendant,
[data-theme-setting="dark"] .badge-op-attendant,
[data-theme-setting="blue"] .badge-op-attendant {
    background-color: rgba(14, 165, 233, 0.15) !important;
    color: #38bdf8 !important;
    border-color: rgba(14, 165, 233, 0.35) !important;
}
[data-bs-theme="dark"] .timeline-op-user,
[data-theme-setting="dark"] .timeline-op-user,
[data-theme-setting="blue"] .timeline-op-user {
    color: #f8fafc !important;
}
[data-bs-theme="dark"] .timeline-op-text,
[data-theme-setting="dark"] .timeline-op-text,
[data-theme-setting="blue"] .timeline-op-text {
    color: #cbd5e1 !important;
}
[data-bs-theme="dark"] .timeline-timestamp,
[data-theme-setting="dark"] .timeline-timestamp,
[data-theme-setting="blue"] .timeline-timestamp {
    color: #94a3b8 !important;
}

/* Mensagens no Tema Escuro */
[data-bs-theme="dark"] .timeline-item-card,
[data-theme-setting="dark"] .timeline-item-card,
[data-theme-setting="blue"] .timeline-item-card {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35) !important;
}
[data-bs-theme="dark"] .timeline-msg-staff,
[data-theme-setting="dark"] .timeline-msg-staff,
[data-theme-setting="blue"] .timeline-msg-staff {
    background-color: #1e293b !important;
    border: 1px solid #334155 !important;
    border-left: 4px solid #3b82f6 !important;
}
[data-bs-theme="dark"] .timeline-msg-client,
[data-theme-setting="dark"] .timeline-msg-client,
[data-theme-setting="blue"] .timeline-msg-client {
    background-color: #1e293b !important;
    border: 1px solid #334155 !important;
    border-left: 4px solid #64748b !important;
}
[data-bs-theme="dark"] .timeline-msg-internal,
[data-theme-setting="dark"] .timeline-msg-internal,
[data-theme-setting="blue"] .timeline-msg-internal {
    background-color: #1e293b !important;
    border: 1px solid #334155 !important;
    border-left: 4px solid #64748b !important;
}
[data-bs-theme="dark"] .badge-internal-note,
[data-theme-setting="dark"] .badge-internal-note,
[data-theme-setting="blue"] .badge-internal-note {
    background-color: #334155 !important;
    color: #e2e8f0 !important;
    border-color: #475569 !important;
}
[data-bs-theme="dark"] .badge-staff-msg,
[data-theme-setting="dark"] .badge-staff-msg,
[data-theme-setting="blue"] .badge-staff-msg {
    background-color: #2563eb !important;
    color: #ffffff !important;
    border-color: #1d4ed8 !important;
}
[data-bs-theme="dark"] .badge-client-msg,
[data-theme-setting="dark"] .badge-client-msg,
[data-theme-setting="blue"] .badge-client-msg {
    background-color: #334155 !important;
    color: #e2e8f0 !important;
    border-color: #475569 !important;
}
[data-bs-theme="dark"] .timeline-msg-header,
[data-theme-setting="dark"] .timeline-msg-header,
[data-theme-setting="blue"] .timeline-msg-header {
    background-color: rgba(15, 23, 42, 0.4) !important;
    border-bottom: 1px solid #334155 !important;
}
[data-bs-theme="dark"] .timeline-msg-author,
[data-theme-setting="dark"] .timeline-msg-author,
[data-theme-setting="blue"] .timeline-msg-author {
    color: #f8fafc !important;
}
[data-bs-theme="dark"] .timeline-msg-text,
[data-theme-setting="dark"] .timeline-msg-text,
[data-theme-setting="blue"] .timeline-msg-text {
    color: #f1f5f9 !important;
}
[data-bs-theme="dark"] .timeline-attachments-border,
[data-theme-setting="dark"] .timeline-attachments-border,
[data-theme-setting="blue"] .timeline-attachments-border {
    border-color: #334155 !important;
}
[data-bs-theme="dark"] .timeline-attachments-label,
[data-theme-setting="dark"] .timeline-attachments-label,
[data-theme-setting="blue"] .timeline-attachments-label {
    color: #94a3b8 !important;
}
[data-bs-theme="dark"] .timeline-attachment-pill,
[data-theme-setting="dark"] .timeline-attachment-pill,
[data-theme-setting="blue"] .timeline-attachment-pill {
    background-color: #0f172a !important;
    color: #60a5fa !important;
    border-color: #334155 !important;
}
[data-bs-theme="dark"] .timeline-attachment-pill:hover,
[data-theme-setting="dark"] .timeline-attachment-pill:hover,
[data-theme-setting="blue"] .timeline-attachment-pill:hover {
    background-color: #1e293b !important;
    color: #93c5fd !important;
    border-color: #475569 !important;
}

/* Card de Descrição & Formulário de Resposta no Modo Escuro */
[data-bs-theme="dark"] .ticket-description-card,
[data-theme-setting="dark"] .ticket-description-card,
[data-theme-setting="blue"] .ticket-description-card {
    background-color: #1e293b !important;
    border-color: #334155 !important;
}
[data-bs-theme="dark"] .ticket-description-card-header,
[data-theme-setting="dark"] .ticket-description-card-header,
[data-theme-setting="blue"] .ticket-description-card-header {
    background-color: #1e293b !important;
    border-bottom-color: #334155 !important;
}
[data-bs-theme="dark"] .ticket-description-header-title,
[data-theme-setting="dark"] .ticket-description-header-title,
[data-theme-setting="blue"] .ticket-description-header-title,
[data-nav-style="blue"] .ticket-description-header-title {
    color: #ffffff !important;
}
[data-bs-theme="dark"] .ticket-description-body,
[data-theme-setting="dark"] .ticket-description-body,
[data-theme-setting="blue"] .ticket-description-body,
[data-nav-style="blue"] .ticket-description-body {
    background-color: #0f172a !important;
    color: #ffffff !important;
}
[data-bs-theme="dark"] .ticket-description-content,
[data-bs-theme="dark"] .ticket-description-content *,
[data-theme-setting="dark"] .ticket-description-content,
[data-theme-setting="dark"] .ticket-description-content *,
[data-theme-setting="blue"] .ticket-description-content,
[data-theme-setting="blue"] .ticket-description-content *,
[data-nav-style="blue"] .ticket-description-content,
[data-nav-style="blue"] .ticket-description-content * {
    color: #ffffff !important;
}
[data-bs-theme="dark"] .ticket-description-content a,
[data-theme-setting="dark"] .ticket-description-content a,
[data-theme-setting="blue"] .ticket-description-content a,
[data-nav-style="blue"] .ticket-description-content a {
    color: #38bdf8 !important;
}

[data-bs-theme="dark"] #replyFormCard,
[data-theme-setting="dark"] #replyFormCard,
[data-theme-setting="blue"] #replyFormCard {
    background-color: #1e293b !important;
    border-color: #334155 !important;
}
[data-bs-theme="dark"] .reply-card-header,
[data-theme-setting="dark"] .reply-card-header,
[data-theme-setting="blue"] .reply-card-header {
    background-color: #1e293b !important;
    border-bottom-color: #334155 !important;
}
[data-bs-theme="dark"] .reply-card-title,
[data-theme-setting="dark"] .reply-card-title,
[data-theme-setting="blue"] .reply-card-title {
    color: #ffffff !important;
}

[data-bs-theme="dark"] .movto-card,
[data-theme-setting="dark"] .movto-card,
[data-theme-setting="blue"] .movto-card {
    background-color: #1e293b !important;
    border-color: #334155 !important;
}
[data-bs-theme="dark"] .movto-card-header,
[data-theme-setting="dark"] .movto-card-header,
[data-theme-setting="blue"] .movto-card-header {
    background-color: #1e293b !important;
    border-bottom-color: #334155 !important;
}
[data-bs-theme="dark"] .movto-title,
[data-theme-setting="dark"] .movto-title,
[data-theme-setting="blue"] .movto-title {
    color: #f8fafc !important;
}
[data-bs-theme="dark"] .movto-item,
[data-theme-setting="dark"] .movto-item,
[data-theme-setting="blue"] .movto-item {
    border-color: #334155 !important;
}
[data-bs-theme="dark"] .movto-item-title,
[data-theme-setting="dark"] .movto-item-title,
[data-theme-setting="blue"] .movto-item-title {
    color: #f1f5f9 !important;
}

[data-bs-theme="dark"] .internal-note-box,
[data-theme-setting="dark"] .internal-note-box,
[data-theme-setting="blue"] .internal-note-box {
    background-color: rgba(245, 158, 11, 0.08) !important;
    border-color: rgba(245, 158, 11, 0.25) !important;
}
[data-bs-theme="dark"] .internal-note-box-label,
[data-theme-setting="dark"] .internal-note-box-label,
[data-theme-setting="blue"] .internal-note-box-label {
    color: #fef08a !important;
}

[data-bs-theme="dark"] .movto-card .list-group-item,
[data-theme-setting="dark"] .movto-card .list-group-item,
[data-theme-setting="blue"] .movto-card .list-group-item {
    background-color: transparent !important;
    border-color: #334155 !important;
    color: #f1f5f9 !important;
}

/* ========================================================
   ESTILOS DO QUADRO KANBAN
   ======================================================== */
.tickets-kanban-board {
    margin-top: 0.5rem;
}
.kanban-column {
    background-color: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    min-height: 540px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}
.kanban-column-header {
    background-color: #ffffff;
    border-bottom: 1px solid #e2e8f0;
    border-top-left-radius: 11px;
    border-top-right-radius: 11px;
}
.kanban-col-aguardando .kanban-column-header {
    border-top: 4px solid #f59e0b;
}
.kanban-col-atendimento .kanban-column-header {
    border-top: 4px solid #2563eb;
}
.kanban-col-concluido .kanban-column-header {
    border-top: 4px solid #10b981;
}

.kanban-status-indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    display: inline-block;
}
.kanban-badge-aguardando {
    background-color: #fef3c7;
    color: #92400e;
    border: 1px solid #fde68a;
    font-weight: 600;
}
.kanban-badge-atendimento {
    background-color: #dbeafe;
    color: #1e40af;
    border: 1px solid #bfdbfe;
    font-weight: 600;
}
.kanban-badge-concluido {
    background-color: #d1fae5;
    color: #065f46;
    border: 1px solid #a7f3d0;
    font-weight: 600;
}

.kanban-column-body {
    min-height: 460px;
    max-height: calc(100vh - 290px);
    overflow-y: auto;
    flex: 1;
    transition: background-color 0.2s ease, border-color 0.2s ease;
}
.kanban-column-body::-webkit-scrollbar {
    width: 6px;
}
.kanban-column-body::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

.kanban-col-dragover {
    background-color: rgba(37, 99, 235, 0.08) !important;
    outline: 2px dashed #3b82f6 !important;
    outline-offset: -4px;
    border-radius: 8px;
}

.kanban-card {
    background-color: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    cursor: grab;
    transition: transform 0.15s ease, box-shadow 0.15s ease, opacity 0.15s ease;
}
.kanban-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.08) !important;
}
.kanban-card:active {
    cursor: grabbing;
}
.kanban-card-dragging {
    opacity: 0.4;
    transform: scale(0.98);
}
.kanban-card-title a {
    color: #0f172a;
    transition: color 0.15s;
}
.kanban-card-title a:hover {
    color: #2563eb;
}
.kanban-card-footer {
    border-top: 1px solid #f1f5f9;
}

/* Modo Escuro Kanban */
[data-bs-theme="dark"] .kanban-column,
[data-theme-setting="dark"] .kanban-column,
[data-theme-setting="blue"] .kanban-column {
    background-color: #0f172a !important;
    border-color: #334155 !important;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.4) !important;
}
[data-bs-theme="dark"] .kanban-column-header,
[data-theme-setting="dark"] .kanban-column-header,
[data-theme-setting="blue"] .kanban-column-header {
    background-color: #1e293b !important;
    border-bottom-color: #334155 !important;
}
[data-bs-theme="dark"] .kanban-column-title,
[data-theme-setting="dark"] .kanban-column-title,
[data-theme-setting="blue"] .kanban-column-title {
    color: #f8fafc !important;
}
[data-bs-theme="dark"] .kanban-badge-aguardando,
[data-theme-setting="dark"] .kanban-badge-aguardando,
[data-theme-setting="blue"] .kanban-badge-aguardando {
    background-color: rgba(245, 158, 11, 0.2) !important;
    color: #fbbf24 !important;
    border-color: rgba(245, 158, 11, 0.4) !important;
}
[data-bs-theme="dark"] .kanban-badge-atendimento,
[data-theme-setting="dark"] .kanban-badge-atendimento,
[data-theme-setting="blue"] .kanban-badge-atendimento {
    background-color: rgba(37, 99, 235, 0.2) !important;
    color: #60a5fa !important;
    border-color: rgba(37, 99, 235, 0.4) !important;
}
[data-bs-theme="dark"] .kanban-badge-concluido,
[data-theme-setting="dark"] .kanban-badge-concluido,
[data-theme-setting="blue"] .kanban-badge-concluido {
    background-color: rgba(16, 185, 129, 0.2) !important;
    color: #34d399 !important;
    border-color: rgba(16, 185, 129, 0.4) !important;
}
[data-bs-theme="dark"] .kanban-card,
[data-theme-setting="dark"] .kanban-card,
[data-theme-setting="blue"] .kanban-card {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.35) !important;
}
[data-bs-theme="dark"] .kanban-card:hover,
[data-theme-setting="dark"] .kanban-card:hover,
[data-theme-setting="blue"] .kanban-card:hover {
    background-color: #243247 !important;
    border-color: #475569 !important;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.5) !important;
}
[data-bs-theme="dark"] .kanban-card-title a,
[data-theme-setting="dark"] .kanban-card-title a,
[data-theme-setting="blue"] .kanban-card-title a {
    color: #f8fafc !important;
}
[data-bs-theme="dark"] .kanban-card-title a:hover,
[data-theme-setting="dark"] .kanban-card-title a:hover,
[data-theme-setting="blue"] .kanban-card-title a:hover {
    color: #38bdf8 !important;
}
[data-bs-theme="dark"] .kanban-card-footer,
[data-theme-setting="dark"] .kanban-card-footer,
[data-theme-setting="blue"] .kanban-card-footer {
    border-top-color: #334155 !important;
}
[data-bs-theme="dark"] .kanban-column-body::-webkit-scrollbar-thumb,
[data-theme-setting="dark"] .kanban-column-body::-webkit-scrollbar-thumb,
[data-theme-setting="blue"] .kanban-column-body::-webkit-scrollbar-thumb {
    background: #334155;
}
[data-bs-theme="dark"] .kanban-col-dragover,
[data-theme-setting="dark"] .kanban-col-dragover,
[data-theme-setting="blue"] .kanban-col-dragover {
    background-color: rgba(56, 189, 248, 0.12) !important;
    outline-color: #38bdf8 !important;
}
[data-bs-theme="dark"] #btnToggleKanban.bg-white {
    background-color: #1e293b !important;
    border-color: #334155 !important;
    color: #cbd5e1 !important;
}

/* ========================================================
   BADGES MOBILE: MÓDULOS EM HOMOLOGAÇÃO (OFF)
   ======================================================== */
.badge-item-off {
    position: absolute;
    top: -4px;
    right: -4px;
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #ffffff !important;
    font-size: 0.65rem;
    font-weight: 800;
    line-height: 1;
    padding: 2.5px 5.5px;
    border-radius: 9999px;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 4px rgba(220, 38, 38, 0.4);
    letter-spacing: 0.5px;
    text-transform: uppercase;
    pointer-events: none;
    z-index: 10;
    user-select: none;
}

[data-bs-theme="dark"] .badge-item-off,
[data-theme-setting="dark"] .badge-item-off,
[data-theme-setting="blue"] .badge-item-off {
    border-color: #0f172a !important;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.6);
}

.badge-drawer-off {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #ffffff !important;
    font-size: 0.55rem;
    font-weight: 800;
    line-height: 1;
    padding: 2px 4.5px;
    border-radius: 9999px;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    box-shadow: 0 1px 3px rgba(220, 38, 38, 0.35);
    pointer-events: none;
    user-select: none;
    flex-shrink: 0;
}

[data-bs-theme="dark"] .badge-drawer-off,
[data-theme-setting="dark"] .badge-drawer-off,
[data-theme-setting="blue"] .badge-drawer-off {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

/* ========================================================
   DESTAQUE PARA MÓDULOS EM HOMOLOGAÇÃO
   ======================================================== */
.icon-homolog-destaque {
    border: 1.5px dashed #f59e0b !important;
    box-shadow: 0 0 0 2.5px rgba(245, 158, 11, 0.18), 0 3px 8px rgba(245, 158, 11, 0.12) !important;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.group:hover .icon-homolog-destaque,
.icon-homolog-destaque:hover {
    border-color: #d97706 !important;
    box-shadow: 0 0 0 3.5px rgba(245, 158, 11, 0.35), 0 6px 14px rgba(245, 158, 11, 0.25) !important;
    transform: translateY(-2px);
}

[data-bs-theme="dark"] .icon-homolog-destaque,
[data-theme-setting="dark"] .icon-homolog-destaque,
[data-theme-setting="blue"] .icon-homolog-destaque {
    border-color: #fbbf24 !important;
    box-shadow: 0 0 0 2.5px rgba(251, 191, 36, 0.22), 0 3px 8px rgba(0, 0, 0, 0.4) !important;
}

[data-bs-theme="dark"] .group:hover .icon-homolog-destaque,
[data-theme-setting="dark"] .group:hover .icon-homolog-destaque,
[data-theme-setting="blue"] .group:hover .icon-homolog-destaque {
    border-color: #f59e0b !important;
    box-shadow: 0 0 0 3.5px rgba(251, 191, 36, 0.4), 0 6px 14px rgba(0, 0, 0, 0.6) !important;
}

.badge-item-homolog {
    position: absolute;
    top: -5px;
    right: -6px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #ffffff !important;
    font-size: 0.58rem;
    font-weight: 800;
    line-height: 1;
    padding: 3px 6px;
    border-radius: 9999px;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 6px rgba(217, 119, 6, 0.45);
    letter-spacing: 0.5px;
    text-transform: uppercase;
    pointer-events: none;
    z-index: 10;
    user-select: none;
    animation: pulse-homolog 2.5s infinite ease-in-out;
}

@keyframes pulse-homolog {
    0%, 100% {
        box-shadow: 0 2px 6px rgba(217, 119, 6, 0.45);
        transform: scale(1);
    }
    50% {
        box-shadow: 0 2px 10px rgba(245, 158, 11, 0.75);
        transform: scale(1.05);
    }
}

[data-bs-theme="dark"] .badge-item-homolog,
[data-theme-setting="dark"] .badge-item-homolog,
[data-theme-setting="blue"] .badge-item-homolog {
    border-color: #0f172a !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.6);
}

.badge-drawer-homolog {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #ffffff !important;
    font-size: 0.55rem;
    font-weight: 800;
    line-height: 1;
    padding: 2px 5px;
    border-radius: 9999px;
    letter-spacing: 0.4px;
    text-transform: uppercase;
    box-shadow: 0 1px 3px rgba(217, 119, 6, 0.35);
    pointer-events: none;
    user-select: none;
    flex-shrink: 0;
}

/* ========================================================
   BADGES MOBILE: RESTRITO A ADMINISTRADORES (CADEADO)
   ======================================================== */
.badge-item-lock {
    position: absolute;
    top: -4px;
    right: -4px;
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #ffffff !important;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    border: 2px solid #ffffff;
    box-shadow: 0 2px 5px rgba(217, 119, 6, 0.45);
    pointer-events: none;
    z-index: 10;
    user-select: none;
}

[data-bs-theme="dark"] .badge-item-lock,
[data-theme-setting="dark"] .badge-item-lock,
[data-theme-setting="blue"] .badge-item-lock {
    border-color: #0f172a !important;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.6);
}

.badge-drawer-lock {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 17px;
    height: 17px;
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #ffffff !important;
    border-radius: 9999px;
    box-shadow: 0 1px 3px rgba(217, 119, 6, 0.4);
    pointer-events: none;
    user-select: none;
    flex-shrink: 0;
}

[data-bs-theme="dark"] .badge-drawer-lock,
[data-theme-setting="dark"] .badge-drawer-lock,
[data-theme-setting="blue"] .badge-drawer-lock {
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

/* ========================================================
   BOTÃO DE NOTIFICAÇÕES E ÍCONES (TOP NAVBAR)
   Arredondados como o ícone do usuário (36x36px círculo perfeito)
   ======================================================== */
.btn-header-notificacoes,
.top-navbar .btn-header-notificacoes,
.top-navbar #dropdownDashboardDesktop,
.top-navbar #dropdownNotificacoesHeader,
.top-navbar #dropdownHelpDeskHeader {
    width: 36px !important;
    height: 36px !important;
    min-width: 36px !important;
    min-height: 36px !important;
    max-width: 36px !important;
    max-height: 36px !important;
    padding: 0 !important;
    border-radius: 50% !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: rgba(15, 23, 42, 0.22) !important;
    border: 2px solid rgba(255, 255, 255, 0.25) !important;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15) !important;
    color: #ffffff !important;
    flex-shrink: 0 !important;
    transition: transform 0.15s ease-in-out, background-color 0.15s ease-in-out, border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out !important;
    cursor: pointer !important;
}

.top-navbar .btn-header-notificacoes::after,
.top-navbar #dropdownDashboardDesktop::after,
.top-navbar #dropdownNotificacoesHeader::after,
.top-navbar #dropdownHelpDeskHeader::after {
    display: none !important;
}

.btn-header-notificacoes:hover,
.btn-header-notificacoes:focus,
.btn-header-notificacoes.show,
.top-navbar #dropdownDashboardDesktop:hover,
.top-navbar #dropdownDashboardDesktop:focus,
.top-navbar #dropdownDashboardDesktop.show,
.top-navbar #dropdownNotificacoesHeader:hover,
.top-navbar #dropdownNotificacoesHeader:focus,
.top-navbar #dropdownNotificacoesHeader.show,
.top-navbar #dropdownHelpDeskHeader:hover,
.top-navbar #dropdownHelpDeskHeader:focus,
.top-navbar #dropdownHelpDeskHeader.show {
    color: #ffffff !important;
    background: rgba(255, 255, 255, 0.15) !important;
    border-color: rgba(255, 255, 255, 0.4) !important;
    transform: translateY(-1px) scale(1.05) !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.25) !important;
}

.btn-header-notificacoes:active,
.top-navbar #dropdownDashboardDesktop:active,
.top-navbar #dropdownNotificacoesHeader:active,
.top-navbar #dropdownHelpDeskHeader:active {
    transform: scale(0.95) !important;
}

/* ========================================================
   BOTTOM NAVIGATION & MODOS MOBILE
   ======================================================== */
.mobile-mode-sheet {
    max-height: 85vh;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
}

.mode-option-card {
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1.5px solid #e2e8f0;
    background: #ffffff;
}

.mode-option-card:active {
    transform: scale(0.98);
}

.mode-option-card.active-mode {
    border-color: #0284c7;
    background: rgba(2, 132, 199, 0.05);
}

.mode-option-card.active-mode-loja {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.05);
}

.mode-option-card.active-mode-financeiro {
    border-color: #f59e0b;
    background: rgba(245, 158, 11, 0.05);
}

.mode-check-indicator {
    background-color: #cbd5e1;
    border-color: #94a3b8;
}

.mode-option-card.active-mode .mode-check-indicator {
    background-color: #0284c7;
    border-color: #0284c7;
}

.mode-option-card.active-mode-loja .mode-check-indicator {
    background-color: #10b981;
    border-color: #10b981;
}

.mode-option-card.active-mode-financeiro .mode-check-indicator {
    background-color: #f59e0b;
    border-color: #f59e0b;
}

[data-bs-theme="dark"] .mobile-mode-sheet,
[data-theme-setting="dark"] .mobile-mode-sheet,
[data-theme-setting="blue"] .mobile-mode-sheet {
    background-color: #0f172a !important;
    border-color: #334155 !important;
    color: #f8fafc !important;
}

[data-bs-theme="dark"] .mode-option-card,
[data-theme-setting="dark"] .mode-option-card,
[data-theme-setting="blue"] .mode-option-card {
    background-color: #1e293b;
    border-color: #334155;
    color: #f8fafc;
}

[data-bs-theme="dark"] .mode-option-card .text-slate-800,
[data-theme-setting="dark"] .mode-option-card .text-slate-800,
[data-theme-setting="blue"] .mode-option-card .text-slate-800 {
    color: #f8fafc !important;
}

[data-bs-theme="dark"] .mode-option-card .text-slate-500,
[data-theme-setting="dark"] .mode-option-card .text-slate-500,
[data-theme-setting="blue"] .mode-option-card .text-slate-500 {
    color: #94a3b8 !important;
}

