@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@300;400;600;700&family=Pacifico&display=swap');

/* --- RESET & BASE --- */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Poppins', sans-serif;
    color: #333;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    
    /* GRADIENT BACKGROUND BERGERAK UNTUK EFEK KACA */
    background: linear-gradient(135deg, #c3ecf8, #f0f8ff, #a2dbe8, #e0f7fa);
    background-size: 400% 400%;
    animation: gradientBG 12s ease infinite;
}

@keyframes gradientBG {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* --- PRELOADER GLASSMORPHISM --- */
#preloader {
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    z-index: 10000;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.5s ease, visibility 0.5s ease;
    
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
}

.loader-wrapper {
    text-align: center;
}

.spinner-container {
    position: relative;
    width: 120px;
    height: 120px;
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
}

.spinner-ring {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid #217991;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    z-index: 1; 
}

.baby-initial {
    display: block; 
    line-height: 1; 
    font-family: 'Pacifico', cursive;
    font-size: 50px;
    color: #217991;
    position: relative; 
    z-index: 2; 
    margin: 0; 
    text-shadow: 0 4px 10px rgba(255,255,255,0.8);
}

.loader-wrapper p {
    margin-top: 25px;
    font-weight: 600;
    color: #217991;
    letter-spacing: 2px;
    animation: fade 1.5s infinite;
    font-size: 14px;
}

@keyframes spin { 100% { transform: rotate(360deg); } }
@keyframes fade { 0%, 100% { opacity: 0.4; } 50% { opacity: 1; } }

/* --- MAIN CONTAINER GLASSMORPHISM (HALAMAN TAMU) --- */
.container {
    width: 90%;
    max-width: 450px;
    padding: 40px 30px;
    border-radius: 25px;
    text-align: center;
    margin: auto;
    
    /* EFEK KACA (GLASSMORPHISM) */
    background: rgba(255, 255, 255, 0.45); /* Latar transparan */
    backdrop-filter: blur(15px); /* Blur efek kaca */
    -webkit-backdrop-filter: blur(15px); 
    border: 1px solid rgba(255, 255, 255, 0.8); /* Border putih tipis bercahaya */
    box-shadow: 0 10px 40px 0 rgba(31, 38, 135, 0.15); /* Bayangan estetik */
}

.header { margin-bottom: 25px; }

.header h2 {
    font-family: 'Pacifico', cursive;
    color: #1a6275;
    font-weight: 400;
    font-size: 26px;
}

.header h1 {
    color: #217991;
    font-size: 38px;
    margin: 5px 0;
    text-shadow: 0 2px 8px rgba(255,255,255,0.9);
}

