.card {
    background: #ffffff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.08);
}

.page {
    min-height: 100%;
    padding: 24px;
}

.page-title {
    margin: 0 0 20px;
    font-size: 24px;
    font-weight: 700;
}

.grid {
    display: grid;
    gap: 16px;
}

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

.stat-value {
    margin-top: 10px;
    font-size: 28px;
    font-weight: 700;
}

/*
|--------------------------------------------------------------------------
| Authenticated Application Shell
|--------------------------------------------------------------------------
*/

.app-shell {
    height: 100vh;
    display: grid;
    grid-template-columns: 250px minmax(0, 1fr);
    overflow: hidden;
    background: #f4f7f5;
}

/*
|--------------------------------------------------------------------------
| Sidebar
|--------------------------------------------------------------------------
|
| The sidebar remains fixed inside the viewport.
| It does not scroll with the dashboard or product workspace.
|
*/

.app-sidebar {
    position: sticky;
    top: 0;

    width: 250px;
    height: 100vh;
    min-height: 0;
    overflow-y: auto;

    display: flex;
    flex-direction: column;

    padding: 24px 18px;
    background: #123524;
    color: #ffffff;
}

.sidebar-brand {
    flex: 0 0 auto;

    display: flex;
    align-items: center;
    gap: 12px;

    padding: 0 8px 24px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.12);
}

.sidebar-brand-mark {
    width: 42px;
    height: 42px;
    flex: 0 0 42px;

    display: grid;
    place-items: center;

    border-radius: 12px;
    background: #ffffff;
    color: #0a7c3e;
    font-weight: 800;
}

.sidebar-brand strong,
.sidebar-brand small {
    display: block;
}

.sidebar-brand small {
    margin-top: 3px;
    opacity: 0.65;
}

.sidebar-nav {
    flex: 0 0 auto;

    display: grid;
    gap: 7px;

    margin-top: 28px;
}

.sidebar-nav a {
    display: block;
    padding: 13px 14px;

    border-radius: 10px;

    color: rgba(255, 255, 255, 0.78);
    text-decoration: none;
    font-weight: 600;
}

.sidebar-nav a:hover,
.sidebar-nav a.is-active {
    background: rgba(255, 255, 255, 0.12);
    color: #ffffff;
}

.sidebar-logout {
    width: 100%;
    margin-top: auto;

    background: rgba(255, 255, 255, 0.1);
}

.sidebar-logout:hover {
    background: rgba(255, 255, 255, 0.18);
}

/*
|--------------------------------------------------------------------------
| Main Application Area
|--------------------------------------------------------------------------
*/

.app-main {
    min-width: 0;
    height: 100vh;

    display: flex;
    flex-direction: column;

    overflow: hidden;
}

/*
|--------------------------------------------------------------------------
| Header
|--------------------------------------------------------------------------
*/

.app-header {
    position: sticky;
    top: 0;
    z-index: 20;

    flex: 0 0 76px;

    min-height: 76px;
    display: flex;
    align-items: center;
    gap: 16px;

    padding: 14px 28px;

    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
}

.app-header-title {
    min-width: 0;

    display: flex;
    flex-direction: column;
}

.app-header-title strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.app-header-title span {
    margin-top: 3px;
    color: #667085;
    font-size: 13px;
}

.sidebar-toggle {
    display: none;
    width: auto;
    margin: 0;
    padding: 9px 12px;
}

.header-logout {
    width: auto;
    margin: 0 0 0 auto;
    padding: 10px 16px;
}

/*
|--------------------------------------------------------------------------
| Scrollable Workspace
|--------------------------------------------------------------------------
|
| Only this section scrolls.
|
*/

.app-workspace {
    flex: 1 1 auto;
    min-width: 0;
    min-height: 0;

    overflow-y: auto;
    overflow-x: hidden;

    padding: 28px;
}

.app-workspace > #screen-root {
    min-height: 100%;
}

/*
|--------------------------------------------------------------------------
| Transaction Bar
|--------------------------------------------------------------------------
*/

.transaction-bar {
    flex: 0 0 76px;
    min-height: 76px;

    display: flex;
    align-items: center;
    gap: 18px;

    padding: 12px 20px;

    background: #ffffff;
    border-bottom: 1px solid #e5e7eb;
}

.transaction-shop,
.transaction-metric {
    display: flex;
    align-items: center;
    gap: 6px;

    white-space: nowrap;
}

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

.transaction-shop span,
.transaction-metric span {
    color: #667085;
    font-size: 12px;
}

.transaction-shop strong {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;

    color: #123524;
}

.transaction-metric strong {
    color: #123524;
}

.transaction-invoice-button,
.transaction-account-button {
    width: auto;
    margin: 0;
    padding: 10px 14px;

    border-radius: 9px;
}

.transaction-invoice-button:disabled {
    opacity: 0.45;
    cursor: not-allowed;
}

.transaction-account-button {
    background: #eef5f1;
    color: #123524;
}

}

/*
|--------------------------------------------------------------------------
| Responsive
|--------------------------------------------------------------------------
*/

@media (max-width: 850px) {
    .app-shell {
        grid-template-columns: minmax(0, 1fr);
    }

    .app-sidebar {
        position: fixed;
        z-index: 100;
        top: 0;
        bottom: 0;
        left: 0;

        width: 250px;
        height: 100vh;

        transform: translateX(-100%);
        transition: transform 0.2s ease;
    }

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

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

    .app-header {
        padding: 12px 18px;
    }

    .app-workspace {
        padding: 18px;
    }
}

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

    .header-logout {
        padding: 9px 12px;
    }

    .app-header-title span {
        display: none;
    }

	@media (max-width: 980px) {
    .transaction-bar {
        gap: 10px;
        overflow-x: auto;
    }

    .transaction-shop {
        min-width: 180px;
    }
}

@media (max-width: 700px) {
    .transaction-bar {
        min-height: auto;
        flex-wrap: wrap;
        padding: 10px 14px;
    }

    .transaction-shop {
        flex: 1 1 calc(100% - 50px);
    }

    .transaction-metric {
        flex: 0 0 auto;
    }

    .transaction-invoice-button {
        flex: 1 1 auto;
    }
}