/* --- Import Google Fonts --- */
@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;500;600;700&family=Lato:wght@400;700&display=swap');

/* --- Variabel Warna yang Disempurnakan --- */
:root {
    --primary-color: #388E3C; /* Forest Green */
    --secondary-color: #7CB342; /* Light Lime Green */
    --accent-color: #AEEA00;  /* Bright Lime */
    --bg-color: #F1F8E9;     /* Very Light Green */
    --text-color-primary: #212121; /* Dark Gray */
    --text-color-secondary: #757575; /* Medium Gray */
    --header-bg: #FFFFFF;
    --shadow-color: rgba(0, 0, 0, 0.05);
    --border-color: #E0E0E0;
    --bg-highlight: #FFFFFF;
    --bg-harmony: #DCEDC8; /* Pastel Green */
    --bg-tradition: #FFF9C4; /* Light Yellow */
    --bg-adventure: #E1F5FE; /* Light Blue */
    --font-heading: 'Poppins', sans-serif;
    --font-body: 'Lato', sans-serif;
}

/* --- Reset & Pengaturan Dasar Body --- */
* { margin: 0; padding: 0; box-sizing: border-box; }

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-body);
    color: var(--text-color-primary);
    line-height: 1.7;
    background-color: var(--bg-color);
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* --- Header dengan Navigasi --- */
.site-header {
    background-color: var(--header-bg);
    box-shadow: 0 1px 8px var(--shadow-color);
    position: sticky;
    top: 0;
    z-index: 1000;
}
.header-content { display: flex; justify-content: space-between; align-items: center; padding: 1.5rem 0; flex-wrap: wrap; }
.logo-container a, .logo-text a { text-decoration: none; color: inherit; }
.logo-container { display: flex; align-items: center; }
.logo-img { height: 55px; margin-right: 55px; transform: scale(2.5);}
.logo-text h1 { font-family: var(--font-heading); color: var(--primary-color); font-size: 2rem; font-weight: 600; margin: 0; letter-spacing: 0.5px; }
.logo-text .slogan { font-size: 0.9rem; margin: 0; color: var(--text-color-secondary); }

/* --- Navigasi Styling --- */
.main-nav ul {
    list-style: none;
    display: flex;
    gap: 2rem;
}

.main-nav a {
    text-decoration: none;
    color: var(--secondary-color);
    font-family: var(--font-heading);
    font-weight: 600;
    padding-bottom: 5px;
    position: relative;
    transition: color 0.3s ease;
}

.main-nav a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.main-nav a:hover, .main-nav a.active {
    color: var(--primary-color);
}

.main-nav a:hover::after, .main-nav a.active::after {
    width: 100%;
}


/* --- CSS Image Slider (Versi JavaScript) --- */
.slider-container {
    width: 100%;
    height: 70vh;
    overflow: hidden;
    position: relative; /* Penting untuk posisi tombol */
}

.slider {
    display: flex;
    height: 100%;
    /* Transisi ini akan membuat pergerakan slider menjadi halus */
    transition: transform 0.5s ease-in-out;
}

.slide {
    min-width: 100%; /* Setiap slide akan selebar container */
    height: 100%;
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
}

.slide::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(0, 0, 0, 0.4);
    z-index: 1;
}

.slide-caption {
    position: relative;
    z-index: 2;
    color: #FFFFFF;
    padding: 2rem;
    max-width: 800px;
}

.slide-caption h2 {
    font-family: var(--font-heading);
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}

.slide-caption p {
    font-size: 1.2rem;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
}

/* Styling untuk Tombol Prev/Next */
.slider-btn {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background-color: rgba(255, 255, 255, 0.5);
    border: none;
    color: #212121;
    font-size: 2rem;
    font-weight: bold;
    cursor: pointer;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: background-color 0.3s ease;
}

.slider-btn:hover {
    background-color: rgba(255, 255, 255, 0.8);
}

.prev-btn {
    left: 20px;
}

.next-btn {
    right: 20px;
}

/* Styling untuk Navigasi Titik (Dots) */
.slider-dots {
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10;
    display: flex;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease;
}

.dot.active, .dot:hover {
    background-color: #FFFFFF;
    transform: scale(1.2);
}

