/* ════════════════════════════════════════════════════════════════
   SchoolCTL — Global Stylesheet
   ════════════════════════════════════════════════════════════════ */

/* ── Reset & Variables ─────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
    --navy: #0e1540;
    --navy-deep: #080d2b;
    --navy-light: #162055;
    --blue: #0088ff;
    --blue-light: #39a0ff;
    --blue-glow: rgba(0, 136, 255, 0.15);
    --blue-subtle: rgba(0, 136, 255, 0.08);
    --accent: #00d4aa;
    --accent-warm: #ff6b35;
    --white: #ffffff;
    --off-white: #f4f7fb;
    --gray-50: #f8fafc;
    --gray-100: #eef2f7;
    --gray-200: #dce3ed;
    --gray-300: #b8c4d4;
    --gray-400: #8896aa;
    --gray-500: #64748b;
    --gray-600: #475569;
    --gray-700: #334155;
    --text-primary: #0f172a;
    --text-secondary: #475569;
    --text-muted: #94a3b8;
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --shadow-sm: 0 1px 3px rgba(14,21,64,0.06);
    --shadow-md: 0 4px 20px rgba(14,21,64,0.08);
    --shadow-lg: 0 10px 40px rgba(14,21,64,0.12);
    --shadow-xl: 0 20px 60px rgba(14,21,64,0.16);
    --shadow-blue: 0 8px 30px rgba(0,136,255,0.25);
    --font-display: 'Bricolage Grotesque', serif;
    --font-body: 'DM Sans', sans-serif;
    --transition: 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

html { scroll-behavior: smooth; scroll-padding-top: 80px; }
body {
    font-family: var(--font-body);
    color: var(--text-primary);
    background: var(--white);
    line-height: 1.6;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* ── Utility ───────────────────────────────────────────────── */
.container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
.section-pad { padding: 100px 0; }
@media (max-width: 768px) { .section-pad { padding: 64px 0; } }

.badge {
    display: inline-flex; align-items: center; gap: 6px;
    padding: 6px 16px; border-radius: 100px;
    font-size: 0.8rem; font-weight: 600; letter-spacing: 0.03em;
    text-transform: uppercase;
}
.badge--blue { background: var(--blue-subtle); color: var(--blue); }
.badge--navy { background: rgba(255,255,255,0.1); color: rgba(255,255,255,0.8); }
.badge--accent { background: rgba(0,212,170,0.1); color: var(--accent); }

.section-eyebrow {
    font-family: var(--font-display);
    font-size: 0.85rem; font-weight: 700;
    text-transform: uppercase; letter-spacing: 0.1em;
    color: var(--blue); margin-bottom: 12px;
}
.section-title {
    font-family: var(--font-display);
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800; line-height: 1.15;
    margin-bottom: 16px; color: var(--text-primary);
}
.section-title--light { color: var(--white); }
.section-subtitle {
    font-size: 1.1rem; color: var(--text-secondary);
    max-width: 560px; line-height: 1.7;
}
.section-subtitle--light { color: rgba(255,255,255,0.65); }

/* ── SVG Icon Base ─────────────────────────────────────────── */
.icon {
    width: 24px; height: 24px; flex-shrink: 0;
    fill: none; stroke: currentColor; stroke-width: 2;
    stroke-linecap: round; stroke-linejoin: round;
}
.icon--sm { width: 18px; height: 18px; }
.icon--lg { width: 32px; height: 32px; }
.icon-box {
    width: 48px; height: 48px; border-radius: var(--radius-md);
    display: grid; place-items: center; flex-shrink: 0;
}
.icon-box--blue { background: var(--blue-subtle); color: var(--blue); }
.icon-box--navy { background: rgba(14,21,64,0.06); color: var(--navy); }
.icon-box--accent { background: rgba(0,212,170,0.1); color: var(--accent); }
.icon-box--warm { background: rgba(255,107,53,0.1); color: var(--accent-warm); }

/* ── Navigation (Transparent → Solid on scroll) ────────────── */
.nav {
    position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
    background: transparent;
    transition: background 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
    border-bottom: 1px solid transparent;
}
.nav--scrolled {
    background: rgba(255,255,255,0.95);
    backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px);
    box-shadow: var(--shadow-md);
    border-bottom-color: rgba(14,21,64,0.06);
}
.nav__inner {
    display: flex; align-items: center; justify-content: space-between;
    height: 72px; max-width: 1200px; margin: 0 auto; padding: 0 24px;
}

