/* ==========================================
   PREFIX KHUSUS: EXPLORE SUNDA CULTURE INTERFACE
   ========================================== */

.culture-p-section {
    /* align background with timeline theme */
    --navy-deep: #0d2340;
    --navy: #a1ac9e;
    --gold: #D4A574;
    --cream: #f6efe3;
    background-color: var(--navy-deep);
    background-repeat: repeat;
    background-size: 260px;
    color: var(--cream);
    width: 100%;
    position: relative;
}

.culture-p-container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 70px 50px 70px 50px;
    text-align: center;
}


/* --- HERO COVER BANNER ATAS --- */

.culture-p-hero {
    background-size: cover;
    background-position: center;
    padding: 60px 0 40px 0;
    color: #ffffff;
    box-shadow: inset 0 120px 160px rgba(13, 35, 64, 0.6);
}

.culture-p-breadcrumb {
    font-size: 12px;
    opacity: 0.7;
    margin-bottom: 16px;
}

.culture-p-hero h1 {
    font-size: clamp(2rem, 5vw, 3.2rem);
    font-weight: 700;
    margin-bottom: 12px;
    line-height: 1.2;
}

.culture-p-subtitle {
    color: rgba(255, 255, 255, 0.85);
    line-height: 1.6;
    margin-bottom: 30px;
}

.culture-p-search-box {
    display: flex;
    gap: 12px;
    max-width: 550px;
    margin: 0 auto;
}

.culture-p-input-wrap {
    position: relative;
    flex-grow: 1;
}

.culture-p-search-icon {
    position: absolute;
    left: 18px;
    top: 50%;
    transform: translateY(-50%);
    color: #A0AEC0;
}

.culture-p-input-wrap input {
    width: 100%;
    padding: 14px 16px 14px 48px;
    border-radius: 30px;
    border: none;
    font-size: 13px;
    outline: none;
    color: #031828;
}

.culture-p-btn-filter-top {
    background: #ffffff;
    color: #031828;
    border: none;
    padding: 0 24px;
    border-radius: 30px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
}


/* --- TAB BAR KATEGORI HORIZONTAL */

.culture-p-tabs-bar {
    background: #ffffff;
    border-bottom: 1px solid #edf2f9;
    padding: 14px 0;
}

.culture-p-tabs-flex {
    display: flex;
    justify-content: space-between;
    overflow-x: auto;
    gap: 16px;
}

.culture-p-tabs-flex::-webkit-scrollbar {
    height: 0px;
}

.culture-p-tab {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 6px 14px;
    border-radius: 12px;
    cursor: pointer;
    border: 1px solid transparent;
}

.culture-p-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 13px;
}

.c-blue {
    background: #EBF3FF;
    color: #2F80ED;
}

.c-purple {
    background: #EEF2FA;
    color: #9B51E0;
}

.c-green {
    background: #EAF7EE;
    color: #27AE60;
}

.c-orange {
    background: #FFF3EB;
    color: #E67E22;
}

.c-cyan {
    background: #E0F7FA;
    color: #00ACC1;
}

.c-red {
    background: #FDF0F2;
    color: #EB5757;
}

.c-yellow {
    background: #FEF9E7;
    color: #F1C40F;
}

.c-pink {
    background: #FCE4EC;
    color: #EC407A;
}

.c-indigo {
    background: #E8EAF6;
    color: #3F51B5;
}

.culture-p-tab-txt strong {
    display: block;
    font-size: 12px;
    color: #4A5568;
    white-space: nowrap;
}

.culture-p-tab-txt small {
    font-size: 10px;
    color: #A0AEC0;
}

.culture-p-tab.active,
.culture-p-tab:hover {
    background: #f8fafc;
    border-color: #E2E8F0;
}

.culture-p-tab.active .culture-p-tab-txt strong {
    color: #0056fb;
}


/* --- GRID LAYOUT (TANPA SIDEBAR) --- */

.culture-p-grid-split {
    display: grid;
    grid-template-columns: 1fr;
    gap: 32px;
    align-items: start;
}


/* ==========================================
   GRID CONTENT COMPONENT (KANAN)
   ========================================== */


