/* =========================================
   STYLING TABS TAHUN
   ========================================= */
.year-tabs { 
    display: flex; 
    justify-content: center; 
    gap: 15px; 
    margin-bottom: 40px; 
    border-bottom: 2px solid #e2e8f0; 
    padding-bottom: 15px; 
}

.tab-btn { 
    background: transparent; 
    border: none; 
    padding: 10px 30px; 
    font-size: 1.1rem; 
    font-weight: 600; 
    color: #64748b; 
    cursor: pointer; 
    border-radius: 30px; 
    transition: 0.3s; 
}

.tab-btn.active { 
    background: var(--primary); 
    color: white; 
    box-shadow: 0 4px 10px rgba(4, 120, 87, 0.2); 
}

.tab-btn:hover:not(.active) { 
    background: #f1f5f9; 
}

.year-content { 
    display: none; 
    animation: fadeEffect 0.5s; 
}

.year-content.active-content { 
    display: block; 
}

@keyframes fadeEffect { 
    from { opacity: 0; } 
    to { opacity: 1; } 
}

/* =========================================
   HEADER TIAP TAHUN & BADGE TOTAL JUARA
   ========================================= */
.year-header-wrapper { 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    margin-bottom: 30px; 
}

.year-title { 
    font-size: 2rem; 
    color: var(--dark-navy); 
    margin-bottom: 5px; 
}

.total-badge { 
    display: flex; 
    align-items: center; 
    gap: 15px; 
    background: white; 
    padding: 15px 25px; 
    border-radius: 12px; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.05); 
    border: 1px solid #f1f5f9; 
}

.total-icon { 
    font-size: 2rem; 
    color: var(--gold); 
}

.total-text strong { 
    font-size: 1.4rem; 
    color: var(--dark-navy); 
    display: block; 
    line-height: 1; 
}

.total-text span { 
    font-size: 0.85rem; 
    color: #64748b; 
}

/* =========================================
   GRID KARTU PRESTASI UTAMA (PERBAIKAN)
   ========================================= */
.prestasi-card-grid { 
    display: grid; 
    grid-template-columns: repeat(1, 1fr); /* Layar HP (1 Kolom) */
    gap: 25px; 
    align-items: start; /* Mencegah kartu melar ke bawah */
}

/* Layar Tablet (2 Kolom) */
@media (min-width: 768px) {
    .prestasi-card-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Layar PC/Laptop (Mutlak 3 Kolom) */
@media (min-width: 1024px) {
    .prestasi-card-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.pres-card { 
    background: white; 
    border-radius: 16px; 
    padding: 25px; 
    box-shadow: 0 4px 15px rgba(0,0,0,0.05); 
    border: 1px solid #f1f5f9; 
    display: flex; 
    flex-direction: column; 
    transition: 0.3s; 
}

.pres-card:hover { 
    transform: translateY(-5px); 
    box-shadow: 0 10px 25px rgba(0,0,0,0.08); 
}

.pres-header { 
    display: flex; 
    gap: 15px; 
    margin-bottom: 20px; 
}

.pres-icon { 
    font-size: 1.8rem; 
    color: var(--gold); 
    margin-top: 2px; 
}

.pres-name { 
    font-size: 1.15rem; 
    color: var(--dark-navy); 
    margin: 0 0 5px 0; 
}

.pres-desc { 
    font-size: 0.9rem; 
    color: #64748b; 
    line-height: 1.5; 
    margin: 0; 
}

/* =========================================
   STYLE KOLASE MINI GRID (FOTO MULTIPLE)
   ========================================= */
.pres-multi-grid {
    display: grid;
    gap: 4px;
    margin-bottom: 20px;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    max-height: 250px !important; 
}

.grid-count-1 { grid-template-columns: 1fr; }
.grid-count-1 .mini-foto-item { height: 200px !important; }

.grid-count-2 { grid-template-columns: 1fr 1fr; }
.grid-count-2 .mini-foto-item { height: 160px !important; }

.grid-count-3 { grid-template-columns: 1fr 1fr 1fr; }
.grid-count-3 .mini-foto-item { height: 140px !important; }

.grid-count-4 { grid-template-columns: 1fr 1fr; grid-template-rows: 120px 120px; }
.grid-count-4 .mini-foto-item { height: 100% !important; }

.mini-foto-item { 
    position: relative; 
    width: 100%; 
    transition: 0.3s; 
    overflow: hidden; 
}

.mini-foto-item:hover { filter: brightness(0.9); }

.mini-foto-item img { 
    width: 100% !important; 
    height: 100% !important; 
    object-fit: cover !important; 
    object-position: center !important; 
    display: block; 
}

/* --- Lightbox Prestasi: foto ditampilkan utuh (tidak crop) + transisi modern --- */
#presLightboxImg {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 30px 60px rgba(0, 0, 0, 0.6);
    transition: opacity 0.28s ease, transform 0.28s ease;
    opacity: 1;
    transform: translateX(0) scale(1);
}

/* Dipasang sesaat oleh JS sebelum ganti gambar, lalu dilepas sesudahnya,
   supaya perpindahan next/prev terasa meluncur & modern (bukan "loncat"). */
#presLightboxImg.pres-slide-left  { opacity: 0; transform: translateX(-24px) scale(0.98); }
#presLightboxImg.pres-slide-right { opacity: 0; transform: translateX(24px) scale(0.98); }

.more-overlay {
    position: absolute; inset: 0; background: rgba(0,0,0,0.6);
    color: white; display: flex; align-items: center; justify-content: center;
    font-size: 1.8rem; font-weight: 700;
}

/* =========================================
   FOOTER KARTU (TOMBOL LIHAT DOKUMENTASI)
   ========================================= */
.pres-footer { 
    margin-top: auto; 
    display: flex; 
    justify-content: space-between; 
    align-items: center; 
    border-top: 1px solid #f1f5f9; 
    padding-top: 15px; 
}

.doc-count { 
    font-size: 0.85rem; 
    color: #64748b; 
    font-weight: 500; 
}

.btn-lihat-doc { 
    background: none; 
    border: none; 
    color: var(--dark-navy); 
    font-weight: 600; 
    font-size: 0.9rem; 
    cursor: pointer; 
    transition: 0.3s; 
    font-family: inherit; 
}

.btn-lihat-doc:hover { color: var(--primary); }

/* =========================================
   RESPONSIVE LAYOUT UNTUK MOBILE (HP)
   ========================================= */
@media (max-width: 768px) {
    .year-header-wrapper { 
        flex-direction: column; 
        align-items: flex-start; 
        gap: 20px; 
    }
    
    .year-tabs { 
        flex-wrap: wrap; 
        justify-content: flex-start; 
    }
    
    .tab-btn { 
        padding: 8px 20px; 
        font-size: 1rem; 
    }
}