/* ============================================ */
/*                  GLOBAL SETUP                  */
/* ============================================ */
:root {
    --primary-color: #d11b2a; /* Merah khas Mazda */
    --dark-color: #1a1a1a;
    --grey-color: #f5f5f5;
    --text-color: #333;
    --text-light: #fff;
    --border-color: #e0e0e0;
    --font-family: 'Poppins', sans-serif;
    --navbar-height: 80px;
}

*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--navbar-height);
}

body {
    font-family: var(--font-family);
    font-size: 16px;
    line-height: 1.7;
    color: var(--text-color);
    background-color: #fff;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

a {
    color: var(--primary-color);
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

.content-section {
    padding: 80px 0;
}

.grey-bg {
    background-color: var(--grey-color);
}

.section-title {
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 15px;
    color: var(--dark-color);
}

.section-subtitle {
    text-align: center;
    max-width: 700px;
    margin: 0 auto 50px auto;
    font-size: 1rem;
    color: #666;
}

.cta-button {
    display: inline-block;
    padding: 12px 35px;
    background-color: var(--primary-color);
    color: var(--text-light);
    border-radius: 5px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 2px solid var(--primary-color);
    transition: all 0.3s ease;
    text-align: center;
}

.cta-button:hover {
    background-color: #a9121f;
    border-color: #a9121f;
}

/* ============================================ */
/*           HEADER & NAVIGASI (NAVBAR)           */
/* ============================================ */
.navbar {
    background-color: #fff;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: var(--navbar-height);
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    transition: top 0.3s;
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100%;
}

.logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo img {
    height: 35px;
}

.logo span {
    color: var(--dark-color);
    font-weight: 700;
    font-size: 1.3rem;
}

.nav-menu {
    display: flex;
    gap: 35px;
}

.nav-link {
    color: var(--text-color);
    font-weight: 500;
    position: relative;
    padding: 5px 0;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.nav-link:hover, .nav-link.active {
    color: var(--primary-color);
}

.nav-link:hover::after, .nav-link.active::after {
    width: 100%;
}

.header-cta {
    background-color: var(--primary-color);
    color: var(--text-light);
    padding: 10px 20px;
    border-radius: 5px;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.header-cta:hover {
    background-color: #a9121f;
}

.hamburger-menu {
    display: none;
    font-size: 1.8rem;
    color: var(--dark-color);
    cursor: pointer;
}

/* ============================================ */
/*                 HERO SECTION                 */
/* ============================================ */
/* === PERBAIKAN DI SINI === */
.hero {
    height: 100vh; /* Mengisi tinggi layar penuh */
    min-height: 600px; /* Tinggi minimal agar tidak terlalu pendek di layar lebar */
    display: flex;
    align-items: center; /* Membuat konten di tengah vertikal */
    color: var(--text-light);
    position: relative;
    background-image: url('images/hero-background.jpg');
    background-size: cover;
    background-position: center;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: linear-gradient(90deg, rgba(0,0,0,0.8) 0%, rgba(0,0,0,0.2) 100%);
}

.hero-content {
    position: relative; 
    z-index: 2;
    max-width: 600px;
}

.hero-content h1 {
    font-size: 1.5rem;
    font-weight: 600;
    background-color: var(--primary-color);
    display: inline-block;
    padding: 5px 15px;
    margin-bottom: 15px;
}

.hero-content h2 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.hero-content p {
    font-size: 1rem;
    font-weight: 300;
    margin-bottom: 30px;
    max-width: 500px;
}

/* ============================================ */
/*           WHY CHOOSE US SECTION              */
/* ============================================ */
.why-us-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
    text-align: center;
}

.why-us-card {
    padding: 20px;
}

.why-us-icon {
    font-size: 3.5rem;
    color: var(--primary-color);
    margin-bottom: 20px;
}

.why-us-card h3 {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 10px;
}

/* ============================================ */
/*                 PRODUK SECTION               */
/* ============================================ */
.produk-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.produk-card {
    background-color: #fff;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
}

.produk-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.produk-card:hover img {
    transform: scale(1.05);
}

.produk-info {
    padding: 25px;
    text-align: center;
    border-top: 1px solid var(--border-color);
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.produk-info h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 8px;
}

.produk-info .harga {
    color: #555;
    margin-bottom: 20px;
}

.produk-buttons {
    margin-top: auto;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.produk-btn {
    padding: 10px;
    border-radius: 5px;
    font-weight: 500;
    text-align: center;
    transition: all 0.3s ease;
}

.produk-btn:first-child {
    background-color: var(--dark-color);
    color: var(--text-light);
}
.produk-btn:first-child:hover {
    background-color: #000;
}

.produk-btn.youtube {
    background-color: #ff0000;
    color: var(--text-light);
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
}

.produk-btn.youtube:hover {
    background-color: #cc0000;
}

/* ============================================ */
/*               PRICE LIST SECTION             */
/* ============================================ */
.pricelist-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 30px;
}

.pricelist-model {
    background-color: var(--grey-color);
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
}

.pricelist-model h3 {
    font-size: 1.3rem;
    font-weight: 600;
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
    margin-bottom: 15px;
}

.pricelist-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    font-size: 0.95rem;
}

.pricelist-item:not(:last-child) {
    border-bottom: 1px solid var(--border-color);
}

.pricelist-item .harga-detail {
    font-weight: 600;
    color: var(--primary-color);
}

.terms-conditions {
    margin-top: 50px;
    background-color: var(--grey-color);
    border-left: 5px solid var(--primary-color);
    padding: 20px;
    border-radius: 5px;
}

.terms-conditions h4 {
    margin-bottom: 10px;
}

.terms-conditions ul {
    list-style-position: inside;
    padding-left: 5px;
    font-size: 0.9rem;
    color: #666;
}

/* ============================================ */
/*              PROMO CTA SECTION               */
/* ============================================ */
.promo-cta-section {
    padding: 100px 0;
    text-align: center;
    color: var(--text-light);
    background-image: url('images/promo-background.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    position: relative;
}

.promo-overlay {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-color: rgba(0,0,0,0.7);
}

.promo-cta-content {
    position: relative;
    z-index: 2;
}

.promo-cta-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 20px;
}

.promo-cta-content p {
    max-width: 600px;
    margin: 0 auto 30px auto;
}

.promo-cta-content .cta-button {
    font-size: 1.2rem;
    padding: 15px 40px;
    display: inline-flex;
    align-items: center;
    gap: 10px;
}

/* ============================================ */
/*                  KONTAK SECTION              */
/* ============================================ */
.kontak-wrapper {
    display: grid;
    grid-template-columns: 1fr 1.2fr;
    gap: 50px;
    align-items: flex-start; /* Ubah dari center ke flex-start */
}

.kontak-info h3, .kontak-form h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 20px;
}

.info-item {
    display: flex;
    align-items: flex-start; /* Ubah dari center ke flex-start */
    gap: 20px;
    margin-bottom: 25px;
}

.info-item i {
    font-size: 1.8rem;
    color: var(--primary-color);
    margin-top: 5px; /* Tambah margin agar ikon sejajar dengan teks */
}

.info-item h4 {
    font-size: 1rem;
    margin-bottom: 3px;
    font-weight: 500;
}
.info-item a, .info-item p {
    color: #555;
    font-weight: 500;
}

/* === CSS BARU UNTUK MAPS === */
.map-container {
    margin-top: 15px;
    border-radius: 8px;
    overflow: hidden; /* Penting agar border-radius diterapkan pada iframe */
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.map-container iframe {
    display: block; /* Menghilangkan spasi putih di bawah iframe */
}
/* === AKHIR CSS BARU === */

.kontak-form {
    background-color: var(--grey-color);
    padding: 40px;
    border-radius: 8px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group input, .form-group select {
    width: 100%;
    padding: 15px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-family: var(--font-family);
    font-size: 1rem;
}

.form-group input::placeholder {
    color: #999;
}

.form-group .error-message {
    color: var(--primary-color);
    font-size: 0.8rem;
    display: none;
    margin-top: 5px;
}

.form-group.error input, .form-group.error select {
    border-color: var(--primary-color);
}

.form-group.error .error-message {
    display: block;
}

.full-width {
    width: 100%;
}

/* ============================================ */
/*                    FOOTER                    */
/* ============================================ */
footer {
    background-color: var(--dark-color);
    color: #a0a0a0;
    padding: 25px 0;
    text-align: center;
    font-size: 0.9rem;
}

/* ============================================ */
/*           FLOATING & UTILITY BUTTONS         */
/* ============================================ */
.whatsapp-float {
    position: fixed;
    bottom: 20px;
    right: 20px;
    width: 60px;
    height: 60px;
    background-color: #25d366;
    color: #fff;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 2.5rem;
    box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    z-index: 998;
    transition: transform 0.3s ease;
}
.whatsapp-float:hover {
    transform: scale(1.1);
}

.back-to-top-btn {
    position: fixed;
    bottom: 90px;
    right: 20px;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: none;
    justify-content: center;
    align-items: center;
    font-size: 1.5rem;
    z-index: 998;
    opacity: 0;
    transition: opacity 0.3s, transform 0.3s;
}

.back-to-top-btn.show {
    opacity: 1;
    display: flex;
}

/* ============================================ */
/*             ANIMASI SAAT SCROLL              */
/* ============================================ */
.animate-on-scroll {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}
.animate-on-scroll.is-visible {
    opacity: 1;
    transform: translateY(0);
}

/* ============================================ */
/*              RESPONSIVE DESIGN               */
/* ============================================ */
@media (max-width: 992px) {
    .header-cta { display: none; }
    .nav-menu { display: none; }
    .hamburger-menu { display: block; }

    .nav-menu.active {
        display: flex;
        position: fixed;
        top: var(--navbar-height);
        left: 0;
        width: 100%;
        height: calc(100vh - var(--navbar-height));
        background-color: #fff;
        flex-direction: column;
        align-items: center;
        padding-top: 40px;
        gap: 30px;
    }
    .nav-link { font-size: 1.2rem; }
    .why-us-grid { grid-template-columns: repeat(2, 1fr); }
    .kontak-wrapper { grid-template-columns: 1fr; }
}

@media (max-width: 768px) {
    /* === PERBAIKAN DI SINI JUGA === */
    .hero { 
        text-align: center; /* Teks rata tengah di layar kecil */
    }
    .hero-overlay {
        /* Overlay lebih gelap merata agar teks lebih mudah dibaca di mobile */
        background: rgba(0,0,0,0.7); 
    }
    .hero-content {
        margin: 0 auto; /* Posisikan konten di tengah secara horizontal */
    }
    .hero-content h2 { 
        font-size: 2.2rem; /* Ukuran font disesuaikan untuk mobile */
    }
    
    .section-title, .promo-cta-content h2 { font-size: 2rem; }
    .why-us-grid { grid-template-columns: 1fr; }
    .pricelist-container { grid-template-columns: 1fr; }
    .kontak-form { padding: 25px; }
}

/* ============================================ */
/*            GALERI TESTIMONI SECTION          */
/* ============================================ */
.galeri-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.galeri-item {
    overflow: hidden; 
    border-radius: 8px; 
    position: relative;
    border: 1px solid var(--border-color);
    box-shadow: 0 4px 10px rgba(0,0,0,0.05);
}

.galeri-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    cursor: pointer;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: block; 
}

.galeri-item figure {
    margin: 0;
    padding: 0;
    position: relative;
}

.galeri-item figcaption {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), rgba(0, 0, 0, 0));
    color: white;
    padding: 30px 15px 15px 15px;
    font-size: 0.9rem;
    text-align: center;
    opacity: 0;
    transform: translateY(20px);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.galeri-item:hover figcaption {
    opacity: 1;
    transform: translateY(0);
}

.galeri-item:hover img {
    transform: scale(1.05);
}

/* Lightbox Styling */
.lightbox {
    display: none;
    position: fixed;
    z-index: 2000;
    padding-top: 60px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0, 0, 0, 0.9);
    animation: fadeIn 0.4s;
}