/* --- Bagian Sorotan Utama --- */
.highlight-section { padding: 5rem 0; background-color: var(--bg-highlight); text-align: center; }
.section-title { font-family: var(--font-heading); font-size: 2.8rem; color: var(--primary-color); font-weight: 600; margin-bottom: 3.5rem; letter-spacing: 1px; text-align: center;}
.highlight-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr)); gap: 2.5rem; }
.highlight-card { background-color: #fff; padding: 2.5rem 2rem; border-radius: 12px; box-shadow: 0 6px 18px rgba(0, 0, 0, 0.08); transition: transform 0.3s ease-in-out, box-shadow 0.3s ease-in-out; border: 1px solid var(--border-color); }
.highlight-card:hover { transform: translateY(-8px); box-shadow: 0 12px 24px rgba(0, 0, 0, 0.12); }
.highlight-card .icon { font-size: 3.5rem; margin-bottom: 1.2rem; color: var(--accent-color); }
.highlight-card h4 { font-family: var(--font-heading); font-size: 1.3rem; color: var(--primary-color); font-weight: 600; margin-bottom: 0.75rem; }
.highlight-card p { color: var(--text-color-secondary); font-size: 1rem; line-height: 1.6; }

/* --- Styling Konten Utama --- */
.content-section { padding: 5rem 0; }
.bg-harmony { background-color: var(--bg-harmony); }
.bg-tradition { background-color: var(--bg-tradition); }
.bg-adventure { background-color: var(--bg-adventure); }
.content-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 4rem; align-items: center; }
.text-content h3 { font-family: var(--font-heading); font-size: 2.6rem; color: var(--primary-color); font-weight: 600; margin-bottom: 1.2rem; }
.text-content p { font-size: 1.1rem; color: var(--text-color-primary); line-height: 1.8; }
.image-content img { width: 100%; height: auto; border-radius: 12px; box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1); transition: box-shadow 0.3s ease-in-out; }
.image-content img:hover { box-shadow: 0 12px 28px rgba(0, 0, 0, 0.15); }
.content-grid.reverse { direction: rtl; }
.content-grid.reverse > * { direction: ltr; }

/* --- Footer --- */
.site-footer { text-align: center; padding: 3rem 0; background-color: #37474F; color: #ECEFF1; font-size: 0.9rem; }

/* --- Responsiveness --- */
@media (max-width: 1024px) {
    .slide-caption h2 { font-size: 2.5rem; }
    .slide-caption p { font-size: 1.1rem; }
    .content-grid { gap: 3rem; }
}
@media (max-width: 960px) {
    .header-content { flex-direction: column; align-items: flex-start; gap: 1.5rem; }
    .main-nav ul { margin-top: 1rem; gap: 2rem; }
    .content-grid { grid-template-columns: 1fr; gap: 2.5rem; }
    .content-grid.reverse { direction: ltr; }
    .text-content { text-align: left; order: 2; }
    .image-content { order: 1; }
    .section-title { font-size: 2.4rem; }
}
@media (max-width: 600px) {
    .header-content { flex-direction: column; align-items: flex-start; gap: 1rem; padding: 1.5rem 2rem; }
    .main-nav { width: 100%; }
    .main-nav ul { flex-direction: column; align-items: flex-start; gap: 1rem; }
    .slider-container { height: 60vh; }
    .slide-caption h2 { font-size: 1.8rem; }
    .slide-caption p { font-size: 1rem; }
    .text-content h3 { font-size: 2rem; }
}

/* === CSS UNTUK HALAMAN PROFIL === */

/* Styling Hero Banner */
.hero-profil {
    position: relative;
    height: 50vh;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
}

/* Overlay gelap agar teks terbaca */
.hero-profil::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.45);
}

.hero-caption {
    position: relative;
    z-index: 2;
}

.hero-caption h1 {
    font-size: 3.5rem;
    font-weight: 700;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.5);
    margin: 0;
}

.hero-caption p {
    font-size: 1.2rem;
    margin-top: 0.5rem;
    opacity: 0.9;
}

/* Styling untuk daftar Misi */
.text-content ul {
    list-style: none;
    padding-left: 0;
}

.text-content ul li {
    padding-left: 1.5rem;
    position: relative;
    margin-bottom: 0.8rem;
}

.text-content ul li::before {
    content: '✔'; /* Ganti dengan ikon lain jika suka */
    color: var(--primary-color);
    position: absolute;
    left: 0;
}

