/* ==========================================================================
   DAFTAR ISI (TABLE OF CONTENTS)
   1. GLOBAL VARIABLES & RESET
   2. LAYOUT & NAVIGATION
   3. HERO SECTION (SLIDESHOW)
   4. COMPONENTS (Cards, Buttons, Badges)
   5. ANIMATIONS (Fade In, Zoom)
   6. PAGE: BERANDA (Director, Facilities, Partners)
   7. PAGE: PTB (Penerimaan Taruna Baru - Connector Steps)
   8. UTILITIES (Lightbox, WhatsApp Float)
   ========================================================================== */

/* =========================================
   1. GLOBAL VARIABLES & RESET
   ========================================= */
:root {
    --primary-color: #002366;    /* Biru Maritim Deep */
    --accent-color: #ffc107;     /* Emas */
    --text-dark: #333333;
    --bg-light: #f8f9fa;
    --font-heading: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    display: flex;
    flex-direction: column;
    min-height: 100vh; /* Sticky Footer Logic */
    font-family: var(--font-heading);
    color: var(--text-dark);
}

main {
    flex: 1;
}

/* =========================================
   2. LAYOUT & NAVIGATION
   ========================================= */
/* Navbar Biru Laut */
.bg-maritim {
    background-color: var(--primary-color) !important;
    transition: 0.3s;
}

/* =========================================
   3. HERO SECTION (SLIDESHOW)
   ========================================= */
.hero-section {
    position: relative;
    overflow: hidden;
    background: var(--primary-color);
    color: white;
    padding: 100px 0;
    text-align: center;
}

.hero-overlay {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: rgba(0, 35, 102, 0.7);
    z-index: 1;
}

.slideshow-container {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    z-index: 0;
}

.slide-item {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    object-fit: cover;
    object-position: center;
    opacity: 0;
    animation: imageAnimation 25s linear infinite 0s;
}

/* Timing Slide Bergantian */
.slide-item:nth-child(1) { animation-delay: 0s; }
.slide-item:nth-child(2) { animation-delay: 5s; }
.slide-item:nth-child(3) { animation-delay: 10s; }
.slide-item:nth-child(4) { animation-delay: 15s; }
.slide-item:nth-child(5) { animation-delay: 20s; }

@keyframes imageAnimation { 
    0% { opacity: 0; animation-timing-function: ease-in; }
    4% { opacity: 1; animation-timing-function: ease-out; }
    20% { opacity: 1; transform: scale(1.05); }
    24% { opacity: 0; }
    100% { opacity: 0; }
}

.hero-content-wrapper {
    position: relative;
    z-index: 10;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* =========================================
   4. COMPONENTS (Cards, Buttons)
   ========================================= */
/* Tombol Kuning */
.btn-warning {
    background-color: var(--accent-color);
    border: none;
    color: #000;
}

.btn-warning:hover {
    background-color: #e0a800;
    color: #000;
}

/* Hover Card Effect (General) */
.hover-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    border-bottom: 4px solid transparent;
}

.hover-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.1) !important;
    border-bottom-color: var(--accent-color);
}

.hover-card:hover i {
    transform: scale(1.2);
    color: var(--primary-color) !important;
    transition: 0.3s;
}

/* Info Box (Akreditasi) */
.badge-box {
    background: white;
    padding: 20px;
    border-radius: 10px;
    border-bottom: 4px solid var(--primary-color);
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
    transition: all 0.3s ease;
    height: 100%;
    display: flex; flex-direction: column;
    justify-content: center; align-items: center;
}

.badge-box:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 30px rgba(0, 35, 102, 0.15);
    border-bottom-color: var(--accent-color);
}

.badge-title {
    font-weight: bold; font-size: 0.9rem; margin-top: 10px;
    color: #333; text-transform: uppercase; letter-spacing: 0.5px;
}