/* Logo switching */
.nav__logo { display: flex; align-items: center; text-decoration: none; }
.nav__logo-img { height: 32px; width: auto; transition: opacity 0.3s ease; }
.nav__logo-img--dark { display: none; }
.nav--scrolled .nav__logo-img--white { display: none; }
.nav--scrolled .nav__logo-img--dark { display: block; }

/* Nav on light pages (contact, demo) */
.nav--light { background: var(--white); border-bottom-color: var(--gray-100); }
.nav--light .nav__logo-img--white { display: none; }
.nav--light .nav__logo-img--dark { display: block; }
.nav--light .nav__links a { color: var(--text-secondary); }
.nav--light .nav__links a:hover { color: var(--navy); }
.nav--light .nav__toggle span { background: var(--navy); }

.nav__links { display: flex; align-items: center; gap: 32px; list-style: none; }
.nav__links a {
    text-decoration: none; color: rgba(255,255,255,0.7);
    font-size: 0.92rem; font-weight: 500; transition: var(--transition);
    position: relative;
}
.nav__links a::after {
    content: ''; position: absolute; bottom: -4px; left: 0;
    width: 0; height: 2px; background: var(--blue);
    border-radius: 2px; transition: var(--transition);
}
.nav__links a:hover, .nav__links a.active { color: var(--white); }
.nav__links a:hover::after, .nav__links a.active::after { width: 100%; }
.nav--scrolled .nav__links a { color: var(--text-secondary); }
.nav--scrolled .nav__links a:hover, .nav--scrolled .nav__links a.active { color: var(--navy); }

.nav__cta {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 10px 24px; border-radius: 100px;
    background: var(--blue); color: var(--white) !important;
    font-size: 0.9rem; font-weight: 600;
    transition: var(--transition);
}
.nav__cta:hover { background: var(--blue-light); transform: translateY(-1px); box-shadow: var(--shadow-blue); }
.nav__cta::after { display: none !important; }

/* Mobile nav */
.nav__toggle {
    display: none; background: none; border: none; cursor: pointer;
    width: 32px; height: 32px; position: relative; z-index: 10;
}
.nav__toggle span {
    display: block; width: 22px; height: 2px; background: var(--white);
    border-radius: 2px; transition: var(--transition);
    position: absolute; left: 5px;
}
.nav--scrolled .nav__toggle span { background: var(--navy); }
.nav__toggle span:nth-child(1) { top: 9px; }
.nav__toggle span:nth-child(2) { top: 15px; }
.nav__toggle span:nth-child(3) { top: 21px; }
.nav__toggle.active span:nth-child(1) { transform: rotate(45deg); top: 15px; }
.nav__toggle.active span:nth-child(2) { opacity: 0; }
.nav__toggle.active span:nth-child(3) { transform: rotate(-45deg); top: 15px; }

@media (max-width: 768px) {
    .nav__toggle { display: block; }
    .nav__links {
        position: fixed; top: 0; right: -100%; width: 280px; height: 100vh;
        flex-direction: column; padding: 100px 32px 32px;
        background: var(--white); box-shadow: var(--shadow-xl);
        transition: right 0.35s ease; gap: 20px;
    }
    .nav__links.open { right: 0; }
    .nav__links a { font-size: 1.05rem; color: var(--text-secondary) !important; }
    .nav__links a:hover { color: var(--navy) !important; }
}

/* ── Buttons ───────────────────────────────────────────────── */
.btn {
    display: inline-flex; align-items: center; gap: 8px;
    padding: 14px 32px; border-radius: 100px;
    font-family: var(--font-body); font-size: 0.95rem; font-weight: 600;
    text-decoration: none; transition: var(--transition);
    border: none; cursor: pointer;
}
.btn--primary {
    background: var(--blue); color: var(--white);
    box-shadow: 0 4px 20px rgba(0,136,255,0.3);
}
.btn--primary:hover { background: var(--blue-light); transform: translateY(-2px); box-shadow: var(--shadow-blue); }
.btn--outline {
    background: transparent; color: var(--white);
    border: 1.5px solid rgba(255,255,255,0.25);
}
.btn--outline:hover { border-color: var(--blue); color: var(--blue); background: rgba(0,136,255,0.05); }
.btn--outline-dark {
    background: transparent; color: var(--navy);
    border: 1.5px solid var(--gray-200);
}
.btn--outline-dark:hover { border-color: var(--blue); color: var(--blue); }
.btn--dark { background: var(--navy); color: var(--white); }
.btn--dark:hover { background: var(--navy-light); transform: translateY(-2px); }
.btn--accent { background: var(--accent); color: var(--navy); }
.btn--accent:hover { filter: brightness(1.1); transform: translateY(-2px); }

