/* ================= BAnner gallery ================= */
.banner-gallery{
    position:relative;
    overflow:hidden;
    background:
    linear-gradient(
        120deg,
        #8b0000 0%,
        #c40012 45%,
        #e60012 100%
    );
    padding:50px 0;
    text-align:center;
}

/* SHAPE KIRI */
.banner-gallery::before{
    content:"";
    position:absolute;
    width:520px;
    height:520px;
    left:-250px;
    top:-180px;
    background:
    linear-gradient(
        135deg,
        rgba(255,255,255,.18),
        rgba(255,255,255,0)
    );
    transform:rotate(35deg);
}

.banner-gallery::after{
    content:"";
    position:absolute;
    width:600px;
    height:600px;
    right:-280px;
    bottom:-260px;
    background:
    linear-gradient(
        135deg,
        rgba(255,255,255,.22),
        rgba(255,255,255,0)
    );
    transform:rotate(-25deg);
}

.banner-gallery-content{
    max-width:700px;
    position:relative;
    z-index:2;
    display:flex;
    gap:12px;
    font-size:25px;
    margin-top:30px;
}

.banner-gallery-content h2{
    font-size:30px;
    font-weight:700;
    color:white;
    margin-bottom:15px;
    text-align:left;
}

.gallery-breadcrumb{
    display:flex;
    gap:12px;
    font-size:15px;
    margin-bottom:10px;
}

.gallery-breadcrumb a{
    color:#fff;
    text-decoration:none;
    opacity:.9;
    font-weight:600;
}

.gallery-breadcrumb a:hover{
    color:#af1b88;
    text-decoration:none;
}

.gallery-breadcrumb span{
    color:#d4d4d4;
    text-decoration:none;   
    opacity:.9;
    font-weight:600;
}

.detail-gallery-label{
    display:inline-block;
    letter-spacing:3px;
    font-size:49px;
    font-weight:700;
    color:#ffd166;
    margin-top: 90px; 
}

.gallery-detail-title{
    position:relative;
    z-index:2;
    width:100%;
    max-width:1200px;
    margin:0 auto;
    padding:0 24px;
}

.gallery-detail-title h1{
    font-size:48px;
    line-height:1.25;
    line-height:1.2;
    margin-top:10px;
    margin-bottom:20px;
    max-width:850px;
}

.detail-gallery-meta{
    display:flex;
    gap:30px;
    font-size:16px;
    margin-top:12px;
}

.gallery-detail-wrapper{
    margin-top:15px;
    position:relative;
    z-index:10;
    max-width:1200px;
    margin-left:auto;
    margin-right:auto;
    padding:0 24px;
}

.gallery-detail-image{
    max-height:650px;
    height:650px;
    object-fit:cover;
    object-position:center;
    display:block;
}

.gallery-detail-image-card{
    background:#fff;
    border-radius:28px;
    padding:18px;
    box-shadow:0 20px 60px rgba(0,0,0,.10);
    margin-bottom:40px;
}

.gallery-detail-image-card img{
    background:#fff;
    border-radius:28px;
    padding:18px;
    box-shadow:0 20px 60px rgba(0,0,0,.10);
    margin-bottom:40px;
}

.gallery-detail-article-card{
    background:#fff;
    border-radius:28px;
    box-shadow:0 20px 60px rgba(0,0,0,.08);
    margin-bottom:70px;
    border-radius:28px;
    padding:50px 60px;
}

.article-gallery-content{
    font-size:19px;
    line-height:2;
    color:#374151;
}

.article-gallery-content p{
    margin-bottom:24px;
}

.gallery-video-wrapper{
    position:relative;
    width:100%;
    aspect-ratio:16/9;
    border-radius:20px;
    overflow:hidden;
}

.gallery-video-wrapper iframe{
    width:100%;
    height:100%;
    border:none;
    display:block;
}

/* =========================================================
   RESPONSIVE — MOBILE
   DNA mengikuti DETAIL BERITA
   Desktop TIDAK DISENTUH
========================================================= */

