:root {
  --bg: #0f0f10;          /* rubber */
  --surface: #1c1c1e;
  --ink: #ffffff;
  --muted: #a6a6aa;
  --accent: #ffd21f;      /* shop-sign yellow */
  --accent-soft: #ffe46e;
  --accent-ink: #0f0f10;
  --field-1: #2b2b2e;     /* asphalt */
  --field-2: #f3f3ef;     /* sidewall white */
  --field-2-ink: #121214;

  --display: "Libre Franklin", "Arial Black", system-ui, sans-serif;
  --text: "Source Serif 4", Georgia, serif;

  --step-small: clamp(0.8125rem, 0.79rem + 0.1vw, 0.875rem);
  --step-body: clamp(1.0625rem, 1rem + 0.25vw, 1.1875rem);
  --step-lead: clamp(1.25rem, 1.1rem + 0.7vw, 1.625rem);
  --step-head: clamp(2rem, 1.3rem + 3.2vw, 4rem);
  --step-display: clamp(3.25rem, 6.2vw, 7rem);

  --m: clamp(16px, 2.4vw, 32px);
  --gap: clamp(96px, 12vw, 200px);
  --ease: cubic-bezier(.2, .7, .1, 1);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 var(--step-body)/1.55 var(--text);
  overflow-x: hidden;
}
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2, h3, p, ul, figure { margin: 0; }
ul { padding: 0; list-style: none; }
button, input, select { font: inherit; color: inherit; }
::selection { background: var(--accent); color: var(--accent-ink); }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }

.display, .head, h3, .wordmark, .btn, .code, .types-list button, .figure, summary, .mark span {
  font-family: var(--display);
  font-weight: 700;
}
.display {
  font-size: var(--step-display);
  line-height: .92;
  letter-spacing: -0.035em;
  text-transform: uppercase;
}
.head {
  font-size: var(--step-head);
  line-height: 1;
  letter-spacing: -0.03em;
}
.lead { font-size: var(--step-lead); line-height: 1.4; }

/* buttons: round, like everything else here */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 56px; padding: 0 30px;
  border-radius: 999px; border: 0;
  background: var(--accent); color: var(--accent-ink);
  font-size: var(--step-body); letter-spacing: -0.01em;
  text-decoration: none; cursor: pointer;
  transition: transform .25s var(--ease), background-color .25s;
}
.btn:hover { background: var(--accent-soft); transform: translateY(-2px); }
.btn:active { transform: translateY(1px) scale(.98); }
.btn-small { min-height: 44px; padding: 0 22px; font-size: var(--step-small); }
.btn-dark { background: var(--bg); color: var(--ink); }
.btn-dark:hover { background: var(--field-1); }

/* ---------- bar ---------- */
.bar {
  position: absolute; inset: 0 0 auto; z-index: 5;
  display: flex; justify-content: space-between; align-items: center;
  padding: 20px var(--m);
  background: var(--bg);
}
.wordmark { font-size: var(--step-lead); text-decoration: none; letter-spacing: -0.03em; }
.bar nav { display: flex; align-items: center; gap: clamp(16px, 2.4vw, 36px); }
.bar nav a:not(.btn) { text-decoration: none; font-size: var(--step-small); font-family: var(--display); position: relative; }
.bar nav a:not(.btn)::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -4px; height: 3px;
  background: var(--accent); transform: scaleX(0); transform-origin: left; transition: transform .3s var(--ease);
}
.bar nav a:not(.btn):hover::after { transform: scaleX(1); }

/* ---------- hero ---------- */
.hero {
  position: relative; min-height: 100svh; overflow: hidden;
  display: flex; align-items: center;
  padding: 120px var(--m) 80px;
}
.hero-copy { position: relative; z-index: 2; max-width: 36rem; }
.hero-copy .display { margin-bottom: 32px; }
.hero-copy .lead { max-width: 30ch; margin-bottom: 36px; }

.tire {
  position: absolute; z-index: 1;
  width: 120vh; height: 120vh;
  left: calc(84% - 60vh); top: calc(55% - 60vh);
}
.tire-ring { position: absolute; inset: 0; width: 100%; height: 100%; will-change: transform; }
.ring-fill { fill: var(--accent); }
.ring-text { fill: var(--accent-ink); font-family: var(--display); font-weight: 700; font-size: 46px; }
.tire-hub {
  position: absolute; inset: 15%;
  border-radius: 50%; overflow: hidden; background: var(--bg);
}
.tire-hub img { width: 100%; height: 100%; object-fit: cover; object-position: 60% 40%; }

