/* DAEDALUS landing — dark product stage, stone editorial sections, olive accents and a red thread. */

:root {
  --bg: #07090c;
  --bg-alt: #0a0d11;
  --surface: #0e1217;
  --surface-2: #131820;
  --line: rgba(236, 232, 223, 0.08);
  --line-2: rgba(236, 232, 223, 0.14);
  --line-3: rgba(236, 232, 223, 0.26);
  --text: #ece8df;
  --text-2: #bab7af;
  --muted: #8d949e;
  --dim: #5d6570;
  --gold: #d6a84f;
  --gold-2: #f0cd7c;
  --gold-soft: rgba(214, 168, 79, 0.10);
  --gold-line: rgba(214, 168, 79, 0.45);
  --thread: #e5534b;
  --ok: #46b97a;

  --display: "Inter Tight", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --sans: var(--display);
  --mono: "JetBrains Mono", ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;

  --container: 1320px;
  --gutter: clamp(16px, 3.6vw, 48px);
  --nav-h: 64px;
  --ease: cubic-bezier(0.2, 0.7, 0.2, 1);
  color-scheme: dark;
}

/* ---------------------------------------------------------------- base */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--nav-h) + 8px); -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.6 var(--sans);
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, p { margin: 0; }
em { font-style: italic; }
code {
  font-family: var(--mono);
  font-size: 0.86em;
  color: var(--text);
  background: rgba(236, 232, 223, 0.06);
  border: 1px solid var(--line);
  padding: 0 4px;
  border-radius: 2px;
}
pre code { background: none; border: 0; padding: 0; font-size: inherit; color: inherit; border-radius: 0; }
::selection { background: rgba(214, 168, 79, 0.35); color: #fff; }
:focus-visible { outline: 1px solid var(--gold); outline-offset: 3px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 var(--gutter); }

.skip {
  position: absolute; left: 16px; top: -48px; z-index: 100;
  background: var(--gold); color: var(--bg); padding: 8px 14px; font-weight: 600;
}
.skip:focus { top: 12px; }

/* ---------------------------------------------------------------- buttons */
.btn {
  --h: 44px;
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  height: var(--h); padding: 0 20px;
  border: 1px solid transparent; border-radius: 2px;
  font: 600 13px/1 var(--display); letter-spacing: 0.06em; text-transform: uppercase;
  white-space: nowrap; cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s, color 0.2s, transform 0.2s;
}
.btn--sm { --h: 36px; padding: 0 14px; font-size: 12px; }
.btn--lg { --h: 52px; padding: 0 26px; font-size: 13.5px; }
.btn--primary { background: var(--gold); color: #0a0d11; }
.btn--primary:hover { background: var(--gold-2); }
.btn--ghost { border-color: var(--line-3); color: var(--text); background: transparent; }
.btn--ghost:hover { border-color: var(--text); background: rgba(236, 232, 223, 0.04); }
.btn .arrow { transition: transform 0.25s var(--ease); }
.btn:hover .arrow { transform: translateX(3px); }
.btn:disabled { opacity: 0.55; cursor: progress; }

/* ---------------------------------------------------------------- nav */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 50;
  height: var(--nav-h);
  border-bottom: 1px solid transparent;
  transition: background-color 0.3s, border-color 0.3s, backdrop-filter 0.3s;
}
.nav.is-scrolled, .nav.is-open {
  background: rgba(7, 9, 12, 0.82);
  backdrop-filter: blur(14px) saturate(140%);
  -webkit-backdrop-filter: blur(14px) saturate(140%);
  border-bottom-color: var(--line);
}
/* a backdrop-filter would become the containing block of the fixed mobile panel */
.nav.is-open { background: var(--bg); backdrop-filter: none; -webkit-backdrop-filter: none; }
.nav__inner { height: 100%; display: flex; align-items: center; gap: 32px; }

.brand { display: inline-flex; align-items: center; gap: 12px; color: var(--gold); flex: none; }
.brand__mark { width: 26px; height: 26px; }
.brand__name {
  font: 600 14px/1 var(--display); letter-spacing: 0.32em; color: var(--text);
  margin-right: -0.32em;
}

.nav__links { display: flex; align-items: center; gap: 22px; margin-left: auto; }
.nav__links a {
  position: relative; font: 500 12px/1 var(--display); letter-spacing: 0.05em; text-transform: uppercase; color: var(--text-2);
  padding: 8px 0; transition: color 0.2s;
}
.nav__links a:hover, .nav__links a.is-current { color: var(--text); }
.nav__links a.is-current::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px; height: 1px; background: var(--gold);
}
/* Arrow after links that lead to another page of the site. */
.ext { display: inline-block; margin-left: 2px; color: inherit; font-size: 0.85em; transition: transform 0.2s var(--ease); }
a:hover > .ext { transform: translate(2px, -2px); }

.nav__actions { display: flex; align-items: center; gap: 14px; }

.lang { display: inline-flex; border: 1px solid var(--line-2); border-radius: 2px; }
.lang button {
  background: none; border: 0; cursor: pointer;
  font: 500 11px/1 var(--mono); letter-spacing: 0.08em; color: var(--dim);
  padding: 8px 9px; transition: color 0.2s, background-color 0.2s;
}
.lang button[aria-pressed="true"] { color: var(--text); background: rgba(236, 232, 223, 0.08); }
.lang button:hover { color: var(--text); }

/* Buy me a coffee: quiet ghost button, the cup picks up the bronze accent */
.coffee { gap: 8px; }
.coffee__icon {
  width: 16px; height: 16px; flex: none;
  fill: none; stroke: var(--gold); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round;
}
.coffee__steam { opacity: 0.6; transition: opacity 0.25s, transform 0.4s var(--ease); }
.coffee:hover { border-color: var(--gold-line); background: var(--gold-soft); color: var(--gold-2); }
.coffee:hover .coffee__steam { opacity: 1; transform: translateY(-1px); }
.github__icon { width: 16px; height: 16px; flex: none; fill: currentColor; }
.nav__github:hover, .github-link:hover { border-color: var(--gold-line); background: var(--gold-soft); color: var(--gold-2); }

.nav__toggle {
  display: none; width: 40px; height: 36px; padding: 0; margin-right: -8px;
  background: none; border: 0; cursor: pointer; position: relative;
}
.nav__toggle span {
  position: absolute; left: 10px; right: 10px; height: 1px; background: var(--text);
  transition: transform 0.3s var(--ease), top 0.3s var(--ease);
}
.nav__toggle span:first-child { top: 14px; }
.nav__toggle span:last-child { top: 21px; }
.nav.is-open .nav__toggle span:first-child { top: 17.5px; transform: rotate(45deg); }
.nav.is-open .nav__toggle span:last-child { top: 17.5px; transform: rotate(-45deg); }

.nav__mobile {
  background: var(--bg);
  border-top: 1px solid var(--line);
  position: fixed; top: var(--nav-h); left: 0; right: 0; bottom: 0;
  overflow-y: auto; overscroll-behavior: contain;
}
.nav__mobile .container { display: flex; flex-direction: column; padding-top: 8px; padding-bottom: 24px; }
.nav__mobile a:not(.btn) {
  font: 600 20px/1.2 var(--display); letter-spacing: -0.01em; text-transform: uppercase;
  padding: 16px 0; border-bottom: 1px solid var(--line); color: var(--text);
}
.nav__mobile .btn { margin-top: 24px; }
.nav__mobile .btn + .btn { margin-top: 10px; }

