/* Registration page and confirmation page — mobile-first. ROUND 4, 2026-08-28.
   Michael asked for a ground-up redesign with full flexibility (taste-skill
   pass), which supersedes the 2026-08-25 round-3 lock. What did NOT move:
   every copy string (still pinned by tools/check_page_copy.py), the form DOM
   contract with register.js and the server, the disclaimer prominence rules,
   and the decisions that survived from round 3 on purpose:

   - the session facts live INSIDE the signup card (Michael, 2026-08-25)
   - the gold word in the headline
   - the flat navy ground with one quiet fractal-noise grain, no washes
   - the top bar is WHITE so it reads as its own plane
   - a named, pictured host

   What is new in round 4: Bricolage Grotesque display type over Inter body,
   both self-hosted from /assets/fonts (no Google CDN request); the session
   header inside the card goes navy so the card reads as a ticket; the covers
   list becomes a five-cell bento with one navy and one gold-tinted cell; the
   host photo gets a gold offset panel; entrance and scroll-reveal motion,
   fully gated behind prefers-reduced-motion.

   Radius system, one rule everywhere: containers 18px, controls 12px,
   chips/badges full pill.

   Senior floors, unchanged: 18px body minimum (17px wordmark is the one
   exception), labels above fields, 48px+ full-width CTA, one column on
   mobile, contrast measured not eyeballed (tools/contrast notes in log). */

:root {
  --white: #FFFFFF;
  --tint: #F2F5F9;
  --ink: #0A1628;
  --ink-2: #3E4C5E;
  --navy-panel: #14263D;
  --on-navy: #FFFFFF;
  --on-navy-2: #C7D0DB;
  --gold: #C9A84C;
  --gold-hover: #D8B95F;
  --gold-deep: #8A6D1E;      /* the only gold allowed as TYPE on a light ground */
  --gold-ghost: #F7F1E1;     /* tinted panel only, never a text colour */
  --ctrl: #6B7A8A;
  --hairline: #D7DEE6;
  --chip-edge: #7E8E9E;      /* drawn edges: 3.36:1 on white, 3.10:1 on the tint */
  --helper: #4A5A6C;
  --error-ink: #8C2F1F;
  --error-bg: #FBEDE9;
  --display: 'Bricolage Grotesque', 'Avenir Next', 'Segoe UI', Arial, sans-serif;
  --body: 'Inter', -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  --ease: cubic-bezier(0.16, 1, 0.3, 1);
}

/* Self-hosted latin subsets, variable weight. The page is English-only, so the
   latin block is the whole need; two files, ~150KB total, no third-party call. */
@font-face {
  font-family: 'Bricolage Grotesque';
  font-style: normal;
  font-weight: 200 800;
  font-display: swap;
  src: url('/assets/fonts/bricolage-grotesque-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url('/assets/fonts/inter-latin.woff2') format('woff2');
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  font-family: var(--body);
  background: var(--white);
  color: var(--ink);
  font-size: 19px;
  line-height: 1.55;
}
/* No `overflow-x: hidden` on the body, deliberately. It hides exactly the
   failures this page must not have: with it on, document.scrollWidth reports a
   clean width while an element overflows underneath, which is how the top bar
   ran 81px wide at 375px without the document admitting it. */

.shell { max-width: 1140px; margin: 0 auto; padding: 0 20px; }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 20;
  background: var(--white); color: var(--ink); padding: 14px 18px;
  font-size: 18px; font-weight: 700; border-radius: 0 0 12px 0;
}
.skip:focus { left: 0; }

a:focus-visible, button:focus-visible, input:focus-visible, .radio:focus-within {
  outline: 3px solid var(--ink);
  outline-offset: 2px;
}
.hero a:focus-visible, .legal a:focus-visible { outline-color: var(--on-navy); }
/* The skip link's target takes focus rather than just scroll position, so it
   needs a visible landing state of its own. */
#signup:focus-visible { outline: 3px solid var(--gold); outline-offset: 4px; }

/* ------------------------------------------------- top bar: white, not navy */
.topbar {
  background: var(--white);
  color: var(--ink);
  border-bottom: 1px solid var(--hairline);
}
.topbar .shell {
  display: flex; align-items: center; justify-content: space-between;
  gap: 14px; padding-top: 14px; padding-bottom: 14px;
}
.brand { display: flex; align-items: center; gap: 11px; }
.brand img { width: 30px; height: 30px; }
.brand span {
  font-size: 17px;              /* the one sub-18 string: it is a logotype */
  font-weight: 800; letter-spacing: 0.06em; text-transform: uppercase;
  white-space: nowrap; color: var(--ink);
}
/* The phone is the header's one action for a 65-to-75 audience, so it is drawn
   as a button, not a text link. */
