/* Base Reset & Typography */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: #fafafa; /* Background sedikit off-white biar mata nyaman */
    color: #111111;
    /* FONT UTAMA UTK BODY: Menggunakan 'Inter' yang dipakai e-commerce dunia Apple & Nike */
    font-family: 'Inter', sans-serif;
    padding: 0 0 40px 0;
    -webkit-font-smoothing: antialiased;
}

/* ========================================================
   STYLE TOP BAR / HEAD BAR 
   ======================================================== */
.top-bar {
    background-color: #0b0b0b;
    color: #ffffff;
    font-size: 0.72rem;
    padding: 10px 0;
    font-weight: 500;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    border-bottom: 1px solid #1a1a1a;
}

.top-bar-container {
    display: table;
    width: 90%;
    margin: 0 auto;
}

.top-bar-left {
    display: table-cell;
    text-align: left;
    vertical-align: middle;
    opacity: 0.65;
}

.top-bar-right {
    display: table-cell;
    text-align: right;
    vertical-align: middle;
}

.top-bar-right a {
    color: #ffffff;
    text-decoration: none;
    margin-left: 24px;
    opacity: 0.65;
    transition: opacity 0.2s ease;
}

.top-bar-right a:hover {
    opacity: 1;
}

/* ========================================================
   STYLE NAVBAR UTAMA
   ======================================================== */
/* ========================================================
   FIXED: NAVIGATION BAR (ANTI GEPENG & SUPER STABIL)
   ======================================================== */
/* ========================================================
   UPGRADE NAVBAR: MODERN FLEXBOX LINK (ANTI PATAH & ANTI GEPENG)
   ======================================================== */
.navbar {
    width: 90%;
    margin: 0 auto 30px auto;
    background: #ffffff;
    border-bottom: 1px solid #eeeeee;
    padding: 20px 0;
    
    /* Menggunakan flexbox modern agar pembagian kiri-tengah-kanan presisi */
    display: flex;
    display: -webkit-flex; /* Support browser lawas */
    justify-content: space-between;
    align-items: center;
}

.logo {
    width: max-content;
    flex-shrink: 0;
    display: inline-flex;
    align-items: center;
    gap: 8px; /* Dibuat jadi 8px biar makin rapat dan menyatu pas dengan logonya */
    
    font-family: 'Inter', sans-serif;
    font-size: 1.5rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: -0.5px;
    color: #111111;
    white-space: nowrap;
}


.search-bar {
    flex-grow: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.search-bar input {
    width: 75%; /* Memberikan ruang ekstra di kanan kiri agar tidak menjepit logo */
    padding: 12px 24px;
    border: 1px solid #e5e5e5;
    border-radius: 30px;
    outline: none;
    font-size: 0.88rem;
    font-family: 'Inter', sans-serif;
    background: #f5f5f5;
    transition: all 0.25s ease;
}

.search-bar input:focus {
    border-color: #111111;
    background: #ffffff;
    box-shadow: 0 0 0 4px rgba(0,0,0,0.03);
}

.cart-status {
    width: max-content;
    flex-shrink: 0;
    text-align: right;
}

.cart-status span {
    background: #111111;
    color: #ffffff;
    padding: 10px 22px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    letter-spacing: 0.3px;
    white-space: nowrap;
}

/* Penutup layout float agar grid produk di bawahnya tidak rusak */
.navbar::after {
    content: "";
    display: block;
    clear: both;
}

/* ========================================================
   CATEGORY FILTER BUTTONS
   ======================================================== */
.filter-container {
    width: 90%;
    margin: 0 auto 40px auto;
    display: flex;
    gap: 12px;
}

.btn-filter {
    background: #ffffff;
    border: 1px solid #e5e5e5;
    padding: 10px 22px;
    border-radius: 30px;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.82rem;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.2px;
    transition: all 0.2s ease;
}

.btn-filter.active, .btn-filter:hover {
    background: #111111;
    color: #ffffff;
    border-color: #111111;
}

/* ========================================================
   PRODUCT GRID SYSTEM
   ======================================================== */
.products-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 40px 30px; /* Jarak atas-bawah dan kanan-kiri yang seimbang */
    width: 90%;
    margin: 0 auto;
}

/* --------------------------------------------------------
   UPGRADE DETIL VISUAL CARD (PROFESSIONAL LOOK)
   -------------------------------------------------------- */