/* ---------------------------------------------------------------- labels */
.sec-label, .frame__bar, .flow__num, .pillar__k, .note__k,
.spec__row--head, .stack__title, .stack__k, .targets__k, .sec-item__n, .use__n, .ethics__k,
.code__bar, .form__head, .field__label, .process__n, .fam__count-label, .ent__cat {
  font-family: var(--mono);
  font-size: 11.5px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.pulse {
  position: relative; width: 6px; height: 6px; border-radius: 50%; background: var(--thread); flex: none;
}
.pulse::after {
  content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 1px solid var(--thread);
  opacity: 0; animation: pulse 2.4s var(--ease) infinite;
}
@keyframes pulse { 0% { transform: scale(0.4); opacity: 0.9; } 100% { transform: scale(1.8); opacity: 0; } }

/* ---------------------------------------------------------------- hero */
/* Product-page composition: one oversized name, concise product facts, then the film. */
.hero {
  --hero-gap: clamp(42px, 6vh, 70px);
  min-height: clamp(570px, 64svh, 760px);
  padding: calc(var(--nav-h) + clamp(130px, 18vh, 200px)) 0 var(--hero-gap);
}
.hero .container, .showcase .container {
  max-width: none;
  padding-inline: clamp(20px, 2vw, 42px);
}
.hero__title {
  color: #fff;
  font: 600 clamp(74px, 13vw, 196px)/0.84 var(--display);
  letter-spacing: -0.085em;
  white-space: nowrap;
}
.hero__line { display: block; }
.hero__details {
  display: grid;
  grid-template-columns: minmax(190px, 260px) minmax(0, 1fr) 42px;
  align-items: start;
  column-gap: clamp(28px, 5.2vw, 96px);
  margin-top: var(--hero-gap);
}
.hero__product { max-width: 240px; }
.hero__category {
  color: #fff;
  font: 600 13px/1.2 var(--display);
  letter-spacing: 0.015em;
  text-transform: uppercase;
}
.hero__code {
  margin-top: 30px;
  color: var(--muted);
  font: 400 11px/1.4 var(--mono);
  letter-spacing: 0.12em;
}
.hero__copy { max-width: 580px; }
.hero__sub {
  color: var(--text-2);
  font: 600 13px/1.32 var(--display);
  letter-spacing: 0.015em;
  text-transform: uppercase;
}
.hero__facts {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px clamp(12px, 2vw, 24px);
  margin-top: 18px;
  margin-bottom: 0;
}
.hero__metric {
  display: flex;
  align-items: baseline;
  gap: 0.55em;
  color: var(--muted);
  font: 400 11px/1.4 var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
}
.hero__metric dt, .hero__metric dd { margin: 0; font: inherit; color: inherit; }
.hero__scroll {
  display: grid;
  width: 42px;
  height: 50px;
  place-items: center;
  color: #fff;
  transition: opacity 0.2s, transform 0.3s var(--ease);
}
.hero__scroll:hover { opacity: 0.65; transform: translateY(4px); }
.hero__scroll svg { width: 25px; height: 34px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: square; stroke-linejoin: miter; }

/* ---------------------------------------------------------------- frames */
.frame { position: relative; margin: 0; border: 1px solid var(--line-2); background: var(--surface); --tick: var(--gold-line); }
.frame::after {
  content: ""; position: absolute; inset: -7px; pointer-events: none;
  background:
    linear-gradient(var(--tick), var(--tick)) top left / 14px 1px no-repeat,
    linear-gradient(var(--tick), var(--tick)) top left / 1px 14px no-repeat,
    linear-gradient(var(--tick), var(--tick)) top right / 14px 1px no-repeat,
    linear-gradient(var(--tick), var(--tick)) top right / 1px 14px no-repeat,
    linear-gradient(var(--tick), var(--tick)) bottom left / 14px 1px no-repeat,
    linear-gradient(var(--tick), var(--tick)) bottom left / 1px 14px no-repeat,
    linear-gradient(var(--tick), var(--tick)) bottom right / 14px 1px no-repeat,
    linear-gradient(var(--tick), var(--tick)) bottom right / 1px 14px no-repeat;
}
.frame__bar {
  display: flex; justify-content: space-between; align-items: center; gap: 16px;
  padding: 11px 16px; border-bottom: 1px solid var(--line-2);
  color: var(--muted); font-size: 10.5px;
}
.frame__bar b { color: var(--gold); font-weight: 500; margin-right: 8px; }
.frame__meta { color: var(--dim); white-space: nowrap; }
.frame__media { position: relative; overflow: hidden; background: #0a0d11; }
.frame__media img { width: 100%; }
.frame__media video { display: block; width: 100%; height: auto; aspect-ratio: 16 / 9; background: #0a0d11; }
.frame__media--stack { display: grid; }
.frame__media--stack img {
  grid-area: 1 / 1; opacity: 0; transform: scale(1.012); pointer-events: none;
  transition: opacity 0.6s var(--ease), transform 1.2s var(--ease);
}
.frame__media--stack img.is-active { opacity: 1; transform: none; }
.frame__media--stack video {
  grid-area: 1 / 1;
  width: 100%;
  height: 100%;
  aspect-ratio: auto;
  object-fit: contain;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity 0.3s;
}
.frame__media--stack video.is-active { opacity: 1; visibility: visible; pointer-events: auto; }

.showcase { position: relative; padding: 0 0 clamp(70px, 8vw, 120px); }
.showcase .frame--hero { border: 0; background: transparent; box-shadow: none; }
.showcase .frame--hero::after { display: none; }
.showcase .frame__media { background: #050505; }
.showcase .frame__media video { background: #050505; pointer-events: none; }
.showcase__caption {
  margin-top: 12px;
  color: var(--muted);
  font: 400 11px/1.5 var(--mono);
  letter-spacing: 0.08em;
}
.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;
}

/* ---------------------------------------------------------------- sections */
.section { position: relative; padding: clamp(88px, 11vw, 168px) 0; border-top: 1px solid var(--line); }
.section--alt { background: var(--bg-alt); }

.sec-head {
  display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); gap: var(--gutter);
  margin-bottom: clamp(48px, 7vw, 96px);
}
.sec-label { display: flex; align-items: center; align-self: start; gap: 12px; color: var(--muted); padding-top: 0.9em; font-family: var(--display); font-size: 12px; letter-spacing: 0.05em; }
.sec-label__n { color: var(--gold); display: inline-flex; align-items: center; gap: 12px; }
.sec-label__n::after { content: ""; width: 24px; height: 1px; background: var(--gold-line); }
.sec-title {
  font: 400 clamp(32px, 4.6vw, 66px)/1.04 var(--display);
  letter-spacing: -0.035em;
  max-width: 20ch;
  text-wrap: balance;
}
.sec-lead {
  margin-top: clamp(20px, 2.4vw, 32px);
  max-width: 62ch;
  font-size: clamp(16px, 1.3vw, 18.5px); color: var(--text-2); line-height: 1.65;
}

/* compact sections: less air around the heading, two-line titles */
.section--compact { padding-top: clamp(64px, 7vw, 112px); }
.section--compact-end { padding-bottom: clamp(64px, 7vw, 112px); }
.section--compact .sec-head { margin-bottom: clamp(32px, 4vw, 56px); }
.section--compact .sec-title { font-size: clamp(30px, 4vw, 56px); max-width: 30ch; }
.section--compact .sec-lead { margin-top: clamp(14px, 1.6vw, 22px); }

/* pillars */
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--gutter); }
.pillar { border-top: 1px solid var(--line-3); padding-top: 24px; }
.pillar__k { color: var(--gold); margin-bottom: 40px; }
.pillar h3 { font: 400 clamp(22px, 2vw, 28px)/1.15 var(--display); letter-spacing: -0.02em; margin-bottom: 14px; }
.pillar p { color: var(--muted); font-size: 15.5px; }

/* ---------------------------------------------------------------- workflow */
.flow { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: var(--gutter); align-items: start; }
.flow__steps { display: flex; flex-direction: column; border-bottom: 1px solid var(--line-2); }
.flow__step {
  position: relative; display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 4px;
  width: 100%; text-align: left; background: none; border: 0; border-top: 1px solid var(--line-2);
  padding: 22px 0; cursor: pointer; color: var(--muted);
  transition: color 0.25s;
}
.flow__step:hover { color: var(--text-2); }
.flow__step.is-active { color: var(--text); }
.flow__num { padding-top: 6px; font-size: 11px; color: var(--dim); transition: color 0.25s; }
.flow__step.is-active .flow__num { color: var(--gold); }
.flow__name { display: block; font: 400 clamp(20px, 1.9vw, 26px)/1.2 var(--display); letter-spacing: -0.02em; }
.flow__desc {
  display: block; max-height: 0; overflow: hidden; opacity: 0;
  font-size: 15px; line-height: 1.6; color: var(--text-2);
  transition: max-height 0.5s var(--ease), opacity 0.35s, margin 0.5s var(--ease);
}
.flow__step.is-active .flow__desc { max-height: 260px; opacity: 1; margin-top: 10px; }
.flow__bar { position: absolute; left: 0; right: 0; top: -1px; height: 1px; overflow: hidden; }
.flow__bar i { display: block; height: 100%; width: 0; background: var(--gold); }
.flow__step.is-active .flow__bar i { width: 100%; }
.flow.is-playing .flow__step.is-active .flow__bar i { width: 0; animation: progress var(--flow-ms, 7000ms) linear forwards; }
.flow.is-paused .flow__step.is-active .flow__bar i { animation-play-state: paused; }
@keyframes progress { to { width: 100%; } }
.flow__frame { position: sticky; top: calc(var(--nav-h) + 32px); }

/* ---------------------------------------------------------------- cards (hairline grid) */
.grid { display: grid; gap: 1px; background: var(--line-2); border: 1px solid var(--line-2); }
.grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid--4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.grid--6 { grid-template-columns: repeat(6, minmax(0, 1fr)); }
.card, .sec-item {
  background: var(--bg); padding: clamp(28px, 3vw, 40px);
  transition: background-color 0.3s;
}
.section--alt .card, .section--alt .sec-item { background: var(--bg-alt); }
.card:hover, .sec-item:hover { background: var(--surface); }
.card__icon {
  width: 32px; height: 32px; margin-bottom: 44px;
  fill: none; stroke: var(--muted); stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round;
  transition: stroke 0.3s;
}
.card:hover .card__icon { stroke: var(--gold); }
.card__icon--thread .t { stroke: var(--thread); stroke-dasharray: 2.4 1.8; }
.section--compact .card {
  display: grid; grid-template-columns: 26px minmax(0, 1fr); column-gap: 14px; row-gap: 10px; align-items: center; align-content: start;
  padding: clamp(22px, 2.2vw, 30px) clamp(22px, 2.4vw, 32px);
}
.section--compact .card__icon { width: 26px; height: 26px; margin: 0; }
.section--compact .card h3 { margin: 0; }
.section--compact .card p { grid-column: 2; }
.card h3, .sec-item h3 { font: 500 19px/1.3 var(--display); letter-spacing: -0.01em; margin-bottom: 12px; }
.card p, .sec-item p { color: var(--muted); font-size: 15px; }
.sec-item__n { color: var(--gold); margin-bottom: 36px; }
.section--compact .sec-item {
  display: grid; grid-template-columns: max-content minmax(0, 1fr); column-gap: 14px; row-gap: 10px; align-items: baseline; align-content: start;
  padding: clamp(22px, 2.2vw, 30px) clamp(22px, 2.4vw, 32px);
}
.section--compact .sec-item__n, .section--compact .sec-item h3 { margin: 0; }
.section--compact .sec-item__n { grid-column: 1; grid-row: 1; white-space: nowrap; }
.section--compact .sec-item h3 { grid-column: 2; grid-row: 1; }
.section--compact .sec-item p:last-child { grid-column: 2; }
/* Six narrow columns: stack number, title and text instead of setting the number beside the title. */
.section--compact .grid--6 .sec-item { display: flex; flex-direction: column; gap: 10px; padding: 22px 20px; }
.grid--6 .sec-item p { font-size: 14px; }
.grid--6 .sec-item code { overflow-wrap: anywhere; }

/* ---------------------------------------------------------------- coverage */
/* Families vary from 1 to 9 transforms: main.js groups them into balanced columns and the cards stretch to a common bottom edge. */
.families { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.fam-col { display: flex; flex-direction: column; gap: 10px; }
.fam { flex: 1 0 auto; background: var(--bg-alt); padding: 18px 20px 16px; }
.fam__head { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; margin-bottom: 8px; }
.fam__name { font: 500 19px/1.2 var(--display); letter-spacing: -0.01em; }
.fam__count { font: 300 32px/1 var(--display); letter-spacing: -0.04em; color: var(--gold); font-variant-numeric: tabular-nums; }
.fam__list { list-style: none; margin: 0; padding: 0; }
.fam__list li {
  display: flex; gap: 10px; align-items: baseline; justify-content: space-between;
  padding: 4px 0; border-top: 1px dashed var(--line);
  font-family: var(--mono); font-size: 12.5px; line-height: 1.45; color: var(--text-2);
}
.fam__list .src { color: var(--dim); }
.fam__list .key {
  flex: none; font-size: 9.5px; letter-spacing: 0.12em; text-transform: uppercase;
  color: var(--gold); border: 1px solid var(--gold-line); padding: 1px 5px; border-radius: 2px;
}

.coverage-notes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: var(--gutter); margin-top: clamp(28px, 3.5vw, 44px); }
.note { border-left: 1px solid var(--gold-line); padding-left: 20px; }
.note__k { color: var(--gold); margin-bottom: 10px; }
.note p:not(.note__k) { color: var(--text-2); font-size: 15px; }

.entities { margin-top: clamp(64px, 8vw, 112px); }
.entities__head { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: var(--gutter); align-items: end; margin-bottom: 32px; }
.entities__head h3 { font: 400 clamp(24px, 2.4vw, 34px)/1.15 var(--display); letter-spacing: -0.025em; }
.entities__head p { color: var(--muted); font-size: 15.5px; max-width: 56ch; }
.entities__grid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 1px; background: var(--line-2); border: 1px solid var(--line-2); }
.ent__group { background: var(--bg-alt); padding: 20px 18px 22px; }
.ent__cat { color: var(--dim); font-size: 10px; margin-bottom: 14px; }
.ent__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.ent__item { display: flex; align-items: center; gap: 10px; font-size: 14px; color: var(--text-2); }
.ent__dot { width: 9px; height: 9px; border-radius: 50%; border: 1.5px solid var(--c); box-shadow: 0 0 0 3px color-mix(in srgb, var(--c) 14%, transparent); flex: none; }

