/* ============================================================
   SIPBUM - Mobile App Stylesheet
   Tampilan mobile bergaya aplikasi native (Android/iOS)
   Aktif hanya pada layar < 992px
   ============================================================ */

:root {
    --app-primary: #1842b6;
    --app-primary-dark: #0f2e80;
    --app-surface: #ffffff;
    --app-bg: #f4f6fb;
    --app-text: #1c2333;
    --app-muted: #6b7280;
    --app-nav-height: 64px;
}

@media (max-width: 991.98px) {

    html {
        scroll-behavior: smooth;
        -webkit-text-size-adjust: 100%;
    }

    body {
        background-color: var(--app-bg);
        color: var(--app-text);
        -webkit-tap-highlight-color: transparent;
        overflow-x: hidden;
    }



    /* ---------- Topbar desktop disembunyikan ---------- */
    .container-fluid.bg-dark,
    .topbar,
    #note {
        display: none !important;
    }

    /* ---------- Navbar atas jadi app bar ringkas ---------- */
    .container-fluid.bg-primary:not(.page-header) {
        position: sticky;
        top: 0;
        z-index: 1020;
        box-shadow: 0 2px 12px rgba(24, 66, 182, 0.35);
    }

    .navbar-brand img.logo-img {
        height: 44px !important;
    }

    /* ---------- Navbar atas tetap di atas (frontend) ---------- */
    .navbar-toggler {
        border-color: rgba(255, 255, 255, 0.6);
    }

    .navbar-collapse {
        background: #ffffff !important;
        border-radius: 0 0 16px 16px;
        padding: 8px 16px 16px;
        box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
    }

    .navbar-collapse .nav-link,
    .navbar-collapse .dropdown-item {
        color: #1c2333 !important;
        padding: 12px 10px !important;
        border-radius: 12px;
    }

    .navbar-collapse .nav-link:hover,
    .navbar-collapse .nav-link:focus,
    .navbar-collapse .dropdown-item:hover,
    .navbar-collapse .dropdown-item:focus {
        background-color: #f0f3fa;
        color: var(--app-primary) !important;
    }

    .navbar-collapse .nav-link.active {
        color: var(--app-primary) !important;
        font-weight: 700;
    }

    .navbar-collapse .dropdown-menu {
        background: #ffffff !important;
        border: 1px solid #e7eaf1;
        box-shadow: none;
    }

    /* Frontend: sembunyikan bottom nav (hanya admin yang pakai bottom) */
    #app-bottom-nav, #appMenuSheet { display: none !important; }

    /* tiap tab */
    #app-bottom-nav .app-tab {
        position: relative;
        flex: 1;
        max-width: 72px;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        gap: 4px;
        text-decoration: none;
        color: var(--app-muted);
        font-size: 10.5px;
        font-weight: 600;
        line-height: 1;
        letter-spacing: 0.02em;
        background: transparent;
        border: 0;
        cursor: pointer;
        padding: 4px 2px;
        border-radius: 16px;
        transition: color 0.2s ease, background 0.2s ease, transform 0.12s ease;
        -webkit-tap-highlight-color: transparent;
    }

    #app-bottom-nav .app-tab-icon {
        width: 28px;
        height: 28px;
        display: grid;
        place-items: center;
        border-radius: 10px;
        transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
    }

    #app-bottom-nav .app-tab-icon i {
        font-size: 18px;
        line-height: 1;
    }

    #app-bottom-nav .app-tab:active {
        transform: scale(0.92);
    }

    #app-bottom-nav .app-tab.active {
        color: var(--app-primary);
    }

    #app-bottom-nav .app-tab.active .app-tab-icon {
        background: #eef2ff;
        color: var(--app-primary);
        transform: translateY(-1px);
    }

    /* Tab Menu (tengah) sedikit menonjol gaya iOS/Android */
    #app-bottom-nav .app-tab-menu .app-tab-icon {
        background: var(--app-primary);
        color: #fff;
        width: 32px;
        height: 32px;
        border-radius: 12px;
        box-shadow: 0 4px 12px rgba(24, 66, 182, 0.35);
    }

    #app-bottom-nav .app-tab-menu.active {
        color: var(--app-primary);
    }

    #app-bottom-nav .app-tab-menu.active .app-tab-icon {
        background: var(--app-primary-dark);
        color: #fff;
    }

    #app-bottom-nav .app-tab-label {
        font-size: 10px;
        white-space: nowrap;
    }

    /* ---------- Bottom Sheet / App Drawer ---------- */
    #appMenuSheet {
        border-radius: 24px 24px 0 0;
        max-height: 82vh;
        height: auto;
        border: 0;
        box-shadow: 0 -12px 40px rgba(16, 32, 77, 0.18);
        background: #ffffff;
        z-index: 1045;
    }

    #appMenuSheet.offcanvas-bottom {
        --bs-offcanvas-height: auto;
    }

    .offcanvas-backdrop.show {
        opacity: 0.45;
    }

    .app-sheet-handle {
        width: 36px;
        height: 5px;
        border-radius: 999px;
        background: #d9deea;
        margin: 10px auto 2px;
    }

    .app-sheet-header {
        padding: 6px 18px 10px;
        border-bottom: 1px solid #eef1f6;
    }

    .app-sheet-header .offcanvas-title {
        font-size: 16px;
        font-weight: 800;
        color: #1c2333;
        letter-spacing: -0.02em;
    }

    .app-sheet-body {
        padding: 16px 14px calc(16px + env(safe-area-inset-bottom, 0px));
        overflow-y: auto;
    }

    .app-menu-grid {
        display: grid;
        grid-template-columns: repeat(4, 1fr);
        gap: 10px 8px;
    }

    .app-menu-item {
        display: flex;
        flex-direction: column;
        align-items: center;
        gap: 7px;
        text-decoration: none;
        color: #1c2333;
        font-size: 11px;
        font-weight: 600;
        text-align: center;
        padding: 8px 4px;
        border-radius: 14px;
        transition: background 0.15s ease, transform 0.12s ease;
    }

    .app-menu-item:active {
        background: #f4f6fb;
        transform: scale(0.97);
    }

    .app-menu-icon {
        width: 54px;
        height: 54px;
        border-radius: 16px;
        display: grid;
        place-items: center;
        color: #fff;
        font-size: 20px;
        box-shadow: 0 6px 14px rgba(0,0,0,0.08);
    }

    .app-menu-icon.bg-primary { background: linear-gradient(135deg, #1842b6, #2a5bd7); }
    .app-menu-icon.bg-info { background: linear-gradient(135deg, #0ea5e9, #22d3ee); }
    .app-menu-icon.bg-success { background: linear-gradient(135deg, #0a7a2e, #16a34a); }
    .app-menu-icon.bg-warning { background: linear-gradient(135deg, #d97706, #facc15); color: #1c2333; }
    .app-menu-icon.bg-danger { background: linear-gradient(135deg, #dc2626, #f87171); }
    .app-menu-icon.bg-dark { background: linear-gradient(135deg, #1e293b, #475569); }
    .app-menu-icon.bg-secondary { background: linear-gradient(135deg, #6b7280, #9ca3af); }

    .app-sheet-divider {
        height: 1px;
        background: #eef1f6;
        margin: 16px 2px;
    }

    .app-sheet-section {
        margin-bottom: 14px;
    }

    .app-sheet-title {
        font-size: 12px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.07em;
        color: #6b7280;
        margin: 0 0 8px 4px;
    }

    .app-sheet-list {
        display: flex;
        flex-direction: column;
        gap: 6px;
    }

    .app-sheet-list-item {
        display: flex;
        align-items: center;
        gap: 10px;
        padding: 12px 14px;
        background: #f8f9fe;
        border-radius: 12px;
        text-decoration: none;
        color: #1c2333;
        font-size: 14px;
        font-weight: 600;
        line-height: 1.2;
    }

    .app-sheet-list-item i.fa-chevron-right {
        font-size: 12px;
        color: #9aa3b8;
        flex-shrink: 0;
    }

    .app-sheet-list-item small {
        margin-left: auto;
        font-size: 11px;
        font-weight: 500;
        color: #6b7280;
        text-align: right;
        max-width: 42%;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
    }

    .app-sheet-list-item:active {
        background: #eef2ff;
    }

    /* ---------- Page Header lebih ringkas ---------- */
    .page-header {
        padding-top: 2.5rem !important;
        padding-bottom: 2.5rem !important;
        border-radius: 0 0 24px 24px;
    }

    .page-header h1.display-2 {
        font-size: 1.75rem !important;
        margin-bottom: 0.75rem !important;
    }

    .page-header .breadcrumb {
        font-size: 13px;
    }

    /* ---------- Kartu & seksi ---------- */
    section,
    main {
        scroll-margin-top: 70px;
    }

    .container {
        padding-left: 18px;
        padding-right: 18px;
    }

    .blog-item,
    .services-item,
    .project-item,
    .team-item,
    .testimonial-item,
    .card,
    .weather-card {
        border-radius: 18px !important;
        overflow: hidden;
    }

    .blog-item,
    .card,
    .services-item {
        box-shadow: 0 6px 18px rgba(16, 32, 77, 0.07);
        margin-bottom: 8px;
    }

    .section-title h1,
    h1 {
        word-wrap: break-word;
    }

    /* tombol besar ramah jempol */
    .btn {
        min-height: 44px;
    }

    .btn-sm {
        min-height: 32px;
    }

    /* ---------- Carousel ---------- */
    .carousel-caption img[alt="Logo"] {
        max-width: 62% !important;
    }

    .carousel-caption p.display-6 {
        font-size: 1rem !important;
        line-height: 1.45 !important;
        text-shadow: 0 1px 6px rgba(0, 0, 0, 0.55);
    }

    .carousel-caption {
        padding-bottom: 1.25rem !important;
    }

    /* ---------- Formulir ---------- */
    .form-control,
    .form-select {
        font-size: 16px; /* cegah auto-zoom iOS */
        min-height: 46px;
        border-radius: 12px;
    }

    textarea.form-control {
        min-height: 120px;
    }

    .form-label {
        font-weight: 600;
    }

    .btn-primary,
    .btn-secondary {
        border-radius: 12px;
    }

    /* ---------- Offcanvas cuaca full lebar di ponsel ---------- */
    #offcanvasRight {
        width: 88% !important;
        max-width: 360px;
    }

    /* Tombol toggle cuaca mengambang di atas bottom nav */
    button#weatherToggleButton.position-fixed.top-50 {
        top: auto !important;
        transform: none !important;
        bottom: calc(var(--app-nav-height) + 18px + env(safe-area-inset-bottom, 0px));
        right: 0;
        border-radius: 14px 0 0 14px;
        padding: 10px 12px !important;
        box-shadow: 0 4px 14px rgba(0, 0, 0, 0.25);
    }

    /* ---------- Back to Top ---------- */
    .back-to-top {
        bottom: calc(var(--app-nav-height) + 90px) !important;
        right: 14px !important;
    }

    /* ---------- Footer ---------- */
    footer.bg-primary {
        border-radius: 24px 24px 0 0;
        padding-bottom: 1.25rem;
    }

    footer.bg-primary img {
        height: 76px !important;
    }
}

/* Layar sangat kecil (<380px) */
@media (max-width: 379.98px) {
    #app-bottom-nav .app-tab {
        font-size: 9.5px;
    }

    #app-bottom-nav .app-tab-icon i {
        font-size: 16px;
    }

    #app-bottom-nav .app-tab-icon {
        width: 26px;
        height: 26px;
    }

    #app-bottom-nav .app-tab-menu .app-tab-icon {
        width: 30px;
        height: 30px;
    }

    .app-menu-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 8px 6px;
    }

    .app-menu-icon {
        width: 48px;
        height: 48px;
        font-size: 18px;
        border-radius: 14px;
    }

    .app-menu-item {
        font-size: 10px;
        padding: 6px 2px;
    }
}

/* ============================================================
   LAPISAN ELEMEN - semua komponen halaman bergaya aplikasi
   ============================================================ */
@media (max-width: 991.98px) {

    /* ---------- Skala tipografi ---------- */
    h1 {
        font-size: clamp(1.4rem, 5.5vw, 1.9rem);
    }

    h2 {
        font-size: clamp(1.2rem, 4.8vw, 1.55rem);
    }

    h3, .h3 {
        font-size: clamp(1.1rem, 4.2vw, 1.35rem);
    }

    h4, .h4, h5, .h5 {
        font-size: clamp(0.95rem, 3.8vw, 1.1rem);
    }

    p {
        font-size: 0.95rem;
    }

    /* ---------- Kompresi ruang seksi ---------- */
    .container-fluid.py-5:not(.page-header),
    .container.py-5:not(.page-header) {
        padding-top: 1.75rem !important;
        padding-bottom: 1.75rem !important;
    }

    .my-5 {
        margin-top: 1.25rem !important;
        margin-bottom: 1.25rem !important;
    }

    .py-5.my-5,
    .container-fluid.pb-5.mb-5,
    .container-fluid.py-5.mb-5 {
        padding-top: 1.75rem !important;
        padding-bottom: 1.75rem !important;
        margin-bottom: 1.25rem !important;
    }

    .g-5 {
        --bs-gutter-x: 1.25rem;
        --bs-gutter-y: 1.25rem;
    }

    /* ---------- Kartu statistik pengunjung ---------- */
    .card-stats {
        min-height: auto;
    }

    .card-stats .card-body {
        padding: 0.9rem 1rem;
    }

    .card-stats .display-4 {
        font-size: 1.8rem;
    }

    .card-stats .card-title {
        font-size: 0.7rem !important;
        letter-spacing: 0.04em;
    }

    .card-stats .bi {
        font-size: 2rem !important;
        opacity: 0.85;
    }

    /* ---------- Video YouTube & embed Instagram: selalu 2 baris ---------- */
    .contact-detail .row > .col-lg-6 {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .contact-map {
        padding: 0.75rem !important;
        margin-bottom: 16px;
        background: #ffffff !important;
        border-radius: 18px !important;
        box-shadow: 0 6px 18px rgba(16, 32, 77, 0.07);
    }

    .contact-map iframe {
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 16 / 9;
        border-radius: 12px;
        display: block;
    }

    .contact-form {
        padding: 0.75rem !important;
        background: #ffffff !important;
        border-radius: 18px !important;
        box-shadow: 0 6px 18px rgba(16, 32, 77, 0.07);
        overflow-x: hidden;
    }

    .contact-form blockquote.instagram-media,
    .instagram-media {
        max-width: 100% !important;
        width: 100% !important;
        margin: 0 auto !important;
    }

    /* kartu info alamat/telepon/email ikut rapi */
    .contact-detail .d-flex.bg-light {
        padding: 12px !important;
        align-items: center;
    }

    /* ---------- Kalender FullCalendar ---------- */
    #calendar1,
    .fc {
        font-size: 12px;
    }

    .fc .fc-toolbar.fc-header-toolbar {
        flex-wrap: wrap;
        gap: 6px;
        justify-content: center !important;
    }

    .fc .fc-toolbar-title {
        font-size: 1rem !important;
    }

    .fc .fc-button {
        padding: 0.25rem 0.55rem;
        font-size: 0.78rem;
    }

    .fc .fc-daygrid-event {
        font-size: 10px;
        padding: 1px 2px;
    }

    .fc-theme-standard td,
    .fc-theme-standard th {
        padding: 1px;
    }

    /* ---------- Ikon layanan tidak raksasa ---------- */
    .services-content-icon i.fa-7x {
        font-size: 3.1rem !important;
    }

    .services-content-icon p {
        margin-bottom: 0.75rem !important;
    }

    /* ---------- Nomor proyek / fasilitas ---------- */
    .project-content h1 {
        font-size: 1.35rem !important;
    }

    .project-content p {
        font-size: 0.85rem !important;
    }

    /* ---------- Seksi Tentang: foto tumpang-tindih jadi susun ---------- */
    .h-100.position-relative > img.img-fluid {
        width: 100% !important;
        margin-bottom: 0 !important;
        border-radius: 16px;
    }

    .h-100.position-relative > div.position-absolute {
        position: static !important;
        width: 100% !important;
        margin-top: -56px;
        padding: 0 22px;
    }

    .h-100.position-relative > div.position-absolute img {
        border: 6px solid #fff;
        border-radius: 16px !important;
        box-shadow: 0 10px 26px rgba(16, 32, 77, 0.14);
    }

    /* ---------- Kartu tim / pimpinan ---------- */
    .team-carousel .team-item,
    .team-item {
        max-width: 320px;
        margin-left: auto;
        margin-right: auto;
    }

    .team-img {
        max-width: 150px;
        margin-left: auto;
        margin-right: auto;
    }

    .team-icon {
        display: none !important; /* sosial media kosong tidak perlu di app */
    }

    /* ---------- Testimoni ---------- */
    .testimonial-carousel .testimonial-item {
        max-width: 92%;
        margin-left: auto;
        margin-right: auto;
    }

    .testimonial-item img {
        width: 56px;
        height: 56px;
        object-fit: cover;
        border-radius: 50%;
    }

    /* ---------- Galeri: grid 2 kolom + lightbox nyaman ---------- */
    .thumbnails-container .row > .col-12 {
        flex: 0 0 50%;
        max-width: 50%;
    }

    .thumbnail {
        height: 140px !important;
        width: 100%;
        object-fit: cover;
        border-radius: 14px !important;
    }

    .gallery-modal .close,
    .modal > span.close,
    span.close {
        top: 8px !important;
        right: 10px !important;
        font-size: 34px !important;
        line-height: 1;
        padding: 6px 12px;
        text-shadow: 0 1px 4px rgba(0,0,0,0.8);
    }

    a.prev, a.next {
        padding: 20px 14px !important;
        font-size: 20px !important;
    }

    iframe.modal-image {
        width: 92vw !important;
        height: calc(92vw * 9 / 16) !important;
        max-width: none !important;
        max-height: none !important;
    }

    video.modal-image {
        max-width: 94vw !important;
        max-height: 70vh !important;
    }

    /* ---------- Modal gambar besar (struktur/tupoksi) ---------- */
    #popupGambar .modal-dialog {
        max-width: 96vw;
        margin: 1rem auto;
    }

    #popupGambar .modal-body img {
        max-height: 76vh;
        object-fit: contain;
    }

    /* ---------- Formulir kritik & saran ---------- */
    main#konten-utama section.container {
        background: var(--app-surface);
        border-radius: 20px;
        box-shadow: 0 6px 18px rgba(16, 32, 77, 0.06);
        margin-top: 1.25rem;
        padding: 1.5rem 1.25rem !important;
    }

    .form-section-title {
        display: flex;
        align-items: center;
        gap: 8px;
    }

    .form-section-title::before {
        content: "";
        width: 4px;
        height: 18px;
        border-radius: 4px;
        background: var(--app-primary);
    }

    /* ---------- Strip warna beranda lebih ramping ---------- */
    .color-strip {
        height: 12px;
    }

    /* ---------- Blog "Selengkapnya" bar ---------- */
    .blog-coment {
        border-radius: 0 0 18px 18px !important;
    }

    /* ---------- Detail halaman (detail tempat/artikel) ---------- */
    .blog-item img.rounded-top {
        aspect-ratio: 16 / 10;
        object-fit: cover;
    }

    .blog-item img[width="80"] {
        width: 64px !important;
        height: 64px;
        object-fit: cover;
    }
}



/* ============================================================
   KOMPAKSI PONSEL (<768px) - grid kartu 2 kolom gaya aplikasi
   ============================================================ */
@media (max-width: 767.98px) {

    /* ---------- Grid kartu: paksa 2 kolom ---------- */
    .blog .row > .col-lg-6,
    .services-inner > .col-md-6,
    .project .row > .col-md-6,
    .team .row.g-4 > .col-lg-3,
    .team .row.g-5 > .col-xl-4,
    .row.g-5.justify-content-center > .col-lg-4.col-xl-4 {
        flex: 0 0 50%;
        max-width: 50%;
    }

    /* gutter & jarak seksi lebih rapat */
    .g-4, .g-5 {
        --bs-gutter-x: 0.75rem;
        --bs-gutter-y: 0.75rem;
    }

    .container-fluid.py-5:not(.page-header),
    .container.py-5:not(.page-header) {
        padding-top: 1.25rem !important;
        padding-bottom: 1.25rem !important;
    }

    /* tombol lebih ramping */
    .btn {
        min-height: 40px;
    }

    /* ---------- Kartu artikel/blog ---------- */
    .blog-item img.rounded-circle {
        width: 44px !important;
        height: 44px !important;
        border-width: 3px !important;
        margin-bottom: 6px !important;
    }

    .blog-item .blog-content {
        margin-top: -30px !important;
        padding-left: 8px !important;
        padding-right: 8px !important;
    }

    .blog-item .blog-content h5 {
        font-size: 0.9rem !important;
        line-height: 1.3;
        display: -webkit-box;
        -webkit-line-clamp: 2;
        -webkit-box-orient: vertical;
        overflow: hidden;
    }

    .blog-item .blog-content p {
        font-size: 0.78rem;
        padding-top: 4px !important;
        padding-bottom: 6px !important;
    }

    .blog-item img.rounded-top {
        aspect-ratio: 16 / 11;
        object-fit: cover;
    }

    .blog-item span.position-absolute {
        font-size: 11px !important;
        padding: 4px 12px !important;
        top: -14px !important;
        right: 10px !important;
    }

    .blog-coment {
        padding-top: 5px !important;
        padding-bottom: 5px !important;
    }

    .blog-coment small {
        font-size: 11px !important;
    }

    /* ---------- Kartu layanan ---------- */
    .services-item .p-4 {
        padding: 0.75rem !important;
    }

    .services-content-icon i.fa-7x {
        font-size: 2rem !important;
        margin-bottom: 8px !important;
    }

    .services-content-icon h4 {
        font-size: 0.85rem !important;
    }

    .services-content-icon p {
        display: none; /* deskripsi panjang disembunyikan agar kartu ringkas */
    }

    /* ---------- Kartu fasilitas/pengelolaan ---------- */
    .project-content h1 {
        font-size: 1.1rem !important;
    }

    .project-content p {
        font-size: 0.72rem !important;
    }

    /* ---------- Kartu tim/pimpinan ---------- */
    .team-item {
        max-width: none !important;
    }

    .team-img {
        max-width: 92px;
    }

    .team-name h4 {
        font-size: 0.85rem !important;
    }

    .team-name p {
        font-size: 0.75rem !important;
    }

    /* ---------- Statistik pengunjung: 3 mini sebaris ---------- */
    .statistik-row {
        display: flex;
        gap: 6px;
    }

    .statistik-row > * {
        flex: 1 1 0;
        max-width: 33.333%;
        margin-bottom: 0 !important;
        padding-left: 0;
        padding-right: 0;
    }

    .statistik-row .card-stats .card-body {
        padding: 8px 10px;
    }

    .statistik-row .card-stats .card-title {
        font-size: 0.62rem !important;
    }

    .statistik-row .card-stats .display-4 {
        font-size: 1.35rem !important;
    }

    .statistik-row .card-stats i.bi {
        display: none;
    }

    /* ---------- Galeri makin ringkas ---------- */
    .thumbnail {
        height: 118px !important;
    }
}

/* Ponsel sangat kecil: tetap 2 kolom, elemen ekstra rapat */
@media (max-width: 379.98px) {
    .blog-item .blog-content h5 {
        font-size: 0.82rem !important;
    }

    .statistik-row .card-stats .display-4 {
        font-size: 1.15rem !important;
    }

    .statistik-row .card-stats .card-title {
        font-size: 0.56rem !important;
    }
}


/* Kartu Jadwal Sarana: tampil 1 baris penuh di ponsel */
@media (max-width: 767.98px) {
    .blog .row > .col-jadwal {
        flex: 0 0 100%;
        max-width: 100%;
    }

    .blog .row > .col-jadwal .card-body {
        padding-left: 12px;
        padding-right: 12px;
    }
}


/* ============================================================
   KONTAK KOMPAK (alamat, YouTube, Instagram)
   Berlaku di semua layar < 1200px agar tidak lagi meniru
   susunan desktop yang sekadar diperkecil.
   ============================================================ */
@media (max-width: 1199.98px) {

    /* Kartu info: Alamat / Telepon / Email ditumpuk 1 kolom */
    .contact-detail .row.mb-5 > .col-xl-4,
    .contact-detail .row.mb-5 > .col-lg-6 {
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

    .contact-detail .d-flex.bg-light {
        padding: 10px 14px !important;
        border-radius: 12px !important;
        align-items: center;
        margin-bottom: 8px;
    }

    .contact-detail h4.text-primary {
        font-size: 0.72rem !important;
        text-transform: uppercase;
        letter-spacing: 0.05em;
        margin-bottom: 2px !important;
    }

    .contact-detail a.h5 {
        font-size: 0.92rem !important;
        word-break: break-word;
    }

    /* YouTube & Instagram: selalu 2 baris penuh, bergaya kartu */
    .contact-detail .row.g-5:not(.mb-5) > .col-lg-6 {
        flex: 0 0 100% !important;
        max-width: 100% !important;
    }

    .contact-map {
        padding: 10px !important;
        margin-bottom: 14px;
        background: #ffffff !important;
        border-radius: 16px !important;
        box-shadow: 0 6px 18px rgba(16, 32, 77, 0.07);
    }

    .contact-map iframe {
        width: 100% !important;
        height: auto !important;
        aspect-ratio: 16 / 9;
        border-radius: 10px;
        display: block;
    }

    .contact-form {
        padding: 10px !important;
        background: #ffffff !important;
        border-radius: 16px !important;
        box-shadow: 0 6px 18px rgba(16, 32, 77, 0.07);
        overflow-x: hidden;
    }

    /* Embed Instagram: paksa pas di dalam kartu (lawan gaya inline IG) */
    .contact-form > *,
    .contact-form iframe,
    .contact-form blockquote,
    .contact-form blockquote.instagram-media,
    .contact-form .instagram-media {
        display: block;
        width: 100% !important;
        max-width: 100% !important;
        min-width: 0 !important;
        margin: 0 auto !important;
    }

    .contact-form iframe {
        border: 0 !important;
        border-radius: 10px;
    }
}


/* ============================================================
   LOGO RATA KIRI DI PONSEL (<768px)
   ============================================================ */
@media (max-width: 767.98px) {

    /* Banner carousel beranda: logo + teks sambutan ke kiri */
    .carousel-caption .carousel-content {
        text-align: left;
    }

    .carousel-caption .carousel-content img[alt="Logo"] {
        display: block !important;
        margin-left: 0 !important;
        margin-right: auto !important;
        max-width: 38% !important;
    }

    /* Footer: logo & seluruh baris bawah rata kiri */
    footer.bg-primary .row {
        text-align: left !important;
    }

    footer.bg-primary img[alt="Logo Bagian Umum"] {
        display: block;
        margin-left: 0;
        margin-right: auto;
    }

    /* App bar atas: pastikan logo menempel kiri */
    .navbar-brand img.logo-img {
        margin: 0;
    }
}
