/* =========================================
   STYLE.CSS - FINAL UPDATE DENGAN FITUR PROMO
   =========================================
*/

/* --- 1. RESET & BASIC --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

:root {
    --primary: #c0392b; /* Merah Jepang */
    --primary-dark: #a93226;
    --secondary: #f39c12; /* Kuning Emas */
    --dark: #2c3e50;
    --light: #f9f9f9;
    --white: #ffffff;
    --shadow: 0 5px 15px rgba(0,0,0,0.1);
}

html { scroll-behavior: smooth; }
body { background-color: var(--light); color: var(--dark); }

/* Utility */
.container { padding: 60px 8%; max-width: 1200px; margin: 0 auto; }

/* --- 2. TOP BANNER (MARKETING) --- */
.top-banner {
    background: linear-gradient(90deg, #c0392b 0%, #e74c3c 100%);
    color: white;
    text-align: center;
    padding: 12px 5%;
    font-size: 0.9rem;
    position: relative;
    z-index: 1002;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.top-banner p { margin: 0; line-height: 1.5; }

.top-banner .blink {
    color: #f1c40f; 
    font-weight: 800; 
    text-transform: uppercase;
    animation: blink-text 1s infinite;
    margin: 0 5px;
}

.banner-btn {
    background: white; 
    color: #c0392b; 
    padding: 4px 12px; 
    border-radius: 4px;
    text-decoration: none; 
    font-weight: 700; 
    font-size: 0.8rem;
    margin-left: 10px; 
    transition: 0.3s;
    white-space: nowrap;
}
.banner-btn:hover { background: #f1c40f; transform: scale(1.05); }

@keyframes blink-text { 0% { opacity: 1; } 50% { opacity: 0.5; } 100% { opacity: 1; } }

/* --- 3. NAVBAR --- */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 8%;
    background: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: sticky;
    top: 0; 
    z-index: 1000;
}

.nav-brand {
    font-size: 1.5rem; 
    font-weight: 700; 
    color: var(--primary);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-img { height: 40px; width: auto; object-fit: contain; }

.nav-links { list-style: none; display: flex; gap: 20px; }
.nav-links a { text-decoration: none; color: var(--dark); font-weight: 500; transition: 0.3s; }
.nav-links a:hover, .nav-links a.active { color: var(--primary); font-weight: 700; }

/* --- 4. SLIDER BANNER --- */
.slider-container {
    width: 100%;
    max-width: 1200px;
    margin: 20px auto;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    position: relative;
    aspect-ratio: 16/6;
    background-color: #ddd;
    touch-action: pan-y;
}

.slider-wrapper {
    display: flex;
    width: 100%;
    height: 100%;
    transition: transform 0.5s ease-in-out;
}

.slide {
    min-width: 100%;
    width: 100%;
    height: 100%;
    flex-shrink: 0;
}

.slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    user-select: none;
    -webkit-user-drag: none;
}

/* --- 5. HERO SECTION --- */
.hero {
    background: linear-gradient(135deg, #fff5f5 0%, #ffffff 100%);
    padding: 40px 8% 60px; 
}
.hero-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
}
.hero-text { flex: 1; min-width: 300px; }
.hero-text h1 { font-size: 3.5rem; color: var(--primary); margin-bottom: 15px; line-height: 1.2; }
.hero-text p { font-size: 1.1rem; color: #555; margin-bottom: 25px; line-height: 1.6; }

.hero-video-box {
    flex: 1;
    min-width: 300px;
    position: relative;
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 20px 20px 0px rgba(192, 57, 43, 0.1);
    background: #000;
}
.hero-video-box video {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
    aspect-ratio: 1/1;
}

#muteBtn {
    position: absolute; bottom: 20px; right: 20px;
    background: rgba(0,0,0,0.6); color: white;
    border: none; padding: 8px 15px; border-radius: 50px;
    cursor: pointer; font-size: 0.9rem;
    display: flex; align-items: center; gap: 8px; transition: 0.3s; z-index: 10;
}
#muteBtn:hover { background: var(--primary); }

.btn {
    display: inline-block; padding: 10px 25px;
    border-radius: 50px; text-decoration: none;
    font-weight: 600; transition: 0.3s; cursor: pointer; border: none;
}
.btn-primary { background: var(--primary); color: var(--white); }
.btn-primary:hover { background: var(--primary-dark); transform: translateY(-2px); }

/* --- 6. MENU SECTION --- */
.section-title {
    text-align: center; font-size: 2.2rem; margin-bottom: 30px;
    color: var(--dark); position: relative; padding-bottom: 10px;
}
.section-title::after {
    content: ''; position: absolute; bottom: 0; left: 50%; transform: translateX(-50%);
    width: 60px; height: 4px; background: var(--primary); border-radius: 2px;
}

.category-title {
    font-size: 1.5rem; color: var(--secondary); margin-bottom: 25px;
    border-left: 5px solid var(--primary); padding-left: 15px; margin-top: 50px;
}

.menu-grid {
    display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 30px;
}
.menu-item {
    background: var(--white); border-radius: 15px; overflow: hidden;
    box-shadow: var(--shadow); transition: 0.3s; display: flex; flex-direction: column;
}
.menu-item:hover { transform: translateY(-5px); box-shadow: 0 10px 20px rgba(0,0,0,0.15); }

.img-box { width: 100%; height: 200px; overflow: hidden; }
.img-box img { width: 100%; height: 100%; object-fit: cover; transition: 0.5s; }
.menu-item:hover .img-box img { transform: scale(1.1); }

.menu-info { padding: 20px; flex-grow: 1; display: flex; flex-direction: column; text-align: center; }
.menu-info h3 { margin-bottom: 5px; font-size: 1.2rem; line-height: 1.3; }
.menu-info p { color: #777; font-size: 0.9rem; margin-bottom: 15px; flex-grow: 1; }

.btn-order {
    background: var(--dark); color: white; width: 100%; border: none;
    padding: 10px; border-radius: 50px; cursor: pointer;
    font-weight: bold; transition: 0.3s;
}
.btn-order:hover { background: var(--primary); }

.price-container { margin-bottom: 15px; display: flex; flex-direction: column; align-items: center; }
.fake-price-row { display: flex; align-items: center; gap: 10px; margin-bottom: 2px; }
.fake-price { text-decoration: line-through; color: #95a5a6; font-size: 0.9rem; }
.promo-badge { background: #e74c3c; color: white; font-size: 0.7rem; padding: 2px 8px; border-radius: 4px; font-weight: bold; animation: pulse 2s infinite; }
.real-price { display: block; font-size: 1.4rem; font-weight: 800; color: var(--primary); }
@keyframes pulse { 0% { transform: scale(1); } 50% { transform: scale(1.05); } 100% { transform: scale(1); } }

/* Timer */
.promo-timer {
    margin-bottom: 25px; background: rgba(255, 255, 255, 0.5);
    padding: 15px; border-radius: 10px; display: inline-block;
    border: 2px dashed var(--primary);
}
.promo-label {
    font-size: 1rem; font-weight: 700; color: var(--primary);
    margin-bottom: 10px !important; text-transform: uppercase; letter-spacing: 1px;
}
#countdown { display: flex; gap: 10px; justify-content: flex-start; }
.time-box {
    background: var(--dark); color: var(--white); padding: 8px 12px;
    border-radius: 8px; text-align: center; min-width: 60px;
    box-shadow: 0 5px 10px rgba(0,0,0,0.2);
}
.time-box span { display: block; font-size: 1.5rem; font-weight: 800; color: var(--secondary); }
.time-box small { font-size: 0.7rem; text-transform: uppercase; }

/* --- 7. MODALS (GENERAL & PROMO) --- */
.modal {
    display: none; position: fixed; z-index: 2000; left: 0; top: 0;
    width: 100%; height: 100%; background-color: rgba(0,0,0,0.6);
    backdrop-filter: blur(5px); justify-content: center; align-items: center;
}
.modal-content {
    background: var(--white); padding: 30px; border-radius: 15px;
    width: 90%; max-width: 400px; text-align: center;
    position: relative; animation: zoomIn 0.3s;
}
@keyframes zoomIn { from {transform: scale(0.8); opacity: 0;} to {transform: scale(1); opacity: 1;} }

.close-btn { position: absolute; top: 10px; right: 20px; font-size: 28px; cursor: pointer; color: #aaa; }
.close-btn:hover { color: var(--primary); }

/* --- 8. PROMO SYSTEM STYLES (BARU!) --- */
.promo-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    width: 300px; /* Ukuran kartu promo */
    display: flex;
    flex-direction: column;
    transition: transform 0.3s;
    border: 1px solid #eee;
}
.promo-card:hover { transform: translateY(-8px); box-shadow: 0 15px 30px rgba(0,0,0,0.15); }

.promo-img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-bottom: 3px solid var(--secondary);
}

.promo-body {
    padding: 20px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    text-align: left;
}

.promo-badge {
    background: var(--secondary);
    color: var(--dark);
    padding: 5px 12px;
    border-radius: 50px;
    font-weight: 800;
    font-size: 0.75rem;
    display: inline-block;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

/* Upload Area di Modal Promo */
#clUploadArea {
    background: #fff8e1; /* Kuning muda */
    border: 2px dashed var(--secondary);
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 20px;
    text-align: left;
}

/* Code Box di Modal Sukses */
#finalCode {
    background: #f4f4f4;
    color: #333;
    padding: 15px;
    font-family: 'Courier New', monospace;
    font-size: 2rem;
    font-weight: 800;
    letter-spacing: 3px;
    border: 3px dashed var(--primary);
    border-radius: 10px;
    margin: 20px 0;
}

/* Tombol Redeem */
.btn-redeem-opt {
    flex: 1;
    padding: 12px;
    border-radius: 8px;
    border: none;
    font-weight: bold;
    cursor: pointer;
    transition: 0.2s;
}
.btn-redeem-opt:hover { opacity: 0.9; }

/* --- 9. ABOUT & FOOTER --- */
.about-content { display: flex; align-items: center; gap: 40px; flex-wrap: wrap; }
.about-img { flex: 1; min-width: 300px; }
.about-img img { width: 100%; border-radius: 15px; box-shadow: var(--shadow); }
.about-text { flex: 1; min-width: 300px; }
.about-features { list-style: none; margin-top: 20px; }
.about-features li i { color: var(--secondary); margin-right: 10px; }

footer { background: var(--dark); color: var(--white); text-align: center; padding: 40px 20px 20px; margin-top: 50px; }
.socials a { color: white; font-size: 1.5rem; margin: 0 10px; transition: 0.3s; }
.socials a:hover { color: var(--secondary); }
.footer-bottom { border-top: 1px solid rgba(255,255,255,0.1); padding-top: 20px; font-size: 0.8rem; }

/* --- 10. MOBILE RESPONSIVE --- */
@media (max-width: 768px) {
    .hero-text h1 { font-size: 2.5rem; }
    .hero { text-align: center; padding-top: 40px; }
    .hero-container { justify-content: center; flex-direction: column-reverse; }
    
    .navbar { flex-direction: column; gap: 15px; padding: 15px; }
    .nav-brand { justify-content: center; width: 100%; }
    
    .about-content { text-align: center; }
    
    .top-banner { flex-direction: column; padding: 10px; }
    .banner-btn { margin: 5px 0 0 0; }
    
    #countdown { justify-content: center; }
    .promo-timer { width: 100%; }
    
    .hero-video-box video { aspect-ratio: 16/9; }
    
    /* Promo Mobile */
    .promo-card { width: 100%; max-width: 350px; margin: 0 auto; }
}

/* --- TAMBAHAN UNTUK PROMO PAGE --- */

/* Tombol Panduan (Floating Button) */
.guide-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    color: #c0392b;
    border: 2px solid #c0392b;
    padding: 8px 20px;
    border-radius: 50px;
    font-weight: bold;
    font-size: 1rem;
    cursor: pointer;
    margin-top: 15px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: 0.3s;
}
.guide-btn:hover {
    background: #c0392b;
    color: white;
    transform: translateY(-2px);
}

/* Style Countdown Timer di Card Promo */
.promo-countdown {
    background: #2c3e50;
    color: white;
    padding: 8px;
    border-radius: 5px;
    margin-top: 10px;
    margin-bottom: 10px;
    text-align: center;
    font-size: 0.9rem;
    font-weight: bold;
    display: flex;
    justify-content: center;
    gap: 5px;
}
.countdown-item {
    background: rgba(255,255,255,0.2);
    padding: 2px 5px;
    border-radius: 3px;
    min-width: 25px;
}
.countdown-label {
    font-size: 0.6rem;
    font-weight: normal;
    display: block;
    color: #ccc;
}

/* Style Modal Panduan */
#guideModal ol li {
    margin-bottom: 5px;
}

/* --- ANIMASI TIMER PROMO (SLIDE TICKER) --- */

.promo-timer-container {
    position: relative;
    width: 100%;
    height: 40px; /* Tinggi area timer */
    background: #2c3e50;
    border-radius: 5px;
    margin: 10px 0;
    overflow: hidden; /* Sembunyikan yg di luar kotak */
}

/* Wrapper untuk animasi slide */
.timer-slide-wrapper {
    display: flex;
    width: 200%; /* Lebar 2x karena ada 2 konten (Tanggal & Timer) */
    height: 100%;
    animation: slideTicker 10s infinite cubic-bezier(0.4, 0, 0.2, 1);
}

/* Konten di dalam wrapper */
.timer-content {
    width: 50%; /* Setengah dari wrapper */
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: bold;
    font-size: 0.9rem;
}

/* Konten 1: Tanggal Kadaluarsa */
.timer-date-info {
    background: #e74c3c; /* Merah */
}

/* Konten 2: Hitung Mundur */
.timer-countdown-view {
    background: #2c3e50; /* Gelap */
    gap: 5px;
}

/* Kotak-kotak kecil angka timer */
.countdown-box {
    background: rgba(255,255,255,0.2);
    padding: 2px 6px;
    border-radius: 4px;
    min-width: 28px;
    text-align: center;
}

/* KEYFRAMES ANIMASI */
@keyframes slideTicker {
    0%, 45% {
        transform: translateX(0%); /* Tahan di Tanggal (5 detik) */
    }
    50%, 95% {
        transform: translateX(-50%); /* Geser ke Timer & Tahan (5 detik) */
    }
    100% {
        transform: translateX(0%); /* Balik lagi */
    }
}

/* =========================================
   UPDATE STYLE.CSS (TIMER, KUOTA, GRID)
   ========================================= */

/* 1. ANIMASI TIMER BARU (SLIDE UP) */
.promo-timer-container {
    height: 40px; /* Tinggi fix agar teks tidak terpotong */
    overflow: hidden;
    background: #2c3e50;
    border-radius: 8px;
    margin: 12px 0;
    position: relative;
    border: 1px solid rgba(0,0,0,0.1);
    box-shadow: inset 0 2px 5px rgba(0,0,0,0.2);
}

.timer-slide-wrapper {
    display: flex;
    flex-direction: column;
    width: 100%;
    /* Animasi 8 detik: 3.5s Tanggal, 0.5s Geser, 3.5s Waktu, 0.5s Geser */
    animation: slideUpTimer 8s infinite cubic-bezier(0.4, 0, 0.2, 1);
}

.timer-content {
    height: 40px; /* Harus sama dengan container */
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 0.9rem;
    width: 100%;
    flex-shrink: 0;
}

/* Slide 1: Info Tanggal */
.timer-date-info {
    background: #c0392b; /* Merah */
    color: white;
    text-shadow: 1px 1px 0 rgba(0,0,0,0.2);
}

/* Slide 2: Hitung Mundur */
.timer-countdown-view {
    background: #2c3e50; /* Gelap */
    gap: 5px;
}

.countdown-box {
    background: rgba(255,255,255,0.1);
    padding: 2px 6px;
    border-radius: 4px;
    min-width: 28px;
    text-align: center;
    font-family: 'Courier New', monospace;
    border: 1px solid rgba(255,255,255,0.2);
    font-weight: bold;
}

@keyframes slideUpTimer {
    0%, 45% { transform: translateY(0); }         /* Diam di Tanggal */
    50%, 95% { transform: translateY(-40px); }    /* Geser ke Timer (-40px) */
    100% { transform: translateY(0); }            /* Balik */
}

/* 2. BADGE SISA KUOTA */
.quota-badge {
    font-size: 0.75rem;
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
    padding: 4px 10px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 5px;
    font-weight: 700;
    box-shadow: 0 2px 4px rgba(0,0,0,0.05);
}

/* 3. DOWNLOAD GRID (KOTAK KECIL) */
.download-section-title {
    font-size: 0.85rem;
    font-weight: bold;
    color: #555;
    margin-bottom: 8px;
    display: block;
    border-bottom: 2px solid #eee;
    padding-bottom: 5px;
}

.download-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 Kolom */
    gap: 10px;
}

