/* AgRadiance website. Shares its tokens with the Web Tool and Atlas
   (AGR-Webtool apps/web/src/app/globals.css); keep the two in step. */

@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("../fonts/inter-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 100 900; font-display: swap;
  src: url("../fonts/inter-latin-ext.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }

:root {
  color-scheme: light;
  --forest: #1b4332;
  --green: #2d6a4f;
  --green-light: #40916c;
  --green-pale: #eaf3ed;
  --gold: #e9c46a;
  --gold-dark: #c89b32;
  --gold-pale: #fbf4df;
  --ink: #252925;
  --ink-2: #4b514c;
  --muted: #687068;
  --line: #e3e5df;
  --line-strong: #cbd0c7;
  --surface: #fefefd;
  --surface-2: #f5f5f1;
  --surface-3: #eeefea;
  --danger: #a64334;
  --danger-pale: #fbeeeb;
  --shadow-float: 0 6px 24px rgba(28, 35, 28, 0.1);
  --radius: 10px;
  --radius-sm: 6px;
  --font: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --topbar-h: 72px;
  --page: 1200px;
  --gutter: clamp(16px, 4vw, 40px);
  /* The forest band keeps its colours in both themes */
  --band: #1b4332;
  --band-ink: #f2f5f3;
  --band-ink-2: #c3d6ca;
  --band-line: rgba(242, 245, 243, 0.16);
  --on-accent: #ffffff;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --forest: #cfe3d7; --green: #5fb08a; --green-light: #7cc4a1; --green-pale: #1d3128;
    --gold-dark: #e0b64a; --gold-pale: #33301f;
    --ink: #f2f5f3; --ink-2: #c9d3cd; --muted: #97a39d;
    --line: #2a3a31; --line-strong: #3a4e43;
    --surface: #14201a; --surface-2: #0f1713; --surface-3: #1a2a22;
    --danger: #e0806f; --danger-pale: #3a1f1a;
    --shadow-float: 0 12px 32px rgba(0, 0, 0, 0.45);
    --band: #1f4a38;
    --on-accent: #0f1713;
  }
}
:root[data-theme="dark"] {
  color-scheme: dark;
  --forest: #cfe3d7; --green: #5fb08a; --green-light: #7cc4a1; --green-pale: #1d3128;
  --gold-dark: #e0b64a; --gold-pale: #33301f;
  --ink: #f2f5f3; --ink-2: #c9d3cd; --muted: #97a39d;
  --line: #2a3a31; --line-strong: #3a4e43;
  --surface: #14201a; --surface-2: #0f1713; --surface-3: #1a2a22;
  --danger: #e0806f; --danger-pale: #3a1f1a;
  --shadow-float: 0 12px 32px rgba(0, 0, 0, 0.45);
  --band: #1f4a38;
  --on-accent: #0f1713;
}

/* Base ------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--topbar-h) + 16px); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body {
  margin: 0; background: var(--surface); color: var(--ink);
  font-family: var(--font); font-size: 1rem; line-height: 1.6;
  font-synthesis: none; -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  caret-color: var(--green);
}
::selection { background: var(--gold-pale); color: var(--ink); }
* { scrollbar-width: thin; scrollbar-color: var(--line-strong) transparent; }
img, video, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: var(--green); text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:hover { color: var(--forest); }
h1, h2, h3, h4 { margin: 0; font-weight: 600; letter-spacing: -0.02em; line-height: 1.15; text-wrap: balance; color: var(--ink); }
p { margin: 0; text-wrap: pretty; }
ul, ol { margin: 0; padding: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; border-radius: 4px; }
[hidden] { display: none !important; }
.num { font-variant-numeric: tabular-nums; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.skip { position: absolute; left: 12px; top: -48px; z-index: 100; padding: 10px 14px; background: var(--green); color: var(--on-accent); border-radius: var(--radius-sm); font-weight: 600; text-decoration: none; }
.skip:focus { top: 12px; color: var(--on-accent); }

.wrap { width: 100%; max-width: var(--page); margin: 0 auto; padding: 0 var(--gutter); }
.measure { max-width: 64ch; }

/* Type scale: the Web Tool's 1.2 ratio, stretched at the top for marketing */
.t-display { font-size: clamp(2.5rem, 1.6rem + 3.6vw, 4.5rem); line-height: 1.02; letter-spacing: -0.035em; font-weight: 650; }
.t-h2 { font-size: clamp(1.75rem, 1.3rem + 1.6vw, 2.6rem); line-height: 1.08; letter-spacing: -0.03em; }
.t-h3 { font-size: 1.25rem; line-height: 1.25; }
.t-lead { font-size: clamp(1.0625rem, 1rem + 0.35vw, 1.25rem); line-height: 1.55; color: var(--ink-2); }
.t-body { font-size: 1rem; color: var(--ink-2); }
.t-small { font-size: 0.875rem; color: var(--ink-2); }
.t-note { font-size: 0.8125rem; color: var(--muted); }

/* Buttons: same anatomy as the Web Tool .btn, marketing height --------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 44px; padding: 0 18px; border-radius: var(--radius-sm);
  border: 1px solid var(--line-strong); background: var(--surface); color: var(--ink);
  font-weight: 550; font-size: 0.9375rem; line-height: 1; text-decoration: none; white-space: nowrap;
  transition: background-color 150ms ease-out, border-color 150ms ease-out, color 150ms ease-out;
}
.btn:hover { background: var(--surface-3); color: var(--ink); }
/* --btn-hover: forest in light; in dark the forest token turns pale, so hover lightens instead */
.btn.primary { --btn-hover: #1b4332; background: var(--green); border-color: var(--green); color: var(--on-accent); }
.btn.primary:hover { background: var(--btn-hover); border-color: var(--btn-hover); color: var(--on-accent); }
:root[data-theme="dark"] .btn.primary { --btn-hover: var(--green-light); }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn.primary { --btn-hover: var(--green-light); } }
:root[data-theme="dark"] .btn.primary:hover { color: #0f1713; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .btn.primary:hover { color: #0f1713; } }
.btn.quiet { border-color: transparent; background: transparent; color: var(--green); padding: 0 10px; }
.btn.quiet:hover { background: var(--green-pale); color: var(--forest); }
.btn.sm { height: 36px; padding: 0 14px; font-size: 0.875rem; }
.btn svg { width: 16px; height: 16px; flex: none; }

/* Status chip, as in the Web Tool */
.chip { display: inline-flex; align-items: center; gap: 6px; height: 24px; padding: 0 10px; border-radius: 999px;
  background: var(--gold-pale); color: var(--ink-2); font-size: 0.75rem; font-weight: 550; white-space: nowrap; }
.chip::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: var(--gold-dark); }
.chip.green { background: var(--green-pale); color: var(--forest); }
.chip.green::before { background: var(--green); }

/* Top bar: the Web Tool's .topbar, one size up ------------------------- */
.topbar { position: sticky; top: 0; z-index: 40; height: var(--topbar-h); background: var(--surface); border-bottom: 1px solid var(--line); }
.topbar .wrap { height: 100%; display: flex; align-items: center; gap: 24px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--ink); flex: none; }
/* Brand guide: the circle never below 60px on screen where space allows */
.brand img { height: 60px; width: auto; margin: -6px 0; }
.brand .logo-dark { display: none; }
:root[data-theme="dark"] .brand .logo-light { display: none; }
:root[data-theme="dark"] .brand .logo-dark { display: block; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .brand .logo-light { display: none; } :root:not([data-theme="light"]) .brand .logo-dark { display: block; } }
.topnav { display: flex; gap: 2px; }
.topnav a { padding: 7px 11px; border-radius: 8px; text-decoration: none; color: var(--ink-2); font-weight: 500; font-size: 0.9375rem; }
.topnav a:hover { background: var(--surface-3); color: var(--ink); }
.topnav a[aria-current="page"] { background: var(--green-pale); color: var(--forest); }
.topbar .spacer { flex: 1; }
.topbar .actions { display: flex; align-items: center; gap: 8px; }
.lang { position: relative; }
.lang summary { list-style: none; display: inline-flex; align-items: center; gap: 6px; height: 36px; padding: 0 10px; border-radius: 8px; color: var(--ink-2); font-size: 0.875rem; font-weight: 550; cursor: pointer; }
.lang summary::-webkit-details-marker { display: none; }
.lang summary:hover { background: var(--surface-3); color: var(--ink); }
.lang summary svg { width: 16px; height: 16px; }
.lang ul { position: absolute; right: 0; top: calc(100% + 6px); list-style: none; min-width: 160px; padding: 6px; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow-float); }
.lang li a { display: flex; justify-content: space-between; gap: 12px; padding: 8px 10px; border-radius: var(--radius-sm); color: var(--ink); text-decoration: none; font-size: 0.875rem; }
.lang li a:hover { background: var(--surface-3); }
.lang li a[aria-current="true"] { background: var(--green-pale); color: var(--forest); font-weight: 600; }
.lang li a span { color: var(--muted); font-variant-numeric: tabular-nums; }
.menu-toggle { display: none; }