/* ---------------------------------------------------------------- spec table */
.spec { border-top: 1px solid var(--line-3); }
.spec__row {
  display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 4fr) minmax(0, 5fr); gap: var(--gutter);
  padding: 22px 0; border-bottom: 1px solid var(--line-2); align-items: baseline;
  transition: background-color 0.25s;
}
.spec__row--head { padding: 14px 0; color: var(--dim); font-size: 10.5px; }
.spec__row:not(.spec__row--head):hover { background: linear-gradient(90deg, var(--gold-soft), transparent 70%); }
.spec__fn { font: 400 clamp(20px, 1.9vw, 26px)/1.2 var(--display); letter-spacing: -0.02em; transition: color 0.25s; }
.spec__row:hover .spec__fn { color: var(--gold-2); }
.spec__q { color: var(--text-2); font-size: 16px; }
.spec__a { font-family: var(--mono); font-size: 13px; color: var(--muted); }

/* ---------------------------------------------------------------- deploy */
.deploy { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(32px, 5vw, 80px); align-items: start; }
.stack { display: flex; flex-direction: column; gap: 10px; }
.stack__title { color: var(--dim); margin-bottom: 6px; }
.stack__layer {
  display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 16px; align-items: baseline;
  border: 1px solid var(--line-2); background: var(--bg); padding: 18px 20px;
  transition: border-color 0.3s;
}
.stack__layer:hover { border-color: var(--line-3); }
.stack__k { color: var(--gold); font-size: 10.5px; }
.stack__v { font-size: 14.5px; color: var(--text-2); }
.stack__split { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 10px; }
.stack__split .stack__layer { grid-template-columns: minmax(0, 1fr); gap: 8px; }
.stack__layer--base { border-color: var(--gold-line); background: linear-gradient(180deg, var(--gold-soft), transparent); }
.stack__link {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 0; position: relative;
  font: 500 10px/1 var(--mono); letter-spacing: 0.12em; text-transform: uppercase; color: var(--dim);
  padding: 8px 0;
}
.stack__link::before {
  content: ""; position: absolute; left: 50%; top: -10px; bottom: -10px; width: 1px;
  background: repeating-linear-gradient(180deg, var(--thread) 0 3px, transparent 3px 6px); opacity: 0.8;
}
.stack__link span { padding: 0 16px; }
.stack__link span:first-child { text-align: right; }

.targets { list-style: none; margin: 0 0 28px; padding: 0; border-top: 1px solid var(--line-3); }
.targets li { display: grid; grid-template-columns: 140px minmax(0, 1fr); gap: 16px; padding: 18px 0; border-bottom: 1px solid var(--line-2); align-items: baseline; }
.targets__k { color: var(--text); font-size: 11px; }
.targets__v { color: var(--muted); font-size: 15px; }