/* Styling Bagian Demografi */
.demografi-section {
    padding: 5rem 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.stat-card {
    background-color: #fff;
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.07);
    border-top: 5px solid var(--secondary-color);
}

.stat-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

.stat-label {
    font-size: 1rem;
    color: var(--text-color-secondary);
    margin-top: 0.5rem;
}

/* Styling Bagian Aparatur Desa */
.pemerintahan-section {
    padding: 5rem 0;
}

.team-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.team-member {
    text-align: center;
    background: #fff;
    padding: 2rem;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.team-member:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 25px rgba(0,0,0,0.1);
}

.team-member img {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    object-fit: cover;
    border: 5px solid #fff;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    margin-bottom: 1rem;
}

.team-member h4 {
    font-size: 1.3rem;
    margin: 0;
    color: var(--primary-color);
}

.team-member p {
    margin-top: 0.25rem;
    color: var(--text-color-secondary);
}

/* Responsiveness tambahan */
@media(max-width: 768px) {
    .hero-caption h1 {
        font-size: 2.5rem;
    }
}

/* style.css (Tambahkan kode ini di bawah) */

/* === CSS UNTUK HALAMAN PROGRAM DESA === */

/* Styling Tombol dan Konten Tab */
.program-tabs-section {
    padding: 5rem 0;
    background-color: var(--bg-light);
}

.tab-buttons {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 3rem;
    flex-wrap: wrap;
}

.tab-btn {
    padding: 0.8rem 1.8rem;
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-secondary);
    background-color: #fff;
    border: 1px solid var(--border-color);
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-btn:hover {
    background-color: #E8F5E9;
    color: var(--primary-color);
}

.tab-btn.active {
    background-color: var(--primary-color);
    color: #fff;
    border-color: var(--primary-color);
    box-shadow: 0 4px 15px rgba(46, 125, 50, 0.3);
}

.tab-content {
    display: none; /* Semua konten disembunyikan secara default */
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.tab-content.active {
    display: grid; /* Konten yang aktif akan ditampilkan sebagai grid */
}

/* Styling Kartu Program */
.program-card {
    background-color: #fff;
    border-radius: 12px;
    padding: 2rem;
    box-shadow: 0 4px 20px rgba(0,0,0,0.06);
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.program-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.program-card h4 {
    font-family: var(--font-heading);
    font-size: 1.3rem;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
}

.program-card p {
    color: var(--text-secondary);
    flex-grow: 1; /* Mendorong status ke bawah */
    margin-bottom: 1.5rem;
}

.status {
    display: inline-block;
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    align-self: flex-start; /* Posisi di kiri bawah */
}

.status.berjalan {
    color: #1565C0;
    background-color: #E3F2FD;
}

.status.terlaksana {
    color: #2E7D32;
    background-color: #E8F5E9;
}

.status.direncanakan {
    color: #F57F17;
    background-color: #FFFDE7;
}

/* Styling Bagian Call-to-Action (CTA) */
.cta-section {
    padding: 5rem 0;
    background: var(--primary-color);
    text-align: center;
    color: #fff;
}

.cta-section h2 {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.cta-section p {
    max-width: 600px;
    margin: 0 auto 2rem;
    opacity: 0.9;
}

.cta-button {
    display: inline-block;
    padding: 1rem 2.5rem;
    background-color: var(--accent-color);
    color: var(--text-primary);
    border-radius: 30px;
    text-decoration: none;
    font-weight: 700;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.cta-button:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

/* === CSS UNTUK HALAMAN TRADISI === */

/* Styling Hero Banner Halaman Tradisi */
.hero-tradisi {
    position: relative;
    height: 90vh;
    background-image: url('/img/banner-tradisi.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    text-align: center;
    overflow: hidden;
}

.hero-tradisi::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.7); /* Overlay hitam transparan */
    z-index: 1;
}

.hero-tradisi > * {
    position: relative;
    z-index: 2; /* Agar konten tetap tampil di atas overlay */
}


/* Styling untuk background video (opsional) */
.hero-video-bg {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    min-width: 100%;
    min-height: 100%;
    width: auto;
    height: auto;
    z-index: 0;
}

.hero-tradisi::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0,0,0,0.7), rgba(0,0,0,0.3));
    z-index: 1; /* Di atas video, di bawah teks */
}

.hero-tradisi .hero-caption {
    z-index: 2; /* Teks paling depan */
}

