/* Variabel Warna & Properti */
:root {
    --primary: #4361ee;
    --primary-soft: rgba(67, 97, 238, 0.1);
    --secondary: #2b2d42;
    --success: #4cc9f0;
    --danger: #f72585;
    --glass-bg: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(255, 255, 255, 0.3);
}

* {
    margin: 0; padding: 0; box-sizing: border-box;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

body {
    /* Background Gradient Animasi */
    background: linear-gradient(-45deg, #ee7752, #e73c7e, #23a6d5, #23d5ab);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    min-height: 100vh;
    margin: 0;
    /* Menghapus display flex agar layout utama tidak berantakan */
    display: block; 
    overflow-x: hidden;
}

/* Animasi Pergerakan Gradient */
@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* Tambahan: Dekorasi Lingkaran Melayang agar lebih interaktif */
.bg-decoration {
    position: fixed;
    z-index: -1;
    border-radius: 50%;
    filter: blur(80px);
    opacity: 0.6;
    animation: float 20s infinite alternate;
}

.blur-1 {
    width: 400px;
    height: 400px;
    background: rgba(255, 255, 255, 0.3);
    top: -100px;
    right: -100px;
}

.blur-2 {
    width: 300px;
    height: 300px;
    background: rgba(67, 97, 238, 0.2);
    bottom: -50px;
    left: -50px;
    animation-delay: -5s;
}

@keyframes float {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(50px, 100px) scale(1.2); }
}


/* Header Modern */
.unbk-header {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--glass-border);
    padding: 15px 5%;
    display: flex; justify-content: space-between; align-items: center;
    position: sticky; top: 0; z-index: 100;
}

.logo .text { font-weight: 800; font-size: 1.1rem; line-height: 1; }
.logo .text span { display: block; font-size: 0.7rem; color: var(--primary); letter-spacing: 2px; }

.timer-wrapper { text-align: center; }
.timer-label { font-size: 0.6rem; font-weight: bold; color: #888; }
.timer-clock { font-size: 1.4rem; font-weight: 800; letter-spacing: 1px; }

/* Progress Card */
.glass-card {
    background: var(--glass-bg);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass-border);
    border-radius: 15px; padding: 15px; margin-bottom: 20px;
}

.pb-bg { background: #e0e6ed; height: 10px; border-radius: 10px; overflow: hidden; margin-top: 10px; }
.pb-fill { height: 100%; background: linear-gradient(90deg, var(--primary), var(--success)); width: 0%; transition: 0.4s ease; }

/* Layout Utama */
.main-content {
    display: flex; padding: 25px 5%; gap: 25px; max-width: 1300px; margin: 0 auto;
}

.question-area { flex: 3; }
.number-sidebar { 
    flex: 1; height: fit-content; padding: 20px; border-radius: 20px;
    background: var(--glass-bg); backdrop-filter: blur(10px); border: 1px solid var(--glass-border);
}

/* Card Pertanyaan */
.card.glass {
    background: white; border-radius: 24px;
    box-shadow: 0 15px 35px rgba(0,0,0,0.05); overflow: hidden;
    border: 1px solid white;
}

.card-header { padding: 20px 30px; background: var(--primary-soft); color: var(--primary); font-weight: 800; }
.card-body { padding: 35px; }
.question-text { font-size: 1.2rem; font-weight: 600; line-height: 1.6; margin-bottom: 30px; }

/* Opsi Jawaban */
.options-container { display: flex; flex-direction: column; gap: 12px; }
.option-btn {
    padding: 10px 20px; border: 2px solid #f0f2f5; border-radius: 10px;
    background: white; text-align: left; cursor: pointer; transition: 0.2s;
    font-weight: 600; font-size: 1rem; color: #444;
}

.option-btn:hover { border-color: var(--primary); background: var(--primary-soft); }
.option-btn.selected { background: var(--primary); color: white; border-color: var(--primary); box-shadow: 0 8px 20px rgba(67, 97, 238, 0.3); }

/* Grid Nomor */
.number-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(45px, 1fr)); gap: 10px; margin: 20px 0; }
.num-item {
    aspect-ratio: 1; display: flex; align-items: center; justify-content: center;
    background: white; border-radius: 12px; cursor: pointer; font-weight: bold;
    border: 2px solid #eee; transition: 0.2s;
}
.num-item.active { border-color: var(--primary); color: var(--primary); transform: scale(1.1); }
.num-item.filled { background: var(--primary); color: white; border-color: var(--primary); }

/* Tombol-Tombol */
.btn-finish { background: var(--danger); color: white; border: none; padding: 10px 20px; border-radius: 10px; font-weight: bold; cursor: pointer; transition: 0.3s; }
.btn-finish:hover { transform: scale(1.05); box-shadow: 0 5px 15px rgba(247, 37, 133, 0.4); }
.btn-nav.blue { background: var(--primary); color: white; }
.btn-nav.secondary { background: #e0e6ed; color: #555; }
.card-footer {
    padding: 20px;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    /* Ini kuncinya: */
    justify-content: center; 
    align-items: center;
    gap: 20px; /* Memberikan jarak antar tombol agar tidak dempet */
}

.btn-nav {
    padding: 14px 30px; /* Ukuran tombol yang lebih proporsional */
    border-radius: 12px;
    font-weight: 800;
    border: none;
    cursor: pointer;
    transition: 0.3s;
    min-width: 160px; /* Agar ukuran tombol kiri dan kanan seimbang */
}

.btn-nav:hover {
    transform: scale(1.05); box-shadow: 0 5px 15px rgba(0, 0, 133, 0.4);
    filter: brightness(1.1);
}

.btn-nav.full { width: 100%; margin-top: 20px; }

/* Responsive untuk HP */
@media (max-width: 900px) {
    .main-content { flex-direction: column; padding: 15px; }
    .unbk-header { flex-direction: column; gap: 15px; text-align: center; }
    .question-area { order: 1; }
    .number-sidebar { order: 2; width: 100%; }
}

/* Modal Styling */
.modal {
    display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5); backdrop-filter: blur(8px); z-index: 1000;
    justify-content: center; align-items: center;
}
#review-container {
    max-height: 60vh; /* Mengambil 60% dari tinggi layar */
    overflow-y: auto;
    padding: 10px;
    background: #fff;
    border-radius: 8px;
    /* Membuat scrollbar terlihat lebih modern (opsional) */
}

#review-container::-webkit-scrollbar {
    width: 6px;
}

#review-container::-webkit-scrollbar-thumb {
    background-color: #ccc;
    border-radius: 10px;
}
.modal-content { background: white; padding: 40px; border-radius: 30px; width: 90%; max-width: 500px; text-align: center; }
.score-display { display: flex; gap: 15px; margin: 25px 0; }
.score-box { flex: 1; padding: 20px; background: #f8f9fa; border-radius: 20px; border: 1px solid #eee; }
.score-box.highlight { background: var(--primary-soft); border-color: var(--primary); }
.score-box .value { display: block; font-size: 2rem; font-weight: 800; color: var(--primary); }