/* Gratlinie — Farben, Schrift und Tonfall aus brand/brand.md. Alpenglühen höchstens einmal pro Ansicht. */

@font-face {
  font-family: "Jost";
  src: url("fonts/jost.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --kreide: #F2EDE3;
  --tinte: #1E2A33;
  --nacht: #121C26;
  --firn: #ECE6DA;
  --arve: #2F4A3E;
  --fels: #5E6B73;
  --gluehen: #A9502E;
  --gluehen-hell: #D9825B;
  --kante: #C9C0AF;
  --grund: #E2DBCD;
  --firn-leise: rgba(236, 230, 218, 0.72);
  --rand: clamp(1rem, 5vw, 3rem);
  --breite: 72rem;
  --zeichnen: 3.2s;
  color-scheme: light;
}

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

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: 4.5rem; }

body {
  margin: 0;
  background: var(--kreide);
  color: var(--tinte);
  font: 400 1.0625rem/1.6 "Jost", system-ui, sans-serif;
  overflow-x: hidden;
}

img, svg { display: block; max-width: 100%; height: auto; }

a { color: inherit; text-underline-offset: 0.2em; text-decoration-thickness: 1px; }
a:hover { text-decoration-thickness: 2px; }

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

h1, h2, h3 { font-weight: 500; line-height: 1.15; margin: 0; }
h2, h3 { text-transform: uppercase; letter-spacing: 0.3em; }
h2 { font-size: clamp(1.15rem, 1rem + 1vw, 1.6rem); }
h3 { font-size: 1rem; }
p { margin: 0; }

.klein { font-size: 0.875rem; color: var(--fels); }

.sprung {
  position: absolute; left: 1rem; top: -4rem; z-index: 10;
  background: var(--kreide); padding: 0.5rem 1rem;
}
.sprung:focus { top: 1rem; }

/* Kopf */

.kopf {
  position: absolute; inset: 0 0 auto; z-index: 5;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1rem var(--rand);
  color: var(--firn);
}
.marke img { width: 8.5rem; }
.kopf nav { display: flex; gap: clamp(0.9rem, 3vw, 2rem); font-size: 0.8125rem; text-transform: uppercase; letter-spacing: 0.2em; }
.kopf nav a { text-decoration: none; padding: 0.5rem 0; }
.kopf nav a:hover { text-decoration: underline; }

/* Bühne mit den Linien */

.buehne {
  background: var(--nacht);
  color: var(--firn);
  min-height: 100svh;
  display: grid;
  align-content: center;
  gap: clamp(1.5rem, 4vh, 3rem);
  padding: 6rem var(--rand) 3.5rem;
}

.motiv { width: min(100%, 56rem); margin: 0 auto; display: grid; gap: 1.25rem; justify-items: center; }

.linien path {
  fill: none;
  stroke: var(--firn);
  stroke-width: 1px;
  vector-effect: non-scaling-stroke;
  stroke-linejoin: round;
  stroke-linecap: round;
  stroke-dasharray: 1;
  stroke-dashoffset: 1;
  animation: zeichnen 1.6s cubic-bezier(0.3, 0.6, 0.2, 1) calc(var(--i) / var(--n) * var(--zeichnen)) forwards;
}

@keyframes zeichnen { to { stroke-dashoffset: 0; } }

.buehne-text { max-width: 40rem; margin-inline: auto; text-align: center; display: grid; gap: 1.1rem; justify-items: center; }

.zeile {
  font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.2em;
  color: var(--firn-leise);
  font-variant-numeric: tabular-nums;
  text-align: center;
}
.zeile > span { display: inline-block; }
.zaehler { display: inline-block; min-width: 2ch; text-align: right; }

h1 { font-size: clamp(2rem, 1.3rem + 3.5vw, 3.6rem); letter-spacing: 0.01em; text-wrap: balance; }

.lead { font-size: clamp(1.05rem, 1rem + 0.4vw, 1.25rem); color: var(--firn-leise); text-wrap: pretty; max-width: 34rem; }

.aktionen { display: flex; flex-wrap: wrap; justify-content: center; align-items: center; gap: 0.75rem 1.5rem; margin-top: 0.5rem; }

.knopf {
  display: inline-block;
  background: var(--gluehen); color: var(--kreide);
  padding: 0.85rem 1.6rem; border-radius: 2px;
  text-decoration: none; font-weight: 500;
  text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.8125rem;
  transition: transform 0.2s ease, background-color 0.2s ease;
}
.knopf:hover { transform: translateY(-1px); background: #93431f; }
.buehne .knopf { background: var(--gluehen-hell); color: var(--nacht); }
.buehne .knopf:hover { background: #e59873; }
.leise { font-size: 0.9375rem; color: var(--firn-leise); padding: 0.6rem 0; }

/* Abschnitte */

.serie, .entstehung, .kaufen { padding: clamp(3.5rem, 9vw, 6.5rem) var(--rand); }
.serie > *, .entstehung > *, .kaufen > * { max-width: var(--breite); margin-inline: auto; }

.abschnitt-kopf { display: grid; gap: 1rem; margin-bottom: clamp(2rem, 5vw, 3rem); }
.abschnitt-kopf > p { max-width: 38rem; color: var(--fels); }

.filter, .stile { display: none; flex-wrap: wrap; gap: 0.4rem; }
.js .filter, .js .stile { display: flex; }
.filter { flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; margin-inline: calc(-1 * var(--rand)); padding-inline: var(--rand); }
.filter::-webkit-scrollbar { display: none; }
.filter > button { flex: none; padding-inline: 0.75rem; letter-spacing: 0.08em; }

.filter button, .stile button {
  font: inherit; cursor: pointer;
  background: transparent; color: var(--tinte);
  border: 1px solid var(--kante); border-radius: 2px;
  min-height: 2.75rem; padding: 0.4rem 1rem;
  font-size: 0.8125rem; text-transform: uppercase; letter-spacing: 0.15em;
  transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}
.filter button:hover, .stile button:hover { border-color: var(--tinte); }
.filter button[aria-pressed="true"], .stile button[aria-pressed="true"] { background: var(--tinte); border-color: var(--tinte); color: var(--kreide); }

/* Die Serie */

.raster {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 16.5rem), 1fr));
  gap: clamp(2.5rem, 5vw, 3.5rem) clamp(1.5rem, 3vw, 2.5rem);
}

