/* ══════════════════════════════════════════════
   EXTRA.CSS — Componentes adicionales
   ══════════════════════════════════════════════ */

/* ── SNACKBAR ── */
.snackbar {
    position: fixed;
    bottom: 1.5rem;
    left: 50%;
    transform: translateX(-50%) translateY(80px);
    background: var(--color-dark);
    color: white;
    padding: .75rem 1.5rem;
    border-radius: 9999px;
    font-size: .875rem;
    font-weight: 600;
    z-index: 9999;
    transition: transform .3s cubic-bezier(.34, 1.56, .64, 1), opacity .3s;
    opacity: 0;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .25);
    white-space: nowrap;
}

.snackbar.show {
    transform: translateX(-50%) translateY(0);
    opacity: 1;
}

.snackbar.success {
    background: #27AE60;
}

.snackbar.error {
    background: #E74C3C;
}

.snackbar.warning {
    background: #F39C12;
    color: #1A2633;
}

/* ── WELCOME BANNER ── */
.welcome-banner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--color-primary) 0%, #c9581a 100%);
    border-radius: var(--radius-xl);
    padding: 1.5rem 2rem;
    color: white;
    margin-bottom: 1.5rem;
    position: relative;
    overflow: hidden;
}

.welcome-banner::after {
    content: '';
    position: absolute;
    right: -30px;
    top: -30px;
    width: 200px;
    height: 200px;
    background: rgba(255, 255, 255, .07);
    border-radius: 50%;
}

.welcome-banner::before {
    content: '';
    position: absolute;
    right: 80px;
    bottom: -50px;
    width: 150px;
    height: 150px;
    background: rgba(255, 255, 255, .04);
    border-radius: 50%;
}

.welcome-text h2 {
    font-size: 1.375rem;
    font-weight: 800;
    margin-bottom: .25rem;
}

.welcome-text p {
    font-size: .9375rem;
    opacity: .85;
}

.welcome-cta {
    display: flex;
    gap: .625rem;
    position: relative;
    z-index: 1;
}

/* ── DASHBOARD GRIDS ── */
.dashboard-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-bottom: 1.5rem;
}

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

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

.dashboard-main {
    display: grid;
    grid-template-columns: 1.6fr 1fr;
    gap: 1rem;
}

.dashboard-bottom {
    display: grid;
    grid-template-columns: 1.5fr 1fr 1fr;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

@media (max-width: 1100px) {

    .dashboard-main,
    .dashboard-bottom {
        grid-template-columns: 1fr;
    }
}

/* ── STAT CARDS ── */
.stat-card {
    background: var(--color-bg-card);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 1.25rem 1.5rem;
    position: relative;
    overflow: hidden;
    transition: transform .15s, box-shadow .15s;
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.stat-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: .875rem;
}

.stat-card-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
}

.stat-card-menu {
    font-size: 1.125rem;
    cursor: pointer;
    color: var(--color-text-muted);
    line-height: 1;
}

.stat-label {
    font-size: .8125rem;
    font-weight: 600;
    color: var(--color-text-muted);
    text-transform: uppercase;
    letter-spacing: .04em;
    margin-bottom: .375rem;
}

.stat-value {
    font-size: 1.375rem;
    font-weight: 800;
    color: var(--color-text-primary);
    line-height: 1.2;
}

.stat-prev {
    font-size: .8125rem;
    color: var(--color-text-muted);
    margin-top: .25rem;
}

.stat-trend {
    font-size: .825rem;
    font-weight: 700;
    margin-top: .375rem;
}

.stat-trend.up {
    color: var(--color-success);
}

.stat-trend.down {
    color: var(--color-danger);
}

/* ── RECENT TX LIST ── */
.recent-tx-list {
    overflow: hidden;
}

.tx-list-item {
    display: flex;
    align-items: center;
    gap: .875rem;
    padding: .75rem 1.25rem;
    cursor: pointer;
    border-bottom: 1px solid var(--color-border-light);
    transition: background .12s;
}

.tx-list-item:last-child {
    border-bottom: none;
}

.tx-list-item:hover {
    background: var(--color-bg);
}

.tx-list-info {
    flex: 1;
    min-width: 0;
}

.tx-list-desc {
    font-size: .9375rem;
    font-weight: 600;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.tx-list-cat {
    font-size: .77rem;
    color: var(--color-text-muted);
    margin-top: .1rem;
}

.tx-list-amount {
    font-size: .9375rem;
    font-weight: 700;
    white-space: nowrap;
}

/* ── TX ICON ── */
.tx-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .9rem;
    flex-shrink: 0;
}

