/*
 * Zwischen den Gleisen – Stylesheet
 *
 * Aufbau
 *   1. Schrift
 *   2. Farben und Werte (Design-Tokens)
 *   3. Grundlagen
 *   4. Seitenraster und Abschnitte
 *   5. Typografie
 *   6. Buttons und Links
 *   7. Kopfzeile und Handy-Menü
 *   8. Hero
 *   9. Bausteine (Bilder, Karten, Listen, Kennzahlen, Lageplan, FAQ, Downloads)
 *  10. Termine und Preise
 *  11. Countdown
 *  12. Abschluss-Band und Fußzeile
 *  13. Ticket-Leiste, „Nach oben“ und Barrierefreiheits-Menü
 *  14. Unterseiten (Barrierefreiheit, 404)
 *  15. Animationen
 *  16. Einstellungen aus dem Barrierefreiheits-Menü
 *
 * Bildschirmbreiten
 *   klein   ab 375px     Handy-Ränder werden breiter
 *   sm      ab 481px
 *   md      ab 768px     Tablet
 *   lg      ab 1024px    Laptop
 *   xl      ab 1280px
 *   Menü    ab 1441px    Hauptnavigation statt Menü-Knopf
 *
 * Regeln
 *   - Magenta (--accent) nie als Textfarbe, nur als Fläche oder Unterstreichung.
 *   - Der Markenverlauf als Schrift (.text-verlauf) nur für Hero-Titel, Kennzahlen und Countdown.
 *   - Kein Inline-Style im HTML: Die Content-Security-Policy in .htaccess erlaubt nur diese Datei.
 */

/* 1. Schrift ------------------------------------------------------------------------------------------------------- */

@font-face {
  font-family: 'Inter Variable';
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url('../schrift/inter-latin-ext.woff2') format('woff2-variations');
  unicode-range:
    U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F,
    U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: 'Inter Variable';
  font-style: normal;
  font-display: swap;
  font-weight: 100 900;
  src: url('../schrift/inter-latin.woff2') format('woff2-variations');
  unicode-range:
    U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC,
    U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

/* 2. Farben und Werte ---------------------------------------------------------------------------------------------- */

:root {
  color-scheme: dark;
  --schrift: 'Inter Variable', Inter, system-ui, sans-serif;

  /* Nachtblau-Schwarz wie der Himmel über dem Lokschuppen (#070816). */
  --background: 236 52% 6%;
  --foreground: 240 16% 96%;
  --foreground-soft: 235 16% 82%;
  --card: 233 46% 11%;
  --card-hover: 232 43% 14%;
  --muted: 232 43% 15%;
  --muted-foreground: 240 10% 69%;
  /* Magenta aus dem Logo (#FA03E7). Weiß darauf hält nur 3,4:1, deshalb trägt der Akzent dunklen Text. */
  --accent: 305 98% 50%;
  --accent-hover: 305 100% 64%;
  --accent-hell: 306 97% 74%;
  --accent-foreground: 236 52% 6%;
  /* Cyan aus dem Logo (#05EDFB): Icons, Status, Fokus und Hover. */
  --signal: 183 97% 50%;
  /* Violett (#9A7CF6), nur als Mittelstopp des Markenverlaufs. */
  --verlauf-mitte: 255 87% 73%;
  --border: 233 22% 36%;

  --ease-out: cubic-bezier(0.23, 1, 0.32, 1);
  --schatten-button: 0 4px 24px -6px hsla(305, 98%, 50%, 0.45);
  --schatten-gross: 0 25px 50px -12px rgb(0 0 0 / 0.25);
  --schatten-mittel: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1);
  --verlauf-marke: linear-gradient(
    90deg,
    hsl(var(--accent)) 0%,
    hsl(var(--verlauf-mitte)) 50%,
    hsl(var(--signal)) 100%
  );

  /* Seitenrand links und rechts, wächst mit der Bildschirmbreite. */
  --rand: 1.5rem;
  --inhalt-max: 80rem;
  --text-max: 42rem;
}

@media (min-width: 375px) {
  :root {
    --rand: 2rem;
  }
}

@media (min-width: 1024px) {
  :root {
    --rand: 4rem;
  }
}

/* 3. Grundlagen ---------------------------------------------------------------------------------------------------- */

*,
::before,
::after {
  box-sizing: border-box;
  border: 0 solid hsl(var(--border));
}

html {
  line-height: 1.5;
  -webkit-text-size-adjust: 100%;
  tab-size: 4;
  font-family: var(--schrift);
  scroll-behavior: smooth;
  /* Die feste Kopfzeile darf Sprungziele und Fokus nicht verdecken (WCAG 2.4.11). */
  scroll-padding-top: 6rem;
}

body {
  margin: 0;
  line-height: inherit;
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  font-family: var(--schrift);
  font-weight: 400;
  overflow-wrap: break-word;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0;
  font-family: var(--schrift);
  font-size: inherit;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: 0.025em;
  text-wrap: balance;
}

p,
li,
dd,
figcaption {
  text-wrap: pretty;
}

p,
dl,
dd,
figure,
blockquote {
  margin: 0;
}

ul,
ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

a {
  color: inherit;
  text-decoration: inherit;
}

strong {
  font-weight: bolder;
}

address {
  font-style: normal;
}

img,
svg {
  display: block;
  vertical-align: middle;
}

img {
  max-width: 100%;
  height: auto;
}

button {
  margin: 0;
  padding: 0;
  font: inherit;
  letter-spacing: inherit;
  color: inherit;
  text-transform: none;
  background-color: transparent;
  background-image: none;
  cursor: pointer;
}

:disabled {
  cursor: default;
}

summary {
  display: list-item;
}

dialog {
  padding: 0;
}

[hidden] {
  display: none !important;
}

::selection {
  background-color: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
}

:focus:not(:focus-visible) {
  outline: none;
}

/* Zweifarbig: Cyan außen, dunkler Ring innen. Sichtbar auf Dunkel, auf Bildern und auf dem Verlauf-Button. */
:focus-visible {
  outline: 2px solid hsl(var(--signal));
  outline-offset: 2px;
  box-shadow: 0 0 0 2px hsl(var(--background));
}

#main-content:focus {
  outline: none;
  box-shadow: none;
}

/* Nur für Screenreader. */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

.skip-link {
  position: fixed;
  top: -100%;
  left: 50%;
  z-index: 9999;
  transform: translateX(-50%);
  padding: 0.75rem 1.5rem;
  background: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  white-space: nowrap;
  transition: top 0.2s;
}

.skip-link:focus {
  top: 1rem;
  outline: 2px solid hsl(var(--accent-foreground));
  outline-offset: 2px;
}

/* 4. Seitenraster und Abschnitte ----------------------------------------------------------------------------------- */

/* Inhaltsbreite: höchstens 80rem, mittig, mit Seitenrand. */
.inhaltsbreite,
.inhalt-ebene {
  max-width: var(--inhalt-max);
  margin-inline: auto;
  padding-inline: var(--rand);
}

.inhalt-ebene {
  position: relative;
  z-index: 10;
}

/* Wie .inhaltsbreite, aber für volle Breite mit Hintergrund (Kopfzeile, Handy-Menü). */
.raster-x {
  padding-inline: calc(max(0px, (100% - var(--inhalt-max)) / 2) + var(--rand));
}

