*{
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:Arial, sans-serif;
}

body{
    min-height:100vh;
    background-image:
        linear-gradient(
            rgba(255,255,255,.2),
            rgba(255,255,255,.2)
        ),
        url("background.png");

    background-size:cover;
    background-position:center;
    background-repeat:no-repeat;
    background-attachment:fixed;
}

/* =====================================================
   SIDEBAR
===================================================== */

.sidebar{
    position:fixed;
    top:0;
    left:0;
    width:250px;
    height:100vh;

    display:flex;
    flex-direction:column;

    background:linear-gradient(180deg,#0d2f8d,#123fbb);

    overflow:hidden;
    transition:.35s;

    z-index:1000;
}

.sidebar::before{
    content:"";
    position:absolute;
    inset:0;
    background:url("sidebar.png") center bottom no-repeat;
    background-size:100% auto;
    opacity:.15;
}

.sidebar>*{
    position:relative;
    z-index:2;
}

/* =====================================================
   LOGO
===================================================== */

.logo{
    display:flex;
    justify-content:center;
    align-items:center;
    gap:12px;
    color:#fff;
    padding:35px 20px;
    font-size:20px;
    border-bottom:1px solid rgba(255,255,255,.15);
}

.logo i{
    font-size:28px;
}

.logo h2{
    font-size:22px;
}

.sidebar ul{
    list-style:none;
    padding:25px 18px;
}

.sidebar ul li{
    margin-bottom:12px;
}

.sidebar ul li a{
    display:flex;
    align-items:center;
    gap:18px;
    color:white;
    text-decoration:none;
    padding:16px 18px;
    border-radius:14px;
    transition:.3s;
    font-size:18px;
}

.sidebar ul li a i{
    width:22px;
    text-align:center;
    font-size:20px;
}

.sidebar ul li a:hover{
    background:rgba(255,255,255,.12);
    transform:translateX(5px);
}

.sidebar ul li a.active{
    background:#1d63da;
    box-shadow:0 8px 20px rgba(0,0,0,.25);
}

/* =====================================================
   MAIN
===================================================== */

.main-content{
    margin-left:250px;
    padding:35px;
    transition:.35s;
}

.container{
    max-width:1300px;
    margin:auto;
}

/* =====================================================
   OVERLAY
===================================================== */

.overlay{
    position:fixed;
    inset:0;
    background:rgba(0,0,0,.45);
    opacity:0;
    visibility:hidden;
    transition:.3s;
    z-index:999;
}

.overlay.show{
    opacity:1;
    visibility:visible;
}

/* =====================================================
   HAMBURGER
===================================================== */

.menu-toggle{
    display:none;

    position:fixed;

    top:15px;
    left:15px;

    width:46px;
    height:46px;

    border:none;
    border-radius:10px;

    background:#1e3a8a;
    color:white;

    cursor:pointer;

    font-size:20px;

    z-index:1001;
}
/* =====================================================
   HEADER
===================================================== */

h1{
    text-align:center;
    color:#1e3a8a;
    font-size:36px;
    margin-bottom:10px;
}

.subtitle{
    text-align:center;
    color:#64748b;
    font-size:15px;
    line-height:1.7;
    margin-bottom:35px;
}

/* =====================================================
   CARD STATISTIK
===================================================== */

.statistik{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:22px;
    margin-bottom:35px;
}

.stat-card{
    background:#fff;
    padding:28px;
    border-radius:18px;
    text-align:center;
    box-shadow:0 8px 22px rgba(0,0,0,.08);
    transition:.25s;
}

.stat-card:hover{
    transform:translateY(-5px);
}

.stat-card h3{
    color:#64748b;
    font-size:16px;
    margin-bottom:15px;
    font-weight:600;
}

.stat-card h2{
    font-size:40px;
    color:#1e3a8a;
}

.green{
    color:#16a34a !important;
}

.orange{
    color:#f59e0b !important;
}

.red{
    color:#dc2626 !important;
}

/* =====================================================
   FILTER
===================================================== */

.filter-box{
    background:#fff;
    padding:30px;
    border-radius:18px;
    margin-bottom:35px;
    box-shadow:0 8px 22px rgba(0,0,0,.08);
}

.filter-box h2{
    color:#1e3a8a;
    margin-bottom:25px;
}

.filter-grid{

    display:grid;

    grid-template-columns:repeat(3,1fr);

    gap:28px;

    margin-bottom:30px;

}

.tanggal{

    display:grid;

    grid-template-columns:repeat(2,1fr);

    gap:28px;

    margin-bottom:30px;

}

.filter-grid > div,
.tanggal > div{

    display:flex;

    flex-direction:column;

    gap:10px;

}

.filter-grid label,
.tanggal label{
    display:block;
    font-weight:600;
    margin-bottom:8px;
    color:#374151;
}

.filter-grid input,
.filter-grid select,
.tanggal input{

    height:52px;

    padding:0 16px;

    border-radius:12px;

}

.filter-grid input:focus,
.filter-grid select:focus,
.tanggal input:focus{

    outline:none;

    border-color:#2563eb;

    box-shadow:0 0 0 4px rgba(37,99,235,.12);
}

.btn-cari{

    width:100%;

    padding:14px;

    border:none;

    border-radius:10px;

    background:#1e3a8a;

    color:white;

    font-size:15px;

    cursor:pointer;

    transition:.3s;
}

.btn-cari:hover{

    background:#2563eb;

    transform:translateY(-2px);

    box-shadow:0 8px 20px rgba(37,99,235,.25);
}
/* =====================================================
   TABLE
===================================================== */

.table-box{
    background:#ffffff;
    padding:30px;
    border-radius:18px;
    box-shadow:0 8px 22px rgba(0,0,0,.08);
    overflow:hidden;
}

.table-box h2{
    color:#1e3a8a;
    margin-bottom:25px;
    font-size:24px;
}

/* Wrapper untuk responsive */

.table-responsive{
    width:100%;
    overflow-x:auto;
    -webkit-overflow-scrolling:touch;
}

table{
    width:100%;
    min-width:1050px;
    border-collapse:collapse;
}

thead th{
    background:#1e3a8a;
    color:white;
    padding:16px;
    font-size:15px;
    text-align:center;
    white-space:nowrap;
}

tbody td{
    padding:15px;
    border-bottom:1px solid #e5e7eb;
    text-align:center;
    vertical-align:middle;
}

tbody tr:nth-child(even){
    background:#f8fbff;
}

tbody tr:hover{
    background:#eef4ff;
}

/* =====================================================
   STATUS BADGE
===================================================== */

.status-naik,
.status-stabil,
.status-turun{

    display:inline-flex;
    align-items:center;
    justify-content:center;

    padding:8px 14px;

    border-radius:999px;

    font-size:13px;
    font-weight:600;
}

.status-naik{
    background:#dcfce7;
    color:#15803d;
}

.status-stabil{
    background:#fef3c7;
    color:#b45309;
}

.status-turun{
    background:#fee2e2;
    color:#dc2626;
}

/* =====================================================
   BUTTON DETAIL
===================================================== */

.detail-btn{

    border:none;

    border-radius:8px;

    padding:10px 18px;

    background:#1e3a8a;

    color:white;

    cursor:pointer;

    transition:.25s;

    font-size:14px;

    font-weight:600;
}

.detail-btn:hover{

    background:#2563eb;

    transform:translateY(-2px);

    box-shadow:0 8px 18px rgba(37,99,235,.25);
}

/* =====================================================
   RESPONSIVE
===================================================== */

/* =========================
   TABLET
========================= */

@media (max-width:991px){

    .sidebar{
        left:-260px;
        width:250px;
        transition:.35s;
    }

    .sidebar.show{
        left:0;
    }

    .overlay{
        position:fixed;
        inset:0;
        background:rgba(0,0,0,.45);
        opacity:0;
        visibility:hidden;
        transition:.3s;
        z-index:999;
    }

    .overlay.show{
        opacity:1;
        visibility:visible;
    }

    .menu-toggle{
        display:flex;
        justify-content:center;
        align-items:center;
    }

    .main-content{
        margin-left:0;
        padding:80px 25px 25px;
    }

    .statistik{
        grid-template-columns:repeat(2,1fr);
    }

    .filter-grid{
        grid-template-columns:1fr;
    }

    .tanggal{
        grid-template-columns:1fr;
    }

    .table-box{
        padding:25px;
    }

}

/* =========================
   MOBILE
========================= */

@media (max-width:768px){

    .main-content{
        padding:75px 18px 20px;
    }

    h1{
        font-size:28px;
    }

    .subtitle{
        font-size:14px;
    }

    .statistik{
        grid-template-columns:1fr;
        gap:16px;
    }

    .stat-card{
        padding:22px;
    }

    .stat-card h2{
        font-size:34px;
    }

    .filter-box{
        padding:22px;
    }

    .table-box{
        padding:20px;
    }

    table{
        min-width:1050px;
    }

    .detail-btn{
        white-space:nowrap;
    }

}

/* =========================
   SMALL MOBILE
========================= */

@media (max-width:480px){

    .main-content{
        padding:70px 12px 18px;
    }

    h1{
        font-size:24px;
    }

    .subtitle{
        font-size:13px;
    }

    .filter-box{
        padding:18px;
    }

    .table-box{
        padding:15px;
    }

    .stat-card{
        padding:18px;
    }

    .stat-card h3{
        font-size:14px;
    }

    .stat-card h2{
        font-size:30px;
    }

    .filter-grid input,
    .filter-grid select,
    .tanggal input{
        font-size:14px;
    }

    .btn-cari{
        font-size:14px;
    }

}

/* ===========================
   PAGINATION
=========================== */

.pagination{
    display:flex;
    justify-content:center;
    align-items:center;
    gap:10px;
    margin-top:35px;

    flex-wrap:nowrap;          /* jangan pindah baris */
    overflow-x:auto;           /* bisa digeser jika sempit */
    overflow-y:hidden;

    padding-bottom:8px;

    -webkit-overflow-scrolling:touch;
}

.pagination::-webkit-scrollbar{
    height:6px;
}

.pagination::-webkit-scrollbar-thumb{
    background:#cbd5e1;
    border-radius:20px;
}

.pagination a{
    text-decoration:none;
    transition:.25s;
    flex-shrink:0;             /* tombol tidak mengecil */
}

/* ===========================
   NOMOR HALAMAN
=========================== */

.pagination a:not(.page-btn){

    width:46px;
    height:46px;

    display:flex;
    justify-content:center;
    align-items:center;

    border:1px solid #dbe3f1;
    border-radius:12px;

    background:#fff;
    color:#1e3a8a;

    font-weight:600;
    font-size:16px;
}

.pagination a:not(.page-btn):hover{

    background:#eef4ff;

}

.pagination .active-page{

    background:#1e3a8a !important;
    color:#fff !important;

}

/* ===========================
   TOMBOL SEBELUMNYA/NEXT
=========================== */

.page-btn{

    display:flex;
    align-items:center;
    justify-content:center;

    min-width:145px;

    height:46px;

    padding:0 20px;

    border:1px solid #dbe3f1;
    border-radius:12px;

    background:#fff;

    color:#1e3a8a;

    font-weight:600;

    white-space:nowrap;
}

.page-btn:hover{

    background:#eef4ff;

}

/* ===========================
   MOBILE
=========================== */

@media(max-width:768px){

    .pagination{
        justify-content:flex-start;
    }

    .page-btn{
        min-width:120px;
        font-size:14px;
    }

    .pagination a:not(.page-btn){
        width:42px;
        height:42px;
        font-size:15px;
    }

}