.lightbox-content {
    margin: auto;
    display: block;
    width: 85%;
    max-width: 900px;
    animation: zoomIn 0.4s;
}

.close-lightbox {
    position: absolute;
    top: 15px;
    right: 35px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }
@keyframes zoomIn { from { transform: scale(0.8); } to { transform: scale(1); } }


/* ============================================ */
/*                 ARTIKEL SECTION              */
/* ============================================ */
.artikel-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
}

.artikel-card {
    background-color: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.artikel-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0,0,0,0.08);
}

.artikel-card img {
    width: 100%;
    height: 220px;
    object-fit: cover;
}

.artikel-content {
    padding: 25px;
}

.artikel-content h3 {
    font-size: 1.4rem;
    font-weight: 600;
    margin-bottom: 10px;
}

.artikel-content p {
    color: #555;
    font-size: 0.95rem;
}

/* Penyesuaian responsive untuk artikel dan kontak */
@media (max-width: 768px) {
    .artikel-grid {
        grid-template-columns: 1fr;
    }
}

/* Pastikan seksi kontak juga mendapat background abu-abu jika sebelumnya tidak */
#kontak {
    background-color: var(--grey-color);
}
/* ============================================ */
/*                 TENTANG SAYA                 */
/* ============================================ */
.tentang-grid {
    display: grid;
    grid-template-columns: 1fr 2fr; /* Kolom foto lebih kecil dari kolom teks */
    gap: 50px;
    align-items: center;
}

.tentang-foto img {
    width: 100%;
    max-width: 350px; /* Batasi lebar maksimal foto */
    height: auto;
    border-radius: 10px; /* Membuat sudut foto lebih lembut */
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    display: block;
    margin: 0 auto; /* Tengahkankan foto jika kolom lebih lebar */
}

.tentang-deskripsi h3 {
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 15px;
}

.tentang-deskripsi p {
    margin-bottom: 15px;
    color: #555;
}

.tentang-deskripsi .cta-button {
    margin-top: 20px;
}

/* Penyesuaian untuk layar lebih kecil (tablet & mobile) */
@media (max-width: 992px) {
    .tentang-grid {
        grid-template-columns: 1fr; /* Ubah jadi 1 kolom */
        gap: 30px;
        text-align: center;
    }

    .tentang-deskripsi {
        order: 2; /* Pindahkan teks di bawah foto */
    }

    .tentang-foto {
        order: 1; /* Pindahkan foto di atas teks */
    }
}