/* nikolausi.net – statische Version */
:root {
  --paper: #f8f3ea;
  --paper-2: #efe6d6;
  --ink: #2a211a;
  --ink-soft: #6b5d50;
  --red: #a3161b;
  --red-dark: #7a0f13;
  --pine: #1e4a39;
  --gold: #c6a03a;
  --line: #dccfb9;
  --card: #fffdf8;
  --radius: 10px;
  --serif: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, serif;
  --sans: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: #e00 url("hintergrund-2fc467be.jpg") center top / 1600px auto repeat fixed;
  color: var(--ink);
  font: 17px/1.6 var(--sans);
}
/* Inhalt auf hellem Panel, damit er auf dem Schneeflocken-Hintergrund lesbar bleibt */
main {
  background: rgba(248, 243, 234, .96);
  border-radius: 16px;
  margin-top: 24px !important;
  margin-bottom: 32px !important;
  box-shadow: 0 10px 40px rgba(20, 15, 10, .18);
}
@media (max-width: 820px) {
  /* iOS unterstützt "fixed" nicht sauber */
  body { background-attachment: scroll; }
  main { margin: 12px 8px 24px !important; border-radius: 12px; padding: 24px 16px 40px; }
}
img { max-width: 100%; height: auto; }
a { color: var(--red); text-underline-offset: 2px; }
a:hover { color: var(--red-dark); }

/* Kopf */
.topbar { height: 6px; background: repeating-linear-gradient(90deg, var(--red) 0 28px, #fff 28px 34px, var(--pine) 34px 62px, #fff 62px 68px); }
.site-header {
  /* Schneeflocken dezent hinter Logo und Menü: helle Schicht darüber hält das Menü gut lesbar */
  background:
    linear-gradient(90deg, rgba(255,253,248,.74) 0%, rgba(255,253,248,.88) 38%, rgba(255,253,248,.94) 100%),
    #e00 url("hintergrund-2fc467be.jpg") center 30% / 1000px auto repeat;
  border-bottom: 1px solid var(--line);
  box-shadow: 0 2px 10px rgba(20,15,10,.08);
}
.nav > ul > li > a { background: rgba(255,253,248,.55); }
.nav > ul > li > a:hover, .nav > ul > li > a:focus-visible { background: var(--paper-2); }
.header-inner {
  max-width: 1100px; margin: 0 auto; padding: 14px 16px;
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
}
.brand { display: block; line-height: 0; }
.brand img { height: 64px; width: auto; }
.nav-toggle {
  display: none; border: 1px solid var(--line); background: var(--paper);
  border-radius: 8px; padding: 8px 12px; font: 600 15px var(--sans); color: var(--ink); cursor: pointer;
}
.nav > ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 4px; }
.nav li { position: relative; }
.nav a {
  display: block; padding: 8px 12px; border-radius: 8px;
  color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px;
}
.nav a:hover, .nav a:focus-visible { background: var(--paper-2); color: var(--red-dark); }
.nav a.active { color: var(--red); }
.nav ul ul {
  list-style: none; margin: 0; padding: 6px; position: absolute; left: 0; top: 100%;
  min-width: 180px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  box-shadow: 0 8px 24px rgba(42,33,26,.12); display: none; z-index: 20;
}
.nav li:hover > ul, .nav li:focus-within > ul { display: block; }
.nav ul ul a { font-weight: 500; }

/* Inhalt */
main { max-width: 1100px; margin: 0 auto; padding: 32px 32px 48px; }
.page-title { font: 600 clamp(28px, 4vw, 40px)/1.15 var(--serif); margin: 0 0 8px; color: var(--ink); }
.lead { font-size: 19px; color: var(--ink-soft); margin: 0 0 28px; max-width: 70ch; }
h2 { font: 600 24px/1.25 var(--serif); margin: 36px 0 12px; }
h3 { font: 600 19px/1.3 var(--serif); margin: 24px 0 8px; }
.prose { max-width: 70ch; }
.prose p { margin: 0 0 1em; }
.breadcrumb { font-size: 14px; color: var(--ink-soft); margin-bottom: 10px; }
.breadcrumb a { color: var(--ink-soft); }

.hero {
  display: grid; grid-template-columns: 1.2fr 1fr; gap: 32px; align-items: center;
  background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 28px;
}
.hero img { border-radius: var(--radius); display: block; }
.hero h1 { font: 600 clamp(26px, 3.6vw, 38px)/1.2 var(--serif); margin: 0 0 12px; }
.hero p { margin: 0; color: var(--ink-soft); }

/* Mitglieder */
.members { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 16px; margin-top: 16px; }
.member { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; text-align: center; }
.member img { width: 120px; height: 120px; object-fit: cover; border-radius: 50%; background: var(--paper-2); display: block; margin: 0 auto 10px; }
.member .name { font: 600 19px var(--serif); }
.member .role { font-size: 13px; color: var(--red); font-weight: 600; text-transform: uppercase; letter-spacing: .04em; min-height: 1.3em; }
.member dl { margin: 8px 0 0; font-size: 14px; color: var(--ink-soft); }
.member dt { font-weight: 600; color: var(--ink); }
.member dd { margin: 0 0 4px; }

/* Tabellen */
.table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--radius); background: var(--card); }
table { border-collapse: collapse; width: 100%; font-size: 15px; }
th, td { padding: 8px 10px; text-align: left; border-bottom: 1px solid var(--line); white-space: nowrap; }
thead th { background: var(--pine); color: #fff; font-weight: 600; position: sticky; top: 0; }
tbody tr:nth-child(even) { background: #fbf7f0; }
td.num, th.num { text-align: right; font-variant-numeric: tabular-nums; }
.pts { display: block; font-size: 13px; color: var(--ink-soft); font-variant-numeric: tabular-nums; }
.rank-1 { color: var(--red); font-weight: 700; }
.rank-6 { color: var(--ink-soft); }
.kranz { font-weight: 700; color: var(--red); }
.corona td { color: var(--ink-soft); font-style: italic; }
.legend { font-size: 14px; color: var(--ink-soft); margin-top: 8px; }

/* Galerie */
.albums { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 16px; }
.album { display: block; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; text-decoration: none; color: var(--ink); transition: transform .15s, box-shadow .15s; }
.album:hover { transform: translateY(-2px); box-shadow: 0 8px 20px rgba(42,33,26,.12); color: var(--ink); }
.album .cover { aspect-ratio: 4/3; background: var(--paper-2); overflow: hidden; }
.album .cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.album .label { padding: 8px 12px; display: flex; justify-content: space-between; align-items: baseline; }
.album .year { font: 600 20px var(--serif); }
.album .count { font-size: 13px; color: var(--ink-soft); }
.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.grid a { display: block; aspect-ratio: 1; overflow: hidden; border-radius: 8px; background: var(--paper-2); }
.grid img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .2s; }
.grid a:hover img { transform: scale(1.04); }
.album-nav { display: flex; justify-content: space-between; gap: 12px; margin: 24px 0 0; flex-wrap: wrap; }
.btn { display: inline-block; padding: 8px 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--card); color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; cursor: pointer; font-family: var(--sans); }
.btn:hover { border-color: var(--red); color: var(--red); }
.btn[disabled] { opacity: .4; pointer-events: none; }

