/* --- Global Styles & Fonts --- */
:root {
    --primary-color: #e50914;
    --dark-color: #141414;
    --light-color: #f5f5f5;
    --grey-color: #333;
    --font-heading: 'Teko', sans-serif;
    --font-body: 'Roboto', sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
    font-family: var(--font-body);
    background-color: var(--dark-color);
    color: var(--light-color);
    line-height: 1.6;
}
.container { max-width: 1100px; margin: auto; padding: 4rem 2rem; }
h1, h2, h3 { font-family: var(--font-heading); font-weight: 600; letter-spacing: 1px; }
h2 { font-size: 3rem; color: var(--primary-color); margin-bottom: 2rem; text-transform: uppercase; text-align: center; }
p { margin-bottom: 1rem; }

/* --- Navbar --- */
.navbar { display: flex; justify-content: space-between; align-items: center; padding: 0.5rem 2rem; background-color: rgba(20, 20, 20, 0.8); backdrop-filter: blur(10px); position: fixed; width: 100%; top: 0; z-index: 100; }
.nav-logo { font-family: var(--font-heading); font-size: 2rem; color: var(--primary-color); text-decoration: none; font-weight: 700; }
.nav-menu { display: flex; list-style: none; }
.nav-item { margin-left: 2rem; }
.nav-link { color: var(--light-color); text-decoration: none; transition: color 0.3s; }
.nav-link:hover { color: var(--primary-color); }
.hamburger { display: none; cursor: pointer; }
.bar { display: block; width: 25px; height: 3px; margin: 5px auto; background-color: var(--light-color); transition: all 0.3s ease-in-out; }
.nav-logo img {height: 75px; width: auto; display: block; padding: 0 0 0 0.4rem;}

/* --- HERO SECTION DENGAN SLIDER --- */
.hero-section { height: 100vh; position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; margin-top: 5rem;}
.hero-section::before { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.7); z-index: 1; }
.hero-slider { position: absolute; top: 0; left: 0; width: 300%; height: 100%; display: flex; transition: transform 1s ease-in-out; z-index: 0; }
.hero-slide { width: 33.333%; height: 100%; background-size: cover; background-position: center; }
.hero-content { position: relative; z-index: 2; text-align: center; padding: 0 1rem; }
.hero-content h1 { font-family: var(--font-heading); font-size: 5rem; font-weight: 900; color: var(--light-color); text-transform: uppercase; margin-bottom: 1rem; }
.hero-content p { font-size: 1.2rem; max-width: 600px; margin: 0 auto 2rem auto; }
.hero-dots { position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%); display: flex; z-index: 3; }
.hero-dot { width: 12px; height: 12px; border-radius: 50%; background-color: rgba(255, 255, 255, 0.5); margin: 0 6px; cursor: pointer; transition: all 0.3s ease; }
.hero-dot.active { background-color: var(--primary-color); transform: scale(1.2); }

/* --- Tombol CTA --- */
.cta-button { background-color: var(--primary-color); color: var(--light-color); padding: 15px 30px; text-decoration: none; border-radius: 5px; font-weight: 700; transition: transform 0.3s, background-color 0.3s; display: inline-block; }
.cta-button:hover { background-color: #ff0a16; transform: scale(1.05); }

/* --- Sections --- */
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 1.5rem; text-align: left; }
.feature-item { background-color: var(--grey-color); padding: 1.5rem; border-radius: 5px; border-left: 5px solid var(--primary-color); }
.feature-item h3 { font-size: 1.5rem; }

/* --- BAGIAN PROGRAM KAMI (SLIDER) --- */
.category-section { margin-top: 4rem; text-align: left;}
.category-title { font-size: 2.5rem; color: var(--light-color); border-bottom: 3px solid var(--primary-color); padding-bottom: 0.5rem; margin-bottom: 2rem; display: inline-block; }

.program-carousel-wrapper {
    position: relative;
}
.program-carousel {
    display: flex;
    overflow-x: auto; /* Memungkinkan scroll horizontal */
    scroll-behavior: smooth;
    -ms-overflow-style: none;  /* Sembunyikan scrollbar di IE dan Edge */
    scrollbar-width: none;  /* Sembunyikan scrollbar di Firefox */
    padding-bottom: 1rem; /* Beri ruang agar shadow tidak terpotong */
}
.program-carousel::-webkit-scrollbar {
    display: none; /* Sembunyikan scrollbar di Chrome, Safari, Opera */
}
.program-carousel .program-card {
    flex: 0 0 320px; /* Lebar setiap kartu, jangan menyusut atau membesar */
    margin-right: 1.5rem;
}
.program-card {
    background-color: var(--grey-color);
    border-radius: 8px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: transform 0.3s, box-shadow 0.3s;
}
.program-card:hover { transform: translateY(-10px); box-shadow: 0 10px 20px rgba(0,0,0,0.4); }
.program-card-img { width: 100%; height: 230px; object-fit: cover; }
.program-card-content { padding: 1.5rem; display: flex; flex-direction: column; flex-grow: 1; text-align: left; }
.program-card-content h3 { font-size: 1.8rem; margin-bottom: 0.5rem; color: var(--primary-color); }
.program-card-content p { flex-grow: 1; margin-bottom: 1.5rem; }
.wa-button { background-color: var(--primary-color); color: var(--light-color); padding: 10px 20px; text-align: center; text-decoration: none; border-radius: 5px; font-weight: 700; transition: background-color 0.3s; margin-top: auto; }
.wa-button:hover { background-color: #ff0a16; }

.program-prev, .program-next {
    top: 40%; /* Menyesuaikan posisi vertikal tombol */
}

/* --- Carousel Galeri --- */
#gallery-carousel-wrapper { position: relative; max-width: 900px; margin: auto; }
.carousel-inner { display: flex; transition: transform 0.5s ease-in-out; overflow: hidden; border-radius: 8px;}
.carousel-item { min-width: 100%; }
.carousel-item img { width: 100%; display: block; aspect-ratio: 16 / 9; object-fit: cover; }
.carousel-control { position: absolute; top: 50%; transform: translateY(-50%); background-color: rgba(0, 0, 0, 0.5); color: white; border: none; padding: 1rem; cursor: pointer; font-size: 1.5rem; z-index: 10; border-radius: 50%; width: 50px; height: 50px; line-height: 1; }
.carousel-control.prev { left: 15px; }
.carousel-control.next { right: 15px; }

/* --- Lokasi & Peta --- */
#location p { text-align: center; }
#location .map-container { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; max-width: 100%; background: #eee; border-radius: 8px; margin-top: 2rem; }
.map-container iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; }

