@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&display=swap');

/* ============================================
   MASJID FINANCE — PROFESSIONAL LIGHT THEME
   ============================================ */

:root {
    --bg-body: #f5f7fa;
    --bg-white: #ffffff;
    --bg-card: #ffffff;
    --bg-card-hover: #fafbfc;
    --bg-sidebar: #ffffff;
    --bg-input: #f8f9fb;
    --bg-input-focus: #ffffff;

    --border-light: #e8ecf1;
    --border-default: #dde1e8;
    --border-strong: #c8ced8;
    --border-focus: #16a34a;

    --text-primary: #1a1f36;
    --text-secondary: #5e6687;
    --text-tertiary: #8c93a8;
    --text-placeholder: #b0b7c9;

    --accent: #16a34a;
    --accent-light: #22c55e;
    --accent-bg: rgba(22, 163, 74, 0.08);
    --accent-border: rgba(22, 163, 74, 0.2);

    --income: #16a34a;
    --income-bg: rgba(22, 163, 74, 0.06);
    --income-border: rgba(22, 163, 74, 0.15);
    --expense: #dc2626;
    --expense-bg: rgba(220, 38, 38, 0.06);
    --expense-border: rgba(220, 38, 38, 0.15);
    --warning: #d97706;
    --warning-bg: rgba(217, 119, 6, 0.06);
    --warning-border: rgba(217, 119, 6, 0.15);
    --info: #2563eb;
    --info-bg: rgba(37, 99, 235, 0.06);
    --info-border: rgba(37, 99, 235, 0.15);
    --debt: #7c3aed;
    --debt-bg: rgba(124, 58, 237, 0.06);
    --debt-border: rgba(124, 58, 237, 0.15);

    --radius-sm: 8px;
    --radius-md: 10px;
    --radius-lg: 14px;
    --radius-xl: 18px;
    --radius-full: 9999px;

    --shadow-xs: 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.06), 0 1px 2px rgba(0, 0, 0, 0.04);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.08);

    --ease: cubic-bezier(0.25, 0.8, 0.25, 1);
    --duration: 0.2s;
}

*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-body);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
}

/* ---- TYPOGRAPHY ---- */
h1 {
    font-size: 1.6rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    color: var(--text-primary);
}

h2 {
    font-size: 1.35rem;
    font-weight: 700;
    letter-spacing: -0.01em;
}

h3 {
    font-size: 1.05rem;
    font-weight: 600;
}

h4 {
    font-size: 0.95rem;
    font-weight: 600;
}

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

.text-tertiary {
    color: var(--text-tertiary);
}

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

.text-income {
    color: var(--income);
}

.text-expense {
    color: var(--expense);
}

.text-debt {
    color: var(--debt);
}

.text-xs {
    font-size: 0.75rem;
}

.text-sm {
    font-size: 0.85rem;
}

.text-lg {
    font-size: 1.125rem;
}

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

.font-medium {
    font-weight: 500;
}

.font-semibold {
    font-weight: 600;
}

.font-bold {
    font-weight: 700;
}

.font-extrabold {
    font-weight: 800;
}

