:root {
  --sand: #f2efe7;
  --paper: #f8f6f1;
  --card: #f6f4ee;
  --ink: #16241c;
  --ink-2: #3f4a43;
  --muted: #72766f;
  --rule: #dcd7cb;
  --rule-2: #e6e2d8;
  --green: #1f4d36;
  --green-2: #173d2a;
  --leaf: #c9dfcf;

  --sans: "Geist", "Helvetica Neue", Arial, sans-serif;
  --mono: "Geist Mono", ui-monospace, "SFMono-Regular", Menlo, monospace;

  --max: 1280px;
  --gutter: clamp(16px, 4vw, 48px);
  --r: 3px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 72px; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--sand);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
button { font: inherit; color: inherit; }
h1, h2, h3, p, dl, dd, ul, ol, figure { margin: 0; padding: 0; }
ul, ol { list-style: none; }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--green); outline-offset: 3px; }

.skip { position: absolute; left: 16px; top: -48px; z-index: 100; background: var(--green); color: #fff; padding: 8px 12px; }
.skip:focus { top: 12px; }

.wrap { width: 100%; max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- type ---------- */
.label {
  display: flex; align-items: center; gap: 10px;
  font-family: var(--mono); font-size: 11px; font-weight: 500;
  letter-spacing: .22em; text-transform: uppercase; color: var(--ink-2);
}
.dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); display: inline-block; }
.caption {
  font-family: var(--mono); font-size: 10.5px; letter-spacing: .2em; line-height: 1.7;
  text-transform: uppercase; color: var(--ink-2);
}
.h2 {
  font-size: clamp(26px, 2.6vw, 36px); font-weight: 600; line-height: 1.12;
  letter-spacing: -.025em; text-wrap: balance;
}
.h2.caps { text-transform: uppercase; letter-spacing: -.02em; line-height: 1.05; }
.muted { color: var(--muted); }

/* ---------- buttons & links ---------- */
.i { width: 14px; height: 14px; flex: none; transition: transform .15s; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 40px; padding: 0 18px; border: 1px solid transparent; border-radius: var(--r);
  font-size: 14px; font-weight: 500; text-decoration: none; cursor: pointer; white-space: nowrap;
  transition: background-color .15s, border-color .15s, color .15s;
}
.btn-lg { min-height: 48px; padding: 0 26px; }
.btn-solid { background: var(--green); color: #fff; }
.btn-solid:hover { background: var(--green-2); }
.btn-outline { border-color: rgba(22, 36, 28, .35); color: var(--ink); background: rgba(248, 246, 241, .6); }
.btn-outline:hover { border-color: var(--ink); background: var(--paper); }
.btn-paper { background: var(--paper); color: var(--green); }
.btn-paper:hover { background: #fff; }
.btn:hover .i, .link:hover .i { transform: translateX(2px); }

.link {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 13px; font-weight: 500; color: var(--green);
  text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 1px;
}
.link:hover { color: var(--green-2); }

/* ---------- nav ---------- */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: rgba(242, 239, 231, .94);
  backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule-2);
}
.nav-inner {
  max-width: calc(var(--max) + 2 * var(--gutter)); margin: 0 auto; padding: 0 var(--gutter);
  height: 68px; display: flex; align-items: center; gap: 32px;
}
.brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; }
.brand-cube { width: 32px; height: 32px; }
.brand-word {
  display: flex; flex-direction: column; font-size: 20px; font-weight: 700; line-height: 1;
  letter-spacing: .08em; text-transform: uppercase;
}
.brand-word small { font-family: var(--mono); font-size: 8.5px; font-weight: 500; letter-spacing: .3em; margin-top: 4px; }
.nav-links { display: flex; gap: 36px; margin: 0 auto; }
.nav-links a { font-size: 13.5px; text-decoration: none; color: var(--ink-2); }
.nav-links a:hover { color: var(--ink); }
.nav-actions { display: flex; gap: 12px; }

