/* ============================================
   SP International School
   Cinematic · Minimal · Apple-inspired
   ============================================ */

:root {
    /* Pure light canvas */
    --bg: #FFFFFF;
    --bg-soft: #F8F9FB;
    --bg-elevated: #F3F5F8;
    --surface: #FFFFFF;
    --surface-2: #FAFBFC;

    /* Text — deep navy that harmonizes with the logo's sky-blue shield */
    --text: #0E2A47;
    --text-soft: rgba(14,42,71,0.78);
    --text-muted: rgba(14,42,71,0.55);
    --text-faint: rgba(14,42,71,0.25);

    /* Inverse (for dark accents on light bg) */
    --inverse: #FFFFFF;

    /* Accent — burnished gold, calibrated for AA contrast on white */
    --accent: #B8860B;
    --accent-strong: #8B6508;
    --accent-soft: #C9890F;
    --accent-glow: rgba(184,134,11,0.28);
    --blue: #4A90E2;

    /* Lines */
    --border: rgba(10,10,10,0.08);
    --border-strong: rgba(10,10,10,0.16);

    /* Shadows */
    --shadow-sm: 0 1px 2px rgba(0,0,0,0.04), 0 1px 4px rgba(0,0,0,0.04);
    --shadow-md: 0 4px 12px rgba(0,0,0,0.06), 0 2px 6px rgba(0,0,0,0.04);
    --shadow-lg: 0 20px 50px rgba(0,0,0,0.08), 0 8px 24px rgba(0,0,0,0.05);

    /* Type — single Inter font for everything */
    --font: 'Plus Jakarta Sans', -apple-system, BlinkMacSystemFont, system-ui, sans-serif;

    /* Easing */
    --ease: cubic-bezier(0.25, 0.46, 0.45, 0.94);
    --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
}

*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    scroll-padding-top: 80px;
}

html.nofx { scroll-behavior: auto; }

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    line-height: 1.5;
    overflow-x: hidden;
    font-weight: 400;
}

img { max-width: 100%; height: auto; display: block; }
button { font-family: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }

/* ===== SPLASH INTRO ===== */
.splash {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
}

.splash.fade-bg {
    background: #FFFFFF;
    pointer-events: none;
}

.splash.reveal {
    background: transparent;
    transition: background 0.8s var(--ease-out);
}

.splash.done {
    display: none;
}

.splash-content {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* Splash logo */
.splash-logo {
    width: 220px;
    height: 220px;
    object-fit: contain;
    opacity: 0;
    transform: scale(0.6);
    filter: drop-shadow(0 16px 48px rgba(184,134,11,0.25));
    z-index: 10000;
    transition: opacity 1s var(--ease-out), transform 1s var(--ease-out);
}

.splash-logo.visible {
    opacity: 1;
    transform: scale(1);
}

/* Flying state for both logo and name */
.splash-logo.fly {
    position: fixed;
    transition: left 1.2s cubic-bezier(0.4, 0, 0.2, 1),
                top 1.2s cubic-bezier(0.4, 0, 0.2, 1),
                width 1.2s cubic-bezier(0.4, 0, 0.2, 1),
                height 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10000;
}

.splash-name.fly {
    position: fixed !important;
    transition: left 1.2s cubic-bezier(0.4, 0, 0.2, 1),
                top 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 10000;
    transform: none !important;
    opacity: 1 !important;
}

.splash-name.fly .splash-name-text {
    transition: font-size 1.2s cubic-bezier(0.4, 0, 0.2, 1);
    clip-path: none !important;
    animation: none !important;
}

/* Splash school name — absolute so it doesn't push logo */
.splash-name {
    position: absolute;
    top: calc(100% + 2rem);
    left: 50%;
    transform: translateX(-50%);
    opacity: 0;
    white-space: nowrap;
}

.splash-name.visible {
    opacity: 1;
}

.splash-name-text {
    font-family: var(--font);
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 800;
    letter-spacing: -0.025em;
    color: var(--text);
    white-space: nowrap;
    display: inline-block;
}

/* Splash slogan */
.splash-slogan {
    position: absolute;
    top: calc(100% + 7rem);
    left: 50%;
    transform: translateX(-50%);
    font-family: 'Quicksand', system-ui, sans-serif;
    font-size: clamp(1.125rem, 2.6vw, 1.5rem);
    font-weight: 500;
    letter-spacing: 0.06em;
    text-transform: none;
    color: #C41E3A;
    opacity: 0;
    white-space: nowrap;
}

.splash-slogan.visible {
    opacity: 1;
    transition: opacity 0.8s var(--ease-out);
}

.splash-slogan.fade-out {
    opacity: 0;
    transition: opacity 0.4s var(--ease);
}

/* Writing reveal — smooth left to right */
.splash-name-text.writing {
    clip-path: inset(0 100% 0 0);
    animation: penReveal 1.8s cubic-bezier(0.25, 0.1, 0.25, 1) forwards;
}

@keyframes penReveal {
    0%   { clip-path: inset(0 100% 0 0); }
    100% { clip-path: inset(0 0% 0 0); }
}

/* Body state during splash */
body.splash-active {
    overflow: hidden;
}

body.splash-active .nav,
body.splash-active .hero {
    opacity: 0;
}

body.splash-active .brand-name {
    opacity: 0;
}

.brand-name.splash-hidden {
    opacity: 0 !important;
}

.nav {
    transition: opacity 0.6s var(--ease-out);
}

/* ===== FLOATING SCHOOL ELEMENTS ===== */
.school-floats {
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: 0;
    overflow: hidden;
}

.float-item {
    position: absolute;
    opacity: 0;
    pointer-events: auto;
    cursor: default;
    transition: transform 0.4s var(--ease-out), opacity 0.4s;
    will-change: transform;
}

/* Fade in from left */
.float-item.float-from-left {
    transform: translateX(-60px) rotate(-10deg);
}
.float-item.float-from-left.visible {
    opacity: 1;
    transform: translateX(0) rotate(0deg);
    transition: opacity 1s var(--ease-out), transform 1s var(--ease-out);
}

/* Fade in from right */
.float-item.float-from-right {
    transform: translateX(60px) rotate(10deg);
}
.float-item.float-from-right.visible {
    opacity: 1;
    transform: translateX(0) rotate(0deg);
    transition: opacity 1s var(--ease-out), transform 1s var(--ease-out);
}

/* Floating animation — each item gets a unique one via data-speed */
.float-item.visible {
    animation: schoolFloat var(--float-dur, 6s) ease-in-out infinite;
    animation-delay: var(--float-delay, 0s);
}

@keyframes schoolFloat {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    25%      { transform: translateY(-10px) rotate(2deg); }
    75%      { transform: translateY(8px) rotate(-2deg); }
}

/* Hover — pop and spin */
.float-item:hover {
    animation-play-state: paused;
    transform: scale(1.4) rotate(15deg) !important;
    opacity: 0.9 !important;
    filter: drop-shadow(0 4px 12px rgba(0,0,0,0.15));
    transition: transform 0.3s var(--ease-out), filter 0.3s, opacity 0.3s;
}

/* Hide on small screens */
@media (max-width: 768px) {
    .school-floats { display: none; }
}

/* ===== TYPOGRAPHY SCALE ===== */
.eyebrow {
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--accent);
    margin-bottom: 1.5rem;
}

.display {
    font-family: var(--font);
    font-size: clamp(2.5rem, 7vw, 6rem);
    font-weight: 600;
    line-height: 1.02;
    letter-spacing: -0.025em;
    color: var(--text);
    font-variation-settings: "opsz" 144;
}

