:root {
    --bg: #FAFAFA;
    --surface: #FFFFFF;
    --surface-hover: #F8F9FA;
    --border: #EAEAEA;
    --border-hover: #D4D4D4;
    --text-main: #171717;
    --text-muted: #737373;
    --text-light: #A3A3A3;
    --accent: #171717;
    --accent-bg: #F5F5F5;
    --success: #16A34A;
    --danger: #DC2626;
    --sidebar-width: 260px;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.02);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.03);
    --shadow-lg: 0 12px 24px rgba(0, 0, 0, 0.04);
    --ui-scale: 1;
}

@media (min-width: 1536px) {
    :root {
        --ui-scale: 0.95;
    }
}

@media (min-width: 1800px) {
    :root {
        --ui-scale: 0.9;
    }
}

* {
    box-sizing: border-box;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

body {
    margin: 0;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: var(--bg);
    color: var(--text-main);
    min-height: 100vh;
    overflow: hidden;
    font-size: 14px;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: 'Plus Jakarta Sans', sans-serif;
    margin: 0;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

.dashboard-shell {
    display: flex;
    height: 100vh;
}

/* Sidebar */
.sidebar {
    width: var(--sidebar-width);
    background: #0f172a;
    border-right: none;
    display: flex;
    flex-direction: column;
    padding: 32px 24px;
    height: 100vh;
    overflow-y: auto;
    overflow-x: hidden;
    z-index: 10;
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 48px;
}

.brand-icon {
    width: 32px;
    height: 32px;
    background: #ffffff;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: #0f172a;
}

.sidebar-header h1 {
    font-size: 1.25rem;
    font-weight: 700;
    color: #f8fafc;
}

.nav-section {
    margin-bottom: 36px;
}

.nav-section-title {
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #64748b;
    font-weight: 600;
    margin-bottom: 12px;
    display: block;
    padding-left: 12px;
}

.nav-links {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.nav-links a {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 8px;
    color: #94a3b8;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.nav-links a i {
    font-size: 1.1rem;
    transition: color 0.2s ease;
    color: #64748b;
}

.nav-links a:hover {
    color: #f8fafc;
    background: rgba(255, 255, 255, 0.06);
}

.nav-links a:hover i {
    color: #f8fafc;
}

.nav-links a.active {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.05);
    box-shadow: none;
    font-weight: 600;
}

.nav-links a.active i {
    color: #ffffff;
}

.nav-badge {
    margin-left: auto;
    min-width: 22px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 0.72rem;
    font-weight: 700;
    line-height: 1;
    color: #0f172a;
    background: #e2e8f0;
}

.nav-links a.active .nav-badge {
    color: #ffffff;
    background: rgba(255, 255, 255, 0.24);
}

/* Main Content */
.main-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    background-color: var(--bg);
    overflow-y: auto;
}

/* Top Bar */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: calc(24px * var(--ui-scale)) calc(48px * var(--ui-scale));
    background: rgba(250, 250, 250, 0.8);
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 20;
    border-bottom: 1px solid var(--border);
}

.mobile-menu-btn {
    display: none;
}

.search-wrapper {
    position: relative;
    width: 320px;
}

.search-wrapper i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-light);
    font-size: 1rem;
}

.search-wrapper input {
    width: 100%;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-main);
    padding: 10px 14px 10px 40px;
    border-radius: 8px;
    font-size: 0.9rem;
    transition: all 0.2s ease;
    font-family: inherit;
    box-shadow: var(--shadow-sm);
}

.search-wrapper input:focus {
    outline: none;
    border-color: var(--text-light);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.03);
}

.search-wrapper input::placeholder {
    color: var(--text-light);
}

.top-bar-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.top-profile {
    margin-left: 12px;
    padding-left: 20px;
    border-left: 1px solid var(--border);
    display: flex;
    align-items: center;
    cursor: pointer;
    position: relative;
}

.top-company-name {
    margin-left: 10px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--text-main);
    max-width: 180px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.top-profile img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    border: 2px solid var(--surface);
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s ease;
}

.top-profile:hover img {
    transform: scale(1.05);
}

.dropdown-menu {
    display: none;
    position: absolute;
    top: calc(100% + 10px);
    right: 0;
    min-width: 180px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    z-index: 100;
    padding: 8px;
    flex-direction: column;
    gap: 4px;
}

.dropdown-menu.show {
    display: flex;
    animation: dropdownFade 0.2s ease;
}

