/*====================================================
            GOOGLE FONT & RESET
====================================================*/

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
}

body{
    font-family:'Poppins',sans-serif;
    background:#f6f9ff;
    color:#222;
    overflow-x:hidden;
}

/*====================================================
                HERO
====================================================*/

.gallery-hero{
    position:relative;
    width:100%;
    min-height: 450px; /* Diubah dari height ke min-height agar responsif */
    background:
    linear-gradient(rgba(5,45,120,.72),
    rgba(5,45,120,.72)),
    url("../images/gedung.jpg");
    background-size:cover;
    background-position:center;
    display:flex;
    align-items:center;
    padding: 60px 20px; /* Tambahkan padding samping agar tidak mepet layar HP */
    overflow:hidden;
}

.gallery-overlay{
    position:absolute;
    inset:0;
    background:linear-gradient(
        90deg,
        rgba(4,44,120,.95) 0%,
        rgba(4,44,120,.55) 45%,
        rgba(4,44,120,.15) 100%
    );
}

.gallery-hero-content{
    position:relative;
    z-index:5;
    max-width:650px;
    width: 100%;
    color:#fff;
}

/*====================================================
            SUB TITLE
====================================================*/

.gallery-subtitle{
    display:inline-flex;
    align-items:center;
    gap:10px;
    background:rgba(255,255,255,.15);
    padding:10px 18px;
    border-radius:50px;
    backdrop-filter:blur(8px);
    margin-bottom:25px;
    font-size:15px;
    letter-spacing:.5px;
}

.gallery-subtitle i{
    color:#FFD34D;
}

/*====================================================
                HERO TITLE
====================================================*/

.gallery-hero-content h1{
    font-size:70px;
    line-height:1.1;
    font-weight:700;
    margin-bottom:20px;
}

.gallery-hero-content p{
    font-size:19px;
    line-height:1.8;
    color:#f4f4f4;
    margin-bottom:35px;
}

/*====================================================
            BREADCRUMB
====================================================*/

.hero-breadcrumb{
    display:inline-flex;
    align-items:center;
    gap:15px;
    background:#ffffff;
    color:#222;
    padding:14px 24px;
    border-radius:50px;
    box-shadow:0 10px 30px rgba(0,0,0,.15);
}

.hero-breadcrumb a{
    color:#0a57d5;
    text-decoration:none;
    font-weight:600;
}

.hero-breadcrumb span{
    font-weight:600;
}

.hero-breadcrumb i{
    color:#888;
    font-size:13px;
}

/*====================================================
                WAVE
====================================================*/

.wave{
    position:absolute;
    bottom:-2px;
    left:0;
    width:100%;
}

.wave svg{
    width:100%;
    height:90px;
}

/*====================================================
            STATISTIK GALERI
====================================================*/

.gallery-stats{
    position:relative;
    margin-top:-35px;
    margin-bottom:20px;
    padding: 0 20px; /* Menjaga kontainer aman di HP */
    z-index:20;
}

.stats-card{
    background:#fff;
    border-radius:25px;
    box-shadow:0 18px 45px rgba(0,0,0,.12);
    padding:35px;
    display:flex;
    justify-content:space-between;
    align-items:center;
}

.stat-item{
    display:flex;
    align-items:center;
    gap:18px;
    flex:1;
}

.stat-icon{
    width:70px;
    height:70px;
    border-radius:50%;
    background:#edf4ff;
    color:#0b5ed7;
    display:flex;
    justify-content:center;
    align-items:center;
    font-size:28px;
    flex-shrink: 0;
}

.stat-item h3{
    font-size:38px;
    color:#123c78;
    margin-bottom:5px;
}

.stat-item span{
    color:#777;
    font-size:16px;
}

.stat-divider{
    width:1px;
    height:70px;
    background:#ddd;
}

/*====================================================
            SECTION GALERI & TOOLBAR
====================================================*/

.gallery-wrapper{
    padding:40px 20px 80px;
    position:relative;
}

.gallery-title{
    text-align:center;
    margin-bottom:35px;
}

