/* --- CSS Variables & Global Styles --- */
:root {
    --primary-color: #5D8A31; /* Hijau Pramuka */
    --secondary-color: #C4A57B; /* Coklat Kayu */
    --accent-color: #FFD700;   /* Kuning Kecoklatan/Emas */
    --dark-color: #333;
    --light-color: #f4f4f4;
    --white-color: #fff;
    --font-family: 'Poppins', sans-serif;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    line-height: 1.6;
    color: var(--dark-color);
    background-color: var(--white-color);
}

.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
}

.section-padding {
    padding: 80px 0;
}

.bg-light {
    background-color: var(--light-color);
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header h2 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.section-header p {
    font-size: 1.1rem;
    color: #666;
}

/* --- Buttons --- */
.btn {
    display: inline-block;
    padding: 12px 28px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white-color);
}

.btn-primary:hover {
    background-color: #4a6f27;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(93, 138, 49, 0.4);
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background-color: var(--primary-color);
    color: var(--white-color);
}

/* --- Header --- */
.main-header {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 15px 0;
    position: fixed;
    width: 100%;
    top: 0;
    left: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    transition: all 0.3s ease;
}

.main-header .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    height: 50px;
}

.main-nav ul {
    list-style: none;
    display: flex;
}

.main-nav ul li {
    margin-left: 25px;
}

.main-nav ul li a {
    text-decoration: none;
    color: var(--dark-color);
    font-weight: 500;
    position: relative;
    transition: color 0.3s ease;
}

.main-nav ul li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: -5px;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.main-nav ul li a:hover {
    color: var(--primary-color);
}

.main-nav ul li a:hover::after {
    width: 100%;
}

.menu-toggle {
    display: none;
    flex-direction: column;
    background: none;
    border: none;
    cursor: pointer;
}

.menu-toggle span {
    width: 25px;
    height: 3px;
    background-color: var(--dark-color);
    margin: 3px 0;
    transition: 0.3s;
}

/* --- Hero Section --- */
.hero {
    height: 100vh;
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), url('../assets/images/hero-bg.jpg') no-repeat center center/cover;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    color: var(--white-color);
    position: relative;
}

.hero-content h1 {
    font-size: 3.5rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.hero-content .slogan {
    font-size: 1.5rem;
    font-weight: 400;
    margin-bottom: 30px;
    font-style: italic;
}

.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
}

.scroll-indicator span {
    display: block;
    width: 30px;
    height: 50px;
    border: 2px solid var(--white-color);
    border-radius: 25px;
    position: relative;
}

.scroll-indicator span::before {
    content: '';
    position: absolute;
    top: 10px;
    left: 50%;
    width: 6px;
    height: 6px;
    margin-left: -3px;
    background-color: var(--white-color);
    border-radius: 50%;
    animation: scrolling 2s infinite;
}

@keyframes scrolling {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(20px); opacity: 0; }
}

/* --- Sambutan Section --- */
.sambutan-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
    align-items: center;
}

.sambutan-image img {
    width: 100%;
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.sambutan-text h2 {
    font-size: 2rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.sambutan-text p {
    margin-bottom: 15px;
}

/* --- Activity Grid --- */
.activity-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 30px;
}

.activity-card {
    background: var(--white-color);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.activity-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.15);
}

.activity-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.activity-card .card-body {
    padding: 25px;
}

.activity-card .card-body h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    color: var(--primary-color);
}

/* --- Info Cepat --- */
.info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    text-align: center;
}

.info-item h3 {
    font-size: 3rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.info-item p {
    font-size: 1.1rem;
    color: #666;
    text-transform: uppercase;
}

/* --- Social Media Grid --- */
.social-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.social-card {
    background: var(--white-color);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    text-align: center;
}

.social-card h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
    color: var(--dark-color);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.social-card h3 img {
    width: 30px;
    height: 30px;
}

/* --- Kontak Grid --- */
.kontak-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 50px;
}

.kontak-info h3 {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.kontak-info p {
    margin-bottom: 15px;
}

.kontak-map {
    border-radius: 10px;
    overflow: hidden;
    height: 400px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
}

.kontak-map iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

/* --- Footer --- */
.main-footer {
    background-color: var(--dark-color);
    color: var(--light-color);
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo img {
    height: 60px;
    margin-bottom: 10px;
}

.footer-logo p {
    font-size: 1.2rem;
    font-weight: 600;
}

.footer-links h4, .footer-contact h4 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--accent-color);
}