/* ── Forms ─────────────────────────────────────────────────── */
.form-card {
    background: var(--white); border: 1px solid var(--gray-100);
    border-radius: var(--radius-lg); padding: 36px;
}
.form-card--dark {
    background: rgba(255,255,255,0.04); border-color: rgba(255,255,255,0.08);
    backdrop-filter: blur(10px);
}
.form-card__title {
    font-family: var(--font-display); font-size: 1.3rem;
    font-weight: 700; margin-bottom: 4px; color: var(--text-primary);
}
.form-card--dark .form-card__title { color: var(--white); }
.form-card__subtitle {
    font-size: 0.88rem; margin-bottom: 24px; color: var(--text-secondary);
}
.form-card--dark .form-card__subtitle { color: rgba(255,255,255,0.5); }

.form-group { margin-bottom: 16px; }
.form-group label {
    display: block; font-size: 0.82rem; font-weight: 600;
    margin-bottom: 6px; color: var(--text-primary);
}
.form-card--dark .form-group label { color: rgba(255,255,255,0.7); }

.form-input, .form-select, .form-textarea {
    width: 100%; padding: 12px 16px; border-radius: var(--radius-sm);
    font-family: var(--font-body); font-size: 0.92rem;
    transition: var(--transition); outline: none;
    background: var(--gray-50); border: 1px solid var(--gray-200);
    color: var(--text-primary);
}
.form-input::placeholder, .form-textarea::placeholder { color: var(--gray-400); }
.form-input:focus, .form-select:focus, .form-textarea:focus {
    border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-glow);
    background: var(--white);
}

/* Dark form inputs */
.form-card--dark .form-input,
.form-card--dark .form-select,
.form-card--dark .form-textarea {
    background: rgba(255,255,255,0.06); border-color: rgba(255,255,255,0.12);
    color: var(--white);
}
.form-card--dark .form-input::placeholder,
.form-card--dark .form-textarea::placeholder { color: rgba(255,255,255,0.3); }
.form-card--dark .form-input:focus,
.form-card--dark .form-select:focus,
.form-card--dark .form-textarea:focus {
    border-color: var(--blue); box-shadow: 0 0 0 3px rgba(0,136,255,0.15);
}
.form-card--dark .form-select option { background: var(--navy); color: var(--white); }

.form-textarea { resize: vertical; min-height: 90px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 600px) { .form-row { grid-template-columns: 1fr; } }

.form-btn {
    width: 100%; padding: 14px; border-radius: var(--radius-sm);
    font-family: var(--font-body); font-size: 0.95rem; font-weight: 700;
    border: none; cursor: pointer; transition: var(--transition);
    margin-top: 8px; background: var(--blue); color: var(--white);
}
.form-btn:hover { background: var(--blue-light); transform: translateY(-1px); box-shadow: var(--shadow-blue); }
.form-btn--navy { background: var(--navy); }
.form-btn--navy:hover { background: var(--navy-light); }

.form-success {
    background: rgba(0,212,170,0.08); border: 1px solid rgba(0,212,170,0.2);
    border-radius: var(--radius-md); padding: 28px; text-align: center;
}
.form-success__title {
    font-family: var(--font-display); font-weight: 700;
    font-size: 1.1rem; margin-bottom: 6px; color: var(--text-primary);
}
.form-success__desc { font-size: 0.88rem; color: var(--text-secondary); }

.form-error {
    background: rgba(255,59,48,0.06); border: 1px solid rgba(255,59,48,0.15);
    border-radius: var(--radius-sm); padding: 12px 16px;
    font-size: 0.85rem; color: #dc2626; margin-bottom: 16px;
}

