/* =========================================
   1. SETUP DASAR & WARNA
   ========================================= */
:root {
    --primary-color: #00a8e8; 
    
    --primary-hover: #008fc6;
    
    --secondary-color: #333333;
    --dark-overlay: rgba(0, 0, 0, 0.5); 
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f8f9fa; 
}

.navbar {
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.btn-primary {
    background-color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

.btn-primary:hover {
    background-color: var(--primary-hover) !important;
    border-color: var(--primary-hover) !important;
}

.btn-outline-primary {
    color: var(--primary-color) !important;
    border-color: var(--primary-color) !important;
}

.btn-outline-primary:hover {
    background-color: var(--primary-color) !important;
    color: #fff !important;
}

.text-primary {
    color: var(--primary-color) !important;
}

.nav-link.active, .nav-link:hover {
    color: var(--primary-color) !important;
    font-weight: bold;
}

/* =========================================
   2. CAROUSEL / SLIDER MODERN
   ========================================= */

.hero-img {
    height: 600px; 
    object-fit: cover; 
    position: relative;
}

.overlay-dark {
    position: absolute;
    top: 0; left: 0; width: 100%; height: 100%;
    background: var(--dark-overlay);
    z-index: 1;
}

.carousel-caption {
    z-index: 2;
    bottom: 0; top: 0; 
}

.animated-text { animation: fadeInUp 1s ease-in-out; }
.animated-text-delay { animation: fadeInUp 1s ease-in-out 0.3s backwards; }
.animated-btn { animation: fadeInUp 1s ease-in-out 0.6s backwards; }

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

/* =========================================
   3. KOMPONEN LAIN (BERITA & CARD)
   ========================================= */

.card-hover { transition: all 0.3s ease; }
.card-hover:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.15) !important;
}

