/* ========================================================== */
/* 1. RESET DAN DASAR */
/* ========================================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif; 
}

body {
    line-height: 1.6;
    background-color: #f8f8f8;
    color: #333;
}

a {
    text-decoration: none;
    color: inherit;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ========================================================== */
/* 2. HEADER & NAVIGASI (Logo Dominan 150px) */
/* ========================================================== */
.header {
    background-color: #fff;
    color: #333;
    /* PENTING: Padding vertikal 0px agar logo 150px mengisi penuh */
    padding: 0px 40px; 
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); 
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: sticky;
    top: 0;
    z-index: 500;
}

.logo img {
    /* PENTING: Ukuran logo sangat besar */
    height: 150px; 
    transition: transform 0.3s;
}

.logo img:hover {
    transform: scale(1.05);
}

.navbar a {
    margin: 0 18px; 
    font-weight: 500;
    letter-spacing: 0.5px;
    transition: color 0.3s, border-bottom 0.3s;
    padding-bottom: 8px;
    position: relative;
}

.navbar a:hover,
.navbar a.active {
    color: #8B0000; 
}

/* Garis bawah modern pada navigasi aktif/hover */
.navbar a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 0;
    height: 2px;
    background-color: #8B0000;
    transition: width 0.3s ease-out;
}
.navbar a:hover::after,
.navbar a.active::after {
    width: 100%;
}

.header-actions {
    display: flex;
    align-items: center;
}

/* Icon Keranjang */
.cart-icon {
    position: relative;
    cursor: pointer;
    font-size: 1.6em;
    color: #333;
    padding: 5px;
    transition: color 0.3s;
}
.cart-icon:hover {
    color: #8B0000;
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -10px;
    background-color: #8B0000; 
    color: white;
    border-radius: 50%;
    padding: 3px 7px;
    font-size: 0.7em;
    line-height: 1;
    min-width: 20px;
    text-align: center;
    box-shadow: 0 0 5px rgba(0, 0, 0, 0.2);
}

/* ========================================================== */
/* 3. CAROUSEL/SLIDER (Elegansi) - RASIO 2:1 (135x67cm) */
/* ========================================================== */
.carousel-container {
    width: 100%;
    overflow: hidden;
    position: relative;
    /* MENGGUNAKAN PADDING UNTUK RASIO ASPEK 2:1 */
    height: 0; 
    padding-top: 50%; /* Membuat tinggi menjadi 50% dari lebar (rasio 2:1) */
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2); 
    margin-top: -1px; 
}

.slides {
    position: absolute;
    top: 0;
    left: 0;
    width: 300%; 
    height: 100%;
    display: flex;
    animation: slide-animation 15s infinite; 
}

.slide {
    width: calc(100% / 3);
    height: 100%;
    background-size: cover;
    background-position: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    text-align: center;
    padding: 0 5%;
}

/* Background images untuk setiap slide */
#slide-1 { 
    background-image: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('banner1.png'); 
}
#slide-2 { 
    background-image: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('banner2.png'); 
}
#slide-3 { 
    background-image: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.6)), url('banner3.png'); 
}

.slide h1 {
    font-size: 4em; 
    margin-bottom: 15px;
    font-weight: 700;
    letter-spacing: 2px;
    text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.7);
}

.slide p {
    font-size: 1.3em;
    margin-bottom: 30px;
    max-width: 700px;
}

.btn-slider {
    background-color: #8B0000;
    color: white;
    padding: 14px 40px; 
    border-radius: 50px; 
    font-weight: bold;
    letter-spacing: 1px;
    transition: background-color 0.3s, transform 0.2s;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

.btn-slider:hover {
    background-color: #A52A2A;
    transform: translateY(-2px);
}

/* Keyframes untuk Animasi Geser */
@keyframes slide-animation {
    0% { transform: translateX(0); }
    30% { transform: translateX(0); }
    33% { transform: translateX(-33.33%); }
    63% { transform: translateX(-33.33%); }
    66% { transform: translateX(-66.66%); }
    96% { transform: translateX(-66.66%); }
    100% { transform: translateX(0); }
}

/* ========================================================== */
/* 4. GRID PRODUK (Bersih dan Fokus) */
/* ========================================================== */
main {
    padding: 60px 0; 
}

.page-title {
    text-align: center;
    padding: 20px 0 40px;
}

.page-title h1 {
    font-size: 3em;
    color: #333;
}

.page-title p {
    color: #666;
    margin-top: 5px;
}

.product-section {
    max-width: 1200px;
    margin: 40px auto;
    padding: 0 20px;
    text-align: center;
}

.product-section h2 {
    font-size: 2.5em;
    margin-bottom: 50px;
    color: #333;
    display: inline-block;
    position: relative;
    padding-bottom: 10px;
}
.product-section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60%;
    height: 4px;
    background-color: #8B0000;
    border-radius: 2px;
}


.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); 
    gap: 35px;
}