.display-sm {
    font-family: var(--font);
    font-size: clamp(2rem, 5vw, 4rem);
    font-weight: 600;
    line-height: 1.05;
    letter-spacing: -0.02em;
    color: var(--text);
    font-variation-settings: "opsz" 96;
}

h1, h2, h3 {
    font-family: var(--font);
    font-weight: 600;
    letter-spacing: -0.02em;
    font-variation-settings: "opsz" 72;
}

.lead {
    font-size: clamp(1.0625rem, 1.4vw, 1.25rem);
    line-height: 1.6;
    color: var(--text-soft);
    font-weight: 400;
    max-width: 640px;
}

.text-muted { color: var(--text-muted); }

.gradient-text {
    background: linear-gradient(135deg, #FDB913 0%, #FFD451 50%, #FDB913 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
}

.container-wide {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.875rem 1.75rem;
    border-radius: 100px;
    font-size: 0.9375rem;
    font-weight: 500;
    border: none;
    transition: all 0.4s var(--ease-out);
    white-space: nowrap;
}

.btn-primary {
    background: var(--text);
    color: var(--inverse);
}

.btn-primary:hover {
    background: #1a1a1a;
    color: var(--inverse);
    transform: translateY(-2px);
    box-shadow: 0 16px 40px rgba(0,0,0,0.18);
}

.btn-ghost {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border-strong);
}

.btn-ghost:hover {
    background: rgba(10,10,10,0.04);
    border-color: var(--text);
}

.btn-ghost .arrow {
    transition: transform 0.4s var(--ease-out);
}

.btn-ghost:hover .arrow {
    transform: translateX(4px);
}

.btn-lg {
    padding: 1.125rem 2.25rem;
    font-size: 1rem;
}

.btn-block {
    width: 100%;
    justify-content: center;
    padding: 1.125rem;
}

/* ===== NAVIGATION ===== */
.nav {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 1rem 0;
    transition: background 0.4s var(--ease), backdrop-filter 0.4s var(--ease), -webkit-backdrop-filter 0.4s var(--ease);
}

.nav.scrolled {
    background: rgba(255,255,255,0.85);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
}

.nav-inner {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    transition: transform 0.4s var(--ease-out);
}

.nav-brand:hover { transform: translateY(-1px); }

