/* =========================================
   1. VARIABEL & RESET
   ========================================= */
:root {
    --primary-blue: #003399;   /* Warna Biru Utama (Header) */
    --dark-blue: #002266;      /* Warna Biru Gelap (Footer) */
    --accent-yellow: #FFFF00;  /* Warna Kuning (Teks/Hover) */
    --white: #ffffff;
    --gray-bg: #f5f5f5;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

body {
    font-family: 'Segoe UI', sans-serif; /* Atau 'Roboto' jika sudah load font google */
    background-color: var(--gray-bg);
    color: #333;
    /* Jaga jarak bawah khusus di HP agar konten tidak ketutup menu sticky */
    padding-bottom: 80px; 
}

a { text-decoration: none; color: inherit; transition: 0.3s; }
ul { list-style: none; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* =========================================
   2. HEADER BARU (DESKTOP STYLE)
   ========================================= */
.main-header {
    background-color: var(--primary-blue);
    color: var(--white);
    padding: 15px 0;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky; /* Header nempel saat scroll */
    top: 0;
    z-index: 1000;
}

/* Flexbox Utama Header (Kiri - Tengah - Kanan) */
.header-flex {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* --- Bagian Kiri: Logo + Kategori --- */
.header-left {
    display: flex;
    align-items: center;
}

.brand-logo {
    font-size: 24px;
    font-weight: 800;
    color: var(--white);
    margin-right: 25px; /* Jarak antara logo dan tombol kategori */
    letter-spacing: -0.5px;
}
.brand-logo span { color: var(--accent-yellow); }

/* Tombol Kategori (Sebelah Logo) */
.kategori-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    border-left: 1px solid rgba(255,255,255,0.3); /* Garis pemisah tipis */
    padding-left: 20px;
    height: 30px;
}
.kategori-btn:hover { color: var(--accent-yellow); }

/* --- Bagian Tengah: Menu Navigasi --- */
.desktop-nav {
    display: flex;
    gap: 25px;
}
.desktop-nav a {
    color: var(--white);
    font-size: 14px;
    font-weight: 500;
    opacity: 0.9;
}
.desktop-nav a:hover, .desktop-nav a.active {
    opacity: 1;
    color: var(--accent-yellow);
}

/* --- Bagian Kanan: Search Bar --- */
.header-right {
    display: flex;
    align-items: center;
}
.search-box {
    background: var(--white);
    border-radius: 4px;
    padding: 5px 12px;
    display: flex;
    align-items: center;
    width: 220px;
}
.search-icon { color: #999; font-size: 12px; margin-right: 8px; }
.search-box input {
    border: none;
    outline: none;
    width: 100%;
    font-size: 13px;
    color: #333;
}

/* Tombol Hamburger (Khusus HP) */
.mobile-toggle {
    display: none; /* Sembunyi di Desktop */
    font-size: 24px;
    cursor: pointer;
}

/* =========================================
   3. FOOTER INFORMASI (BIRU GELAP)
   ========================================= */
.site-footer {
    background-color: var(--dark-blue);
    color: var(--white);
    padding: 40px 0 20px;
    margin-top: 40px;
    font-size: 14px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr; /* Default 1 kolom (HP) */
    gap: 30px;
}

.footer-column h3 {
    color: var(--accent-yellow);
    margin-bottom: 15px;
    font-size: 16px;
    text-transform: uppercase;
    font-weight: bold;
}

/* List Icon Sosmed & Badge Pembayaran */
.social-links a { margin-right: 15px; font-size: 18px; }
.social-links a:hover { color: var(--accent-yellow); }

.payment-list { display: flex; flex-wrap: wrap; gap: 8px; }
.pay-badge {
    background: white;
    color: #333;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
}

.contact-list li { margin-bottom: 10px; display: flex; align-items: flex-start; }
.contact-list i { width: 20px; margin-top: 4px; color: var(--accent-yellow); }

.copyright {
    text-align: center;
    border-top: 1px solid rgba(255,255,255,0.1);
    padding-top: 20px;
    margin-top: 40px;
    font-size: 12px;
    color: #ccc;
}

/* =========================================
   4. STICKY BOTTOM NAV (KHUSUS HP)
   ========================================= */
.bottom-nav {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 65px;
    background: var(--white);
    box-shadow: 0 -2px 15px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    padding: 0 10px;
    z-index: 999;
}

.nav-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--primary-blue);
    font-size: 10px;
    flex: 1;
    height: 100%;
}
.nav-item i { font-size: 20px; margin-bottom: 4px; }
.nav-item:active { background-color: #f9f9f9; }

/* Tombol Home Floating (Menonjol) */
.nav-item.home-btn {
    position: relative;
    top: -25px;
    overflow: visible;
}
.home-circle {
    width: 55px;
    height: 55px;
    background: var(--primary-blue);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 5px solid var(--white);
    box-shadow: 0 -3px 5px rgba(0,0,0,0.1);
}

/* =========================================
   5. MEDIA QUERIES (RESPONSIVE RULES)
   ========================================= */

/* A. TAMPILAN HP / TABLET KECIL (Dibawah 900px) */
@media (max-width: 900px) {
    /* Sembunyikan elemen Desktop Header yang ribet */
    .desktop-nav, 
    .kategori-btn, 
    .header-right { 
        display: none; 
    }
    
    /* Munculkan tombol Hamburger */
    .mobile-toggle { display: block; }
}

/* B. TAMPILAN DESKTOP (Diatas 900px) */
@media (min-width: 901px) {
    /* Padding Body dinormalkan (karena tidak ada menu bawah) */
    body { padding-bottom: 0; }
    
    /* Sembunyikan Menu Bawah & Hamburger */
    .bottom-nav, 
    .mobile-toggle { 
        display: none; 
    }
    
    /* Grid Footer jadi 3 Kolom */
    .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
}


/* =========================================
   6. BAGIAN KONTEN UTAMA (HOME)
   ========================================= */

/* --- A. HERO SLIDER --- */
.hero-section { margin-bottom: 20px; }
.hero-slide-item img {
    width: 100%;
    height: auto;
    border-radius: 0; /* Full width di HP */
    display: block;
}
@media (min-width: 768px) {
    .hero-slide-item img { border-radius: 10px; height: 300px; object-fit: cover; }
}

/* --- B. KATEGORI CETAK (Grid Bulat) --- */
.kategori-section { padding: 20px 0; background: white; margin-bottom: 15px; }
.kategori-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr); /* 5 kolom */
    gap: 15px;
    text-align: center;
}
.kat-item { display: flex; flex-direction: column; align-items: center; cursor: pointer; }
.kat-icon {
    width: 50px; height: 50px;
    border: 1px solid #eee; border-radius: 15px;
    display: flex; align-items: center; justify-content: center;
    margin-bottom: 8px; font-size: 20px; color: var(--primary-blue);
}
.kat-text { font-size: 11px; color: #555; line-height: 1.2; }

/* --- C. FLASH SALE / SECTION HEADER --- */
.section-box {
    background: white;
    padding: 15px 0 20px 0; /* Padding atas bawah */
    margin-bottom: 15px;
    border-top: 1px solid #eee;
}

.section-header {
    display: flex; justify-content: space-between; align-items: center;
    padding: 0 20px 15px 20px; /* Padding kiri kanan */
}

.header-left-group { display: flex; align-items: center; gap: 10px; }
.section-title { font-size: 16px; font-weight: 800; color: #333; }
.see-all { font-size: 12px; color: var(--primary-blue); font-weight: 600; }

/* Countdown Timer Style */
.countdown { display: flex; gap: 4px; align-items: center; margin-left: 10px; }
.time-box {
    background-color: #d0011b; /* Merah Flash Sale */
    color: white;
    font-size: 12px; font-weight: bold;
    padding: 3px 6px; border-radius: 4px;
}
.time-sep { font-weight: bold; color: #d0011b; }

/* =========================================
   UPDATE STYLE PRODUCT CARD (MARKETPLACE STYLE)
   ========================================= */

/* Wrapper supaya bayangan tidak terpotong slider */
.slick-list { padding: 10px 0 20px 0 !important; } 
.slick-slide { margin: 0 8px; } /* Jarak antar kartu */

.product-card {
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px; /* Sudut tumpul */
    overflow: hidden;
    position: relative;
    transition: all 0.3s ease;
    height: 100%; /* Biar tinggi sama rata */
    display: flex;
    flex-direction: column;
}

/* Efek Hover: Naik sedikit & Bayangan */
.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    border-color: var(--primary-blue);
}

/* Badge Diskon (Tag Merah) */
.discount-badge {
    position: absolute;
    top: 0;
    right: 0;
    background: #d0011b; /* Merah cabe */
    color: white;
    font-size: 10px;
    font-weight: 800;
    padding: 4px 8px;
    border-bottom-left-radius: 8px;
    z-index: 2;
}

/* Bagian Gambar */
.prod-img-wrap {
    width: 100%;
    padding-top: 100%; /* Trik rasio 1:1 (Kotak Sempurna) */
    position: relative;
    background-color: #f9f9f9;
}
.prod-img-wrap img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover; /* Gambar pas penuh */
}

/* Bagian Isi (Teks) */
.prod-info {
    padding: 12px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.prod-name {
    font-size: 13px;
    font-weight: 500;
    color: #333;
    line-height: 1.4;
    margin-bottom: 8px;
    
    /* Batasi cuma 2 baris, sisanya ... */
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 38px; /* Tinggi fix untuk 2 baris */
}

/* Harga Coret (Abu kecil) */
.coret {
    font-size: 11px;
    color: #999;
    text-decoration: line-through;
    display: block;
    margin-bottom: 2px;
}

/* Harga Asli (Besar & Tebal) */
.price-final {
    font-size: 15px;
    font-weight: 700;
    color: var(--primary-blue); /* Atau ganti #ee4d2d (Oren Shopee) */
    display: block;
}

/* Tombol Aksi (Opsional, muncul pas hover atau selalu ada) */
.action-btn {
    margin-top: 10px;
    width: 100%;
    padding: 6px 0;
    font-size: 12px;
    font-weight: bold;
    color: var(--primary-blue);
    border: 1px solid var(--primary-blue);
    background: white;
    border-radius: 4px;
    cursor: pointer;
    text-align: center;
    transition: 0.2s;
}
.product-card:hover .action-btn {
    background: var(--primary-blue);
    color: white;
}


/* =========================================
   STYLE KATEGORI ALA SHOPEE (2 BARIS)
   ========================================= */

/* Box Putih Pembungkus Utama */
.shopee-cat-box {
    background: white;
    border: 1px solid #e5e5e5;
    padding: 0; /* Padding 0 biar rapi */
    margin-bottom: 20px;
    border-radius: 3px;
}

/* Judul "KATEGORI" */
.cat-header-title {
    padding: 20px;
    font-size: 16px;
    font-weight: 700;
    color: rgba(0,0,0,.54);
    border-bottom: 1px solid #e5e5e5;
    text-transform: uppercase;
}

/* Item Kategori Individual */
.cat-item-link {
    display: block;
    border-right: 1px solid #f1f1f1;
    border-bottom: 1px solid #f1f1f1;
    text-align: center;
    padding: 15px 5px;
    transition: 0.2s;
    height: 150px; /* Tinggi fix biar sama rata */
    text-decoration: none !important;
    background: white;
    color: rgba(0,0,0,.8);
}

.cat-item-link:hover {
    box-shadow: 0 0 8px rgba(0,0,0,0.1);
    border-color: rgba(0,0,0,0.1);
    position: relative;
    z-index: 5; /* Biar pas hover dia muncul di atas border tetangga */
}

/* Gambar Kategori */
.cat-img-box {
    width: 80px; /* Ukuran gambar shopee biasanya segini */
    height: 80px;
    margin: 0 auto 10px;
    /* border-radius: 50%; kalau mau bulat opsional */
    display: flex;
    align-items: center;
    justify-content: center;
}
.cat-img-box img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* Teks Kategori */
.cat-text-shopee {
    font-size: 13px;
    line-height: 1.2;
    margin-top: 5px;
    display: -webkit-box;
    -webkit-line-clamp: 2; /* Maksimal 2 baris */
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Navigasi Panah Kanan/Kiri Slider */
.cat-slider .slick-arrow {
    background: white;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    box-shadow: 0 1px 4px rgba(0,0,0,0.2);
    z-index: 10;
}
.cat-slider .slick-prev { left: -10px; }
.cat-slider .slick-next { right: -10px; }
.cat-slider .slick-prev:before, .cat-slider .slick-next:before {
    color: #333; /* Warna panah */
    font-size: 16px;
}



/* =========================================
   TOMBOL PESAN (CTA) UNTUK PRODUK
   ========================================= */
.card-action-btn {
    display: block;
    width: 100%;
    padding: 6px 0;
    margin-top: 10px;
    text-align: center;
    background-color: #fff;
    color: var(--primary-blue);
    border: 1px solid var(--primary-blue);
    border-radius: 4px;
    font-size: 12px;
    font-weight: bold;
    transition: all 0.2s ease-in-out;
}

/* Efek Hover: Jadi Biru Penuh */
.product-card:hover .card-action-btn {
    background-color: var(--primary-blue);
    color: #fff;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}



/* =========================================
   MOBILE SIDE MENU (SLIDE DARI KIRI)
   ========================================= */

/* Wadah Menu (Sembunyi di Kiri Layar) */
.mobile-side-menu {
    position: fixed;
    top: 0;
    left: -280px; /* Sembunyi sejauh 280px ke kiri */
    width: 280px;
    height: 100%;
    background: #fff;
    z-index: 2000; /* Paling atas */
    box-shadow: 2px 0 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease-in-out;
    display: flex;
    flex-direction: column;
}

/* Class Aktif (Munculin Menu) */
.mobile-side-menu.active {
    left: 0; /* Geser ke posisi 0 (terlihat) */
}

/* Header Sidebar */
.side-menu-header {
    background: var(--primary-blue);
    padding: 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: white;
}
.close-menu-btn {
    cursor: pointer;
    font-size: 20px;
    color: white;
}

/* List Menu */
.side-menu-list {
    padding: 10px 0;
    overflow-y: auto; /* Bisa discroll kalau menu panjang */
}
.side-menu-list li {
    display: block;
}
.side-menu-list a {
    display: flex;
    align-items: center;
    padding: 15px 20px;
    color: #333;
    font-size: 14px;
    font-weight: 500;
    border-bottom: 1px solid #f5f5f5;
    transition: 0.2s;
}
.side-menu-list a i {
    width: 25px;
    color: var(--primary-blue);
    margin-right: 10px;
    font-size: 16px;
}
.side-menu-list a:hover {
    background: #f9f9f9;
    color: var(--primary-blue);
    padding-left: 25px; /* Efek geser dikit pas hover */
}

/* Garis Pemisah */
.side-menu-list li.divider {
    height: 5px;
    background: #f5f5f5;
    margin: 10px 0;
}

/* Layar Hitam Transparan (Overlay) */
.menu-overlay {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 1999;
    display: none; /* Sembunyi default */
    opacity: 0;
    transition: opacity 0.3s;
}
.menu-overlay.active {
    display: block;
    opacity: 1;
}