.textbreite {
  max-width: var(--text-max);
}

.abschnitt-basis {
  position: relative;
  overflow: hidden;
  padding-block: 4rem;
  background-color: hsl(var(--background));
}

@media (min-width: 768px) {
  .abschnitt-basis {
    padding-block: 6rem;
  }
}

/* Kopf eines Abschnitts: Titel, Einleitung, Buttons. */
.abschnitt-kopf {
  max-width: var(--text-max);
  margin-bottom: 3rem;
}

.abschnitt-kopf > * + * {
  margin-top: 1.5rem;
}

.abschnitt-kopf > .button-reihe {
  margin-top: 2.5rem;
}

.abschnitt-kopf--mittig {
  margin-inline: auto;
  text-align: center;
}

.abschnitt-kopf--mittig .button-reihe,
.abschnitt-kopf--mittig .chip-liste,
.button-reihe--mittig {
  justify-content: center;
}

.abschnitt-kopf--schluss,
.abschnitt-kopf--allein {
  margin-bottom: 0;
}

@media (min-width: 768px) {
  .abschnitt-kopf {
    margin-bottom: 4rem;
  }

  .abschnitt-kopf--schluss,
  .abschnitt-kopf--allein {
    margin-bottom: 0;
  }
}

.abschnitt-fuss {
  margin-top: 3rem;
}

@media (min-width: 768px) {
  .abschnitt-fuss {
    margin-top: 4rem;
  }
}

/* Mehrere Blöcke untereinander. */
.gruppen > * + * {
  margin-top: 3rem;
}

@media (min-width: 768px) {
  .gruppen > * + * {
    margin-top: 4rem;
  }
}

.gruppen-kopf {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  margin-bottom: 2rem;
}

/* Text und Bild nebeneinander (ab lg). */
.zweispalter {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: center;
  gap: 2rem;
}

.zweispalter > .abschnitt-kopf {
  margin-bottom: 0;
}

@media (min-width: 1024px) {
  .zweispalter {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 4rem;
  }

  /* Bild links statt rechts. */
  .zweispalter > .bild-zuerst {
    order: -1;
  }
}

/* Weiches Leuchten an den Rändern. Setzt nur das Hintergrundbild, die Flächenfarbe bleibt. */
.leuchten-diagonal {
  background-image:
    radial-gradient(60% 50% at 85% 10%, hsl(var(--signal) / 0.07), transparent 70%),
    radial-gradient(60% 60% at 0% 100%, hsl(var(--accent) / 0.1), transparent 70%);
}

.leuchten-oben {
  background-image: radial-gradient(70% 90% at 50% 0%, hsl(var(--accent) / 0.2), transparent 65%);
}

.leuchten-ecke {
  background-image: radial-gradient(60% 60% at 100% 100%, hsl(var(--signal) / 0.06), transparent 70%);
}

.leuchten-fuss {
  background-image: radial-gradient(80% 120% at 15% 0%, hsl(var(--accent) / 0.1), transparent 60%);
}

.leuchten-karte {
  background-image: radial-gradient(90% 80% at 100% 0%, hsl(var(--accent) / 0.18), transparent 65%);
}

/* 5. Typografie ---------------------------------------------------------------------------------------------------- */

.titel-h1 {
  font-size: 2.25rem;
  line-height: 1;
  letter-spacing: 0.025em;
  text-transform: uppercase;
}

.titel-unterzeile {
  font-size: 1.125rem;
  line-height: 1.25;
  letter-spacing: 0.025em;
  text-transform: uppercase;
  color: hsl(var(--foreground-soft));
  text-wrap: balance;
}

.titel-h2 {
  font-size: 1.5rem;
  line-height: 1.1;
  letter-spacing: 0.025em;
  text-transform: uppercase;
  color: hsl(var(--foreground));
}

.titel-h3,
.titel-karte {
  font-size: 1.25rem;
  line-height: 1.25;
  letter-spacing: 0.025em;
  text-transform: uppercase;
  color: hsl(var(--foreground));
}

.titel-karte {
  line-height: 1.375;
  letter-spacing: 0.05em;
}