.badge-subtitle { font-size: 0.8rem; color: #666; margin-bottom: 5px; }

/* =========================================
   5. ANIMATIONS
   ========================================= */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

.animate-fade-in {
    animation: fadeInUp 1s ease-out forwards;
    opacity: 0;
}

.delay-1 { animation-delay: 0.2s; }
.delay-2 { animation-delay: 0.4s; }
.delay-3 { animation-delay: 0.6s; }

/* Pulse Effect (Tombol Berdenyut) */
.pulse-effect {
    animation: pulse 2s infinite;
}
@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* =========================================
   6. PAGE: BERANDA SPECIFIC
   ========================================= */
/* Director Section */
.section-direktur {
    background: linear-gradient(135deg, #f0f8ff 0%, #ffffff 100%);
    position: relative; overflow: hidden;
}

.section-direktur::before {
    content: "⚓";
    position: absolute; top: -50px; right: 10px;
    font-size: 20rem; color: var(--primary-color);
    opacity: 0.03; transform: rotate(20deg); z-index: 0; pointer-events: none;
}

.director-img-frame { position: relative; z-index: 1; }
.director-img-frame::before {
    content: ""; position: absolute; top: -20px; left: -20px;
    width: 100%; height: 100%; background-color: rgba(0, 35, 102, 0.1);
    border-radius: 10px; z-index: -1; transition: 0.3s;
}
.director-img-frame:hover::before {
    top: -10px; left: -10px; background-color: rgba(255, 193, 7, 0.3);
}

.director-text-box {
    padding: 30px; border-radius: 15px;
    transition: all 0.4s; border-left: 5px solid transparent;
    position: relative; z-index: 1;
}
.director-text-box:hover {
    background-color: rgba(255, 255, 255, 0.6);
    box-shadow: 0 10px 30px rgba(0, 35, 102, 0.08);
    transform: translateX(10px);
    border-left-color: var(--accent-color);
}

/* Partner Logo */
.partner-logo {
    filter: grayscale(100%); opacity: 0.6; transition: all 0.3s ease;
    max-height: 60px; width: auto;
}
.partner-logo:hover {
    filter: grayscale(0%); opacity: 1; transform: scale(1.1);
}

/* Tabs Facilities */
.nav-pills-custom .nav-link {
    color: #555; background: #f8f9fa; border: 1px solid #ddd;
    margin: 0 5px 10px 0; border-radius: 50px; padding: 10px 25px;
    font-weight: 600; transition: all 0.3s ease;
}
.nav-pills-custom .nav-link.active {
    background-color: var(--primary-color); color: #fff;
    border-color: var(--primary-color);
    box-shadow: 0 4px 10px rgba(0, 35, 102, 0.3); transform: translateY(-2px);
}

/* Sertifikat Frame */
.cert-frame {
    position: relative; padding: 10px; background: #fff;
    border: 1px solid #eaeaea; box-shadow: 0 15px 35px rgba(0,0,0,0.1);
    border-radius: 10px; transition: transform 0.4s ease;
}
.cert-frame:hover {
    transform: scale(1.02) rotate(1deg);
    box-shadow: 0 20px 40px rgba(0,0,0,0.15);
}
.cert-img {
    width: 100%; height: auto; border-radius: 5px;
    border: 1px solid #eee; cursor: zoom-in;
}

/* Checklist Style */
.check-list li {
    margin-bottom: 10px; position: relative; padding-left: 25px; color: #555;
}
.check-list li::before {
    content: '✓'; position: absolute; left: 0;
    color: var(--accent-color); font-weight: bold;
}

/* =========================================
   7. PAGE: PTB (PENERIMAAN TARUNA BARU)
   ========================================= */
/* Step Connector (Garis Putus-putus) */
.step-connector::after {
    content: ''; position: absolute;
    top: 40px; left: 50%; width: 100%; height: 2px;
    background-image: linear-gradient(to right, var(--primary-color) 50%, transparent 50%);
    background-size: 15px 2px; background-repeat: repeat-x;
    z-index: 0;
}

.no-connector::after { display: none; }

/* Responsif Alur PTB */
@media (max-width: 768px) {
    .step-connector::after { display: none; }
    .mobile-arrow { display: block !important; }
}
@media (min-width: 769px) {
    .mobile-arrow { display: none !important; }
}

/* =========================================
   8. UTILITIES (Lightbox, WhatsApp)
   ========================================= */

/* Lightbox Overlay (Container Utama) */
.lightbox-overlay {
    display: none; 
    position: fixed; 
    z-index: 9999;
    padding-top: 50px; 
    left: 0; top: 0; 
    width: 100%; height: 100%;
    background-color: rgba(0, 0, 0, 0.9); 
    backdrop-filter: blur(5px);
    flex-direction: column; 
    align-items: center; 
    justify-content: center;
}

/* Gambar di dalam Lightbox */
.lightbox-content {
    margin: auto; 
    display: block; 
    width: auto;       /* Ubah jadi auto agar rasio gambar terjaga */
    max-width: 90%;    /* Maksimal 90% lebar layar */
    max-height: 85vh;  /* Maksimal 85% tinggi layar */
    object-fit: contain; 
    border-radius: 5px;
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.2); 
    animation: zoomIn 0.3s;
}

/* Tombol Close (X) */
.close-lightbox {
    position: absolute; 
    top: 20px; right: 35px;
    color: #f1f1f1; 
    font-size: 40px; 
    font-weight: bold;
    transition: 0.3s; 
    cursor: pointer;
    z-index: 10001; /* Pastikan di atas gambar */
}

.close-lightbox:hover { 
    color: #ffc107; /* Warna aksen kuning (sesuai tema KPN/Situs) */
    text-decoration: none; 
}

/* Caption Gambar */
#caption {
    margin: auto; 
    display: block; 
    width: 80%; 
    max-width: 700px;
    text-align: center; 
    color: #ccc; 
    padding: 10px 0; 
    font-size: 1rem;
}

