* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background-color: #f4f7f6;
    color: #333;
}


.logo {
    font-size: 24px;
    font-weight: 600;
}

.logo span { color: #27ae60; }


.nav-links li { margin-left: 25px; }

.nav-links a {
    text-decoration: none;
    color: #333;
    font-weight: 400;
    transition: 0.3s;
}

.nav-links a:hover { color: #27ae60; }

.menu-toggle .bar {
    width: 25px;
    height: 3px;
    background-color: #333;
    border-radius: 3px;
    transition: 0.3s;
}

/* --- 2. NAVBAR MOBILE (Hanya untuk HP) --- */
@media (max-width: 768px) {
     
    .nav-links li {
        margin: 15px 0; /* Jarak antar menu vertikal */
    }

    /* Munculkan menu saat tombol diklik (JS akan menambah class .active) */
    .nav-links.active {
        left: 0;
    }

    /* Animasi silang (X) untuk hamburger */
    .menu-toggle.is-active .bar:nth-child(2) { opacity: 0; }
    .menu-toggle.is-active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .menu-toggle.is-active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
}

/* Hero Section */
.hero {
    height: 100vh; /* Mengurangi tinggi menjadi 80% layar */
    min-height: 400px; /* Di laptop, gambar tidak akan kurang dari 600px */
    background: linear-gradient(rgba(0,0,0,0.5), rgba(0,0,0,0.5)), 
                url('https://images.unsplash.com/photo-1512917774080-9991f1c4c750?auto=format&fit=crop&w=1200&q=80');
    background-size: cover;
    background-position: center;
    background-attachment: fixed; /* Opsional: Efek Parallax biar lebih keren */
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    color: white;
}

.hero-content h1 { font-size: 3rem; margin-bottom: 20px; }

.btn-main {
    display: inline-block;
    padding: 12px 30px;
    background: #27ae60;
    color: white;
    text-decoration: none;
    border-radius: 5px;
    margin-top: 20px;
}

/* Unit Grid */
.units { padding: 50px 8%; }

.units h2 { text-align: center; margin-bottom: 40px; }

.grid-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.card {
    background: #fff;
    border-radius: 10px;
    overflow: hidden;
    transition: 0.3s;
    box-shadow: 0 4px 15px rgba(0,0,0,0.05);
}

.card:hover { transform: translateY(-10px); }

.card-img { height: 200px; background-size: cover; background-position: center; }

.card-info { padding: 20px; }

.price {
    display: block;
    color: #27ae60;
    font-weight: 600;
    font-size: 1.2rem;
    margin: 10px 0;
}

.btn-detail {
    width: 100%;
    padding: 10px;
    border: 1px solid #27ae60;
    background: transparent;
    color: #27ae60;
    cursor: pointer;
    border-radius: 5px;
}

.btn-detail:hover { background: #27ae60; color: white; }

/* Styling Halaman Detail */
.container-detail {
    padding: 40px 8%;
    max-width: 1200px;
    margin: auto;
}

.detail-wrapper {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
}

.main-image {
    width: 100%;
    height: 450px;
    background-size: cover;
    background-position: center;
    border-radius: 15px;
    margin-bottom: 30px;
}

.description h2 { margin-bottom: 15px; margin-top: 20px; }
.description p { line-height: 1.6; color: #666; margin-bottom: 20px; }
.description ul { margin-left: 20px; color: #555; }
.description li { margin-bottom: 8px; }

/* Sticky Box di Sisi Kanan */
.sticky-box {
    background: white;
    padding: 25px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    position: sticky;
    top: 100px;
}

.badge {
    background: #e8f5e9;
    color: #2e7d32;
    padding: 5px 12px;
    border-radius: 50px;
    font-size: 0.8rem;
    font-weight: 600;
}

.location { color: #888; font-size: 0.9rem; margin-bottom: 15px; }

.specs-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    margin: 20px 0;
    gap: 10px;
    font-size: 0.85rem;
}

.price-large {
    font-size: 1.8rem;
    font-weight: 600;
    color: #27ae60;
    margin-bottom: 25px;
}

.contact-card {
    background: #f9f9f9;
    padding: 15px;
    border-radius: 10px;
}

.contact-card input {
    width: 100%;
    padding: 12px;
    margin-bottom: 10px;
    border: 1px solid #ddd;
    border-radius: 5px;
}

/* Responsive untuk HP */
@media (max-width: 768px) {
    .detail-wrapper {
        grid-template-columns: 1fr;
    }
    .main-image { height: 300px; }
}

/* Search Bar Hero */
.search-container {
    background: white;
    padding: 15px;
    border-radius: 10px;
    display: flex;
    max-width: 700px;
    margin: 30px auto 0;
    gap: 10px;
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

.search-container input, .search-container select {
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 5px;
    flex: 1;
}

.btn-search {
    background: #27ae60;
    color: white;
    border: none;
    padding: 0 30px;
    border-radius: 5px;
    cursor: pointer;
}

/* Facilities Advanced Section */
.facilities-advanced {
    padding: 80px 8%;
    background-color: #ffffff;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.sub-title {
    color: #27ae60;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.9rem;
}

.facility-main-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 60px;
}

.fac-card {
    padding: 35px;
    background: #fdfdfd;
    border: 1px solid #f0f0f0;
    border-radius: 20px;
    transition: all 0.4s ease;
}

.fac-card:hover {
    background: #ffffff;
    box-shadow: 0 15px 35px rgba(0,0,0,0.07);
    border-color: #27ae60;
    transform: translateY(-5px);
}

.fac-icon {
    font-size: 2.5rem;
    margin-bottom: 20px;
}

.fac-card h3 {
    margin-bottom: 12px;
    color: #2c3e50;
    font-size: 1.25rem;
}

.fac-card p {
    color: #7f8c8d;
    font-size: 0.95rem;
    line-height: 1.6;
}

/* Location Highlights */
.location-highlights {
    background: #2c3e50;
    color: white;
    padding: 40px;
    border-radius: 25px;
    text-align: center;
}

.location-highlights h3 {
    margin-bottom: 30px;
    font-size: 1.8rem;
}

.loc-item {
    border-right: 1px solid rgba(255,255,255,0.1);
}

.loc-item:last-child {
    border-right: none;
}

/* Styling Ikon Lokasi */
.loc-icon {
    font-size: 2rem;
    margin-bottom: 10px;
    background: rgba(255, 255, 255, 0.1); /* Background lingkaran transparan */
    width: 60px;
    height: 60px;
    line-height: 60px;
    border-radius: 50%;
    margin: 0 auto 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: 0.3s;
}

/* Efek hover pada item lokasi */
.loc-item:hover .loc-icon {
    background: #27ae60;
    transform: scale(1.1);
}

.loc-item {
    border-right: 1px solid rgba(255,255,255,0.1);
    padding: 10px;
}

/* Perbaikan Grid agar muat 6 item */
.location-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 30px;
}

.time {
    display: block;
    font-size: 1.5rem;
    font-weight: 600;
    color: #27ae60;
}

.loc-item p {
    font-size: 0.9rem;
    color: #bdc3c7;
    margin-top: 5px;
}

/* Responsive Fix */
@media (max-width: 768px) {
    .loc-item {
        border-right: none;
        border-bottom: 1px solid rgba(255,255,255,0.1);
        padding-bottom: 15px;
    }
}

/* Testimonials */
.testimonials { padding: 60px 8%; background: #f4f7f6; }
.testi-container { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; }
.testi-card { background: white; padding: 25px; border-radius: 10px; max-width: 400px; box-shadow: 0 5px 15px rgba(0,0,0,0.05); }
.testi-card h4 { margin-top: 15px; color: #27ae60; }

/* Footer */
.main-footer { background: #2c3e50; color: white; padding: 60px 8% 20px; margin-top: 50px; }
.footer-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 40px; }
.footer-about .logo { color: white; margin-bottom: 20px; }
.footer-links ul { list-style: none; }
.footer-links a { color: #bdc3c7; text-decoration: none; line-height: 2; }
.footer-links a:hover { color: white; }
.footer-bottom { text-align: center; margin-top: 50px; padding-top: 20px; border-top: 1px solid #3e4f5f; font-size: 0.9rem; }

.floating-wa {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25d366;
    color: white;
    padding: 10px 20px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
    z-index: 9999;
    transition: 0.3s;
}

.floating-wa img { width: 30px; height: 30px; }
.floating-wa:hover { transform: scale(1.05); background-color: #128c7e; }

/* Sembunyikan teks di HP agar hanya muncul ikon saja */
@media (max-width: 480px) {
    .wa-text { display: none; }
    .floating-wa { padding: 15px; border-radius: 50%; }
}

/* About Header */
.about-header {
    background: linear-gradient(rgba(39, 174, 96, 0.9), rgba(44, 62, 80, 0.9)), 
                url('https://images.unsplash.com/photo-1497366216548-37526070297c?auto=format&fit=crop&w=1200&q=80');
    background-size: cover;
    padding: 100px 8%;
    color: white;
    text-align: center;
}

/* Container Flex */
.about-content { padding: 80px 8%; background: #fff; }
.container-flex { display: flex; align-items: center; gap: 50px; flex-wrap: wrap; }
.about-text { flex: 1; min-width: 300px; }
.about-image { flex: 1; min-width: 300px; }
.about-image img { width: 100%; border-radius: 20px; box-shadow: 20px 20px 0 #27ae60; }

.stats-grid {
    display: flex;
    gap: 30px;
    margin-top: 40px;
}

.stat-box h3 { font-size: 2rem; color: #27ae60; }

/* Thumbnail Gallery Proyek */
.project-gallery { padding: 80px 8%; background: #f9f9f9; }

.thumbnail-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.thumb-card {
    position: relative;
    border-radius: 15px;
    overflow: hidden;
    height: 250px;
}

.thumb-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: 0.5s;
}

.thumb-overlay {
    position: absolute;
    bottom: -100%;
    left: 0;
    width: 100%;
    background: linear-gradient(transparent, rgba(0,0,0,0.8));
    color: white;
    padding: 20px;
    transition: 0.4s;
}

.thumb-card:hover .thumb-overlay { bottom: 0; }
.thumb-card:hover img { transform: scale(1.1); }

/* About Preview di Index */
.about-preview {
    padding: 100px 8%;
    background: #fff;
}

.about-img-stack {
    position: relative;
    flex: 1;
    min-width: 300px;
}

.img-main {
    width: 90%;
    border-radius: 20px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.1);
}

.experience-badge {
    position: absolute;
    bottom: -20px;
    right: 20px;
    background: #27ae60;
    color: white;
    padding: 20px 30px;
    border-radius: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
    box-shadow: 0 10px 20px rgba(39, 174, 96, 0.3);
}

.experience-badge .num {
    font-size: 2.5rem;
    font-weight: 700;
    border-right: 2px solid rgba(255,255,255,0.3);
    padding-right: 15px;
}

.about-text-preview {
    flex: 1;
    min-width: 300px;
}

.mini-features {
    margin: 25px 0;
}

.mini-item {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
    font-weight: 500;
}

.mini-item .check {
    color: #27ae60;
    font-weight: bold;
}

.btn-outline {
    display: inline-block;
    padding: 12px 25px;
    border: 2px solid #27ae60;
    color: #27ae60;
    text-decoration: none;
    border-radius: 5px;
    font-weight: 600;
    transition: 0.3s;
}

.btn-outline:hover {
    background: #27ae60;
    color: white;
}

/* Contact Section */
.contact-section {
    padding: 80px 8%;
    background: #fdfdfd;
}

.contact-wrapper {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr;
    gap: 40px;
    align-items: start;
}

.info-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.info-item {
    display: flex;
    gap: 15px;
    background: white;
    padding: 20px;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.05);
}

.info-item .icon { font-size: 1.5rem; }
.info-item h4 { font-size: 1rem; color: #2c3e50; }
.info-item p { font-size: 0.85rem; color: #7f8c8d; }

/* Form Styling */
.main-contact-form {
    background: white;
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

.main-contact-form h3 { margin-bottom: 20px; }

.form-group {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

.main-contact-form input, 
.main-contact-form textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #eee;
    border-radius: 8px;
    background: #f9f9f9;
    font-size: 0.9rem;
    outline: none;
    display: block; /* Pastikan input berderet ke bawah dengan rapi */
    margin-bottom: 15px; /* Tambahkan jarak antar input jika belum ada */
}

.main-contact-form textarea { margin-bottom: 15px; }

.main-contact-form input:focus, 
.main-contact-form textarea:focus {
    border-color: #27ae60;
    background: #fff;
}

/* Map Styling */
.contact-map {
    height: 100%;
    min-height: 400px;
}

/* Responsive */
@media (max-width: 992px) {
    .contact-wrapper {
        grid-template-columns: 1fr;
    }
    .contact-map {
        height: 350px;
    }
}

/* Penyesuaian Lebar agar sejajar dengan .units */
.about-preview {
    padding: 80px 8%; /* SAMA DENGAN .units */
    background: #fff;
}

.about-item-wrapper {
    margin-bottom: 100px;
}

/* Flexbox Layout */
.container-flex {
    display: flex;
    align-items: center;
    gap: 60px;
}

.about-img-stack, .about-text-preview {
    flex: 1;
}

/* OTOMATIS SELANG-SELING */
/* Baris Genap (2, 4, 6): Gambar Kanan, Teks Kiri */
.about-item-wrapper:nth-child(even) .container-flex {
    flex-direction: row-reverse;
}

/* Styling Detail Teks */
.about-text-preview h2 {
    font-size: 2.2rem;
    margin: 15px 0;
    color: #2c3e50;
    line-height: 1.2;
}

.about-text-preview p {
    color: #64748b;
    line-height: 1.8;
    margin-bottom: 25px;
}

/* Badge Pengalaman agar lebih proporsional */
.experience-badge {
    position: absolute;
    bottom: 20px;
    right: 0;
    background: #27ae60;
    color: white;
    padding: 15px 25px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    box-shadow: 0 10px 20px rgba(39, 174, 96, 0.2);
}

.experience-badge .num {
    font-size: 2rem;
    font-weight: 700;
}

.badge-text {
    font-size: 0.8rem;
    line-height: 1;
    text-transform: uppercase;
}

/* Responsive Mobile */
@media (max-width: 992px) {
    .container-flex {
        flex-direction: column !important;
        gap: 40px;
    }
    
    .about-img-stack, .about-text-preview {
        width: 100%;
    }
    
    .img-main {
        width: 100%; /* Full width di HP */
    }
}

/* Container Logo di Navbar */
.logo {
    display: flex;
    align-items: center;
    max-height: 50px; /* Batasi tinggi maksimal seluruh container */
}

.logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
    gap: 10px;
}

/* KUNCI PERBAIKAN: Berikan limit pada img */
.logo-link img {
    height: 40px !important; /* Paksa tinggi ke 40px */
    width: auto;             /* Lebar mengikuti secara otomatis */
    max-width: 150px;        /* Jangan sampai terlalu lebar ke samping */
    object-fit: contain;     /* Pastikan gambar tidak gepeng */
    display: block;
}

.logo-text {
    font-size: 1.2rem;       /* Sesuaikan ukuran font */
    font-weight: 700;
    color: #333;
    white-space: nowrap;     /* Nama perumahan tidak turun ke bawah */
}

.logo-text span {
    color: #27ae60;
}

/* Responsif Mobile */
@media (max-width: 480px) {
    .logo-text {
        font-size: 18px; /* Teks lebih kecil di HP */
    }
    .logo-link img {
        height: 35px;
    }
}

/* --- PERBAIKAN RESPONSIVE GLOBAL --- */

/* 1. Navbar Mobile: Sembunyikan link jika layar kecil atau buat scrollable */
@media (max-width: 768px) {
   
    /* Tampilkan hanya tombol konfirmasi di mobile */
    .nav-links li:nth-last-child(2) {
        display: block;
    }
}

/* 2. Hero Section Mobile */
@media (max-width: 768px) {
    .hero {
        height: auto;
        padding: 120px 20px 60px;
        text-align: center;
    }
    .hero h1 { font-size: 1.8rem; }
    
    /* Search Bar di Hero agar tidak gepeng */
    .search-container {
        flex-direction: column;
        background: transparent;
        box-shadow: none;
    }
    .search-container select, 
    .search-container input, 
    .search-container .btn-search {
        width: 100%;
        margin: 5px 0;
        border-radius: 8px !important;
        padding: 15px;
    }
}

/* 3. Grid Unit (Sangat Penting) */
.grid-container {
    display: grid;
    /* Otomatis 1 kolom di HP, 2 di Tablet, 3 di Desktop */
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    padding: 20px 0;
}

/* 4. Fasilitas & Lokasi di HP */
@media (max-width: 600px) {
    .facility-main-grid, .location-grid {
        grid-template-columns: 1fr !important; /* Paksa jadi 1 kolom */
    }
    .about-section, .units, .facilities-advanced, .contact-section {
        padding: 40px 5% !important; /* Kecilkan padding samping di HP */
    }
}

/* 5. Footer Responsive */
.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
}

/* 6. Floating WA agar tidak menutupi konten penting */
@media (max-width: 480px) {
    .floating-wa .wa-text { display: none; } /* Sembunyikan teks, sisa ikon saja */
    .floating-wa { bottom: 20px; right: 20px; padding: 10px; }
}

/* --- RESPONSIVE OPTIMIZATION --- */
@media (max-width: 992px) {
    .about-section, .units, .facilities-advanced, .contact-section {
        padding: 40px 5% !important; 
    }
    
    .container-flex {
        flex-direction: column !important;
        gap: 30px;
    }

    .contact-wrapper {
        grid-template-columns: 1fr !important;
    }
}

@media (max-width: 768px) {
   
    .hero-content h1 {
        font-size: 1.8rem !important;
    }

    .search-container {
        flex-direction: column;
        width: 100%;
    }

    .search-container select, 
    .search-container input, 
    .search-container .btn-search {
        width: 100%;
        margin-bottom: 10px;
        border-radius: 8px !important;
    }

    .grid-container {
        grid-template-columns: 1fr !important;
    }
}

/* Styling Tombol Hamburger (Default Sembunyi) */

.menu-toggle .bar {
    width: 25px;
    height: 3px;
    background-color: #2c3e50;
    border-radius: 3px;
    transition: 0.3s;
}

/* RESPONSIVE: Saat di Layar HP */
@media (max-width: 768px) {

    /* Agar logo tidak terlalu besar di HP */
    .logo img {
        height: 40px;
    }
}
        
    /* Saat menu aktif (diklik) */
    .nav-links.active {
        left: 0; /* Muncul ke tengah */
    }

    /* Animasi Hamburger jadi tanda (X) saat aktif */
    .menu-toggle.is-active .bar:nth-child(2) { opacity: 0; }
    .menu-toggle.is-active .bar:nth-child(1) { transform: translateY(8px) rotate(45deg); }
    .menu-toggle.is-active .bar:nth-child(3) { transform: translateY(-8px) rotate(-45deg); }
}

/* --- 1. TAMPILAN DESKTOP (Default) --- */

/* --- 2. TAMPILAN MOBILE (Hanya aktif di layar < 768px) --- */
@media (max-width: 768px) {
    
    /* Saat menu dibuka di HP */
    .nav-links.active {
        display: flex; /* Munculkan kembali saat tombol diklik */
        left: 0;
    }
}

/* KODE INI BERDIRI SENDIRI - TARUH DI PALING BAWAH FILE */

/* --- RESET KHUSUS NAVBAR --- */
.navbar, .nav-links, .menu-toggle {
    all: revert; /* Mengembalikan ke pengaturan awal agar tidak ada warisan kode lama */
    display: flex;
}

.navbar {
    justify-content: space-between !important;
    align-items: center;
    padding: 0 8%;
    background-color: #ffffff;
    height: 80px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

/* LAPTOP: Menu Berjejer Samping */
@media screen and (min-width: 769px) {
    .nav-links {
        list-style: none;
        display: flex !important; 
        gap: 20px;
    }
    .nav-links a {
        color: #333 !important; /* Pastikan hitam agar tidak "hilang" karena putih */
        text-decoration: none;
        font-weight: 500;
    }
    .menu-toggle {
        display: none !important;
    }
}

/* HP: Menu Sembunyi & Vertikal */
@media screen and (max-width: 768px) {
    .menu-toggle {
        display: flex !important;
        flex-direction: column;
        gap: 5px;
        cursor: pointer;
    }
    
    .menu-toggle .bar {
        width: 25px; 
        height: 3px; 
        background: #333;
    }

    .nav-links {
        display: none; /* Sembunyi default di HP */
        flex-direction: column !important;
        
        /* --- PERBAIKAN POSISI TENGAH --- */
        align-items: center !important;    /* Menengahkan konten secara horizontal */
        text-align: center !important;      /* Memastikan teks di dalam li juga tengah */
        
        position: absolute;
        top: 80px; 
        left: 0; 
        width: 100%;
        background: white;
        padding: 30px 0; /* Memberi ruang atas bawah lebih lega */
        box-shadow: 0 10px 15px rgba(0,0,0,0.1); /* Tambah bayangan agar menu tidak "tembus" ke konten bawah */
    }

    .nav-links.active {
        display: flex !important;
    }

    .nav-links li {
        margin-left: 0 !important; /* Hapus margin kiri bawaan desktop */
        margin-bottom: 20px;       /* Beri jarak antar baris menu */
        width: 100%;               /* Biar area klik selebar layar */
    }

    .nav-links li:last-child {
        margin-bottom: 0;
    }
}