/* Production Row waitlist. Values come from brand_tokens.json (Brand Bible v2.0).
   theme.js sets data-theme on <html>: the system theme unless someone picks one. */

:root {
  color-scheme: light;
  --bg: #ffffff;
  --surface: #ffffff;
  --section: #f5f6f8;
  --tile: #ffffff;
  --fill: #eceef2;
  --line: #e3e6eb;
  --line-strong: #858e9c;
  --text: #111b2e;
  --muted: #5b6474;
  --disabled: #9aa1ab;
  --link: #1f7a83;
  --link-hover: #17616a;
  --success: #27704a;
  --success-bg: #e5f3ea;
  --danger: #b23a27;
  --band: #111b2e;
  --band-text: #ffffff;
  --band-muted: #a7b0be;
  --gold: #e3a13a;
  --gold-600: #cc8a24;
  --gold-700: #b87a1e;
  --on-gold: #111b2e;
  --wash:
    radial-gradient(80% 120% at 0% 0%, rgba(238, 154, 62, 0.28), transparent 60%),
    radial-gradient(80% 120% at 100% 100%, rgba(111, 166, 238, 0.3), transparent 60%);
  --elevation-1: 0 1px 2px rgba(17, 27, 46, 0.04), 0 6px 16px rgba(17, 27, 46, 0.06);

  --font-display: 'Big Shoulders Display', Impact, 'Arial Narrow', sans-serif;
  --font-text: 'DM Sans', Arial, sans-serif;
  --font-mono: 'IBM Plex Mono', ui-monospace, Menlo, monospace;

  --fast: 120ms;
  --base: 180ms;
  --slow: 240ms;
  --ease: cubic-bezier(0.2, 0, 0, 1);
  --margin: 48px;

  --icon-alert: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='12' cy='12' r='10'/%3E%3Cpath d='M12 8v4M12 16h.01'/%3E%3C/svg%3E");
  --icon-check: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='black' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 6 9 17l-5-5'/%3E%3C/svg%3E");
}

/* Dark: Night Navy surfaces; Gold stays Gold. */
:root[data-theme='dark'] {
  color-scheme: dark;
  --bg: #0b1322;
  --surface: #1b2842;
  --section: #111b2e;
  --tile: #1b2842;
  --fill: #22324f;
  --line: #2a3b5c;
  --line-strong: #7d8aa3;
  --text: #f2efe8;
  --muted: #a7b0be;
  --disabled: #6b768a;
  --link: #5fb8c1;
  --link-hover: #86cdd4;
  --success: #7fd1a4;
  --success-bg: rgba(39, 112, 74, 0.3);
  --danger: #f28b78;
  --band: #1b2842;
  --band-text: #f2efe8;
  --band-muted: #a7b0be;
  --wash:
    radial-gradient(80% 120% at 0% 0%, rgba(238, 154, 62, 0.16), transparent 60%),
    radial-gradient(80% 120% at 100% 100%, rgba(111, 166, 238, 0.18), transparent 60%);
  --elevation-1: 0 1px 2px rgba(0, 0, 0, 0.3);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}
html {
  -webkit-text-size-adjust: 100%;
}
/* Component display rules must never un-hide something. */
[hidden] {
  display: none !important;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 16px/1.5 var(--font-text);
  -webkit-font-smoothing: antialiased;
}
h1,
h2,
h3,
p {
  margin: 0;
}
button,
input {
  font: inherit;
  color: inherit;
}
a {
  color: var(--link);
  text-underline-offset: 3px;
}
a:hover {
  color: var(--link-hover);
}
:focus-visible {
  outline: 3px solid var(--link);
  outline-offset: 3px;
}
.sr {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
.skip {
  position: absolute;
  left: 16px;
  top: -60px;
  z-index: 10;
  padding: 10px 14px;
  border-radius: 8px;
  background: var(--text);
  color: var(--bg);
  font-weight: 700;
}
.skip:focus {
  top: 8px;
}

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

/* Mono labels: uppercase, +8% tracking. */
.label {
  font: 500 12px/1.3 var(--font-mono);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

/* Tertiary action: a Teal link. */
.link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--link);
  font-size: 15px;
  font-weight: 700;
  text-decoration: underline;
  text-underline-offset: 3px;
  cursor: pointer;
}
.link:hover {
  color: var(--link-hover);
}