.product-card {
    background: #ffffff;
    border: 1px solid #eaeaea;
    border-radius: 20px;
    position: relative; 
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    /* Efek bayangan diganti super tipis halus ala brand mewah */
    box-shadow: 0 4px 15px rgba(0,0,0,0.015);
    transition: transform 0.45s cubic-bezier(0.165, 0.84, 0.44, 1), box-shadow 0.3s ease;
    cursor: pointer;
}

/* Efek pas ditaruh kursor mouse */
.product-card:hover {
    box-shadow: 0 30px 50px rgba(0, 0, 0, 0.06);
    transform: translateY(-8px) rotate(1.5deg);
}

/* Efek pas diklik */
.product-card:active {
    transform: scale(0.96) rotate(-0.5deg);
    transition: transform 0.1s ease;
}

/* Box Gambar Jersey */
.img-box {
    width: 100%;
    height: 310px;
    background: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 25px;
    border-top-left-radius: 20px;
    border-top-right-radius: 20px;
    overflow: hidden;
}

.img-box img {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.product-card:hover .img-box img {
    transform: scale(1.06);
}

/* --------------------------------------------------------
   UPGRADE BADGE DENGAN WARNA GRADASI MEWAH (GLOSSY)
   -------------------------------------------------------- */
.badge {
    position: absolute;
    top: -12px;        
    left: -12px;       
    padding: 7px 16px;
    font-size: 0.68rem;
    font-weight: 800;
    border-radius: 30px; 
    color: #ffffff;
    z-index: 99;       
    letter-spacing: 0.8px;
    text-transform: uppercase;
    box-shadow: 0 6px 14px rgba(0, 0, 0, 0.15); 
    animation: badgeWiggle 1.4s ease-in-out infinite;
    transform-origin: center;
}

@keyframes badgeWiggle {
    0%, 100% { transform: rotate(0deg) scale(1); }
    25% { transform: rotate(-6deg) scale(1.05); }
    50% { transform: rotate(6deg) scale(1.05); }
    75% { transform: rotate(-3deg) scale(1); }
}

/* Warna gradasi premium metalik */
.badge.hot { 
    background: linear-gradient(135deg, #ff416c, #ff4b2b); 
}

.badge.bestseller { 
    background: linear-gradient(135deg, #f12711, #f5af19); 
}

/* --------------------------------------------------------
   UPGRADE TYPOGRAPHY INFO BOX
   -------------------------------------------------------- */
.info-box {
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    background: #ffffff;
    border-bottom-left-radius: 20px;
    border-bottom-right-radius: 20px;
}

.league {
    font-size: 0.72rem;
    color: #00b4d8; /* Biru toska premium */
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.jersey-name {
    font-size: 1rem;
    font-weight: 700;
    color: #111111;
    line-height: 1.4;
    letter-spacing: -0.2px;
}

.price {
    font-size: 1.15rem;
    font-weight: 800;
    color: #111111; /* Hitam solid berkelas, bukan merah norak */
    margin-bottom: 10px;
    letter-spacing: -0.3px;
}

/* --------------------------------------------------------
   UPGRADE TOMBOL KERANJANG PREMIUM (HITAM SOLID MODEREN)
   -------------------------------------------------------- */
.btn-add-cart {
    background: #111111;
    color: #ffffff;
    border: none;
    padding: 14px;
    border-radius: 12px;
    cursor: pointer;
    font-weight: 700;
    font-size: 0.85rem;
    font-family: 'Inter', sans-serif;
    letter-spacing: 0.3px;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
}

.btn-add-cart:hover {
    background: #333333;
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

/* --- Responsive Layout --- */
@media (max-width: 1024px) {
    .products-grid { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    .top-bar { display: none; }
    .navbar {
        display: flex;
        flex-direction: column;
        gap: 14px;
        width: 100%;
        padding: 15px 20px;
    }
    .logo, .search-bar, .cart-status {
        display: block;
        width: 100%;
        text-align: center;
    }
    .search-bar input { width: 100%; }
    .cart-status { text-align: right; }
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 20px;
        width: 100%;
    }
    .filter-container {
        width: 100%;
        overflow-x: auto;
        white-space: nowrap;
    }
    .badge {
        top: -8px;
        left: -8px;
    }
}