/* Hallmark · pre-emit critique: P5 H5 E5 S5 R4 V5
 * Hallmark · macrostructure: Split Studio (editorial) · theme: studied-DNA
 * source: user design brief + Regenetix reference board
 * paper #F2F1EE · surfaces #FFFFFF / #F9EDEA · ink #141414 · one accent #E0281C
 * type: Geist Sans 600/500/400 + Geist Mono 500 technical labels
 * wordmark: custom Attesko artwork, never set in a font
 *
 * Carried from the brief: warm-paper page, alternating white/blush sections,
 * one signal red, bracket device 【 like this* 】, black pills, circled section
 * numbers, oversized 01/02/03 numerals, red arrows, and hairline rules.
 * imagery: six cohesive glossy signal-red studio renders; no illustration stand-ins.
 *
 * Deviations, and why:
 *   410×840 iPhone frame   → bezel-less silhouette; hand-drawn phone chrome is a tell (gate 47)
 *   two figures asterisked → ALL illustrative figures asterisked; partial disclosure is worse
 *   #FFFFFF surfaces       → kept exactly as the brief specifies (trips gate 7 knowingly)
 *   pre-footer scrim added → the S7 copy sits on the red office plate: ink read ~1.3:1 and the
 *     red CTA disappeared into the red behind it. The original review missed this because
 *     office.avif was encoded so that Chrome never painted it (see assets note below); it was
 *     only ever seen on the paper background. Scrim clears the copy, art keeps full strength.
 * assets: AVIF must not be encoded with macOS `sips` — those files carry correct ispe
 *   dimensions but never rasterise in Chrome. Encode with ffmpeg/libsvtav1.
 * contrast: pass (40–41) · honest: pass (46, every invented figure disclosed)
 * tokens: pass (48) · responsive: pass (49) · mobile: pass (34, 50–57)
 */

/* ── base ─────────────────────────────────────────────────── */

*, *::before, *::after { box-sizing: border-box; }
html, body { overflow-x: clip; max-width: 100%; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 96px; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-brand);
  font-size: var(--t-body);
  font-weight: 400;
  line-height: var(--lh-body);
  letter-spacing: var(--tr-body);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  margin: 0;
  font-family: var(--font-brand);
  font-weight: 600;
  font-style: normal;
  letter-spacing: var(--tr-display);
}
p, ul, ol, dl, dd, dt, figure { margin: 0; }
ul, ol { list-style: none; padding: 0; }
img { display: block; max-width: 100%; height: auto; }
svg { display: block; }
a { color: inherit; }
sup { font-size: 0.62em; vertical-align: super; line-height: 0; }

/* The generated renders sit on a near-white sweep, which prints as a visible
   plate against warm paper or blush. Lift the sweep to pure white, then
   multiply: white × any backdrop = that backdrop, so the plate disappears
   and only the red object remains. */
.knockout { filter: brightness(1.09); mix-blend-mode: multiply; }

::selection { background: var(--red); color: var(--white); }
:focus-visible { outline: 2px solid var(--red); outline-offset: 3px; border-radius: 3px; }

.skip {
  position: absolute; left: -9999px; top: var(--s-2); z-index: 999;
  background: var(--ink); color: var(--white);
  padding: var(--s-2) var(--s-4); border-radius: var(--r-sm);
  font-size: var(--t-body); white-space: nowrap;
}
.skip:focus { left: var(--s-4); }

.wrap { max-width: var(--container); margin-inline: auto; padding-inline: var(--gutter); }
.red  { color: var(--red); }
.mono { font-family: var(--font-technical); font-weight: 500; }

/* ── shared type ──────────────────────────────────────────── */

.h2 { font-size: var(--t-h2); line-height: 1.03; }
.h3 { font-size: var(--t-h3); line-height: 1.06; }

.lead {
  font-size: var(--t-lead);
  color: var(--ink-70);
  max-width: 46ch;
  margin-top: var(--s-6);
}

.eyebrow {
  display: flex; align-items: center; gap: var(--s-4);
  font-size: var(--t-label); letter-spacing: var(--tr-label);
  text-transform: uppercase; color: var(--ink-55);
  margin-bottom: var(--s-16);
}

.pill {
  display: inline-flex; align-items: center;
  padding: 7px var(--s-4) 6px;
  border-radius: var(--r-pill);
  background: var(--ink); color: var(--white);
  font-family: var(--font-brand);
  font-size: var(--t-label); font-weight: 600;
  letter-spacing: var(--tr-label); text-transform: uppercase;
  white-space: nowrap;
}
.pills { display: flex; flex-wrap: wrap; gap: var(--s-3); margin-top: var(--s-10); }

