/* =========================================================
   SIAP BPSDM
   STYLE UTAMA
   ========================================================= */


/* =========================================================
   VARIABLE
   ========================================================= */

:root {

    --navy: #061a3a;
    --navy2: #0a2b63;

    --blue: #1455b8;
    --blue2: #2d75dc;

    --bg: #f4f7fb;
    --text: #17233c;
    --muted: #718096;

    --line: #e7edf5;

    --white: #ffffff;

}


/* =========================================================
   RESET
   ========================================================= */

* {
    box-sizing: border-box;
}


html {
    margin: 0;
    padding: 0;
    min-height: 100%;
}


body {
    margin: 0;
    padding: 0;
    min-height: 100%;

    background: var(--bg);
    color: var(--text);

    font-family:
        Inter,
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        sans-serif;
}


body.sidebar-open {
    overflow: hidden;
}


a {
    text-decoration: none;
}


/* =========================================================
   APP
   ========================================================= */

.app {
    min-height: 100vh;
}


/* =========================================================
   SIDEBAR
   ========================================================= */

.sidebar {

    position: fixed;

    left: 0;
    top: 0;
    bottom: 0;

    width: 260px;
    height: 100vh;

    padding: 22px 15px;

    background:
        linear-gradient(
            180deg,
            var(--navy),
            #0b3476
        );

    color: #fff;

    z-index: 1050;

    display: flex;
    flex-direction: column;

    box-shadow:
        10px 0 30px
        rgba(3, 24, 58, 0.12);

    overflow-x: hidden;
    overflow-y: auto;

    -webkit-overflow-scrolling: touch;
}


.sidebar::-webkit-scrollbar {
    width: 5px;
}


.sidebar::-webkit-scrollbar-track {
    background: transparent;
}


.sidebar::-webkit-scrollbar-thumb {
    background: rgba(255,255,255,.15);
    border-radius: 20px;
}


/* =========================================================
   BRAND
   ========================================================= */

.sidebar-brand {

    display: flex;
    align-items: center;

    gap: 12px;

    padding: 3px 8px 26px;

    flex-shrink: 0;
}


.brand-icon {

    width: 45px;
    height: 45px;
    min-width: 45px;

    border-radius: 13px;

    background: #ffffff;

    color: var(--navy2);

    display: flex;
    align-items: center;
    justify-content: center;

    font-size: 21px;
}


.brand-name {

    font-size: 18px;

    font-weight: 800;

    letter-spacing: .3px;

    color: #fff;
}


.brand-subtitle {

    font-size: 9px;

    letter-spacing: 1.3px;

    color: #adc3e8;

    margin-top: 2px;

}


/* =========================================================
   SIDEBAR MENU
   ========================================================= */

.sidebar-menu {

    width: 100%;

    flex: 0 0 auto;
}


.menu-title {

    display: block;

    font-size: 10px;

    font-weight: 700;

    letter-spacing: 1.4px;

    color: #89a6d8;

    margin:
        14px 8px 7px;
}


/* =========================================================
   SIDEBAR LINK
   ========================================================= */

.sidebar-link {

    width: 100%;

    min-height: 42px;

    display: flex !important;

    align-items: center;

    gap: 12px;

    color: #dce8fb;

    padding: 10px 12px;

    border-radius: 10px;

    margin: 3px 0;

    font-size: 13px;

    font-weight: 500;

    line-height: 1.2;

    transition:
        background .18s ease,
        color .18s ease,
        transform .18s ease;

    cursor: pointer;

    position: relative;

    z-index: 10;

    pointer-events: auto;
}


.sidebar-link i {

    width: 20px;

    min-width: 20px;

    text-align: center;

    font-size: 16px;

    pointer-events: none;
}


.sidebar-link span {

    flex: 1;

    min-width: 0;

    white-space: nowrap;

    overflow: hidden;

    text-overflow: ellipsis;

    pointer-events: none;
}


.sidebar-link:hover {

    background:
        rgba(255,255,255,.12);

    color: #fff;

    transform:
        translateX(2px);
}


.sidebar-link.active {

    background:
        rgba(255,255,255,.17);

    color: #fff;

    font-weight: 700;
}