/*.culture-p-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
}

.culture-p-meta-info strong {
    font-size: 15px;
    color: #031828;
    font-weight: 700;
    display: block;
    margin-bottom: 2px;
}

.culture-p-meta-info span {
    font-size: 12px;
    color: #718096;
}

.culture-p-sort-actions {
    display: flex;
    align-items: center;
    gap: 8px;
}

.culture-p-sort-actions span {
    font-size: 12px;
    color: #718096;
}

.culture-p-sort-select {
    border: 1px solid #E2E8F0;
    padding: 6px 12px;
    border-radius: 8px;
    font-size: 12px;
    color: #031828;
    background: #ffffff;
    font-weight: 500;
    outline: none;
}

.culture-p-view-btn {
    width: 32px;
    height: 32px;
    border-radius: 6px;
    border: 1px solid #E2E8F0;
    background: #ffffff;
    color: #A0AEC0;
    cursor: pointer;
    font-size: 11px;
}

.culture-p-view-btn.active {
    color: #0056fb;
    border-color: #0056fb;
}


/* Grid 4 Kolom Kartu Budaya Sejajar */

.culture-p-cards-grid {
    padding-top: 32px;
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}


/* Featured quick links below hero to reduce visual emptiness */

.culture-p-featured {
    display: flex;
    gap: 16px;
    max-width: 980px;
    margin: 18px auto 0;
    padding: 0 24px;
}

.culture-p-featured .feat {
    background: rgba(255, 255, 255, 0.06);
    border-radius: 12px;
    padding: 12px 16px;
    flex: 1;
    color: #e6eef8;
}

.culture-p-featured .feat h4 {
    margin-bottom: 6px;
    font-size: 15px;
}

.culture-p-featured .feat p {
    font-size: 13px;
    color: #cbdaf0;
}


/* Modal for expanded card */

.culture-modal {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(4, 11, 25, 0.6);
    z-index: 9999;
}
#cultureModalOverlay {
    display: none; /* Tersembunyi di awal */
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 9999;
    justify-content: center;
    align-items: center;
}

.culture-modal.open {
    display: flex;
}

.culture-modal .modal-card {
    width: min(920px, 94%);
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.02), rgba(255, 255, 255, 0.03));
    border-radius: 14px;
    overflow: hidden;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
}

.culture-modal .modal-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.culture-modal .modal-body {
    padding: 20px;
    color: #e6eef8;
}

.culture-modal .modal-close {
    position: absolute;
    top: 18px;
    right: 22px;
    background: transparent;
    border: none;
    color: #fff;
    font-size: 20px;
    cursor: pointer;
}

.culture-p-card-item {
    background: #ffffff;
    border-radius: 18px;
    overflow: hidden;
    border: 1px solid #edf2f9;
    display: flex;
    flex-direction: column;
    position: relative;
    padding-bottom: 50px;
    /* Ruang kosong untuk letak tombol panah di bawah */
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.culture-p-card-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(3, 24, 40, 0.04);
}

.culture-p-card-media {
    position: relative;
    height: 140px;
    overflow: hidden;
}

.culture-p-card-media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.culture-p-badge {
    position: absolute;
    top: 12px;
    left: 12px;
    font-size: 9px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 6px;
    color: #ffffff;
}

.b-blue {
    background: #2F80ED;
}

.b-red {
    background: #EB5757;
}

.b-green {
    background: #27AE60;
}

.b-orange {
    background: #E67E22;
}

.b-cyan {
    background: #00ACC1;
}

.b-yellow {
    background: #F1C40F;
}

.b-pink {
    background: #EC407A;
}

.b-indigo {
    background: #3F51B5;
}

