/* style.css (Kode LENGKAP dan TERUJI) */

/* --- 1. FONT & VARIABEL DASAR --- */
:root {
    /* Palet Warna Soft */
    --primary-main: #3498db; 
    --primary-dark: #2980b9; 
    --secondary-accent: #2ecc71; 
    --warning-accent: #f39c12; 
    --danger-color: #e74c3c; 
    
    /* Warna Background & Text */
    --bg-page: #ecf0f1; 
    --bg-popup: #ffffff;
    --text-primary: #34495e; 

    /* Desain */
    --radius-large: 15px;
    --shadow-subtle: 0 8px 25px rgba(0, 0, 0, 0.1);
    --transition-speed: 0.3s;
}

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

body {
    font-family: 'Poppins', 'Segoe UI', sans-serif; 
    background-color: var(--bg-page);
    color: var(--text-primary);
    min-height: 100vh;
}

/* --- 2. NAVIGASI MENU (Navbar) --- */
.navbar {
    width: 100%;
    background-color: var(--primary-dark);
    padding: 10px 0; 
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 999;
}

.navbar-list {
    list-style: none;
    margin: 0;
    padding: 0;
    text-align: center;
}

.navbar-list li {
    display: inline-block;
    margin: 0 15px;
}

.navbar-list li a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    padding: 8px 12px; 
    border-radius: 5px;
    transition: background-color var(--transition-speed) ease;
}

.navbar-list li a:hover {
    background-color: var(--primary-main);
}

/* --- 3. OVERLAY POP-UP (Mencegah tampilan tumpah) --- */
#popupOverlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6); 
    display: none; /* Default: Tersembunyi */
    justify-content: center; 
    align-items: center; 
    z-index: 1000;
    opacity: 0; 
    transition: opacity var(--transition-speed) ease;
    overflow: hidden; 
}

/* WATERMARK BESAR (©Rayy) di Latar Pop-up */
#popupContainer::before {
    content: "©Rayy"; 
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) rotate(-20deg); 
    font-size: 5em; 
    font-weight: 900;
    color: var(--text-primary);
    opacity: 0.05; 
    z-index: 0; 
    pointer-events: none;
    user-select: none;
    white-space: nowrap;
}

/* KOTAK KONTEN POP-UP */
#popupContainer {
    background-color: var(--bg-popup);
    padding: 30px;
    border-radius: var(--radius-large);
    box-shadow: var(--shadow-subtle);
    max-width: 450px; 
    width: 90%;
    text-align: center;
    
    /* Persiapan Animasi Premium */
    opacity: 0; 
    transform: none; 
    transition: opacity var(--transition-speed) ease;
    
    position: relative; 
    z-index: 1002; 
}

/* Kelas untuk Menampilkan Pop-up */
#popupOverlay.show-popup { 
    opacity: 1;
    display: flex;
}
#popupOverlay.show-popup #popupContainer {
    opacity: 1;
    /* Terapkan animasi canggih */
    animation: popin-premium 0.6s cubic-bezier(0.68, -0.55, 0.27, 1.55) forwards;
}


/* --- 4. KEPALA & PESAN POP-UP --- */
#popup-header {
    color: var(--primary-main);
    margin-bottom: 10px;
    font-size: 1.6em;
    font-weight: 700;
    border-bottom: 2px solid var(--bg-page); 
    padding-bottom: 15px;
    z-index: 3; 
    position: relative;
}

#popup-message {
    margin-top: 15px;
    margin-bottom: 25px;
    line-height: 1.7;
    font-size: 1em;
    text-align: left;
    white-space: pre-wrap;
    z-index: 3;
    position: relative;
}

/* --- 5. AREA TOMBOL & INTERAKSI --- */
#popup-actions {
    display: flex;
    flex-direction: column;
    gap: 12px;
    z-index: 3;
    position: relative;
}

/* Gaya dasar semua tombol & link */
#popup-actions button,
#popup-actions a {
    padding: 14px 25px;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    font-weight: 600;
    cursor: pointer;
    text-decoration: none;
    display: block;
    text-align: left; /* Rata kiri untuk daftar menu */
    padding-left: 20px;
    transition: all var(--transition-speed) ease; 
}

/* Tombol Pilihan Biru */
.choice-button {
    background-color: var(--primary-main);
    color: white;
}

.choice-button:hover {
    background-color: var(--primary-dark); 
    transform: translateY(-3px);
    box-shadow: 0 8px 15px rgba(52, 152, 219, 0.4);
}

/* Tombol Kembali/Tutup (Kuning/Merah/Biru gelap) */
.back-button {
    background-color: var(--warning-accent) !important;
    color: white !important; 
    font-weight: 600;
    text-align: center !important; /* Rata tengah untuk tombol Kembali/Tutup */
}
.back-button:hover {
    background-color: #d89619 !important;
    transform: translateY(-3px);
    box-shadow: 0 8px 15px rgba(243, 156, 18, 0.4);
}

/* Tombol Link (Hijau) */
.wa-link-button {
    background-color: var(--secondary-accent); 
    color: white;
}

.wa-link-button:hover {
    background-color: #27ae60;
    transform: translateY(-3px);
    box-shadow: 0 8px 15px rgba(46, 204, 113, 0.4);
}


/* --- 6. WATERMARK BAWAH KANAN (Watermark Default) --- */
.watermark {
    position: fixed; 
    bottom: 15px;
    right: 15px;
    color: var(--danger-color); 
    opacity: 0.5; 
    font-size: 12px;
    user-select: none;
    letter-spacing: 0.5px;
    z-index: 1001; 
    font-weight: 700; 
}


/* --- 7. ANIMASI POP-UP CANGGIH DAN PREMIUM --- */
@keyframes popin-premium {
    /* Kondisi Awal: Kecil, sedikit ke bawah, tidak terlihat */
    0% {
        opacity: 0;
        transform: translate3d(0, 50px, 0) scale(0.8);
    }
    
    /* Kondisi Akhir: Ukuran penuh, di tengah */
    100% {
        opacity: 1;
        transform: translate3d(0, 0, 0) scale(1);
    }
}
