
/* =====================================
   HEADER KPU
===================================== */

.topbar{

    display:flex;
    align-items:center;
    justify-content:space-between;

    background:#7f1d1d;

    color:#fff;

    padding:8px 20px;

    min-height:80px;

    box-shadow:0 3px 10px rgba(0,0,0,.25);

}

/* kiri */

.topbar-left{

    width:220px;

    display:flex;
    align-items:center;

}

/* tengah */

.topbar-center{

    flex:1;

    text-align:center;

}

/* kanan */

.topbar-right{

    width:220px;

}

/* logo */

.logo-kpu{

    width:50px !important;
    height:50px !important;

    object-fit:contain;

    display:block;

    margin:0 auto 6px;

}

/* judul */

.topbar-center h1{

    margin:0;

    font-size:20px;

    font-weight:700;

    letter-spacing:.5px;

}

.topbar-center small{

    display:block;

    margin-top:5px;

    color:#ffe3a5;

    font-size:13px;

}

/* =====================================
   HOME BUTTON
===================================== */

.btn-home{

    display:flex;

    align-items:center;

    gap:10px;

    text-decoration:none;

    color:white;

    background:rgba(255,255,255,.12);

    padding:10px 18px;

    border-radius:10px;

    transition:.25s;

    font-weight:600;

}

.btn-home i{

    font-size:20px;

}

.btn-home:hover{

    background:white;

    color:#7f1d1d;

    transform:translateY(-2px);

}


body{
    margin:0;
    font-family: 'Segoe UI', sans-serif;
    background:#f4f6f9;
}

/* CONTAINER */
.container{
    display:grid;
    grid-template-columns: 260px 1fr 320px;
    gap:12px;
    padding:12px;
}

/* SIDEBAR */
.sidebar{
    display:flex;
    flex-direction:column;
    gap:12px;
}

/* CARD STYLE */
.card{
    background:white;
    padding:15px;
    border-radius:12px;
    box-shadow:0 2px 8px rgba(0,0,0,0.08);
}

/* MAP */
.map-container{
    background:white;
    border-radius:12px;
    overflow:hidden;
    box-shadow:0 2px 8px rgba(0,0,0,0.08);
}

/* ==========================
   MAP RESPONSIVE
========================== */

.map-responsive{

    width:100%;
    height:75vh;

}

/* Tablet */

@media (max-width:992px){

    .map-responsive{

        height:500px;

    }

}

/* HP */

@media (max-width:768px){

    .map-responsive{

        height:380px;

    }

}

/* HP kecil */

@media (max-width:576px){

    .map-responsive{

        height:300px;

    }

}

.card{

    border-radius:15px;

}

.card-header{

    font-weight:700;

}

#judulStat{

    font-size:26px;

    font-weight:bold;

}

#subJudul{

    display:block;

    margin-top:5px;

}

@media(max-width:768px){

    #judulStat{

        font-size:22px;

    }

}

.chart-container{

    max-width:320px;

    margin:auto;

}

@media(min-width:992px){

    .sidebar-sticky{

        position:sticky;

        top:15px;

    }

}

.ts-wrapper{

    width:100%;

}

/* RIGHT PANEL */
.right-panel{
    display:flex;
    flex-direction:column;
}

/* FORM */
select, input[type="file"], button{
    width:100%;
    padding:8px;
    margin-top:6px;
    border-radius:6px;
    border:1px solid #ccc;
}

button{
    background:#2563eb;
    color:white;
    border:none;
    cursor:pointer;
}

button:hover{
    background:#1d4ed8;
}

/* ALERT */
.success{
    background:#d4edda;
    padding:10px;
    border-radius:6px;
    color:#155724;
}

.error{
    background:#f8d7da;
    padding:10px;
    border-radius:6px;
    color:#721c24;
}

.footer {
    background: #9e0821;
    color: #ccc;
    text-align: center;
    padding: 12px;
    font-size: 13px;
}

.chart-container{

    max-width:320px;

    margin:auto;

}


/* STAT ITEM */
.stat-item{
    display:flex;
    justify-content:space-between;
    margin:6px 0;
    font-size:14px;
}

.stat-item.total{
    margin-top:10px;
    padding-top:8px;
    border-top:1px solid #eee;
    font-weight:bold;
}

/* CHART BOX */
.chart-box{
    border:1px solid #e5e7eb;
    border-radius:10px;
    padding:12px;
    margin-top:12px;
    background:#fff;
    box-shadow:0 1px 4px rgba(0,0,0,0.05);
}

/* GARIS ATAS (STYLE KPU) */
.chart-box{
    border-top:4px solid #b91c1c;
}

/* JUDUL */
.chart-title{
    font-weight:600;
    font-size:14px;
    margin-bottom:10px;
    text-align:center;
}

/* CHART */
.chart-box canvas{
    max-height:250px;
}

/* HEADER STATISTIK */
.stat-header{
    margin-bottom:12px;
}

.stat-title{
    font-size:18px;
    font-weight:600;
    line-height:1.3;
}

.stat-sub{
    font-size:15px;
    font-weight:600;
    margin-top:4px;
    color:#374151;
    white-space:pre-line; /* biar bisa enter */
}

/* LABEL (Laki-laki, Perempuan) */
.stat-item span{
    font-weight:650;
    color:#374151;
}

/* ANGKA */
.stat-item b{
    font-weight:700;
    font-size:18px;
    color:#111827;
}

/* =========================
   RADIO CARD JENIS DATA
========================= */

.jenis-data-box{
    margin-bottom:15px;
}

.jenis-data-box label{
    display:block;
    font-weight:700;
    margin-bottom:10px;
}

.jenis-data-box div{
    background:#f8fafc;
    border:1px solid #e5e7eb;
    border-radius:10px;
    padding:10px 12px;
    margin-bottom:8px;
    cursor:pointer;
    transition:all .2s ease;
}

.jenis-data-box div:hover{
    background:#eff6ff;
    border-color:#3b82f6;
}

.jenis-data-box input[type="radio"]{
    margin-right:8px;
}

/* =========================
   PANEL STATISTIK MODERN
========================= */

.stat-item{
    display:flex;
    justify-content:space-between;
    align-items:center;
    padding:12px 0;
    border-bottom:1px solid #f1f5f9;
}

.stat-item span{
    font-size:16px;
    font-weight:700;
    color:#1f2937;
}

.stat-item b{
    font-size:22px;
    font-weight:700;
    color:#991b1b;
}

.stat-item.total{
    margin-top:10px;
    padding-top:15px;
    border-top:2px solid #e5e7eb;
    border-bottom:none;
}

.stat-item.total b{
    font-size:28px;
    color:#111827;
}

/* =========================
   JUDUL PANEL KANAN
========================= */

.stat-title{
    font-size:24px;
    font-weight:700;
    color:#111827;
}

.stat-sub{
    font-size:14px;
    color:#6b7280;
    margin-top:6px;
}

/* =========================
   DROPDOWN MODERN
========================= */

select{
    background:#fff;
    font-size:14px;
    font-weight:500;
    padding:10px;
}

/* =========================
   SIDEBAR HEADER
========================= */

.sidebar h4{
    margin-top:0;
    margin-bottom:20px;
    font-size:20px;
    color:#111827;
    border-left:4px solid #b91c1c;
    padding-left:10px;
}

