/* Layout único — claro e escuro. Não depende do CSS antigo do painel. */

:root,
html[data-theme="light"] {
    --ink: #1A1740;
    --muted: #6B6590;
    --canvas: #EEEAF8;
    --surface: #FFFFFF;
    --surface-2: #F6F3FC;
    --line: #DDD6F0;
    --soft: #EDE7FF;
    --primary: #4C3FBF;
    --primary-dark: #2A2470;
    --sidebar: 248px;
    --header: 64px;
    --radius: 20px;
    --shadow: 0 10px 30px rgba(61, 52, 140, 0.1);
}

html[data-theme="dark"] {
    --ink: #E7EEF8;
    --muted: #A8B8CE;
    --canvas: #0B1220;
    --surface: #121A2B;
    --surface-2: #182236;
    --line: #2A3A52;
    --soft: rgba(167, 139, 250, 0.2);
    --primary: #C4B5FD;
    --primary-dark: #8EBEFF;
    --shadow: none;
}

html, body {
    background: var(--canvas) !important;
    color: var(--ink) !important;
    font-family: Inter, "Segoe UI", sans-serif;
}

h1, h2, h3, h4, h5, h6, p, label, small, strong, li, span, td, th {
    color: inherit;
}

a { color: var(--primary); }
a:hover { color: var(--primary-dark); }

.app-shell { min-height: 100vh; background: var(--canvas); }

.navbar.navbar-dark {
    background: var(--surface) !important;
    color: var(--ink) !important;
    border-bottom: 1px solid var(--line);
    min-height: var(--header);
    padding: 0.6rem 1rem;
    box-shadow: none;
}

.navbar .navbar-brand,
.navbar .btn-outline-light,
.navbar .dropdown-toggle,
.glacial-clock,
.glacial-clock strong,
.glacial-clock small {
    color: var(--ink) !important;
    background: transparent !important;
    border-color: var(--line) !important;
}

.glacial-clock {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    justify-content: center;
    background: var(--soft) !important;
    border-radius: 999px;
    padding: 0.2rem 0.85rem;
    line-height: 1.15;
}

#glacial-clock > i,
#glacial-clock .fa,
#glacial-clock .fa-snowflake,
#glacial-clock::before,
#glacial-clock::after {
    display: none !important;
    content: none !important;
}

#user-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--ink);
}

.user-navbar-avatar,
.user-navbar-avatar-fallback,
#profile-avatar-preview {
    width: 32px;
    height: 32px;
    max-width: 32px;
    max-height: 32px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

.user-navbar-avatar-fallback {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: #3D348C;
    color: #fff;
    font-size: 0.7rem;
    font-weight: 700;
}

.user-navbar-name {
    max-width: 140px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.watermark {
    position: fixed;
    bottom: 16px;
    right: 16px;
    z-index: 999;
    pointer-events: none;
    font-size: 0.75rem;
    color: var(--muted);
    background: var(--surface);
    border: 1px solid var(--line);
    border-radius: 6px;
    padding: 0.25rem 0.55rem;
}

.watermark.hidden { visibility: hidden; opacity: 0; }

.app-main { background: var(--canvas); }

@media (min-width: 992px) {
    .app-main > .row > .col-lg-2 {
        flex: 0 0 var(--sidebar) !important;
        width: var(--sidebar) !important;
        max-width: var(--sidebar) !important;
    }
    .app-main > .row > .col-lg-10 {
        flex: 1 1 auto !important;
        width: auto !important;
        max-width: calc(100% - var(--sidebar)) !important;
        min-width: 0 !important;
    }
    .sidebar {
        position: sticky !important;
        top: 0;
        width: 100% !important;
        height: calc(100vh - var(--header));
        overflow: auto;
        border-radius: 0;
    }
}

.sidebar {
    background: var(--surface) !important;
    color: var(--ink);
    border-right: 1px solid var(--line);
    padding: 0.75rem 0.6rem 1.25rem;
}

.sidebar-nav-label {
    font-size: 0.68rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--muted);
    padding: 0.85rem 0.75rem 0.25rem;
}

.sidebar-nav-group.is-hidden { display: none; }

.sidebar .nav-link {
    color: var(--ink);
    border-radius: 8px;
    padding: 0.45rem 0.7rem;
    margin: 0.1rem 0;
    display: flex;
    align-items: center;
    gap: 0.55rem;
    font-weight: 500;
}