/* ---------- hero ---------- */
.hero { position: relative; min-height: min(620px, 88vh); display: flex; overflow: hidden; }
.hero-media, .closing-media { position: absolute; inset: 0; }
.hero-media img, .closing-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-media img { object-position: 70% 62%; filter: saturate(.9) contrast(.94) brightness(1.06); }
.hero-media::after, .closing-media::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(90deg, rgba(242,239,231,.94) 0%, rgba(242,239,231,.72) 36%, rgba(242,239,231,0) 62%),
    linear-gradient(0deg, rgba(242,239,231,.22), rgba(242,239,231,.22));
}
.hero-inner { position: relative; display: flex; align-items: center; padding-top: 72px; padding-bottom: 72px; }
.hero-copy { max-width: 760px; }
.hero-title {
  margin-top: 22px;
  font-size: clamp(44px, 6.4vw, 92px); font-weight: 700; line-height: .92;
  letter-spacing: -.045em; text-transform: uppercase; color: var(--ink);
}
.hero-lede { margin-top: 24px; max-width: 34ch; font-size: clamp(17px, 1.5vw, 20px); line-height: 1.4; color: var(--ink-2); }
.cta { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 36px; }
.hero-caption { position: absolute; right: var(--gutter); bottom: 32px; text-align: right; }

.hero .label, .hero-title, .hero-lede, .hero .cta { animation: rise .7s cubic-bezier(.2,.7,.2,1) both; }
.hero .label { animation-delay: .05s; }
.hero-title { animation-delay: .1s; }
.hero-lede { animation-delay: .2s; }
.hero .cta { animation-delay: .3s; }
@keyframes rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* ---------- stats ---------- */
.stats { border-bottom: 1px solid var(--rule); background: var(--sand); }
.stats-row { display: grid; grid-template-columns: repeat(4, 1fr); }
.stats-row > div { padding: 28px 28px 30px; border-left: 1px solid var(--rule); }
.stats-row > div:last-child { border-right: 1px solid var(--rule); }
.stats-row dt { font-family: var(--mono); font-size: 10.5px; letter-spacing: .2em; text-transform: uppercase; color: var(--ink-2); }
.stats-row dd { margin-top: 10px; font-size: clamp(26px, 2.4vw, 34px); font-weight: 600; letter-spacing: -.03em; line-height: 1; font-variant-numeric: tabular-nums; }
.stats-row p { margin-top: 10px; font-family: var(--mono); font-size: 10px; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }

/* ---------- sections ---------- */
.section { padding: clamp(56px, 7vw, 88px) 0; border-bottom: 1px solid var(--rule); }

.idea-grid { display: grid; grid-template-columns: 1.15fr .9fr 1.6fr; gap: clamp(24px, 4vw, 56px); align-items: center; }
.idea-head .h2 { margin-top: 20px; }
.idea-text p { font-size: 14.5px; color: var(--ink-2); max-width: 36ch; }
.idea-text .link { margin-top: 20px; }
.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.pillars li { border: 1px solid var(--rule); border-radius: var(--r); padding: 22px 18px 24px; background: rgba(248,246,241,.55); }
.pillars svg { width: 28px; height: 28px; fill: none; stroke: var(--green); stroke-width: 1.3; stroke-linecap: round; stroke-linejoin: round; }
.pillars h3 { margin-top: 20px; font-family: var(--mono); font-size: 11.5px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; }
.pillars p { margin-top: 8px; font-size: 13px; line-height: 1.45; color: var(--ink-2); }