/* ── Buttons: 52 px, radius 8, one Gold action per view ─── */
.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-width: 88px;
  min-height: 52px;
  padding: 0 22px;
  border: 1px solid transparent;
  border-radius: 8px;
  font-size: 16px;
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition:
    background-color var(--fast) var(--ease),
    border-color var(--fast) var(--ease),
    color var(--fast) var(--ease);
}
.button-primary {
  background: var(--gold);
  color: var(--on-gold);
}
.button-primary:hover {
  background: var(--gold-600);
}
.button-primary:active {
  background: var(--gold-700);
}
.button[aria-busy='true'] {
  cursor: progress;
}
.button[aria-busy='true']::before {
  content: '';
  width: 16px;
  height: 16px;
  border: 2px solid currentColor;
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
}
@keyframes spin {
  to {
    transform: rotate(1turn);
  }
}
.button-inverse {
  border-color: var(--band-text);
  background: transparent;
  color: var(--band-text);
}
.button-inverse:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--band-text);
}
.button-inverse:active {
  background: rgba(255, 255, 255, 0.18);
}

/* ── Nav: 52 px, hairline under it ────────────────────────── */
.nav {
  border-bottom: 1px solid var(--line);
  background: var(--bg);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 52px;
}
.logo {
  display: block;
  padding: 8px 0;
}
.logo img {
  display: block;
  width: 164px;
  height: auto;
}
.logo .logo-dark,
[data-theme='dark'] .logo .logo-light {
  display: none;
}
[data-theme='dark'] .logo .logo-dark {
  display: block;
}
.nav-end {
  display: flex;
  align-items: center;
  gap: 12px;
}
.nav .link {
  font-size: 14px;
  text-decoration: none;
  white-space: nowrap;
}
.nav .link:hover {
  text-decoration: underline;
}
.theme-toggle {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  margin-right: -10px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: none;
  color: var(--muted);
  cursor: pointer;
  transition:
    background-color var(--fast) var(--ease),
    color var(--fast) var(--ease);
}
.theme-toggle:hover {
  background: var(--fill);
  color: var(--text);
}
.theme-toggle svg {
  width: 20px;
  height: 20px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.theme-toggle .icon-sun,
[data-theme='dark'] .theme-toggle .icon-moon {
  display: none;
}
[data-theme='dark'] .theme-toggle .icon-sun {
  display: block;
}

/* ── Hero: a soft Kelvin wash behind the split ────────────── */
.hero {
  padding: 64px 0 96px;
  background: var(--wash), var(--bg);
}
.intro {
  max-width: 760px;
  margin: 0 auto;
  text-align: center;
}
.intro h1 {
  margin-top: 12px;
  text-wrap: balance;
  font-size: 24px;
  font-weight: 500;
  line-height: 1.35;
}

/* The split: renters and owners, side by side. Choosing one widens it to two
   thirds and opens its form; the other stays visible as a narrow column. */
.split {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-top: 40px;
  transition: grid-template-columns 240ms var(--ease);
}
.split[data-open='renter'] {
  grid-template-columns: 2fr 1fr;
}
.split[data-open='supplier'] {
  grid-template-columns: 1fr 2fr;
}
.side {
  position: relative;
  scroll-margin-top: 16px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 28px;
  min-width: 0;
  padding: 32px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  transition:
    border-color var(--fast) var(--ease),
    box-shadow var(--fast) var(--ease);
}
.side:not(.is-open):hover {
  border-color: var(--line-strong);
}
.side.is-open {
  border-color: var(--text);
  box-shadow: inset 0 0 0 1px var(--text);
}
.side h2 {
  margin-top: 16px;
  font: 800 clamp(40px, 5.6vw, 72px) / 0.95 var(--font-display);
  letter-spacing: 0.01em;
  text-transform: uppercase;
}
.side-pitch {
  max-width: 30em;
  margin-top: 16px;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.5;
}
.side-joined {
  margin-top: 16px;
}
.side-joined[hidden] {
  display: none;
}
/* Closed cards are one big target: the button's hit area covers the card. */
.side-open {
  margin-top: auto;
}
.side-open::after {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: 16px;
}
.side-open:focus-visible {
  outline: none;
}
.side:has(.side-open:focus-visible) {
  outline: 3px solid var(--link);
  outline-offset: 3px;
}
.side.is-minor h2 {
  font-size: clamp(32px, 3.2vw, 44px);
}
.side.is-minor .side-open {
  margin-top: 0;
}
.side.is-minor .side-pitch {
  font-size: 15px;
}

/* Secondary button: outline in the text colour. */
.button-secondary {
  border-color: var(--text);
  background: transparent;
  color: var(--text);
}
.button-secondary:hover {
  background: var(--fill);
}

/* ── Forms inside the open card ───────────────────────────── */
.side-form,
.side-done {
  display: grid;
  gap: 20px;
  width: 100%;
  max-width: 720px;
  animation: step-in var(--slow) var(--ease);
}
.side-form[hidden],
.side-done[hidden] {
  display: none;
}
.step-in {
  animation: step-in var(--base) var(--ease);
}
@keyframes step-in {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
}
.side-done h3 {
  font: 800 32px/1.05 var(--font-display);
  letter-spacing: 0.01em;
  text-transform: uppercase;
}
.side-done h3:focus {
  outline: none;
}
.side-done p {
  margin-top: -8px;
  color: var(--muted);
}
.side-done b {
  color: var(--text);
  overflow-wrap: anywhere;
}
.submit-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px 20px;
}
.submit-row .button {
  min-width: 220px;
}
.fine {
  color: var(--muted);
  font-size: 13px;
  line-height: 1.4;
}
.noscript {
  margin-top: 16px;
  text-align: center;
}
.trap {
  position: absolute;
  left: -9999px;
}
.opt {
  margin-left: 4px;
  color: var(--muted);
  font-weight: 400;
}

