/* Dart Weather landing — design system.
   Palette mirrors the app: near-black surfaces, blue-400 primary, Inter. */

@font-face {
  font-family: "Inter";
  src: url("fonts/inter-var.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

:root {
  color-scheme: dark;
  --bg: #0A0A0A;
  --surface: #1A1A1A;
  --surface-2: #242424;
  --primary: #60A5FA;
  --primary-strong: #3B82F6;
  --text: #F5F5F5;
  --text-2: #A3A3A3;
  --text-3: #737373;
  --border: #2A2A2A;
  --focus: #93C5FD;
  --radius: 14px;
  --band-gap: clamp(64px, 9vw, 112px);
}

* { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 16px;
  line-height: 1.5;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

img, svg, video { display: block; }
p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
h1, h2 { margin: 0; }

::selection { background: rgba(96, 165, 250, 0.35); }

:focus-visible {
  outline: 2px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

a { color: var(--primary); }

.skip-link {
  position: absolute;
  top: -48px;
  left: 16px;
  z-index: 100;
  background: var(--surface-2);
  color: var(--text);
  padding: 10px 14px;
  border-radius: 8px;
  text-decoration: none;
  font-size: 14px;
  font-weight: 600;
  transition: top 0.15s ease-out;
}
.skip-link:focus { top: 16px; }

/* ---------- Bands ---------- */

.band {
  max-width: 1040px;
  margin-inline: auto;
  padding-inline: 24px;
  margin-top: var(--band-gap);
}
.band-wide { max-width: 1440px; }
.band-narrow { max-width: 820px; }

/* ---------- Hero ---------- */

.hero {
  position: relative;
  min-height: clamp(560px, 78vh, 820px);
  display: grid;
  place-items: center;
  overflow: hidden;
}

.hero-bg,
.hero-bg img,
.hero-video,
.hero-scrim {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-bg img,
.hero-video {
  object-fit: cover;
  /* Bias toward the radar cell (left-of-center in the source frame) so
     narrow viewports keep color in frame instead of empty dark map. */
  object-position: 38% 50%;
}

.hero-video {
  opacity: 0;
  transition: opacity 0.8s ease;
}
.hero-video.is-playing { opacity: 1; }

.hero-scrim {
  background: linear-gradient(
    180deg,
    rgba(10, 10, 10, 0.84) 0%,
    rgba(10, 10, 10, 0.56) 44%,
    rgba(10, 10, 10, 0.82) 76%,
    #0A0A0A 100%
  );
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 1040px;
  padding: 96px 24px;
  text-align: center;
}

.hero-icon {
  width: 56px;
  height: 56px;
  margin-inline: auto;
  border-radius: 14px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.14), 0 10px 30px rgba(0, 0, 0, 0.5);
}

.eyebrow {
  margin-top: 22px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-2);
}

.hero h1 {
  max-width: min(800px, 100%);
  margin: 14px auto 0;
  font-size: clamp(28px, 5vw, 44px);
  font-weight: 700;
  line-height: 1.16;
  letter-spacing: -0.02em;
  text-wrap: balance;
}

/* ---------- Play badge ---------- */

.play-badge {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-top: 34px;
  padding: 15px 26px;
  background: #000;
  border: 1px solid #3A3A3A;
  border-radius: 12px;
  text-decoration: none;
  transition: transform 0.16s ease-out, border-color 0.16s ease-out,
    box-shadow 0.16s ease-out;
}
.play-badge:hover {
  border-color: var(--primary);
  transform: translateY(-1px);
  box-shadow: 0 6px 22px rgba(96, 165, 250, 0.16);
}

.badge-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 2px;
}
.badge-kicker {
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.09em;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.7);
}
.badge-store {
  font-size: 22px;
  font-weight: 600;
  line-height: 1.1;
  color: #fff;
}

/* ---------- Showcase ---------- */

.shots {
  display: grid;
  grid-template-columns: 1fr;
  gap: 44px 20px;
}
@media (min-width: 760px) {
  .shots { grid-template-columns: repeat(3, 1fr); }
}

.shot figure { margin: 0; }

.shot-frame {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--surface);
  box-shadow: 0 12px 28px rgba(96, 165, 250, 0.1);
}
.shot-frame img {
  width: 100%;
  height: auto;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.shot figcaption { text-align: center; }
.shot h2 {
  margin-top: 16px;
  font-size: 18px;
  font-weight: 600;
}
.shot figcaption p {
  margin-top: 6px;
  font-size: 15px;
  color: var(--text-2);
}

/* ---------- Vehicles ---------- */

.vehicles h2,
.faq h2 {
  max-width: 680px;
  margin-inline: auto;
  text-align: center;
  font-size: clamp(20px, 2.6vw, 26px);
  font-weight: 600;
  line-height: 1.3;
  text-wrap: balance;
}

.makes {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
  margin-top: 40px;
}
@media (min-width: 720px) {
  .makes { grid-template-columns: repeat(3, 1fr); }
}
@media (min-width: 1000px) {
  .makes { grid-template-columns: repeat(4, 1fr); }
}

.make {
  display: flex;
  flex-direction: column;
  justify-content: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px;
  text-align: center;
  transition: transform 0.16s ease-out, border-color 0.16s ease-out,
    box-shadow 0.16s ease-out;
}
@media (hover: hover) {
  .make:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    box-shadow: 0 4px 18px rgba(96, 165, 250, 0.12);
  }
}

