/* GripCast website: "Game HUD", Farben 1:1 aus src/ui/theme.ts */
:root {
  --bg: #171411;
  --panel: #24211e;
  --panel-soft: #302b26;
  --panel-deep: #1d1916;
  --mint: #61f2b0;
  --mint-soft: #84e9b9;
  --gold: #ffca3a;
  --blue: #7ec6f3;
  --orange: #ff8c42;
  --red: #ff4757;
  --text: #f5efe6;
  --text-2: #cfbfac;
  --muted: #9a8a78;
  --border: #4a4036;
  --outline: #0f0c0a;
  --radius-s: 10px;
  --radius-m: 14px;
  --radius-l: 20px;
  --font: system-ui, -apple-system, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(97, 242, 176, 0.09), transparent 60%),
    radial-gradient(700px 400px at -10% 30%, rgba(255, 202, 58, 0.05), transparent 60%), var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  overflow-x: hidden;
}

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

a:focus-visible,
summary:focus-visible {
  outline: 3px solid var(--blue);
  outline-offset: 3px;
  border-radius: 6px;
}

.wrap {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 20px;
}

.wrap.narrow {
  max-width: 780px;
}

.logo {
  display: block;
  width: 46px;
  height: 46px;
  flex: none;
}

.micro {
  display: block;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.12em;
  color: var(--muted);
}

/* ---------- Top bar ---------- */

.topbar {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(23, 20, 17, 0.88);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(74, 64, 54, 0.6);
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 68px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 900;
  font-size: 19px;
  letter-spacing: 0.02em;
}

.topnav {
  display: flex;
  align-items: center;
  gap: 22px;
}

.topnav a {
  color: var(--text-2);
  text-decoration: none;
  font-size: 14px;
  font-weight: 700;
}

.topnav a:hover {
  color: var(--text);
}

.topnav .lang {
  border: 2px solid var(--border);
  border-radius: 999px;
  padding: 3px 10px;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--text);
}

.topnav .lang:hover {
  border-color: var(--mint);
}

@media (max-width: 760px) {
  .topnav a:not(.lang) {
    display: none;
  }
}

/* ---------- Typography ---------- */

h1,
h2,
h3 {
  margin: 0;
  line-height: 1.1;
  letter-spacing: -0.015em;
}

h1 {
  font-size: clamp(38px, 6vw, 62px);
  font-weight: 900;
}

h1 em {
  font-style: normal;
  color: var(--mint);
}

h2 {
  font-size: clamp(28px, 4vw, 40px);
  font-weight: 900;
  margin-bottom: 28px;
}

h3 {
  font-size: 19px;
  font-weight: 800;
  margin-bottom: 8px;
}

.eyebrow {
  margin: 0 0 12px;
  font-size: 12px;
  font-weight: 800;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--mint);
}

.eyebrow.gold {
  color: var(--gold);
}

.eyebrow.blue {
  color: var(--blue);
}

.lead {
  margin: 22px 0 0;
  font-size: 19px;
  color: var(--text-2);
  max-width: 34em;
}

.body {
  color: var(--text-2);
  margin: 0 0 20px;
}

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

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

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 52px;
  padding: 0 22px;
  border-radius: var(--radius-m);
  border: 2px solid var(--outline);
  font-weight: 900;
  font-size: 16px;
  letter-spacing: 0.02em;
  text-decoration: none;
  transition:
    transform 0.12s ease,
    box-shadow 0.12s ease;
}

.btn-icon {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.btn-primary {
  background: var(--mint);
  color: var(--outline);
  box-shadow: 0 5px 0 var(--outline);
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 7px 0 var(--outline);
}

.btn-soon {
  background: var(--panel);
  color: var(--text-2);
  border-color: var(--border);
  border-style: dashed;
}

.btn-ghost {
  background: var(--panel);
  color: var(--text);
  border-color: var(--border);
  box-shadow: 0 5px 0 var(--outline);
}

.btn-ghost:hover {
  border-color: var(--mint);
  transform: translateY(-2px);
}

.perks {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 20px;
  list-style: none;
  padding: 0;
  margin: 22px 0 0;
  color: var(--text-2);
  font-size: 15px;
  font-weight: 700;
}

.perks li {
  display: flex;
  align-items: center;
  gap: 6px;
}

.perks svg,
.ticks svg {
  width: 18px;
  height: 18px;
  flex: none;
  fill: none;
  stroke: var(--mint);
  stroke-width: 3;
  stroke-linecap: round;
  stroke-linejoin: round;
}

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

.hero {
  padding: 64px 0 88px;
}

.hero-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 0.9fr);
  gap: 56px;
  align-items: center;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  padding-bottom: 40px;
}

.hero-visual .notif {
  position: absolute;
  left: 50%;
  bottom: 0;
  width: min(340px, 100%);
  transform: translateX(-68%) rotate(-2deg);
}