.circ {
  display: inline-grid; place-items: center;
  width: 28px; height: 28px; flex: none;
  border: 1px solid var(--ink-40); border-radius: 50%;
  font-family: var(--font-technical); font-size: var(--t-micro);
  font-weight: 500;
  color: var(--ink-55); letter-spacing: 0;
}

.ast { color: var(--red); font-weight: 600; }

.foot {
  margin-top: var(--s-8);
  font-family: var(--font-technical);
  font-weight: 500;
  font-size: var(--t-micro); line-height: 1.5;
  color: var(--ink-40); letter-spacing: 0;
  max-width: 60ch;
}

/* the brief's signature device: 【 phrase* 】 in red */
.brk { color: var(--red); white-space: nowrap; }
.brk::before { content: "【"; margin-right: 0.04em; font-weight: 400; }
.brk::after  { content: "】"; margin-left: 0.04em; font-weight: 400; }

/* ── sections ─────────────────────────────────────────────── */

.s { padding-block: var(--section-y); position: relative; }
.s--white { background: var(--white); }
.s--blush { background: var(--blush); }
.s--tight { padding-top: 0; }
.s + .s--white { border-top: 1px solid var(--rule); }

/* ── nav ──────────────────────────────────────────────────── */

.nav { position: relative; z-index: var(--z-nav); background: var(--white); border-bottom: 1px solid var(--rule); }
.nav__in {
  max-width: var(--container); margin-inline: auto;
  min-height: var(--nav-h);
  padding-inline: var(--gutter);
  display: flex; align-items: center; gap: var(--s-6);
}
.brand { display: inline-flex; align-items: center; min-height: 44px; }
.brand__logo { height: 26px; width: auto; }
.brand--inv .brand__logo { filter: invert(1); }

.nav__icons { display: flex; gap: var(--s-3); margin-inline: auto; }
.iconbtn {
  width: 36px; height: 36px; padding: 0;
  display: grid; place-items: center;
  border: 1px solid var(--rule); border-radius: 50%;
  background: transparent; color: var(--ink-55);
  text-decoration: none;
  cursor: pointer;
  transition: border-color var(--d-1) var(--ease), color var(--d-1) var(--ease);
}
.iconbtn svg { width: 15px; height: 15px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.iconbtn:hover { color: var(--red); border-color: var(--red-30); }
.iconbtn:active { color: var(--red); }
.iconbtn[disabled] { opacity: 0.45; cursor: not-allowed; }

.menu {
  display: inline-flex; align-items: center; gap: var(--s-3);
  min-height: 44px; padding: 0; border: 0; background: transparent;
  font-family: var(--font-brand); font-size: var(--t-label); font-weight: 500;
  letter-spacing: var(--tr-label); text-transform: uppercase;
  color: var(--ink); cursor: pointer; white-space: nowrap;
}
.menu__bars { display: grid; gap: 4px; width: 22px; }
.menu__bars i { display: block; height: 1px; background: var(--ink); }
.menu:hover .menu__bars i { background: var(--red); }
.menu[aria-expanded="true"] .menu__bars i:first-child { transform: translateY(2.5px) rotate(45deg); }
.menu[aria-expanded="true"] .menu__bars i:last-child { transform: translateY(-2.5px) rotate(-45deg); }
.menu__bars i { transition: transform var(--d-1) var(--ease), background-color var(--d-1) var(--ease); }

.menu-panel {
  position: absolute; inset: calc(100% + 1px) var(--gutter) auto auto;
  width: min(420px, calc(100% - (2 * var(--gutter))));
  padding: var(--s-4) var(--s-6);
  background: var(--ink); color: var(--white);
  border-radius: 0 0 var(--r-md) var(--r-md);
  box-shadow: var(--shadow-float);
  opacity: 0; visibility: hidden; transform: translateY(-8px);
  transition: opacity var(--d-1) var(--ease), transform var(--d-2) var(--ease), visibility var(--d-1) linear;
}
.menu-panel.is-open { opacity: 1; visibility: visible; transform: none; }
.menu-panel a {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 52px; border-bottom: 1px solid var(--white-15);
  font-family: var(--font-brand); font-size: 1.35rem; font-weight: 500;
  text-decoration: none;
}
.menu-panel a:last-child { color: var(--red); border-bottom: 0; }
.menu-panel a span { font-family: var(--font-technical); font-size: var(--t-micro); }

/* ── S1 hero ──────────────────────────────────────────────── */

.hero { padding-bottom: 0; }
.hero__grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: var(--s-16);
  align-items: end;
}
.hero__title {
  font-size: var(--t-hero);
  line-height: var(--lh-display);
  max-width: 20ch;
  overflow-wrap: anywhere; min-width: 0;
}