/* ---------- machines ---------- */
.machines { padding-bottom: clamp(48px, 5vw, 64px); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 28px; }
.section-head .h2 { margin-top: 18px; max-width: 18ch; }
.head-actions { display: flex; align-items: center; gap: 24px; }
.arrows { display: flex; gap: 8px; }
.icon-btn {
  width: 36px; height: 36px; display: grid; place-items: center; cursor: pointer;
  border: 1px solid var(--rule); border-radius: var(--r); background: var(--paper);
}
.icon-btn:hover { border-color: var(--ink); }
.icon-btn:disabled { opacity: .4; cursor: default; border-color: var(--rule); }
.icon-btn svg { width: 16px; height: 16px; fill: none; stroke: var(--ink); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

.rail {
  display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 3 * 16px) / 4); gap: 16px;
  overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; overscroll-behavior-x: contain;
}
.rail::-webkit-scrollbar { display: none; }
.card {
  scroll-snap-align: start; display: flex; flex-direction: column;
  background: var(--card); border: 1px solid var(--rule); border-radius: var(--r); padding: 18px 18px 20px;
}
.card-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.card h3 { font-size: 15px; font-weight: 600; letter-spacing: -.01em; }
.card-top p { font-size: 12.5px; color: var(--ink-2); margin-top: 2px; }
.status { display: inline-flex; align-items: center; gap: 6px; font-family: var(--mono); font-size: 10px; letter-spacing: .14em; text-transform: uppercase; color: var(--green); padding-top: 3px; }
.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.status.is-maint { color: var(--muted); }