/* ── Footer ────────────────────────────────────────────────── */
.footer {
    background: var(--navy-deep); padding: 60px 0 32px;
    border-top: 1px solid rgba(255,255,255,0.06);
}
.footer__logo-link { display: inline-block; }
.footer__logo-link img { height: 36px; width: auto; }
.footer__grid {
    display: grid; grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px; margin-bottom: 48px;
}
.footer__brand-desc {
    font-size: 0.88rem; color: rgba(255,255,255,0.4);
    line-height: 1.65; margin-top: 16px; max-width: 300px;
}
.footer__recognition {
    font-size: 0.75rem; color: rgba(255,255,255,0.25);
    margin-top: 12px; font-style: italic;
}
.footer__heading {
    font-family: var(--font-display); font-size: 0.85rem;
    font-weight: 700; color: rgba(255,255,255,0.6);
    text-transform: uppercase; letter-spacing: 0.08em;
    margin-bottom: 16px;
}
.footer__links { list-style: none; }
.footer__links li { margin-bottom: 10px; }
.footer__links a {
    text-decoration: none; color: rgba(255,255,255,0.4);
    font-size: 0.88rem; transition: var(--transition);
}
.footer__links a:hover { color: var(--blue); }
.footer__bottom {
    border-top: 1px solid rgba(255,255,255,0.06);
    padding-top: 24px; display: flex; justify-content: space-between;
    align-items: center; flex-wrap: wrap; gap: 16px;
}
.footer__copy { font-size: 0.82rem; color: rgba(255,255,255,0.3); }
.footer__powered { font-size: 0.82rem; color: rgba(255,255,255,0.25); }
.footer__powered a { color: var(--blue); text-decoration: none; }
.footer__powered a:hover { text-decoration: underline; }
.footer__legal { display: flex; gap: 24px; }
.footer__legal a {
    font-size: 0.82rem; color: rgba(255,255,255,0.3);
    text-decoration: none; transition: var(--transition);
}
.footer__legal a:hover { color: var(--blue); }

@media (max-width: 768px) { .footer__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) {
    .footer__grid { grid-template-columns: 1fr; }
    .footer__bottom { flex-direction: column; text-align: center; }
}

/* ── Animations ────────────────────────────────────────────── */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(24px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}
.reveal {
    opacity: 0; transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible { opacity: 1; transform: translateY(0); }
.reveal-delay-1 { transition-delay: 0.1s; }
.reveal-delay-2 { transition-delay: 0.2s; }
.reveal-delay-3 { transition-delay: 0.3s; }

/* ── Cloudflare widget ─────────────────────────────────────── */
.cf-turnstile { margin-top: 8px; margin-bottom: 4px; }

/* ── Error Pages ───────────────────────────────────────────── */
.error-page {
    min-height: 100vh; display: flex; align-items: center; justify-content: center;
    background: var(--navy-deep); text-align: center; padding: 40px 24px;
}
.error-page__code {
    font-family: var(--font-display); font-size: clamp(5rem, 15vw, 10rem);
    font-weight: 800; color: rgba(0,136,255,0.15); line-height: 1;
    margin-bottom: -20px;
}
.error-page__title {
    font-family: var(--font-display); font-size: clamp(1.5rem, 3vw, 2.2rem);
    font-weight: 700; color: var(--white); margin-bottom: 12px;
}
.error-page__desc {
    font-size: 1rem; color: rgba(255,255,255,0.5);
    max-width: 400px; margin: 0 auto 32px; line-height: 1.7;
}
.error-page__logo { margin-bottom: 40px; }
.error-page__logo img { height: 36px; width: auto; opacity: 0.6; }

/* ── Page Header (for inner pages) ─────────────────────────── */
.page-header {
    background: var(--navy-deep); padding: 140px 0 80px;
    position: relative; overflow: hidden;
}
.page-header__bg {
    position: absolute; inset: 0;
    background:
        radial-gradient(ellipse 60% 50% at 70% 40%, rgba(0,136,255,0.12), transparent),
        radial-gradient(ellipse 40% 60% at 20% 80%, rgba(0,212,170,0.06), transparent);
}
.page-header__content { position: relative; z-index: 2; max-width: 640px; }
.page-header__title {
    font-family: var(--font-display); font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 800; color: var(--white); margin-bottom: 12px; line-height: 1.15;
}
.page-header__desc {
    font-size: 1.1rem; color: rgba(255,255,255,0.55); line-height: 1.7;
}