@media (min-width: 768px) {
  .titel-h1 {
    font-size: 3rem;
  }

  .titel-unterzeile {
    font-size: 1.25rem;
  }

  .titel-h2 {
    font-size: 2.25rem;
  }

  .titel-h3,
  .titel-karte {
    font-size: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .titel-h1 {
    font-size: 3.75rem;
  }

  .titel-h2 {
    font-size: 3rem;
  }
}

@media (min-width: 1280px) {
  .titel-h1 {
    font-size: 4.5rem;
  }
}

.fliesstext,
.text-gedaempft,
.text-weich,
.text-betont {
  font-size: 1rem;
  line-height: 1.5rem;
}

.fliesstext {
  line-height: 1.625;
  color: hsl(var(--muted-foreground));
}

.text-gedaempft {
  color: hsl(var(--muted-foreground));
}

.text-weich {
  color: hsl(var(--foreground-soft));
}

.text-betont {
  font-weight: 500;
  color: hsl(var(--foreground));
}

.lead-text,
.lead-text-hell {
  font-size: 1.125rem;
  line-height: 1.625;
  color: hsl(var(--muted-foreground));
}

.lead-text-hell {
  color: hsl(var(--foreground-soft));
}

@media (min-width: 768px) {
  .lead-text,
  .lead-text-hell {
    font-size: 1.25rem;
  }
}

/* Kleine Versal-Zeile, weit gesperrt (Gruppentitel, Wochentag, „Veranstalter“). */
.label-weit {
  font-size: 0.75rem;
  line-height: 1rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: hsl(var(--muted-foreground));
}

/* Markenverlauf als Schriftfarbe. Breite = Text, sonst zeigt kurzer Text nur Magenta. */
.text-verlauf {
  width: fit-content;
  max-width: 100%;
  background-image: var(--verlauf-marke);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  -webkit-text-fill-color: transparent;
}

@media (forced-colors: active) {
  .text-verlauf {
    background: none;
    color: CanvasText;
    -webkit-text-fill-color: CanvasText;
  }
}

/* 6. Buttons und Links --------------------------------------------------------------------------------------------- */

.btn-primary,
.btn-secondary {
  display: inline-block;
  padding: 1rem 2rem;
  border: 1px solid transparent;
  font-size: 0.75rem;
  line-height: 1rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  transform-origin: center;
  transition:
    background-color 300ms var(--ease-out),
    border-color 300ms var(--ease-out),
    color 300ms var(--ease-out),
    transform 150ms var(--ease-out);
}

.btn-primary:active,
.btn-secondary:active {
  transform: scale(0.97);
}

/* Markenverlauf, doppelt so breit wie der Button: Beim Hover gleitet er von Magenta nach Cyan. */
.btn-primary {
  background-color: hsl(var(--accent));
  background-image: var(--verlauf-marke);
  background-origin: border-box;
  background-repeat: no-repeat;
  background-size: 200% 100%;
  background-position: 0% 50%;
  color: hsl(var(--accent-foreground));
  font-weight: 600;
  box-shadow: var(--schatten-button);
  transition:
    background-position 600ms var(--ease-out),
    transform 150ms var(--ease-out);
}

.btn-primary:hover {
  background-position: 100% 50%;
}

/* Rahmen dauerhaft sichtbar, mindestens 3:1 (WCAG 1.4.11). */
.btn-secondary {
  border-color: hsl(var(--foreground) / 0.5);
  color: hsl(var(--foreground));
}

.btn-secondary:hover {
  border-color: hsl(var(--signal));
  background-color: hsl(var(--signal) / 0.05);
  color: hsl(var(--signal));
}

/* Gesperrt bis zum Vorverkauf: gedämpft, ohne Hover, Leuchten und Klick-Effekt. */
.btn-primary:disabled,
.btn-secondary:disabled {
  cursor: not-allowed;
  opacity: 0.6;
  box-shadow: none;
  background-position: 0% 50%;
  transform: none;
}

/* Feine Kontur auf hochauflösenden Bildschirmen. */
@media (min-resolution: 2dppx) {
  .btn-primary,
  .btn-secondary {
    border-width: 0.5px;
  }
}

@media (max-width: 1023.98px) {
  .btn-primary,
  .btn-secondary {
    letter-spacing: 0.1em;
  }
}

@media (min-width: 481px) and (max-width: 1023.98px) {
  .btn-primary,
  .btn-secondary {
    padding-inline: 1.25rem;
  }
}

@media (max-width: 480.98px) {
  .btn-primary,
  .btn-secondary {
    width: fit-content;
    align-self: flex-start;
    padding-inline: 1rem;
    text-align: left;
  }
}

@media (max-width: 374.98px) {
  .btn-primary,
  .btn-secondary {
    letter-spacing: 0.05em;
  }
}

/* Button über die volle Breite (Hero-Karte). */
.btn-primary.btn--voll {
  display: flex;
  width: 100%;
  justify-content: center;
}

/* Reihe aus Buttons: auf Handys untereinander, gleich breit. */
.button-reihe {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 1rem;
}

.button-reihe > .btn-primary,
.button-reihe > .btn-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

@media (min-width: 481px) {
  .button-reihe {
    flex-direction: row;
    flex-wrap: wrap;
    align-items: stretch;
  }
}

@media (max-width: 480.98px) {
  .button-reihe {
    display: grid;
    grid-template-columns: fit-content(100%);
    justify-content: start;
  }

  .abschnitt-kopf--mittig .button-reihe,
  .button-reihe--mittig {
    justify-content: center;
  }

  .button-reihe > .btn-primary,
  .button-reihe > .btn-secondary {
    width: 100%;
    text-align: center;
  }
}

/* Textlink: Unterstreichung in Magenta, beim Hover Cyan. */
.text-link,
.text-links a {
  color: hsl(var(--foreground));
  text-decoration-line: underline;
  text-decoration-color: hsl(var(--accent));
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
  transition: text-decoration-color 300ms var(--ease-out);
}

.text-link:hover,
.text-links a:hover {
  color: hsl(var(--signal));
  text-decoration-color: hsl(var(--signal));
}

/* Link, der erst beim Hover unterstrichen wird. */
.hover-link {
  text-decoration-line: underline;
  text-decoration-color: transparent;
  text-decoration-thickness: 2px;
  text-underline-offset: 4px;
  transition: text-decoration-color 300ms var(--ease-out);
}

.hover-link:hover {
  color: hsl(var(--signal));
  text-decoration-color: currentColor;
}

/* Link mit 44px Klickhöhe. */
.link-zeile {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  font-size: 1rem;
  line-height: 1.5rem;
  color: hsl(var(--foreground));
}

.link-zeile--mittig {
  width: 100%;
  justify-content: center;
}

/* 7. Kopfzeile und Handy-Menü -------------------------------------------------------------------------------------- */

.kopfzeile {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 50;
  /* Platz unter der Leiste für den weichen Übergang. */
  padding-bottom: 6.5rem;
  pointer-events: none;
  animation: kopfzeile-ein 0.6s ease-out forwards;
}

.kopfzeile__leiste {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 1.5rem;
  pointer-events: auto;
}

/* Zwei Verläufe: oben auf dem Hero leicht, nach dem Scrollen dichter. */
.kopfzeile::before,
.kopfzeile::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  transition: opacity 300ms var(--ease-out);
}

.kopfzeile::before {
  background: linear-gradient(
    to bottom,
    hsl(var(--background) / 0.72) 0%,
    hsl(var(--background) / 0.15) 70%,
    transparent 100%
  );
  -webkit-mask-image: linear-gradient(to bottom, black 30%, transparent 100%);
  mask-image: linear-gradient(to bottom, black 30%, transparent 100%);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

.kopfzeile::after {
  background: linear-gradient(
    to bottom,
    hsl(var(--background) / 0.92) 0%,
    hsl(var(--background) / 0.86) 45%,
    hsl(var(--background) / 0.66) 58%,
    hsl(var(--background) / 0.44) 69%,
    hsl(var(--background) / 0.26) 79%,
    hsl(var(--background) / 0.12) 88%,
    hsl(var(--background) / 0.04) 95%,
    transparent 100%
  );
  -webkit-mask-image: linear-gradient(to bottom, black 45%, rgb(0 0 0 / 0.5) 75%, transparent 100%);
  mask-image: linear-gradient(to bottom, black 45%, rgb(0 0 0 / 0.5) 75%, transparent 100%);
  -webkit-backdrop-filter: blur(16px);
  backdrop-filter: blur(16px);
  opacity: 0;
}

.kopfzeile.ist-gescrollt::before {
  opacity: 0;
}

.kopfzeile.ist-gescrollt::after {
  opacity: 1;
}

.kopfzeile__links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
}

.kopfzeile__logo {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  height: 2.75rem;
}

.kopfzeile__logo img {
  width: auto;
  height: 2.75rem;
  object-fit: contain;
}

.kopf-meta {
  display: none;
  padding-left: 1.5rem;
  border-left: 1px solid hsl(var(--foreground) / 0.15);
  font-size: 0.75rem;
  line-height: 1rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: hsl(var(--foreground-soft));
}

.hauptnav {
  display: none;
  align-items: center;
  gap: 0.75rem;
  font-size: 0.875rem;
  line-height: 1.25rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: hsl(var(--foreground-soft));
}

.hauptnav a {
  padding-block: 0.5rem;
  transition: color 150ms;
}

.hauptnav a:hover {
  color: hsl(var(--foreground));
}

.kopfzeile__rechts {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  gap: 0.5rem;
}

.menue-knopf {
  padding: 0.75rem;
  color: hsl(var(--foreground));
}

.menue-knopf svg {
  width: 1.25rem;
  height: 1.25rem;
}

@media (min-width: 768px) {
  .kopf-meta {
    display: block;
  }
}

@media (min-width: 1024px) {
  .kopfzeile__logo,
  .kopfzeile__logo img {
    height: 3.5rem;
  }
}

@media (min-width: 1441px) {
  .hauptnav {
    display: flex;
  }

  .menue-knopf {
    display: none;
  }
}

.handymenue {
  position: fixed;
  inset: 0;
  z-index: 40;
  display: flex;
  flex-direction: column;
  background-color: hsl(var(--background));
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 300ms var(--ease-out),
    visibility 0s linear 300ms;
}

.handymenue.ist-offen {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition:
    opacity 300ms var(--ease-out),
    visibility 0s;
}