/* Styling Section Pengenalan */
.intro-tradisi {
    text-align: center;
    padding: 5rem 0;
    background-color: var(--bg-light);
}

.intro-tradisi .section-title {
    margin-bottom: 1rem;
}

.intro-text {
    font-size: 1.1rem;
    max-width: 800px;
    margin: 0 auto;
    color: var(--text-secondary);
    font-style: italic;
}

/* Warna latar belakang khusus untuk section tradisi */
.bg-light-yellow {
    background: linear-gradient(180deg, #FFFDE7, #fff);
}


.galeri-tradisi-section {
    padding: 5rem 0;
    background-color: var(--bg-light);
}

.galeri-grid {
    display: grid;
    /* Membuat kolom yang responsif, minimal 250px */
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 3rem;
}

.galeri-item {
    display: block;
    /* KUNCI 1: Memberi tinggi yang sama untuk semua kotak galeri */
    height: 250px; 
    border-radius: 12px;
    /* KUNCI 2: Menyembunyikan bagian gambar yang membesar saat hover */
    overflow: hidden; 
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.galeri-item:hover {
    transform: scale(1.05); /* Sedikit membesar saat disentuh kursor */
    box-shadow: 0 12px 30px rgba(0,0,0,0.15);
}

.galeri-item img {
    width: 100%;
    height: 100%;
    /* KUNCI 3: Membuat gambar mengisi kotak tanpa distorsi (akan ter-crop jika perlu) */
    object-fit: cover; 
    transition: transform 0.3s ease;
}

.galeri-item:hover img {
    transform: scale(1.1); /* Efek zoom pada gambar di dalamnya */
}

/* === CSS UNTUK HALAMAN KONTAK === */

.kontak-section {
    padding: 5rem 0;
}

.kontak-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 4rem;
    background-color: #fff;
    padding: 3rem;
    border-radius: 12px;
    box-shadow: 0 8px 30px rgba(0,0,0,0.08);
}

.info-kontak h3, .form-kontak h3 {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

.info-item {
    display: flex;
    align-items: flex-start;
    gap: 1rem;
    margin-bottom: 1.2rem;
    color: var(--text-secondary);
}

.info-item i {
    font-size: 1.2rem;
    color: var(--secondary-color);
    margin-top: 4px;
}

.social-media {
    margin-top: 2rem;
    display: flex;
    gap: 1rem;
}

.social-media a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: #F1F8E9;
    color: var(--primary-color);
    border-radius: 50%;
    text-decoration: none;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.social-media a:hover {
    background-color: var(--primary-color);
    color: #fff;
    transform: translateY(-4px);
}

/* Styling Formulir */
.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input, .form-group textarea {
    width: 100%;
    padding: 0.8rem 1rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

.form-group input:focus, .form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(46, 125, 50, 0.15);
}

.submit-btn {
    padding: 0.9rem 2.5rem;
    font-family: var(--font-heading);
    font-size: 1rem;
    font-weight: 700;
    color: #fff;
    background-color: var(--primary-color);
    border: none;
    border-radius: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.submit-btn:hover {
    background-color: #1B5E20; /* Warna hijau lebih gelap */
    transform: translateY(-3px);
    box-shadow: 0 8px 15px rgba(46, 125, 50, 0.2);
}


/* Styling Bagian FAQ */
.faq-section {
    padding: 5rem 0;
    background: var(--bg-light);
}

.faq-container {
    max-width: 800px;
    margin: 3rem auto 0;
}

.faq-item {
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
}

.faq-question {
    width: 100%;
    background: none;
    border: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    text-align: left;
    padding: 1rem 0.5rem;
    font-family: var(--font-heading);
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--text-primary);
    cursor: pointer;
}

.faq-question i {
    transition: transform 0.3s ease;
    color: var(--primary-color);
}

.faq-item.active .faq-question i {
    transform: rotate(180deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-hight 0.5s ease-out;
}

.faq-answer p {
    padding: 0 0.5rem 1rem;
    color: var(--text-secondary);
}

.faq-item.active .faq-answer {
    max-height: 200px; /* Sesuaikan jika jawaban lebih panjang */
    transition: max-height 0.5s ease-in;
}

/* Responsiveness */
@media (max-width: 960px) {
    .kontak-wrapper {
        grid-template-columns: 1fr;
    }
}