.topbar-phone {
  display: inline-flex; align-items: center; gap: 9px;
  font-size: 18px; font-weight: 700; color: var(--ink);
  text-decoration: none; white-space: nowrap;
  min-height: 48px; padding: 9px 18px;
  border: 2px solid var(--ink); border-radius: 999px;
  background: var(--white);
}
.topbar-phone:hover { background: var(--tint); }
.topbar-phone svg { flex: 0 0 auto; color: var(--gold-deep); }

/* ------------------------------------------------------------------- hero */
.hero, .legal { position: relative; isolation: isolate; }
/* One quiet grain over the flat navy so a large colour field does not read as a
   default. Fractal-noise mechanism from Magic UI's noise-texture component,
   reimplemented as a data-URI because this project is vanilla CSS. */
.hero::before, .legal::before {
  content: ""; position: absolute; inset: 0; z-index: 0; pointer-events: none;
  opacity: 0.3;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='260' height='260'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.42'/%3E%3C/svg%3E");
  background-size: 260px 260px;
}
.hero > .shell, .legal > .shell { position: relative; z-index: 1; }

.hero {
  background: var(--ink);
  color: var(--on-navy);
  padding: 40px 0 76px;
}

h1 {
  font-family: var(--display);
  font-size: clamp(40px, 10vw, 58px);
  line-height: 1.02;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-wrap: balance;
  margin-bottom: 18px;
}
/* The gold half of the headline takes its own line: two short lines read
   faster at this size than one long one, and the colour break lands cleaner. */
.h1-em { display: block; color: var(--gold); }

.sub {
  font-size: 20px;
  line-height: 1.55;
  color: var(--on-navy-2);
  max-width: 30em;
  text-wrap: pretty;
}

/* The host strip: the named host is the category's strongest trust element,
   now placed at the point of decision instead of a screen below it. Two lines,
   both sourced (see the host-strip section of registration-page-copy.md). */
.hero-host {
  display: flex; align-items: center; gap: 15px;
  margin-top: 30px;
}
.hero-host-photo {
  width: 62px; height: 62px; flex: 0 0 62px;
  border-radius: 50%; object-fit: cover; object-position: 50% 12%;
  border: 2px solid var(--gold);
}
.hero-host-text { display: block; }
.hero-host-name { display: block; font-size: 18px; font-weight: 700; }
.hero-host-cred { display: block; font-size: 18px; color: var(--on-navy-2); }

/* -------------------------------------------- the signup band: form + story */
/* The session facts, the disclosure and the form are one object. The header
   inside the card is navy so the whole thing reads as a ticket for a specific
   evening, not a generic web form. On desktop the band is two columns: the
   story (covers + about) on the left, the card on the right, so the space
   beside the tall form carries the reason to register rather than air
   (Michael, 2026-08-28). The pull-up lives on the card, not the section, so
   the story column starts cleanly below the navy. */
.signup { position: relative; z-index: 2; padding-bottom: 56px; }

.form-card {
  margin-top: -48px;
  background: var(--white); color: var(--ink);
  border-radius: 18px; overflow: hidden;
  border: 1px solid var(--hairline);
  border-top: 5px solid var(--gold);
  box-shadow: 0 28px 64px rgba(4, 10, 20, 0.32), 0 4px 12px rgba(4, 10, 20, 0.14);
}

/* the session head */
.session {
  background: var(--navy-panel);
  color: var(--on-navy);
  padding: 18px 20px 16px;
}
.when { display: flex; align-items: center; gap: 14px; margin-bottom: 13px; }
.when-mark { color: var(--gold); display: grid; place-items: center; }
.when-body { display: block; }
.when-date {
  display: block; font-family: var(--display);
  font-size: 24px; font-weight: 700; letter-spacing: -0.01em;
}
.when-time { display: block; font-size: 18px; font-weight: 600; color: var(--gold); }

.badges { list-style: none; display: flex; flex-wrap: wrap; gap: 7px; }
.badge {
  display: inline-flex; align-items: flex-start; gap: 7px;
  font-size: 18px; font-weight: 600; color: var(--on-navy);
  max-width: 100%;
  padding: 6px 12px; border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.38);
  background: rgba(255, 255, 255, 0.06);
}
/* No `white-space: nowrap`: a badge that cannot wrap clips at 320px. */
.badge svg { flex: 0 0 auto; color: var(--gold); margin-top: 2px; }