.brand-mark {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: radial-gradient(circle at 30% 30%, #ffffff 0%, #f4f7fc 70%, #e8eef7 100%);
    box-shadow:
        0 1px 0 rgba(255,255,255,0.9) inset,
        0 0 0 1px rgba(14,42,71,0.08),
        0 6px 18px rgba(14,42,71,0.10);
    overflow: hidden;
    position: relative;
    transition: box-shadow 0.4s var(--ease-out), transform 0.5s var(--ease-out);
    color: var(--inverse);
    font-weight: 800;
    font-size: 0.8125rem;
    letter-spacing: -0.02em;
}

.brand-mark img {
    width: 86%;
    height: 86%;
    object-fit: contain;
    display: block;
    filter: drop-shadow(0 1px 2px rgba(14,42,71,0.15));
    transition: transform 0.6s var(--ease-out);
}

.brand-mark::after {
    /* Subtle light sweep on hover */
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(115deg, transparent 35%, rgba(255,255,255,0.7) 50%, transparent 65%);
    transform: translateX(-120%);
    transition: transform 0.8s var(--ease-out);
    pointer-events: none;
}

.nav-brand:hover .brand-mark {
    box-shadow:
        0 1px 0 rgba(255,255,255,0.9) inset,
        0 0 0 1px rgba(212,160,23,0.35),
        0 12px 28px rgba(14,42,71,0.18);
}
.nav-brand:hover .brand-mark img { transform: scale(1.06) rotate(-3deg); }
.nav-brand:hover .brand-mark::after { transform: translateX(120%); }

.brand-mark.large {
    width: 56px;
    height: 56px;
    border-radius: 14px;
}

.brand-name {
    font-family: var(--font);
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.15;
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 0.5rem;
    align-items: center;
    margin-left: auto;
    margin-right: 2rem;
}

.nav-links a,
.nav-link-btn {
    display: inline-block;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    font-weight: 400;
    color: var(--text-soft);
    background: none;
    border: none;
    transition: all 0.3s var(--ease);
    border-radius: 8px;
    font-family: inherit;
    position: relative;
}

.nav-links a::after {
    content: '';
    position: absolute;
    bottom: 2px;
    left: 50%;
    width: 0;
    height: 2px;
    background: var(--accent);
    border-radius: 2px;
    transition: all 0.3s var(--ease-out);
    transform: translateX(-50%);
}

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

.nav-links a:hover::after {
    width: 60%;
}

.nav-link-btn:hover {
    color: var(--text);
}

.nav-portal {
    display: inline-block;
    padding: 0.5rem 1.25rem;
    background: linear-gradient(135deg, #D4A017 0%, #FDB913 100%);
    color: #fff;
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 600;
    transition: all 0.3s var(--ease);
    box-shadow: 0 2px 8px rgba(253,185,19,0.25);
}

.nav-portal:hover {
    background: linear-gradient(135deg, #B8860B 0%, #D4A017 100%);
    color: #fff;
    transform: translateY(-1px);
    box-shadow: 0 6px 16px rgba(253,185,19,0.3);
}

.nav-cta {
    display: inline-block;
    padding: 0.5rem 1.25rem;
    background: var(--text);
    color: var(--inverse);
    border-radius: 100px;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s var(--ease);
}

.nav-cta:hover {
    background: #1a1a1a;
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(0,0,0,0.15);
}

.nav-portal-wrapper {
    position: relative;
}

.nav-dropdown {
    position: absolute;
    top: calc(100% + 8px);
    left: 50%;
    transform: translateX(-50%) translateY(-4px);
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 0.5rem;
    min-width: 200px;
    box-shadow: var(--shadow-lg);
    opacity: 0;
    visibility: hidden;
    transition: all 0.25s var(--ease);
}

.nav-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateX(-50%) translateY(0);
}

.nav-dropdown a {
    display: block;
    padding: 0.625rem 0.875rem;
    font-size: 0.875rem;
    color: var(--text-soft);
    border-radius: 8px;
    transition: all 0.2s var(--ease);
}

.nav-dropdown a:hover {
    background: rgba(10,10,10,0.05);
    color: var(--text);
}

.nav-burger {
    display: none;
    flex-direction: column;
    gap: 5px;
    background: none;
    border: none;
    padding: 8px;
}

.nav-burger span {
    width: 22px;
    height: 1.5px;
    background: var(--text);
    border-radius: 2px;
    transition: all 0.3s var(--ease);
}

/* ============================================
   1. HERO — Split layout, logo right, gold accents
   ============================================ */
.hero {
    position: relative;
    height: 100vh;
    min-height: 720px;
    max-height: 1080px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    padding: 7rem 2rem 4rem;
}

.hero-bg {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 70% 60% at 75% 50%, rgba(253,185,19,0.04) 0%, transparent 60%),
        radial-gradient(ellipse 80% 50% at 20% 40%, rgba(74,144,226,0.03) 0%, transparent 60%),
        linear-gradient(180deg, #FFFFFF 0%, #FAFBFD 50%, #F7F8FC 100%);
    z-index: 0;
}

.hero-grid {
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(14,42,71,0.04) 1px, transparent 1px),
        linear-gradient(90deg, rgba(14,42,71,0.04) 1px, transparent 1px);
    background-size: 80px 80px;
    mask-image: radial-gradient(ellipse 60% 50% at 50% 50%, #000 30%, transparent 80%);
    -webkit-mask-image: radial-gradient(ellipse 60% 50% at 50% 50%, #000 30%, transparent 80%);
    z-index: 1;
}

/* Split layout */
.hero-split {
    position: relative;
    z-index: 2;
    max-width: 1280px;
    margin: 0 auto;
    width: 100%;
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 4rem;
    align-items: center;
}

.hero-left {
    text-align: left;
}

.hero-right {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Logo on right side */
.hero-logo-wrapper {
    position: relative;
    width: 400px;
    height: 400px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hero-logo-glow {
    position: absolute;
    inset: -20%;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(14,42,71,0.06) 0%, rgba(14,42,71,0.02) 40%, transparent 70%);
    animation: logoGlow 4s ease-in-out infinite;
}

@keyframes logoGlow {
    0%, 100% { transform: scale(1); opacity: 0.8; }
    50%      { transform: scale(1.08); opacity: 1; }
}

.hero-logo-img {
    width: 340px;
    height: 340px;
    object-fit: contain;
    filter: drop-shadow(0 12px 40px rgba(184,134,11,0.25));
    transition: transform 0.6s var(--ease-out), filter 0.6s var(--ease-out), opacity 0.3s;
    animation: logoFloat 6s ease-in-out infinite;
}

/* Hidden until splash logo lands */
.hero-logo-img.hidden-for-splash {
    opacity: 0 !important;
}

.hero-logo-img:hover {
    transform: scale(1.05) rotate(-2deg);
    filter: drop-shadow(0 20px 50px rgba(184,134,11,0.35));
}

@keyframes logoFloat {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(-12px); }
}

/* Hero badge — gold pill */
.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    background: rgba(14,42,71,0.05);
    border: 1px solid rgba(14,42,71,0.1);
    color: var(--text);
    border-radius: 100px;
    font-size: 0.8125rem;
    font-weight: 600;
    margin-bottom: 2rem;
    margin-top: 1.5rem;
}
.hero-badge-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #FDB913;
    box-shadow: 0 0 12px rgba(253,185,19,0.6);
    animation: pulseDot 2s ease-in-out infinite;
}
@keyframes pulseDot {
    0%, 100% { opacity: 1; transform: scale(1); }
    50%      { opacity: 0.5; transform: scale(0.85); }
}

.hero-title {
    font-family: var(--font);
    font-size: clamp(2.75rem, 6vw, 5.5rem);
    font-weight: 800;
    line-height: 1.05;
    letter-spacing: -0.035em;
    color: var(--text);
    margin-bottom: 1.75rem;
}

.hero-title-gold {
    background: linear-gradient(135deg, #D4A017 0%, #FDB913 40%, #FFD451 70%, #D4A017 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.hero-sub {
    font-size: clamp(1.0625rem, 1.3vw, 1.1875rem);
    color: var(--text-soft);
    max-width: 520px;
    margin-bottom: 2.5rem;
    font-weight: 400;
    line-height: 1.65;
}

/* Gold buttons */
.btn-gold {
    background: linear-gradient(135deg, #D4A017 0%, #FDB913 100%);
    color: #fff;
    font-weight: 600;
    box-shadow: 0 4px 16px rgba(253,185,19,0.3);
}
.btn-gold:hover {
    background: linear-gradient(135deg, #B8860B 0%, #D4A017 100%);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(253,185,19,0.35);
}

.btn-ghost-gold {
    background: transparent;
    color: var(--accent-strong);
    border: 1.5px solid var(--accent);
}
.btn-ghost-gold:hover {
    background: rgba(253,185,19,0.08);
    border-color: var(--accent-strong);
}
.btn-ghost-gold .arrow {
    transition: transform 0.4s var(--ease-out);
}
.btn-ghost-gold:hover .arrow {
    transform: translateX(4px);
}

.hero-actions {
    display: flex;
    gap: 0.875rem;
    flex-wrap: wrap;
    margin-bottom: 3rem;
}

/* Hero features card */
.hero-features {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    padding: 1rem 1.5rem;
    background: rgba(14,42,71,0.03);
    border: 1px solid rgba(14,42,71,0.08);
    border-radius: 16px;
    flex-wrap: wrap;
    max-width: fit-content;
}

.hf-item {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    font-size: 0.875rem;
    font-weight: 500;
    color: var(--text);
    white-space: nowrap;
}

.hf-icon {
    color: var(--accent);
    font-size: 0.625rem;
}

.hf-divider {
    width: 1px;
    height: 18px;
    background: rgba(14,42,71,0.15);
}

.hero-scroll {
    position: absolute;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
    color: var(--text-muted);
    z-index: 2;
}

/* Hero elements hidden until .hero-animate triggers them */
.hero-badge,
.hero-title,
.hero-sub,
.hero-actions,
.hero-features {
    opacity: 0;
}

/* Hero entrance — unique animations per element, triggered by .hero-animate class */
@media (prefers-reduced-motion: no-preference) {

    /* Only animate when .hero-animate is added */
    .hero-animate .hero-badge {
        animation: heroPopIn 0.6s cubic-bezier(0.16, 1, 0.3, 1) 0.04s both;
    }

    .hero-animate .hero-title {
        animation: heroSlideLeft 0.85s cubic-bezier(0.16, 1, 0.3, 1) 0.12s both;
    }

    .hero-animate .hero-sub {
        animation: heroSlideRight 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.25s both;
    }

    .hero-animate .hero-actions {
        animation: heroBounceUp 0.75s cubic-bezier(0.34, 1.4, 0.64, 1) 0.38s both;
    }

    .hero-animate .hero-features {
        animation: heroSlideUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) 0.5s both;
    }
}

@keyframes heroPopIn {
    0%   { opacity: 0; transform: scale(0.6); }
    100% { opacity: 1; transform: scale(1); }
}

@keyframes heroSlideLeft {
    0%   { opacity: 0; transform: translateX(-60px); }
    100% { opacity: 1; transform: translateX(0); }
}

@keyframes heroSlideRight {
    0%   { opacity: 0; transform: translateX(40px); }
    100% { opacity: 1; transform: translateX(0); }
}

@keyframes heroBounceUp {
    0%   { opacity: 0; transform: translateY(40px); }
    100% { opacity: 1; transform: translateY(0); }
}

@keyframes heroSlideUp {
    0%   { opacity: 0; transform: translateY(30px); }
    100% { opacity: 1; transform: translateY(0); }
}

@keyframes heroLogoReveal {
    0%   { opacity: 0; transform: scale(0.5) rotate(-10deg); }
    60%  { opacity: 1; transform: scale(1.05) rotate(2deg); }
    100% { opacity: 1; transform: scale(1) rotate(0deg); }
}

/* Disable hero entrance when nofx (for screenshots) */
html.nofx .hero-badge,
html.nofx .hero-title,
html.nofx .hero-sub,
html.nofx .hero-actions,
html.nofx .hero-features {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
}

/* Reduced motion fallback — just show immediately */
@media (prefers-reduced-motion: reduce) {
    .hero-animate .hero-badge,
    .hero-animate .hero-title,
    .hero-animate .hero-sub,
    .hero-animate .hero-actions,
    .hero-animate .hero-features {
        opacity: 1;
    }
}

.hero-scroll span {
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.25em;
    font-weight: 500;
}

.scroll-line {
    width: 1px;
    height: 48px;
    background: linear-gradient(to bottom, var(--accent), transparent);
    animation: scrollPulse 2.5s ease-in-out infinite;
}

@keyframes fadeUp {
    from { opacity: 0; transform: translateY(40px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes scrollPulse {
    0%, 100% { transform: scaleY(0.5); opacity: 0.3; transform-origin: top; }
    50% { transform: scaleY(1); opacity: 1; transform-origin: top; }
}

/* ============================================
   2. STORY
   ============================================ */
.story {
    background: var(--bg);
    padding: 7rem 2rem;
    position: relative;
}

.story-inner {
    max-width: 1100px;
    margin: 0 auto 5rem;
}

.story .display {
    margin-bottom: 2rem;
}

.story-aims {
    margin-top: 6rem;
    padding-top: 5rem;
    border-top: 1px solid var(--border);
}

.story-aims .story-inner {
    margin-bottom: 0;
}

.story-aims .display-sm {
    margin-bottom: 3rem;
}

.story-pillars {
    max-width: 1100px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3rem;
    padding-top: 4rem;
    border-top: 1px solid var(--border);
}

.pillar {
    text-align: left;
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid transparent;
    transition: all 0.4s var(--ease-out);
}

.pillar:hover {
    background: var(--bg-soft);
    border-color: var(--border);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.pillar:hover .pillar-num {
    color: var(--accent);
    transition: color 0.3s;
}

.pillar:hover h3 {
    color: var(--accent-strong);
    transition: color 0.3s;
}

.pillar-num {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.1em;
    margin-bottom: 1.5rem;
}

.pillar h3 {
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
}

.pillar p {
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--text-muted);
}

/* ============================================
   3. STATS
   ============================================ */
.stats {
    background: var(--bg-soft);
    padding: 7rem 2rem;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.stats-inner {
    max-width: 1200px;
    margin: 0 auto;
}

.stats .display-sm {
    margin-bottom: 4rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-bottom: 5rem;
}

.stat {
    border-top: 1px solid var(--border);
    padding-top: 2rem;
}

.stat-num {
    font-size: clamp(3rem, 6vw, 5rem);
    font-weight: 700;
    line-height: 1;
    letter-spacing: -0.04em;
    color: var(--text);
    margin-bottom: 1rem;
}

.stat-label {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 400;
}

.stats-chart {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 3rem;
    box-shadow: var(--shadow-sm);
}

/* ============================================
   DEFENCE FAMILIES — Proudly serving 95%
   ============================================ */
.defence {
    position: relative;
    padding: 8rem 2rem;
    background: linear-gradient(180deg, #0A1D33 0%, #081627 60%, #050F1E 100%);
    color: #F5EFE0;
    overflow: hidden;
    border-top: 1px solid rgba(184,134,11,0.25);
    border-bottom: 1px solid rgba(184,134,11,0.25);
}

.defence-bg {
    position: absolute;
    inset: 0;
    pointer-events: none;
    z-index: 0;
}

.defence-stars {
    position: absolute;
    inset: 0;
    background-image:
        radial-gradient(1.5px 1.5px at 10% 20%, rgba(255,236,180,0.55), transparent 60%),
        radial-gradient(1px 1px at 25% 70%, rgba(255,236,180,0.4), transparent 60%),
        radial-gradient(1.5px 1.5px at 45% 40%, rgba(255,236,180,0.5), transparent 60%),
        radial-gradient(1px 1px at 70% 15%, rgba(255,236,180,0.45), transparent 60%),
        radial-gradient(2px 2px at 85% 55%, rgba(255,236,180,0.55), transparent 60%),
        radial-gradient(1px 1px at 60% 80%, rgba(255,236,180,0.4), transparent 60%),
        radial-gradient(1.2px 1.2px at 15% 85%, rgba(255,236,180,0.45), transparent 60%),
        radial-gradient(1px 1px at 92% 25%, rgba(255,236,180,0.4), transparent 60%);
    opacity: 0.75;
}

.defence-glow {
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 60% 45% at 20% 10%, rgba(184,134,11,0.18) 0%, transparent 60%),
        radial-gradient(ellipse 55% 50% at 85% 90%, rgba(184,134,11,0.15) 0%, transparent 60%),
        radial-gradient(ellipse 70% 50% at 50% 50%, rgba(74,144,226,0.06) 0%, transparent 70%);
}

.defence::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image:
        linear-gradient(rgba(255,255,255,0.022) 1px, transparent 1px),
        linear-gradient(90deg, rgba(255,255,255,0.022) 1px, transparent 1px);
    background-size: 60px 60px;
    pointer-events: none;
    z-index: 0;
}

.defence-inner {
    position: relative;
    z-index: 1;
    max-width: 1200px;
    margin: 0 auto;
}

.defence-head {
    text-align: center;
    max-width: 820px;
    margin: 0 auto 5rem;
}

.defence-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1.125rem;
    border-radius: 999px;
    background: rgba(184,134,11,0.12);
    border: 1px solid rgba(212,160,23,0.4);
    color: #F0C860;
    font-size: 0.8125rem;
    font-weight: 600;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    margin-bottom: 2rem;
}

.defence-badge svg {
    color: #F0C860;
}

.defence .display {
    color: #F8F4E6;
    margin-bottom: 1.75rem;
}

.defence-gold {
    background: linear-gradient(135deg, #F5D56E 0%, #D4A017 45%, #F5D56E 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
}

.defence-muted {
    color: rgba(245,239,224,0.55);
}

.defence .lead {
    color: rgba(245,239,224,0.78);
    max-width: 720px;
    margin: 0 auto;
}

.defence-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-bottom: 5rem;
}

.defence-card {
    position: relative;
    padding: 2.5rem 2.25rem;
    background: linear-gradient(160deg, rgba(255,255,255,0.045) 0%, rgba(255,255,255,0.015) 100%);
    border: 1px solid rgba(212,160,23,0.18);
    border-radius: 22px;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    transition: all 0.4s var(--ease-out);
    overflow: hidden;
}

.defence-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(245,213,110,0.5), transparent);
}

.defence-card:hover {
    transform: translateY(-6px);
    border-color: rgba(212,160,23,0.45);
    background: linear-gradient(160deg, rgba(255,255,255,0.065) 0%, rgba(255,255,255,0.025) 100%);
    box-shadow: 0 20px 50px rgba(0,0,0,0.4), 0 0 0 1px rgba(212,160,23,0.15);
}

.defence-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border-radius: 14px;
    background: linear-gradient(135deg, rgba(245,213,110,0.15) 0%, rgba(184,134,11,0.08) 100%);
    border: 1px solid rgba(212,160,23,0.3);
    color: #F0C860;
    margin-bottom: 1.5rem;
}

.defence-card h3 {
    font-size: 1.375rem;
    font-weight: 700;
    line-height: 1.25;
    color: #F8F4E6;
    margin-bottom: 0.875rem;
    letter-spacing: -0.01em;
}

.defence-card p {
    font-size: 0.9375rem;
    line-height: 1.7;
    color: rgba(245,239,224,0.72);
}

/* Portraits — heroes & their little stars */
.defence-portraits {
    margin-top: 1rem;
    margin-bottom: 5rem;
    padding-top: 4rem;
    border-top: 1px solid rgba(212,160,23,0.18);
}

.defence-portraits-head {
    text-align: center;
    max-width: 680px;
    margin: 0 auto 3rem;
}

.defence-portraits-head .eyebrow {
    color: #F0C860;
}

.defence-portraits-head h3 {
    font-size: clamp(1.75rem, 3vw, 2.5rem);
    font-weight: 700;
    color: #F8F4E6;
    letter-spacing: -0.02em;
    margin: 0.5rem 0 1rem;
}

.defence-portraits-sub {
    color: rgba(245,239,224,0.65);
    font-size: 1rem;
    line-height: 1.6;
}

.defence-portraits-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 3rem;
    max-width: 900px;
    margin: 0 auto;
}

.defence-portrait {
    text-align: center;
}

.defence-portrait-frame {
    position: relative;
    display: block;
    width: 280px;
    max-width: 100%;
    margin: 0 auto 1.5rem;
    padding: 14px;
    filter: drop-shadow(0 25px 50px rgba(0,0,0,0.4));
}

.defence-portrait-frame::before {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, #F5D56E 0%, #D4A017 50%, #8B6508 100%);
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
}

.defence-portrait-frame::after {
    content: '';
    position: absolute;
    inset: 10px;
    background: #0A1D33;
    clip-path: polygon(50% 0%, 100% 25%, 100% 75%, 50% 100%, 0% 75%, 0% 25%);
}

.defence-portrait-alt .defence-portrait-frame::before,
.defence-portrait-alt .defence-portrait-frame::after {
    clip-path: polygon(50% 0%, 95% 18%, 100% 62%, 78% 95%, 22% 95%, 0% 62%, 5% 18%);
}

.defence-portrait-shape {
    position: relative;
    width: 100%;
    aspect-ratio: 1 / 1.05;
    overflow: hidden;
    clip-path: polygon(50% 2%, 97% 26%, 97% 74%, 50% 98%, 3% 74%, 3% 26%);
    z-index: 2;
    background: linear-gradient(160deg, rgba(184,134,11,0.2) 0%, rgba(10,29,51,0.9) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.defence-portrait-alt .defence-portrait-shape {
    clip-path: polygon(50% 2%, 93% 20%, 98% 62%, 77% 93%, 23% 93%, 2% 62%, 7% 20%);
}

.defence-portrait-shape img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.6s var(--ease-out);
}

.defence-portrait-frame:hover .defence-portrait-shape img {
    transform: scale(1.06);
}

.defence-portrait-placeholder {
    position: absolute;
    inset: 0;
    display: none;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.5rem;
    text-align: center;
    color: rgba(245,213,110,0.7);
    font-size: 0.75rem;
    letter-spacing: 0.04em;
}

.defence-portrait-shape.is-placeholder .defence-portrait-placeholder {
    display: flex;
}

.defence-portrait-ribbon {
    position: absolute;
    bottom: -4px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 3;
    padding: 0.375rem 1.25rem;
    background: linear-gradient(135deg, #D4A017 0%, #8B6508 100%);
    color: #0A1D33;
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 0.3em;
    border-radius: 4px;
    box-shadow: 0 6px 18px rgba(0,0,0,0.4);
}

.defence-portrait figcaption {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: rgba(245,239,224,0.75);
    font-style: italic;
    max-width: 320px;
    margin: 1rem auto 0;
}

/* Final quote */
.defence-quote {
    position: relative;
    max-width: 760px;
    margin: 0 auto;
    padding: 3rem 2rem;
    text-align: center;
    border-top: 1px solid rgba(212,160,23,0.2);
    border-bottom: 1px solid rgba(212,160,23,0.2);
}

.defence-quote-mark {
    font-family: Georgia, serif;
    font-size: 5rem;
    line-height: 1;
    color: rgba(245,213,110,0.35);
    margin-bottom: -1.5rem;
}

.defence-quote p {
    font-size: clamp(1.25rem, 2.4vw, 1.75rem);
    font-weight: 400;
    line-height: 1.45;
    color: rgba(245,239,224,0.9);
    letter-spacing: -0.01em;
}

.defence-quote p strong {
    background: linear-gradient(135deg, #F5D56E 0%, #D4A017 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    color: transparent;
    font-weight: 700;
}

/* ============================================
   4. VISION
   ============================================ */
.vision {
    background: var(--bg);
    padding: 9rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.vision::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 60% 40% at 50% 50%, rgba(212, 160, 23, 0.08) 0%, transparent 60%);
    z-index: 0;
}

.vision-inner {
    position: relative;
    z-index: 1;
    max-width: 1000px;
    margin: 0 auto;
}

.vision .display {
    margin-bottom: 2.5rem;
}

.vision .lead {
    margin: 0 auto;
}

/* ============================================
   LEADERSHIP
   ============================================ */
.leadership {
    background: var(--bg-soft);
    padding: 7rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.leadership-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-top: 4rem;
}

.leader-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 2.5rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.4s var(--ease-out);
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.leader-card:hover {
    border-color: var(--border-strong);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.leader-card-featured {
    grid-column: 1 / -1;
    background: linear-gradient(135deg, #FFFDF5 0%, #FFF9E6 100%);
    border-color: rgba(253,185,19,0.2);
}

.leader-avatar {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: var(--bg-elevated);
    border: 2px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-muted);
    overflow: hidden;
}

.leader-avatar svg {
    width: 28px;
    height: 28px;
}

.leader-avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.4s var(--ease-out);
}

.leader-avatar {
    transition: transform 0.5s var(--ease-out), box-shadow 0.5s var(--ease-out);
    cursor: pointer;
}

.leader-avatar:hover {
    transform: scale(2.5);
    box-shadow: 0 12px 40px rgba(0,0,0,0.18);
    z-index: 10;
}

.leader-avatar-featured {
    width: 64px;
    height: 64px;
    background: rgba(253,185,19,0.1);
    border-color: rgba(253,185,19,0.3);
    color: var(--accent);
}

.leader-avatar-featured svg {
    width: 32px;
    height: 32px;
}

.leader-info {
    flex: 1;
    min-width: 0;
}

.leader-role {
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--accent);
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.leader-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.75rem;
}

.leader-card p {
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--text-muted);
    font-style: italic;
}

/* ============================================
   5. FACILITIES — Horizontal scroll
   ============================================ */
.facilities {
    background: var(--bg-soft);
    padding: 7rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.section-head {
    margin-bottom: 4rem;
}

.section-head.center {
    text-align: center;
}

.section-head .eyebrow {
    margin-bottom: 1rem;
}

.hscroll {
    overflow-x: auto;
    overflow-y: hidden;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding: 0 2rem;
}

.hscroll::-webkit-scrollbar { display: none; }

.hscroll-track {
    display: flex;
    gap: 1.5rem;
    padding: 1rem 0 2rem;
}

.hcard {
    flex: 0 0 420px;
    height: 540px;
    border-radius: 28px;
    padding: 2.5rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    border: 1px solid var(--border);
    background: var(--surface);
    box-shadow: var(--shadow-sm);
    transition: all 0.5s var(--ease-out);
    position: relative;
    overflow: hidden;
}

.hcard::before {
    content: '';
    position: absolute;
    inset: 0;
    opacity: 0.07;
    z-index: 0;
}

.hcard-1::before { background: radial-gradient(circle at 70% 30%, #4A90E2 0%, transparent 60%); }
.hcard-2::before { background: radial-gradient(circle at 70% 30%, #10B981 0%, transparent 60%); }
.hcard-3::before { background: radial-gradient(circle at 70% 30%, #F97316 0%, transparent 60%); }
.hcard-4::before { background: radial-gradient(circle at 70% 30%, #D4A017 0%, transparent 60%); }
.hcard-5::before { background: radial-gradient(circle at 70% 30%, #8B5CF6 0%, transparent 60%); }
.hcard-6::before { background: radial-gradient(circle at 70% 30%, #EC4899 0%, transparent 60%); }

.hcard:hover {
    transform: translateY(-8px);
    border-color: var(--border-strong);
    box-shadow: var(--shadow-lg);
}

.hcard-num {
    position: relative;
    z-index: 1;
    font-size: 0.75rem;
    color: var(--text-muted);
    letter-spacing: 0.15em;
    font-weight: 500;
}

.hcard-body {
    position: relative;
    z-index: 1;
}

.hcard-tag {
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--accent);
    margin-bottom: 1rem;
    font-weight: 500;
}

.hcard h3 {
    font-size: 2rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
    line-height: 1.1;
}

.hcard-desc {
    font-size: 0.9375rem;
    line-height: 1.6;
    color: var(--text-muted);
}

/* ============================================
   6. ACADEMICS
   ============================================ */
.academics {
    background: var(--bg);
    padding: 7rem 0;
}

.academics-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-top: 4rem;
}

.acad-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 3rem 2.5rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.4s var(--ease-out);
}

.acad-card:hover {
    border-color: var(--border-strong);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.acad-card h3 {
    font-size: 1.75rem;
    font-weight: 600;
    letter-spacing: -0.02em;
    margin-bottom: 1rem;
}

.acad-card p {
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.acad-meta {
    font-size: 0.75rem;
    color: var(--accent);
    text-transform: uppercase;
    letter-spacing: 0.15em;
    font-weight: 500;
}

/* ============================================
   7. VOICES
   ============================================ */
.voices {
    background: var(--bg-soft);
    padding: 7rem 0;
    border-top: 1px solid var(--border);
    border-bottom: 1px solid var(--border);
}

.voices-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-top: 4rem;
}

.voice {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    padding: 3rem 2.5rem;
    box-shadow: var(--shadow-sm);
    transition: all 0.4s var(--ease-out);
}

.voice:hover {
    border-color: var(--border-strong);
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.voice blockquote {
    font-size: 1.0625rem;
    line-height: 1.6;
    color: var(--text);
    font-weight: 400;
    margin-bottom: 2.5rem;
    letter-spacing: -0.005em;
}

.voice figcaption {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    border-top: 1px solid var(--border);
    padding-top: 1.5rem;
}

.voice strong {
    font-size: 0.9375rem;
    font-weight: 600;
}

.voice span {
    font-size: 0.8125rem;
    color: var(--text-muted);
}

/* ============================================
   8. CTA
   ============================================ */
.cta {
    background: var(--bg);
    padding: 9rem 2rem;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.cta::before {
    content: '';
    position: absolute;
    inset: 0;
    background:
        radial-gradient(ellipse 50% 50% at 50% 100%, rgba(212, 160, 23, 0.14) 0%, transparent 60%);
    z-index: 0;
}

.cta-inner {
    position: relative;
    z-index: 1;
    max-width: 900px;
    margin: 0 auto;
}

.cta .display {
    margin-bottom: 2rem;
}

.cta .lead {
    margin: 0 auto 0.75rem;
}

.cta-deadline {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-bottom: 3rem;
}

.cta-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    flex-wrap: wrap;
}

/* ============================================
   FOOTER
   ============================================ */
.footer {
    background: var(--bg-soft);
    border-top: 1px solid var(--border);
    padding: 6rem 2rem 2rem;
}

.footer-inner {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 2fr;
    gap: 6rem;
    margin-bottom: 6rem;
}

.footer-brand-top {
    display: flex;
    align-items: center;
    gap: 1rem;
    margin-bottom: 1rem;
}

.footer-school-name {
    font-size: 1.25rem;
    font-weight: 800;
    letter-spacing: -0.02em;
    line-height: 1.2;
}

.footer-brand-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.footer-brand p {
    font-size: 0.9375rem;
    font-weight: 500;
}

.footer-muted {
    color: var(--text-muted);
    font-weight: 400 !important;
    font-size: 0.8125rem !important;
}

.footer-cols {
    display: grid;
    grid-template-columns: 1fr 1.3fr 1.6fr;
    gap: 2.5rem;
}

.footer-cols h5 {
    font-size: 0.6875rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 1.5rem;
}

.footer-cols a {
    display: block;
    font-size: 0.9375rem;
    color: var(--text-soft);
    margin-bottom: 0.875rem;
    transition: color 0.2s var(--ease);
}

.footer-cols a:hover {
    color: var(--text);
}

.footer-base {
    max-width: 1200px;
    margin: 0 auto;
    padding-top: 2rem;
    border-top: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    font-size: 0.8125rem;
    color: var(--text-muted);
}

.footer-base strong {
    color: var(--accent);
    font-weight: 500;
}

/* ============================================
   MODAL
   ============================================ */
.modal {
    display: none;
    position: fixed;
    inset: 0;
    background: rgba(10,10,10,0.45);
    backdrop-filter: blur(8px);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    padding: 2rem;
    opacity: 0;
    transition: opacity 0.3s var(--ease);
}

.modal.active {
    display: flex;
    opacity: 1;
}

.modal-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 3rem;
    max-width: 560px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    box-shadow: var(--shadow-lg);
    transform: scale(0.96) translateY(8px);
    transition: transform 0.4s var(--ease-out);
}

.modal.active .modal-card {
    transform: scale(1) translateY(0);
}

.modal-x {
    position: sticky;
    top: 0;
    float: right;
    margin-top: -0.5rem;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(10,10,10,0.05);
    border: none;
    color: var(--text-soft);
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s var(--ease);
}

.modal-x:hover {
    background: rgba(10,10,10,0.1);
    color: var(--text);
}

.modal-card h2 {
    font-size: 1.75rem;
    font-weight: 700;
    letter-spacing: -0.02em;
    margin-bottom: 0.5rem;
}

.modal-sub {
    font-size: 0.9375rem;
    color: var(--text-muted);
    margin-bottom: 2.5rem;
}

.modal-form {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

.form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1.25rem;
}

.field label {
    display: block;
    font-size: 0.75rem;
    font-weight: 500;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.08em;
    margin-bottom: 0.5rem;
}

.field input,
.field select {
    width: 100%;
    padding: 0.875rem 1rem;
    background: var(--bg-soft);
    border: 1px solid var(--border);
    border-radius: 12px;
    color: var(--text);
    font-size: 0.9375rem;
    font-family: inherit;
    transition: all 0.2s var(--ease);
}

.field input:focus,
.field select:focus {
    outline: none;
    border-color: var(--text);
    background: var(--surface);
    box-shadow: 0 0 0 4px rgba(10,10,10,0.05);
}

.field select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12' fill='none'%3E%3Cpath d='M3 5L6 8L9 5' stroke='rgba(10,10,10,0.5)' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    appearance: none;
    -webkit-appearance: none;
}

/* ============================================
   8. GALLERY
   ============================================ */
.gallery {
    background: var(--bg);
    padding: 7rem 0;
}

.gallery-subtitle {
    font-size: 1.125rem;
    font-weight: 600;
    letter-spacing: -0.01em;
    margin-bottom: 2rem;
    color: var(--text);
}

.gallery-videos {
    margin-bottom: 5rem;
}

.gallery-video-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.gallery-video-item {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    border-radius: 20px;
    overflow: hidden;
    background: var(--bg-soft);
    border: 1px solid var(--border);
    box-shadow: var(--shadow-sm);
}

.gallery-video-item iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.yt-channel-card {
    display: flex;
    align-items: center;
    gap: 2rem;
    padding: 2.5rem;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 20px;
    box-shadow: var(--shadow-sm);
    transition: all 0.4s var(--ease-out);
    margin-bottom: 2rem;
    text-decoration: none;
    color: inherit;
}

.yt-channel-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--border-strong);
}

.yt-channel-icon {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(255, 0, 0, 0.06);
    display: flex;
    align-items: center;
    justify-content: center;
}

.yt-channel-info h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
}

.yt-channel-info p {
    font-size: 0.9375rem;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 1rem;
}

.yt-channel-link {
    font-size: 0.875rem;
    font-weight: 600;
    color: #FF0000;
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
}

.yt-channel-card:hover .yt-channel-link .arrow {
    transform: translateX(4px);
}

.yt-channel-link .arrow {
    transition: transform 0.4s var(--ease-out);
}

.gallery-yt-card {
    background: var(--bg-soft) !important;
    display: flex !important;
    padding: 0 !important;
}

.gallery-yt-card a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    position: absolute;
    inset: 0;
    text-decoration: none;
    transition: background 0.3s;
}

.gallery-yt-card a:hover {
    background: rgba(255,0,0,0.03);
}

.yt-card-inner {
    text-align: center;
    padding: 2rem;
}

.yt-card-inner h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text);
    margin-top: 1rem;
    margin-bottom: 0.5rem;
}

.yt-card-inner p {
    font-size: 0.875rem;
    color: var(--text-muted);
    line-height: 1.5;
}

.gallery-yt-btn {
    margin-top: 1rem;
}

.gallery-image-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
}

.gallery-img-placeholder {
    position: relative;
    aspect-ratio: 4/3;
    border-radius: 20px;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: all 0.4s var(--ease-out);
    box-shadow: var(--shadow-sm);
}

.gallery-img-placeholder span {
    font-size: 0.875rem;
    color: var(--text-muted);
    font-weight: 500;
}

.gallery-img-placeholder:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
    border-color: var(--border-strong);
}

.gallery-img-placeholder img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.6s var(--ease-out);
}

.gallery-img-placeholder.has-image {
    background: var(--bg-soft);
}

.gallery-img-placeholder.has-image span {
    display: none;
}

.gallery-img-placeholder.has-image:hover img {
    transform: scale(1.05);
}

/* ============================================
   SPORTS DAY SLIDESHOW
   ============================================ */
.sports-slideshow-wrap {
    padding: 0 !important;
    overflow: hidden;
}

/* The slideshow container fills its parent card */
.sports-slideshow {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

/* Individual slides */
.sports-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.7s ease-in-out;
    pointer-events: none;
}

.sports-slide.active {
    opacity: 1;
    pointer-events: auto;
}

.sports-slide img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.7s ease-in-out;
}

.sports-slideshow-wrap:hover .sports-slide.active img {
    transform: scale(1.04);
}

/* Prev / Next arrows */
.sports-prev,
.sports-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(8px);
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: var(--text);
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s, background 0.3s, transform 0.3s;
    box-shadow: 0 2px 10px rgba(0,0,0,0.18);
    line-height: 1;
}