/* =========================================================
   SIDEBAR USER
   ========================================================= */

.sidebar-user {

    margin-top: auto;

    padding-top: 16px;

    border-top:
        1px solid
        rgba(255,255,255,.12);

    flex-shrink: 0;
}


.sidebar-user-box {

    display: flex;

    align-items: center;

    gap: 10px;

    padding: 9px 8px;

    border-radius: 12px;

    background:
        rgba(255,255,255,.07);
}


.sidebar-user-icon {

    width: 38px;
    height: 38px;
    min-width: 38px;

    border-radius: 50%;

    background:
        rgba(255,255,255,.12);

    display: flex;

    align-items: center;
    justify-content: center;

    color: #fff;
}


.sidebar-user-info {

    min-width: 0;

    flex: 1;
}


.sidebar-user-name {

    color: #fff;

    font-size: 12px;

    font-weight: 700;

    white-space: nowrap;

    overflow: hidden;

    text-overflow: ellipsis;
}


.sidebar-user-role {

    color: #9eb5dc;

    font-size: 10px;

    margin-top: 2px;
}


.sidebar-logout {

    color: #ffccd0 !important;

    margin-top: 5px !important;
}


.sidebar-logout:hover {

    color: #fff !important;

    background:
        rgba(220,53,69,.18);
}


/* =========================================================
   TOPBAR
   ========================================================= */

.topbar {

    height: 78px;

    margin-left: 260px;

    background: #fff;

    border-bottom:
        1px solid
        var(--line);

    display: flex;

    align-items: center;

    padding: 0 30px;

    gap: 15px;

    position: relative;

    z-index: 100;
}


.top-title {

    flex: 1;

    min-width: 0;
}


.top-title .fw-bold {

    font-size: 17px;

    font-weight: 800;
}


.top-title small {

    display: block;

    color: var(--muted);

    font-size: 11px;

    margin-top: 2px;

    white-space: nowrap;

    overflow: hidden;

    text-overflow: ellipsis;
}


/* =========================================================
   PROFILE
   ========================================================= */

.profile-chip {

    display: flex;

    align-items: center;

    gap: 9px;

    background: #f3f6fb;

    border:
        1px solid
        var(--line);

    border-radius: 999px;

    padding: 6px 13px 6px 7px;

    font-size: 12px;

    flex-shrink: 0;
}


.profile-icon {

    width: 34px;
    height: 34px;
    min-width: 34px;

    border-radius: 50%;

    background: #dce9ff;

    color: var(--blue);

    display: flex;

    align-items: center;
    justify-content: center;
}


/* =========================================================
   MAIN
   ========================================================= */

.main {

    margin-left: 260px;

    padding: 28px 30px;

    min-height:
        calc(100vh - 78px);

    position: relative;

    z-index: 1;
}


/* =========================================================
   CARD
   ========================================================= */

.stat-card,
.card-modern {

    background: #fff;

    border:
        1px solid
        var(--line);

    border-radius: 17px;

    box-shadow:
        0 8px 25px
        rgba(14,40,80,.055);
}


.stat-card {

    padding: 21px;

    height: 100%;

    transition:
        transform .18s ease,
        box-shadow .18s ease;
}


.stat-card:hover {

    transform:
        translateY(-2px);

    box-shadow:
        0 12px 30px
        rgba(14,40,80,.09);
}


.stat-icon {

    width: 49px;
    height: 49px;

    border-radius: 13px;

    background: #e9f1ff;

    color: var(--blue);

    display: flex;

    align-items: center;
    justify-content: center;

    font-size: 20px;
}


.stat-value {

    font-size: 29px;

    font-weight: 800;

    line-height: 1.1;
}


.section-title {

    font-size: 17px;

    font-weight: 750;
}


/* =========================================================
   TABLE
   ========================================================= */

.table {

    margin-bottom: 0;
}


.table thead th {

    font-size: 11px;

    text-transform: uppercase;

    letter-spacing: .35px;

    color: #64748b;

    background: #f7f9fc;

    border-bottom:
        1px solid
        var(--line);

    white-space: nowrap;
}