.footer-links ul {
    list-style: none;
}

.footer-links ul li {
    margin-bottom: 10px;
}

.footer-links ul li a {
    color: var(--light-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links ul li a:hover {
    color: var(--primary-color);
}

.social-media a {
    margin-right: 15px;
}

.social-media img {
    width: 30px;
    height: 30px;
    filter: brightness(0) invert(1);
    transition: transform 0.3s ease;
}

.social-media a:hover img {
    transform: scale(1.2);
}

.footer-bottom {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid #444;
    font-size: 0.9rem;
}

/* --- Responsive Design --- */
@media (max-width: 768px) {
    .main-nav {
        display: none;
    }

    .menu-toggle {
        display: flex;
    }

    .hero-content h1 {
        font-size: 2.5rem;
    }

    .sambutan-grid,
    .social-grid,
    .kontak-grid {
        grid-template-columns: 1fr;
    }

    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .social-media {
        margin-top: 15px;
    }
}


/* --- Gaya untuk Tombol Cepat --- */
.tombol-cepat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.tombol-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px;
    background: var(--white-color);
    border-radius: 10px;
    text-decoration: none;
    color: var(--dark-color);
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transition: all 0.3s ease;
}

.tombol-item:hover {
    transform: translateY(-5px);
    background-color: var(--primary-color);
    color: var(--white-color);
}

.tombol-item .icon {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.tombol-item span:last-child {
    font-weight: 600;
}

/* --- Gaya untuk Halaman Konten (profil.php) --- */
.page-content {
    padding-top: 100px; /* Beri jarak dari header yang fixed */
}

.content-section {
    margin-bottom: 50px;
}

.content-section h2 {
    color: var(--primary-color);
    border-bottom: 2px solid var(--accent-color);
    padding-bottom: 10px;
    margin-bottom: 20px;
}

.content-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
    margin-bottom: 50px;
}

.content-card {
    background: var(--light-color);
    padding: 25px;
    border-radius: 10px;
    border-left: 5px solid var(--primary-color);
}

.content-card h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

.content-card .jargon {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--secondary-color);
}

.content-card ul {
    list-style-type: '✔ ';
    padding-left: 20px;
}

.org-table-wrapper {
    overflow-x: auto; /* Agar tabel bisa di-scroll di layar kecil */
}

.org-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    font-size: 0.9rem;
}

.org-table th, .org-table td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: left;
    vertical-align: top;
}

.org-table th {
    background-color: var(--primary-color);
    color: var(--white-color);
}

.org-table tbody tr:nth-child(even) {
    background-color: #f9f9f9;
}


/* --- Gaya Baru untuk Struktur Organisasi (Card Layout) --- */

.org-structure-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
    margin-top: 40px;
}

.org-card {
    background: var(--white-color);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.07);
    transition: all 0.3s ease;
    border-top: 5px solid var(--primary-color);
}

.org-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.12);
}

.org-card .card-header {
    background-color: var(--primary-color);
    color: var(--white-color);
    padding: 15px 20px;
}

.org-card .card-header h3 {
    margin: 0;
    font-size: 1.1rem;
    font-weight: 600;
}

.org-card .card-body {
    padding: 20px;
}

.org-card .card-body ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.org-card .card-body ul li {
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid #f0f0f0;
    font-size: 0.95rem;
    line-height: 1.6;
}

.org-card .card-body ul li:last-child {
    margin-bottom: 0;
    padding-bottom: 0;
    border-bottom: none;
}

.org-card .card-body strong {
    color: var(--secondary-color); /* Warna coklat untuk jabatan */
    display: block;
    margin-bottom: 5px;
}

/* Warna Khusus untuk Kartu Pimpinan dan DKR */
.org-card.card-pimpinan {
    border-top-color: var(--secondary-color);
}
.org-card.card-pimpinan .card-header {
    background-color: var(--secondary-color);
}

.org-card.card-dkr {
    border-top-color: var(--accent-color); /* Warna emas */
}
.org-card.card-dkr .card-header {
    background-color: var(--accent-color);
}

/* Responsif untuk layar lebih kecil */
@media (max-width: 768px) {
    .org-structure-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    .org-card .card-body ul li {
        font-size: 0.9rem;
    }
}


/* --- Gaya untuk Halaman Berita --- */
.berita-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.berita-card {
    background: var(--white-color);
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0,0,0,0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.berita-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.12);
}

.berita-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.berita-content {
    padding: 25px;
}

.berita-content h2 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    line-height: 1.4;
}