.stats { display: flex; }
.stats--row { gap: clamp(24px, 4vw, 64px); padding-bottom: var(--s-3); }
.stat__n {
  font-family: var(--font-brand);
  font-size: var(--t-stat-sm);
  font-weight: 600; line-height: 1;
  letter-spacing: var(--tr-display);
  font-variant-numeric: tabular-nums;
  display: flex; align-items: baseline; gap: 2px;
  white-space: nowrap;
}
.stat__u { font-size: 0.42em; font-weight: 500; color: var(--ink-55); }
.stat__k {
  margin-top: var(--s-3);
  font-family: var(--font-technical);
  font-weight: 500;
  font-size: var(--t-micro); line-height: 1.4;
  letter-spacing: 0.04em; text-transform: uppercase;
  color: var(--ink-55); max-width: 16ch;
}
.stats--big { gap: clamp(40px, 8vw, 128px); margin-top: var(--s-24); }
.stats--big .stat__n { font-size: var(--t-stat); }
.stats--big .stat__k { max-width: 20ch; }

.plate { position: relative; margin-top: var(--s-20); }
.plate--hero img { width: 100%; height: clamp(280px, 55vh, 620px); object-fit: cover; }

/* ── S2 belief ────────────────────────────────────────────── */

.belief {
  display: grid;
  grid-template-columns: 28px minmax(0, 1.35fr) minmax(0, var(--measure));
  gap: var(--s-10) clamp(32px, 6vw, 96px);
  align-items: start;
}
.belief__say { grid-column: 2; }
.say {
  font-size: var(--t-display);
  line-height: 1.02;
  max-width: 18ch;
  overflow-wrap: anywhere; min-width: 0;
}
.belief__body {
  grid-column: 3;
  font-size: var(--t-lead); color: var(--ink-70);
  padding-top: var(--s-2);
}
.belief .stats--big { grid-column: 2 / -1; }
.belief .foot { grid-column: 2 / -1; margin-top: 0; }

/* ── S3 map ───────────────────────────────────────────────── */

.map {
  display: grid;
  grid-template-columns: minmax(0, 45fr) minmax(0, 55fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: center;
}
.arrowlink {
  display: inline-flex; align-items: center; gap: var(--s-2);
  min-height: 44px; margin-top: var(--s-8);
  font-weight: 500; color: var(--red);
  text-decoration: none; white-space: nowrap;
  border-bottom: 1px solid var(--red-30);
  transition: border-color var(--d-1) var(--ease);
}
.arrowlink:hover { border-bottom-color: var(--red); }
.arrowlink:active { opacity: 0.7; }

.map__vis { position: relative; display: grid; place-items: center; }
.map__vis img { width: min(540px, 100%); height: auto; }

.mpill {
  position: absolute;
  display: inline-flex; align-items: center; gap: var(--s-2);
  padding: 9px var(--s-4);
  border-radius: var(--r-pill);
  background: var(--ink); color: var(--white);
  font-size: var(--t-label); font-weight: 500;
  white-space: nowrap;
  box-shadow: var(--shadow-float);
}
.mpill__arrow, .mpill__up { color: var(--red); font-weight: 600; }
.mpill--a { top: 10%; left: -1%; }
.mpill--b { bottom: 14%; right: -1%; }

/* ── S4 how ───────────────────────────────────────────────── */

.howtitle { text-align: right; margin-bottom: var(--s-16); }

.how {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 280px);
  gap: clamp(32px, 4vw, 64px);
  align-items: center;
}
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-6); }
.card {
  position: relative;
  padding: var(--s-8) var(--s-6) var(--s-6);
  background: var(--white);
  border: 1px solid var(--rule);
  border-radius: var(--r-md);
  box-shadow: var(--shadow-card);
  overflow: clip;
}
.card__num {
  position: absolute; top: -0.3em; right: -0.05em;
  font-size: clamp(96px, 11vw, 190px);
  font-family: var(--font-brand); font-weight: 600; line-height: 1;
  letter-spacing: -0.05em;
  color: var(--ink-08);
  pointer-events: none;
}
.card .pill { position: relative; }
.card__t { position: relative; font-size: var(--t-card); font-weight: 500; line-height: 1.1; margin: var(--s-5) 0 var(--s-3); }
.card p { position: relative; color: var(--ink-70); }
.ghost {
  position: relative;
  display: inline-flex; align-items: center; gap: var(--s-2);
  min-height: 44px; margin-top: var(--s-5);
  padding: 0 var(--s-5);
  border: 1px solid var(--rule); border-radius: var(--r-pill);
  font-size: var(--t-label); font-weight: 500;
  text-transform: uppercase; letter-spacing: var(--tr-label);
  text-decoration: none; white-space: nowrap;
  transition: border-color var(--d-1) var(--ease), color var(--d-1) var(--ease);
}
.ghost:hover { border-color: var(--red); color: var(--red); }
.ghost:active { opacity: 0.7; }

