:root {
    --primary-dark: #07263a;
    --primary-light: #1a6a8f;
    --fucsia: #d81b60;
    --fucsia-dark: #ad154c;
    --light: #ffffff;
    --soft: #e5e7eb;
    --card-bg: #ffffff;
    --radius: 18px;
    --shadow: 0 14px 40px rgba(0, 0, 0, 0.25);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(to top, var(--primary-dark), var(--primary-light));
    color: var(--light);
    min-height: 100vh;
    text-align: center;
}

/* Fixed header + menu */
header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(7, 38, 58, 0.96);
    backdrop-filter: blur(6px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.35);
}

.hero {
    width: 100%;
    height: 320px;
    background-image: url('header-1.jpg');
    /* vervang door echte afbeelding */
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border-bottom: 4px solid rgba(255, 255, 255, 0.15);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    padding-bottom: 20px;
    margin-bottom: 30px;
}

.hero .logo {
    width: 150px;
    height: 150px;
    border-radius: 50%;
    box-shadow: var(--shadow);
    border: 4px solid white;
}

.nav-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 10px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.nav-title {
    font-weight: 700;
    font-size: 1.1rem;
    white-space: nowrap;
}

.nav-title span {
    color: var(--fucsia);
}

nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 10px 18px;
    justify-content: flex-end;
}

nav a {
    color: var(--soft);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: 500;
    transition: color 0.2s;
}

nav a:hover {
    color: var(--fucsia);
}

nav ul li a {
    padding: 15px 2px;
    display: inline-block;
}

/* CTA in the top menu */
nav ul li.menu-cta {
    display: flex;
    align-items: center;
}

nav ul li.menu-cta .cta-button {
    background: var(--fucsia);
    color: white;
    padding: 10px 16px;
    border-radius: 28px;
    font-weight: 700;
    box-shadow: 0 8px 20px rgba(216, 27, 96, 0.22);
    transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
    text-decoration: none;
    white-space: nowrap;
}

nav ul li.menu-cta .cta-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 14px 30px rgba(168, 21, 76, 0.28);
    background: var(--fucsia-dark);
}

/* ruimte onder fixed header */
.top-spacer {
    height: 70px;
    position: absolute;
}

.container {
    max-width: 1100px;
    margin: auto;
    padding: 40px 20px 40px 20px;
}

.container ul {
    list-style: disc;
    padding-left: 20px;
    margin-bottom: 20px;
    text-align: left;
}

.logo {
    width: 130px;
    height: 130px;
    border-radius: 50%;
    margin: 0 auto 20px auto;
    box-shadow: var(--shadow);
    object-fit: cover;
}

h1 {
    font-size: 2.6rem;
    font-weight: 700;
    margin-bottom: 10px;
}

.subtitle {
    font-size: 1.1rem;
    color: var(--soft);
    margin-bottom: 20px;
}

.address {
    font-size: 0.95rem;
    margin-bottom: 40px;
    color: #d9e6ef;
}

.intro {
    max-width: 800px;
    margin: 0 auto 50px auto;
    font-size: 1.05rem;
    color: #e8eef5;
    line-height: 1.6;
}

.section {
    background: var(--card-bg);
    padding: 30px;
    margin: 35px auto;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    max-width: 900px;
    color: #333;
    text-align: left;

    /* zodat het onder de header zichtbaar start */
    scroll-margin-top: 90px;
}

.section h2 {
    color: var(--fucsia-dark);
    margin-bottom: 15px;
}

.section p {
    color: #444;
    line-height: 1.6;
    margin-bottom: 12px;
}

.placeholder,
.image img {
    max-width: 400px;
    max-height: 500px;
    width: auto;
    height: auto;
    background: #eee;
    border-radius: 12px;
    margin: 15px 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #777;
    font-size: 1rem;
    font-style: italic;
}

.image {
    width: auto;
    overflow-y: hidden;
}