.berita-content h2 a {
    color: var(--dark-color);
    text-decoration: none;
}

.berita-content h2 a:hover {
    color: var(--primary-color);
}

.berita-meta {
    font-size: 0.9rem;
    color: #777;
}

.berita-meta .tanggal {
    margin-left: 15px;
}

/* --- Gaya untuk Halaman Detail Berita --- */
.berita-detail {
    max-width: 800px;
    margin: 0 auto;
}

.berita-detail-header {
    text-align: center;
    margin-bottom: 30px;
    border-bottom: 1px solid #eee;
    padding-bottom: 20px;
}

.berita-detail-header h1 {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 10px;
}

.berita-detail-image {
    margin-bottom: 30px;
}

.berita-detail-image img {
    width: 100%;
    border-radius: 10px;
}

.berita-detail-body {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #444;
    text-align: justify;
}


/* --- Gaya untuk Program Kerja --- */
.program-list .program-item {
    background: #f9f9f9;
    border-left: 5px solid var(--primary-color);
    padding: 20px;
    margin-bottom: 20px;
    border-radius: 5px;
}
.program-item h3 { color: var(--primary-color); }
.program-details { margin-top: 15px; }
.program-details p { margin-bottom: 5px; }

/* --- Gaya untuk Agenda --- */
.agenda-table-wrapper, .org-table-wrapper { overflow-x: auto; }
.agenda-table, .org-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: var(--white-color);
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}
.agenda-table th, .org-table th {
    background: var(--primary-color);
    color: white;
    padding: 12px;
    text-align: left;
}
.agenda-table td, .org-table td {
    padding: 12px;
    border-bottom: 1px solid #eee;
}
.agenda-table tbody tr:hover { background-color: #f5f5f5; }

/* --- Gaya untuk Unduhan --- */
.unduhan-kategori {
    margin-bottom: 40px;
}
.unduhan-kategori h2 {
    color: var(--secondary-color);
    border-bottom: 2px solid var(--secondary-color);
    padding-bottom: 5px;
    margin-bottom: 20px;
}
.unduhan-list {
    list-style: none;
    padding: 0;
}
.unduhan-list li {
    margin-bottom: 10px;
}
.unduhan-link {
    display: block;
    padding: 15px;
    background: var(--white-color);
    text-decoration: none;
    color: var(--dark-color);
    border: 1px solid #ddd;
    border-radius: 5px;
    transition: all 0.2s ease;
}
.unduhan-link:hover {
    background-color: var(--primary-color);
    color: var(--white-color);
    border-color: var(--primary-color);
    transform: translateX(5px);
}
.unduhan-judul {
    font-weight: 600;
    display: block;
}
.unduhan-deskripsi {
    font-size: 0.9rem;
    color: #666;
    margin-top: 5px;
}
.unduhan-link:hover .unduhan-deskripsi { color: #f0f0f0; }


/* --- Gaya untuk Data Kepramukaan (Tab) --- */
.data-tabs .tab-nav {
    display: flex;
    border-bottom: 2px solid #eee;
    margin-bottom: 20px;
    overflow-x: auto; /* Untuk mobile */
}
.tab-btn {
    background: none;
    border: none;
    padding: 15px 25px;
    font-size: 1rem;
    font-weight: 600;
    color: #777;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
}
.tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
}
.tab-btn:hover {
    color: var(--primary-color);
}
.tab-content {
    display: none;
}
.tab-content.active {
    display: block;
    animation: fadeIn 0.5s;
}
.data-table-wrapper { overflow-x: auto; }
.data-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0,0,0,0.05);
}
.data-table th, .data-table td {
    padding: 12px 15px;
    text-align: left;
    border-bottom: 1px solid #f0f0f0;
}
.data-table th {
    background-color: var(--primary-color);
    color: white;
    font-weight: 600;
}


/* --- Gaya untuk Layanan --- */
.layanan-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 30px;
}
.layanan-card {
    background: var(--white-color);
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 20px rgba(0,0,0,0.08);
    text-align: center;
}
.layanan-card .card-icon {
    font-size: 3rem;
    margin-bottom: 20px;
}
.layanan-card h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}
.layanan-form {
    text-align: left;
    margin-top: 25px;
}
.layanan-form input,
.layanan-form select,
.layanan-form textarea {
    width: 100%;
    padding: 12px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: inherit;
}
.alert {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 5px;
    color: white;
}
.alert-success { background-color: #2ecc71; }
.alert-error { background-color: #e74c3c; }