/* PlateSurf: shared look for the site and the web app. Colors match Theme.swift in the iOS app. */

@font-face { font-family: "Inter"; src: url("fonts/inter.woff2") format("woff2"); font-weight: 400 700; font-display: swap; }
@font-face { font-family: "Barlow Condensed"; src: url("fonts/barlow-condensed-700.woff2") format("woff2"); font-weight: 700; font-display: swap; }
@font-face { font-family: "Dancing Script"; src: url("fonts/dancing-script-700.woff") format("woff"); font-weight: 700; font-display: swap; }

:root {
  --bg: #F3F5F8;
  --surface: #FFFFFF;
  --line: #E4E8EE;
  --border: #C7CED8;
  --ink: #0F1B2D;
  --body: #46536A;
  --muted: #5A667A;
  --accent: #1B2A6B;
  --on-accent: #FFFFFF;
  --focus-ring: #DDE3F2;
  --available: #0F7B3F;
  --taken: #A34A00;
  --struck: #8A94A6;
  --available-card: #E6F3EC;
  --plate-bg: #FFFFFF;
  --plate-border: #C7CED8;
  --plate-ink: #1B2A6B;
  --plate-top: #C8102E;
  --brand: #0A7C8C;        /* app icon teal */
  --brand-ink: #14315C;    /* app icon navy */
  --brand-tint: #E3F1F3;
  --scrim: rgba(15, 27, 45, 0.55);
  --radius: 14px;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  --plate-font: "Barlow Condensed", "Arial Narrow", sans-serif;
  --script: "Dancing Script", "Snell Roundhand", cursive;
  color-scheme: light;
}

/* Black & yellow plate theme (the app's second theme). */
:root[data-theme="legacy"] {
  --bg: #0B0B0B;
  --surface: #171717;
  --line: #2A2A2A;
  --border: #3C3C3C;
  --ink: #F4F1E6;
  --body: #CFCAB9;
  --muted: #A8A391;
  --accent: #F2C200;
  --on-accent: #111111;
  --focus-ring: #3A3000;
  --available: #F2C200;
  --taken: #FF9A52;
  --struck: #7C786C;
  --available-card: #2A2406;
  --plate-bg: #111111;
  --plate-border: #F2C200;
  --plate-ink: #F2C200;
  --plate-top: #F2C200;
  --scrim: rgba(0, 0, 0, 0.65);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 16px/1.5 var(--sans);
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
a { color: var(--accent); text-underline-offset: 2px; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0; }
p { margin: 0; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
[hidden] { display: none !important; }

/* ---- Plates ------------------------------------------------------------------------- */

.plate {
  background: var(--plate-bg);
  border: 2px solid var(--plate-border);
  border-radius: var(--radius);
  height: 128px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px;
  padding: 0 12px;
  position: relative;
}
.plate-state { font: 700 26px/1 var(--script); color: var(--plate-top); }
:root[data-theme="legacy"] .plate-state { font: 700 13px/1 var(--sans); letter-spacing: 0.25em; text-transform: uppercase; }
.plate-text {
  font: 700 66px/1 var(--plate-font);
  letter-spacing: 0.06em;
  color: var(--plate-ink);
  white-space: nowrap;
}
.mini-plate {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 118px; min-height: 44px; padding: 0 10px;
  background: var(--plate-bg);
  border: 1.5px solid var(--plate-border);
  border-radius: 7px;
  font: 700 26px/1 var(--plate-font);
  letter-spacing: 0.05em;
  color: var(--plate-ink);
  white-space: nowrap;
}
.mini-plate.is-struck { color: var(--struck); border-color: var(--border); text-decoration: line-through; text-decoration-color: var(--struck); }

/* ---- Buttons ------------------------------------------------------------------------ */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  min-height: 54px; padding: 0 20px;
  border-radius: var(--radius);
  font: 600 17px/1.2 var(--sans);
  text-decoration: none;
  cursor: pointer;
  border: 1.5px solid transparent;
  transition: transform .08s ease, opacity .15s ease;
}
.btn:active { transform: scale(.98); }
.btn[disabled], .btn[aria-disabled="true"] { opacity: .45; cursor: not-allowed; transform: none; }
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-outline { background: var(--surface); color: var(--accent); border-color: var(--accent); }
.btn-quiet { background: var(--surface); color: var(--ink); border: 1px solid var(--border); min-height: 48px; font-size: 15px; }
.btn-block { width: 100%; }
.btn svg { flex-shrink: 0; }

.icon-btn {
  width: 44px; height: 44px; flex-shrink: 0;
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border-radius: 12px;
  background: var(--surface); border: 1px solid var(--border); color: var(--ink);
  cursor: pointer; text-decoration: none;
}
.icon-btn.with-label { width: auto; padding: 0 12px; font-size: 14px; font-weight: 600; }

.app-store-badge { display: inline-block; line-height: 0; border-radius: 9px; }
.app-store-badge img { height: 54px; width: auto; }
.app-store-badge.is-soon { pointer-events: none; opacity: .55; }
.soon-note { font-size: 13px; color: var(--muted); }

/* ---- Site chrome (landing + legal pages) --------------------------------------------- */

.site { min-height: 100vh; display: flex; flex-direction: column; background: var(--surface); }
.wrap { width: 100%; max-width: 1080px; margin: 0 auto; padding: 0 20px; }
.wrap-narrow { max-width: 720px; }

.site-header { border-bottom: 1px solid var(--line); background: var(--surface); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--ink); text-decoration: none; font-weight: 700; font-size: 20px; letter-spacing: -0.02em; }
.brand img { width: 34px; height: 34px; border-radius: 8px; }
.site-nav { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; justify-content: flex-end; }
.site-nav a { color: var(--body); text-decoration: none; font-weight: 500; font-size: 15px; padding: 10px 12px; border-radius: 10px; }
.site-nav a:hover, .site-nav a[aria-current="page"] { color: var(--ink); background: var(--bg); }

