main > .container, main > .container-fluid
{
    padding: 90px 15px 20px;
}

/* ===================================================================
 * Sidebar navigation (Frontend/portal unit kerja) — disalin dari
 * backend, lihat common/docs/decisions/0029-sidebar-backend.md dan
 * common/docs/decisions/0036-sidebar-frontend.md
 * =================================================================== */
:root {
    --sidebar-width: 17rem;
    --sidebar-width-collapsed: 4.5rem;
}

.app-sidebar-toggle-input {
    display: none;
}

.app-shell {
    min-height: 100vh;
}

.app-sidebar {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--sidebar-width);
    display: flex;
    flex-direction: column;
    background: linear-gradient(165deg, var(--accent-dark, #1e293b) 0%, #020617 100%);
    color: #e2e8f0;
    z-index: 1040;
    transition: transform .2s ease, width .2s ease;
}

.app-sidebar-collapse-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 1.8rem;
    height: 1.8rem;
    margin-left: auto;
    flex: none;
    border: none;
    border-radius: .4rem;
    background: transparent;
    color: rgba(226, 232, 240, .7);
    cursor: pointer;
}

.app-sidebar-collapse-toggle:hover {
    background: rgba(255, 255, 255, .1);
    color: #fff;
}

.app-sidebar-collapse-toggle svg {
    width: 1.05rem;
    height: 1.05rem;
    transition: transform .2s ease;
}

.app-sidebar-brand {
    display: flex;
    align-items: center;
    gap: .65rem;
    padding: 1.25rem 1.25rem;
    border-bottom: 1px solid rgba(255, 255, 255, .1);
    flex: none;
}

.app-sidebar-brand-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.1rem;
    height: 2.1rem;
    border-radius: .6rem;
    background: rgba(255, 255, 255, .12);
    border: 1px solid rgba(255, 255, 255, .22);
    flex: none;
}

.app-sidebar-brand-icon svg {
    width: 1.2rem;
    height: 1.2rem;
}

.app-sidebar-brand-text {
    font-weight: 700;
    font-size: 1.02rem;
    letter-spacing: .01em;
    color: #fff;
}

.app-sidebar-nav {
    flex: 1 1 auto;
    overflow-y: auto;
    padding: .85rem .75rem;
}

.app-sidebar-header {
    font-size: .68rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .1em;
    color: rgba(226, 232, 240, .45);
    padding: 1rem .6rem .35rem;
}

.app-sidebar-nav .app-sidebar-header:first-child {
    padding-top: .35rem;
}

.app-sidebar-link {
    display: flex;
    align-items: center;
    gap: .75rem;
    padding: .55rem .6rem;
    margin-bottom: .1rem;
    border-radius: .5rem;
    color: rgba(226, 232, 240, .82);
    text-decoration: none;
    font-size: .89rem;
    width: 100%;
    border: none;
    background: transparent;
    text-align: left;
    cursor: pointer;
}

.app-sidebar-link svg {
    width: 1.1rem;
    height: 1.1rem;
    flex: none;
    opacity: .85;
}

.app-sidebar-link:hover {
    background: rgba(255, 255, 255, .08);
    color: #fff;
    text-decoration: none;
}