.block3 {
  font-size: 18px; font-weight: 600; line-height: 1.5;
  margin: 0 20px; padding: 17px 0 16px;
  border-bottom: 1px solid var(--hairline);
}

#regform { padding: 18px 20px 24px; }

/* the qualifier, the first thing on the form */
fieldset { border: 0; margin: 0 0 20px; }
legend { font-size: 18px; font-weight: 600; padding: 0; margin-bottom: 8px; }
.radio {
  display: flex; align-items: flex-start; gap: 12px;
  font-size: 18px; line-height: 1.45; cursor: pointer;
  padding: 12px 13px; margin-bottom: 8px;
  border: 1px solid var(--chip-edge); border-radius: 12px;
  min-height: 50px;
}
.radio:last-child { margin-bottom: 0; }
.radio input {
  width: 24px; height: 24px; flex: 0 0 24px; margin-top: 1px;
  accent-color: var(--ink); cursor: pointer;
}
.radio:has(input:checked) { border-color: var(--ink); background: var(--tint); }

.field { margin-bottom: 17px; }
.field label {
  display: block; font-size: 18px; font-weight: 600;
  margin-bottom: 6px; color: var(--ink);
}
.input-wrap { position: relative; display: block; }
.f-icon {
  position: absolute; left: 15px; top: 50%; transform: translateY(-50%);
  color: var(--ctrl); pointer-events: none;
}
.field input {
  width: 100%; font: inherit; font-size: 19px; color: var(--ink);
  min-height: 56px;
  background: var(--tint);
  border: 1.5px solid var(--ctrl);
  border-radius: 12px;
  padding: 14px 14px 14px 48px;
}
.field input:focus { background: var(--white); }
.input-wrap:focus-within .f-icon { color: var(--ink); }
.two-up { display: block; }

.hp-wrap { display: none; }

.consent {
  border: 2px solid var(--ctrl); border-radius: 12px;
  padding: 15px; margin: 18px 0;
}
.consent.is-locked { border-style: dashed; }
/* Armed consent goes gold: the one place the accent paints a surface, because
   it marks the one decision on the page that is genuinely the reader's. */
.consent.is-unlocked {
  border-style: solid; border-color: var(--ink); background: var(--gold-ghost);
}
.consent .row { display: flex; align-items: flex-start; gap: 12px; }
.consent input[type="checkbox"] {
  width: 26px; height: 26px; flex: 0 0 26px; margin-top: 1px;
  accent-color: var(--ink);
}
.consent.is-locked input[type="checkbox"] { cursor: not-allowed; }
.consent label { font-size: 18px; line-height: 1.5; cursor: pointer; }
#consentNumber { font-weight: 700; white-space: nowrap; }
#consentNumber.is-empty { font-weight: 400; color: var(--helper); }
.helper { font-size: 18px; color: var(--helper); margin: 9px 0 0 38px; }
.helper.is-problem { color: var(--error-ink); font-weight: 600; }
.consent.is-unlocked .helper { display: none; }

.cta {
  display: block; width: 100%; min-height: 60px;
  font: inherit; font-size: 20px; font-weight: 700;
  color: var(--ink); background: var(--gold);
  border: 2px solid var(--ink); border-radius: 12px;
  padding: 16px; cursor: pointer; margin-top: 6px;
}
.cta:hover { background: var(--gold-hover); }
.cta[disabled] { opacity: 0.75; cursor: wait; }

.submit-error {
  display: none; font-size: 18px; font-weight: 600;
  color: var(--error-ink); background: var(--error-bg);
  border-radius: 12px; padding: 13px 15px; margin-top: 14px;
}
.submit-error.is-visible { display: block; }

.under-cta { text-align: center; font-size: 18px; margin-top: 8px; }
.under-cta a { color: var(--ink-2); display: inline-block; padding: 11px 10px; }

/* ------------------------------------------------- the story column */
/* One rhythm for the whole column: every object (tiles, About panel) sits a
   single 12px gap from its neighbour, so the column reads as one stack. */
.story-col { margin-top: 48px; }
.story-h {
  font-family: var(--display);
  font-size: clamp(28px, 6.5vw, 36px);
  font-weight: 800; letter-spacing: -0.015em;
  margin-bottom: 16px; text-wrap: balance;
}
.covers { list-style: none; display: grid; gap: 12px; }
.tile {
  border-radius: 18px;
  padding: 24px 22px;
  background: var(--tint);
}
.c-icon { color: var(--gold-deep); display: block; margin-bottom: 13px; }
.c-text { display: block; }
.c-label {
  display: block; font-family: var(--display);
  font-size: 22px; font-weight: 700;
  letter-spacing: -0.01em; margin-bottom: 4px;
}
.c-desc { display: block; font-size: 18px; line-height: 1.55; color: var(--ink-2); }
/* Two cells carry colour so the grid has depth without a photo in it: the navy
   anchor cell and one gold-tinted cell. Text on both stays at measured AA+. */