.gipfel { display: grid; gap: 0.75rem; align-content: start; }
.gipfel[hidden] { display: none; }

.plakat {
  width: 100%; aspect-ratio: 1000 / 1414;
  background: var(--grund);
  box-shadow: 0 0 0 1px var(--kante), 0 18px 40px -24px rgba(30, 42, 51, 0.45);
  transition: opacity 0.25s ease;
}
.plakat.wechselt { opacity: 0.35; }

.gipfel .stile button { min-height: 2.75rem; padding-inline: 0.8rem; font-size: 0.75rem; }
.gipfel h3 { font-size: 1.05rem; margin-top: 0.4rem; }
.fakten { color: var(--fels); font-size: 0.8125rem; text-transform: uppercase; letter-spacing: 0.2em; margin-top: -0.4rem; }

.kauf-links { list-style: none; margin: 0.25rem 0 0; padding: 0; border-top: 1px solid var(--kante); }
.kauf-links li { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; border-bottom: 1px solid var(--kante); }
.kauf-links a { flex: 1; padding: 0.7rem 0; text-decoration: none; font-weight: 500; }
.kauf-links a::after { content: " →"; color: var(--fels); transition: margin 0.2s ease; }
.kauf-links a:hover::after { margin-left: 0.25rem; }
.kauf-links span { color: var(--fels); font-size: 0.9375rem; font-variant-numeric: tabular-nums; white-space: nowrap; }

.js .gipfel.kommt { opacity: 0; transform: translateY(1.5rem); }
.gipfel { transition: opacity 0.7s ease, transform 0.7s cubic-bezier(0.2, 0.7, 0.2, 1); }

/* Entstehung */

.entstehung { background: var(--grund); }
.schritte { list-style: none; margin: 2rem auto 0; padding: 0; display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); counter-reset: schritt; }
.schritte li { counter-increment: schritt; border-top: 1px solid var(--tinte); padding-top: 1rem; display: grid; gap: 0.6rem; }
.schritte li::before { content: "0" counter(schritt); font-size: 0.8125rem; letter-spacing: 0.2em; color: var(--fels); }
.schritte p { color: var(--tinte); max-width: 30rem; }

/* Kaufen */

.wege { display: grid; gap: 1.5rem; margin-top: 2rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr)); }
.weg { border: 1px solid var(--kante); padding: clamp(1.4rem, 4vw, 2.2rem); display: grid; gap: 1rem; align-content: start; }
.preis { font-variant-numeric: tabular-nums; font-weight: 500; }
.pfeil { font-weight: 500; text-transform: uppercase; letter-spacing: 0.18em; font-size: 0.8125rem; display: inline-block; padding: 0.85rem 0; }
.pfeil::after { content: " →"; }

/* Fuss */

.fuss {
  background: var(--nacht); color: var(--firn);
  padding: 3rem var(--rand) 2.5rem;
  display: grid; gap: 0.75rem; justify-items: center; text-align: center;
}
.fuss-logo { width: 9rem; margin-bottom: 0.5rem; }
.fuss .klein { color: var(--firn-leise); max-width: 34rem; }
.fuss nav { display: flex; gap: 1.5rem; margin-top: 0.75rem; }
.fuss nav a, .fuss p a { display: inline-block; padding: 0.4rem 0; }

/* Rechtliche Seiten */

.seite { max-width: 42rem; margin-inline: auto; padding: 2rem var(--rand) 4rem; }
.seite-kopf { padding: 1.25rem var(--rand); max-width: 42rem; margin-inline: auto; }
.seite-kopf img { width: 8.5rem; }
.seite h1 { font-size: clamp(1.6rem, 1.3rem + 1.5vw, 2.2rem); margin-bottom: 1.5rem; }
.seite h2 { font-size: 0.95rem; margin: 2.2rem 0 0.7rem; }
.seite p, .seite ul { margin: 0 0 0.9rem; }
.seite ul { padding-left: 1.2rem; }
.seite address { font-style: normal; margin-bottom: 0.9rem; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .linien path { animation: none; stroke-dashoffset: 0; }
  .js .gipfel.kommt { opacity: 1; transform: none; }
  .gipfel, .plakat, .knopf { transition: none; }
}