/* Animasi Zoom */
@keyframes zoomIn { 
    from {transform:scale(0.8); opacity: 0;} 
    to {transform:scale(1); opacity: 1;} 
}

/* =========================================
   TESTIMONIAL MOBILE SLIDER
   ========================================= */

/* Hanya berlaku di layar HP (< 768px) */
@media (max-width: 767px) {
    .overflow-hidden-mobile {
        overflow-x: auto;      /* Izinkan scroll menyamping */
        scroll-snap-type: x mandatory; /* Efek magnet saat scroll */
        -webkit-overflow-scrolling: touch; /* Scroll halus di iOS */
        padding-bottom: 20px;  /* Ruang untuk shadow card */
        scrollbar-width: none; /* Sembunyikan scrollbar (Firefox) */
    }

    .overflow-hidden-mobile::-webkit-scrollbar {
        display: none; /* Sembunyikan scrollbar (Chrome/Safari) */
    }

    .testimonial-item {
        scroll-snap-align: center; /* Posisi kartu selalu di tengah saat berhenti scroll */
        flex: 0 0 85%; /* Lebar kartu 85% dari layar agar kartu sebelah terlihat sedikit */
    }
}

/* Agar tombol navigasi berada di atas konten */
.z-2 { z-index: 2; }

/* =========================================
   TESTIMONIAL SLIDER (MOBILE & DESKTOP)
   ========================================= */

/* Container Slider */
.slider-container {
    display: flex;
    flex-wrap: nowrap; /* Wajib agar berjejer ke samping */
    overflow-x: auto;  /* Scrollable */
    scroll-snap-type: x mandatory; /* Efek magnet */
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none; /* Sembunyikan scrollbar (Firefox) */
    padding-bottom: 20px; /* Ruang untuk shadow */
    scroll-behavior: smooth;
}

.slider-container::-webkit-scrollbar {
    display: none; /* Sembunyikan scrollbar (Chrome) */
}

/* Item Slider */
.testimonial-item {
    scroll-snap-align: center;
    scroll-snap-stop: always;
    padding: 0 10px; /* Jarak antar kartu */
}

/* RESPONSIVE LOGIC */

/* Mobile (Layak Kecil): 1 Kartu Full (100%) */
@media (max-width: 767px) {
    .testimonial-item {
        flex: 0 0 100%;
        max-width: 100%;
    }
}

/* Desktop (Layar Besar): 3 Kartu (33.33%) */
@media (min-width: 768px) {
    .testimonial-item {
        flex: 0 0 33.3333%; 
        max-width: 33.3333%;
    }
}

/* Style Kartu */
.testimonial-card-large {
    border-radius: 24px;
    padding: 40px 20px; /* Padding standar */
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    position: relative;
    background: white;
}

/* Agar teks tidak ketabrak tombol navigasi */
.safe-padding {
    padding-left: 2rem;
    padding-right: 2rem;
}

/* Foto & Icon */
.testimonial-photo-large {
    width: 100px; height: 100px;
    border-radius: 50%;
    border: 4px solid white;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    object-fit: cover;
    margin-bottom: 15px;
    background-color: #eee;
}

.quote-icon-large {
    position: absolute;
    top: 20px; left: 50%;
    transform: translateX(-50%);
    font-size: 3rem;
    color: #002366;
    opacity: 0.05;
}

/* =========================================
   9. LAYOUT: NAVBAR & HEADER (Glassmorphism)
   ========================================= */