.tile-1 { background: var(--ink); color: var(--on-navy); }
.tile-1 .c-icon { color: var(--gold); }
.tile-1 .c-desc { color: var(--on-navy-2); }
.tile-1 .c-label { font-size: 24px; }
.tile-4 { background: var(--gold-ghost); }

/* ------------------------------------------------------------------ about */
/* A tinted panel in the story column rather than its own full-width band, so
   Khris sits beside the form on desktop instead of a screen below it. */
.about-panel {
  margin-top: 12px;
  background: var(--tint);
  border-radius: 18px;
  padding: 24px 22px;
}
.about-panel .story-h { font-size: clamp(24px, 5.5vw, 28px); margin-bottom: 14px; }
.about-panel .lede { font-size: 20px; line-height: 1.6; text-wrap: pretty; }

/* A named, pictured host is the most consistent trust element in the captured
   category and the only one of its conversion devices compliance leaves open. */
.host {
  display: grid; grid-template-columns: 1fr; gap: 22px;
  margin-top: 22px;
  align-items: start;
}
.host-photo-wrap { position: relative; display: block; width: 172px; }
.host-photo-wrap::before {
  content: ""; position: absolute;
  left: 12px; top: 12px; right: -12px; bottom: -12px;
  background: var(--gold); opacity: 0.25; border-radius: 18px;
}
.host-photo {
  position: relative;
  width: 172px; height: 215px; object-fit: cover; object-position: 50% 20%;
  border-radius: 18px; display: block;
  border: 1px solid var(--hairline);
}
.host p { font-size: 19px; line-height: 1.6; max-width: 36em; }

/* ----------------------------------------------------------------- footer */
/* Prominence is required — 422.2267(e)(41)(iv). Full contrast, 18px, never greyed. */
.legal {
  background: var(--ink); color: var(--on-navy);
  border-top: 5px solid var(--gold);
  padding: 36px 0 44px;
}
.legal-brand {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 22px;
}
.legal-brand img { width: 30px; height: 30px; }
.legal-brand span {
  font-size: 17px; font-weight: 800; letter-spacing: 0.06em;
  text-transform: uppercase;
}
.legal p {
  font-size: 18px; line-height: 1.6; max-width: 62em;
  margin-bottom: 14px;
}
.legal p:last-child { margin-bottom: 0; }

/* ================================================================= desktop
   Desktop is the mobile page widened, not a second composition. The card
   pulls up 160px into the hero's 200px bottom pad, so it can never collide
   with the headline at any zoom level. */

@media (min-width: 620px) {
  .host { grid-template-columns: auto 1fr; gap: 24px; }
  .host-photo-wrap, .host-photo { width: 168px; }
  .host-photo { height: 210px; }

  /* Between phone and the two-column band, the card and the story sit
     centered at a comfortable reading width. */
  .form-card { max-width: 560px; margin-left: auto; margin-right: auto; }
  .story-col { max-width: 620px; margin-left: auto; margin-right: auto; }
}

@media (min-width: 900px) {
  .shell { padding: 0 32px; }

  .hero { padding: 64px 0 120px; }
  .hero h1 { max-width: 660px; }
  .hero .sub { max-width: 540px; }

  .form-card { margin-top: -64px; }
  .session { padding: 22px 28px 18px; }
  .when-date { font-size: 26px; }
  .block3 { margin: 0 28px; padding: 20px 0 18px; }
  #regform { padding: 20px 28px 28px; }

  .two-up { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }

  .signup { padding-bottom: 88px; }
  .story-col { margin-top: 56px; }
  .tile { padding: 26px 24px; }
  .legal { padding: 44px 0 54px; }
}

/* The two-column band. The card takes a fixed right column and pulls 160px up
   into the hero's 200px bottom pad (40px clearance below the headline at any
   zoom); the story column fills the left with the covers and the About panel,
   which together run about the card's own height, so neither column trails
   off into empty space. */