.dl-box {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 10px 5px;
    text-decoration: none;
    color: #444;
    transition: all 0.2s;
    height: 80px;
    position: relative;
    overflow: hidden;
}

.dl-box:hover {
    border-color: #3498db;
    background: #f0f8ff;
    transform: translateY(-3px);
    box-shadow: 0 5px 10px rgba(0,0,0,0.1);
}

.dl-icon {
    font-size: 1.4rem;
    margin-bottom: 5px;
}
.dl-icon.img { color: #e67e22; } /* Ikon Gambar Orange */
.dl-icon.vid { color: #e74c3c; } /* Ikon Video Merah */

.dl-text {
    font-size: 0.65rem;
    font-weight: 600;
    text-align: center;
    line-height: 1.2;
    width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* --- ORDER MODAL STYLES --- */
.modal {
    display: none; 
    position: fixed; 
    z-index: 3000; 
    left: 0; top: 0;
    width: 100%; height: 100%; 
    background-color: rgba(0,0,0,0.6); 
    backdrop-filter: blur(5px);
    justify-content: center; 
    align-items: center;
    animation: fadeIn 0.3s;
}

.modal-content {
    background: white;
    width: 90%;
    max-width: 400px;
    border-radius: 15px;
    padding: 30px;
    position: relative;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    animation: slideDown 0.3s;
}

/* Efek Hover Tombol */
.order-options a:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.15);
    filter: brightness(1.1);
}

@keyframes fadeIn { from { opacity:0; } to { opacity:1; } }
@keyframes slideDown { from { transform: translateY(-20px); opacity:0; } to { transform: translateY(0); opacity:1; } }

/* =========================================
   UPDATE: FILTER MENU STYLES
   ========================================= */

.filter-container {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    overflow-x: auto; /* Biar bisa scroll samping di HP */
    padding-bottom: 10px;
    -webkit-overflow-scrolling: touch;
}

.filter-btn {
    background: white;
    border: 1px solid #ddd;
    color: #555;
    padding: 8px 20px;
    border-radius: 50px;
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap; /* Teks gak turun ke bawah */
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}

.filter-btn:hover {
    background: #eee;
    transform: translateY(-2px);
}

.filter-btn.active {
    background: var(--primary); /* Merah */
    color: white;
    border-color: var(--primary);
    box-shadow: 0 4px 10px rgba(192, 57, 43, 0.3);
}

/* Biar di HP tombolnya rata kiri & scrollable */
@media (max-width: 768px) {
    .filter-container {
        justify-content: flex-start;
        padding-left: 5px;
        padding-right: 5px;
    }
}