/* ================= CSS DASAR & VARIABEL ================= */
:root {
    --primary-color: #1A365D; 
    --secondary-color: #D4AF37; 
    --bg-light: #F7FAFC;
    --text-dark: #2D3748;
    --text-muted: #4A5568;
    --white: #FFFFFF;
}

* {
    -webkit-box-sizing: border-box;
    -moz-box-sizing: border-box;
    box-sizing: border-box;
}

html {
    -webkit-text-size-adjust: 100%;
    -ms-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    margin: 0;
    padding: 0;
    color: var(--text-dark);
    background-color: white;
    line-height: 1.6;
    scroll-behavior: smooth;
}

img {
    max-width: 100%;
    height: auto;
    border: 0;
}

a,
button,
input,
textarea,
select {
    font: inherit;
}

.container { max-width: 1100px; margin: 0 auto; padding: 0 20px; }
.section-padding { padding: 80px 0; }
.bg-light { background-color: var(--bg-light); }
.text-center { text-align: center; }

.section-title {
    color: var(--primary-color);
    font-size: 2.3rem;
    margin-top: 0;
    margin-bottom: 40px;
}

/* ================= NAVIGASI ================= */
header {
    background-color: #11243E;
    box-shadow: 0 2px 5px rgba(0,0,0,0.25);
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1100px;
    margin: 0 auto;
    padding: 15px 20px;
    box-sizing: border-box;
}

.logo {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    font-size: 1.8rem;
    font-weight: 800;
    color: white;
    text-decoration: none;
    letter-spacing: 1px;
}

.logo-image {
    width: 42px;
    height: 42px;
    object-fit: contain;
    border-radius: 0;
    background: transparent;
    padding: 0;
    display: inline-block;
}

.logo-text {
    display: inline-block;
    color: var(--white);
}

