:root {
  --race-background: #f9f6ef;
  --race-surface: #ffffff;
  --race-elevated: #e8e0d1;
  --race-border: #b8ae9d;
  --race-border-strong: #1a1a1a;
  --race-text: #0b0b0b;
  --race-text-muted: #3f3f3f;
  --race-text-subtle: #5f5f5f;
  --race-primary: #e34331;
  --race-primary-deep: #b92718;
  --race-primary-soft: #ffc1b8;
  --race-primary-tint: #ffe8e1;
  --race-computed-tint: #fff0ea;
  --race-accent: #d28a00;
  --race-accent-soft: #ffe59d;
  --race-success: #087c48;
  --race-error: #b91c1c;
  --site-max-width: 1120px;
  --site-radius-card: 18px;
  --site-radius-control: 14px;
  color: var(--race-text);
  background: var(--race-background);
  font-family: Inter, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-size: 16px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-width: 320px;
  background: var(--race-background);
  color: var(--race-text);
}

img,
svg {
  max-width: 100%;
}

a {
  color: inherit;
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.22em;
}

a:focus-visible,
button:focus-visible {
  outline: 3px solid var(--race-accent);
  outline-offset: 4px;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.site-header,
.site-footer,
.section,
.hero-content {
  width: min(100% - 32px, var(--site-max-width));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 16px 0;
  background: color-mix(in srgb, var(--race-background) 92%, transparent);
  backdrop-filter: blur(10px);
}

.brand-link {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 800;
  text-decoration: none;
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border: 1px solid var(--race-border-strong);
  border-radius: 13px;
  background: var(--race-primary);
  color: var(--race-surface);
  font-family: Unbounded, Inter, sans-serif;
  font-size: 12px;
}

.header-nav {
  display: none;
  gap: 18px;
  align-items: center;
  color: var(--race-text-muted);
  font-size: 0.95rem;
  font-weight: 700;
}

.header-nav a {
  text-decoration: none;
}

.hero-section {
  position: relative;
  display: grid;
  min-height: min(820px, calc(100svh - 74px));
  padding: 48px 0 64px;
}

.hero-backdrop {
  order: 2;
  position: static;
  display: flex;
  align-items: center;
  justify-content: center;
  width: min(100% - 32px, var(--site-max-width));
  margin: 34px auto 0;
}

.hero-phone {
  width: min(310px, 78vw);
}

.hero-content {
  order: 1;
  display: grid;
  align-content: center;
  justify-items: start;
  max-width: 760px;
  padding-top: 10px;
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--race-text-muted);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  margin: 0;
  font-family: Unbounded, Inter, sans-serif;
  letter-spacing: 0;
  line-height: 1.02;
}

h1 {
  max-width: 100%;
  color: var(--race-primary);
  overflow-wrap: break-word;
  font-size: clamp(2.25rem, 8vw, 4.6rem);
  font-weight: 800;
}

h1 span {
  display: block;
  width: max-content;
  max-width: 100%;
  white-space: nowrap;
}

h2 {
  max-width: 780px;
  font-size: clamp(2rem, 7vw, 4.5rem);
  font-weight: 800;
}

h3 {
  font-size: 1.15rem;
  font-weight: 800;
}

p {
  line-height: 1.65;
}

.hero-subtitle {
  max-width: 620px;
  margin: 22px 0 0;
  color: var(--race-text);
  font-size: clamp(1.05rem, 3vw, 1.35rem);
  font-weight: 700;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 22px;
  border: 1px solid var(--race-border-strong);
  border-radius: var(--site-radius-control);
  font: 800 0.96rem/1 Inter, system-ui, sans-serif;
  text-decoration: none;
  cursor: pointer;
}

.button-primary {
  background: var(--race-primary);
  color: var(--race-surface);
  border-color: var(--race-primary);
}

.button-primary:hover {
  background: var(--race-primary-deep);
  border-color: var(--race-primary-deep);
}

.button-secondary {
  background: var(--race-surface);
  color: var(--race-text);
}

.hero-note {
  min-height: 1.4em;
  margin: 18px 0 0;
  color: var(--race-text-muted);
  font-size: 0.9rem;
}

.section {
  padding: 68px 0;
}

.section-heading {
  margin-bottom: 24px;
}

.steps-grid,
.mode-grid,
.screens-grid {
  display: grid;
  gap: 16px;
}

.info-card {
  min-height: 100%;
  padding: 22px;
  border: 1px solid var(--race-border);
  border-radius: var(--site-radius-card);
  background: var(--race-surface);
}

.info-card p {
  margin: 12px 0 0;
  color: var(--race-text-muted);
  font-weight: 500;
}

.step-number {
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  margin-bottom: 18px;
  border-radius: 14px;
  background: var(--race-accent-soft);
  color: var(--race-accent);
  font-family: Unbounded, Inter, sans-serif;
  font-weight: 800;
}

.mode-card {
  border-color: var(--race-border-strong);
}

.screen-section {
  padding-bottom: 88px;
}

.screens-grid {
  grid-template-columns: 1fr;
}

.screen-card {
  margin: 0;
}

.screen-card figcaption {
  margin-top: 12px;
  color: var(--race-text-muted);
  font-size: 0.9rem;
  font-weight: 800;
  text-align: center;
}

.phone-frame {
  aspect-ratio: 9 / 19.5;
  width: 100%;
  max-width: 320px;
  margin-inline: auto;
  padding: 12px;
  border: 2px solid var(--race-border-strong);
  border-radius: 36px;
  background: var(--race-text);
  box-shadow: 0 16px 40px rgba(11, 11, 11, 0.14);
}

