/* ============================================================
   Vitagri — The Bi-Directional Predictive Model
   Redesign. Editorial restraint for content, drama for the engine.
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--cream-paper);
  color: var(--charcoal);
  font-family: var(--font-sans);
  overflow-x: hidden;
}
img { max-width: 100%; display: block; }
a { color: inherit; }

/* deep night surface used by hero + engine */
:root {
  --night: #11201A;          /* deeper than forest-ink for the engine well */
  --night-2: #0B1611;
  --field: #2A4A37;          /* farm/soil green world */
  --field-bright: #6B8A5A;
  --field-lime: #9FB04F;
  --biology: #8B2783;        /* food/biology berry world */
  --biology-bright: #C2398C;
  --seam: #B8762A;           /* the model core / ochre seam */
  --seam-glow: #E9A84C;
  --line-dim: rgba(246,242,233,0.12);
  --ink-on-dark: rgba(246,242,233,0.92);
  --ink-on-dark-soft: rgba(246,242,233,0.6);
  --ink-on-dark-faint: rgba(246,242,233,0.4);

  /* Base tokens this page needs that styles.css doesn't define.
     (Everything else — creams, forest-ink, ochre, fonts, --max-w,
     --section-pad, --radius/-sm, shadows, --lime-bright, --moss — comes
     from styles.css, which loads first.) */
  --vitagri-teal: #2A9D8F;             /* hero kicker pulse dot */
  --border-line:  rgba(31,58,43,0.09); /* cream-section card borders */
  --radius-btn:   2px;                 /* editorial sharp button radius */
  --radius-pill:  999px;
  --h2-size:      clamp(1.9rem, 3.5vw, 2.8rem);
  --tier-4:       #9BA4B0;             /* gearbox <60% gate row */
}

.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 32px; }
.wrap--wide { max-width: 1320px; }

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ochre);
  margin: 0;
}
.eyebrow--dim { color: var(--ink-on-dark-faint); }

/* ============================================================
   TOP BAR
   ============================================================ */
.topbar {
  position: sticky; top: 0; z-index: 60;
  background: rgba(17,32,26,0.86);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--line-dim);
}
.topbar__in {
  max-width: 1320px; margin: 0 auto; padding: 14px 32px;
  display: flex; align-items: center; gap: 28px;
}
.topbar__logo { height: 26px; width: auto; }
.topbar__crumb {
  font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.16em;
  text-transform: uppercase; color: var(--ink-on-dark-faint);
  margin-left: 4px;
}
.topbar__spacer { flex: 1; }
.topbar__switch {
  display: flex; align-items: center; gap: 0;
  border: 1px solid var(--line-dim); border-radius: var(--radius-pill);
  padding: 3px; background: rgba(0,0,0,0.25);
}
.topbar__switch button {
  font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--ink-on-dark-soft);
  background: none; border: none; padding: 7px 14px; cursor: pointer;
  border-radius: var(--radius-pill); transition: all .25s ease; white-space: nowrap;
}
.topbar__switch button.is-active { background: var(--ochre); color: #fff; }
.topbar__cta {
  font-family: var(--font-sans); font-size: 0.72rem; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase; text-decoration: none;
  color: var(--night); background: var(--ink-on-dark); padding: 10px 18px;
  border-radius: var(--radius-btn);
}
@media (max-width: 880px){ .topbar__crumb, .topbar__cta { display:none; } }

/* ============================================================
   BUTTONS
   ============================================================ */
.btn {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 15px 28px; border-radius: var(--radius-btn);
  font-family: var(--font-sans); font-size: 0.8rem; font-weight: 700;
  letter-spacing: 0.07em; text-transform: uppercase; text-decoration: none;
  border: 1px solid transparent; cursor: pointer; transition: all .2s ease;
}
.btn svg { width: 15px; height: 15px; }
.btn--accent { background: var(--ochre); color: #fff; border-color: var(--ochre); }
.btn--accent:hover { background: var(--ochre-light); border-color: var(--ochre-light); }
.btn--ghost-dark { background: transparent; color: var(--ink-on-dark); border-color: rgba(246,242,233,0.4); }
.btn--ghost-dark:hover { border-color: var(--ink-on-dark); background: rgba(246,242,233,0.06); }
.btn--primary { background: var(--forest-ink); color: var(--cream-paper); border-color: var(--forest-ink); }
.btn--primary:hover { background: #16291F; }
.btn--outline { background: transparent; color: var(--forest-ink); border-color: rgba(31,58,43,0.4); }
.btn--outline:hover { border-color: var(--forest-ink); }

/* ============================================================
   HERO  (shared shell; per-direction skins below)
   ============================================================ */
.hero {
  position: relative; overflow: hidden;
  background: var(--night); color: var(--ink-on-dark);
  border-bottom: 3px solid var(--ochre);
}
.hero__grid {
  position: relative; z-index: 3;
  display: grid; gap: 40px; align-items: center;
  padding: 92px 0 84px;
}
.hero__kicker { display: flex; align-items: center; gap: 14px; margin-bottom: 26px; }
.hero__kicker .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--vitagri-teal); box-shadow: 0 0 0 0 rgba(42,157,143,.6); animation: pulse 2.6s infinite; }
@keyframes pulse { 0%{box-shadow:0 0 0 0 rgba(42,157,143,.5);} 70%{box-shadow:0 0 0 9px rgba(42,157,143,0);} 100%{box-shadow:0 0 0 0 rgba(42,157,143,0);} }
.hero h1 {
  font-family: var(--font-serif); font-weight: 300;
  font-size: clamp(2.8rem, 6.4vw, 5.4rem); line-height: 1.02;
  letter-spacing: -0.025em; color: var(--cream-paper); margin: 0 0 26px;
}
.hero h1 em { font-style: italic; color: var(--seam-glow); font-weight: 300; }
.hero__lead {
  font-family: var(--font-serif); font-weight: 300; font-style: italic;
  font-size: clamp(1.15rem, 1.7vw, 1.42rem); line-height: 1.5;
  color: var(--ink-on-dark-soft); max-width: 46ch; margin: 0 0 34px;
}
.hero__lead b { color: var(--cream-paper); font-style: normal; font-weight: 400; }
.hero__actions { display: flex; gap: 14px; flex-wrap: wrap; }
.hero__readout {
  display: flex; gap: 30px; flex-wrap: wrap; margin-top: 44px;
  padding-top: 22px; border-top: 1px solid var(--line-dim);
  font-family: var(--font-mono); font-size: 0.64rem; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--ink-on-dark-faint);
}
.hero__readout b { display: block; color: var(--cream-paper); font-weight: 400; font-size: 0.82rem; letter-spacing: 0.04em; margin-top: 5px; }