.app-sidebar-link.active {
    background: rgba(255, 255, 255, .14);
    color: #fff;
    box-shadow: inset 3px 0 0 var(--accent-light, #ef4444);
}

.app-sidebar-footer {
    flex: none;
    padding: .75rem;
    border-top: 1px solid rgba(255, 255, 255, .1);
}

.app-sidebar-logout {
    color: rgba(226, 232, 240, .6);
}

.app-sidebar-logout:hover {
    color: #fca5a5;
}

.app-sidebar-backdrop {
    display: none;
}

.app-content {
    margin-left: var(--sidebar-width);
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    transition: margin-left .2s ease;
}

.app-topbar {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: .85rem 1.5rem;
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
    position: sticky;
    top: 0;
    z-index: 1020;
}

.app-topbar .breadcrumb {
    margin-bottom: 0;
    background: transparent;
    padding: 0;
}

.app-topbar-toggle {
    display: none;
    align-items: center;
    justify-content: center;
    width: 2.2rem;
    height: 2.2rem;
    border-radius: .5rem;
    color: #334155;
    cursor: pointer;
    flex: none;
}

.app-topbar-toggle:hover {
    background: #f1f5f9;
}

.app-topbar-toggle svg {
    width: 1.3rem;
    height: 1.3rem;
}

.app-main {
    flex: 1 1 auto;
    padding: 1.5rem;
}

.app-footer {
    flex: none;
    padding: 1rem 1.5rem;
    font-size: .82rem;
    color: #94a3b8;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
}

@media (min-width: 992px) {
    .app-sidebar-collapse-toggle {
        display: inline-flex;
    }

    body.sidebar-collapsed .app-sidebar {
        width: var(--sidebar-width-collapsed);
    }

    body.sidebar-collapsed .app-content {
        margin-left: var(--sidebar-width-collapsed);
    }

    body.sidebar-collapsed .app-sidebar-brand {
        justify-content: center;
        padding-left: .5rem;
        padding-right: .5rem;
    }

    body.sidebar-collapsed .app-sidebar-brand-text,
    body.sidebar-collapsed .app-sidebar-header,
    body.sidebar-collapsed .app-sidebar-link span,
    body.sidebar-collapsed .app-sidebar-logout span {
        display: none;
    }

    body.sidebar-collapsed .app-sidebar-collapse-toggle {
        margin-left: 0;
    }

    body.sidebar-collapsed .app-sidebar-collapse-toggle svg {
        transform: rotate(180deg);
    }

    body.sidebar-collapsed .app-sidebar-link {
        justify-content: center;
    }
}

@media (max-width: 991.98px) {
    .app-sidebar {
        transform: translateX(-100%);
    }

    .app-content {
        margin-left: 0;
    }

    .app-topbar-toggle {
        display: inline-flex;
    }

    .app-sidebar-toggle-input:checked ~ .app-sidebar {
        transform: translateX(0);
        box-shadow: 0 0 40px rgba(0, 0, 0, .35);
    }

    .app-sidebar-toggle-input:checked ~ .app-sidebar-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        background: rgba(15, 23, 42, .5);
        z-index: 1030;
    }
}

.footer {
    background-color: #f5f5f5;
    font-size: .9em;
    height: 60px;
}

.footer > .container, .footer > .container-fluid {
    padding-right: 15px;
    padding-left: 15px;
}

.not-set {
    color: #c55;
    font-style: italic;
}

/* add sorting icons to gridview sort links */
a.asc:after, a.desc:after {
    content: '';
    left: 3px;
    display: inline-block;
    width: 0;
    height: 0;
    border: solid 5px transparent;
    margin: 4px 4px 2px 4px;
    background: transparent;
}

a.asc:after {
    border-bottom: solid 7px #212529;
    border-top-width: 0;
}

a.desc:after {
    border-top: solid 7px #212529;
    border-bottom-width: 0;
}

.grid-view th,
.grid-view td:last-child {
    white-space: nowrap;
}

.grid-view .filters input,
.grid-view .filters select {
    min-width: 50px;
}

.hint-block {
    display: block;
    margin-top: 5px;
    color: #999;
}

.error-summary {
    color: #a94442;
    background: #fdf7f7;
    border-left: 3px solid #eed3d7;
    padding: 10px 20px;
    margin: 0 0 15px 0;
}

/* align the logout "link" (button in form) of the navbar */
.navbar form > button.logout {
    padding-top: 7px;
    color: rgba(255, 255, 255, 0.5);
}

@media(max-width:767px) {
    .navbar form > button.logout {
        display:block;
        text-align: left;
        width: 100%;
        padding: 10px 0;
    }
}

.navbar form > button.logout:focus,
.navbar form > button.logout:hover {
    text-decoration: none;
    color: rgba(255, 255, 255, 0.75);
}

.navbar form > button.logout:focus {
    outline: none;
}

/* style breadcrumb widget as in previous bootstrap versions */
.breadcrumb {
    background-color: var(--bs-gray-200);
    border-radius: .25rem;
    padding: .75rem 1rem;
}

.breadcrumb-item > a
{
    text-decoration: none;
}/* ===================================================================
 * SIMANJA-NG — Auth & Dashboard Design System
 * =================================================================== */
.auth-body {
    margin: 0;
    min-height: 100vh;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background: #f1f5f9;
}

.auth-wrapper {
    display: flex;
    min-height: 100vh;
}

.auth-pattern-b {
    flex-direction: row-reverse;
}

.auth-brand {
    position: relative;
    flex: 1 1 46%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 3rem;
    background: linear-gradient(135deg, var(--accent-dark) 0%, var(--accent-light) 100%);
    color: #fff;
    overflow: hidden;
}