.navbar-glass {
    background: rgba(0, 35, 102, 0.95); /* Biru Navy Transparan */
    backdrop-filter: blur(10px); /* Efek Blur */
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: all 0.3s ease;
}

/* Hover Menu Effect (Garis Emas Berjalan) */
.nav-link {
    position: relative;
    font-weight: 600;
    letter-spacing: 0.5px;
    transition: color 0.3s ease;
}

.nav-link::after {
    content: '';
    position: absolute;
    width: 0;
    height: 2px;
    bottom: 0;
    left: 50%;
    background-color: var(--accent-color, #ffc107); /* Menggunakan variabel atau fallback */
    transition: all 0.3s ease;
    transform: translateX(-50%);
}

.nav-link:hover::after, 
.nav-link.active::after {
    width: 100%;
}

/* =========================================
   10. LAYOUT: FOOTER & SOCIAL MEDIA
   ========================================= */
/* Footer Mewah dengan Pola Halus */
.footer-luxury {
    background-color: #001529; /* Deep Navy */
    /* Pola SVG Halus */
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.03'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* Tombol Sosmed Bulat */
.social-btn {
    width: 40px; height: 40px;
    display: inline-flex;
    align-items: center; justify-content: center;
    border-radius: 50%;
    background: rgba(255,255,255,0.1);
    transition: 0.3s;
}

.social-btn:hover {
    background: var(--accent-color, #ffc107);
    color: #000 !important;
    transform: translateY(-3px);
}

/* Link Teks Hover di Footer */
.hover-text-warning {
    transition: all 0.3s ease;
}
.hover-text-warning:hover {
    color: var(--accent-color, #ffc107) !important;
    padding-left: 5px; /* Efek geser sedikit */
}

/* =========================================
   11. COMPONENTS: FLOATING WHATSAPP
   ========================================= */
.wa-float {
    position: fixed; 
    bottom: 30px; 
    right: 30px;
    z-index: 1000;
    background-color: #25d366; 
    color: white;
    width: 60px; height: 60px;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    font-size: 30px;
    box-shadow: 2px 2px 10px rgba(0,0,0,0.2);
    transition: transform 0.3s;
}

.wa-float:hover { 
    transform: scale(1.1); 
    color: white; 
}

/* =========================================
   NAVBAR DROPDOWN (PREMIUM STYLE)
   ========================================= */

/* Hapus border default, ganti dengan shadow halus */
.dropdown-menu {
    border: none;
    border-top: 3px solid #ffc107; /* Aksen Emas di atas */
    border-radius: 0 0 10px 10px; /* Sudut bawah membulat */
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); /* Bayangan lembut */
    padding: 0; /* Reset padding */
    overflow: hidden;
    margin-top: 10px; /* Jarak sedikit dari navbar */
}

/* Style Item Dropdown */
.dropdown-item {
    padding: 12px 20px;
    font-size: 0.9rem;
    font-weight: 500;
    color: #333;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.3s ease;
}

/* Efek Hover pada Item */
.dropdown-item:hover {
    background-color: #f8f9fa;
    color: #002366; /* Biru Navy */
    padding-left: 25px; /* Efek geser ke kanan */
    border-left: 3px solid #ffc107; /* Indikator emas di kiri */
}

.dropdown-item:last-child {
    border-bottom: none;
}

/* Tanda Panah Kecil di Navbar */
.nav-link.dropdown-toggle::after {
    margin-left: 0.4em;
    vertical-align: 0.1em;
    transition: transform 0.3s;
}

/* Putar panah saat diklik (opsional, butuh JS tambahan atau biarkan default) */
.show > .nav-link.dropdown-toggle::after {
    transform: rotate(180deg);
}

/* =========================================
   12. PAGE: AKADEMIK (PROGRAM STUDI)
   ========================================= */

/* Hero Section Gradient */
.hero-gradient-navy {
    background: linear-gradient(135deg, #001a4d 0%, #003380 100%);
    position: relative;
    overflow: hidden;
}

/* Background Pattern Titik Halus */
.pattern-dots-white {
    position: absolute;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background-image: radial-gradient(#ffffff 1px, transparent 1px);
    background-size: 30px 30px;
    opacity: 0.1;
    pointer-events: none;
}

/* Kartu Prodi dengan Efek Hover Lift */
.card-prodi {
    border: 0;
    border-top-width: 4px; /* Garis warna di atas */
    border-top-style: solid;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card-prodi:hover {
    transform: translateY(-10px); /* Efek naik */
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1) !important;
}

/* Variasi Warna Border Atas */
.border-top-navy { border-top-color: #002366; }
.border-top-red { border-top-color: #dc3545; }
.border-top-green { border-top-color: #198754; }

/* Lingkaran Icon Besar */
.icon-circle-lg {
    width: 80px; 
    height: 80px;
    display: inline-flex;
    align-items: center; 
    justify-content: center;
    border-radius: 50%;
    margin-bottom: 1.5rem;
}

.hover-card:hover .card-img-top {
    transform: scale(1.1);
}

/* =========================================
   13. SECTION: PRODI (BERANDA)
   ========================================= */

/* Garis Separator di bawah Judul */
.separator-line {
    width: 60px;
    height: 4px;
}

/* Wrapper Gambar agar ukurannya seragam */
.prodi-img-wrapper {
    height: 250px; 
    overflow: hidden;
}

/* Gambar Prodi */
.prodi-img-wrapper img {
    object-fit: cover;
    transition: transform 0.5s ease;
}

/* Efek Zoom saat Hover (Opsional, agar lebih interaktif) */
.hover-card:hover .prodi-img-wrapper img {
    transform: scale(1.1);
}

/* --- BUTTON HOVER FIXES --- */

/* Paksa teks jadi putih saat hover tombol outline primary (Biru) & danger (Merah) */
.btn-outline-primary:hover, 
.btn-outline-danger:hover {
    color: #fff !important;
}

/* Khusus KPN: Background Kuning, Teks Hitam saat Hover (agar terbaca) */
.btn-outline-warning:hover {
    background-color: #ffc107 !important;
    color: #000 !important;
}

/* =========================================
   13. SECTION: PRODI (BERANDA & AKADEMIK)
   ========================================= */

/* Garis Separator Kuning */
.separator-line {
    width: 60px;
    height: 4px;
}

/* Spacer Kosong untuk KPN (agar tinggi kartu sejajar) */
.kpn-spacer {
    height: 110px;
    padding: 1rem;
    margin-bottom: 1rem;
    margin-top: 0.5rem;
}

/* Efek Zoom Gambar saat Hover */
.hover-card:hover .card-img-top {
    transform: scale(1.1);
}

/* --- BUTTON HOVER HELPERS --- */

/* Paksa teks jadi putih saat hover (untuk tombol Biru & Merah) */
.hover-text-white:hover {
    color: #fff !important;
}

/* Khusus KPN: Background Kuning, Teks Hitam saat Hover */
.hover-bg-warning:hover {
    background-color: #ffc107 !important;
    color: #000 !important;
}

/* =========================================
   14. PAGE: DETAIL PRODI (THEMES & LIGHTBOX)
   ========================================= */

/* --- TEMA WARNA SOLID --- */
/* Nautika (Navy Blue) */
.theme-navy .text-theme { color: #002366 !important; }
.theme-navy .bg-theme { background-color: #002366 !important; }
.theme-navy .btn-theme { background-color: #002366; color: #fff; border: 2px solid #002366; }
.theme-navy .btn-theme:hover { background-color: transparent; color: #002366; }
.theme-navy .border-theme { border-color: #002366 !important; }

/* Teknika (Deep Red) */
.theme-red .text-theme { color: #dc3545 !important; }
.theme-red .bg-theme { background-color: #dc3545 !important; }
.theme-red .btn-theme { background-color: #dc3545; color: #fff; border: 2px solid #dc3545; }
.theme-red .btn-theme:hover { background-color: transparent; color: #dc3545; }
.theme-red .border-theme { border-color: #dc3545 !important; }

/* KPN (Gold/Yellow - Darker for readability) */
.theme-gold .text-theme { color: #d4a017 !important; } /* Emas Gelap agar terbaca */
.theme-gold .bg-theme { background-color: #ffc107 !important; color: #000; }
.theme-gold .btn-theme { background-color: #ffc107; color: #000; border: 2px solid #ffc107; }
.theme-gold .btn-theme:hover { background-color: transparent; color: #000; }
.theme-gold .border-theme { border-color: #ffc107 !important; }

/* --- SERTIFIKAT & GAMBAR --- */
.cert-card {
    cursor: pointer;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    transition: transform 0.3s ease;
    position: relative;
}

.cert-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0,0,0,0.2);
}

.cert-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.cert-card:hover .cert-overlay {
    opacity: 1;
}

/* --- LIGHTBOX (ZOOM EFFECT) --- */
.lightbox-modal {
    display: none; 
    position: fixed; 
    z-index: 9999; 
    padding-top: 50px; 
    left: 0; top: 0; 
    width: 100%; height: 100%; 
    overflow: auto; 
    background-color: rgba(0,0,0,0.9); 
}

.lightbox-content {
    margin: auto; 
    display: block; 
    max-width: 90%; 
    max-height: 85vh;
    border-radius: 5px;
    animation: zoomIn 0.3s;
}

.close-btn {
    position: absolute; 
    top: 20px; right: 35px; 
    color: #f1f1f1; 
    font-size: 40px; 
    font-weight: bold; 
    cursor: pointer;
    transition: 0.3s;
}

.close-btn:hover { color: #bbb; }

@keyframes zoomIn {
    from {transform:scale(0)} 
    to {transform:scale(1)}
}

/* =========================================
   15. HERO BACKGROUND SLIDER
   ========================================= */

/* Style Dasar Gambar Slide */
.slide-img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    opacity: 0; /* Sembunyi secara default */
    transform: scale(1);
    transition: opacity 1.5s ease-in-out, transform 6s ease; /* Transisi Halus */
}

/* State Aktif (Gambar Muncul) */
.slide-img.active {
    opacity: 1;
    transform: scale(1.1); /* Efek Zoom-in perlahan (Ken Burns Effect) */
}

/* =========================================
   VISI MISI & ANIMATION UTILITIES
   ========================================= */

/* Warna Tema (Jika belum ada) */
.text-theme {
    color: #002366 !important; /* Biru Gelap Khas Maritim */
}

/* Card Hover Effects */
.hover-shadow {
    transition: all 0.3s ease;
}

.hover-shadow:hover {
    transform: translateY(-10px); /* Kartu naik sedikit saat di-hover */
    box-shadow: 0 1rem 3rem rgba(0,0,0,.175)!important;
}

.transition-all {
    transition: all 0.3s ease-in-out;
}

/* Scroll Animations (Fade In Up) */
.animate-fade-in {
    opacity: 0;
    transform: translateY(30px); /* Posisi awal sedikit di bawah */
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
    will-change: opacity, transform;
}

/* Class ini akan ditambahkan oleh JS saat elemen muncul di layar */
.animate-fade-in.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Animation Delays */
.delay-1 { transition-delay: 0.2s; }
.delay-2 { transition-delay: 0.4s; }
.delay-3 { transition-delay: 0.6s; }

/* Icon Box Styling */
.icon-box {
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.card:hover .icon-box {
    transform: scale(1.1); /* Icon membesar sedikit saat kartu di-hover */
}

/* =========================================
   TIMELINE ANIMATIONS & STYLES
   ========================================= */

/* 1. Animasi Garis Vertikal (Tumbuh ke Bawah) */
.timeline-line {
    height: 0; /* Kondisi awal: tinggi 0 */
    transition: height 1.5s ease-out; /* Durasi tumbuh 1.5 detik */
}

/* Class ini akan ditambahkan oleh JS saat scroll sampai */
.timeline-line.grow-full {
    height: 100% !important;
}

/* 2. Animasi Item Timeline (Container per Baris) */
.timeline-item {
    opacity: 0;
    transition: all 0.8s cubic-bezier(0.25, 0.46, 0.45, 0.94); /* Efek easing yang smooth */
}

/* Item Ganjil (Kiri): Geser dari kiri (-50px) */
.timeline-item:nth-child(odd) {
    transform: translateX(-50px);
}

/* Item Genap (Kanan): Geser dari kanan (+50px) */
.timeline-item:nth-child(even) {
    transform: translateX(50px);
}

/* Saat Visible: Posisi kembali normal */
.timeline-item.visible {
    opacity: 1;
    transform: translateX(0);
}

/* 3. Animasi Dot (Titik) - Efek Pop Up */
.timeline-dot {
    transform: scale(0) translate(-50%, -50%); /* Awalnya kecil (hilang) */
    transition: transform 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275); /* Efek membal (bouncy) */
    transition-delay: 0.5s; /* Muncul belakangan setelah teks */
}

/* Perbaikan posisi titik saat animasi scale berjalan */
/* Kita perlu override translate-middle bawaan bootstrap saat animasi */
.timeline-dot {
    transform-origin: center;
}

.timeline-item.visible .timeline-dot {
    /* Kembalikan ke ukuran asli (scale 1) */
    /* Note: translate(-50%, -50%) diperlukan untuk menjaga posisi tengah */
    transform: scale(1) translate(-50%, -50%); 
}

/* Khusus Dot Kanan (Start-100) perlu translate yang berbeda agar tetap di tengah */
.timeline-item:nth-child(even).visible .timeline-dot {
     /* Karena dia di kanan (start-100), transformnya hanya perlu scale saja jika parent relative pas */
     /* Tapi karena kita pakai utility bootstrap, kita biarkan logic di atas, 
        browser modern cukup pintar menangani transform matrix */
     transform: scale(1) translate(-50%, -50%);
}

/* =========================================
   NEWS & DIRECTORY STYLES
   ========================================= */

/* 1. News Card Animation */
.news-card {
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.news-card:hover {
    transform: translateY(-5px); /* Kartu naik sedikit */
    box-shadow: 0 1rem 3rem rgba(0,0,0,.15)!important;
}

/* 2. Image Zoom Effect */
.news-img-wrapper {
    height: 240px; /* Tinggi tetap agar rapi */
    width: 100%;
}

.card-img-top {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.news-card:hover .card-img-top {
    transform: scale(1.1); /* Zoom in gambar */
}

/* 3. Typography & Links */
.hover-underline:hover {
    text-decoration: underline !important;
    color: #003366 !important;
}

.hover-theme:hover {
    color: #002366 !important; /* Biru AMP */
    padding-left: 5px; /* Efek geser kanan */
    transition: all 0.3s ease;
}

/* 4. Sidebar Styles */
.border-bottom-dashed {
    border-bottom: 1px dashed #dee2e6;
}

.sidebar-wrapper {
    z-index: 10;
}

/* 5. Custom Pagination (Blue Theme) */
.page-item.active .page-link {
    background-color: #002366;
    border-color: #002366;
    color: white;
}

.page-link {
    color: #002366;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    transition: all 0.3s;
}

.page-link:hover {
    background-color: #ffc107;
    color: #000;
}

/* =========================================
   ANIMASI POP-UP (TIMBUL) FOTO SIMULATOR
   ========================================= */
@keyframes popUpImage {
    0% {
        opacity: 0;
        transform: scale(0.9) translateY(30px); /* Mulai dari kecil & bawah */
    }
    60% {
        opacity: 1;
        transform: scale(1.02) translateY(-5px); /* Efek membal sedikit ke atas */
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0); /* Posisi normal */
    }
}

.animate-pop-up {
    opacity: 0; /* Sembunyikan di awal */
    /* Gunakan cubic-bezier untuk efek membal yang halus */
    animation: popUpImage 1s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}
/* Delay agar tidak muncul bersamaan */
.delay-pop-1 { animation-delay: 0.3s; }
.delay-pop-2 { animation-delay: 0.6s; }

/* =========================================
   ANIMASI GAMBAR TIMBUL & BERGERAK
   ========================================= */

/* 1. Animasi Mengapung (Naik Turun Halus) */
@keyframes floatImage {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-20px); } /* Naik 20px */
}

.animate-float {
    animation: floatImage 6s ease-in-out infinite; /* Bergerak selamanya */
}

/* 2. Styling Gambar Timbul (3D Look) */
.img-timbul {
    border-radius: 20px; /* Sudut membulat */
    border: 8px solid #ffffff; /* Bingkai putih tebal */
    box-shadow: 0 20px 60px rgba(0, 35, 102, 0.2); /* Bayangan biru gelap tebal */
    transition: all 0.5s ease;
}

/* Efek saat mouse diarahkan ke gambar */
.img-timbul:hover {
    transform: scale(1.03); /* Membesar sedikit */
    box-shadow: 0 30px 80px rgba(0, 35, 102, 0.3);
}

/* 3. Dekorasi Latar Belakang Text */
.text-decoration-bg {
    position: relative;
    z-index: 1;
}
.text-decoration-bg::before {
    content: '';
    position: absolute;
    top: -20px;
    left: -20px;
    width: 100px;
    height: 100px;
    background: rgba(255, 193, 7, 0.1); /* Kuning transparan */
    border-radius: 50%;
    z-index: -1;
}

/* =======================================================
   STYLE KHUSUS HALAMAN LABORATORIUM
   ======================================================= */

/* 1. ANIMASI GAMBAR MENGAPUNG (FLOATING)
   Membuat gambar bergerak naik turun perlahan seperti di air */
@keyframes floatLab {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-15px); }
}

.animate-float {
    /* Durasi 4 detik, gerakan halus, looping selamanya */
    animation: floatLab 4s ease-in-out infinite;
}

/* 2. STYLE GAMBAR TIMBUL (3D FRAME)
   Memberikan bingkai putih tebal dan bayangan agar terlihat pop-out */
.img-timbul {
    border: 8px solid #ffffff; /* Bingkai putih */
    border-radius: 20px;       /* Sudut membulat */
    box-shadow: 0 15px 40px rgba(0, 35, 102, 0.15); /* Bayangan biru samar */
    transition: all 0.4s ease; /* Transisi halus saat di-hover */
}

/* Efek saat mouse diarahkan ke area Lab Item */
.lab-item:hover .img-timbul {
    transform: scale(1.05); /* Membesar sedikit */
    box-shadow: 0 25px 60px rgba(0, 35, 102, 0.25); /* Bayangan makin dalam */
    border-color: #ffc107; /* Opsional: Bingkai berubah jadi kuning */
}

/* 3. CUSTOM NAV PILLS (TOMBOL TAB MENU) */
.nav-pills .nav-link {
    background-color: #e9ecef; /* Abu muda saat tidak aktif */
    color: #6c757d;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.nav-pills .nav-link:hover {
    background-color: #dde0e3;
    transform: translateY(-2px);
}

.nav-pills .nav-link.active {
    background-color: #002366 !important; /* Biru AMP */
    color: #ffc107 !important; /* Kuning Emas */
    box-shadow: 0 10px 20px rgba(0, 35, 102, 0.3);
    border-color: #ffc107;
}

/* 4. SECTION SAFETY (BACKGROUND GRADIENT) */
.bg-safety-gradient {
    background: linear-gradient(135deg, #001f4d 0%, #003366 100%);
}

/* 5. KARTU MELAYANG DI SECTION SAFETY */
.hover-float {
    transition: transform 0.3s ease, box-shadow 0.3s ease, background-color 0.3s;
}

.hover-float:hover {
    transform: translateY(-15px); /* Naik ke atas */
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4) !important;
    background-color: rgba(255, 255, 255, 0.15) !important; /* Jadi lebih terang */
    cursor: default;
}

/* 6. RESPONSIVE ADJUSTMENTS */
@media (max-width: 768px) {
    .img-timbul {
        height: 200px !important; /* Perkecil tinggi gambar di HP */
    }
    
    .nav-pills .nav-link {
        font-size: 0.85rem; /* Perkecil font tab di HP */
        padding: 0.5rem 1rem !important;
        margin-bottom: 10px;
    }
}

/* =========================================================
   TIMELINE ALUR UKP (MARITIME THEME) - FIXED ALIGNMENT
   ========================================================= */
.maritime-timeline {
    position: relative;
}

/* Garis Putus-putus */
.maritime-timeline::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 35px; /* Setengah dari ukuran lebar icon (70px) agar persis di tengah */
    width: 4px;
    margin-left: -2px; /* Menarik garis persis ke titik pusat */
    background-image: linear-gradient(to bottom, #0d6efd 50%, rgba(255, 255, 255, 0) 0%);
    background-size: 4px 15px;
    background-repeat: repeat-y;
    z-index: 0;
}

.timeline-item {
    position: relative;
    margin-bottom: 3rem;
    padding-left: 100px; /* Memberi ruang untuk icon (70px) + jarak (30px) ke kartu */
}

/* Lingkaran Icon */
.timeline-icon {
    position: absolute;
    left: 0;
    top: 15px; /* Diturunkan sedikit agar sejajar rapi dengan kartu */
    width: 70px;
    height: 70px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1;
    border: 5px solid #f8f9fa; /* Warna harus sama dengan background section (.bg-light) */
    box-shadow: 0 0.5rem 1rem rgba(0,0,0,0.15);
    background-color: white;
}

.timeline-content {
    position: relative;
}

/* Responsif untuk layar HP */
@media (max-width: 768px) {
    .maritime-timeline::before { 
        left: 25px; /* Setengah dari ukuran icon HP (50px) */
    }
    .timeline-item { 
        padding-left: 70px; /* Ruang untuk icon HP (50px) + jarak (20px) */
    }
    .timeline-icon { 
        width: 50px; 
        height: 50px; 
        border-width: 3px;
        top: 10px;
    }
    .timeline-icon i { font-size: 1.2rem !important; }
}