.product-card {
    background-color: #fff;
    border-radius: 10px;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.1); 
    overflow: hidden;
    transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
    transform: translateY(-8px); 
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
}

.product-card img {
    width: 100%;
    height: 350px; 
    object-fit: cover;
    border-bottom: 1px solid #eee;
}

.product-info {
    padding: 20px;
    text-align: left;
}

.product-info h3 {
    font-size: 1.3em;
    margin-bottom: 8px;
    color: #333;
}

.product-info .price {
    color: #8B0000;
    font-weight: bold;
    margin-bottom: 15px;
    font-size: 1.2em;
}

.add-to-cart-btn {
    width: 100%;
    background-color: #333;
    color: white;
    border: none;
    padding: 12px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: background-color 0.3s, transform 0.2s;
}

.add-to-cart-btn:hover {
    background-color: #8B0000;
    transform: translateY(-1px);
}


/* ========================================================== */
/* 5. FOOTER (Elegan) */
/* ========================================================== */
.footer {
    background-color: #222; 
    color: #ccc;
    padding: 50px 40px 30px;
    margin-top: 50px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto 30px;
    padding-bottom: 25px;
    border-bottom: 1px solid #444;
}

.footer-column h4 {
    color: #fff;
    margin-bottom: 18px;
    font-size: 1.3em;
    border-left: 3px solid #8B0000;
    padding-left: 10px;
}

.footer-column p {
    font-size: 0.9em;
    line-height: 1.6;
    color: #bbb;
}

.footer-column ul {
    list-style: none;
    padding: 0;
}

.footer-column ul li a {
    display: block;
    padding: 6px 0;
    font-size: 0.9em;
    color: #bbb;
    transition: color 0.3s;
}

.footer-column ul li a:hover {
    color: #8B0000;
    transform: translateX(5px);
}

.footer-bottom {
    text-align: center;
    font-size: 0.8em;
    color: #888;
}


/* ========================================================== */
/* 6. CART MODAL (Keranjang Belanja) */
/* ========================================================== */

#cart-modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.7);
    display: none; 
}

.modal-content {
    background-color: #fefefe;
    margin: 5% auto; 
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 500px; 
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    position: relative;
    animation: fadeIn 0.3s ease-out; 
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-50px); }
    to { opacity: 1; transform: translateY(0); }
}

.close-btn {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    top: 15px;
    right: 20px;
}
.close-btn:hover,
.close-btn:focus {
    color: #333;
    text-decoration: none;
    cursor: pointer;
}

#cart-items {
    list-style: none;
    padding: 0;
    max-height: 300px; 
    overflow-y: auto; 
    margin-bottom: 20px;
}

.cart-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0; 
    border-bottom: 1px solid #eee; 
}

.cart-item:last-child {
    border-bottom: none; 
}

.item-details {
    flex-grow: 1;
}

.item-name {
    font-weight: 600; 
    color: #333;
}

.item-price {
    display: block;
    font-size: 0.9em;
    color: #8B0000; 
    font-weight: bold;
}

.quantity-controls {
    display: flex;
    align-items: center;
    gap: 8px; 
}

.quantity-controls button {
    background-color: #f0f0f0;
    color: #333;
    border: none;
    padding: 5px 10px;
    cursor: pointer;
    border-radius: 4px;
    font-weight: bold;
}

.quantity-controls button:hover {
    background-color: #e0e0e0;
}

#cart-total {
    font-size: 1.3em;
    font-weight: bold;
    text-align: right;
    padding-top: 15px;
    border-top: 2px solid #ddd;
    margin-top: 15px;
    color: #333;
}

#checkout-btn {
    width: 100%;
    padding: 15px;
    background-color: #25D366; 
    color: white;
    font-size: 1.1em;
    font-weight: bold;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    transition: background-color 0.3s;
    margin-top: 10px;
}

#checkout-btn:hover {
    background-color: #128C7E;
}

/* ========================================================== */
/* 7. MEDIA QUERIES (RESPONSIVE) */
/* ========================================================== */
@media (max-width: 900px) {
    .product-grid {
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 20px;
    }
    .slide h1 {
        font-size: 3em;
    }
    /* Logo 150px masih dipertahankan untuk semua lebar (jika muat) */
}

@media (max-width: 768px) {
    .header {
        /* Kembali ke padding standar untuk perangkat kecil */
        padding: 10px 20px; 
        flex-wrap: wrap;
    }
    .logo img {
         /* MENGECILKAN logo secara paksa di perangkat kecil agar muat */
        height: 60px; 
    }
    .navbar {
        order: 3;
        flex-basis: 100%;
        text-align: center;
        margin-top: 10px;
    }
    .navbar a {
        margin: 0 8px;
        padding-bottom: 5px;
        font-size: 0.9em;
    }
    .slide h1 {
        font-size: 2.5em;
    }
    .slide p {
        font-size: 1em;
    }
    .product-card img {
        height: 250px;
    }
    .footer-grid {
        grid-template-columns: 1fr;
    }
}