.table td {

    font-size: 13px;

    vertical-align: middle;

    border-color: #eef2f7;
}


/* =========================================================
   FORM
   ========================================================= */

.form-control,
.form-select {

    border-radius: 10px;

    border-color: #dce4ef;

    padding: 10px 12px;
}


.form-control:focus,
.form-select:focus {

    border-color: #75a4e8;

    box-shadow:
        0 0 0 .2rem
        rgba(20,85,184,.10);
}


/* =========================================================
   BUTTON
   ========================================================= */

.btn {

    border-radius: 10px;
}


.btn-primary {

    background: var(--blue);

    border-color: var(--blue);
}


.btn-primary:hover {

    background: #0d4295;

    border-color: #0d4295;
}


/* =========================================================
   BADGE
   ========================================================= */

.badge-soft {

    padding: 6px 10px;

    border-radius: 999px;

    font-weight: 600;

    font-size: 11px;
}


/* =========================================================
   EMPTY
   ========================================================= */

.empty {

    padding: 40px;

    text-align: center;

    color: var(--muted);
}


/* =========================================================
   LOGIN
   ========================================================= */

.login-page {

    min-height: 100vh;

    background:
        radial-gradient(
            circle at 15% 20%,
            #194c9a 0,
            #0a2d68 34%,
            #04152f 80%
        );

    display: grid;

    place-items: center;

    padding: 20px;
}


.login-card {

    width:
        min(430px,100%);

    background: #fff;

    border-radius: 25px;

    padding: 35px;

    box-shadow:
        0 28px 80px
        rgba(0,0,0,.3);
}


.login-logo {

    width: 70px;
    height: 70px;

    border-radius: 19px;

    background: #e9f1ff;

    color: var(--navy2);

    display: flex;

    align-items: center;
    justify-content: center;

    font-size: 31px;

    margin: auto;
}


.login-title {

    font-weight: 800;

    font-size: 25px;
}


.login-sub {

    color: var(--muted);

    font-size: 13px;
}


.alert {

    border-radius: 11px;
}


/* =========================================================
   MOBILE MENU BUTTON
   ========================================================= */

.mobile-menu-btn {

    display: none;

    position: fixed;

    top: 12px;
    left: 12px;

    width: 48px;
    height: 48px;

    padding: 0;

    border: none;

    border-radius: 13px;

    background: var(--navy);

    color: #fff;

    align-items: center;
    justify-content: center;

    font-size: 24px;

    cursor: pointer;

    z-index: 99999;

    box-shadow:
        0 8px 25px
        rgba(6,26,58,.30);

    transition:
        transform .15s ease,
        background .15s ease;

    pointer-events: auto;
}


.mobile-menu-btn i {

    pointer-events: none;
}


.mobile-menu-btn:hover {

    background: var(--navy2);
}


.mobile-menu-btn:active {

    transform: scale(.94);
}


.mobile-menu-btn.active {

    background: var(--navy2);
}


/* =========================================================
   MOBILE CLOSE BUTTON
   ========================================================= */

.mobile-close-btn {

    display: none;

    position: absolute;

    top: 14px;
    right: 14px;

    width: 40px;
    height: 40px;

    padding: 0;

    border: none;

    border-radius: 10px;

    background:
        rgba(255,255,255,.12);

    color: #fff;

    align-items: center;
    justify-content: center;

    font-size: 18px;

    cursor: pointer;

    z-index: 99999;

    pointer-events: auto;
}


.mobile-close-btn i {

    pointer-events: none;
}


.mobile-close-btn:hover {

    background:
        rgba(255,255,255,.20);
}


/* =========================================================
   OVERLAY
   ========================================================= */

.sidebar-overlay {

    display: none;

    position: fixed;

    inset: 0;

    width: 100%;
    height: 100%;

    background:
        rgba(0,0,0,.55);

    z-index: 9000;

    cursor: pointer;

    opacity: 0;

    transition:
        opacity .25s ease;

}


.sidebar-overlay.show {

    display: block;

    opacity: 1;
}


/* =========================================================
   MOBILE
   ========================================================= */