.sports-prev { left: 10px; }
.sports-next { right: 10px; }

.sports-slideshow-wrap:hover .sports-prev,
.sports-slideshow-wrap:hover .sports-next {
    opacity: 1;
}

.sports-prev:hover,
.sports-next:hover {
    background: rgba(255,255,255,1);
    transform: translateY(-50%) scale(1.1);
}

/* Dot indicators */
.sports-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 6px;
    z-index: 10;
}

.sports-dot {
    width: 7px;
    height: 7px;
    border-radius: 50%;
    background: rgba(255,255,255,0.55);
    cursor: pointer;
    transition: background 0.3s, transform 0.3s;
    border: 1.5px solid rgba(255,255,255,0.7);
}

.sports-dot.active {
    background: #ffffff;
    transform: scale(1.3);
}

/* ============================================
   ANNUAL FUNCTION SLIDESHOW
   ============================================ */
.annual-slideshow-wrap {
    padding: 0 !important;
    overflow: hidden;
}

.annual-slideshow {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.annual-slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 0.7s ease-in-out;
    pointer-events: none;
}

.annual-slide.active {
    opacity: 1;
    pointer-events: auto;
}

.annual-slide img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center;
    display: block;
    transition: transform 0.7s ease-in-out;
}

.annual-slideshow-wrap:hover .annual-slide.active img {
    transform: scale(1.04);
}

