body {
    min-height: 100vh;
    background:
        radial-gradient(circle at top left, rgba(15, 23, 42, 0.03), transparent 28%),
        linear-gradient(180deg, #f8fafc 0%, #eef2f7 100%);
    color: #0f172a;
}

#app-shell {
    min-height: 100vh;
}

.sidebar {
    width: 296px;
    min-height: 100vh;
    position: sticky;
    top: 0;
    background: linear-gradient(180deg, #111827 0%, #0f172a 100%) !important;
    border-right: 1px solid rgba(255, 255, 255, 0.06);
}

.main-shell {
    min-width: 0;
}

.topbar-card {
    background: rgba(255, 255, 255, 0.94);
    border: 1px solid rgba(15, 23, 42, 0.06);
    border-radius: 1.25rem;
    padding: 1.25rem 1.5rem;
    box-shadow: 0 1rem 2rem rgba(15, 23, 42, 0.06);
}

.eyebrow-label {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #64748b;
    margin-bottom: 0.4rem;
}

.page-title {
    font-size: clamp(1.6rem, 2vw, 2rem);
    font-weight: 700;
    color: #0f172a;
}

.page-subtitle {
    color: #64748b;
}

.page-meta {
    min-width: 110px;
}

.mobile-menu-btn {
    border-radius: 0.95rem;
}

.sidebar-brand {
    display: flex;
    align-items: center;
    gap: 0.9rem;
}

.brand-mark {
    width: 2.6rem;
    height: 2.6rem;
    border-radius: 0.9rem;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.1);
    font-size: 1.1rem;
}

.sidebar-section-label {
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.09em;
    color: rgba(255, 255, 255, 0.45);
    margin-bottom: 0.85rem;
}

.sidebar .nav-link {
    color: rgba(255, 255, 255, 0.82);
    border-radius: 1rem;
    padding: 0.9rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.sidebar .nav-link.active,
.sidebar .nav-link:hover {
    background: rgba(255, 255, 255, 0.14);
    color: #fff;
}

.sidebar .nav-link.active {
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.offcanvas .nav-link {
    color: rgba(255, 255, 255, 0.85);
    border-radius: 1rem;
    padding: 0.9rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    font-weight: 500;
}

.offcanvas .nav-link.active,
.offcanvas .nav-link:hover {
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
}

.stat-card {
    border: 1px solid rgba(15, 23, 42, 0.06);
    border-radius: 1.15rem;
    box-shadow: 0 0.7rem 1.8rem rgba(15, 23, 42, 0.06);
    background: rgba(255, 255, 255, 0.96);
}

.stat-sales {
    border-top: 4px solid #0f766e;
}

.stat-expense {
    border-top: 4px solid #b45309;
}

.stat-flow {
    border-top: 4px solid #1d4ed8;
}

.table-wrap {
    background: #fff;
    border-radius: 1.2rem;
    border: 1px solid rgba(15, 23, 42, 0.06);
    box-shadow: 0 0.7rem 1.8rem rgba(15, 23, 42, 0.05);
}

.quick-card {
    background: #fff;
    border-radius: 1.2rem;
    border: 1px solid rgba(15, 23, 42, 0.06);
    box-shadow: 0 0.7rem 1.8rem rgba(15, 23, 42, 0.05);
}

.section-card {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(15, 23, 42, 0.06);
    border-radius: 1.2rem;
    box-shadow: 0 0.7rem 1.8rem rgba(15, 23, 42, 0.05);
}

.section-kicker {
    font-size: 0.78rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    color: #64748b;
    margin-bottom: 0.35rem;
}

.quick-links-grid .col-6,
.quick-links-grid .col-lg-3 {
    display: flex;
}

.quick-link-card {
    width: 100%;
    text-decoration: none;
    color: #0f172a;
    background: #f8fafc;
    border: 1px solid rgba(15, 23, 42, 0.08);
    border-radius: 1rem;
    padding: 1.1rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.85rem;
    font-weight: 600;
}

.quick-link-card i {
    width: 2.6rem;
    height: 2.6rem;
    border-radius: 0.9rem;
    display: grid;
    place-items: center;
    background: #e2e8f0;
    color: #0f172a;
    font-size: 1.1rem;
}

.ui-table thead th {
    font-size: 0.76rem;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #64748b;
    padding-top: 0;
    padding-bottom: 0.9rem;
    border-bottom-color: #e2e8f0;
}

.ui-table tbody td {
    padding-top: 0.95rem;
    padding-bottom: 0.95rem;
    vertical-align: middle;
    border-bottom-color: #eef2f7;
}

.table-notes {
    max-width: 240px;
    color: #475569;
}

.sticky-card {
    position: sticky;
    top: 1.5rem;
}

.actions-inline {
    display: flex;
    justify-content: flex-end;
    gap: 0.5rem;
    flex-wrap: wrap;
}

@media (max-width: 991.98px) {
    .topbar-card {
        padding: 1rem;
    }

    .page-meta {
        min-width: auto;
    }

    .quick-link-card {
        padding: 1rem 0.85rem;
    }

    .sticky-card {
        position: static;
    }

    .actions-inline {
        justify-content: stretch;
    }

    .actions-inline .btn,
    .actions-inline form,
    .actions-inline form .btn {
        flex: 1 1 auto;
    }

    .table-wrap,
    .section-card,
    .quick-card,
    .stat-card {
        border-radius: 1rem;
    }
}

@media (max-width: 767.98px) {
    .ui-table thead {
        display: none;
    }

    .ui-table,
    .ui-table tbody,
    .ui-table tr,
    .ui-table td {
        display: block;
        width: 100%;
    }

    .ui-table tr {
        padding: 0.9rem 0;
        border-bottom: 1px solid #e2e8f0;
    }

    .ui-table tbody td {
        border: 0;
        padding: 0.35rem 0;
        text-align: left !important;
    }

    .ui-table tbody td::before {
        content: attr(data-label);
        display: block;
        font-size: 0.76rem;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.06em;
        color: #64748b;
        margin-bottom: 0.15rem;
    }

    .actions-inline {
        margin-top: 0.5rem;
    }

    .actions-inline .btn,
    .actions-inline form .btn,
    .btn-lg,
    .form-control-lg {
        min-height: 3rem;
    }

    .table-notes {
        max-width: none;
    }
}