/* Lightbox */
.lb { position: fixed; inset: 0; background: rgba(15,10,8,.92); display: none; align-items: center; justify-content: center; z-index: 100; }
.lb.open { display: flex; }
.lb img { max-width: 92vw; max-height: 86vh; border-radius: 4px; box-shadow: 0 10px 40px rgba(0,0,0,.5); }
.lb button { position: absolute; background: rgba(255,255,255,.12); color: #fff; border: 0; border-radius: 50%; width: 48px; height: 48px; font-size: 26px; line-height: 48px; cursor: pointer; }
.lb button:hover { background: rgba(255,255,255,.25); }
.lb .close { top: 16px; right: 16px; }
.lb .prev { left: 16px; top: 50%; transform: translateY(-50%); }
.lb .next { right: 16px; top: 50%; transform: translateY(-50%); }
.lb .caption { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; color: #ddd; font-size: 14px; }

/* Statuten */
.book { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 20px; text-align: center; }
.book img { max-height: 80vh; border: 1px solid var(--line); box-shadow: 0 6px 20px rgba(42,33,26,.15); }
.book-controls { display: flex; align-items: center; justify-content: center; gap: 12px; margin-top: 14px; flex-wrap: wrap; }
.book-pages { display: flex; gap: 6px; justify-content: center; flex-wrap: wrap; margin-top: 12px; }
.book-pages button { width: 36px; height: 36px; border-radius: 8px; border: 1px solid var(--line); background: var(--paper); cursor: pointer; font: 600 14px var(--sans); color: var(--ink); }
.book-pages button.active { background: var(--red); color: #fff; border-color: var(--red); }

/* Videos */
.videos { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 16px; }
.video { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; }
.video video { width: 100%; border-radius: 6px; background: #111; aspect-ratio: 16/9; display: block; }
.video .meta { display: flex; justify-content: space-between; align-items: center; margin-top: 8px; font-size: 14px; gap: 8px; }
.video .fallback { display: none; aspect-ratio: 16/9; background: var(--paper-2); border-radius: 6px; align-items: center; justify-content: center; text-align: center; padding: 16px; font-size: 14px; color: var(--ink-soft); }
.video.no-play video { display: none; }
.video.no-play .fallback { display: flex; }
.year-head { font: 600 22px var(--serif); margin: 32px 0 12px; padding-bottom: 6px; border-bottom: 2px solid var(--red); display: inline-block; }

/* Spiele */
.games { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 16px; }
.game { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; display: flex; flex-direction: column; }
.game .thumb { aspect-ratio: 4/3; background: var(--paper-2); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.game .thumb img { width: 100%; height: 100%; object-fit: cover; }
.game .body { padding: 12px 14px 14px; display: flex; flex-direction: column; gap: 6px; flex: 1; }
.game h3 { margin: 0; }
.game p { margin: 0; font-size: 15px; color: var(--ink-soft); flex: 1; }

.note { background: #fff7e0; border: 1px solid #ecd58f; border-radius: var(--radius); padding: 12px 16px; font-size: 15px; margin: 16px 0; }
.figure { margin: 24px 0; }
.figure img { border-radius: var(--radius); display: block; }
.figure figcaption { font-size: 14px; color: var(--ink-soft); margin-top: 6px; }
.honor { columns: 2; padding-left: 20px; }

/* Fuss */
.site-footer { border-top: 1px solid var(--line); background: var(--card); }
.footer-inner { max-width: 1100px; margin: 0 auto; padding: 20px 16px; display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap; font-size: 14px; color: var(--ink-soft); }
.footer-inner a { color: var(--ink-soft); }

@media (max-width: 820px) {
  .nav-toggle { display: block; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; background: var(--card); border-bottom: 1px solid var(--line); padding: 8px 16px 16px; z-index: 30; }
  .nav.open { display: block; }
  .site-header { position: relative; }
  .nav > ul { flex-direction: column; }
  .nav ul ul { position: static; display: block; border: 0; box-shadow: none; padding: 0 0 0 14px; background: transparent; }
  .brand img { height: 48px; }
  .hero { grid-template-columns: 1fr; padding: 20px; }
  .honor { columns: 1; }
}

/* Startseite: Porträts kreisen um das Esel-Bild (Ersatz für das TwoJ-Karussell) */
.orbit { position: relative; width: 100%; aspect-ratio: 1 / 0.9; }
.orbit-center {
  position: absolute; left: 50%; top: 50%; width: 52%; transform: translate(-50%, -50%);
  border-radius: var(--radius); box-shadow: 0 8px 24px rgba(42,33,26,.18); z-index: 50;
}
.orbit-item {
  position: absolute; left: 50%; top: 50%; width: 22%; aspect-ratio: 1;
  margin: -11% 0 0 -11%; border-radius: 50%; overflow: hidden; display: block;
  border: 3px solid #fff; box-shadow: 0 6px 16px rgba(42,33,26,.28); background: var(--paper-2);
  will-change: transform; transition: box-shadow .2s;
}
.orbit-item img { width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 0; }
.orbit-item:hover, .orbit-item:focus-visible { box-shadow: 0 0 0 4px var(--red), 0 8px 20px rgba(42,33,26,.35); }
.member.flash { animation: flash 1.6s ease; }
@keyframes flash { 0%, 100% { box-shadow: none; } 20%, 60% { box-shadow: 0 0 0 4px var(--red); } }

/* Rangliste: Kranzresultate */
.pts.k { color: var(--red); font-weight: 700; }
.hero-links { margin-top: 16px; }

/* YouTube-Video am Ende jeder Seite */
.video-band { padding: 0 16px 32px; }
.video-band-inner { max-width: 720px; margin: 0 auto; background: var(--card); border-radius: 16px; padding: 14px; box-shadow: 0 10px 40px rgba(20,15,10,.18); }
.video-frame { position: relative; aspect-ratio: 16 / 9; border-radius: 10px; overflow: hidden; background: #111; }
.video-frame iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-note { margin: 10px 4px 2px; font-size: 13px; color: var(--ink-soft); line-height: 1.45; }
@media (max-width: 820px) { .video-band { padding: 0 8px 24px; } }

/* ---------- Interaktive Auswertung (Statistik) ---------- */
.aw { margin-top: 40px; padding-top: 8px; border-top: 2px solid var(--line); }
.aw-lead { color: var(--ink-soft); margin: 0 0 16px; }
.aw-filter { display: flex; flex-direction: column; gap: 10px; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.aw-zeitraum, .aw-personen { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.aw-flabel { font-size: 13px; font-weight: 700; color: var(--ink-soft); text-transform: uppercase; letter-spacing: .04em; min-width: 82px; }
.aw select { font: 15px var(--sans); padding: 6px 8px; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); }
.aw-chip { display: inline-flex; align-items: center; gap: 4px; font: 600 14px var(--sans); padding: 5px 10px; border-radius: 999px; border: 1px solid var(--line); background: #fff; color: var(--ink-soft); cursor: pointer; }
.aw-chip[aria-pressed="true"] { background: #fff; color: var(--ink); border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.aw-chip[aria-pressed="false"] .aw-dot { opacity: .35; }
.aw-chip.aw-klein { font-weight: 500; font-size: 13px; background: var(--paper); }
.aw-chip:hover { border-color: var(--red); }
.aw-dot { flex: none; vertical-align: -1px; }
.aw-tabs { display: flex; gap: 2px; margin: 16px 0 0; border-bottom: 2px solid var(--line); overflow-x: auto; }
.aw-tabs [role=tab] { font: 600 15px var(--sans); padding: 9px 14px; border: 0; background: none; color: var(--ink-soft); cursor: pointer; border-bottom: 3px solid transparent; margin-bottom: -2px; white-space: nowrap; }
.aw-tabs [role=tab][aria-selected="true"] { color: var(--red); border-bottom-color: var(--red); }
.aw-tabs [role=tab]:hover { color: var(--ink); }
.aw-panel { padding: 16px 0 4px; outline: none; }
.aw-optionen { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; margin-bottom: 10px; font-size: 15px; }
.aw-check, .aw-inline { display: inline-flex; align-items: center; gap: 6px; }
.aw-vs { color: var(--ink-soft); font-weight: 600; }
.aw-chart { position: relative; background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 4px; }
.aw-svg { display: block; max-width: 100%; height: auto; font-family: var(--sans); }
.aw-grid { stroke: #ece4d6; stroke-width: 1; }
.aw-null { stroke: #b9ab96; stroke-width: 1; }
.aw-tick { fill: #7a6d60; font-size: 12px; }
.aw-label { fill: var(--ink); font-size: 13px; font-weight: 600; }
.aw-wert { fill: var(--ink); font-size: 13px; font-variant-numeric: tabular-nums; }
.aw-stiel { stroke: #d8ccb8; stroke-width: 2; }
.aw-schnitt { stroke-dasharray: 5 4; }
.aw-ausfall { fill: #f1eadf; }
.aw-kreuz { stroke: #9b8e7e; stroke-width: 1; stroke-dasharray: 3 3; }
.aw-bin { fill: #2a78d6; }
.aw-hit { cursor: default; }
.aw-hit:hover path, .aw-hit:hover circle { filter: brightness(.92); }
.aw-tip { position: absolute; z-index: 5; pointer-events: none; background: #fff; border: 1px solid var(--line); border-radius: 8px; box-shadow: 0 6px 20px rgba(42,33,26,.18); padding: 8px 10px; font-size: 13px; min-width: 150px; max-width: 260px; }
.aw-tip strong { display: block; margin-bottom: 4px; }
.aw-tip-z { display: grid; grid-template-columns: 14px 1fr auto auto; gap: 6px; align-items: center; }
.aw-tip-z b { font-variant-numeric: tabular-nums; }
.aw-tip-z small { color: var(--ink-soft); }
.aw-hinweis { font-size: 13px; color: var(--ink-soft); margin: 8px 0 0; }
.aw-leer { padding: 24px; text-align: center; color: var(--ink-soft); background: var(--card); border: 1px dashed var(--line); border-radius: var(--radius); }
.aw-table { margin-top: 10px; }
.aw-table summary { cursor: pointer; font-size: 14px; font-weight: 600; color: var(--red); padding: 4px 0; }
.aw-table .table-wrap { margin-top: 8px; }
.aw-kennzahlen th, .aw-kennzahlen td { font-size: 14px; }
.aw-sort { font: inherit; font-weight: 600; color: inherit; background: none; border: 0; padding: 0; cursor: pointer; white-space: nowrap; }
.aw-kacheln { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 10px; margin-bottom: 12px; }
.aw-kachel { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; }
.aw-kachel strong { display: block; font: 600 26px/1.15 var(--serif); font-variant-numeric: tabular-nums; }
.aw-kachel span { font-size: 13px; color: var(--ink-soft); display: inline-flex; gap: 4px; align-items: center; }
.aw-rekorde { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; }
.aw-rekord h3 { margin-top: 0; }
.aw-rekord td, .aw-rekord th { font-size: 14px; }
.aw-name { display: inline-flex; align-items: center; gap: 4px; }
.aw-fuss { margin-top: 16px; display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.aw h3 { font-size: 18px; }
@media (max-width: 560px) { .aw-flabel { min-width: 100%; } .aw-tabs [role=tab] { padding: 8px 10px; font-size: 14px; } }

/* Social-Links im Fuss */
.sozial-links { display: inline-flex; gap: 16px; flex-wrap: wrap; }
.sozial.insta { font-weight: 700; color: var(--red); }