/* ---- LAYOUT ---- */
.app-container {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.main-content {
    flex: 1;
    padding: 1.25rem;
    padding-bottom: 5.5rem;
    max-width: 1100px;
    margin: 0 auto;
    width: 100%;
}

/* ---- SIDEBAR (Desktop) ---- */
@media (min-width: 768px) {
    .app-container {
        flex-direction: row;
    }

    .mobile-nav {
        display: none !important;
    }

    .desktop-sidebar {
        width: 250px;
        position: sticky;
        top: 0;
        height: 100vh;
        background: var(--bg-sidebar);
        border-right: 1px solid var(--border-light);
        padding: 1.25rem 0.75rem;
        display: flex;
        flex-direction: column;
        overflow-y: auto;
    }

    .main-content {
        padding: 2rem 2.5rem;
        padding-bottom: 2rem;
    }

    .sidebar-brand {
        display: flex;
        align-items: center;
        gap: 0.65rem;
        padding: 0.5rem 0.75rem;
        margin-bottom: 1.75rem;
    }

    .sidebar-brand-icon {
        width: 38px;
        height: 38px;
        background: var(--accent-bg);
        border: 1px solid var(--accent-border);
        border-radius: var(--radius-md);
        display: flex;
        align-items: center;
        justify-content: center;
        color: var(--accent);
    }

    .sidebar-brand-text h2 {
        font-size: 1rem;
        line-height: 1.2;
    }

    .sidebar-brand-text span {
        font-size: 0.65rem;
        color: var(--text-tertiary);
        text-transform: uppercase;
        letter-spacing: 0.08em;
        font-weight: 600;
    }

    .sidebar-section-title {
        font-size: 0.6rem;
        color: var(--text-tertiary);
        text-transform: uppercase;
        letter-spacing: 0.1em;
        font-weight: 700;
        padding: 0.5rem 0.75rem;
        margin-top: 0.75rem;
        margin-bottom: 0.2rem;
    }

    .desktop-nav-item {
        display: flex;
        align-items: center;
        gap: 0.65rem;
        padding: 0.55rem 0.75rem;
        color: var(--text-secondary);
        border-radius: var(--radius-sm);
        transition: all var(--duration) var(--ease);
        font-weight: 500;
        font-size: 0.875rem;
        margin-bottom: 1px;
    }

    .desktop-nav-item svg {
        width: 18px;
        height: 18px;
        stroke-width: 1.8;
    }

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

    .desktop-nav-item.active {
        background: var(--accent-bg);
        color: var(--accent);
        font-weight: 600;
    }
}

@media (max-width: 767px) {
    .desktop-sidebar {
        display: none;
    }
}

/* ---- MOBILE BOTTOM NAV ---- */
.mobile-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-top: 1px solid var(--border-light);
    display: flex;
    justify-content: space-around;
    padding: 0.35rem 0;
    padding-bottom: calc(0.35rem + env(safe-area-inset-bottom));
    z-index: 1000;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    color: var(--text-tertiary);
    font-size: 0.6rem;
    font-weight: 600;
    gap: 0.1rem;
    padding: 0.35rem 0.5rem;
    border-radius: var(--radius-sm);
    transition: all var(--duration) var(--ease);
    position: relative;
}

.nav-item svg {
    width: 20px;
    height: 20px;
    stroke-width: 1.8;
}

.nav-item.active {
    color: var(--accent);
}

.nav-item.active::after {
    content: '';
    position: absolute;
    top: -0.35rem;
    left: 50%;
    transform: translateX(-50%);
    width: 16px;
    height: 2px;
    background: var(--accent);
    border-radius: 2px;
}

/* ---- STAT CARDS ---- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

@media(min-width: 768px) {
    .stats-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.stat-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 1.1rem;
    box-shadow: var(--shadow-xs);
    position: relative;
    overflow: hidden;
}

.stat-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 3px;
}

.stat-card.income::before {
    background: var(--income);
}

.stat-card.expense::before {
    background: var(--expense);
}

.stat-card.balance::before {
    background: var(--info);
}

.stat-card.debt::before {
    background: var(--debt);
}

.stat-icon {
    width: 36px;
    height: 36px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 0.6rem;
}

.stat-icon svg {
    width: 18px;
    height: 18px;
}

.stat-icon.income {
    background: var(--income-bg);
    color: var(--income);
}

.stat-icon.expense {
    background: var(--expense-bg);
    color: var(--expense);
}

.stat-icon.balance {
    background: var(--info-bg);
    color: var(--info);
}

.stat-icon.debt {
    background: var(--debt-bg);
    color: var(--debt);
}

.stat-label {
    font-size: 0.7rem;
    color: var(--text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.stat-value {
    font-size: 1.35rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.2;
    color: var(--text-primary);
}

@media(max-width: 480px) {
    .stat-value {
        font-size: 1.05rem;
    }

    .stat-card {
        padding: 0.85rem;
    }
}

/* ---- CARDS ---- */
.card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 1.25rem;
    box-shadow: var(--shadow-xs);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.85rem;
    padding-bottom: 0.65rem;
    border-bottom: 1px solid var(--border-light);
}

/* ---- ACCOUNT CARDS ---- */
.accounts-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.75rem;
    margin-bottom: 1.25rem;
}

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

.account-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 1rem;
    box-shadow: var(--shadow-xs);
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

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

.account-card-icon svg {
    width: 18px;
    height: 18px;
}

.account-card-icon.cash {
    background: var(--warning-bg);
    color: var(--warning);
}

