:root {
    --primary: #082430;
    --secondary: #57cc99;
    --accent: #ee9e09;
    --dark: #0b4d61;
    --light: #f8f9fa;
    --gray: #6c757d;
    --kuning-desa: #d19a04; /* STANDARISASI WARNA KUNING */
    --shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    --radius: 8px;
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f7fa;
}

h1, h2, h3, h4, h5 {
    font-family: 'Poppins', sans-serif;
    font-weight: 600;
    color: var(--dark);
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header Styles */
header {
    background-color: rgb(226, 217, 217);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.top-bar {
    background-color: var(--dark);
    color: white;
    padding: 8px 0;
    font-size: 0.9rem;
}

.top-bar-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.top-bar-links a {
    color: white;
    text-decoration: none;
    margin-left: 20px;
    transition: var(--transition);
}

.top-bar-links a:hover {
    color: var(--kuning-desa);
}

/* LOGO HEADER YANG SUDAH DIPERBAIKI */
.logo-header {
    display: flex;
    align-items: center;
    padding: 15px 0;
    gap: 20px;
}

.logo-img {
    display: flex;
    align-items: center;
    justify-content: center;
}

.logo-img img {
    height: 70px;
    width: auto;
    object-fit: contain;
    display: block;
}

.logo-text h1 {
    font-size: 1.8rem;
    color: var(--primary);
    line-height: 1.2;
    margin: 0 0 5px 0;
}

.logo-text p {
    color: var(--gray);
    font-size: 0.9rem;
    margin: 0;
}

/* Welcome Banner */
.welcome-banner {
    background-color: var(--kuning-desa);
    padding: 8px 0;
    border-top: 3px solid var(--kuning-desa);
    border-bottom: 3px solid var(--kuning-desa);
}

.welcome-text {
    color: white;
    text-align: center;
    font-size: 1.3rem;
    font-weight: 600;
    letter-spacing: 1px;
}

.welcome-text h2,
.welcome-text h5,
.welcome-text span {
    margin: 0;
    padding: 5px 0;
    color: white;
}

.welcome-text span {
    color: var(--primary);
    font-weight: 700;
}

/* Navigation */
nav {
    background-color: var(--primary);
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-links {
    display: flex;
    list-style: none;
}

.nav-links li {
    position: relative;
}

.nav-links a {
    color: white;
    text-decoration: none;
    padding: 18px 20px;
    display: block;
    transition: var(--transition);
    font-weight: 500;
    border-bottom: 3px solid transparent;
}

.nav-links a:hover {
    background-color: rgba(255, 255, 255, 0.1);
    border-bottom-color: var(--kuning-desa);
}

.dropdown {
    position: absolute;
    background-color: white;
    min-width: 220px;
    box-shadow: var(--shadow);
    border-radius: var(--radius);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    top: 100%;
    left: 0;
    z-index: 100;
}

.dropdown li a {
    color: var(--dark);
    padding: 12px 20px;
    display: flex;
    align-items: center;
    border-bottom: none;
}

.dropdown li a i {
    margin-right: 10px;
    width: 20px;
    text-align: center;
}

.dropdown li a:hover {
    background-color: #f8f9fa;
    color: var(--kuning-desa);
    border-bottom: none;
}

.nav-links li:hover .dropdown {
    opacity: 1;
    visibility: visible;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 10px;
}

/* Swiper Slider Hero */
.hero-slider {
    width: 100%;
    height: 550px;
    position: relative;
}

.swiper {
    width: 100%;
    height: 100%;
}

.swiper-slide {
    position: relative;
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slide-content {
    position: relative;
    z-index: 2;
    text-align: center;
    color: white;
    max-width: 800px;
    padding: 0 20px;
}

.slide-content h2 {
    font-size: 3rem;
    margin-bottom: 20px;
    text-shadow: 2px 2px 5px rgba(0, 0, 0, 0.5);
    animation: fadeInUp 1s ease;
    color: white;
}

.slide-content p {
    font-size: 1.3rem;
    margin-bottom: 30px;
    opacity: 0.9;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
    animation: fadeInUp 1.2s ease;
}

.swiper-slide::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to right, rgba(10, 45, 62, 0.7), rgba(10, 45, 62, 0.4));
}

.swiper-button-next, .swiper-button-prev {
    color: white;
    background-color: rgba(255, 255, 255, 0.2);
    width: 50px;
    height: 50px;
    border-radius: 50%;
    transition: var(--transition);
}

.swiper-button-next:hover, .swiper-button-prev:hover {
    background-color: rgba(255, 255, 255, 0.3);
}

.swiper-button-next:after, .swiper-button-prev:after {
    font-size: 1.5rem;
}

.swiper-pagination-bullet {
    width: 12px;
    height: 12px;
    background-color: white;
    opacity: 0.5;
}

.swiper-pagination-bullet-active {
    opacity: 1;
    background-color: var(--kuning-desa);
}

.cta-button {
    display: inline-block;
    background-color: var(--secondary);
    color: white;
    padding: 14px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    transition: var(--transition);
    border: 2px solid var(--secondary);
    animation: fadeInUp 1.5s ease;
}

.cta-button:hover {
    background-color: transparent;
    color: var(--secondary);
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* Population Stats */
.population-stats {
    background-color: white;
    padding: 50px 0;
    margin-top: -50px;
    position: relative;
    z-index: 5;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    max-width: 1100px;
    margin-left: auto;
    margin-right: auto;
}

.stats-title {
    text-align: center;
    margin-bottom: 30px;
}

.stats-title h3 {
    font-size: 1.8rem;
    color: var(--primary);
    margin-bottom: 10px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.stat-card {
    text-align: center;
    padding: 20px;
    border-radius: var(--radius);
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow);
}

.stat-card.total {
    background-color: rgba(26, 95, 122, 0.1);
    border-top: 5px solid var(--primary);
}

.stat-card.dewasa {
    background-color: rgba(87, 204, 153, 0.1);
    border-top: 5px solid var(--secondary);
}

.stat-card.lansia {
    background-color: rgba(209, 154, 4, 0.1);
    border-top: 5px solid var(--kuning-desa);
}

.stat-card.anak {
    background-color: rgba(108, 117, 125, 0.1);
    border-top: 5px solid var(--gray);
}

.stat-card.bayi {
    background-color: rgba(255, 107, 107, 0.1);
    border-top: 5px solid #ff6b6b;
}

.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--dark);
    margin-bottom: 5px;
}

.stat-label {
    font-size: 1rem;
    color: var(--gray);
    font-weight: 500;
}

/* Sections Common Styles */
section {
    padding: 80px 0;
}

.section-title {
    text-align: center;
    margin-bottom: 50px;
}

.section-title h2 {
    font-size: 2.2rem;
    color: var(--primary);
    position: relative;
    display: inline-block;
    padding-bottom: 15px;
}

.section-title h2::after {
    content: '';
    position: absolute;
    width: 70px;
    height: 4px;
    background-color: var(--kuning-desa);
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    border-radius: 2px;
}

/* Features Section */
.features {
    background-color: white;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.feature-card {
    background-color: white;
    border-radius: var(--radius);
    padding: 30px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-10px);
}

.feature-icon {
    width: 70px;
    height: 70px;
    background-color: rgba(87, 204, 153, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: var(--secondary);
    font-size: 1.8rem;
}

.feature-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
}

/* Institutions Section */
.institutions {
    background-color: #f8f9fa;
}

.institutions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.institution-card {
    background-color: white;
    border-radius: var(--radius);
    padding: 30px;
    text-align: center;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.institution-card:hover {
    transform: translateY(-10px);
}

.institution-icon {
    width: 80px;
    height: 80px;
    background-color: rgba(26, 95, 122, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: var(--primary);
    font-size: 2rem;
}

.institution-card h3 {
    font-size: 1.4rem;
    margin-bottom: 15px;
    color: var(--dark);
}

.institution-card.bumdes .institution-icon {
    background-color: rgba(87, 204, 153, 0.1);
    color: var(--secondary);
}

.institution-card.karang-taruna .institution-icon {
    background-color: rgba(209, 154, 4, 0.1);
    color: var(--kuning-desa);
}

/* Tourism Section */
.tourism {
    background-color: white;
}

.tourism-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.tourism-card {
    background-color: white;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.tourism-card:hover {
    transform: translateY(-10px);
}

.tourism-img {
    height: 200px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.tourism-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background-color: var(--kuning-desa);
    color: var(--primary);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.tourism-content {
    padding: 25px;
}

.tourism-content h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
    color: var(--dark);
}

.tourism-rating {
    color: #ffc107;
    margin-bottom: 10px;
}

.tourism-location {
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
}

.tourism-location i {
    margin-right: 8px;
}

/* Services Section */
.services {
    background-color: white;
}

.services-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.service-card {
    background-color: white;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.service-img {
    height: 200px;
    background-color: var(--primary);
    background-size: cover;
    background-position: center;
}

.service-content {
    padding: 25px;
}

.service-content h3 {
    font-size: 1.3rem;
    margin-bottom: 10px;
}

/* News Section */
.news-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.news-card {
    background-color: white;
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.news-card:hover {
    transform: translateY(-5px);
}

.news-img {
    height: 200px;
    background-color: var(--gray);
    background-size: cover;
    background-position: center;
}

.news-content {
    padding: 25px;
}

.news-date {
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 10px;
}

.news-content h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
}

.read-more {
    color: var(--primary);
    text-decoration: none;
    font-weight: 500;
    display: inline-block;
    margin-top: 10px;
}

.read-more:hover {
    color: var(--kuning-desa);
}

/* Contact Section */
.contact {
    background-color: var(--light);
}

.contact-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
}

.contact-info h3 {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.contact-detail {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.contact-detail i {
    width: 40px;
    height: 40px;
    background-color: rgba(209, 154, 4, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-right: 15px;
    color: var(--kuning-desa);
}

/* Footer */
footer {
    background-color: var(--dark);
    color: white;
    padding: 60px 0 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-logo .logo-img {
    margin-bottom: 15px;
}

.footer-logo .logo-img img {
    height: 60px;
    width: auto;
}

.footer-logo h3 {
    color: white;
    font-size: 1.5rem;
    margin-bottom: 10px;
}

.footer-links h4, .footer-contact h4 {
    color: white;
    font-size: 1.2rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.footer-links h4::after, .footer-contact h4::after {
    content: '';
    position: absolute;
    width: 40px;
    height: 3px;
    background-color: var(--kuning-desa);
    bottom: 0;
    left: 0;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 10px;
}

.footer-links a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: var(--transition);
}

.footer-links a:hover {
    color: var(--kuning-desa);
    padding-left: 5px;
}

.copyright {
    text-align: center;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes countUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ============ RESPONSIVE STYLES YANG DIPERBAIKI ============ */
@media (max-width: 1200px) {
    .population-stats {
        margin: 0 20px;
        margin-top: -30px;
    }
}

@media (max-width: 992px) {
    .slide-content h2 {
        font-size: 2.5rem;
    }
    
    .section-title h2 {
        font-size: 1.8rem;
    }
    
    .population-stats {
        padding: 40px 0;
    }
}

@media (max-width: 768px) {
    /* Mobile Navigation */
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background-color: var(--primary);
        flex-direction: column;
        box-shadow: var(--shadow);
        z-index: 999;
    }

    .nav-links.active {
        display: flex;
    }

    .mobile-menu-btn {
        display: block;
    }

    /* Dropdown Mobile - DIPERBAIKI */
    .dropdown {
        position: static;
        opacity: 1;
        visibility: visible;
        box-shadow: none;
        background-color: rgba(0, 0, 0, 0.15);
        border-radius: 0;
        display: none;
        width: 100%;
    }

    .dropdown.active {
        display: block;
    }

    .nav-links li:hover .dropdown {
        display: none; /* MATIKAN HOVER DI MOBILE */
    }

    .dropdown li a {
        color: white;
        padding-left: 40px;
    }

    .dropdown li a:hover {
        background-color: rgba(255, 255, 255, 0.1);
        color: var(--kuning-desa);
    }

    /* Chevron rotation */
    .fa-chevron-down {
        transition: transform 0.3s ease;
    }

    .fa-chevron-down.rotated {
        transform: rotate(180deg);
    }

    /* Hero Slider */
    .hero-slider {
        height: 500px;
    }

    .slide-content h2 {
        font-size: 2rem;
    }

    .slide-content p {
        font-size: 1.1rem;
    }

    /* Stats Grid */
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    section {
        padding: 60px 0;
    }
    
    /* Logo Header */
    .logo-header {
        gap: 15px;
    }
    
    .logo-text h1 {
        font-size: 1.5rem;
    }
    
    .logo-img img {
        height: 60px;
    }
}

@media (max-width: 576px) {
    .top-bar-content {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    .top-bar-links a {
        margin: 0 10px;
    }

    .logo-header {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    .logo-text h1 {
        font-size: 1.3rem;
    }

    .hero-slider {
        height: 450px;
    }

    .slide-content h2 {
        font-size: 1.6rem;
    }
    
    .slide-content p {
        font-size: 1rem;
    }

    .cta-button {
        padding: 12px 25px;
        font-size: 1rem;
    }

    .stats-grid {
        grid-template-columns: 1fr;
    }

    .stat-number {
        font-size: 2rem;
    }

    .feature-card, .institution-card, .tourism-card, .service-card, .news-card {
        padding: 20px;
    }
    
    .section-title h2 {
        font-size: 1.5rem;
    }
    
    .welcome-text {
        font-size: 1.1rem;
    }
}