.logo span { color: var(--white); }
nav a { margin-left: 20px; text-decoration: none; color: #A0AEC0; font-weight: 600; transition: color 0.3s ease; }
nav a:hover { color: var(--secondary-color); }

/* ================= HERO ================= */
.hero {
    position: relative;
    --slide-image: url('IMG/Residential_1.jpg');
    --slide-image-next: none;
    min-height: 430px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: #1f2937;
    color: white;
    text-align: center;
    padding: 130px 20px;
    box-sizing: border-box;
    isolation: isolate;
}

.hero::before {
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(rgba(0, 0, 0, 0.38), rgba(0, 0, 0, 0.38)), var(--slide-image);
    background-position: center;
    background-size: cover;
    content: '';
    opacity: 1;
    transition: opacity 700ms ease-in-out, transform 900ms ease-in-out;
}

.hero::after {
    position: absolute;
    inset: 0;
    z-index: -2;
    background: linear-gradient(rgba(0, 0, 0, 0.38), rgba(0, 0, 0, 0.38)), var(--slide-image-next);
    background-position: center;
    background-size: cover;
    content: '';
    opacity: 0;
    transition: opacity 700ms ease-in-out, transform 900ms ease-in-out;
}

.hero.is-changing::before { opacity: 0; transform: scale(1.04); }
.hero.is-changing::after { opacity: 1; }

.hero-content { position: relative; z-index: 1; max-width: 850px; }

.hero h1 { font-size: 3.5rem; margin-bottom: 15px; margin-top: 0; }
.hero p { font-size: 1.2rem; max-width: 750px; margin: 0 auto 30px auto; color: #E2E8F0; }
.hero-buttons { display: flex; justify-content: center; gap: 15px; flex-wrap: wrap; }

.slide-control { position: absolute; top: 50%; z-index: 2; width: 42px; height: 42px; transform: translateY(-50%); border: 1px solid rgba(255,255,255,0.7); border-radius: 50%; background: rgba(0,0,0,0.25); color: white; font-size: 1.4rem; cursor: pointer; }
.slide-control:hover { background: var(--secondary-color); }
.slide-prev { left: 24px; }
.slide-next { right: 24px; }
.slide-dots { position: absolute; bottom: 24px; left: 50%; z-index: 2; display: flex; gap: 10px; transform: translateX(-50%); }
.slide-dot { width: 11px; height: 11px; padding: 0; border: 1px solid white; border-radius: 50%; background: transparent; cursor: pointer; }
.slide-dot.active { background: var(--secondary-color); border-color: var(--secondary-color); }

.btn { padding: 15px 30px; text-decoration: none; border-radius: 5px; font-size: 1.1rem; font-weight: bold; cursor: pointer; transition: 0.3s ease; display: inline-block; }
.btn-primary { background-color: var(--secondary-color); color: white; border: 2px solid var(--secondary-color); }
.btn-primary:hover { background-color: #B8860B; border-color: #B8860B; }
.btn-outline { background-color: transparent; color: white; border: 2px solid white; }
.btn-outline:hover { background-color: white; color: var(--primary-color); }

/* ================= TENTANG ================= */
.about .lead-text { font-size: 1.2rem; font-weight: bold; color: var(--primary-color); margin-bottom: 20px; }

/* ================= VISI & MISI ================= */
.visi-misi-container { margin-top: 50px; display: flex; flex-direction: column; gap: 40px; }
.visi-box {
    text-align: center; background: var(--primary-color); color: white; padding: 35px 20px;
    border-radius: 8px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); border-bottom: 5px solid var(--secondary-color);
}
.visi-box h3 { margin-top: 0; color: var(--secondary-color); font-size: 1.5rem; margin-bottom: 15px; }
.visi-box p { font-size: 1.25rem; font-style: italic; margin: 0; max-width: 800px; margin: 0 auto; color: #E2E8F0; }

.misi-box h3 { text-align: center; color: var(--primary-color); font-size: 1.6rem; margin-top: 0; margin-bottom: 25px; }
.misi-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 20px; }
.misi-item { background: white; padding: 20px; border-radius: 8px; border-left: 4px solid var(--secondary-color); box-shadow: 0 2px 5px rgba(0,0,0,0.05); }
.misi-item h4 { color: var(--primary-color); margin: 0 0 10px 0; font-size: 1.05rem; }
.misi-item p { margin: 0; font-size: 0.95rem; color: var(--text-muted); }

/* ================= LAYANAN ================= */
.service-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 25px; }
.service-card { display: flex; flex-direction: column; background: white; padding: 30px 20px; border-radius: 8px; box-shadow: 0 4px 10px rgba(0,0,0,0.05); border-top: 4px solid var(--secondary-color); }
.service-card:last-child { grid-column: 2; }
.service-card h2 { color: var(--primary-color); font-size: 1.1rem; line-height: 1.35; margin: 0 0 15px; }
.service-card p { font-size: 0.95rem; color: var(--text-muted); margin: 0; }
.custom-list { margin: 0; padding-left: 20px; font-size: 0.95rem; color: var(--text-muted); }
.custom-list li { margin-bottom: 8px; }

/* ================= GALERI PROYEK / PORTOFOLIO ================= */
.portfolio-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 25px; max-width: 850px; margin: 0 auto; }
.portfolio-item { position: relative; overflow: hidden; width: 100%; padding: 0; border: 0; border-radius: 8px; box-shadow: 0 4px 10px rgba(0,0,0,0.1); height: 260px; background-color: #CBD5E0; cursor: pointer; text-align: left; }
.portfolio-item img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform 0.5s ease; }
.portfolio-overlay {
    position: absolute; bottom: 0; left: 0; right: 0;
    background: linear-gradient(to top, rgba(26, 54, 93, 0.9), transparent);
    color: white; padding: 20px; opacity: 0; transition: opacity 0.3s ease;
    display: flex; flex-direction: column; justify-content: flex-end; height: 100%;
}
.portfolio-item:hover img { transform: scale(1.1); }
.portfolio-item:hover .portfolio-overlay { opacity: 1; }
.portfolio-overlay strong { margin: 0 0 5px 0; font-size: 1.2rem; color: white; }
.portfolio-overlay span { margin: 0; font-size: 0.9rem; color: #E2E8F0; }
.portfolio-overlay small { margin-top: 12px; color: var(--secondary-color); font-weight: bold; }
.modal-open { overflow: hidden; }
.gallery-modal { position: fixed; inset: 0; z-index: 1000; display: none; align-items: center; justify-content: center; padding: 20px; background: rgba(0,0,0,0.78); }
.gallery-modal.open { display: flex; }
.gallery-dialog { position: relative; width: min(900px, 100%); padding: 28px; border-radius: 8px; background: white; box-sizing: border-box; }
.gallery-dialog h2 { margin: 0 45px 18px 0; color: var(--primary-color); }
.gallery-close { position: absolute; top: 12px; right: 16px; border: 0; background: transparent; color: var(--text-muted); font-size: 2rem; line-height: 1; cursor: pointer; }
.gallery-viewer { position: relative; display: flex; align-items: center; justify-content: center; min-height: 320px; background: #1f2937; }
.gallery-viewer > img { width: 100%; height: min(55vh, 500px); object-fit: contain; }
.gallery-arrow { position: absolute; z-index: 1; width: 40px; height: 40px; border: 1px solid white; border-radius: 50%; background: rgba(0,0,0,0.45); color: white; font-size: 1.3rem; cursor: pointer; }
.gallery-arrow:hover { background: var(--secondary-color); }
.gallery-prev { left: 14px; }
.gallery-next { right: 14px; }
.gallery-thumbnails { display: grid; grid-template-columns: repeat(5, 1fr); gap: 8px; margin-top: 12px; }
.gallery-thumbnails button { height: 70px; padding: 0; border: 2px solid transparent; background: none; cursor: pointer; overflow: hidden; }
.gallery-thumbnails button.active { border-color: var(--secondary-color); }
.gallery-thumbnails img { width: 100%; height: 100%; object-fit: cover; }

/* ================= ALASAN MEMILIH KAMI ================= */
.reasons-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; }
.reason-item { background: white; padding: 20px; border-radius: 8px; border: 1px solid #E2E8F0; }
.reason-item h4 { color: var(--primary-color); margin: 0 0 10px 0; font-size: 1.1rem; }
.reason-item p { margin: 0; font-size: 0.95rem; color: var(--text-muted); }

/* ================= PROSES KERJA ================= */
.process-steps { display: flex; flex-direction: column; gap: 15px; max-width: 600px; margin: 0 auto; }
.step { background: white; padding: 15px 20px; border-radius: 5px; box-shadow: 0 2px 5px rgba(0,0,0,0.05); text-align: left; font-weight: 600; display: flex; align-items: center; border: 1px solid #E2E8F0; }
.step span { background: var(--secondary-color); color: white; width: 30px; height: 30px; display: inline-flex; justify-content: center; align-items: center; border-radius: 50%; margin-right: 15px; font-weight: bold; }

/* ================= FAQ ================= */
.faq-container { max-width: 700px; margin: 0 auto; }
.faq-item { background: white; margin-bottom: 15px; border-radius: 5px; border: 1px solid #E2E8F0; }
.faq-item summary { font-weight: bold; padding: 15px 20px; cursor: pointer; color: var(--primary-color); outline: none; list-style: none; display: flex; justify-content: space-between; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; color: var(--secondary-color); font-size: 1.2rem; }
.faq-item[open] summary::after { content: '-'; }
.faq-item p { padding: 0 20px 20px 20px; margin: 0; color: var(--text-muted); }

/* ================= CTA FOOTER ================= */
.cta-footer { background-color: var(--primary-color); color: white; padding: 80px 20px; }
.cta-footer h2 { font-size: 2.5rem; margin-top: 0; margin-bottom: 20px; }
.cta-footer p { font-size: 1.1rem; color: #E2E8F0; max-width: 700px; margin: 0 auto 35px auto; }

.download-profile {
    margin-top: 20px;
}

/* ================= FOOTER ================= */
.site-footer {
    background-color: var(--primary-color);
    color: var(--white);
    padding: 30px 20px;
    border-top: 1px solid rgba(212, 175, 55, 0.2);
}

.site-footer .footer-content {
    max-width: 1100px;
    margin: 0 auto;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 16px 30px;
    text-align: center;
}

.site-footer .footer-brand {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    min-width: 240px;
}

.site-footer .footer-brand img {
    width: 42px;
    height: 42px;
    object-fit: contain;
    border-radius: 50%;
    background: var(--white);
    padding: 4px;
}

.site-footer .footer-brand span {
    color: var(--white);
    font-weight: 700;
    font-size: 0.95rem;
    white-space: nowrap;
}

.site-footer .footer-social {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.site-footer .social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--white);
    text-decoration: none;
    font-weight: 700;
    font-size: 0.96rem;
    border: 1px solid rgba(255,255,255,0.35);
    padding: 8px 14px;
    border-radius: 999px;
    transition: transform 0.2s ease, border-color 0.2s ease, color 0.2s ease;
    min-width: 260px;
}

.site-footer .social-link:hover {
    color: var(--white);
    border-color: var(--white);
    transform: translateY(-2px);
}

.site-footer .social-icon {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 1.8;
    display: inline-block;
    vertical-align: middle;
}

.site-footer .footer-copyright {
    width: 100%;
    max-width: 1100px;
    margin: 14px auto 0;
    color: var(--white);
    font-size: 0.84rem;
}

/* ================= HOMEPAGE ================= */
.eyebrow { margin: 0 0 14px; color: var(--secondary-color); font-size: 0.78rem; font-weight: 800; letter-spacing: 2px; }
.home-intro { background: white; }
.home-intro-grid { display: grid; grid-template-columns: 1.05fr 0.95fr; gap: 80px; align-items: end; }
.home-intro .section-title { max-width: 560px; margin-bottom: 0; font-size: 2.45rem; line-height: 1.18; }
.home-intro-grid > div:last-child { max-width: 440px; padding-bottom: 4px; }
.home-intro-grid p:not(.eyebrow) { margin: 0 0 22px; color: var(--text-muted); font-size: 1.08rem; }
.text-link { display: inline-flex; align-items: center; gap: 10px; color: var(--primary-color); font-weight: 800; text-decoration: none; }
.text-link span { color: var(--secondary-color); font-size: 1.35rem; transition: transform 0.2s ease; }
.text-link:hover span { transform: translateX(4px); }
.section-heading-row { display: flex; align-items: end; justify-content: space-between; gap: 24px; margin-bottom: 34px; }
.section-heading-row .section-title { margin-bottom: 0; }
.home-service-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
.home-service-card { min-height: 210px; padding: 24px; border-top: 3px solid var(--secondary-color); background: white; box-shadow: 0 8px 24px rgba(26,54,93,0.07); box-sizing: border-box; }
.service-number { display: block; margin-bottom: 48px; color: var(--secondary-color); font-size: 0.78rem; font-weight: 800; letter-spacing: 1px; }
.home-service-card h3 { margin: 0 0 10px; color: var(--primary-color); font-size: 1.15rem; }
.home-service-card p { margin: 0; color: var(--text-muted); font-size: 0.92rem; line-height: 1.55; }
.home-project-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px; max-width: 920px; }
.home-project-card { position: relative; display: block; height: 330px; overflow: hidden; color: white; text-decoration: none; background: var(--primary-color); }
.home-project-card img { width: 100%; height: 100%; display: block; object-fit: cover; transition: transform 0.5s ease; }
.home-project-card::after { position: absolute; inset: 35% 0 0; background: linear-gradient(transparent, rgba(17,36,62,0.92)); content: ''; }
.home-project-card span { position: absolute; right: 24px; bottom: 22px; left: 24px; z-index: 1; }
.home-project-card strong, .home-project-card small { display: block; }
.home-project-card strong { margin-bottom: 5px; font-size: 1.25rem; }
.home-project-card small { color: #E2E8F0; }
.home-project-card:hover img { transform: scale(1.06); }

/* ================= RESPONSIVE / MOBILE ================= */
@media (max-width: 768px) {
    .nav-container {
        flex-direction: column;
        gap: 12px;
        padding: 14px 16px;
    }

    nav {
        display: flex;
        justify-content: center;
        flex-wrap: wrap;
        gap: 8px 16px;
    }

    nav a {
        margin-left: 0;
        font-size: 0.9rem;
    }

    .hero {
        padding: 90px 20px;
    }

    .hero h1 {
        font-size: 2.35rem;
        line-height: 1.2;
    }

    .hero p {
        font-size: 1rem;
    }

    .section-padding {
        padding: 55px 0;
    }

    .section-title {
        font-size: 1.9rem;
        margin-bottom: 28px;
    }

    .container {
        padding: 0 16px;
    }

    .visi-box,
    .service-card,
    .misi-item,
    .reason-item {
        padding: 22px 18px;
    }

    .visi-box p {
        font-size: 1.05rem;
    }

    .portfolio-grid,
    .service-grid,
    .misi-grid,
    .reasons-grid {
        grid-template-columns: 1fr;
    }

    .portfolio-item {
        height: 220px;
    }

    .service-card:last-child {
        grid-column: auto;
    }

    .gallery-modal {
        padding: 12px;
    }

    .gallery-dialog {
        padding: 20px 12px 12px;
    }

    .gallery-dialog h2 {
        font-size: 1.3rem;
    }

    .gallery-viewer {
        min-height: 220px;
    }

    .gallery-viewer > img {
        height: 40vh;
    }

    .gallery-thumbnails {
        gap: 4px;
    }

    .gallery-thumbnails button {
        height: 52px;
    }

    .portfolio-overlay {
        opacity: 1;
    }

    .btn {
        width: 100%;
        box-sizing: border-box;
        text-align: center;
    }

    .hero-buttons {
        gap: 12px;
    }

    .home-intro-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .home-intro .section-title {
        font-size: 1.9rem;
    }

    .section-heading-row {
        align-items: flex-start;
        flex-direction: column;
        gap: 12px;
    }

    .home-service-grid,
    .home-project-grid {
        grid-template-columns: 1fr;
    }

    .home-service-card {
        min-height: 175px;
    }

    .service-number {
        margin-bottom: 30px;
    }

    .home-project-card {
        height: 245px;
    }

    .cta-footer {
        padding: 55px 20px;
    }

    .cta-footer h2 {
        font-size: 2rem;
    }
}

/* ================= BROWSER SAFETY / FALLBACKS ================= */
@supports not (display: grid) {
    .portfolio-grid,
    .service-grid,
    .misi-grid,
    .reasons-grid,
    .home-service-grid,
    .home-project-grid,
    .home-intro-grid {
        display: flex;
        flex-wrap: wrap;
        gap: 20px;
    }

    .portfolio-grid > *,
    .service-grid > *,
    .reasons-grid > *,
    .home-service-grid > *,
    .home-project-grid > * {
        flex: 1 1 280px;
    }
}

@media (max-width: 900px) {
    .home-intro-grid,
    .home-service-grid,
    .home-project-grid,
    .service-grid,
    .portfolio-grid {
        grid-template-columns: 1fr;
    }

    .home-service-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .section-heading-row {
        align-items: flex-start;
        flex-direction: column;
    }
}

@media (max-width: 520px) {
    .nav-container {
        align-items: stretch;
    }

    nav {
        width: 100%;
    }

    nav a {
        flex: 1 1 auto;
        text-align: center;
    }

    .hero h1 {
        font-size: 2rem;
    }

    .hero p {
        font-size: 0.95rem;
    }

    .section-title {
        font-size: 1.7rem;
    }

    .footer-content {
        flex-direction: column;
    }

    .site-footer .social-link {
        min-width: auto;
        width: 100%;
    }
}