.shot { margin: 14px 0 16px; aspect-ratio: 3 / 2; display: grid; place-items: center; }
.shot svg { width: 100%; height: 100%; }
.shot .sh { fill: rgba(22, 36, 28, .09); }
.shot .b1 { fill: #e3e1da; stroke: #b9b6ac; stroke-width: .8; }
.shot .b2 { fill: #cfccc3; }
.shot .b3 { fill: #a9a69c; }
.shot .b4 { fill: #5a5f59; }
.shot .dk { fill: #2c322e; }
.shot .gr { fill: #3d8a5c; }
.shot .ln { stroke: #8e8b82; stroke-width: 1; fill: none; }
.shot .leg-far path { fill: none; stroke: #6f746e; stroke-width: 6; stroke-linecap: round; stroke-linejoin: round; }
.shot .leg-near path { fill: none; stroke: #2c322e; stroke-width: 5.5; stroke-linecap: round; }
.shot .thigh path { fill: none; stroke: #c3c0b7; stroke-width: 11; stroke-linecap: round; }
.shot .arm { fill: none; stroke: #d3d0c7; stroke-width: 11; stroke-linecap: round; stroke-linejoin: round; }
.shot .arm.thin { stroke-width: 7; }
.shot .grip { fill: none; stroke: #2c322e; stroke-width: 3.5; stroke-linecap: round; }

.metrics { border-top: 1px solid var(--rule-2); padding-top: 10px; }
.metrics div { display: flex; justify-content: space-between; padding: 5px 0; }
.metrics dt { font-family: var(--mono); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--muted); }
.metrics dd { font-family: var(--mono); font-size: 12px; font-variant-numeric: tabular-nums; }
.card > .link { margin-top: 14px; align-self: flex-start; }

/* ---------- flow ---------- */
.flow { background: var(--green); color: #eef3ef; padding: clamp(48px, 5vw, 64px) 0; }
.flow-grid { display: grid; grid-template-columns: minmax(300px, 1fr) 2.6fr; gap: clamp(32px, 4vw, 64px); align-items: center; }
.flow .h2 { font-size: clamp(24px, 2.2vw, 30px); }
.flow-head p { margin-top: 16px; max-width: 36ch; font-size: 14px; line-height: 1.5; color: #cddbd1; }
.flow-head .btn { margin-top: 24px; }
.steps { display: grid; grid-template-columns: repeat(5, 1fr); }
.steps li { position: relative; padding: 0 20px; }
.steps li + li { border-left: 1px solid rgba(255,255,255,.14); }
.steps li + li::before {
  content: ""; position: absolute; left: -7px; top: 18px; width: 13px; height: 13px;
  background: var(--green) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3E%3Cpath d='M2.5 8h10M9 4.5 12.5 8 9 11.5' fill='none' stroke='%23c9dfcf' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center / 13px no-repeat;
}
.steps svg { width: 48px; height: 48px; fill: none; stroke: var(--leaf); stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.steps h3 { margin-top: 18px; font-family: var(--mono); font-size: 11px; font-weight: 500; letter-spacing: .12em; text-transform: uppercase; color: #fff; }
.steps p { margin-top: 8px; font-size: 13px; line-height: 1.45; color: #bfd2c5; }

/* ---------- network ---------- */
.network-grid { display: grid; grid-template-columns: minmax(240px, 1fr) 2.8fr; gap: clamp(32px, 4vw, 64px); align-items: start; }
.network-head .h2 { margin-top: 18px; font-size: clamp(24px, 2.1vw, 30px); }
.network-head .btn { margin-top: 28px; }
.mini-stats { display: grid; grid-template-columns: repeat(4, 1fr); border-bottom: 1px solid var(--rule); }
.mini-stats div { padding: 4px 20px 22px; border-left: 1px solid var(--rule); }
.mini-stats dt { font-family: var(--mono); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--ink-2); }
.mini-stats dd { margin-top: 8px; font-size: clamp(22px, 1.9vw, 26px); font-weight: 600; letter-spacing: -.025em; font-variant-numeric: tabular-nums; }
.chart { display: grid; grid-template-columns: 1fr 150px; gap: 24px; padding-top: 24px; }
.chart-key p:not(.label) { margin-top: 10px; font-size: 12.5px; color: var(--muted); }
.chart-key .label { font-size: 10px; }
.chart-key p.chart-readout { display: flex; flex-direction: column; gap: 2px; margin-top: 20px; }
.chart-readout b { font-family: var(--mono); font-weight: 500; font-size: 15px; color: var(--ink); }
.chart-readout span { font-size: 12px; }
.chart-wrap svg { display: block; width: 100%; height: auto; overflow: visible; }
.chart-wrap svg:focus-visible { outline-offset: 6px; }
.chart-grid line { stroke: var(--rule-2); stroke-width: 1; }
.chart-axis text { font-family: var(--mono); font-size: 10px; fill: var(--muted); }
.chart-area { fill: url(#areaFill); }
.chart-line { fill: none; stroke: var(--green); stroke-width: 1.5; stroke-linejoin: round; }
.chart-cross { stroke: var(--ink); stroke-width: 1; stroke-dasharray: 2 3; opacity: .5; }
.chart-dot { fill: var(--paper); stroke: var(--green); stroke-width: 1.5; }

/* ---------- closing ---------- */
.closing { position: relative; overflow: hidden; border-bottom: 1px solid var(--rule); }
.closing-media img { object-position: 64% 56%; filter: saturate(.9) contrast(.94) brightness(1.06); }
.closing-inner { position: relative; display: flex; align-items: center; min-height: 420px; padding-top: 64px; padding-bottom: 64px; }
.closing-title { font-size: clamp(28px, 3vw, 42px); font-weight: 700; }
.closing-lede { margin-top: 14px; font-size: 18px; color: var(--ink-2); }
.closing-caption { position: absolute; right: var(--gutter); bottom: 32px; text-align: right; }

/* ---------- footer ---------- */
.footer { padding: 48px 0 40px; background: var(--sand); }
.footer-grid { display: grid; grid-template-columns: 1.3fr 2fr 1fr; gap: 40px; }
.footer-brand .caption { margin-top: 24px; }
.footer-cols { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.footer-cols h3 { font-size: 13px; font-weight: 600; }
.footer-cols ul { margin-top: 10px; display: grid; gap: 6px; }
.footer-cols a, .footer-cols span { font-size: 13px; color: var(--ink-2); text-decoration: none; }
.footer-cols a:hover { color: var(--ink); text-decoration: underline; text-underline-offset: 3px; }
.footer-meta { font-size: 11.5px; color: var(--muted); text-align: right; align-self: end; }
.footer-meta p + p { margin-top: 6px; }

/* ---------- toast ---------- */
.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 80;
  max-width: calc(100% - 32px); padding: 12px 16px; border-radius: var(--r);
  background: var(--ink); color: #f2efe7; font-size: 13.5px;
}

/* ---------- responsive ---------- */
@media (max-width: 1180px) {
  .idea-grid { grid-template-columns: 1fr 1fr; }
  .pillars { grid-column: 1 / -1; }
  .flow-grid, .network-grid { grid-template-columns: 1fr; }
  .rail { grid-auto-columns: calc((100% - 2 * 16px) / 3); }
}
@media (max-width: 960px) {
  .nav-links { display: none; }
  .nav-actions { margin-left: auto; }
  .stats-row { grid-template-columns: repeat(2, 1fr); }
  .stats-row > div:nth-child(2) { border-right: 1px solid var(--rule); }
  .stats-row > div:nth-child(-n+2) { border-bottom: 1px solid var(--rule); }
  .steps { grid-template-columns: repeat(2, 1fr); row-gap: 32px; }
  .steps li { padding: 0 20px 0 0; }
  .steps li + li { border-left: 0; }
  .steps li + li::before { display: none; }
  .rail { grid-auto-columns: calc((100% - 16px) / 2); }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-meta { text-align: left; }
}
@media (max-width: 640px) {
  .nav-inner { height: 60px; gap: 12px; }
  .nav-actions .btn-outline { display: none; }
  .nav-actions .btn { min-height: 36px; padding: 0 14px; font-size: 13px; }
  .brand-word { font-size: 17px; }
  .hero { min-height: 0; }
  .hero-media img { object-position: 78% 60%; }
  .hero-media::after, .closing-media::after {
    background: linear-gradient(180deg, rgba(242,239,231,.9) 0%, rgba(242,239,231,.78) 55%, rgba(242,239,231,.35) 100%);
  }
  .hero-inner { flex-direction: column; align-items: flex-start; padding-top: 48px; padding-bottom: 40px; }
  .hero-caption, .closing-caption { position: static; text-align: left; margin-top: 48px; }
  .cta { flex-direction: column; align-items: stretch; }
  .stats-row > div { padding: 20px 16px; }
  .idea-grid { grid-template-columns: 1fr; }
  .pillars { grid-template-columns: 1fr; }
  .pillars li { display: grid; grid-template-columns: 28px 1fr; column-gap: 16px; padding: 18px 16px; }
  .pillars svg { grid-row: span 2; }
  .pillars h3 { margin-top: 2px; }
  .pillars p { margin-top: 4px; }
  .section-head { flex-direction: column; align-items: flex-start; }
  .head-actions { width: 100%; justify-content: space-between; }
  .rail { grid-auto-columns: 84%; }
  .steps { grid-template-columns: 1fr; row-gap: 0; }
  .steps li { display: grid; grid-template-columns: 40px 1fr; column-gap: 16px; padding: 16px 0; border-top: 1px solid rgba(255,255,255,.14); }
  .steps li:last-child { border-bottom: 1px solid rgba(255,255,255,.14); }
  .steps svg { width: 40px; height: 40px; grid-row: span 2; }
  .steps h3 { margin-top: 2px; }
  .steps p { margin-top: 4px; }
  .mini-stats { grid-template-columns: repeat(2, 1fr); }
  .mini-stats div { padding: 14px 14px 16px; }
  .mini-stats div:nth-child(odd) { border-left: 0; padding-left: 0; }
  .chart { grid-template-columns: 1fr; }
  .chart-key { order: -1; display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 16px; }
  .chart-key p:not(.label) { margin-top: 0; }
  .chart-key p.chart-readout { margin-top: 0; flex-direction: row; gap: 8px; align-items: baseline; }
  .closing-inner { flex-direction: column; align-items: flex-start; min-height: 0; padding-top: 56px; padding-bottom: 40px; }
  .footer-cols { grid-template-columns: 1fr 1fr; }
}

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

/* ---------- preview-data flags ---------- */
.stats-wrap { position: relative; }
.data-flag {
  position: absolute; top: 8px; right: calc(var(--gutter) + 10px);
  font-family: var(--mono); font-size: 9.5px; letter-spacing: .14em; text-transform: uppercase; color: var(--muted);
}
.data-flag.is-inline { position: static; margin-left: 6px; padding: 2px 6px; border: 1px solid var(--rule); border-radius: 2px; letter-spacing: .12em; }
@media (max-width: 640px) {
  .data-flag:not(.is-inline) { position: static; padding: 8px 0 0; }
}
