/* Ini adalah file CSS untuk mengatur tampilan */
body {
    font-family: 'Poppins', sans-serif; /* Font baru yang lebih elegan */
    background-color: #f8f9fa; /* Warna latar sedikit lebih terang dan bersih */
    color: #333;
    margin: 0;
    padding: 0;
}

/* Mengatur bagian Header (Atas) */
/* ================= HEADER & NAVIGASI PREMIUM ================= */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: #111; /* Hitam pekat elegan */
    padding: 20px 5%; /* Jarak spasi lebih lega */
    position: sticky; /* Membuat menu selalu menempel di atas saat discroll */
    top: 0;
    z-index: 999; /* Memastikan menu selalu paling depan */
    box-shadow: 0 4px 10px rgba(0,0,0,0.5); /* Bayangan bawah header */
}

/* Desain Logo Dua Warna */
.logo h2 {
    margin: 0;
    font-size: 1.8em;
    font-weight: 800; /* Font logo lebih tebal dari menu */
    letter-spacing: 2px; /* Jarak antar huruf sedikit dilebarkan */
    color: white;
}
.logo h2 span {
    color: #f39c12; /* Warna Emas/Oranye untuk kata PREMIUM */
}

/* Desain Menu Navigasi */
nav a {
    color: #cccccc; /* Warna menu sedikit lebih redup dari logo */
    text-decoration: none;
    margin-left: 35px; /* Jarak antar menu */
    font-weight: 500;
    font-size: 1em;
    letter-spacing: 0.5px;
    position: relative; /* Wajib untuk animasi garis bawah */
    transition: color 0.3s ease; /* Transisi perubahan warna yang mulus */
}

/* Efek saat mouse menyorot menu */
nav a:hover {
    color: #ffffff; /* Teks menyala jadi putih bersih */
}

/* Garis bawah animasi yang tersembunyi */
nav a::after {
    content: '';
    position: absolute;
    width: 0; /* Awalnya tidak ada garis */
    height: 2px; /* Ketebalan garis */
    bottom: -6px; /* Posisi di bawah teks */
    left: 0;
    background-color: #f39c12; /* Warna garis emas */
    transition: width 0.3s ease; /* Kecepatan animasi garis muncul */
}

/* Garis bawah meluncur penuh saat disorot */
nav a:hover::after {
    width: 100%;
}

/* Mengatur bagian Banner Utama (Hero) */
/* ================= HERO BANNER PREMIUM ================= */
.hero {
    /* Menggunakan foto moge dari Unsplash sebagai latar + efek gelap (gradient) */
    background-image: linear-gradient(rgba(17, 17, 17, 0.7), rgba(17, 17, 17, 0.8)), url('https://images.unsplash.com/photo-1568772585407-9361f9bf3a87?q=80&w=1920&auto=format&fit=crop'); 
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Ini yang membuat efek PARALLAX 3D */
    padding: 20px 20px; /* Ruang atas bawah lebih lega */
    text-align: center;
    color: white;
}

.hero h1 {
    font-size: 3.5em; /* Ukuran font lebih besar dan gagah */
    font-weight: 800;
    margin-bottom: 10px;
    letter-spacing: -1px;
    text-shadow: 2px 2px 10px rgba(0,0,0,0.5); /* Efek bayangan pada teks */
}

.hero p {
    font-size: 1.2em;
    color: #cccccc;
    margin-bottom: 40px;
}