/* ---- Direction A hero: the instrument ---- */
.heroA__viz { position: absolute; inset: 0; z-index: 1; }
.heroA__grid-lines { position: absolute; inset: 0; opacity: 0.5;
  background-image: linear-gradient(var(--line-dim) 1px, transparent 1px), linear-gradient(90deg, var(--line-dim) 1px, transparent 1px);
  background-size: 56px 56px; mask-image: radial-gradient(ellipse 80% 75% at 50% 40%, #000 30%, transparent 78%); }
.heroA__field, .heroA__food {
  position: absolute; top: 0; bottom: 0; width: 30%;
  pointer-events: none;
}
.heroA__field { left: 0; background: linear-gradient(90deg, rgba(42,74,55,0.55), transparent); }
.heroA__food  { right: 0; background: linear-gradient(270deg, rgba(139,39,131,0.42), transparent); }
.heroA__edge-label {
  position: absolute; top: 50%; font-family: var(--font-mono); font-size: 0.6rem;
  letter-spacing: 0.2em; text-transform: uppercase; writing-mode: vertical-rl;
  transform: translateY(-50%); color: var(--ink-on-dark-faint);
}
.heroA__edge-label--l { left: 22px; }
.heroA__edge-label--r { right: 22px; transform: translateY(-50%) rotate(180deg); }

/* flowing connector lines behind the A hero headline */
.flowline { fill: none; stroke-width: 1.4; stroke-linecap: round; }
.flowline--fwd { stroke: var(--field-bright); }
.flowline--rev { stroke: var(--biology-bright); }
.flow-dash { stroke-dasharray: 5 12; animation: flowdash 2.4s linear infinite; }
@keyframes flowdash { to { stroke-dashoffset: -34; } }
.flow-dash--rev { animation: flowdash-rev 2.8s linear infinite; }
@keyframes flowdash-rev { to { stroke-dashoffset: 34; } }

/* ---- Direction B hero: two worlds meet ---- */
.heroB { padding: 0; }
.heroB__split { position: relative; display: grid; grid-template-columns: 1fr 1fr; min-height: 92vh; }
.heroB__half { position: relative; overflow: hidden; }
.heroB__half img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.heroB__half--field::after { content:''; position:absolute; inset:0; background: linear-gradient(105deg, rgba(11,22,17,0.82) 8%, rgba(31,58,43,0.45) 60%, rgba(184,118,42,0.18) 100%); }
.heroB__half--food::after  { content:''; position:absolute; inset:0; background: linear-gradient(255deg, rgba(20,8,20,0.84) 8%, rgba(139,39,131,0.42) 60%, rgba(184,118,42,0.18) 100%); }
.heroB__half .tag {
  position: absolute; z-index: 4; bottom: 36px; font-family: var(--font-mono);
  font-size: 0.64rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-on-dark-soft);
}
.heroB__half--field .tag { left: 36px; }
.heroB__half--food .tag { right: 36px; text-align: right; }
.heroB__half .tag b { display:block; color:#fff; font-weight:400; font-size:0.78rem; letter-spacing:0.04em; margin-top:5px; }
.heroB__seam {
  position: absolute; top: 0; bottom: 0; left: 50%; transform: translateX(-50%);
  width: 2px; background: linear-gradient(var(--seam-glow), var(--seam));
  box-shadow: 0 0 40px 6px rgba(233,168,76,0.5); z-index: 5;
}
.heroB__core {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  z-index: 6; width: min(720px, 86vw); text-align: center; color: var(--ink-on-dark);
}
.heroB__core h1 { color: var(--cream-paper); }
.heroB__core .hero__lead { margin-left: auto; margin-right: auto; max-width: 52ch; }
.heroB__core .hero__actions { justify-content: center; }
.heroB__core .hero__kicker { justify-content: center; }
.heroB__seal {
  display: inline-flex; flex-direction: column; align-items: center; gap: 8px;
  margin: 0 auto 30px; padding: 16px 22px; border-radius: var(--radius);
  background: rgba(11,22,17,0.5); border: 1px solid rgba(233,168,76,0.4);
  backdrop-filter: blur(6px);
}
.heroB__seal .ring {
  width: 54px; height: 54px; border-radius: 50%; display:grid; place-items:center;
  border: 2px solid var(--seam-glow); position: relative;
}
.heroB__seal .ring::before, .heroB__seal .ring::after {
  content:''; position:absolute; width: 9px; height: 9px; border-radius:50%;
}
.heroB__seal .ring::before { background: var(--field-lime); left: -5px; }
.heroB__seal .ring::after  { background: var(--biology-bright); right: -5px; }
.heroB__seal .ring span { font-family: var(--font-mono); font-size: 0.9rem; color: var(--seam-glow); }
.heroB__seal small { font-family: var(--font-mono); font-size: 0.56rem; letter-spacing:0.18em; text-transform:uppercase; color: var(--ink-on-dark-soft); }

/* ============================================================
   HERO — THE VISION (combined: two-worlds split + flow-lines)
   ============================================================ */
.hero--vision { min-height: 94vh; display: grid; align-items: center; }
.vhero__bg { position: absolute; inset: 0; z-index: 1; }
.vhero__half { position: absolute; top: 0; bottom: 0; width: 50%; overflow: hidden; }
.vhero__half--field { left: 0; }
.vhero__half--food { right: 0; }
.vhero__half img { width: 100%; height: 100%; object-fit: cover; }
.vhero__half--field::after { content: ''; position: absolute; inset: 0; background: linear-gradient(100deg, rgba(11,22,17,0.92) 12%, rgba(31,58,43,0.5) 68%, rgba(184,118,42,0.18)); }
.vhero__half--food::after { content: ''; position: absolute; inset: 0; background: linear-gradient(260deg, rgba(20,8,20,0.92) 12%, rgba(139,39,131,0.46) 68%, rgba(184,118,42,0.18)); }
.vhero__flow { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 2; opacity: 0.7; }
.vhero__seam { position: absolute; top: 0; bottom: 0; left: 50%; transform: translateX(-50%); width: 2px;
  background: linear-gradient(var(--seam-glow), var(--seam)); box-shadow: 0 0 50px 8px rgba(233,168,76,0.45); z-index: 3; }
.vhero__scrim { position: absolute; inset: 0; z-index: 3;
  background: radial-gradient(ellipse 66% 80% at 50% 50%, rgba(11,22,17,0.92) 26%, rgba(11,22,17,0.55) 72%, rgba(11,22,17,0.32) 100%); }
.vhero__tag { position: absolute; bottom: 30px; z-index: 4; font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.18em; text-transform: uppercase; }
.vhero__tag--l { left: 34px; color: var(--field-lime); }
.vhero__tag--r { right: 34px; color: var(--biology-bright); }
.vhero__content { position: relative; z-index: 5; max-width: 920px; margin: 0 auto; text-align: center; padding: 124px 0 72px; }
.hero--vision h1 { font-size: clamp(2.4rem, 5.2vw, 4.5rem); max-width: 18ch; margin: 0 auto 26px; }
.hero--vision .hero__kicker { justify-content: center; }
.hero--vision .hero__lead { margin: 0 auto 34px; max-width: 58ch; }
.hero--vision .hero__actions { justify-content: center; }
.vhero__how { margin-top: 44px; padding-top: 26px; border-top: 1px solid var(--line-dim);
  display: flex; gap: 12px; align-items: center; justify-content: center; flex-wrap: wrap; }
.vhero__how-k { font-family: var(--font-mono); font-size: 0.64rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-on-dark-faint); }
.vhero__chip { display: inline-flex; align-items: center; gap: 9px; font-family: var(--font-sans); font-size: 0.83rem; font-weight: 600;
  color: var(--ink-on-dark); padding: 8px 15px; border: 1px solid var(--line-dim); border-radius: var(--radius-pill); background: rgba(0,0,0,0.3); }
.vhero__chip b { font-family: var(--font-mono); font-size: 0.66rem; color: var(--seam-glow); }
.vhero__chip--accent { border-color: rgba(233,168,76,0.5); background: rgba(233,168,76,0.13); color: var(--cream-paper); }
.vhero__arrow { color: var(--ink-on-dark-faint); font-family: var(--font-mono); }
@media (max-width: 700px) {
  .vhero__content { padding: 104px 0 56px; }
  .hero--vision .hero__lead { font-size: 1.02rem; line-height: 1.55; margin-bottom: 28px; }
  .vhero__how { flex-direction: column; gap: 8px; }
  .vhero__arrow { transform: rotate(90deg); }
}

/* ============================================================
   SECTION SHELL
   ============================================================ */
section { position: relative; }
.sec { padding: var(--section-pad) 0; }
.sec--cream { background: var(--cream-paper); }
.sec--cream2 { background: var(--cream-2); }
.sec-head { max-width: 760px; margin: 0 auto 56px; text-align: center; }
.sec-head--left { text-align: left; margin-left: 0; }
.sec-head .eyebrow { margin-bottom: 16px; }
.sec-head h2 {
  font-family: var(--font-serif); font-weight: 400; font-size: var(--h2-size);
  line-height: 1.12; letter-spacing: -0.01em; color: var(--forest-ink); margin: 0 0 18px;
}
.sec-head h2 em { font-style: italic; color: var(--ochre); }
.sec-head p { font-size: 1.06rem; line-height: 1.65; color: var(--text-mid); margin: 0; }
.sec-head--center p { margin-left: auto; margin-right: auto; max-width: 60ch; }

/* ============================================================
   IDEA IN SHORT — predict / verify / improve triad
   ============================================================ */
.triad { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.triad__card {
  position: relative; padding: 34px 30px 30px; border-radius: var(--radius);
  background: #fff; border: 1px solid var(--border-line); overflow: hidden;
  transition: transform .3s ease, box-shadow .3s ease;
}
.triad__card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.triad__card::before { content:''; position:absolute; left:0; top:0; bottom:0; width:4px; }
.triad__card--predict::before { background: var(--field-bright); }
.triad__card--verify::before  { background: var(--biology-bright); }
.triad__card--improve::before { background: var(--seam); }
.triad__n { font-family: var(--font-mono); font-size: 0.66rem; letter-spacing: 0.18em; text-transform: uppercase; color: var(--muted-ink); }
.triad__card h3 { font-family: var(--font-serif); font-weight: 500; font-size: 1.5rem; color: var(--forest-ink); margin: 14px 0 10px; }
.triad__card p { font-size: 0.95rem; line-height: 1.6; color: var(--text-mid); margin: 0; }
.triad__icon { width: 40px; height: 40px; margin-bottom: 6px; }
.triad__from-to { font-family: var(--font-mono); font-size: 0.66rem; color: var(--muted-ink); margin-top: 16px; padding-top: 14px; border-top: 1px dashed var(--border-line); letter-spacing: 0.04em; }
.triad__from-to b { color: var(--forest-ink); font-weight: 700; }

/* ============================================================
   THE ENGINE  (the dramatic centrepiece)
   ============================================================ */
.engine {
  background: radial-gradient(ellipse 120% 90% at 50% 0%, #16291F 0%, var(--night) 45%, var(--night-2) 100%);
  color: var(--ink-on-dark); padding: 88px 0 96px; overflow: hidden;
  border-top: 1px solid rgba(0,0,0,0.3);
}
.engine__head { display: grid; grid-template-columns: 1fr auto; gap: 30px; align-items: end; margin-bottom: 14px; }
.engine__head h2 { font-family: var(--font-serif); font-weight: 300; font-size: clamp(1.9rem, 3.4vw, 3rem); color: var(--cream-paper); letter-spacing: -0.01em; line-height: 1.1; margin: 12px 0 0; max-width: 18ch; }
.engine__head h2 em { font-style: italic; color: var(--seam-glow); }
.engine__head p { color: var(--ink-on-dark-soft); max-width: 40ch; font-size: 0.98rem; line-height: 1.6; margin: 0; }

/* mode tabs */
.engine__modes { display: flex; gap: 10px; flex-wrap: wrap; margin: 30px 0 26px; }
.mode-tab {
  display: flex; align-items: center; gap: 11px;
  padding: 12px 20px 12px 14px; border-radius: var(--radius-pill);
  background: rgba(246,242,233,0.04); border: 1px solid var(--line-dim);
  color: var(--ink-on-dark-soft); cursor: pointer; transition: all .25s ease;
  font-family: var(--font-sans);
}
.mode-tab:hover { border-color: rgba(246,242,233,0.3); color: var(--ink-on-dark); }
.mode-tab__dot { width: 10px; height: 10px; border-radius: 50%; flex: none; }
.mode-tab__t { text-align: left; }
.mode-tab__t b { display: block; font-size: 0.92rem; font-weight: 700; letter-spacing: 0.02em; }
.mode-tab__t span { font-family: var(--font-mono); font-size: 0.58rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-on-dark-faint); }
.mode-tab[data-mode="predict"] .mode-tab__dot { background: var(--field-bright); }
.mode-tab[data-mode="verify"]  .mode-tab__dot { background: var(--biology-bright); }
.mode-tab[data-mode="improve"] .mode-tab__dot { background: var(--seam-glow); }
.mode-tab.is-active { background: rgba(246,242,233,0.1); border-color: rgba(246,242,233,0.45); color: var(--cream-paper); }
.mode-tab.is-active[data-mode="predict"] { box-shadow: inset 0 0 0 1px var(--field-bright), 0 0 24px -6px var(--field-bright); }
.mode-tab.is-active[data-mode="verify"]  { box-shadow: inset 0 0 0 1px var(--biology-bright), 0 0 24px -6px var(--biology-bright); }
.mode-tab.is-active[data-mode="improve"] { box-shadow: inset 0 0 0 1px var(--seam-glow), 0 0 24px -6px var(--seam-glow); }

/* attention hint — Verify & Improve pulse a cyan glow in sequence to invite a press;
   only while the engine is in view and only until the viewer engages a tab */
.engine__modes.is-hinting .mode-tab[data-mode="verify"]:not(.is-active),
.engine__modes.is-hinting .mode-tab[data-mode="improve"]:not(.is-active) {
  animation: mode-tab-hint 2.8s ease-in-out infinite;
}
.engine__modes.is-hinting .mode-tab[data-mode="improve"]:not(.is-active) { animation-delay: 1.4s; }
@keyframes mode-tab-hint {
  0%, 18%, 100% { box-shadow: 0 0 0 0 rgba(60,214,224,0); border-color: var(--line-dim); }
  46% { box-shadow: 0 0 22px -3px rgba(60,214,224,0.6), inset 0 0 0 1px rgba(60,214,224,0.55); border-color: rgba(60,214,224,0.6); }
}
@media (prefers-reduced-motion: reduce) {
  .engine__modes.is-hinting .mode-tab { animation: none; }
}

/* path bar — narrates direction across the top of the stage */
.stage__path { display: grid; grid-template-columns: 1fr 64px 1.15fr 64px 1fr; align-items: center;
  padding: 13px 26px; background: rgba(0,0,0,0.34); border-bottom: 1px solid var(--line-dim); }
.path-node { text-align: center; }
.path-node b { display: block; font-family: var(--font-serif); font-weight: 500; font-size: 0.98rem; color: var(--cream-paper); letter-spacing: 0.01em; }
.path-node span { display: block; margin-top: 3px; font-family: var(--font-mono); font-size: 0.56rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-on-dark-faint); transition: color .35s ease; min-height: 1em; }
.stage[data-mode="predict"] .path-node:first-child span { color: var(--field-lime); }
.stage[data-mode="verify"] .path-node:last-child span { color: var(--biology-bright); }
.stage[data-mode="improve"] .path-node:first-child span { color: var(--field-lime); }
.stage[data-mode="improve"] .path-node:last-child span { color: var(--biology-bright); }
.path-node--model span { color: var(--seam-glow) !important; }
.path-arrow { text-align: center; line-height: 0; transition: color .35s ease; color: var(--ink-on-dark-faint); }
.path-arrow svg { width: 44px; height: 22px; display: inline-block; }
.path-arrow .chev { opacity: 0.18; }
.stage[data-mode="predict"] .path-arrow { color: var(--field-bright); }
.stage[data-mode="verify"] .path-arrow { color: var(--biology-bright); }
.stage[data-mode="improve"] .path-arrow { color: var(--seam-glow); }
.path-arrow .chev { animation: chevmarch 1.2s linear infinite; }
.path-arrow .chev:nth-child(2) { animation-delay: 0.18s; }
.path-arrow .chev:nth-child(3) { animation-delay: 0.36s; }
@keyframes chevmarch { 0%, 100% { opacity: 0.18; } 28% { opacity: 1; } 56% { opacity: 0.18; } }
.path-arrow .loop-spin { transform-origin: 50% 50%; animation: loopspin 2.6s linear infinite; }
@keyframes loopspin { to { transform: rotate(360deg); } }

/* the inactive world dims so input vs answer is obvious */
.world { transition: opacity .45s ease, filter .45s ease; }
.stage[data-mode="predict"] .world--food { opacity: 0.45; filter: saturate(0.45); }
.stage[data-mode="verify"] .world--field { opacity: 0.45; filter: saturate(0.45); }

/* the INPUT world is visibly 'where the story starts' */
.world.is-input { position: relative; }
.world.is-input::before { content: ''; position: absolute; inset: 0; pointer-events: none; border: 2px solid; border-radius: 2px; z-index: 3; }
.world--field.is-input::before { border-color: var(--field-bright); box-shadow: inset 0 0 34px -14px var(--field-bright); }
.world--food.is-input::before { border-color: var(--biology-bright); box-shadow: inset 0 0 34px -14px var(--biology-bright); }
.world.is-input.flash::before { animation: inputflash 1.1s ease; }
@keyframes inputflash { 0% { opacity: 0; } 25% { opacity: 1; box-shadow: inset 0 0 60px -10px currentColor; } 100% { opacity: 1; } }
.world__start { display: none; font-family: var(--font-mono); font-size: 0.56rem; letter-spacing: 0.16em; text-transform: uppercase; padding: 5px 10px; border-radius: var(--radius-pill); width: max-content; }
.world.is-input .world__start { display: inline-block; }
.world--field .world__start { background: rgba(107,138,90,0.22); color: var(--field-lime); border: 1px solid rgba(107,138,90,0.5); }
.world--food .world__start { background: rgba(194,57,140,0.18); color: var(--biology-bright); border: 1px solid rgba(194,57,140,0.5); }

/* stacked layout: the INPUT world moves to the TOP, right under the mode buttons,
   so clicking Verify visibly starts at the food sample */
@media (max-width: 1040px) {
  .stage__grid > * { order: 2; }
  .stage[data-mode="predict"] .world--field { order: 0; }
  .stage[data-mode="verify"] .world--food { order: 0; }
  .stage[data-mode="improve"] .world--field { order: 0; }
  .stage .core { order: 1; }
  .stage[data-mode="verify"] .world--field { order: 2; }
}

/* readout cells flash when a mode rewrites them */
.engine__readout .cell.tick { animation: cellflash 0.9s ease; }
@keyframes cellflash { 0% { background: rgba(233,168,76,0.18); } 100% { background: var(--night); } }

@media (prefers-reduced-motion: reduce) {
  .path-arrow .chev, .path-arrow .loop-spin { animation: none !important; }
  .path-arrow .chev { opacity: 0.9; }
}
@media (max-width: 620px) {
  .stage__path { grid-template-columns: 1fr 36px 1.15fr 36px 1fr; padding: 11px 14px; }
  .path-arrow svg { width: 30px; height: 18px; }
  .path-node b { font-size: 0.8rem; }
  .path-node span { font-size: 0.5rem; }
}

/* stage */
.stage {
  position: relative; border-radius: 16px; overflow: hidden;
  border: 1px solid var(--line-dim);
  background: linear-gradient(180deg, rgba(0,0,0,0.18), rgba(0,0,0,0.35));
}
/* IMPROVE: the loop made visible — an ochre comet orbiting the whole stage */
@property --loop-angle { syntax: '<angle>'; initial-value: 0deg; inherits: false; }
.stage__comet { position: absolute; inset: 0; border-radius: 16px; padding: 3px; pointer-events: none; z-index: 9;
  background: conic-gradient(from var(--loop-angle, 0deg), transparent 0 70%, rgba(233,168,76,0.12) 78%, rgba(233,168,76,0.55) 90%, #FFE3B3 99%, transparent 100%);
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor; mask-composite: exclude;
  opacity: 0; transition: opacity .5s ease; }
.stage[data-mode="improve"] .stage__comet { opacity: 1; animation: looporbit 2.8s linear infinite; }
@keyframes looporbit { to { --loop-angle: 360deg; } }
/* IMPROVE: the core spins like a turbine */
.stage[data-mode="improve"] .core__ring svg { animation: ringspin 1.5s linear infinite; }
@keyframes ringspin { from { transform: rotate(-90deg); } to { transform: rotate(270deg); } }
.stage[data-mode="improve"] .core__ring { box-shadow: 0 0 60px -12px rgba(233,168,76,0.55); }
/* IMPROVE: confirmations land on the food side */
.chip.is-confirmed { border-color: rgba(159,176,79,0.65); background: rgba(118,184,42,0.1); }
.chip.is-confirmed .chip__io { background: var(--lime-bright) !important; }
@media (prefers-reduced-motion: reduce) {
  .stage__comet, .stage[data-mode="improve"] .core__ring svg { animation: none !important; }
}
.stage__grid {
  display: grid; grid-template-columns: 1fr 1.15fr 1fr; align-items: stretch;
  min-height: 540px; position: relative;
}
/* worlds */
.world { position: relative; padding: 30px 26px; display: flex; flex-direction: column; gap: 16px; }
.world--field { background: linear-gradient(180deg, rgba(42,74,55,0.30), rgba(42,74,55,0.08)); }
.world--food  { background: linear-gradient(180deg, rgba(139,39,131,0.28), rgba(139,39,131,0.07)); }
.world__photo {
  height: 118px; border-radius: 10px; overflow: hidden; position: relative;
  border: 1px solid var(--line-dim);
}
.world__photo img { width: 100%; height: 100%; object-fit: cover; }
.world__photo::after { content:''; position:absolute; inset:0; }
.world--field .world__photo::after { background: linear-gradient(180deg, transparent 30%, rgba(11,22,17,0.55)); }
.world--food .world__photo::after  { background: linear-gradient(180deg, transparent 30%, rgba(20,8,20,0.6)); }
.world__label { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.18em; text-transform: uppercase; }
.world--field .world__label { color: var(--field-lime); }
.world--food .world__label { color: var(--biology-bright); }
.world__title { font-family: var(--font-serif); font-size: 1.25rem; font-weight: 500; color: var(--cream-paper); margin: 2px 0 4px; line-height: 1.2; }
.world__sub { font-size: 0.8rem; color: var(--ink-on-dark-soft); margin: 0 0 4px; line-height: 1.5; }

.chip {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 13px; border-radius: 9px; background: rgba(0,0,0,0.28);
  border: 1px solid var(--line-dim); transition: all .35s ease;
  position: relative;
}
.chip__io { width: 8px; height: 8px; border-radius: 2px; flex: none; }
.world--field .chip__io { background: var(--field-bright); }
.world--food .chip__io { background: var(--biology-bright); }
.chip__txt b { display: block; font-size: 0.82rem; color: var(--cream-paper); font-weight: 600; letter-spacing: 0.01em; line-height: 1.25; }
.chip__txt span { font-family: var(--font-mono); font-size: 0.58rem; letter-spacing: 0.06em; color: var(--ink-on-dark-faint); }
.chip.is-lit { border-color: rgba(246,242,233,0.5); background: rgba(0,0,0,0.45); transform: translateX(var(--lit-shift, 0)); }
.chip.swap .chip__txt { animation: chipswap .55s ease; }
@keyframes chipswap { 0% { opacity: 0; transform: translateY(7px); } 100% { opacity: 1; transform: none; } }
.world--field .chip.is-lit { box-shadow: -3px 0 0 0 var(--field-bright), 0 0 22px -8px var(--field-bright); }
.world--food .chip.is-lit { box-shadow: 3px 0 0 0 var(--biology-bright), 0 0 22px -8px var(--biology-bright); }

/* core */
.core {
  position: relative; display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 24px; gap: 16px; background: rgba(0,0,0,0.25);
  border-left: 1px solid var(--line-dim); border-right: 1px solid var(--line-dim);
}
.core__ring {
  position: relative; width: 188px; height: 188px; border-radius: 50%;
  display: grid; place-items: center;
  background: radial-gradient(circle at 50% 50%, rgba(184,118,42,0.18), rgba(0,0,0,0.1) 70%);
}
.core__ring svg { position: absolute; inset: 0; width: 100%; height: 100%; transform: rotate(-90deg); }
.core__label { text-align: center; z-index: 2; }
.core__label .k { font-family: var(--font-mono); font-size: 0.54rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-on-dark-faint); }
.core__label .v { font-family: var(--font-serif); font-size: 1.15rem; color: var(--cream-paper); line-height: 1.15; margin-top: 3px; }
.core__verdict {
  text-align: center; padding: 12px 16px; border-radius: 10px; min-height: 64px;
  display: flex; flex-direction: column; justify-content: center; gap: 4px;
  border: 1px solid var(--line-dim); background: rgba(0,0,0,0.3); width: 100%;
  transition: all .4s ease;
}
.core__verdict .vk { font-family: var(--font-mono); font-size: 0.56rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--ink-on-dark-faint); }
.core__verdict .vv { font-size: 0.9rem; font-weight: 700; color: var(--cream-paper); letter-spacing: 0.01em; }
.core__verdict.is-certified { border-color: rgba(118,184,42,0.6); background: rgba(118,184,42,0.12); }
.core__verdict.is-certified .vv { color: var(--lime-bright); }
.core__spark { position: absolute; width: 14px; height: 14px; border-radius: 50%; pointer-events: none; opacity: 0; }