.annual-prev,
.annual-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    z-index: 10;
    background: rgba(255,255,255,0.85);
    backdrop-filter: blur(8px);
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
    color: var(--text);
    cursor: pointer;
    opacity: 0;
    transition: opacity 0.3s, background 0.3s, transform 0.3s;
    box-shadow: 0 2px 10px rgba(0,0,0,0.18);
    line-height: 1;
}

.annual-prev { left: 10px; }
.annual-next { right: 10px; }

.annual-slideshow-wrap:hover .annual-prev,
.annual-slideshow-wrap:hover .annual-next {
    opacity: 1;
}

.annual-prev:hover,
.annual-next:hover {
    background: rgba(255,255,255,1);
    transform: translateY(-50%) scale(1.1);
}

.annual-dots {
    position: absolute;
    bottom: 10px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 5px;
    z-index: 10;
}

.annual-dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: rgba(255,255,255,0.55);
    cursor: pointer;
    transition: background 0.3s, transform 0.3s;
    border: 1.5px solid rgba(255,255,255,0.7);
}

.annual-dot.active {
    background: #ffffff;
    transform: scale(1.3);
}

/* ============================================
   FOOTER SOCIALS & MAP
   ============================================ */
.footer-address {
    font-size: 0.875rem;
    color: var(--text-muted);
    margin-top: 0.75rem;
    line-height: 1.5;
}