@media (max-width: 900px) {
  .hero {
    padding-top: 40px;
  }

  .hero-grid {
    grid-template-columns: minmax(0, 1fr);
    gap: 48px;
  }

  .hero-visual .notif {
    transform: translateX(-50%) rotate(-2deg);
  }
}

/* ---------- Phone with screenshot ---------- */

.phone {
  margin: 0;
  width: 300px;
  max-width: 100%;
  padding: 10px;
  border-radius: 38px;
  background: linear-gradient(160deg, #3a332c, #1d1916);
  border: 2px solid var(--outline);
  box-shadow:
    0 10px 0 var(--outline),
    0 30px 60px rgba(0, 0, 0, 0.5),
    0 0 80px rgba(97, 242, 176, 0.12);
}

.phone-screen {
  position: relative;
  border-radius: 30px;
  background: var(--bg);
  overflow: hidden;
  /* clip statt hidden: Ausschnitt lässt sich nicht verschieben (scrollIntoView,
     Suche). flow-root, weil clip keinen Block-Kontext bildet und der negative
     margin-top des Screenshots sonst mit dem Container kollabiert. */
  overflow: clip;
  display: flow-root;
}

/*
 * Screenshot im S23-Format (1080×2340): oben die Statusleiste (74 px, also
 * 30/439 der Breite), unten die Navigationsleiste ausblenden. Sichtbar
 * bleiben 2086 von 2340 Zeilen (Seitenverhältnis 439/848). Prozent-Margins beziehen sich auf die
 * Breite, darum funktioniert das unabhängig von der Auflösung.
 */
.shot {
  aspect-ratio: 439 / 848;
  /* Ohne overflow: hidden wächst ein aspect-ratio-Block sonst mit dem Inhalt. */
  min-height: 0;
}

.shot img {
  display: block;
  width: 100%;
  height: auto;
  margin-top: calc(-30 / 439 * 100%);
}

.shot::after {
  content: '';
  position: absolute;
  inset: auto 0 0;
  height: 18%;
  background: linear-gradient(to bottom, transparent, var(--bg));
  pointer-events: none;
}

/* ---------- Notification mockup ---------- */

.notif {
  background: #2c2824;
  border: 2px solid var(--outline);
  border-radius: 18px;
  padding: 12px 14px 13px;
  box-shadow:
    0 6px 0 var(--outline),
    0 20px 40px rgba(0, 0, 0, 0.45);
  font-size: 14px;
  line-height: 1.4;
}

.notif-head {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 6px;
}

.notif-head .logo {
  width: 20px;
  height: 20px;
}

.notif-head time {
  margin-left: auto;
}

.notif b {
  display: block;
  font-weight: 800;
}

.notif p {
  margin: 2px 0 0;
  color: var(--text-2);
}

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

.section {
  padding: 84px 0;
  scroll-margin-top: 68px;
}

.section-alt {
  background: linear-gradient(180deg, var(--panel-deep), rgba(29, 25, 22, 0.4));
  border-top: 1px solid rgba(74, 64, 54, 0.6);
  border-bottom: 1px solid rgba(74, 64, 54, 0.6);
}

.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  margin-bottom: 24px;
}

@media (max-width: 860px) {
  .cards {
    grid-template-columns: minmax(0, 1fr);
  }
}

.card {
  background: var(--panel);
  border: 2px solid var(--border);
  border-radius: var(--radius-l);
  box-shadow: 0 6px 0 var(--outline);
  padding: 24px;
}

.card p {
  margin: 0;
  color: var(--text-2);
  font-size: 16px;
}

.card-flat {
  box-shadow: none;
  border-left: 4px solid var(--blue);
}

.card-icon {
  --c: var(--mint);
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 14px;
  margin-bottom: 16px;
  background: color-mix(in srgb, var(--c) 14%, transparent);
  border: 2px solid var(--c);
}

.card-icon.drop {
  --c: var(--blue);
}

.card-icon.bolt {
  --c: var(--gold);
}