/* Logos are local monochrome-white trims of the OEM marks (media/logos/,
   normalized to a uniform trim height) drawn straight on the dark card. */
.make-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 44px;
  color: var(--text);    /* alt-text fallback if a logo fails to load */
  font-size: 14px;
  font-weight: 600;
}
.make-logo img {
  height: 26px;
  max-width: 86%;
  object-fit: contain;
  opacity: 0.92;
}

.make-models {
  display: block;
  margin-top: 10px;
  font-size: 12.5px;
  line-height: 1.7;
  color: var(--text-3);
}

/* ---------- FAQ ---------- */

.faq-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  margin-top: 8px;
}
.faq h2 + .faq-item { margin-top: 28px; }

.faq-item summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  cursor: pointer;
  font-size: 17px;
  font-weight: 600;
  list-style: none;
  border-radius: 12px;
}
.faq-item summary::-webkit-details-marker { display: none; }

.faq-item .chev {
  flex: none;
  color: var(--text-2);
  transition: transform 0.2s ease-out;
}
.faq-item[open] .chev {
  transform: rotate(180deg);
  color: var(--primary);
}

.faq-a {
  padding: 0 20px 20px;
  color: var(--text-2);
  line-height: 1.6;
  max-width: 65ch;
}
.faq-a p + p { margin-top: 12px; }

.faq-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-weight: 600;
  text-decoration: none;
}
.faq-link:hover { text-decoration: underline; }

/* ---------- Footer ---------- */

footer {
  margin-top: var(--band-gap);
  padding: 40px 24px 44px;
  border-top: 1px solid var(--border);
  text-align: center;
}

.foot-links {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px 24px;
}
.foot-links a {
  color: var(--text-2);
  font-size: 13px;
  text-decoration: none;
}
.foot-links a:hover {
  color: var(--text);
  text-decoration: underline;
}

footer p {
  margin-top: 16px;
  font-size: 12px;
  color: var(--text-3);
}
footer p + p { margin-top: 4px; }

/* ---------- 404 ---------- */

.error-page {
  text-align: center;
  margin-top: 20vh;
}
.error-page h1 { font-size: clamp(24px, 4vw, 34px); }
.error-page p { margin-top: 12px; color: var(--text-2); }
.error-page .error-home { margin-top: 24px; }

/* ---------- Reveal-on-scroll (JS-gated so no-JS never hides content) ---------- */

.js .reveal {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}
.js .reveal.in {
  opacity: 1;
  transform: none;
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .hero-video { transition: none; }
  .play-badge, .make { transition: none; }
}

@media (max-width: 360px) {
  .band { padding-inline: 16px; }
  .hero-content { padding-inline: 16px; }
}