.footer-socials {
    display: flex;
    gap: 0.75rem;
    margin-top: 1.25rem;
}

.footer-socials a {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: rgba(14,42,71,0.06);
    color: var(--text-soft);
    transition: all 0.3s var(--ease);
}

.footer-socials a:hover {
    background: var(--text);
    color: var(--inverse);
    transform: translateY(-2px);
}

.footer-map-col {
    min-width: 0;
}

.footer-map-col iframe {
    display: block;
    width: 100%;
    max-width: 100%;
    border: 1px solid var(--border);
    border-radius: 12px;
    box-shadow: var(--shadow-sm);
}

/* ============================================
   AOS overrides — softer, slower
   ============================================ */
[data-aos="fade-up"] {
    transform: translateY(40px);
    opacity: 0;
    transition-property: transform, opacity;
}

[data-aos="fade-up"].aos-animate {
    transform: translateY(0);
    opacity: 1;
}

/* ============================================
   SweetAlert2 light theme overrides
   ============================================ */
.swal2-popup {
    background: var(--surface) !important;
    border: 1px solid var(--border) !important;
    color: var(--text) !important;
    border-radius: 20px !important;
    font-family: var(--font) !important;
    box-shadow: 0 30px 80px rgba(0,0,0,0.18) !important;
}

