/*
 * PeakQuiz Website. Werte aus src/components/theme.ts der App: nur Dark Mode,
 * ein Akzent, Haarlinien statt Schatten, keine Verläufe, Systemschrift,
 * tabellarische Ziffern. Farben stehen nur hier in :root, der Rest nutzt die
 * Variablen. Die Klassen unter „Linkseiten" stammen aus der ersten Website und
 * bleiben stabil, damit die Seiten /r, /t und /f des Servers sie nutzen können.
 */
:root {
  color-scheme: dark;
  --bg0: #09090b;
  --bg1: #111114;
  --bg2: #18181c;
  --hair: rgba(255, 255, 255, 0.1);
  --hair-strong: rgba(255, 255, 255, 0.18);
  --ink: #ffffff;
  --dim: rgba(255, 255, 255, 0.62);
  --dimmer: rgba(255, 255, 255, 0.4);
  --accent: #4f8cff;
  --accent-ink: #09090b;
  --accent-soft: rgba(79, 140, 255, 0.16);
  /* Nur in der Telefon-Attrappe, wie in der App: Spielfeedback, nie Dekoration. */
  --positive: #34d399;
  --positive-soft: rgba(52, 211, 153, 0.18);
  --island: #000000;
  --nav-bg: rgba(9, 9, 11, 0.9);

  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --touch-min: 44px;
  --touch-primary: 56px;
  --gutter: 20px;
  --nav-h: 64px;

  --fade: 200ms;
  --reveal: 450ms;
  --press: 160ms;
  --curve: cubic-bezier(0.22, 0.61, 0.36, 1);
  --fade-curve: cubic-bezier(0.22, 1, 0.36, 1);
  --press-curve: cubic-bezier(0.25, 0.46, 0.45, 0.94);

  --font:
    -apple-system, BlinkMacSystemFont, 'SF Pro Text', 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

/* Grundlagen */

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--nav-h) + 16px);
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg0);
  color: var(--ink);
  font-family: var(--font);
  font-size: 16px;
  line-height: 24px;
  font-variant-numeric: tabular-nums;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3,
p,
figure {
  margin: 0;
}

svg {
  display: block;
  flex: none;
}

a {
  color: var(--accent);
  text-underline-offset: 3px;
}

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

[hidden] {
  display: none !important;
}

.skip {
  position: absolute;
  z-index: 20;
  left: var(--gutter);
  top: -100px;
  padding: 8px 12px;
  background: var(--bg1);
  color: var(--ink);
  border: 1px solid var(--hair);
  border-radius: var(--radius-sm);
}

