:root{
  --nacht:#141B2D;--nacht-flaeche:#1F2A44;--papier:#F4F5F7;--papier-flaeche:#E3E6EC;
  --tinte:#141B2D;--weiss:#FFFFFF;--grau:#8C94A6;--akzent:#FFD23F;--richtig:#33D17A;--falsch:#FF4D4D;
  --fach:#3D8BFF;
  --fach-mathe:#3D8BFF;--fach-physik:#9B6BFF;--fach-chemie:#FF5FA2;--fach-biologie:#33D17A;--fach-sachkunde:#33D17A;--fach-deutsch:#FF6A4D;--fach-englisch:#22C7E5;--fach-fremdsprachen:#22C7E5;--fach-geschichte:#E8A44A;--fach-politik:#E8A44A;--fach-erdkunde:#21C3A6;--fach-musik:#FF9F43;--fach-kunst:#FF9F43;--fach-informatik:#5EF2C7;
  --schrift:"Montserrat",system-ui,sans-serif;
  --versalien-laufweite:0.08em;
  --easing:cubic-bezier(0.16, 1, 0.3, 1);
  --pop:350ms;--einschieben:450ms;--punch:280ms;--versatz:120ms;
  --punch-faktor:1.06;
  --radius:24px;--strich:5px;--strich-dick:10px;
  --figur-hoehe:460px;
}
@font-face{font-family:"Montserrat";font-weight:500;font-style:normal;font-display:swap;src:url("/fonts/montserrat-latin-500-normal.woff2") format("woff2");}
@font-face{font-family:"Montserrat";font-weight:700;font-style:normal;font-display:swap;src:url("/fonts/montserrat-latin-700-normal.woff2") format("woff2");}
@font-face{font-family:"Montserrat";font-weight:900;font-style:normal;font-display:swap;src:url("/fonts/montserrat-latin-900-normal.woff2") format("woff2");}
/* stil.css – Website schulpuls.com. Alle Farben, Schrift, Radien, Dauern und Easing kommen als
   CSS-Variablen aus theme.json (website\bauen.ts schreibt sie vor diese Datei). Hier stehen nur
   Layout und relative Verhältnisse – kein Hex-Wert, keine Millisekunde. */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  font-family: var(--schrift);
  font-weight: 500;
  line-height: 1.45;
  background: var(--hg);
  color: var(--text);
  --hg: var(--papier);
  --flaeche: var(--papier-flaeche);
  --text: var(--tinte);
  --kontur: var(--tinte);
  --leise: var(--grau);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