/* SVG flow overlay across the stage */
.stage__flow { position: absolute; inset: 0; z-index: 5; pointer-events: none; }
.stage__flow path { fill: none; stroke-width: 1.6; opacity: 0; transition: opacity .4s ease; }
.stage__flow path.is-on { opacity: 0.9; }
.flow-fwd { stroke: var(--field-bright); }
.flow-rev { stroke: var(--biology-bright); }
.flow-imp { stroke: var(--seam-glow); }
.dashflow { stroke-dasharray: 4 10; }

/* moving particle */
.particle { position: absolute; width: 7px; height: 7px; border-radius: 50%; z-index: 6; pointer-events: none; opacity: 0; box-shadow: 0 0 10px 2px currentColor; }

/* readout strip under stage */
.engine__readout {
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px;
  margin-top: 22px; background: var(--line-dim); border: 1px solid var(--line-dim);
  border-radius: 12px; overflow: hidden;
}
.engine__readout .cell { background: var(--night); padding: 18px 22px; }
.engine__readout .cell .k { font-family: var(--font-mono); font-size: 0.58rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-on-dark-faint); margin-bottom: 8px; }
.engine__readout .cell .v { font-family: var(--font-serif); font-size: 1.45rem; color: var(--cream-paper); line-height: 1.1; }
.engine__readout .cell .v small { font-size: 0.85rem; color: var(--ink-on-dark-soft); }
.engine__readout .cell .s { font-family: var(--font-mono); font-size: 0.62rem; color: var(--seam-glow); margin-top: 6px; letter-spacing: 0.04em; }

