/* XAG — homepage styles. Self-contained: no external fonts, no external requests. */

:root {
  --bg: #060b1c;
  --bg-2: #0a1230;
  --ink: #f2f6ff;
  --ink-2: rgba(242, 246, 255, 0.70);
  --ink-3: rgba(242, 246, 255, 0.54);
  --line: rgba(242, 246, 255, 0.10);
  --royal: #0a2a6b;
  --blue: #1356d6;
  --sky: #1aa3ff;
  --ice: #7fd0ff;
  --gold: #ffb000;
  --orange: #ff8a00;
  --font-display: "Segoe UI Variable Display", "Segoe UI", -apple-system, BlinkMacSystemFont, "SF Pro Display", "Helvetica Neue", Inter, Roboto, Arial, sans-serif;
  --font-text: "Segoe UI Variable Text", "Segoe UI", -apple-system, BlinkMacSystemFont, "SF Pro Text", "Helvetica Neue", Inter, Roboto, Arial, sans-serif;
  --gutter: clamp(1.25rem, 6vw, 7rem);
  --max: 1320px;
  --nav-h: 76px;
  --lang-h: 36px;
  --strip-h: 0px;                                  /* height of the announcement strip (html.has-strip) */
  --top-h: calc(var(--strip-h) + var(--lang-h));   /* everything above the top bar */
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
  --sy: 0;
  --mx: 0;
  --my: 0;
  --p: 0;
}

/* ------------------------------------------------------------------ base */
*, *::before, *::after { box-sizing: border-box; }

html {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-text);
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  overflow-x: clip;
}
html.motion:not(.intro-done) { overflow: hidden; }

body {
  margin: 0;
  min-height: 100vh;
  line-height: 1.5;
  font-size: 1rem;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
h1, h2, h3, p, ul { margin: 0; }
ul { padding: 0; list-style: none; }

:focus-visible { outline: 2px solid var(--gold); outline-offset: 4px; border-radius: 2px; }

.sr {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}

.skip {
  position: fixed; top: 0.75rem; left: 0.75rem; z-index: 200;
  padding: 0.6rem 1rem; background: var(--gold); color: #140b00; font-weight: 600;
  transform: translateY(-200%); transition: transform 0.2s;
}
.skip:focus { transform: none; }

::selection { background: rgba(255, 176, 0, 0.35); color: var(--ink); }

/* ------------------------------------------------------------------ intro overlay */
.intro {
  position: fixed; inset: 0; z-index: 100;
  background: var(--bg);
  display: none;
}
html.motion:not(.intro-done) .intro { display: block; }
html.motion .intro.out { display: block; opacity: 0; transition: opacity 1s ease 0.05s; pointer-events: none; }
.intro canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.intro-skip {
  position: absolute; right: var(--gutter); bottom: 1.6rem;
  background: none; border: 1px solid var(--line); color: var(--ink-2);
  font-size: 0.66rem; letter-spacing: 0.26em; text-transform: uppercase;
  padding: 0.75rem 1.2rem; cursor: pointer;
  opacity: 0; animation: fade-in 0.8s ease 1.1s forwards;
  transition: color 0.3s, border-color 0.3s;
}
.intro-skip:hover, .intro-skip:focus-visible { color: var(--ink); border-color: var(--gold); }
@keyframes fade-in { to { opacity: 1; } }

/* ------------------------------------------------------------------ top bar */
.top {
  position: fixed; inset: var(--top-h) 0 auto 0; z-index: 80;
  height: var(--nav-h);
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 var(--gutter);
  transition: background 0.5s, box-shadow 0.5s, opacity 1s var(--ease) 0.2s, transform 1s var(--ease) 0.2s;
}
.top.scrolled {
  background: rgba(6, 11, 28, 0.66);
  -webkit-backdrop-filter: blur(16px) saturate(140%);
  backdrop-filter: blur(16px) saturate(140%);
  box-shadow: 0 1px 0 var(--line);
}
html.lite .top.scrolled { background: var(--bg); -webkit-backdrop-filter: none; backdrop-filter: none; }
html.motion:not(.intro-done) .top { opacity: 0; transform: translateY(-12px); }

.brand-lockup { display: flex; align-items: center; gap: 0.9rem; }
.brand { display: inline-flex; align-items: center; }
.brand img { height: 38px; width: auto; }
.top-seal { display: inline-block; line-height: 0; color: var(--gold); }
.top-seal .seal { width: 48px; height: 48px; filter: drop-shadow(0 0 6px rgba(255, 176, 0, 0.45)); }
html.lite .top-seal .seal { filter: none; }

.nav { margin-inline: auto; }
.nav ul { display: flex; gap: 2.4rem; }
.nav a {
  display: inline-block; position: relative; padding: 0.45rem 0;
  font-size: 0.72rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--ink-2); transition: color 0.3s;
}
.nav a::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: var(--gold); transform: scaleX(0); transform-origin: right;
  transition: transform 0.55s var(--ease);
}
.nav a:hover, .nav a:focus-visible, .nav a[aria-current] { color: var(--ink); }
.nav a:hover::after, .nav a[aria-current]::after { transform: none; transform-origin: left; }

.menu-btn {
  display: none; align-items: center; gap: 0.7rem; margin-left: 1.4rem;
  background: none; border: 0; padding: 0.6rem 0; cursor: pointer;
  font-size: 0.72rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--ink);
}
.menu-btn-bars { display: block; width: 22px; height: 1px; background: currentColor; position: relative; }
.menu-btn-bars::before, .menu-btn-bars::after {
  content: ""; position: absolute; left: 0; width: 100%; height: 1px; background: currentColor;
}
.menu-btn-bars::before { top: -6px; }
.menu-btn-bars::after { top: 6px; width: 60%; }

/* full-screen menu (small screens) */
.menu {
  position: fixed; inset: var(--top-h) 0 0 0; z-index: 90;
  background: var(--bg);
  display: flex; flex-direction: column;          /* scrolls when the Education list is open on a short screen; the list is centred when it fits */
  overflow-y: auto; overscroll-behavior: contain;
  padding: var(--gutter);
  visibility: hidden; opacity: 0;
  clip-path: circle(0 at calc(100% - 3rem) 2.4rem);
  transition: clip-path 0.9s var(--ease), opacity 0.4s, visibility 0s 0.9s;
}
.menu.open {
  visibility: visible; opacity: 1;
  clip-path: circle(170% at calc(100% - 3rem) 2.4rem);
  transition: clip-path 0.9s var(--ease), opacity 0.2s, visibility 0s;
}
html:not(.motion) .menu { transition: none; clip-path: none; }
.menu nav { margin-block: auto; }
.menu ul { display: grid; gap: 0.3rem; }
.menu a, .menu-edu-btn {
  display: flex; gap: 1rem; align-items: baseline;
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(2rem, 9vw, 3.4rem); letter-spacing: -0.02em; line-height: 1.2;
  padding: 0.3rem 0;
}
.menu a small, .menu-edu-btn small { font-size: 0.68rem; letter-spacing: 0.3em; color: var(--gold); min-width: 2.2em; }
.menu-close {
  position: fixed; top: calc(var(--top-h) + (var(--nav-h) - 2.4rem) / 2); right: var(--gutter);
  background: var(--bg); border: 1px solid var(--line); color: var(--ink);
  font-size: 0.72rem; letter-spacing: 0.22em; text-transform: uppercase; padding: 0.7rem 1.1rem; cursor: pointer;
}

/* ------------------------------------------------------------------ chapters */
.chapter {
  position: relative; isolation: isolate;
  min-height: 100vh; min-height: 100svh;
  display: grid; align-content: center;
  padding: clamp(5rem, 14vh, 10rem) var(--gutter);
  overflow: clip;
  scroll-margin-top: var(--top-h);
}
.wrap {
  max-width: var(--max); width: 100%; margin-inline: auto;
  display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); column-gap: 1.5rem;
}
.wrap > * { grid-column: 1 / -1; min-width: 0; }
@media (min-width: 900px) {
  .wrap > .kinetic { grid-column: 1 / 11; }
  .wrap > .lede { grid-column: 4 / 10; }
  .wrap > .soon { grid-column: 4 / 10; }
}

/* one key light behind the whole page: six pre-lit positions, cross-faded by opacity only
   (compositor work, no repaints), with the vignette folded into the same layer */
.keylight { position: fixed; inset: 0; z-index: -1; pointer-events: none; }
.keylight i {
  position: absolute; inset: 0; display: block; opacity: 0;
  transition: opacity 2.2s ease;
  background-image:
    radial-gradient(closest-side, rgba(19, 86, 214, 0.36), rgba(19, 86, 214, 0)),
    radial-gradient(closest-side, rgba(255, 138, 0, 0.16), rgba(255, 138, 0, 0)),
    radial-gradient(120% 90% at 50% 45%, rgba(2, 4, 12, 0) 55%, rgba(2, 4, 12, 0.64) 100%);
  background-repeat: no-repeat;
  background-size: 120vmax 120vmax, 64vmax 64vmax, 100% 100%;
  background-position: var(--kb), var(--kg), 0 0;
}
.keylight i[data-k="home"] { --kb: 50% 22%; --kg: 78% 62%; opacity: 1; }
.keylight i[data-k="families"] { --kb: 2% 78%; --kg: 112% 12%; }
.keylight i[data-k="software"] { --kb: 104% 10%; --kg: -14% 96%; }
.keylight i[data-k="education"] { --kb: -8% 24%; --kg: 108% 78%; }
.keylight i[data-k="about"] { --kb: 96% 84%; --kg: -16% -10%; }
.keylight i[data-k="contact"] { --kb: -6% -4%; --kg: 56% 58%; }
html[data-chapter] .keylight i[data-k="home"] { opacity: 0; }
html[data-chapter="home"] .keylight i[data-k="home"],
html[data-chapter="families"] .keylight i[data-k="families"],
html[data-chapter="software"] .keylight i[data-k="software"],
html[data-chapter="education"] .keylight i[data-k="education"],
html[data-chapter="about"] .keylight i[data-k="about"],
html[data-chapter="contact"] .keylight i[data-k="contact"] { opacity: 1; }

