.bom-section {
    background-color: #f9f9f9;
    padding: 40px 0px;
    width: 100%;
}

.bom-header {
    margin-bottom: 30px;
    text-align: center;
}

.bom-header h2 {
    color: #4a4a4a;
    font-size: 2rem;
    font-weight: 800;
    line-height: 1;
    margin: 0;
    margin-bottom: 30px;
}

.bom-header h2 span {
    color: #e51d27;
}

/* Styling Grup per Kategori */
.bom-category-group {
    margin-bottom: 60px;
}

.bom-category-title {
    margin-bottom: 25px;
    text-align: center;
}

.bom-category-title h3 {
    font-size: 1.8rem;
    font-weight: 700;
    color: #2a2a2a;
    position: relative;
    display: inline-block;
    padding-bottom: 10px;
}

.bom-category-title h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 60px;
    height: 3px;
    background-color: #e51d27;
    border-radius: 2px;
}

/* Flexbox Grid */
.bom-grid {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 30px;
}

/* Layout Desktop: 3 Kolom */
.bom-card {
    position: relative;
    width: calc((100% - 60px) / 3);
    flex-shrink: 0;
    height: 480px;
    overflow: hidden;
    background-color: #d9d9d9;
    cursor: pointer;
    border-radius: 8px;
}

.bom-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
    transition: transform 0.5s ease;
}

.bom-card:hover img {
    transform: scale(1.05);
}

.bom-info {
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    background: linear-gradient(
        to bottom,
        transparent 0%,
        rgba(0, 0, 0, 0.85) 100%
    );
    padding: 60px 25px 25px 25px;
    color: #ffffff;
    box-sizing: border-box;
}

.bom-info h4 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 5px;
}

.bom-info p {
    font-size: 0.85rem;
    font-weight: 400;
    margin: 0;
    color: #e0e0e0;
}

/* Modal Background Overlay */
.bom-modal-overlay {
    position: fixed;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.75);
    backdrop-filter: blur(5px);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.35s ease, visibility 0.35s ease;
    box-sizing: border-box;
}

.bom-modal-overlay.is-open {
    opacity: 1;
    visibility: visible;
}

/* Container Utama Modal Window */
.bom-modal-container {
    width: 100%;
    max-width: 1000px;
    background-color: #ffffff;
    border-radius: 20px;
    overflow: hidden;
    display: grid;
    grid-template-columns: 48% 52%;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.3);
    transform: scale(0.92);
    transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
    height: 85vh;
    max-height: 560px;
}

.bom-modal-overlay.is-open .bom-modal-container {
    transform: scale(1);
}

.bom-modal-left {
    background: radial-gradient(circle at center, #555555 0%, #1a1a1a 100%);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    overflow: hidden;
    position: relative;
}

.bom-modal-left img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: top center;
}

.bom-modal-right {
    position: relative;
    background-color: #ffffff;
    padding: 50px 45px 40px;
    display: flex;
    flex-direction: column;
    height: 100%;             /* Pastikan mengisi tinggi modal penuh */
    box-sizing: border-box;
    overflow: hidden !important; /* Tutup scroll di container utama agar tidak terbelah */
}

.bom-modal-right::after {
    content: "";
    position: absolute;
    top: -30px;
    right: -30px;
    width: 260px;
    height: 260px;
    background-image: url("assets/global/images/stroke.png");
    background-size: contain;
    background-repeat: no-repeat;
    opacity: 0.12;
    pointer-events: none;
    z-index: 1;
}

.bom-modal-right::-webkit-scrollbar {
    width: 4px;
    height: 0px;
}

.bom-modal-right::-webkit-scrollbar-thumb {
    background: #cccccc;
    border-radius: 4px;
}

