/* =====================================================================
   TriNetra Foundation · v2 stylesheet
   Type: Fraunces (display) + Manrope (text). Fluid scale via clamp().
   Palette: ink navy, ember saffron, sage. Light and dark themes.
   Breakpoints: 560 · 768 · 1024 · 1280 · 1600 (+ reduced-motion, print)
   ===================================================================== */

/* ---------- Tokens ---------- */
:root {
  --ink: #0c1424;
  --ink-2: #16213a;
  --ember: #e8892a;
  --ember-hi: #f6b25c;
  --ember-lo: #b8560f;
  --sage: #5f9a8c;
  --sage-soft: #dcece7;
  --paper: #f7f3ec;
  --paper-2: #efe9dd;
  --white: #ffffff;

  --bg: var(--paper);
  --surface: #fffdf9;
  --surface-2: var(--paper-2);
  --text: var(--ink);
  --muted: #56617a;
  --line: rgba(12,20,36,.12);
  --accent: var(--ember);
  --accent-ink: #9c4a0d;
  --on-accent: #1a1006;
  --night-bg: #0c1424;
  --night-text: #eef1f7;
  --night-muted: #a9b4c9;

  --shadow-1: 0 1px 2px rgba(12,20,36,.06), 0 6px 18px -10px rgba(12,20,36,.18);
  --shadow-2: 0 20px 50px -22px rgba(12,20,36,.35);
  --glass: rgba(255,253,249,.72);

  --r-sm: 12px;
  --r: 20px;
  --r-lg: 32px;
  --wrap: min(1220px, 100% - 2.75rem);
  --header-h: 74px;
  --ease: cubic-bezier(.16,.84,.24,1);
  --ease-soft: cubic-bezier(.4,0,.2,1);

  --f-display: "Fraunces", "Iowan Old Style", Georgia, serif;
  --f-text: "Manrope", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  font-size: 16px;
  color-scheme: light;
}

/* Dark theme: OS preference, unless user chose light explicitly */
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --dark-vars: 1; }
}
:root[data-theme="dark"], :root:not([data-theme="light"]):is(.__never__) { --dark-vars: 1; }

:root[data-theme="dark"] {
  --bg: #0a1120;
  --surface: #111b2e;
  --surface-2: #0e1729;
  --text: #eef1f7;
  --muted: #a9b4c9;
  --line: rgba(238,241,247,.12);
  --accent: var(--ember-hi);
  --accent-ink: #f6c27f;
  --shadow-1: 0 1px 2px rgba(0,0,0,.4);
  --shadow-2: 0 24px 60px -20px rgba(0,0,0,.75);
  --glass: rgba(17,27,46,.7);
  --sage-soft: rgba(95,154,140,.18);
  color-scheme: dark;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #0a1120;
    --surface: #111b2e;
    --surface-2: #0e1729;
    --text: #eef1f7;
    --muted: #a9b4c9;
    --line: rgba(238,241,247,.12);
    --accent: var(--ember-hi);
    --accent-ink: #f6c27f;
    --shadow-1: 0 1px 2px rgba(0,0,0,.4);
    --shadow-2: 0 24px 60px -20px rgba(0,0,0,.75);
    --glass: rgba(17,27,46,.7);
    --sage-soft: rgba(95,154,140,.18);
    color-scheme: dark;
  }
}