.card-icon svg {
  width: 24px;
  height: 24px;
  fill: none;
  stroke: var(--c);
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.split {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 56px;
  align-items: center;
}

@media (max-width: 860px) {
  .split {
    grid-template-columns: minmax(0, 1fr);
    gap: 36px;
  }
}

.ticks {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 12px;
}

.ticks li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.ticks svg {
  margin-top: 4px;
}

.alert-visual {
  display: flex;
  justify-content: center;
}

.ride-card {
  width: min(360px, 100%);
  background: var(--panel);
  border: 2px solid var(--border);
  border-radius: var(--radius-l);
  box-shadow: 0 6px 0 var(--outline);
  padding: 20px;
}

.ride-card > .micro {
  margin-bottom: 14px;
  color: var(--gold);
}

.ride-row {
  margin-bottom: 14px;
}

.ride-label {
  display: flex;
  justify-content: space-between;
  font-size: 13px;
  margin-bottom: 6px;
}

.ride-label b {
  font-weight: 900;
  letter-spacing: 0.08em;
}

.ride-label span {
  color: var(--text-2);
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.ride-bar {
  position: relative;
  height: 12px;
  border-radius: 6px;
  background: var(--panel-soft);
}

.ride-bar i {
  position: absolute;
  top: 0;
  bottom: 0;
  border-radius: 6px;
  background: var(--mint);
  box-shadow: 0 0 10px rgba(97, 242, 176, 0.4);
}

.ride-scale {
  display: flex;
  justify-content: space-between;
  font-size: 11px;
  color: var(--muted);
  font-weight: 700;
  margin: -6px 0 16px;
}

.ride-threshold {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}

.ride-threshold b {
  font-size: 26px;
  font-weight: 900;
  color: var(--mint);
}

.text-link {
  font-weight: 800;
  text-decoration: none;
}

.text-link:hover {
  text-decoration: underline;
}

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

.faq {
  display: grid;
  gap: 10px;
}

.faq details {
  background: var(--panel);
  border: 2px solid var(--border);
  border-radius: var(--radius-m);
}

.faq details[open] {
  border-color: rgba(97, 242, 176, 0.5);
}

.faq summary {
  cursor: pointer;
  list-style: none;
  padding: 16px 48px 16px 18px;
  font-weight: 800;
  position: relative;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  content: '+';
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 22px;
  font-weight: 700;
  color: var(--mint);
}

.faq details[open] summary::after {
  content: '−';
}

.faq details p {
  margin: 0;
  padding: 0 18px 18px;
  color: var(--text-2);
}

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

.footer {
  padding: 48px 0 56px;
  border-top: 1px solid rgba(74, 64, 54, 0.6);
}

.footer-inner {
  display: grid;
  gap: 10px;
}

.footer-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 900;
  font-size: 18px;
  margin-bottom: 6px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  margin-bottom: 8px;
}

.footer-links a {
  font-weight: 700;
  color: var(--text);
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--mint);
}

.footer-note {
  margin: 0;
  font-size: 13px;
  color: var(--muted);
  max-width: 60em;
}

.footer-note a {
  color: var(--text-2);
}

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

.legal {
  padding-top: 32px;
  padding-bottom: 72px;
}

.legal-meta {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px;
  margin: 0 0 28px;
  font-size: 14px;
  font-weight: 700;
}

.legal-meta a {
  text-decoration: none;
}

.prose {
  color: var(--text-2);
  overflow-wrap: anywhere;
}

.prose h1 {
  color: var(--text);
  overflow-wrap: normal;
  hyphens: auto;
  font-size: clamp(32px, 5vw, 44px);
  margin-bottom: 16px;
}

.prose h2 {
  color: var(--text);
  font-size: 24px;
  margin: 44px 0 12px;
  scroll-margin-top: 80px;
}

.prose h3 {
  color: var(--text);
  font-size: 18px;
  margin: 28px 0 8px;
  scroll-margin-top: 80px;
}

.prose .anchor {
  color: inherit;
  text-decoration: none;
}

.prose .anchor:hover::after {
  content: ' #';
  color: var(--muted);
}

.prose strong {
  color: var(--text);
}

.prose code {
  font-size: 0.9em;
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 1px 5px;
}

.prose blockquote {
  margin: 20px 0;
  padding: 12px 18px;
  border-left: 4px solid var(--blue);
  background: var(--panel);
  border-radius: 0 var(--radius-s) var(--radius-s) 0;
}

.prose blockquote p {
  margin: 0;
}

.prose li + li {
  margin-top: 6px;
}

.table-wrap {
  overflow-x: auto;
  margin: 18px 0;
  border: 2px solid var(--border);
  border-radius: var(--radius-m);
}

.prose table {
  overflow-wrap: normal;
  border-collapse: collapse;
  width: 100%;
  min-width: 560px;
  font-size: 15px;
  line-height: 1.5;
}

.prose th,
.prose td {
  text-align: left;
  vertical-align: top;
  padding: 10px 14px;
  border-bottom: 1px solid var(--border);
}

.prose th:first-child,
.prose td:first-child {
  min-width: 150px;
}

.prose th {
  background: var(--panel);
  color: var(--text);
  font-size: 13px;
  letter-spacing: 0.04em;
}

.prose tr:last-child td {
  border-bottom: 0;
}

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

.notfound {
  min-height: 80vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: 40px;
  padding-bottom: 40px;
}

.notfound .logo {
  width: 112px;
  height: 112px;
  margin-bottom: 24px;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .btn {
    transition: none;
  }
}