@media (min-width: 1080px) {
  .hero { padding: 76px 0 200px; }

  .signup-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 508px;
    gap: 56px;
    align-items: start;
  }
  .form-col { grid-column: 2; grid-row: 1; }
  /* The heading's top sits on the same line as the card's white body (the
     bottom edge of its navy session header), so the two columns share a
     reference line instead of each starting at its own height. The 60px is
     that measured line, not a guess. */
  .story-col {
    grid-column: 1; grid-row: 1;
    margin: 0; max-width: 600px;
    padding-top: 60px;
  }
  /* Two-across tiles under the full-width navy anchor: keeps the bento
     character and holds the story column to roughly the card's height, so
     neither column trails past the other (Codex review catch). */
  .story-col .covers { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .story-col .tile-1 { grid-column: 1 / -1; }
  .signup-grid .form-card { max-width: none; margin-left: 0; margin-right: 0; margin-top: -160px; }
  .signup { padding-bottom: 96px; }
}

@media (min-width: 1180px) {
  .hero h1 { font-size: 68px; }
}

/* Below 600px the wordmark and the phone button cannot both sit on one line,
   and a truncated firm name is worse than an absent one. The wordmark yields:
   the anchor mark still carries the brand, the firm name appears in the footer
   brand row, the page title, the consent sentence and the About paragraph, and
   for a 65-to-75 audience a tappable phone number is worth more in a header
   than a logotype. Measured, not guessed: wordmark + pill need 507px of line;
   the shell provides 500px at a 540px viewport. Round 3's cut was 479px, sized
   for a plain text link; the round-4 pill is 49px wider (Codex review catch). */
@media (max-width: 599px) {
  .brand span { display: none; }
  .brand img { width: 32px; height: 32px; }
  .topbar-phone { font-size: 18px; padding: 8px 14px; }
}

/* ------------------------------------------------------------ thanks page */
/* Same shell, same card. It has no form, so the card carries the session facts,
   the disclosure and the two short lines the registrant needs next. */
.thanks .hero { padding: 40px 0 76px; }
/* Nothing follows the card on this page, so the section carries the air the
   covers section provides on the registration page. */
.thanks .signup { padding-bottom: 56px; }
.thanks-body { padding: 18px 20px 24px; }
.thanks-body p { font-size: 19px; line-height: 1.6; margin-bottom: 14px; }
.thanks-body p:last-child { margin-bottom: 0; }
.thanks-body a { color: var(--ink); font-weight: 700; }
.thanks-body .note {
  background: var(--gold-ghost); border-left: 4px solid var(--gold);
  border-radius: 0 12px 12px 0; padding: 14px 15px; font-size: 18px;
}

/* The thanks page has no story column, so it keeps the centered single-column
   composition at every width. .thanks .hero outweighs the generic .hero rules,
   so the deep two-column hero pad never reaches it. */
@media (min-width: 900px) {
  .thanks .hero { padding: 64px 0 120px; }
  .thanks-body { padding: 20px 28px 28px; }
}

/* ----------------------------------------------------------------- motion */
/* Everything that moves lives inside this gate. Reduced motion means the page
   is simply still: nothing is hidden, nothing waits for a scroll position. */
@media (prefers-reduced-motion: no-preference) {
  @keyframes rise {
    from { opacity: 0; transform: translateY(22px); }
    to   { opacity: 1; transform: none; }
  }
  .hero h1            { animation: rise 0.7s var(--ease) both; }
  .hero .sub          { animation: rise 0.7s var(--ease) 0.09s both; }
  .hero-host          { animation: rise 0.7s var(--ease) 0.16s both; }
  .signup .form-card  { animation: rise 0.7s var(--ease) 0.22s both; }

  /* .reveal-armed is set on <html> by a tiny HEAD script (same guards as the
     observer script), so reveal targets are hidden BEFORE first paint and a
     mid-page refresh cannot flash content off (Gemini review catch). A no-JS,
     no-IntersectionObserver or reduced-motion visit never gets the class, so
     nothing is ever hidden for them. One reveal per element, then let go. */
  .reveal-armed [data-reveal] { opacity: 0; transform: translateY(18px); }
  .reveal-armed [data-reveal].is-in {
    opacity: 1; transform: none;
    transition: opacity 0.6s var(--ease), transform 0.6s var(--ease);
  }
  .reveal-armed .covers .tile:nth-child(2).is-in { transition-delay: 0.06s; }
  .reveal-armed .covers .tile:nth-child(3).is-in { transition-delay: 0.06s; }
  .reveal-armed .covers .tile:nth-child(4).is-in { transition-delay: 0.12s; }
  .reveal-armed .covers .tile:nth-child(5).is-in { transition-delay: 0.18s; }

  .cta { transition: background 0.18s ease, transform 0.18s ease; }
  .cta:hover:not([disabled]) { transform: translateY(-1px); }
  .cta:active:not([disabled]) { transform: translateY(1px) scale(0.99); }
  .topbar-phone { transition: background 0.15s ease; }
  .field input { transition: background 0.15s ease; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}