.terminal { border: 1px solid var(--line-2); background: #05070a; }
.terminal__bar { display: flex; align-items: center; gap: 6px; padding: 10px 14px; border-bottom: 1px solid var(--line); }
.terminal__bar i { width: 8px; height: 8px; border-radius: 50%; background: var(--line-3); }
.terminal__bar span { margin-left: auto; font: 500 10px/1 var(--mono); letter-spacing: 0.12em; color: var(--dim); text-transform: uppercase; }
.terminal pre, .code pre {
  margin: 0; padding: 18px 20px; overflow-x: auto;
  font: 400 13px/1.75 var(--mono); color: var(--text-2);
  tab-size: 4;
}
.c-p { color: var(--gold); user-select: none; }
.c-m { color: var(--dim); }
.c-k { color: var(--gold-2); }
.c-s { color: #9fd3a8; }
.c-f { color: #8cc4f0; }
.c-d { color: var(--thread); }

/* ---------------------------------------------------------------- use cases */
.uses { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(32px, 4vw, 56px) var(--gutter); }
.use { border-top: 1px solid var(--line-3); padding-top: 22px; }
.use__n { color: var(--gold); margin-bottom: 28px; }
.use h3 { font: 400 clamp(21px, 1.9vw, 26px)/1.2 var(--display); letter-spacing: -0.02em; margin-bottom: 12px; }
.use p { color: var(--muted); font-size: 15.5px; }
.section--compact .uses { row-gap: clamp(24px, 3vw, 36px); }
.section--compact .use {
  display: grid; grid-template-columns: 32px minmax(0, 1fr); column-gap: 12px; row-gap: 8px; align-items: baseline; align-content: start;
  padding-top: 18px;
}
.section--compact .use__n, .section--compact .use h3 { margin: 0; }
.section--compact .use h3 { font-size: clamp(19px, 1.6vw, 22px); }
.section--compact .use__n { grid-column: 1; grid-row: 1; }
.section--compact .use h3 { grid-column: 2; grid-row: 1; }
.section--compact .use p:last-child { grid-column: 2; font-size: 15px; }

.ethics {
  margin-top: clamp(64px, 8vw, 112px);
  display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 9fr); gap: var(--gutter);
  padding: clamp(28px, 3.4vw, 44px) 0;
  border-top: 1px solid var(--line-2); border-bottom: 1px solid var(--line-2);
  position: relative;
}
.ethics::before {
  content: ""; position: absolute; left: 0; top: -1px; width: 120px; height: 1px;
  background: repeating-linear-gradient(90deg, var(--thread) 0 6px, transparent 6px 10px);
}
.ethics__k { color: var(--thread); padding-top: 0.5em; }
.ethics__d { font: 400 clamp(18px, 1.7vw, 23px)/1.5 var(--display); letter-spacing: -0.01em; color: var(--text); max-width: 60ch; }
.section--compact .ethics { margin-top: clamp(40px, 5vw, 64px); padding: clamp(22px, 2.6vw, 32px) 0; }

/* ---------------------------------------------------------------- code */
.code-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: var(--gutter); }
/* side by side only where both fit without scrolling; the plugin needs a little more room */
@media (min-width: 1360px) { .code-grid { grid-template-columns: minmax(0, 1.1fr) minmax(0, 1fr); } }
.code { margin: 0; border: 1px solid var(--line-2); background: #05070a; min-width: 0; }
.code__bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 11px 16px; border-bottom: 1px solid var(--line); color: var(--muted); font-size: 10.5px; text-transform: none; letter-spacing: 0.04em; }
.code__tag { color: var(--gold); text-transform: uppercase; letter-spacing: 0.14em; }
.code pre { font-size: 12.5px; line-height: 1.7; }

/* ---------------------------------------------------------------- access */
.section--access {
  background:
    radial-gradient(60% 50% at 15% 0%, rgba(214, 168, 79, 0.07), transparent 70%),
    var(--bg);
}
.access { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(40px, 6vw, 96px); align-items: start; }
.access__label { padding-top: 0; margin-bottom: 28px; }
.access__intro .sec-title { font-size: clamp(32px, 3.8vw, 54px); }

.process { list-style: none; margin: 40px 0 0; padding: 0; border-top: 1px solid var(--line-2); }
.process li { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 8px; padding: 18px 0; border-bottom: 1px solid var(--line-2); }
.process__n { color: var(--gold); font-size: 11px; padding-top: 3px; }
.process b { font: 500 16px/1.3 var(--display); display: block; margin-bottom: 4px; }
.process p { color: var(--muted); font-size: 14.5px; }

.access__links { display: grid; gap: 10px; margin-top: 32px; }
.link-row {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  border: 1px solid var(--line-2); padding: 16px 18px;
  transition: border-color 0.25s, background-color 0.25s;
}
.link-row:hover { border-color: var(--gold-line); background: var(--gold-soft); }
.link-row b { display: block; font-weight: 500; font-size: 14.5px; }
.link-row b + span { display: block; color: var(--muted); font-size: 13.5px; margin-top: 2px; }
.link-row .arrow { color: var(--gold); font-size: 18px; transition: transform 0.25s var(--ease); }
.link-row:hover .arrow { transform: translate(2px, -2px); }

.form { border: 1px solid var(--line-2); background: rgba(14, 18, 23, 0.8); position: relative; }
.form__head {
  display: flex; justify-content: space-between; gap: 16px;
  padding: 14px 24px; border-bottom: 1px solid var(--line-2); color: var(--text-2); font-size: 10.5px;
}
.form__ref { color: var(--dim); }
.form__grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 22px 20px; padding: 28px 24px 8px; }
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.field--full { grid-column: 1 / -1; }
.field__label { color: var(--muted); font-size: 10.5px; }
.field__label em { font-style: normal; color: var(--dim); margin-left: 6px; }
.field input, .field select, .field textarea {
  width: 100%; min-width: 0;
  background: rgba(7, 9, 12, 0.7); border: 1px solid var(--line-2); border-radius: 2px;
  padding: 12px 14px; font-size: 15px; color: var(--text);
  transition: border-color 0.2s, background-color 0.2s;
}
.field textarea { resize: vertical; min-height: 120px; line-height: 1.55; }
.field input::placeholder, .field textarea::placeholder { color: var(--dim); }
.field select {
  appearance: none; -webkit-appearance: none; cursor: pointer; padding-right: 40px;
  background-image: linear-gradient(45deg, transparent 50%, var(--muted) 50%), linear-gradient(135deg, var(--muted) 50%, transparent 50%);
  background-position: calc(100% - 20px) 52%, calc(100% - 15px) 52%;
  background-size: 5px 5px; background-repeat: no-repeat;
}
.field select option { background: var(--surface); color: var(--text); }
.field input:hover, .field select:hover, .field textarea:hover { border-color: var(--line-3); }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-color: var(--gold); background-color: rgba(7, 9, 12, 0.95); }
.field.is-invalid input, .field.is-invalid select, .field.is-invalid textarea { border-color: var(--thread); }
.field--hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.check { display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 12px; align-items: start; cursor: pointer; color: var(--text-2); font-size: 14px; line-height: 1.55; }
.check input {
  appearance: none; -webkit-appearance: none; margin: 2px 0 0; width: 18px; height: 18px;
  border: 1px solid var(--line-3); border-radius: 2px; background: rgba(7, 9, 12, 0.7); cursor: pointer;
  display: grid; place-content: center; transition: border-color 0.2s, background-color 0.2s;
}
.check input::after { content: ""; width: 9px; height: 5px; border: solid #0a0d11; border-width: 0 0 2px 2px; transform: rotate(-45deg) translate(1px, -1px); opacity: 0; }
.check input:checked { background: var(--gold); border-color: var(--gold); }
.check input:checked::after { opacity: 1; }
.check.is-invalid input { border-color: var(--thread); }

.form__foot { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 24px 24px; flex-wrap: wrap; }
.form__status { font-size: 14px; color: var(--muted); flex: 1 1 240px; min-height: 1.4em; }
.form__status.is-error { color: var(--thread); }
.form__status.is-ok { color: var(--ok); }

.form__done { padding: 56px 32px 64px; text-align: left; }
.form__done[hidden] { display: none; }
.form.is-done .form__grid, .form.is-done .form__foot { display: none; }
.form__done-ref { margin-top: 24px; font: 500 12px/1 var(--mono); letter-spacing: 0.14em; color: var(--gold); }
.form__done-alt { margin-top: 20px; font-size: 14px; color: var(--muted) !important; }
.form__done-alt[hidden] { display: none; }
.form__done-alt a { color: var(--gold-2); border-bottom: 1px solid var(--gold-line); white-space: nowrap; }
.form__done-alt a:hover { border-color: var(--gold-2); }
.form__done .mark { width: 44px; height: 44px; border: 1px solid var(--gold-line); display: grid; place-content: center; color: var(--gold); margin-bottom: 28px; }
.form__done h3 { font: 400 clamp(26px, 2.6vw, 36px)/1.15 var(--display); letter-spacing: -0.025em; margin-bottom: 14px; }
.form__done p { color: var(--text-2); max-width: 52ch; }

/* ---------------------------------------------------------------- roadmap */
/* A rail runs through the phases: solid bronze where work has shipped, Ariadne's dashed thread where it is still ahead. */
.roadmap__track { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gutter); }
.phase { position: relative; min-width: 0; }
.phase::before {
  content: ""; position: absolute; top: 12px; left: 0; right: calc(-1 * var(--gutter)); height: 1px;
  background: repeating-linear-gradient(90deg, var(--thread) 0 6px, transparent 6px 11px); opacity: 0.75;
}
.phase--shipped::before { background: var(--gold); opacity: 1; }
.phase:last-child::before { right: 0; -webkit-mask: linear-gradient(90deg, #000 40%, transparent); mask: linear-gradient(90deg, #000 40%, transparent); }

.phase__head { position: relative; display: flex; align-items: center; gap: 12px; height: 24px; margin-bottom: 28px; }
.phase__node {
  width: 15px; height: 15px; flex: none; transform: rotate(45deg) scale(0.78);
  border: 1px solid var(--line-3); background: var(--bg-alt);
}
.phase--shipped .phase__node { background: var(--gold); border-color: var(--gold); }
.phase--next .phase__node { border-color: var(--thread); box-shadow: 0 0 0 4px rgba(229, 83, 75, 0.12); }
.phase--exploring .phase__node { border-style: dashed; }
.phase__n, .phase__status, .phase__meta, .roadmap__note { font-family: var(--mono); font-size: 10.5px; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase; }
.phase__n { color: var(--dim); background: var(--bg-alt); padding: 0 6px; margin: 0 -6px; }
.phase__status { padding: 4px 8px; line-height: 14px; border: 1px solid var(--line-2); border-radius: 2px; color: var(--muted); background: var(--bg-alt); }
.phase--shipped .phase__status { color: var(--gold-2); border-color: var(--gold-line); background: #14120c; }
.phase--next .phase__status { color: var(--thread); border-color: rgba(229, 83, 75, 0.45); background: #160d0d; }
.phase--exploring .phase__status { border-style: dashed; color: var(--dim); }

.phase__title { font: 400 clamp(22px, 2vw, 28px)/1.15 var(--display); letter-spacing: -0.02em; }
.phase__meta { margin-top: 8px; color: var(--gold); }
.phase__items { list-style: none; margin: 20px 0 0; padding: 0; border-top: 1px solid var(--line-2); }
.phase__summary { margin-top: 20px; padding-top: 14px; border-top: 1px solid var(--line-2); color: var(--text-2); font-size: 15px; line-height: 1.6; }
.phase__note { margin-top: 14px; color: var(--dim); font-size: 13.5px; line-height: 1.55; }
.phase__items li {
  display: grid; grid-template-columns: 16px minmax(0, 1fr); gap: 10px; align-items: baseline;
  padding: 11px 0; border-bottom: 1px dashed var(--line); font-size: 14.5px; line-height: 1.5; color: var(--text-2);
}
.phase--exploring .phase__items li, .phase--planned .phase__items li { color: var(--muted); }
.phase__mark { width: 9px; height: 9px; border: 1px solid var(--line-3); transform: translateY(1px); }
.phase--shipped .phase__mark {
  border: 0; width: 10px; height: 6px; transform: translateY(-2px) rotate(-45deg);
  border-left: 1.5px solid var(--gold); border-bottom: 1.5px solid var(--gold);
}
.phase--next .phase__mark { border-color: var(--thread); }
.phase--exploring .phase__mark { border-style: dashed; }
.roadmap__note { margin-top: 28px; color: var(--dim); letter-spacing: 0.08em; text-transform: none; font-size: 11.5px; }

.support {
  position: relative;
  margin-top: clamp(64px, 8vw, 104px);
  display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: var(--gutter); align-items: center;
  padding: clamp(32px, 4vw, 48px);
  border: 1px solid var(--gold-line);
  background: linear-gradient(120deg, rgba(214, 168, 79, 0.08), transparent 60%), var(--bg);
}
.support h3 { font: 400 clamp(26px, 2.8vw, 40px)/1.1 var(--display); letter-spacing: -0.03em; margin-bottom: 14px; }
.support p { color: var(--text-2); font-size: 16px; max-width: 54ch; }
.support__actions { display: grid; gap: 10px; justify-self: end; width: min(100%, 340px); }
.btn__icon { width: 16px; height: 16px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.4; stroke-linejoin: round; }
.btn--primary .coffee__icon { stroke: currentColor; }

/* ---------------------------------------------------------------- footer */
/* Logo top left, three link columns on the right; legal lines bottom left, contact under the last column. */
.footer { border-top: 1px solid var(--line); padding: clamp(56px, 6vw, 80px) 0 clamp(48px, 5vw, 72px); background: var(--bg); }
.footer__grid {
  display: grid;
  grid-template-areas: "brand nav nav nav" "legal legal . contact";
  grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr));
  column-gap: var(--gutter); row-gap: clamp(64px, 8vw, 128px); align-items: start;
}
.footer__brand { grid-area: brand; }
.footer__brand .brand__mark { width: 30px; height: 30px; }
.footer__brand .brand__name { font-size: 19px; }
.footer__nav { grid-area: nav; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: var(--gutter); }
@supports (grid-template-columns: subgrid) { .footer__nav { grid-template-columns: subgrid; } }
.footer__col ul, .footer__links { list-style: none; margin: 0; padding: 0; }
.footer__h {
  font: 500 13px/1.2 var(--display); letter-spacing: 0.03em; text-transform: uppercase; color: var(--muted);
  margin-bottom: clamp(28px, 3.6vw, 52px);
}
.footer__col a, .footer__mail {
  font: 400 clamp(18px, 1.5vw, 22px)/1.5 var(--display); letter-spacing: -0.01em; color: var(--text);
  transition: color 0.2s;
}
.footer__col a:hover, .footer__mail:hover { color: var(--gold-2); }
.footer__legal { grid-area: legal; }
.footer__copy { font: 600 13.5px/1.3 var(--display); letter-spacing: 0.02em; text-transform: uppercase; color: var(--text); margin-bottom: 18px; }
.footer__links a { font: 500 14px/1.6 var(--display); color: var(--muted); transition: color 0.2s; }
.footer__links a:hover { color: var(--text); }
.footer__note { margin-top: 22px; max-width: 52ch; font-size: 12.5px; line-height: 1.55; color: var(--dim); }
.footer__note code { font-size: 0.92em; color: var(--muted); }
.footer__contact { grid-area: contact; }
.footer__mail { white-space: nowrap; }

/* ---------------------------------------------------------------- type voice */
/* Base heading rhythm; the editorial product-section overrides below set sentence case. */
.sec-title, .pillar h3, .flow__name, .card h3, .sec-item h3, .fam__name, .fam__count, .entities__head h3, .spec__fn,
.use h3, .process b, .link-row b, .form__done h3, .phase__title, .support h3 {
  font-family: var(--display); font-weight: 600; text-transform: uppercase;
}
.sec-title { font-size: clamp(28px, 3.9vw, 56px); line-height: 0.98; letter-spacing: -0.03em; max-width: 28ch; }
.section--compact .sec-title { font-size: clamp(26px, 3.4vw, 48px); max-width: 30ch; }
.access__intro .sec-title { font-size: clamp(26px, 3.2vw, 46px); }
.entities__head h3, .support h3, .form__done h3 { line-height: 1.02; letter-spacing: -0.025em; }
.entities__head h3 { font-size: clamp(22px, 2.1vw, 30px); }
.support h3 { font-size: clamp(24px, 2.5vw, 36px); }
.form__done h3 { font-size: clamp(22px, 2.2vw, 30px); }
.pillar h3, .phase__title { font-size: clamp(18px, 1.6vw, 23px); line-height: 1.1; letter-spacing: -0.01em; }
.flow__name, .spec__fn { font-size: clamp(17px, 1.5vw, 21px); line-height: 1.15; letter-spacing: -0.01em; }
.use h3 { line-height: 1.15; letter-spacing: -0.005em; }
.section--compact .use h3 { font-size: clamp(16px, 1.4vw, 19px); }
.card h3, .sec-item h3, .fam__name { font-size: 15.5px; line-height: 1.25; letter-spacing: 0.01em; }
.fam__count { font-size: 28px; letter-spacing: -0.03em; }
.process b, .link-row b { font-size: 13.5px; letter-spacing: 0.03em; }

/* ---------------------------------------------------------------- density */
/* Tighter vertical rhythm for everything below the hero. */
.showcase { padding-bottom: clamp(46px, 5.5vw, 82px); }
.section { padding: clamp(50px, 5.8vw, 90px) 0; }
.section--compact { padding-top: clamp(44px, 4.8vw, 74px); }
.section--compact-end { padding-bottom: clamp(44px, 4.8vw, 74px); }
.sec-head { margin-bottom: clamp(26px, 3.5vw, 50px); }
.section--compact .sec-head { margin-bottom: clamp(20px, 2.6vw, 34px); }
.sec-title { font-size: clamp(26px, 3.5vw, 50px); }
.section--compact .sec-title { font-size: clamp(24px, 3.1vw, 44px); }
.access__intro .sec-title { font-size: clamp(24px, 2.9vw, 42px); }
.sec-lead { margin-top: clamp(12px, 1.5vw, 20px); }
.pillar { padding-top: 18px; }
.pillar__k { margin-bottom: 20px; }
.pillar h3 { margin-bottom: 10px; }
.flow__step { padding: 16px 0; }
.coverage-notes { margin-top: clamp(24px, 3vw, 36px); }
.entities { margin-top: clamp(32px, 4vw, 56px); }
.entities__head { margin-bottom: 22px; }
.spec__row { padding: 13px 0; }
.spec__row--head { padding: 9px 0; }
.stack { gap: 8px; }
.stack__layer { padding: 14px 18px; }
.targets { margin-bottom: 20px; }
.targets li { padding: 11px 0; }
.terminal pre, .code pre { padding: 14px 18px; }
.section--compact .ethics { margin-top: clamp(32px, 4vw, 52px); }
.phase__head { margin-bottom: 20px; }
.phase__items { margin-top: 14px; }
.phase__items li { padding: 8px 0; }
.roadmap__note { margin-top: 20px; }
.support { margin-top: clamp(32px, 4vw, 52px); padding: clamp(22px, 2.6vw, 34px); }
.section--access { padding: clamp(44px, 4.8vw, 74px) 0; }
.access__label { margin-bottom: 18px; }
/* Process steps sit side by side instead of stacking. */
.process { margin-top: 22px; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px; border-top: 0; }
.process li { display: block; padding: 12px 0 0; border-bottom: 0; border-top: 1px solid var(--line-2); }
.process__n { display: block; padding-top: 0; margin-bottom: 6px; }
.process p { font-size: 13.5px; line-height: 1.5; }
.access__links { margin-top: 22px; gap: 8px; }
.link-row { padding: 12px 16px; }
.form__head { padding-top: 12px; padding-bottom: 12px; }
.form__grid { gap: 14px 16px; padding-top: 16px; }
.field { gap: 6px; }
.field input, .field select, .field textarea { padding: 10px 12px; }
.field textarea { min-height: 88px; }
.form__foot { padding-top: 16px; padding-bottom: 20px; }
.footer { padding: clamp(56px, 6vw, 80px) 0 clamp(48px, 5vw, 72px); }
.footer__grid { row-gap: clamp(64px, 8vw, 128px); }
.footer__h { margin-bottom: clamp(28px, 3.6vw, 52px); }

/* ---------------------------------------------------------------- decode */
/* Headings type in behind a tail of scrambled glyphs (decode.js). Until their turn they keep their space but stay
   hidden; the decode itself is the entrance, so they skip the fade-up. */
.decode-ready .hero__line.reveal, .decode-ready .sec-title.reveal { opacity: 1; transform: none; transition: none; }
.decode-ready :is(.hero__line, .sec-title, [data-decode], [data-decode-sub]):not(.is-decoding):not(.is-decoded) { visibility: hidden; }
.dc-rest { visibility: hidden; }
.dc-ch { position: relative; color: transparent; }
.dc-ch::after {
  content: attr(data-c); content: attr(data-c) / "";
  position: absolute; left: 0; top: 0; line-height: normal; color: var(--dc-color, currentColor);
}

/* ---------------------------------------------------------------- reveal */
.js .reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.9s var(--ease), transform 0.9s var(--ease); }
.js .reveal.is-in { opacity: 1; transform: none; }

/* ---------------------------------------------------------------- responsive */
/* Keep secondary action buttons icon-only while the full nav is constrained. */
@media (max-width: 1519px) {
  .nav__coffee { width: 36px; padding: 0; }
  .nav__coffee .coffee__label {
    position: absolute; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
  }
  .nav__github { width: 36px; padding: 0; }
  .nav__github .github__label {
    position: absolute; width: 1px; height: 1px; overflow: hidden;
    clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
  }
}
@media (min-width: 1121px) {
  .nav__inner {
    display: grid;
    max-width: none;
    grid-template-areas: "brand links actions";
    grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
    gap: clamp(16px, 2vw, 28px);
    padding-inline: clamp(24px, 3vw, 48px);
  }
  .brand { grid-area: brand; }
  .nav__links { grid-area: links; justify-self: center; margin-left: 0; gap: clamp(20px, 2vw, 32px); }
  .nav__actions { grid-area: actions; justify-self: end; gap: clamp(8px, 1vw, 12px); }
}
@media (min-width: 1121px) and (max-width: 1519px) {
  .nav__inner { gap: 24px; }
  .nav__links { gap: 20px; }
}

@media (max-width: 1120px) {
  .nav__links { display: none; }
  .nav__toggle { display: block; }
  .nav__actions { margin-left: auto; }
  .hero__details { column-gap: clamp(24px, 4vw, 48px); }
  .flow { grid-template-columns: minmax(0, 1fr); }
  .flow__frame { position: relative; top: 0; order: -1; }
  .families { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--6 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .entities__grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
  .ent__group:last-child { grid-column: span 2; }
  .deploy { grid-template-columns: minmax(0, 1fr); }
  .roadmap__track { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .phase { padding: 0 0 44px 36px; }
  .phase::before {
    top: 0; bottom: 0; left: 7px; right: auto; width: 1px; height: auto;
    background: repeating-linear-gradient(180deg, var(--thread) 0 6px, transparent 6px 11px);
  }
  .phase--shipped::before { background: var(--gold); }
  .phase:last-child::before { right: auto; -webkit-mask: linear-gradient(180deg, #000 40%, transparent); mask: linear-gradient(180deg, #000 40%, transparent); }
  .phase__node { position: absolute; left: -36px; top: 4.5px; }
  .phase__head { margin-bottom: 16px; }
  .phase__items { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: var(--gutter); }
  .support { grid-template-columns: minmax(0, 1fr); }
  .support__actions { display: flex; flex-wrap: wrap; gap: 12px; justify-self: start; width: auto; }
  .access { grid-template-columns: minmax(0, 1fr); }
  .code-grid { grid-template-columns: minmax(0, 1fr); }
}

/* footer: logo on its own row, then the three columns; legal and contact share the last row */
@media (max-width: 1120px) {
  .footer__grid {
    grid-template-areas: "brand brand brand" "nav nav nav" "legal legal contact";
    grid-template-columns: repeat(3, minmax(0, 1fr));
    row-gap: clamp(48px, 7vw, 80px);
  }
}
@media (max-width: 640px) {
  .footer__grid {
    grid-template-areas: "brand" "nav" "contact" "legal";
    grid-template-columns: minmax(0, 1fr);
    row-gap: 48px;
  }
  .footer__nav { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 40px; }
}

@media (max-width: 760px) {
  .hero {
    --hero-gap: 38px;
    min-height: 0;
    padding-top: calc(var(--nav-h) + clamp(136px, 21vh, 188px));
    /* Same 18px rhythm as [OSINT] -> copy and copy -> metrics. */
    padding-bottom: 18px;
  }
  /* "DAEDALUS" ink is ~4.53em wide at this tracking: fill the row, leaving ~4px before the right gutter. */
  .hero__title { font-size: calc((100vw - 44px) / 4.53); }
  .hero__details { grid-template-columns: minmax(0, 1fr) 42px; row-gap: 18px; margin-top: 18px; }
  .hero__product { grid-column: 1; grid-row: 1; }
  .hero__scroll { grid-column: 2; grid-row: 1; }
  .hero__copy { grid-column: 1 / -1; grid-row: 2; }
  .hero__code { margin-top: 18px; }
}

@media (max-width: 860px) {
  .code pre { white-space: pre-wrap; overflow-wrap: anywhere; }
  .sec-head, .ethics, .entities__head { grid-template-columns: minmax(0, 1fr); }
  .sec-head { gap: 20px; }
  .sec-label { padding-top: 0; }
  .pillars, .uses { grid-template-columns: minmax(0, 1fr); }
  .section--compact .uses { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3, .grid--4, .grid--6 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3 > :last-child:nth-child(odd) { grid-column: 1 / -1; }
  .coverage-notes { grid-template-columns: minmax(0, 1fr); }
  .entities__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .spec__row--head { display: none; }
  .spec__row { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .pillar__k, .use__n { margin-bottom: 20px; }
}

@media (max-width: 640px) {
  :root { --nav-h: 58px; }
  .nav__inner { gap: 16px; }
  .nav__actions { gap: 10px; }
  .frame__bar { flex-direction: column; align-items: flex-start; gap: 4px; }
  .grid--3, .grid--4, .grid--6 { grid-template-columns: minmax(0, 1fr); }
  .families { grid-template-columns: minmax(0, 1fr); }
  .card__icon { margin-bottom: 28px; }
  .section--compact .card__icon { margin: 0; }
  .stack__layer { grid-template-columns: minmax(0, 1fr); gap: 6px; }
  .stack__split { grid-template-columns: minmax(0, 1fr); }
  .targets li { grid-template-columns: minmax(0, 1fr); gap: 4px; }
  .form__grid { grid-template-columns: minmax(0, 1fr); padding: 24px 18px 4px; }
  .process { grid-template-columns: minmax(0, 1fr); gap: 0; }
  .process li { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 8px; padding: 11px 0; }
  .process__n { margin-bottom: 0; padding-top: 3px; }
  .form__head, .form__foot { padding-left: 18px; padding-right: 18px; }
  .form__foot .btn { width: 100%; }
  .phase__items { grid-template-columns: minmax(0, 1fr); }
  .section--compact .uses { grid-template-columns: minmax(0, 1fr); }
  .support__actions .btn { width: 100%; height: auto; min-height: var(--h); padding-block: 12px; white-space: normal; text-align: center; line-height: 1.3; }
}

/* Phones: coffee and GitHub stay in the menu panel, so the bar keeps room for the brand, language and menu. */
@media (max-width: 520px) {
  .nav__coffee, .nav__github { display: none; }
}
/* Narrow phones: keep the 2x2 metric grid, tightening type so labels like "Tipos de entidad" fit their column. */
@media (max-width: 400px) {
  .hero__facts { gap: 6px 10px; }
  .hero__metric { gap: 0.4em; font-size: 10px; letter-spacing: 0.06em; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-delay: 0s !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
  .js .reveal { opacity: 1; transform: none; }
}

/* ---------------------------------------------------------------- editorial product sections */
/* Keep the original near-black / bronze / red palette; the editorial layout changes the rhythm only. */
.section > .container, .footer > .container { max-width: none; }
.section > .container { padding-inline: clamp(24px, 2.5vw, 52px); }
.footer > .container { padding-inline: clamp(20px, 2vw, 42px); }
.section :is(.sec-title, .pillar h3, .flow__name, .card h3, .sec-item h3, .fam__name,
  .entities__head h3, .spec__fn, .use h3, .process b, .link-row b, .phase__title, .support h3, .form__done h3) {
  text-transform: none;
}
.section .sec-head {
  display: block;
  margin-bottom: clamp(28px, 3.5vw, 48px);
}
.section .sec-label {
  padding-top: 0;
  margin-bottom: clamp(16px, 2vw, 24px);
  color: var(--muted);
  font: 500 12px/1.3 var(--display);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.section .sec-label__n { color: var(--gold); }
.section .sec-label__n::after { background: var(--gold-line); }
.section .sec-title {
  max-width: 17ch;
  color: var(--text);
  font: 500 clamp(42px, 6.2vw, 86px)/0.97 var(--display);
  letter-spacing: -0.065em;
  text-wrap: balance;
}
.section--compact .sec-title { font-size: clamp(38px, 5.5vw, 76px); }
.section .sec-lead {
  max-width: 64ch;
  margin-top: clamp(14px, 1.8vw, 22px);
  color: var(--text-2);
  font: 400 clamp(17px, 1.45vw, 20px)/1.5 var(--display);
  letter-spacing: -0.01em;
}
.section code {
  color: var(--text);
  background: rgba(236, 232, 223, 0.06);
  border-color: var(--line);
}

/* Overview: open editorial columns instead of a dense dashboard grid. */
.section .pillars { gap: clamp(14px, 1.4vw, 20px); }
.section .pillar {
  min-height: 204px;
  padding: 18px 0 0;
  border-top-color: var(--line-3);
}
.section .pillar__k { color: var(--gold); font: 500 11px/1 var(--mono); letter-spacing: 0.12em; }
.section .pillar h3 {
  color: var(--text);
  font: 500 clamp(22px, 2.1vw, 29px)/1.12 var(--display);
  letter-spacing: -0.035em;
}
.section .pillar p { color: var(--muted); font-size: 15px; line-height: 1.5; }

/* Workflow: product image first, tabbed steps beside it. */
.section .flow {
  grid-template-columns: minmax(0, 8fr) minmax(0, 4fr);
  gap: clamp(32px, 5vw, 76px);
}
.section .flow__frame { order: -1; border: 0; background: transparent; }
.section .flow__frame::after { display: none; }
.section .flow__frame .frame__bar {
  padding: 0 0 14px;
  border: 0;
  color: var(--muted);
  background: transparent;
}
.section .flow__frame .frame__bar b { color: var(--gold); }
.section .flow__frame .frame__meta { color: var(--dim); }
.section .flow__frame .frame__media { background: var(--bg-alt); }
.section .flow__step { padding: 12px 0; color: var(--muted); border-top-color: var(--line-2); }
.section .flow__step:hover, .section .flow__step.is-active { color: var(--text); }
.section .flow__num { color: var(--dim); }
.section .flow__step.is-active .flow__num { color: var(--gold); }
.section .flow__name {
  font: 500 clamp(19px, 1.8vw, 25px)/1.15 var(--display);
  letter-spacing: -0.035em;
}
.section .flow__desc { color: var(--text-2); font-size: 14px; line-height: 1.5; }
.section .flow__bar i { background: var(--gold); }

/* Capabilities: separated feature tiles with the original warm neutral and thread accents. */
#capacidades {
  padding-top: clamp(40px, 3.5vw, 54px);
  padding-bottom: clamp(40px, 3.5vw, 54px);
}
#capacidades .sec-head { margin-bottom: clamp(18px, 2.1vw, 28px); }
#capacidades .cards { gap: 12px; border: 0; background: transparent; }
#capacidades .cards .card {
  display: flex;
  min-height: 208px;
  flex-direction: column;
  align-items: stretch;
  padding: clamp(18px, 1.8vw, 24px);
  border: 0;
  background: var(--surface);
  color: var(--text);
  text-align: left;
  transition: background-color 0.25s, transform 0.25s var(--ease);
}
#capacidades .cards .card:hover { background: var(--surface-2); transform: translateY(-3px); }
#capacidades .cards .card h3 {
  order: -1;
  min-height: 1.2em;
  margin: 0;
  color: var(--text);
  font: 500 clamp(19px, 1.7vw, 23px)/1.12 var(--display);
  letter-spacing: -0.035em;
}
#capacidades .cards .card__icon {
  width: 36px;
  height: 36px;
  align-self: center;
  margin: auto;
  stroke: var(--gold);
}
#capacidades .cards .card__icon--thread .t { stroke: var(--thread); }
#capacidades .cards .card p {
  margin-top: auto;
  color: var(--text-2);
  font-size: 14px;
  line-height: 1.45;
}

/* Coverage and analysis panels use separated surfaces and crisp rules. */
.section .entities__grid {
  gap: 10px;
  border: 0;
  background: transparent;
}
.section .fam, .section .ent__group {
  border: 1px solid var(--line-2);
  background: var(--bg-alt);
}
.section .fam__name { color: var(--text); font-size: 18px; }
.section .fam__count { color: var(--gold); font-weight: 500; }
.section .fam__list li { color: var(--text-2); border-top-style: solid; border-top-color: var(--line); }
.section .fam__list .src { color: var(--muted); }
.section .fam__list .key { color: var(--gold); border-color: var(--gold-line); }
.section .note { border-left-color: var(--gold-line); }
.section .note__k { color: var(--gold); }
.section .note p:not(.note__k), .section .entities__head p { color: var(--text-2); }
.section .entities__head h3 { color: var(--text); font-size: clamp(24px, 2.6vw, 36px); }
.section .ent__cat { color: var(--muted); }
.section .ent__item { color: var(--text-2); }
.section .spec { border-top-color: var(--line-3); }
.section .spec__row { border-bottom-color: var(--line-2); }
.section .spec__row:not(.spec__row--head):hover { background: linear-gradient(90deg, var(--gold-soft), transparent 70%); }
.section .spec__row--head { color: var(--muted); }
.section .spec__fn { color: var(--text); }
.section .spec__row:hover .spec__fn { color: var(--gold); }
.section .spec__q { color: var(--text-2); }
.section .spec__a { color: var(--muted); }

/* Deployment and developer examples remain dark, like embedded product screens. */
.section .stack__layer { border-color: var(--line-2); background: var(--bg); }
.section .stack__layer--base { border-color: var(--gold-line); background: linear-gradient(180deg, var(--gold-soft), transparent); }
.section .stack__k, .section .process__n { color: var(--gold); }
.section .stack__v, .section .targets__v { color: var(--text-2); }
.section .stack__title, .section .stack__link { color: var(--muted); }
.section .stack__link::before { background: repeating-linear-gradient(180deg, var(--thread) 0 3px, transparent 3px 6px); }
.section .targets { border-top-color: var(--line-3); }
.section .targets li { border-bottom-color: var(--line-2); }
.section .targets__k { color: var(--text); }

/* Use cases and safety notes read as an editorial index. */
.section .uses { gap: clamp(18px, 2.2vw, 32px) clamp(16px, 1.8vw, 26px); }
.section .use { border-top-color: var(--line-3); }
.section .use__n { color: var(--gold); }
.section .use h3 { color: var(--text); font: 500 clamp(20px, 1.8vw, 25px)/1.15 var(--display); letter-spacing: -0.035em; }
.section .use p { color: var(--muted); }
.section .ethics { border-color: var(--line-2); }
.section .ethics::before { background: repeating-linear-gradient(90deg, var(--thread) 0 6px, transparent 6px 10px); }
.section .ethics__k { color: var(--gold); }
.section .ethics__d { color: var(--text); }

/* Roadmap timeline and support card use quiet rules and bronze / red details. */
.section .phase::before { background: repeating-linear-gradient(90deg, var(--thread) 0 6px, transparent 6px 11px); }
.section .phase--shipped::before { background: var(--gold); }
.section .phase__node, .section .phase__n { background-color: var(--bg-alt); border-color: var(--line-3); }
.section .phase--shipped .phase__node { background: var(--gold); border-color: var(--gold); }
.section .phase--next .phase__node { border-color: var(--thread); box-shadow: 0 0 0 4px rgba(229, 83, 75, 0.12); }
.section .phase__n { color: var(--muted); }
.section .phase__status { color: var(--muted); border-color: var(--line-2); background: var(--surface); }
.section .phase--shipped .phase__status {
  color: var(--gold);
  border-color: var(--gold-line);
  /* Same tint as before, over an opaque base so the timeline line does not show through. */
  background: linear-gradient(var(--gold-soft), var(--gold-soft)), var(--bg-alt);
}
.section .phase--next .phase__status { color: var(--thread); border-color: rgba(229, 83, 75, 0.45); background: #160d0d; }
.section .phase__meta { color: var(--gold); }
.section .phase__items { border-top-color: var(--line-2); }
.section .phase__items li { color: var(--text-2); border-bottom-color: var(--line-2); }
.section .phase__mark { border-color: var(--line-3); }
.section .phase--shipped .phase__mark { border-color: var(--gold); }
.section .phase--next .phase__mark { border-color: var(--thread); }
.section .roadmap__note { color: var(--muted); }
.section .support { border-color: var(--gold-line); background: linear-gradient(120deg, var(--gold-soft), transparent 60%), var(--bg); }
.section .support h3 { color: var(--text); font: 500 clamp(26px, 3vw, 42px)/1.05 var(--display); letter-spacing: -0.05em; }
.section .support p { color: var(--text-2); }

@media (max-width: 860px) {
  .section .flow { grid-template-columns: minmax(0, 1fr); }
  .section .flow__frame { order: -1; }
}
@media (max-width: 640px) {
  #capacidades .cards .card { min-height: 204px; }
  .section .sec-title { max-width: 15ch; }
  .section--access .sec-title { font-size: clamp(38px, 10vw, 58px); }
}

/* ---------------------------------------------------------------- mission page */
.mission-page :is(.mission-hero > .container, .mission-story > .container, .mission-principles > .container, .footer > .container) {
  max-width: none;
  padding-inline: clamp(20px, 2vw, 42px);
}
.mission-hero {
  position: relative;
  display: flex;
  min-height: clamp(560px, 70svh, 820px);
  align-items: center;
  padding: calc(var(--nav-h) + clamp(88px, 14vh, 156px)) 0 clamp(56px, 7vh, 88px);
  overflow: hidden;
  background: radial-gradient(ellipse 54% 52% at 78% 82%, var(--gold-soft), transparent 72%), var(--bg);
}
.mission-hero::after {
  position: absolute;
  right: clamp(20px, 2vw, 42px);
  bottom: 34px;
  left: clamp(20px, 2vw, 42px);
  height: 1px;
  background: linear-gradient(90deg, var(--gold-line), var(--line) 40%, transparent);
  content: "";
}
.mission-hero__inner { position: relative; z-index: 1; }
.mission-kicker {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--gold);
  font: 500 12px/1.3 var(--display);
  letter-spacing: 0.05em;
  text-transform: uppercase;
}
.mission-kicker::before { width: 28px; height: 1px; background: var(--gold-line); content: ""; }
.mission-hero__title {
  max-width: 14ch;
  margin-top: clamp(26px, 3vw, 42px);
  color: var(--text);
  font: 500 clamp(58px, 9vw, 124px)/0.94 var(--display);
  letter-spacing: -0.07em;
  text-wrap: balance;
}
.mission-hero__bottom {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 30px;
  margin-top: clamp(36px, 5vw, 68px);
}
.mission-hero__lead {
  max-width: 56ch;
  color: var(--text-2);
  font: 400 clamp(17px, 1.55vw, 21px)/1.5 var(--display);
}
.mission-scroll {
  display: grid;
  width: 44px;
  height: 52px;
  flex: 0 0 auto;
  place-items: center;
  color: var(--text);
  transition: color 0.2s, transform 0.25s var(--ease);
}
.mission-scroll:hover { color: var(--gold); transform: translateY(4px); }
.mission-scroll svg { width: 25px; height: 34px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: square; stroke-linejoin: miter; }
.mission-film { border-block: 1px solid var(--line-2); background: #050505; }
.mission-film__frame { height: clamp(320px, 58vw, 820px); max-height: 82svh; margin: 0; overflow: hidden; }
.mission-film__video { display: block; width: 100%; height: 100%; background: #050505; object-fit: cover; pointer-events: none; }
.mission-story {
  padding: clamp(76px, 9vw, 124px) 0;
  border-bottom: 1px solid var(--line-2);
  background: var(--bg-alt);
}
.mission-story__layout {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  gap: clamp(32px, 7vw, 104px);
  align-items: start;
}
.mission-story__kicker { padding-top: 0.5em; }
.mission-story__kicker span:first-child { color: var(--dim); }
.mission-story__copy {
  max-width: 62ch;
  color: var(--text-2);
  font: 400 clamp(21px, 2.4vw, 32px)/1.3 var(--display);
  letter-spacing: -0.035em;
}
.mission-photo { height: clamp(320px, 50vw, 760px); margin: 0; overflow: hidden; border-block: 1px solid var(--line-2); background: #080807; }
.mission-photo img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 54%; }
.mission-manifesto {
  padding: clamp(84px, 10vw, 140px) 0;
  border-bottom: 1px solid var(--line-2);
  background: var(--bg);
}
.mission-manifesto__title {
  display: flex;
  flex-direction: column;
  margin-top: clamp(32px, 4.5vw, 58px);
  color: var(--text);
  font: 500 clamp(46px, 7.7vw, 108px)/0.92 var(--display);
  letter-spacing: -0.07em;
  text-transform: uppercase;
}
.mission-manifesto__accent { color: var(--thread); }
.mission-details { padding: clamp(76px, 9vw, 124px) 0; background: var(--bg-alt); }
.mission-detail {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  gap: clamp(32px, 7vw, 104px);
  padding: clamp(28px, 3.5vw, 44px) 0;
  border-top: 1px solid var(--line-3);
}
.mission-detail:last-child { border-bottom: 1px solid var(--line-3); }
.mission-detail__kicker { padding-top: 0.5em; }
.mission-detail__kicker span:first-child { color: var(--dim); }
.mission-detail__body h2 {
  max-width: 24ch;
  color: var(--text);
  font: 500 clamp(27px, 3.2vw, 44px)/1.08 var(--display);
  letter-spacing: -0.045em;
}
.mission-detail__body p {
  max-width: 68ch;
  margin-top: 18px;
  color: var(--text-2);
  font-size: 16px;
  line-height: 1.65;
}
.mission-notes { padding: clamp(76px, 9vw, 124px) 0; }
.mission-disclaimer { border-top: 1px solid var(--line); padding: clamp(48px, 6vw, 84px) 0; }
.mission-disclaimer__layout { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(32px, 7vw, 104px); align-items: start; }
.mission-disclaimer__body { display: grid; gap: 14px; max-width: 72ch; }
.mission-disclaimer__body p { color: var(--muted); font-size: 14px; line-height: 1.65; }
@media (max-width: 860px) { .mission-disclaimer__layout { grid-template-columns: minmax(0, 1fr); gap: 20px; } }
.mission-notes__head {
  display: grid;
  grid-template-columns: minmax(0, 4fr) minmax(0, 8fr);
  gap: clamp(32px, 7vw, 104px);
  align-items: start;
  margin-bottom: clamp(34px, 4.5vw, 58px);
}
.mission-notes__head h2 {
  max-width: 18ch;
  color: var(--text);
  font: 500 clamp(34px, 4.5vw, 60px)/1.02 var(--display);
  letter-spacing: -0.055em;
}
.mission-notes__grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.mission-note {
  display: flex;
  min-height: 300px;
  flex-direction: column;
  align-items: start;
  padding: clamp(24px, 3vw, 40px);
  border-top: 1px solid var(--gold-line);
  background: var(--surface);
}
.mission-note__index { color: var(--gold); font: 500 11px/1.2 var(--mono); letter-spacing: 0.12em; }
.mission-note h3 {
  max-width: 18ch;
  margin-top: clamp(36px, 4vw, 52px);
  color: var(--text);
  font: 500 clamp(24px, 2.7vw, 36px)/1.08 var(--display);
  letter-spacing: -0.045em;
}
.mission-note > p:not(.mission-note__index) { max-width: 44ch; margin-top: 14px; color: var(--muted); font-size: 15px; line-height: 1.55; }
.mission-note a {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin-top: auto;
  padding-top: 28px;
  color: var(--text);
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: color 0.2s;
}
.mission-note a span:last-child { color: var(--gold); transition: transform 0.2s var(--ease); }
.mission-note a:hover { color: var(--gold-2); }
.mission-note a:hover span:last-child { transform: translate(3px, -3px); }

@media (max-width: 760px) {
  .mission-hero { min-height: 620px; padding-top: calc(var(--nav-h) + 96px); padding-bottom: 64px; }
  .mission-hero__title { max-width: 12ch; font-size: clamp(58px, 12.5vw, 88px); }
  .mission-hero__bottom { align-items: start; gap: 20px; }
  .mission-story__layout { grid-template-columns: minmax(0, 1fr); gap: 24px; }
  .mission-detail, .mission-notes__head { grid-template-columns: minmax(0, 1fr); gap: 22px; }
  .mission-notes__grid { grid-template-columns: minmax(0, 1fr); }
  .mission-note { min-height: 270px; }
}
@media (max-width: 480px) {
  .mission-hero { min-height: 590px; }
  .mission-hero__bottom { align-items: end; }
  .mission-hero__lead { font-size: 17px; }
  .mission-film__frame { height: 56vw; min-height: 250px; }
  .mission-photo { height: 58vw; min-height: 250px; }
  .mission-manifesto__title { font-size: clamp(40px, 11vw, 58px); }
}

/* ---------------------------------------------------------------- documentation page */
/* Both translations are in the page; only the current language shows. */
html:not([lang="es"]) [data-lang-block="es"], html[lang="es"] [data-lang-block="en"] { display: none; }
.doc[hidden], .docs-toc[hidden] { display: none; }

.docs-head {
  padding: calc(var(--nav-h) + clamp(40px, 5vw, 72px)) 0 clamp(28px, 3vw, 40px);
  background: radial-gradient(60% 70% at 85% 0%, var(--gold-soft), transparent 70%), var(--bg);
  border-bottom: 1px solid var(--line);
}
.docs-head .sec-label { padding-top: 0; }
.docs-head__title {
  margin-top: clamp(18px, 2vw, 26px);
  font: 500 clamp(36px, 5vw, 68px)/1 var(--display); letter-spacing: -0.045em; text-wrap: balance;
}
.docs-head__lead { margin-top: 16px; max-width: 60ch; color: var(--text-2); font-size: clamp(16px, 1.3vw, 18px); }

.docs-tabs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin-top: clamp(28px, 3vw, 40px); }
.docs-tab {
  display: grid; grid-template-columns: max-content minmax(0, 1fr); column-gap: 14px; row-gap: 6px; align-items: baseline;
  padding: 18px 20px; border: 1px solid var(--line-2); background: var(--bg-alt);
  transition: border-color 0.25s, background-color 0.25s;
}
.docs-tab:hover { border-color: var(--line-3); background: var(--surface); }
.docs-tab[aria-current] { border-color: var(--gold-line); background: var(--gold-soft); }
.docs-tab__n { grid-row: span 2; color: var(--gold); font: 500 11px/1.3 var(--mono); letter-spacing: 0.14em; }
.docs-tab b { font: 500 16px/1.25 var(--display); color: var(--text); }
.docs-tab__d { color: var(--muted); font-size: 13.5px; line-height: 1.45; }

.docs__layout {
  display: grid; grid-template-columns: 250px minmax(0, 1fr); gap: clamp(32px, 5vw, 80px); align-items: start;
  padding-top: clamp(32px, 4vw, 56px); padding-bottom: clamp(56px, 6vw, 96px);
  scroll-margin-top: var(--nav-h);
}

/* Contents sidebar */
.docs__side { position: sticky; top: calc(var(--nav-h) + 24px); max-height: calc(100vh - var(--nav-h) - 48px); overflow-y: auto; overscroll-behavior: contain; scrollbar-width: thin; }
.docs__side > summary { display: none; }
.docs-toc__h, .docs__side > summary {
  color: var(--muted); font: 500 10.5px/1.3 var(--mono); letter-spacing: 0.14em; text-transform: uppercase; margin-bottom: 14px;
}
.docs-toc ol { list-style: none; margin: 0; padding: 0; }
.docs-toc > ol { border-left: 1px solid var(--line-2); }
.docs-toc a {
  display: flex; gap: 10px; margin-left: -1px; padding: 6px 0 6px 14px; border-left: 1px solid transparent;
  color: var(--text-2); font-size: 13.5px; line-height: 1.4; transition: color 0.2s, border-color 0.2s;
}
.docs-toc a:hover { color: var(--text); }
.docs-toc a.is-current { color: var(--text); border-left-color: var(--gold); }
.docs-toc__n { flex: none; color: var(--dim); font: 500 10.5px/1.9 var(--mono); }
.docs-toc a.is-current .docs-toc__n { color: var(--gold); }
.docs-toc ol ol { display: none; padding-bottom: 6px; }
.docs-toc li.is-current > ol { display: block; }
.docs-toc ol ol a { padding: 4px 0 4px 38px; font-size: 12.5px; color: var(--muted); }

/* Article */
.doc__head { padding-bottom: clamp(24px, 3vw, 36px); border-bottom: 1px solid var(--line-2); }
.doc__kicker { display: flex; align-items: center; gap: 12px; color: var(--muted); font: 500 12px/1.3 var(--display); letter-spacing: 0.05em; text-transform: uppercase; }
.doc__kicker span { display: inline-flex; align-items: center; gap: 12px; color: var(--gold); }
.doc__kicker span::after { content: ""; width: 24px; height: 1px; background: var(--gold-line); }
.doc__title { margin-top: 16px; font: 500 clamp(28px, 3.4vw, 46px)/1.08 var(--display); letter-spacing: -0.035em; text-wrap: balance; }
.doc__lead { margin-top: 16px; max-width: 72ch; }
.doc__lead p { color: var(--text-2); font-size: 16.5px; line-height: 1.65; }
.doc__lead p + * { margin-top: 14px; }
.doc__meta {
  display: flex; flex-wrap: wrap; gap: 8px 24px; margin-top: 20px;
  color: var(--dim); font: 500 11px/1.3 var(--mono); letter-spacing: 0.08em; text-transform: uppercase;
}
.doc__meta a { color: var(--gold); transition: color 0.2s; }
.doc__meta a:hover { color: var(--gold-2); }

.prose { color: var(--text-2); font-size: 15.5px; line-height: 1.7; }
.prose > * + *, .doc__lead > * + * { margin-top: 16px; }
.prose p, .prose ul, .prose ol { max-width: 76ch; }
.prose h2 {
  display: flex; align-items: baseline; gap: 14px;
  margin-top: clamp(48px, 5vw, 72px); padding-top: 24px; border-top: 1px solid var(--line-2);
  color: var(--text); font: 500 clamp(24px, 2.4vw, 32px)/1.15 var(--display); letter-spacing: -0.025em;
}
.prose > h2:first-child { margin-top: clamp(32px, 3.5vw, 48px); border-top: 0; padding-top: 0; }
.doc-h__n { flex: none; color: var(--gold); font: 500 12px/1 var(--mono); letter-spacing: 0.14em; transform: translateY(-0.35em); }
.prose h3 { margin-top: 36px; color: var(--text); font: 500 19px/1.3 var(--display); letter-spacing: -0.01em; }
.prose h4 { margin-top: 28px; color: var(--text); font: 500 15.5px/1.35 var(--display); }
.prose h2 + *, .prose h3 + *, .prose h4 + * { margin-top: 14px; }
.prose :is(h2, h3, h4) { scroll-margin-top: calc(var(--nav-h) + 20px); }
.prose strong { color: var(--text); font-weight: 500; }
.prose a, .doc__lead a { color: var(--gold-2); border-bottom: 1px solid var(--gold-line); transition: border-color 0.2s; }
.prose a:hover, .doc__lead a:hover { border-color: var(--gold-2); }
.doc__lead strong { color: var(--text); font-weight: 500; }
.prose ul, .prose ol { padding-left: 1.3em; }
.prose li + li { margin-top: 6px; }
.prose li > ul, .prose li > ol { margin-top: 6px; }
.prose li::marker { color: var(--gold); }
.prose ol > li::marker { font: 500 12px var(--mono); }
.prose hr { border: 0; border-top: 1px solid var(--line-2); margin: 40px 0; }
.prose blockquote, .doc__lead blockquote {
  margin: 20px 0 0; padding: 14px 18px; max-width: 76ch;
  border-left: 2px solid var(--gold-line); background: var(--gold-soft); color: var(--text-2);
}
.prose blockquote p, .doc__lead blockquote p { font-size: 14.5px; }

.doc-table { overflow-x: auto; border: 1px solid var(--line-2); background: var(--bg-alt); }
.doc-table table { width: 100%; border-collapse: collapse; font-size: 14px; line-height: 1.55; }
.doc-table th {
  text-align: left; white-space: nowrap; padding: 10px 14px; border-bottom: 1px solid var(--line-2);
  color: var(--muted); font: 500 10.5px/1.3 var(--mono); letter-spacing: 0.12em; text-transform: uppercase;
}
.doc-table td { padding: 10px 14px; border-top: 1px solid var(--line); vertical-align: top; color: var(--text-2); }
.doc-table tr:first-child td { border-top: 0; }
.doc-table td:first-child { color: var(--text); }
.doc-table code { white-space: nowrap; }

.doc-code pre { font-size: 12.5px; line-height: 1.7; }
.doc-code pre code { padding: 0; border: 0; background: none; font-size: inherit; color: inherit; }
.doc-code .code__bar { text-transform: uppercase; letter-spacing: 0.14em; color: var(--gold); }

.doc-shot { margin: 24px 0 0; border: 1px solid var(--line-2); background: var(--bg-alt); }
.doc-shot img { width: 100%; }

.doc-pager { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; margin-top: clamp(48px, 5vw, 72px); }
.doc-pager__link {
  display: grid; gap: 6px; padding: 18px 20px; border: 1px solid var(--line-2);
  transition: border-color 0.25s, background-color 0.25s;
}
.doc-pager__link:hover { border-color: var(--gold-line); background: var(--gold-soft); }
.doc-pager__link span { color: var(--muted); font: 500 10.5px/1.3 var(--mono); letter-spacing: 0.14em; text-transform: uppercase; }
.doc-pager__link b { font: 500 17px/1.25 var(--display); color: var(--text); }
.doc-pager__link--next { grid-column: 2; text-align: right; }

@media (max-width: 960px) {
  .docs__layout { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .docs__side { position: static; max-height: none; overflow: visible; border: 1px solid var(--line-2); background: var(--bg-alt); }
  .docs__side > summary { display: flex; justify-content: space-between; margin: 0; padding: 14px 18px; cursor: pointer; list-style: none; }
  .docs__side > summary::-webkit-details-marker { display: none; }
  .docs__side > summary::after { content: "+"; color: var(--gold); font-size: 14px; line-height: 1; }
  .docs__side[open] > summary::after { content: "−"; }
  .docs__side .docs-toc { padding: 0 18px 14px; }
  .docs__side .docs-toc__h { display: none; }
}
@media (max-width: 760px) {
  /* Wide tables scroll sideways instead of squeezing each column to a few words. */
  .doc-table th, .doc-table td { min-width: 120px; }
  .doc-table td:last-child { min-width: 260px; }
  .docs-tabs { grid-template-columns: minmax(0, 1fr); }
  .docs-tab__d { display: none; }
  .docs-tab { padding: 14px 16px; }
  .docs-tab__n { grid-row: auto; }
  .doc-pager { grid-template-columns: minmax(0, 1fr); }
  .doc-pager__link--next { grid-column: auto; }
}