@keyframes dropdownFade {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

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

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 16px;
    color: var(--text-main);
    text-decoration: none;
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

.dropdown-item i {
    font-size: 1.1rem;
    color: var(--text-muted);
}

.dropdown-item:hover {
    background: var(--surface-hover);
}

.dropdown-item:hover i {
    color: var(--text-main);
}

.dropdown-item.text-danger {
    color: var(--danger);
}

.dropdown-item.text-danger i {
    color: var(--danger);
}

.dropdown-item.text-danger:hover {
    background: #FEE2E2;
}

.dropdown-divider {
    height: 1px;
    background: var(--border);
    margin: 4px 0;
}

.icon-btn {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background: var(--surface);
    border: 1px solid var(--border);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    position: relative;
    box-shadow: var(--shadow-sm);
}

.icon-btn:hover {
    color: var(--text-main);
    border-color: var(--border-hover);
    background: var(--surface-hover);
}

.notification-dot {
    position: absolute;
    top: 10px;
    right: 10px;
    width: 6px;
    height: 6px;
    background: var(--danger);
    border-radius: 50%;
}

.sidebar-backdrop {
    display: none;
}

/* Main Panel */
.main-panel {
    padding: calc(32px * var(--ui-scale)) calc(48px * var(--ui-scale)) calc(74px * var(--ui-scale));
    display: flex;
    flex-direction: column;
    gap: calc(32px * var(--ui-scale));
    width: 100%;
}

.hero-panel {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0;
    background: transparent;
    border: none;
}

.eyebrow {
    color: var(--text-muted);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    font-weight: 600;
    margin-bottom: 8px;
    display: block;
}

.welcome-header h2 {
    font-size: 2rem;
    margin-bottom: 8px;
    font-weight: 600;
    letter-spacing: -0.03em;
}

.welcome-header p {
    color: var(--text-muted);
    font-size: 1rem;
    max-width: 500px;
    line-height: 1.5;
    margin: 0;
}

.hero-actions {
    display: flex;
    gap: 12px;
}

.primary-btn {
    background: var(--text-main);
    color: var(--surface);
    border: 1px solid var(--text-main);
    padding: 10px 20px;
    border-radius: 8px;
    font-family: inherit;
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.primary-btn:hover {
    background: #000000;
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

.primary-btn i {
    color: var(--surface);
}

.secondary-btn {
    background: var(--surface);
    color: var(--text-main);
    border: 1px solid var(--border);
    padding: 10px 20px;
    border-radius: 8px;
    font-family: inherit;
    font-weight: 500;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.secondary-btn:hover {
    background: var(--surface-hover);
    border-color: var(--border-hover);
}

/* Stats Grid */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: calc(20px * var(--ui-scale));
}

.stat-card {
    background: var(--surface);
    border: 1px solid var(--border);
    padding: 24px;
    border-radius: 16px;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
    display: flex;
    flex-direction: column;
}

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

.stat-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.stat-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    background: var(--bg);
    border: 1px solid var(--border);
    color: var(--text-main);
}

.trend {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 4px 8px;
    border-radius: 6px;
    background: var(--bg);
}

.trend.up {
    color: var(--success);
    background: #DCFCE7;
}

.trend.down {
    color: var(--text-main);
    background: var(--bg);
}

.trend-critical {
    color: var(--danger);
    background: #FEE2E2;
}

.stat-info span {
    color: var(--text-muted);
    font-size: 0.85rem;
    font-weight: 500;
    margin-bottom: 4px;
    display: block;
}

.stat-info h3 {
    font-size: 1.75rem;
    font-weight: 600;
    color: var(--text-main);
    letter-spacing: -0.02em;
}

/* Content Row */
.content-row {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: calc(20px * var(--ui-scale));
}

.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 28px;
    box-shadow: var(--shadow-sm);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 28px;
    background: transparent;
    border-bottom: none;
}

.card-kicker {
    color: #94a3b8;
    font-size: 0.65rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    margin-bottom: 4px;
}

.card-header h3 {
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 1.15rem;
    font-weight: 700;
    color: #0f172a;
    margin: 0;
}

.filter-pill {
    padding: 7px 16px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    font-size: 0.8rem;
    font-weight: 600;
    color: #64748b;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
}

.filter-pill:hover {
    background: #f8fafc;
    color: #0f172a;
}

.dashboard-filter-active {
    background: #1e293b !important;
    color: #ffffff !important;
    border-color: #1e293b !important;
}

.dashboard-btn-group {
    display: inline-flex;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.dashboard-btn-group .filter-pill {
    border-radius: 0;
    border-right: none;
}

.dashboard-btn-group .filter-pill:last-child {
    border-right: 1px solid #e2e8f0;
}

.dashboard-btn-group-start { border-top-left-radius: 8px !important; border-bottom-left-radius: 8px !important; }
.dashboard-btn-group-end { border-top-right-radius: 8px !important; border-bottom-right-radius: 8px !important; }



.view-all-link {
    color: var(--text-main);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    padding: 6px 12px;
    border-radius: 6px;
    border: 1px solid var(--border);
    transition: all 0.2s ease;
}

.view-all-link:hover {
    background: var(--surface-hover);
}

/* Chart */
.chart-container {
    padding: 12px 0 0 0;
}

.chart-legend {
    display: flex;
    gap: 20px;
    margin-bottom: 24px;
}

.chart-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.85rem;
    color: var(--text-muted);
    font-weight: 500;
}

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

.legend-dot-primary {
    background: var(--text-main);
}

.legend-dot-secondary {
    background: var(--border-hover);
}

.chart-axis-labels {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    text-align: center;
    margin-top: 16px;
    font-size: 0.75rem;
    color: var(--text-light);
    font-weight: 500;
}

.chart-area {
    fill: url(#revenueArea);
}

.chart-line {
    fill: none;
    stroke: var(--text-main);
    stroke-width: 2;
}

.chart-points circle {
    fill: var(--surface);
    stroke: var(--text-main);
    stroke-width: 2;
    transition: all 0.2s ease;
}

.chart-points circle:hover {
    r: 6;
    fill: var(--text-main);
}

/* Transactions */
.transactions-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.transaction-item {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px;
    background: var(--surface);
    border: 1px solid transparent;
    border-radius: 12px;
    transition: all 0.2s ease;
}

.transaction-item:hover {
    background: var(--surface-hover);
    border-color: var(--border);
}

.t-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--bg);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: var(--text-muted);
}