@media(max-width:600px){

    /* =====================================================
       BANNER
    ===================================================== */

    .gallery-breadcrumb{
        display:none;
    }

    .banner-gallery-content{
        max-width:700px;
        position:relative;
        z-index:2;
        display:flex;
        gap:12px;
        font-size:25px;
        margin-top:-18px;
        margin-left:2px;
        padding:0;
    }

    .banner-gallery-content h2{
        font-size:30px;
        font-weight:700;
        color:#fff;
        margin-bottom:15px;
        text-align:left;
    }


    /* =====================================================
       JUDUL GALLERY
    ===================================================== */

    .gallery-detail-title{
        width:100%;
        max-width:none;

        margin:0;

        padding:24px 20px 0;

        box-sizing:border-box;
    }

    .gallery-detail-title h1{
        font-size:28px;
        line-height:1.25;
        font-weight:700;

        margin:0 0 16px;

        max-width:none;

        color:#172554;
    }


    /* =====================================================
       META TANGGAL + KATEGORI
    ===================================================== */

    .detail-gallery-meta{
        display:flex;

        align-items:center;

        flex-wrap:wrap;

        gap:10px 18px;

        font-size:14px;

        line-height:1.5;

        margin:0;

        color:#64748b;
    }

    .detail-gallery-meta span{
        display:inline-flex;

        align-items:center;

        gap:5px;
    }


    /* =====================================================
       WRAPPER KONTEN
    ===================================================== */

    .gallery-detail-wrapper{
        width:100%;

        max-width:none;

        margin:20px 0 0;

        padding:0 20px;

        box-sizing:border-box;
    }


    /* =====================================================
       CARD GAMBAR / VIDEO
    ===================================================== */

    .gallery-detail-image-card{
        padding:12px;

        border-radius:22px;

        background:#fff;

        box-shadow:0 10px 30px rgba(0,0,0,.08);

        margin-bottom:24px;
    }


    /* =====================================================
       IMAGE VIEWER
    ===================================================== */

    .gallery-detail-image-card .media-viewer{
        position:relative;

        width:100%;

        height:220px;

        overflow:hidden;

        border-radius:16px;

        background:#f8fafc;
    }


    /* =====================================================
       GAMBAR
    ===================================================== */

    .gallery-detail-image-card
    .media-viewer
    .gallery-detail-image{

        display:block;

        width:100%;

        height:100%;

        max-height:none;

        padding:0;

        margin:0;

        border-radius:16px;

        object-fit:cover;

        object-position:center;

        box-shadow:none;
    }


    /*
       Untuk gallery foto/artikel, gambar thumbnail
       mengikuti jendela preview seperti berita.
    */


    /* =====================================================
       OVERLAY "LIHAT GAMBAR"
    ===================================================== */

    .gallery-detail-image-card .media-overlay{
        position:absolute;

        inset:0;

        display:flex;

        align-items:center;

        justify-content:center;

        background:rgba(0,0,0,.18);

        opacity:1;
    }


    /* =====================================================
       VIDEO
    ===================================================== */

    .gallery-video-wrapper{
        position:relative;

        width:100%;

        aspect-ratio:16/9;

        border-radius:16px;

        overflow:hidden;
    }

    .gallery-video-wrapper iframe{
        width:100%;

        height:100%;

        border:none;

        display:block;
    }


    /* =====================================================
       CARD ISI ARTIKEL
    ===================================================== */

    .gallery-detail-article-card{
        width:100%;

        box-sizing:border-box;

        background:#fff;

        border-radius:22px;

        padding:28px 24px;

        margin:0 0 60px;

        box-shadow:0 12px 35px rgba(0,0,0,.07);

        border:none;
    }


    /* =====================================================
       TEKS ARTIKEL
    ===================================================== */

    .article-gallery-content{
        width:100%;

        font-size:16px;

        line-height:1.85;

        color:#475569;

        text-align:left;

        word-break:normal;

        overflow-wrap:break-word;
    }


    /*
       Konten Gallery menggunakan:
       replace('\n','<br>') | safe

       Jadi kita pertahankan perilaku <br>
       seperti pada Detail Berita.
    */

    .article-gallery-content br{
        line-height:1.85;
    }


    /* =====================================================
       SPACING BAWAH
    ===================================================== */

    .gallery-detail-wrapper::after{
        content:"";

        display:block;

        height:20px;
    }

}