/* ==========================================================================
   Zaytūn International Academy — website stylesheet (v4)
   Identity: the three leaves of the ZIA logo stand for mind, body and soul.
   Surfaces take their tone from the campus: raw concrete and olive.
   The circular "aperture" frames echo the prayer hall's round openings.
   ========================================================================== */

@font-face { font-family: "Outfit"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url(../fonts/outfit-latin-wght-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Outfit"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url(../fonts/outfit-latin-ext-wght-normal.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Instrument Sans"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(../fonts/instrument-sans-latin-wght-normal.woff2) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Instrument Sans"; font-style: normal; font-weight: 400 700; font-display: swap;
  src: url(../fonts/instrument-sans-latin-ext-wght-normal.woff2) format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: "Reem Kufi"; font-style: normal; font-weight: 400; font-display: swap;
  src: url(../fonts/reem-kufi-arabic-400-normal.woff2) format("woff2"); unicode-range: U+0600-06FF, U+0750-077F, U+08A0-08FF, U+FB50-FDFF, U+FE70-FEFF; }

:root {
  --ink: #1d2a22; --ink-2: #4b564d;
  --olive: #4f5f2a; --olive-d: #3a4720;
  --forest: #1f2b1d;
  --concrete: #e9e7e1; --paper: #f7f6f2;
  --line: #d3d0c6; --line-dark: rgba(255, 255, 255, .16);
  --red: #c9463d; --blue: #2d6fb0; --green: #5a9a3b;
  --accent: var(--olive);
  --serif: "Outfit", system-ui, -apple-system, "Segoe UI", sans-serif;
  --sans: "Instrument Sans", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --kufi: "Reem Kufi", "Noto Kufi Arabic", "Segoe UI", sans-serif;
  --r-lg: 28px; --r: 18px; --r-sm: 10px;
  --shadow: 0 24px 48px -32px rgba(29, 42, 34, .45);
  --gutter: clamp(1.1rem, 4vw, 2.6rem);
  --sec: clamp(4.2rem, 9vw, 7.5rem);
  --ease: cubic-bezier(.2, .7, .2, 1);
}

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 96px; }
body { margin: 0; font: 400 1.0625rem/1.65 var(--sans); color: var(--ink); background: var(--paper); -webkit-font-smoothing: antialiased; }
img, video, iframe { max-width: 100%; display: block; }
img { height: auto; }
a { color: var(--olive); text-underline-offset: .18em; text-decoration-thickness: 1px; }
a:hover { color: var(--olive-d); }
h1, h2, h3, h4 { font-family: var(--serif); font-weight: 600; line-height: 1.12; letter-spacing: -.015em; margin: 0 0 .55em; color: inherit; font-optical-sizing: auto; }
h1 { font-size: clamp(2.6rem, 5.6vw, 4.8rem); }
h2 { font-size: clamp(2rem, 3.6vw, 3.05rem); }
h3 { font-size: clamp(1.3rem, 1.9vw, 1.55rem); line-height: 1.2; }
h4 { font-size: 1.2rem; }
p { margin: 0 0 1em; }
ul, ol { margin: 0 0 1em; padding-left: 1.2em; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--blue); outline-offset: 3px; border-radius: 4px; }
::selection { background: #d8e4b7; }
.sr { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 1rem; top: -4rem; z-index: 100; background: var(--forest); color: #fff; padding: .7rem 1rem; border-radius: var(--r-sm); }
.skip:focus { top: 1rem; color: #fff; }
main { display: block; }
main:focus { outline: none; }
.wrap { width: 100%; max-width: 1260px; margin-inline: auto; padding-inline: var(--gutter); }
.wrap.narrow { max-width: 860px; }
.center { text-align: center; }

/* ---------- leaf marks ---------- */
.leaves { display: inline-flex; gap: 5px; align-items: flex-end; margin-bottom: 1.3rem; }
.leaves i { display: block; width: 13px; height: 22px; border-radius: 100% 0 100% 0; transform: rotate(var(--r, 0deg)); }
.leaves i:nth-child(1) { --r: -12deg; }
.leaves i:nth-child(2) { height: 27px; }
.leaves i:nth-child(3) { --r: 12deg; }
.l-red, .leafdots i:nth-child(1) { background: var(--red); }
.l-blue, .leafdots i:nth-child(2) { background: var(--blue); }
.l-green, .leafdots i:nth-child(3) { background: var(--green); }
.leafdots { display: inline-flex; gap: 3px; margin-right: .55rem; vertical-align: -1px; }
.leafdots i { width: 7px; height: 11px; border-radius: 100% 0 100% 0; display: block; }
.kufic { font-family: var(--kufi); line-height: 1; pointer-events: none; user-select: none; direction: rtl; }

/* ---------- buttons & links ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 48px; padding: .75rem 1.45rem; border-radius: 999px; font: 600 .98rem/1.2 var(--sans); text-decoration: none; border: 1.5px solid transparent; cursor: pointer; transition: background-color .2s, color .2s, border-color .2s; white-space: nowrap; }
.btn-olive { background: var(--accent); color: #fff; }
.btn-olive:hover { background: var(--olive-d); color: #fff; }
.btn-light { background: #fff; color: var(--forest); }
.btn-light:hover { background: #e8ecd9; color: var(--forest); }
.btn-ghost { border-color: rgba(255, 255, 255, .55); color: #fff; }
.btn-ghost:hover { background: rgba(255, 255, 255, .1); color: #fff; border-color: #fff; }
.btn-outline { border-color: var(--olive); color: var(--olive); }
.btn-outline:hover { background: var(--olive); color: #fff; }
.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }
.actions.center { justify-content: center; }
.tlink { display: inline-flex; align-items: center; gap: .4rem; font-weight: 600; text-decoration: none; color: var(--olive); border-bottom: 1.5px solid currentColor; padding-bottom: 2px; }
.tlink::after { content: ""; width: .45em; height: .45em; border-top: 1.5px solid; border-right: 1.5px solid; transform: rotate(45deg); transition: transform .2s var(--ease); }
.tlink:hover::after { transform: translateX(3px) rotate(45deg); }
.dark .tlink { color: #fff; }
.tag { display: inline-block; font-size: .78rem; font-weight: 600; color: var(--olive); background: #e3e7d4; padding: .15rem .6rem; border-radius: 999px; text-decoration: none; margin: 0; }

/* ---------- top bar & header ---------- */
.topbar { background: var(--forest); color: #dfe5d8; font-size: .86rem; }
.topbar-in { display: flex; justify-content: space-between; align-items: center; gap: 1rem; min-height: 40px; }
.topbar a { color: inherit; text-decoration: none; }
.topbar a:hover { color: #fff; text-decoration: underline; }
.topbar-adm { font-weight: 600; color: #fff !important; }
.topbar-links { display: flex; gap: 1.5rem; }
.masthead { position: sticky; top: 0; z-index: 40; background: #fff; border-bottom: 1px solid transparent; transition: box-shadow .25s, border-color .25s; }
.masthead.is-stuck { border-color: var(--line); box-shadow: 0 10px 30px -24px rgba(29, 42, 34, .6); }
.masthead-in { display: flex; align-items: center; justify-content: space-between; gap: 1.2rem; min-height: 84px; }
.brand img { width: auto; height: 58px; }
.brand span { font: 600 1.3rem var(--serif); color: var(--ink); }
.nav { display: flex; align-items: center; gap: 1rem; }
.nav-list { display: flex; list-style: none; margin: 0; padding: 0; gap: .1rem; }
.nav-list > li { position: relative; }
.nav-list > li > a, .sub-toggle { white-space: nowrap; display: inline-flex; align-items: center; gap: .35rem; padding: .55rem .7rem; font-size: .96rem; font-weight: 500; color: var(--ink); text-decoration: none; border-radius: 999px; background: none; border: 0; cursor: pointer; }
.nav-list > li > a:hover, .sub-toggle:hover { background: var(--concrete); color: var(--ink); }
.nav-list a[aria-current="page"] { color: var(--olive); font-weight: 650; }
.sub-toggle svg { transition: transform .2s; }
.has-sub.is-open .sub-toggle svg { transform: rotate(180deg); }
.sub { position: absolute; top: calc(100% + 8px); left: 0; min-width: 220px; list-style: none; margin: 0; padding: .5rem; background: #fff; border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); opacity: 0; visibility: hidden; transform: translateY(-6px); transition: opacity .18s, transform .18s, visibility 0s .18s; }
.has-sub.is-open .sub { opacity: 1; visibility: visible; transform: none; transition: opacity .18s, transform .18s; }
.sub a { display: block; padding: .55rem .8rem; border-radius: var(--r-sm); color: var(--ink); text-decoration: none; font-size: .95rem; }
.sub a:hover { background: var(--concrete); }
.nav-tools { display: flex; align-items: center; gap: .4rem; }
.icon-btn { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; color: var(--ink); }
.icon-btn:hover { background: var(--concrete); color: var(--ink); }
.nav-toggle { display: none; width: 48px; height: 48px; border: 1px solid var(--line); border-radius: 50%; background: #fff; cursor: pointer; align-items: center; justify-content: center; }
.bars, .bars::before, .bars::after { display: block; width: 20px; height: 2px; background: var(--ink); border-radius: 2px; position: relative; transition: transform .25s, background .25s; }
.bars::before, .bars::after { content: ""; position: absolute; left: 0; }
.bars::before { top: -6px; }
.bars::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .bars::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .bars::after { transform: translateY(-6px) rotate(-45deg); }

/* ---------- aperture (circular frames) ---------- */
.aperture { position: relative; border-radius: 50%; overflow: hidden; aspect-ratio: 1; background: var(--concrete); isolation: isolate; }
.aperture img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

/* ---------- aspect-ratio system ----------
   hero 16:9 (4:5 on phones) · news lead 16:9 · cards, thumbs, strip 4:3
   facility panels 16:10 · portraits 4:5 · reels 9:16 · video tour 16:9 */
.ratio { position: relative; display: block; overflow: hidden; background: var(--line); }
.ratio > img, .ratio > video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.r-16x9 { aspect-ratio: 16 / 9; } .r-16x10 { aspect-ratio: 16 / 10; } .r-4x3 { aspect-ratio: 4 / 3; } .r-4x5 { aspect-ratio: 4 / 5; } .r-1x1 { aspect-ratio: 1; }

/* ---------- hero ---------- */
.hero { position: relative; color: #fff; overflow: hidden; background: var(--forest); width: 100%; min-height: clamp(560px, 78vh, 760px); display: flex; align-items: center; padding: clamp(4rem, 8vh, 6rem) 0 clamp(7rem, 12vh, 8.5rem); }
.hero-slides, .hero-slides img { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-slides img { object-fit: cover; opacity: 0; transition: opacity 1.4s ease, transform 7s ease-out; transform: scale(1.06); }
.hero-slides img.is-on { opacity: 1; transform: scale(1); }
.hero-shade { position: absolute; inset: 0; background: linear-gradient(90deg, rgba(18, 28, 17, .88) 0%, rgba(18, 28, 17, .66) 42%, rgba(18, 28, 17, .12) 75%), linear-gradient(0deg, rgba(18, 28, 17, .5), transparent 35%); }
.hero-in { position: relative; z-index: 2; width: 100%; }
.hero-text { max-width: 620px; }
.hero-kicker { display: inline-flex; align-items: center; gap: .6rem; font-weight: 600; font-size: .92rem; color: #e8d48a; margin-bottom: 1.1rem; }
.hero-kicker .leaves { margin: 0; }
.hero-kicker .leaves i { width: 9px; height: 15px; }
.hero-kicker .leaves i:nth-child(2) { height: 18px; }
.hero h1 { font-size: clamp(2.3rem, 4.6vw, 4rem); font-weight: 700; line-height: 1.06; letter-spacing: -.025em; margin-bottom: 1.2rem; }
.hero h1 .hl { display: inline; }
.hero h1 .hl + .hl::before { content: " "; }
.hero h1 .hl:last-child { color: #c9dc8f; }
.hero-lead { font-size: clamp(1.02rem, 1.25vw, 1.15rem); color: #e8ece2; max-width: 34em; margin-bottom: 0; }
.hero .actions { margin-top: 1.8rem; }
.hero-ctrl { position: absolute; z-index: 3; left: 0; right: 0; bottom: 4rem; display: flex; align-items: center; justify-content: flex-end; gap: .6rem; margin-inline: auto; }
.hero-ctrl button { border: 0; cursor: pointer; color: #fff; background: none; padding: 0; }
.slide-arrow { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; border: 1px solid rgba(255, 255, 255, .45) !important; transition: background .2s; }
.slide-arrow:hover { background: rgba(255, 255, 255, .15) !important; }
.slide-dots { display: flex; gap: .45rem; padding: 0 .4rem; }
.slide-dot { width: 9px; height: 9px; border-radius: 6px; background: rgba(255, 255, 255, .5) !important; transition: width .3s, background .3s; }
.slide-dot.is-on { background: #fff !important; width: 26px; }
.slide-pause { width: 36px; height: 36px; display: grid; place-items: center; }
.slide-pause .i-play { display: none; }
.slide-pause[aria-pressed="true"] .i-play { display: block; }
.slide-pause[aria-pressed="true"] .i-pause { display: none; }
@media (prefers-reduced-motion: no-preference) {
  .hero h1 { opacity: 0; transform: translateY(.3em); animation: rise .9s var(--ease) .15s forwards; }
  .hero .leaves i { opacity: 0; animation: leaf .6s var(--ease) forwards; }
  .hero .leaves i:nth-child(2) { animation-delay: .1s; } .hero .leaves i:nth-child(3) { animation-delay: .2s; }
  .hero-lead, .hero .actions { opacity: 0; animation: fade .8s ease .6s forwards; }
}
@keyframes rise { to { opacity: 1; transform: none; } }
@keyframes leaf { from { opacity: 0; transform: rotate(var(--r, 0deg)) scale(.3); } to { opacity: 1; transform: rotate(var(--r, 0deg)); } }
@keyframes fade { to { opacity: 1; } }

/* traits bar overlapping the hero edge */
.traits-bar { position: relative; z-index: 4; margin-top: -2.6rem; }
.traits { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 0; background: #fff; border-radius: var(--r-lg); box-shadow: 0 30px 60px -35px rgba(29, 42, 34, .5); overflow: hidden; }
.trait-card { display: flex; gap: 1rem; align-items: flex-start; padding: 1.5rem 1.6rem; text-decoration: none; color: var(--ink-2); font-size: .92rem; line-height: 1.5; border-top: 4px solid var(--c); transition: background .2s; }
.trait-card + .trait-card { border-left: 1px solid var(--line); }
.trait-card:hover { background: var(--paper); color: var(--ink-2); }
.trait-card strong { display: block; font-family: var(--serif); font-size: 1.3rem; font-weight: 500; color: var(--ink); margin-bottom: .2rem; }
.leaf-sm { flex: none; width: 18px; height: 28px; border-radius: 100% 0 100% 0; background: var(--c); margin-top: .3rem; }
.t-red { --c: var(--red); } .t-blue { --c: var(--blue); } .t-green { --c: var(--green); }

/* ---------- sections ---------- */
.sec { padding-block: var(--sec); position: relative; }
.sec-head { margin-bottom: clamp(2.2rem, 4vw, 3.4rem); }
.sec-head h2 { margin: 0; }
.sec-head p { color: var(--ink-2); font-size: 1.1rem; margin: 0; max-width: 40em; }
.sec-head.split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 1.2rem 4rem; align-items: end; }
.sec-head.center { text-align: center; }
.sec-head.center p { margin: 1rem auto 0; }
.sec-head.row { display: flex; justify-content: space-between; align-items: end; gap: 1rem; flex-wrap: wrap; }
.dark { background: var(--forest); color: #fff; }
.dark .sec-head p { color: #c9d1c2; }
.sec-pillars, .sec-holistic, .sec-updates, .sec-parents, .sec-facilities, .sec-req, .sec-reach, .sec-faqmore, .sec-related, .sec-list, .sec-map { background: var(--concrete); }
.sec-why, .sec-leaders, .sec-voices, .sec-campus, .sec-process, .sec-form, .sec-faqs, .sec-letter, .sec-event, .sec-badge, .sec-applyform, .sec-overview { background: var(--paper); }

/* pillars */
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.4rem, 3vw, 2.6rem); }
.pillar-img { position: relative; border-radius: 999px 999px var(--r) var(--r); overflow: hidden; aspect-ratio: 5 / 6; margin-bottom: 1.6rem; background: var(--line); }
.pillar-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.pillar:hover .pillar-img img { transform: scale(1.04); }
.pillar-img::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 6px; background: var(--c); }
.p-red { --c: var(--red); } .p-blue { --c: var(--blue); } .p-green { --c: var(--green); }
.pillar h3 { margin-bottom: .6rem; }
.pillar-body { color: var(--ink-2); font-size: 1rem; }

/* why */
.why { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(2rem, 6vw, 6rem); align-items: center; }
.why-visual { position: relative; }
.why-visual::before { content: ""; position: absolute; inset: -5% 10% 10% -5%; border-radius: 50%; border: 1.5px solid var(--line); }
.aperture-why { width: min(100%, 520px); background: #fff; }
.aperture-why img { object-fit: contain; padding: 9%; }
.prose-why p:first-child { font-family: var(--serif); font-weight: 500; font-size: clamp(1.25rem, 1.8vw, 1.5rem); line-height: 1.4; color: var(--ink); }
.prose-why strong { color: var(--olive); font-weight: 650; letter-spacing: .02em; }

/* holistic */
.holistic { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.2rem, 3vw, 2rem); }
.hol { background: var(--paper); border-radius: var(--r-lg); padding: clamp(1.6rem, 3vw, 2.4rem); }
.hol p { color: var(--ink-2); margin: 0; font-size: 1rem; }
.leaf-big { display: block; width: 34px; height: 54px; border-radius: 100% 0 100% 0; background: var(--c); margin-bottom: 1.6rem; }
.h-red { --c: var(--red); } .h-blue { --c: var(--blue); } .h-green { --c: var(--green); }

/* vision & mission */
.sec-vm { overflow: hidden; }
.vm-kufic { position: absolute; right: -4vw; top: 50%; transform: translateY(-50%); font-size: clamp(14rem, 34vw, 32rem); color: #fff; opacity: .035; }
.vm { position: relative; display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line-dark); border-bottom: 1px solid var(--line-dark); }
.vm-col { padding: clamp(1.8rem, 4vw, 3rem) clamp(0rem, 3vw, 3rem) clamp(1.8rem, 4vw, 3rem) 0; }
.vm-col + .vm-col { border-left: 1px solid var(--line-dark); padding-left: clamp(1.4rem, 4vw, 3rem); }
.vm-col h3 { font-size: 1rem; font-family: var(--sans); font-weight: 600; color: #b9c69a; margin-bottom: 1.2rem; }
.vm-text p { font-family: var(--serif); font-weight: 400; font-size: clamp(1.1rem, 1.5vw, 1.3rem); line-height: 1.5; color: #f0f2ea; }
.vm-text p:last-child { margin-bottom: 0; }
.mp-title { position: relative; font-size: clamp(1.5rem, 2.4vw, 2rem); margin: clamp(3rem, 6vw, 4.5rem) 0 2rem; }
.mpillars { position: relative; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.2rem, 3vw, 2.4rem); }
.mp { padding-top: 1.4rem; border-top: 3px solid var(--c); }
.m-red { --c: var(--red); } .m-blue { --c: var(--blue); } .m-green { --c: var(--green); }
.mp-icon { display: grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: #fff; margin-bottom: 1.1rem; }
.mp-icon img { width: 38px; height: auto; }
.mp h4 { font-size: 1.35rem; margin-bottom: .5rem; }
.mp p { color: #c9d1c2; font-size: .98rem; margin: 0; }

/* video */
.video { position: relative; border-radius: var(--r-lg); overflow: hidden; background: var(--forest); aspect-ratio: 16 / 9; }
.video > img, .video > video, .video > iframe, .video-blank { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; border: 0; }
.video > video { object-fit: contain; background: #000; }
.video-blank { background: linear-gradient(135deg, var(--forest), var(--olive-d)); }
.video > img { transition: transform .8s var(--ease); }
.video:hover > img { transform: scale(1.03); }
.video-play { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; gap: .9rem; border: 0; cursor: pointer; background: linear-gradient(0deg, rgba(20, 30, 18, .55), rgba(20, 30, 18, .05) 60%); color: #fff; font-weight: 600; }
.video-play-icon { display: grid; place-items: center; width: 74px; height: 74px; border-radius: 50%; background: #fff; color: var(--forest); box-shadow: 0 0 0 10px rgba(255, 255, 255, .22); transition: transform .25s var(--ease); }
.video-play-icon .icon { width: 28px; height: 28px; margin-left: 4px; }
.video-play:hover .video-play-icon { transform: scale(1.06); }
.video-play-label { font-size: 1rem; text-shadow: 0 1px 8px rgba(0, 0, 0, .4); }
.video.is-playing .video-play, .video.is-playing > img, .video.is-playing > .video-blank { display: none; }
.video-tall { aspect-ratio: 4 / 5; }
.video-list { display: grid; gap: 1.5rem; margin-top: 2rem; }

/* leaders */
.leaders { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1.4rem, 3vw, 2.6rem); }
.leader { background: #fff; border-radius: var(--r-lg); padding: clamp(1.6rem, 3.4vw, 2.8rem); display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 1.8rem; align-items: start; box-shadow: var(--shadow); }
.aperture-leader { width: 140px; }
.aperture-leader img { object-position: center 18%; }
.leader h2 { font-size: clamp(1.5rem, 2.2vw, 1.95rem); margin-bottom: 1rem; }
.leader-greet { font-family: var(--serif); color: var(--ink-2); }
.leader-text > p { font-size: 1rem; color: var(--ink-2); }
.leader-name { display: flex; flex-direction: column; margin: 1.3rem 0 1.2rem; }
.leader-name strong { font-family: var(--serif); font-size: 1.3rem; font-weight: 500; color: var(--ink); }
.leader-name span { font-size: .9rem; color: var(--ink-2); }

/* updates & cards */
.ugrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(1rem, 2.2vw, 1.8rem); }
.ugrid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.ucard { display: flex; flex-direction: column; }
.ucard-media { position: relative; display: block; aspect-ratio: 4 / 3; border-radius: var(--r); overflow: hidden; background: var(--line); }
.ucard-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease); }
.ucard:hover .ucard-media img { transform: scale(1.05); }
.ucard-media .ph { position: absolute; inset: 0; background: linear-gradient(135deg, var(--olive), var(--forest)); }
.ucard-media .count { position: absolute; left: .8rem; bottom: .8rem; background: rgba(31, 43, 29, .82); color: #fff; font-size: .8rem; font-weight: 600; padding: .25rem .7rem; border-radius: 999px; }
.ucard-body { padding: 1.1rem .2rem 0; display: flex; flex-direction: column; flex: 1; }
.ucard .meta { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; font-size: .86rem; color: var(--ink-2); margin-bottom: .45rem; }
.ucard h3 { font-size: 1.28rem; margin-bottom: .7rem; }
.ucard h3 a { color: var(--ink); text-decoration: none; }
.ucard h3 a:hover { color: var(--olive); }
.ucard .more { margin-top: auto; font-size: .92rem; font-weight: 600; text-decoration: none; color: var(--olive); }
.ucard .more:hover { text-decoration: underline; }
.upcoming { background: var(--paper); border-radius: var(--r-lg); padding: 1.6rem clamp(1.2rem, 3vw, 2rem); margin-bottom: 2.4rem; }
.upcoming h2, .upcoming h3 { font-size: 1.3rem; margin-bottom: .8rem; }
.upcoming ul { list-style: none; padding: 0; margin: 0; }
.upcoming li { display: grid; grid-template-columns: 11rem 1fr; gap: .2rem 1.2rem; padding: .8rem 0; border-top: 1px solid var(--line); }
.upcoming time { font-weight: 600; color: var(--olive); font-size: .95rem; }
.upcoming a { color: var(--ink); font-weight: 600; text-decoration: none; }
.upcoming small { grid-column: 2; color: var(--ink-2); }

/* voices & parents */
.voices { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(2rem, 6vw, 6rem); align-items: center; }
.voices-video { max-width: 440px; }
.voices-sub { font-family: var(--serif); font-size: clamp(1.3rem, 2vw, 1.7rem); color: var(--olive); margin-bottom: 1rem; }
.voices-text > p:last-child { font-size: 1.12rem; color: var(--ink-2); max-width: 32em; }
.parents { display: grid; grid-template-columns: minmax(0, .75fr) minmax(0, 1.25fr); gap: clamp(1.4rem, 3vw, 2.6rem); align-items: start; }
.parents-video { position: sticky; top: 110px; }
.quotes { display: grid; gap: 1.2rem; }
.quote { margin: 0; background: var(--paper); border-radius: var(--r-lg); padding: clamp(1.4rem, 3vw, 2.2rem); position: relative; }
.quote::before { content: ""; position: absolute; left: clamp(1.4rem, 3vw, 2.2rem); top: 0; width: 46px; height: 4px; background: var(--c); border-radius: 0 0 4px 4px; }
.q-red { --c: var(--red); } .q-blue { --c: var(--blue); } .q-green { --c: var(--green); }
.stars { display: inline-flex; gap: 2px; color: #b5862a; margin-bottom: .9rem; }
.quote blockquote { margin: 0 0 1.2rem; }
.quote blockquote p { font-family: var(--sans); font-size: clamp(1.08rem, 1.5vw, 1.24rem); line-height: 1.5; color: var(--ink); margin: 0; }
.quote figcaption { display: flex; flex-direction: column; }
.quote figcaption strong { font-weight: 650; }
.quote figcaption span { font-size: .9rem; color: var(--ink-2); }
.quote .video { margin-top: 1rem; }

/* ---------- inner page head ---------- */
.pagehead { position: relative; background: var(--concrete); padding: clamp(2.4rem, 5vw, 4rem) 0 clamp(3rem, 6vw, 4.6rem); overflow: hidden; }
.pagehead::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 5px; background: linear-gradient(90deg, var(--red) 0 33.33%, var(--blue) 33.33% 66.66%, var(--green) 66.66%); }
.pagehead-in { display: grid; grid-template-columns: minmax(0, 1fr); gap: 2rem; align-items: center; }
.pagehead.has-image .pagehead-in { grid-template-columns: minmax(0, 1.3fr) minmax(0, .7fr); }
.pagehead h1 { font-size: clamp(2.4rem, 5vw, 4.2rem); margin-bottom: 1rem; max-width: 15em; }
.pagehead-intro { font-size: clamp(1.08rem, 1.5vw, 1.25rem); color: var(--ink-2); max-width: 38em; margin: 0; }
.aperture-head { width: min(100%, 360px); justify-self: end; }
.crumbs { display: flex; flex-wrap: wrap; gap: .45rem; font-size: .88rem; color: var(--ink-2); margin-bottom: 1.4rem; }
.crumbs a { color: var(--ink-2); text-decoration: none; }
.crumbs a:hover { color: var(--olive); text-decoration: underline; }
.crumbs [aria-current] { color: var(--ink); font-weight: 600; }
.event-meta { display: flex; flex-wrap: wrap; gap: .5rem 1.2rem; align-items: center; color: var(--ink-2); font-weight: 500; margin: 0; }
.pagehead-404 { padding-block: clamp(4rem, 10vw, 8rem); }
.links-404 { list-style: none; padding: 0; display: flex; flex-wrap: wrap; gap: 1.5rem; margin-top: 2rem; }

/* ---------- facility ---------- */
.campus { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: clamp(2rem, 5vw, 5rem); align-items: center; }
.facilities { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(1rem, 2vw, 1.5rem); }
.fac { background: var(--paper); border-radius: var(--r-lg); padding: 1.8rem 1.6rem; }
.fac-icon { display: grid; place-items: center; width: 74px; height: 74px; border-radius: 50%; background: #fff; margin-bottom: 1.3rem; box-shadow: 0 0 0 1px var(--line); }
.fac-icon img { width: 46px; height: 46px; object-fit: contain; }
.fac h3 { font-size: 1.3rem; }
.fac p { font-size: .96rem; color: var(--ink-2); margin: 0; }
.fac-img { margin-top: 1.2rem; border-radius: var(--r-sm); }

/* ---------- curriculum ---------- */
.stage { background: var(--paper); }
.stage-flip { background: var(--concrete); }
.stage-in { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); gap: clamp(2rem, 6vw, 6rem); align-items: center; }
.stage-flip .stage-text { order: 2; }
.stage-age { display: inline-block; font-weight: 600; font-size: .9rem; color: #fff; background: var(--olive); padding: .3rem .9rem; border-radius: 999px; margin-bottom: 1.2rem; }
.stage-text h2 { margin-bottom: 1.2rem; }
.stage-text .prose h3 { margin-top: 1.8rem; }
.stage-text .btn { margin-top: 1.6rem; }
.stage-img { border-radius: 999px 999px var(--r-lg) var(--r-lg); overflow: hidden; aspect-ratio: 9 / 10; background: var(--line); }
.stage-img img { width: 100%; height: 100%; object-fit: cover; }
.sec-badge { padding-block: 3.5rem; }
.sec-badge a { display: inline-block; background: var(--forest); border-radius: var(--r-lg); padding: 1.4rem 2rem; }
.sec-badge img { margin-inline: auto; width: 280px; }

/* ---------- admission ---------- */
.facts-strip { background: var(--paper); padding-top: clamp(2.5rem, 5vw, 3.5rem); }
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1rem; }
.fact { background: #fff; border-radius: var(--r); padding: 1.4rem 1.6rem; border-top: 4px solid var(--c); box-shadow: var(--shadow); }
.fact span { display: block; font-size: .9rem; color: var(--ink-2); font-weight: 500; }
.fact strong { font-family: var(--serif); font-size: clamp(1.5rem, 2.4vw, 2rem); font-weight: 500; }
.f-red { --c: var(--red); } .f-blue { --c: var(--blue); } .f-green { --c: var(--green); }
.sec-applyform { padding-top: clamp(2.5rem, 5vw, 3.5rem); }
.applycard { position: relative; overflow: hidden; background: var(--forest); color: #fff; border-radius: var(--r-lg); padding: clamp(2.4rem, 6vw, 4.5rem) clamp(1.4rem, 5vw, 4rem); text-align: center; }
.applycard-kufic { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); font-size: clamp(10rem, 26vw, 22rem); color: #fff; opacity: .04; }
.applycard > :not(.kufic) { position: relative; }
.applycard-label { font-weight: 600; color: #b9c69a; }
.applycard h2 { font-size: clamp(2.4rem, 5vw, 4rem); margin-bottom: .6rem; }
.applycard-session { font-size: 1.15rem; color: #dfe5d8; }
.applycard-session strong { color: #fff; }
.applycard-for { font-family: var(--serif); font-size: clamp(1.6rem, 3vw, 2.3rem); margin: 1.2rem 0 .3rem; }
.applycard p { margin-bottom: .4rem; }
.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(1rem, 2vw, 1.6rem); }
.step { position: relative; padding: 1.8rem 1.4rem 1.6rem; background: #fff; border-radius: var(--r-lg); }
.step-n { display: block; font-family: var(--serif); font-size: 3.4rem; line-height: 1; color: var(--olive); font-weight: 300; margin-bottom: 1rem; }
.step h3 { font-size: 1.3rem; }
.step p { font-size: .96rem; color: var(--ink-2); margin: 0; }
.req { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1rem, 3vw, 2rem); }
.req-col { background: var(--paper); border-radius: var(--r-lg); padding: clamp(1.6rem, 3vw, 2.4rem); }
.checklist { list-style: none; padding: 0; margin: 0; }
.checklist li { position: relative; padding: .75rem 0 .75rem 2.1rem; border-top: 1px solid var(--line); }
.checklist li:first-child { border-top: 0; }
.checklist li::before { content: ""; position: absolute; left: .2rem; top: 1.05rem; width: 14px; height: 8px; border-left: 2px solid var(--green); border-bottom: 2px solid var(--green); transform: rotate(-45deg); }
.checklist small { display: block; color: var(--ink-2); }
.applyband { background: var(--forest); color: #fff; padding-block: clamp(2.6rem, 5vw, 3.6rem); }
.applyband-in { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem; }
.applyband h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); margin: 0 0 .3rem; }
.applyband p { color: #c9d1c2; margin: 0; }
.applyband .leaves { margin-bottom: .8rem; }
.applyband .actions { margin: 0; }

/* ---------- contact ---------- */
.reach { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(1rem, 2vw, 1.5rem); }
.rcard { background: var(--paper); border-radius: var(--r-lg); padding: 1.8rem 1.6rem; border-top: 4px solid var(--c, var(--olive)); }
.r-red { --c: var(--red); } .r-blue { --c: var(--blue); } .r-green { --c: var(--green); }
.rcard h3 { font-size: 1.35rem; }
.rcard p { margin: 0 0 .35rem; font-size: .98rem; overflow-wrap: anywhere; }
.connect { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1.5rem; margin-top: 2.5rem; padding-top: 2rem; border-top: 1px solid var(--line); }
.connect h3 { margin-bottom: .3rem; }
.connect p { color: var(--ink-2); margin: 0; }
.map { position: relative; border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 16 / 7; background: var(--paper); }
.map iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.map-load { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .5rem; border: 0; cursor: pointer; background: repeating-linear-gradient(45deg, transparent 0 22px, rgba(79, 95, 42, .05) 22px 23px), var(--paper); }
.map-load span { background: var(--olive); color: #fff; font-weight: 600; padding: .8rem 1.5rem; border-radius: 999px; }
.map-load small { color: var(--ink-2); }

/* forms */
.formcard { background: #fff; border-radius: var(--r-lg); padding: clamp(1.6rem, 4vw, 2.8rem); box-shadow: var(--shadow); }
.formcard h2 { font-size: clamp(1.7rem, 2.8vw, 2.3rem); margin-bottom: .3rem; }
.formcard-intro { color: var(--ink-2); margin-bottom: 1.6rem; }
.form .field { margin-bottom: 1.1rem; }
.form label { display: block; font-weight: 600; font-size: .92rem; margin-bottom: .35rem; }
.form input[type=text], .form input[type=email], .form input[type=tel], .form textarea, .search-form input { width: 100%; padding: .8rem .95rem; border: 1.5px solid var(--line); border-radius: var(--r-sm); background: var(--paper); font: inherit; color: var(--ink); transition: border-color .15s, background .15s; }
.form input:focus, .form textarea:focus, .search-form input:focus { outline: none; border-color: var(--olive); background: #fff; box-shadow: 0 0 0 4px #e1e8cc; }
.form textarea { resize: vertical; min-height: 130px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
.has-error input, .has-error textarea { border-color: var(--red); }
.field-error { color: #a3271f; font-size: .88rem; margin: .35rem 0 0; }
.form .consent { display: flex; gap: .7rem; align-items: flex-start; font-weight: 400; font-size: .92rem; color: var(--ink-2); margin: .4rem 0 1.4rem; }
.consent input { margin-top: .3rem; width: 18px; height: 18px; accent-color: var(--olive); flex: none; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.alert { padding: 1rem 1.2rem; border-radius: var(--r-sm); margin-bottom: 1.4rem; }
.alert-ok { background: #e6f1dd; color: #244d14; }
.alert-err { background: #fbe7e5; color: #8a1f16; }

/* faqs */
.faqs { display: grid; gap: .7rem; }
.faq { background: #fff; border-radius: var(--r); border: 1px solid var(--line); transition: border-color .2s; }
.faq[open] { border-color: var(--olive); }
.faq summary { list-style: none; display: flex; justify-content: space-between; gap: 1rem; align-items: center; padding: 1.15rem 1.4rem; cursor: pointer; font-weight: 600; font-size: 1.04rem; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary i { position: relative; flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--concrete); }
.faq summary i::before, .faq summary i::after { content: ""; position: absolute; left: 50%; top: 50%; width: 12px; height: 2px; background: var(--olive); transform: translate(-50%, -50%); transition: transform .2s; }
.faq summary i::after { transform: translate(-50%, -50%) rotate(90deg); }
.faq[open] summary i::after { transform: translate(-50%, -50%) rotate(0); }
.faq-a { padding: 0 1.4rem 1.3rem; color: var(--ink-2); }
.faq-group { font-size: 1.6rem; margin: 2.5rem 0 1rem; }
.faqmore { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(2rem, 5vw, 5rem); align-items: start; }
.faqmore-text p { font-size: 1.12rem; color: var(--ink-2); }

/* event, gallery */
.cover { margin: 0 0 2rem; border-radius: var(--r-lg); overflow: hidden; }
.photos-bar { display: flex; justify-content: space-between; align-items: end; gap: 1rem; margin: 1rem 0 1.4rem; }
.photos-bar h2 { font-size: 1.6rem; margin: 0; }
.photo-grid { columns: 3 150px; column-gap: .8rem; }
.photo { display: block; margin-bottom: .8rem; border-radius: var(--r-sm); overflow: hidden; break-inside: avoid; background: var(--line); }
.photo img { width: 100%; transition: transform .6s var(--ease); }
.photo:hover img { transform: scale(1.03); }
.album-link { margin-bottom: 2rem; }
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2.2rem; }
.filters a { padding: .5rem 1.1rem; border-radius: 999px; background: var(--paper); color: var(--ink); text-decoration: none; font-weight: 500; font-size: .94rem; border: 1px solid var(--line); }
.filters a:hover { border-color: var(--olive); }
.filters a[aria-current] { background: var(--olive); color: #fff; border-color: var(--olive); }
.pager { display: flex; justify-content: center; align-items: center; gap: 1.5rem; margin-top: 3rem; }
.pager a { padding: .6rem 1.3rem; border-radius: 999px; border: 1.5px solid var(--olive); text-decoration: none; font-weight: 600; }
.pager a:hover { background: var(--olive); color: #fff; }
.list-h { font-size: 1.8rem; margin: 3.5rem 0 1.4rem; }
.vgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 1.4rem; }
.vgrid figure { margin: 0; }
.vgrid figcaption { margin-top: .6rem; font-weight: 600; }
.empty { color: var(--ink-2); font-size: 1.05rem; padding: 2rem; background: var(--paper); border-radius: var(--r); text-align: center; }

/* leader letter */
.letter { display: grid; grid-template-columns: 260px minmax(0, 1fr); gap: clamp(2rem, 6vw, 5rem); align-items: start; }
.letter-side { position: sticky; top: 120px; }
.letter-side .aperture-leader { width: 220px; }
.prose-letter { font-size: 1.12rem; max-width: 40em; }
.prose-letter p:first-child { font-family: var(--serif); font-size: 1.3rem; }
.leaders-mini { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.leader-mini { display: flex; align-items: center; gap: 1.2rem; background: var(--paper); border-radius: var(--r-lg); padding: 1.2rem 1.4rem; text-decoration: none; color: var(--ink-2); }
.leader-mini img { width: 72px; height: 72px; border-radius: 50%; object-fit: cover; }
.leader-mini strong { display: block; font-family: var(--serif); font-size: 1.3rem; font-weight: 500; color: var(--ink); }

/* prose */
.prose { max-width: 42em; }
.prose > :last-child { margin-bottom: 0; }
.prose h2 { font-size: 1.8rem; margin-top: 2rem; }
.prose h3 { font-size: 1.4rem; margin-top: 1.6rem; }
.prose blockquote { margin: 1.6rem 0; padding: .4rem 0 .4rem 1.4rem; border-left: 3px solid var(--green); font-family: var(--serif); font-weight: 500; font-size: 1.15em; color: var(--ink); }
.prose blockquote p { margin: 0; }
.prose img { border-radius: var(--r-sm); margin-block: 1rem; }
.prose ul li { margin-bottom: .35rem; }
.prose table { border-collapse: collapse; width: 100%; }
.prose td, .prose th { border: 1px solid var(--line); padding: .5rem .7rem; }

/* misc pages */
.search-form { display: flex; gap: .7rem; margin-bottom: 1.5rem; }
.search-count { color: var(--ink-2); }
.search-results { display: grid; gap: 1rem; }
.search-result { background: #fff; border-radius: var(--r); padding: 1.3rem 1.5rem; border: 1px solid var(--line); }
.search-result h2 { font-size: 1.35rem; margin: .5rem 0 .3rem; }
.search-result h2 a { color: var(--ink); text-decoration: none; }
.search-result p:last-child { margin: 0; color: var(--ink-2); }
.quick-searches { display: flex; flex-wrap: wrap; gap: .6rem; }
.quick-searches a { padding: .55rem 1.1rem; border: 1px solid var(--line); border-radius: 999px; text-decoration: none; color: var(--ink); background: #fff; }
.table-scroll { overflow-x: auto; border-radius: var(--r); border: 1px solid var(--line); background: #fff; }
.menu-table { border-collapse: collapse; width: 100%; min-width: 720px; }
.menu-table th, .menu-table td { padding: .9rem 1rem; text-align: left; vertical-align: top; border-bottom: 1px solid var(--line); font-size: .95rem; }
.menu-table thead th { background: var(--forest); color: #fff; font-weight: 600; }
.menu-table tbody th small { display: block; color: var(--olive); font-weight: 600; }
.menu-table .is-today { background: #eef2e2; }
.timeline { list-style: none; padding: 0; margin: 0; border-left: 2px solid var(--line); }
.timeline li { display: grid; grid-template-columns: 11rem 1fr; gap: 1rem; padding: 1rem 0 1rem 1.6rem; position: relative; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: 1.45rem; width: 12px; height: 12px; border-radius: 50%; background: var(--olive); }
.timeline h3 { font-size: 1.25rem; margin-bottom: .2rem; }
.tl-time { font-weight: 600; color: var(--olive); margin: .15rem 0 0; }
.cal-month { margin-bottom: 2.5rem; }
.cal-month h2 { font-size: 1.7rem; padding-bottom: .6rem; border-bottom: 1px solid var(--line); }
.cal-list { list-style: none; padding: 0; }
.cal-item { display: grid; grid-template-columns: 9rem 1fr; gap: 1rem; padding: 1rem 0; border-bottom: 1px solid var(--line); }
.cal-item.is-past { opacity: .6; }
.cal-item h3 { font-size: 1.2rem; margin-bottom: .2rem; }
.cal-date { font-weight: 600; color: var(--olive); margin: 0; }
.cal-type { font-size: .85rem; color: var(--ink-2); margin: 0; }
.dl-h { font-size: 1.5rem; margin-top: 1rem; }
.dl-list { list-style: none; padding: 0; display: grid; gap: .7rem; }
.dl-list a { display: flex; align-items: center; gap: 1rem; padding: 1.1rem 1.3rem; background: #fff; border: 1px solid var(--line); border-radius: var(--r); text-decoration: none; color: var(--ink); }
.dl-list a:hover { border-color: var(--olive); }
.dl-title { font-weight: 600; flex: 1; }
.dl-meta { font-size: .85rem; color: var(--ink-2); }

/* ---------- footer ---------- */
.footer { position: relative; background: var(--forest); color: #d3dacb; overflow: hidden; padding-top: clamp(3.5rem, 7vw, 5.5rem); }
.footer .kufic { position: absolute; right: -2vw; bottom: -4vw; font-size: clamp(10rem, 24vw, 22rem); color: #fff; opacity: .04; }
.footer a { color: #fff; text-decoration: none; }
.footer a:hover { text-decoration: underline; }
.footer-top { position: relative; display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr) minmax(0, .8fr); gap: clamp(2rem, 5vw, 4rem); padding-bottom: 3rem; }
.badge { display: inline-block; margin-bottom: 1.6rem; }
.badge img { height: 78px; width: auto; }
.social { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; margin: 0; }
.social a { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-width: 44px; height: 44px; border-radius: 999px; border: 1px solid var(--line-dark); color: #fff; }
.social a:hover { background: rgba(255, 255, 255, .1); text-decoration: none; }
.social-dark a { border-color: var(--line); color: var(--ink); padding: 0 1rem; text-decoration: none; }
.social-dark a:hover { background: #fff; color: var(--ink); }
.footer-contact { font-style: normal; }
.footer-contact p { margin: 0 0 1.1rem; font-size: 1rem; }
.footer-contact span { display: block; font-size: .82rem; font-weight: 600; color: #a9b79a; margin-bottom: .15rem; }
.footer-links h2 { font: 600 .82rem var(--sans); color: #a9b79a; margin-bottom: .8rem; letter-spacing: 0; }
.footer-links ul { list-style: none; padding: 0; margin: 0; columns: 2; column-gap: 1.5rem; }
.footer-links li { margin-bottom: .55rem; }
.footer-bottom { position: relative; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; padding-block: 1.4rem; border-top: 1px solid var(--line-dark); font-size: .88rem; color: #a9b79a; }
.footer-bottom p { margin: 0; display: flex; flex-wrap: wrap; gap: 1.3rem; }
.footer-bottom a { color: #d3dacb; }

/* floating actions */
.wa-float { position: fixed; right: 1.2rem; bottom: 1.2rem; z-index: 30; width: 56px; height: 56px; border-radius: 50%; display: grid; place-items: center; background: #25d366; color: #fff; box-shadow: 0 12px 28px -10px rgba(0, 0, 0, .45); transition: transform .2s; }
.wa-float .icon { width: 28px; height: 28px; }
.wa-float:hover { color: #fff; transform: scale(1.05); }
.mobile-cta { display: none; }

/* lightbox */
.lightbox { position: fixed; inset: 0; z-index: 90; background: rgba(15, 22, 14, .95); display: flex; align-items: center; justify-content: center; }
.lightbox[hidden] { display: none; }
.lightbox figure { margin: 0; max-width: 92vw; max-height: 86vh; text-align: center; }
.lightbox img { max-width: 92vw; max-height: 80vh; width: auto; margin-inline: auto; border-radius: 6px; }
.lightbox figcaption { color: #dfe5d8; margin-top: .8rem; }
.lightbox button { position: absolute; border: 0; background: rgba(255, 255, 255, .12); color: #fff; width: 52px; height: 52px; border-radius: 50%; font-size: 1.9rem; line-height: 1; cursor: pointer; }
.lightbox button:hover { background: rgba(255, 255, 255, .25); }
.lb-close { top: 1rem; right: 1rem; }
.lb-prev { left: 1rem; top: 50%; transform: translateY(-50%); }
.lb-next { right: 1rem; top: 50%; transform: translateY(-50%); }
.lb-count { position: absolute; bottom: 1rem; left: 50%; transform: translateX(-50%); color: #a9b79a; margin: 0; font-size: .9rem; }

/* ======================= v5 components ======================= */
/* ticker */
.ticker { background: var(--olive); color: #fff; font-size: .9rem; overflow: hidden; }
.ticker-in { display: flex; align-items: stretch; color: #fff; text-decoration: none; }
.ticker-in:hover { color: #fff; }
.ticker-tag { flex: none; display: flex; align-items: center; background: var(--red); padding: .55rem 1rem; font-weight: 700; font-size: .78rem; letter-spacing: .02em; position: relative; z-index: 1; }
.ticker-track { flex: 1; overflow: hidden; display: flex; align-items: center; mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); }
.ticker-run { display: flex; width: max-content; animation: marquee 32s linear infinite; }
.ticker-in:hover .ticker-run, .ticker-in:focus .ticker-run { animation-play-state: paused; }
.ticker-set { display: flex; }
.ticker-item { display: inline-flex; align-items: center; gap: .6rem; padding: .55rem 2rem .55rem 0; white-space: nowrap; font-weight: 500; }
.leafdot { width: 8px; height: 12px; border-radius: 100% 0 100% 0; background: #e8d48a; display: inline-block; }
@keyframes marquee { to { transform: translateX(-50%); } }
.topbar-links { display: flex; align-items: center; gap: 1.3rem; }
.topbar-links a { display: inline-flex; align-items: center; gap: .4rem; }
.topbar-links .icon { width: 14px; height: 14px; }
.topbar-social { display: inline-flex; gap: .2rem; margin-left: .2rem; }
.topbar-social a { width: 28px; height: 28px; justify-content: center; border-radius: 50%; }
.topbar-social a:hover { background: rgba(255, 255, 255, .12); }
.brand-badge { display: flex; align-items: center; background: var(--forest); border-radius: 12px; padding: .45rem .7rem; margin-right: auto; margin-left: .2rem; }
.brand-badge img { height: 36px; width: auto; }

/* pillars as photo cards */
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.2rem, 2.6vw, 2rem); }
.pcard { background: #fff; border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow); display: flex; flex-direction: column; border-bottom: 5px solid var(--c); }
.pcard-img img { transition: transform .8s var(--ease); }
.pcard:hover .pcard-img img { transform: scale(1.05); }
.pcard-body { padding: 1.6rem 1.6rem 1.8rem; display: flex; flex-direction: column; flex: 1; }
.pcard-body h3 { margin-bottom: .7rem; }
.pcard-text { color: var(--ink-2); font-size: .98rem; flex: 1; }
.pcard .tlink { align-self: flex-start; margin-top: 1rem; }

/* overview collage */
.overview { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(2rem, 6vw, 5.5rem); align-items: center; }
.collage { position: relative; display: grid; grid-template-columns: 1.15fr 1fr; grid-template-rows: 1fr 1fr 1fr; gap: .9rem; aspect-ratio: 1 / 1.02; }
.collage > div:not(.collage-badge) { position: relative; overflow: hidden; border-radius: var(--r); background: var(--line); }
.collage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.collage-1 { grid-row: 1 / 3; }
.collage-2 { grid-row: 1 / 2; }
.collage-3 { grid-row: 2 / 4; }
.collage-4 { grid-row: 3 / 4; }
.collage-badge { grid-column: 1 / -1; grid-row: 1 / -1; white-space: nowrap; z-index: 2; position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); display: flex; align-items: center; gap: .7rem; background: #fff; border-radius: 999px; padding: .5rem 1.3rem .5rem .5rem; box-shadow: 0 20px 40px -20px rgba(0, 0, 0, .45); }
.collage-badge img { width: 58px; height: 58px; border-radius: 50%; object-fit: contain; background: #fff; }
.collage-badge span { font-family: var(--serif); font-size: 1.35rem; line-height: 1; color: var(--ink); }
.collage-badge small { display: block; font-family: var(--sans); font-size: .78rem; color: var(--ink-2); margin-top: .25rem; }
.sec-overview { background: var(--paper); }

/* tabs */
.tablist { display: flex; flex-wrap: wrap; gap: .4rem; margin-bottom: 2rem; }
.tablist [role=tab] { border: 1.5px solid var(--line); background: #fff; color: var(--ink); padding: .7rem 1.3rem; border-radius: 999px; font-weight: 600; cursor: pointer; font-size: .95rem; }
.tablist [role=tab][aria-selected=true] { background: var(--olive); border-color: var(--olive); color: #fff; }
.tablist-sm { gap: .3rem; margin-bottom: 1rem; }
.tablist-sm [role=tab] { padding: .5rem .95rem; font-size: .86rem; }

/* leadership */
.sec-leaders { background: #fff; }
.leader-panel { display: grid; grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
.leader-panel[hidden] { display: none; }
.leader-photo { margin: 0; position: relative; }
.leader-photo .ratio { border-radius: var(--r-lg); }
.leader-photo .ratio img { object-position: center 20%; }
.leader-photo figcaption { position: absolute; left: 1rem; right: 1rem; bottom: 1rem; background: rgba(255, 255, 255, .94); border-radius: var(--r); padding: .8rem 1rem; display: flex; flex-direction: column; }
.leader-photo strong { font-family: var(--serif); font-size: 1.25rem; font-weight: 500; }
.leader-photo span { font-size: .88rem; color: var(--ink-2); }
.leader-msg h2 { font-size: clamp(1.9rem, 3vw, 2.6rem); }
.leader-msg > p { color: var(--ink-2); font-size: 1.06rem; max-width: 40em; }
.leader-greet { font-family: var(--serif); font-weight: 500; color: var(--ink) !important; font-size: 1.08rem !important; }

/* news + notice board */
.sec-board { background: var(--concrete); }
.board { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(0, 1fr); gap: clamp(1.4rem, 3vw, 2.4rem); align-items: start; }
.board-head { display: flex; justify-content: space-between; align-items: end; gap: 1rem; margin-bottom: 1.4rem; }
.board-head h2 { margin: 0; font-size: clamp(1.8rem, 3vw, 2.5rem); }
.board-news { display: grid; grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr); grid-template-rows: auto 1fr; gap: 0 1.6rem; }
.board-head { grid-column: 1 / -1; }
.news-lead { background: #fff; border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow); align-self: start; }
.news-lead .ratio img { transition: transform .8s var(--ease); }
.news-lead:hover .ratio img { transform: scale(1.04); }
.news-lead-body { padding: 1.3rem 1.5rem 1.6rem; }
.news-lead .meta, .news-text time { font-size: .84rem; color: var(--ink-2); display: flex; gap: .6rem; align-items: center; margin-bottom: .45rem; }
.news-lead h3 { font-size: 1.5rem; margin: 0; }
.news-lead h3 a { color: var(--ink); text-decoration: none; }
.news-list { list-style: none; padding: 0; margin: 0; display: grid; gap: .7rem; align-content: start; }
.news-list a { display: grid; grid-template-columns: 112px minmax(0, 1fr); gap: 1rem; align-items: center; padding: .55rem; border-radius: var(--r); background: #fff; text-decoration: none; color: var(--ink); transition: box-shadow .2s, transform .2s; }
.news-list a:hover { box-shadow: var(--shadow); transform: translateY(-1px); }
.news-thumb { border-radius: 12px; }
.news-text strong { display: block; font-family: var(--serif); font-weight: 500; font-size: 1.08rem; line-height: 1.25; margin-bottom: .3rem; }
.news-text time { margin: 0; }
.noticeboard { background: #fff; border-radius: var(--r-lg); box-shadow: var(--shadow); padding: 1.4rem 1.4rem 1rem; display: flex; flex-direction: column; }
.nb-head { display: flex; align-items: center; gap: .6rem; margin-bottom: 1rem; }
.nb-head .icon { width: 26px; height: 26px; color: var(--red); }
.nb-head h2 { margin: 0; font-size: 1.6rem; }
.nb-panel { max-height: 430px; overflow-y: auto; scrollbar-width: thin; margin-right: -.4rem; padding-right: .4rem; }
.notices, .agenda { list-style: none; margin: 0; padding: 0; }
.notices li + li, .agenda li + li { border-top: 1px solid var(--line); }
.notices a, .notice-static, .agenda a { display: grid; grid-template-columns: 52px minmax(0, 1fr); gap: .9rem; align-items: center; padding: .8rem .2rem; color: var(--ink); text-decoration: none; }
.notices a:hover strong, .agenda a:hover strong { color: var(--olive); text-decoration: underline; }
.dtile { display: grid; place-items: center; align-content: center; width: 52px; height: 52px; border-radius: 12px; background: var(--paper); border: 1px solid var(--line); font-size: .72rem; font-weight: 600; color: var(--ink-2); line-height: 1.1; text-transform: uppercase; }
.dtile b { font-family: var(--serif); font-size: 1.35rem; font-weight: 500; color: var(--olive); }
.dtile-icon .icon { width: 22px; height: 22px; color: var(--olive); }
.nl-text strong { display: block; font-weight: 600; font-size: .96rem; line-height: 1.35; }
.nl-text small { display: block; font-size: .8rem; color: var(--ink-2); margin-top: .15rem; }
.nl-body { display: block; font-size: .9rem; color: var(--ink-2); margin-top: .3rem; }
.new { font-style: normal; font-size: .68rem; font-weight: 700; color: #fff; background: var(--red); padding: .1rem .45rem; border-radius: 999px; vertical-align: 2px; animation: pulse 2s ease-in-out infinite; }
@keyframes pulse { 50% { opacity: .6; } }
.nb-empty { text-align: center; padding: 1.5rem .5rem; color: var(--ink-2); }
.nb-empty .icon { width: 36px; height: 36px; color: var(--olive); margin: 0 auto .6rem; }
.nb-none { color: var(--ink-2); padding: 1rem 0; }
.nb-all { display: flex; justify-content: center; align-items: center; gap: .4rem; margin-top: .6rem; padding: .8rem; border-top: 1px solid var(--line); font-weight: 600; text-decoration: none; }
.nb-all .icon { width: 16px; height: 16px; }
.board-page { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); }
.nb-page .notices a { padding-block: 1rem; }

/* admissions panel */
.sec-admit { background: var(--paper); }
.admit { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); background: var(--forest); color: #fff; border-radius: var(--r-lg); overflow: hidden; }
.admit-img { aspect-ratio: auto; min-height: 100%; }
.admit-body { padding: clamp(2rem, 5vw, 3.6rem); position: relative; }
.admit-label { color: #b9c69a; font-weight: 600; margin-bottom: .4rem; }
.admit-body h2 { font-size: clamp(2.2rem, 4vw, 3.4rem); margin-bottom: 1.4rem; }
.admit-facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: .8rem; margin: 0; }
.admit-facts div { border-top: 3px solid var(--red); padding-top: .8rem; }
.admit-facts div:nth-child(2) { border-color: var(--blue); }
.admit-facts div:nth-child(3) { border-color: var(--green); }
.admit-facts dt { font-size: .85rem; color: #c9d1c2; }
.admit-facts dd { margin: .2rem 0 0; font-family: var(--serif); font-size: 1.45rem; }

/* reels */
.sec-feed { background: #fff; overflow: hidden; }
.feed-sub { font-family: var(--serif); font-weight: 500; font-size: 1.2rem !important; color: var(--olive) !important; margin: .4rem 0 .3rem !important; }
.carousel-btns { display: flex; gap: .5rem; }
.cbtn { display: grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; border: 1.5px solid var(--line); background: #fff; cursor: pointer; color: var(--ink); }
.cbtn:hover { border-color: var(--olive); color: var(--olive); }
.cbtn[disabled] { opacity: .35; cursor: default; }
.carousel { overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; padding-inline: max(var(--gutter), calc((100vw - 1260px) / 2 + var(--gutter))); scroll-padding-inline: max(var(--gutter), calc((100vw - 1260px) / 2 + var(--gutter))); }
.carousel::-webkit-scrollbar { display: none; }
.carousel-track { display: flex; gap: 1.1rem; width: max-content; padding-bottom: .4rem; }
.reel { margin: 0; width: clamp(220px, 22vw, 280px); scroll-snap-align: start; }
.video-reel { aspect-ratio: 9 / 16; border-radius: var(--r-lg); }
.video-reel .video-play { flex-direction: column; justify-content: flex-end; padding-bottom: 1.6rem; }
.video-reel .video-play-icon { width: 58px; height: 58px; }
.video-reel .video-play-label { display: none; }
.reel figcaption { margin-top: .7rem; font-weight: 600; font-size: .95rem; }

/* tour */
.sec-tour { background: var(--concrete); }
.tour { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(0, 1fr); gap: clamp(1.2rem, 3vw, 2rem); align-items: end; }
.tour h2 { margin-bottom: 1.2rem; }
.tour-side { display: grid; gap: 1.2rem; }
.tour-item h3 { font-size: 1.2rem; margin: .7rem 0 0; }
.yt-card { display: flex; align-items: center; gap: 1rem; background: #fff; border-radius: var(--r-lg); padding: 1.2rem 1.4rem; text-decoration: none; color: var(--ink-2); box-shadow: var(--shadow); }
.yt-card .icon { width: 44px; height: 44px; color: #e62117; flex: none; }
.yt-card strong { display: block; color: var(--ink); font-size: 1.05rem; }

/* facility tabs */
.sec-campus-tabs { background: #fff; }
.ftabs { display: grid; grid-template-columns: minmax(0, 300px) minmax(0, 1fr); gap: clamp(1.4rem, 3vw, 2.6rem); align-items: start; }
.ftab-list { display: grid; gap: .35rem; }
.ftab-list [role=tab] { display: flex; align-items: center; gap: .8rem; text-align: left; border: 0; background: var(--paper); border-radius: var(--r); padding: .7rem 1rem; font-weight: 600; cursor: pointer; color: var(--ink); border-left: 4px solid transparent; }
.ftab-list [role=tab] img { width: 36px; height: 36px; object-fit: contain; background: #fff; border-radius: 50%; padding: 4px; }
.ftab-list [role=tab][aria-selected=true] { background: var(--forest); color: #fff; border-left-color: var(--green); }
.ftab-panel { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); gap: clamp(1.2rem, 3vw, 2.2rem); align-items: center; }
.ftab-panel[hidden] { display: none; }
.ftab-panel .ratio { border-radius: var(--r-lg); }
.ftab-text p { color: var(--ink-2); }

/* parents' voices */
.sec-parents .quotes { grid-template-columns: repeat(3, minmax(0, 1fr)); display: grid; gap: clamp(1rem, 2.4vw, 1.8rem); }
.sec-parents .quote { background: #fff; box-shadow: var(--shadow); display: flex; flex-direction: column; }
.sec-parents .quote blockquote { flex: 1; }
.sec-parents .quote blockquote p { font-size: 1.08rem; }
.quote figcaption { flex-direction: row !important; align-items: center; gap: .8rem; }
.quote figcaption > span:last-child { display: flex; flex-direction: column; font-size: .88rem; color: var(--ink-2); }
.avatar { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--c); color: #fff; font-family: var(--serif); font-size: 1.3rem; flex: none; }

/* plan + strip */
.sec-plan { background: var(--paper); padding-bottom: 0; overflow: hidden; }
.plan { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 1rem; margin-bottom: clamp(2.5rem, 5vw, 4rem); }
.plan-card { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .9rem; background: #fff; border-radius: var(--r); padding: 1.1rem 1.2rem; text-decoration: none; color: var(--ink); border: 1px solid var(--line); transition: border-color .2s, box-shadow .2s; }
.plan-card:hover { border-color: var(--olive); box-shadow: var(--shadow); color: var(--ink); }
.plan-card .icon { width: 28px; height: 28px; color: var(--olive); }
.plan-card span { font-size: .82rem; font-weight: 600; color: var(--olive); }
.strip { overflow: hidden; padding-bottom: var(--sec); }
.strip-run { display: flex; width: max-content; animation: marquee 60s linear infinite; }
.strip:hover .strip-run { animation-play-state: paused; }
.strip-set { display: flex; gap: 1rem; padding-right: 1rem; }
.strip .ratio { width: 300px; border-radius: var(--r); }

/* event gallery: uniform 4:3 tiles, first one large */
.photo-grid { columns: auto; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .8rem; }
.photo { position: relative; margin: 0; aspect-ratio: 4 / 3; border-radius: var(--r-sm); }
.photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.photo:first-child { grid-column: span 2; grid-row: span 2; }
.photo::after { content: ""; position: absolute; inset: 0; background: rgba(20, 30, 18, 0); transition: background .25s; }
.photo:hover::after { background: rgba(20, 30, 18, .18); }
.video-list { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
.video-list .video { aspect-ratio: 9 / 16; }

/* footer additions */
.footer-cta { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1.5rem; padding-bottom: clamp(2.5rem, 5vw, 3.5rem); margin-bottom: clamp(2.5rem, 5vw, 3.5rem); border-bottom: 1px solid var(--line-dark); }
.footer-cta h2 { color: #fff; font-size: clamp(1.7rem, 3vw, 2.4rem); margin: 0 0 .3rem; }
.footer-cta p { margin: 0; }
.footer-cta .leaves { margin-bottom: .8rem; }
.footer-cta .actions { margin: 0; }
.footer-top { grid-template-columns: minmax(0, 1.3fr) minmax(0, .7fr) minmax(0, .7fr) minmax(0, 1.2fr); }
.footer-links ul { columns: 1; }
.footer-map h2 { font: 600 .82rem var(--sans); color: #a9b79a; margin-bottom: .8rem; letter-spacing: 0; }
.map-sm { aspect-ratio: 4 / 3; border-radius: var(--r); }
.footer .map-load small { color: var(--ink-2); }
.footer .social { margin-top: 1.2rem; }
.applyband { display: none; }

/* ---------- responsive ---------- */
@media (max-width: 1240px) {
  .nav-list > li > a, .sub-toggle { padding-inline: .5rem; font-size: .93rem; }
  .facilities { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .reach { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ugrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 1100px) {
  .nav-toggle { display: inline-flex; }
  .nav { position: fixed; top: var(--nav-top, 84px); left: 0; right: 0; bottom: 0; z-index: 39; flex-direction: column; align-items: stretch; gap: 1rem; padding: 1rem var(--gutter) 6rem; background: #fff; overflow-y: auto; transform: translateX(100%); visibility: hidden; transition: transform .3s var(--ease), visibility 0s .3s; }
  .nav.is-open { transform: none; visibility: visible; transition: transform .3s var(--ease); }
  .nav-list { flex-direction: column; gap: 0; }
  .nav-list > li { border-bottom: 1px solid var(--line); }
  .nav-list > li > a, .sub-toggle { width: 100%; justify-content: space-between; padding: 1rem .2rem; font-size: 1.12rem; border-radius: 0; }
  .sub { position: static; display: none; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 0 0 .8rem .6rem; background: none; }
  .has-sub.is-open .sub { display: block; }
  .nav-tools { justify-content: space-between; }
  .nav-tools .btn { flex: 1; }
  body.nav-open { overflow: hidden; }
  .steps { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .hero-in, .why, .campus, .stage-in, .voices, .parents, .faqmore, .letter, .pagehead.has-image .pagehead-in { grid-template-columns: minmax(0, 1fr); }
  .hero-visual { justify-self: center; width: min(82%, 440px); order: -1; }
  .hero { padding-top: 2.4rem; }
  .why-visual { max-width: 420px; }
  .stage-flip .stage-text { order: 0; }
  .stage-img { max-width: 520px; }
  .aperture-head { display: none; }
  .sec-head.split { grid-template-columns: minmax(0, 1fr); }
  .pillars, .holistic, .mpillars { grid-template-columns: minmax(0, 1fr); }
  .pillar { display: grid; grid-template-columns: 38% minmax(0, 1fr); gap: 0 1.4rem; align-items: start; }
  .pillar-img { grid-row: span 3; margin: 0; }
  .vm { grid-template-columns: minmax(0, 1fr); }
  .vm-col { padding-right: 0; }
  .vm-col + .vm-col { border-left: 0; border-top: 1px solid var(--line-dark); padding-left: 0; }
  .leaders, .req { grid-template-columns: minmax(0, 1fr); }
  .parents-video, .letter-side { position: static; }
  .voices-video, .parents-video { max-width: 420px; }
  .footer-top { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .footer-brand { grid-column: 1 / -1; }
  .ugrid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  body { font-size: 1rem; }
  .topbar-links { display: none; }
  .masthead-in { min-height: 70px; }
  .brand img { height: 46px; }
  .nav { --nav-top: 70px; }
  
  .pillar { display: block; }
  .pillar-img { margin-bottom: 1.2rem; aspect-ratio: 4 / 3; border-radius: 160px 160px var(--r) var(--r); }
  .leader { grid-template-columns: minmax(0, 1fr); }
  .aperture-leader { width: 110px; }
  .ugrid, .ugrid-3, .facilities, .reach, .facts, .steps { grid-template-columns: minmax(0, 1fr); }
  .field-row { grid-template-columns: minmax(0, 1fr); }
  .upcoming li, .timeline li, .cal-item { grid-template-columns: minmax(0, 1fr); gap: .1rem; }
  .upcoming small { grid-column: 1; }
  .footer-top { grid-template-columns: minmax(0, 1fr); }
  .map { aspect-ratio: 4 / 5; }
  .search-form { flex-direction: column; }
  .mobile-cta { position: fixed; left: 0; right: 0; bottom: 0; z-index: 29; display: grid; grid-template-columns: 1fr 1fr; background: var(--forest); box-shadow: 0 -10px 30px -20px rgba(0, 0, 0, .5); }
  .mobile-cta a { display: flex; align-items: center; justify-content: center; min-height: 56px; color: #fff; font-weight: 600; text-decoration: none; }
  .mobile-cta a + a { border-left: 1px solid var(--line-dark); }
  .wa-float { bottom: 72px; width: 50px; height: 50px; }
  .footer { padding-bottom: 56px; }
  .actions .btn { flex: 1 1 auto; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
}
@media print {
  .topbar, .masthead, .footer, .wa-float, .mobile-cta, .video-play, .slide-ctrl { display: none !important; }
  body { background: #fff; }
}

@media (max-width: 1340px) {
  .brand-badge { display: none; }
}
@media (max-width: 1100px) {
  .board, .board-page { grid-template-columns: minmax(0, 1fr); }
  .footer-top { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .plan { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .ftabs { grid-template-columns: minmax(0, 1fr); }
  .ftab-list { grid-auto-flow: column; grid-auto-columns: max-content; overflow-x: auto; padding-bottom: .4rem; }
}
@media (max-width: 900px) {
  .hero { min-height: 0; align-items: flex-end; padding: 9rem 0 4.5rem; }
  .hero-shade { background: linear-gradient(0deg, rgba(20, 30, 18, .92) 0%, rgba(20, 30, 18, .6) 45%, rgba(20, 30, 18, .1) 80%); }
  .hero-ctrl { justify-content: center; bottom: 1rem; }
  .slide-arrow { display: none !important; }
  .traits-bar { margin-top: 0; }
  .traits { grid-template-columns: minmax(0, 1fr); border-radius: 0; box-shadow: none; }
  .trait-card + .trait-card { border-left: 0; }
  .pillars, .sec-parents .quotes { grid-template-columns: minmax(0, 1fr); }
  .overview, .leader-panel, .admit, .tour, .ftab-panel { grid-template-columns: minmax(0, 1fr); }
  .leader-photo { max-width: 340px; }
  .admit-img { aspect-ratio: 16 / 9; }
  .board-news { grid-template-columns: minmax(0, 1fr); gap: 1rem; }
  .collage { max-width: 560px; }
  .topbar-links:first-child a:last-child { display: none; }
}
@media (max-width: 640px) {
  .topbar { display: none; }
  .ticker-tag { display: none; }
  .hero { padding-top: 12rem; }
  .hero h1 { font-size: clamp(2rem, 9vw, 2.6rem); }
  .admit-facts { grid-template-columns: minmax(0, 1fr); }
  .plan { grid-template-columns: minmax(0, 1fr); }
  .footer-top { grid-template-columns: minmax(0, 1fr); }
  .photo-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .strip .ratio { width: 220px; }
  .news-list a { grid-template-columns: 96px minmax(0, 1fr); }
  .collage-badge { padding-right: .9rem; }
  .collage-badge span { font-size: 1.1rem; }
}
@media (prefers-reduced-motion: reduce) {
  .ticker-run, .strip-run { animation: none !important; }
  .strip { overflow-x: auto; }
}
.footer .btn-light, .footer .btn-light:hover { color: var(--forest); text-decoration: none; }
.footer .btn-ghost:hover { text-decoration: none; }
@media (max-width: 640px) {
  .collage-badge { display: none; }
  .leader-photo { max-width: 240px; }
  .board-head .tlink { white-space: nowrap; }
}

/* ======================= v6 ======================= */
/* section titles: last word in olive with a hand-drawn underline, as on the school's preferred feed */
.st { font-size: clamp(2rem, 3.6vw, 3rem); font-weight: 700; letter-spacing: -.02em; }
.st em { font-style: normal; color: var(--olive); position: relative; white-space: nowrap; }
.st em::after { content: ""; position: absolute; left: 4%; right: 0; bottom: -.32em; height: .3em; background: no-repeat center / 100% 100% url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 20' preserveAspectRatio='none'%3E%3Cpath d='M3 15 Q100 1 197 13' fill='none' stroke='%234f5f2a' stroke-width='4' stroke-linecap='round'/%3E%3C/svg%3E"); }
.dark .st em { color: #c9dc8f; }
.dark .st em::after { filter: brightness(2.2); }
.sec-head.center .st + p { margin-top: 1.2rem; }

/* Our Feed: centred title, four reels in view, arrows at the sides */
.sec-feed .sec-head { margin-bottom: clamp(2rem, 4vw, 3rem); }
.feed { position: relative; padding-inline: 3.4rem; }
.feed .carousel { padding-inline: 0; scroll-padding-inline: 0; }
.feed .carousel-track { gap: clamp(1rem, 2.4vw, 2.2rem); }
.feed .reel { width: calc((100% - 3 * clamp(1rem, 2.4vw, 2.2rem)) / 4); min-width: 220px; }
.feed .carousel-track { width: 100%; }
.feed-arrow { position: absolute; top: calc(50% - 1.4rem); transform: translateY(-50%); z-index: 2; display: grid; place-items: center; width: 44px; height: 44px; border: 0; background: none; color: var(--green); cursor: pointer; border-radius: 50%; }
.feed-arrow .icon { width: 30px; height: 30px; }
.feed-arrow:hover { background: var(--paper); }
.feed-arrow[disabled] { opacity: .3; cursor: default; }
.feed-prev { left: 0; } .feed-next { right: 0; }
.video-reel { border-radius: 22px; box-shadow: 0 18px 40px -26px rgba(0, 0, 0, .55); }
.reel figcaption { text-align: center; color: var(--ink-2); font-weight: 500; }

/* life at ZIA: five photo tiles */
.life { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1rem; }
.life-tile { position: relative; display: block; border-radius: var(--r-lg); overflow: hidden; aspect-ratio: 3 / 4; color: #fff; text-decoration: none; background: var(--forest); }
.life-tile img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .8s var(--ease); }
.life-tile:hover img { transform: scale(1.06); }
.life-tile::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(18, 28, 17, .92) 0%, rgba(18, 28, 17, .35) 48%, rgba(18, 28, 17, 0) 70%); }
.life-text { position: absolute; z-index: 1; left: 1.2rem; right: 1.2rem; bottom: 1.2rem; }
.life-text strong { display: block; font-family: var(--serif); font-size: 1.3rem; font-weight: 600; margin-bottom: .3rem; }
.life-text span { display: block; font-size: .88rem; line-height: 1.45; color: #e3e8dc; }
.life-tile .bar { position: absolute; z-index: 1; left: 1.2rem; top: 1.2rem; width: 34px; height: 4px; border-radius: 4px; background: var(--c); }
.life-tile:hover { color: #fff; }

/* achievements */
.achieve { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1rem, 2.4vw, 1.8rem); }
.ach { display: flex; flex-direction: column; background: #fff; border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow); text-decoration: none; color: var(--ink); }
.ach .ratio img { transition: transform .8s var(--ease); }
.ach:hover .ratio img { transform: scale(1.05); }
.ach-body { padding: 1.2rem 1.4rem 1.5rem; }
.ach-body time { font-size: .84rem; color: var(--ink-2); }
.ach-body h3 { font-size: 1.25rem; margin: .3rem 0 0; }
.ach-badge { position: absolute; left: 1rem; top: 1rem; z-index: 1; background: #e8d48a; color: var(--forest); font-size: .78rem; font-weight: 700; padding: .25rem .7rem; border-radius: 999px; }

/* facility categories */
.fcat { margin-top: clamp(3rem, 6vw, 4.5rem); }
.fcat:first-child { margin-top: 0; }
.fcat-head { display: flex; align-items: center; gap: .9rem; margin-bottom: 1.4rem; }
.fcat-head h2 { margin: 0; font-size: clamp(1.6rem, 2.6vw, 2.2rem); }
.fcat-head .bar { width: 40px; height: 5px; border-radius: 5px; background: var(--c, var(--olive)); }
.fgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(.9rem, 2vw, 1.4rem); }
.fitem { background: #fff; border-radius: var(--r-lg); overflow: hidden; box-shadow: 0 16px 34px -28px rgba(29, 42, 34, .5); display: flex; flex-direction: column; }
.fitem .ratio { background: var(--paper); }
.fitem .ratio .fitem-icon { position: absolute; inset: 0; display: grid; place-items: center; }
.fitem .ratio .fitem-icon img { position: static; width: 64px; height: 64px; object-fit: contain; }
.fitem .ratio .fitem-icon span { width: 54px; height: 54px; border-radius: 100% 0 100% 0; background: var(--c, var(--olive)); opacity: .9; }
.fitem-body { padding: 1.1rem 1.2rem 1.3rem; }
.fitem-body h3 { font-size: 1.15rem; margin-bottom: .35rem; }
.fitem-body p { margin: 0; font-size: .93rem; color: var(--ink-2); }
.spotlight { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 0; background: var(--forest); color: #fff; border-radius: var(--r-lg); overflow: hidden; }
.spotlight .ratio { min-height: 100%; aspect-ratio: auto; }
.spotlight-body { padding: clamp(2rem, 5vw, 3.4rem); }
.spotlight-label { display: inline-block; background: #e8d48a; color: var(--forest); font-weight: 700; font-size: .8rem; padding: .3rem .8rem; border-radius: 999px; margin-bottom: 1rem; }
.spotlight h2 { font-size: clamp(2rem, 4vw, 3rem); margin-bottom: 1rem; }
.spotlight p { color: #dfe5d8; font-size: 1.05rem; }
.cat-academic { --c: var(--blue); } .cat-sports { --c: var(--red); } .cat-residential { --c: var(--green); } .cat-other { --c: var(--olive); }
.chips { display: flex; flex-wrap: wrap; gap: .45rem; margin: 1rem 0 1.3rem; padding: 0; list-style: none; }
.chips li { background: var(--paper); border: 1px solid var(--line); border-radius: 999px; padding: .3rem .8rem; font-size: .86rem; font-weight: 500; }

/* student development */
.devgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1rem, 2.4vw, 1.6rem); }
.dev { background: #fff; border-radius: var(--r-lg); overflow: hidden; box-shadow: var(--shadow); }
.dev-body { padding: 1.3rem 1.4rem 1.5rem; border-top: 4px solid var(--c, var(--olive)); }
.dev-body h3 { font-size: 1.25rem; }
.dev-body p { margin: 0; font-size: .95rem; color: var(--ink-2); }

/* newsletter: A4 covers */
.newsgrid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(1rem, 2.4vw, 1.8rem); }
.nl-card { display: block; text-decoration: none; color: var(--ink); }
.nl-cover { aspect-ratio: 1 / 1.414; border-radius: var(--r); overflow: hidden; box-shadow: 0 20px 40px -26px rgba(0, 0, 0, .5); background: linear-gradient(160deg, var(--forest), var(--olive)); position: relative; }
.nl-cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.nl-card:hover .nl-cover img { transform: scale(1.04); }
.nl-cover .nl-ph { position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end; padding: 1.2rem; color: #fff; font-family: var(--serif); font-size: 1.4rem; font-weight: 600; line-height: 1.15; }
.nl-cover .nl-ph small { font-family: var(--sans); font-size: .8rem; font-weight: 500; color: #c9dc8f; }
.nl-meta { margin-top: .8rem; }
.nl-meta strong { display: block; font-weight: 600; }
.nl-meta span { font-size: .86rem; color: var(--ink-2); }

/* FAQ filter chips */
.faq-filter { display: flex; flex-wrap: wrap; gap: .45rem; margin-bottom: 1.8rem; }
.faq-filter button { border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: .5rem 1rem; font-weight: 500; font-size: .9rem; cursor: pointer; }
.faq-filter button[aria-pressed=true] { background: var(--olive); border-color: var(--olive); color: #fff; }
.faq-group { font-size: 1.35rem; margin: 2rem 0 .9rem; }
.fees { background: #fff; border-radius: var(--r-lg); padding: clamp(1.4rem, 3vw, 2rem); box-shadow: var(--shadow); margin-top: 2rem; display: flex; flex-wrap: wrap; gap: 1rem 2rem; align-items: center; justify-content: space-between; }
.fees h3 { margin: 0 0 .3rem; }
.fees p { margin: 0; color: var(--ink-2); }

@media (max-width: 1100px) {
  .life { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .fgrid, .newsgrid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .feed .reel { width: calc((100% - 2 * 1.4rem) / 3); }
}
@media (max-width: 900px) {
  .achieve, .devgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .spotlight { grid-template-columns: minmax(0, 1fr); }
  .spotlight .ratio { aspect-ratio: 16 / 10; }
  .feed { padding-inline: 0; }
  .feed-arrow { display: none; }
  .feed .carousel { padding-inline: var(--gutter); margin-inline: calc(var(--gutter) * -1); }
  .feed .carousel-track { width: max-content; }
  .feed .reel { width: 240px; }
}
@media (max-width: 640px) {
  .life { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .life-tile:first-child { grid-column: span 2; aspect-ratio: 16 / 10; }
  .achieve, .devgrid { grid-template-columns: minmax(0, 1fr); }
  .fgrid, .newsgrid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .fitem-body p { display: none; }
  .feed .reel { width: 72vw; }
}

.sec-jump { background: #fff; border-bottom: 1px solid var(--line); position: sticky; top: 76px; z-index: 20; }
.sec-jump .filters { list-style: none; padding: .8rem 0; margin: 0; overflow-x: auto; flex-wrap: nowrap; }
.sec-jump .filters a { white-space: nowrap; }
.sec-archery { background: var(--paper); padding-bottom: 0; }
.sec-dev { background: var(--concrete); }
.sec-life { background: #fff; }
.sec-achieve { background: var(--paper); }
.ach .ratio { display: block; }
@media (max-width: 640px) { .sec-jump { top: 70px; } }
.brand { flex: none; }

/* ======================= v6.2 ======================= */
/* leadership: two open cards */
.leaders2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(1.2rem, 3vw, 2.2rem); }
.lcard { display: flex; flex-direction: column; background: var(--paper); border-radius: var(--r-lg); padding: clamp(1.4rem, 3vw, 2.2rem); border-top: 5px solid var(--c); }
.l-red { --c: var(--red); } .l-blue { --c: var(--blue); } .l-green { --c: var(--green); }
.lcard-top { display: grid; grid-template-columns: 132px minmax(0, 1fr); gap: 1.3rem; align-items: end; margin-bottom: 1.3rem; }
.lcard-photo { border-radius: var(--r); }
.lcard-photo img { object-position: center 18%; }
.lcard-id h2 { font-size: clamp(1.35rem, 2vw, 1.7rem); margin-bottom: .7rem; }
.lcard-id p { margin: 0; display: flex; flex-direction: column; }
.lcard-id strong { font-size: 1.1rem; font-weight: 600; }
.lcard-id span { font-size: .9rem; color: var(--ink-2); }
.lcard-text { color: var(--ink-2); flex: 1; }
.lcard .btn { align-self: flex-start; margin-top: .4rem; }

/* parents' voices: video + testimonials */
.pv { display: grid; grid-template-columns: minmax(0, 340px) minmax(0, 1fr); gap: clamp(1.4rem, 3vw, 2.4rem); align-items: start; }
.pv-novideo { grid-template-columns: minmax(0, 1fr); }
.pv-video { margin: 0; position: sticky; top: 110px; }
.pv-video figcaption { text-align: center; margin-top: .7rem; font-weight: 500; color: var(--ink-2); }
.pv-quotes { display: grid; gap: 1rem; }
.pv-novideo .pv-quotes { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.pv-quotes .quote { background: #fff; box-shadow: var(--shadow); }
.pv-quotes .quote blockquote p { font-size: 1.02rem; }

/* footer: one compact row */
.footer { padding-top: clamp(3rem, 6vw, 4.2rem); }
.footer-top { grid-template-columns: minmax(0, 1.15fr) minmax(0, 1.05fr) minmax(0, 1fr) minmax(0, 1.1fr); gap: clamp(1.6rem, 4vw, 3rem); padding-bottom: 2.4rem; align-items: start; }
.footer-top h2 { font: 600 .82rem var(--sans); color: #a9b79a; margin: 0 0 .9rem; letter-spacing: 0; }
.footer .badge { display: block; margin: 0 0 1.4rem; padding: 0 0 1.4rem; border-bottom: 1px solid var(--line-dark); }
.footer .badge img { height: auto; width: 100%; max-width: 280px; }
.footer .social { margin-top: 0; }
.footer-contact p { margin: 0 0 .8rem; font-size: .95rem; line-height: 1.5; }
.footer-links ul { columns: 2; column-gap: 1.2rem; }
.footer-links li { margin-bottom: .5rem; font-size: .95rem; break-inside: avoid; }
.footer-map .map-sm { aspect-ratio: 16 / 10; }
.footer-cta { display: none; }
@media (max-width: 1100px) {
  .footer-top { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
  .footer-brand { grid-column: auto; }
}
@media (max-width: 900px) {
  .leaders2, .pv { grid-template-columns: minmax(0, 1fr); }
  .pv-video { position: static; max-width: 320px; margin-inline: auto; }
  .pv-novideo .pv-quotes { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 640px) {
  .lcard-top { grid-template-columns: 100px minmax(0, 1fr); }
  .footer-top { grid-template-columns: minmax(0, 1fr); gap: 1.8rem; }
  .footer .badge img { max-width: 240px; }
}

/* ======================= v8: enquiry page ======================= */
.enq { position: relative; overflow: hidden; background: linear-gradient(180deg, var(--forest) 0 470px, var(--concrete) 470px); padding: clamp(2rem, 5vw, 3.5rem) 0 var(--sec); }
.enq-kufic { position: absolute; right: -3vw; top: -2vw; font-size: clamp(10rem, 26vw, 22rem); color: #fff; opacity: .04; }
.enq-grid { position: relative; display: grid; grid-template-columns: minmax(0, .95fr) minmax(0, 1.05fr); grid-template-areas: "head card" "info card"; gap: 0 clamp(1.6rem, 4vw, 3.4rem); align-items: start; }
.enq-side { grid-area: head; } .enq-info { grid-area: info; } .enq-card { grid-area: card; }
.enq-side { color: #fff; padding-top: .4rem; }
.crumbs-light, .crumbs-light a { color: #b9c69a; }
.crumbs-light [aria-current] { color: #fff; }
.enq-kicker { display: inline-flex; align-items: center; gap: .6rem; color: #e8d48a; font-weight: 600; font-size: .92rem; margin: 0 0 .8rem; }
.enq-kicker .leaves { margin: 0; }
.enq-kicker .leaves i { width: 9px; height: 15px; }
.enq-side h1 { font-size: clamp(2.6rem, 5.6vw, 4.4rem); font-weight: 700; letter-spacing: -.03em; margin-bottom: .9rem; }
.enq-lead { color: #dfe5d8; font-size: 1.1rem; max-width: 30em; }
.enq-note { display: inline-block; background: rgba(232, 212, 138, .14); border: 1px solid rgba(232, 212, 138, .4); color: #f3e8bd; border-radius: var(--r); padding: .7rem 1rem; font-size: .95rem; max-width: 32em; }
.enq-steps { list-style: none; padding: 0; margin: 2rem 0; display: grid; gap: .3rem; color: var(--ink); background: #fff; border-radius: var(--r-lg); box-shadow: var(--shadow); padding: 1.2rem 1.4rem; }
.enq-steps li { display: flex; gap: 1rem; align-items: flex-start; padding: .65rem 0; }
.enq-steps li + li { border-top: 1px solid var(--line); }
.enq-steps span { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; color: #fff; font-weight: 700; font-family: var(--serif); background: var(--red); }
.enq-steps li:nth-child(2) span { background: var(--blue); }
.enq-steps li:nth-child(3) span { background: var(--green); }
.enq-steps strong { display: block; font-family: var(--serif); font-weight: 600; font-size: 1.05rem; }
.enq-steps div { font-size: .92rem; color: var(--ink-2); }
.enq-contact { display: grid; gap: .6rem; }
.enq-contact a { display: flex; align-items: center; gap: .9rem; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: .75rem 1rem; color: var(--ink); text-decoration: none; transition: border-color .2s, transform .2s; }
.enq-contact a:hover { border-color: var(--olive); transform: translateY(-1px); color: var(--ink); }
.enq-contact .icon { width: 22px; height: 22px; color: var(--olive); flex: none; }
.enq-contact small { display: block; font-size: .78rem; color: var(--ink-2); }
.enq-contact span { font-weight: 600; overflow-wrap: anywhere; }

.enq-card { position: relative; background: #fff; border-radius: 28px; padding: clamp(1.6rem, 4vw, 2.8rem); box-shadow: 0 40px 80px -40px rgba(18, 28, 17, .55); }
.enq-card::before { content: ""; position: absolute; left: 2rem; right: 2rem; top: 0; height: 5px; border-radius: 0 0 6px 6px; background: linear-gradient(90deg, var(--red) 0 33.3%, var(--blue) 33.3% 66.6%, var(--green) 66.6%); }
.enq-card-head h2 { font-size: 1.6rem; margin-bottom: .2rem; }
.enq-card-head p { color: var(--ink-2); font-size: .92rem; margin-bottom: 1.6rem; }
.enq-card-head b, .fl label b { color: var(--red); }
.fl-row { display: grid; grid-template-columns: 1fr 1fr; gap: 0 1rem; }
/* floating labels */
.fl { position: relative; margin-bottom: 1.05rem; }
.fl input, .fl textarea { width: 100%; font: inherit; font-size: 1rem; color: var(--ink); background: var(--paper); border: 1.5px solid var(--line); border-radius: 14px; padding: 1.45rem 1rem .55rem; transition: border-color .2s, background .2s, box-shadow .2s; }
.fl textarea { resize: vertical; min-height: 140px; }
.fl label { position: absolute; left: 1rem; top: 1rem; color: var(--ink-2); font-size: 1rem; pointer-events: none; transition: transform .18s var(--ease), font-size .18s, color .18s, top .18s; transform-origin: left top; }
.fl input:focus, .fl textarea:focus { outline: none; border-color: var(--olive); background: #fff; box-shadow: 0 0 0 4px #e1e8cc; }
.fl input:focus + label, .fl input:not(:placeholder-shown) + label, .fl textarea:focus + label, .fl textarea:not(:placeholder-shown) + label { top: .45rem; font-size: .76rem; font-weight: 600; color: var(--olive); }
.fl.has-error input, .fl.has-error textarea { border-color: var(--red); background: #fff7f6; }
.fl.has-error label { color: #a3271f !important; }
.fl-err { margin: .35rem 0 0 .2rem; font-size: .85rem; color: #a3271f; }
.fl.is-ok input { border-color: #9cbf86; }
.fl-count { text-align: right; font-size: .78rem; color: var(--ink-2); margin: -.6rem 0 1rem; }
.enq-submit { width: 100%; min-height: 56px; font-size: 1.05rem; border-radius: 14px; position: relative; letter-spacing: .02em; }
.enq-spin { display: none; width: 20px; height: 20px; border: 2.5px solid rgba(255, 255, 255, .4); border-top-color: #fff; border-radius: 50%; animation: spin .8s linear infinite; }
.enq-submit.is-busy .enq-spin { display: inline-block; }
.enq-submit.is-busy .enq-submit-label { opacity: .8; }
@keyframes spin { to { transform: rotate(360deg); } }
.enq-privacy { font-size: .82rem; color: var(--ink-2); margin: 1rem 0 0; text-align: center; }
.enq-done { text-align: center; padding: 1.5rem 0 .5rem; }
.enq-tick { width: 84px; height: 84px; margin: 0 auto 1.2rem; display: block; }
.enq-tick circle { fill: #e6f1dd; stroke: var(--green); stroke-width: 2.5; }
.enq-tick path { fill: none; stroke: var(--green); stroke-width: 4; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 40; stroke-dashoffset: 40; animation: tick .6s .25s var(--ease) forwards; }
@keyframes tick { to { stroke-dashoffset: 0; } }
.enq-done h2 { font-size: clamp(1.8rem, 3vw, 2.4rem); }
.enq-done p { color: var(--ink-2); font-size: 1.05rem; }
.enq-ref { display: inline-block; background: var(--paper); border: 1px dashed var(--olive); border-radius: 12px; padding: .6rem 1.1rem; color: var(--ink) !important; }
.enq-ref strong { font-family: var(--serif); letter-spacing: .04em; }
.admit-closed { color: #dfe5d8; margin: -.6rem 0 1.2rem; max-width: 30em; }

/* ======================= v8: popup ======================= */
.promo { position: fixed; inset: 0; z-index: 95; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.promo[hidden] { display: none; }
.promo-backdrop { position: absolute; inset: 0; background: rgba(15, 22, 14, .62); backdrop-filter: blur(3px); opacity: 0; transition: opacity .3s; }
.promo-box { position: relative; display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); width: min(880px, 100%); max-height: calc(100vh - 2rem); overflow: auto; background: #fff; border-radius: 26px; box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .6); opacity: 0; transform: translateY(18px) scale(.98); transition: opacity .35s var(--ease), transform .35s var(--ease); }
.promo.is-open .promo-backdrop { opacity: 1; }
.promo.is-open .promo-box { opacity: 1; transform: none; }
.promo-noimg { grid-template-columns: minmax(0, 1fr); width: min(560px, 100%); }
.promo-img { position: relative; min-height: 420px; background: var(--forest); }
.promo-img img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.promo-body { padding: clamp(1.6rem, 4vw, 2.6rem); display: flex; flex-direction: column; justify-content: center; }
.promo-body .leaves { margin-bottom: 1rem; }
.promo-kicker { font-weight: 600; color: var(--olive); font-size: .92rem; margin-bottom: .4rem; }
.promo-body h2 { font-size: clamp(1.8rem, 3.4vw, 2.6rem); font-weight: 700; margin-bottom: .8rem; }
.promo-text { color: var(--ink-2); font-size: 1.04rem; }
.promo-body .actions { margin-top: 1.2rem; }
.promo-x { position: absolute; right: .8rem; top: .8rem; z-index: 2; width: 42px; height: 42px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .92); color: var(--ink); font-size: 1.6rem; line-height: 1; cursor: pointer; box-shadow: 0 6px 18px -8px rgba(0, 0, 0, .4); }
.promo-x:hover { background: #fff; }
.promo-later { align-self: flex-start; margin-top: 1rem; background: none; border: 0; color: var(--ink-2); text-decoration: underline; cursor: pointer; padding: .3rem 0; font-size: .9rem; }
body.promo-open { overflow: hidden; }

@media (max-width: 900px) {
  .enq { background: linear-gradient(180deg, var(--forest) 0 420px, var(--concrete) 420px); }
  .enq-grid { grid-template-columns: minmax(0, 1fr); grid-template-areas: "head" "card" "info"; gap: 1.4rem; }
  .enq-steps { margin: 1.4rem 0; }
}
@media (max-width: 640px) {
  .fl-row { grid-template-columns: minmax(0, 1fr); }
  .enq { background: linear-gradient(180deg, var(--forest) 0 400px, var(--concrete) 400px); }
  .promo { align-items: flex-end; padding: 0; }
  .promo-box { grid-template-columns: minmax(0, 1fr); border-radius: 24px 24px 0 0; max-height: 92vh; }
  .promo-img { aspect-ratio: 16 / 10; min-height: 0; }
  .enq-contact { display: grid; }
  .promo-body .leaves { display: none; }
  .promo-body .actions .btn { flex: 1 1 100%; }
}

/* ======================= logo prominence ======================= */
/* Desktop: the logo sits on a white plate that hangs over the page top, and folds back into the bar on scroll. */
.brand { flex: none; display: block; line-height: 0; border-radius: 0 0 22px 22px; transition: padding .3s var(--ease), margin .3s var(--ease), box-shadow .3s var(--ease), background .3s; }
.brand img { width: auto; height: 62px; transition: height .3s var(--ease); }
@media (min-width: 1101px) {
  .masthead-in { min-height: 88px; }
  .brand { position: relative; z-index: 3; align-self: flex-start; background: #fff; padding: 14px 24px 16px; margin: 0 0 -34px -24px; box-shadow: 0 22px 40px -26px rgba(18, 28, 17, .55); }
  .brand::after { content: ""; position: absolute; left: 24px; right: 24px; bottom: 7px; height: 3px; border-radius: 3px; background: linear-gradient(90deg, var(--red) 0 33.3%, var(--blue) 33.3% 66.6%, var(--green) 66.6%); transition: opacity .2s; }
  .brand img { height: 88px; }
  .masthead.is-stuck .masthead-in { min-height: 76px; }
  .masthead.is-stuck .brand { align-self: center; padding: 0; margin: 0; box-shadow: none; background: transparent; }
  .masthead.is-stuck .brand::after { opacity: 0; }
  .masthead.is-stuck .brand img { height: 56px; }
  .hero { padding-top: clamp(5rem, 10vh, 7rem); }
  .pagehead { padding-top: clamp(3.4rem, 6vw, 4.6rem); }
}
@media (min-width: 1101px) and (max-width: 1320px) {
  .brand img { height: 64px; }
  .brand { padding: 10px 14px 13px; margin-left: -14px; margin-bottom: -26px; }
  .brand::after { left: 14px; right: 14px; bottom: 5px; }
  .nav { gap: .5rem; }
  .nav-list > li > a, .sub-toggle { padding-inline: .42rem; font-size: .9rem; }
  .nav-tools .btn { padding-inline: 1rem; }
}
@media (max-width: 1100px) { .brand img { height: 56px; } }
@media (max-width: 640px) { .masthead-in { min-height: 74px; } .brand img { height: 50px; } }

/* Footer: the school logo on its own white plate above the Cambridge badge */
.footer-logo { display: inline-block; background: #fff; border-radius: 18px; padding: 14px 20px; margin-bottom: 1.4rem; line-height: 0; box-shadow: 0 16px 34px -24px rgba(0, 0, 0, .6); }
.footer-logo img { height: 72px; width: auto; }
.footer .badge { padding-top: 0; }
.footer .badge img { max-width: 230px; }
@media (min-width: 1101px) and (max-width: 1180px) {
  .brand img { height: 56px; }
  .nav-list > li > a, .sub-toggle { padding-inline: .34rem; font-size: .87rem; }
  .nav-tools .icon-btn { width: 36px; }
}

/* ======================= reading comfort for long text ======================= */
/* Headings break into even lines; paragraphs avoid single-word last lines. */
h1, h2, h3, h4, .st, .sec-head p { text-wrap: balance; }
p, li, blockquote, dd { text-wrap: pretty; }
/* Long passages are justified, with hyphenation so word gaps stay even. Narrow cards stay left-aligned. */
.prose, .prose-why, .prose-letter, .pcard-text, .hol p, .vm-text p, .lcard-text, .faq-a, .stage-text .prose,
.campus-text .prose, .ftab-text p, .dev-body p, .spotlight p, .mp p, .quote blockquote p, .voices-text > p:last-child,
.enq-lead, .leader-msg > p, .pagehead-intro {
  text-align: justify; text-justify: inter-word;
  -webkit-hyphens: auto; hyphens: auto; hyphenate-limit-chars: 7 3 3; overflow-wrap: break-word;
}
.prose { line-height: 1.75; }
.prose p { margin-bottom: 1.05em; }
.prose h2, .prose h3 { text-align: left; margin-top: 1.8em; margin-bottom: .55em; }
.prose ul, .prose ol { text-align: left; padding-left: 1.3em; }
.prose li::marker { color: var(--olive); }
.prose strong { color: var(--ink); font-weight: 650; }
/* leadership letters: greeting, quote and signature set apart from the body */
.prose-letter { max-width: 42rem; }
.prose-letter p:first-child { text-align: left; font-family: var(--serif); font-weight: 500; font-size: 1.15rem; color: var(--ink); padding-bottom: 1rem; border-bottom: 1px solid var(--line); margin-bottom: 1.4rem; }
.prose-letter blockquote { text-align: left; background: var(--paper); border-left: 4px solid var(--green); border-radius: 0 var(--r) var(--r) 0; padding: 1rem 1.3rem; }
.prose-letter p:has(> strong:only-child) { text-align: left; }
.prose-letter p:last-of-type:has(strong) { margin-top: 1.6rem; }
/* centred intros stay centred */
.sec-head.center p, .enq-done p { text-align: center; }
/* FAQ answers read better a little narrower */
.faq-a { max-width: 64ch; line-height: 1.7; }
@media (max-width: 560px) {
  .prose, .prose-why, .prose-letter, .pcard-text, .hol p, .vm-text p, .lcard-text, .faq-a, .stage-text .prose,
  .campus-text .prose, .ftab-text p, .dev-body p, .spotlight p, .mp p, .quote blockquote p, .voices-text > p:last-child,
  .enq-lead, .leader-msg > p, .pagehead-intro { text-align: left; -webkit-hyphens: manual; hyphens: manual; }
}
/* large lead lines stay left-aligned: justifying big type opens wide gaps */
.prose-why p:first-child, .pagehead-intro, .enq-lead, .vm-text p, .leader-greet { text-align: left; -webkit-hyphens: manual; hyphens: manual; }

/* ======================= careers page (embedded application form) ======================= */
.sec-jobs { background: var(--concrete); padding-top: clamp(2.4rem, 5vw, 3.6rem); }
.job-steps { list-style: none; margin: 0 0 1.6rem; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .8rem; }
.job-steps li { display: flex; gap: .8rem; align-items: flex-start; background: #fff; border-radius: var(--r); padding: 1rem 1.1rem; font-size: .9rem; color: var(--ink-2); }
.job-steps span { flex: none; display: grid; place-items: center; width: 32px; height: 32px; border-radius: 50%; background: var(--olive); color: #fff; font-weight: 700; font-family: var(--serif); }
.job-steps li:nth-child(1) span { background: var(--red); } .job-steps li:nth-child(2) span { background: var(--blue); } .job-steps li:nth-child(3) span { background: var(--green); }
.job-steps strong { display: block; color: var(--ink); font-family: var(--serif); font-weight: 600; font-size: 1.02rem; }
.job-card { background: #fff; border-radius: 26px; box-shadow: 0 40px 80px -46px rgba(18, 28, 17, .5); overflow: hidden; position: relative; }
.job-card::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: 5px; background: linear-gradient(90deg, var(--red) 0 33.3%, var(--blue) 33.3% 66.6%, var(--green) 66.6%); }
.job-bar { display: flex; flex-wrap: wrap; gap: .6rem 1rem; justify-content: space-between; align-items: center; padding: 1.3rem clamp(1.2rem, 3vw, 2rem) 1rem; border-bottom: 1px solid var(--line); }
.job-bar h2 { margin: 0; font-size: 1.35rem; }
.job-bar a { display: inline-flex; align-items: center; gap: .4rem; font-weight: 600; font-size: .9rem; text-decoration: none; }
.job-bar a .icon { width: 15px; height: 15px; transform: rotate(-45deg); }
.job-frame { position: relative; min-height: 600px; }
.job-frame iframe { display: block; width: 100%; height: 1400px; border: 0; background: transparent; opacity: 0; transition: opacity .35s; }
.job-card.is-ready iframe { opacity: 1; }
.job-loading { position: absolute; left: 0; right: 0; top: 4rem; display: flex; justify-content: center; align-items: center; gap: .7rem; color: var(--ink-2); margin: 0; }
.job-loading .enq-spin { display: inline-block; border-color: var(--line); border-top-color: var(--olive); }
.job-card.is-ready .job-loading { display: none; }
.job-help { text-align: center; color: var(--ink-2); font-size: .95rem; margin: 1.4rem 0 0; }
@media (max-width: 900px) { .job-steps { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .job-steps { grid-template-columns: minmax(0, 1fr); } .job-steps li { padding: .8rem .9rem; } }
.job-fallback { display: none; text-align: center; padding: 4rem 1.5rem; }
.job-fallback p { color: var(--ink-2); }
.job-card.is-blocked .job-fallback { display: block; }
.job-card.is-blocked iframe, .job-card.is-blocked .job-loading { display: none; }
.job-card.is-blocked .job-frame { min-height: 0; }

/* ======================= v7: Gallery & Events ======================= */
/* justified photo rows: each photo keeps its own shape, every row fills the width */
.jgrid { display: flex; flex-wrap: wrap; gap: 8px; }
.jgrid::after { content: ""; flex-grow: 999999; }
.jg { position: relative; display: block; flex: var(--r) 1 calc(var(--r) * 230px); aspect-ratio: var(--r); max-height: 440px; overflow: hidden; border-radius: 10px; background-size: cover; background-position: center; cursor: zoom-in; }
.jg img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .5s ease, transform .6s var(--ease); }
.jg.is-loaded img { opacity: 1; }
.jg:hover img { transform: scale(1.035); }
.jg::after { content: ""; position: absolute; inset: 0; background: linear-gradient(0deg, rgba(0, 0, 0, .25), transparent 40%); opacity: 0; transition: opacity .25s; }
.jg:hover::after, .jg:focus-visible::after { opacity: 1; }
@media (max-width: 640px) { .jg { flex-basis: calc(var(--r) * 105px); max-height: 260px; } .jgrid { gap: 5px; } }
@media (prefers-reduced-motion: reduce) { .jg img { opacity: 1; } }

/* event page */
.ev-head { background: var(--concrete); padding: clamp(2rem, 4vw, 3rem) 0 1.6rem; }
.ev-titlebar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: 1.2rem 2rem; }
.ev-titlebar h1 { font-size: clamp(2rem, 4.4vw, 3.4rem); margin-bottom: .6rem; max-width: 18em; }
.event-meta .icon { width: 16px; height: 16px; margin-right: .3rem; vertical-align: -2px; color: var(--olive); }
.event-meta > * { display: inline-flex; align-items: center; }
.event-meta > * + *::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: var(--line); margin-right: 1.1rem; }
.ev-tools { display: flex; flex-wrap: wrap; gap: .5rem; align-items: center; }
.ev-tools .btn .icon { width: 18px; height: 18px; }
.share { position: relative; }
.share-menu { position: absolute; right: 0; top: calc(100% + 8px); z-index: 20; min-width: 210px; background: #fff; border: 1px solid var(--line); border-radius: var(--r); box-shadow: var(--shadow); padding: .4rem; }
.share-menu a, .share-menu button { display: flex; align-items: center; gap: .7rem; width: 100%; padding: .65rem .8rem; border: 0; background: none; border-radius: var(--r-sm); color: var(--ink); text-decoration: none; font: inherit; cursor: pointer; text-align: left; }
.share-menu a:hover, .share-menu button:hover { background: var(--paper); }
.share-menu .icon { width: 20px; height: 20px; color: var(--olive); }
.mosaic { display: grid; grid-template-columns: 2fr 1fr 1fr; grid-template-rows: 1fr 1fr; gap: 8px; aspect-ratio: 21 / 9; border-radius: var(--r-lg); overflow: hidden; margin-top: 1.4rem; }
.mosaic button { position: relative; border: 0; padding: 0; cursor: zoom-in; overflow: hidden; }
.mosaic img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .7s var(--ease), filter .3s; }
.mosaic button:hover img { transform: scale(1.04); filter: brightness(1.05); }
.mosaic-0 { grid-row: 1 / 3; }
.mosaic-more { position: absolute; inset: 0; display: grid; place-items: center; background: rgba(18, 28, 17, .55); color: #fff; font: 600 1.25rem var(--serif); }
.ev-story { margin-bottom: 2.4rem; }
.ev-lead { font-size: 1.15rem; }
.ev-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; padding-bottom: var(--sec); }
.ev-nav a { display: block; background: #fff; border: 1px solid var(--line); border-radius: var(--r); padding: 1rem 1.3rem; text-decoration: none; color: var(--ink); transition: border-color .2s, transform .2s; }
.ev-nav a:hover { border-color: var(--olive); transform: translateY(-2px); }
.ev-nav small { display: block; color: var(--ink-2); font-size: .82rem; }
.ev-nav strong { font-family: var(--serif); font-weight: 600; }
.ev-nav-next { text-align: right; grid-column: 2; }
@media (max-width: 760px) {
  .mosaic { grid-template-columns: 1fr 1fr; grid-template-rows: 2fr 1fr; aspect-ratio: 4 / 3.4; }
  .mosaic-0 { grid-column: 1 / 3; grid-row: 1; }
  .mosaic-3, .mosaic-4 { display: none; }
  .mosaic-2 .mosaic-more { display: grid; }
  .ev-nav { grid-template-columns: 1fr; } .ev-nav-next { grid-column: auto; text-align: left; }
}

/* listing: search, years, category chips, months */
.evbar { position: sticky; top: 76px; z-index: 15; background: rgba(247, 246, 242, .94); backdrop-filter: blur(8px); border-bottom: 1px solid var(--line); }
.evbar-in { display: flex; flex-wrap: wrap; gap: .8rem 1.2rem; align-items: center; padding-block: .8rem; }
.evsearch { display: flex; gap: .5rem; flex: 1 1 380px; }
.evsearch input, .evsearch select { padding: .65rem .9rem; border: 1.5px solid var(--line); border-radius: 999px; font: inherit; background: #fff; }
.evsearch input { flex: 1; min-width: 0; }
.evsearch input:focus, .evsearch select:focus { outline: none; border-color: var(--olive); box-shadow: 0 0 0 4px #e1e8cc; }
.evsearch .btn { min-height: 44px; }
.evchips { display: flex; gap: .4rem; overflow-x: auto; scrollbar-width: none; flex: 1 1 100%; padding-bottom: 2px; }
.evchips::-webkit-scrollbar { display: none; }
.evchips a { flex: none; padding: .45rem .9rem; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink); text-decoration: none; font-size: .9rem; font-weight: 500; }
.evchips a span { color: var(--ink-2); font-size: .8rem; margin-left: .15rem; }
.evchips a[aria-current] { background: var(--olive); border-color: var(--olive); color: #fff; }
.evchips a[aria-current] span { color: #dfe7c9; }
.evresult { color: var(--ink-2); margin-bottom: 1.4rem; }
.evmonth + .evmonth { margin-top: clamp(2.4rem, 5vw, 3.4rem); }
.evmonth-h { display: flex; align-items: baseline; gap: .8rem; font-size: clamp(1.4rem, 2.4vw, 1.9rem); margin-bottom: 1.2rem; }
.evmonth-h::after { content: ""; flex: 1; height: 1px; background: var(--line); align-self: center; }
.evmonth-h small { font: 500 .9rem var(--sans); color: var(--ink-2); order: 2; }
@media (max-width: 640px) { .evbar { top: 74px; } .evsearch { flex-wrap: wrap; } .evsearch input { flex-basis: 100%; } }

/* lightbox v2 */
.lightbox { display: grid; grid-template-rows: auto 1fr auto; background: rgba(10, 14, 10, .97); }
.lightbox[hidden] { display: none; }
.lb-top { display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .7rem 1rem; color: #dfe5d8; z-index: 2; }
.lightbox .lb-count { position: static; transform: none; margin: 0; color: #c9d1c2; font-size: .9rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lb-tools { display: flex; gap: .3rem; }
.lightbox .lb-btn { position: static; display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; border: 0; background: rgba(255, 255, 255, .08); color: #fff; cursor: pointer; transform: none; font-size: 1rem; }
.lightbox .lb-btn:hover { background: rgba(255, 255, 255, .2); }
.lb-btn svg { width: 22px; height: 22px; }
.lb-btn .i-pause { display: none; } .is-playing .lb-btn .i-pause { display: block; } .is-playing .lb-btn .i-play { display: none; }
.lb-stage { position: relative; overflow: hidden; display: flex; align-items: center; justify-content: center; touch-action: none; min-height: 0; }
.lb-img { max-width: 94vw; max-height: 100%; width: auto; height: auto; object-fit: contain; border-radius: 4px; transition: transform .25s var(--ease), opacity .25s; user-select: none; -webkit-user-drag: none; cursor: zoom-in; }
.is-zoomed .lb-img { cursor: grab; transition: none; }
.is-loading .lb-img { opacity: .35; }
.lightbox .lb-prev, .lightbox .lb-next { top: 50%; z-index: 3; width: 54px; height: 54px; background: rgba(255, 255, 255, .1); font-size: 2rem; }
.is-zoomed .lb-prev, .is-zoomed .lb-next { opacity: 0; pointer-events: none; }
.lb-bottom { padding: .4rem 0 .9rem; z-index: 2; }
.lb-cap { text-align: center; color: #e8ece2; margin: 0 1rem .6rem; min-height: 1.2em; font-size: .95rem; }
.lb-strip { display: flex; gap: 6px; overflow-x: auto; padding: 2px 1rem; scrollbar-width: none; justify-content: safe center; }
.lb-strip::-webkit-scrollbar { display: none; }
.lb-strip button { flex: none; width: 64px; height: 48px; border-radius: 6px; border: 2px solid transparent; background: #333 center / cover; opacity: .5; cursor: pointer; padding: 0; transition: opacity .2s, border-color .2s; }
.lb-strip button.is-on { opacity: 1; border-color: #fff; }
.lb-strip button:hover { opacity: .85; }
.lb-toast { position: absolute; left: 50%; bottom: 7rem; transform: translateX(-50%); background: #fff; color: var(--ink); padding: .5rem 1rem; border-radius: 999px; font-size: .9rem; margin: 0; }
.lightbox:fullscreen .lb-strip, .lightbox:fullscreen .lb-top { opacity: 0; transition: opacity .3s; }
.lightbox:fullscreen:hover .lb-strip, .lightbox:fullscreen:hover .lb-top { opacity: 1; }
@media (max-width: 640px) {
  .lightbox .lb-prev, .lightbox .lb-next { display: none; }
  .lb-tools [data-lb=fs] { display: none; }
  .lb-strip button { width: 52px; height: 40px; }
}

/* reception TV (/screen) */
body.tv { margin: 0; background: #0b0f0a; overflow: hidden; cursor: none; height: 100vh; }
.tv-stage, .tv-slide { position: fixed; inset: 0; }
.tv-slide { background: center / cover no-repeat; opacity: 0; transition: opacity 1.6s ease; }
.tv-slide.is-on { opacity: 1; }
.kb-a { animation: kbA 9s linear forwards; } .kb-b { animation: kbB 9s linear forwards; }
@keyframes kbA { from { transform: scale(1.02) translate(0, 0); } to { transform: scale(1.12) translate(-2%, -1.5%); } }
@keyframes kbB { from { transform: scale(1.12) translate(2%, 1%); } to { transform: scale(1.02) translate(0, 0); } }
.tv-cap { position: fixed; left: 0; right: 0; bottom: 0; padding: 4rem 4vw 2.4rem; background: linear-gradient(0deg, rgba(0, 0, 0, .7), transparent); color: #fff; display: flex; flex-direction: column; gap: .3rem; }
.tv-cap strong { font: 700 clamp(1.6rem, 3vw, 3rem) var(--serif); }
.tv-cap span { font-size: clamp(1rem, 1.4vw, 1.4rem); color: #dfe5d8; }
.tv-logo { position: fixed; right: 3vw; top: 3vh; height: clamp(50px, 8vh, 90px); background: #fff; padding: 10px 16px; border-radius: 16px; }
.tv-fs { position: fixed; left: 3vw; top: 3vh; cursor: pointer; border: 0; border-radius: 999px; padding: .6rem 1.1rem; background: rgba(255, 255, 255, .85); font-weight: 600; }
.tv-empty { color: #fff; text-align: center; margin-top: 40vh; font-size: 1.4rem; }
@media (prefers-reduced-motion: reduce) { .kb-a, .kb-b { animation: none; } }