body.hg-nacht {
  --hg: var(--nacht);
  --flaeche: var(--nacht-flaeche);
  --text: var(--weiss);
  --kontur: var(--weiss);
}
main { flex: 1; width: min(100% - 2.5rem, 72rem); margin: 0 auto; padding-bottom: 6rem; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
h1, h2, h3 { font-weight: 900; line-height: 1.05; margin: 0 0 0.5em; letter-spacing: -0.01em; }
h1 { font-size: clamp(2rem, 5vw, 3.6rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2.1rem); }
h3 { font-size: 1.15rem; }
h2 small { font-weight: 700; font-size: 0.55em; color: var(--leise); margin-left: 0.5em; text-transform: uppercase; letter-spacing: var(--versalien-laufweite); }
p { margin: 0 0 1em; }
.akzent { color: var(--akzent); }
strong { font-weight: 700; }

.springen { position: absolute; left: -999px; top: 0; background: var(--akzent); color: var(--tinte); padding: 0.5rem 1rem; z-index: 100; }
.springen:focus { left: 1rem; }

/* Kopfzeile */
.kopf {
  width: min(100% - 2.5rem, 72rem);
  margin: 0 auto;
  padding: 1rem 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}
.marke img { width: clamp(150px, 22vw, 220px); height: auto; }
.nav { display: flex; gap: 0.25rem; flex-wrap: wrap; align-items: center; }
.nav a {
  text-decoration: none;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: var(--versalien-laufweite);
  font-size: 0.8rem;
  padding: 0.55rem 0.85rem;
  border-radius: 999px;
  transition: background var(--pop) var(--easing), transform var(--pop) var(--easing);
}
.nav a:hover, .nav a[aria-current] { background: var(--flaeche); transform: translateY(-2px); }
.nav .nav-youtube { color: var(--falsch); }
.nav .nav-spotify { color: var(--richtig); }

/* Knöpfe und Chips */
.knoepfe { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-top: 1.5rem; }
.knopf {
  display: inline-flex; align-items: center; gap: 0.5rem;
  text-decoration: none; font-weight: 900; text-transform: uppercase; letter-spacing: var(--versalien-laufweite);
  font-size: 0.85rem; padding: 0.9rem 1.4rem; border-radius: 999px;
  border: var(--strich) solid transparent;
  transition: transform var(--pop) var(--easing), box-shadow var(--pop) var(--easing);
}
.knopf:hover { transform: translateY(-3px) scale(1.03); }
.knopf:active { transform: scale(0.97); }
.knopf-primaer { background: var(--akzent); color: var(--tinte); }
.knopf-sekundaer { background: transparent; color: var(--text); border-color: var(--kontur); }
.knopf-youtube { background: var(--falsch); color: var(--weiss); }
.knopf-spotify { background: var(--richtig); color: var(--tinte); }
.knopf-pdf { background: var(--fach); color: var(--weiss); }
.knopf-leise { background: transparent; color: var(--richtig); border-color: var(--richtig); }
.knopf-aus { background: var(--flaeche); color: var(--leise); cursor: default; }
.knopf-aus:hover { transform: none; }
.knopf-youtube::before { content: ""; width: 0; height: 0; border-left: 0.7em solid currentColor; border-top: 0.42em solid transparent; border-bottom: 0.42em solid transparent; }
.knopf-pdf::before { content: ""; width: 0.8em; height: 1em; border: 2px solid currentColor; border-radius: 2px; }
.chip {
  display: inline-block; padding: 0.3rem 0.7rem; border-radius: 999px; font-size: 0.72rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: var(--versalien-laufweite); background: var(--flaeche); color: var(--text);
}
.chip-fach { background: var(--fach); color: var(--weiss); }
.chip-leise { background: transparent; border: 2px solid var(--flaeche); color: var(--leise); }
.status { position: absolute; right: 0.6rem; top: 0.6rem; font-size: 0.65rem; font-weight: 900; text-transform: uppercase; letter-spacing: var(--versalien-laufweite); padding: 0.25rem 0.55rem; border-radius: 999px; }
.status-da { background: var(--richtig); color: var(--tinte); }
.status-kommt { background: var(--flaeche); color: var(--leise); }

/* Held (Startseite) */
.held { display: grid; gap: 2rem; align-items: center; padding: 2rem 0 1rem; }
.held-text h1 { font-size: clamp(2.4rem, 6vw, 4.5rem); }
/* Auf Papier trägt das Gelb nicht – die zweite Zeile nimmt das Blau der Wortmarke. */
.hg-papier .held-text .akzent { color: var(--fach); }
.held-satz { font-size: clamp(1.05rem, 2vw, 1.3rem); max-width: 36rem; }
.held-bild { position: relative; background: var(--band-hg); border-radius: var(--radius); overflow: hidden; }
.held-bild::before {
  content: ""; position: absolute; left: 0; right: 0; top: var(--puls-y); height: var(--puls-staerke);
  background: var(--akzent); transform: translateY(-50%);
}
.held-bild img { position: relative; width: 100%; }
@media (min-width: 900px) { .held { grid-template-columns: 1.1fr 1fr; } }

/* Abschnitte */
section { margin: 3.5rem 0; }
.seite-kopf { margin-top: 1.5rem; }
.unterzeile { font-size: 1.1rem; max-width: 44rem; color: var(--text); opacity: 0.85; }
.brotkrumen { font-size: 0.8rem; font-weight: 700; text-transform: uppercase; letter-spacing: var(--versalien-laufweite); color: var(--leise); }
.brotkrumen a { text-decoration: none; }
.brotkrumen a:hover { color: var(--text); }

.schritte { list-style: none; padding: 0; margin: 0; display: grid; gap: 1.25rem; }
.schritte li { background: var(--flaeche); border-radius: var(--radius); padding: 1.5rem; position: relative; }
.schritte strong { display: block; font-size: 1.2rem; font-weight: 900; margin: 0.5rem 0 0.4rem; }
.schritte p { margin: 0; }
.schritt-nr { display: inline-grid; place-items: center; width: 2.4rem; height: 2.4rem; border-radius: 50%; background: var(--akzent); color: var(--tinte); font-weight: 900; font-size: 1.2rem; }
@media (min-width: 720px) { .schritte { grid-template-columns: repeat(3, 1fr); } }

/* Klassen und Fächer */
.klassen-raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(7.5rem, 1fr)); gap: 0.75rem; }
.klasse-kachel {
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.15rem;
  padding: 1.1rem 0.5rem; border-radius: var(--radius); text-decoration: none; text-align: center;
  border: var(--strich) solid var(--kontur);
  transition: transform var(--pop) var(--easing), box-shadow var(--pop) var(--easing);
}
.klasse-kachel.hg-papier { background: var(--papier); color: var(--tinte); border-color: var(--tinte); }
.klasse-kachel.hg-nacht { background: var(--nacht); color: var(--weiss); border-color: var(--nacht-flaeche); }
a.klasse-kachel:hover { transform: translateY(-4px) rotate(-1.5deg); box-shadow: 0 0.6rem 0 var(--akzent); }
.klasse-zahl { font-size: 2rem; font-weight: 900; line-height: 1; }
.klasse-kachel span:not(.klasse-zahl) { font-size: 0.75rem; font-weight: 700; text-transform: uppercase; letter-spacing: var(--versalien-laufweite); }
.klasse-kachel small { font-size: 0.7rem; opacity: 0.7; }
.klasse-kommt { opacity: 0.45; border-style: dashed; }

