/* Hallmark · macrostructure: Feature Stack · tone: technical, calm-confident · anchor hue: cobalt 256
 * genre: modern-minimal · theme: Cobalt · nav: Cobalt bordered bar + ⌘K palette · footer: Ft5 Statement
 * enrichment: real product screenshots + E5 hand-built SVG (QuoteMate room, SSO flow) · motion: GSAP 3 (ScrollTrigger, SplitText, ScrambleText, DrawSVG)
 * Hallmark · pre-emit critique: P4 H5 E4 S5 R4 V4
 */
@import url("tokens.css");

*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 80px; }
body {
  margin: 0;
  background: var(--color-paper);
  color: var(--color-ink-2);
  font: 400 var(--text-base)/1.6 var(--font-body);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3, h4 { font-family: var(--font-display); color: var(--color-ink); font-weight: 600; font-style: normal; margin: 0; letter-spacing: -0.02em; overflow-wrap: anywhere; min-width: 0; }
p { margin: 0; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--color-focus); outline-offset: 3px; border-radius: 4px; }
::selection { background: var(--color-accent-soft); color: var(--color-ink); }

.wrap { width: 100%; max-width: 1240px; margin-inline: auto; padding-inline: var(--gutter); }
.mono { font-family: var(--font-mono); }
.label { font: 500 var(--text-xs)/1.4 var(--font-mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--color-muted); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* hero elements are hidden only while JS animation is pending */
.js-anim [data-hero] { visibility: hidden; }

/* ───────────────────────── Buttons & links ───────────────────────── */
.btn {
  display: inline-flex; align-items: center; gap: var(--space-2xs);
  height: 44px; padding: 0 var(--space-md);
  border-radius: var(--radius-sm); border: var(--rule-hair) solid transparent;
  font: 500 var(--text-sm)/1 var(--font-body); white-space: nowrap; text-decoration: none; cursor: pointer;
  transition: background-color var(--dur-micro) var(--ease-out), border-color var(--dur-micro) var(--ease-out), transform var(--dur-micro) var(--ease-out);
}
.btn:active { transform: translateY(1px); }
.btn--primary { background: var(--color-accent); color: var(--color-accent-ink); }
.btn--primary:hover { background: var(--color-accent-hover); }
.btn--ghost { border-color: var(--color-rule-2); color: var(--color-ink); background: var(--color-surface); }
.btn--ghost:hover { border-color: var(--color-accent); }
.btn__arrow { transition: transform var(--dur-short) var(--ease-out); }
.btn:hover .btn__arrow { transform: translateX(3px); }

.link {
  color: var(--color-ink); text-decoration: none; white-space: nowrap;
  background: linear-gradient(var(--color-accent), var(--color-accent)) 0 100% / 0 1px no-repeat;
  transition: background-size var(--dur-short) var(--ease-out), color var(--dur-micro) var(--ease-out);
}
.link:hover { background-size: 100% 1px; color: var(--color-accent); }

/* ───────────────────────── Nav ───────────────────────── */
.nav {
  position: sticky; top: 0; z-index: 50;
  background: color-mix(in oklch, var(--color-paper) 94%, transparent);
  backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
  border-bottom: var(--rule-hair) solid var(--color-rule);
}
.nav__inner { display: flex; align-items: center; gap: var(--space-lg); height: 64px; }
.wordmark { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; color: var(--color-ink); font: 600 var(--text-lg)/1 var(--font-display); letter-spacing: -0.02em; white-space: nowrap; }
.wordmark__mark { width: 30px; height: 30px; }
.nav__links { display: flex; gap: var(--space-md); margin: 0; padding: 0; list-style: none; font-size: var(--text-sm); }
.nav__links a { padding-block: 6px; }
.nav__links a.is-current { color: var(--color-accent); background-size: 100% 1px; }
.nav__right { margin-left: auto; display: flex; align-items: center; gap: var(--space-xs); }
.kbd-btn {
  height: 36px; display: inline-flex; align-items: center; gap: var(--space-2xs);
  padding: 0 var(--space-xs); border: var(--rule-hair) solid var(--color-rule-2); border-radius: var(--radius-sm);
  background: var(--color-surface); color: var(--color-muted); font: 400 var(--text-sm)/1 var(--font-body); cursor: pointer; white-space: nowrap;
  transition: border-color var(--dur-micro) var(--ease-out), color var(--dur-micro) var(--ease-out);
}
.kbd-btn:hover { border-color: var(--color-accent); color: var(--color-ink); }
kbd { font: 500 11px/1 var(--font-mono); padding: 4px 6px; border: var(--rule-hair) solid var(--color-rule-2); border-radius: 4px; background: var(--color-paper-2); color: var(--color-ink-2); }
.nav .btn { height: 36px; padding: 0 var(--space-sm); }
.nav__progress { position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; background: var(--color-accent); transform-origin: 0 50%; transform: scaleX(0); }

/* ───────────────────────── Hero ───────────────────────── */
.hero { padding-block: clamp(56px, 10vh, 120px) clamp(64px, 10vh, 112px); }
.hero__grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr); gap: clamp(32px, 5vw, 72px); align-items: center; }
.hero__meta { display: inline-flex; align-items: center; gap: var(--space-2xs); margin-bottom: var(--space-md); }
.hero__meta::before { content: ""; width: 8px; height: 8px; border-radius: 2px; background: var(--color-accent); }
.hero h1 { font-size: var(--text-display-s); line-height: 1.04; letter-spacing: -0.035em; }
.swap-line { display: block; white-space: nowrap; }
.swap { color: var(--color-accent); position: relative; display: inline-block; }
.swap::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0.04em; height: 0.07em; background: var(--color-accent-line); transform-origin: 0 50%; transform: scaleX(var(--u, 1)); }
.hero__lede { margin-top: var(--space-lg); max-width: 34rem; font-size: var(--text-lg); line-height: 1.6; color: var(--color-ink-2); }
.hero__actions { margin-top: var(--space-xl); display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-sm) var(--space-md); }