@media (max-width: 1180px) {
  .topnav, .topbar .actions .btn:not(.primary) { display: none; }
  .menu-toggle { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border: 1px solid var(--line-strong); border-radius: 8px; background: var(--surface); color: var(--ink); }
  .menu-toggle svg { width: 20px; height: 20px; }
  .topbar.open .topnav { display: flex; flex-direction: column; position: absolute; left: 0; right: 0; top: var(--topbar-h); padding: 12px var(--gutter) 20px; background: var(--surface); border-bottom: 1px solid var(--line); box-shadow: var(--shadow-float); }
  .topbar.open .topnav a { padding: 12px; font-size: 1rem; }
  .topbar.open .topnav .mobile-only { display: block; }
}
.topnav .mobile-only { display: none; }
@media (max-width: 520px) { .brand img { height: 44px; } .topbar .wrap { gap: 12px; } .topbar .actions .btn.primary { padding: 0 12px; } }

/* Sections ---------------------------------------------------------------- */
.section { padding: clamp(64px, 9vw, 120px) 0; }
.section.tight { padding: clamp(48px, 6vw, 80px) 0; }
.section.alt { background: var(--surface-2); }
.section + .section:not(.alt):not(.band) { border-top: 1px solid var(--line); }
.section-head { display: grid; gap: 16px; margin-bottom: clamp(32px, 4vw, 56px); max-width: 760px; }
.section-head.split { max-width: none; grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); align-items: end; gap: 24px 64px; }
@media (max-width: 860px) { .section-head.split { grid-template-columns: 1fr; } }