.icon-circle{
    width:80px;
    height:80px;
    border-radius:50%;
    margin:auto;
    display:flex;
    align-items:center;
    justify-content:center;
    background:linear-gradient(135deg,#0b5ed7,#3c82ff);
    color:#fff;
    font-size:28px;
    margin-bottom:20px;
    box-shadow:0 20px 35px rgba(11,94,215,.25);
}

.gallery-title h2{
    font-size:46px;
    color:#123c78;
    margin-bottom:12px;
}

.gallery-title p{
    font-size:18px;
    color:#666;
}

.gallery-toolbar{
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:20px;
    flex-wrap:wrap;
    margin-bottom:35px;
}

.gallery-search{
    width:300px;
    height:48px;
    background:#fff;
    border:1px solid #dce6f5;
    border-radius:50px;
    display:flex;
    align-items:center;
    padding:0 18px;
    box-shadow:0 10px 25px rgba(0,0,0,.08);
}

.gallery-search i{
    color:#0b5ed7;
    margin-right:10px;
}

.gallery-search input{
    width:100%;
    border:none;
    outline:none;
    background:transparent;
    font-size:15px;
}

/*====================================================
            FILTER
====================================================*/

.gallery-filter{
    display:flex;
    justify-content:center;
    flex-wrap:wrap;
    gap:18px;
    margin-bottom:50px;
}

.gallery-filter button{
    border:none;
    padding:14px 28px;
    border-radius:50px;
    background:rgba(255,255,255,.85);
    backdrop-filter:blur(12px);
    box-shadow:0 10px 25px rgba(0,0,0,.08);
    cursor:pointer;
    transition:.35s;
    font-size:15px;
    font-weight:600;
    display:flex;
    align-items:center;
    gap:10px;
}

.gallery-filter button i{
    color:#0b5ed7;
}

.gallery-filter button:hover,
.gallery-filter button.active{
    background:#0b5ed7;
    color:#fff;
}

.gallery-filter button:hover i,
.gallery-filter button.active i{
    color:#fff;
}

/*====================================================
                GALLERY GRID
====================================================*/

.gallery-grid{
    display:grid;
    grid-template-columns:repeat(4,1fr);
    gap:35px;
}

.gallery-item{
    position:relative;
    overflow:hidden;
    border-radius:20px;
    background:#fff;
    box-shadow:0 15px 35px rgba(0,0,0,.12);
    transition:all .35s ease;
    cursor:pointer;
}

.gallery-item:hover{
    transform:translateY(-8px);
    box-shadow:0 25px 45px rgba(0,0,0,.18);
}

.gallery-item img{
    width:100%;
    height:300px;
    object-fit:cover;
    display:block;
    transition:transform .45s ease;
}

.gallery-item:hover img{
    transform:scale(1.08);
}

.gallery-overlay-box{
    position:absolute;
    left:0;
    right:0;
    bottom:0;
    padding:20px;
    background:linear-gradient(
    to top,
    rgba(0,0,0,.85),
    rgba(0,0,0,.25),
    transparent);
    color:#fff;
}

.gallery-category{
    display:inline-block;
    padding:6px 14px;
    margin-bottom:14px;
    background:#0B63F6;
    color:#fff;
    font-size:12px;
    font-weight:600;
    border-radius:30px;
    letter-spacing:.3px;
}

.gallery-overlay-box h3{
    font-size:22px;
    font-weight:600;
    line-height:1.4;
    margin-bottom:6px;
    color:#fff;
}

.gallery-overlay-box p{
    display:flex;
    align-items:center;
    gap:8px;
    font-size:13px;
    color:rgba(255,255,255,.85);
    margin:0;
}

.gallery-view{
    position:absolute;
    top:20px;
    right:20px;
    width:45px;
    height:45px;
    border-radius:50%;
    background:#fff;
    color:#0b5ed7;
    display:flex;
    justify-content:center;
    align-items:center;
    opacity:0;
    transition:.3s;
}

.gallery-item:hover .gallery-view{
    opacity:1;
}

.load-gallery{
    margin-top:50px;
    text-align:center;
}

.load-gallery button{
    padding:15px 35px;
    border:none;
    border-radius:40px;
    background:#0b5ed7;
    color:#fff;
    font-size:16px;
    cursor:pointer;
}

.no-result{
    display:none;
    text-align:center;
    padding:70px 20px;
    color:#6c757d;
}

.no-result i{
    font-size:70px;
    color:#cfd8e3;
    margin-bottom:20px;
}

.no-result h3{
    font-size:28px;
    color:#2d3a4a;
    margin-bottom:10px;
}

.no-result p{
    font-size:16px;
}

/*====================================================
            CTA GALERI
====================================================*/

.gallery-cta{
    padding:40px 20px 70px;
}

.gallery-cta-box{
    background:linear-gradient(90deg,#EAF3FF 0%,#DCEEFF 100%);
    border-radius:22px;
    padding:40px 45px;
    display:flex;
    justify-content:space-between;
    align-items:center;
    gap:30px;
    box-shadow:0 15px 40px rgba(0,0,0,.08);
}

.gallery-cta-left{
    display:flex;
    align-items:center;
    gap:25px;
}

.gallery-cta-icon{
    width:70px;
    height:70px;
    border-radius:50%;
    background:#0d47a1;
    color:#fff;
    display:flex;
    justify-content:center;
    align-items:center;
    font-size:30px;
    flex-shrink:0;
}

.gallery-cta-left h2{
    color:#0d47a1;
    font-size:32px;
    margin-bottom:8px;
}

.gallery-cta-left p{
    color:#555;
    line-height:1.8;
    max-width:650px;
}

.gallery-btn-wa{
    display:flex;
    align-items:center;
    gap:10px;
    background:#0d47a1;
    color:#fff;
    padding:16px 34px;
    border-radius:12px;
    text-decoration:none;
    font-weight:600;
    transition:.3s;
    white-space: nowrap;
}

.gallery-btn-wa:hover{
    background:#08357d;
    transform:translateY(-3px);
}

/*=============================
        LIGHTBOX & MODAL
=============================*/

.lightbox{
    position:fixed;
    inset:0;
    background:rgba(0,0,0,.92);
    display:none;
    justify-content:center;
    align-items:center;
    z-index:99999;
    animation:fadeIn .3s;
}

.lightbox img{
    max-width:90%;
    max-height:85vh;
    border-radius:15px;
    box-shadow:0 20px 60px rgba(0,0,0,.6);
    animation:zoomIn .35s;
}

.close-lightbox,
.lightbox-prev,
.lightbox-next{
    position:absolute;
    width:55px;
    height:55px;
    border-radius:50%;
    background:rgba(255,255,255,.12);
    backdrop-filter:blur(10px);
    display:flex;
    justify-content:center;
    align-items:center;
    color:#fff;
    cursor:pointer;
    transition:.3s;
}

.close-lightbox:hover,
.lightbox-prev:hover,
.lightbox-next:hover{
    background:#0b5ed7;
}

.close-lightbox{ top:30px; right:30px; font-size:30px; }
.lightbox-prev{ left:30px; font-size:28px; }
.lightbox-next{ right:30px; font-size:28px; }

.upload-modal{
    position:fixed;
    inset:0;
    background:rgba(0,0,0,.6);
    display:none;
    justify-content:center;
    align-items:center;
    z-index:99999;
}

.upload-modal.active{
    display:flex;
}

.upload-box{
    width:90%;
    max-width:360px;
    background:#fff;
    border-radius:20px;
    padding:30px;
    text-align:center;
    animation:popup .25s ease;
}

.upload-box h3{ margin-bottom:25px; color:#123c78; }
.upload-box button{
    width:100%;
    margin:10px 0;
    padding:16px;
    border:none;
    border-radius:12px;
    cursor:pointer;
    font-size:16px;
    font-weight:600;
    transition:.3s;
}

#openCamera{ background:#0b5ed7; color:white; }
#openGallery{ background:#198754; color:white; }
#closeUpload{ background:#f1f1f1; }

@keyframes fadeIn{ from{opacity:0;} to{opacity:1;} }
@keyframes zoomIn{ from{transform:scale(.8); opacity:0;} to{transform:scale(1); opacity:1;} }
@keyframes popup{ from{transform:scale(.8); opacity:0;} to{transform:scale(1); opacity:1;} }

/*==================================
            FOOTER
==================================*/

.footer{
    background:#0d47a1;
    color:#fff;
    padding:70px 20px 25px;
}

.footer-grid{
    display:grid;
    grid-template-columns:2fr 1fr 1.3fr 1fr;
    gap:50px;
}

.footer-about img{ width:150px; margin-bottom:20px; }
.footer-about h3{ margin-bottom:15px; }
.footer-about p{ line-height:1.8; color:#d9e6ff; }
.footer h4{ margin-bottom:20px; font-size:20px; }
.footer ul{ list-style:none; padding:0; }
.footer ul li{ margin-bottom:12px; }
.footer ul li a{ color:#d9e6ff; text-decoration:none; transition:.3s; }
.footer ul li a:hover{ color:#fff; }
.footer-contact p{ margin-bottom:12px; color:#d9e6ff; }
.footer-contact i{ width:22px; }
/* Tautan telepon/WA/email di footer: ikut warna teks, bukan biru bawaan. */
.footer-contact a{ color:inherit; text-decoration:none; }
.footer-contact a:hover,
.footer-contact a:focus{ color:#fff; text-decoration:underline; }

.social-icons{
    display:flex;
    gap:12px;
}

.social-icons a{
    width:45px;
    height:45px;
    border-radius:50%;
    background:rgba(255,255,255,.15);
    display:flex;
    justify-content:center;
    align-items:center;
    color:#fff;
    text-decoration:none;
    transition:.3s;
}

.social-icons a:hover{
    background:#fff;
    color:#0d47a1;
    transform:translateY(-5px);
    box-shadow:0 10px 20px rgba(0,0,0,.15);
}

.footer-bottom{
    border-top:1px solid rgba(255,255,255,.15);
    margin-top:50px;
    padding-top:20px;
    text-align:center;
    color:#cbdcff;
}

/*====================================================
            RESPONSIVE BREAKPOINTS (ALL-IN-ONE)
====================================================*/

/* Laptop (Max 1200px) */
@media (max-width: 1200px){
    .gallery-grid{
        grid-template-columns:repeat(3, 1fr);
    }
}

/* Tablet (Max 992px) */
@media(max-width:992px){
    .gallery-hero{
        min-height:430px;
    }
    .gallery-hero-content h1{
        font-size:52px;
    }
    .stats-card{
        flex-direction:column;
        gap:30px;
    }
    .stat-divider{
        display:none;
    }
    .stat-item{
        justify-content:center;
    }
    .gallery-grid{
        grid-template-columns:repeat(2, 1fr);
        gap:25px;
    }
    .footer-grid{
        grid-template-columns:1fr 1fr;
    }
}

/* Tablet Kecil / Smartphone Tinggi (Max 768px) */
@media(max-width:768px){
    .gallery-hero{
        min-height: auto;
        padding: 50px 20px;
    }
    .gallery-hero-content{
        text-align:center;
        margin:auto;
    }
    .gallery-hero-content h1{
        font-size:40px;
    }
    .gallery-hero-content p{
        font-size:16px;
    }
    .gallery-title h2{
        font-size:34px;
    }
    .hero-breadcrumb{
        font-size:14px;
        padding: 10px 18px;
    }
    .gallery-cta-box{
        flex-direction:column;
        text-align:center;
    }
    .gallery-cta-left{
        flex-direction:column;
        text-align: center;
    }
    .lightbox img{
        max-width:95%;
    }
    .lightbox-prev,
    .lightbox-next{
        width:45px;
        height:45px;
    }
    .lightbox-prev{ left: 10px; }
    .lightbox-next{ right: 10px; }
}

/* Smartphone / HP (Max 576px) */
@media(max-width:576px){
    .gallery-hero{
        padding: 40px 15px;
    }
    .gallery-hero-content h1{
        font-size:30px;
    }
    .gallery-subtitle{
        font-size:12px;
        padding: 8px 14px;
    }
    .gallery-search{
        width: 100%; /* Search bar memenuhi layar HP */
    }
    .gallery-filter{
        gap:8px;
    }
    .gallery-filter button{
        padding:8px 14px;
        font-size:12px;
    }
    .gallery-grid{
        grid-template-columns: 1fr; /* 1 kolom penuh di HP */
        gap:20px;
    }
    .gallery-item img{
        height:240px;
    }
    .gallery-overlay-box h3{
        font-size:18px;
    }
    .gallery-overlay-box p{
        font-size:12px;
    }
    .footer-grid{
        grid-template-columns:1fr;
        text-align:center;
    }
    .social-icons{
        justify-content:center;
    }
}