/* Halbzeitathlet – Stylesheet (Handy zuerst, ab 700px größer) */

/* Schriften lokal – keine Verbindung zu Google */
@font-face { font-family: "Nunito"; font-weight: 600; font-style: normal; font-display: swap;
  src: url("../fonts/nunito-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Nunito"; font-weight: 800; font-style: normal; font-display: swap;
  src: url("../fonts/nunito-latin-800-normal.woff2") format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-weight: 400; font-style: normal; font-display: swap;
  src: url("../fonts/source-sans-3-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Source Sans 3"; font-weight: 600; font-style: normal; font-display: swap;
  src: url("../fonts/source-sans-3-latin-600-normal.woff2") format("woff2"); }

:root {
  --petrol: #1F5C63;
  --petrol-dunkel: #174A50;
  --anthrazit: #2E3133;
  --leinen: #F4F0E8;
  --ocker: #B9853F;        /* nur Linien und Flächen */
  --ocker-text: #8A5F22;   /* dunkler, damit Text auf Leinen lesbar ist */
  --linie: #D9D3C7;
  --grau-text: #4A4F52;
  --spalte: 760px;
}

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

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--leinen);
  color: var(--anthrazit);
  font-family: "Source Sans 3", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 18px;
  line-height: 1.7;
}

a { color: var(--petrol); }
a:hover { color: var(--petrol-dunkel); }
:focus-visible { outline: 3px solid var(--ocker); outline-offset: 3px; border-radius: 4px; }

h1, h2, h3 { font-family: "Nunito", system-ui, sans-serif; font-weight: 800; color: var(--petrol); margin: 0; line-height: 1.15; }
p { margin: 0; }

.sprunglink { position: absolute; left: -9999px; top: 0; background: var(--petrol); color: var(--leinen); padding: 12px 16px; z-index: 10; }
.sprunglink:focus { left: 16px; top: 16px; }

.leiste { height: 8px; background: var(--petrol); }

.spalte { max-width: var(--spalte); margin: 0 auto; padding-left: 20px; padding-right: 20px; }

/* Kopf */
.kopf { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 16px; padding-top: 16px; padding-bottom: 16px; }
.marke { font-family: "Nunito", sans-serif; font-weight: 800; font-size: 22px; color: var(--petrol); text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }
.marke span { color: var(--ocker-text); }
.navi { display: flex; flex-wrap: wrap; gap: 4px 18px; font-weight: 600; font-size: 16px; }
.navi a { text-decoration: none; min-height: 44px; display: inline-flex; align-items: center; }

/* Abschnitte */
.abschnitt { padding-top: 48px; padding-bottom: 56px; display: flex; flex-direction: column; gap: 20px; }
.abschnitt + .abschnitt { border-top: 1px solid var(--linie); }

.anpfiff { align-items: center; text-align: center; padding-top: 32px; }
.figur { width: 136px; height: 136px; border-radius: 50%; background: var(--petrol); display: flex; align-items: center; justify-content: center; }
.figur svg { width: 94px; height: auto; }
.dachzeile { font-weight: 600; color: var(--ocker-text); letter-spacing: 0.06em; text-transform: uppercase; font-size: 14px; }
.anpfiff h1 { font-size: 36px; }
.unterzeile { font-family: "Nunito", sans-serif; font-weight: 600; font-size: 20px; line-height: 1.4; }
h2 { font-size: 30px; }

/* Knöpfe */
.knopf { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: 0 24px; border-radius: 999px; font-weight: 600; text-decoration: none; font-size: 17px; font-family: inherit; cursor: pointer; }
.knopf--voll { background: var(--petrol); color: var(--leinen); border: 0; }
.knopf--voll:hover { background: var(--petrol-dunkel); color: var(--leinen); }
.knopf--rand { border: 2px solid var(--petrol); color: var(--petrol); background: transparent; }
.knopf--rand:hover { background: var(--petrol); color: var(--leinen); }
.knopfreihe { display: flex; flex-wrap: wrap; gap: 12px; }