.term {
  margin: 0; background: var(--color-graphite); color: var(--color-on-dark);
  border: var(--rule-hair) solid var(--color-graphite-3); border-radius: var(--radius-md);
  box-shadow: 0 1px 2px var(--color-shadow), 0 24px 48px -24px var(--color-shadow);
  font: 400 13px/1.7 var(--font-mono); overflow: hidden;
}
.term__head { display: flex; justify-content: space-between; gap: var(--space-sm); padding: var(--space-xs) var(--space-md); border-bottom: var(--rule-hair) solid var(--color-on-dark-rule); color: var(--color-on-dark-2); font-size: var(--text-xs); }
.term__body { padding: var(--space-md); display: grid; gap: 2px; }
.term__cmd { color: var(--color-on-dark-2); margin-bottom: var(--space-2xs); }
.term__cmd b { color: var(--color-accent-on-dark); font-weight: 500; }
.term__row {
  display: grid; grid-template-columns: minmax(0, 1.2fr) minmax(0, 1.2fr) auto; gap: var(--space-sm); align-items: center;
  padding: 6px 8px; margin-inline: -8px; border-radius: 4px; text-decoration: none; color: inherit;
  transition: background-color var(--dur-micro) var(--ease-out);
}
a.term__row:hover { background: var(--color-graphite-2); }
.term__row span { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.term__kind { color: var(--color-on-dark-2); }
.dot { display: inline-flex; align-items: center; gap: 6px; }
.dot::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.dot--live { color: var(--color-live); }
.dot--beta { color: var(--color-beta); }
.dot--next { color: var(--color-accent-on-dark); }
.dot--next::before { background: transparent; border: 1.5px solid currentColor; }
.term__row--next { margin-top: var(--space-2xs); border-top: var(--rule-hair) dashed var(--color-on-dark-rule); padding-top: 12px; border-radius: 0; }
.term__caret { display: inline-block; width: 8px; height: 15px; background: var(--color-accent-on-dark); vertical-align: -2px; margin-left: 4px; }

/* ───────────────────────── Section heads ───────────────────────── */
.section { padding-block: clamp(72px, 12vw, 144px); }
.section-head { display: grid; gap: var(--space-sm); max-width: 44rem; margin-bottom: clamp(40px, 6vw, 72px); }
.section-head::before { content: ""; width: 44px; height: 4px; border-radius: 2px; background: var(--color-accent); }
.section-head h2 { font-size: var(--text-3xl); line-height: 1.08; }
.hl { color: var(--color-accent); }
.band .hl { color: var(--color-accent-on-dark); }
.section-head p { font-size: var(--text-lg); color: var(--color-muted); }

/* ───────────────────────── Work index ───────────────────────── */
.index { list-style: none; margin: 0; padding: 0; border-top: var(--rule-hair) solid var(--color-rule-2); }
.index__row { border-bottom: var(--rule-hair) solid var(--color-rule); }
.index__link {
  display: grid; grid-template-columns: 56px minmax(0, 1.4fr) minmax(0, 1.2fr) 120px 24px; gap: var(--space-md); align-items: center;
  padding: var(--space-md) 0; text-decoration: none; color: var(--color-ink);
}
.index__num { color: var(--color-accent); }
.index__name { font: 600 var(--text-2xl)/1.15 var(--font-display); letter-spacing: -0.02em; transition: transform var(--dur-short) var(--ease-out), color var(--dur-micro) var(--ease-out); }
.index__kind { color: var(--color-muted); font-size: var(--text-sm); }
.index__status { font-size: var(--text-sm); }
.index__arrow { color: var(--color-muted); transition: transform var(--dur-short) var(--ease-out), color var(--dur-micro) var(--ease-out); }
.index__link:hover .index__name { transform: translateX(8px); color: var(--color-accent); }
.index__link:hover .index__arrow { transform: translateX(4px); color: var(--color-accent); }
.preview {
  position: fixed; left: 0; top: 0; z-index: 40; width: 340px; aspect-ratio: 16 / 10; pointer-events: none;
  border-radius: var(--radius-md); overflow: hidden; border: var(--rule-hair) solid var(--color-rule-2);
  background: var(--color-paper-2); box-shadow: 0 24px 48px -16px var(--color-shadow);
  visibility: hidden; opacity: 0;
}
.preview > * { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: top center; opacity: 0; transition: opacity var(--dur-short) var(--ease-out); }
.preview > .is-on { opacity: 1; }
.preview__svg { background: var(--color-paper-2); padding: 16px; object-fit: contain; }
.preview__tm { background: var(--color-graphite); object-fit: contain !important; object-position: center !important; padding: 12px; }

/* ───────────────────────── Case studies (Feature Stack) ───────────────────────── */
.case { padding-block: clamp(64px, 9vw, 120px); border-top: var(--rule-hair) solid var(--color-rule); }
.case__grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: clamp(32px, 5vw, 80px); }
.case__rail { position: sticky; top: 96px; align-self: start; display: grid; gap: var(--space-md); max-height: calc(100vh - 120px); }
.case__num { display: flex; gap: var(--space-xs); align-items: center; color: var(--color-accent); }
.case__num::after { content: ""; flex: 1; height: 2px; background: var(--color-accent-line); max-width: 80px; }
.case h3 { font-size: var(--text-3xl); line-height: 1.05; }
.case__ask { padding-left: var(--space-sm); border-left: 2px solid var(--color-accent); color: var(--color-ink); font-size: var(--text-lg); line-height: 1.5; }
.case__ask .label { display: block; margin-bottom: 4px; }
.steps { list-style: none; margin: 0; padding: 0; border-top: var(--rule-hair) solid var(--color-rule); }
.step { border-bottom: var(--rule-hair) solid var(--color-rule); }
.step__btn { width: 100%; display: grid; grid-template-columns: 32px minmax(0, 1fr); gap: var(--space-2xs); align-items: baseline; padding: var(--space-xs) 0; background: none; border: 0; text-align: left; cursor: pointer; color: var(--color-muted); transition: color var(--dur-short) var(--ease-out); }
.step__btn .mono { font-size: var(--text-xs); }
.step__title { font: 500 var(--text-base)/1.4 var(--font-display); }
.step__body { display: grid; grid-template-rows: 0fr; transition: grid-template-rows var(--dur-long) var(--ease-in-out); }
.step__body > p { overflow: hidden; padding-left: 40px; font-size: var(--text-sm); color: var(--color-ink-2); }
.step.is-active .step__btn { color: var(--color-ink); }
.step.is-active .step__btn .mono { color: var(--color-accent); }
.step.is-active .step__body { grid-template-rows: 1fr; }
.step.is-active .step__body > p { padding-bottom: var(--space-sm); }
.case__meta { display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-2xs) var(--space-md); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; margin: 0; padding: 0; }
.chips li { font: 400 var(--text-xs)/1 var(--font-mono); padding: 6px 8px; border: var(--rule-hair) solid var(--color-rule-2); border-radius: 4px; color: var(--color-ink-2); background: var(--color-surface); }
.status { font: 500 var(--text-xs)/1 var(--font-mono); letter-spacing: 0.04em; }