@media (max-width: 991px) {


    /* =====================================================
       SIDEBAR
       ===================================================== */

    .sidebar {

        width: 290px;

        height: 100dvh;

        top: 0;
        left: 0;
        bottom: 0;

        padding:
            20px 14px 17px;

        transform:
            translateX(-110%);

        transition:
            transform .28s
            cubic-bezier(.4,0,.2,1);

        z-index: 9500;

        pointer-events: auto;

        overflow-x: hidden;

        overflow-y: auto;
    }


    .sidebar.show {

        transform:
            translateX(0);

        pointer-events: auto;
    }


    /* =====================================================
       MENU BUTTON
       ===================================================== */

    .mobile-menu-btn {

        display: flex;
    }


    /* =====================================================
       CLOSE BUTTON
       ===================================================== */

    .mobile-close-btn {

        display: flex;
    }


    /* =====================================================
       BRAND
       ===================================================== */

    .sidebar-brand {

        padding:
            8px 48px 21px 7px;

        margin-bottom: 5px;

        border-bottom:
            1px solid
            rgba(255,255,255,.08);
    }


    .brand-icon {

        width: 44px;
        height: 44px;

        min-width: 44px;

        background:
            rgba(255,255,255,.12);

        color: #fff;
    }


    .brand-name {

        font-size: 16px;
    }


    .brand-subtitle {

        font-size: 8px;

        letter-spacing: .5px;
    }


    /* =====================================================
       MENU
       ===================================================== */

    .sidebar-menu {

        padding:
            5px 1px 15px;
    }


    .menu-title {

        font-size: 9px;

        margin:
            15px 8px 6px;
    }


    /* =====================================================
       LINKS
       ===================================================== */

    .sidebar-link {

        min-height: 43px;

        padding:
            10px 11px;

        gap: 11px;

        margin:
            2px 0;

        font-size: 13px;

        border-radius: 10px;

        position: relative;

        z-index: 9600;

        pointer-events: auto;

        cursor: pointer;
    }


    .sidebar-link i {

        width: 21px;

        min-width: 21px;

        font-size: 16px;

        pointer-events: none;
    }


    .sidebar-link span {

        white-space: nowrap;

        pointer-events: none;
    }


    .sidebar-link:hover {

        transform: none;
    }


    /* =====================================================
       USER
       ===================================================== */

    .sidebar-user {

        padding-top: 12px;
    }


    .sidebar-user-box {

        padding:
            9px;

        background:
            rgba(255,255,255,.08);
    }


    /* =====================================================
       TOPBAR
       ===================================================== */

    .topbar {

        height: 70px;

        margin-left: 0;

        padding:
            0 14px 0 75px;

        z-index: 100;
    }


    .top-title .fw-bold {

        font-size: 16px;
    }


    .top-title small {

        font-size: 9px;
    }


    /* =====================================================
       PROFILE
       ===================================================== */

    .profile-chip {

        padding: 5px;
    }


    .profile-info {

        display: none !important;
    }


    /* =====================================================
       MAIN
       ===================================================== */

    .main {

        margin-left: 0;

        padding:
            20px 15px;

        min-height:
            calc(100vh - 70px);

        z-index: 1;
    }


}


/* =========================================================
   MOBILE KECIL
   ========================================================= */

@media (max-width: 576px) {


    .sidebar {

        width: 290px;
    }


    .mobile-menu-btn {

        top: 11px;

        left: 11px;

        width: 46px;

        height: 46px;

        border-radius: 13px;

        font-size: 23px;
    }


    .mobile-close-btn {

        top: 14px;

        right: 13px;
    }


    .topbar {

        height: 64px;

        padding:
            0 10px 0 69px;
    }


    .top-title .fw-bold {

        font-size: 15px;
    }


    .top-title small {

        font-size: 8.5px;
    }


    .main {

        padding:
            15px 10px;
    }


    .stat-card {

        border-radius: 17px;
    }


}


/* =========================================================
   HP SANGAT KECIL
   ========================================================= */

@media (max-width: 360px) {


    .sidebar {

        width: 275px;
    }


    .sidebar-link {

        font-size: 12px;
    }


}