/* ==============================
   0️⃣ Variables & Reset
============================== */
:root {
    --primary-color: #2c7a4b;
    --secondary-color: #66bb6a;
    --accent-color: #007BFF;
    --text-color: #fff;
    --bg-light: #f9f9f9;
    --bg-page: #f4f4f4;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    overflow-x: hidden;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    background: var(--bg-page);
    color: #333;
}

/* ==============================
   FIX GLOBAL MEDIA
============================== */
img, iframe {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ==============================
   LINK GLOBAL (KONTEN)
============================== */
a {
    color: var(--primary-color);
    text-decoration: none;
}

a:hover {
    color: var(--accent-color);
    text-decoration: underline;
}

/* ==============================
   FIX KHUSUS FOOTER (🔥 PENTING)
============================== */
footer a {
    color: #fff;
}

footer a:hover {
    color: var(--secondary-color);
}

/* ==============================
   1️⃣ Container
============================== */
.container {
    width: 90%;
    max-width: 1100px;
    margin: auto;
}

/* ==============================
   2️⃣ Header & Navbar
============================== */
header {
    background: var(--primary-color);
    color: var(--text-color);
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
}

/* ==============================
   Logo + Judul
============================== */
.logo-title {
    display: flex;
    align-items: center;
    gap: 10px;
    max-width: 100%;
}

.logo-title img {
    width: 50px;
    height: 50px;
}

.title-text {
    max-width: 100%;
    overflow-wrap: break-word;
}

.title-text .small-title,
.title-text .main-title {
    font-size: 22px;
    font-weight: bold;
    color: var(--text-color);
    line-height: 1.2;
    display: block;
}

/* ==============================
   Navbar
============================== */
nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
}

nav ul li a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s ease;
}

nav ul li a.active,
nav ul li a:hover {
    color: var(--accent-color);
}

.menu-toggle {
    display: none;
    font-size: 28px;
    cursor: pointer;
    color: var(--text-color);
}

/* ==============================
   Responsive Navbar
============================== */
@media (max-width: 768px) {
    nav ul {
        display: none;
        flex-direction: column;
        background: var(--primary-color);
        position: absolute;
        top: 60px;
        right: 10px;
        width: 200px;
        padding: 10px;
        z-index: 999;
        border-radius: 10px;
    }

    nav ul.active {
        display: flex;
    }

    .menu-toggle {
        display: block;
    }
}

/* ==============================
   3️⃣ Grid Layanan
============================== */
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1.5rem;
    margin-top: 20px;
}

.layanan-card {
    background: var(--bg-light);
    padding: 20px;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.layanan-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.2);
}

/* ==============================
   Kontak Section
============================== */
.kontak {
    padding: 40px 0;
}

.kontak h2 {
    text-align: center;
    margin-bottom: 30px;
}

.kontak .grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

/* 🔥 FIX MOBILE */
@media (max-width: 768px) {
    .kontak .grid {
        grid-template-columns: 1fr;
    }
}

.contact-info, 
.contact-form {
    background: var(--bg-light);
    padding: 20px;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.contact-form form {
    display: flex;
    flex-direction: column;
}

.contact-form input,
.contact-form textarea {
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #ccc;
    font-family: inherit;
}

/* ==============================
   Animasi
============================== */
.animate {
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.8s ease-out;
}

.animate.show {
    opacity: 1;
    transform: translateY(0);
}

/* ==============================
   Footer
============================== */
footer {
    background: var(--primary-color);
    color: var(--text-color);
    text-align: center;
    padding: 20px 0;
    margin-top: 40px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

/* ==============================
   Extra Mobile Fix
============================== */
@media (max-width: 480px) {
    .layanan-card {
        padding: 15px;
    }

    .logo-title img {
        width: 40px;
        height: 40px;
    }

    .title-text .small-title,
    .title-text .main-title {
        font-size: 18px;
    }
}

.map-responsive {
    overflow: hidden;
    /* Maintain a 4:3 aspect ratio */
    padding-bottom: 75%; 
    position: relative;
    height: 0;
}

.map-responsive iframe {
    left: 0;
    top: 0;
    height: 100%;
    width: 100%;
    position: absolute;
}