.auth-brand::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(circle at 15% 20%, rgba(255, 255, 255, .14) 0, transparent 40%),
        radial-gradient(circle at 85% 80%, rgba(255, 255, 255, .10) 0, transparent 45%),
        repeating-linear-gradient(135deg, rgba(255, 255, 255, .05) 0 2px, transparent 2px 40px);
    pointer-events: none;
}

.auth-brand-inner {
    position: relative;
    max-width: 26rem;
}

.auth-logo {
    display: flex;
    align-items: center;
    gap: .6rem;
    margin-bottom: 2.75rem;
}

.auth-logo-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: .75rem;
    background: rgba(255, 255, 255, .16);
    border: 1px solid rgba(255, 255, 255, .28);
    flex: none;
}

.auth-logo-icon svg {
    width: 1.4rem;
    height: 1.4rem;
}

.auth-logo-text {
    font-size: 1.15rem;
    font-weight: 700;
    letter-spacing: .02em;
}

.auth-logo-accent {
    opacity: .75;
    font-weight: 500;
}

.auth-module-badge {
    display: inline-block;
    font-size: .72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: .12em;
    padding: .3rem .7rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, .16);
    border: 1px solid rgba(255, 255, 255, .28);
    margin-bottom: 1rem;
}

.auth-module-title {
    font-size: 2.5rem;
    font-weight: 800;
    line-height: 1.1;
    margin: 0 0 1rem;
}

.auth-tagline {
    font-size: 1rem;
    line-height: 1.6;
    color: rgba(255, 255, 255, .88);
    margin: 0 0 2.5rem;
}

.auth-brand-footer {
    font-size: .78rem;
    color: rgba(255, 255, 255, .65);
    border-top: 1px solid rgba(255, 255, 255, .22);
    padding-top: 1rem;
}

.auth-form-panel {
    flex: 1 1 54%;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2.5rem 1.5rem;
    background: #f8fafc;
}

.auth-form-card {
    width: 100%;
    max-width: 24rem;
}

.auth-form-title {
    font-size: 1.6rem;
    font-weight: 700;
    color: #0f172a;
    margin-bottom: .35rem;
}

.auth-form-subtitle {
    color: #64748b;
    font-size: .92rem;
    margin-bottom: 1.75rem;
}

.auth-form .form-control {
    padding: .65rem .9rem;
    border-radius: .6rem;
    border: 1px solid #e2e8f0;
    font-size: .95rem;
}

.auth-form .form-control:focus {
    border-color: var(--accent-light);
    box-shadow: 0 0 0 .2rem rgba(0, 0, 0, .06);
}

.auth-form label {
    font-size: .85rem;
    font-weight: 600;
    color: #334155;
}

.auth-form-row {
    margin-bottom: 1.1rem;
}

.auth-submit-btn {
    width: 100%;
    padding: .75rem 1rem;
    border: none;
    border-radius: .6rem;
    font-weight: 700;
    font-size: .95rem;
    color: #fff;
    background: linear-gradient(135deg, var(--accent-dark), var(--accent-light));
    transition: filter .15s ease, transform .15s ease;
}

.auth-submit-btn:hover {
    filter: brightness(1.08);
    color: #fff;
}

.auth-submit-btn:active {
    transform: translateY(1px);
}

.auth-form-footer {
    margin-top: 2rem;
    font-size: .78rem;
    color: #94a3b8;
}

@media (max-width: 860px) {
    .auth-wrapper {
        flex-direction: column;
    }
    .auth-brand, .auth-form-panel {
        flex: none;
        min-height: auto;
    }
    .auth-brand {
        padding: 2.5rem 1.5rem;
    }
    .auth-module-title {
        font-size: 2rem;
    }
}

/* Dark "pusat kendali" variant — dipakai oleh backend/Komando */
.auth-dark-wrapper {
    margin: 0;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2rem 1rem;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    background: radial-gradient(circle at 50% 0%, #1e293b 0%, #0f172a 60%, #020617 100%);
    position: relative;
    overflow: hidden;
}

.auth-dark-wrapper::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: repeating-linear-gradient(90deg, rgba(255, 255, 255, .03) 0 1px, transparent 1px 48px),
                       repeating-linear-gradient(0deg, rgba(255, 255, 255, .03) 0 1px, transparent 1px 48px);
    pointer-events: none;
}