.site-footer { margin-top: auto; border-top: 1px solid var(--line); background: var(--bg); padding: 32px 0 40px; font-size: 14px; color: var(--muted); }
.site-footer .wrap { display: flex; flex-direction: column; gap: 14px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 20px; }
.footer-links a { color: var(--body); text-decoration: none; font-weight: 500; }
.footer-links a:hover { color: var(--ink); text-decoration: underline; }
.disclaimer { max-width: 640px; line-height: 1.5; }

/* ---- Landing ----------------------------------------------------------------------- */

.hero { background: var(--brand-tint); border-bottom: 1px solid var(--line); overflow: hidden; }
.hero .wrap { display: grid; grid-template-columns: 1.05fr 1fr; gap: 48px; align-items: center; padding-top: 64px; padding-bottom: 72px; }
.eyebrow { font-size: 13px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--brand); }
.hero h1 { font-size: clamp(36px, 5.2vw, 56px); margin: 12px 0 16px; }
.hero .lede { font-size: 19px; color: var(--body); max-width: 34em; }
.hero-plate { max-width: 440px; width: 100%; justify-self: center; height: 200px; box-shadow: 0 24px 48px -24px rgba(20, 49, 92, .35); }
.hero-plate .plate-state { font-size: 38px; }
.hero-plate .plate-text { font-size: clamp(56px, 7vw, 88px); }
.caret { display: inline-block; width: 4px; height: .82em; margin-left: 4px; background: currentColor; vertical-align: -0.06em; animation: blink 1s step-end infinite; }
@keyframes blink { 50% { opacity: 0; } }

.choose { padding: 64px 0 24px; }
.choose h2, .section h2 { font-size: clamp(26px, 3.4vw, 34px); margin-bottom: 8px; }
.section-lede { color: var(--body); font-size: 17px; max-width: 40em; }
.choices { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; margin-top: 28px; }
.choice {
  border: 1px solid var(--border); border-radius: 18px; padding: 28px;
  display: flex; flex-direction: column; gap: 14px; background: var(--surface);
}
.choice.is-recommended { border: 2px solid var(--brand); }
.choice-tag { align-self: flex-start; font-size: 12px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--brand); background: var(--brand-tint); padding: 4px 10px; border-radius: 999px; }
.choice h3 { font-size: 22px; }
.choice p { color: var(--body); }
.choice ul { margin: 0; padding-left: 20px; color: var(--body); display: flex; flex-direction: column; gap: 6px; }
.choice .actions { margin-top: auto; padding-top: 8px; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }

.section { padding: 56px 0; }
.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 28px; padding: 0; list-style: none; counter-reset: step; }
.steps li { background: var(--bg); border-radius: 16px; padding: 24px; counter-increment: step; display: flex; flex-direction: column; gap: 8px; }
.steps li::before { content: counter(step); width: 32px; height: 32px; border-radius: 16px; background: var(--brand-ink); color: #fff; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.steps h3 { font-size: 18px; }
.steps p { color: var(--body); }

.example { display: grid; grid-template-columns: 1fr 1.2fr; gap: 40px; align-items: start; }
.example-list { background: var(--bg); border-radius: 18px; padding: 20px; display: flex; flex-direction: column; gap: 16px; }
.group-title { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.plate-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.plate-chips .mini-plate { min-width: 0; font-size: 22px; min-height: 40px; }

.rules-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; margin-top: 24px; }
.rule { display: flex; gap: 14px; align-items: flex-start; padding: 18px; border: 1px solid var(--line); border-radius: 14px; }
.rule-badge { flex-shrink: 0; min-width: 56px; height: 32px; padding: 0 6px; border-radius: 6px; border: 1.5px solid var(--border); display: flex; align-items: center; justify-content: center; font: 700 18px/1 var(--plate-font); color: var(--plate-ink); }
.rule-badge.is-small { font-size: 13px; }
.rule strong { display: block; font-weight: 600; }
.rule span { font-size: 15px; color: var(--body); }

/* ---- Legal + support pages ---------------------------------------------------------- */

.doc { padding: 48px 0 64px; }
.doc h1 { font-size: clamp(32px, 4.5vw, 44px); margin-bottom: 8px; }
.doc .updated { color: var(--muted); font-size: 15px; margin-bottom: 28px; }
.doc h2 { font-size: 22px; margin: 36px 0 10px; }
.doc h3 { font-size: 17px; margin: 20px 0 6px; letter-spacing: -0.01em; }
.doc p, .doc li { color: var(--body); font-size: 17px; line-height: 1.65; }
.doc p + p { margin-top: 12px; }
.doc ul { padding-left: 22px; margin: 10px 0; }
.doc li + li { margin-top: 6px; }
.summary { background: var(--brand-tint); border-radius: 16px; padding: 22px 24px; }
.summary p, .summary li { color: var(--ink); }
.contact-card { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; border: 1px solid var(--border); border-radius: 16px; padding: 22px 24px; margin: 8px 0 12px; }
.contact-card strong { display: block; font-size: 18px; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary { cursor: pointer; padding: 18px 0; font-weight: 600; font-size: 17px; list-style: none; display: flex; justify-content: space-between; gap: 16px; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-weight: 400; font-size: 24px; line-height: 1; color: var(--muted); }
.faq details[open] summary::after { content: "–"; }
.faq details > div { padding: 0 0 18px; }

@media (max-width: 820px) {
  .hero .wrap, .example { grid-template-columns: 1fr; gap: 32px; }
  .hero .wrap { padding-top: 40px; padding-bottom: 48px; }
  .hero-plate { height: 150px; order: -1; }
  .hero-plate .plate-state { font-size: 28px; }
  .hero-plate .plate-text { font-size: clamp(48px, 15vw, 72px); }
  .choices, .steps, .rules-grid { grid-template-columns: 1fr; }
  .site-nav .hide-sm { display: none; }
}

.hero-ctas { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; margin-top: 28px; }
.hero-ctas .btn { min-height: 54px; }

.features { list-style: none; padding: 0; margin: 28px 0 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
.features li { background: var(--bg); border-radius: 16px; padding: 22px; display: flex; flex-direction: column; gap: 6px; }
.features strong { font-size: 18px; }
.features span { color: var(--body); }
@media (max-width: 820px) { .features { grid-template-columns: 1fr; } }