.account-card-icon.bank {
    background: var(--info-bg);
    color: var(--info);
}

.account-card-icon.other {
    background: var(--debt-bg);
    color: var(--debt);
}

.account-card-info {
    flex: 1;
}

.account-card-info .label {
    font-size: 0.7rem;
    color: var(--text-tertiary);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.account-card-info .value {
    font-size: 1.05rem;
    font-weight: 700;
    color: var(--text-primary);
}

.account-card-info .meta {
    font-size: 0.7rem;
    color: var(--text-tertiary);
}

/* ---- FORMS ---- */
.form-group {
    margin-bottom: 1.15rem;
}

.form-label {
    display: block;
    margin-bottom: 0.35rem;
    font-size: 0.78rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.form-control {
    width: 100%;
    padding: 0.65rem 0.85rem;
    background: var(--bg-input);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    color: var(--text-primary);
    font-size: 0.9rem;
    font-family: inherit;
    transition: all var(--duration) var(--ease);
    appearance: none;
    -webkit-appearance: none;
}

.form-control:focus {
    outline: none;
    border-color: var(--accent);
    background: var(--bg-input-focus);
    box-shadow: 0 0 0 3px var(--accent-bg);
}

.form-control::placeholder {
    color: var(--text-placeholder);
}

select.form-control {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%238c93a8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.75rem center;
    padding-right: 2.5rem;
}

.form-error {
    font-size: 0.78rem;
    color: var(--expense);
    margin-top: 0.25rem;
}

.form-card {
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 1.5rem;
    max-width: 700px;
    margin: 0 auto;
    box-shadow: var(--shadow-xs);
}

/* ---- BUTTONS ---- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.4rem;
    padding: 0.6rem 1.1rem;
    border-radius: var(--radius-md);
    font-weight: 600;
    font-size: 0.85rem;
    font-family: inherit;
    border: none;
    cursor: pointer;
    transition: all var(--duration) var(--ease);
    white-space: nowrap;
}

.btn svg {
    width: 16px;
    height: 16px;
}

.btn-primary {
    background: var(--accent);
    color: #fff;
    box-shadow: 0 1px 3px rgba(22, 163, 74, 0.2);
}

.btn-primary:hover {
    background: var(--accent-light);
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(22, 163, 74, 0.25);
}

.btn-secondary {
    background: var(--bg-body);
    color: var(--text-secondary);
    border: 1px solid var(--border-default);
}

.btn-secondary:hover {
    border-color: var(--border-strong);
    color: var(--text-primary);
}

.btn-danger {
    background: var(--expense-bg);
    color: var(--expense);
    border: 1px solid var(--expense-border);
}

.btn-danger:hover {
    background: rgba(220, 38, 38, 0.12);
}

.btn-ghost {
    background: transparent;
    color: var(--text-tertiary);
    padding: 0.4rem;
    border-radius: var(--radius-sm);
}

.btn-ghost:hover {
    color: var(--text-primary);
    background: var(--bg-body);
}

.btn-sm {
    padding: 0.35rem 0.7rem;
    font-size: 0.78rem;
}

.btn-icon {
    width: 34px;
    height: 34px;
    padding: 0;
    border-radius: var(--radius-sm);
}

/* ---- BADGES ---- */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.2rem;
    padding: 0.15rem 0.5rem;
    border-radius: var(--radius-full);
    font-size: 0.65rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.badge-income {
    background: var(--income-bg);
    color: var(--income);
    border: 1px solid var(--income-border);
}

.badge-expense {
    background: var(--expense-bg);
    color: var(--expense);
    border: 1px solid var(--expense-border);
}

.badge-cash {
    background: var(--warning-bg);
    color: var(--warning);
    border: 1px solid var(--warning-border);
}

.badge-bank {
    background: var(--info-bg);
    color: var(--info);
    border: 1px solid var(--info-border);
}

.badge-debt {
    background: var(--debt-bg);
    color: var(--debt);
    border: 1px solid var(--debt-border);
}

.badge-pending {
    background: var(--warning-bg);
    color: var(--warning);
    border: 1px solid var(--warning-border);
}

.badge-paid {
    background: var(--income-bg);
    color: var(--income);
    border: 1px solid var(--income-border);
}

.badge-partial {
    background: var(--info-bg);
    color: var(--info);
    border: 1px solid var(--info-border);
}

/* ---- TRANSACTION LIST ---- */
.transaction-list {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.transaction-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    transition: all var(--duration) var(--ease);
    box-shadow: var(--shadow-xs);
}

.transaction-item:hover {
    border-color: var(--border-default);
    box-shadow: var(--shadow-sm);
}

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

.transaction-icon svg {
    width: 18px;
    height: 18px;
}

.transaction-icon.income {
    background: var(--income-bg);
    color: var(--income);
}

.transaction-icon.expense {
    background: var(--expense-bg);
    color: var(--expense);
}

.transaction-details {
    flex: 1;
    min-width: 0;
}

.transaction-title {
    font-weight: 600;
    font-size: 0.9rem;
    line-height: 1.3;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.transaction-meta {
    font-size: 0.75rem;
    color: var(--text-tertiary);
    display: flex;
    align-items: center;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 0.1rem;
}

.transaction-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 0.15rem;
}

.transaction-meta-item svg {
    width: 11px;
    height: 11px;
}

.transaction-amount {
    font-weight: 700;
    font-size: 0.95rem;
    white-space: nowrap;
    text-align: right;
}

.transaction-actions {
    display: flex;
    gap: 0.25rem;
    margin-left: 0.15rem;
}

/* ---- DATA LIST ---- */
.data-list {
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
}

.data-item {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    transition: all var(--duration) var(--ease);
    box-shadow: var(--shadow-xs);
}

.data-item:hover {
    border-color: var(--border-default);
    box-shadow: var(--shadow-sm);
}

.data-item-icon {
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: var(--bg-body);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-tertiary);
    flex-shrink: 0;
}

.data-item-icon svg {
    width: 18px;
    height: 18px;
}

.data-item-content {
    flex: 1;
    min-width: 0;
}

.data-item-title {
    font-weight: 600;
    font-size: 0.9rem;
}

.data-item-subtitle {
    font-size: 0.78rem;
    color: var(--text-tertiary);
    margin-top: 0.05rem;
}

.data-item-actions {
    display: flex;
    gap: 0.25rem;
}

/* ---- PAGE HEADER ---- */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.25rem;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.page-header-left h1 {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.page-header-left p {
    color: var(--text-tertiary);
    font-size: 0.82rem;
    margin-top: 0.1rem;
}

/* ---- EMPTY STATE ---- */
.empty-state {
    text-align: center;
    padding: 2.5rem 1.25rem;
    color: var(--text-tertiary);
}

.empty-state-icon {
    width: 52px;
    height: 52px;
    margin: 0 auto 0.75rem;
    background: var(--bg-body);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-tertiary);
}

.empty-state-icon svg {
    width: 24px;
    height: 24px;
}

/* ---- SECTIONS ---- */
.section {
    margin-bottom: 1.25rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.65rem;
}

.section-title {
    font-weight: 700;
    font-size: 0.95rem;
    display: flex;
    align-items: center;
    gap: 0.35rem;
}

/* ---- ALERTS ---- */
.alert {
    padding: 0.75rem 1rem;
    border-radius: var(--radius-md);
    font-size: 0.85rem;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-bottom: 1rem;
}

.alert-success {
    background: var(--income-bg);
    border: 1px solid var(--income-border);
    color: var(--income);
}

.alert-error {
    background: var(--expense-bg);
    border: 1px solid var(--expense-border);
    color: var(--expense);
}

/* ---- AUTH (Login/Register) ---- */
.auth-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem;
    background: var(--bg-body);
    background-image: radial-gradient(ellipse at 30% 50%, rgba(22, 163, 74, 0.04) 0%, transparent 55%),
        radial-gradient(ellipse at 70% 30%, rgba(37, 99, 235, 0.03) 0%, transparent 50%);
}