.frames { display: grid; gap: 0; }
.frame { min-height: 82vh; display: grid; align-content: center; gap: var(--space-sm); margin: 0; padding-block: var(--space-xl); }
.frame:first-child { min-height: 70vh; align-content: start; padding-top: 0; }
.frame__media { border-radius: var(--radius-md); overflow: hidden; border: var(--rule-hair) solid var(--color-rule-2); background: var(--color-paper-2); box-shadow: 0 1px 2px var(--color-shadow), 0 32px 64px -32px var(--color-shadow); }
.frame__media img { width: 100%; height: auto; aspect-ratio: 16 / 10; object-fit: cover; object-position: top center; transform-origin: 50% 0; }
.frame figcaption { display: none; font-size: var(--text-sm); color: var(--color-muted); }
.frame figcaption b { color: var(--color-ink); font-weight: 600; }
.frame__note { font-size: var(--text-xs); color: var(--color-muted); }

/* Built panels (diagrams that are not screenshots) */
.panel { padding: clamp(20px, 3vw, 40px); background: var(--color-surface); }
.panel--dark { background: var(--color-graphite); color: var(--color-on-dark); }
.panel__title { display: flex; justify-content: space-between; gap: var(--space-sm); margin-bottom: var(--space-md); }
.panel--dark .label { color: var(--color-on-dark-2); }