.how__vis { position: relative; }
.how__vis img { width: 100%; }
.thread-yes,
.hand-yes {
  position: absolute; z-index: 2;
  display: grid; place-items: center;
  color: var(--white);
  font-size: clamp(10px, 1vw, 14px); font-weight: 600; letter-spacing: 0.08em;
  pointer-events: none;
}
.thread-yes { left: 14%; top: 40%; width: 36%; height: 18%; }

/* ── S5 statement ─────────────────────────────────────────── */

.statement { overflow: clip; }
.statement__grid {
  display: grid;
  grid-template-columns: minmax(0, 40fr) minmax(0, 60fr);
  gap: var(--s-10);
  align-items: center;
}
.statement__say { position: relative; z-index: 1; }
.statement__say .circ { margin-bottom: var(--s-6); }
.say--stack { font-size: var(--t-display); line-height: 1.0; max-width: none; }
.statement__body { max-width: 34ch; margin-top: var(--s-8); color: var(--ink-70); }

/* the brief: the headline's last line tucks behind the wrist */
.statement__vis { position: relative; margin-left: clamp(-96px, -7vw, 0px); }
.statement__vis img { width: 100%; }
.hand-yes { left: 20%; top: 17%; width: 13%; aspect-ratio: 1; }

.mpill--c { top: 22%; left: 3%; }
.mpill--d { top: 22%; left: 3%; transform: translateY(46px); }
.resize {
  position: absolute; right: 5%; bottom: 12%;
  color: var(--red); font-size: 20px; letter-spacing: 0;
}

/* ── S6 ledger ────────────────────────────────────────────── */

.ledger {
  display: grid;
  grid-template-columns: minmax(0, 42fr) minmax(0, 58fr);
  gap: clamp(32px, 6vw, 96px);
  align-items: center;
}
.ledger__vis img { width: min(520px, 100%); margin-inline: auto; }

/* device — silhouette, not redrawn iOS chrome */
.device {
  margin-top: var(--s-10);
  width: min(320px, 100%);
  padding: 14px;
  border: 1px solid var(--rule);
  border-radius: 30px;
  background: var(--white);
  box-shadow: var(--shadow-device);
}
.device__screen {
  display: flex; flex-direction: column; align-items: flex-start; gap: var(--s-2);
  padding: var(--s-4);
  border-radius: 20px;
  background: var(--paper);
}
.bub {
  padding: 10px 13px;
  border-radius: 14px 14px 14px 4px;
  background: var(--white);
  border: 1px solid var(--rule);
  font-size: var(--t-label); line-height: 1.45;
  max-width: 92%;
}
.bub__r { display: block; margin-top: var(--s-2); color: var(--red); font-weight: 600; }
.bub--out {
  align-self: flex-end;
  border-radius: 14px 14px 4px 14px;
  background: var(--red); border-color: var(--red); color: var(--white);
  font-weight: 600; letter-spacing: 0.06em;
}
.bub--quiet { color: var(--ink-55); }
.bub--fri { border-color: var(--red-30); background: var(--red-08); font-weight: 500; }

/* ── S7 pre-footer ────────────────────────────────────────── */

.prefoot {
  position: relative; overflow: clip;
  min-height: clamp(420px, 40vw, 560px);
  display: grid; align-items: center;
  background: var(--white);
  border-top: 1px solid var(--rule);
}
.prefoot__art {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; object-position: center 58%;
  pointer-events: none;
}
/* The art is a saturated red floor plate and the copy sits on top of it:
   ink at ~1.3:1 and a red CTA that vanishes into the red behind it. This
   scrim clears a paper-coloured centre for the heading and button while
   leaving the render at full strength around the edges. */