/* ---------- Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); -webkit-text-size-adjust: 100%; text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--f-text);
  font-size: clamp(.98rem, .94rem + .2vw, 1.06rem);
  line-height: 1.7;
  color: var(--text);
  background: var(--bg);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  transition: background-color .5s var(--ease-soft), color .5s var(--ease-soft);
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0 0 .5em; line-height: 1.08; font-weight: 500; letter-spacing: -.012em; }
h3 { font-family: var(--f-text); font-weight: 700; font-size: 1.12rem; letter-spacing: -.01em; }
p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }
em { font-family: var(--f-display); font-style: italic; font-weight: 400; color: var(--accent-ink); }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 8px; }

.skip-link { position: absolute; left: 1rem; top: -4rem; z-index: 300; padding: .65rem 1rem; border-radius: 10px; background: var(--accent); color: var(--on-accent); font-weight: 700; }
.skip-link:focus { top: 1rem; }

.container { width: var(--wrap); margin-inline: auto; }
.narrow { max-width: 860px; }
.center { text-align: center; margin-inline: auto; }
.center p { margin-inline: auto; }

.section { position: relative; padding-block: clamp(4.5rem, 3rem + 6vw, 9rem); }
.section-tint { background: var(--surface-2); }
.section-night { background: var(--night-bg); color: var(--night-text); overflow: hidden; }
.section-night::before {
  content: ""; position: absolute; inset: -20% -10% auto auto; width: 60vmax; height: 60vmax;
  background: radial-gradient(circle, rgba(232,137,42,.18), transparent 60%); pointer-events: none;
}
.section-night .eyebrow { color: var(--ember-hi); }
.section-night .section-head p { color: var(--night-muted); }
.section-night em { color: var(--ember-hi); }

.section-head { max-width: 760px; margin-bottom: clamp(2.5rem, 2rem + 3vw, 4.5rem); }
.section-head p { color: var(--muted); font-size: clamp(1rem, .95rem + .3vw, 1.12rem); }
.section-head.center { margin-inline: auto; }

.eyebrow {
  display: inline-flex; align-items: center; gap: .6rem; margin: 0 0 1.1rem;
  font-size: .74rem; font-weight: 800; letter-spacing: .18em; text-transform: uppercase; color: var(--accent-ink);
}
.eyebrow::before { content: ""; width: 26px; height: 2px; border-radius: 2px; background: currentColor; opacity: .7; }

.h2 {
  font-family: var(--f-display); font-weight: 400; font-variation-settings: "opsz" 120, "SOFT" 30;
  font-size: clamp(2.1rem, 1.3rem + 3vw, 3.9rem); line-height: 1.04; letter-spacing: -.02em; margin-bottom: .6em;
}

/* ---------- Buttons ---------- */
.btn {
  position: relative; isolation: isolate; overflow: hidden;
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
  min-height: 50px; padding: .8rem 1.5rem; border-radius: 999px; border: 1px solid transparent;
  font-weight: 700; font-size: .98rem; letter-spacing: .005em; cursor: pointer; white-space: nowrap;
  transition: transform .4s var(--ease), box-shadow .4s var(--ease), background-color .3s, color .3s, border-color .3s;
}
.btn svg { width: 18px; height: 18px; transition: transform .4s var(--ease); flex: 0 0 auto; }
.btn:hover svg { transform: translateX(4px); }
.btn::before {
  content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
  background: radial-gradient(circle at var(--bx, 50%) var(--by, 50%), rgba(255,255,255,.35), transparent 60%);
  opacity: 0; transition: opacity .3s;
}
.btn:hover::before { opacity: 1; }
.btn:active { transform: scale(.97); }
.btn-solid { background: linear-gradient(135deg, var(--ember-hi), var(--ember) 55%, #d8701a); color: #1a1006; box-shadow: 0 10px 26px -10px rgba(232,137,42,.75), inset 0 1px 0 rgba(255,255,255,.35); }
.btn-solid:hover { box-shadow: 0 18px 36px -12px rgba(232,137,42,.85), inset 0 1px 0 rgba(255,255,255,.35); transform: translateY(-2px); }
.btn-ghost { background: transparent; border-color: var(--line); color: var(--text); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent-ink); transform: translateY(-2px); }
.night .btn-ghost, .section-night .btn-ghost { border-color: rgba(238,241,247,.22); color: var(--night-text); }
.btn-lg { min-height: 56px; padding: .95rem 1.8rem; font-size: 1.02rem; }
.btn-sm { min-height: 42px; padding: .5rem 1.05rem; font-size: .9rem; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .65; cursor: progress; transform: none; }
.magnetic { will-change: transform; }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 100; height: var(--header-h); isolation: isolate;
}
.site-header::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: var(--glass);
  backdrop-filter: saturate(1.6) blur(18px); -webkit-backdrop-filter: saturate(1.6) blur(18px);
  border-bottom: 1px solid transparent; transition: border-color .4s;
}
.site-header.is-scrolled::before { border-bottom-color: var(--line); }
.header-inner { height: 100%; display: flex; align-items: center; gap: 1.25rem; }