.content-text { font-size: 1.1rem; color: #333; }

/* =========================================
   4. STRUKTUR ORGANISASI (COMPACT & RESPONSIVE)
   ========================================= */

.tree-container {
    width: 100%;
    overflow-x: auto; 
    overflow-y: hidden;
    padding: 20px 0;
    text-align: center;
    -webkit-overflow-scrolling: touch; 
}

.tree { display: inline-block; min-width: 100%; }

.tree ul {
    padding-top: 15px; position: relative;
    transition: all 0.5s;
    display: flex; justify-content: center; margin: 0; 
}

.tree li {
    float: left; text-align: center; list-style-type: none;
    position: relative; padding: 15px 4px 0 4px; 
    transition: all 0.5s;
}

.tree li::before, .tree li::after{
    content: ''; position: absolute; top: 0; right: 50%;
    border-top: 1px solid #444; width: 50%; height: 15px; 
}
.tree li::after{ right: auto; left: 50%; border-left: 1px solid #444; }

.tree li:only-child::after, .tree li:only-child::before { display: none; }
.tree li:only-child{ padding-top: 0;}
.tree li:first-child::before, .tree li:last-child::after{ border: 0 none; }
.tree li:last-child::before{ border-right: 1px solid #444; border-radius: 0 5px 0 0; }
.tree li:first-child::after{ border-radius: 5px 0 0 0; }

.tree ul ul::before{
    content: ''; position: absolute; top: 0; left: 50%;
    border-left: 1px solid #444; width: 0; height: 15px;
}

.tree li .box {
    border: 1px solid #333;
    padding: 6px 4px; 
    text-decoration: none; color: #000;
    font-family: 'Segoe UI', sans-serif;
    font-size: 11px; font-weight: 600; 
    display: inline-block; background: #fff;
    min-width: 80px; max-width: 120px; 
    line-height: 1.2; position: relative; z-index: 2;
    border-radius: 3px; box-shadow: 0 1px 2px rgba(0,0,0,0.1);
}

.tree li .box:hover {
    background: #e3f2fd;
    border-color: var(--primary-color); 
    transform: scale(1.05); z-index: 100; transition: all 0.2s;
}

.tree li.dotted::before, .tree li.dotted::after {
    border-top: 1px dashed #333 !important;
}
.tree li.dotted::after { border-left: 1px dashed #333 !important; }

.prodi-wrapper { display: flex; align-items: center; justify-content: center; gap: 5px; }

.dashed-box {
    border: 1px dashed #000; padding: 5px;
    background: #fff; font-size: 10px; font-weight: bold;
    width: 90px; line-height: 1.1;
}

.connector-line {
    width: 15px; height: 1px; background-color: transparent;
    border-top: 1px dashed #000; margin-top: 2px;
}

.tree small {
    font-size: 9px; font-weight: normal; color: #555;
    display: block; margin-top: 2px;
}
/* =========================================
   5. RESPONSIVE HEADER (KHUSUS HP)
   ========================================= */
@media (max-width: 576px) {
    .navbar-brand img {
        height: 50px !important; 
        margin-right: 10px !important;
    }

    .navbar-brand span {
        font-size: 1.1rem !important; 
        line-height: 1.1 !important;
    }
}
/* =========================================
   6. TOMBOL TOGGLE ANIMASI (HAMBURGER KEREN)
   ========================================= */

.navbar-toggler:focus {
    box-shadow: none !important;
    outline: none !important;
}

.hamburger-lines {
    display: block;
    height: 26px;
    width: 32px;
    position: relative;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.hamburger-lines .line {
    display: block;
    height: 4px;
    width: 100%;
    border-radius: 10px;
    background: var(--primary-color); 
    transition: transform 0.4s ease-in-out; 
}

.navbar-toggler[aria-expanded="true"] .line1 {
    transform: rotate(45deg);
    transform-origin: 0% 0%;
}

.navbar-toggler[aria-expanded="true"] .line2 {
    transform: scaleY(0);
}

.navbar-toggler[aria-expanded="true"] .line3 {
    transform: rotate(-45deg);
    transform-origin: 0% 100%;
}
/* =========================================
   7. FOOTER STYLING
   ========================================= */

.footer-link {
    transition: all 0.3s ease;
}
.footer-link:hover {
    color: var(--primary-color) !important; 
    padding-left: 8px; 
}

.social-btn {
    width: 35px;
    height: 35px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    border-color: var(--primary-color);
}
.social-btn:hover {
    background-color: var(--primary-color);
    color: #fff;
}
/* =========================================
   8. PAGE HEADER GRADIENT (Agar Pas dengan Logo)
   ========================================= */
.page-header {
    background: linear-gradient(135deg, #00a8e8 0%, #007bb5 100%);
    color: white;
    padding-top: 3rem;
    padding-bottom: 3rem;
    margin-bottom: 3rem;
    position: relative;
    box-shadow: 0 4px 15px rgba(0, 168, 232, 0.2); 
}
/* =========================================
   8. FLOATING WHATSAPP BUTTON
   ========================================= */
.float-wa {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background-color: #25d366; 
    color: white;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    text-align: center;
    font-size: 30px;
    box-shadow: 2px 2px 10px rgba(0, 0, 0, 0.2);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    text-decoration: none;
}

.float-wa:hover {
    background-color: #128c7e; 
    color: white;
    transform: scale(1.1);
}

.float-wa::after {
    content: "Chat Kami";
    position: absolute;
    right: 70px;
    background: white;
    color: #333;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 12px;
    font-weight: bold;
    box-shadow: 1px 1px 5px rgba(0,0,0,0.1);
    opacity: 0;
    transition: 0.3s;
    pointer-events: none;
    white-space: nowrap;
}

.float-wa:hover::after {
    opacity: 1;
    right: 75px; 
}

/* =========================================
   9. INFINITE LOGO SLIDER (PARTNER)
   ========================================= */
.slider-area {
    background: transparent; 
    box-shadow: none;        
    height: 120px;           
    margin: auto;
    overflow: hidden;
    position: relative;
    width: 100%;
    display: flex;
    align-items: center;
}

.slider-track {
    -webkit-animation: scroll 40s linear infinite;
    animation: scroll 40s linear infinite;
    display: flex;
    width: calc(250px * 14);
}

.slide-logo {
    height: 100px;
    width: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 20px;
}

.slide-logo img {
    width: 100%;
    height: auto;
    max-height: 80px;
    object-fit: contain;
    transition: 0.3s;
}

.slide-logo img:hover {
    transform: scale(1.1); 
}

@keyframes scroll {
    0% { transform: translateX(0); }
    100% { transform: translateX(calc(-250px * 7)); }
}
/* =========================================
   10. RESPONSIVE SLIDER (FIX ZOOM MOBILE)
   ========================================= */

@media (max-width: 768px) {
    .hero-img {
        height: 70vh !important; 
        object-position: center; 
    }

    .carousel-item .display-3 {
        font-size: 1.8rem !important; 
        margin-bottom: 10px;
        text-shadow: 2px 2px 4px rgba(0,0,0,0.8); 
    }

    .carousel-item .lead {
        font-size: 0.9rem !important; 
        line-height: 1.4;
    }

    .animated-btn .btn {
        padding: 8px 20px !important; 
        font-size: 0.9rem !important;
    }

    .carousel-caption {
        bottom: 3rem !important; 
        padding-left: 15px;
        padding-right: 15px;
    }
}