.sidebar .nav-link i { width: 1.1rem; text-align: center; color: var(--muted); }
.sidebar .nav-link:hover { background: var(--soft); color: var(--primary-dark); }
.sidebar .nav-link.active {
    background: var(--soft);
    color: var(--primary-dark);
    box-shadow: none;
}
.sidebar .nav-link.active i { color: var(--primary); }

@media (max-width: 991.98px) {
    .sidebar {
        position: fixed;
        left: -320px;
        top: var(--header);
        bottom: 0;
        z-index: 1040;
        width: min(280px, 86vw);
        height: auto;
        transition: left 0.2s ease;
        box-shadow: var(--shadow);
    }
    body.sidebar-open .sidebar { left: 0; }
    .sidebar-overlay {
        display: none;
        position: fixed;
        inset: 0;
        top: var(--header);
        background: rgba(2, 8, 23, 0.45);
        z-index: 1030;
    }
    body.sidebar-open .sidebar-overlay { display: block; }
}

.card, .modal-content, .dropdown-menu, .list-group-item, .stat-card {
    background: var(--surface) !important;
    color: var(--ink) !important;
    border: 1px solid var(--line) !important;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
}

.card-header, .modal-header, .dropdown-header {
    background: var(--surface) !important;
    color: var(--ink) !important;
    border-bottom: 1px solid var(--line) !important;
}

.card-header.bg-warning,
.card-header.bg-info,
.card-header.bg-success,
.card-header.bg-primary,
.card-header.bg-dark {
    background: var(--surface) !important;
    color: var(--ink) !important;
}

.modal-footer { border-top: 1px solid var(--line); background: var(--surface); }
.dropdown-item { color: var(--ink); }
.dropdown-item:hover, .dropdown-item:focus { background: var(--soft); color: var(--ink); }