.faecher-raster { display: grid; grid-template-columns: repeat(auto-fill, minmax(11rem, 1fr)); gap: 0.75rem; }
.fach-kachel {
  background: var(--fach); color: var(--weiss); text-decoration: none; border-radius: var(--radius);
  padding: 1.4rem 1.2rem; display: flex; flex-direction: column; gap: 0.2rem;
  transition: transform var(--pop) var(--easing);
}
.fach-kachel strong { font-size: 1.3rem; font-weight: 900; }
.fach-kachel small { opacity: 0.85; font-weight: 700; }
.fach-kachel:hover { transform: translateY(-4px) scale(1.02); }
.fach-sprung { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-top: 1rem; }
.fach-sprung a { text-decoration: none; font-weight: 900; font-size: 0.8rem; text-transform: uppercase; letter-spacing: var(--versalien-laufweite); padding: 0.5rem 0.9rem; border-radius: 999px; background: var(--fach); color: var(--weiss); }

.fach-abschnitt { border-left: var(--strich-dick) solid var(--fach); padding-left: 1.25rem; margin: 2.5rem 0; }
.fach-abschnitt h2 a { text-decoration: none; }
.bereich { color: var(--leise); text-transform: uppercase; letter-spacing: var(--versalien-laufweite); font-size: 0.8rem; margin: 1.5rem 0 0.5rem; }
.themen-liste { list-style: none; padding: 0; margin: 0; display: grid; gap: 0.35rem; }
.themen-liste a {
  display: grid; grid-template-columns: 3rem 1fr auto; align-items: center; gap: 0.75rem;
  text-decoration: none; background: var(--flaeche); border-radius: calc(var(--radius) / 2); padding: 0.7rem 0.9rem;
  transition: transform var(--pop) var(--easing), background var(--pop) var(--easing);
}
.themen-liste a:hover { transform: translateX(6px); }
.themen-liste .nr { font-weight: 900; color: var(--fach); font-size: 0.85rem; }
.themen-liste .titel { font-weight: 700; }
.themen-liste .status { position: static; }

/* Karten */
.karten { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 1rem; }
.karte {
  text-decoration: none; border-radius: var(--radius); overflow: hidden; background: var(--flaeche);
  display: flex; flex-direction: column; border: var(--strich) solid transparent;
  transition: transform var(--pop) var(--easing), border-color var(--pop) var(--easing);
}
.karte:hover { transform: translateY(-5px); border-color: var(--fach); }
.karte-bild { position: relative; aspect-ratio: 16 / 9; background: var(--nacht); overflow: hidden; }
.karte-bild img { width: 100%; height: 100%; object-fit: cover; }
.karte-platzhalter, .video-platzhalter {
  width: 100%; height: 100%; display: grid; place-items: center; text-align: center; padding: 1rem;
  background: var(--nacht); color: var(--weiss); border-left: var(--strich-dick) solid var(--fach);
}
.karte-platzhalter b, .video-platzhalter b { display: block; font-weight: 900; font-size: 1.1rem; line-height: 1.1; }
.video-platzhalter b { font-size: clamp(1.4rem, 4vw, 2.8rem); }
.karte-text { padding: 0.9rem 1rem 1.1rem; display: flex; flex-direction: column; gap: 0.25rem; }
.karte-meta { font-size: 0.7rem; font-weight: 700; text-transform: uppercase; letter-spacing: var(--versalien-laufweite); color: var(--fach); }
.karte-text strong { font-weight: 700; line-height: 1.25; }