.image img {
    max-width: 100%;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

iframe {
    border-radius: 12px;
    width: 100%;
    max-width: 100%;
}

.whatsapp-button,
.email-button {
    display: inline-block;
    padding: 14px 22px;
    border-radius: 50px;
    font-size: 18px;
    font-weight: 600;
    text-decoration: none;
    margin-top: 15px;
    margin-right: 10px;
    box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
    color: white;
}

.whatsapp-button {
    background: #25D366;
}

.whatsapp-button:hover {
    background: #1ebe5d;
}

.email-button {
    background: var(--fucsia);
}

.email-button:hover {
    background: var(--fucsia-dark);
}

footer {
    margin-top: 50px;
    font-size: 0.85rem;
    color: #d1dbe5;
}

.bible {
    margin-top: 12px;
    font-size: 1rem;
    font-weight: 600;
    opacity: 0.9;
}

/* eenvoudige responsiviteit */
@media (max-width: 768px) {
    .nav-inner {
        flex-direction: row; /* was column */
        align-items: center; /* center vertically */
        justify-content: space-between;
        width: 100%;
        gap: 12px;
    }

    nav ul {
        justify-content: flex-start;
    }

    /* small spacing so the title doesn't sit flush to the button */
    .nav-title {
        margin-left: 8px;
    }
}

@media (max-width: 768px) {
    /* hide the normal nav buttons on small screens */
    nav ul {
        display: none; /* hidden by default on mobile */
    }

    /* show hamburger button */
    .menu-toggle {
        display: inline-flex;
        flex-direction: column; /* stack the three bars vertically */
        align-items: center;
        justify-content: center;
        padding: 6px;
    }

    /* When header has the "nav-open" class show the nav as a vertical dropdown */
    header.nav-open nav ul {
        display: flex;
        flex-direction: column;
        gap: 8px;
        position: absolute;
        top: 60px;
        right: 12px;
        background: linear-gradient(180deg, #ffffff, #fbfdff);
        color: #21313a;
        padding: 12px;
        border-radius: 10px;
        box-shadow: 0 12px 40px rgba(7,38,58,0.12);
        width: 220px;
        z-index: 1100;
    }

    /* transform hamburger into an X when open */
    .menu-toggle.open .bar:nth-child(1) { transform: translateY(6px) rotate(45deg); }
    .menu-toggle.open .bar:nth-child(2) { opacity: 0; }
    .menu-toggle.open .bar:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }

    /* ensure the menu CTA fits full width when nav is collapsed */
    nav ul li.menu-cta .cta-button {
        padding: 10px 12px;
    }
}

/* Hide menu controls on the inscription page */
body.inscripcion-page .menu-toggle,
body.inscripcion-page nav {
    display: none !important;
}

@media (max-width: 768px) {
    /* center dropdown horizontally and ensure it's not too narrow */
    header.nav-open nav ul {
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        width: min(92%, 320px);
        top: 60px;
        z-index: 1300;
    }
}

/* Mobile menu toggle button base styles (display controlled via media queries) */
.menu-toggle {
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    border-radius: 10px;
    background: transparent;
    border: none;
    cursor: pointer;
    color: var(--soft);
    z-index: 1200; /* ensure it's above the header dropdown */
}
.menu-toggle:focus { outline: 2px solid rgba(216,27,96,0.18); outline-offset: 2px; }
.menu-toggle .bar {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--soft);
    margin: 3px 0;
    transition: transform 0.18s ease, opacity 0.18s ease;
}

/* hide the hamburger on desktop explicitly */
@media (min-width: 769px) {
    .menu-toggle { display: none !important; }
}

/* When the mobile dropdown is shown, make CTA buttons dark blue and links readable */
header.nav-open nav ul a {
    color: #21313a; /* dark text on light dropdown */
}
header.nav-open nav ul li.menu-cta .cta-button {
    background: linear-gradient(180deg, var(--primary-dark), var(--primary-light));
    color: #fff;
    box-shadow: 0 12px 30px rgba(7,38,58,0.08);
}
header.nav-open nav ul li.menu-cta .cta-button:hover {
    background: var(--primary-light);
}

/* Form styles: modern card-like inputs and buttons */
.form-card {
    background: linear-gradient(180deg, rgba(255,255,255,0.98), rgba(250,250,250,0.98));
    padding: 26px;
    border-radius: 14px;
    box-shadow: 0 12px 30px rgba(7,38,58,0.12);
    color: #21313a;
}

.form-section {
    margin-bottom: 20px;
}

.form-section h3 {
    margin: 0 0 14px 0;
    color: var(--primary-dark);
    font-size: 1.05rem;
}