/* ---------- decoder ---------- */
.decoder {
  background: var(--field-2); color: var(--field-2-ink);
  padding: var(--gap) var(--m) clamp(80px, 9vw, 140px);
}
.decoder-head { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; align-items: end; margin-bottom: 56px; }
.decoder-head .head { grid-column: 1 / 7; }
.decoder-head p { grid-column: 8 / 12; max-width: 44ch; }

.decoder-input { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; margin-bottom: 40px; }
.decoder-input label { font-family: var(--display); font-size: var(--step-small); width: 100%; }
.decoder-input input {
  width: min(100%, 340px); min-height: 56px; padding: 0 24px;
  border: 0; border-radius: 999px; background: #e2e2dc;
  font-family: var(--display); font-weight: 700; font-size: var(--step-body); letter-spacing: .02em;
  color: var(--field-2-ink);
}
.presets { display: flex; flex-wrap: wrap; gap: 8px; }
.presets button {
  min-height: 44px; padding: 0 18px; border: 0; border-radius: 999px;
  background: transparent; color: var(--field-2-ink); cursor: pointer;
  font-size: var(--step-small); font-weight: 600;
  transition: background-color .2s, transform .2s var(--ease);
}
.presets button:hover { background: #e2e2dc; }
.presets button:active { transform: scale(.96); }

.code {
  display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 .06em;
  font-size: clamp(3.25rem, 11.5vw, 12rem);
  line-height: .9; letter-spacing: -0.04em;
  margin: 0 0 48px -0.04em;
}
.code button {
  font: inherit; letter-spacing: inherit; color: #8a8a86;
  background: none; border: 0; padding: 0 .02em; cursor: pointer;
  border-radius: 999px; position: relative;
  transition: color .25s, transform .3s var(--ease);
}
.code button:hover { color: var(--field-2-ink); transform: translateY(-.04em); }
.code button[aria-selected="true"] { color: var(--field-2-ink); }
.code button[aria-selected="true"]::after {
  content: ""; position: absolute; left: 50%; bottom: -.16em;
  width: .14em; height: .14em; margin-left: -.07em; border-radius: 50%; background: var(--accent-ink);
}
.code .sep { color: #8a8a86; }
.code .gap { width: .3em; }

.decoded { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; align-items: start; }
.explain { grid-column: 1 / 7; min-height: 9em; }
.explain-title { font-family: var(--display); font-weight: 700; font-size: var(--step-lead); letter-spacing: -0.02em; margin-bottom: 10px; }
.explain p:not(.explain-title) { max-width: 46ch; }
.figures { grid-column: 8 / 13; display: grid; gap: 14px; justify-items: start; }
.figure { font-size: var(--step-lead); letter-spacing: -0.02em; margin-right: .3em; }
.figures .btn { margin-top: 14px; }
.decoder-error { margin-top: 24px; font-weight: 600; }

/* ---------- services ---------- */
.services {
  display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px;
  align-items: center;
  padding: var(--gap) var(--m) var(--gap) 0;
}
.circle-photo {
  grid-column: 1 / 6;
  width: 78svh; max-width: 120%; aspect-ratio: 1; margin-left: -12%;
  border-radius: 50%; overflow: hidden;
}
.circle-photo img { width: 100%; height: 100%; object-fit: cover; }
.services-body { grid-column: 7 / 13; }
.services-body .head { margin-bottom: 56px; }
.points { display: grid; grid-template-columns: repeat(3, 1fr); gap: 44px 40px; }
.points h3 { font-size: var(--step-body); letter-spacing: -0.01em; line-height: 1.25; margin-bottom: 6px; display: flex; gap: .5em; align-items: center; }
.points h3::before {
  content: ""; flex: none; width: .7em; height: .7em; border-radius: 50%;
  background: var(--accent);
}
.points li:nth-child(3n+2) h3::before { background: var(--field-2); }
.points li:nth-child(3n) h3::before { background: var(--muted); }
.points p { color: var(--muted); font-size: var(--step-small); line-height: 1.5; }

/* ---------- types ---------- */
.types {
  position: relative; min-height: 100svh;
  display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px;
  padding: 80px var(--m);
  background: var(--surface);
  overflow: hidden;
}
.types-stage { grid-column: 4 / 13; grid-row: 1; position: relative; min-height: 78svh; }
.disc {
  position: absolute; width: 64svh; height: 64svh; border-radius: 50%;
  left: 58%; top: 50%; translate: -50% -50%;
  background: var(--accent);
  transition: background-color .4s;
}
.types-photo {
  position: absolute; width: 46svh; height: 46svh; border-radius: 50%; overflow: hidden;
  left: 58%; top: 50%; translate: -50% -58%;
}
.types-photo img { width: 100%; height: 100%; object-fit: cover; transition: opacity .3s, scale .6s var(--ease); }
.types-photo img.swap { opacity: 0; scale: 1.06; }
.types-fact {
  position: absolute; left: calc(58% + 34svh); top: 50%;
  width: 22ch; translate: 0 -50%; font-size: var(--step-body);
}
.types-list {
  grid-column: 1 / 6; grid-row: 1; align-self: end; position: relative; z-index: 2;
  display: flex; flex-direction: column; align-items: flex-start;
}
.types-heading, .types-list button {
  font-family: var(--display); font-size: var(--step-head);
  letter-spacing: -0.03em; line-height: 1.15;
}
.types-heading { color: var(--muted); }
.types-list button {
  background: none; border: 0; padding: 0; cursor: pointer; color: var(--muted);
  transition: color .25s, transform .3s var(--ease);
}
.types-list button:hover { color: var(--ink); transform: translateX(8px); }
.types-list button[aria-selected="true"] { color: var(--ink); }
.types-list button[aria-selected="true"]::before {
  content: ""; display: inline-block; width: .42em; height: .42em; border-radius: 50%;
  background: var(--accent); margin-right: .3em; vertical-align: .12em;
}

/* ---------- prices ---------- */
.prices { display: grid; grid-template-columns: 5fr 7fr; min-height: 90svh; }
.plan { display: flex; flex-direction: column; padding: 40px var(--m) var(--m); }
.plan-a { background: var(--field-1); }
.plan-b { background: var(--accent); color: var(--accent-ink); }
.plan .head { margin-bottom: 20px; }
.plan-for { font-size: var(--step-lead); line-height: 1.35; max-width: 26ch; margin-bottom: 20px; }
.plan-inc { max-width: 44ch; }
.plan-foot { margin-top: auto; padding-top: 64px; display: flex; align-items: flex-end; justify-content: space-between; gap: 16px; flex-wrap: wrap; }
.price-row { display: flex; align-items: baseline; gap: .6em; }
.price { font-size: clamp(3.25rem, 9vw, 9rem); line-height: .85; }
.plan-b { position: relative; }
.plan-photo {
  position: absolute; top: 40px; right: var(--m);
  width: clamp(160px, 18vw, 300px); aspect-ratio: 1; border-radius: 50%; overflow: hidden;
}
.plan-photo img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- faq ---------- */
.faq {
  display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px;
  padding: var(--gap) var(--m);
}
.faq-side { grid-column: 1 / 5; position: sticky; top: 96px; align-self: start; }
.faq-photo { width: min(100%, 300px); aspect-ratio: 1; border-radius: 50%; overflow: hidden; margin-top: 40px; }
.faq-photo img { width: 100%; height: 100%; object-fit: cover; }
.faq-caption { margin-top: 16px; max-width: 26ch; color: var(--muted); font-size: var(--step-small); }
.faq-list { grid-column: 5 / 13; display: grid; gap: 8px; }
details { background: var(--surface); border-radius: 36px; transition: background-color .3s; }
details[open] { background: var(--accent); color: var(--accent-ink); }
summary {
  list-style: none; cursor: pointer;
  min-height: 72px; padding: 20px 72px 20px 28px; position: relative;
  display: flex; align-items: center;
  font-size: var(--step-lead); letter-spacing: -0.02em; line-height: 1.2;
}
summary::-webkit-details-marker { display: none; }
summary::before, summary::after {
  content: ""; position: absolute; right: 28px; top: 50%;
  width: 16px; height: 3px; margin-top: -1.5px; background: currentColor;
  transition: transform .3s var(--ease);
}
summary::after { transform: rotate(90deg); }
details[open] summary::after { transform: rotate(0deg); }
summary:hover { color: var(--accent); }
details[open] summary:hover { color: inherit; }
details p { padding: 0 28px 28px; max-width: 52ch; }

/* ---------- book ---------- */
.book { padding: 0 var(--m) var(--gap); }
.coupon {
  position: relative; max-width: 1240px; margin: 0 auto;
  display: grid; grid-template-columns: 46fr 54fr;
  background: var(--accent); color: var(--accent-ink);
  border-radius: 14px; overflow: hidden;
}
.notch {
  position: absolute; left: 46%; width: 28px; height: 28px; margin-left: -14px;
  border-radius: 50%; background: var(--bg); z-index: 2;
}
.notch-top { top: -14px; }
.notch-bottom { bottom: -14px; }
.perf { position: absolute; left: 46%; top: 22px; bottom: 22px; width: 10px; height: calc(100% - 44px); margin-left: -5px; fill: var(--bg); }
.coupon-left { padding: 48px; display: flex; flex-direction: column; justify-content: space-between; gap: 40px; }
.coupon-left .head { font-size: clamp(2rem, 1.3rem + 2vw, 3rem); text-transform: uppercase; letter-spacing: -0.035em; line-height: .95; }
.coupon-form { padding: 48px; display: grid; gap: 10px; align-content: center; }
.coupon-form input, .coupon-form select {
  min-height: 52px; padding: 0 20px; border: 0; border-radius: 10px;
  background: var(--accent-soft); color: var(--accent-ink); font-size: 16px;
}
.coupon-form ::placeholder { color: #5a4b00; opacity: 1; }
.submit {
  min-height: 56px; border: 0; border-radius: 999px; margin-top: 6px;
  background: var(--accent-ink); color: var(--ink); cursor: pointer;
  font-family: var(--display); font-weight: 700; font-size: var(--step-body);
  transition: transform .2s var(--ease), background-color .2s;
}
.submit:hover { background: var(--field-1); transform: translateY(-2px); }
.submit:active { transform: scale(.98); }

/* ---------- footer ---------- */
.foot { background: var(--field-1); padding: var(--m) var(--m) 24px; }
.mark { display: flex; gap: 4px; align-items: flex-end; height: 34svh; min-height: 200px; }
.mark span {
  flex: 1; height: var(--h); background: var(--accent); color: var(--field-1);
  display: flex; align-items: flex-end; padding: 0 0 .04em .06em;
  font-size: var(--step-display); line-height: .8; letter-spacing: -0.03em;
  transform-origin: bottom;
}
.mark span:nth-child(3n+2) { background: var(--field-2); }
.mark span:nth-child(3n) { background: var(--muted); }
.foot-cols { display: grid; grid-template-columns: repeat(12, 1fr); gap: 24px; margin-top: 56px; }
.foot-cols ul:nth-child(1) { grid-column: 1 / 3; }
.foot-cols ul:nth-child(2) { grid-column: 3 / 5; }
.foot-cols li { margin-bottom: 8px; }
.foot-cols a { text-decoration: none; }
.foot-cols a:hover { color: var(--accent); }
.foot-contact { grid-column: 8 / 13; display: grid; grid-template-columns: repeat(3, auto); gap: 24px; }
.credits { margin-top: 56px; max-width: 70ch; font-size: var(--step-small); color: var(--muted); }
.foot-last { margin-top: 24px; display: flex; justify-content: space-between; align-items: center; gap: 16px; font-size: var(--step-small); }

/* ---------- motion ---------- */
.js [data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .7s var(--ease), transform .7s var(--ease); transition-delay: var(--d, 0ms); }
.js [data-reveal].in { opacity: 1; transform: none; }

.js .shutter { clip-path: circle(0% at 50% 50%); }
.js .shutter img { scale: 1.12; }
.js .shutter.open { clip-path: circle(50% at 50% 50%); transition: clip-path 1.1s var(--ease) .15s; }
.js .shutter.open img { scale: 1; transition: scale 1.6s var(--ease) .15s; }

.js .mark span { transform: scaleY(.2); transition: transform .8s var(--ease); transition-delay: var(--d, 0ms); }
.js .mark.in span { transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js [data-reveal], .js .mark span { opacity: 1; transform: none; transition: none; }
  .js .shutter { clip-path: none; }
  .js .shutter img { scale: 1; }
}

/* ---------- tablet / tall screens ---------- */
@media (max-width: 1100px) {
  .points { grid-template-columns: repeat(2, 1fr); }
}

/* ---------- phone (and portrait tablets) ---------- */
@media (max-width: 900px), (max-aspect-ratio: 5/4) {
  .bar nav a:not(.btn) { display: none; }
  .hero { align-items: flex-start; padding-top: 15svh; min-height: 100svh; }
  .hero-copy .display { font-size: 11.5vw; margin-bottom: 20px; }
  .hero-copy .lead { font-size: var(--step-body); margin-bottom: 24px; }
  .tire { width: 130vw; height: 130vw; left: -15vw; top: 62svh; }
}
@media (max-width: 900px) {
  .decoder-head, .decoded { display: block; }
  .decoder-head p { margin-top: 20px; }
  .code { margin-bottom: 32px; }
  .explain { min-height: 0; margin-bottom: 32px; }

  .services { display: block; padding-right: var(--m); }
  .circle-photo { width: 82vw; max-height: 60svh; margin: 0 0 40px -18vw; }
  .services-body .head { margin-bottom: 32px; }
  .points { grid-template-columns: 1fr; gap: 28px; }
  .points h3 { margin-left: calc(-.7em - .5em); }
  .services-body { padding-left: 1.2em; }

  .types { display: flex; flex-direction: column; padding: 64px var(--m); min-height: 0; }
  .types-stage { min-height: 0; order: 1; }
  .disc { position: relative; display: block; width: 86vw; height: 86vw; left: auto; top: auto; translate: none; margin: 0 auto; }
  .types-photo { width: 62vw; height: 62vw; left: 50%; top: 43vw; }
  .types-fact { position: static; translate: none; width: auto; margin-top: 16px; }
  .types-list { order: 2; align-self: stretch; flex-direction: row; overflow-x: auto; gap: 24px; margin-top: 24px; scrollbar-width: none; }
  .types-heading { display: none; }
  .types-list button { font-size: 26px; white-space: nowrap; }
  .types-list button:hover { transform: none; }
  .types { gap: 0; }
  .types::before { content: "Tires we stock"; font-family: var(--display); font-weight: 700; font-size: var(--step-head); letter-spacing: -0.03em; margin-bottom: 32px; color: var(--muted); }

  .prices { display: flex; flex-direction: column-reverse; }
  .plan { min-height: 70svh; padding: 28px 20px 20px; }
  .plan-foot { flex-direction: column; align-items: stretch; }
  .plan-foot .btn { width: 100%; }
  .price { font-size: 20vw; }

  .faq { display: block; }
  .faq-side { position: static; margin-bottom: 32px; display: grid; grid-template-columns: 1fr auto; align-items: end; gap: 16px; }
  .faq-photo { width: 34vw; margin: 0; grid-row: 1 / 3; grid-column: 2; }
  .faq-caption { grid-column: 1; }
  .plan-photo { width: 34vw; top: 24px; right: 20px; }
  .plan-b .plan-for, .plan-b .head { max-width: calc(100% - 38vw); }
  details { border-radius: 28px; }
  summary { font-size: 18px; min-height: 64px; padding: 16px 60px 16px 20px; }
  summary::before, summary::after { right: 22px; }
  details p { padding: 0 20px 20px; font-size: 16px; }

  .book { padding-left: 12px; padding-right: 12px; }
  .coupon { grid-template-columns: 1fr; }
  .notch { left: auto; top: 46%; margin: -14px 0 0; }
  .notch-top { left: -14px; }
  .notch-bottom { right: -14px; bottom: auto; }
  .perf { left: 22px; right: 22px; top: 46%; width: calc(100% - 44px); height: 10px; margin: -5px 0 0; }
  .coupon-left { padding: 28px 24px 48px; min-height: 46%; }
  .coupon-form { padding: 40px 24px 28px; }
  .coupon-form input, .coupon-form select, .submit { min-height: 54px; }

  .mark { height: 22svh; min-height: 140px; }
  .mark span { font-size: 11vw; }
  .foot-cols { grid-template-columns: 1fr 1fr; }
  .foot-cols ul:nth-child(n) { grid-column: auto; }
  .foot-contact { grid-column: 1 / -1; grid-template-columns: 1fr; gap: 12px; }
}
