* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

#historySection {
    position: relative;
    height: 100vh;
    width: 100vw;
    overflow: hidden;
    display: flex;
    background-size: cover;
    background-position: center;
    transition: background-image 0.5s ease;
}

#historySection .section-title {
    position: absolute;
    top: 3rem;
    left: 2rem;
    color: white !important;
    font-size: 2.5rem;
    line-height: 2.875rem;
    font-weight: 700;
    z-index: 10;
    text-shadow: 0 0 5px rgba(0, 0, 0, 0.7) !important;
    user-select: none;
    text-transform: uppercase;
}

#historySection::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: 0;
}

/* Container utama, flex row */
#historySection .content-container {
    position: relative;
    z-index: 1;
    display: flex;
    width: 100%;
    height: 100%;
    padding: 2rem;
}

/* Detail besar kiri */
#historySection .detail-card {
    flex: 1 1 50%;
    position: absolute;
    top: 40%;
    height: 60%;
    max-height: 70vh;
    background: rgba(0, 0, 0, 0.4);
    border-radius: 16px;
    padding: 2rem;
    /* display: flex;
    flex-direction: column;
    justify-content: center; */
    backdrop-filter: blur(6px);
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.7);
    position: relative;
    overflow: hidden;
    overflow-y: auto;
    scrollbar-width: thin;
}

#historySection .detail-card .desc {
    max-height: 100%;
    white-space: normal;
}

#historySection .detail-card .arrow-icon {
    position: absolute;
    top: 1rem;
    left: 1rem;
    font-size: 1rem;
    color: white !important;
}
#historySection .detail-card .year {
    color: #fff !important;
    font-size: 1rem;
    font-weight: bold;
    margin-bottom: 0.5rem;
}
#historySection .detail-card .title {
    color: #fff !important;
    font-size: 1.3rem;
    font-weight: 800;
    margin-bottom: 1rem;
}
#historySection .detail-card .desc {
    color: #fff !important;
    font-size: 1rem;
    line-height: 1.5;
    max-width: 90%;
}

/* Container card slider bawah */
#historySection .slider-container {
    flex: 1 1 100%;
    display: flex;
    flex-direction: column;
    justify-content: end;
    padding-left: 2rem;
    position: relative;
}

/* Wrapper arrows */
#historySection .arrows {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 1rem;
    width: 100%;
}

#historySection .nav-buttons {
    display: flex;
    gap: 0.5rem;
    position: relative;
    padding-right: 1rem;
}

#historySection .nav-buttons::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 100%;
    height: 1px;
    width: 760px;
    background: white;
    transform: translateY(-50%);
}

#historySection .nav-buttons button {
    background: rgba(255, 255, 255, 0.3);
    border: none;
    color: white;
    font-size: 1.4rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s;
}

#historySection .nav-buttons button:hover {
    background: rgba(255, 255, 255, 0.6);
}

#historySection .counting {
    display: flex;
    align-items: center;
    justify-content: flex-end;
}

#historySection .counter {
    color: white;
    font-size: 3rem;
    font-weight: 600;
}

/* Card kecil */
#historySection .cards {
    display: flex;
    gap: 1rem;
    overflow-x: auto;
    padding-bottom: 5rem;
    scrollbar-width: none;
    padding-top: 2rem;
    padding-left: 2rem;
}

#historySection .cards::-webkit-scrollbar {
    display: none;
}

#historySection .card {
    flex: 0 0 auto;
    width: 19%;
    height: 177%;
    border-radius: 12px;
    background-size: cover;
    background-position: center;
    position: relative;
    cursor: pointer;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.7);
    transition: transform 0.3s ease;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    color: white !important;
    padding: 0.5rem;
}
#historySection .card:hover {
    transform: scale(1.05);
    z-index: 5;
}

.card-img {
    position: relative;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

.card-img::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.2);
}
.card-img > * {
    position: relative;
    z-index: 1;
}

/* Tanggal pojok kiri atas */
#historySection .card .year {
    /* font-weight: 700;
    background: rgba(0, 0, 0, 0.6); */
    padding: 2px 8px;
    border-radius: 8px;
    font-size: 0.85rem;
    align-self: flex-start;
}
/* Judul pojok kiri bawah */
#historySection .card .title {
    /* font-weight: 900;
    background: rgba(0, 0, 0, 0.6); */
    padding: 4px 8px;
    border-radius: 8px;
    font-size: 0.8rem;
    align-self: flex-start;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Card aktif style */
#historySection .card.active {
    outline: 3px solid #fff;
    /* box-shadow: 0 0 15px 3px #00ffff; */
    transform: scale(1.1);
    z-index: 10;
}

#historySection .detail-card::-webkit-scrollbar {
    width: 6px;
}
#historySection .detail-card::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.4);
    border-radius: 4px;
}

@media (max-width: 768px) {
    /* Hilangkan cards */
    #historySection .cards {
        display: none !important;
    }

    /* Container jadi kolom */
    #historySection .content-container {
        display: flex;
        flex-direction: column;
        gap: 1rem;
    }

    #historySection .arrows {
        display: flex;
        align-items: center; /* biar vertikal sejajar */
        justify-content: space-between; /* kiri - kanan */
        margin-bottom: 0.5rem;
        width: 100%;
    }

    #historySection .nav-buttons {
        display: flex;
        justify-content: flex-start; /* tombol tetap kiri */
        gap: 0.5rem; /* jarak antar tombol */
    }

    #historySection .counter {
        font-size: 1rem;
        font-weight: 600;
        color: #fff;
    }

    /* Detail-card di bawah arrows */
    #historySection .detail-card {
        order: 2;
        position: relative;
        top: auto;
        margin-top: 0;
        width: 100%;
        height: auto;
        padding: 1rem;
    }

    /* === FONT ADJUSTMENT === */
    #historySection .section-title {
        font-size: 1.25rem; /* lebih kecil supaya tidak menutupi layar */
        line-height: 1.5rem;
    }

    #historySection .detail-card .year {
        font-size: 0.85rem; /* tahun tetap jelas tapi tidak mendominasi */
    }

    #historySection .detail-card .title {
        font-size: 1.1rem; /* judul masih menonjol tapi ringan */
        line-height: 1.4rem;
    }

    #historySection .detail-card .desc {
        font-size: 0.9rem; /* teks nyaman dibaca di tablet/HP */
        line-height: 1.4;
    }

    #historySection .arrows button {
        font-size: 1.5rem; /* tombol lebih kecil biar tidak mengganggu */
        width: 36px;
        height: 36px;
    }

    #historySection .nav-buttons::after {
        width: 160px;
        height: 1px;
    }

    #historySection .slider-container {
        padding-left: 0;
    }
}

/* Responsif */
@media (min-width: 1440px) {
    #historySection .detail-card .year {
        color: #fff !important;
        font-size: 2rem;
        font-weight: bold;
        margin-bottom: 0.5rem;
    }

    #historySection .detail-card .title {
        color: #fff !important;
        font-size: 2rem;
        font-weight: 800;
        margin-bottom: 1rem;
    }
    #historySection .detail-card .desc {
        color: #fff !important;
        font-size: 1.5rem;
        line-height: 1.5;
        max-width: 90%;
    }

    #historySection .cards {
        padding-bottom: 12rem;
    }

    #historySection .card {
        width: 22%;
        height: 269%;
    }

    #historySection .card .title {
        font-size: 1rem;
    }

    #historySection .nav-buttons::after {
        width: 1450px;
        height: 3px;
    }
}