/* ── BILL MINI CARD ── */
.bill-mini-card {
    display: flex;
    align-items: flex-start;
    gap: .75rem;
    padding: .75rem;
    border-radius: var(--radius-md);
    border: 1px solid var(--color-border-light);
    cursor: pointer;
    transition: background .12s;
}

.bill-mini-card:hover {
    background: var(--color-bg);
}

.bill-mini-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.bill-mini-info {
    flex: 1;
}

.bill-mini-name {
    font-size: .875rem;
    font-weight: 600;
}

.bill-mini-date {
    font-size: .75rem;
    color: var(--color-text-muted);
}

.bill-mini-amount {
    font-size: .9rem;
    font-weight: 700;
    color: var(--color-danger);
    flex-shrink: 0;
}

/* ── PROGRESS BAR ── */
.progress-bar-thin .progress-fill {
    height: 3px;
}

.progress-bar-lg {
    height: 10px;
    border-radius: 5px;
}

/* ── TABLE STYLES ── */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1.5rem;
    flex-wrap: wrap;
    gap: .75rem;
}

.page-header-left h2 {
    font-size: 1.375rem;
    font-weight: 800;
    margin: 0;
}

.page-header-left p {
    font-size: .9rem;
    color: var(--color-text-muted);
    margin: .25rem 0 0;
}

.page-header-actions {
    display: flex;
    gap: .625rem;
}

.td-icon {
    display: flex;
    align-items: center;
    gap: .625rem;
}

.td-desc {
    font-size: .9375rem;
    font-weight: 600;
}

.td-sub {
    font-size: .77rem;
    color: var(--color-text-muted);
    margin-top: .1rem;
}

.td-amount {
    font-weight: 700;
    font-size: .9375rem;
    text-align: right;
}

.td-amount.income {
    color: var(--color-success);
}

.td-amount.expense {
    color: var(--color-danger);
}

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

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

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

.row-actions {
    display: flex;
    gap: .25rem;
}

.filter-bar {
    display: flex;
    gap: .625rem;
    padding: 1rem 1.25rem;
    border-bottom: 1px solid var(--color-border-light);
    flex-wrap: wrap;
    align-items: center;
}

.filter-select {
    padding: .4rem .75rem;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-md);
    background: var(--color-bg-card);
    color: var(--color-text-primary);
    font-size: .8125rem;
    font-family: inherit;
    cursor: pointer;
    outline: none;
    transition: border-color .15s;
}

.filter-select:focus {
    border-color: var(--color-primary);
}

.btn-icon {
    padding: .35rem .5rem !important;
}

/* ── ACCOUNT CARD ── */
.account-card {
    background: var(--color-bg-card);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: 1.25rem;
    position: relative;
    transition: box-shadow .15s, border-color .15s;
    cursor: default;
}

.account-card:hover {
    box-shadow: var(--shadow-md);
    border-color: var(--color-border-hover);
}

.account-card-icon {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
    margin-bottom: .875rem;
}

.account-card-name {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: .2rem;
}

.account-card-type {
    font-size: .8125rem;
    color: var(--color-text-muted);
    margin-bottom: .875rem;
}