/* the "cut": a hairline of gold that draws itself where one chapter becomes the next */
.chapter::after {
  content: ""; position: absolute; top: 0; left: var(--gutter); right: var(--gutter); height: 1px;
  background: linear-gradient(90deg, rgba(255, 176, 0, 0.9), rgba(255, 176, 0, 0.14) 55%, transparent);
  transform: scaleX(0); transform-origin: left; transition: transform 1.4s var(--ease);
}
html:not(.motion) .chapter::after, .chapter.in::after { transform: none; }
.hero::after { display: none; }

.chapter-num {
  position: absolute; right: calc(var(--gutter) * 0.5); top: 50%; z-index: -1;
  font-family: var(--font-display); font-weight: 600; line-height: 1;
  font-size: clamp(11rem, 32vw, 30rem);
  color: transparent; -webkit-text-stroke: 1px rgba(242, 246, 255, 0.07);
  transform: translateY(-50%);
  pointer-events: none; user-select: none;
}

.chapter-mark {
  display: flex; align-items: center; gap: 1rem;
  font-size: 0.68rem; letter-spacing: 0.34em; text-transform: uppercase; color: var(--gold);
  margin-bottom: 2.2rem;
}
.chapter-mark::before {
  content: ""; width: 3rem; height: 1px; background: var(--gold);
  transform-origin: left; transition: transform 1s var(--ease) 0.1s;
}
html.motion .chapter-mark::before { transform: scaleX(0); }
html.motion .in .chapter-mark::before { transform: none; }

.kinetic {
  font-family: var(--font-display); font-weight: 300;
  font-size: clamp(1.9rem, 0.6rem + 7vw, 6.6rem);
  line-height: 1.02; letter-spacing: -0.022em;
  margin-bottom: 1.8rem;
}
.kinetic em { font-style: normal; font-weight: 600; color: var(--gold); }

.line { display: block; overflow: hidden; padding-block: 0.08em; margin-block: -0.08em; white-space: nowrap; }
@media (max-width: 360px) { .line { white-space: normal; } }
.line-in { display: block; }
html.motion .line-in {
  transform: translateY(112%) rotate(0.5deg); transform-origin: left top;
  transition: transform 1.2s var(--ease);
}
html.motion .line:nth-child(2) .line-in { transition-delay: 0.12s; }
html.motion .line:nth-child(3) .line-in { transition-delay: 0.24s; }
html.motion .in .line-in { transform: none; }
html.motion .kinetic { letter-spacing: 0.08em; transition: letter-spacing 1.9s var(--ease); }
html.motion .in .kinetic { letter-spacing: -0.022em; }

.lede {
  font-weight: 300; font-size: clamp(1.05rem, 0.95rem + 0.5vw, 1.3rem);
  color: var(--ink-2); max-width: 44ch; margin-bottom: 3.5rem; line-height: 1.55;
}

html.motion .reveal {
  opacity: 0; transform: translateY(26px);
  transition: opacity 1.1s var(--ease), transform 1.1s var(--ease);
  transition-delay: var(--d, 0.25s);
}
html.motion .in .reveal { opacity: 1; transform: none; }

/* ------------------------------------------------------------------ hero */
.hero {
  place-items: center; text-align: center;
  gap: clamp(1.2rem, 3vh, 2.2rem);
  padding-top: calc(var(--nav-h) + var(--top-h) + 2vh);
  padding-bottom: 7.5rem;
}

.hero-visual { position: relative; width: min(78vw, 1000px, calc((100vh - 38rem) * 2.37)); min-width: min(92vw, 420px); }
.logo-stage {
  position: relative;
  transform: translate3d(calc(var(--mx) * 10px), calc(var(--sy) * -0.22px + var(--my) * 8px), 0);
  will-change: transform;
}
.hero-logo { width: 100%; aspect-ratio: 1600 / 674; position: relative; z-index: 1; }

/* ---- signature light: a studio light passing over the polished logo ---- */
/* breathing glow behind the logo */
.hero-glow {
  position: absolute; left: 50%; top: 50%; width: 118%; aspect-ratio: 1.7; pointer-events: none;
  transform: translate(-50%, -50%) scale(0.98);
  background: radial-gradient(ellipse at 50% 50%, rgba(26, 110, 255, 0.34), rgba(255, 150, 0, 0.09) 42%, rgba(6, 11, 28, 0) 70%);
  opacity: 0.7;
}
html.motion .hero-glow { animation: breathe 7.5s ease-in-out infinite; }
@keyframes breathe {
  0%, 100% { transform: translate(-50%, -50%) scale(0.95); opacity: 0.55; }
  50% { transform: translate(-50%, -50%) scale(1.06); opacity: 0.9; }
}

/* the light itself: an overlay masked to the logo's own alpha (mask set by site.js from the image the
   browser loaded, so nothing extra is downloaded); blends like light on metal */
.logo-light {
  position: absolute; inset: 0; z-index: 2; pointer-events: none; visibility: hidden;
  -webkit-mask-size: 100% 100%; mask-size: 100% 100%;
  -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
  mix-blend-mode: screen;
}
.logo-light.ready { visibility: visible; }
.sheen {
  position: absolute; inset: -35%; display: none;
  background: radial-gradient(circle at 50% 50%, rgba(255, 255, 255, 0.20), rgba(150, 200, 255, 0.10) 28%, rgba(6, 11, 28, 0) 58%);
  transform: translate3d(calc(var(--mx) * 24%), calc(var(--my) * 24%), 0);
}
html.fine .sheen { display: block; }
.sweep-band {
  position: absolute; top: -30%; bottom: -30%; left: 0; width: 100%;
  transform: translate3d(-80%, 0, 0); will-change: transform;
  background: linear-gradient(104deg,
    rgba(6, 11, 28, 0) 38%,
    rgba(90, 160, 255, 0.22) 45%,
    rgba(205, 226, 255, 0.52) 49%,
    rgba(255, 248, 226, 0.76) 50.4%,
    rgba(255, 226, 150, 0.62) 51.8%,
    rgba(255, 176, 0, 0.22) 55%,
    rgba(90, 160, 255, 0.16) 59%,
    rgba(6, 11, 28, 0) 64%);
}
.logo-stage.sweeping .sweep-band { animation: sweep 2.2s cubic-bezier(0.45, 0, 0.2, 1) both; }
@keyframes sweep { from { transform: translate3d(-72%, 0, 0); } to { transform: translate3d(72%, 0, 0); } }

/* lens flare riding the leading edge of the sweep */
.flare-rig {
  position: absolute; left: 0; top: 50%; width: 100%; height: 0; z-index: 3; pointer-events: none;
  opacity: 0; transform: translate3d(-80%, 0, 0); will-change: transform, opacity;
  mix-blend-mode: screen;
}
.logo-stage.sweeping .flare-rig { animation: sweep 2.2s cubic-bezier(0.45, 0, 0.2, 1) both, flare-fade 2.2s linear both; }
@keyframes flare-fade { 0% { opacity: 0; } 14% { opacity: 1; } 84% { opacity: 1; } 100% { opacity: 0; } }
.flare-rig > span { position: absolute; left: 51%; top: 0; transform: translate(-50%, -50%); }
.fl-streak {
  width: 128%; height: 2px;
  background: linear-gradient(90deg, rgba(90, 160, 255, 0) 0%, rgba(120, 180, 255, 0.45) 28%, rgba(235, 243, 255, 0.95) 50%, rgba(120, 180, 255, 0.45) 72%, rgba(90, 160, 255, 0) 100%);
}
.fl-streak::before, .fl-streak::after {
  content: ""; position: absolute; left: 0; right: 0; height: 6px; top: -2px;
  background: linear-gradient(90deg, rgba(90, 160, 255, 0) 0%, rgba(120, 180, 255, 0.22) 30%, rgba(190, 215, 255, 0.4) 50%, rgba(120, 180, 255, 0.22) 70%, rgba(90, 160, 255, 0) 100%);
}
.fl-streak::before { top: -3px; background: linear-gradient(90deg, rgba(255, 80, 120, 0) 0%, rgba(255, 110, 140, 0.16) 35%, rgba(255, 160, 170, 0.22) 50%, rgba(255, 110, 140, 0.16) 65%, rgba(255, 80, 120, 0) 100%); }
.fl-streak::after { top: -1px; background: linear-gradient(90deg, rgba(60, 140, 255, 0) 0%, rgba(80, 150, 255, 0.18) 35%, rgba(120, 190, 255, 0.26) 50%, rgba(80, 150, 255, 0.18) 65%, rgba(60, 140, 255, 0) 100%); }
.fl-core {
  width: 30%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 246, 220, 0.75) 0%, rgba(255, 200, 90, 0.42) 12%, rgba(255, 150, 0, 0.16) 30%, rgba(26, 110, 255, 0.10) 48%, rgba(6, 11, 28, 0) 66%);
}
.fl-ghost { border-radius: 50%; }
.fl-g1 {
  left: 36%; width: 7%; aspect-ratio: 1;
  background: radial-gradient(circle, rgba(255, 200, 120, 0) 0 42%, rgba(255, 200, 120, 0.26) 50%, rgba(255, 120, 200, 0.16) 56%, rgba(120, 220, 255, 0.20) 62%, rgba(6, 11, 28, 0) 68%);
}
.fl-g2 {
  left: 24%; width: 4.5%; aspect-ratio: 1; border-radius: 0;
  background: radial-gradient(circle, rgba(140, 200, 255, 0.26), rgba(140, 200, 255, 0.08) 55%, rgba(6, 11, 28, 0) 72%);
  clip-path: polygon(25% 3%, 75% 3%, 100% 50%, 75% 97%, 25% 97%, 0 50%);
}
.fl-g3 {
  left: 10%; width: 11%; aspect-ratio: 1;
  background: radial-gradient(circle, rgba(255, 176, 0, 0) 0 50%, rgba(255, 176, 0, 0.12) 58%, rgba(255, 120, 200, 0.07) 64%, rgba(120, 220, 255, 0.10) 70%, rgba(6, 11, 28, 0) 76%);
}