/* SSO flow */
.flow { display: grid; grid-template-columns: minmax(0, 1fr) 64px minmax(0, 1fr) 64px minmax(0, 1fr); align-items: center; gap: 0; }
.flow__node { padding: var(--space-md) var(--space-sm); border: var(--rule-hair) solid var(--color-rule-2); border-radius: var(--radius-md); background: var(--color-paper); display: grid; gap: 6px; min-height: 132px; align-content: start; }
.flow__node h4 { font-size: var(--text-lg); line-height: 1.2; }
.flow__node p { font-size: var(--text-sm); color: var(--color-muted); }
.flow__node--key { border-color: var(--color-accent); box-shadow: 0 0 0 4px var(--color-accent-soft); }
.flow__wire { position: relative; height: 2px; background: var(--color-rule-2); }
.flow__pulse { position: absolute; left: 0; top: -4px; width: 10px; height: 10px; border-radius: 50%; background: var(--color-accent); }
.flow__foot { margin-top: var(--space-md); display: flex; flex-wrap: wrap; gap: var(--space-2xs) var(--space-md); }
.flow__foot span { display: inline-flex; gap: 6px; align-items: center; font-size: var(--text-sm); color: var(--color-ink-2); }
.flow__foot span::before { content: "✓"; color: var(--color-accent); font-weight: 600; }

/* QuoteMate phone screens */
.phones { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(8px, 2vw, 20px); align-items: start; }
.frame__media .phones img { width: 100%; height: auto; aspect-ratio: 780 / 1688; object-fit: cover; border-radius: var(--radius-lg); border: var(--rule-hair) solid var(--color-rule-2); box-shadow: 0 16px 32px -20px var(--color-shadow); }
.phones img:nth-child(2) { margin-top: clamp(12px, 3vw, 32px); }