.stat-card { overflow: hidden; }
.stat-card::before { display: none; }
.stat-card:hover { transform: none; }
.stat-card h6, .stat-card small { color: var(--muted) !important; }
.stat-card h2, .stat-card h3 { color: var(--ink) !important; }
.stat-card.primary { box-shadow: inset 3px 0 0 #3D348C; }
.stat-card.success { box-shadow: inset 3px 0 0 #157347; }
.stat-card.warning { box-shadow: inset 3px 0 0 #B45309; }
.stat-card.danger { box-shadow: inset 3px 0 0 #B42318; }
.stat-card.info { box-shadow: inset 3px 0 0 #A78BFA; }

.form-control, .form-select, .input-group-text {
    background: var(--surface-2) !important;
    color: var(--ink) !important;
    border: 1px solid var(--line) !important;
    border-radius: 8px;
}
.form-control::placeholder { color: var(--muted); }
.form-control:focus, .form-select:focus {
    border-color: #5B4FBF !important;
    box-shadow: 0 0 0 3px rgba(167, 139, 250, 0.28);
}
.form-label { color: var(--ink); font-weight: 600; }

.nav-tabs { border-bottom: 1px solid var(--line); gap: 0.25rem; }
.nav-tabs .nav-link {
    color: var(--muted) !important;
    background: transparent !important;
    border: 0 !important;
    border-radius: 0;
}
.nav-tabs .nav-link:hover { color: var(--ink) !important; }
.nav-tabs .nav-link.active {
    color: var(--primary-dark) !important;
    background: transparent !important;
    box-shadow: inset 0 -2px 0 #5B4FBF !important;
}

.table-responsive { overflow: auto; }

.table {
    --bs-table-bg: transparent;
    --bs-table-color: var(--ink);
    --bs-table-border-color: var(--line);
    --bs-table-striped-bg: var(--surface-2);
    --bs-table-striped-color: var(--ink);
    --bs-table-hover-bg: var(--soft);
    --bs-table-hover-color: var(--ink);
    --bs-table-accent-bg: transparent;
    color: var(--ink) !important;
    margin-bottom: 0;
    width: 100%;
}

.table > :not(caption) > * > * {
    color: var(--ink) !important;
    background-color: transparent !important;
    border-color: var(--line) !important;
    box-shadow: none !important;
    padding: 0.7rem 0.75rem;
    vertical-align: top;
}

.table thead,
.table thead.bg-light,
.table thead th {
    background: var(--surface-2) !important;
    color: var(--muted) !important;
    font-size: 0.72rem;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    white-space: nowrap;
}

.table tbody tr:hover,
.table tbody tr:hover > * {
    background: var(--soft) !important;
    color: var(--ink) !important;
    transform: none !important;
}

.table tbody td .fw-bold,
.table tbody td strong { color: var(--ink) !important; }

.table td:last-child,
.table .btn-group,
.suppliers-actions { white-space: nowrap; }

.table .btn-group { display: inline-flex; flex-wrap: nowrap; gap: 0.25rem; }
.table .btn-group > .btn { border-radius: 8px !important; }

.table small, .text-muted, .text-body-secondary {
    color: var(--muted) !important;
}

.suppliers-cell-name,
.suppliers-cell-cnpj,
.suppliers-contact-line,
.suppliers-contact-item {
    color: var(--ink) !important;
}

.suppliers-cell-name {
    font-weight: 600;
    max-width: 22rem;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.suppliers-cell-cnpj {
    font-family: "JetBrains Mono", ui-monospace, monospace;
    font-size: 0.85em;
    white-space: nowrap;
    color: var(--muted) !important;
}

.badge {
    border-radius: 999px;
    font-weight: 600;
    padding: 0.35em 0.7em;
}

.bg-primary { background: #3D348C !important; color: #fff !important; }
.bg-success { background: #157347 !important; color: #fff !important; }
.bg-danger { background: #B42318 !important; color: #fff !important; }
.bg-warning { background: #F5D78E !important; color: #7A4E00 !important; }
.bg-info { background: #EDE7FF !important; color: #3D348C !important; }
.bg-secondary { background: var(--surface-2) !important; color: var(--ink) !important; border: 1px solid var(--line); }
.bg-light { background: var(--surface-2) !important; color: var(--ink) !important; }
.text-dark { color: var(--ink) !important; }

.btn { border-radius: 8px; font-weight: 600; }
.btn-primary { background: #3D348C; border-color: #3D348C; }
.btn-primary:hover { background: #2A2470; border-color: #2A2470; }
.btn-outline-primary { color: var(--primary-dark); border-color: var(--line); }
.btn-outline-light { color: var(--ink); border-color: var(--line); }
.btn-light {
    background: var(--surface-2) !important;
    color: var(--ink) !important;
    border: 1px solid var(--line) !important;
}

code, .glacial-code {
    color: var(--ink);
    background: var(--surface-2);
    border-radius: 6px;
    padding: 0.1rem 0.35rem;
}

.glacial-badge {
    background: var(--soft);
    color: var(--primary-dark);
    border-radius: 999px;
}
.glacial-badge--ok { background: #E8F6EE; color: #157347; }
.glacial-badge--off { background: #FDECEC; color: #B42318; }
html[data-theme="dark"] .glacial-badge--ok { background: rgba(21, 115, 71, 0.25); color: #8EE0B2; }
html[data-theme="dark"] .glacial-badge--off { background: rgba(180, 35, 24, 0.25); color: #F5B5B0; }

.cal-day {
    background: var(--surface-2);
    color: var(--ink);
    border: 1px solid var(--line);
    border-radius: 10px;
    min-height: 64px;
    padding: 0.45rem;
}
.cal-day--paid { background: #157347; color: #fff; border-color: #157347; }
.cal-day--soon { background: #F5D78E; color: #7A4E00; border-color: #E8C56A; }
.cal-day--late { background: #B42318; color: #fff; border-color: #B42318; }
.cal-day--today { outline: 2px solid #5B4FBF; outline-offset: 1px; }
.cal-day small { color: inherit !important; }

.alert { border-radius: var(--radius); }
.list-group-item { color: var(--ink) !important; }

body.release-notes-open { overflow: hidden; }

.release-notes-overlay {
    position: fixed;
    inset: 0;
    z-index: 20000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    background: transparent;
}
.release-notes-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(12, 10, 28, 0.62);
}
.release-notes-panel {
    position: relative;
    z-index: 1;
    width: min(640px, 100%);
    max-height: min(88vh, 820px);
    display: flex;
    flex-direction: column;
    background: var(--surface, #fff);
    color: var(--ink, #1A1740);
    border: 1px solid var(--line, #DDD6F0);
    border-radius: 20px;
    box-shadow: 0 24px 64px rgba(26, 23, 64, 0.28);
    overflow: hidden;
}
.release-notes-header {
    padding: 1.5rem 1.5rem 1.15rem;
    background: linear-gradient(105deg, #1B2458 0%, #3D3A8C 46%, #A78BFA 100%);
    color: #fff;
}
.release-notes-header__badge {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.3rem 0.75rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.18);
    font-size: 0.8rem;
    font-weight: 600;
    margin-bottom: 0.75rem;
}
.release-notes-header__title {
    margin: 0 0 0.4rem;
    font-size: 1.45rem;
    font-weight: 700;
    color: #fff;
}
.release-notes-header__subtitle {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.45;
    color: rgba(255, 255, 255, 0.92);
}
.release-notes-body {
    flex: 1;
    overflow: auto;
    padding: 1rem 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    background: var(--surface, #fff);
}
.release-notes-card {
    display: flex;
    gap: 0.85rem;
    padding: 0.9rem 1rem;
    border-radius: 14px;
    border: 1px solid var(--line, #DDD6F0);
    background: var(--surface-2, #F6F3FC);
}
.release-notes-card__icon {
    flex: 0 0 2.5rem;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #EDE7FF;
    color: #3D348C;
}
.release-notes-card__body { min-width: 0; }
.release-notes-card__date {
    display: block;
    font-size: 0.75rem;
    color: var(--muted, #6B6590);
}
.release-notes-card__title {
    margin: 0.15rem 0 0.3rem;
    font-size: 1rem;
    font-weight: 700;
    color: var(--ink, #1A1740);
}
.release-notes-card__summary,
.release-notes-card__highlights {
    margin: 0;
    font-size: 0.875rem;
    line-height: 1.45;
    color: var(--muted, #6B6590);
}
.release-notes-card__highlights { padding-left: 1.1rem; }
.release-notes-footer {
    padding: 0.9rem 1.25rem 1.15rem;
    border-top: 1px solid var(--line, #DDD6F0);
    background: var(--surface, #fff);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}
.release-notes-footer__hint {
    margin: 0;
    font-size: 0.8rem;
    color: var(--muted, #6B6590);
}
.release-notes-btn-primary {
    border: 0;
    border-radius: 12px;
    padding: 0.7rem 1.2rem;
    font-weight: 700;
    color: #fff;
    background: #3D348C;
}
html[data-theme="dark"] .release-notes-panel,
html[data-theme="dark"] .release-notes-body,
html[data-theme="dark"] .release-notes-footer {
    background: #16182E;
    color: #E7EEF8;
}
html[data-theme="dark"] .release-notes-card {
    background: #12122A;
    border-color: #2A3A52;
}
html[data-theme="dark"] .release-notes-card__title { color: #E7EEF8; }
html[data-theme="dark"] .release-notes-card__summary,
html[data-theme="dark"] .release-notes-card__highlights,
html[data-theme="dark"] .release-notes-card__date,
html[data-theme="dark"] .release-notes-footer__hint { color: #C4B5FD; }
@media (max-width: 576px) {
    .release-notes-card { flex-direction: column; }
}

html[data-theme="light"],
html[data-theme="light"] body,
html[data-theme="light"] .app-shell,
html[data-theme="light"] .app-main {
    background: linear-gradient(180deg, #E4DFF6 0%, #F3EEFB 42%, #F8F7FC 100%) !important;
}

html[data-theme="light"] .navbar.navbar-dark {
    background: rgba(255, 255, 255, 0.82) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.7);
    box-shadow: none;
    backdrop-filter: blur(10px);
}

html[data-theme="light"] .sidebar {
    background: rgba(255, 255, 255, 0.72) !important;
    border-right: 1px solid rgba(255, 255, 255, 0.8);
}

html[data-theme="light"] .sidebar .nav-link {
    color: #2C2758;
    border-radius: 12px;
}

html[data-theme="light"] .sidebar .nav-link.active {
    background: #EDE7FF;
    color: #2A2470;
    font-weight: 600;
}

html[data-theme="light"] .sidebar .nav-link.active i,
html[data-theme="light"] .dash-icon {
    color: #5B4FBF;
}

html[data-theme="light"] .sidebar-nav-label {
    color: #7B93AB;
}

html[data-theme="light"] .card,
html[data-theme="light"] .dashboard-card,
html[data-theme="light"] .menu-card,
html[data-theme="light"] .modal-content {
    background: #ffffff !important;
    border: 1px solid rgba(255, 255, 255, 0.9) !important;
    border-radius: 20px !important;
    box-shadow: 0 12px 32px rgba(61, 52, 140, 0.08) !important;
}

html[data-theme="light"] .glacial-hero {
    background: linear-gradient(105deg, #1B2458 0%, #3D3A8C 46%, #A78BFA 100%) !important;
    color: #ffffff !important;
    border: 0 !important;
    border-radius: 22px !important;
    box-shadow: 0 16px 36px rgba(61, 52, 140, 0.28) !important;
    padding: 1.35rem 1.5rem;
}

html[data-theme="light"] .glacial-hero h2,
html[data-theme="light"] .glacial-hero__mark {
    color: #ffffff !important;
}

html[data-theme="light"] .glacial-hero p,
html[data-theme="light"] .glacial-hero__kicker {
    color: rgba(255, 255, 255, 0.88) !important;
}

html[data-theme="light"] .glacial-hero__mark {
    background: rgba(255, 255, 255, 0.18);
    border-radius: 16px;
}

html[data-theme="light"] .glacial-clock {
    background: linear-gradient(135deg, #1E2A6B 0%, #7C6AD8 100%) !important;
    color: #ffffff !important;
    border: 0 !important;
    border-radius: 18px;
    padding: 0.4rem 0.85rem;
    gap: 0.55rem;
    box-shadow: 0 8px 18px rgba(61, 52, 140, 0.28);
}

.glacial-clock .fa-snowflake { display: none; }

html[data-theme="light"] .glacial-clock strong {
    color: #ffffff !important;
    font-size: 1.05rem;
    letter-spacing: 0.03em;
    display: block;
    line-height: 1.1;
}

html[data-theme="light"] .glacial-clock small {
    color: rgba(255, 255, 255, 0.86) !important;
    display: block;
}

html[data-theme="light"] .btn {
    border-radius: 12px;
}

html[data-theme="light"] .form-control,
html[data-theme="light"] .form-select,
html[data-theme="light"] .input-group-text {
    background: #FFFFFF !important;
    border-color: #D3E6F5 !important;
    border-radius: 12px;
    color: #1A1740 !important;
}

html[data-theme="light"] .form-control::placeholder {
    color: #8A9BB0;
}

html[data-theme="light"] .form-label {
    color: #1E293B;
    font-size: 0.92rem;
}

html[data-theme="light"] .nav-tabs .nav-link {
    color: #4E5E74 !important;
    padding: 0.55rem 0.7rem;
}

html[data-theme="light"] .nav-tabs .nav-link.active {
    color: #2A2470 !important;
    font-weight: 600;
}

html[data-theme="light"] .table thead,
html[data-theme="light"] .table thead.bg-light,
html[data-theme="light"] .table thead th {
    background: #F4FAFE !important;
    color: #5E7894 !important;
}

html[data-theme="light"] .card {
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04), 0 10px 28px rgba(15, 23, 42, 0.05);
}

html[data-theme="light"] .alert-info {
    background: #E8F3FF;
    border-color: #C5DDF8;
    color: #0F172A;
}

html[data-theme="light"] .alert-success {
    background: #E8F6EE;
    border-color: #C6E6D4;
    color: #145C38;
}

html[data-theme="light"] .alert-warning {
    background: #FFF6E5;
    border-color: #F0D7A4;
    color: #7A4E00;
}

html[data-theme="light"] .alert-danger {
    background: #FDECEC;
    border-color: #F3C7C4;
    color: #8E1D16;
}

html[data-theme="light"] .text-muted,
html[data-theme="light"] .table small {
    color: #5E7894 !important;
}

.glacial-hero {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.2rem 1.4rem;
    border-radius: 16px;
    background: var(--surface);
    color: var(--ink);
    border: 1px solid var(--line);
    box-shadow: var(--shadow);
}

.glacial-hero__mark {
    width: 46px;
    height: 46px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    background: var(--soft);
    color: #5B4FBF;
    flex-shrink: 0;
}

.glacial-hero h2 {
    margin: 0;
    font-size: 1.35rem;
    color: var(--ink);
}

.glacial-hero p,
.glacial-hero__kicker {
    margin: 0;
    color: var(--muted);
}

.glacial-hero__kicker {
    font-size: 0.72rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
}

html[data-theme="light"] .dashboard-card:hover,
html[data-theme="light"] .menu-card:hover {
    border-color: #D4C8F5 !important;
}

.dashboard-card,
.menu-card {
    border-radius: 16px !important;
    transition: border-color 0.15s ease, box-shadow 0.15s ease;
}

.menu-card { position: relative; }

.dashboard-card:hover,
.menu-card:hover {
    border-color: #CDBFEF !important;
}

.dash-icon { color: #5B4FBF; }

html[data-theme="dark"] .glacial-hero {
    background: linear-gradient(105deg, #141833 0%, #3D348C 58%, #A78BFA 100%) !important;
    color: #ffffff !important;
    border: 0 !important;
    box-shadow: none;
}

html[data-theme="dark"] .glacial-hero h2,
html[data-theme="dark"] .glacial-hero__mark {
    color: #ffffff !important;
}

html[data-theme="dark"] .glacial-hero p,
html[data-theme="dark"] .glacial-hero__kicker {
    color: rgba(255, 255, 255, 0.86) !important;
}

html[data-theme="dark"] .glacial-hero__mark {
    background: rgba(255, 255, 255, 0.16);
}

html[data-theme="dark"] .dashboard-card,
html[data-theme="dark"] .menu-card {
    background: #162033 !important;
    border: 1px solid #31445F !important;
    box-shadow: none !important;
}

html[data-theme="dark"] .dashboard-card h3,
html[data-theme="dark"] .dashboard-card h6,
html[data-theme="dark"] .menu-card h6,
html[data-theme="dark"] .dashboard-card .fw-bold,
html[data-theme="dark"] .fs-5 {
    color: #F4F7FB !important;
}

html[data-theme="dark"] .text-muted,
html[data-theme="dark"] h5.text-muted {
    color: #B7C6DA !important;
}

html[data-theme="dark"] .dash-icon,
html[data-theme="dark"] .sidebar .nav-link i {
    color: #C4B5FD;
}

html[data-theme="dark"] .sidebar .nav-link {
    color: #E7EEF8;
}

html[data-theme="dark"] .sidebar .nav-link.active {
    background: rgba(167, 139, 250, 0.22);
    color: #ffffff;
}

.dash-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    min-width: 1.45rem;
    height: 1.45rem;
    padding: 0 0.35rem;
    border-radius: 999px;
    background: #E11D48;
    color: #fff;
    font-size: 0.75rem;
    font-weight: 700;
    display: grid;
    place-items: center;
}

.overview-card {
    border-radius: 16px !important;
    overflow: hidden;
}

.overview-card .card-body {
    padding: 1rem 1.1rem 0.95rem;
    text-align: left;
}

.overview-card__label {
    margin: 0 0 0.35rem;
    font-size: 0.78rem;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--muted) !important;
}

.overview-card__value {
    margin: 0;
    font-size: 1.85rem;
    font-weight: 700;
    line-height: 1.1;
    color: var(--ink) !important;
}

.overview-card__value--money {
    font-size: 1.25rem;
    letter-spacing: -0.02em;
}

.overview-card--total { box-shadow: inset 4px 0 0 #2A2470 !important; }
.overview-card--pending { box-shadow: inset 4px 0 0 #D97706 !important; }
.overview-card--ok { box-shadow: inset 4px 0 0 #157347 !important; }
.overview-card--money { box-shadow: inset 4px 0 0 #A78BFA !important; }

html[data-theme="light"] .overview-card--total { box-shadow: inset 4px 0 0 #2A2470, 0 12px 32px rgba(61, 52, 140, 0.08) !important; }
html[data-theme="light"] .overview-card--pending { box-shadow: inset 4px 0 0 #D97706, 0 12px 32px rgba(61, 52, 140, 0.08) !important; }
html[data-theme="light"] .overview-card--ok { box-shadow: inset 4px 0 0 #157347, 0 12px 32px rgba(61, 52, 140, 0.08) !important; }
html[data-theme="light"] .overview-card--money { box-shadow: inset 4px 0 0 #A78BFA, 0 12px 32px rgba(61, 52, 140, 0.08) !important; }
.contas-pagar-panel,
.contas-pagar-panel .card-header,
.contas-pagar-panel .card-body,
.contas-pagar-panel .table,
.contas-pagar-panel .table-dark {
    background: var(--surface) !important;
    color: var(--ink) !important;
    --bs-table-bg: transparent;
    --bs-table-color: var(--ink);
}

.contas-pagar-panel .table > :not(caption) > * > * {
    background: transparent !important;
    color: var(--ink) !important;
}

.wa-create-modal .modal-content {
    border: 1px solid var(--line);
    border-radius: 16px;
    background: var(--surface);
    color: var(--ink);
}
.wa-create-modal .modal-header,
.wa-create-modal .modal-footer { border-color: var(--line); }
.wa-help {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    color: var(--muted);
    font-size: 0.92rem;
    margin: 0.45rem 0 1rem;
}
.wa-help a { white-space: nowrap; }
.wa-note {
    background: var(--soft);
    border: 1px solid var(--line);
    border-left: 4px solid var(--primary);
    border-radius: 12px;
    padding: 0.9rem 1rem;
    margin: 0.25rem 0 1rem;
    color: var(--ink);
}
