/* --- CSS VARIABLES --- */
:root {
    --primary-color: #8C5535;
    --primary-hover: #6D4128;
    --accent-color: #E8D8C8;
    --bg-color: #FAFAF7;
    --text-main: #333333;
    --text-muted: #666666;
    
    --font-heading: 'Playfair Display', serif;
    --font-body: 'Poppins', sans-serif;
}

/* --- RESET & DASAR --- */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    background-color: var(--bg-color);
    color: var(--text-main);
    line-height: 1.6;
}

/* --- NAVIGASI --- */
.navbar {
    background-color: #ffffff;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.brand-logo {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: var(--primary-color);
    font-style: italic;
}

.cart-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    cursor: pointer;
    color: var(--primary-color);
}

.badge {
    background-color: #D9534F;
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 50%;
    position: absolute;
    top: -8px;
    right: -10px;
}

/* --- HERO SECTION --- */
.hero {
    position: relative;
    height: 60vh;
    min-height: 400px;
    background: url('https://images.unsplash.com/photo-1509440159596-0249088772ff?q=80&w=2072&auto=format&fit=crop') center/cover no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0, 0, 0, 0.4);
}

.hero-content {
    position: relative;
    z-index: 1;
    color: #ffffff;
    max-width: 600px;
    padding: 0 2rem;
}

.hero-content h2 {
    font-family: var(--font-heading);
    font-size: 3.5rem;
    line-height: 1.2;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
}

.hero-content p {
    font-size: 1.1rem;
    font-weight: 300;
    text-shadow: 1px 1px 3px rgba(0,0,0,0.3);
}

/* --- KONTEN UTAMA & GRID --- */
.container {
    max-width: 1200px;
    margin: 4rem auto;
    padding: 0 2rem;
}

.section-header {
    text-align: center;
    margin-bottom: 3rem;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.section-subtitle {
    color: var(--text-muted);
    font-size: 1rem;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 2rem;
}

.card {
    background: #ffffff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0,0,0,0.04);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex;
    flex-direction: column;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
    border-bottom: 3px solid var(--accent-color);
}

.card-content {
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.card-content h3 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: var(--text-main);
    margin-bottom: 0.5rem;
}

.card-content p {
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1rem;
    flex-grow: 1;
}

.price {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
    margin-bottom: 1.2rem;
    display: block;
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 0.8rem;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 500;
    font-family: var(--font-body);
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.btn-primary:hover:not(:disabled) {
    background-color: var(--primary-hover);
}

footer {
    background-color: #222;
    color: #aaa;
    text-align: center;
    padding: 2rem;
    margin-top: 4rem;
    font-size: 0.9rem;
}

/* --- MODAL CHECKOUT --- */
.modal {
    display: none; 
    position: fixed;
    z-index: 999;
    left: 0; top: 0;
    width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.6);
    align-items: center;
    justify-content: center;
}

.modal.active {
    display: flex;
}

.modal-content {
    background-color: var(--bg-color);
    padding: 2rem;
    border-radius: 12px;
    width: 90%;
    max-width: 450px;
    position: relative;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

.close-btn {
    position: absolute;
    top: 15px; right: 20px;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--text-muted);
}

.input-field {
    width: 100%;
    padding: 0.8rem;
    margin-bottom: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: var(--font-body);
}

.cart-item-row {
    display: flex;
    justify-content: space-between;
    border-bottom: 1px dashed #ccc;
    padding: 0.5rem 0;
    font-size: 0.95rem;
}

@media (max-width: 768px) {
    .hero-content h2 { font-size: 2.5rem; }
    .product-grid { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }
}