.bom-modal-close {
    top: 15px;
    left: 15px;
    background: rgba(255, 255, 255, 0.8);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.bom-modal-close {
    position: absolute;
    top: 25px;
    left: auto;
    right: 15px;
    background: none;
    border: none;
    font-size: 1.25rem;
    color: #333333;
    cursor: pointer;
    z-index: 10;
    transition: transform 0.2s ease, color 0.2s ease;
}
.bom-modal-close i::before {
    content: "\f00d";
}

.bom-modal-close:hover {
    transform: translateX(-3px);
    color: #e51d27;
}

.bom-modal-content {
    position: relative;
    z-index: 2;
    display: flex;
    flex-direction: column;
    height: 100%;             /* Penuhi area bom-modal-right */
    min-height: 0;            /* KUNCI: Izinkan flex child mengecil agar scroll bekerja */
    overflow: hidden;
}

.bom-modal-content h2 {
    font-size: 1.85rem;
    font-weight: 800;
    color: #1a1a1a;
    margin-bottom: 4px;
    line-height: 1.2;
    flex-shrink: 0;
}

.bom-modal-content h4 {
    font-size: 1.05rem;
    font-weight: 700;
    color: #e51d27;
    margin-bottom: 25px;
    flex-shrink: 0;
}

.bom-modal-bio-text {
    flex: 1;                  /* Otomatis penuhi sisa ruang kosong di bom-modal-content */
    min-height: 0;            /* KUNCI: Wajib ada agar overflow-y bisa aktif di Flexbox */
    overflow-y: auto !important; /* Aktifkan scroll saat teks lebih panjang dari sisa ruang */
    padding-right: 10px;      /* Jarak aman agar scrollbar tidak menutupi huruf */
}

/* Kustomisasi tampilan scrollbar pada bio text */
.bom-modal-bio-text::-webkit-scrollbar {
    width: 5px;
}

.bom-modal-bio-text::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.bom-modal-bio-text::-webkit-scrollbar-thumb {
    background: #cccccc;
    border-radius: 4px;
}

.bom-modal-bio-text::-webkit-scrollbar-thumb:hover {
    background: #e51d27;
}

.bom-modal-content p {
    font-size: 0.88rem;
    color: #777777;
    line-height: 1.65;
    font-weight: 400;
    margin: 0;
}

body:has(.bom-modal-overlay.is-open) {
    overflow: hidden !important;
}

@media (max-width: 1024px) { 
    .bom-section {
        padding: 30px 0;
    }
    .bom-header h2 {
        font-size: 1.8rem;
    }
    .bom-header {
        margin-bottom: 30px;
    }
    .bom-info h4 {
        font-size: 1.2rem;
    }
    .bom-info p {
        font-size: 0.8rem;
    }
    .bom-modal-content h2 {
        font-size: 1.8rem;
    }
    .bom-modal-content h4 {
        font-size: 1rem;
    }
    .bom-modal-content p {
        font-size: 0.85rem;
    }
} 
@media (max-width: 900px) { 
    .bom-grid {
        gap: 20px;
    }
    .bom-card {
        width: calc((100% - 20px) / 2); /* 2 Kolom di Tablet */
        height: 400px;
    }
    .bom-section {
        padding: 20px 0;
    }
    .bom-header h2 {
        font-size: 1.6rem;
    }
    .bom-header {
        margin-bottom: 30px;
    }
    .bom-info h4 {
        font-size: 1.15rem;
        font-weight: 700;
        margin-bottom: 5px;
    }
    .bom-info p {
        font-size: 0.75rem;
        font-weight: 400;
        margin: 0;
        color: #e0e0e0;
    }
    .bom-modal-content h2 {
        font-size: 1.75rem;
    }
    .bom-modal-content h4 {
        font-size: 0.95rem;
    }
    .bom-modal-content p {
        font-size: 0.8rem;
    }
} 
@media (max-width: 800px) { 
    .bom-card {
        height: 300px;
    }
    .bom-section {
        padding: 20px 0;
    }
    .bom-header h2 {
        font-size: 1.6rem;
    }
    .bom-header {
        margin-bottom: 30px;
    }
    .bom-modal-content h2 {
        font-size: 1.5rem;
    }
    .bom-modal-content h4 {
        font-size: 0.9rem;
    }
    .bom-modal-content p {
        font-size: 0.75rem;
    }
} 
@media (max-width: 768px) { 
    .bom-card {
        height: 300px;
    }
    .bom-header h2 {
        font-size: 1.6rem;
    }
    .bom-header {
        margin-bottom: 30px;
    }
    .bom-header {
        margin-bottom: 30px;
    }
    .bom-info h4 {
        font-size: 1.15rem;
    }
    .bom-info p {
        font-size: 0.75rem;
    }
} 
@media (max-width: 600px) { 
    .bom-card {
        width: 100%;
        height: 420px;
    }
    .bom-header h2 {
        font-size: 1.4rem;
    }
    .bom-section {
        padding: 20px 0;
    }
    .bom-header {
        margin-bottom: 30px;
    }
    .bom-info h4 {
        font-size: 1.25rem;
    }
    .bom-info p {
        font-size: 0.85rem;
    }
    .bom-modal-container {
        grid-template-columns: 1fr;
        height: 85vh;
        max-height: 700px;
        overflow-y: auto;
        border-radius: 12px;
    }

    .bom-modal-left {
        height: 340px;
    }

    .bom-modal-right {
        padding: 30px 25px;
        justify-content: flex-start;
    }
} 
@media (max-width: 480px) { 
    .bom-header h2 {
        font-size: 1.2rem;
    }
}
@media (max-width: 419px) { 
    .bom-header h2 {
        font-size: 1.2rem;
    }
}