/* ======================================
   ROOT STYLES (Light Mode Standaard)
====================================== */
:root {
    --bg: #f6f8fb;
    --bg-gradient-top: #f0f6ff;
    --bg-gradient-bottom: #fdfefe;
    --card: #ffffff;
    --text: #0f172a;
    --muted: #6b7280;
    --shadow: 0 10px 30px rgba(16,24,40,0.08);
    --glass: rgba(255,255,255,0.65);
    --accent: #2b6df6;
    --school-detail-bg: linear-gradient(180deg, #ffffff, #fbfdff);
    transition: background-color 0.3s, color 0.3s;

    /* Extra variabelen voor Dark Mode overgangen (optioneel, helpt voor consistente hover-effecten) */
    --accent-rgb: 43, 109, 246; 
    --muted-rgb: 107, 114, 128;
    --text-rgb: 15, 23, 42;
}

/* ======================================
   DARK MODE OVERRIDES
====================================== */
.dark-mode {
    --bg: #18191a;
    --bg-gradient-top: #18191a;
    --bg-gradient-bottom: #1c1d1f;
    --card: #242526;
    --text: #e4e6eb;
    --muted: #b0b3b8;
    --shadow: 0 4px 15px rgba(0,0,0,0.4);
    --glass: rgba(36, 37, 38, 0.75);
    --accent: #5e8cf6; 
    --school-detail-bg: linear-gradient(180deg, #242526, #2d2f31);

    --accent-rgb: 94, 140, 246;
    --muted-rgb: 176, 179, 184;
    --text-rgb: 228, 230, 235;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: Inter, system-ui, -apple-system, 'Segoe UI', Roboto, Arial;
    /* Gebruik CSS variabelen voor achtergrond en tekstkleur */
    background: linear-gradient(180deg, var(--bg-gradient-top) 0%, var(--bg-gradient-bottom) 60%);
    color: var(--text);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    transition: background 0.5s ease; /* Vloeiende overgang bij mode-wissel */
}

/* ======================================
   FLOATING BLOBS BACKGROUND
====================================== */
.blob {
    position: fixed;
    border-radius: 50%;
    filter: blur(40px) saturate(120%);
    opacity: .18;
    pointer-events: none;
    z-index: 0;
}

.blob.a {
    width: 420px;
    height: 420px;
    background: linear-gradient(135deg, #8ec5ff 0%, #7ee8fa 100%);
    top: -80px;
    left: -80px;
    animation: floatA 10s ease-in-out infinite;
}

.blob.b {
    width: 360px;
    height: 360px;
    background: linear-gradient(135deg, #ffd1ff 0%, #ffb7c3 100%);
    bottom: -120px;
    right: -140px;
    animation: floatB 12s ease-in-out infinite;
}

@keyframes floatA {
    0% { transform: translateY(0) rotate(0); }
    50% { transform: translateY(18px) rotate(8deg); }
    100% { transform: translateY(0) rotate(0); }
}

@keyframes floatB {
    0% { transform: translateY(0) rotate(0); }
    50% { transform: translateY(-18px) rotate(-6deg); }
    100% { transform: translateY(0) rotate(0); }
}

/* ======================================
   NAVIGATIEBALK
====================================== */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 64px;
    background: var(--card);
    display: flex;
    justify-content: center; 
    align-items: center;
    box-shadow: var(--shadow);
    z-index: 10;
    transition: background 0.3s, box-shadow 0.3s;
}

.navbar-content {
    max-width: 1100px;
    width: 100%;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between; 
}

.nav-brand {
    font-size: 18px;
    font-weight: 700;
    color: var(--accent);
    text-decoration: none;
    flex-shrink: 0;
}

.nav-links {
    list-style: none; 
    margin: 0;
    padding: 0;
    display: flex; 
    gap: 0; 
    flex-shrink: 0; 
}

.nav-links li {
    margin: 0 4px; 
}

.nav-links a {
    text-decoration: none;
    color: var(--muted);
    font-weight: 500;
    /* Extra padding om de knop van de rand af te duwen */
    padding: 20px 14px; 
    display: block;
    transition: color 0.15s ease;
}

.nav-links a:hover {
    color: var(--accent);
}

.dropdown {
    position: relative;
}

.dropdown > a {
    display: flex;
    align-items: center;
    gap: 4px;
}

.dropdown-menu {
    position: absolute;
    top: 100%; 
    left: 0; /* FIX: Lijn het menu links uit met de knop */
    transform: translateY(10px); 
    list-style: none;
    padding: 8px 0;
    margin: 0;
    background: var(--card);
    border-radius: 8px;
    box-shadow: var(--shadow);
    min-width: 180px;
    z-index: 100;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.dropdown:hover .dropdown-menu {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0); 
}

.dropdown-menu li a {
    padding: 8px 16px;
    font-size: 14px;
    font-weight: 500;
    color: var(--text);
    transition: background 0.15s ease, color 0.15s ease;
}

.dropdown-menu li a:hover {
    /* Gebruik de accentkleur en een lichte achtergrond voor de hover */
    background: rgba(var(--accent-rgb), 0.1); 
    color: var(--accent);
}

.arrow {
    font-size: 10px;
    transition: transform 0.2s ease;
}

.dropdown:hover .arrow {
    transform: rotate(180deg);
}

/* --- DARK MODE TOGGLE STYLING --- */
.dark-mode-toggle {
    /* ACHTERGROND TOEGEVOEGD VOOR ZEKERHEID */
    background: var(--bg); 
    border: 1px solid var(--muted); /* Border toegevoegd */
    cursor: pointer;
    font-size: 20px;
    margin-left: 10px;
    padding: 0;
    height: 38px; /* Iets kleiner gemaakt */
    width: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s, border-color 0.2s;
    /* BELANGRIJK: Zorgt dat de knop altijd zichtbaar is */
    flex-shrink: 0; 
}

.dark-mode-toggle:hover {
    background-color: rgba(var(--accent-rgb), 0.1);
    border-color: var(--accent);
}

/* Zorg dat de iconen correct kleuren afhankelijk van de mode */
.icon-light, .icon-dark {
    color: var(--text);
}

/* Zichtbaarheid van iconen */
.icon-dark, .dark-mode .icon-light {
    display: none;
}

.dark-mode .icon-dark {
    display: inline;
}

/* ======================================
   HEADER (COMPENSATIE VOOR VASTE NAVIGATIE)
====================================== */
header {
    /* Compensatie voor de navigatie (64px) + oorspronkelijke header padding (56px) */
    padding-top: calc(64px + 56px); 
    
    position: relative;
    z-index: 2;
    text-align: center;
    padding-bottom: 12px;
}

header h1 {
    margin: 0;
    font-size: 36px;
    font-weight: 800;
    letter-spacing: .2px;
    /* De gradiënt blijft behouden, maar de kleuren zijn nu variabel */
    background: linear-gradient(90deg, #0ea5e9, var(--accent)); 
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

header p.tag {
    margin-top: 8px;
    font-size: 14px;
    color: var(--muted);
}

/* ======================================
   CAROUSEL
====================================== */
.carousel-wrap {
    position: relative;
    z-index: 2;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 18px 20px 44px;
}

.carousel {
    display: flex;
    align-items: center;
    gap: 18px;
    max-width: 1100px;
    width: 100%;
    justify-content: center;
}

.arrow-btn {
    width: 56px;
    height: 56px;
    border-radius: 999px;
    border: none;
    display: flex;
    justify-content: center;
    align-items: center;
    background: var(--glass);
    backdrop-filter: blur(6px);
    box-shadow: var(--shadow);
    cursor: pointer;
    font-size: 26px;
    color: var(--accent);
    transition: transform .15s ease, box-shadow .15s ease, background 0.3s;
}

.arrow-btn:hover {
    transform: translateY(-3px);
}

.arrow-btn:focus {
    outline: 3px solid rgba(var(--accent-rgb), 0.12);
}

.icons-row {
    display: flex;
    gap: 18px;
    align-items: center;
    justify-content: center;
    flex: 1 1 auto;
    padding: 12px;
}

/* ======================================
   CAROUSEL ITEM STYLING
====================================== */
.item {
    width: 140px;
    height: 140px;
    border-radius: 16px;
    background: var(--card);
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: var(--shadow);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
    transition: transform 520ms cubic-bezier(.2,.9,.2,1),
                opacity 420ms ease,
                filter 420ms ease,
                box-shadow 420ms ease,
                background 0.3s;
}

.item img {
    max-width: 84%;
    max-height: 84%;
    object-fit: contain;
    transition: transform 520ms cubic-bezier(.2,.9,.2,1), opacity 420ms ease;
}

/* positions */
.item--left2, .item--right2 {
    transform: scale(.78);
    opacity: .55;
    filter: grayscale(.12) blur(.2px);
}

.item--left1, .item--right1 {
    transform: scale(.94);
    opacity: .85;
}

.item--center {
    transform: scale(1.28);
    z-index: 3;
    /* Andere shadow voor het centrale item */
    box-shadow: 0 20px 50px rgba(var(--text-rgb), 0.12);
}

.fading {
    opacity: 0;
    transform: translateY(6px) scale(.98) !important;
}

/* sparkles */
.spark {
    position: absolute;
    border-radius: 50%;
    pointer-events: none;
    mix-blend-mode: screen;
}

/* ======================================
   OVER ONS + SCHOOL SECTIONS
====================================== */
.sections {
    max-width: 1100px;
    margin: 48px auto;
    padding: 0 20px;
    position: relative;
    z-index: 2;
}

.card {
    background: var(--card);
    padding: 22px;
    border-radius: 12px;
    display: flex;
    gap: 20px;
    align-items: center;
    opacity: 0;
    transform: translateY(18px);
    transition: opacity 700ms cubic-bezier(.2,.9,.2,1), 
                transform 700ms cubic-bezier(.2,.9,.2,1),
                background 0.3s, color 0.3s, box-shadow 0.3s;
    box-shadow: var(--shadow);
}

.card.visible {
    opacity: 1;
    transform: none;
}

.text {
    flex: 1;
    font-size: 15px;
    line-height: 1.6;
}

.text h2 {
    margin: 0 0 8px;
    font-size: 20px;
    color: var(--text);
}

.photo {
    width: 220px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: stretch;
}

.photo img {
    width: 100%;
    border-radius: 8px;
    display: block;
}

/* ⭐ LRC Home Link Styling */
.lrc-home-link {
    display: block;
    text-align: center;
    padding: 10px 16px;
    background: var(--accent);
    color: white !important;
    text-decoration: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.2s, transform 0.1s, box-shadow 0.2s;
    box-shadow: 0 4px 10px rgba(var(--accent-rgb), 0.25);
    width: 100%;
}

.lrc-home-link:hover {
    background-color: #1e53c4;
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(var(--accent-rgb), 0.35);
}

.dark-mode .lrc-home-link:hover {
    background-color: #4a7ae8;
}

/* school detail box */
.school-detail {
    margin-top: 14px;
    background: var(--school-detail-bg);
    padding: 16px;
    border-radius: 10px;
    display: flex;
    gap: 14px;
    align-items: center;
    transition: background 0.3s;
}

.school-detail img {
    width: 120px;
    border-radius: 8px;
    flex-shrink: 0;
}

.school-detail p {
    margin: 0;
    font-size: 14px;
    color: var(--muted);
}

/* ======================================
   RESPONSIVE
====================================== */
@media (max-width: 900px) {
    .item {
        width: 110px;
        height: 110px;
    }

    .item--center {
        transform: scale(1.12);
    }

    .arrow-btn {
        width: 48px;
        height: 48px;
        font-size: 22px;
    }

    .card {
        flex-direction: column;
        align-items: flex-start;
    }

    .photo {
        width: 140px;
    }

    .school-detail {
        flex-direction: column;
        align-items: flex-start;
    }

    .school-detail img {
        width: 100%;
    }
    
    /* Navigatie aanpassing op kleinere schermen */
    .navbar-content {
        justify-content: space-between;
    }

    .nav-links {
        gap: 0; 
    }
    .nav-brand {
        font-size: 16px;
    }
    
    .dropdown-menu {
        left: 0; 
        right: auto;
        transform: translateX(0);
    }
    .dropdown:hover .dropdown-menu {
        transform: translateX(0) translateY(0);
    }
}