/* Tokens lifted directly from the app's own Material 3 theme
   (app/src/main/java/app/auxwire/ui/theme/Theme.kt), so the site reads as
   an extension of the app, not a separate brand. AuxWire is a dark-first
   in-dash surface, so dark is the default here too (not gated behind a
   media query) — light is the override for visitors who prefer it. */
:root {
  --bg: #15110f;
  --surface: #1e1815;
  --surface-variant: #322a24;
  --surface-container: #211b17;
  --fg: #f5efea;
  --muted: #b9ada4;
  --outline: #3a322c;
  --primary: #ff7a3d;
  --on-primary: #3a1300;
  --primary-container: #4a2718;
  --on-primary-container: #ffd9c7;
  --tertiary: #4ecdc4;
  --tertiary-container: #163a38;
  --on-tertiary-container: #cff0ec;

  --r-sm: 8px;
  --r-md: 12px;
  --r-lg: 16px;
  --r-xl: 28px;
  --r-pill: 999px;
  --max-w: 1080px;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #fbf6f2;
    --surface: #ffffff;
    --surface-variant: #f5eee7;
    --surface-container: #f2ece5;
    --fg: #201f1f;
    --muted: #756a62;
    --outline: #ede3db;
    --primary: #e85d2e;
    --on-primary: #ffffff;
    --primary-container: #ffe4d6;
    --on-primary-container: #4a2718;
    --tertiary: #1f8a82;
    --tertiary-container: #d7f3f0;
    --on-tertiary-container: #0b3a38;
  }
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }
a { color: inherit; }

.wrap { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }

/* ---------- Header ---------- */

header.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: color-mix(in srgb, var(--surface-container) 88%, transparent);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--outline);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  max-width: var(--max-w);
  margin: 0 auto;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.05rem;
  text-decoration: none;
  letter-spacing: -0.01em;
}

.brand img { width: 30px; height: 30px; border-radius: var(--r-sm); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 28px;
  font-size: 0.92rem;
  color: var(--muted);
}

.nav-links a { text-decoration: none; transition: color 0.15s ease; }
.nav-links a:hover { color: var(--fg); }

@media (max-width: 720px) {
  .nav-links { display: none; }
}

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

.hero {
  position: relative;
  overflow: hidden;
  padding: 88px 24px 72px;
  text-align: center;
}

.hero > .wrap { position: relative; z-index: 1; }

.hero-icon {
  width: 80px;
  height: 80px;
  border-radius: var(--r-lg);
  margin: 0 auto 28px;
}

.hero h1 {
  font-size: clamp(2.1rem, 5vw, 3rem);
  font-weight: 800;
  letter-spacing: -0.01em;
  margin: 0 0 14px;
}

.hero p.tagline {
  color: var(--muted);
  font-size: clamp(1rem, 2vw, 1.15rem);
  max-width: 560px;
  margin: 0 auto 36px;
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-bottom: 18px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 13px 24px;
  border-radius: var(--r-pill);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: none;
}

.btn-primary { background: var(--primary); color: var(--on-primary); }

.btn-tonal {
  background: var(--primary-container);
  color: var(--on-primary-container);
}

.btn-outline {
  background: transparent;
  color: var(--muted);
  border: 1px solid var(--outline);
}

.hero-note {
  color: var(--muted);
  font-size: 0.85rem;
  max-width: 480px;
  margin: 0 auto;
}

/* ---------- Sections ---------- */

section { padding: 72px 0; }

.section-head {
  text-align: center;
  max-width: 640px;
  margin: 0 auto 44px;
}

.section-head .kicker {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.74rem;
  color: var(--primary);
  font-weight: 700;
  margin-bottom: 8px;
}

.section-head h2 {
  font-size: clamp(1.5rem, 3.4vw, 2rem);
  font-weight: 700;
  margin: 0 0 10px;
  letter-spacing: -0.01em;
}

.section-head p { color: var(--muted); margin: 0; }

/* ---------- Features ---------- */

.feature-rows {
  display: flex;
  flex-direction: column;
  gap: 72px;
}

.feature-row {
  display: flex;
  align-items: center;
  gap: 56px;
}

.feature-row.reverse { flex-direction: row-reverse; }

.feature-row .shot {
  flex: 0 0 54%;
  min-width: 0;
}

/* A wide "dash frame" (not a phone bezel) — these are landscape car-display
   screenshots, so the frame reads as an in-dash panel rather than a handset. */
.dash-frame {
  border: 1px solid var(--outline);
  border-radius: var(--r-xl);
  overflow: hidden;
  background: var(--surface);
  box-shadow: 0 24px 48px -24px rgba(0, 0, 0, 0.5);
}

.dash-frame img { display: block; }

.feature-row .text { flex: 1; min-width: 0; }

.feature-row .icon {
  width: 44px;
  height: 44px;
  border-radius: var(--r-md);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  background: var(--primary-container);
  color: var(--on-primary-container);
  margin-bottom: 16px;
}

.feature-row h3 { margin: 0 0 8px; font-size: 1.3rem; font-weight: 700; }
.feature-row p { margin: 0; color: var(--muted); font-size: 0.98rem; max-width: 420px; }

@media (max-width: 860px) {
  .feature-row,
  .feature-row.reverse {
    flex-direction: column;
    text-align: center;
    gap: 28px;
  }
  .feature-row .shot { flex-basis: auto; width: 100%; }
  .feature-row .icon { margin-left: auto; margin-right: auto; }
  .feature-row p { max-width: none; }
}

/* ---------- More-features strip ---------- */

.more-features {
  background: var(--surface-container);
  border-top: 1px solid var(--outline);
  border-bottom: 1px solid var(--outline);
}

.more-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 28px;
  margin-top: 40px;
}

.more-item h4 {
  margin: 0 0 6px;
  font-size: 1.02rem;
  font-weight: 700;
}

.more-item p {
  margin: 0;
  color: var(--muted);
  font-size: 0.92rem;
}

/* ---------- Download band ---------- */

.download-band {
  position: relative;
  overflow: hidden;
  text-align: center;
}

.download-band > .wrap { position: relative; z-index: 1; }

.download-band h2 { margin: 0 0 8px; font-size: 1.7rem; font-weight: 700; }
.download-band p { color: var(--muted); margin: 0 0 28px; }

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

footer {
  padding: 36px 24px 56px;
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
}

footer .foot-links {
  display: flex;
  gap: 20px;
  justify-content: center;
  margin-bottom: 14px;
  flex-wrap: wrap;
}

footer a { color: var(--muted); text-decoration: none; }
footer a:hover { color: var(--fg); }

/* ---------- Legal pages ---------- */

.legal {
  max-width: 720px;
  margin: 0 auto;
  padding: 64px 24px 96px;
}

.legal h1 { font-size: 1.9rem; font-weight: 700; margin-bottom: 6px; }
.legal .updated { color: var(--muted); font-size: 0.86rem; margin-bottom: 36px; }
.legal h2 { font-size: 1.15rem; font-weight: 700; margin-top: 36px; }
.legal p, .legal li { color: var(--muted); font-size: 0.96rem; }
.legal ul { padding-left: 20px; }
.legal a { color: var(--primary); text-decoration: underline; text-underline-offset: 3px; }