/* QuoteMate room */
.room { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: var(--space-lg); align-items: center; }
.room svg { width: 100%; height: auto; overflow: visible; }
.room .r-floor { fill: var(--color-accent-soft); stroke: var(--color-accent); stroke-width: 1.5; }
.room .r-wall { fill: var(--color-paper); stroke: var(--color-ink-2); stroke-width: 1.2; }
.room .r-wall--b { fill: var(--color-paper-3); }
.room .r-open { fill: var(--color-paper-2); stroke: var(--color-ink-2); stroke-width: 1; stroke-dasharray: 3 3; }
.room .r-dim { font: 500 12px var(--font-mono); fill: var(--color-ink); }
.room .r-tick { stroke: var(--color-muted); stroke-width: 1; }
.readout { display: grid; gap: 0; font-family: var(--font-mono); font-size: var(--text-sm); }
.readout dd { white-space: nowrap; }
.readout div { display: flex; justify-content: space-between; gap: var(--space-sm); padding: 10px 0; border-bottom: var(--rule-hair) solid var(--color-rule); }
.readout dt, .readout dd { margin: 0; }
.readout dt { color: var(--color-muted); }
.readout dd { color: var(--color-ink); font-weight: 500; }
.readout .is-total dd { color: var(--color-accent); }

/* QuoteMate calc */
.calc { display: grid; gap: 0; font-family: var(--font-mono); }
.calc__row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-md); padding: var(--space-sm) 0; border-bottom: var(--rule-hair) solid var(--color-on-dark-rule); align-items: baseline; }
.calc__row span:first-child { color: var(--color-on-dark-2); font-size: var(--text-sm); }
.calc__row span:last-child { color: var(--color-on-dark); font-size: var(--text-lg); }
.calc__row--total span:last-child { color: var(--color-accent-on-dark); font: 600 var(--text-3xl)/1 var(--font-display); }

/* QuoteMate pipeline */
.pipe { display: flex; flex-wrap: wrap; gap: var(--space-2xs); list-style: none; padding: 0; margin: 0 0 var(--space-lg); }
.pipe li { font: 500 var(--text-sm)/1 var(--font-mono); padding: 10px 12px; border-radius: var(--radius-sm); border: var(--rule-hair) solid var(--color-rule-2); background: var(--color-surface); color: var(--color-muted); }
.pipe li.is-lit { border-color: var(--color-accent); color: var(--color-ink); }
.pipe li:last-child.is-lit { background: var(--color-accent); color: var(--color-accent-ink); }
.pdf { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: var(--space-xs) var(--space-md); padding: var(--space-md); border: var(--rule-hair) solid var(--color-rule-2); border-radius: var(--radius-sm); background: var(--color-paper); font-size: var(--text-sm); }
.pdf__no { font: 600 var(--text-xl)/1 var(--font-display); color: var(--color-ink); white-space: nowrap; }
.pdf__bar { grid-column: 1 / -1; height: 8px; border-radius: 2px; background: var(--color-paper-3); }
.pdf__bar:nth-of-type(2) { width: 82%; }
.pdf__bar:nth-of-type(3) { width: 64%; }

/* TaskMaster */
.tm { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: clamp(24px, 4vw, 48px); align-items: center; }
.tm img { width: 300px; height: auto; aspect-ratio: auto; border-radius: var(--radius-md); box-shadow: 0 24px 48px -16px oklch(0% 0 0 / 0.5); }
.tm__list { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; }
.tm__list li { padding: var(--space-sm) 0; border-bottom: var(--rule-hair) solid var(--color-on-dark-rule); display: grid; gap: 2px; }
.tm__list b { color: var(--color-on-dark); font: 500 var(--text-base)/1.3 var(--font-display); }
.tm__list span { color: var(--color-on-dark-2); font-size: var(--text-sm); }
.builds { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--space-sm); }
.build { padding: var(--space-md); border: var(--rule-hair) solid var(--color-rule-2); border-radius: var(--radius-md); background: var(--color-surface); display: grid; gap: var(--space-2xs); }
.build b { font: 600 var(--text-xl)/1.1 var(--font-display); color: var(--color-ink); }
.build code { font: 400 var(--text-xs)/1.5 var(--font-mono); color: var(--color-muted); overflow-wrap: anywhere; }