.skip:focus {
  top: 8px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.wrap {
  width: 100%;
  max-width: 1120px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.num {
  font-variant-numeric: tabular-nums;
  font-weight: 600;
}

.icon {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.icon-fill {
  fill: currentColor;
  stroke: none;
}

/* Logo „Doppelgipfel", Geometrie wie favicon.svg */

.logo {
  width: 32px;
  height: 22px;
  stroke-width: 48;
  stroke-linejoin: round;
}

.logo-a {
  fill: var(--ink);
  stroke: var(--ink);
}

.logo-gap {
  fill: var(--bg0);
  stroke: var(--bg0);
  stroke-width: 104;
}

.logo-b {
  fill: var(--accent);
  stroke: var(--accent);
}

/* Navigation */

.nav {
  position: fixed;
  inset: 0 0 auto;
  z-index: 10;
  background: var(--nav-bg);
  border-bottom: 1px solid var(--hair);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.nav-inner {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: var(--nav-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: var(--touch-min);
  margin-right: auto;
  color: var(--ink);
  text-decoration: none;
  font-size: 20px;
  font-weight: 800;
  letter-spacing: -0.4px;
}

.nav-links {
  display: flex;
  gap: 2px;
  margin: 0 8px 0 0;
  padding: 0;
  list-style: none;
}

.nav-links a {
  display: inline-flex;
  align-items: center;
  min-height: var(--touch-min);
  padding: 0 12px;
  border-radius: var(--radius-sm);
  color: var(--dim);
  text-decoration: none;
  font-size: 15px;
  font-weight: 600;
  transition: color var(--fade) var(--fade-curve);
}

.nav-links a:hover,
.nav-links a[aria-current] {
  color: var(--ink);
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: var(--touch-min);
  height: var(--touch-min);
  padding: 0;
  border: 1px solid var(--hair);
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}

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

  .js .nav-toggle {
    display: inline-flex;
  }

  .js .nav[data-open] .nav-links {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    margin: 0;
    padding: 8px var(--gutter) 16px;
    background: var(--bg0);
    border-bottom: 1px solid var(--hair);
  }

  .js .nav[data-open] .nav-links a {
    width: 100%;
    padding: 0;
    font-size: 17px;
  }
}

/* Knöpfe: primäre Aktion 56 px, alles andere mindestens 44 px */

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  max-width: 540px;
  margin-top: 32px;
}

.actions .button {
  flex: 1 1 220px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  min-height: var(--touch-primary);
  padding: 0 24px;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
  font: inherit;
  font-size: 17px;
  line-height: 22px;
  font-weight: 700;
  letter-spacing: -0.1px;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition:
    transform var(--press) var(--press-curve),
    background-color var(--fade) var(--fade-curve);
}

.button:active {
  transform: scale(0.97);
}

.button-primary {
  background: var(--accent);
  color: var(--accent-ink);
}

.button-secondary {
  background: transparent;
  color: var(--ink);
  border-color: var(--hair);
}

.button-secondary:hover {
  background: var(--bg1);
}

.button-small {
  min-height: var(--touch-min);
  padding: 0 16px;
  font-size: 15px;
}

.button-ghost {
  min-height: var(--touch-min);
  background: transparent;
  color: var(--accent);
}

/* Text */

.label {
  display: block;
  margin: 0 0 8px;
  font-size: 11px;
  line-height: 14px;
  font-weight: 600;
  letter-spacing: 1.8px;
  text-transform: uppercase;
  color: var(--dim);
}

.title {
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.12;
  font-weight: 800;
  letter-spacing: -0.025em;
}

.lead {
  margin: 12px 0 0;
  font-size: 18px;
  line-height: 27px;
  color: var(--dim);
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border: 1px solid var(--hair);
  border-radius: 999px;
  font-size: 12px;
  line-height: 16px;
  font-weight: 600;
  color: var(--dim);
  white-space: nowrap;
}

.card-title {
  font-size: 19px;
  line-height: 25px;
  font-weight: 700;
  letter-spacing: -0.2px;
}

.card-text {
  margin-top: 8px;
  color: var(--dim);
}

/* Einstieg */

.intro {
  padding: calc(var(--nav-h) + 48px) 0 72px;
}

.intro-grid {
  display: grid;
  gap: 56px;
  align-items: center;
}

.intro-title {
  font-size: clamp(38px, 6vw, 64px);
  line-height: 1.04;
  font-weight: 800;
  letter-spacing: -0.035em;
}

.intro-title .line {
  display: block;
}

.intro .lead {
  margin-top: 20px;
  max-width: 34em;
  font-size: clamp(18px, 2vw, 20px);
  line-height: 1.5;
}

.intro-note {
  margin-top: 16px;
  color: var(--dim);
  font-size: 14px;
  line-height: 20px;
}

@media (min-width: 900px) {
  .intro {
    padding: calc(var(--nav-h) + 88px) 0 112px;
  }

  .intro-grid {
    grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  }
}

/* Telefon-Attrappe: vereinfachter Startscreen der App mit Beispieldaten */

.phone {
  width: min(300px, 100%);
  margin: 0 auto;
  padding: 10px;
  border: 1px solid var(--hair-strong);
  border-radius: 48px;
  background: var(--bg1);
}

.phone-screen {
  position: relative;
  height: 600px;
  overflow: hidden;
  border: 1px solid var(--hair);
  border-radius: 38px;
  background: var(--bg0);
}

.phone-island {
  position: absolute;
  top: 10px;
  left: 50%;
  width: 84px;
  height: 24px;
  margin-left: -42px;
  border-radius: 999px;
  background: var(--island);
}

.phone-status {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 44px;
  padding: 0 24px 0 30px;
  font-size: 13px;
  font-weight: 600;
}

.phone-status svg {
  width: 40px;
  height: 12px;
  fill: currentColor;
}

.app {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 8px 16px 0;
}

.app-head {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.app-label {
  font-size: 9px;
  line-height: 12px;
  font-weight: 600;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--dim);
}

.app-accent {
  color: var(--accent);
}

.app-wordmark {
  font-size: 27px;
  line-height: 32px;
  font-weight: 800;
  letter-spacing: -0.6px;
}

.app-date {
  display: flex;
  gap: 6px;
  font-size: 12px;
  line-height: 18px;
  color: var(--dim);
}

.app-summary {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 10px 0;
  border-top: 1px solid var(--hair);
  border-bottom: 1px solid var(--hair);
}

.app-row {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  font-size: 11px;
  line-height: 16px;
  color: var(--dim);
}

.app-row strong {
  font-size: 12px;
  font-weight: 600;
  color: var(--ink);
}

.app-bar {
  height: 4px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--bg2);
}

.app-bar span {
  display: block;
  width: 14.3%;
  height: 100%;
  border-radius: inherit;
  background: var(--accent);
}

.app-tiles {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.app-tile {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 12px;
  border: 1px solid var(--hair);
  border-radius: 12px;
  background: var(--bg1);
}

.app-icon {
  display: grid;
  place-items: center;
  flex: none;
  width: 34px;
  height: 34px;
  border-radius: 999px;
  background: var(--bg2);
  color: var(--ink);
}

.app-icon svg {
  width: 18px;
  height: 18px;
}

.is-solved .app-icon {
  background: var(--positive-soft);
  color: var(--positive);
}

.app-tile-text {
  display: flex;
  flex: 1;
  flex-direction: column;
  min-width: 0;
}

.app-tile-text .app-label {
  font-size: 8px;
  line-height: 11px;
}

.app-tile-name {
  font-size: 14px;
  line-height: 19px;
  font-weight: 700;
}

.app-status {
  display: flex;
  gap: 8px;
  font-size: 11px;
  line-height: 15px;
  color: var(--dim);
  white-space: nowrap;
}

.is-solved .app-status span:first-child {
  color: var(--positive);
}

.app-status .app-faint,
.app-chevron {
  color: var(--dimmer);
}

.app-chevron {
  width: 14px;
  height: 14px;
}

.app-tabbar {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  align-items: end;
  padding: 8px 0 18px;
  border-top: 1px solid var(--hair);
  background: var(--bg0);
}

.app-tab {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 3px;
  font-size: 8px;
  line-height: 11px;
  font-weight: 600;
  letter-spacing: 1.2px;
  text-transform: uppercase;
  color: var(--dimmer);
}

.app-tab svg {
  width: 20px;
  height: 20px;
}

.app-tab.is-active {
  color: var(--accent);
}

.app-play {
  display: grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  background: var(--accent);
  color: var(--accent-ink);
}

/* Abschnitte */

.block {
  padding: 72px 0;
  border-top: 1px solid var(--hair);
}

.block-head {
  max-width: 680px;
  margin-bottom: 40px;
}

.block-head .lead {
  margin-top: 16px;
}

.center {
  margin-left: auto;
  margin-right: auto;
  text-align: center;
}

.label-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
  margin-bottom: 8px;
}

.label-row .label {
  margin: 0;
}

@media (min-width: 900px) {
  .block {
    padding: 112px 0;
  }

  .block-head {
    margin-bottom: 56px;
  }
}

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

.card {
  padding: 28px 24px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-lg);
  background: var(--bg1);
}

@media (min-width: 760px) {
  .cards-3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .cards-2 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 760px) and (max-width: 1023px) {
  .cards-features {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

.step-num,
.card-icon {
  display: grid;
  place-items: center;
  width: var(--touch-min);
  height: var(--touch-min);
  margin-bottom: 20px;
  border: 1px solid var(--hair);
  border-radius: 999px;
  background: var(--bg2);
  font-size: 17px;
  font-weight: 700;
}

/* Spiele */

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 24px;
}

.chip {
  min-height: var(--touch-min);
  padding: 0 16px;
  border: 1px solid var(--hair);
  border-radius: 999px;
  background: transparent;
  color: var(--dim);
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition:
    transform var(--press) var(--press-curve),
    color var(--fade) var(--fade-curve);
}

.chip:hover {
  color: var(--ink);
}

.chip:active {
  transform: scale(0.96);
}

.chip[aria-pressed='true'] {
  border-color: var(--accent);
  background: var(--accent-soft);
  color: var(--ink);
}

.games {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 12px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.game {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 20px;
  border: 1px solid var(--hair);
  border-radius: var(--radius-md);
  background: var(--bg1);
}

/* Kategorie über dem Namen wie in den Kacheln der App; lange Namen wie „Farbgedächtnis" passen so immer. */
.game-top {
  display: flex;
  flex-direction: column-reverse;
  align-items: flex-start;
  gap: 10px;
}

.game-name {
  font-size: 18px;
  line-height: 24px;
  font-weight: 700;
}

.game-tagline {
  color: var(--dim);
}

.game-metric {
  margin-top: auto;
  padding-top: 8px;
  border-top: 1px solid var(--hair);
  font-size: 14px;
  line-height: 20px;
  color: var(--dim);
}

.game-metric strong {
  color: var(--ink);
  font-weight: 600;
}

/* Plus */

.checks {
  display: grid;
  gap: 10px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
  color: var(--dim);
}

.checks li {
  position: relative;
  padding-left: 28px;
}

.checks li::before {
  content: '';
  position: absolute;
  left: 4px;
  top: 5px;
  width: 6px;
  height: 11px;
  border-right: 2px solid var(--ink);
  border-bottom: 2px solid var(--ink);
  transform: rotate(45deg);
}

.prices {
  margin-top: 16px;
}

.price {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.price-amount {
  margin-top: 12px;
  font-size: 40px;
  line-height: 46px;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.price-unit {
  color: var(--dim);
}

.price .pill {
  align-self: flex-start;
  margin-top: 12px;
}

.fineprint {
  max-width: 720px;
  margin-top: 24px;
  color: var(--dim);
  font-size: 14px;
  line-height: 20px;
}

/* Häufige Fragen */

.faq {
  max-width: 760px;
  margin: 0 auto;
  border-top: 1px solid var(--hair);
}

.faq details {
  border-bottom: 1px solid var(--hair);
}

.faq summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 64px;
  padding: 16px 0;
  font-size: 17px;
  line-height: 24px;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
}

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

.faq summary::after {
  content: '';
  flex: none;
  width: 9px;
  height: 9px;
  margin-right: 4px;
  border-right: 2px solid var(--dim);
  border-bottom: 2px solid var(--dim);
  transform: translateY(-3px) rotate(45deg);
  transition: transform var(--fade) var(--fade-curve);
}

.faq details[open] summary::after {
  transform: translateY(2px) rotate(225deg);
}

.faq-answer {
  max-width: 64ch;
  padding: 0 0 20px;
  color: var(--dim);
}

/* Abschluss und Fuß */

.cta .actions {
  justify-content: center;
  margin-left: auto;
  margin-right: auto;
}

.footer {
  padding: 56px 0 40px;
  border-top: 1px solid var(--hair);
  color: var(--dim);
  font-size: 14px;
  line-height: 20px;
}

.footer-grid {
  display: grid;
  gap: 32px;
}

.footer-grid p {
  margin-top: 8px;
  max-width: 32em;
}

.footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer a {
  display: inline-flex;
  align-items: center;
  min-height: var(--touch-min);
  color: var(--dim);
  text-decoration: none;
}

.footer a:hover {
  color: var(--ink);
  text-decoration: underline;
}

.footer .brand {
  color: var(--ink);
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 24px;
  margin-top: 40px;
  padding-top: 24px;
  border-top: 1px solid var(--hair);
}

.footer-bottom nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0 24px;
}

.footer > .wrap > .footer-bottom:only-child {
  margin-top: 0;
  padding-top: 0;
  border-top: 0;
}

@media (min-width: 760px) {
  .footer-grid {
    grid-template-columns: 2fr 1fr 1fr 1.4fr;
  }
}

/* Rechtstexte */

.legal {
  padding: calc(var(--nav-h) + 48px) 0 72px;
}

.legal .wrap {
  max-width: 760px;
}

.legal h1 {
  margin-bottom: 8px;
}

.legal h2 {
  margin: 32px 0 8px;
}

.legal p,
.legal address {
  margin: 0 0 12px;
  font-style: normal;
}

/* Lange Adressen im Fließtext umbrechen, sonst scrollt die Seite auf schmalen Geräten seitlich. */
.legal a {
  overflow-wrap: anywhere;
}

/* Linkseiten und 404: schmale Spalte aus der ersten Website */

.page {
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  padding: 0 var(--gutter);
}

.page .button {
  width: 100%;
}

.top {
  display: flex;
  align-items: center;
  min-height: var(--nav-h);
  border-bottom: 1px solid var(--hair);
}

.hero {
  padding: 56px 0 32px;
}

.section {
  padding: 24px 0;
  border-top: 1px solid var(--hair);
}

.wordmark {
  font-size: 44px;
  line-height: 50px;
  font-weight: 800;
  letter-spacing: -1px;
}

.display {
  font-size: 30px;
  line-height: 36px;
  font-weight: 800;
  letter-spacing: -0.5px;
}

.heading {
  margin: 0 0 8px;
  font-size: 22px;
  line-height: 28px;
  font-weight: 700;
  letter-spacing: -0.3px;
}

.body-dim {
  margin: 0;
  color: var(--dim);
}

.list {
  margin: 12px 0 0;
  padding: 0;
  list-style: none;
}

.row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  min-height: var(--touch-min);
  border-bottom: 1px solid var(--hair);
}

.row:last-child {
  border-bottom: 0;
}

.row-open,
.row .meta,
.hint {
  color: var(--dim);
}

.row .meta {
  font-size: 14px;
  text-align: right;
}

.hint {
  margin: 8px 0 0;
  font-size: 14px;
  line-height: 20px;
  text-align: center;
}

.foot {
  margin-top: 32px;
  padding: 24px 0 32px;
  border-top: 1px solid var(--hair);
  font-size: 14px;
  line-height: 20px;
}

.foot nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0 24px;
}

.foot a {
  display: inline-flex;
  align-items: center;
  min-height: var(--touch-min);
  color: var(--dim);
}

/* Einblenden beim Scrollen (site.js), abgeschaltet bei „Bewegung reduzieren" */

.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition:
    opacity var(--reveal) var(--fade-curve),
    transform var(--reveal) var(--curve);
}

.js .reveal.is-visible {
  opacity: 1;
  transform: none;
}

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

  .js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .button,
  .chip,
  .faq summary::after {
    transition: none;
  }

  .button:active,
  .chip:active {
    transform: none;
  }
}