.screen-image {
  display: block;
  width: 100%;
  height: 100%;
  border-radius: 26px;
  background: var(--race-background);
  object-fit: cover;
}

.screen-placeholder {
  display: grid;
  place-items: center;
  height: 100%;
  padding: 24px;
  border-radius: 26px;
  background:
    linear-gradient(var(--race-background), var(--race-background)) padding-box;
  color: var(--race-text);
  text-align: center;
}

.screen-placeholder strong {
  display: block;
  margin: 10px 0;
  overflow-wrap: anywhere;
  font-family: Unbounded, Inter, sans-serif;
  font-size: 1rem;
  line-height: 1.25;
}

.screen-placeholder span {
  color: var(--race-text-muted);
  font-size: 0.82rem;
  font-weight: 800;
}

.placeholder-kicker {
  color: var(--race-primary) !important;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.site-footer {
  display: grid;
  gap: 16px;
  padding: 28px 0 40px;
  border-top: 1px solid var(--race-border);
  color: var(--race-text-muted);
}

.site-footer strong {
  color: var(--race-text);
  font-family: Unbounded, Inter, sans-serif;
}

.site-footer p {
  margin: 4px 0 0;
}

.site-footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  font-weight: 800;
}

.legal-page {
  width: min(100% - 32px, 900px);
  margin: 0 auto;
  padding: 58px 0 86px;
}

.legal-document {
  padding: clamp(22px, 5vw, 42px);
  border: 1px solid var(--race-border);
  border-radius: var(--site-radius-card);
  background: var(--race-surface);
}

.legal-document h1 {
  max-width: 100%;
  font-size: clamp(2.35rem, 8vw, 4.4rem);
}

.legal-document h2 {
  margin-bottom: 14px;
  font-size: clamp(1.35rem, 4vw, 2.2rem);
}

.legal-updated {
  margin: 14px 0 34px;
  color: var(--race-text-muted);
  font-weight: 800;
}

.legal-section {
  padding-top: 28px;
  margin-top: 28px;
  border-top: 1px solid var(--race-border);
}

.legal-section:first-of-type {
  border-top: 0;
  margin-top: 0;
}

.legal-section p,
.legal-section li {
  color: var(--race-text-muted);
  font-weight: 500;
}

.legal-section p {
  margin: 0 0 14px;
}

.legal-section p:last-child {
  margin-bottom: 0;
}

.legal-section ul {
  display: grid;
  gap: 14px;
  padding-left: 1.2rem;
  margin: 0;
}

.legal-section strong {
  color: var(--race-text);
}

.duel-page {
  min-height: 100svh;
  background:
    radial-gradient(circle at 80% 10%, var(--race-primary-tint), transparent 34%),
    var(--race-background);
}

.duel-shell {
  display: grid;
  align-content: center;
  width: min(100% - 32px, 760px);
  min-height: 100svh;
  margin-inline: auto;
  padding: 28px 0;
}

.duel-brand {
  width: max-content;
  margin-bottom: 22px;
}

.duel-card {
  padding: clamp(24px, 6vw, 54px);
  border: 1px solid var(--race-border);
  border-radius: 28px;
  background: var(--race-surface);
  box-shadow: 0 18px 60px rgba(11, 11, 11, 0.10);
}

.duel-proof {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  margin: 2px 0 22px;
  padding: 12px 14px;
  border: 2px solid var(--race-border-strong);
  border-radius: 18px;
  background: var(--race-primary-tint);
}

.duel-flag {
  font-size: 2rem;
  line-height: 1;
}

.duel-time {
  color: var(--race-primary);
  font-family: Unbounded, Inter, sans-serif;
  font-size: clamp(1.4rem, 7vw, 2.7rem);
  font-weight: 800;
  line-height: 1;
}

.duel-copy {
  max-width: 640px;
  margin: 22px 0 0;
  color: var(--race-text-muted);
  font-size: clamp(1rem, 3vw, 1.25rem);
  font-weight: 600;
}

.duel-copy strong {
  color: var(--race-text);
}

.duel-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 30px;
}

.button-disabled,
.button-disabled:hover {
  border-color: var(--race-border);
  background: var(--race-elevated);
  color: var(--race-text-subtle);
  cursor: not-allowed;
}

@media (min-width: 680px) {
  .header-nav {
    display: flex;
  }

  .steps-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .mode-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .screens-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .site-footer {
    grid-template-columns: 1fr auto auto;
    align-items: center;
  }
}

@media (min-width: 960px) {
  .hero-section {
    grid-template-columns:
      minmax(max(32px, calc((100vw - var(--site-max-width)) / 2)), 1fr)
      minmax(0, 680px)
      minmax(300px, 440px)
      minmax(max(32px, calc((100vw - var(--site-max-width)) / 2)), 1fr);
    align-items: center;
    column-gap: 32px;
    min-height: min(780px, calc(100svh - 74px));
    padding-top: 42px;
  }

  .hero-content {
    order: 0;
    grid-column: 2;
    grid-row: 1;
    width: 100%;
    margin: 0;
  }

  .hero-backdrop {
    order: 0;
    grid-column: 3;
    grid-row: 1;
    width: 100%;
    margin: 0;
    justify-content: center;
  }

  .hero-phone {
    width: min(390px, 100%);
  }

  .mode-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .screens-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

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