/* ───────────────────────── Capabilities (the one dark band) ───────────────────────── */
.band { background: var(--color-band); color: var(--color-on-dark-2); }
.band .section-head::before { background: var(--color-accent-on-dark); }
.band .section-head h2 { color: var(--color-on-dark); }
.band .section-head p { color: var(--color-on-dark-2); }
.caps { list-style: none; margin: 0; padding: 0; }
.cap { position: relative; display: grid; grid-template-columns: 64px minmax(0, 1.1fr) minmax(0, 1.3fr) minmax(0, 0.9fr); gap: var(--space-md); padding: var(--space-xl) 0; align-items: start; }
.cap__rule { position: absolute; left: 0; right: 0; top: 0; height: 1px; background: var(--color-band-rule); transform-origin: 0 50%; }
.cap__num { color: var(--color-accent-on-dark); }
.cap h3 { color: var(--color-on-dark); font-size: var(--text-2xl); line-height: 1.15; transition: color var(--dur-short) var(--ease-out); }
.cap p { font-size: var(--text-base); }
.cap .chips li { background: var(--color-band-2); border-color: var(--color-band-rule); color: var(--color-on-dark); }
.cap:hover h3 { color: var(--color-accent-on-dark); }
.cap__flag { display: inline-block; margin-left: var(--space-2xs); font: 500 var(--text-xs)/1 var(--font-mono); color: var(--color-accent-on-dark); vertical-align: middle; letter-spacing: 0.04em; }

/* ───────────────────────── Process ───────────────────────── */
.process-wrap { position: relative; }
.process { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--space-lg); list-style: none; margin: 0; padding: 0; }
.process__line { position: absolute; left: 0; right: 0; top: 7px; width: 100%; height: 2px; overflow: visible; }
.process__line path { stroke: var(--color-accent); stroke-width: 2; fill: none; }
.process__line .base { stroke: var(--color-rule-2); }
.pstep { position: relative; display: grid; gap: var(--space-xs); padding-top: var(--space-xl); }
.pstep::before { content: ""; position: absolute; top: 0; left: 0; width: 16px; height: 16px; border-radius: 50%; background: var(--color-accent); box-shadow: 0 0 0 5px var(--color-accent-soft); }
.pstep h3 { font-size: var(--text-xl); line-height: 1.2; }
.pstep p { font-size: var(--text-sm); }
.pstep--key::before { background: var(--color-accent); }

/* ───────────────────────── Footer — Statement ───────────────────────── */
.foot { padding-block: clamp(80px, 12vw, 160px) var(--space-xl); border-top: var(--rule-hair) solid var(--color-rule); }
.foot__statement { font-size: var(--text-display-s); line-height: 1.04; letter-spacing: -0.035em; max-width: 16ch; }
.foot__cta { margin-top: var(--space-xl); display: flex; flex-wrap: wrap; align-items: center; gap: var(--space-md); }
.foot__mail { font: 500 var(--text-2xl)/1.2 var(--font-display); color: var(--color-accent); text-decoration: none; background: linear-gradient(var(--color-accent), var(--color-accent)) 0 100% / 100% 2px no-repeat; padding-bottom: 4px; transition: color var(--dur-micro) var(--ease-out); overflow-wrap: anywhere; }
.foot__mail:hover { color: var(--color-accent-hover); }
.foot__base { margin-top: var(--space-3xl); padding-top: var(--space-md); border-top: var(--rule-hair) solid var(--color-rule); display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: var(--space-sm); font-size: var(--text-sm); color: var(--color-muted); }
.foot__brand { display: inline-flex; align-items: center; gap: var(--space-xs); }
.foot__brand img { width: 40px; height: 40px; }
.foot__brand > span { display: grid; gap: 2px; }
.foot__brand b { font: 600 var(--text-lg)/1.1 var(--font-display); color: var(--color-ink); letter-spacing: -0.02em; }

