@import url('https://fonts.googleapis.com/css2?family=Inter:wght@100;200;300;400;500;600;700&display=swap');

* {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    padding-top: 0 !important;
}

/* HEADER GAMBAR */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    z-index: 1000;
    background-image: url('../assets/images/hero1.jpg');
    background-size: cover;
    background-position: center;
    transition: background-image 1.8s ease-in-out;
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

/* HERO WRAPPER */
.hero-wrapper {
    position: relative;
    height: 520px;
    overflow: hidden;
}

.hero-slideshow {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    opacity: 0;
    transition: opacity 1.8s ease-in-out;
}

.hero-slide.active { opacity: 1; }

.hero-content {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: 100px 20px 70px;
    pointer-events: none;
}

.text-center { text-align: center; pointer-events: auto; }

.header-title {
    font-size: 3rem;
    font-weight: 200;
    color: white;
    text-shadow: 0 3px 15px rgba(0,0,0,0.6);
    margin-bottom: 12px;
}

.header-subtitle {
    font-size: 1.4rem;
    color: #fff;
    margin: 8px 0;
    font-weight: 200;
    text-shadow: 0 2px 10px rgba(0,0,0,0.5);
}

.header-text {
    font-size: 1.2rem;
    color: #fff;
    font-weight: 100;
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
}

/* TOOLBAR */
.toolbar-container { pointer-events: auto; width: 100%; }
.toolbar {
    display: flex;
    justify-content: center;
    gap: 16px;
    flex-wrap: wrap;
    padding: 0 15px;
}

.view-btn,
.model-btn {
    background: transparent;
    color: white;
    border: 1.5px solid rgb(255, 255, 255);
    padding: 14px 28px;
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s ease;
    cursor: pointer;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
    min-width: 120px;
    justify-content: center;
}

.view-btn:hover,
.model-btn:hover,
.view-btn.active,
.model-btn.active {
    background: transparent;
    border-color: white;
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.25);
}

/* PRODUCTS GRID - DINAMIS */
.products-section {
    padding: 60px 0;
    background: #fff;
}

.products-section .container {
    padding: 0 !important;
    max-width: 100% !important;
    margin: 0 !important;
}

.products-grid {
    display: grid;
    gap: 2px;
    transition: grid-template-columns 0.4s ease;
}

/* DEFAULT (NORMAL) */
.products-grid.compact-view {
    grid-template-columns: repeat(6, 1fr); /* Desktop: 6 */
}

/* VIEW DI TEKAN */
.products-grid.expanded-view {
    grid-template-columns: repeat(3, 1fr); /* Desktop: 3 */
}

/* MOBILE: 768px ke bawah */
@media (max-width: 768px) {
    .products-grid.compact-view {
        grid-template-columns: repeat(3, 1fr); /* Mobile normal: 3 */
    }
    .products-grid.expanded-view {
        grid-template-columns: repeat(2, 1fr); /* Mobile view: 2 */
    }
}

/* ITEM */
.item {
    background: #fff;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease forwards;
}

.item:hover {
    transform: translateY(-6px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.15);
}

.item-image {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1;
    overflow: hidden;
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
}

/* BADGE: HITAM + KECIL */
.discount-badge,
.out-of-stock-badge {
    position: absolute;
    top: 8px;
    padding: 3px 7px;
    font-size: 9px;
    font-weight: 700;
    border-radius: 3px;
    z-index: 10;
    color: white;
    background: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(4px);
    letter-spacing: 0.5px;
}

.discount-badge { left: 8px; }
.out-of-stock-badge { right: 8px; }

/* TEKS: TIPIS & MODERN */
.item-content {
    padding: 12px;
    background: #fff;
}

.item-title {
    font-size: 0.82rem;
    font-weight: 200;
    color: #111;
    margin: 0 0 4px;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    overflow: hidden;
    letter-spacing: 0.3px;
}

.item-price {
    font-size: 0.78rem;
    font-weight: 200;
    color: #111;
    letter-spacing: 0.5px;
}

.final-price { color: #000; font-weight: 200; }
.original-price {
    color: #999;
    font-weight: 100;
    text-decoration: line-through;
    font-size: 0.68rem;
    margin-left: 4px;
}

.model-icon { width: 22px; height: 22px; }

@keyframes pulse { 0%, 100% { transform: scale(1); } 50% { transform: scale(1.18); } }
@keyframes fadeInUp { to { opacity: 1; transform: translateY(0); } }

/* RESPONSIVE */
@media (max-width: 768px) {
    .hero-wrapper { height: 420px; }
    .hero-content { padding: 90px 15px 60px; }
    .header-title { font-size: 2.4rem; }
    .toolbar { gap: 12px; }
    .view-btn, .model-btn { padding: 12px 20px; font-size: 0.9rem; min-width: 100px; }
}

@media (max-width: 480px) {
    .header-title { font-size: 2rem; }
    .view-btn, .model-btn { padding: 10px 16px; font-size: 0.85rem; min-width: 90px; }
    .toolbar { gap: 8px; }
}