.swal2-title { color: var(--text) !important; font-weight: 700 !important; }
.swal2-html-container { color: var(--text-soft) !important; }
.swal2-confirm {
    background: var(--text) !important;
    color: var(--inverse) !important;
    border-radius: 100px !important;
    padding: 0.75rem 1.75rem !important;
    font-weight: 500 !important;
    box-shadow: none !important;
}
.swal2-confirm:hover {
    background: #1a1a1a !important;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 1024px) {
    .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 3rem; }
    .story-pillars { grid-template-columns: 1fr; gap: 4rem; }
    .academics-grid { grid-template-columns: 1fr; }
    .leadership-grid { grid-template-columns: 1fr; }
    .leader-card-featured { grid-column: auto; }
    .voices-grid { grid-template-columns: 1fr; }
    .footer-inner { grid-template-columns: 1fr; gap: 3rem; }
    .footer-cols { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
    /* --- Mobile Nav Menu --- */
    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        flex-direction: column;
        background: rgba(255,255,255,0.97);
        backdrop-filter: saturate(180%) blur(20px);
        -webkit-backdrop-filter: saturate(180%) blur(20px);
        border-bottom: 1px solid var(--border);
        padding: 1rem 1.5rem 1.5rem;
        gap: 0.25rem;
        box-shadow: 0 12px 32px rgba(0,0,0,0.08);
    }
    .nav-links.open {
        display: flex;
    }
    .nav-links a,
    .nav-link-btn {
        padding: 0.75rem 1rem;
        font-size: 1rem;
        border-radius: 10px;
    }
    .nav-links a:hover {
        background: rgba(10,10,10,0.04);
    }
    .nav-burger { display: flex; }
    .nav-burger.active span:first-child {
        transform: rotate(45deg) translate(4px, 4px);
    }
    .nav-burger.active span:last-child {
        transform: rotate(-45deg) translate(4px, -4px);
    }
    .nav-inner { gap: 0.4rem; padding: 0 0.875rem; }
    .nav-brand { gap: 0.45rem; flex: 0 1 auto; min-width: 0; }
    .brand-mark { width: 34px; height: 34px; border-radius: 10px; flex-shrink: 0; }
    .brand-name {
        display: inline-block;
        font-size: 0.875rem;
        font-weight: 700;
        letter-spacing: -0.015em;
        white-space: nowrap;
    }
    /* Group Portal + Apply + Burger on the right */
    .nav-portal {
        margin-left: auto;
        padding: 0.4rem 0.7rem;
        font-size: 0.75rem;
        white-space: nowrap;
    }
    .nav-cta { padding: 0.4rem 0.7rem; font-size: 0.75rem; white-space: nowrap; }

    /* --- Hero --- */
    .hero { padding: 5rem 1.25rem 3rem; min-height: auto; max-height: none; height: auto; }
    .hero-split {
        grid-template-columns: 1fr;
        text-align: center;
        gap: 0.5rem;
    }
    .hero-left { text-align: center; }
    .hero-right { order: -1; margin-bottom: 0; }
    .hero-logo-wrapper { width: 100px; height: 100px; }
    .hero-logo-img { width: 90px; height: 90px; }
    .hero-logo-glow { display: none; }
    .hero-title { font-size: clamp(2rem, 8vw, 3rem); margin-bottom: 1rem; }
    .hero-badge { margin-bottom: 1rem; }
    .hero-sub { margin-left: auto; margin-right: auto; }
    .hero-actions {
        flex-direction: column;
        align-items: stretch;
        width: 100%;
        max-width: 320px;
        margin-left: auto;
        margin-right: auto;
    }
    .hero-actions .btn { width: 100%; justify-content: center; }
    .hero-features {
        flex-direction: column;
        gap: 0.875rem;
        padding: 1rem 1.25rem;
        border-radius: 16px;
        margin: 0 auto;
    }
    .hf-divider { display: none; }
    .hero-badge { margin-left: auto; margin-right: auto; }

    /* --- Gallery --- */
    .gallery-video-grid { grid-template-columns: 1fr; }
    .gallery-image-grid { grid-template-columns: repeat(2, 1fr); }

    /* --- Sections padding --- */
    .story, .stats, .vision, .facilities, .academics, .voices, .gallery, .cta {
        padding-left: 1.5rem;
        padding-right: 1.5rem;
        padding-top: 5rem;
        padding-bottom: 5rem;
    }

    /* --- Grids --- */
    .stats-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-cols { grid-template-columns: 1fr; gap: 2rem; }
    .footer-base { flex-direction: column; gap: 0.5rem; text-align: center; }

    /* --- Facilities cards --- */
    .hcard { flex: 0 0 320px; height: 460px; padding: 2rem; }

    /* --- Modal --- */
    .modal-card { padding: 2rem; }
    .form-grid { grid-template-columns: 1fr; }

    /* --- Stats chart --- */
    .stats-chart { padding: 1.5rem; }

    /* --- Footer map --- */
    .footer-map { padding: 0 1.5rem; }
}