/* --- CTA Final & Footer --- */
.cta-final { background-color: var(--grey-color); padding: 4rem 2rem; text-align: center;}
footer { text-align: center; padding: 2rem; background-color: #000; }
.social-icons { margin-bottom: 1.5rem; }
.social-icons a { color: var(--light-color); font-size: 1.8rem; margin: 0 15px; text-decoration: none; transition: color 0.3s; }
.social-icons a:hover { color: var(--primary-color); }


/* --- CSS BARU UNTUK GALERI --- */
.gallery-wrapper {
    position: relative;
    max-width: 900px;
    margin: auto;
}

.gallery-carousel {
    display: flex;
    overflow-x: auto;
    /* Ini adalah inti dari metode baru */
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    border-radius: 8px;
    /* Sembunyikan scrollbar */
    -ms-overflow-style: none;
    scrollbar-width: none;
}

.gallery-carousel::-webkit-scrollbar {
    display: none;
}

.gallery-item {
    flex: 0 0 100%;
    width: 100%;
    scroll-snap-align: center; /* Pastikan gambar berhenti di tengah */
}

.gallery-item img {
    width: 100%;
    display: block;
    aspect-ratio: 16 / 9;
    object-fit: cover;
}

/* Tombol navigasi untuk galeri */
.gallery-prev, .gallery-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
}

.gallery-prev {
    left: 15px;
}

.gallery-next {
    right: 15px;
}

/* --- BAGIAN TESTIMONI --- */
#testimonials {
    padding-bottom: 4rem;
}

.testimonial-slider-wrapper {
    width: 100%;
    overflow: hidden;
    /* Efek gradien di tepi untuk menyamarkan awal/akhir slider */
    -webkit-mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent);
    mask-image: linear-gradient(to right, transparent, black 20%, black 80%, transparent);
}

.testimonial-slider {
    display: flex;
    /* Lebar total adalah (jumlah kartu asli * lebar kartu) * 2 */
    width: calc(380px * 10); 
    /* Nama animasi, durasi, tipe, dan perulangan */
    animation: scroll-right 40s linear infinite;
}

.testimonial-slider:hover {
    /* Jeda animasi saat kursor mouse di atasnya */
    animation-play-state: paused;
}

.testimonial-card {
    flex-shrink: 0;
    width: 350px; /* Lebar setiap kartu testimoni */
    margin: 0 15px; /* Jarak antar kartu */
    background-color: var(--grey-color);
    padding: 2rem;
    border-radius: 8px;
    border-top: 5px solid var(--primary-color);
    text-align: center;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.testimonial-quote {
    font-style: italic;
    font-size: 1.1rem;
    flex-grow: 1;
    margin-bottom: 1.5rem;
}

.testimonial-quote::before {
    content: '“';
    font-size: 3rem;
    color: var(--primary-color);
    font-family: serif;
    display: block;
    line-height: 0.5;
}

.testimonial-name {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--light-color);
    margin-bottom: 0.25rem;
}

.testimonial-program {
    font-size: 0.9rem;
    color: #aaa;
}

/* --- Media Queries (Responsif) --- */
@media (max-width: 768px) {
    .nav-menu { position: fixed; left: -100%; top: 60px; flex-direction: column; background-color: var(--dark-color); width: 100%; text-align: center; transition: 0.3s; z-index: 99; }
    .nav-menu.active { left: 0; }
    .nav-item { margin: 1.5rem 0; }
    .hamburger { display: block; z-index: 101;}
    .hamburger.active .bar:nth-child(2) { opacity: 0; }
    .hamburger.active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .hamburger.active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
    .hero-content h1 { font-size: 3rem; }
    h2 { font-size: 2.5rem; }
    .category-section { text-align: center; }
    .category-title { text-align: center; display: inline-block; }
    .program-carousel .program-card { flex: 0 0 280px; }
}


/* --- Animasi Keyframes untuk Scroll --- */
@keyframes scroll-right {
    0% {
        transform: translateX(0);
    }
    100% {
        /* Geser ke kiri sejauh setengah dari lebar total slider */
        /* (jumlah kartu asli * lebar kartu) */
        transform: translateX(calc(-380px * 5));
    }
}