.auth-card {
    width: 100%;
    max-width: 400px;
    background: var(--bg-card);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 2.25rem 1.75rem;
    box-shadow: var(--shadow-lg);
}

.auth-brand {
    text-align: center;
    margin-bottom: 1.75rem;
}

.auth-brand-icon {
    width: 52px;
    height: 52px;
    margin: 0 auto 0.85rem;
    background: var(--accent-bg);
    border: 1px solid var(--accent-border);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent);
}

.auth-brand h1 {
    font-size: 1.35rem;
    margin-bottom: 0.2rem;
}

.auth-brand p {
    color: var(--text-tertiary);
    font-size: 0.85rem;
}

.auth-footer {
    text-align: center;
    margin-top: 1.25rem;
    font-size: 0.85rem;
    color: var(--text-tertiary);
}

.auth-footer a {
    color: var(--accent);
    font-weight: 600;
}

.auth-footer a:hover {
    color: var(--accent-light);
}

/* ---- MOBILE HEADER ---- */
.mobile-page-header {
    display: none;
    margin-bottom: 1.25rem;
}

@media (max-width: 767px) {
    .mobile-page-header {
        display: flex;
        justify-content: space-between;
        align-items: center;
    }
}

/* ---- UTILITIES ---- */
.flex {
    display: flex;
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.flex-center {
    display: flex;
    align-items: center;
    justify-content: center;
}

.items-center {
    align-items: center;
}

.gap-1 {
    gap: 0.25rem;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-3 {
    gap: 0.75rem;
}

.gap-4 {
    gap: 1rem;
}

.mt-1 {
    margin-top: 0.25rem;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mt-3 {
    margin-top: 0.75rem;
}

.mt-4 {
    margin-top: 1rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}

.mb-3 {
    margin-bottom: 0.75rem;
}

.mb-4 {
    margin-bottom: 1rem;
}

.w-full {
    width: 100%;
}

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

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

.divider {
    height: 1px;
    background: var(--border-light);
    margin: 1.25rem 0;
}

/* ---- SCROLLBAR ---- */
::-webkit-scrollbar {
    width: 5px;
}

::-webkit-scrollbar-track {
    background: transparent;
}

::-webkit-scrollbar-thumb {
    background: var(--border-default);
    border-radius: 3px;
}

/* ---- ANIMATIONS ---- */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(6px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-in {
    animation: fadeIn 0.25s var(--ease) both;
}

/* ---- SEARCHABLE SELECT ---- */
.searchable-select {
    position: relative;
}

.searchable-select .search-input {
    cursor: text;
}

.searchable-select .search-input.has-value {
    font-weight: 600;
    color: var(--text-primary);
}

.search-options {
    display: none;
    position: absolute;
    top: calc(100% + 4px);
    left: 0;
    right: 0;
    background: var(--bg-card);
    border: 1px solid var(--border-default);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
    max-height: 200px;
    overflow-y: auto;
    z-index: 100;
}

.search-option {
    padding: 0.55rem 0.85rem;
    cursor: pointer;
    font-size: 0.88rem;
    transition: background var(--duration) var(--ease);
}

.search-option:hover {
    background: var(--accent-bg);
    color: var(--accent);
}

.search-option-empty {
    padding: 0.75rem;
    text-align: center;
    color: var(--text-tertiary);
    font-size: 0.85rem;
}

/* ---- FILTER TABS ---- */
.filter-tabs {
    display: inline-flex;
    gap: 2px;
    background: var(--bg-body);
    border-radius: var(--radius-md);
    padding: 2px;
}

.filter-tab {
    padding: 0.35rem 0.75rem;
    border: none;
    background: transparent;
    border-radius: var(--radius-sm);
    font-size: 0.78rem;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    color: var(--text-tertiary);
    transition: all var(--duration) var(--ease);
}

.filter-tab:hover {
    color: var(--text-primary);
}

.filter-tab.active {
    background: var(--bg-card);
    box-shadow: var(--shadow-xs);
    color: var(--text-primary);
}

.filter-tab.active.income {
    color: var(--income);
}

.filter-tab.active.expense {
    color: var(--expense);
}

/* ---- SECTIONS ---- */
.section {
    margin-bottom: 1.5rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.75rem;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 0.4rem;
    font-size: 0.95rem;
    font-weight: 700;
}

/* ---- UTILITIES ---- */
.mb-3 {
    margin-bottom: 0.75rem;
}

.mb-4 {
    margin-bottom: 1rem;
}

.mt-1 {
    margin-top: 0.25rem;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mt-3 {
    margin-top: 0.75rem;
}

.gap-2 {
    gap: 0.5rem;
}

.gap-3 {
    gap: 0.75rem;
}

.flex {
    display: flex;
}

.flex-between {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.items-center {
    align-items: center;
}

.w-full {
    width: 100%;
}