/* ================= SEARCH BAR KAPSUL ================= */
/* ================= SEARCH BAR KAPSUL ================= */
.search-kapsul {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 500px; /* Dipersempit agar tidak terlalu melebar */
    margin: 0 auto;
    background: white;
    border-radius: 50px;
    padding: 5px; /* Jarak putih di luar tombol sangat ditipiskan */
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.search-kapsul input {
    border: none;
    padding: 10px 20px; /* Ruang ketik dirampingkan */
    font-size: 0.95em; /* Ukuran huruf sedikit dikecilkan */
    width: 70%;
    outline: none;
    border-radius: 50px 0 0 50px;
    font-family: 'Poppins', sans-serif;
    color: #333;
}

.search-kapsul button {
    border: none;
    background: linear-gradient(135deg, #f39c12, #e67e22);
    color: white;
    padding: 10px 25px; /* Tombol oranye dibuat jauh lebih ramping */
    font-size: 0.95em; /* Huruf tombol dikecilkan */
    font-weight: 700;
    border-radius: 50px;
    cursor: pointer;
    transition: 0.3s ease;
}

.search-kapsul button:hover {
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(243, 156, 18, 0.4);
}

/* Mengatur bagian Bawah (Footer) */
footer {
    background-color: #1a1a1a;
    color: white;
    text-align: center;
    padding: 20px;
    margin-top: 40px;
}
/* --- DESAIN KATEGORI SOROTAN --- */
/* ================= KATEGORI SOROTAN PREMIUM ================= */
.kategori {
    padding: 1px 5px 5px 5px; /* Jarak atas dipangkas jadi 30px, jarak bawah 20px (sebelumnya 60px) */
    background-color: #f8f9fa;
    text-align: center;
}

.kategori h2 {
    font-size: 2.2em;
    color: #1a1a1a;
    margin-bottom: 25px; /* Jarak antara teks judul ke kotak-kotak dikurangi (sebelumnya 40px) */
    font-weight: 700;
}

.kategori-container {
    display: flex;
    justify-content: center;
    gap: 15px; /* Sebelumnya 25px, sekarang lebih rapat */
    flex-wrap: wrap;
    max-width: 1000px;
    margin: 0 auto;
}

.kategori-box {
    background: linear-gradient(145deg, #2c3e50, #1a1a1a);
    color: white;
    padding: 15px 25px; /* Ruang dalam jauh lebih kecil (sebelumnya 30px 40px) */
    border-radius: 8px; /* Ujung kotak sedikit lebih tajam agar terlihat rapi */
    min-width: 180px; /* Lebar minimal dikurangi (sebelumnya 220px) */
    box-shadow: 0 5px 15px rgba(0,0,0,0.1); /* Bayangan sedikit ditipiskan */
    transition: all 0.3s ease;
    border-bottom: 4px solid #f39c12;
    position: relative;
    overflow: hidden;
}

/* Efek saat mouse menyorot kategori */
.kategori-box:hover {
    transform: translateY(-8px); /* Kotak terangkat sedikit */
    box-shadow: 0 15px 30px rgba(243, 156, 18, 0.3); /* Bayangan memancarkan cahaya emas */
    cursor: pointer;
}

.kategori-box h3 {
    margin: 0 0 5px 0; /* Jarak antara judul dan teks bawah lebih rapat */
    font-size: 1.1em; /* Ukuran font lebih proporsional */
    font-weight: 600;
    letter-spacing: 0.5px;
    color: #f39c12;
}

.kategori-box p {
    margin: 0;
    font-size: 0.8em; /* Teks "Klik untuk lihat koleksi" lebih kecil */
    color: #bbbbbb;
    font-weight: 300;
}

/* --- DESAIN ETALASE PRODUK --- */
.etalase {
    text-align: center;
    padding: 40px 20px;
    background-color: #ffffff;
}

.produk-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr); /* 3 kolom untuk produk */
    gap: 25px;
    max-width: 1000px;
    margin: 30px auto;
}

.produk-card {
    background-color: white;
    border-radius: 12px; /* Ujung kartu lebih membulat */
    padding: 15px;
    text-align: center;
    box-shadow: 0 4px 10px rgba(0,0,0,0.05); /* Bayangan sangat lembut */
    transition: all 0.3s ease; /* Animasi mulus selama 0.3 detik */
    border: 1px solid #eee;
    position: relative;
}

/* Efek saat mouse diarahkan ke kartu */
.produk-card:hover {
    transform: translateY(-10px); /* Kartu terangkat ke atas 10 pixel */
    box-shadow: 0 15px 25px rgba(0,0,0,0.15); /* Bayangan membesar */
    border-color: #f39c12; /* Muncul garis tepi warna emas/oranye */
}

/* Merapikan teks harga */
.produk-card .harga {
    color: #e67e22;
    font-size: 1.2em;
    font-weight: 700;
    margin: 10px 0 20px 0;
}

/* Tempat foto sementara */
.gambar-dummy {
    background-color: #ccc;
    height: 200px;
    border-radius: 5px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    margin-bottom: 15px;
}

.harga {
    color: #e74c3c;
    font-size: 1.2em;
    font-weight: bold;
}

.btn-detail {
    display: block;
    background: linear-gradient(135deg, #2c3e50, #1a1a1a); /* Warna gradien gelap mewah */
    color: white;
    padding: 12px;
    text-decoration: none;
    border-radius: 30px; /* Bentuk tombol kapsul */
    font-weight: 600;
    letter-spacing: 1px;
    transition: 0.3s;
}

.btn-detail:hover {
    background: linear-gradient(135deg, #f39c12, #e67e22); /* Berubah warna emas/oranye saat disorot */
    transform: scale(1.05); /* Tombol sedikit membesar */
}

.btn-more {
    display: inline-block;
    background-color: #f39c12;
    color: white;
    padding: 12px 25px;
    text-decoration: none;
    border-radius: 5px;
    font-weight: bold;
    margin-top: 20px;
}

/* Desain Label Terjual */
.produk-card { position: relative; } /* Wajib ditambahkan agar label tidak lari */
.label-sold {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: #e74c3c;
    color: white;
    padding: 5px 15px;
    font-weight: bold;
    border-radius: 5px;
    z-index: 10;
    font-size: 0.9em;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* ================= TOMBOL LIHAT KATALOG ================= */
.btn-katalog-home {
    display: inline-block;
    background: linear-gradient(135deg, #f39c12, #e67e22); /* Warna gradien khas otomotif */
    color: white;
    padding: 12px 35px;
    border-radius: 50px; /* Bentuk kapsul kekinian */
    text-decoration: none;
    font-size: 1.05em;
    font-weight: 700;
    letter-spacing: 0.5px;
    box-shadow: 0 5px 15px rgba(243, 156, 18, 0.3);
    transition: all 0.3s ease;
}

.btn-katalog-home:hover {
    transform: translateY(-5px); /* Tombol sedikit terangkat */
    box-shadow: 0 10px 20px rgba(243, 156, 18, 0.5); /* Cahaya oranye melebar */
}

/* ================= FOOTER PREMIUM ================= */
footer {
    background-color: #111; /* Hitam pekat senada dengan Header */
    color: #cccccc;
    text-align: center;
    padding: 50px 20px;
    margin-top: 60px;
    border-top: 3px solid #f39c12; /* Garis emas tegas di bagian atas footer */
}

footer p {
    margin: 5px 0;
    font-size: 0.95em;
    letter-spacing: 0.5px;
}

footer strong {
    color: #f39c12; /* Menonjolkan nomor WA */
}

/* Desain Link Sosial Media */
/* Desain Logo Sosial Media (Bulat Aesthetic) */
.social-links {
    margin-top: 25px;
}

.social-links a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 45px;
    height: 45px;
    background-color: #222; /* Lingkaran gelap di belakang logo */
    color: #ffffff; /* Warna logo putih */
    text-decoration: none;
    margin: 0 10px;
    font-size: 1.2em; /* Ukuran logo proporsional */
    border-radius: 50%; /* Membuat lingkarannya bulat sempurna */
    border: 1px solid #333; /* Garis tepi tipis elegan */
    transition: all 0.3s ease;
}

/* Efek saat logo disentuh mouse */
.social-links a:hover {
    background-color: #f39c12; /* Lingkaran berubah warna emas */
    color: #111; /* Logo berubah gelap agar kontras */
    transform: translateY(-5px); /* Efek melayang ke atas */
    border-color: #f39c12;
    box-shadow: 0 5px 15px rgba(243, 156, 18, 0.4); /* Efek cahaya memancar */
}

/* ================= FILTER KATALOG MODERN ================= */
.filter-box {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    background: white;
    padding: 15px 25px;
    border-radius: 50px; /* Bentuk kapsul yang menyatu */
    max-width: 550px;
    margin: 20px auto 40px auto;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
    border: 1px solid #eee;
}

.filter-box label {
    font-weight: 600;
    color: #333;
    font-size: 0.95em;
}

.filter-box select {
    padding: 8px 15px;
    border-radius: 20px;
    border: 1px solid #ddd;
    outline: none;
    font-family: 'Poppins', sans-serif;
    font-size: 0.95em;
    background-color: #f8f9fa;
    color: #333;
    cursor: pointer;
}

.filter-box button {
    background: linear-gradient(135deg, #f39c12, #e67e22); /* Tombol gradien emas */
    color: white;
    border: none;
    padding: 8px 20px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.95em;
    cursor: pointer;
    transition: 0.3s ease;
}

.filter-box button:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 10px rgba(243, 156, 18, 0.4);
}

/* --- IKON USER DI NAVIGASI --- */
.nav-icon {
    display: inline-flex;
    align-items: center;
    padding-left: 15px;
    margin-left: 10px;
    border-left: 1px solid #444; /* Garis pembatas tipis di sebelah Tentang Saya */
}

.nav-icon svg {
    stroke: #cccccc; /* Warna abu-abu senada dengan teks menu */
    transition: all 0.3s ease;
}

.nav-icon:hover svg {
    stroke: #32cd32; /* Efek menyala hijau terang saat disorot */
    transform: scale(1.1); /* Ikon sedikit membesar */
}

/* =======================================================
   PENGATURAN RESPONSIVE UNTUK LAYAR HP (Maksimal 768px)
   ======================================================= */
@media screen and (max-width: 768px) {
    
    /* 1. Perbaiki Header agar logo dan menu tersusun ke bawah */
    header {
        flex-direction: column;
        text-align: center;
        padding: 15px;
        height: auto; /* Membiarkan tinggi header menyesuaikan isi */
    }
    
    header nav {
        margin-top: 15px;
        display: flex;
        flex-direction: column; /* Menu disusun ke bawah */
        gap: 10px;
        align-items: center;
    }

    /* Hilangkan garis pada ikon user di tampilan HP */
    .nav-icon {
        border-left: none; 
        padding-left: 0;
        margin-left: 0;
        margin-top: 10px;
    }

    /* 2. Perbaiki Daftar Motor agar menjadi 1 Kolom ke bawah */
    /* Catatan: Sesuaikan nama class ini jika di index.php Anda menggunakan nama berbeda */
    .katalog-grid, 
    .grid-produk,
    .produk-container {
        grid-template-columns: 1fr !important; /* Paksa menjadi 1 kolom penuh */
        gap: 20px;
        padding: 10px;
    }

    /* 3. Pastikan gambar di dalam kartu produk tidak meluber */
    .katalog-grid img, 
    .grid-produk img,
    .produk-container img {
        width: 100%;
        height: auto;
        object-fit: cover;
    }
    
    /* 4. Perbaiki Bagian Filter di Halaman Katalog */
    /* Menyesuaikan dengan elemen form, select, dan input pencarian */
    form {
        display: flex;
        flex-direction: column;
        gap: 10px;
        width: 100%;
    }

    select#kategori, 
    input[type="text"], 
    button[type="submit"] {
        width: 100% !important; /* Memaksa kotak memanjang penuh di layar HP */
        padding: 12px;
        box-sizing: border-box;
        margin-bottom: 5px;
    }
    
    /* 5. Paksa Kotak Putih Filter agar Tidak Keluar Layar */
    /* (Saya memasukkan beberapa kemungkinan nama class, ini akan otomatis mendeteksi) */
    .filter-container, 
    .form-filter, 
    form, 
    .kotak-filter {
        width: 100% !important;
        max-width: 100% !important;
        box-sizing: border-box !important; /* Mencegah padding membuat kotak melar */
        margin: 0 auto !important;
        padding: 15px !important;
        overflow: hidden; /* Mencegah isinya luber */
    }
}

/* Tombol Panah Kiri dan Kanan untuk Slider */
        .prev, .next {
            cursor: pointer;
            position: absolute;
            top: 50%;
            width: auto;
            padding: 15px 20px;
            margin-top: -30px;
            color: white;
            font-weight: bold;
            font-size: 24px;
            transition: 0.3s ease;
            user-select: none;
            background-color: rgba(0, 0, 0, 0.6);
            border: none;
            z-index: 1010;
        }
        .prev { left: 0; border-radius: 0 5px 5px 0; }
        .next { right: 0; border-radius: 5px 0 0 5px; }
        
        .prev:hover, .next:hover {
            background-color: #32cd32;
            color: #1a1a1a;
        }
        
        
    .galeri-tambahan img {
            width: 100%;
            aspect-ratio: 1 / 1; 
            object-fit: contain; /* Ubah 'cover' menjadi 'contain' */
            background-color: #ffffff; /* Tambahkan latar putih agar lebih rapi */
            border-radius: 8px;
            cursor: pointer; 
            transition: 0.3s;
            border: 1px solid #eee; /* Opsional: garis tepi tipis */
        }
        
    .produk-card img, .katalog-grid img {
            width: 100%;
            height: 200px; /* atau sesuai tinggi yang Anda atur sebelumnya */
            object-fit: contain; /* Pastikan ini contain */
            background-color: #ffffff;
        }
        
    
    /* Memastikan foto utama halaman detail tampil utuh di HP */
    .detail-kiri img, 
    .detail-produk img, 
    .foto-utama {
        height: auto !important;
        object-fit: contain !important;
        max-height: 300px; 
        background-color: #ffffff;
    }