.panel { background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.callout { border-radius: var(--radius-sm); padding: 12px 14px; font-size: 0.875rem; color: var(--ink-2); background: var(--surface-3); }
.callout.gold { background: var(--gold-pale); }

/* Footer ------------------------------------------------------------------ */
.site-footer { background: var(--surface-2); border-top: 1px solid var(--line); padding: 56px 0 32px; font-size: 0.875rem; color: var(--ink-2); }
.site-footer .cols { display: grid; grid-template-columns: 1.4fr repeat(3, 1fr); gap: 32px; }
/* three columns while the Tools column is switched off (site.config.json) */
@media (min-width: 861px) { .site-footer .cols:not(:has(> :nth-child(4))) { grid-template-columns: 1.4fr repeat(2, 1fr); } }
.site-footer h2 { font-size: 0.8125rem; font-weight: 600; color: var(--ink); margin-bottom: 12px; letter-spacing: 0; }
.site-footer ul { list-style: none; display: grid; gap: 8px; }
.site-footer a { color: var(--ink-2); text-decoration: none; }
.site-footer a:hover { color: var(--forest); text-decoration: underline; }
.site-footer .brand img { height: 56px; }
.site-footer .about { display: grid; gap: 14px; align-content: start; max-width: 34ch; }
.site-footer .legal { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px; margin-top: 48px; padding-top: 20px; border-top: 1px solid var(--line); font-size: 0.8125rem; color: var(--muted); }
.site-footer .legal a { color: var(--muted); }
@media (max-width: 860px) { .site-footer .cols { grid-template-columns: 1fr 1fr; } .site-footer .about { grid-column: 1 / -1; } }


.t-h1 { font-size: clamp(2.25rem, 1.6rem + 2.4vw, 3.5rem); line-height: 1.05; letter-spacing: -0.035em; font-weight: 650; }
.narrow { max-width: 860px; }
.ticks { list-style: none; display: grid; gap: 10px; }
.ticks li { position: relative; padding-left: 26px; color: var(--ink-2); font-size: 0.9375rem; }
.ticks li::before { content: ""; position: absolute; left: 3px; top: 7px; width: 11px; height: 6px; border-left: 2px solid var(--green); border-bottom: 2px solid var(--green); transform: rotate(-45deg); }
.ticks.cols { grid-template-columns: 1fr 1fr; gap: 0 32px; border-top: 1px solid var(--line); }
.ticks.cols li { padding-top: 14px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.ticks.cols li::before { top: 21px; }
@media (max-width: 700px) { .ticks.cols { grid-template-columns: 1fr; } }

/* Buttons on the forest band */
.btn.gold { background: var(--gold); border-color: var(--gold); color: #1b1b1b; }
.btn.gold:hover { background: #f0d48c; border-color: #f0d48c; color: #1b1b1b; }
.btn.ghost { background: transparent; border-color: rgba(242, 245, 243, 0.4); color: var(--band-ink); }
.btn.ghost:hover { background: rgba(242, 245, 243, 0.1); color: var(--band-ink); }

/* Inner page head */
.page-head { padding: clamp(40px, 6vw, 80px) 0 clamp(24px, 3vw, 40px); border-bottom: 1px solid var(--line); }
.page-head-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 20px 64px; align-items: end; }
.page-head-grid .t-lead { max-width: 52ch; }
@media (max-width: 860px) { .page-head-grid { grid-template-columns: 1fr; } }
.crumbs { font-size: 0.8125rem; color: var(--muted); margin-bottom: 14px; }
.crumbs a { color: var(--muted); text-decoration: none; }
.crumbs a:hover { color: var(--forest); text-decoration: underline; }
.legal-note { font-size: 0.875rem; color: var(--ink-2); background: var(--gold-pale); border-radius: var(--radius-sm); padding: 10px 14px; max-width: 72ch; }

/* Closing band on inner pages */
.cta-band { padding: clamp(48px, 6vw, 80px) 0; }
.cta-inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 24px 48px; }
.cta-inner p { color: var(--band-ink-2); margin-top: 8px; }
.cta-actions { display: flex; flex-wrap: wrap; gap: 10px; }

/* Method */
table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
th, td { text-align: left; padding: 10px 8px 10px 0; border-bottom: 1px solid var(--line); }
thead th { font-size: 0.8125rem; font-weight: 550; color: var(--muted); }
tbody th { font-weight: 550; }
td.num { font-variant-numeric: tabular-nums; }
.deliver { display: grid; grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.1fr); gap: 24px 64px; align-items: start; }
.deliver > div { display: grid; gap: 16px; }
@media (max-width: 900px) { .deliver { grid-template-columns: 1fr; } }


/* Method page, as designed on the canvas (direction A): one chapter layout, one leading figure each */
.m-head .t-h1 { font-size: clamp(2.5rem, 1.6rem + 3vw, 4rem); line-height: 1; letter-spacing: -0.04em; text-wrap: balance; }
.m-lead { display: grid; gap: 14px; }
.m-lead .t-lead { color: var(--ink); font-size: clamp(1.125rem, 1rem + 0.4vw, 1.25rem); line-height: 1.5; }
.m-lead p:not(.t-lead) { max-width: 56ch; font-size: 1.0625rem; line-height: 1.55; color: var(--ink-2); }

.m-overview { padding: clamp(32px, 4vw, 48px) 0 0; }
.m-chain { display: flex; flex-wrap: wrap; align-items: stretch; gap: 12px; padding: 12px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface); }
.m-chain ol { list-style: none; display: flex; flex: 1 1 100%; }
.m-chain li { display: flex; flex: 1; align-items: center; }
.m-chain li + li::before { content: "→"; flex: none; padding: 0 4px; color: var(--line-strong); }
.m-chain li a { display: flex; flex: 1; align-items: center; gap: 12px; min-height: 48px; padding: 0 16px; border-radius: 8px; color: var(--ink); font-weight: 500; text-decoration: none; }
.m-chain li a:hover { background: var(--surface-2); color: var(--forest); }
.m-chain li span { display: grid; place-items: center; flex: none; width: 28px; height: 28px; border-radius: 50%; background: #1b4332; color: #fff; font-size: 0.75rem; font-weight: 600; }
.m-chain li:last-child span { background: var(--gold); color: #1b1b1b; }
.m-claims { list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: 8px 32px; margin-top: 20px; font-size: 0.9375rem; }
.m-claims li { position: relative; padding-left: 22px; font-weight: 500; color: var(--ink); }
.m-claims li::before { content: ""; position: absolute; left: 3px; top: 6px; width: 10px; height: 5px; border-left: 2px solid var(--green); border-bottom: 2px solid var(--green); transform: rotate(-45deg); }
.m-claims .m-claims-link { padding-left: 0; font-weight: 400; }
.m-claims .m-claims-link::before { content: none; }
.m-claims a { text-underline-offset: 4px; }

.m-chapter { padding: clamp(64px, 7vw, 96px) 0 0; }
.m-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 40px 56px; align-items: center; padding-top: clamp(48px, 5vw, 64px); background: linear-gradient(var(--line), var(--line)) center top / calc(100% - 2 * var(--gutter)) 1px no-repeat; }
.m-grid.m-top { align-items: start; }
.m-n { font-size: 0.875rem; color: var(--muted); }
.m-text .t-h2 { margin-top: 8px; font-size: clamp(2rem, 1.5rem + 1.4vw, 2.5rem); text-wrap: balance; }
.m-body { margin-top: 16px; max-width: 42ch; font-size: 1.0625rem; line-height: 1.6; color: var(--ink-2); }
.m-hero { margin-top: 40px; }
.m-hero-v { font-size: clamp(3rem, 2.2rem + 2.6vw, 4rem); font-weight: 650; letter-spacing: -0.045em; line-height: 1; color: var(--forest); }
.m-hero-l { margin-top: 12px; font-weight: 500; color: var(--ink); }
.m-hero-n { font-size: 0.875rem; color: var(--muted); }
.m-more { display: flex; flex-wrap: wrap; gap: 12px 40px; margin: 32px 0 0; padding-top: 20px; border-top: 1px solid var(--line); }
.m-more div { display: flex; flex-direction: column; }
.m-more dt { order: 2; font-size: 0.875rem; color: var(--muted); }
.m-more dd { order: 1; margin: 0; font-size: 1.5rem; font-weight: 600; letter-spacing: -0.02em; color: var(--ink); white-space: nowrap; }
.m-facts { margin: 28px 0 0; display: grid; border-top: 1px solid var(--line); }
.m-facts div { display: grid; grid-template-columns: 7rem minmax(0, 1fr); gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 0.875rem; }
.m-facts dt { color: var(--muted); }
.m-facts dd { margin: 0; color: var(--ink); font-weight: 500; }
.m-figure { margin: 0; }
.m-figure img { display: block; width: 100%; height: auto; border: 1px solid var(--line); border-radius: 12px; background: #fff; }
.m-figure figcaption { margin-top: 12px; font-size: 0.875rem; color: var(--muted); max-width: 70ch; }
.m-figure .scale { margin-top: 14px; font-size: 0.8125rem; }
.m-charts { display: grid; gap: 16px; }

/* Microclimate: leaf heat days as two bars */
.m-heat { padding: 28px; border: 1px solid var(--line); border-radius: 12px; background: var(--surface-2); }
.m-heat .m-heat-h { margin: 0 0 20px; font-size: 1rem; font-weight: 600; color: var(--ink); }
.m-heat dl { margin: 0; display: grid; gap: 16px; }
.m-heat dl div { display: grid; gap: 6px; }
.m-heat dt { font-size: 0.875rem; color: var(--ink-2); }
.m-heat dd { margin: 0; display: flex; align-items: center; gap: 14px; }
.m-heat dd i { display: block; width: var(--w); height: 28px; border-radius: 6px; background: var(--line-strong); }
.m-heat .on dd i { background: #2d6a4f; }
.m-heat dd b { font-size: 1.75rem; font-weight: 650; letter-spacing: -0.03em; color: var(--ink); }
.m-heat .on dd b { color: var(--forest); }

/* Validation band: heading left, the four steps right, the trial chart below */
.m-val { margin-top: clamp(64px, 7vw, 96px); }
.m-val-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.4fr); gap: 40px 64px; align-items: start; }
.m-val-grid h2 { max-width: 16ch; font-size: clamp(2rem, 1.5rem + 1.4vw, 2.5rem); line-height: 1.1; text-wrap: balance; }
.m-val-steps { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 32px; }
.m-val-steps li { display: grid; gap: 4px; align-content: start; padding-top: 16px; border-top: 1px solid var(--band-line); }
.m-val-steps span { font-size: 0.875rem; color: var(--band-ink-2); }
.m-val-steps h3 { font-size: 1.125rem; color: var(--band-ink); }
.m-val-steps p { font-size: 0.9375rem; color: var(--band-ink-2); }
.m-val-chart { margin-top: clamp(40px, 5vw, 64px); }
.m-val-chart .chart { color: var(--ink); }

@media (max-width: 1020px) {
  .m-grid, .m-val-grid { grid-template-columns: 1fr; }
}
@media (max-width: 720px) {
  .m-chain ol { flex-direction: column; flex-basis: 100%; }
  .m-chain li { flex-direction: column; align-items: stretch; }
  .m-chain li + li::before { content: "↓"; align-self: flex-start; padding: 0 0 0 26px; line-height: 1.2; color: var(--muted); }
  .m-val-steps { grid-template-columns: 1fr; }
  .m-heat { padding: 20px; }
}

/* Charts: HTML bars with real text, in the showcase report's palette (skeleton_report BRAND):
   crops wheat deep forest, spinach gold, pasture light green; zones under the modules deep forest,
   between the rows light green, farming zone forest green, open field gold. Dark theme lifts the greens. */
:root { --series-1: #1b4332; --series-2: #e9c46a; --series-3: #40916c; --zone-under: #1b4332; --zone-between: #40916c; --zone-farming: #2d6a4f; --zone-open: #e9c46a; }
:root[data-theme="dark"] { --series-1: #95d5b2; --series-2: #e9c46a; --series-3: #40916c; --zone-under: #95d5b2; --zone-between: #40916c; --zone-farming: #52b788; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) { --series-1: #95d5b2; --series-2: #e9c46a; --series-3: #40916c; --zone-under: #95d5b2; --zone-between: #40916c; --zone-farming: #52b788; } }
.s1 { --c: var(--series-1); } .s2 { --c: var(--series-2); } .s3 { --c: var(--series-3); }
.z-under { --c: var(--zone-under); } .z-between { --c: var(--zone-between); } .z-farming { --c: var(--zone-farming); } .z-open { --c: var(--zone-open); }

/* Colour scale under a model figure (method page and homepage) */
.scale { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 4px 10px; margin-top: 12px; font-size: 0.75rem; color: var(--muted); }
.scale span { grid-column: 1 / -1; color: var(--ink-2); font-weight: 500; }
.scale i { grid-column: 1 / -1; grid-row: 2; height: 8px; border-radius: 4px; }
.scale b { grid-row: 3; font-weight: 500; font-variant-numeric: tabular-nums; }
.scale b:last-child { grid-column: 3; }
.scale-light i { background: linear-gradient(90deg, #1b4332 0%, #2d6a4f 24%, #8ac416 44%, #e9c46a 68%, #fbf4dc 100%); box-shadow: inset 0 0 0 1px var(--line); }
.scale-soil i { background: linear-gradient(90deg, #f6f1df 0%, #a9cbe3 36%, #3f7fbf 73%, #1b4f8f 100%); box-shadow: inset 0 0 0 1px var(--line); }
.chart { --lab: 9.5rem; --reserve: 7.5rem; margin: 0; display: grid; gap: 14px; padding: 20px 22px 16px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); }
.ch-head { display: grid; gap: 4px; }
.ch-head h3 { font-size: 1rem; }
.ch-head p { font-size: 0.8125rem; color: var(--muted); max-width: 70ch; }
.ch-legend { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 0.8125rem; color: var(--ink-2); }
.ch-legend li { display: inline-flex; align-items: center; gap: 7px; }
.ch-legend .sw { width: 10px; height: 10px; border-radius: 3px; background: var(--c); }
.ch-rows { display: grid; gap: 10px; padding-right: var(--reserve); }
.ch-row { display: flex; align-items: center; gap: 12px; }
.ch-label { flex: 0 0 var(--lab); min-width: 0; hyphens: auto; overflow-wrap: break-word; font-size: 0.8125rem; color: var(--ink-2); line-height: 1.3; }
.ch-label small { display: block; color: var(--muted); font-size: 0.75rem; }
.ch-label.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }
.ch-group { display: flex; align-items: center; gap: 12px; padding: 4px 0; }
.ch-group + .ch-group { border-top: 1px solid var(--line); padding-top: 10px; }
.ch-glabel { flex: 0 0 var(--lab); min-width: 0; hyphens: auto; overflow-wrap: break-word; font-size: 0.8125rem; font-weight: 550; color: var(--ink); }
.ch-bars { flex: 1; display: grid; gap: 4px; }
.ch-track { position: relative; flex: 1; height: 18px; }
.ch-row.tight .ch-track { height: 14px; }
.ch-bar { position: absolute; top: 0; bottom: 0; left: var(--a); width: calc(var(--b) - var(--a)); background: var(--c); border-radius: 0 4px 4px 0; }
.ch-range { position: absolute; top: 50%; height: 6px; margin-top: -3px; left: var(--a); width: calc(var(--b) - var(--a)); background: var(--c); border-radius: 3px; }
.ch-dot { position: absolute; top: 50%; left: var(--x); width: 12px; height: 12px; margin: -6px 0 0 -6px; border-radius: 50%; background: var(--c); box-shadow: 0 0 0 2px var(--surface); pointer-events: none; }
.ch-val { position: absolute; z-index: 1; top: 50%; left: calc(var(--b) + 5px); transform: translateY(-50%); padding: 0 3px; background: var(--surface); border-radius: 3px; font-size: 0.8125rem; font-weight: 600; color: var(--ink); white-space: nowrap; font-variant-numeric: tabular-nums; pointer-events: none; }
.ch-val small { font-weight: 400; color: var(--muted); margin-left: 4px; }
.ch-ref { position: absolute; top: -5px; bottom: -5px; left: var(--x); border-left: 1px solid var(--ink-2); opacity: 0.45; pointer-events: none; }
.ch-axis { position: relative; height: 22px; margin: 2px var(--reserve) 0 calc(var(--lab) + 12px); border-top: 1px solid var(--line); }
.ch-axis span { position: absolute; top: 5px; left: var(--x); transform: translateX(-50%); font-size: 0.75rem; color: var(--muted); font-variant-numeric: tabular-nums; }
.ch-data summary { cursor: pointer; font-size: 0.8125rem; color: var(--green); font-weight: 550; width: max-content; }
.ch-data table { margin-top: 8px; font-size: 0.8125rem; }
.ch-tip { position: fixed; z-index: 60; pointer-events: none; padding: 7px 10px; border-radius: 6px; background: var(--ink); color: var(--surface); font-size: 0.75rem; line-height: 1.4; max-width: 260px; transform: translate(-50%, calc(-100% - 12px)); opacity: 0; transition: opacity 120ms ease-out; }
.ch-tip.on { opacity: 1; }
.ch-bar[data-tip]:hover, .ch-range[data-tip]:hover { filter: brightness(1.08); }
@media (max-width: 560px) {
  .chart { --lab: 6.25rem; --reserve: 3.5rem; padding: 16px; }
  .ch-val small { display: none; }
}


/* News */
.news-list { display: grid; }
.news-item:first-child { padding-top: 8px; }
.news-item:last-child { border-bottom: 0; }
.news-item { display: grid; grid-template-columns: minmax(0, 15rem) minmax(0, 1fr); gap: 16px 56px; padding: clamp(32px, 4vw, 56px) 0; border-bottom: 1px solid var(--line); }
.news-meta { display: grid; gap: 8px; align-content: start; justify-items: start; position: sticky; top: calc(var(--topbar-h) + 24px); }
.news-date { font-size: 1.125rem; font-weight: 600; letter-spacing: -0.01em; color: var(--ink); }
.news-place { font-size: 0.875rem; color: var(--muted); }
.news-body { display: grid; gap: 16px; max-width: 72ch; }
.news-body h2 { font-size: clamp(1.5rem, 1.2rem + 1vw, 2rem); line-height: 1.15; letter-spacing: -0.025em; }
.news-body > p:not(.t-lead) { color: var(--ink-2); }
.news-points { display: grid; gap: 0; padding: 0; list-style: none; counter-reset: fm; border-top: 1px solid var(--line); }
.news-points li { counter-increment: fm; display: grid; grid-template-columns: 28px 1fr; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--line); color: var(--ink-2); font-size: 0.9375rem; }
.news-points li::before { content: counter(fm); width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; background: var(--surface-3); color: var(--ink-2); font-size: 0.75rem; font-weight: 600; margin-top: 1px; }
.news-facts { margin: 0; display: grid; border-top: 1px solid var(--line); }
.news-facts div { display: grid; grid-template-columns: 8rem 1fr; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 0.9375rem; }
.news-facts dt { color: var(--muted); }
.news-facts dd { margin: 0; color: var(--ink); }
.news-link a { font-weight: 550; }
.talks { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.talk { display: grid; gap: 10px; align-content: start; padding: 18px; background: var(--surface-2); border-radius: var(--radius); }
.talk header { display: flex; align-items: center; gap: 12px; }
.talk header img { width: 48px; height: 48px; border-radius: 50%; object-fit: cover; object-position: 50% 20%; }
.talk h3 { font-size: 0.9375rem; }
.talk header p { font-size: 0.8125rem; color: var(--muted); }
.talk-title { font-weight: 600; color: var(--ink); line-height: 1.4; }
.talk > p:not(.talk-title) { font-size: 0.9375rem; color: var(--ink-2); }
@media (max-width: 860px) { .news-item { grid-template-columns: 1fr; } .news-meta { position: static; display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; } .talks { grid-template-columns: 1fr; } }
/* Home teaser */
.news-head { display: flex; align-items: end; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.news-teasers { list-style: none; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; }
.news-teasers a { display: grid; gap: 8px; align-content: start; justify-items: start; height: 100%; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); text-decoration: none; color: var(--ink); transition: border-color 150ms ease-out, background-color 150ms ease-out; }
.news-teasers a:hover { border-color: var(--green); background: var(--green-pale); color: var(--ink); }
.news-teasers .news-date { font-size: 0.875rem; }
.news-teasers h3 { font-size: 1.0625rem; line-height: 1.35; }
@media (max-width: 900px) { .news-teasers { grid-template-columns: 1fr; } }

/* FAQ */
.qa-items { border-top: 1px solid var(--line); }
.qa-item { border-bottom: 1px solid var(--line); }
.qa-item summary { list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 24px; padding: 20px 4px; cursor: pointer; border-radius: var(--radius-sm); }
.qa-item summary::-webkit-details-marker { display: none; }
.qa-item summary h2 { font-size: 1.125rem; font-weight: 600; letter-spacing: -0.01em; }
.qa-item summary svg { width: 20px; height: 20px; flex: none; color: var(--green); transition: transform 200ms ease-out; }
.qa-item[open] summary svg { transform: rotate(45deg); }
.qa-item summary:hover h2 { color: var(--forest); }
.qa-body { padding: 0 4px 22px; }
.qa-body p { color: var(--ink-2); max-width: 70ch; }

/* Glossary */
.terms { margin: 0; border-top: 1px solid var(--line); }
.term { display: grid; grid-template-columns: minmax(0, 0.8fr) minmax(0, 1.6fr); gap: 8px 40px; padding: 18px 0; border-bottom: 1px solid var(--line); }
.term dt { font-weight: 600; }
.term dfn { font-style: normal; }
.term dd { margin: 0; color: var(--ink-2); font-size: 0.9375rem; }
:target { scroll-margin-top: calc(var(--topbar-h) + 24px); }
.term:target { background: var(--gold-pale); box-shadow: -12px 0 0 var(--gold-pale), 12px 0 0 var(--gold-pale); }
@media (max-width: 700px) { .term { grid-template-columns: 1fr; } }

/* Evidence */
.refs { list-style: none; display: grid; border-top: 1px solid var(--line); }
.refs li { display: flex; gap: 16px; align-items: flex-start; padding: 16px 0; border-bottom: 1px solid var(--line); }
.refs h3 { font-size: 0.9375rem; font-weight: 550; line-height: 1.45; letter-spacing: 0; text-wrap: pretty; }
.refs p { color: var(--muted); font-size: 0.875rem; margin-top: 4px; }
.refs .chip { margin-top: 2px; }

/* Legal text */
.prose { max-width: 72ch; }
.prose h1 { font-size: clamp(2rem, 1.6rem + 1.6vw, 2.75rem); letter-spacing: -0.03em; margin-bottom: 24px; }
.prose h2 { font-size: 1.125rem; margin: 32px 0 10px; letter-spacing: -0.01em; }
.prose p, .prose li { color: var(--ink-2); font-size: 0.9375rem; }
.prose p + p { margin-top: 10px; }
.prose ul { padding-left: 20px; margin: 8px 0 12px; display: grid; gap: 4px; }
.prose .last-updated { color: var(--muted); font-size: 0.875rem; }

.notfound { display: grid; gap: 16px; justify-items: start; padding: 40px 0; }

/* ======================================================================
   Home
   ====================================================================== */

/* Hero: field footage under a forest wash, one statement on top. Same in light and dark. */
.hero { position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: flex-end; min-height: clamp(560px, calc(100svh - var(--topbar-h)), 820px); background: #1b4332; color: #f2f5f3; }
.hero-bg { position: absolute; inset: 0; z-index: -1; }
.hero-bg img, .hero-bg video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 60%; }
.hero-bg video { opacity: 0; transition: opacity 600ms ease-out; }
.hero-bg video.playing { opacity: 1; }
.hero-bg::after { content: ""; position: absolute; inset: 0; background:
  linear-gradient(90deg, rgba(14, 38, 27, 0.8) 0%, rgba(14, 38, 27, 0.52) 42%, rgba(14, 38, 27, 0.1) 78%),
  linear-gradient(0deg, rgba(14, 38, 27, 0.6) 0%, rgba(14, 38, 27, 0) 50%); }
.hero-copy { padding-top: 64px; padding-bottom: clamp(56px, 8vw, 96px); }
.hero-copy h1 { max-width: 12ch; color: #f2f5f3; font-size: clamp(2.75rem, 1.6rem + 4vw, 5.25rem); line-height: 1; letter-spacing: -0.04em; }
.hero-lead { margin-top: 24px; max-width: 34ch; font-size: clamp(1.0625rem, 1rem + 0.4vw, 1.3rem); line-height: 1.5; color: rgba(242, 245, 243, 0.94); }
.hero-proof { list-style: none; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin-top: 18px; font-size: 0.875rem; color: #c3d6ca; }
.hero-proof li { display: inline-flex; align-items: center; gap: 12px; }
.hero-proof li + li::before { content: ""; width: 4px; height: 4px; border-radius: 50%; background: var(--gold); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 36px; }
.hero-toggle { position: absolute; right: var(--gutter); bottom: 20px; display: inline-flex; align-items: center; gap: 8px; height: 34px; padding: 0 12px; border: 0; border-radius: 999px; background: rgba(0, 0, 0, 0.28); color: rgba(255, 255, 255, 0.88); font: 500 0.75rem var(--font); cursor: pointer; backdrop-filter: blur(6px); }
.hero-toggle:hover { background: rgba(0, 0, 0, 0.42); }
.hero-toggle:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; }
.hero-toggle svg { width: 13px; height: 13px; }
.hero-toggle .i-play, .hero-toggle[aria-pressed="true"] .i-pause { display: none; }
.hero-toggle[aria-pressed="true"] .i-play { display: block; }
.hero .btn:focus-visible { outline-color: var(--gold); }
@media (max-width: 640px) { .hero-copy { padding-bottom: 72px; } .hero-bg::after { background: linear-gradient(0deg, rgba(14, 38, 27, 0.88) 0%, rgba(14, 38, 27, 0.55) 60%, rgba(14, 38, 27, 0.3) 100%); } }

/* How clients use us: five situations as one flow; the chosen one opens its study below */
.uses-title { margin-bottom: clamp(32px, 4vw, 48px); }
.flow { --g: 16px; --n: 5; position: relative; display: grid; grid-template-columns: repeat(var(--n), minmax(0, 1fr)); gap: 0 var(--g); align-items: stretch; }
.flow::before { content: ""; position: absolute; top: 14px; left: 14px; right: calc((100% - (var(--n) - 1) * var(--g)) / var(--n) - 14px); height: 1px; background: var(--line-strong); }
.flow-step { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 10px; padding: 0; border: 0; background: none; color: var(--ink); font: inherit; text-align: left; cursor: pointer; }
.flow-step:focus-visible { outline: none; }
.flow-step:focus-visible .flow-card { outline: 2px solid var(--green); outline-offset: 2px; }
.flow-dot { position: relative; z-index: 1; display: grid; place-items: center; width: 28px; height: 28px; border: 1px solid var(--line-strong); border-radius: 50%; background: var(--surface); color: var(--ink-2); font-size: 0.8125rem; font-weight: 600; transition: background-color 150ms ease-out, border-color 150ms ease-out, color 150ms ease-out; }
.flow-stage { font-size: 0.8125rem; color: var(--muted); }
.flow-card { display: flex; flex-direction: column; flex: 1; width: 100%; padding: 20px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface); transition: border-color 150ms ease-out, box-shadow 150ms ease-out, background-color 150ms ease-out; }
.flow-title { font-size: 1.125rem; font-weight: 600; line-height: 1.25; letter-spacing: -0.01em; }
.flow-line { margin-top: 8px; font-size: 0.9375rem; line-height: 1.5; color: var(--ink-2); }
.flow-format { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-top: auto; padding-top: 20px; font-size: 0.8125rem; color: var(--muted); }
.flow-format::after { content: ""; flex: none; width: 7px; height: 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); margin-top: -4px; transition: transform 200ms ease-out; }
.flow-step:hover .flow-card { border-color: var(--line-strong); background: var(--surface-2); }
.flow-step:hover .flow-dot { border-color: var(--green); }
.flow-step[aria-expanded="true"] .flow-dot { border-color: #1b4332; background: #1b4332; color: #fff; }
.flow-step[aria-expanded="true"] .flow-card { border-color: var(--green); box-shadow: inset 0 0 0 1px var(--green); background: var(--surface); }
.flow-step[aria-expanded="true"] .flow-title { color: var(--forest); }
.flow-step[aria-expanded="true"] .flow-format { color: var(--green); }
.flow-step[aria-expanded="true"] .flow-format::after { transform: rotate(225deg); margin-top: 4px; }

.flow-panel { position: relative; grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr) auto; gap: 24px 48px; align-items: start; margin-top: 18px; padding: 28px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--surface-2); }
.flow-panel[hidden] { display: none; }
.flow.ready .flow-panel { grid-row: 2; }
.flow-panel::before { content: ""; position: absolute; top: -7px; left: calc((100% - (var(--n) - 1) * var(--g)) / var(--n) * var(--i) + var(--g) * var(--i) + 34px); width: 12px; height: 12px; border-left: 1px solid var(--line); border-top: 1px solid var(--line); background: var(--surface-2); transform: rotate(45deg); }
.flow-kicker { font-size: 0.8125rem; color: var(--muted); }
.flow-panel h3 { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin-top: 4px; font-size: 1.25rem; }
.flow-panel-text > p:last-child { margin-top: 8px; max-width: 58ch; font-size: 0.9375rem; color: var(--ink-2); }
.flow-panel dl { margin: 0; display: grid; gap: 8px; padding-top: 22px; }
.flow-panel dl div { display: grid; grid-template-columns: 6.5rem minmax(0, 1fr); gap: 12px; font-size: 0.875rem; }
.flow-panel dt { color: var(--muted); }
.flow-panel dd { margin: 0; color: var(--ink); font-weight: 500; }
.flow-panel .btn { margin-top: 22px; }
@media (prefers-reduced-motion: no-preference) { .flow-panel:not([hidden]) { animation: flow-in 220ms ease-out; } }
@keyframes flow-in { from { opacity: 0; transform: translateY(-4px); } to { opacity: 1; transform: none; } }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .flow-step[aria-expanded="true"] .flow-dot { border-color: var(--green-light); background: var(--green-light); color: #0f1713; } }
:root[data-theme="dark"] .flow-step[aria-expanded="true"] .flow-dot { border-color: var(--green-light); background: var(--green-light); color: #0f1713; }

/* Narrow: the flow runs down the page, each study opens right under its step */
@media (max-width: 1020px) {
  .flow { display: flex; flex-direction: column; }
  .flow::before { top: 14px; bottom: 14px; left: 14px; right: auto; width: 1px; height: auto; }
  .flow-step { display: grid; grid-template-columns: 28px minmax(0, 1fr); gap: 4px 16px; padding-bottom: 14px; }
  .flow-dot { grid-row: 1 / span 2; }
  .flow-stage { align-self: center; }
  .flow-card { grid-column: 2; }
  .flow-panel { grid-template-columns: 1fr; gap: 0; margin: -4px 0 18px 44px; padding: 20px; }
  .flow-panel::before { display: none; }
  .flow-panel dl { padding-top: 16px; }
  .flow-panel .btn { justify-self: start; margin-top: 18px; }
}

/* Crop question: the question first, the comparison as its answer */
.crop-head { margin-bottom: 0; }
.crop-head h2 { max-width: 20ch; }
.crop .cmp-stage { margin-top: clamp(16px, 3vw, 40px); }

/* Yield ranges over twenty seasons, beside the national rules */
.ys-wrap { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: 32px 56px; align-items: center; margin-top: clamp(40px, 5vw, 64px); }
.yield-sheet { --lab: 6.5rem; --val: 4.5rem; margin: 0; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 1px 2px rgba(27, 67, 50, 0.04), 0 12px 32px -16px rgba(27, 67, 50, 0.18); }
.ys-head { display: flex; flex-wrap: wrap; align-items: flex-start; justify-content: space-between; gap: 16px; padding: 20px 24px; border-bottom: 1px solid var(--line); }
.ys-kicker { font-size: 0.8125rem; color: var(--muted); }
.ys-head h3 { margin-top: 4px; font-size: 1.25rem; }
.ys-toggle { display: inline-flex; padding: 2px; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.ys-toggle button { height: 32px; padding: 0 12px; border: 0; border-radius: 4px; background: transparent; color: var(--ink-2); font: 500 0.875rem var(--font); cursor: pointer; }
.ys-toggle button:hover { background: var(--surface-3); color: var(--ink); }
.ys-toggle button[aria-checked="true"] { background: #1b4332; color: #fff; }
.ys-toggle button:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.ys-chart { padding: 24px 24px 4px; }
.ys-plot { position: relative; }
.ys-ref { position: absolute; top: 0; bottom: 0; left: calc(var(--lab) + 12px); right: calc(var(--val) + 12px); pointer-events: none; }
.ys-below { position: absolute; top: 0; bottom: 0; left: 0; width: var(--x); background: var(--danger-pale); }
.ys-din, .ys-open { position: absolute; top: 0; bottom: 0; left: var(--x); }
.ys-din { border-left: 1px dashed var(--danger); }
.ys-open { border-left: 1px solid var(--ink-2); }
.ys-rows { list-style: none; position: relative; display: grid; gap: 18px; padding: 10px 0; }
.ys-rows li { display: grid; grid-template-columns: var(--lab) minmax(0, 1fr) var(--val); gap: 12px; align-items: center; }
.ys-crop { font-weight: 500; }
.ys-track { position: relative; height: 28px; }
.ys-range { position: absolute; top: 50%; left: var(--a); width: calc(var(--b) - var(--a)); height: 8px; margin-top: -4px; border-radius: 4px; background: linear-gradient(90deg, #95d5b2, #2d6a4f); }
.ys-dot { position: absolute; top: 50%; left: var(--m); width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%; background: #1b4332; box-shadow: 0 0 0 2px var(--surface), 0 1px 3px rgba(0, 0, 0, 0.2); }
@media (prefers-reduced-motion: no-preference) { .ys-range { transition: left 300ms ease-out, width 300ms ease-out; } .ys-dot { transition: left 300ms ease-out; } }
.ys-val { text-align: right; font-size: 1.125rem; font-weight: 600; letter-spacing: -0.02em; }
.ys-axis { position: relative; height: 24px; margin: 4px calc(var(--val) + 12px) 0 calc(var(--lab) + 12px); border-top: 1px solid var(--line); font-size: 0.75rem; color: var(--muted); }
.ys-axis span { position: absolute; top: 5px; left: var(--x); transform: translateX(-50%); }
.ys-legend { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 18px; margin-top: 12px; font-size: 0.8125rem; color: var(--ink-2); }
.ys-legend li { display: inline-flex; align-items: center; gap: 8px; }
.ys-legend i { flex: none; }
.lg-dot { width: 12px; height: 12px; border-radius: 50%; background: #1b4332; }
.lg-range { width: 24px; height: 8px; border-radius: 4px; background: linear-gradient(90deg, #95d5b2, #2d6a4f); }
.lg-din { height: 12px; border-left: 1px dashed var(--danger); }
.lg-open { height: 12px; border-left: 1px solid var(--ink-2); }
.ys-parcel { margin: 20px 0 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); border-top: 1px solid var(--line); }
.ys-parcel div { padding: 16px 20px 18px; }
.ys-parcel div + div { border-left: 1px solid var(--line); }
.ys-parcel dt { min-height: 2.9em; font-size: 0.8125rem; font-weight: 500; line-height: 1.45; color: var(--ink-2); }
.ys-parcel dd { margin: 0; }
.ys-parcel dd.num { margin-top: 4px; font-size: 1.5rem; font-weight: 600; letter-spacing: -0.03em; line-height: 1.15; color: var(--ink); white-space: nowrap; }
.ys-parcel dd + dd { margin-top: 2px; font-size: 0.75rem; line-height: 1.4; color: var(--muted); }
.ys-aside h3 { font-size: 1.25rem; }
.ys-aside p { margin-top: 8px; font-size: 0.9375rem; color: var(--ink-2); }
.ys-aside ul { list-style: none; display: grid; gap: 10px; margin-top: 18px; }
.ys-aside li { display: flex; align-items: center; gap: 10px; font-size: 0.9375rem; font-weight: 550; }
.ys-aside .rules-more { margin-top: 6px; font-weight: 550; }
@media (max-width: 1020px) { .ys-wrap { grid-template-columns: 1fr; } }
@media (max-width: 640px) {
  .yield-sheet { --lab: 4.5rem; --val: 3.5rem; }
  .ys-head, .ys-chart { padding-left: 16px; padding-right: 16px; }
  .ys-parcel { grid-template-columns: 1fr 1fr; }
  .ys-parcel div { padding: 14px 16px; }
  .ys-parcel div:nth-child(3) { border-left: 0; }
  .ys-parcel div:nth-child(n + 3) { border-top: 1px solid var(--line); }
}

.cmp { margin: 0; position: relative; }
.cmp-stage { position: relative; margin-top: clamp(8px, 2vw, 24px); height: clamp(300px, 44vw, 640px); user-select: none; -webkit-user-select: none; touch-action: pan-y; }
.cmp-svg { width: 100%; height: 100%; overflow: visible; }
.cmp-svg .sun { fill: var(--gold); }
.cmp-svg .rays line { stroke: var(--gold-dark); stroke-width: 1.25; stroke-linecap: round; stroke-dasharray: 2 7; opacity: 0.7; }
/* FSPM wheat in side view; leaf tone follows the light the leaf receives */
.cmp-svg .fspm .stems line { stroke: #5b8f4e; stroke-width: 0.9; }
.cmp-svg .fspm .leaves path { stroke: none; }
.cmp-svg .fspm .l1 { fill: #4a9a4f; } .cmp-svg .fspm .l2 { fill: #37813f; } .cmp-svg .fspm .l3 { fill: #276632; }
.cmp-svg .fspm .spikes line { stroke: #c49a3a; stroke-width: 1.4; stroke-linecap: round; }
:root[data-theme="dark"] .cmp-svg .fspm .l1 { fill: #5cb362; } :root[data-theme="dark"] .cmp-svg .fspm .l2 { fill: #489a4f; } :root[data-theme="dark"] .cmp-svg .fspm .l3 { fill: #367f3d; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cmp-svg .fspm .l1 { fill: #5cb362; } :root:not([data-theme="light"]) .cmp-svg .fspm .l2 { fill: #489a4f; } :root:not([data-theme="light"]) .cmp-svg .fspm .l3 { fill: #367f3d; } }
.cmp-svg .layer-labels text { fill: var(--ink-2); font: 500 13px var(--font); }
.cmp-svg .crop-labels text { fill: var(--ink); font: 600 13px var(--font); font-variant-numeric: tabular-nums; paint-order: stroke; stroke: var(--surface); stroke-width: 4px; stroke-linejoin: round; }
.cmp-svg .light-open { fill: var(--gold); }
.cmp-svg .post { stroke: var(--ink-2); stroke-width: 3; stroke-linecap: round; }
.cmp-svg .module { stroke: #1f3a5a; stroke-width: 7; stroke-linecap: round; }
:root[data-theme="dark"] .cmp-svg .module { stroke: #8fb3d9; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .cmp-svg .module { stroke: #8fb3d9; } }
.cmp-svg .axis { fill: var(--surface); stroke: var(--ink-2); stroke-width: 2; }
.cmp-svg .ground { stroke: var(--ink-2); stroke-width: 1.5; }
.cmp-svg .soil { fill: var(--surface-2); }
.cmp-svg .dim line { stroke: var(--muted); stroke-width: 1; }
.cmp-svg .dim text { fill: var(--muted); font: 500 13px var(--font); font-variant-numeric: tabular-nums; }
.cmp-svg .split { stroke: var(--ink); stroke-width: 1.5; }

.cmp-tag { position: absolute; top: 40%; z-index: 2; font-size: 0.8125rem; font-weight: 600; color: var(--ink); background: var(--surface); border: 1px solid var(--line); border-radius: 999px; padding: 4px 12px; white-space: nowrap; pointer-events: none; }
.cmp-tag { left: 0; will-change: transform; }
.cmp-tag-open { transform: translateX(calc(var(--split-px, 50vw) - 100% - 18px)); }
.cmp-tag-array { transform: translateX(calc(var(--split-px, 50vw) + 18px)); }
.cmp-grip { position: absolute; z-index: 3; top: 54%; left: 0; width: 44px; height: 44px; transform: translateX(calc(var(--split-px, 50vw) - 22px)); will-change: transform; display: grid; place-items: center; border-radius: 50%; background: var(--ink); color: var(--surface); box-shadow: var(--shadow-float); pointer-events: none; }
.cmp-grip svg { width: 22px; height: 22px; }
.cmp-range { position: absolute; inset: 0; z-index: 4; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; -webkit-appearance: none; appearance: none; background: transparent; }
.cmp-range::-webkit-slider-thumb { -webkit-appearance: none; width: 48px; height: 600px; }
.cmp-range::-moz-range-thumb { width: 48px; height: 600px; border: 0; }
.cmp-stage:has(.cmp-range:focus-visible) .cmp-grip { outline: 2px solid var(--green); outline-offset: 3px; }
.cmp-stage:has(.cmp-range:active) .cmp-grip { transform: translateX(calc(var(--split-px, 50vw) - 22px)) scale(1.08); }

.cmp-caption { margin-top: 16px; font-size: 0.8125rem; color: var(--muted); max-width: 90ch; }
@media (max-width: 640px) {
  .cmp-stage { margin-top: 12px; height: 380px; }
  .cmp-svg .dim-half { display: none; }
  .cmp-tag { top: 8%; font-size: 0.75rem; }
  .cmp-svg .dim text, .cmp-svg .layer-labels text, .cmp-svg .crop-labels text { font-size: 20px; }
  .cmp .cmp-svg .lbl-m { display: inline; }
  .cmp .cmp-svg .lbl-d { display: none; }
}

/* Readouts ride the split, like the Web Tool's floating scene panels */
.cmp-readouts { position: absolute; left: 0; right: 0; top: clamp(8px, 2vw, 24px); height: clamp(300px, 44vw, 640px); z-index: 3; pointer-events: none; }
.cmp-panel { position: absolute; top: 0; left: 0; width: 250px; will-change: transform; padding: 12px 14px 8px; background: var(--surface); border-radius: var(--radius); box-shadow: var(--shadow-float); transition: opacity 200ms ease-out; }
.cmp-panel-open { transform: translateX(calc(var(--split-px, 50vw) - 100% - 18px)); }
.cmp-panel-array { transform: translateX(calc(var(--split-px, 50vw) + 18px)); width: 290px; }
.cmp-panel.cramped { opacity: 0; }
.cmp-panel .cmp-panel-title { display: flex; align-items: center; gap: 8px; font-size: 0.8125rem; font-weight: 600; letter-spacing: 0; color: var(--ink); }
.cmp-panel .cmp-panel-title::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--gold); }
.cmp-panel-array .cmp-panel-title::before { background: var(--green); }
.cmp-panel > p { font-size: 0.75rem; color: var(--muted); margin-top: 4px; }
.cmp-panel dl { margin: 6px 0 0; }
.cmp-panel dl div { display: grid; grid-template-columns: 1fr auto; gap: 12px; align-items: baseline; padding: 5px 0; border-top: 1px solid var(--line); }
.cmp-panel dt { font-size: 0.8125rem; color: var(--ink-2); line-height: 1.3; }
.cmp-panel dt span { display: none; font-size: 0.6875rem; color: var(--muted); margin-top: 1px; }
.cmp-panel dd { margin: 0; font-size: 1.125rem; font-weight: 600; letter-spacing: -0.02em; color: var(--ink); white-space: nowrap; }
.cmp-panel dt .cmp-delta { display: block; color: var(--green); font-weight: 500; }
.cmp-panel dt .cmp-delta b { font-weight: 600; font-variant-numeric: tabular-nums; }
.cmp-panel [data-pos] { font-variant-numeric: tabular-nums; }

/* Whole-parcel figures: fixed, they do not depend on the line */
.cmp-parcel { width: 100%; max-width: var(--page); margin: 0 auto; padding: clamp(20px, 2.5vw, 32px) var(--gutter) clamp(40px, 5vw, 72px); display: grid; grid-template-columns: minmax(140px, 1fr) 4fr; gap: 24px; align-items: start; }
.cmp-parcel-title { display: flex; align-items: center; gap: 8px; font-size: 0.8125rem; font-weight: 600; color: var(--ink); padding-top: 12px; }
.cmp-parcel-title::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--ink-2); }
.cmp-parcel dl { margin: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.cmp-parcel dl div { border-top: 1px solid var(--line); padding-top: 12px; }
.cmp-parcel dt { font-size: 0.8125rem; color: var(--ink-2); font-weight: 500; }
.cmp-parcel dd { margin: 0; }
.cmp-parcel dd.num { font-size: clamp(1.5rem, 1.2rem + 0.8vw, 2rem); font-weight: 600; letter-spacing: -0.03em; line-height: 1.15; margin-top: 4px; color: var(--ink); white-space: nowrap; }
.cmp-parcel dd + dd { font-size: 0.75rem; color: var(--muted); margin-top: 2px; line-height: 1.4; }
@media (max-width: 900px) {
  .cmp-parcel { grid-template-columns: 1fr; gap: 8px; }
  .cmp-parcel-title { padding-top: 0; }
  .cmp-parcel dl { grid-template-columns: 1fr 1fr; gap: 16px 12px; }
}
@media (min-width: 901px) { .cmp-tag { display: none; } }
.cmp-svg .lbl-m { display: none; }
.cmp-tag.cramped { opacity: 0; }
@media (max-width: 900px) {
  .cmp-readouts { position: static; height: auto; display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 16px var(--gutter) 0; }
  .cmp-panel { position: static; width: auto; box-shadow: none; border: 1px solid var(--line); transform: none; }
  .cmp-panel.cramped { opacity: 1; }
  .cmp-panel dt span { display: block; }
  .cmp-notes { display: none; }
}
@media (max-width: 640px) {
  .cmp-readouts { grid-template-columns: 1fr; }
  .cmp-panel-array { order: -1; }
  .cmp-panel-open > p:not(.cmp-panel-title) { display: none; }
  .cmp-panel-open dl div { padding: 3px 0; }
  .cmp-panel-open dd { font-size: 1rem; }
}

/* Track record band */
.band { background: var(--band); color: var(--band-ink); }
.band h2 { color: var(--band-ink); }
.track { display: grid; gap: clamp(28px, 4vw, 48px); }
.track-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 14px 48px; }
.track-head p { color: var(--band-ink-2); max-width: 38ch; }
.track-figures { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 24px; margin: 0; }
.track-figures > div { border-top: 1px solid var(--band-line); padding-top: 14px; }
.track-figures dt { font-size: 0.875rem; line-height: 1.45; min-height: 2.9em; color: var(--band-ink-2); }
.track-figures dd { margin: 0; }
.track-figures dd.num { font-size: clamp(2.25rem, 1.6rem + 2vw, 3.5rem); font-weight: 600; letter-spacing: -0.035em; line-height: 1; margin-top: 10px; color: var(--band-ink); }
.track-figures dd.num.todo { color: var(--gold); }
.track-note { font-size: 0.8125rem; color: var(--band-ink-2); margin-top: 8px; }
.track-draft { font-size: 0.8125rem; color: var(--gold); border-top: 1px dashed rgba(233, 196, 106, 0.5); padding-top: 10px; }
[data-confirmed="true"] ~ .track-draft { display: none; }
@media (max-width: 1020px) { .track-figures { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) { .track-figures { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* Photo band */
.photo-band { margin: 0; height: clamp(280px, 46vw, 640px); overflow: hidden; background: var(--surface-3); }
.photo-band picture, .photo-band img { width: 100%; height: 100%; }
.photo-band img { object-fit: cover; object-position: 50% 62%; }

/* Model */
.model-figure { position: relative; margin: 0; }
.model-figure img { width: 100%; aspect-ratio: 3 / 1; object-fit: cover; object-position: 50% 8%; border-radius: var(--radius); background: #fff; border: 1px solid var(--line); }
@media (max-width: 900px) { .model-figure img { aspect-ratio: auto; } }
.model-scale { position: absolute; left: 20px; bottom: 16px; width: min(330px, 45%); margin: 0; padding: 10px 12px; background: rgba(255, 255, 255, 0.92); border-radius: 8px; color: #5b6168; }
.model-scale span { color: #2e3338; }
/* Five linked steps: each model passes its result to the next */
.model-chain { list-style: none; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); margin-top: 28px; }
.model-chain li { position: relative; display: grid; gap: 6px; align-content: start; padding: 22px 28px 0 0; border-top: 2px solid var(--line); }
.model-chain li::before { content: ""; position: absolute; top: -6px; left: 0; width: 10px; height: 10px; border-radius: 50%; background: var(--green); }
.model-chain li:not(:last-child)::after { content: ""; position: absolute; top: -6px; right: 14px; width: 8px; height: 8px; border-top: 2px solid var(--line-strong); border-right: 2px solid var(--line-strong); transform: rotate(45deg); }
.model-chain h3 { font-size: 1.0625rem; }
.model-chain p { font-size: 0.875rem; color: var(--ink-2); line-height: 1.45; max-width: 24ch; }
@media (max-width: 900px) {
  .model-chain { grid-template-columns: 1fr; gap: 0; }
  .model-chain li { border-top: 0; border-left: 2px solid var(--line); padding: 0 0 22px 22px; }
  .model-chain li::before { top: 4px; left: -6px; }
  .model-chain li:not(:last-child)::after { top: auto; right: auto; bottom: 4px; left: -5px; transform: rotate(135deg); }
  .model-chain p { max-width: none; }
  .model-chain li:last-child { border-left-color: transparent; padding-bottom: 0; }
  .model-scale { position: static; width: auto; padding: 0; background: none; margin-top: 12px; color: var(--muted); }
  .model-scale span { color: var(--ink-2); }
}
.model-more { margin-top: 28px; font-size: 0.9375rem; font-weight: 550; }

/* Team */
.team { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.person { display: grid; grid-template-columns: minmax(0, 200px) 1fr; gap: 24px; padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--radius); align-items: start; }
.person img { border-radius: var(--radius-sm); width: 100%; aspect-ratio: 5 / 6; object-fit: cover; }
.person h3 { font-size: 1.25rem; }
.person .role { color: var(--green); font-weight: 550; font-size: 0.875rem; margin: 2px 0 12px; }
.person p:not(.role) { color: var(--ink-2); font-size: 0.9375rem; }
@media (max-width: 1020px) { .team { grid-template-columns: 1fr; } }
@media (max-width: 560px) { .person { grid-template-columns: 1fr; } .person picture { max-width: 220px; } }

/* Contact */
.contact { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr); gap: 40px 72px; align-items: start; }
.contact-intro { display: grid; gap: 18px; }
.contact-send { list-style: none; display: grid; border-top: 1px solid var(--line); }
.contact-send li { padding: 12px 0 12px 28px; border-bottom: 1px solid var(--line); position: relative; font-size: 0.9375rem; color: var(--ink-2); }
.contact-send li::before { content: ""; position: absolute; left: 4px; top: 19px; width: 12px; height: 7px; border-left: 2px solid var(--green); border-bottom: 2px solid var(--green); transform: rotate(-45deg); }
.form { padding: clamp(20px, 3vw, 32px); display: grid; gap: 16px; }
.field-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.field { display: grid; gap: 6px; }
.field label { font-size: 0.875rem; font-weight: 550; color: var(--ink); }
.field .opt { font-weight: 400; color: var(--muted); }
.field input, .field select, .field textarea { width: 100%; min-height: 44px; padding: 10px 12px; border: 1px solid var(--line-strong); border-radius: var(--radius-sm); background: var(--surface); color: var(--ink); font-size: 0.9375rem; transition: border-color 150ms ease-out, box-shadow 150ms ease-out; }
.field textarea { resize: vertical; min-height: 120px; line-height: 1.5; }
.field input::placeholder, .field textarea::placeholder { color: var(--muted); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--green); box-shadow: 0 0 0 3px rgba(45, 106, 79, 0.18); }
.field [aria-invalid="true"] { border-color: var(--danger); }
.consent { display: grid; grid-template-columns: 20px 1fr; gap: 10px; align-items: start; font-size: 0.8125rem; color: var(--ink-2); }
.consent input { width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--green); }
.hp { position: absolute; left: -9999px; }
.form-error, .form-fail { font-size: 0.875rem; color: var(--danger); background: var(--danger-pale); padding: 10px 12px; border-radius: var(--radius-sm); }
.form-done { padding: 16px; border-radius: var(--radius-sm); background: var(--green-pale); color: var(--forest); }
.form-done h3 { color: var(--forest); font-size: 1rem; margin-bottom: 4px; }
.form .btn[type="submit"] { justify-self: start; min-width: 160px; }
.form .btn[disabled] { opacity: 0.6; cursor: progress; }
@media (max-width: 900px) { .contact { grid-template-columns: 1fr; } }
@media (max-width: 520px) { .field-row { grid-template-columns: 1fr; } }