/* mode caption */
.engine__caption {
  margin-top: 20px; display: flex; gap: 14px; align-items: flex-start;
  font-size: 0.95rem; line-height: 1.6; color: var(--ink-on-dark-soft); max-width: 70ch;
}
.engine__caption .badge { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.12em; text-transform: uppercase; padding: 5px 10px; border-radius: var(--radius-pill); flex: none; margin-top: 2px; }
.engine__caption .badge--predict { background: rgba(107,138,90,0.18); color: var(--field-lime); border: 1px solid rgba(107,138,90,0.4); }
.engine__caption .badge--verify { background: rgba(194,57,140,0.16); color: var(--biology-bright); border: 1px solid rgba(194,57,140,0.4); }
.engine__caption .badge--improve { background: rgba(233,168,76,0.16); color: var(--seam-glow); border: 1px solid rgba(233,168,76,0.4); }
.engine__caption b { color: var(--cream-paper); font-weight: 700; }

/* improve loop orbit (shown only in improve mode) */
.orbit { position: absolute; inset: 0; z-index: 4; pointer-events: none; opacity: 0; transition: opacity .5s ease; }
.orbit.is-on { opacity: 1; }
.orbit__node {
  position: absolute; transform: translate(-50%,-50%);
  font-family: var(--font-mono); font-size: 0.58rem; letter-spacing: 0.1em; text-transform: uppercase;
  color: var(--seam-glow); background: rgba(11,22,17,0.85); border: 1px solid rgba(233,168,76,0.5);
  padding: 6px 11px; border-radius: var(--radius-pill); white-space: nowrap;
}