/* smaller echo of the same light over the top-bar logo and the gold seals */
.mini-light {
  position: absolute; inset: 0; pointer-events: none; mix-blend-mode: screen;
  -webkit-mask-size: 100% 100%; mask-size: 100% 100%; -webkit-mask-repeat: no-repeat; mask-repeat: no-repeat;
}
.mini-light.logo { -webkit-mask-image: url("../assets/xag-logo-nav.d65aa085.webp"); mask-image: url("../assets/xag-logo-nav.d65aa085.webp"); }
.mini-light.ring {
  -webkit-mask-image: radial-gradient(circle closest-side, rgba(0, 0, 0, 0) 0 82%, #000 84% 87%, rgba(0, 0, 0, 0) 89% 93%, #000 94.5% 97%, rgba(0, 0, 0, 0) 98%);
  mask-image: radial-gradient(circle closest-side, rgba(0, 0, 0, 0) 0 82%, #000 84% 87%, rgba(0, 0, 0, 0) 89% 93%, #000 94.5% 97%, rgba(0, 0, 0, 0) 98%);
}
.mini-light i {
  position: absolute; top: -20%; bottom: -20%; left: 0; width: 100%; display: block;
  transform: translate3d(-110%, 0, 0);
  background: linear-gradient(104deg, rgba(6, 11, 28, 0) 24%, rgba(120, 180, 255, 0.4) 38%, rgba(255, 250, 232, 0.95) 47%, rgba(255, 250, 232, 0.95) 52%, rgba(255, 228, 150, 0.75) 60%, rgba(6, 11, 28, 0) 76%);
}
.brand { position: relative; }
.top-seal, .seal-hero { position: relative; }
.seal-hero .mini-light { inset: 0; }
.top.sweeping .mini-light i, .seal-hero.sweeping .mini-light i { animation: minisweep 1.1s cubic-bezier(0.45, 0, 0.2, 1) both; }
@keyframes minisweep { from { transform: translate3d(-110%, 0, 0); } to { transform: translate3d(110%, 0, 0); } }

html:not(.motion) .hero-glow, html:not(.motion) .logo-light, html:not(.motion) .flare-rig, html:not(.motion) .mini-light,
html.lite .hero-glow, html.lite .logo-light, html.lite .flare-rig, html.lite .mini-light { display: none; }

html.motion .hero-visual { opacity: 1; transition: opacity 1s; }

.flare {
  position: absolute; width: 24vmin; height: 24vmin; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(255, 190, 40, 0.62) 0, rgba(255, 138, 0, 0.22) 26%, transparent 62%);
  opacity: 0.55;
  transform: translate3d(calc(var(--mx) * -16px), calc(var(--sy) * -0.1px + var(--my) * -12px), 0);
}
.flare::after {
  content: ""; position: absolute; left: -140%; right: -140%; top: 50%; height: 1px;
  background: linear-gradient(90deg, transparent, rgba(255, 210, 110, 0.38) 35%, rgba(255, 230, 170, 0.5) 50%, rgba(255, 210, 110, 0.38) 65%, transparent);
  box-shadow: 0 0 8px 1px rgba(255, 176, 0, 0.22);
  transform: translateY(-50%);
}
.flare-a { left: -3%; bottom: 2%; }
.flare-b { left: 38%; top: -8%; width: 16vmin; height: 16vmin; }
html.motion .flare-a { animation: flare 9s ease-in-out infinite alternate; }
html.motion .flare-b { animation: flare 7s ease-in-out 2s infinite alternate; }
@keyframes flare { 0% { opacity: 0.42; } 50% { opacity: 0.7; } 100% { opacity: 0.5; } }
html.lite .flare { opacity: 0.35; }

.hero-title {
  font-family: var(--font-display); font-weight: 300;
  /* ONE line at every width (320 to 2560): fluid size, never wraps; shrinks on very narrow phones */
  font-size: clamp(0.9rem, 5.3vw, 5rem);
  line-height: 1.12; letter-spacing: -0.022em;
  white-space: nowrap; width: 100%; max-width: 100%; text-wrap: nowrap; text-align: center;
}
.hero-title .line { display: inline-block; vertical-align: top; white-space: nowrap; }
@media (max-width: 360px) { .hero-title .line { white-space: nowrap; } }
@media (min-width: 1000px) { .hero-title { font-size: clamp(2.6rem, 5.3vw, 5rem); } }
html.motion .hero-title { letter-spacing: 0.06em; transition: letter-spacing 2s var(--ease) 0.2s; }
html.motion.intro-done .hero-title, html.motion .hero.in .hero-title { letter-spacing: -0.022em; }
html.motion .hero .line-in { transition-delay: 0.15s; }
html.motion .hero .line:nth-child(2) .line-in { transition-delay: 0.3s; }

/* a single pass of light across the title once it has landed */
html.motion .hero-title .line-in {
  background: linear-gradient(100deg, var(--ink) 0 38%, #fff3cf 46%, var(--gold) 50%, #fff3cf 54%, var(--ink) 62% 100%);
  background-size: 300% 100%; background-position: 100% 0;
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
html.motion .hero.in .hero-title .line-in { animation: sheen 2.4s ease-in-out 1.1s 1 both; }
@keyframes sheen { from { background-position: 100% 0; } to { background-position: 0% 0; } }

/* big rolling text bar under the headline (js/ticker.js) */
.ticker { position: relative; width: 100vw; max-width: 100vw; margin-inline: calc(50% - 50vw); display: flex; align-items: center; justify-content: center; }
.ticker-view {
  flex: 1; min-width: 0; overflow: hidden;
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
  mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent);
}
.ticker-track { display: flex; width: max-content; margin: 0; padding: 0.3rem 0; list-style: none; }
.ticker-track li {
  flex: none; display: flex; align-items: center; white-space: nowrap;
  font-family: var(--font-display); font-weight: 300; font-size: clamp(1.45rem, 0.9rem + 2.6vw, 3.1rem); line-height: 1.25; color: var(--ink);
}
.ticker-track li::after { content: ""; flex: none; width: 0.5rem; height: 0.5rem; margin-inline: clamp(1.6rem, 4vw, 3.4rem); background: var(--gold); transform: rotate(45deg); box-shadow: 0 0 10px rgba(255, 176, 0, 0.6); }
.ticker.is-roll .ticker-track { animation: ticker-roll var(--ticker-dur, 160s) linear infinite; will-change: transform; }
@keyframes ticker-roll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
.ticker.is-roll:hover .ticker-track, .ticker.is-roll:focus-within .ticker-track, .ticker.is-paused .ticker-track { animation-play-state: paused; }
/* reduced motion: one sentence at a time, slow crossfade */
.ticker.is-fade .ticker-track { display: grid; width: 100%; padding: 0.3rem var(--gutter); }
.ticker.is-fade .ticker-track li { grid-area: 1 / 1; justify-content: center; white-space: normal; text-align: center; opacity: 0; transition: opacity 2s ease; pointer-events: none; }
.ticker.is-fade .ticker-track li::after { display: none; }
.ticker.is-fade .ticker-track li.on { opacity: 1; pointer-events: auto; }
.ticker.is-fade .ticker-view { -webkit-mask-image: none; mask-image: none; }
.no-js .ticker-track { flex-wrap: wrap; width: auto; justify-content: center; gap: 0.4rem 1.5rem; }
.no-js .ticker-track li::after { display: none; }
.ticker-pause {
  position: absolute; right: var(--gutter); bottom: -2.6rem; z-index: 3;
  width: 2.5rem; height: 2.5rem; display: grid; place-items: center; cursor: pointer;
  background: rgba(6, 11, 28, 0.7); border: 1.5px solid rgba(255, 176, 0, 0.7); border-radius: 50%; color: var(--gold);
}
.ticker-pause[hidden] { display: none; }
.ticker-pause:hover { background: var(--gold); color: #140b00; }
.ticker-pause:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.tp-ico { width: 0.8rem; height: 0.8rem; border-inline: 0.25rem solid currentColor; }
.ticker-pause[aria-pressed="true"] .tp-ico { width: 0; height: 0; border-inline: 0; border-block: 0.4rem solid transparent; border-left: 0.7rem solid currentColor; }

.cue {
  position: absolute; left: 50%; bottom: 1.6rem; transform: translateX(-50%);
  width: auto; margin: 0;
  font-size: 0.62rem; letter-spacing: 0.34em; text-transform: uppercase; color: var(--ink-2);
  padding: 0.4rem 0.2rem;
}
.cue::after {
  content: ""; display: block; width: 1px; height: 42px; margin: 0.7rem auto 0;
  background: linear-gradient(var(--gold), transparent); transform-origin: top;
}
html.motion .cue { opacity: 0; transition: opacity 1.2s ease 1.4s; }
html.motion .hero.in .cue { opacity: 1; }
html.motion .cue::after { animation: cue 2.4s var(--ease) infinite; }
@keyframes cue { 0% { transform: scaleY(0); } 45% { transform: scaleY(1); transform-origin: top; } 46% { transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* ------------------------------------------------------------------ families */
.split {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  border-top: 1px solid var(--line); border-left: 1px solid var(--line);
}
.family {
  display: block; position: relative;
  padding: 2.6rem clamp(1.4rem, 3vw, 2.6rem); background: var(--bg);
  border-right: 1px solid var(--line); border-bottom: 1px solid var(--line);
  transition: background 0.6s var(--ease);
}
.family::before {
  content: ""; position: absolute; left: 0; top: 0; width: 2.2rem; height: 1px; background: var(--gold);
  transition: width 0.7s var(--ease);
}
.family:hover::before, .family:focus-visible::before { width: 100%; }
.family .eyebrow {
  display: block; margin-bottom: 1.1rem;
  font-size: 0.64rem; letter-spacing: 0.3em; text-transform: uppercase; color: var(--gold);
}
.family:hover, .family:focus-visible { background: rgba(19, 86, 214, 0.12); }
.family strong { display: block; font-family: var(--font-display); font-size: 1.4rem; font-weight: 600; margin-bottom: 0.55rem; }
.family .desc { display: block; color: var(--ink-2); font-weight: 300; max-width: 40ch; line-height: 1.5; }
.family .go {
  display: inline-block; margin-top: 1.2rem; color: var(--gold);
  font-size: 0.68rem; letter-spacing: 0.26em; text-transform: uppercase;
  transition: transform 0.6s var(--ease);
}
.family:hover .go { transform: translateX(6px); }

/* ------------------------------------------------------------------ product cards */
/* any number of cards: columns are whatever fits, rows wrap, partial rows keep their ledger lines */
.cards {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr));
  border-top: 1px solid var(--line); border-left: 1px solid var(--line);
}
.card { background: var(--bg); border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.card-static { display: none; }
.card-static:only-child { display: block; padding: 1.5rem; color: var(--ink-2); }
.card-link {
  position: relative; display: grid; grid-template-rows: auto 1fr auto; gap: 1.4rem;
  min-height: 16rem; height: 100%; padding: 1.5rem 1.5rem 1.35rem;
  transition: background 0.6s var(--ease);
}
.card-link::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(70% 60% at 85% 0%, rgba(26, 163, 255, 0.18), transparent 70%);
  opacity: 0; transition: opacity 0.7s var(--ease);
}
.card-link:hover::before, .card-link:focus-visible::before { opacity: 1; }
.card-link:hover { background: rgba(19, 86, 214, 0.08); }
.card-soon { cursor: default; }
.card-soon:hover { background: var(--bg); }
.card-soon:hover::before { opacity: 0; }
.chip.chip-soon { color: #f2f6ff; background: #3a4458; border-color: #5d6a82; }
.card-head { display: flex; align-items: center; gap: 1rem; }
.chip {
  font-size: 0.6rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--gold);
  border: 1px solid rgba(255, 176, 0, 0.45); border-radius: 999px; padding: 0.34em 0.75em; white-space: nowrap;
}
.card-name {
  display: block; font-family: var(--font-display); font-size: 1.32rem; font-weight: 600;
  letter-spacing: -0.01em; line-height: 1.2; margin-bottom: 0.5rem;
}
.card-tag { display: block; color: var(--ink-2); font-weight: 300; line-height: 1.45; }
.card-foot { display: flex; justify-content: space-between; align-items: end; gap: 1rem; }
.card-for { font-size: 0.78rem; color: var(--ink-3); line-height: 1.4; }
.card-arrow { color: var(--gold); font-size: 1.15rem; line-height: 1; transition: transform 0.6s var(--ease); }
.card-link:hover .card-arrow, .card-link:focus-visible .card-arrow { transform: translateX(6px); }

/* app cards: a picture of the app, a status badge and a link to the app's landing page */
.card-app { grid-template-rows: auto auto 1fr auto; gap: 1.1rem; min-height: 0; }
.card-shot {
  display: block; aspect-ratio: 16 / 10; overflow: hidden;
  border: 1px solid var(--line); background: var(--bg-2);
}
.card-shot img {
  display: block; width: 100%; height: 100%; object-fit: cover; object-position: top left;
  opacity: 0.9; transition: opacity 0.6s var(--ease), transform 0.9s var(--ease);
}
.card-app:hover .card-shot img, .card-app:focus-visible .card-shot img { opacity: 1; transform: scale(1.03); }
.chip.chip-live { color: #04210f; background: #7ee2b8; border-color: #7ee2b8; font-weight: 600; }
.card-has-dl { display: flex; flex-direction: column; }
.card-has-dl .card-link { flex: 1 1 auto; height: auto; }
.card-dl {
  display: block; margin: 0 1.5rem 1.5rem; padding: 0.8rem 1rem; text-align: center; text-decoration: none;
  background: var(--gold); color: #140b00; font-weight: 600; font-size: 0.9rem; letter-spacing: 0.04em;
  border-radius: 999px; transition: background 0.4s var(--ease);
}
.card-dl:hover, .card-dl:focus-visible { background: #e09a00; }
.cards-more { margin-top: 1.6rem; }
.cards-more-link {
  display: inline-block; color: var(--gold); text-decoration: none;
  font-size: 0.68rem; letter-spacing: 0.26em; text-transform: uppercase;
  transition: transform 0.6s var(--ease);
}
.cards-more-link:hover, .cards-more-link:focus-visible { transform: translateX(6px); }

html.motion .card {
  opacity: 0; transform: translateY(22px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
  transition-delay: calc(0.2s + min(var(--i, 0) * 65ms, 0.7s));
}
html.motion .in .card { opacity: 1; transform: none; }

/* ------------------------------------------------------------------ seal: 27 years in education (canonical mark, assets/badge-27-years.svg) */
.seal-wrap { display: inline-block; line-height: 0; color: var(--gold); }
.seal { display: block; width: 140px; height: 140px; }
.seal-hero { margin-top: 0.4rem; }
html.motion .seal-hero { opacity: 0; transform: translateY(10px); transition: opacity 1.4s ease 1.3s, transform 1.4s var(--ease) 1.3s; }
html.motion .hero.in .seal-hero { opacity: 1; transform: none; }
.seal-about { margin-top: 0.2rem; margin-bottom: 2.2rem; }
.seal-about .seal { width: 104px; height: 104px; opacity: 0.92; }
/* the large "27 years" badge sits on the LEFT of the hero, away from the buttons fixed to the right-hand side */
@media (max-width: 900px) {
  .seal-hero { justify-self: start; }
}
@media (min-width: 901px) {
  .seal-hero { position: absolute; left: calc(var(--gutter) - 1rem); bottom: 1.2rem; margin: 0; }
  .seal-hero .mini-light { inset: 0; }
  .wrap > .seal-about { grid-column: 1 / 4; grid-row: 3; align-self: start; justify-self: start; margin-bottom: 0; }
}
@media (max-width: 760px) {
  .seal { width: 116px; height: 116px; }
}

/* ------------------------------------------------------------------ photo slots (hidden until a file exists) */
.photo {
  position: relative; display: none; margin: 0; overflow: hidden;
  background: linear-gradient(160deg, #10204f 0%, #0a1434 45%, #060b1c 100%);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 16%, #000 84%, transparent), linear-gradient(180deg, transparent, #000 14%, #000 86%, transparent);
  -webkit-mask-composite: source-in;
  mask-image: linear-gradient(90deg, transparent, #000 16%, #000 84%, transparent), linear-gradient(180deg, transparent, #000 14%, #000 86%, transparent);
  mask-composite: intersect;
}
.photo img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block;
  transform: translate3d(0, var(--py, 0px), 0) scale(1.08);
}
.photo::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(85% 85% at 50% 50%, rgba(6, 11, 28, 0) 45%, rgba(6, 11, 28, 0.78) 100%);
}
.photo.missing { display: none !important; }
.photo-a, .photo-c { aspect-ratio: 4 / 5; }
.photo-b { aspect-ratio: 1 / 1; }
html.motion .photo { opacity: 0; transition: opacity 1.8s ease 0.3s; }
html.motion .in .photo { opacity: 1; }
html.motion .photo img { transition: transform 0.2s linear; }
html.photos-demo .photo img { visibility: hidden; }
html.photos-demo .photo.missing { display: block !important; }
@media (max-width: 1279px) { html.photos-demo .photo-b.missing, html.photos-demo .photo-c.missing { display: none !important; } }

@media (min-width: 1280px) {
  .wrap > .photo { display: block; grid-column: 10 / -1; grid-row: 1 / 4; align-self: start; width: 100%; }
  .wrap.has-photo > .chapter-mark { grid-column: 1 / 10; }
  .wrap.has-photo > .kinetic { grid-column: 1 / 10; }
}
@media (max-width: 1279px) {
  .wrap > .photo-a { display: block; aspect-ratio: 16 / 9; max-height: 400px; margin-bottom: 2.6rem; }
  .wrap > .photo-b, .wrap > .photo-c { display: none; }
}
@media (max-width: 760px) {
  .wrap > .photo-a { aspect-ratio: 16 / 10; margin-bottom: 2rem; }
}

/* ------------------------------------------------------------------ about */
.principles {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  gap: 2.6rem clamp(2rem, 4vw, 4rem); border-top: 1px solid var(--line); padding-top: 2.6rem;
}
.principle .p-idx { display: block; color: var(--gold); font-size: 0.7rem; letter-spacing: 0.3em; margin-bottom: 1.1rem; }
.principle h3 { font-family: var(--font-display); font-weight: 600; font-size: 1.3rem; letter-spacing: -0.01em; margin-bottom: 0.6rem; }
.principle p { color: var(--ink-2); font-weight: 300; max-width: 34ch; line-height: 1.55; }
.principle:nth-child(2) { --d: 0.4s; }
.principle:nth-child(3) { --d: 0.55s; }

/* ------------------------------------------------------------------ contact */
.soon {
  position: relative; max-width: 560px; margin-inline: 0; padding: 2.2rem 2.4rem;
  border: 1px solid rgba(255, 176, 0, 0.35);
  background: linear-gradient(180deg, rgba(255, 176, 0, 0.06), rgba(255, 176, 0, 0));
}
.soon::before {
  content: ""; position: absolute; top: -1px; left: -1px; width: 2.2rem; height: 2.2rem;
  border-top: 1px solid var(--gold); border-left: 1px solid var(--gold);
}
.soon-k { display: block; font-size: 0.64rem; letter-spacing: 0.32em; text-transform: uppercase; color: var(--gold); margin-bottom: 1rem; }
.soon p { color: var(--ink-2); font-weight: 300; line-height: 1.55; }

/* contact form (js/contact.js shows it; index.html ships it hidden so it never appears without JavaScript) */
.soon-form { max-width: 600px; }
.cform { display: grid; gap: 1.15rem; margin-top: 1.8rem; padding-top: 1.8rem; border-top: 1px solid var(--line); }
.cform[hidden] { display: none; }
.cform-title { font-family: var(--font-display); font-weight: 600; font-size: 1.3rem; letter-spacing: -0.01em; }
.soon p.cform-note { font-size: 0.86rem; line-height: 1.6; }
.cform-field { display: grid; gap: 0.5rem; }
.cform-field label { font-size: 0.7rem; letter-spacing: 0.22em; text-transform: uppercase; color: var(--ink-2); }
.cform input[type="text"], .cform input[type="email"], .cform textarea {
  width: 100%; margin: 0; padding: 0.8rem 0.9rem;
  font: inherit; font-size: 1rem; font-weight: 300; line-height: 1.5; color: var(--ink);
  background: rgba(242, 246, 255, 0.04); border: 1px solid rgba(242, 246, 255, 0.28); border-radius: 2px;
  transition: border-color 0.3s, background 0.3s;
}
.cform textarea { min-height: 8.5rem; resize: vertical; }
.cform input[type="text"]:hover, .cform input[type="email"]:hover, .cform textarea:hover { border-color: rgba(242, 246, 255, 0.5); }
.cform input[type="text"]:focus-visible, .cform input[type="email"]:focus-visible, .cform textarea:focus-visible {
  border-color: var(--gold); background: rgba(242, 246, 255, 0.07); outline-offset: 2px;
}
.cform [aria-invalid="true"] { border-color: #ff8a8a; }
/* browsers paint autofilled fields pale: keep them readable on the dark page */
.cform input:-webkit-autofill, .cform textarea:-webkit-autofill {
  -webkit-text-fill-color: var(--ink); caret-color: var(--ink); box-shadow: 0 0 0 100px var(--bg-2) inset;
}
/* honeypot: off-screen, not display:none, so simple bots still fill it; people and screen readers never reach it */
.cform-hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.cform-consent { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 0.8rem; align-items: start; }
.cform-consent input { width: 1.2rem; height: 1.2rem; margin: 0.15rem 0 0; accent-color: var(--gold); }
.cform-consent label { font-size: 0.9rem; font-weight: 300; line-height: 1.5; color: var(--ink-2); }
.cform a { color: var(--gold); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; }
.cform a:hover, .cform a:focus-visible { text-decoration-thickness: 2px; }
.cform .btn { justify-self: start; margin-top: 0; background: transparent; border-radius: 0; cursor: pointer; }
.cform .btn:hover, .cform .btn:focus-visible { background: var(--gold); color: #140b00; }
.cform .btn[aria-disabled="true"] { opacity: 0.6; cursor: progress; }
.soon p.cform-status { font-size: 0.95rem; }
.soon p.cform-status:empty { display: block; height: 0; margin: -0.6rem 0 0; }
.soon p.cform-status[data-state="ok"] { color: #35e07a; }
.soon p.cform-status[data-state="bad"] { color: #ff8a8a; }
@media (max-width: 560px) {
  .soon-form { padding: 1.7rem 1.25rem; }
}

/* ------------------------------------------------------------------ footer (compact: badge, links, appearance and QR) */
.foot {
  display: flex; flex-direction: column; align-items: center; gap: 0.7rem;
  padding: 1.4rem var(--gutter) 1.6rem;
  border-top: 1px solid var(--line);
  font-size: 0.74rem; letter-spacing: 0.02em; color: var(--ink-2); text-align: center;
}
.foot-row { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0.5rem 1.1rem; }
.foot-seal { display: inline-block; line-height: 0; color: var(--gold); }
.foot-seal .seal { width: 52px; height: 52px; }
.foot-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.25rem 1rem; }
.foot a.foot-link { color: var(--ink-2); display: inline-flex; align-items: center; gap: 0.3rem; min-height: 32px; }
.foot a.foot-link:hover { color: var(--ink); text-decoration: underline; }
.ic-terms::before { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M7 3h8l4 4v14H7z'/%3E%3Cpath d='M15 3v4h4M10 12h6M10 16h6'/%3E%3C/svg%3E"); }
.ic-privacy::before { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3l8 3v6c0 5-3.5 8-8 9-4.5-1-8-4-8-9V6z'/%3E%3C/svg%3E"); }
.ic-refund::before { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 12a8 8 0 1 0 3-6.2M4 4v4h4'/%3E%3C/svg%3E"); }
.ic-dpa::before { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='5' y='4' width='14' height='17' rx='2'/%3E%3Cpath d='M9 9h6M9 13h6M9 17h3'/%3E%3C/svg%3E"); }
.ic-edu::before { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M2 9l10-5 10 5-10 5z'/%3E%3Cpath d='M6 11.5V16c0 1.5 2.7 3 6 3s6-1.5 6-3v-4.5'/%3E%3C/svg%3E"); }
.ic-light::before { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='4'/%3E%3Cpath d='M12 2v2M12 20v2M4.9 4.9l1.4 1.4M17.7 17.7l1.4 1.4M2 12h2M20 12h2M4.9 19.1l1.4-1.4M17.7 6.3l1.4-1.4'/%3E%3C/svg%3E"); }
.ic-dark::before { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M21 12.8A9 9 0 1 1 11.2 3a7 7 0 0 0 9.8 9.8z'/%3E%3C/svg%3E"); }
.ic-brite::before { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M4 6l6 6-6 6M12 18h8'/%3E%3C/svg%3E"); }
.ic-qr::before { --ic: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='4' y='4' width='6' height='6'/%3E%3Crect x='14' y='4' width='6' height='6'/%3E%3Crect x='4' y='14' width='6' height='6'/%3E%3Cpath d='M14 14h2v2h-2zM18 18h2v2h-2z'/%3E%3C/svg%3E"); }
.foot-compact [class*="ic-"]::before { content: ""; width: 0.95em; height: 0.95em; background: currentColor; -webkit-mask: var(--ic) center / contain no-repeat; mask: var(--ic) center / contain no-repeat; flex: none; }
.foot-row2 { gap: 0.4rem 1.2rem; }
.foot-look { display: inline-flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 0.3rem; }
.foot-look-label { margin-right: 0.2rem; }
.foot-look-label::before { content: ""; display: inline-block; width: 0.95em; height: 0.95em; margin-right: 0.3rem; vertical-align: -0.12em; background: currentColor; -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3a9 9 0 100 18c1.4 0 2-1 1.6-2-.5-1.2.2-2.5 1.6-2.5H17a4 4 0 004-4c0-5-4-9.5-9-9.5z'/%3E%3C/svg%3E") center / contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M12 3a9 9 0 100 18c1.4 0 2-1 1.6-2-.5-1.2.2-2.5 1.6-2.5H17a4 4 0 004-4c0-5-4-9.5-9-9.5z'/%3E%3C/svg%3E") center / contain no-repeat; }
.foot-pick { display: inline-flex; align-items: center; gap: 0.3rem; font-size: 0.72rem; padding: 0.2rem 0.6rem; min-height: 30px; border-radius: 999px; border: 1px solid var(--line); background: transparent; color: var(--ink-2); cursor: pointer; }
.foot-pick[aria-pressed="true"] { border-color: var(--gold); color: var(--ink); background: rgba(255, 176, 0, 0.14); }
.foot-qr { display: inline-flex; align-items: center; gap: 0.6rem; color: var(--ink-2); text-align: left; }
.foot-qr img { width: 64px; height: 64px; border-radius: 6px; background: #fff; }
.foot-qr-cap { display: inline-flex; align-items: center; gap: 0.3rem; max-width: 9.5rem; line-height: 1.3; }
.foot-edu a.foot-link { color: var(--gold); font-weight: 600; }

/* ------------------------------------------------------------------ status light */
.status { position: relative; display: flex; align-items: center; flex: none; }
.status-btn {
  display: grid; place-items: center; width: 2.75rem; height: 2.75rem; padding: 0; margin: 0; background: transparent; border: 0; border-radius: 50%; cursor: pointer;
}
.status-btn:focus-visible { outline: 3px solid var(--gold); outline-offset: -2px; }
.status .dot {
  width: 12px; height: 12px; border-radius: 50%; background: rgba(242, 246, 255, 0.45);
  transition: background 0.5s, box-shadow 0.5s;
}
.status.ok .dot { background: #35e07a; color: rgba(53, 224, 122, 0.8); }
.status.warn .dot { background: #ffb020; color: rgba(255, 176, 32, 0.8); }
.status.bad .dot { background: #ff5a5a; color: rgba(255, 90, 90, 0.8); }
.status.ok .dot, .status.warn .dot, .status.bad .dot { box-shadow: 0 0 8px 1px currentColor; }
html.motion .status.ok .dot, html.motion .status.warn .dot, html.motion .status.bad .dot { animation: status-pulse 2.4s ease-in-out infinite; }
@keyframes status-pulse { 0%, 100% { box-shadow: 0 0 6px 1px currentColor; } 50% { box-shadow: 0 0 16px 5px currentColor; } }
.status-tip {
  position: absolute; top: calc(100% + 4px); right: 0; z-index: 95; width: max-content; max-width: min(18rem, 80vw);
  padding: 0.55rem 0.8rem; background: #0b1330; color: var(--ink); border: 1px solid rgba(242, 246, 255, 0.28); border-radius: 6px;
  font-size: 0.82rem; line-height: 1.35; letter-spacing: 0; text-transform: none; text-align: left;
  display: grid; gap: 0.15rem; opacity: 0; visibility: hidden; transform: translateY(-4px); pointer-events: none;
  transition: opacity 0.18s, transform 0.18s, visibility 0.18s;
}
.status-tip strong { font-weight: 700; }
.status-tip .status-label { color: var(--ink-2); font-size: 0.76rem; }
.status:hover .status-tip, .status:focus-within .status-tip, .status.tip-open .status-tip { opacity: 1; visibility: visible; transform: none; }

/* ------------------------------------------------------------------ atmosphere */
.rail {
  position: fixed; right: 1.1rem; top: 50%; z-index: 70; width: 1px; height: 120px;
  background: var(--line); transform: translateY(-50%); pointer-events: none;
}
.rail i { position: absolute; inset: 0; background: var(--gold); transform: scaleY(var(--p)); transform-origin: top; }

/* film grain: one small tile with its own faint alpha, stepped like a projector */
.film {
  position: fixed; inset: 0; z-index: 60; pointer-events: none;
  background: url("../assets/grain.c56ba8b5.png") repeat 0 0 / 128px 128px;
}
html.motion .film { animation: film 1.4s steps(7) infinite; }
@keyframes film {
  0% { background-position: 0 0; }
  14% { background-position: -37px 23px; }
  28% { background-position: 29px -51px; }
  42% { background-position: -61px -17px; }
  56% { background-position: 47px 41px; }
  70% { background-position: -19px 59px; }
  84% { background-position: 63px -29px; }
  100% { background-position: 0 0; }
}
html.lite .film { display: none; }

.cursor {
  position: fixed; left: 0; top: 0; z-index: 120; pointer-events: none;
  width: 34px; height: 34px; margin: -17px 0 0 -17px; border-radius: 50%;
  border: 1px solid rgba(242, 246, 255, 0.7);
  opacity: 0;
  transition: opacity 0.4s, width 0.4s var(--ease), height 0.4s var(--ease), margin 0.4s var(--ease), border-color 0.4s;
}
html.fine .cursor.live { opacity: 1; }
.cursor.on { width: 60px; height: 60px; margin: -30px 0 0 -30px; border-color: var(--gold); }
.cursor.down { width: 20px; height: 20px; margin: -10px 0 0 -10px; }
[data-magnet] { transition: transform 0.5s var(--ease); }

/* ------------------------------------------------------------------ language bar (built by js/lang.js) */
.lang {
  position: fixed; inset: var(--strip-h) 0 auto 0; z-index: 85; height: var(--lang-h);
  display: flex; align-items: center; justify-content: flex-end; gap: 0.7rem;
  padding: 0 var(--gutter);
  background: #040817; box-shadow: 0 1px 0 var(--line);
  font-size: 0.62rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--ink-2);
}
.lang-label { white-space: nowrap; flex: none; }
.flags {
  list-style: none; margin: 0; padding: 0; min-width: 0; display: flex; align-items: center; gap: 1px;
  overflow-x: auto; overflow-y: hidden; scrollbar-width: none; -webkit-overflow-scrolling: touch; overscroll-behavior-x: contain;
}
.flags::-webkit-scrollbar { display: none; }
.flags li { flex: none; display: block; }
.flag { background: none; border: 0; margin: 0; cursor: pointer; font: inherit; display: grid; place-items: center; height: 28px; padding: 0 3px; border-radius: 3px; position: relative; }
.flag img { display: block; width: 22px; height: 15px; border-radius: 2px; box-shadow: 0 0 0 1px rgba(242, 246, 255, 0.28); opacity: 0.9; }
.flag:hover img { opacity: 1; }
.flag:focus-visible { outline: 2px solid #fff; outline-offset: 0; }
.flag[aria-current] img { opacity: 1; box-shadow: 0 0 0 2px var(--bg, #060b1c), 0 0 0 4px var(--gold); }
.flag[aria-current] { cursor: default; }
.lang-noscript { margin: 0; padding: 0.5rem var(--gutter); background: #040817; font-size: 0.8rem; }
.lang-noscript a { color: var(--gold); text-decoration: underline; }
.lang { justify-content: center; }
@media (max-width: 1280px) {
  .lang-label { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; }
}
@media (max-width: 1120px) {
  .lang { justify-content: flex-start; gap: 0; padding: 0; }
  .flags {
    flex: 1; padding: 0 var(--gutter);
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 14px, #000 calc(100% - 14px), transparent);
    mask-image: linear-gradient(90deg, transparent, #000 14px, #000 calc(100% - 14px), transparent);
  }
}

/* ------------------------------------------------------------------ 404 */
.page-404 .chapter { min-height: 100vh; padding-top: calc(var(--nav-h) + var(--lang-h) + 4rem); }
.page-404 .top { opacity: 1; transform: none; }
.page-404 .chapter::after { display: none; }
.btn {
  display: inline-block; margin-top: 0.5rem; padding: 0.9rem 1.5rem; border: 1px solid var(--gold); color: var(--gold);
  font-size: 0.7rem; letter-spacing: 0.26em; text-transform: uppercase; transition: background 0.4s, color 0.4s;
}
.btn:hover, .btn:focus-visible { background: var(--gold); color: #140b00; }

/* ------------------------------------------------------------------ small screens */
@media (max-width: 900px) {
  .nav { display: none; }
  .menu-btn { display: inline-flex; }
  .status { margin-left: auto; }
}
@media (max-width: 760px) {
  :root { --nav-h: 64px; }
  .brand img { height: 28px; }
  .brand-lockup { gap: 0.6rem; }
  .top-seal .seal { width: 38px; height: 38px; }
  .hero-visual { width: 92vw; }
  .hero { gap: 1.6rem; padding-bottom: 7.5rem; min-height: 100vh; min-height: 100svh; }
  .chapter:not(.hero) { padding-block: 5.5rem; min-height: 0; }
  .chapter-num { font-size: 42vw; right: 0; top: 4rem; transform: none; }
  .kinetic { margin-bottom: 1.4rem; }
  .lede { margin-bottom: 2.4rem; }
  .card-link { min-height: 0; }
  .rail { display: none; }
  .foot { padding-bottom: 1.6rem; }
  .flare { display: none; }
}

@media (min-width: 901px) and (max-width: 1100px) {
  .nav ul { gap: 1.1rem; }
  /* tighter letter spacing keeps all six options on one line, with a clear gap after the small 27 emblem beside the logo */
  .nav a, .nav-edu-btn { letter-spacing: 0.1em; }
  .nav { margin-left: 1.25rem; }
}
@media (min-width: 901px) and (max-width: 960px) {
  .nav ul { gap: 0.85rem; }
  .nav a, .nav-edu-btn { letter-spacing: 0.04em; }
}

/* ------------------------------------------------------------------ Education menu and the four fixed buttons (js/edu-menu.js) */
/* The four button colours. Dark text (--float-ink) on each is at least 7:1 (WCAG AAA); the white focus ring is 19:1 on the page.
   To change a colour keep it bright and keep the text/colour contrast at 4.5:1 or more (the tests check this). */
.tone-sky   { --tone: #35c4ff; --tone-hi: #7bd8ff; }
.tone-mint  { --tone: #3de08a; --tone-hi: #7aeab0; }
.tone-amber { --tone: #ffc531; --tone-hi: #ffd86b; }
.tone-rose  { --tone: #ff79b8; --tone-hi: #ffa3cf; }
:root { --float-ink: #07101f; --float-w: 11rem; }

/* the Education option in the top bar (desktop) */
.nav-edu { position: relative; }
.nav-edu-btn {
  display: inline-flex; align-items: center; gap: 0.55rem; position: relative; padding: 0.45rem 0;
  background: none; border: 0; cursor: pointer;
  font-size: 0.72rem; letter-spacing: 0.22em; text-transform: uppercase;
  color: var(--ink-2); transition: color 0.3s;
}
.nav-edu-btn::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 1px;
  background: var(--gold); transform: scaleX(0); transform-origin: right;
  transition: transform 0.55s var(--ease);
}
.nav-edu-btn:hover, .nav-edu-btn:focus-visible, .nav-edu-btn[aria-current], .nav-edu-btn[aria-expanded="true"] { color: var(--ink); }
.nav-edu-btn:hover::after, .nav-edu-btn[aria-current]::after, .nav-edu-btn[aria-expanded="true"]::after { transform: none; transform-origin: left; }
.caret {
  display: inline-block; flex: none; width: 0.42em; height: 0.42em;
  border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor;
  transform: translateY(-0.14em) rotate(45deg); transition: transform 0.3s var(--ease);
}
[aria-expanded="true"] > .caret { transform: translateY(0.1em) rotate(225deg); }

.nav .nav-edu-panel {
  position: absolute; top: calc(100% + 0.8rem); left: -1rem; z-index: 5; width: 21.5rem;
  max-height: calc(100vh - var(--top-h) - var(--nav-h) - 1.5rem); overflow-y: auto;
  padding: 0.45rem; background: #0a1230;
  border: 1px solid rgba(242, 246, 255, 0.16); border-top-color: rgba(255, 176, 0, 0.7);
  box-shadow: 0 22px 60px rgba(0, 0, 0, 0.6);
}
html.motion .nav .nav-edu-panel { animation: edu-panel-in 0.18s ease-out; }
.nav .nav-edu-panel[hidden] { display: none; }
.nav .nav-edu-panel ul { display: grid; gap: 0; }
@keyframes edu-panel-in { from { opacity: 0; transform: translateY(-6px); } }

/* one link of the Education menu (desktop dropdown and full-screen menu); the four with a fixed button also get its colour as a dot */
.nav .edu-link, .menu .edu-link {
  display: grid; grid-template-columns: 0.6rem minmax(0, 1fr); column-gap: 0.8rem; align-items: center;
  padding: 0.7rem 0.85rem; border-radius: 6px;
  font-family: var(--font-text); font-size: 0.95rem; font-weight: 400; letter-spacing: 0; text-transform: none; line-height: 1.25;
  color: var(--ink); transition: background-color 0.2s;
}
.nav .edu-link::after, .menu .edu-link::after { content: none; }
.nav .edu-link::before, .menu .edu-link::before {
  content: ""; grid-row: 1 / span 2; width: 0.6rem; height: 0.6rem; border-radius: 50%; background: transparent;
}
.nav .edu-link-quick::before, .menu .edu-link-quick::before { background: var(--tone); }
/* the extra entry that stays on this page: a gold ring instead of a colour dot, set apart by a line */
.nav .edu-link-here::before, .menu .edu-link-here::before { border: 1.5px solid var(--gold); }
.nav .nav-edu-panel li.edu-here, .menu .menu-edu-list li.edu-here { margin-top: 0.35rem; padding-top: 0.35rem; border-top: 1px solid var(--line); }
.edu-link-label { grid-column: 2; }
.edu-link-note { grid-column: 2; margin-top: 0.12rem; font-size: 0.74rem; color: var(--ink-2); }
.nav .edu-link:hover, .nav .edu-link:focus-visible, .menu .edu-link:hover, .menu .edu-link:focus-visible { background: rgba(242, 246, 255, 0.09); }
.nav .edu-link:focus-visible, .menu .edu-link:focus-visible { outline-offset: -2px; }

/* Education inside the full-screen menu (small screens) */
.menu-edu-btn { width: 100%; background: none; border: 0; text-align: left; cursor: pointer; color: var(--ink); }
.menu-edu-btn .caret { align-self: center; width: 0.26em; height: 0.26em; margin-left: 0.2rem; }
.menu .menu-edu-list { display: grid; gap: 0; margin: 0.1rem 0 0.9rem 2.5rem; padding: 0.2rem 0 0.2rem 0.5rem; border-left: 1px solid rgba(255, 176, 0, 0.5); }
.menu .menu-edu-list[hidden] { display: none; }
.menu .edu-link { min-height: 2.75rem; font-size: 1.05rem; }

/* the four bright buttons fixed to the right-hand side (they stay put while the page scrolls) */
.float-links {
  position: fixed; right: 0; right: env(safe-area-inset-right, 0px);
  top: calc(var(--top-h) + var(--nav-h) + 1.5rem);
  z-index: 75; width: var(--float-w);
}
.float-list { display: grid; gap: 0.6rem; }
.float-link {
  position: relative; isolation: isolate; display: flex; align-items: center; gap: 0.7rem;
  min-height: 3.6rem; padding: 0.6rem 0.8rem 0.6rem 0.75rem; border-radius: 1rem 0 0 1rem;
  background: var(--tone); color: var(--float-ink);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.45), inset 0 0 0 1px rgba(255, 255, 255, 0.35);
  transition: transform 0.25s var(--ease), background-color 0.25s, box-shadow 0.25s;
}
.float-link:hover, .float-link:focus-visible {
  background: var(--tone-hi); transform: translateX(-4px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.55), inset 0 0 0 1px rgba(255, 255, 255, 0.55);
}
.float-link:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.float-icon { flex: none; width: 1.7rem; height: 1.7rem; }
.float-text { display: grid; gap: 0.1rem; min-width: 0; }
.float-label { font-size: 0.66rem; font-weight: 700; letter-spacing: 0.12em; text-transform: uppercase; line-height: 1.2; }
.float-action { font-size: 0.86rem; font-weight: 700; line-height: 1.22; overflow-wrap: anywhere; }
/* a soft ring around each button, twice, once the page has opened; never flashing, and finished within five seconds */
.float-link::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
  background: var(--tone); opacity: 0; pointer-events: none;
}
html.motion:not(.intro-done) .float-links { visibility: hidden; }
html.motion.intro-done .float-link { animation: float-in 0.7s var(--ease) backwards; }
html.motion.intro-done .float-link::before { animation: float-ring 1.6s ease-out 2; }
html.motion.intro-done .float-list li:nth-child(2) .float-link { animation-delay: 0.12s; }
html.motion.intro-done .float-list li:nth-child(3) .float-link { animation-delay: 0.24s; }
html.motion.intro-done .float-list li:nth-child(4) .float-link { animation-delay: 0.36s; }
html.motion.intro-done .float-list li:nth-child(1) .float-link::before { animation-delay: 0.8s; }
html.motion.intro-done .float-list li:nth-child(2) .float-link::before { animation-delay: 1s; }
html.motion.intro-done .float-list li:nth-child(3) .float-link::before { animation-delay: 1.2s; }
html.motion.intro-done .float-list li:nth-child(4) .float-link::before { animation-delay: 1.4s; }
@keyframes float-in { from { opacity: 0; transform: translateX(1.5rem); } }
@keyframes float-ring { 0% { opacity: 0.45; transform: scale(1); } 100% { opacity: 0; transform: scale(1.14, 1.3); } }
/* the scroll-progress line moves to the left of the buttons */
html.has-edu-float .rail { right: calc(var(--float-w) + 0.7rem); }

/* Anything narrower than 1700px (or shorter than 520px): a compact stack of icon buttons that sits inside the page's side margin;
   the words appear beside a button on hover or keyboard focus (and are always its accessible name). Only from 1700px up is
   there room beside the content (it is at most 1320px wide and centred) for the wide buttons with their words. */
@media (max-width: 1699px), (max-height: 520px) {
  :root { --float-w: 2.75rem; }
  .float-list { gap: 0.45rem; }
  .float-link { height: 2.75rem; min-height: 0; padding: 0; justify-content: center; border-radius: 0.75rem 0 0 0.75rem; }
  .float-text {
    position: absolute; right: calc(100% + 0.6rem); top: 50%; width: max-content; max-width: 15rem;
    padding: 0.5rem 0.75rem; border-radius: 0.6rem; background: var(--bg-2); color: var(--ink);
    border: 1px solid var(--tone); box-shadow: 0 8px 24px rgba(0, 0, 0, 0.5);
    transform: translateY(-50%); opacity: 0; visibility: hidden; pointer-events: none; transition: opacity 0.15s;
  }
  .float-link:hover .float-text, .float-link:focus-visible .float-text { opacity: 1; visibility: visible; }
}
/* phones: the stack sits at the bottom right, where the first screen is empty, and a strip is kept clear at the right of the
   text sections and the footer so the buttons never sit on top of words or form fields */
@media (max-width: 760px) {
  .float-links { top: auto; bottom: 1rem; bottom: max(1rem, env(safe-area-inset-bottom, 0px)); }
  .float-icon { width: 1.5rem; height: 1.5rem; }
  html.has-edu-float .chapter:not(.hero), html.has-edu-float .foot { padding-right: max(var(--gutter), 3.1rem); }
}
@media (forced-colors: active) { .float-link { border: 2px solid CanvasText; } }
@media print { .float-links, .strip { display: none !important; } }

/* ------------------------------------------------------------------ the way to the main website (the education website) */
/* 1. announcement strip at the very top. Visible unless dismissed for this session (js/head.js removes html.has-strip first
   thing, so a dismissed strip never flashes). Dark text on gold: 11:1. */
html.has-strip { --strip-h: 2.25rem; }
.strip {
  position: fixed; inset: 0 0 auto 0; z-index: 86; height: var(--strip-h);
  display: flex; align-items: center; justify-content: center; padding: 0 3rem 0 1rem;
  background: var(--gold); color: #140b00;
}
html:not(.has-strip) .strip, .strip[hidden] { display: none; }
.strip-text { margin: 0; text-align: center; font-size: 0.84rem; line-height: 1.25; font-weight: 500; }
.strip-link { font-weight: 700; text-decoration: underline; text-underline-offset: 3px; white-space: nowrap; }
.strip-link:hover { text-decoration-thickness: 2px; }
.strip-close {
  position: absolute; right: 0.4rem; top: 50%; width: 2.25rem; height: 2.25rem; transform: translateY(-50%);
  display: grid; place-items: center; padding: 0; border: 0; border-radius: 50%;
  background: transparent; color: #140b00; font-size: 1.4rem; line-height: 1; cursor: pointer;
}
.strip-close:hover { background: rgba(20, 11, 0, 0.14); }
.strip a:focus-visible, .strip-close:focus-visible { outline: 2px solid #140b00; outline-offset: 2px; }
html.no-js .strip-close { display: none; }
@media (max-width: 760px) {
  html.has-strip { --strip-h: 3rem; }
  .strip { padding-left: 0.75rem; }
  .strip-text { font-size: 0.8rem; }
  .strip-close { width: 2.5rem; height: 2.5rem; }
}

/* 2. the large button in the hero: the way to the main website */
.hero-cta {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.7rem; min-height: 3.5rem; padding: 0.9rem 1.8rem;
  border-radius: 999px; background: var(--gold); color: #140b00;
  font-size: clamp(1rem, 0.9rem + 0.4vw, 1.2rem); font-weight: 700; line-height: 1.2; text-align: center;
  box-shadow: 0 10px 30px rgba(255, 176, 0, 0.3);
  transition: transform 0.25s var(--ease), background-color 0.25s, box-shadow 0.25s;
}
.hero-cta:hover, .hero-cta:focus-visible { background: #ffd36b; transform: translateY(-2px); box-shadow: 0 14px 36px rgba(255, 176, 0, 0.45); }
.hero-cta:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
html.motion .hero-cta { opacity: 0; transform: translateY(18px); transition: opacity 1.2s var(--ease) 0.8s, transform 1.2s var(--ease) 0.8s, background-color 0.25s, box-shadow 0.25s; }
html.motion .hero.in .hero-cta { opacity: 1; transform: none; }
html.motion .hero.in .hero-cta:hover, html.motion .hero.in .hero-cta:focus-visible { transform: translateY(-2px); transition-delay: 0s; }

/* 3. the section directly under the hero */
.chapter-main {
  min-height: 0; padding-block: clamp(3.5rem, 9vh, 5.5rem);
  background: linear-gradient(180deg, rgba(19, 86, 214, 0.26), rgba(19, 86, 214, 0.07));
  border-block: 1px solid var(--line);
}
.chapter-main .main-title { font-size: clamp(1.8rem, 0.9rem + 3.6vw, 3.6rem); margin-bottom: 1rem; }
.chapter-main .wrap > .lede { grid-column: 1 / -1; max-width: 52ch; margin-bottom: 2rem; }
.door-list { display: grid; grid-template-columns: 1fr; gap: 1rem; }
.door-list:empty { display: none; }
@media (min-width: 560px) { .door-list { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1000px) { .door-list { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.door {
  position: relative; display: grid; align-content: start; gap: 0.3rem; min-height: 10.5rem; padding: 1.3rem 1.3rem 1.2rem;
  border-radius: 1.1rem; background: var(--tone); color: var(--float-ink);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.4), inset 0 0 0 1px rgba(255, 255, 255, 0.35);
  transition: transform 0.25s var(--ease), background-color 0.25s, box-shadow 0.25s;
}
.door:hover, .door:focus-visible { background: var(--tone-hi); transform: translateY(-4px); box-shadow: 0 16px 36px rgba(0, 0, 0, 0.5), inset 0 0 0 1px rgba(255, 255, 255, 0.55); }
.door:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }
.door-icon { width: 2.6rem; height: 2.6rem; margin-bottom: 0.5rem; }
.door-label { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.14em; text-transform: uppercase; line-height: 1.2; }
.door-action { font-size: clamp(1.1rem, 0.95rem + 0.5vw, 1.4rem); font-weight: 700; line-height: 1.2; }
.door-go { position: absolute; right: 1.1rem; bottom: 0.9rem; font-size: 1.5rem; font-weight: 700; line-height: 1; }
.door-all-item { grid-column: 1 / -1; }
.door-all {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 3.5rem; padding: 0.9rem 1.3rem;
  border: 2px solid var(--gold); border-radius: 1.1rem; color: var(--ink); font-size: 1.05rem; font-weight: 600;
  transition: background-color 0.25s, color 0.25s;
}
.door-all:hover, .door-all:focus-visible { background: var(--gold); color: #140b00; }
.door-all:focus-visible { outline: 3px solid #fff; outline-offset: 3px; }

/* 4. the footer link */


/* ------------------------------------------------------------------ reduced motion: a still, complete page */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

@media print {
  .intro, .film, .keylight, .cursor, .rail, .status, .menu, .cue, .lang, .lang-noscript { display: none !important; }
  html, body { background: #fff; color: #000; }
}

/* Public contact address (Contact chapter) */
.soon a.mail { color: var(--gold, #ffb000); text-decoration: underline; text-underline-offset: 3px; text-decoration-thickness: 1px; overflow-wrap: anywhere; }
.soon a.mail:hover, .soon a.mail:focus-visible { text-decoration-thickness: 2px; }

/* "Our paid apps" row */
.paid-apps { margin: 0 0 2rem; }
.paid-title, .more-tools { font-size: 1.1rem; font-weight: 600; margin: 0 0 .8rem; }
.paid-list { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: .8rem; }
.paid-link { display: flex; flex-direction: column; gap: .2rem; padding: .9rem 1rem; border: 1px solid currentColor; border-radius: 12px; text-decoration: none; color: inherit; }
.paid-link:hover, .paid-link:focus-visible { transform: translateY(-2px); }
.paid-note { font-size: .9rem; opacity: .8; }

/* Education chapter: short Recruitment paragraph with two links */
.edu-recruit { max-width: 44ch; margin: -1.5rem 0 2.5rem; }
.edu-recruit-title { font-family: var(--font-display); font-weight: 600; font-size: 1.1rem; color: var(--ink); margin-bottom: 0.4rem; }
.edu-recruit-text { font-weight: 300; color: var(--ink-2); line-height: 1.55; margin-bottom: 0.7rem; }
.edu-recruit-links a { font-weight: 700; color: var(--gold); text-decoration: underline; text-underline-offset: 3px; margin-right: 1.2rem; }
.edu-recruit-links a:hover { text-decoration-thickness: 2px; }
.edu-recruit-links a:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
@media (min-width: 900px) { .wrap > .edu-recruit { grid-column: 4 / 10; } }

/* ------------------------------------------------------------------ Home button (every page) and whole-box links */
.home-btn {
  display: inline-flex; align-items: center; gap: 0.45rem; min-height: 2.75rem; padding: 0 0.95rem; margin-left: 0.9rem;
  border: 1.5px solid var(--gold); border-radius: 999px; background: rgba(255, 176, 0, 0.12); color: var(--ink);
  font-size: 0.78rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; text-decoration: none; cursor: pointer;
  white-space: nowrap; flex: none;
  transition: background-color 0.2s, color 0.2s, transform 0.15s;
}
.home-btn .home-ico { flex: none; color: var(--gold); transition: color 0.2s; }
.home-btn:hover, .home-btn:focus-visible { background: var(--gold); color: #140b00; }
.home-btn:hover .home-ico, .home-btn:focus-visible .home-ico { color: #140b00; }
.home-btn:active { background: #e09a00; color: #140b00; }
.home-btn[aria-current="page"] { background: var(--gold); color: #140b00; }
.home-btn[aria-current="page"] .home-ico { color: #140b00; }
@media (max-width: 760px) {
  .home-btn { margin-left: 0.5rem; padding: 0 0.7rem; gap: 0.35rem; font-size: 0.72rem; letter-spacing: 0.04em; }
}
@media (max-width: 400px) {
  .home-btn { padding: 0 0.55rem; margin-left: 0.35rem; }
}

/* a box that is one big link: hover, pressed and keyboard-focus states; the focus ring is drawn inside so no parent clips it */
.family, .card-link, .door, .door-all, .paid-link { cursor: pointer; -webkit-tap-highlight-color: rgba(255, 176, 0, 0.25); }
.card-soon { cursor: default; }
.family:focus-visible, .card-link:focus-visible, .paid-link:focus-visible { outline: 3px solid var(--gold); outline-offset: -3px; }
.family:active, .card-link:not(.card-soon):active { background: rgba(19, 86, 214, 0.26); }
.card-link:not(.card-soon):active .card-arrow { transform: translateX(10px); }
.door:active { background: var(--tone); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.8); }
.door-all:active { background: #e09a00; color: #140b00; }
.paid-link { transition: transform 0.2s, background-color 0.2s; }
.paid-link:hover { background: rgba(19, 86, 214, 0.12); }
.paid-link:active { background: rgba(19, 86, 214, 0.26); }
/* two different actions in one box (Recruitment: teachers / schools) stay two separate buttons */
.edu-recruit-links { display: flex; flex-wrap: wrap; gap: 0.7rem; }
.edu-recruit-links a.btn-box {
  display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0 1.2rem; margin: 0;
  border: 1.5px solid var(--gold); border-radius: 999px; color: var(--ink); text-decoration: none; cursor: pointer;
  transition: background-color 0.2s, color 0.2s, transform 0.15s;
}
.edu-recruit-links a.btn-box:hover, .edu-recruit-links a.btn-box:focus-visible { background: var(--gold); color: #140b00; }
.edu-recruit-links a.btn-box:active { background: #e09a00; color: #140b00; }

/* ------------------------------------------------------------------ Software section (directly under the hero) */
.chapter-software { padding-top: clamp(3rem, 6vw, 5rem); }
.chips { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 0 0 2rem; }
.chip-btn {
  min-height: 2.5rem; padding: 0 1.1rem; border-radius: 999px; cursor: pointer; background: transparent; color: var(--ink);
  border: 1.5px solid rgba(242, 246, 255, 0.4); font: inherit; font-size: 0.85rem; font-weight: 600; letter-spacing: 0.04em;
}
.chip-btn:hover { border-color: var(--gold); }
.chip-btn[aria-pressed="true"] { background: var(--gold); border-color: var(--gold); color: #140b00; }
.chip-btn:focus-visible { outline: 3px solid #fff; outline-offset: 2px; }
.sw-group { margin: 0 0 2.5rem; scroll-margin-top: calc(var(--top-h) + var(--nav-h)); }
.sw-group[hidden] { display: none; }
.sw-title { margin-bottom: 1rem; }

/* the connection light lives in the top-right corner of the language bar (js/lang.js moves it there) */
.lang .status { position: absolute; right: calc(var(--gutter) - 10px); top: 0; height: 100%; }
.lang .status-btn { width: 36px; height: 36px; }
.lang .status-tip { top: calc(100% + 2px); }
@media (max-width: 1120px) { .flags { margin-right: 40px; } }
.lang .status-btn:focus-visible { outline-offset: -4px; }
.menu-btn { margin-left: auto; }

/* ---- text wrapping: no stray single-word last lines, no wrapped labels ---- */
h1, h2, h3, h4, h5, h6, .eyebrow, figcaption, summary { text-wrap: balance; }
p, li, dd, blockquote, td { text-wrap: pretty; overflow-wrap: break-word; }
.nav a, .menu a, .top a, .lang button, [class*="chip"], [class*="badge"], [class*="pill"], [role="tab"], th, label.field-label { white-space: nowrap; }
button, .btn, .hero-cta, a[class*="cta"] { text-wrap: balance; }
.lede, .card-for, .paid-note, .paid-link, .door, .door *, .line-in, .card-title, .card h3 { text-wrap: balance; }
@media (max-width: 380px) { .hero-cta { font-size: 0.9rem; padding-inline: 1rem; } }
footer a, .foot a, .legal a { text-wrap: balance; }
label { text-wrap: pretty; }

/* ---- phones: finger-sized tap targets (live-sites audit 2026-10-19); height only, layout unchanged ---- */
@media (max-width: 640px) {
  .menu-btn, .status-btn, .brand { min-height: 40px; }
  .brand, a.foot-link, .cards-more-link, .strip-link, a.mail { display: inline-flex; align-items: center; min-height: 40px; }
}

/* ------------------------------------------------------------------ themes: Dark (default, above), Light, Brite */
html[data-theme="light"] { --bg: #f4f7fc; --bg-2: #e8eef9; --ink: #0b1c2d; --ink-2: rgba(11, 28, 45, 0.80); --ink-3: rgba(11, 28, 45, 0.66); --line: rgba(11, 28, 45, 0.16); --gold: #8a5700; --ice: #0b5cad; --sky: #0b5cad; color-scheme: light; }
html[data-theme="brite"] { --bg: #012456; --bg-2: #01306e; --ink: #ffffff; --ink-2: #d9f6ff; --ink-3: #aee9ff; --line: rgba(0, 229, 255, 0.40); --gold: #ffee00; --ice: #00e5ff; --sky: #00e5ff; --blue: #0078d4; color-scheme: dark; }
html[data-theme="brite"] a:not(.btn):hover { color: #39ff88; }
html[data-theme="brite"] :focus-visible { outline-color: #ffee00; }
html[data-theme="light"] .top.scrolled, html[data-theme="light"] .top { background-color: var(--bg); }
html[data-theme="light"] .hero-glow, html[data-theme="light"] .logo-light, html[data-theme="light"] .flare-rig, html[data-theme="light"] .mini-light, html[data-theme="light"] .film, html[data-theme="light"] .keylight { display: none; }
/* electric blue glow on every button in the dark themes; Light keeps plain buttons */
html[data-theme="dark"] :is(button, .btn, .pr-btn, .hero-cta, .home-btn, .chip-btn, .menu-edu-btn, .nav-edu-btn),
html[data-theme="brite"] :is(button, .btn, .pr-btn, .hero-cta, .home-btn, .chip-btn, .menu-edu-btn, .nav-edu-btn) { box-shadow: 0 0 0 1px #2f80ff, 0 0 12px rgba(47, 128, 255, 0.75); }
html[data-theme="dark"] :is(button, .btn, .pr-btn, .hero-cta, .home-btn, .chip-btn, .menu-edu-btn, .nav-edu-btn):is(:hover, :focus-visible),
html[data-theme="brite"] :is(button, .btn, .pr-btn, .hero-cta, .home-btn, .chip-btn, .menu-edu-btn, .nav-edu-btn):is(:hover, :focus-visible) { box-shadow: 0 0 0 2px #5aa2ff, 0 0 24px rgba(70, 150, 255, 0.95); }

/* ------------------------------------------------------------------ the 27-years badge: one navy-disc version everywhere, light ring so it reads on dark */
.seal { background: #0b1c2d; border-radius: 50%; box-shadow: 0 0 0 1px rgba(255, 224, 138, 0.35); }
.seal-wrap, .top-seal, .foot-seal { color: #ffb000; }
html[data-theme="brite"] .seal { background: #001a44; box-shadow: 0 0 0 1px #00e5ff; }