.header p { color: #444; font-size: 13px; margin-bottom: 3px; }
.instruction { text-align: center; font-size: 13px; margin-bottom: 20px; color: #444; font-weight: 600; }

/* --- INPUT GLASSMORPHISM --- */
.quiz-form { text-align: left; }
.input-group { margin-bottom: 15px; }
.input-group label { display: block; margin-bottom: 6px; font-weight: 600; color: #217991; font-size: 13px; }

.input-group input {
    width: 100%;
    padding: 12px 15px;
    border-radius: 12px;
    font-size: 14px;
    font-family: 'Poppins', sans-serif;
    box-sizing: border-box;
    transition: all 0.3s ease;
    
    /* Efek kaca pada form input */
    background: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.9);
    color: #333;
}

.input-group input:focus {
    background: rgba(255, 255, 255, 0.95);
    border-color: #217991;
    outline: none;
    box-shadow: 0 0 12px rgba(33, 121, 145, 0.2);
}

.btn-submit {
    width: 100%;
    background: linear-gradient(135deg, #217991, #185a6d);
    color: white;
    border: none;
    padding: 15px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    margin-top: 10px;
    font-family: 'Poppins', sans-serif;
    box-shadow: 0 4px 15px rgba(33, 121, 145, 0.3);
}

.btn-submit:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(33, 121, 145, 0.4); }

/* --- ALERTS & DONE CONTAINER --- */
.alert { padding: 12px; border-radius: 10px; margin-bottom: 20px; text-align: center; font-size: 13px; font-weight: 600; }
.success { background: rgba(212, 237, 218, 0.85); color: #155724; border: 1px solid rgba(195, 230, 203, 0.8); }
.error { background: rgba(248, 215, 218, 0.85); color: #721c24; border: 1px solid rgba(245, 198, 203, 0.8); }

.done-container { padding: 15px 0; text-align: center; }
.icon-check { width: 60px; height: 60px; background: linear-gradient(135deg, #28a745, #218838); color: white; border-radius: 50%; font-size: 30px; margin: 0 auto 15px; display: flex; justify-content: center; align-items: center; box-shadow: 0 4px 15px rgba(40, 167, 69, 0.3); }
.done-container h3 { color: #217991; margin-bottom: 10px; }
.done-container p { font-size: 13px; color: #444; line-height: 1.6; }


/* =======================================================
   HALAMAN ADMIN (Solid / Tidak Transparan agar mudah dibaca)
   ======================================================= */
.admin-body {
    background: #e9ecef; /* Background abu-abu solid */
    display: block; /* Menonaktifkan rata tengah agar tabel leluasa */
    padding: 40px 20px;
}

.admin-container {
    max-width: 1000px;
    margin: 0 auto;
    background: white; /* Kotak tabel putih bersih */
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.05);
}

.admin-container h2 { color: #217991; margin-bottom: 20px; text-align: center; }
.styled-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.styled-table thead tr { background-color: #217991; color: #ffffff; text-align: left; }
.styled-table th, .styled-table td { padding: 12px 15px; border-bottom: 1px solid #dddddd; }
.styled-table tbody tr:hover { background-color: #f1f1f1; }
.winner-row { background-color: #fff3cd !important; }

.badge { display: inline-block; padding: 5px 10px; border-radius: 20px; font-weight: bold; font-size: 12px; }
.winner-badge { background-color: #ffc107; color: #212529; margin-bottom: 5px;}

.btn-win { background-color: #28a745; color: white; padding: 6px 12px; text-decoration: none; border-radius: 5px; font-size: 12px; transition: background 0.3s; display: inline-block; }
.btn-win:hover { background-color: #218838; }

.btn-wa { background-color: #25D366; color: white; padding: 6px 10px; text-decoration: none; border-radius: 5px; font-size: 12px; display: inline-block; margin-top: 8px; font-weight: bold; transition: background 0.3s; }
.btn-wa:hover { background-color: #1ebe57; }

.btn-cancel { background-color: #dc3545; color: white; padding: 6px 10px; text-decoration: none; border-radius: 5px; font-size: 12px; display: inline-block; margin-top: 8px; font-weight: bold; transition: background 0.3s; }
.btn-cancel:hover { background-color: #c82333; }

.action-group { display: flex; gap: 5px; flex-wrap: wrap; }
/* --- DESAIN SILUET BAYI --- */
.baby-silhouette {
    width: 130px; /* Atur angka ini jika ingin membesarkan/mengecilkan siluet */
    height: auto;
    display: block;
    margin: 0 auto 15px auto; /* Posisi di tengah, jarak 15px ke teks bawahnya */
    
    /* Efek Estetik: Sedikit transparan dan diberi bayangan agar elegan */
    opacity: 0.85; 
    filter: drop-shadow(0 5px 8px rgba(33, 121, 145, 0.4));
    /* Mengubah warna siluet hitam menjadi warna tema (Opsional) */
    filter: invert(34%) sepia(87%) saturate(583%) hue-rotate(149deg) brightness(92%) contrast(85%) drop-shadow(0 5px 8px rgba(33, 121, 145, 0.4));
}