/* Fields: labels above, 44 px, errors explain the fix. */
.field {
  display: grid;
  gap: 6px;
}
.field label,
.chips legend {
  font-size: 14px;
  font-weight: 700;
}
.field input {
  width: 100%;
  min-height: 44px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 8px;
  background: var(--surface);
  font-size: 16px;
  transition: border-color var(--fast) var(--ease);
}
.field input::placeholder {
  color: var(--disabled);
}
.field input:focus {
  outline: none;
  border-color: var(--link);
  box-shadow: 0 0 0 1px var(--link);
}
.field input[aria-invalid='true'] {
  border-color: var(--danger);
  box-shadow: 0 0 0 1px var(--danger);
}
.err {
  color: var(--danger);
  font-size: 14px;
  line-height: 1.45;
}
.err:empty {
  display: none;
}
.err::before {
  content: '';
  display: inline-block;
  width: 16px;
  height: 16px;
  margin-right: 6px;
  vertical-align: -3px;
  background: currentColor;
  -webkit-mask: var(--icon-alert) center / contain no-repeat;
  mask: var(--icon-alert) center / contain no-repeat;
}
.row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

/* Chips: optional answers. */
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}
.chips legend {
  margin-bottom: 8px;
  padding: 0;
}
.chips label {
  position: relative;
}
.chips input {
  position: absolute;
  opacity: 0;
  inset: 0;
  margin: 0;
  cursor: pointer;
}
.chips label > span {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 40px;
  padding: 0 14px;
  border: 1px solid var(--line-strong);
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  transition:
    background-color var(--fast) var(--ease),
    border-color var(--fast) var(--ease),
    color var(--fast) var(--ease);
}
.chips label:hover span {
  border-color: var(--text);
}
.chips input:checked + span {
  border-color: var(--text);
  background: var(--text);
  color: var(--bg);
}
.chips input:checked + span::before {
  content: '';
  width: 14px;
  height: 14px;
  background: currentColor;
  -webkit-mask: var(--icon-check) center / contain no-repeat;
  mask: var(--icon-check) center / contain no-repeat;
}
.chips input:focus-visible + span {
  outline: 3px solid var(--link);
  outline-offset: 2px;
}