.prefoot::after {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  /* Absolute radii rather than percentages: the copy block is a fixed
     physical size, so the clearing needs to be too. On a phone that means
     the scrim spans the full-width CTA; on a desktop it stays a pocket
     with the render at full strength either side. */
  background: radial-gradient(
    ellipse 520px 150px at 50% 47%,
    var(--white) 0%,
    var(--white) 40%,
    var(--white-70) 68%,
    transparent 100%
  );
}

.prefoot__in { position: relative; z-index: 1; text-align: center; padding-block: var(--s-24); }
.prefoot__t {
  font-family: var(--font-brand); font-weight: 600;
  font-size: var(--t-h3); line-height: 1.05;
  overflow-wrap: anywhere; min-width: 0;
}
.cta {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 52px; margin-top: var(--s-10);
  padding: 0 var(--s-10);
  border-radius: var(--r-pill);
  background: var(--red); color: var(--white);
  font-weight: 500; text-decoration: none; white-space: nowrap;
  transition: background-color var(--d-1) var(--ease), transform var(--d-1) var(--ease);
}
.cta:hover { background: var(--red-hover); }
.cta:active { transform: translateY(1px); }

/* ── footer ───────────────────────────────────────────────── */

.foot-b { background: var(--ink); color: var(--white); padding-top: var(--s-20); }
.foot-b__in {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: var(--s-10);
  align-items: center;
  padding-bottom: var(--s-16);
}
.foot-b__links { display: flex; flex-wrap: wrap; gap: var(--s-8); justify-content: center; }
.foot-b__links a {
  display: inline-flex; align-items: center; min-height: 44px;
  font-size: var(--t-label); font-weight: 500;
  text-transform: uppercase; letter-spacing: var(--tr-label);
  color: var(--white-70); text-decoration: none; white-space: nowrap;
  transition: color var(--d-1) var(--ease);
}
.foot-b__links a:hover { color: var(--white); }
.foot-b__links a:active { color: var(--red); }
.foot-b__note {
  font-family: var(--font-technical);
  font-size: var(--t-micro); line-height: 1.5; letter-spacing: 0;
  color: var(--white-70); max-width: 34ch; text-align: right;
}

.strip { border-top: 1px solid var(--white-15); overflow: clip; padding-block: var(--s-4); }
.strip__t {
  display: flex; gap: var(--s-10); width: max-content;
  animation: marq 42s linear infinite;
}
.strip__t span {
  font-size: var(--t-label); font-weight: 500;
  text-transform: uppercase; letter-spacing: var(--tr-label);
  color: var(--white-70); white-space: nowrap;
}
@keyframes marq { to { transform: translateX(-50%); } }
.strip:hover .strip__t, .strip:focus-within .strip__t { animation-play-state: paused; }

/* ── responsive ───────────────────────────────────────────── */

@media (max-width: 68rem) {
  .hero__grid { grid-template-columns: minmax(0, 1fr); gap: var(--s-12); align-items: start; }
  .hero__title { max-width: none; }

  .belief { grid-template-columns: 28px minmax(0, 1fr); }
  .belief__body { grid-column: 2; padding-top: 0; }
  .belief .stats--big, .belief .foot { grid-column: 2; }

  .map, .ledger, .statement__grid { grid-template-columns: minmax(0, 1fr); }
  .how { grid-template-columns: minmax(0, 1fr); }
  .how__vis { max-width: 250px; margin-inline: auto; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .howtitle { text-align: left; }

  .foot-b__in { grid-template-columns: minmax(0, 1fr); justify-items: start; gap: var(--s-6); }
  .foot-b__links { justify-content: flex-start; }
  .foot-b__note { text-align: left; }
}

@media (max-width: 48rem) {
  .cards { grid-template-columns: minmax(0, 1fr); }
  .stats--row, .stats--big {
    display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: var(--s-8) var(--s-6); width: 100%;
  }
  .nav__icons { display: none; }          /* keeps the bar to one line */
  .brand { margin-right: auto; }
  .mpill--a { top: 1%; left: 0; }
  .mpill--b { bottom: 2%; right: 0; }
  .device { margin-inline: auto; }
}

@media (max-width: 40rem) {
  .menu__t { display: none; }
  .plate--hero img { height: 300px; }
  .prefoot__in { padding-block: var(--s-20); }
  .cta { width: 100%; }
  .mpill--c, .mpill--d { left: 0; }
  .statement__vis { margin-top: var(--s-8); }
}

/* ── reduced motion ───────────────────────────────────────── */

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
  .strip__t { animation: none; }
}
