/* /assets/css/core/04_tema_escuro.css */
/* Estética Smoked Pearl Glass (Alabastro Fumê · Escuro de Alto Contraste) */

html[data-theme="dark"] {
    --bg-outer: #111113;
    --bg-shell: #19191d;
    --bg-sidebar: #151518;
    --bg-card: #222227;
    --bg-card-hover: #2a2a30;
    --bg-input: #2b2b31;
    --bg-subtle: rgba(255, 255, 255, 0.035);
    --bg-charcoal: #e8e1cc; /* Destaque ativo em Pérola Dourado luminoso */
    --bg-charcoal-hover: #f3eee0;

    --border-white: rgba(255, 255, 255, 0.08);
    --border-subtle: rgba(255, 255, 255, 0.09);
    --border-strong: rgba(255, 255, 255, 0.20);

    --text-dark: #f4f4f6;
    --text-secondary: #d4d4dc;
    --text-muted: #9e9ea9;
    --text-faint: #70707b;

    --green-trend: #4ade80;
    --green-bg: rgba(74, 222, 128, 0.14);
    --red-trend: #f87171;
    --red-bg: rgba(248, 113, 113, 0.14);
    --amber-trend: #fbbf24;
    --pearl-gold: #3c372a;
    --pearl-gold-light: #2d2a21;

    --shadow-shell: 0 32px 70px -12px rgba(0, 0, 0, 0.65), 0 4px 20px rgba(0, 0, 0, 0.4);
    --shadow-card: 0 8px 24px -4px rgba(0, 0, 0, 0.35), inset 0 1px 0 rgba(255, 255, 255, 0.06);
    --shadow-row: 0 2px 6px rgba(0, 0, 0, 0.22);
    --shadow-row-hover: 0 8px 20px -4px rgba(0, 0, 0, 0.4), 0 2px 6px rgba(0, 0, 0, 0.25);
    --shadow-active: 0 8px 22px -4px rgba(232, 225, 204, 0.22);
    --focus-ring: 0 0 0 3px rgba(232, 225, 204, 0.18);
}

html[data-theme="dark"] body {
    background-image: radial-gradient(circle at 50% 0%, rgba(232, 225, 204, 0.05), transparent 70%);
}

html[data-theme="dark"] ::selection {
    background-color: var(--bg-charcoal);
    color: #141417;
}

html[data-theme="dark"] ::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.18);
}

html[data-theme="dark"] ::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.32);
}

/* Ajustes finos de contraste para elementos de destaque no modo escuro */
html[data-theme="dark"] .nav-tile.active,
html[data-theme="dark"] .nav-sublink.active,
html[data-theme="dark"] .btn-sidebar-dash.active,
html[data-theme="dark"] .nav-group.group-active .nav-group-icon,
html[data-theme="dark"] .pill-action,
html[data-theme="dark"] .sidebar-brand-badge,
html[data-theme="dark"] .pro-badge-ok,
html[data-theme="dark"] .active-pill,
html[data-theme="dark"] .quick-action-btn:hover .q-icon,
html[data-theme="dark"] .btn-icon-sm:hover,
html[data-theme="dark"] .btn-close-modal:hover {
    color: #141417 !important;
}

html[data-theme="dark"] .nav-sublink.active .sublink-dot {
    background-color: #141417 !important;
}

html[data-theme="dark"] .nav-tile:hover {
    background-color: var(--bg-input);
}

html[data-theme="dark"] .metrics-strip {
    background-color: rgba(34, 34, 39, 0.92);
}

html[data-theme="dark"] .spool-fan-card.fan-mid {
    background-color: #28282e;
}

html[data-theme="dark"] .spool-fan-card.fan-center {
    background: linear-gradient(145deg, #332f25, #464030);
    border-color: rgba(232, 225, 204, 0.65);
    box-shadow: 0 12px 28px -6px rgba(0, 0, 0, 0.5), inset 0 1px 0 rgba(255, 255, 255, 0.12);
}

html[data-theme="dark"] .fan-thumb {
    background-color: rgba(0, 0, 0, 0.32);
    border-color: rgba(255, 255, 255, 0.1);
}

html[data-theme="dark"] .bento-pill {
    background-color: var(--bg-input);
    color: var(--text-secondary);
}

html[data-theme="dark"] .bento-pill:hover {
    background-color: #35353d;
    color: var(--text-dark);
}

html[data-theme="dark"] .avatar-circle {
    background-color: #32323a;
    color: #f4f4f6;
    border-color: rgba(255, 255, 255, 0.22);
}

html[data-theme="dark"] .pearl-field select option {
    background-color: #222227;
    color: #f4f4f6;
}