.t-info {
    flex: 1;
}

.t-info h4 {
    font-size: 0.9rem;
    font-weight: 500;
    margin-bottom: 2px;
    color: var(--text-main);
}

.t-info p {
    color: var(--text-light);
    font-size: 0.8rem;
    margin: 0;
}

.t-amount {
    font-weight: 600;
    font-size: 0.9rem;
}

.t-positive {
    color: var(--success);
}

.t-negative {
    color: var(--text-main);
}

.t-brand {
    color: var(--text-main);
}

/* Data Table */
.table-responsive {
    overflow-x: auto;
}

.data-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
}

.data-table th {
    padding: 16px;
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--text-muted);
    font-weight: 600;
    border-bottom: 1px solid var(--border);
}

.data-table td {
    padding: 16px;
    font-size: 0.9rem;
    color: var(--text-main);
    border-bottom: 1px solid var(--border);
}

.data-table tbody tr:last-child td {
    border-bottom: none;
}

.data-table tbody tr:hover td {
    background: var(--surface-hover);
}

.badge {
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 0.75rem;
    font-weight: 600;
    display: inline-block;
}

.badge-success {
    background: #DCFCE7;
    color: var(--success);
}

.badge-warning {
    background: #FEF9C3;
    color: #CA8A04;
}

.badge-danger {
    background: #FEE2E2;
    color: var(--danger);
}

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

    .content-row {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 992px) {
    .dashboard-shell {
        height: 100vh;
    }

    .sidebar {
        width: var(--sidebar-width);
        height: 100vh;
        padding: 24px;
        position: fixed;
        top: 0;
        left: 0;
        transform: translateX(-100%);
        transition: transform 0.25s ease;
        z-index: 40;
        border-bottom: none;
        overflow-y: auto;
    }

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

    .sidebar-backdrop {
        position: fixed;
        inset: 0;
        background: rgba(15, 23, 42, 0.45);
        z-index: 30;
    }

    .sidebar-backdrop.show {
        display: block;
    }

    .main-content {
        height: 100vh;
        width: 100%;
    }

    .top-bar {
        padding: 20px 24px;
    }

    .mobile-menu-btn {
        display: inline-flex;
        margin-right: 8px;
    }

    .main-panel {
        padding: 24px 24px 48px;
    }

    .top-company-name {
        max-width: 120px;
        font-size: 0.85rem;
    }
}

@media (max-width: 768px) {
    .top-bar {
        flex-direction: row;
        flex-wrap: wrap;
        gap: 16px;
        align-items: center;
    }

    .search-wrapper {
        width: 100%;
        order: 3;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .hero-panel {
        flex-direction: column;
        align-items: flex-start;
        gap: 20px;
    }

    .card {
        padding: 20px;
    }

    .top-profile {
        margin-left: 0;
        padding-left: 0;
        border-left: none;
    }

    .top-company-name {
        display: none;
    }
}

/* Form Styles */
.form-row {
    display: flex;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
    flex: 1;
    margin-bottom: 16px;
}

.form-group label {
    font-weight: 500;
    color: var(--text-muted);
}

.form-group input {
    padding: 12px;
    border: 1px solid var(--border);
    border-radius: 8px;
    background: var(--bg);
    color: var(--text-main);
    font-family: inherit;
    font-size: 0.9rem;
}

.form-group input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 3px rgba(0, 0, 0, 0.05);
}