/* ───────────────────────── ⌘K palette ───────────────────────── */
.palette { position: fixed; inset: 0; z-index: 100; display: none; place-items: start center; padding: 14vh var(--space-sm) 0; background: var(--color-scrim); }
.palette.is-open { display: grid; }
.palette__box { width: min(560px, 100%); background: var(--color-surface); border: var(--rule-hair) solid var(--color-rule-2); border-radius: var(--radius-lg); box-shadow: 0 32px 64px -24px var(--color-shadow); overflow: hidden; }
.palette__input { width: 100%; height: 56px; padding: 0 var(--space-md); border: 0; border-bottom: var(--rule-hair) solid var(--color-rule); background: transparent; font: 400 var(--text-base)/1 var(--font-mono); color: var(--color-ink); outline: none; }
.palette__list { list-style: none; margin: 0; padding: var(--space-2xs); max-height: 50vh; overflow: auto; }
.palette__item { display: flex; justify-content: space-between; gap: var(--space-sm); padding: 10px 12px; border-radius: var(--radius-sm); cursor: pointer; font-size: var(--text-sm); color: var(--color-ink-2); }
.palette__item span:last-child { color: var(--color-muted); font: 400 var(--text-xs)/1.6 var(--font-mono); white-space: nowrap; }
.palette__item.is-sel { background: var(--color-accent-soft); color: var(--color-ink); }
.palette__empty { padding: var(--space-md); color: var(--color-muted); font-size: var(--text-sm); }

/* ───────────────────────── Responsive ───────────────────────── */
@media (max-width: 1080px) {
  .cap { grid-template-columns: 48px minmax(0, 1fr) minmax(0, 1.2fr); }
  .cap .chips { grid-column: 2 / -1; }
  .process { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: var(--space-xl); }
  .process__line { display: none; }
}
@media (max-width: 900px) {
  .nav__links { display: none; }
  .hero__grid { grid-template-columns: minmax(0, 1fr); }
  .case__grid { grid-template-columns: minmax(0, 1fr); }
  .case__rail { position: static; max-height: none; }
  .steps { display: none; }
  .frame, .frame:first-child { min-height: 0; padding-block: var(--space-md) 0; }
  .frame figcaption { display: block; }
  .room { grid-template-columns: minmax(0, 1fr); }
  .tm { grid-template-columns: minmax(0, 1fr); justify-items: center; }
  .index__link { grid-template-columns: 40px minmax(0, 1fr) 24px; }
  .index__kind, .index__status { display: none; }
  .preview { display: none; }
}
@media (max-width: 640px) {
  .kbd-btn .kbd-label { display: none; }
  .flow { grid-template-columns: minmax(0, 1fr); gap: var(--space-xs); }
  .flow__wire { width: 2px; height: 28px; justify-self: center; }
  .flow__pulse { left: -4px; top: 0; }
  .flow__node { min-height: 0; }
  .builds { grid-template-columns: minmax(0, 1fr); }
  .cap { grid-template-columns: minmax(0, 1fr); gap: var(--space-xs); padding: var(--space-lg) 0; }
  .cap .chips { grid-column: auto; }
  .process { grid-template-columns: minmax(0, 1fr); }
  .term { font-size: 12px; }
  .term__row { grid-template-columns: minmax(0, 1fr) auto; }
  .term__kind { display: none; }
  .tm img { width: min(300px, 100%); }
  .nav__inner { gap: var(--space-sm); }
}
@media (max-width: 400px) {
  .nav .btn { display: none; }
  .swap-line { white-space: normal; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: 150ms !important; animation-duration: 150ms !important; animation-iteration-count: 1 !important; }
  .js-anim [data-hero] { visibility: visible; }
  html { scroll-behavior: auto; }
}
