@font-face {
  font-family: "Bricolage Grotesque";
  src: url("schrift/bricolage-latin.woff2") format("woff2");
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-display: swap;
}

:root {
  --papier: #f2eee6;
  --tinte: #1b211e;
  --grau: #5b605b;
  --holz: #8a5a2e;
  --linie: #d6cfc2;
  --kopf-h: 3.25rem;
  --rand: clamp(1rem, 4vw, 3.5rem);
  --schrift: "Bricolage Grotesque", "Avenir Next", "Segoe UI", sans-serif;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  background: var(--papier);
}
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }

body {
  margin: 0;
  background: var(--papier);
  color: var(--tinte);
  font-family: var(--schrift);
  font-size: 1.0625rem;
  line-height: 1.55;
  font-weight: 400;
  font-optical-sizing: auto;
  overflow-x: clip;
  -webkit-font-smoothing: antialiased;
}

img, canvas { display: block; max-width: 100%; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.18em; }
a:focus-visible, button:focus-visible, [tabindex]:focus-visible {
  outline: 2px solid var(--holz);
  outline-offset: 3px;
}
button { font: inherit; color: inherit; }
p { margin: 0; }

.unsichtbar {
  position: absolute; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

/* Schriftstufen: gross eng, Fliesstext normal */
.riesig {
  font-size: clamp(2.75rem, 8.4vw, 8.75rem);
  line-height: 0.98;
  letter-spacing: -0.045em;
  font-weight: 560;
  font-stretch: 88%;
  margin: 0;
  text-wrap: balance;
}
.gross {
  font-size: clamp(2.1rem, 5.6vw, 5.25rem);
  line-height: 1.02;
  letter-spacing: -0.035em;
  font-weight: 560;
  font-stretch: 90%;
  margin: 0;
  text-wrap: balance;
}

/* Kopfzeile */
.kopf {
  position: fixed; inset: 0 0 auto 0; z-index: 20;
  height: var(--kopf-h);
  display: flex; align-items: center; gap: 0.9rem;
  padding: 0 var(--rand);
  padding-top: env(safe-area-inset-top);
  background: rgba(242, 238, 230, 0.8);
  -webkit-backdrop-filter: blur(18px) saturate(160%);
  backdrop-filter: blur(18px) saturate(160%);
  border-bottom: 1px solid rgba(27, 33, 30, 0.08);
  font-size: 0.9375rem;
  letter-spacing: 0.005em;
}
.kopf-name { font-weight: 620; text-decoration: none; }
.kopf-hinweis { color: var(--grau); }
.kopf-link { margin-left: auto; text-decoration: none; font-weight: 520; }
.kopf-link:hover { text-decoration: underline; }
@media (max-width: 30rem) { .kopf-hinweis { display: none; } }
@media (prefers-reduced-transparency: reduce) {
  .kopf { background: var(--papier); backdrop-filter: none; -webkit-backdrop-filter: none; }
}

/* 1 Titel */
.titel {
  position: relative;
  height: 100svh; min-height: 34rem;
  display: flex; flex-direction: column;
  overflow: hidden;
}
.titel-text {
  padding: calc(var(--kopf-h) + clamp(1.25rem, 5svh, 3.5rem)) var(--rand) clamp(1.25rem, 4svh, 2.5rem);
  display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 1rem 3rem;
  order: -1;
  will-change: transform, opacity;
}
.titel-text .riesig {
  font-size: clamp(2.75rem, 6.3vw, 7.25rem);
  max-width: none;
}
.titel-unter {
  max-width: 22rem;
  font-size: clamp(1.0625rem, 1.4vw, 1.25rem);
  line-height: 1.4;
  color: var(--grau);
}
.titel-bild {
  position: relative; flex: 1 1 auto; min-height: 0;
  overflow: hidden;
  background: #cfd6d6;
}
.titel-bild img {
  position: absolute; inset: 0;
  width: 100%; height: 100%; object-fit: cover;
  object-position: 40% 45%;
  will-change: transform;
}
.titel-fuss {
  position: absolute; left: var(--rand); bottom: calc(1.1rem + env(safe-area-inset-bottom));
  font-size: 0.8125rem; letter-spacing: 0.01em;
  color: #fff;
  background: rgba(27, 33, 30, 0.55);
  padding: 0.25rem 0.5rem;
}
@media (max-aspect-ratio: 1/1) {
  .titel-bild img { object-position: 20% 50%; }
}

/* Gedanke: ein Satz pro Bildschirm */
.gedanke {
  min-height: 92svh;
  display: flex; flex-direction: column; justify-content: center;
  padding: calc(var(--kopf-h) + 3rem) var(--rand) 4rem;
  max-width: 90rem;
}
.gedanke .riesig { max-width: 11ch; }
.gedanke-text {
  margin-top: 1.6rem;
  max-width: 32rem;
  font-size: clamp(1.0625rem, 1.5vw, 1.3rem);
  line-height: 1.45;
  color: var(--grau);
}
.nur-ruhig { display: none; }
.ruhig .nur-film { display: none; }
.ruhig .nur-ruhig { display: inline; }

/* 2 Sonnenfolge */
.tag { position: relative; height: 560svh; }
.tag-buehne {
  position: sticky; top: 0;
  height: 100svh;
  overflow: hidden;
  background: #b8c4b4;
}
.tag-leinwand { position: absolute; inset: 0; width: 100%; height: 100%; }
.tag-ersatz { display: none; }
.no-canvas .tag-ersatz { display: block; position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }

.tag-tafel {
  position: absolute; left: var(--rand); bottom: calc(var(--rand) + env(safe-area-inset-bottom));
  width: min(27rem, calc(100% - 2 * var(--rand)));
  background: rgba(242, 238, 230, 0.94);
  padding: 1.1rem 1.25rem 1.25rem;
}
.tag-uhr { display: flex; align-items: baseline; gap: 0.8rem; }
.tag-zeit {
  font-size: clamp(3rem, 6vw, 5rem);
  line-height: 1;
  letter-spacing: -0.04em;
  font-weight: 560;
  font-variant-numeric: tabular-nums;
  min-width: 4.6ch;
}
.tag-datum { color: var(--grau); font-size: 0.9375rem; }
.tag-saetze { position: relative; margin-top: 0.6rem; min-height: 4.7em; }
.tag-satz {
  position: absolute; inset: 0 0 auto 0;
  opacity: 0;
  transform: translateY(0.4rem);
  transition: opacity 0.35s ease, transform 0.35s ease;
  line-height: 1.45;
}
.tag-satz.an { opacity: 1; transform: none; }
.tag-lade { margin-top: 0.5rem; font-size: 0.875rem; color: var(--grau); }
.tag-wahl { display: none; }

/* Handy hochkant: Bild oben, Tafel darunter */
@media (max-aspect-ratio: 4/5) {
  .tag-leinwand { inset: var(--kopf-h) 0 auto 0; height: 60svh; }
  .tag-tafel {
    left: 0; right: 0; bottom: 0; width: auto;
    top: calc(var(--kopf-h) + 60svh);
    background: var(--papier);
    padding: 1rem var(--rand) calc(1rem + env(safe-area-inset-bottom));
  }
  .tag-buehne { background: var(--papier); }
  .no-canvas .tag-ersatz { top: var(--kopf-h); height: 60svh; bottom: auto; }
}

/* Ruhige Fassung: kein Scroll-Kino, Uhrzeit wählen */
.ruhig .tag { height: auto; }
.ruhig .tag-buehne { position: relative; }
.ruhig .tag-satz { transition: opacity 0.2s linear; transform: none; }
.ruhig .tag-wahl { display: flex; flex-wrap: wrap; gap: 0.25rem 1.1rem; margin-top: 0.7rem; }
.tag-wahl button {
  background: none; border: 0; padding: 0.35rem 0;
  border-bottom: 2px solid transparent;
  font-variant-numeric: tabular-nums;
  cursor: pointer;
}
.tag-wahl button[aria-pressed="true"] { border-bottom-color: var(--tinte); font-weight: 620; }

/* Abschnitte mit Kopf und Fuss */
.abschnitt-kopf {
  padding: clamp(5rem, 14svh, 9rem) var(--rand) clamp(1.5rem, 4svh, 2.5rem);
  display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 1.5rem 3rem;
}
.abschnitt-kopf .gross { max-width: 14ch; }
.abschnitt-fuss {
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 0.5rem 2rem;
  padding: 0.9rem var(--rand) 0;
  font-size: 0.9375rem; color: var(--grau);
}
.zieh-hinweis { color: var(--grau); }
@media (hover: hover) and (pointer: fine) { .zieh-hinweis { display: none; } }

/* 3 Aussicht */
.stock-wahl { display: flex; gap: 1.5rem; }
.stock-wahl button {
  background: none; border: 0; padding: 0.4rem 0;
  font-size: clamp(1.0625rem, 1.6vw, 1.375rem);
  color: var(--grau);
  border-bottom: 2px solid transparent;
  cursor: pointer;
  touch-action: manipulation;
}
.stock-wahl button[aria-selected="true"] { color: var(--tinte); border-bottom-color: var(--tinte); font-weight: 620; }
.stock-wahl button:active { opacity: 0.6; }

.pano {
  position: relative;
  height: max(52svh, calc(100vw / 2.5263));
  max-height: 82svh;
  overflow: hidden;
  background: #c9d3d6;
  cursor: grab;
  touch-action: pan-y;
  user-select: none; -webkit-user-select: none;
}
.pano.zieht { cursor: grabbing; }
.pano-band {
  position: absolute; top: 0; left: 0; height: 100%;
  aspect-ratio: 4800 / 1900;
  will-change: transform;
}
.pano-band img {
  position: absolute; inset: 0; width: 100%; height: 100%;
  opacity: 0; transition: opacity 0.45s ease;
  pointer-events: none;
}
.pano-band img.an { opacity: 1; }

/* 4 Rundum */
.rundum-text { max-width: 26rem; color: var(--grau); }
.dreh {
  position: relative;
  height: min(56.25vw, 86svh);
  overflow: hidden;
  background: #b9c6b2;
  cursor: grab;
  touch-action: pan-y;
  user-select: none; -webkit-user-select: none;
}
.dreh.zieht { cursor: grabbing; }
.dreh img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover;
  opacity: 0; pointer-events: none;
}
.dreh img:first-child { opacity: 1; }
@media (max-aspect-ratio: 4/5) {
  .dreh { height: 62svh; }
}