/* Notifications */
.notification-wrapper {
    position: relative;
}

.notification-dropdown {
    position: absolute;
    top: calc(100% + 12px);
    right: 0;
    width: 360px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-lg);
    display: none;
    flex-direction: column;
    z-index: 100;
    overflow: hidden;
}

.notification-dropdown.show {
    display: flex;
}

.notification-header {
    padding: 16px 20px;
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.notification-header h3 {
    font-size: 1rem;
    font-weight: 600;
}

.mark-read {
    font-size: 0.8rem;
    color: var(--brand, #4f46e5);
    text-decoration: none;
}

.notification-list {
    max-height: 400px;
    overflow-y: auto;
}

.notification-item {
    padding: 16px 20px;
    display: flex;
    gap: 16px;
    text-decoration: none;
    color: inherit;
    border-bottom: 1px solid var(--border);
    transition: background 0.2s;
}

.notification-item:hover {
    background: var(--surface-hover);
}

.notification-item.unread {
    background: rgba(79, 70, 229, 0.03);
}

.notification-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.icon-blue { background: rgba(59, 130, 246, 0.1); color: #3b82f6; }
.icon-green { background: rgba(16, 185, 129, 0.1); color: #10b981; }
.icon-orange { background: rgba(245, 158, 11, 0.1); color: #f59e0b; }
.icon-red { background: rgba(239, 68, 68, 0.1); color: #ef4444; }

.notification-content p {
    margin: 0 0 4px 0;
    font-size: 0.85rem;
    line-height: 1.4;
}

.notification-content span {
    font-size: 0.75rem;
    color: var(--text-light);
}

.notification-footer {
    padding: 12px;
    text-align: center;
    background: var(--surface-hover);
}

.view-all-notifications {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
    text-decoration: none;
}

.notification-dot {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 8px;
    height: 8px;
    background: #ef4444;
    border: 2px solid var(--surface);
    border-radius: 50%;
}

.dashboard-btn-group-start {
    border-radius: 8px 0 0 8px;
}

.dashboard-btn-group-end {
    border-radius: 0 8px 8px 0;
    border-left: none;
}

.dashboard-expense-value {
    color: #dc2626;
}

.dashboard-muted-note {
    font-size: 0.75rem;
    color: #737373;
    margin-top: 12px;
}

.dashboard-trend-warning {
    background: #fefce8;
    color: #a16207;
}

.dashboard-avatar-stack {
    display: flex;
    margin-top: 16px;
    margin-left: 4px;
}

.dashboard-avatar-count {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: 2px solid white;
    margin-left: -4px;
    background: #f1f5f9;
    font-size: 0.6rem;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.dashboard-filter-active {
    border-radius: 0;
    background: #171717;
    color: #fff;
}

.dashboard-dot-revenue { background: #171717; }
.dashboard-dot-expense { background: #6366f1; }
.dashboard-dot-margin { background: #fbbf24; }

.dashboard-chart-line-revenue { stroke: #171717; stroke-width: 3; fill: none; }
.dashboard-chart-line-expense { stroke: #6366f1; stroke-width: 2; opacity: 0.8; fill: none; }
.dashboard-chart-line-margin { stroke: #fbbf24; stroke-dasharray: 4; stroke-width: 2; fill: none; }

.dashboard-t-icon-invoice { background: #f0f9ff; }
.dashboard-t-icon-invoice-color { color: #0284c7; }
.dashboard-t-icon-empty { background: #f1f5f9; }
.dashboard-t-icon-empty-color { color: #737373; }
.dashboard-amount-paid { color: #16a34a; }
.dashboard-amount-overdue { color: #dc2626; }
.dashboard-amount-pending { color: #a16207; }
.dashboard-amount-empty { color: #737373; }

.dashboard-widget-btn {
    width: 100%;
    margin-top: 24px;
    background: transparent;
    border: 1px dashed #eaeaea;
    color: #737373;
    box-shadow: none;
}

.dashboard-row-equal { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.dashboard-row-single { display: grid; grid-template-columns: 1fr; gap: 24px; }
.dashboard-header-actions { display: flex; gap: 12px; align-items: center; }
.dashboard-filter-wrapper { width: 220px; position: relative; }
.dashboard-filter-icon { position: absolute; left: 12px; top: 50%; transform: translateY(-50%); color: #a3a3a3; font-size: 0.9rem; }

.dashboard-filter-input {
    padding: 8px 12px 8px 36px;
    font-size: 0.85rem;
    width: 100%;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    background: #fff;
    transition: all 0.2s ease;
}

.dashboard-filter-input:focus {
    border-color: #171717;
    box-shadow: 0 0 0 3px rgba(23, 23, 23, 0.05);
    outline: none;
}

.dashboard-bulk-btn { padding: 8px 18px; font-size: 0.85rem; border-radius: 10px; }
.dashboard-text-end { text-align: right; }
.dashboard-strong { font-weight: 600; color: #111827; }
.dashboard-meta-text { color: #6b7280; font-size: 0.75rem; margin-top: 2px; }

/* Enhanced Table Styling */
.data-table thead th {
    background: #f9fafb;
    padding: 12px 16px;
    font-weight: 600;
    color: #4b5563;
    border-bottom: 2px solid #f3f4f6;
}

.data-table tbody td {
    padding: 16px;
    vertical-align: middle;
}

/* Card Refinement */
.card {
    background: #ffffff;
    border-radius: 12px;
    border: 1px solid #f1f5f9;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.02), 0 1px 2px -1px rgba(0, 0, 0, 0.02);
    padding: 32px;
    height: 100%;
}

.card-header {
    padding: 0;
    background: transparent !important;
    border-bottom: none;
}

.dashboard-row-equal .card {
    height: 100%;
}

.dashboard-days-overdue { color: #ef4444; font-weight: 600; padding: 2px 8px; background: #fef2f2; border-radius: 6px; font-size: 0.8rem; }
.dashboard-days-today { color: #f97316; font-weight: 600; padding: 2px 8px; background: #fff7ed; border-radius: 6px; font-size: 0.8rem; }
.dashboard-days-near { color: #d97706; padding: 2px 8px; background: #fffbeb; border-radius: 6px; font-size: 0.8rem; }
.dashboard-days-normal { color: #6b7280; padding: 2px 8px; background: #f9fafb; border-radius: 6px; font-size: 0.8rem; }
.dashboard-progress-wrap { display: flex; align-items: center; }

.dashboard-progress {
    width: 100%;
    height: 8px;
    border-radius: 8px;
    overflow: hidden;
}

.dashboard-progress::-webkit-progress-bar {
    background: #e5e7eb;
    border-radius: 8px;
}

.dashboard-progress::-webkit-progress-value {
    background: #171717;
    border-radius: 8px;
}

.dashboard-progress-income::-webkit-progress-value { background: #16a34a; }
.dashboard-progress-expense::-webkit-progress-value { background: #dc2626; }

.dashboard-empty-state { text-align: center; padding: 32px; color: #737373; }
.dashboard-empty-icon { font-size: 2rem; margin-bottom: 8px; display: block; }
.dashboard-empty-subtext { font-size: 0.75rem; margin-top: 4px; }
.dashboard-empty-inline { text-align: center; padding: 28px; color: #737373; }
.dashboard-expense-cell { font-weight: 600; color: #dc2626; }

.dashboard-badge-paid { background: #dcfce7; color: #166534; border: 1px solid #86efac; }
.dashboard-badge-overdue { background: #fee2e2; color: #991b1b; border: 1px solid #fecaca; }
.dashboard-badge-pending,
.dashboard-badge-sent,
.dashboard-badge-unpaid { background: #fef3c7; color: #92400e; border: 1px solid #fde68a; }
.dashboard-badge-partial { background: #dbeafe; color: #1d4ed8; border: 1px solid #93c5fd; }
.dashboard-badge-draft { background: #f3f4f6; color: #374151; border: 1px solid #d1d5db; }

@media (max-width: 992px) {
    .hero-panel { flex-direction: column; align-items: flex-start; gap: 24px; }
    .hero-actions { width: 100%; flex-direction: row; flex-wrap: wrap; }
    .hero-actions .btn-group { width: 100%; }
    .hero-actions button { flex: 1; min-width: 140px; }
    
    .dashboard-header-actions { width: 100%; flex-direction: column; align-items: stretch; gap: 12px; margin-top: 16px; }
    .dashboard-filter-wrapper { width: 100%; }
    .dashboard-row-equal { grid-template-columns: 1fr; }
    
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 16px; }
    
    .data-table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; }
}

@media (max-width: 576px) {
    .stats-grid { grid-template-columns: 1fr; }
    .welcome-header h2 { font-size: 1.5rem; }
    .hero-actions button { width: 100%; flex: none; }
    .card { padding: 16px; }
}