/* ===== Small phones ===== */
@media (max-width: 480px) {
    .nav-inner { padding: 0 0.625rem; gap: 0.3rem; }
    .nav-brand { gap: 0.4rem; }
    .brand-mark { width: 30px; height: 30px; border-radius: 9px; }
    .brand-name {
        font-size: 0.6875rem;
        line-height: 1;
        letter-spacing: -0.02em;
        white-space: nowrap;
    }
    .nav-portal { padding: 0.3rem 0.55rem; font-size: 0.6875rem; }
    .nav-cta { padding: 0.3rem 0.55rem; font-size: 0.6875rem; }
    .nav-burger { width: 32px; height: 32px; }

    .hero { padding: 5rem 1rem 2.5rem; }
    .hero-logo-wrapper { width: 110px; height: 110px; }
    .hero-logo-img { width: 100px; height: 100px; }
    .hero-title { margin-bottom: 1.25rem; }
    .hero-sub { font-size: 0.9375rem; margin-bottom: 2rem; }
    .hero-badge { font-size: 0.75rem; padding: 0.375rem 0.875rem; margin-bottom: 1.5rem; }

    .story, .stats, .vision, .facilities, .academics, .voices, .gallery, .cta, .defence {
        padding-left: 1rem;
        padding-right: 1rem;
        padding-top: 4rem;
        padding-bottom: 4rem;
    }

    .defence-head { margin-bottom: 3rem; }
    .defence-grid { grid-template-columns: 1fr; gap: 1rem; margin-bottom: 3rem; }
    .defence-card { padding: 2rem 1.5rem; border-radius: 18px; }
    .defence-card h3 { font-size: 1.25rem; }
    .defence-card p { font-size: 0.9rem; }
    .defence-icon { width: 48px; height: 48px; margin-bottom: 1.125rem; }
    .defence-portraits { padding-top: 3rem; margin-bottom: 3rem; }
    .defence-portraits-grid { grid-template-columns: 1fr; gap: 3rem; }
    .defence-portrait-frame { width: 240px; }
    .defence-quote { padding: 2rem 1rem; }
    .defence-quote-mark { font-size: 3.5rem; margin-bottom: -1rem; }

    .container, .container-wide { padding: 0 1rem; }

    .stats-grid { grid-template-columns: 1fr; }
    .stat-num { font-size: clamp(2.5rem, 10vw, 3.5rem); }

    .hcard { flex: 0 0 280px; height: 400px; padding: 1.5rem; border-radius: 20px; }
    .hcard h3 { font-size: 1.5rem; }

    .acad-card { padding: 2rem 1.5rem; }

    .voice { padding: 2rem 1.5rem; }
    .voice blockquote { font-size: 1rem; }

    .gallery-image-grid { grid-template-columns: 1fr; gap: 1rem; }
    .gallery-video-item { border-radius: 14px; }

    .cta .display { font-size: clamp(2rem, 6vw, 3rem); }

    .footer { padding: 4rem 1rem 1.5rem; }
    .footer-inner { gap: 2rem; margin-bottom: 3rem; }
    .footer-map iframe { border-radius: 12px; }

    .modal { padding: 1rem; }
    .modal-card { padding: 1.5rem; border-radius: 18px; }
    .modal-card h2 { font-size: 1.375rem; }
}