.auth-dark-card {
    position: relative;
    width: 100%;
    max-width: 25rem;
    background: rgba(15, 23, 42, .72);
    border: 1px solid rgba(148, 163, 184, .18);
    border-radius: 1rem;
    padding: 2.5rem 2.25rem;
    box-shadow: 0 25px 60px -15px rgba(0, 0, 0, .6);
}

.auth-dark-card .auth-logo {
    justify-content: center;
    margin-bottom: 1.5rem;
}

.auth-dark-card .auth-logo-icon {
    background: rgba(239, 68, 68, .14);
    border-color: rgba(239, 68, 68, .35);
    color: #f87171;
}

.auth-dark-card .auth-logo-text {
    color: #f8fafc;
}

.auth-dark-card .auth-module-badge {
    display: block;
    text-align: center;
    margin: 0 auto 1.25rem;
    width: fit-content;
    background: rgba(239, 68, 68, .14);
    border-color: rgba(239, 68, 68, .35);
    color: #fca5a5;
}

.auth-dark-card .auth-form-title {
    color: #f8fafc;
    text-align: center;
}

.auth-dark-card .auth-form-subtitle {
    color: #94a3b8;
    text-align: center;
}

.auth-dark-card .auth-form .form-control {
    background: rgba(255, 255, 255, .05);
    border-color: rgba(148, 163, 184, .25);
    color: #e2e8f0;
}

.auth-dark-card .auth-form .form-control::placeholder {
    color: #64748b;
}

.auth-dark-card .auth-form label {
    color: #cbd5e1;
}

.auth-dark-card .auth-submit-btn {
    background: linear-gradient(135deg, #7f1d1d, #ef4444);
}

.auth-dark-card .auth-form-footer {
    color: #64748b;
    text-align: center;
}

/* ===== Module identity in navbar ===== */
.navbar-module {
    background: linear-gradient(135deg, var(--accent-dark, #1e293b), var(--accent-light, #3b82f6));
}

.navbar-module-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 1.9rem;
    height: 1.9rem;
    border-radius: .5rem;
    background: rgba(255, 255, 255, .16);
    border: 1px solid rgba(255, 255, 255, .28);
    margin-right: .5rem;
}

.navbar-module-icon svg {
    width: 1.05rem;
    height: 1.05rem;
}

/* ===== Dashboard welcome hero ===== */
.module-hero {
    border-radius: 1rem;
    padding: 1.5rem 2.25rem;
    color: #fff;
    background: linear-gradient(135deg, var(--accent-dark, #1e293b), var(--accent-light, #3b82f6));
    position: relative;
    overflow: hidden;
    display: flex;
    align-items: center;
    gap: 1.1rem;
}

.module-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: radial-gradient(circle at 90% 10%, rgba(255, 255, 255, .18) 0, transparent 45%);
    pointer-events: none;
}

.module-hero-icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: .7rem;
    background: rgba(255, 255, 255, .16);
    border: 1px solid rgba(255, 255, 255, .28);
    flex: none;
    margin-bottom: 0;
}

.module-hero-icon svg {
    width: 1.3rem;
    height: 1.3rem;
}

.module-hero h1 {
    position: relative;
    font-weight: 800;
    font-size: 1.5rem;
    margin-bottom: .2rem;
}

.module-hero p {
    position: relative;
    color: rgba(255, 255, 255, .9);
    max-width: 42rem;
    margin: 0;
    font-size: .92rem;
}

.info-tile {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: .75rem;
    padding: 1.1rem 1.25rem;
    height: 100%;
    /* `.stretched-link` di dalam tile ini butuh ancestor positioned
       terdekat supaya area kliknya pas di kartu ini — tanpa ini,
       Bootstrap menempelkannya ke ancestor positioned berikutnya di
       DOM (bisa jauh lebih besar dari kartunya sendiri). */
    position: relative;
}

.info-tile-label {
    font-size: .75rem;
    text-transform: uppercase;
    letter-spacing: .08em;
    color: #94a3b8;
    font-weight: 700;
    margin-bottom: .35rem;
}

.info-tile-value {
    font-size: .98rem;
    color: #1e293b;
    font-weight: 600;
}

/* Warna link konten mengikuti aksen tier (lihat --accent-dark/--accent-light
   di <body>, common/docs/decisions/0003-identitas-visual-login-dashboard.md).
   Tombol (.btn) dikecualikan supaya warna varian Bootstrap-nya tidak tertimpa. */
main a:not(.btn) {
    color: var(--accent-dark, var(--bs-link-color));
}

main a:not(.btn):hover {
    color: var(--accent-light, var(--bs-link-hover-color));
}