.brand { display: inline-flex; align-items: center; gap: .7rem; color: var(--text); }
.brand-emblem { width: 40px; height: 40px; flex: 0 0 40px; transition: transform .8s var(--ease); }
.brand:hover .brand-emblem { transform: rotate(-30deg) scale(1.06); }
.brand-words { display: flex; flex-direction: column; line-height: 1; }
.brand-name { font-family: var(--f-display); font-size: 1.5rem; font-weight: 600; font-variation-settings: "opsz" 72; letter-spacing: -.01em; }
.brand-sub { font-size: .62rem; font-weight: 800; letter-spacing: .34em; text-transform: uppercase; color: var(--muted); margin-top: 5px; }
.brand-dark { color: #eef1f7; }
.brand-dark .brand-sub { color: #8d9ab3; }

.nav { margin-left: auto; display: flex; align-items: center; }
.nav-list { display: flex; gap: .15rem; padding: .3rem; border-radius: 999px; background: color-mix(in srgb, var(--surface) 70%, transparent); border: 1px solid var(--line); }
.nav-list a {
  position: relative; display: block; padding: .55rem .9rem; border-radius: 999px;
  font-size: .9rem; font-weight: 600; color: var(--muted); transition: color .25s, background-color .25s;
}
.nav-list a:hover { color: var(--text); background: color-mix(in srgb, var(--text) 6%, transparent); }
.nav-list a.is-active { color: var(--on-accent); background: var(--text); }
:root[data-theme="dark"] .nav-list a.is-active, :root[data-theme="dark"] .nav-list a.is-active { color: #0a1120; }
.nav-foot { display: none; }

.header-tools { display: flex; align-items: center; gap: .6rem; margin-left: 0; }
.header-cta { display: inline-flex; }

/* Theme switch */
.theme-btn { width: 56px; height: 32px; padding: 0; border: 0; background: none; cursor: pointer; border-radius: 999px; }
.theme-track {
  position: relative; display: block; width: 100%; height: 100%; border-radius: 999px;
  background: linear-gradient(90deg, #f5e6c8, #f6c27f); border: 1px solid var(--line);
  transition: background .5s var(--ease-soft);
}
.theme-knob {
  position: absolute; top: 3px; left: 3px; width: 24px; height: 24px; border-radius: 50%;
  background: var(--ink); box-shadow: 0 2px 8px rgba(0,0,0,.25);
  transition: transform .55s var(--ease), background .4s;
}
.theme-knob::after {
  content: ""; position: absolute; inset: 0; border-radius: 50%;
  background: radial-gradient(circle at 30% 30%, #fff3dc 0 3px, transparent 4px);
  opacity: .9;
}
:root[data-theme="dark"] .theme-track { background: linear-gradient(90deg, #1b2a47, #2c3f66); }
:root[data-theme="dark"] .theme-knob { transform: translateX(24px); background: #f6c27f; }
:root[data-theme="dark"] .theme-knob::after { display: none; }
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-track { background: linear-gradient(90deg, #1b2a47, #2c3f66); }
  :root:not([data-theme="light"]) .theme-knob { transform: translateX(24px); background: #f6c27f; }
  :root:not([data-theme="light"]) .theme-knob::after { display: none; }
}

.burger { position: relative; width: 46px; height: 46px; border-radius: 50%; border: 1px solid var(--line); background: var(--surface); cursor: pointer; display: grid; place-items: center; }
.burger span { position: absolute; left: 14px; right: 14px; height: 2px; border-radius: 2px; background: var(--text); transition: transform .45s var(--ease), opacity .25s, width .3s; }
.burger span:nth-child(1) { top: 17px; }
.burger span:nth-child(2) { top: 26px; width: 14px; margin-left: auto; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(4.5px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { transform: translateY(-4.5px) rotate(-45deg); width: 100%; }

.scroll-bar {
  position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; transform-origin: 0 50%; transform: scaleX(0);
  background: linear-gradient(90deg, var(--ember-hi), var(--ember), var(--sage));
}

.cursor-glow {
  position: fixed; left: 0; top: 0; width: 520px; height: 520px; margin: -260px 0 0 -260px; border-radius: 50%; pointer-events: none; z-index: 0;
  background: radial-gradient(circle, rgba(232,137,42,.13), transparent 62%); opacity: 0; transition: opacity .6s;
}
.cursor-glow.on { opacity: 1; }

/* ---------- Hero ---------- */
.hero {
  position: relative; isolation: isolate; overflow: hidden;
  min-height: min(100svh - var(--header-h), 980px);
  display: flex; align-items: center;
  padding-block: clamp(3rem, 2rem + 4vw, 6.5rem) clamp(4rem, 3rem + 3vw, 6rem);
}
.hero-aurora { position: absolute; inset: 0; z-index: -2; pointer-events: none; }
.hero-aurora span { position: absolute; border-radius: 50%; filter: blur(70px); will-change: transform; }
.hero-aurora span:nth-child(1) { width: 52vmax; height: 52vmax; top: -18vmax; right: -14vmax; background: radial-gradient(circle, rgba(246,178,92,.6), transparent 65%); animation: drift 18s ease-in-out infinite alternate; }
.hero-aurora span:nth-child(2) { width: 40vmax; height: 40vmax; bottom: -16vmax; left: -12vmax; background: radial-gradient(circle, rgba(95,154,140,.5), transparent 65%); animation: drift 22s ease-in-out infinite alternate-reverse; }
.hero-aurora span:nth-child(3) { width: 26vmax; height: 26vmax; top: 30%; left: 38%; background: radial-gradient(circle, rgba(22,33,58,.35), transparent 65%); animation: drift 26s ease-in-out infinite alternate; }
@keyframes drift { to { transform: translate3d(4vmax, -3vmax, 0) scale(1.1); } }
.hero-grain {
  position: absolute; inset: 0; z-index: -1; pointer-events: none; opacity: .35; mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.35'/%3E%3C/svg%3E");
}
:root[data-theme="dark"] .hero-grain { mix-blend-mode: screen; opacity: .12; }

.hero-grid { display: grid; gap: clamp(2.5rem, 2rem + 3vw, 4rem); align-items: center; grid-template-columns: 1fr; }
.kicker {
  display: inline-flex; align-items: center; gap: .6rem; margin: 0 0 1.6rem; padding: .5rem .95rem .5rem .6rem;
  border-radius: 999px; background: var(--glass); border: 1px solid var(--line); backdrop-filter: blur(8px);
  font-size: .82rem; font-weight: 600; color: var(--muted);
}
.kicker-dot { width: 10px; height: 10px; border-radius: 50%; background: var(--sage); box-shadow: 0 0 0 0 rgba(95,154,140,.6); animation: ping 2.4s infinite; }
@keyframes ping { 0% { box-shadow: 0 0 0 0 rgba(95,154,140,.55); } 80%,100% { box-shadow: 0 0 0 12px rgba(95,154,140,0); } }

.display {
  font-family: var(--f-display); font-weight: 350; font-variation-settings: "opsz" 144, "SOFT" 50;
  font-size: clamp(2.9rem, 1.3rem + 6.4vw, 6.6rem); line-height: .98; letter-spacing: -.035em; margin: 0 0 1.4rem;
}
.display .line { display: block; overflow: hidden; padding-bottom: .08em; }
.display .line > span { display: inline-block; transform: translateY(105%); animation: rise-line 1.1s var(--ease) forwards; }
.display .line:nth-child(2) > span { animation-delay: .12s; }
.display .line:nth-child(3) > span { animation-delay: .24s; }
@keyframes rise-line { to { transform: none; } }
.display em { color: var(--accent); font-variation-settings: "opsz" 144, "SOFT" 100; }

.lead { max-width: 52ch; font-size: clamp(1.05rem, 1rem + .35vw, 1.22rem); color: var(--muted); }
.hero-cta { display: flex; flex-wrap: wrap; gap: .8rem; margin-top: 2.2rem; }

/* Reveal helper */
.reveal { opacity: 0; transform: translateY(28px); filter: blur(6px); transition: opacity .9s var(--ease), transform .9s var(--ease), filter .9s var(--ease); transition-delay: calc(var(--i, 0) * 110ms); }
.reveal.in { opacity: 1; transform: none; filter: none; }

/* Emblem */
.emblem-stage { position: relative; display: grid; place-items: center; aspect-ratio: 1; width: min(100%, 520px); justify-self: center; }
.emblem { position: relative; width: 100%; height: 100%; }
.emblem-rings { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.emblem-rings .ring { fill: none; stroke: var(--accent); stroke-width: 1; stroke-dasharray: 4 10; opacity: .5; transform-origin: 200px 200px; }
.ring-a { animation: spin 60s linear infinite; }
.ring-b { stroke: var(--sage) !important; stroke-dasharray: 1 7 !important; animation: spin 44s linear infinite reverse; }
.ring-c { stroke-width: 1.5 !important; stroke-dasharray: 90 14 !important; animation: spin 30s linear infinite; }
.ring-ticks line { stroke: var(--text); stroke-width: 1.5; opacity: .35; }
@keyframes spin { to { transform: rotate(360deg); } }
.emblem-core { position: absolute; left: 22%; top: 22%; width: 56%; height: 56%; filter: drop-shadow(0 20px 40px rgba(232,137,42,.35)); }
.core-tri { stroke-dasharray: 260; stroke-dashoffset: 260; animation: draw-tri 2.2s var(--ease) .3s forwards; }
.core-eye { transform-origin: 100px 118px; animation: blink 5s ease-in-out 2.6s infinite; }
.core-beam { stroke-dasharray: 60; stroke-dashoffset: 60; animation: draw-tri 1.2s var(--ease) 1.6s forwards; }
@keyframes draw-tri { to { stroke-dashoffset: 0; } }
@keyframes blink { 0%,92%,100% { transform: scaleY(1); } 95% { transform: scaleY(.1); } }
.emblem-tag {
  position: absolute; padding: .5rem 1rem; border-radius: 999px; font-size: .8rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  background: var(--glass); border: 1px solid var(--line); box-shadow: var(--shadow-1); backdrop-filter: blur(10px); white-space: nowrap;
  animation: bob 6s ease-in-out infinite;
}
.tag-1 { top: 6%; left: -2%; }
.tag-2 { top: 46%; right: -6%; animation-delay: -2s; }
.tag-3 { bottom: 8%; left: 10%; animation-delay: -4s; }
@keyframes bob { 50% { transform: translateY(-10px); } }

.scroll-hint { position: absolute; left: 50%; bottom: 1.5rem; transform: translateX(-50%); }
.scroll-mouse { display: block; width: 26px; height: 42px; border-radius: 14px; border: 2px solid var(--muted); opacity: .6; position: relative; }
.scroll-mouse span { position: absolute; left: 50%; top: 7px; width: 4px; height: 8px; margin-left: -2px; border-radius: 4px; background: var(--accent); animation: wheel 1.9s var(--ease) infinite; }
@keyframes wheel { 0% { transform: translateY(0); opacity: 1; } 100% { transform: translateY(14px); opacity: 0; } }

/* ---------- Stats band ---------- */
.stats-band { position: relative; z-index: 1; margin-top: -1rem; }
.stats-grid {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px; overflow: hidden;
  background: var(--line); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-2);
}
.stat-item { background: var(--surface); padding: clamp(1.4rem, 1rem + 1.2vw, 2.2rem); display: flex; flex-direction: column; gap: .4rem; }
.stat-num { font-family: var(--f-display); font-weight: 400; font-variation-settings: "opsz" 144; font-size: clamp(2.6rem, 1.6rem + 3vw, 4.2rem); line-height: 1; letter-spacing: -.03em; font-variant-numeric: tabular-nums; }
.stat-word { font-size: clamp(2rem, 1.2rem + 2.4vw, 3.2rem); color: var(--accent-ink); font-style: italic; }
.stat-label { font-size: .88rem; color: var(--muted); font-weight: 600; }

/* ---------- About ---------- */
.about-grid { display: grid; gap: clamp(2.5rem, 2rem + 3vw, 5rem); grid-template-columns: 1fr; }
.about-body p { font-size: clamp(1.02rem, .98rem + .25vw, 1.15rem); color: var(--muted); max-width: 62ch; }
.about-body > p:first-child { color: var(--text); font-size: clamp(1.1rem, 1rem + .45vw, 1.3rem); }
.pillars { display: grid; gap: 1rem; margin-top: 2.2rem; grid-template-columns: 1fr; }
.pillar {
  position: relative; padding: clamp(1.4rem, 1.1rem + .8vw, 2rem); border-radius: var(--r);
  background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1);
  transform-style: preserve-3d; will-change: transform;
}
.pillar::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  background: radial-gradient(420px circle at var(--mx, 50%) var(--my, 50%), rgba(232,137,42,.14), transparent 45%);
  opacity: 0; transition: opacity .4s;
}
.pillar:hover::after { opacity: 1; }
.pillar h3 { font-family: var(--f-display); font-weight: 500; font-size: 1.55rem; font-variation-settings: "opsz" 48; margin-bottom: .4rem; }
.pillar p { color: var(--muted); margin: 0; font-size: .97rem; }
.tags { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: .3rem; }
.tags li { padding: .4rem .85rem; border-radius: 999px; background: var(--sage-soft); color: color-mix(in srgb, var(--sage) 70%, var(--text)); font-size: .85rem; font-weight: 700; }

/* ---------- Marquee ---------- */
.marquee { overflow: hidden; background: var(--ink); color: #eef1f7; padding: 1.2rem 0; }
.marquee-track { display: flex; width: max-content; animation: scroll-x 46s linear infinite; }
.marquee-track span {
  display: inline-flex; align-items: center; gap: 2.2rem; padding-right: 2.2rem; white-space: nowrap;
  font-family: var(--f-display); font-style: italic; font-size: clamp(1.25rem, 1rem + 1vw, 1.9rem); font-weight: 300; font-variation-settings: "opsz" 72;
}
.marquee-track span::after { content: "✦"; color: var(--ember-hi); font-style: normal; font-size: .7em; }
.marquee:hover .marquee-track { animation-play-state: paused; }
@keyframes scroll-x { to { transform: translateX(-50%); } }

/* ---------- Filters & Bento ---------- */
.filters {
  position: relative; display: inline-flex; flex-wrap: wrap; gap: .3rem; padding: .3rem; margin-bottom: 2.4rem; max-width: 100%;
  border-radius: 999px; background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1);
}
.filter { position: relative; z-index: 1; padding: .6rem 1.1rem; border: 0; border-radius: 999px; background: none; cursor: pointer; font-weight: 700; font-size: .9rem; color: var(--muted); transition: color .3s; }
.filter:hover { color: var(--text); }
.filter.is-on { color: var(--on-accent); }
:root[data-theme="dark"] .filter.is-on { color: #0a1120; }
.filter-thumb { position: absolute; z-index: 0; top: .3rem; bottom: .3rem; left: 0; width: 0; border-radius: 999px; background: linear-gradient(135deg, var(--ember-hi), var(--ember)); transition: transform .55s var(--ease), width .55s var(--ease); }

.bento {
  display: grid; gap: 1rem; grid-template-columns: 1fr; grid-auto-flow: dense;
}
.obj {
  position: relative; text-align: left; cursor: pointer; border: 1px solid var(--line); border-radius: var(--r);
  background: var(--surface); padding: clamp(1.4rem, 1.1rem + .8vw, 2rem); display: flex; flex-direction: column; gap: .5rem;
  min-height: 210px; overflow: hidden; isolation: isolate; box-shadow: var(--shadow-1);
  transition: transform .5s var(--ease), box-shadow .5s var(--ease), border-color .4s, opacity .45s var(--ease), scale .45s var(--ease);
  transform-style: preserve-3d;
}
.obj::before {
  content: ""; position: absolute; inset: 0; z-index: -1;
  background: radial-gradient(360px circle at var(--mx, 60%) var(--my, 0%), rgba(232,137,42,.2), transparent 55%);
  opacity: 0; transition: opacity .4s;
}
.obj:hover::before, .obj:focus-visible::before { opacity: 1; }
.obj:hover { box-shadow: var(--shadow-2); border-color: color-mix(in srgb, var(--accent) 50%, var(--line)); }
.obj:focus-visible { outline: 3px solid var(--accent); outline-offset: 4px; }
.obj.is-out { display: none; }
.obj.is-in { animation: pop-in .6s var(--ease) both; }
@keyframes pop-in { from { opacity: 0; transform: translateY(14px) scale(.97); } to { opacity: 1; transform: none; } }
.obj-no { font-family: var(--f-display); font-style: italic; font-size: 1.05rem; color: var(--accent-ink); font-variation-settings: "opsz" 24; }
.obj h3 { font-family: var(--f-display); font-weight: 500; font-size: clamp(1.4rem, 1.1rem + .6vw, 1.75rem); line-height: 1.1; font-variation-settings: "opsz" 72; margin: 0; }
.obj p { color: var(--muted); font-size: .95rem; margin: 0; }
.obj-open { margin-top: auto; padding-top: 1rem; display: inline-flex; align-items: center; gap: .4rem; font-weight: 800; font-size: .85rem; letter-spacing: .04em; color: var(--accent-ink); }
.obj-open svg { width: 18px; height: 18px; transition: transform .4s var(--ease); }
.obj:hover .obj-open svg { transform: translateX(5px); }
.obj-wide { grid-column: span 1; }
.obj-tall { min-height: 320px; }

/* ---------- Approach / timeline ---------- */
.approach-grid { display: grid; gap: clamp(3rem, 2rem + 3vw, 5rem); grid-template-columns: 1fr; }
.approach-sticky { align-self: start; }
.approach-sticky p:not(.eyebrow) { color: var(--muted); font-size: 1.05rem; }
.timeline { position: relative; display: grid; gap: 1rem; padding-left: 0; }
.tl-line { position: absolute; left: 23px; top: 30px; bottom: 30px; width: 2px; background: var(--line); border-radius: 2px; overflow: hidden; }
.tl-fill { position: absolute; inset: 0; background: linear-gradient(var(--ember-hi), var(--sage)); transform: scaleY(0); transform-origin: top; transition: transform .25s linear; }
.tl-step { position: relative; display: grid; grid-template-columns: 48px 1fr; gap: 1.1rem; align-items: start; }
.tl-dot {
  position: relative; z-index: 1; width: 48px; height: 48px; border-radius: 50%; display: grid; place-items: center;
  background: var(--surface); border: 2px solid var(--line); transition: border-color .5s, background .5s, transform .5s var(--ease);
}
.tl-dot span { font-family: var(--f-display); font-size: 1.15rem; font-weight: 600; font-variation-settings: "opsz" 48; }
.tl-step.is-active .tl-dot { border-color: var(--ember); background: var(--ember); color: #1a1006; transform: scale(1.08); box-shadow: 0 10px 24px -8px rgba(232,137,42,.7); }
.tl-card { padding: clamp(1.3rem, 1rem + .8vw, 1.9rem); border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); box-shadow: var(--shadow-1); transition: transform .5s var(--ease), border-color .4s; }
.tl-step.is-active .tl-card { transform: translateX(6px); border-color: color-mix(in srgb, var(--ember) 45%, var(--line)); }
.tl-card h3 { font-family: var(--f-display); font-weight: 500; font-size: 1.6rem; font-variation-settings: "opsz" 48; }
.tl-card p { margin: 0; color: var(--muted); font-size: .97rem; }

/* ---------- Principles ---------- */
.principles { display: grid; gap: 1px; grid-template-columns: 1fr; background: rgba(238,241,247,.1); border-radius: var(--r-lg); overflow: hidden; border: 1px solid rgba(238,241,247,.1); }
.principle { position: relative; background: var(--night-bg); padding: clamp(1.6rem, 1.2rem + 1vw, 2.4rem); transition: background .5s; }
.principle:hover { background: #121d33; }
.p-icon {
  display: grid; place-items: center; width: 56px; height: 56px; border-radius: 18px; margin-bottom: 1.4rem;
  background: linear-gradient(145deg, rgba(246,178,92,.22), rgba(232,137,42,.05)); border: 1px solid rgba(246,178,92,.3);
  color: var(--ember-hi); font-size: 1.4rem; transition: transform .6s var(--ease);
}
.principle:hover .p-icon { transform: rotate(-12deg) scale(1.08); }
.principle h3 { color: #fff; font-family: var(--f-display); font-weight: 500; font-size: 1.6rem; font-variation-settings: "opsz" 48; }
.principle p { color: var(--night-muted); margin: 0; font-size: .97rem; }

/* ---------- Get involved ---------- */
.involve-card {
  position: relative; max-width: 900px; margin-inline: auto; padding: clamp(1.25rem, 1rem + 1.6vw, 2.8rem);
  background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-2);
}
.segmented { position: relative; display: flex; gap: .25rem; padding: .3rem; margin-bottom: 2rem; border-radius: 999px; background: var(--surface-2); overflow-x: auto; scrollbar-width: none; }
.segmented::-webkit-scrollbar { display: none; }
.seg { position: relative; z-index: 1; flex: 1 0 auto; padding: .8rem 1.2rem; border: 0; border-radius: 999px; background: none; cursor: pointer; font-weight: 700; color: var(--muted); white-space: nowrap; transition: color .35s; }
.seg.is-on { color: var(--on-accent); }
:root[data-theme="dark"] .seg.is-on { color: #0a1120; }
.seg-thumb { position: absolute; z-index: 0; top: .3rem; bottom: .3rem; left: 0; width: 0; border-radius: 999px; background: linear-gradient(135deg, var(--ember-hi), var(--ember)); transition: transform .55s var(--ease), width .55s var(--ease); }

.form { display: grid; gap: 1.1rem; animation: form-in .6s var(--ease); }
@keyframes form-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.form-head h3 { font-family: var(--f-display); font-weight: 500; font-size: 1.8rem; font-variation-settings: "opsz" 60; margin-bottom: .2rem; }
.form-head p { color: var(--muted); margin: 0; }
.fields-2 { display: grid; gap: 1.1rem; grid-template-columns: 1fr; }
.field { display: grid; gap: .45rem; min-width: 0; }
.field-label { font-size: .85rem; font-weight: 700; color: var(--text); }
.field-label em { font-style: normal; font-weight: 500; color: var(--muted); }
.field input, .field select, .field textarea {
  width: 100%; padding: .95rem 1.05rem; border-radius: var(--r-sm); border: 1.5px solid var(--line);
  background: var(--bg); color: var(--text); transition: border-color .3s, box-shadow .3s, background .3s;
  appearance: none; -webkit-appearance: none;
}
.field select { background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%); background-position: calc(100% - 20px) 55%, calc(100% - 14px) 55%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 2.4rem; }
.field textarea { resize: vertical; min-height: 110px; }
.field input::placeholder, .field textarea::placeholder { color: color-mix(in srgb, var(--muted) 70%, transparent); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 5px color-mix(in srgb, var(--accent) 22%, transparent); }
.field.invalid input, .field.invalid select, .field.invalid textarea { border-color: #d24b3e; box-shadow: 0 0 0 4px rgba(210,75,62,.14); }
.err { min-height: 0; font-size: .83rem; color: #d24b3e; font-weight: 600; }
.err:empty { display: none; }

.amounts { border: 0; margin: 0; padding: 0; display: grid; gap: .6rem; grid-template-columns: repeat(2, 1fr); }
.amounts legend { margin-bottom: .45rem; padding: 0; }
.amounts label { position: relative; }
.amounts input { position: absolute; opacity: 0; width: 1px; height: 1px; pointer-events: none; }
.amounts span {
  display: grid; place-items: center; min-height: 58px; border-radius: var(--r-sm); border: 1.5px solid var(--line); background: var(--bg);
  font-weight: 800; font-size: 1.05rem; cursor: pointer; transition: transform .4s var(--ease), background .3s, border-color .3s, color .3s, box-shadow .3s;
}
.amounts label:hover span { border-color: var(--accent); transform: translateY(-2px); }
.amounts input:checked + span { background: linear-gradient(135deg, var(--ember-hi), var(--ember)); border-color: transparent; color: #1a1006; box-shadow: 0 10px 24px -10px rgba(232,137,42,.8); transform: translateY(-2px) scale(1.02); }
.amounts input:focus-visible + span { outline: 3px solid var(--accent); outline-offset: 3px; }
@media (min-width: 640px) { .amounts { grid-template-columns: repeat(4, 1fr); } }
.fine { font-size: .85rem; color: var(--muted); margin: 0; }

/* Success state */
.done { text-align: center; padding: clamp(2rem, 1.5rem + 2vw, 3.5rem) 1rem; animation: form-in .7s var(--ease); }
.done-badge { width: 84px; height: 84px; margin: 0 auto 1.2rem; color: var(--sage); }
.done-badge svg { width: 100%; height: 100%; fill: none; stroke: currentColor; stroke-width: 2.4; stroke-linecap: round; stroke-linejoin: round; }
.done-badge circle { stroke-dasharray: 180; stroke-dashoffset: 180; animation: draw-circle .9s var(--ease) forwards; }
.done-badge path { stroke-dasharray: 40; stroke-dashoffset: 40; animation: draw-circle .6s var(--ease) .7s forwards; }
@keyframes draw-circle { to { stroke-dashoffset: 0; } }
.done h3 { font-family: var(--f-display); font-weight: 500; font-size: 2rem; }
.done p { color: var(--muted); max-width: 42ch; margin: 0 auto 1.5rem; }

/* ---------- FAQ ---------- */
.faq { display: grid; gap: .8rem; }
.faq details { background: var(--surface); border: 1px solid var(--line); border-radius: var(--r); padding: 0 1.5rem; transition: border-color .4s, box-shadow .4s, background .4s; }
.faq details[open] { border-color: color-mix(in srgb, var(--accent) 45%, var(--line)); box-shadow: var(--shadow-1); }
.faq summary { list-style: none; cursor: pointer; padding: 1.3rem 3rem 1.3rem 0; font-family: var(--f-display); font-size: clamp(1.15rem, 1rem + .4vw, 1.4rem); font-weight: 500; font-variation-settings: "opsz" 48; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: ""; position: absolute; right: .2rem; top: 50%; width: 14px; height: 14px; margin-top: -7px;
  background: linear-gradient(var(--accent), var(--accent)) center / 100% 2px no-repeat, linear-gradient(var(--accent), var(--accent)) center / 2px 100% no-repeat;
  transition: transform .5s var(--ease);
}
.faq details[open] summary::after { transform: rotate(135deg); }
.faq details p { color: var(--muted); margin: 0; padding-bottom: 1.4rem; max-width: 66ch; animation: form-in .5s var(--ease); }

/* ---------- Contact ---------- */
.contact-grid { display: grid; gap: clamp(2.5rem, 2rem + 3vw, 5rem); grid-template-columns: 1fr; align-items: start; }
.contact-info > p:not(.eyebrow) { color: var(--muted); font-size: 1.05rem; }
.contact-list { display: grid; gap: 1.1rem; margin-top: 2rem; }
.contact-list li { display: flex; gap: 1rem; align-items: center; padding: 1rem 1.1rem; border-radius: var(--r); background: var(--surface); border: 1px solid var(--line); transition: transform .4s var(--ease), border-color .4s; }
.contact-list li:hover { transform: translateX(6px); border-color: color-mix(in srgb, var(--accent) 40%, var(--line)); }
.contact-list strong { display: block; font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted); font-weight: 800; }
.contact-list span, .contact-list a { font-weight: 600; font-size: 1.02rem; }
.contact-list a:hover { color: var(--accent-ink); }
.c-ico { display: grid; place-items: center; flex: 0 0 46px; width: 46px; height: 46px; border-radius: 14px; background: var(--sage-soft); color: var(--sage); font-size: 1.1rem; }
.contact-form { display: grid; gap: 1.1rem; padding: clamp(1.4rem, 1rem + 1.4vw, 2.6rem); background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-lg); box-shadow: var(--shadow-2); }

/* ---------- Dialog ---------- */
.obj-dialog {
  width: min(560px, calc(100% - 2rem)); padding: 0; border: 1px solid var(--line); border-radius: var(--r-lg);
  background: var(--surface); color: var(--text); box-shadow: 0 40px 80px -20px rgba(0,0,0,.5);
}
.obj-dialog::backdrop { background: rgba(7,12,24,.55); backdrop-filter: blur(6px); animation: fade .3s; }
.obj-dialog[open] .dlg-inner { animation: dlg-in .5s var(--ease); }
@keyframes dlg-in { from { opacity: 0; transform: translateY(18px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes fade { from { opacity: 0; } }
.dlg-inner { position: relative; padding: clamp(1.6rem, 1.2rem + 1.4vw, 2.6rem); }
.dlg-close { position: absolute; top: 1rem; right: 1rem; width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: var(--bg); cursor: pointer; display: grid; place-items: center; color: var(--text); transition: transform .4s var(--ease); }
.dlg-close:hover { transform: rotate(90deg); }
.dlg-close svg { width: 18px; height: 18px; }
.dlg-inner h3 { font-family: var(--f-display); font-weight: 500; font-size: clamp(1.7rem, 1.2rem + 1.4vw, 2.3rem); font-variation-settings: "opsz" 96; line-height: 1.08; margin: .2rem 0 1.2rem; padding-right: 2.5rem; }
.dlg-points { display: grid; gap: .65rem; margin-bottom: 1.8rem; }
.dlg-points li { position: relative; padding-left: 1.6rem; color: var(--muted); }
.dlg-points li::before { content: ""; position: absolute; left: 0; top: .6em; width: 10px; height: 10px; border-radius: 3px; background: linear-gradient(135deg, var(--ember-hi), var(--ember)); transform: rotate(45deg); }

/* ---------- Footer ---------- */
.footer { background: var(--ink); color: #aab5ca; padding-top: clamp(4rem, 3rem + 3vw, 6rem); position: relative; overflow: hidden; }
.footer::before { content: ""; position: absolute; left: 50%; top: -40%; width: 90vmax; height: 90vmax; transform: translateX(-50%); background: radial-gradient(circle, rgba(232,137,42,.12), transparent 60%); pointer-events: none; }
.footer-top { position: relative; display: grid; gap: 2.5rem; grid-template-columns: 1fr; padding-bottom: 3rem; }
.footer-brand p { margin: 1.2rem 0 0; max-width: 38ch; font-size: .95rem; }
.footer-col { display: grid; gap: .7rem; align-content: start; }
.footer-col h4 { color: #fff; font-size: .75rem; letter-spacing: .18em; text-transform: uppercase; margin-bottom: .4rem; font-weight: 800; }
.footer-col a { font-size: .95rem; transition: color .25s, transform .3s var(--ease); width: fit-content; }
.footer-col a:hover { color: var(--ember-hi); transform: translateX(4px); }
.footer-bottom { position: relative; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem; padding-block: 1.5rem; border-top: 1px solid rgba(238,241,247,.09); font-size: .88rem; }
.to-top { font-weight: 700; color: #eef1f7; }
.to-top:hover { color: var(--ember-hi); }

/* ---------- Motion: enhancements for fine pointers ---------- */
@media (hover: hover) and (pointer: fine) {
  .cursor-glow { display: block; }
}
@media not all and (hover: hover) and (pointer: fine) {
  .cursor-glow { display: none; }
}

/* ---------- Breakpoints ---------- */

/* ≥ 560px: two-column micro layouts */
@media (min-width: 560px) {
  .fields-2 { grid-template-columns: 1fr 1fr; }
  .pillars { grid-template-columns: 1fr 1fr; }
  .pillars .pillar:last-child { grid-column: 1 / -1; }
  .stats-grid { grid-template-columns: repeat(4, 1fr); }
}

/* ≥ 768px: tablet */
@media (min-width: 768px) {
  .bento { grid-template-columns: repeat(2, 1fr); }
  .obj-wide { grid-column: span 2; }
  .obj-tall { grid-row: span 2; min-height: 0; }
  .principles { grid-template-columns: 1fr 1fr; }
  .footer-top { grid-template-columns: 2fr 1fr 1fr; }
  .stat-item:nth-child(n) { padding: clamp(1.4rem, 1.2rem + 1vw, 2.2rem); }
  .involve-card .field-label { font-size: .88rem; }
}

/* ≥ 900px: split layouts */
@media (min-width: 900px) {
  .about-grid { grid-template-columns: .9fr 1.1fr; }
  .about-intro { position: sticky; top: calc(var(--header-h) + 2rem); align-self: start; }
  .approach-grid { grid-template-columns: .85fr 1.15fr; }
  .approach-sticky { position: sticky; top: calc(var(--header-h) + 3rem); }
  .contact-grid { grid-template-columns: .9fr 1.1fr; }
  .hero-grid { grid-template-columns: 1.1fr .9fr; }
}

/* ≥ 1024px: full desktop nav pill */
@media (min-width: 1024px) {
  .nav { display: flex; }
  .burger { display: none; }
  .header-cta { display: inline-flex; }
  .nav-foot { display: none; }
}

/* 768–1023: keep nav in a drawer. Under 1024: drawer behaviour */
@media (max-width: 1023px) {
  .nav {
    position: fixed; top: var(--header-h); left: 0; right: 0; bottom: 0; z-index: 90; flex-direction: column; align-items: stretch;
    padding: 1.2rem 1.25rem 2rem; gap: 1.2rem; overflow-y: auto;
    background: var(--bg); transform: translateY(-10px); opacity: 0; visibility: hidden;
    transition: transform .5s var(--ease), opacity .35s, visibility .5s;
  }
  .nav.is-open { transform: none; opacity: 1; visibility: visible; }
  .nav-list { flex-direction: column; border-radius: var(--r); padding: .4rem; gap: 0; background: var(--surface); }
  .nav-list a { font-size: 1.1rem; padding: 1rem 1.1rem; border-radius: 12px; color: var(--text); }
  .nav-list a.is-active { color: var(--on-accent); }
  .nav-list li:not(:last-child) a { border-bottom: 1px solid var(--line); border-radius: 0; }
  .nav-foot { display: grid; gap: .7rem; grid-template-columns: 1fr 1fr; margin-top: auto; }
  .nav-foot .btn { min-height: 54px; }
  .burger { display: grid; }
  .header-cta { display: none; }
}

/* ≥ 1024: 4-col bento */
@media (min-width: 1024px) {
  .bento { grid-template-columns: repeat(4, 1fr); }
  .obj-wide { grid-column: span 2; }
  .obj-tall { grid-row: span 2; min-height: 0; }
  .principles { grid-template-columns: repeat(3, 1fr); }
  .pillars { grid-template-columns: repeat(3, 1fr); }
  .pillars .pillar:last-child { grid-column: auto; }
  .stat-item { padding: 2.2rem 2rem; }
}

/* ≥ 1280: spacious */
@media (min-width: 1280px) {
  .display { font-size: clamp(4rem, 2rem + 5.4vw, 7.8rem); }
  .emblem-stage { width: min(100%, 580px); }
}

/* ≥ 1600: very large screens */
@media (min-width: 1600px) {
  :root { font-size: 17px; --wrap: min(1400px, 100% - 3rem); }
}

/* ≤ 380px: small phones */
@media (max-width: 380px) {
  .brand-sub { display: none; }
  .nav-foot { grid-template-columns: 1fr; }
  .hero-cta .btn { width: 100%; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .stat-num { font-size: 2.3rem; }
  .emblem-tag { font-size: .7rem; padding: .4rem .7rem; }
  .amounts { grid-template-columns: 1fr 1fr; }
}

/* Landscape phones: keep hero compact */
@media (max-height: 520px) and (orientation: landscape) {
  .hero { min-height: auto; }
  .emblem-stage { width: min(60vw, 300px); }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; scroll-behavior: auto !important; }
  .marquee-track, .emblem-rings .ring, .hero-aurora span { animation: none !important; }
  .reveal { opacity: 1; transform: none; filter: none; }
  .display .line > span { transform: none; }
  .core-tri, .core-beam, .done-badge circle, .done-badge path { stroke-dashoffset: 0; }
}

/* ---------- Print ---------- */
@media print {
  .site-header, .marquee, .hero-aurora, .hero-grain, .scroll-hint, .involve, .contact-form, .theme-btn, .footer, .cursor-glow, .obj-dialog { display: none !important; }
  .reveal { opacity: 1 !important; transform: none !important; filter: none !important; }
  body { background: #fff; color: #000; }
  .section-night { background: #fff; color: #000; }
  .principles { background: none; }
  .principle { background: #fff; }
  .principle h3, .section-night .section-head p, .principle p { color: #000; }
}