/* ============================================================
   TWO JOBS
   ============================================================ */
.jobs { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
.job {
  position: relative; padding: 40px 36px; border-radius: var(--radius); overflow: hidden;
  color: var(--ink-on-dark);
}
.job--verify { background: linear-gradient(155deg, #1F3A2B, #122A1F); }
.job--innovate { background: linear-gradient(155deg, #3a1f37 0%, #1c0f1b 90%); }
.job__tag { font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.16em; text-transform: uppercase; }
.job--verify .job__tag { color: var(--field-lime); }
.job--innovate .job__tag { color: var(--biology-bright); }
.job h3 { font-family: var(--font-serif); font-weight: 400; font-size: 1.9rem; color: var(--cream-paper); margin: 16px 0 14px; }
.job p { color: var(--ink-on-dark-soft); font-size: 0.98rem; line-height: 1.65; margin: 0; }
.job__glyph { position: absolute; right: -30px; bottom: -30px; width: 180px; height: 180px; opacity: 0.16; }

/* ============================================================
   JOURNEY RAIL — farm → model → food, read three ways
   ============================================================ */
.journey .jrail { max-width: 1040px; margin: 0 auto; display: flex; flex-direction: column; gap: 14px; }
.jbar {
  display: flex; align-items: center; gap: 22px; padding: 18px 30px;
  border-radius: var(--radius-pill); border: 1.5px solid;
}
.jbar__badge {
  flex: none; width: 44px; height: 44px; border-radius: 50%; display: grid; place-items: center;
  font-family: var(--font-serif); font-size: 1.3rem; font-weight: 500; color: #fff;
}
.jbar__k { font-family: var(--font-serif); font-weight: 500; font-size: 1.4rem; letter-spacing: -0.005em; white-space: nowrap; line-height: 1.1; }
.jbar__d { font-size: 1rem; line-height: 1.45; color: var(--text-mid); flex: 1; }
.jbar__d b { color: var(--charcoal); }
.jbar__chevs { flex: none; line-height: 0; }
.jbar__chevs svg { width: 60px; height: 28px; }
.jbar__chevs .chev { opacity: 0.18; animation: chevmarch 1.2s linear infinite; }
.jbar__chevs .chev:nth-child(2) { animation-delay: 0.18s; }
.jbar__chevs .chev:nth-child(3) { animation-delay: 0.36s; }
.jbar__chevs .loop-spin { transform-origin: 50% 50%; animation: loopspin 2.6s linear infinite; }
.jbar--predict { background: linear-gradient(90deg, rgba(107,138,90,0.2), rgba(184,118,42,0.07)); border-color: rgba(107,138,90,0.55); }
.jbar--predict .jbar__k, .jbar--predict .jbar__chevs { color: var(--moss); }
.jbar--predict .jbar__badge { background: var(--moss); }
.jbar--verify { flex-direction: row-reverse; background: linear-gradient(270deg, rgba(139,39,131,0.18), rgba(184,118,42,0.05)); border-color: rgba(139,39,131,0.5); }
.jbar--verify .jbar__d { text-align: right; }
.jbar--verify .jbar__k, .jbar--verify .jbar__chevs { color: var(--biology); }
.jbar--verify .jbar__badge { background: var(--biology); }
.jbar--improve { background: var(--ochre-muted); border-color: rgba(184,118,42,0.65); text-decoration: none; transition: all .2s ease; }
.jbar--improve:hover { background: rgba(184,118,42,0.24); transform: translateY(-2px); box-shadow: var(--shadow-md); }
.jbar--improve .jbar__k, .jbar--improve .jbar__chevs { color: var(--ochre); }
.jbar--improve .jbar__badge { background: var(--ochre); }
.jbar--improve .jbar__d { color: var(--charcoal); font-weight: 500; }
@media (max-width: 760px) {
  .jbar { flex-wrap: wrap; gap: 12px 16px; padding: 16px 20px; border-radius: var(--radius); }
  .jbar__k { font-size: 1.2rem; }
  .jbar__d { flex-basis: 100%; }
  .jbar--verify { flex-direction: row; }
  .jbar--verify .jbar__d { text-align: left; }
}

.jrail__track { display: grid; grid-template-columns: 1fr auto 1fr auto 1fr; align-items: stretch; }
.jnode { padding: 22px 20px; border-radius: var(--radius); border: 1px solid var(--border-line); background: #fff; text-align: center; display: flex; flex-direction: column; align-items: center; gap: 9px; }
.jnode--farm { border-top: 3px solid var(--moss); }
.jnode--food { border-top: 3px solid var(--biology-bright); }
.jnode--model { background: var(--forest-ink); border-color: var(--forest-ink); }
.jnode__num { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.2em; text-transform: uppercase; color: var(--muted-ink); }
.jnode--model .jnode__num { color: var(--seam-glow); }
.jnode__photo { width: 100%; height: 92px; border-radius: 8px; overflow: hidden; }
.jnode__photo img { width: 100%; height: 100%; object-fit: cover; }
.jnode h3 { font-family: var(--font-serif); font-weight: 500; font-size: 1.2rem; margin: 2px 0 0; color: var(--forest-ink); }
.jnode--model h3 { color: var(--cream-paper); }
.jnode p { font-size: 0.82rem; line-height: 1.5; color: var(--text-mid); margin: 0; }
.jnode--model p { color: var(--ink-on-dark-soft); }
.jnode__glyph { width: 92px; height: 60px; }
.jconn { display: flex; align-items: center; justify-content: center; padding: 0 12px; color: var(--ochre); }
.jconn svg { width: 28px; height: 28px; }

/* ============================================================
   ACCELERATION — the third turn (interactive flywheel)
   ============================================================ */
.accel { position: relative; overflow: hidden; color: var(--ink-on-dark);
  background: radial-gradient(ellipse 110% 90% at 50% 118%, #2c2012 0%, var(--night) 52%, var(--night-2) 100%); }
.accel .sec-head h2 { color: var(--cream-paper); }
.accel .sec-head h2 em { color: var(--seam-glow); }
.accel .sec-head p { color: var(--ink-on-dark-soft); }
.accel .eyebrow { color: var(--seam-glow); }
.accel__panel { display: grid; grid-template-columns: 320px 1fr; gap: 34px; align-items: stretch;
  background: rgba(0,0,0,0.26); border: 1px solid var(--line-dim); border-radius: 18px; padding: 30px; }
.accel__left { display: flex; flex-direction: column; gap: 20px; align-items: center; }
.fly { width: 224px; height: 224px; display: block; }
.fly__ring { fill: none; stroke: rgba(246,242,233,0.1); stroke-width: 2; }
.fly__half-l { fill: none; stroke: var(--field-bright); stroke-width: 3; opacity: 0.75; }
.fly__half-r { fill: none; stroke: var(--biology-bright); stroke-width: 3; opacity: 0.75; }
.fly__spoke { stroke: rgba(233,168,76,0.45); stroke-width: 2; stroke-linecap: round; }
.fly__rim { fill: none; stroke: rgba(233,168,76,0.3); stroke-width: 1.5; stroke-dasharray: 3 9; }
.fly__node { fill: var(--seam-glow); }
.fly__hub { fill: rgba(8,16,12,0.92); stroke: var(--seam-glow); stroke-width: 2; }
.fly__sym { fill: var(--seam-glow); font-family: var(--font-mono); font-size: 30px; text-anchor: middle; dominant-baseline: central; }
.accel__halflabel { display: flex; justify-content: space-between; width: 224px; font-family: var(--font-mono); font-size: 0.54rem; letter-spacing: 0.12em; text-transform: uppercase; margin-top: -8px; }
.accel__halflabel .l { color: var(--field-lime); }
.accel__halflabel .r { color: var(--biology-bright); }
.accel__steps { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 7px; width: 100%; }
.accel__step { display: flex; gap: 11px; align-items: center; font-family: var(--font-mono); font-size: 0.62rem;
  letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-on-dark-faint);
  padding: 8px 12px; border-radius: 8px; border: 1px solid transparent; transition: all .3s ease; }
.accel__step .n { color: var(--seam-glow); font-weight: 500; }
.accel__step.is-on { color: var(--cream-paper); background: rgba(233,168,76,0.12); border-color: rgba(233,168,76,0.4); }
.accel__space { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-on-dark-faint); text-align: center; }
.accel__space b { color: var(--seam-glow); font-weight: 500; }
.accel__right { display: flex; flex-direction: column; gap: 16px; }
.accel__chart { position: relative; border-radius: 12px; padding: 12px 14px;
  background: linear-gradient(180deg, rgba(0,0,0,0.18), rgba(0,0,0,0.34)); border: 1px solid var(--line-dim); }
.accel__charttitle { font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-on-dark-soft); margin: 4px 4px 8px; }
.accel__svg { width: 100%; height: auto; display: block; }
.accel__grid-line { stroke: rgba(246,242,233,0.08); stroke-width: 1; }
.accel__axis { fill: var(--ink-on-dark-faint); font-family: var(--font-mono); font-size: 11px; letter-spacing: 0.08em; }
.accel__area { fill: url(#accelFill); opacity: 0.92; }
.accel__line { fill: none; stroke: var(--seam-glow); stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.accel__dot { fill: var(--seam-glow); }
.accel__dot.is-head { fill: #fff; }
.accel__annot { fill: var(--ink-on-dark-faint); font-family: var(--font-mono); font-size: 10.5px; letter-spacing: 0.06em; opacity: 0; transition: opacity .5s ease; }
.accel.is-done .accel__annot { opacity: 1; }
.accel__counters { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--line-dim); border: 1px solid var(--line-dim); border-radius: 12px; overflow: hidden; }
.accel__counter { background: var(--night); padding: 15px 16px; }
.accel__counter .k { font-family: var(--font-mono); font-size: 0.54rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-on-dark-faint); margin-bottom: 7px; }
.accel__counter .v { font-family: var(--font-serif); font-size: 1.75rem; color: var(--cream-paper); line-height: 1; letter-spacing: -0.01em; }
.accel__counter.is-accent .v { color: var(--seam-glow); }
.accel__controls { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; }
.accel__run { display: inline-flex; align-items: center; gap: 10px; padding: 14px 26px; border-radius: var(--radius-btn);
  background: var(--seam-glow); color: var(--night); border: none; cursor: pointer;
  font-family: var(--font-sans); font-size: 0.8rem; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; transition: all .2s ease; }
.accel__run:hover { background: #f4b65e; }
.accel__run svg { width: 14px; height: 14px; }
.accel__run[disabled] { opacity: 0.55; cursor: default; }
.accel__hint { font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.1em; text-transform: uppercase; color: var(--ink-on-dark-faint); }
@media (max-width: 900px) {
  .accel__panel { grid-template-columns: 1fr; }
  .accel__counters { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 820px) {
  .jrail__track { grid-template-columns: 1fr; gap: 6px; }
  .jconn { transform: rotate(90deg); padding: 6px 0; }
  .jbar--verify { flex-direction: row; }
  .jbar--verify .jbar__d { text-align: left; }
}

/* ============================================================
   THE ASSET — 3 numbered reasons
   ============================================================ */
.assets { display: grid; grid-template-columns: repeat(3, 1fr); gap: 26px; counter-reset: a; }
.asset { position: relative; padding-top: 26px; border-top: 2px solid var(--forest-ink); }
.asset__n { font-family: var(--font-serif); font-size: 2.6rem; font-weight: 300; color: var(--ochre); line-height: 1; letter-spacing: -0.02em; }
.asset h3 { font-family: var(--font-serif); font-weight: 500; font-size: 1.4rem; color: var(--forest-ink); margin: 14px 0 12px; }
.asset p { font-size: 0.96rem; line-height: 1.65; color: var(--text-mid); margin: 0; }
.asset p code { font-family: var(--font-mono); font-size: 0.86em; background: var(--ochre-muted); color: var(--ochre); padding: 1px 5px; border-radius: 4px; }

/* ============================================================
   TECHNICAL — under the hood accordion
   ============================================================ */
.tech { background: var(--forest-ink); color: var(--ink-on-dark); }
.tech .sec-head h2 { color: var(--cream-paper); }
.tech .sec-head h2 em { color: var(--seam-glow); }
.tech .sec-head p { color: var(--ink-on-dark-soft); }
.tech .eyebrow { color: var(--seam-glow); }
.acc { max-width: 940px; margin: 0 auto; border-top: 1px solid var(--line-dim); }
.acc__item { border-bottom: 1px solid var(--line-dim); }
.acc__head {
  width: 100%; display: flex; align-items: center; gap: 20px; text-align: left;
  background: none; border: none; cursor: pointer; padding: 26px 4px; color: var(--cream-paper);
  font-family: var(--font-serif); font-size: 1.3rem; font-weight: 400; letter-spacing: -0.005em;
  transition: color .2s ease;
}
.acc__head:hover { color: var(--seam-glow); }
.acc__num { font-family: var(--font-mono); font-size: 0.72rem; letter-spacing: 0.1em; color: var(--seam-glow); flex: none; padding-top: 6px; }
.acc__title { flex: 1; }
.acc__plus { flex: none; width: 26px; height: 26px; position: relative; }
.acc__plus::before, .acc__plus::after { content:''; position:absolute; background: var(--seam-glow); transition: transform .3s ease; }
.acc__plus::before { left: 0; right: 0; top: 12px; height: 2px; }
.acc__plus::after { top: 0; bottom: 0; left: 12px; width: 2px; }
.acc__item.is-open .acc__plus::after { transform: scaleY(0); }
.acc__body { max-height: 0; overflow: hidden; transition: max-height .45s ease; }
.acc__body-in { padding: 0 4px 32px 60px; color: var(--ink-on-dark-soft); font-size: 1rem; line-height: 1.75; max-width: 76ch; }
.acc__body-in p { color: var(--ink-on-dark-soft); margin: 0 0 16px; }
.acc__body-in p:last-child { margin-bottom: 0; }
.acc__body-in strong { color: var(--cream-paper); font-weight: 700; }
.acc__body-in .mono { font-family: var(--font-mono); color: var(--seam-glow); font-size: 0.9em; }
.acc__body-in .gate { display: grid; gap: 8px; margin: 18px 0; }
.acc__gate-row { display: grid; grid-template-columns: 96px 1fr; gap: 16px; align-items: baseline; padding: 12px 16px; border-radius: 8px; background: rgba(0,0,0,0.22); border: 1px solid var(--line-dim); }
.acc__gate-row .pct { font-family: var(--font-mono); font-weight: 500; font-size: 0.95rem; }
.acc__gate-row.g-hi .pct { color: var(--lime-bright); }
.acc__gate-row.g-mid .pct { color: var(--seam-glow); }
.acc__gate-row.g-lo .pct { color: var(--tier-4); }
.acc__gate-row span { color: var(--ink-on-dark-soft); font-size: 0.92rem; }

/* ============================================================
   FAQ
   ============================================================ */
.faq { max-width: 880px; margin: 0 auto; }
.faq__item { border-bottom: 1px solid var(--border-line); }
.faq__head {
  width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 20px;
  background: none; border: none; cursor: pointer; padding: 24px 2px; text-align: left;
  font-family: var(--font-serif); font-size: 1.2rem; font-weight: 500; color: var(--forest-ink);
}
.faq__head:hover { color: var(--ochre); }
.faq__chev { flex: none; width: 18px; height: 18px; transition: transform .3s ease; color: var(--ochre); }
.faq__item.is-open .faq__chev { transform: rotate(180deg); }
.faq__body { max-height: 0; overflow: hidden; transition: max-height .4s ease; }
.faq__body-in { padding: 0 2px 26px; color: var(--text-mid); font-size: 1rem; line-height: 1.7; max-width: 72ch; }
.faq__body-in a { color: var(--teal-ink); }

/* ============================================================
   QUOTE + CTA
   ============================================================ */
.partner { background: var(--cream-2); }
.quote { display: grid; grid-template-columns: 1fr 1.3fr; gap: 56px; align-items: center; }
.quote__media { border-radius: var(--radius); overflow: hidden; aspect-ratio: 4/5; }
.quote__media img { width: 100%; height: 100%; object-fit: cover; }
.quote__txt .eyebrow { margin-bottom: 22px; }
.quote__txt blockquote { margin: 0; font-family: var(--font-serif); font-weight: 300; font-size: clamp(1.6rem, 2.6vw, 2.3rem); line-height: 1.3; color: var(--forest-ink); letter-spacing: -0.01em; }
.quote__txt blockquote em { font-style: italic; color: var(--ochre); }
.quote__attr { margin-top: 26px; font-family: var(--font-mono); font-size: 0.7rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--muted-ink); }

.cta { position: relative; overflow: hidden; background: var(--night); color: var(--ink-on-dark); text-align: center; padding: 110px 0; }
.cta__bg { position: absolute; inset: 0; opacity: 0.22; }
.cta__bg img { width: 100%; height: 100%; object-fit: cover; }
.cta::after { content:''; position:absolute; inset:0; background: radial-gradient(ellipse at 50% 50%, rgba(17,32,26,0.5), var(--night) 75%); }
.cta__in { position: relative; z-index: 2; max-width: 740px; margin: 0 auto; padding: 0 32px; }
.cta h2 { font-family: var(--font-serif); font-weight: 300; font-size: clamp(2.2rem, 4.4vw, 3.6rem); color: var(--cream-paper); line-height: 1.1; letter-spacing: -0.015em; margin: 18px 0 22px; }
.cta h2 em { font-style: italic; color: var(--seam-glow); }
.cta p { color: var(--ink-on-dark-soft); font-size: 1.1rem; line-height: 1.6; max-width: 54ch; margin: 0 auto 36px; }
.cta__actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ============================================================
   FOOTER
   ============================================================ */
.foot { background: var(--night-2); color: var(--ink-on-dark-soft); padding: 56px 0 40px; border-top: 1px solid var(--line-dim); }
.foot__top { display: flex; justify-content: space-between; align-items: flex-start; gap: 40px; flex-wrap: wrap; }
.foot__logo { height: 30px; margin-bottom: 16px; }
.foot__top p { max-width: 38ch; font-size: 0.92rem; line-height: 1.6; color: var(--ink-on-dark-soft); margin: 0; }
.foot__auspices { font-family: var(--font-mono); font-size: 0.62rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink-on-dark-faint); text-align: right; line-height: 1.9; }
.foot__auspices b { color: var(--ink-on-dark-soft); font-weight: 400; }
.foot__rule { height: 1px; background: var(--line-dim); margin: 36px 0 20px; }
.foot__meta { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; font-family: var(--font-mono); font-size: 0.6rem; letter-spacing: 0.12em; text-transform: uppercase; color: var(--ink-on-dark-faint); }

/* ============================================================
   IMAGE PROMPT SLOTS (for art I'd commission)
   ============================================================ */
.imgslot { position: relative; border-radius: var(--radius); overflow: hidden; background: var(--night); border: 1px solid var(--line-dim); }
.imgslot__prompt {
  position: absolute; inset: 0; display: flex; flex-direction: column; justify-content: flex-end;
  padding: 18px; gap: 8px;
  background: repeating-linear-gradient(45deg, rgba(246,242,233,0.02) 0 10px, transparent 10px 20px);
}
.imgslot__tag { font-family: var(--font-mono); font-size: 0.56rem; letter-spacing: 0.16em; text-transform: uppercase; color: var(--seam-glow); }
.imgslot__txt { font-size: 0.8rem; line-height: 1.45; color: var(--ink-on-dark-soft); }
.imgslot__lens { position: absolute; top: 16px; left: 16px; width: 26px; height: 26px; border: 1.5px solid var(--ink-on-dark-faint); border-radius: 50%; }
.imgslot__lens::after { content:''; position: absolute; inset: 6px; border: 1.5px solid var(--ink-on-dark-faint); border-radius: 50%; }

/* ============================================================
   SCROLL REVEAL
   ============================================================ */
.reveal { opacity: 0; transform: translateY(26px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); }
/* react to predictive.js (.in) AND the sitewide main.js reveal observer (.visible) */
.reveal.in, .reveal.visible { opacity: 1; transform: none; }
.reveal[data-d="1"] { transition-delay: .08s; }
.reveal[data-d="2"] { transition-delay: .16s; }
.reveal[data-d="3"] { transition-delay: .24s; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .flow-dash, .dashflow, .hero__kicker .dot { animation: none; }
}

/* ============================================================
   DIRECTION VISIBILITY
   ============================================================ */
[data-dir="A"] .dirB-only { display: none; }
[data-dir="B"] .dirA-only { display: none; }

/* ---- Direction B engine skin: the photographic split ---- */
[data-dir="B"] .engine { background: #0B1611; }
[data-dir="B"] .stage { border-color: rgba(233,168,76,0.22); }
[data-dir="B"] .world--field {
  background: linear-gradient(180deg, rgba(11,22,17,0.55), rgba(11,22,17,0.82)), url('/food-farmland.webp') center/cover no-repeat;
}
[data-dir="B"] .world--food {
  background: linear-gradient(180deg, rgba(20,8,20,0.55), rgba(20,8,20,0.84)), url('/food-beetroot.webp') center/cover no-repeat;
}
[data-dir="B"] .world__photo { display: none; }
[data-dir="B"] .chip { background: rgba(8,14,11,0.62); backdrop-filter: blur(4px); }
[data-dir="B"] .core {
  background: rgba(8,16,12,0.74); backdrop-filter: blur(6px);
  border-left: 1px solid rgba(233,168,76,0.45);
  border-right: 1px solid rgba(233,168,76,0.45);
  box-shadow: 0 0 80px -10px rgba(233,168,76,0.4);
}
[data-dir="B"] .world__title, [data-dir="B"] .world__sub { text-shadow: 0 1px 12px rgba(0,0,0,0.6); }
@media (max-width: 1040px) {
  [data-dir="B"] .core { border-left: none; border-right: none; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 1040px) {
  .triad, .assets { grid-template-columns: 1fr; }
  .jobs, .quote { grid-template-columns: 1fr; }
  .engine__head { grid-template-columns: 1fr; }
  .stage__grid { grid-template-columns: 1fr; }
  .core { border-left: none; border-right: none; border-top: 1px solid var(--line-dim); border-bottom: 1px solid var(--line-dim); }
  .engine__readout { grid-template-columns: 1fr; }
  .stage__flow, .particle, .orbit { display: none; }
  .heroB__split { grid-template-columns: 1fr 1fr; min-height: auto; }
  .heroB__half { min-height: 30vh; }
  .heroB__core { position: relative; transform: none; left: 0; top: 0; padding: 56px 24px 64px; width: auto; grid-column: 1 / -1; background: var(--night); }
  .heroB__seam { top: auto; bottom: 0; height: 30vh; }
  .quote__media { aspect-ratio: 16/10; }
}
@media (max-width: 620px) {
  .wrap { padding: 0 20px; }
  .sec { padding: 64px 0; }
  .engine__readout { grid-template-columns: 1fr; }
  .foot__meta { flex-direction: column; gap: 8px; }
}

/* Farming 1D → 3D looping scene (native port of Claude Design "Farming 1D to 3D v2").
   The scene is a fixed 1280×720 stage scaled to its container width by a ResizeObserver,
   so it stays 16:9 and never overflows the page (the root clips its own bleed). These rules
   only handle outer spacing + small-screen polish; the scene's internals are untouched. */
.journey .f3d{ margin: clamp(1.6rem, 4vw, 2.9rem) auto 0; max-width: 1280px; }
.journey .f3d #farming1d3d{ display:block; }
/* On phones the desktop-scaled drop-shadow/radius are proportionally heavy on the small block. */
@media (max-width: 600px){
  .journey .f3d #farming1d3d{
    border-radius: 12px !important;
    box-shadow: 0 14px 34px -18px rgba(0,0,0,0.55), inset 0 0 0 1px rgba(255,255,255,0.045) !important;
  }
}