.account-balance-label {
    font-size: .75rem;
    color: var(--color-text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.account-balance-val {
    font-size: 1.375rem;
    font-weight: 800;
    margin: .2rem 0;
}

.account-balance-forecast {
    font-size: .8125rem;
    color: var(--color-text-muted);
}

/* ── TARJETA CARD ── */
.tarjeta-card {
    background: var(--color-bg-card);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-xl);
    overflow: hidden;
}

.tarjeta-card-header {
    background: linear-gradient(135deg, var(--color-dark) 0%, #3d5570 100%);
    padding: 1.25rem 1.5rem;
    color: white;
    min-height: 110px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.tarjeta-network {
    font-size: .8125rem;
    font-weight: 700;
    opacity: .6;
    text-transform: uppercase;
    letter-spacing: .06em;
}

.tarjeta-name {
    font-size: 1.1rem;
    font-weight: 800;
    margin-top: .5rem;
}

.tarjeta-number {
    font-size: .875rem;
    opacity: .65;
    letter-spacing: .12em;
    margin-top: .25rem;
}

.tarjeta-card-body {
    padding: 1.25rem;
}

.tarjeta-metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: .5rem;
    margin-bottom: 1rem;
    text-align: center;
}

.tarjeta-metric-label {
    font-size: .7rem;
    color: var(--color-text-muted);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.tarjeta-metric-val {
    font-size: 1rem;
    font-weight: 800;
}

.tarjeta-metric-val.danger {
    color: var(--color-danger);
}

.tarjeta-metric-val.success {
    color: var(--color-success);
}

.tarjeta-actions {
    display: flex;
    gap: .5rem;
    margin-top: 1rem;
}

/* ── BUDGET ── */
.budget-overview-card {
    background: linear-gradient(135deg, var(--color-dark) 0%, #3d5570 100%);
    border-radius: var(--radius-xl);
    padding: 1.75rem 2rem;
}

.budget-overview-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    margin-top: 1.25rem;
    padding-top: 1.25rem;
    border-top: 1px solid rgba(255, 255, 255, .1);
}

.budget-overview-stat-label {
    font-size: .75rem;
    color: rgba(255, 255, 255, .5);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.budget-overview-stat-val {
    font-size: 1.125rem;
    font-weight: 800;
    color: white;
    margin-top: .25rem;
}

.budget-item {
    padding: .875rem 0;
    border-bottom: 1px solid var(--color-border-light);
}

.budget-item:last-child {
    border-bottom: none;
}

.budget-item-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: .5rem;
}

.budget-item-left {
    display: flex;
    align-items: center;
    gap: .625rem;
}

.budget-cat-icon {
    width: 34px;
    height: 34px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: .9rem;
}

.budget-cat-name {
    font-size: .9375rem;
    font-weight: 600;
}

.budget-amounts {
    text-align: right;
}

.budget-spent {
    font-size: .9375rem;
    font-weight: 700;
}

.budget-limit {
    font-size: .77rem;
    color: var(--color-text-muted);
}

/* ── META CARD ── */
.meta-card {
    position: relative;
    overflow: hidden;
    padding: 1.25rem;
}

.meta-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.meta-icon-circle {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid transparent;
}

.meta-name {
    font-size: 1.0625rem;
    font-weight: 700;
    margin-bottom: .5rem;
}

.meta-amounts {
    display: flex;
    justify-content: space-between;
    margin-bottom: .5rem;
}

/* ── CATEGORÍAS ── */
.cat-card {
    transition: transform .15s;
}

.cat-card:hover {
    transform: translateY(-2px);
}

.cat-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: .75rem;
}

.cat-icon-big {
    width: 44px;
    height: 44px;
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.cat-name {
    font-size: 1rem;
    font-weight: 700;
    margin-bottom: .5rem;
}

.cat-chip {
    display: inline-flex;
    align-items: center;
    gap: .375rem;
    font-size: .82rem;
    padding: .2rem .65rem;
    background: var(--color-bg);
    border-radius: 9999px;
}

.cat-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    flex-shrink: 0;
}

/* ── AJUSTES ── */
.settings-layout {
    display: grid;
    grid-template-columns: 240px 1fr;
    gap: 1.5rem;
    align-items: start;
}

@media (max-width: 900px) {
    .settings-layout {
        grid-template-columns: 1fr;
    }
}

.settings-sidebar {
    position: sticky;
    top: 1rem;
}

.settings-user {
    display: flex;
    gap: .875rem;
    align-items: center;
    padding-bottom: 1.25rem;
    border-bottom: 1px solid var(--color-border-light);
    margin-bottom: 1rem;
}

.settings-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--color-primary);
    color: white;
    font-size: .875rem;
    font-weight: 800;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.settings-avatar-lg {
    width: 64px;
    height: 64px;
    font-size: 1.25rem;
}

.settings-avatar-row {
    display: flex;
    gap: 1rem;
    align-items: center;
    margin-bottom: .5rem;
}

.settings-nav {
    display: flex;
    flex-direction: column;
    gap: .125rem;
}

.settings-nav-item {
    display: flex;
    align-items: center;
    gap: .625rem;
    padding: .625rem .875rem;
    border-radius: var(--radius-md);
    font-size: .9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all .15s;
    color: var(--color-text-secondary);
}

.settings-nav-item:hover {
    background: var(--color-bg);
    color: var(--color-text-primary);
}

.settings-nav-item.active {
    background: var(--color-primary-light);
    color: var(--color-primary);
    font-weight: 700;
}

.settings-nav-icon {
    font-size: 1rem;
    flex-shrink: 0;
}

.settings-option-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    padding: .875rem 0;
    border-bottom: 1px solid var(--color-border-light);
}

.settings-option-row:last-child {
    border-bottom: none;
}

.settings-opt-title {
    font-size: .9375rem;
    font-weight: 600;
}

.settings-opt-desc {
    font-size: .8125rem;
    color: var(--color-text-muted);
    margin-top: .125rem;
}