.handymenue__liste {
  flex: 1;
  overflow-y: auto;
  padding-top: 6rem;
  padding-bottom: 1.5rem;
}

.handymenue__link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-block: 1rem;
  border-bottom: 1px solid hsl(var(--border) / 0.6);
  font-size: 1.25rem;
  line-height: 1.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: hsl(var(--foreground-soft));
}

.handymenue__link:hover {
  color: hsl(var(--foreground));
}

@media (min-width: 768px) {
  .handymenue__link {
    font-size: 1.5rem;
    line-height: 2rem;
  }
}

.handymenue__fuss {
  display: flex;
  flex-shrink: 0;
  align-items: stretch;
  gap: 0.75rem;
  padding-block: 1.5rem;
  border-top: 1px solid hsl(var(--border) / 0.6);
}

.handymenue__fuss .btn-primary {
  display: flex;
  flex: 1;
  align-self: stretch;
  align-items: center;
  justify-content: space-between;
}

/* Einträge gleiten nacheinander herein. */
.handymenue__eintrag {
  opacity: 0;
  transform: translateY(8px);
  transition:
    opacity 0.3s var(--ease-out) var(--verzoegerung, 0s),
    transform 0.3s var(--ease-out) var(--verzoegerung, 0s);
}

.handymenue.ist-offen .handymenue__eintrag {
  opacity: 1;
  transform: none;
}

.handymenue__eintrag:nth-child(1) {
  --verzoegerung: 0.05s;
}

.handymenue__eintrag:nth-child(2) {
  --verzoegerung: 0.1s;
}

.handymenue__eintrag:nth-child(3) {
  --verzoegerung: 0.15s;
}

.handymenue__eintrag:nth-child(4) {
  --verzoegerung: 0.2s;
}

.handymenue__eintrag:nth-child(5) {
  --verzoegerung: 0.25s;
}

.handymenue__eintrag:nth-child(6) {
  --verzoegerung: 0.3s;
}

.handymenue__fuss.handymenue__eintrag {
  --verzoegerung: 0.4s;
}

/* 8. Hero ---------------------------------------------------------------------------------------------------------- */

/* Bildband oben, der Inhalt schiebt sich über den ausgeblendeten unteren Rand. */
.hero {
  position: relative;
  isolation: isolate;
}

.hero-bild {
  position: relative;
  overflow: hidden;
  height: clamp(18rem, 60vw, 62svh);
}

.hero-bild img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: 50% 58%;
}

.hero-bild::after {
  content: '';
  position: absolute;
  inset: 0;
  pointer-events: none;
  background: linear-gradient(
    to bottom,
    hsl(var(--background) / 0.4) 0%,
    transparent 30%,
    transparent 45%,
    hsl(var(--background)) 100%
  );
}

.hero-inhalt {
  position: relative;
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: end;
  gap: 2rem;
  margin-top: clamp(-8rem, -9vw, -1.5rem);
  padding-bottom: 4rem;
}

@media (min-width: 768px) {
  .hero-inhalt {
    padding-bottom: 6rem;
  }
}

@media (min-width: 1024px) {
  .hero-inhalt {
    grid-template-columns: minmax(0, 1.25fr) minmax(0, 1fr);
    gap: 4rem;
  }
}

.hero-kopf > * + * {
  margin-top: 1.5rem;
}

.hero-kopf > .titel-unterzeile {
  margin-top: 0.5rem;
}

.hero-karte {
  position: relative;
  padding: 1.5rem;
  border: 1px solid hsl(var(--foreground) / 0.15);
  background-color: hsl(var(--card) / 0.9);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
}

@media (min-width: 768px) {
  .hero-karte {
    padding: 2rem;
  }
}

.hero-karte > * + * {
  margin-top: 1.5rem;
}

