/* REVISI WARNA UNJ (Hanya mengubah kode warna) */

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Arial, sans-serif;
    background-color: #f6f8fa;
    color: #222;
}

h2 {
    color: #005c54;        /* Warna utama sesuai permintaan */
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    font-size: 1.5rem;     /* Ukuran font yang proporsional */
    font-weight: 700;      /* Membuat judul lebih tegas */
    margin-bottom: 15px;   /* Memberi jarak dengan konten di bawahnya */
    line-height: 1.3;
    
    /* Opsional: Tambahkan sedikit aksen garis bawah tipis */
    border-bottom: 2px solid #005c54;
    padding-bottom: 5px;
    display: inline-block; /* Agar garis bawah hanya sepanjang teks */
}

/* Container utama */
.container {
    display: flex;
    flex-direction: row;
    min-height: 100vh;
}

/* Sidebar - Menggunakan Hijau UNJ */
.sidebar {
    width: 260px;
    flex: 0 0 260px; /* kunci lebar sehingga tidak tumbuh atau menyusut */
    min-width: 260px;
    max-width: 260px;
    background: linear-gradient(135deg, #005c54 0%, #00453f 100%); /* Warna Diubah */
    color: #fff;
    padding: 28px 20px 20px 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: 2px 0 12px rgba(0, 92, 84, 0.15); /* Shadow Diubah */
    z-index: 1000;
    transition: left 0.3s ease-in-out;
    height: 100vh; /* pastikan sidebar menjangkau tinggi layar */
    position: sticky; /* tetap berada di tempat saat menggulir */
    top: 0;
    overflow-y: auto; /* scroll internal jika isinya panjang */
    overflow-x: hidden;
    word-wrap: break-word;
} 

.sidebar .app-name {
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 28px;
    text-align: center;
    letter-spacing: 1px;
}

.sidebar .profile {
    text-align: center;
    margin-bottom: 24px;
}

.sidebar .profile img {
    display: block;      /* Tambahkan ini */
    margin: 0 auto 12px; /* Ubah margin-bottom tadi menjadi auto untuk kiri-kanan */
    width: 82px;
    height: 82px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fedd00;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* Pastikan semua gambar di dalam sidebar tidak meluber */
.sidebar img {
    max-width: 100%;
    height: auto;
    display: block;
}

.sidebar .profile .name {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 2px;
}

.sidebar .profile .role {
    font-size: 13px;
    color: #fedd00; /* Warna Diubah (Kuning UNJ) */
}

.sidebar .question-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 6px;
    margin-bottom: 24px;
}

.sidebar .question-grid button {
    background: rgba(255, 255, 255, 0.2); /* Warna Diubah */
    color: #fff;
    border: none;
    padding: 3px 3px 3px 3px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 500;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: background 0.2s, border 0.2s;
    border: 1px solid transparent; 
    width: 30px;      
    height: 20px;       
    text-align: center; 
    padding: 0;         
}

/* Jika ada class 'select', border lebih tebal dan warna kuning */
.sidebar .question-grid button.select {
    border: 3px solid #fedd00; /* Warna Diubah (Kuning UNJ) */
}

/* Jika ada class 'active', background hijau terang */
.sidebar .question-grid button.active {
    background: #43a047 !important; 
    border-color: #ffffff;
    color: #fff;
}

/* Hover ke Kuning jika tidak active */
.sidebar .question-grid button:hover:not(.active) {
    background: #fedd00; /* Warna Diubah */
    color: #005c54; /* Teks jadi Hijau agar kontras */
}

.exit-button {
    text-align: center;
    margin-top: 24px;
}

.exit-button button {
    background: #e53935;
    color: #fff;
    border: none;
    padding: 12px 0;
    border-radius: 7px;
    font-size: 17px;
    font-weight: 600;
    cursor: pointer;
    width: 100%;
    box-shadow: 0 2px 8px rgba(229, 57, 53, 0.08);
    transition: background 0.2s;
}
.exit-button button:hover {
    background: #b71c1c;
}

/* Main content */
.main-content {
    flex: 1;
    padding: 32px 28px;
    background: #f6f8fa;
}

.timer {
    font-size: 20px;
    font-weight: bold;
    margin-bottom: 28px;
    background: linear-gradient(90deg, #005c54 60%, #00897b 100%); /* Warna Diubah */
    color: #fff;
    padding: 12px 0;
    border-radius: 7px;
    text-align: center;
    box-shadow: 0 2px 8px rgba(0, 92, 84, 0.1);
}

.question {
    font-size: 12;
    margin-bottom: 22px;
    font-weight: 500;
}

/* Jika pertanyaan memiliki gambar, tampilkan teks di kiri dan gambar di kanan */
.question.question-with-image {
    display: flex;
    gap: 18px;
    align-items: flex-start;
}

.question-with-image .question-text {
    flex: 1;
}

.question-with-image .question-image {
    width: 300px;
    max-width: 35%;
}

.question-with-image .question-image img {
    width: 100%;
    height: auto;
    border-radius: 8px;
    object-fit: contain;
    border: 1px solid #e0e0e0;
}

/* Responsif: stack gambar di bawah teks pada layar kecil */
@media (max-width: 700px) {
    .question.question-with-image {
        flex-direction: column;
    }
    .question-with-image .question-image {
        width: 100%;
        max-width: 100%;
    }
}

/* Layout opsi sebagai 4 kotak horizontal (desktop) */
.options {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    align-items: stretch;
}

/* Setiap opsi menjadi kotak yang rapi */
.options label {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 4px 10px;
    background: #fff;
    border: 1.5px solid #005c54; /* Warna Diubah */
    border-radius: 7px;
    cursor: pointer;
    font-size: 12px;
    transition: background 0.2s, border 0.2s, transform 0.08s;
    min-height: 40px;
}

/* Hover / checked state */
.options label:hover,
.options input[type="radio"]:checked + label {
    background: #f1f8f7; /* Warna Diubah (Hijau sangat muda) */
    border-color: #00453f; /* Warna Diubah */
    transform: translateY(-2px);
}

.options input[type="radio"] {
    margin-right: 8px;
    transform: scale(1.1);
}

/* Responsif: 2 kolom pada layar sedang, 1 kolom pada layar kecil */
@media (max-width: 900px) {
    .options {
        grid-template-columns: repeat(2, 1fr);
    }
}
@media (max-width: 480px) {
    .options {
        grid-template-columns: 1fr;
    }
}

.action-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    margin-top: 28px;
    margin-bottom: 10px;
    justify-content: center;
}

.action-buttons button,
.action-buttons .btn {
    padding: 11px 22px;
    font-size: 15px;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    outline: none;
}

.action-buttons .btn-warning {
    background: #ffa000;
    color: #fff;
}
.action-buttons .btn-warning:hover {
    background: #ff6f00;
}
.action-buttons .btn-secondary {
    background: #e0e0e0;
    color: #333;
}
.action-buttons .btn-secondary:hover {
    background: #bdbdbd;
}
.action-buttons .btn-danger {
    background: #e53935;
    color: #fff;
}   
.action-buttons .btn-danger:hover {
    background: #b71c1c;
}

.action-buttons .btn-primary {
    background: #005c54; /* Warna Diubah */
    color: #fff;
}
.action-buttons .btn-primary:hover {
    background: #00453f; /* Warna Diubah */
}

.menu-toggle {
    display: none;
    background: #005c54; /* Warna Diubah */
    color: #fff;
    border: none;
    padding: 12px 18px;
    font-size: 20px;
    cursor: pointer;
    margin: 12px 12px 0 12px;
    border-radius: 7px;
    box-shadow: 0 2px 8px rgba(0, 92, 84, 0.1);
}

/* Responsive untuk layar kecil */
@media (max-width: 900px) {
    .container {
        flex-direction: column;
    }
    .sidebar {
        position: fixed;
        left: -100%;
        top: 0;
        height: 100%;
        width: 260px;
        background: linear-gradient(135deg, #005c54 0%, #00453f 100%); /* Warna Diubah */
        transition: left 0.3s ease-in-out;
        box-shadow: 2px 0 12px rgba(0, 0, 0, 0.2);
    }
    .sidebar.show {
        left: 0;
    }
    .menu-toggle {
        display: block;
    }
    .sidebar .question-grid {
        grid-template-columns: repeat(5, 1fr);
    }
    .main-content {
        padding: 16px 8px;
    }
    .exit-button button {
        width: 100%;
    }
}

/* Sembunyikan secara global */
.close-sidebar {
    display: none;
    background: transparent;
    color: #fff;
    border: none;
    font-size: 22px;
    font-weight: bold;
    cursor: pointer;
    text-align: left;
    margin-bottom: 12px;
}
/* Tampilkan hanya di layar kecil dan saat sidebar aktif */
@media (max-width: 900px) {
    .sidebar.show .close-sidebar {
        display: block;
    }
}



/* ################################################################################################################ */
/* Alert Container */
.alert-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 10px;
}
.alert {
    padding: 13px 22px;
    border-radius: 6px;
    color: #fff;
    min-width: 250px;
    box-shadow: 0 4px 12px rgba(25, 118, 210, 0.10);
    position: relative;
    animation: fadeIn 0.5s ease-in-out;
    overflow: hidden;
    font-size: 15px;
}
.alert-success { background: #0ccf3a; }
.alert-error { background: #e53935; }
.alert-warning { background: #ffc107; color: #333; }
.alert-info { background: #1976d2; }
.alert-progress {
    position: absolute;
    bottom: 0;
    left: 0;
    height: 4px;
    background: rgba(255,255,255,0.8);
    width: 100%;
    transform: scaleX(1);
    transform-origin: left;
    animation: progressBar 5s linear forwards;
}
@keyframes progressBar {
    0% { transform: scaleX(1); }
    100% { transform: scaleX(0); }
}
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-10px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeOut {
    from { opacity: 1; }
    to { opacity: 0; transform: translateY(-10px); }
}


/* STYLE MODAL */
.modal {
    display: none; /* Hidden by default */
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    overflow: auto;
    background: rgba(0,0,0,0.3);
    align-items: center;
    justify-content: center;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: #fff;
    border-radius: 12px;
    padding: 32px 28px;
    max-width: 350px;
    margin: auto;
    box-shadow: 0 4px 24px rgba(0,0,0,0.15);
    text-align: center;
    position: relative;
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 18px;
    background: transparent;
    border: none;
    font-size: 22px;
    color: #1976d2;
    cursor: pointer;
}



/* ///////////////////////////////////////////////////////////////////////////////////////////////////////// */
/* ///////////////////////////////////////////////////////////////////////////////////////////////////////// */
/* TIME OUT */
/* ///////////////////////////////////////////////////////////////////////////////////////////////////////// */
/* ///////////////////////////////////////////////////////////////////////////////////////////////////////// */
.time_out-section {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 60vh;
    text-align: center;
}

.time_out-section .super-big {
    font-size: 64px;
    font-weight: 900;
    color: #e53935;
    margin-bottom: 24px;
    letter-spacing: 2px;
}

.time_out-section .desc {
    font-size: 24px;
    color: #333;
    margin-bottom: 18px;
}




/* BUTTON UMUM */
.btn,
button {
    padding: 10px 22px;
    font-size: 15px;
    font-weight: 600;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    transition: background 0.2s, box-shadow 0.2s;
    box-shadow: 0 2px 8px rgba(25, 118, 210, 0.08);
    outline: none;
    margin-right: 4px;
    margin-bottom: 4px;
}

/* Warna-warna tombol umum */
.btn-primary {
    background: #0288d1;
    color: #fff;
}
.btn-primary:hover {
    background: #01579b;
}

.btn-info {
    background: #1976d2;
    color: #fff;
}
.btn-info:hover {
    background: #0d47a1;
}

.btn-warning {
    background: #ffa000;
    color: #fff;
}
.btn-warning:hover {
    background: #ff6f00;
}

.btn-danger {
    background: #e53935;
    color: #fff;
}
.btn-danger:hover {
    background: #b71c1c;
}

.btn-success {
    background: #43a047;
    color: #fff;
}
.btn-success:hover {
    background: #2e7031;
}


/* ///////////////////////////////////////////////////////////////////////////////////////////////////////// */
/* RESULT LAYOUT */
.result-section {
    margin-top: 18px;
}
.result-cards {
    display: flex;
    gap: 18px;
    align-items: flex-start;
    flex-wrap: wrap;
}
.card {
    background: #fff;
    border-radius: 10px;
    padding: 18px;
    box-shadow: 0 8px 24px rgba(16,24,40,0.06);
}
.user-card {
    flex: 1 1 420px;
    min-width: 260px;
}
.detail-table td.label { width: 160px; font-weight: 600; color: #333; }
.detail-table td.sep { width: 12px; color: #666; }
.detail-table td.value { color: #333; }
.summaries {
    display: flex;
    flex-direction: column;
    gap: 12px;
    min-width: 200px;
}
.summary-card {
    padding: 14px 18px;
    border-radius: 8px;
    color: #fff;
    text-align: center;
}
.summary-card .value { font-size: 22px; font-weight: 700; margin-bottom: 6px; }
.summary-card.answered { background: linear-gradient(90deg, #1976d2, #4fc3f7); }
.summary-card.correct { background: linear-gradient(90deg, #43a047, #9ccc65); }
.result-actions { margin-top: 14px; display:flex; gap:10px; }

/* Responsive: stack on small screens */
@media (max-width: 900px) {
    .result-cards { flex-direction: column; }
    .summaries { flex-direction: row; }
    .summary-card { flex: 1; }
}

/* TABEL STYLE UNJ */
/* Container tabel agar responsive */
.table-container {
    width: 100%;
    overflow-x: auto;
    margin: 20px 0;
    
    /* Perubahan di sini */
    background-color: #ffffff; /* Latar belakang putih bersih */
    padding: 15px;             /* Memberi ruang antara isi dan tepi card */
    border-radius: 12px;       /* Membuat sudut lebih tumpul agar terlihat modern */
    border: 1px solid #eee;    /* Garis tipis halus untuk mempertegas bentuk card */
    
    /* Bayangan ditingkatkan agar efek card lebih terasa */
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08); 
}

.unj-table {
    width: 100%;
    border-collapse: collapse;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 13px; /* Ukuran font standar administrasi */
}

/* Header Tabel */
.unj-table thead tr {
    background-color: #005c54; /* Hijau UNJ */
    color: #ffffff;
    text-align: left;
    font-weight: bold;
}

.unj-table th, .unj-table td {
    padding: 12px 15px;
    border: 1px solid #e0e0e0;
}

/* Zebra Striping (Baris Selang-Seling) */
.unj-table tbody tr {
    border-bottom: 1px solid #dddddd;
    background-color: #ffffff;
}

.unj-table tbody tr:nth-of-type(even) {
    background-color: #f9f9f9;
}

/* Hover Effect - Warna Kuning Tipis */
.unj-table tbody tr:hover {
    background-color: rgba(254, 221, 0, 0.1); /* Kuning UNJ transparan */
    transition: background 0.2s ease;
}

/* Baris Terakhir (Opsional untuk Border bawah) */
.unj-table tbody tr:last-of-type {
    border-bottom: 3px solid #fedd00; /* Garis bawah Kuning UNJ */
}

/* Badge/Tombol Aksi di Tabel (Jika Ada) */
.btn-action {
    background-color: #005c54;
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 11px;
}

.btn-action:hover {
    background-color: #fedd00;
    color: #005c54;
}