.form-row {
    display: flex;
    gap: 14px;
    align-items: flex-start;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.form-group {
    flex: 1 1 220px;
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-size: 0.92rem;
    color: #44525a;
    margin-bottom: 6px;
    font-weight: 600;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
    /* subtle card-like surface */
    background: linear-gradient(180deg, #ffffff, #fbfdff);
    border: 1px solid #e6eef2;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 0.95rem;
    color: #21313a;
    font-family: inherit; /* ensure form controls use the same font as body */

    /* soft inner depth */
    box-shadow: inset 0 3px 8px rgba(7,38,58,0.04);
    transition: border-color 0.15s ease, box-shadow 0.18s ease, transform 0.12s ease;
    appearance: none;
    -webkit-appearance: none;
}

.form-group input::placeholder,
.form-group textarea::placeholder {
    color: #9aa8af;
    font-style: italic;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    border-color: var(--fucsia);
    box-shadow: 0 10px 30px rgba(26,106,143,0.06), 0 6px 18px rgba(216,27,96,0.08);
    transform: translateY(-2px);
    outline: none;
}

/* invalid state (browser validation) */
.form-group input:invalid,
.form-group textarea:invalid,
.form-group select:invalid {
    border-color: #e44d4d;
    box-shadow: inset 0 2px 6px rgba(228,77,77,0.05);
}

/* make textareas a bit more spacious */
.form-group textarea {
    /* make textareas match inputs and prevent user resizing */
    min-height: 68px;
    padding-top: 10px;
    padding-bottom: 10px;
    resize: none; /* prevent resizing */
    font-family: inherit; /* use same font as inputs/body */
    font-size: 0.95rem; /* match input sizing */
    line-height: 1.4;
}

/* smaller visual for date and select controls */
.form-group input[type="date"],
.form-group select {
    padding: 10px 12px;
}

/* Make selects visually match inputs (same elevation/altitude) */
.form-group select {
    /* match input surface */
    background: linear-gradient(180deg, #ffffff, #fbfdff);
    border: 1px solid #e6eef2;
    padding: 12px 38px 12px 14px; /* extra right padding for arrow */
    border-radius: 12px;
    font-size: 0.95rem;
    color: #21313a;
    box-shadow: inset 0 3px 8px rgba(7,38,58,0.04);
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    cursor: pointer;
    transition: border-color 0.15s ease, box-shadow 0.18s ease, transform 0.12s ease;
    /* simple CSS arrow using gradients so no external asset required */
    background-image: linear-gradient(45deg, transparent 50%, #21313a 50%), linear-gradient(135deg, #21313a 50%, transparent 50%);
    background-position: calc(100% - 16px) calc(50% - 3px), calc(100% - 12px) calc(50% - 3px);
    background-size: 6px 6px, 6px 6px;
    background-repeat: no-repeat;
}

.form-group select:focus {
    border-color: var(--fucsia);
    box-shadow: 0 10px 30px rgba(26,106,143,0.06), 0 6px 18px rgba(216,27,96,0.08);
    transform: translateY(-2px);
    outline: none;
}

.form-group select:invalid {
    border-color: #e44d4d;
    box-shadow: inset 0 2px 6px rgba(228,77,77,0.05);
}

/* ensure buttons inside form rows keep their look on small screens */
.form-row .btn { white-space: nowrap; }

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 10px 16px;
    border-radius: 12px;
    font-weight: 700;
    cursor: pointer;
    border: none;
    transition: transform 0.12s ease, box-shadow 0.12s ease, opacity 0.12s ease;
    box-shadow: 0 6px 18px rgba(7,38,58,0.08);
    background: #f3f4f6;
    color: #21313a;
    font-family: inherit; /* ensure buttons use the same font as body */
}

/* also ensure native button/input controls inherit the site font */
button,
input[type="button"],
input[type="submit"],
input[type="reset"] {
    font-family: inherit;
}

.btn:hover { transform: translateY(-3px); }

.btn.cta {
    background: linear-gradient(180deg, var(--fucsia), var(--fucsia-dark));
    color: white;
    padding: 12px 20px;
    border-radius: 16px;
    box-shadow: 0 14px 38px rgba(216,27,96,0.18);
}

.btn.ghost {
    background: transparent;
    color: var(--primary-dark);
    border: 1px solid rgba(7,38,58,0.06);
    box-shadow: none;
}

.btn.add-student {
    background: linear-gradient(90deg, rgba(26,106,143,0.06), rgba(216,27,96,0.04));
    color: var(--primary-dark);
    padding: 10px 14px;
    border-radius: 12px;
    font-weight: 700;
}

.student-card {
    background: linear-gradient(180deg, #ffffff, #fbfdff);
    border: 1px solid #eef6f9;
    padding: 14px;
    margin-bottom: 12px;
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(7,38,58,0.04);
}

.student-card h4 { margin: 0 0 8px 0; color: var(--primary-dark); }

.form-message { margin-top: 10px; font-weight: 700; }
.form-message.success { color: #0b8457; }
.form-message.error { color: #c0392b; }

/* Footnote / attention text shown below the form */
.form-footnote {
    margin-top: 12px;
    font-size: 0.92rem;
    color: #33484d;
    background: rgba(247, 249, 250, 0.9);
    padding: 10px 12px;
    border-radius: 10px;
    border: 1px solid rgba(7,38,58,0.04);
    font-style: italic;
    line-height: 1.45;
}

.small { font-size: 0.9rem; color: #64707a; margin-bottom: 8px; }

.form-row.actions { justify-content: flex-end; }

/* Checkbox consent group styling */
.form-group.checkbox {
    flex-direction: row;
    align-items: center;
    gap: 10px;
}
.form-group.checkbox input[type="checkbox"] {
    width: 18px;
    height: 18px;
    margin: 0;
    accent-color: var(--fucsia);
}
.form-group.checkbox label {
    margin: 0; /* keep the label inline with checkbox */
    font-weight: 500;
    color: #44525a;
}
.form-group.checkbox a.consent-link {
    color: var(--fucsia);
    text-decoration: underline;
}

/* File input styling to match other form controls */
.file-input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
}
.file-input-wrapper .student-foto-input {
    /* visually hide native file input but keep it focusable and accessible */
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
}
.file-input-wrapper .file-btn {
    display: inline-block;
    background: linear-gradient(180deg, #ffffff, #fbfdff);
    border: 1px solid #e6eef2;
    padding: 10px 12px;
    border-radius: 12px;
    font-size: 0.95rem;
    color: #21313a;
    box-shadow: inset 0 3px 8px rgba(7,38,58,0.04);
    transition: border-color 0.15s ease, box-shadow 0.18s ease, transform 0.12s ease;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
}
.file-input-wrapper .file-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(26,106,143,0.06), 0 6px 18px rgba(216,27,96,0.08);
}
.file-input-wrapper .file-name {
    font-size: 0.9rem;
    color: #576b71;
    font-style: italic;
    max-width: 46%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.file-input-wrapper .file-preview img {
    max-width: 120px;
    max-height: 100px;
    object-fit: cover;
    border-radius: 10px;
    border: 1px solid #e6eef2;
    box-shadow: 0 6px 18px rgba(7,38,58,0.06);
}

/* Consistent CTA style for Admisiones section */
.admisiones-cta {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 12px 18px;
    border-radius: 999px;
    background: linear-gradient(180deg, var(--primary-dark), var(--primary-light));
    color: #fff !important;
    text-decoration: none;
    box-shadow: 0 10px 30px rgba(7,38,58,0.12);
    font-weight: 700;
    margin-right: 8px;
    margin-bottom:10px;
}
.admisiones-cta:hover {
    background: var(--primary-light);
    transform: translateY(-2px);
}

@media (max-width: 768px) {
    .admisiones-cta { width: 100%; display: inline-flex; }
}

/* Slightly larger on desktop */
@media (min-width: 900px) {
    nav ul li.menu-cta .cta-button {
        padding: 12px 20px;
        font-size: 0.95rem;
    }
}

/* Stack and full-width on small devices */
@media (max-width: 768px) {
    .container {
        padding: 0px;
    }
    nav ul li.menu-cta {
        width: 100%;
        margin-top: 8px;
    }

    nav ul li.menu-cta .cta-button {
        width: 100%;
        text-align: center;
        padding: 12px 14px;
    }
}

/* Responsive tweaks for small screens */
@media (max-width: 768px) {
    .form-row { flex-direction: column; gap: 8px; margin-bottom: 8px; }
    .form-group { width: 100%; flex: 0 0 auto; min-height: 0; margin-bottom: 6px; }
    .form-group label { margin-bottom: 4px; }
    .form-group input,
    .form-group select,
    .form-group textarea {
        margin-bottom: 0; /* avoid extra margins that add vertical space */
        min-height: 0;
        height: auto;
        line-height: 1.15;
    }
    .form-card { padding: 18px; }
    .btn { width: 100%; }
    .form-row.actions .btn { width: auto; }
}

/* Tighter spacing on very small screens */
@media (max-width: 480px) {
    .form-row {
        gap: 8px; /* less horizontal/vertical gap between form groups */
        margin-bottom: 8px; /* reduce space between rows */
    }

    .form-group {
        flex: 1 1 100%;
    }

    .form-group label {
        margin-bottom: 4px; /* smaller distance between label and control */
        font-size: 0.9rem;
    }

    .form-group input[type="text"],
    .form-group input[type="email"],
    .form-group input[type="tel"],
    .form-group input[type="date"],
    .form-group select,
    .form-group textarea {
        padding: 10px 12px; /* slightly smaller padding */
    }

    .form-card {
        padding: 14px; /* less interior padding for the card */
    }

    .student-card {
        padding: 10px;
        margin-bottom: 10px;
    }

    .form-footnote {
        margin-top: 8px;
        font-size: 0.9rem;
        padding: 8px 10px;
    }
}

/* Ensure the file control stacks well on very small screens */
@media (max-width: 480px) {
    .file-input-wrapper { flex-direction: column; align-items: stretch; }
    .file-input-wrapper .file-name { max-width: 100%; }
    .file-input-wrapper .file-btn { width: 100%; text-align: center; }
    .file-input-wrapper .file-preview img { max-width: 100%; height: auto; }
}