/* Spieltag-Liste */
.spieltage { list-style: none; margin: 0; padding: 0; }
.spieltag { border-bottom: 1px solid var(--linie); padding: 16px 0; }
.spieltag__zeile { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 16px; }
.spieltag__nr { width: 64px; display: flex; flex-direction: column; align-items: center; color: var(--petrol); line-height: 1.1; flex: none; }
.spieltag__nr small { font-size: 11px; font-weight: 600; text-transform: uppercase; letter-spacing: 0.06em; }
.spieltag__nr b { font-family: "Nunito", sans-serif; font-weight: 800; font-size: 28px; }
.spieltag__titel { flex: 1 1 180px; font-family: "Nunito", sans-serif; font-weight: 800; font-size: 19px; line-height: 1.3; }
.spieltag__info { color: var(--grau-text); font-size: 15px; }
.spieltag__info--bald { color: var(--ocker-text); font-weight: 600; }

/* Video erst nach Klick */
.video { margin-top: 14px; }
.video__vorschau { position: relative; aspect-ratio: 16 / 9; background: var(--anthrazit); color: var(--leinen); border-radius: 12px; padding: 20px; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; text-align: center; font-size: 15px; line-height: 1.5; }
.video__vorschau p { max-width: 460px; }
.video__vorschau a { color: var(--leinen); }
.video iframe { width: 100%; aspect-ratio: 16 / 9; border: 0; border-radius: 12px; display: block; }

/* Lieblingsgedicht */
.gedicht { margin: 8px 0; padding-block: 20px; padding-left: 20px; border-left: 3px solid var(--ocker); }
.gedicht blockquote { margin: 0; white-space: pre-line; font-family: "Nunito", sans-serif; font-weight: 600; font-size: 19px; line-height: 1.55; color: var(--petrol); }
.gedicht figcaption { margin-top: 12px; font-size: 15px; color: var(--grau-text); }

/* Fuß */
.fuss { background: var(--petrol); color: var(--leinen); padding: 20px 0; font-size: 15px; }
.fuss .spalte { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 8px 16px; }
.fuss nav { display: flex; gap: 20px; }
.fuss a { color: var(--leinen); min-height: 44px; display: inline-flex; align-items: center; }