/* ── SWITCH / TOGGLE ── */
.switch {
    position: relative;
    display: inline-block;
    width: 40px;
    height: 22px;
    flex-shrink: 0;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}

.switch-slider {
    position: absolute;
    inset: 0;
    background: var(--color-border);
    border-radius: 9999px;
    cursor: pointer;
    transition: background .25s;
}

.switch-slider::before {
    content: '';
    position: absolute;
    height: 16px;
    width: 16px;
    left: 3px;
    bottom: 3px;
    background: white;
    border-radius: 50%;
    transition: transform .25s;
    box-shadow: 0 1px 4px rgba(0, 0, 0, .2);
}

.switch input:checked+.switch-slider {
    background: var(--color-primary);
}

.switch input:checked+.switch-slider::before {
    transform: translateX(18px);
}

/* ── MODAL EXTRAS ── */
.tx-type-selector {
    display: flex;
    margin-bottom: 1.25rem;
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-lg);
    overflow: hidden;
}

.tx-type-btn {
    flex: 1;
    padding: .6rem;
    font-size: .875rem;
    font-weight: 600;
    background: none;
    border: none;
    cursor: pointer;
    color: var(--color-text-secondary);
    transition: all .15s;
    font-family: inherit;
}

.tx-type-btn.active-expense {
    background: rgba(231, 76, 60, .1);
    color: var(--color-danger);
}

.tx-type-btn.active-income {
    background: rgba(39, 174, 96, .1);
    color: var(--color-success);
}

.tx-type-btn.active-transfer {
    background: rgba(41, 169, 225, .1);
    color: var(--color-accent);
}

.color-picker-row {
    display: flex;
    flex-wrap: wrap;
    gap: .5rem;
    margin-top: .5rem;
}

.color-dot-pick {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    cursor: pointer;
    border: 3px solid transparent;
    transition: transform .12s, border-color .12s;
}

.color-dot-pick:hover {
    transform: scale(1.2);
}

.color-dot-pick.selected {
    border-color: var(--color-dark);
    transform: scale(1.15);
}

.factura-item {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .625rem 0;
    border-bottom: 1px solid var(--color-border-light);
}

.factura-item:last-child {
    border-bottom: none;
}

.inline-alert {
    display: flex;
    gap: .5rem;
    align-items: flex-start;
    padding: .75rem 1rem;
    border-radius: var(--radius-md);
    margin-bottom: 1rem;
    font-size: .875rem;
}

.inline-alert.info {
    background: rgba(41, 169, 225, .1);
    color: var(--color-text-primary);
    border: 1px solid rgba(41, 169, 225, .2);
}

.inline-alert.warning {
    background: rgba(243, 156, 18, .1);
    color: var(--color-text-primary);
    border: 1px solid rgba(243, 156, 18, .2);
}

.inline-alert.danger {
    background: rgba(231, 76, 60, .1);
    color: var(--color-text-primary);
    border: 1px solid rgba(231, 76, 60, .2);
}

.step-indicator {
    display: flex;
    gap: .5rem;
    justify-content: center;
    margin-bottom: 1.5rem;
}

.step-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--color-border);
    transition: background .2s;
}

.step-dot.active {
    background: var(--color-primary);
    transform: scale(1.3);
}

/* ── GRIDS ── */
.grid-2 {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
}

.grid-2-1 {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 1rem;
}

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

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

    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {

    .grid-2,
    .grid-3,
    .grid-4 {
        grid-template-columns: 1fr;
    }
}

/* ── NOTIFICACIONES ── */
.header-notif-wrapper {
    position: relative;
}

.notif-dropdown {
    position: absolute;
    top: calc(100% + .75rem);
    right: 0;
    width: 360px;
    background: var(--color-bg-card);
    border: 1.5px solid var(--color-border);
    border-radius: var(--radius-xl);
    box-shadow: var(--shadow-xl);
    z-index: 200;
    overflow: hidden;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-8px) scale(.97);
    transform-origin: top right;
    transition: all .2s cubic-bezier(.34, 1.56, .64, 1);
}

.notif-dropdown.open {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
}

.notif-header {
    padding: .875rem 1rem;
    font-weight: 700;
    border-bottom: 1px solid var(--color-border-light);
}

.notif-item {
    display: flex;
    gap: .75rem;
    padding: .875rem 1rem;
    border-bottom: 1px solid var(--color-border-light);
    cursor: pointer;
    transition: background .12s;
}

.notif-item:hover {
    background: var(--color-bg);
}