/* Themenseite */
.thema { max-width: 56rem; margin: 1.5rem auto 0; }
.thema-meta { display: flex; gap: 0.4rem; flex-wrap: wrap; margin-bottom: 1.5rem; }
.video {
  position: relative; aspect-ratio: 16 / 9; border-radius: var(--radius); overflow: hidden; background: var(--nacht);
  border: var(--strich) solid var(--flaeche);
}
.video img { width: 100%; height: 100%; object-fit: cover; }
.video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.abspielen {
  position: absolute; inset: 0; width: 100%; height: 100%; background: transparent; border: 0; cursor: pointer;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 0.6rem; color: var(--weiss);
  font-family: inherit; font-weight: 900; text-transform: uppercase; letter-spacing: var(--versalien-laufweite);
}
.abspielen-icon {
  width: 5.5rem; height: 5.5rem; border-radius: 50%; background: var(--akzent); display: grid; place-items: center;
  transition: transform var(--pop) var(--easing);
}
.abspielen-icon::after { content: ""; margin-left: 0.4rem; border-left: 2rem solid var(--tinte); border-top: 1.2rem solid transparent; border-bottom: 1.2rem solid transparent; }
.abspielen:hover .abspielen-icon { transform: scale(1.12); }
.abspielen-text { background: rgba(0, 0, 0, 0.45); padding: 0.3rem 0.8rem; border-radius: 999px; font-size: 0.8rem; }
.video-hinweis { position: absolute; left: 0; right: 0; bottom: 0; margin: 0; padding: 0.5rem 1rem; font-size: 0.7rem; color: var(--weiss); background: linear-gradient(transparent, rgba(0, 0, 0, 0.6)); pointer-events: none; }
.video-hinweis a { pointer-events: auto; }
.video-kommt { aspect-ratio: auto; }
.video-kommt .video-platzhalter { aspect-ratio: 16 / 9; }
.video-kommt-text { margin: 0; padding: 0.9rem 1.2rem; background: var(--flaeche); font-weight: 700; }
.thema-links { display: flex; gap: 0.75rem; flex-wrap: wrap; margin: 1.25rem 0 2rem; }
.thema-text { margin: 2rem 0; font-size: 1.1rem; }
.karte-eltern, .karte-uebung { background: var(--flaeche); border-radius: var(--radius); padding: 1.5rem; margin: 1.5rem 0; border-left: var(--strich-dick) solid var(--akzent); }
.karte-eltern h2, .karte-uebung h2 { font-size: 0.85rem; text-transform: uppercase; letter-spacing: var(--versalien-laufweite); color: var(--leise); }
.karte-eltern .frage, .karte-uebung .frage { font-weight: 900; font-size: 1.25rem; line-height: 1.2; }
.weiter .karte { max-width: 22rem; }

/* App-Teaser */
.app-teaser { background: var(--nacht); color: var(--weiss); border-radius: var(--radius); padding: clamp(1.5rem, 4vw, 3rem); }
.app-teaser .chip { background: var(--akzent); color: var(--tinte); }
.app-teaser .knopf-sekundaer { color: var(--weiss); border-color: var(--weiss); }
.app-teaser p { max-width: 40rem; }

/* Rechtliches */
.recht { max-width: 46rem; margin: 1.5rem auto 0; }
.recht h2 { font-size: 1.15rem; margin-top: 2rem; }
.vierhundertvier { text-align: center; padding-top: 3rem; }
.vierhundertvier .zahl { font-size: clamp(5rem, 20vw, 12rem); font-weight: 900; line-height: 1; color: var(--akzent); margin: 0; }
.vierhundertvier .knoepfe { justify-content: center; }

/* Fußzeile */
.fuss { background: var(--nacht); color: var(--weiss); margin-top: 3rem; position: relative; }
.fuss-innen { width: min(100% - 2.5rem, 72rem); margin: 0 auto; padding: 3rem 0 4rem; display: grid; gap: 2rem; }
.fuss-spalte { display: flex; flex-direction: column; gap: 0.4rem; }
.fuss-spalte a { text-decoration: none; opacity: 0.85; }
.fuss-spalte a:hover { opacity: 1; text-decoration: underline; }
.fuss h3 { font-size: 0.8rem; text-transform: uppercase; letter-spacing: var(--versalien-laufweite); color: var(--akzent); }
.fuss-logo { width: 11rem; }
.fuss-klein { font-size: 0.85rem; opacity: 0.7; }
.puls { height: var(--strich); background: var(--akzent); }
@media (min-width: 720px) { .fuss-innen { grid-template-columns: 2fr 1fr 1fr; } }

/* Figur: sitzt unten rechts, läuft am unteren Rand entlang; Größe je Stufe relativ zur Bühnenhöhe */
#figur { position: fixed; left: 0; bottom: 0; z-index: 50; pointer-events: none; }
#figur svg { overflow: visible; display: block; will-change: transform; }
#figur .figur-treffer { pointer-events: auto; cursor: pointer; }
@media print { #figur { display: none; } }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}

/* Auftritt per Feder: Karten und Kacheln poppen gestaffelt herein (höchstens drei zugleich, Versatz aus theme.json) */
@keyframes pop { from { opacity: 0; transform: scale(0.6) translateY(1rem); } to { opacity: 1; transform: none; } }
.pop { animation: pop var(--pop) var(--easing) both; animation-delay: calc(var(--versatz) * var(--i, 0)); }