/* Status: icon and word, never colour alone. */
.side-joined {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 28px;
  padding: 0 10px;
  border-radius: 999px;
  background: var(--success-bg);
  color: var(--success);
  font-size: 13px;
  font-weight: 500;
}
.side-joined svg {
  width: 16px;
  height: 16px;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

/* ── Bands: Mist, then Navy ───────────────────────────────── */
.band {
  padding: 96px 0;
}
.band h2 {
  margin-top: 12px;
  font: 700 clamp(32px, 4.4vw, 48px) / 1 var(--font-display);
  letter-spacing: 0.01em;
  text-transform: uppercase;
}
.band-mist {
  background: var(--section);
}
.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 24px;
  margin: 48px 0 0;
  padding: 0;
  list-style: none;
}
.tile {
  padding: 24px;
  border-radius: 10px;
  background: var(--tile);
  box-shadow: var(--elevation-1);
}
.icon {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: var(--text);
  stroke-width: 1.5;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.tile h3 {
  margin-top: 16px;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.25;
}
.tile p {
  margin-top: 8px;
  color: var(--muted);
}

.band-navy {
  background: var(--band);
  color: var(--band-text);
}
.band-navy .label {
  color: var(--band-muted);
}
.owners {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: 64px;
  align-items: end;
}
.band-navy h2 span {
  display: block;
}
.band-navy h2 {
  font-size: clamp(56px, 7.4vw, 112px);
  font-weight: 800;
  line-height: 0.92;
}
.owners p:not(.label) {
  max-width: 30em;
  margin-bottom: 28px;
  font-size: 19px;
  line-height: 1.55;
}

/* ── Footer ───────────────────────────────────────────────── */
.foot {
  border-top: 1px solid var(--line);
}
.foot-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  padding-top: 20px;
  padding-bottom: 20px;
  color: var(--muted);
  font-size: 14px;
}
.foot-links {
  display: flex;
  gap: 24px;
}
.foot a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--muted);
}
.foot a:hover {
  color: var(--text);
}

/* ── Text pages (privacy notice) ──────────────────────────── */
.doc {
  max-width: calc(68ch + 2 * var(--margin));
  margin: 0 auto;
  padding: 64px var(--margin) 96px;
}
.doc h1 {
  margin: 12px 0 8px;
  font: 800 clamp(40px, 6vw, 72px) / 0.95 var(--font-display);
  letter-spacing: 0.01em;
  text-transform: uppercase;
}
.doc h2 {
  margin: 40px 0 8px;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.25;
}
.doc p,
.doc ul {
  margin: 0 0 16px;
}
.doc ul {
  padding-left: 1.2em;
}
.doc li + li {
  margin-top: 8px;
}
.doc .label {
  margin: 0;
}
.doc h1 + .label {
  margin-bottom: 32px;
}
.doc-back {
  margin-top: 48px;
}

/* ── Smaller screens ──────────────────────────────────────── */
@media (max-width: 1023px) {
  :root {
    --margin: 32px;
  }
  .owners {
    grid-template-columns: minmax(0, 1fr);
    gap: 32px;
  }
  .cards {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }
  .band {
    padding: 64px 0;
  }
  .side {
    padding: 24px;
  }
  /* No room for a narrow column: the open card goes first, full width, and the
     other side becomes a strip with its button. */
  .split[data-open='renter'],
  .split[data-open='supplier'] {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }
  .side.is-open {
    order: -1;
  }
  .side.is-minor {
    flex-flow: row wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px 24px;
  }
  .side.is-minor h2 {
    margin-top: 8px;
    font-size: 32px;
  }
  .side.is-minor .side-pitch {
    display: none;
  }
  .side.is-minor .side-open {
    margin-top: 0;
  }
}
@media (max-width: 719px) {
  .split {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    margin-top: 28px;
  }
  .side {
    gap: 20px;
  }
  .side h2 {
    margin-top: 12px;
    font-size: 40px;
  }
  .side-pitch {
    margin-top: 10px;
    font-size: 16px;
  }
}
@media (max-width: 599px) {
  :root {
    --margin: 16px;
  }
  .hero {
    padding: 40px 0 48px;
  }
  .intro h1 {
    font-size: 20px;
  }
  .side {
    padding: 20px;
  }
  .side.is-minor h2 {
    font-size: 28px;
  }
  .submit-row .button {
    width: 100%;
  }
  .row {
    grid-template-columns: minmax(0, 1fr);
  }
  .owners p:not(.label) {
    font-size: 17px;
  }
  .band-navy h2 {
    font-size: 56px;
  }
  .foot-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}

/* Small phones: a smaller logo (still over the 120 px minimum) keeps the nav on one line. */
@media (max-width: 359px) {
  .logo img {
    width: 132px;
  }
  .nav-end {
    gap: 8px;
  }
}

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