.culture-p-card-info {
    padding: 16px;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.culture-p-card-info h3 {
    font-size: 13px;
    color: #031828;
    font-weight: 700;
    margin-bottom: 6px;
    line-height: 1.4;
}

.culture-p-card-info p {
    font-size: 11px;
    color: #7F8C8D;
    line-height: 1.5;
    margin-bottom: 12px;
}


/*.culture-p-rating-row {
    margin-top: auto;
    display: flex;
    align-items: center;
}

.c-star-rating {
    font-size: 11px;
    font-weight: 700;
    color: #031828;
}


/* Tombol Panah Aksi Kanan Bawah Kartu */

.culture-p-arrow-btn {
    position: absolute;
    bottom: 16px;
    right: 16px;
    background: none;
    border: none;
    color: #A0AEC0;
    font-size: 14px;
    cursor: pointer;
    transition: color 0.2s ease, transform 0.2s ease;
}

.culture-p-card-item:hover .culture-p-arrow-btn {
    color: #0056fb;
    transform: translateX(3px);
}


/* Pagination Halaman */

.culture-p-pagination {
    display: flex;
    gap: 6px;
    justify-content: center;
    margin-top: 40px;
}

.c-pag-btn,
.c-pag-arrow,
.c-pag-num {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid #E2E8F0;
    background: #ffffff;
    color: #4A5568;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.c-pag-num.active {
    background: #0056fb;
    color: #ffffff;
    border-color: #0056fb;
}

.c-pag-dots {
    font-size: 12px;
    color: #A0AEC0;
    align-self: center;
    padding: 0 4px;
}


/* --- RESPONSIVITAS GRID ADAPTIF (ANTI-PECAH) --- */

@media (max-width: 1200px) {
    .culture-p-grid-split {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .culture-p-cards-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 992px) {
    .culture-p-grid-split {
        grid-template-columns: 1fr;
    }

    .culture-p-cards-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .culture-p-cards-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .culture-p-toolbar {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }

    .culture-p-sort-actions {
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 520px) {
    .culture-p-cards-grid {
        grid-template-columns: 1fr;
    }

    .culture-p-search-box {
        flex-direction: column;
    }

    .culture-p-btn-filter-top {
        padding: 12px 0;
        justify-content: center;
    }
}

.culture-modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(3, 24, 40, 0.6);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.culture-modal-overlay.active {
    display: flex;
}

.culture-modal-card {
    background: #ffffff;
    border-radius: 20px;
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    display: grid;
    grid-template-columns: 1fr 1.3fr;
    position: relative;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.3);
}

.culture-modal-close {
    position: absolute;
    top: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: none;
    background: #ffffff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
    font-size: 16px;
    cursor: pointer;
    z-index: 5;
}

.culture-modal-image {
    position: relative;
    background: #eee;
    min-height: 280px;
}

.culture-modal-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.culture-modal-badge {
    position: absolute;
    top: 16px;
    left: 16px;
    background: #2F80ED;
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    padding: 5px 14px;
    border-radius: 8px;
    z-index: 3;
}

.culture-modal-content {
    padding: 32px;
}

.culture-modal-content h2 {
    font-size: 26px;
    color: #031828;
    margin-bottom: 12px;
}

.culture-modal-desc {
    font-size: 14px;
    color: #5A738E;
    line-height: 1.7;
    margin-bottom: 20px;
}

.culture-modal-list-wrap hr {
    border: none;
    border-top: 1px solid #edf2f9;
    margin-bottom: 20px;
}

.culture-modal-list-wrap h4 {
    font-size: 15px;
    color: #031828;
    margin-bottom: 14px;
}

.culture-modal-list {
    list-style: none;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px 8px;
}

.culture-modal-list li {
    font-size: 13px;
    color: #5A738E;
    display: flex;
    gap: 6px;
}

.culture-modal-list li .term {
    color: #031828;
    font-weight: 600;
    min-width: 110px;
}

.culture-modal-btn-close {
    margin-top: 24px;
    background: none;
    border: none;
    color: #2F80ED;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
}

@media (max-width: 700px) {
    .culture-modal-card {
        grid-template-columns: 1fr;
    }

    .culture-modal-image {
        min-height: 180px;
    }

    .culture-modal-list {
        grid-template-columns: 1fr;
    }
}

/* ==========================================
   MOBILE SLIDER UNTUK GRID BUDAYA
   ========================================== */
@media (max-width: 992px) {
    .culture-p-cards-grid {
        display: flex;
        overflow-x: auto;
        scroll-snap-type: x mandatory;
        gap: 16px;
        padding-bottom: 24px;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: none;
        /* Firefox */
    }

    .culture-p-cards-grid::-webkit-scrollbar {
        display: none;
        /* Safari dan Chrome */
    }

    .culture-p-card-item {
        min-width: 75vw;
        scroll-snap-align: start;
        flex-shrink: 0;
    }
}