/* =======================================================
   1. RESET & DASAR (PENTING SUPAYA RAPI)
   ======================================================= */
* {
    box-sizing: border-box; /* Kunci agar padding tidak merusak lebar elemen */
}

body {
    margin: 0;
    padding: 0;
    font-family: 'Inter', sans-serif;
    overflow-x: hidden; /* Mencegah scroll horizontal tidak sengaja */
}

a {
    color: #19211b;
    text-decoration: none;
}

a:hover {
    color: #0b150d;
}

/* =======================================================
   2. LAYOUT FRAMEWORK (SOLUSI MASALAH "NEMPEL DINDING")
   ======================================================= */

/* Container: Membungkus konten agar ada jarak kiri-kanan */
.container {
    width: 100%;
    padding-right: 15px; /* Jarak napas kanan */
    padding-left: 15px;  /* Jarak napas kiri */
    margin-right: auto;
    margin-left: auto;
}

/* Media Query: Membatasi lebar container di layar besar */
@media (min-width: 576px) { .container { max-width: 540px; } }
@media (min-width: 768px) { .container { max-width: 720px; } }
@media (min-width: 992px) { .container { max-width: 960px; } }
@media (min-width: 1200px) { .container { max-width: 1140px; } }

/* Section Padding: Jarak atas bawah antar bagian */
.section-padding {
    padding-top: 60px;
    padding-bottom: 60px;
}

/* Row & Column System (Grid Sederhana) */
.row {
    display: flex;
    flex-wrap: wrap;
    margin-right: -15px;
    margin-left: -15px;
}

.col-md-7, .col-md-5, .col-4, .col {
    position: relative;
    width: 100%;
    padding-right: 15px;
    padding-left: 15px;
}

/* Pembagian Kolom di Laptop/Tablet (Layar > 768px) */
@media (min-width: 768px) {
    .col-md-7 {
        flex: 0 0 58.333333%;
        max-width: 58.333333%;
    }
    .col-md-5 {
        flex: 0 0 41.666667%;
        max-width: 41.666667%;
    }
    .col {
        flex: 1 0 0%; /* Kolom otomatis rata */
    }
}

/* Untuk Thumbnail Kecil (3 kolom berjejer) */
.col-4 {
    flex: 0 0 33.333333%;
    max-width: 33.333333%;
}


/* =======================================================
   3. UTILITIES & TYPOGRAPHY (BANTUAN)
   ======================================================= */
.text-center { text-align: center !important; }
.text-white { color: #fff !important; }
.fw-bold { font-weight: 700 !important; }
.mb-3 { margin-bottom: 1rem !important; }
.mb-4 { margin-bottom: 1.5rem !important; }
.mt-4 { margin-top: 1.5rem !important; }
.bg-light { background-color: #f8f9fa !important; }
.rounded { border-radius: 0.25rem !important; }
.shadow-lg { box-shadow: 0 1rem 3rem rgba(0,0,0,.175) !important; }

/* Gambar Responsif */
.img-fluid {
    max-width: 100%;
    height: auto;
}

/* Judul Besar (Display-4) */
.display-4 {
    font-size: 2.5rem;
    font-weight: 300;
    line-height: 1.2;
}
@media (min-width: 768px) { .display-4 { font-size: 3.5rem; } }

.lead {
    font-size: 1.25rem;
    font-weight: 300;
}

/* Scroll Samping untuk Thumbnail di HP */
.overflow-x-auto {
    overflow-x: auto;
    display: flex; /* Memaksa berjejer ke samping */
    flex-wrap: nowrap; /* Jangan turun ke bawah */
    gap: 10px;
    padding-bottom: 10px;
}
.overflow-x-auto .col-4 {
    flex: 0 0 auto; /* Supaya ukuran tetap */
    width: 150px; /* Lebar minimum */
}


/* =======================================================
   4. CUSTOM STYLE KAMU (ASLI DARI KODE SEBELUMNYA)
   ======================================================= */

/* --- HERO & BACKGROUND --- */
.hero-header-bg {
    background-image: 
        linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
        url('../assets/img/bgcrg.jpeg'); /* Pastikan path gambar benar */
    background-size: cover;
    background-position: center;
    height: 30vh;
    min-height: 250px; 
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-hider-bg-pg {
    background-image: 
        linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5)),
        url('../assets/img/bgplg.jpeg');
    background-size: cover;
    background-position: center;
    height: 30vh;
    min-height: 250px; 
    display: flex;
    align-items: center;
    justify-content: center;
}

/* --- CAROUSEL --- */
.carousel-item {
    height: 500px;
    background-size: cover;
    background-position: center;
    position: relative;
    border-radius: 15px;
    overflow: hidden;
}

.carousel-caption-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    color: white;
    text-align: center;
}

@media (max-width: 768px) {
    .carousel-item { height: 300px; }
    .carousel-caption-overlay h1 { font-size: 1.8rem; }
}

/* --- PRICE CARD --- */
.price-card {
    border: none;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    transition: 0.3s;
}
.price-card:hover { transform: translateY(-5px); }
.price-header {
    background-color: #0d6efd;
    color: white;
    padding: 20px;
    border-radius: 5px 5px 0 0;
}

/* --- BUTTONS --- */
.btn-primary {
    display: inline-block;
    font-weight: 400;
    text-align: center;
    vertical-align: middle;
    user-select: none;
    border: 1px solid transparent;
    padding: .375rem .75rem;
    font-size: 1rem;
    line-height: 1.5;
    border-radius: .25rem;
    color: #fff;
    background-color: #28a745;
    border-color: #28a745;
    cursor: pointer;
}
.btn-primary:hover {
    background-color: #218838;
    border-color: #218838;
}

/* --- NAVBAR SHADOW --- */
#mainNavbar { transition: box-shadow 0.3s ease-in-out; }
#mainNavbar.scrolled { box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06); }

/* --- BACK TO TOP --- */
.back-to-top {
    position: fixed;
    bottom: 25px;
    right: 25px;
    display: none;
    width: 44px;
    height: 44px;
    border-radius: 8px;
    background-color: #28a745; /* Saya tambahkan warna background agar terlihat */
    color: white;
    text-align: center;
    line-height: 44px;
    font-size: 24px;
    z-index: 1000;
    transition: opacity 0.3s, visibility 0.3s;
    opacity: 0;
    visibility: hidden;
}
.back-to-top.show {
    display: block;
    opacity: 1;
    visibility: visible;
}

/* --- LAIN-LAIN --- */
.bg-abu-sedang { background-color: #8a95a0; }
.card {
    position: relative;
    display: flex;
    flex-direction: column;
    min-width: 0;
    word-wrap: break-word;
    background-color: #fff;
    background-clip: border-box;
    border: 1px solid rgba(0,0,0,.125);
    border-radius: .25rem;
}
.card-body {
    flex: 1 1 auto;
    padding: 1.25rem;
}
.alert {
    position: relative;
    padding: .75rem 1.25rem;
    margin-bottom: 1rem;
    border: 1px solid transparent;
    border-radius: .25rem;
}
.alert-warning {
    color: #856404;
    background-color: #fff3cd;
    border-color: #ffeeba;
}
.list-unstyled {
    padding-left: 0;
    list-style: none;
}