/* Kurzfakten: Wann, Wo, Preis. */
.fakten-liste {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.fakt {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.fakt-icon {
  display: flex;
  flex-shrink: 0;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  background-color: hsl(var(--signal) / 0.1);
  color: hsl(var(--signal));
}

.fakt-icon svg {
  width: 1.25rem;
  height: 1.25rem;
}

.fakt-wert {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 0.75rem;
  font-size: 1.125rem;
  line-height: 1.75rem;
  font-weight: 700;
  color: hsl(var(--foreground));
}

.fakt-zusatz {
  display: block;
  margin-top: 0.25rem;
  font-size: 1rem;
  line-height: 1.5rem;
  color: hsl(var(--muted-foreground));
}

@media (min-width: 768px) {
  .fakt-wert {
    font-size: 1.25rem;
  }
}

/* 9. Bausteine ----------------------------------------------------------------------------------------------------- */

/* Bilder im festen Seitenverhältnis, das Bild füllt den Rahmen. */
.bildrahmen-3-2,
.bildrahmen-4-3 {
  position: relative;
  overflow: hidden;
  aspect-ratio: 3 / 2;
}

.bildrahmen-4-3 {
  aspect-ratio: 4 / 3;
}

.bild-fuellend {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Kennzeichnet KI-Bilder, damit niemand sie für Veranstaltungsfotos hält. */
.bild-hinweis {
  position: absolute;
  top: 1rem;
  right: 1rem;
  z-index: 10;
  padding: 0.375rem 0.75rem;
  background-color: hsl(var(--background) / 0.8);
  font-size: 0.75rem;
  line-height: 1rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: hsl(var(--foreground-soft));
}

/* Handy: unten rechts, sonst verdeckt die Kopfzeile den Hinweis. Ab lg liegt dort die Hero-Karte, also oben. */
.bild-hinweis--hero {
  top: auto;
  bottom: 2.5rem;
  right: var(--rand);
}

@media (min-width: 1024px) {
  .bild-hinweis--hero {
    top: 7rem;
    bottom: auto;
  }
}

/* Abschluss-Band: Das Foto liegt unten, also auch das Etikett. */
.bild-hinweis--unten {
  top: auto;
  bottom: 1rem;
}

/* Liste mit Haken. */
.haken-liste {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.haken-zeile {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  font-size: 1rem;
  line-height: 1.625;
  color: hsl(var(--foreground-soft));
}

.icon-haken {
  flex-shrink: 0;
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 0.1875rem;
  padding: 0.25rem;
  background-color: hsl(var(--signal) / 0.1);
  color: hsl(var(--signal));
}

/* Kartenraster: Die Spaltenzahl folgt der Kartenzahl, damit nie eine Karte allein in einer Reihe steht. */
.karten-raster {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1rem;
}

@media (min-width: 768px) {
  .karten-raster {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .karten-raster:has(> :nth-child(3):last-child) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .karten-raster:has(> :nth-child(5):last-child),
  .karten-raster:has(> :nth-child(6):last-child) {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.glaskarte {
  display: flex;
  flex-direction: column;
  padding: 2rem;
  border: 1px solid hsl(var(--foreground) / 0.1);
  background-color: hsl(var(--card));
}

.panel {
  padding: 2rem;
  border: 1px solid hsl(var(--foreground) / 0.15);
  background-color: hsl(var(--card));
}

.karte-text > * + * {
  margin-top: 1rem;
}

.icon-kachel {
  display: block;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0.625rem;
  background-color: hsl(var(--signal) / 0.1);
  color: hsl(var(--signal));
}

.icon-kachel svg {
  width: 100%;
  height: 100%;
}

/* Kennzahlen: sechs Kacheln, nie zwei allein in der letzten Reihe. */
.kennzahlen-raster {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1rem;
}

@media (min-width: 375px) {
  .kennzahlen-raster {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

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

@media (min-width: 1280px) {
  .kennzahlen-raster {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}

.kennzahl-kachel {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 1.5rem;
  border: 1px solid hsl(var(--foreground) / 0.1);
  background-color: hsl(var(--card));
}

.kennzahl-wert {
  font-size: 2.25rem;
  line-height: 1;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

.kennzahl-label {
  font-size: 0.75rem;
  line-height: 1.25;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: hsl(var(--muted-foreground));
}

@media (min-width: 768px) {
  .kennzahl-wert {
    font-size: 3rem;
  }
}

/* Adresse, Telefon, E-Mail mit Icon. */
.kontakt-liste {
  display: flex;
  flex-direction: column;
}

.kontakt-zeile {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  min-height: 2.75rem;
  padding-block: 0.5rem;
  font-size: 1rem;
  line-height: 1.625;
  color: hsl(var(--foreground-soft));
}

a.kontakt-zeile {
  width: fit-content;
  transition: color 300ms;
}

a.kontakt-zeile:hover {
  color: hsl(var(--signal));
}

.kontakt-zeile--umbruch {
  word-break: break-all;
}

.kontakt-icon {
  flex-shrink: 0;
  width: 1.25rem;
  height: 1.25rem;
  margin-top: 3px;
  color: hsl(var(--signal));
}

/* Lageplan mit zwei Markierungen. */
.lageplan {
  position: relative;
  overflow: hidden;
  border: 1px solid hsl(var(--foreground) / 0.1);
  background-color: hsl(var(--card));
}

.lageplan img {
  width: 100%;
  height: auto;
}

.lageplan-pin {
  position: absolute;
  width: 1rem;
  height: 1rem;
  margin: -0.5rem 0 0 -0.5rem;
  background-color: hsl(var(--accent));
  box-shadow: 0 0 0 6px hsl(var(--accent) / 0.3);
}

.lageplan-pin--lokschuppen {
  left: 67.2%;
  top: 61.7%;
}

.lageplan-pin--bahnhof {
  left: 32.7%;
  top: 38.1%;
  width: 0.75rem;
  height: 0.75rem;
  margin: -0.375rem 0 0 -0.375rem;
  background-color: hsl(var(--signal));
  box-shadow: 0 0 0 4px hsl(var(--signal) / 0.25);
}

.lageplan-label {
  position: absolute;
  left: 50%;
  bottom: 100%;
  margin-bottom: 0.75rem;
  transform: translateX(-50%);
  padding: 0.25rem 0.5rem;
  background-color: hsl(var(--accent));
  background-image: var(--verlauf-marke);
  font-size: 0.75rem;
  line-height: 1rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  white-space: nowrap;
  color: hsl(var(--accent-foreground));
}

.lageplan-label--neben {
  border: 1px solid hsl(var(--signal) / 0.6);
  background-color: hsl(var(--background) / 0.9);
  background-image: none;
  font-weight: 500;
  color: hsl(var(--foreground));
}

.lageplan-quelle {
  position: absolute;
  right: 0;
  bottom: 0;
  padding: 0.25rem 0.5rem;
  background-color: hsl(var(--background) / 0.85);
  font-size: 0.75rem;
  line-height: 1rem;
  color: hsl(var(--foreground-soft));
}

/* Häufige Fragen als aufklappbare Einträge. */
.faq-liste {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.faq-eintrag {
  border: 1px solid hsl(var(--foreground) / 0.1);
  background-color: hsl(var(--card));
  transition: border-color 300ms var(--ease-out);
}

.faq-eintrag[open] {
  border-color: hsl(var(--foreground) / 0.15);
}

.faq-frage {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.25rem 1.5rem;
  list-style: none;
  cursor: pointer;
  font-size: 1rem;
  line-height: 1.5rem;
  letter-spacing: 0.025em;
  text-transform: uppercase;
  color: hsl(var(--foreground));
  transition: color 300ms var(--ease-out);
}

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

.faq-frage:hover,
.faq-frage:hover .faq-pfeil {
  color: hsl(var(--signal));
}

.faq-pfeil {
  flex-shrink: 0;
  width: 1rem;
  height: 1rem;
  color: hsl(var(--muted-foreground));
  transition: transform 300ms;
}

.faq-eintrag[open] .faq-pfeil {
  transform: rotate(180deg);
}

.faq-antwort {
  padding: 0 1.5rem 1.5rem;
}

@media (min-width: 768px) {
  .faq-antwort {
    max-width: 66%;
  }
}

/* Download-Liste im Presse-Bereich. */
.download-zeile {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.75rem;
  border-top: 1px solid hsl(var(--border) / 0.4);
}

/* Die Spalte wird auf dem Tablet schmal: lange Wörter wie „Lokschuppen“ sauber trennen statt mitten im Wort brechen. */
.download-name {
  display: flex;
  flex-direction: column;
  min-width: 0;
  -webkit-hyphens: auto;
  hyphens: auto;
  hyphenate-limit-chars: 6 3 3;
}

.download-zeile > :last-child {
  flex-shrink: 0;
}

/* Kleine Kästchen, z. B. „8 Tage“. */
.chip-liste {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.chip {
  padding: 0.375rem 0.75rem;
  border: 1px solid hsl(var(--foreground) / 0.15);
  background-color: hsl(var(--background) / 0.4);
  font-size: 0.875rem;
  line-height: 1.25rem;
  font-variant-numeric: tabular-nums;
  color: hsl(var(--foreground-soft));
}

/* 10. Termine und Preise ------------------------------------------------------------------------------------------- */

/* Überschrift, Text und Knopf zum Ticketshop links, Preiskarte rechts (ab lg). */
.ticket-raster {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  align-items: start;
  gap: 2rem;
}

.ticket-raster > .abschnitt-kopf {
  margin-bottom: 0;
}

@media (min-width: 1024px) {
  .ticket-raster {
    grid-template-columns: minmax(0, 1fr) 26rem;
    gap: 4rem;
  }
}

.preis-kopf {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem 1rem;
}

.preis-wert {
  font-size: 3rem;
  line-height: 1;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  color: hsl(var(--foreground));
}

@media (min-width: 768px) {
  .preis-wert {
    font-size: 3.75rem;
  }
}

.preis-badge {
  padding: 0.25rem 0.5rem;
  background-color: hsl(var(--accent));
  background-image: var(--verlauf-marke);
  font-size: 0.75rem;
  line-height: 1rem;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: hsl(var(--accent-foreground));
}

.preis-liste {
  border-top: 1px solid hsl(var(--border) / 0.4);
}

.preis-zeile {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  padding-block: 0.75rem;
  border-bottom: 1px solid hsl(var(--border) / 0.4);
}

.preis-zeile > dt {
  font-size: 1rem;
  line-height: 1.5rem;
  color: hsl(var(--foreground));
}

.preis-zeile > dd {
  font-size: 1.125rem;
  line-height: 1.75rem;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  color: hsl(var(--foreground));
}

@media (min-width: 768px) {
  .preis-zeile > dd {
    font-size: 1.25rem;
  }
}

.preis-hinweis {
  display: block;
}

/* 11. Countdown ---------------------------------------------------------------------------------------------------- */

/* Vier Felder wie Kennzahlen, Ziffern im Verlauf. Ohne JavaScript bleibt nur das Datum. */
.countdown {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.countdown-titel,
.countdown-einheit {
  font-size: 0.75rem;
  line-height: 1rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: hsl(var(--foreground-soft));
}

.countdown-felder {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.countdown-feld {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.25rem;
  padding-block: 0.75rem;
  border: 1px solid hsl(var(--foreground) / 0.1);
  background-color: hsl(var(--background) / 0.4);
}

.countdown-zahl {
  font-size: 1.875rem;
  line-height: 1;
  font-weight: 700;
  font-variant-numeric: tabular-nums;
}

@media (min-width: 768px) {
  .countdown-zahl {
    font-size: 2.25rem;
    line-height: 2.5rem;
  }
}

.countdown-datum {
  font-size: 1rem;
  line-height: 1.5rem;
  color: hsl(var(--muted-foreground));
}

.countdown-fertig {
  display: none;
  font-size: 1.125rem;
  line-height: 1.75rem;
  font-weight: 700;
  color: hsl(var(--foreground));
}

html:not(.js) .countdown-laufend,
.countdown.ist-fertig .countdown-laufend {
  display: none;
}

.countdown.ist-fertig .countdown-fertig {
  display: block;
}

/* Bewegung angehalten: Stand steht still, ohne Sekunden. */
.countdown.ist-ruhig .countdown-felder {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.countdown.ist-ruhig .countdown-feld--sekunden {
  display: none;
}

/* 12. Abschluss-Band und Fußzeile ---------------------------------------------------------------------------------- */

.cta-band {
  position: relative;
  overflow: hidden;
  padding-top: 4rem;
  padding-bottom: clamp(9rem, 22vw, 15rem);
  background-color: hsl(var(--card));
}

@media (min-width: 768px) {
  .cta-band {
    padding-top: 6rem;
  }
}

/* Foto am unteren Rand, nach oben ausgeblendet. */
.cta-band-bild {
  position: absolute;
  inset: auto 0 0;
  width: 100%;
  height: 60%;
  object-fit: cover;
  opacity: 0.4;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, transparent 0%, #000 50%);
  mask-image: linear-gradient(to bottom, transparent 0%, #000 50%);
}

.cta-band-logo {
  width: 6rem;
  height: auto;
  margin-inline: auto;
}

@media (min-width: 768px) {
  .cta-band-logo {
    width: 8rem;
  }
}

.seitenfuss {
  padding-top: 4rem;
  padding-bottom: 3rem;
  border-top: 1px solid hsl(var(--border));
  background-color: hsl(var(--background));
}

@media (min-width: 768px) {
  .seitenfuss {
    padding-top: 6rem;
  }
}

/* Folgt die Fußzeile auf das Abschluss-Band, braucht sie keine Linie. */
.cta-band + .seitenfuss,
main:has(> .cta-band:last-child) + .seitenfuss {
  border-top-width: 0;
}

.fuss-block + .fuss-block {
  padding-top: 3rem;
}

.fuss-block:not(:last-child) {
  padding-bottom: 3rem;
  border-bottom: 1px solid hsl(var(--border) / 0.6);
}

.fuss-raster {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 3rem 1rem;
}

.fuss-marke {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

@media (min-width: 375px) {
  .fuss-raster {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .fuss-marke {
    grid-column: span 2;
  }
}

@media (min-width: 768px) {
  .fuss-raster {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 3rem;
  }

  .fuss-marke {
    grid-column: span 3;
  }
}

@media (min-width: 1024px) {
  .fuss-raster {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .fuss-marke {
    grid-column: span 2;
  }
}

.fuss-logo {
  display: flex;
  align-items: center;
  width: fit-content;
  min-height: 2.75rem;
}

.fuss-logo img {
  width: auto;
  height: 4rem;
  object-fit: contain;
}

.sozial-liste {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.sozial-link {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid hsl(var(--border));
  color: hsl(var(--muted-foreground));
  transition:
    color 300ms,
    background-color 300ms,
    border-color 300ms;
}

.sozial-link:hover {
  border-color: hsl(var(--accent));
  background-color: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
}

.sozial-link svg {
  width: 0.875rem;
  height: 0.875rem;
  fill: currentColor;
}

@media (min-width: 1024px) {
  .sozial-link {
    width: 2rem;
    height: 2rem;
  }
}

.fuss-titel {
  margin-bottom: 1.5rem;
  font-size: 0.75rem;
  line-height: 1rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  white-space: nowrap;
  color: hsl(var(--foreground));
}

.fuss-nav {
  display: flex;
  flex-direction: column;
  font-size: 1rem;
  line-height: 1.5rem;
  color: hsl(var(--muted-foreground));
}

.fuss-link {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  width: fit-content;
  min-height: 2.75rem;
  transition: color 300ms var(--ease-out);
}

.fuss-link:hover,
.fuss-link:focus-visible {
  color: hsl(var(--signal));
}

.fuss-link svg {
  flex-shrink: 0;
  width: 0.75rem;
  height: 0.75rem;
  color: hsl(var(--signal));
  transition: transform 300ms var(--ease-out);
}

.fuss-link:hover svg,
.fuss-link:focus-visible svg {
  transform: translateX(4px);
}

@media (min-width: 1024px) {
  .fuss-nav {
    gap: 0.5rem;
  }

  .fuss-link {
    min-height: 0;
  }
}

.fuss-unten {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  font-size: 0.875rem;
  line-height: 1.25rem;
  text-align: center;
  color: hsl(var(--muted-foreground));
}

.rechtliches {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.rechtliches a {
  display: inline-flex;
  align-items: center;
  min-height: 2.75rem;
  transition: color 150ms;
}

.rechtliches a:hover {
  color: hsl(var(--foreground));
}

@media (min-width: 768px) {
  .rechtliches {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    column-gap: 1.5rem;
  }
}

@media (min-width: 1024px) {
  .rechtliches a {
    min-height: 1.5rem;
  }
}

/* 13. Ticket-Leiste, „Nach oben“ und Barrierefreiheits-Menü -------------------------------------------------------- */

/* Leiste unten auf Handys. Unsichtbar auch für Tastatur und Screenreader, solange sie nicht eingeblendet ist. */
.ticket-leiste {
  position: fixed;
  inset: auto 0 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem var(--rand) calc(0.75rem + env(safe-area-inset-bottom));
  border-top: 1px solid hsl(var(--foreground) / 0.15);
  background-color: hsl(var(--background) / 0.9);
  -webkit-backdrop-filter: blur(12px);
  backdrop-filter: blur(12px);
  transform: translateY(110%);
  visibility: hidden;
  transition:
    transform 350ms var(--ease-out),
    visibility 0s linear 350ms;
}

.ticket-leiste.ist-sichtbar {
  transform: none;
  visibility: visible;
  transition:
    transform 350ms var(--ease-out),
    visibility 0s;
}

.ticket-leiste .btn-primary {
  flex-shrink: 0;
}

.ticket-leiste__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
  font-size: 0.875rem;
  line-height: 1.375;
  color: hsl(var(--foreground-soft));
}

.ticket-leiste__text strong {
  font-weight: 600;
  color: hsl(var(--foreground));
}

@media (min-width: 768px) {
  .ticket-leiste {
    display: none;
  }
}

.nach-oben,
.barrierefreiheit-icon {
  position: fixed;
  bottom: 1rem;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid;
  box-shadow: var(--schatten-mittel);
  transition:
    color 150ms,
    background-color 150ms,
    border-color 150ms;
}

.nach-oben {
  right: 1rem;
  border-color: hsl(var(--accent));
  background-color: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
}

.nach-oben:hover {
  border-color: hsl(var(--foreground));
  background-color: hsl(var(--accent-hover));
}

.nach-oben svg {
  width: 1.25rem;
  height: 1.25rem;
}

.barrierefreiheit-icon {
  left: 1rem;
  border-color: hsl(var(--border));
  background-color: hsl(var(--card));
  color: hsl(var(--foreground));
}

.barrierefreiheit-icon:hover {
  border-color: hsl(var(--foreground));
  background-color: hsl(var(--accent));
}

.barrierefreiheit-icon svg {
  width: 1.5rem;
  height: 1.5rem;
}

/* Liegt die Ticket-Leiste unten, rücken die runden Knöpfe darüber. */
@media (max-width: 767.98px) {
  html.mit-ticketleiste .barrierefreiheit-icon,
  html.mit-ticketleiste .nach-oben {
    bottom: 5.5rem;
  }
}

@media print {
  .barrierefreiheit-icon,
  .nach-oben,
  .ticket-leiste {
    display: none;
  }
}

.barrierefreiheit {
  position: fixed;
  inset: auto auto 1rem 1rem;
  width: min(26rem, calc(100vw - 2rem));
  max-height: calc(100dvh - 2rem);
  margin: 0;
  overflow: hidden;
  border: 1px solid hsl(var(--border));
  background-color: hsl(var(--background));
  color: hsl(var(--foreground));
  box-shadow: var(--schatten-gross);
}

.barrierefreiheit[open] {
  display: flex;
  flex-direction: column;
}

.barrierefreiheit::backdrop {
  background: rgb(0 0 0 / 0.3);
}

.barrierefreiheit__kopf {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.25rem 1.25rem;
  background-color: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
}

.barrierefreiheit__titel {
  font-size: 1.125rem;
  line-height: 1.75rem;
  text-transform: uppercase;
}

.barrierefreiheit__schliessen {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-right: -0.5rem;
  transition: background-color 150ms;
}

.barrierefreiheit__schliessen:hover {
  background-color: hsl(var(--accent-hover));
}

.barrierefreiheit__schliessen svg {
  width: 1.25rem;
  height: 1.25rem;
}

.barrierefreiheit__inhalt {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  overflow-x: hidden;
  overflow-y: auto;
  font-size: 0.875rem;
  line-height: 1.25rem;
  scrollbar-width: thin;
  scrollbar-gutter: stable;
}

.barrierefreiheit__gruppe {
  margin-bottom: 0.25rem;
  font-size: 0.75rem;
  line-height: 1rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: hsl(var(--muted-foreground));
}

.barrierefreiheit__zeile {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  min-height: 2.25rem;
}

.barrierefreiheit__block {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  margin-top: 0.25rem;
}

.barrierefreiheit__stufen {
  display: flex;
  align-items: center;
}

.barrierefreiheit__stufen button {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid hsl(var(--border));
  font-size: 1rem;
  line-height: 1.5rem;
  transition: background-color 150ms;
}

.barrierefreiheit__stufen output {
  width: 3.5rem;
  text-align: center;
}

.barrierefreiheit__auswahl {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.barrierefreiheit__auswahl button {
  min-height: 2.25rem;
  margin-left: -1px;
  border: 1px solid hsl(var(--border));
  transition: background-color 150ms;
}

.barrierefreiheit__auswahl button:first-child {
  margin-left: 0;
}

.barrierefreiheit__kacheln {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.375rem;
  margin-top: 0.25rem;
}

.barrierefreiheit__kacheln button,
.barrierefreiheit__breit {
  min-height: 2.25rem;
  padding-inline: 0.5rem;
  border: 1px solid hsl(var(--border));
  transition: background-color 150ms;
}

.barrierefreiheit__breit {
  padding-inline: 0.75rem;
}

.barrierefreiheit__stufen button:hover,
.barrierefreiheit__auswahl button:hover,
.barrierefreiheit__kacheln button:hover,
.barrierefreiheit__breit:hover {
  background-color: hsl(var(--card));
}

.barrierefreiheit__stufen button[aria-disabled='true'] {
  cursor: not-allowed;
  opacity: 0.4;
}

.barrierefreiheit__stufen button[aria-disabled='true']:hover {
  background-color: transparent;
}

.barrierefreiheit__auswahl button[aria-pressed='true'],
.barrierefreiheit__kacheln button[aria-pressed='true'] {
  border-color: hsl(var(--foreground));
  background-color: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
}

.barrierefreiheit__auswahl button[aria-pressed='true']:hover,
.barrierefreiheit__kacheln button[aria-pressed='true']:hover {
  background-color: hsl(var(--accent-hover));
}

.barrierefreiheit__fuss {
  display: flex;
  flex-direction: column;
  gap: 0.375rem;
  padding-top: 0.5rem;
  border-top: 1px solid hsl(var(--border));
}

.barrierefreiheit__link {
  align-self: center;
  font-size: 0.875rem;
  line-height: 1.25rem;
}

/* Schalter: Stellung auch über die Knopfposition erkennbar (WCAG 1.4.1). */
.schalter {
  position: relative;
  flex-shrink: 0;
  width: 3rem;
  height: 1.5rem;
  border: 1px solid hsl(var(--muted-foreground));
  background-color: transparent;
  transition: background-color 150ms;
}

.schalter::after {
  content: '';
  position: absolute;
  inset: -11px -1px;
}

.schalter__knopf {
  position: absolute;
  top: 3px;
  left: 3px;
  width: 1rem;
  height: 1rem;
  background-color: hsl(var(--foreground));
  transition: transform 150ms;
}

.schalter[aria-checked='true'] {
  border-color: hsl(var(--foreground));
  background-color: hsl(var(--accent));
}

.schalter[aria-checked='true'] .schalter__knopf {
  transform: translateX(1.5rem);
}

.lesemaske {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 60;
  height: 7rem;
  pointer-events: none;
  box-shadow: 0 0 0 100vmax rgb(0 0 0 / 0.7);
}

/* 14. Unterseiten -------------------------------------------------------------------------------------------------- */

.seiten-rahmen {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  background-color: hsl(var(--background));
}

/* Rechtstexte wie die Erklärung zur Barrierefreiheit. */
.rechtstext {
  flex: 1;
  width: 100%;
  max-width: 56rem;
  margin-inline: auto;
  padding: calc(5.85rem + 4rem) var(--rand) 4rem;
  color: hsl(var(--foreground));
}

.rechtstext > h1 {
  margin-bottom: 3rem;
}

.rechtstext-inhalt {
  max-width: var(--text-max);
  line-height: 1.625;
}

.rechtstext-inhalt > * + * {
  margin-top: 3rem;
}

.rechtstext h2 {
  margin-bottom: 1.5rem;
  font-size: 1.25rem;
  line-height: 1.75rem;
  text-transform: uppercase;
  scroll-margin-top: 8rem;
}

.rechtstext section > * + * {
  margin-top: 1rem;
}

.punktliste {
  padding-left: 1.5rem;
  list-style: disc;
}

.punktliste > * + * {
  margin-top: 0.5rem;
}

.punktliste li::marker {
  color: hsl(var(--muted-foreground));
}

@media (min-width: 768px) {
  .rechtstext {
    padding-top: calc(5.85rem + 6rem);
    padding-bottom: 6rem;
  }

  .rechtstext > h1 {
    margin-bottom: 4rem;
  }

  .rechtstext-inhalt > * + * {
    margin-top: 4rem;
  }

  .rechtstext h2 {
    font-size: 1.5rem;
    line-height: 2rem;
  }
}

/* Seite nicht gefunden. */
.fehlerseite {
  flex: 1;
  width: 100%;
  padding-top: calc(5.85rem + 4rem);
  padding-bottom: 4rem;
}

.fehler-code {
  margin-bottom: 3rem;
  font-size: 3.75rem;
  line-height: 1;
  color: hsl(var(--foreground));
}

@media (min-width: 768px) {
  .fehlerseite {
    padding-top: calc(5.85rem + 6rem);
    padding-bottom: 6rem;
  }

  .fehler-code {
    margin-bottom: 4rem;
    font-size: 6rem;
  }
}

/* 15. Animationen -------------------------------------------------------------------------------------------------- */

@keyframes kopfzeile-ein {
  from {
    transform: translateY(-100%);
    opacity: 0;
  }

  to {
    transform: translateY(0);
    opacity: 1;
  }
}

@keyframes einblenden-hoch {
  from {
    opacity: 0;
    transform: translateY(30px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

/* Hero: Titel und Karte blenden beim Laden ein. */
.einblenden {
  animation: einblenden-hoch 0.8s var(--ease-out) both;
}

.einblenden--spaeter {
  animation-delay: 0.3s;
}

/* Abschnitte blenden ein, sobald sie ins Bild kommen (script.js setzt .in-view). Ohne JavaScript ist alles sichtbar. */
.js [data-animate],
.js [data-animate-left],
.js [data-animate-right] {
  opacity: 0;
  transition:
    opacity 0.6s var(--ease-out),
    transform 0.6s var(--ease-out);
}

.js [data-animate] {
  transform: translateY(1.875rem);
}

.js [data-animate-left] {
  transform: translateX(-1.875rem);
}

.js [data-animate-right] {
  transform: translateX(1.875rem);
}

.js [data-animate].in-view,
.js [data-animate-left].in-view,
.js [data-animate-right].in-view {
  opacity: 1;
  transform: none;
}

[data-delay='1'] {
  transition-delay: 0.1s;
}

[data-delay='2'] {
  transition-delay: 0.2s;
}

[data-delay='3'] {
  transition-delay: 0.3s;
}

@media (prefers-reduced-motion: reduce) {
  .js [data-animate],
  .js [data-animate-left],
  .js [data-animate-right] {
    transform: none;
    transition: opacity 0.4s ease;
  }

  .einblenden {
    animation: none;
  }

  .btn-primary:active,
  .btn-secondary:active,
  .fuss-link:hover svg,
  .fuss-link:focus-visible svg {
    transform: none;
  }

  .ticket-leiste,
  .ticket-leiste.ist-sichtbar {
    transition: none;
  }
}

/* 16. Einstellungen aus dem Barrierefreiheits-Menü ----------------------------------------------------------------- */

html[data-schriftgroesse='90'] {
  font-size: 90%;
}

html[data-schriftgroesse='110'] {
  font-size: 110%;
}

html[data-schriftgroesse='125'] {
  font-size: 125%;
}

html[data-schriftgroesse='150'] {
  font-size: 150%;
}

html[data-zeilenhoehe='125'] {
  --zeilenfaktor: 1.25;
}

html[data-zeilenhoehe='150'] {
  --zeilenfaktor: 1.5;
}

html[data-zeilenhoehe='175'] {
  --zeilenfaktor: 1.75;
}

html[data-zeilenhoehe='200'] {
  --zeilenfaktor: 2;
}

html[data-zeilenhoehe] :is(p, li, dd, dt, label, blockquote, figcaption, td, th) {
  line-height: calc(1.6 * var(--zeilenfaktor)) !important;
}

html[data-zeilenhoehe] :is(h1, h2, h3, h4, h5, h6) {
  line-height: calc(1.2 * var(--zeilenfaktor)) !important;
}

html[data-lesbare-schrift] body,
html[data-lesbare-schrift] body * {
  font-family: Verdana, Arial, sans-serif !important;
  letter-spacing: 0.01em;
}

html[data-textausrichtung='links'] {
  --textausrichtung: left;
}

html[data-textausrichtung='mitte'] {
  --textausrichtung: center;
}

html[data-textausrichtung='rechts'] {
  --textausrichtung: right;
}

html[data-textausrichtung] main :is(h1, h2, h3, h4, h5, h6, p, li, dd, dt, blockquote) {
  text-align: var(--textausrichtung) !important;
}

html {
  --kontrast: 1;
  --graustufen: 0;
}

html[data-kontrast='75'] {
  --kontrast: 0.75;
}

html[data-kontrast='125'] {
  --kontrast: 1.25;
}

html[data-kontrast='150'] {
  --kontrast: 1.5;
}

html[data-kontrast='175'] {
  --kontrast: 1.75;
}

html[data-kontrast='200'] {
  --kontrast: 2;
}

html[data-graustufen] {
  --graustufen: 1;
}

html[data-kontrast],
html[data-graustufen] {
  filter: contrast(var(--kontrast)) grayscale(var(--graustufen));
}

/* Logos bleiben sichtbar. */
html[data-bilder-aus] img:not(.logo) {
  visibility: hidden;
}

html[data-motion='paused'] *,
html[data-motion='paused'] *::before,
html[data-motion='paused'] *::after {
  animation-duration: 0.001ms !important;
  animation-delay: 0s !important;
  animation-iteration-count: 1 !important;
  transition-duration: 0.001ms !important;
  transition-delay: 0s !important;
  scroll-behavior: auto !important;
}

html[data-links-hervorheben] a {
  outline: 2px solid hsl(var(--foreground));
  outline-offset: 2px;
  text-decoration: underline;
}

html[data-fokus-rahmen] :focus {
  outline: 3px solid hsl(var(--foreground)) !important;
  outline-offset: 3px !important;
}

html[data-seitenstruktur] :is(header, nav, main, footer, section) {
  outline: 1px dashed hsl(var(--muted-foreground));
  outline-offset: -1px;
}

html[data-seitenstruktur] main h1::before {
  content: 'H1';
}

html[data-seitenstruktur] main h2::before {
  content: 'H2';
}

html[data-seitenstruktur] main h3::before {
  content: 'H3';
}

html[data-seitenstruktur] main :is(h1, h2, h3)::before {
  display: inline-block;
  margin-inline-end: 0.5em;
  padding: 0.15em 0.4em;
  font-size: 0.75rem;
  font-weight: 700;
  line-height: 1;
  vertical-align: middle;
  background-color: hsl(var(--accent));
  color: hsl(var(--accent-foreground));
}