.notif-icon {
    font-size: 1.25rem;
    flex-shrink: 0;
}

.notif-text {
    font-size: .875rem;
    font-weight: 600;
}

.notif-sub {
    font-size: .8rem;
    color: var(--color-text-muted);
    margin-top: .1rem;
}

.notif-time {
    font-size: .75rem;
    color: var(--color-text-muted);
    margin-top: .25rem;
}

/* ── HEADER EXTRAS ── */
.header-page-title {
    font-size: 1.0625rem;
    font-weight: 800;
}

.header-breadcrumb {
    font-size: .75rem;
    color: var(--color-text-muted);
    margin-top: .1rem;
}

.header-month-nav {
    display: flex;
    align-items: center;
    gap: .25rem;
}

/* ── SIDEBAR EXTRAS ── */
.sidebar-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, .4);
    z-index: 40;
    display: none;
}

.sidebar-overlay.visible {
    display: block;
}

@media (max-width: 768px) {
    .sidebar {
        transform: translateX(-100%);
        transition: transform .25s;
    }

    .sidebar.mobile-open {
        transform: translateX(0);
    }

    .main-content {
        margin-left: 0 !important;
    }
}

.sidebar.collapsed {
    width: 64px;
}

.sidebar.collapsed .nav-label,
.sidebar.collapsed .nav-section-title,
.sidebar.collapsed .sidebar-brand-name,
.sidebar.collapsed .user-info,
.sidebar.collapsed .sidebar-collapse-btn {
    display: none;
}

.sidebar.collapsed .nav-icon {
    font-size: 1.25rem;
}

.main-content.sidebar-collapsed {
    margin-left: 64px;
}

/* ── DARK THEME OVERRIDES ── */
.theme-dark {
    --color-bg: #151C24;
    --color-bg-card: #1C2733;
    --color-bg-card-hover: #253040;
    --color-bg-input: #1C2733;
    --color-border: rgba(255, 255, 255, .08);
    --color-border-light: rgba(255, 255, 255, .05);
    --color-border-hover: rgba(255, 255, 255, .15);
    --color-text-primary: #E8EDF2;
    --color-text-secondary: #A0B5C5;
    --color-text-muted: #6B8A9E;
    --color-dark: #0D1520;
}

.theme-dark .sidebar {
    background: #1C2733;
    border-right-color: rgba(255, 255, 255, .06);
}

.theme-dark .top-header {
    background: rgba(28, 39, 51, .95);
    border-bottom-color: rgba(255, 255, 255, .06);
}

.theme-dark .card {
    border-color: rgba(255, 255, 255, .07);
}

/* ── FORM HELPERS ── */
.form-hint {
    font-size: .77rem;
    color: var(--color-text-muted);
    margin-top: .35rem;
}

.form-input-icon {
    position: relative;
}

.form-input-icon .icon {
    position: absolute;
    left: .75rem;
    top: 50%;
    transform: translateY(-50%);
    color: var(--color-text-muted);
    font-size: .875rem;
    pointer-events: none;
}

.form-input-icon .icon-right {
    left: auto;
    right: .75rem;
    cursor: pointer;
    pointer-events: all;
}

/* ── MISC ── */
.chart-legend {
    display: flex;
    flex-wrap: wrap;
    gap: .375rem .875rem;
}

.chart-legend-item {
    display: flex;
    align-items: center;
    gap: .375rem;
    font-size: .8125rem;
    color: var(--color-text-secondary);
}

.legend-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    flex-shrink: 0;
}

.flex-1 {
    flex: 1;
}

.text-right {
    text-align: right;
}

.card-padded {
    padding: 1.25rem;
}

.btn-danger-outline {
    background: transparent;
    border: 1.5px solid var(--color-danger);
    color: var(--color-danger);
}

.btn-danger-outline:hover {
    background: var(--color-danger);
    color: white;
}

.btn-success {
    background: var(--color-success);
    color: white;
    border: none;
}

.btn-success:hover {
    background: #219d53;
}

.btn-xs {
    padding: .3rem .7rem;
    font-size: .78rem;
    border-radius: var(--radius-md);
}

.btn-sm {
    padding: .45rem 1rem;
    font-size: .8125rem;
}

/* ── EMPTY STATE ── */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 3rem 2rem;
    text-align: center;
}

.empty-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
    opacity: .5;
}

.empty-state h4 {
    font-size: 1.0625rem;
    font-weight: 700;
    margin-bottom: .5rem;
}

.empty-state p {
    font-size: .9rem;
    color: var(--color-text-muted);
    max-width: 280px;
}