/* 5 Kennzahlen */
.zahlen { padding: clamp(6rem, 16svh, 11rem) var(--rand) clamp(4rem, 10svh, 7rem); }
.zahlen dl { margin: 0; }
.zahl {
  display: flex; flex-direction: column-reverse;
  padding: clamp(1.5rem, 5svh, 3.5rem) 0;
  border-top: 1px solid var(--linie);
}
.zahl dd {
  margin: 0;
  font-size: clamp(3.25rem, 10.5vw, 10rem);
  line-height: 0.95;
  letter-spacing: -0.05em;
  font-weight: 540;
  font-stretch: 86%;
  font-variant-numeric: tabular-nums;
}
.zahl dt { margin-top: 0.7rem; font-size: clamp(1.0625rem, 1.5vw, 1.3rem); color: var(--grau); }
.zahlen-hinweis { margin-top: 1.5rem; font-size: 0.9375rem; color: var(--grau); }

/* 6 Abschluss */
.schluss {
  min-height: 90svh;
  padding: clamp(5rem, 14svh, 9rem) var(--rand) clamp(4rem, 10svh, 6rem);
  border-top: 1px solid var(--linie);
}
.schluss .riesig { max-width: 12ch; }
.schluss-wege {
  list-style: none; margin: clamp(2.5rem, 8svh, 5rem) 0 0; padding: 0;
  display: grid; gap: 2.5rem 4rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr));
  max-width: 64rem;
}
.schluss-wege a {
  display: inline-block;
  font-size: clamp(1.75rem, 3.4vw, 2.75rem);
  line-height: 1.1;
  letter-spacing: -0.025em;
  font-weight: 580;
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.16em;
  color: var(--holz);
  padding: 0.2rem 0;
}
.schluss-wege a span { display: inline-block; transition: transform 0.2s ease; }
.schluss-wege a:hover span { transform: translateX(0.2em); }
.schluss-wege a:active { opacity: 0.6; }
.schluss-wege p { margin-top: 0.6rem; max-width: 26rem; color: var(--grau); }

/* Fusszeile */
.fuss {
  padding: 2.5rem var(--rand) calc(3rem + env(safe-area-inset-bottom));
  background: var(--tinte); color: #d9d6cf;
  font-size: 0.9375rem;
  display: grid; gap: 0.8rem;
}
.fuss p { max-width: 44rem; }
.fuss-marke { color: #fff; font-weight: 600; font-size: 1.0625rem; }

/* Einblenden beim Scrollen (nur mit Script) */
.js .einblenden { opacity: 0; transform: translateY(1.5rem); }
.ruhig .einblenden { transform: none; }
@media (prefers-reduced-motion: reduce) {
  .titel-bild img, .titel-text { will-change: auto; }
  .tag-satz, .pano-band img { transition-duration: 0.2s; }
  .schluss-wege a span { transition: none; }
}