/* Rechtliche Seiten */
.recht { padding-top: 32px; padding-bottom: 64px; }
.recht h1 { font-size: 32px; margin-bottom: 24px; }
.recht h2 { font-size: 22px; margin: 32px 0 8px; }
.recht p, .recht ul { margin: 0 0 12px; }
.platzhalter { background: #FBE9C8; padding: 0 4px; border-radius: 3px; }
.hinweis { border: 2px dashed var(--ocker); border-radius: 10px; padding: 12px 16px; margin-bottom: 24px; font-size: 16px; }

/* Aufstellung – Spielerpässe an Bändern (eigener Nachbau, kein fremder Code) */
.aufstellung__hinweis { font-size: 15px; color: var(--grau-text); margin-top: -8px; }
.paesse {
  list-style: none; margin: 0 -20px; padding: 0 20px 28px;
  display: flex; gap: 16px;
  overflow-x: auto; scroll-snap-type: x mandatory; scroll-padding-inline: 20px;
  -webkit-overflow-scrolling: touch; scrollbar-width: none;
}
.paesse::-webkit-scrollbar { display: none; }
.pass { flex: 0 0 62%; max-width: 240px; scroll-snap-align: start; position: relative; padding-top: 6px; }
/* Stange, an der die Bänder hängen */
.pass::before { content: ""; position: absolute; top: 0; left: -8px; right: -8px; height: 6px; background: var(--anthrazit); }
.pass:first-child::before { left: 0; border-radius: 3px 0 0 3px; }
.pass:last-child::before { right: 0; border-radius: 0 3px 3px 0; }

.pass--petrol    { --band: var(--petrol);     --band-text: var(--leinen); }
.pass--ocker     { --band: var(--ocker);      --band-text: var(--anthrazit); }
.pass--anthrazit { --band: var(--anthrazit);  --band-text: var(--leinen); }
.pass--streifen  { --band: var(--petrol-dunkel); --band-text: var(--leinen); }

.pass__haenger { transform-origin: 50% 0; display: flex; flex-direction: column; align-items: center; }
.pass__band { display: block; width: 14px; height: 48px; background: var(--band); position: relative; }
.pass--streifen .pass__band { background: linear-gradient(90deg, var(--petrol-dunkel) 0 5px, var(--ocker) 5px 9px, var(--petrol-dunkel) 9px); }
/* Metallclip */
.pass__band::after { content: ""; position: absolute; left: 50%; bottom: -10px; width: 22px; height: 14px; transform: translateX(-50%); border: 3px solid #8C9093; border-radius: 4px; background: var(--leinen); }

.pass__karte {
  display: block; width: 100%; aspect-ratio: 5 / 7; margin-top: 4px; padding: 0;
  border: 0; background: none; font: inherit; color: inherit; cursor: pointer;
  perspective: 900px; -webkit-tap-highlight-color: transparent; border-radius: 14px;
}
.pass__innen { position: relative; display: block; width: 100%; height: 100%; transform-style: preserve-3d; transition: transform 0.6s cubic-bezier(.3,.7,.3,1); }
.pass__karte[aria-pressed="true"] .pass__innen { transform: rotateY(180deg); }

.pass__seite {
  position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center;
  border-radius: 14px; overflow: hidden; text-align: center;
  -webkit-backface-visibility: hidden; backface-visibility: hidden;
  box-shadow: 0 1px 0 rgba(46,49,51,.08), 0 10px 22px -12px rgba(46,49,51,.45);
}
.pass__vorne { background: #FBF9F4; border: 1px solid var(--linie); padding-bottom: 14px; }
.pass__hinten { background: var(--band); color: var(--band-text); transform: rotateY(180deg); justify-content: center; gap: 14px; padding: 20px 16px; }

.pass__kopf { align-self: stretch; display: flex; justify-content: space-between; padding: 14px 14px 10px; background: var(--band); color: var(--band-text); font-size: 11px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; line-height: 1; }
.pass__symbol { margin: auto 0 10px; width: 76px; height: 76px; border-radius: 50%; background: var(--leinen); border: 2px solid var(--linie); display: flex; align-items: center; justify-content: center; color: var(--petrol); }
.pass__symbol svg { width: 44px; height: 44px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.pass__thema { font-size: 12px; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: var(--grau-text); }
.pass__hinten .pass__thema { color: inherit; opacity: .85; }
.pass__wort { font-family: "Nunito", sans-serif; font-weight: 800; font-size: 26px; line-height: 1.15; color: var(--petrol); margin-bottom: auto; }
.pass__tipp { font-size: 12px; color: var(--ocker-text); font-weight: 600; }
.pass__tipp::before { content: "↻ "; }
.pass__punkte { display: flex; flex-direction: column; gap: 8px; align-items: center; }
.pass__punkt { font-family: "Nunito", sans-serif; font-weight: 800; font-size: 20px; line-height: 1.2; }
.pass__punkt + .pass__punkt::before { content: ""; display: block; width: 18px; height: 2px; margin: 0 auto 8px; background: currentColor; opacity: .35; }

.pass__karte:focus-visible { outline: 3px solid var(--ocker); outline-offset: 4px; }

/* Gedämpftes Schwingen – nur nach Antippen oder Mauszeiger, nie von selbst */
@keyframes pass-schwingen {
  0% { transform: rotate(0); } 18% { transform: rotate(4deg); } 38% { transform: rotate(-2.4deg); }
  58% { transform: rotate(1.2deg); } 78% { transform: rotate(-.5deg); } 100% { transform: rotate(0); }
}
@keyframes pass-wippen {
  0% { transform: rotate(0); } 30% { transform: rotate(1.6deg); } 65% { transform: rotate(-.8deg); } 100% { transform: rotate(0); }
}
.pass__haenger.schwingt { animation: pass-schwingen 1.3s ease-out; }
.pass__haenger.wippt { animation: pass-wippen .9s ease-out; }

@media (prefers-reduced-motion: reduce) {
  .pass__haenger.schwingt, .pass__haenger.wippt { animation: none; }
  .pass__innen { transition: none; }
}

@media (min-width: 700px) {
  .aufstellung__wischen { display: none; }
  .paesse { margin: 0; padding: 0 0 28px; overflow: visible; display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px; }
  .pass { max-width: none; }
  .pass__wort { font-size: 24px; }
  .pass__punkt { font-size: 19px; }
}

/* ===== Sternenbahn (3D-Fassung) ===== */
html { background: var(--leinen); }
body { position: relative; z-index: 0; }
.himmel { display: none; }
html.js .himmel { display: block; position: absolute; left: 0; right: 0; top: 0; z-index: -2; pointer-events: none;
  background: linear-gradient(180deg, var(--leinen) 0%, var(--leinen) 38%, #EADFCB 58%, #1F5C63 72%, #123A3F 88%, #0B2427 100%); }
html.js body { background: transparent; }
#szene { position: fixed; inset: 0; width: 100%; height: 100%; z-index: -1; pointer-events: none; display: block; }

/* Nachspielzeit bei Nacht */
.nachspielzeit { position: relative; color: var(--leinen); border-top-color: rgba(244,240,232,.18) !important; }
html:not(.js) .nachspielzeit { background: linear-gradient(180deg, #1F5C63, #0B2427); max-width: none; }
.nachspielzeit h2 { color: var(--leinen); }
.nachspielzeit a { color: var(--leinen); }
.nachspielzeit a:hover { color: #EBC892; }
.nachspielzeit .gedicht { border-left-color: #EBC892; }
.nachspielzeit .gedicht blockquote { color: #EBC892; }
.nachspielzeit .gedicht figcaption { color: #D9D3C7; }
.unendlich { display: none; }
html.ohne-3d .unendlich, html:not(.js) .unendlich { display: block; position: absolute; right: 20px; top: 40px; width: 120px; height: auto; fill: none; stroke: #EBC892; stroke-width: 1.6; stroke-dasharray: 2 5; stroke-linecap: round; opacity: .7; }
html.js .fuss { background: transparent; border-top: 1px solid rgba(244,240,232,.18); }

/* Spieluhr und Pause-Knopf unten rechts */
.anzeige { display: none; }
html.js .anzeige { display: flex; position: fixed; right: 14px; bottom: 14px; z-index: 5; align-items: center; gap: 6px;
  padding: 4px 4px 4px 14px; border-radius: 999px; background: rgba(46,49,51,.88); color: var(--leinen);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); box-shadow: 0 8px 20px -10px rgba(0,0,0,.5); }
.anzeige__uhr { display: inline-flex; align-items: center; gap: 8px; font-family: "Nunito", sans-serif; font-weight: 800; font-size: 15px; min-width: 52px; font-variant-numeric: tabular-nums; }
.anzeige__punkt { width: 8px; height: 8px; border-radius: 50%; background: #EBC892; }
.anzeige__pause { width: 40px; height: 40px; border-radius: 50%; border: 0; background: transparent; color: var(--leinen); cursor: pointer; display: inline-flex; align-items: center; justify-content: center; }
.anzeige__pause:hover { background: rgba(244,240,232,.12); }
.anzeige__pause[hidden] { display: none; }
.anzeige__pause svg { width: 20px; height: 20px; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; fill: none; }
.anzeige__pause .symbol-weiter { display: none; fill: currentColor; stroke: none; }
.anzeige__pause[aria-pressed="true"] .symbol-pause { display: none; }
.anzeige__pause[aria-pressed="true"] .symbol-weiter { display: block; }
html.js .anzeige:has(.anzeige__pause[hidden]) { padding-right: 14px; min-height: 40px; }
.fuss { padding-bottom: 72px; }

/* Größere Bildschirme */
@media (min-width: 700px) {
  body { font-size: 19px; }
  .spalte { padding-left: 24px; padding-right: 24px; }
  .marke { font-size: 24px; }
  .navi { gap: 24px; }
  .abschnitt { padding-top: 64px; padding-bottom: 80px; gap: 24px; }
  .anpfiff { padding-top: 56px; }
  .figur { width: 168px; height: 168px; }
  .figur svg { width: 116px; }
  .anpfiff h1 { font-size: 52px; }
  .unterzeile { font-size: 22px; }
  h2 { font-size: 36px; }
  .spieltag__nr { width: 72px; }
  .spieltag__nr b { font-size: 32px; }
  .spieltag__titel { font-size: 21px; }
  .recht h1 { font-size: 40px; }
}
