/* ================================== */
/* STYLING KHUSUS HALAMAN GALERI */
/* ================================== */

/* Override .container bawaan dari base.css */
.container {
    max-width: 85%;
    margin: 40px auto;
    text-align: center;
    background-color: transparent;
    border-radius: 20px;
    flex: 1;
    padding: 0 20px;
}

/* Slider kategori */
.category-slider {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
    margin: 40px auto 20px;
}

.arrow {
    background-color: #c59b32;
    color: white;
    border: none;
    border-radius: 25%;
    cursor: pointer;
    transition: 0.3s;
    display: flex;
    justify-content: center;
    align-items: center;
    width: clamp(30px, 5vw, 45px);
    height: clamp(30px, 5vw, 45px);
    font-size: clamp(16px, 3vw, 24px);
}

.arrow:hover {
    background-color: #a17f24;
}

.categories {
    display: flex;
    gap: 2rem;
}

.category-slider-wrapper {
    width: 100%;
    padding: 0 5%;
    justify-content: center;
    display: flex;
}

.category {
    background-color: #fff;
    color: #000;
    padding: 10px 90px;
    border-radius: 10px;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.3s;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    white-space: nowrap;
    /* Mencegah teks kategori patah */
}

.category.active {
    background-color: #b3851a;
    color: #fff;
    transform: scale(1.1);
}

/* Konten kategori */
.content-category {
    display: none;
}

.content-category.active {
    display: block;
}

.title-box {
    background-color: #aaa;
    border-radius: 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    width: 100%;
    margin: 40px auto;
}

.gambar-wrapper-kiri,
.gambar-wrapper-kanan {
    flex: 0 0 20%;
    display: flex;
    justify-content: center;
    margin: 0 auto;
}

.gambar-wrapper-kiri img,
.gambar-wrapper-kanan img {
    width: 100%;
    max-width: 300px;
    /* Batas atas agar tidak terlalu besar */
    height: auto;
}

.teks-wrapper {
    flex: 1;
    text-align: center;
    padding: 20px;
    /* Tambahkan padding */
}

.teks-wrapper h2 {
    font-size: 60px;
    color: #fff;
    margin-bottom: 20px;
}

.teks-wrapper p {
    color: #000000;
    font-style: italic;
    line-height: 1.6;
    font-weight: 549;
    font-size: 28px;
}

.product-gallery {
    display: flex;
    justify-content: center;
    align-items: stretch;
    gap: 55px;
    margin: 50px auto;
    width: 100%;
    padding: 0 1%;
}

.gambar-kiri {
    flex: 0 0 40%;
    display: flex;
    justify-content: center;
}

.gambar-kanan {
    flex: 0 0 60%;
    display: flex;
    justify-content: center;
}

.product-gallery img {
    width: 100%;
    height: 700px;
    border-radius: 10%;
    object-fit: cover;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
}

.sec-product-gallery {
    display: flex;
    justify-content: space-between;
    align-items: stretch;
    gap: 3%;
    margin: 20px auto;
    width: 100%;
    padding: 0 1%;
    margin-bottom: 40px;
    flex-wrap: wrap;
    /* Izinkan wrap jika perlu */
}

.sec-product-gallery img {
    flex: 1;
    min-width: 200px;
    /* Lebar minimum sebelum wrap */
    width: 100%;
    height: auto;
    border-radius: 10%;
    object-fit: cover;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
}

.product-gallery img:hover,
.sec-product-gallery img:hover {
    transform: scale(1.02);
}

/* ========================== */
/* MEDIA QUERIES GALERI */
/* ========================== */
@media (max-width: 1024px) {
    .product-gallery {
        gap: 40px;
    }

    .gambar-wrapper-kiri img,
    .gambar-wrapper-kanan img {
        height: 300px;
    }

    .product-gallery img {
        height: 400px;
    }

    .sec-product-gallery img {
        height: auto;
        /* Biarkan tinggi otomatis */
    }

    .teks-wrapper h2 {
        font-size: 50px;
    }

    .teks-wrapper p {
        font-size: 22px;
    }

    .category {
        padding: 8px 25px;
        font-size: 18px;
    }
}

@media (max-width: 768px) {
    .categories {
        gap: 1.2rem;
    }

    .product-gallery {
        gap: 30px;
    }

    .product-gallery img {
        height: 500px;
    }

    .sec-product-gallery img {
        height: auto;
        margin-bottom: 20px;
    }

    .teks-wrapper h2 {
        font-size: 36px;
    }

    .teks-wrapper p {
        font-size: 18px;
    }

    .category {
        padding: 6px 20px;
        font-size: 16px;
    }

    .title-box {
        padding: 15px;
    }

    /* Sembunyikan gambar kecil di title-box */
    .gambar-wrapper-kiri,
    .gambar-wrapper-kanan {
        display: none;
    }

    .teks-wrapper {
        flex: 1 1 100%;
    }

    .sec-product-gallery {
        flex-wrap: wrap;
        justify-content: center;
    }

    .sec-product-gallery img {
        flex: 0 0 calc(50% - 15px);
        /* 2 kolom */
    }
    .title-box{
        margin: 0 auto;
    }
}

@media (max-width: 480px) {
    .categories {
        gap: 0.8rem;
    }

    .category {
        padding: 6px 25px;
        font-size: 16px;
    }

    .product-gallery {
        gap: 10px;
        padding: 0 8px;
        margin: 20px auto;
        flex-direction: column;
        /* Tumpuk di HP */
    }

    .product-gallery img {
        height: 300px;
    }

    .teks-wrapper h2 {
        font-size: 28px;
    }

    .teks-wrapper p {
        font-size: 16px;
    }

    .category {
        padding: 5px 15px;
        font-size: 14px;
    }

    /* .title-box {
        padding: 10px;
    } */

    .sec-product-gallery {
        flex-direction: row;
        /* Tetap 2 kolom */
        gap: 10px;
        padding: 0;
        margin: 10px auto;
    }

    .sec-product-gallery img {
        flex: 0 0 calc(50% - 10px);
        height: 100%;
        /* Biarkan proporsional */
    }
}

@media (max-width: 360px) {
    .categories {
        gap: 0.5rem;
    }

    .category {
        padding: 5px 18px;
        font-size: 14px;
    }

    .product-gallery img {
        height: 250px;
    }

    .teks-wrapper h2 {
        font-size: 24px;
    }

    .teks-wrapper p {
        font-size: 14px;
    }

    .category {
        padding: 4px 12px;
        font-size: 12px;
    }

    .sec-product-gallery img {
        flex: 0 0 calc(50% - 8px);
    }
}