/* VBC Ebikon – Design «Halle»
   Dunkelblau wie das Dress, Royalblau als Akzent, Ballgelb sparsam.
   Schriften selbst gehostet (keine Verbindung zu Google): Big Shoulders Display für Titel, Barlow für Text.
   Die HTML-Struktur kommt aus lib/render.js; hier wird nur gestaltet. */

@font-face { font-family: "Big Shoulders Display"; src: url("/fonts/big-shoulders-display.woff2") format("woff2"); font-weight: 100 900; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("/fonts/barlow-400.woff2") format("woff2"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("/fonts/barlow-500.woff2") format("woff2"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Barlow"; src: url("/fonts/barlow-600.woff2") format("woff2"); font-weight: 600; font-display: swap; }

:root {
  --navy: #0f1a3d;
  --navy-2: #172552;
  --navy-3: #22305c;   /* Linien auf Dunkelblau */
  --royal: #1f5fd8;
  --ice: #e9effa;
  --muted: #93a2c8;
  --ball: #ffcf2e;
  --spieltag: #ff8a3d; /* Markierung Spieltag (viele Heimspiele am selben Tag) */
  --display: "Big Shoulders Display", "Arial Narrow", sans-serif;
  --font: "Barlow", system-ui, -apple-system, "Segoe UI", sans-serif;
  --radius: 10px;
  --gutter: 16px;
  --max: 1280px;
  --header-h: 72px;
  --sec-pad: clamp(56px, 8vw, 104px);
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: calc(var(--header-h) + 16px); }
body { margin: 0; font: 400 1.0625rem/1.6 var(--font); color: var(--ice); background: var(--navy); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-underline-offset: 3px; }
a:hover { color: var(--ball); }
:focus-visible { outline: 2px solid var(--ball); outline-offset: 3px; }
h1, h2, h3, h4 { margin: 0 0 .4em; }
h1, h2, h3 { font-family: var(--display); font-weight: 900; text-transform: uppercase; line-height: .9; letter-spacing: -.005em; }
h1 { font-size: clamp(3.4rem, 9vw, 7rem); }
h2 { font-size: clamp(2.6rem, 6vw, 4.8rem); }
h3 { font-size: clamp(1.7rem, 3vw, 2.2rem); font-weight: 700; }
h4 { font-size: 1.15rem; font-weight: 600; }
/* Lange Wörter (Datenschutzerklärung, Volleyballlager) dürfen auf schmalen Bildschirmen nicht über den Rand ragen */
h1, h2 { overflow-wrap: break-word; }
@media (max-width: 560px) { h1, h2 { -webkit-hyphens: auto; hyphens: auto; hyphenate-limit-chars: 12 5 5; } }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- Header & Navigation ---------- */
.site-header { position: sticky; top: 0; z-index: 50; border-bottom: 1px solid var(--navy-3); }
/* Hintergrund mit Unschärfe auf einer eigenen Ebene: backdrop-filter direkt auf dem Header würde das
   mobile Menü (position: fixed) in den Header einsperren statt es über den ganzen Bildschirm zu legen */
.site-header::before { content: ""; position: absolute; inset: 0; z-index: -1; background: rgba(15, 26, 61, .92); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); transition: background .1s; }
.site-header__inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); height: var(--header-h); display: flex; align-items: center; gap: 16px; }
.site-logo img { height: 44px; width: auto; }
.site-logo { font-family: var(--display); font-weight: 900; font-size: 1.75rem; text-transform: uppercase; text-decoration: none; letter-spacing: .01em; white-space: nowrap; }
.site-social { color: var(--ice); display: flex; margin-left: auto; }
.nav__list, .nav__sub { list-style: none; margin: 0; padding: 0; }
.site-nav a { text-decoration: none; display: block; padding: 8px 12px; font-weight: 500; }
.site-nav a:hover, .nav__item.is-active > a { color: var(--ball); }

.nav-burger { margin-left: auto; width: 44px; height: 44px; border: 0; background: none; cursor: pointer; position: relative; }
.nav-burger span:first-child, .nav-burger span:first-child::before, .nav-burger span:first-child::after {
  position: absolute; left: 11px; width: 22px; height: 2px; background: var(--ice); content: ""; transition: transform .2s;
}
.nav-burger span:first-child { top: 21px; }
.nav-burger span:first-child::before { left: 0; top: -7px; }
.nav-burger span:first-child::after { left: 0; top: 7px; }
.nav-burger[aria-expanded="true"] span:first-child { background: transparent; }
.nav-burger[aria-expanded="true"] span:first-child::before { transform: translateY(7px) rotate(45deg); }
.nav-burger[aria-expanded="true"] span:first-child::after { transform: translateY(-7px) rotate(-45deg); }
.nav-burger + .site-nav + .site-social { margin-left: 0; }

@media (max-width: 899px) {
  .site-nav { position: fixed; inset: var(--header-h) 0 0 0; background: var(--navy); overflow-y: auto; overscroll-behavior: contain; padding: 8px var(--gutter) 40px; display: none; }
  .site-nav.is-open { display: block; }
  .nav__item { position: relative; border-bottom: 1px solid var(--navy-3); }
  .nav__list > .nav__item > a { padding: 14px 48px 14px 4px; font-family: var(--display); font-weight: 700; font-size: 1.8rem; text-transform: uppercase; line-height: 1; }
  .nav__sub a { padding: 10px 48px 10px 4px; }
  .nav__toggle { position: absolute; right: 0; top: 8px; width: 44px; height: 44px; border: 0; background: none; cursor: pointer; }
  .nav__sub .nav__toggle { top: 1px; }
  .nav__toggle::before { content: ""; display: block; margin: auto; width: 10px; height: 10px; border-right: 2px solid var(--ice); border-bottom: 2px solid var(--ice); transform: rotate(45deg); transition: transform .2s; }
  .nav__toggle[aria-expanded="true"]::before { transform: rotate(-135deg); }
  .nav__sub { display: none; padding-left: 16px; }
  .nav__toggle[aria-expanded="true"] + .nav__sub { display: block; }
  .nav__sub .nav__item:last-child { border-bottom: 0; }
  body.nav-open { overflow: hidden; }
}

@media (min-width: 900px) {
  .nav-burger { display: none; }
  .site-nav { margin-left: auto; }
  .nav__list { display: flex; }
  .nav__item { position: relative; }
  .nav__toggle { display: none; }
  .nav__sub { position: absolute; top: 100%; left: 0; min-width: 230px; background: var(--navy-2); border: 1px solid var(--navy-3); border-radius: var(--radius); padding: 6px 0; box-shadow: 0 16px 40px rgba(0,0,0,.35); display: none; }
  .nav__sub a { padding: 7px 16px; }
  .nav__sub .nav__sub { top: -7px; left: 100%; }
  .nav__item:hover > .nav__sub, .nav__item:focus-within > .nav__sub { display: block; }
  .nav__item.has-children > a::after { content: ""; display: inline-block; width: 6px; height: 6px; margin: 0 0 3px 7px; border-right: 1.5px solid currentColor; border-bottom: 1.5px solid currentColor; transform: rotate(45deg); }
  .nav__sub .nav__item.has-children > a::after { transform: rotate(-45deg); margin-bottom: 1px; }
  .site-social { margin-left: 8px; }
}

/* ---------- Abschnitte ---------- */
.sec { padding: var(--sec-pad) 0; }
.sec + .sec--default { padding-top: 0; }
.sec__inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.sec__inner > * + * { margin-top: 24px; }
.sec__inner > :is(.b-heading, .block--heading) + * { margin-top: 12px; }
.site-main > .sec:first-child:not(.sec--hero):not(.sec--banner) { padding-top: clamp(40px, 6vw, 72px); }

/* Titelbild: Foto in Dress-Blau eingefärbt, Titel riesig */
.sec--hero { position: relative; isolation: isolate; overflow: hidden; display: flex; align-items: flex-end; min-height: min(calc(92vh - var(--header-h)), 900px); padding: 0; background: var(--royal); }
.sec--hero::before { content: ""; position: absolute; inset: 0; z-index: -2; background: var(--bg, none) 50% var(--bg-y, 8%) / cover no-repeat; filter: grayscale(1) contrast(1.15); mix-blend-mode: multiply; opacity: .9; }
.sec--hero::after { content: ""; position: absolute; inset: 0; z-index: -1; background: linear-gradient(to top, var(--navy) 4%, rgba(15,26,61,.15) 55%, rgba(15,26,61,.5)); }
.sec--hero .sec__inner { width: 100%; padding-top: 80px; padding-bottom: 64px; display: grid; grid-template-columns: minmax(0, 1fr) auto auto; align-items: end; gap: 22px 12px; }
.sec--hero .sec__inner > * { margin: 0; }
.sec--hero .sec__inner > :is(.b-heading, .block--heading, .b-image, .block--image) { grid-column: 1 / -1; }
.sec--hero .sec__inner > :is(.b-text, .block--text) { grid-column: 1; max-width: 34rem; font-size: 1.2rem; }
/* Lange Wörter (z.B. «Volleyballlager») nicht mitten im Wort umbrechen: Schrift höchstens so gross,
   dass das längste Wort (--wl, vom Renderer) in die Inhaltsbreite passt (.56 em je Buchstabe, mit Reserve) */
.sec--hero { --hero-w: calc(min(100vw, var(--max)) - 2 * var(--gutter)); }
.sec--hero h1 { font-size: min(clamp(4.5rem, 15vw, 14rem), var(--hero-w) / (var(--wl, 6) * .56)); line-height: .86; text-align: left; }
.sec--hero h2 { font-size: min(clamp(3.4rem, 10vw, 8rem), var(--hero-w) / (var(--wl, 6) * .56)); text-align: left; }
.sec--hero .b-text.is-center { margin-left: 0; margin-right: 0; }
.sec--hero .is-center { text-align: left; }
.sec--hero .b-text { max-width: none; }
/* Dezenter Hinweis, welches Team gerade im Titelbild ist */
.sec--hero .hero__caption { position: absolute; left: 0; right: 0; bottom: 14px; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); text-align: right; font-size: .8rem; color: var(--muted); }
@media (max-width: 760px) {
  .sec--hero .sec__inner { grid-template-columns: minmax(0, 1fr); }
  .sec--hero .sec__inner > * { grid-column: 1 / -1; }
}
/* Schmal oder hochkant: Foto nicht auf Bildschirmhöhe aufblasen (schneidet links und rechts die Leute ab),
   sondern in voller Breite als flaches Band (2:1) mit dem oberen Bildteil (Köpfe, Oberkörper; Ausschnitt über --bg-y),
   Titel, Text und Buttons darunter; der Titel ragt ins ausgeblendete Bandende */
@media (max-width: 760px), (max-aspect-ratio: 1/1) {
  .sec--hero { min-height: 0; --hero-h: 50vw; background: linear-gradient(var(--royal), var(--royal)) top / 100% var(--hero-h) no-repeat, var(--navy); }
  .sec--hero::before { bottom: auto; height: var(--hero-h); }
  .sec--hero::after { background: linear-gradient(to bottom, rgba(15,26,61,.3), rgba(15,26,61,0) 14vw, rgba(15,26,61,.4) 32vw, var(--navy) var(--hero-h)); }
  .sec--hero .sec__inner { padding-top: calc(var(--hero-h) - clamp(2.6rem, 11vw, 5rem)); padding-bottom: 16px; }
  /* Bildtext direkt unter dem Titel statt auf dem Foto, damit er niemanden verdeckt */
  .sec--hero .sec__inner > :is(.b-heading, .block--heading):first-child { order: -2; }
  .sec--hero .hero__caption { position: static; order: -1; margin: -14px 0 0; padding: 0; text-align: left; }
}
/* Zwei Hochformat-Fotos nebeneinander, je eine Hälfte */
.sec--hero.has-duo::before { background: var(--bg) 0 var(--bg-y, 8%) / 50% auto no-repeat, var(--bg2) 100% var(--bg-y, 8%) / 50% auto no-repeat; }
@media (max-width: 760px) {
  .sec--hero::before { background-image: var(--bg-s, var(--bg, none)); }
  .sec--hero.has-duo::before { background-image: var(--bg-s, var(--bg)), var(--bg2-s, var(--bg2)); }
}

/* Hinweisband: gelb */
.sec--banner { background: var(--ball); color: var(--navy); padding: 22px 0; }
.sec--banner .sec__inner { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 32px; }
.sec--banner .sec__inner > * { margin: 0; }
.sec--banner :is(h1, h2, h3, h4) { font-size: 2rem; font-weight: 900; margin: 0; }
.sec--banner a:hover { color: var(--royal); }
.sec--banner .btn { background: var(--navy); border-color: var(--navy); color: var(--ice); }
.sec--banner .btn:hover { background: var(--ball); border-color: var(--ball); color: var(--navy); }
.sec--banner + .sec, .sec--muted + .sec, .sec--hero + .sec { padding-top: var(--sec-pad); }

/* Mehrere Standard-Abschnitte hintereinander nicht zu weit auseinander */
.sec--default:has(+ .sec--default) { padding-bottom: 48px; }

/* Abgesetzt: hellere blaue Fläche */
.sec--muted { background: var(--navy-2); }
.sec--muted + .sec--muted { padding-top: 0; }

/* ---------- Blöcke ---------- */
.is-center { text-align: center; }
.richtext > :first-child { margin-top: 0; }
.richtext > :last-child { margin-bottom: 0; }
.richtext a { color: var(--ice); text-decoration-color: var(--ball); text-decoration-thickness: 2px; }
.richtext a:hover { color: var(--ball); }
/* E-Mail-Links: gelb statt unterstrichen (öffentlich data-mail, im Editor noch mailto:), lange Adressen dürfen umbrechen */
.richtext a[data-mail], .richtext a[href^="mailto:"] { color: var(--ball); text-decoration: none; overflow-wrap: anywhere; }
.richtext a[data-mail]:hover, .richtext a[data-mail]:focus-visible,
.richtext a[href^="mailto:"]:hover, .richtext a[href^="mailto:"]:focus-visible { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: 3px; }
.richtext strong { font-weight: 600; color: #fff; }
.b-text { max-width: 68ch; }
.b-text.is-center { margin-left: auto; margin-right: auto; }
.b-heading.is-center { text-align: center; }

.b-image { margin: 0; }
.b-image img { border-radius: var(--radius); width: 100%; }
.b-image figcaption { color: var(--muted); font-size: .9rem; margin-top: 8px; }

.btn { display: inline-block; padding: 14px 24px; border-radius: 999px; font-weight: 600; text-decoration: none; background: var(--ice); color: var(--navy); border: 1.5px solid var(--ice); transition: background .15s, color .15s, border-color .15s; }
.btn:hover { background: var(--ball); border-color: var(--ball); color: var(--navy); }
.btn--line { background: transparent; color: var(--ice); }
.btn--line:hover { background: var(--ice); border-color: var(--ice); color: var(--navy); }
/* Deaktiviert: blass, Klick zeigt nur die Meldung (.btn-note) */
.btn--off, .btn--off:hover { background: transparent; color: var(--muted); border-color: currentColor; border-style: dashed; cursor: not-allowed; font: inherit; font-weight: 600; }
.btn-note { display: block; margin-top: 12px; color: var(--ball); font-size: .95rem; }
.b-button { margin-bottom: 0; }

/* Anmeldeformular (Warteliste) */
.b-form { max-width: 52rem; }
.b-form fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
.b-form .form__group { border-top: 1.5px solid var(--ice); padding: 18px 0 30px; }
.form__group > legend { float: left; width: 100%; margin-bottom: 14px; font-family: var(--display); font-weight: 700; font-size: 1.7rem; text-transform: uppercase; line-height: 1; }
.form__grid { clear: both; display: grid; gap: 16px 20px; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.form__wide { grid-column: 1 / -1; display: grid; gap: 16px 20px; grid-template-columns: inherit; }
.form__wide > .form__field:only-child, .form__wide > .form__choice:only-child { grid-column: 1 / -1; }
.form__full { grid-column: 1 / -1; }
.b-form [hidden] { display: none; }
@media (max-width: 600px) { .form__grid { grid-template-columns: 1fr; } }
.form__field { display: grid; gap: 6px; font-weight: 500; }
.form__field small, .form__field span small { color: var(--muted); font-weight: 400; }
.b-form input:not([type=radio], [type=checkbox]), .b-form textarea { width: 100%; padding: 11px 14px; font: inherit; color: var(--ice); background: var(--navy-2); border: 1.5px solid var(--navy-3); border-radius: var(--radius); color-scheme: dark; }
.b-form textarea { resize: vertical; min-height: 5.5em; }
.b-form input:focus, .b-form textarea:focus { outline: none; border-color: var(--ball); }
.b-form input::placeholder, .b-form textarea::placeholder { color: var(--muted); }
.b-form.was-checked :is(input, textarea):invalid { border-color: var(--spieltag); }
.b-form.was-checked .form__choice:has(:invalid) legend, .form__choice.is-bad legend, .form__consent.is-bad { color: var(--spieltag); }
.form__err { margin: 0; color: var(--spieltag); font-size: .95rem; font-weight: 500; }
.form__choice .form__err { margin-top: 4px; }
.form__consent + .form__err { margin: -14px 0 18px; }
.form__choice legend { padding: 0; margin-bottom: 6px; font-weight: 500; }
.form__choice label { display: inline-flex; align-items: center; gap: 8px; margin: 6px 22px 6px 0; cursor: pointer; }
.b-form input[type=radio], .b-form input[type=checkbox] { width: 20px; height: 20px; margin: 0; accent-color: var(--ball); flex: none; }
.form__consent { display: flex; gap: 12px; align-items: flex-start; margin: 4px 0 22px; color: #c9d3ee; font-size: .95rem; cursor: pointer; }
.b-form .form__consent input { margin-top: 3px; }
.form__consent a { color: var(--ice); text-decoration: underline; text-underline-offset: 2px; }
.form__consent a:hover { color: var(--ball); }
.form__msg { margin: 0 0 16px; padding: 10px 14px; border-radius: var(--radius); background: rgba(255, 138, 61, .14); border-left: 3px solid var(--spieltag); }
.b-form .btn { cursor: pointer; font: inherit; font-weight: 600; }
.b-form .btn:disabled { opacity: .6; cursor: wait; }
.form__hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form__done { max-width: 52rem; border-top: 1.5px solid var(--ball); padding-top: 18px; }
.form__done h3 { color: var(--ball); }
.b-form fieldset:disabled { opacity: .75; }

.b-gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.gallery__item { margin: 0; aspect-ratio: 1; overflow: hidden; border-radius: var(--radius); background: var(--navy-2); }
.gallery__item img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.gallery__item:hover img { transform: scale(1.04); }
@media (min-width: 700px) { .b-gallery { grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); } }

/* Kacheln */
.b-cards { display: grid; gap: 18px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr)); }
.card { position: relative; display: flex; flex-direction: column; background: var(--navy-2); border-radius: var(--radius); overflow: hidden; color: inherit; text-decoration: none; }
.sec--muted .card { background: var(--navy); }
a.card:hover { color: inherit; }
.card__media { aspect-ratio: 4 / 3; background: var(--royal); overflow: hidden; }
.card__media img, .card__media .img-placeholder { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
a.card:hover .card__media img { transform: scale(1.04); }
.card__deck { position: relative; }
.card__deck img { position: absolute; inset: 0; opacity: 0; transition: opacity 1s ease, transform .4s ease; }
.card__deck img.is-on { opacity: 1; }
.card__dots { position: absolute; top: 12px; right: 14px; z-index: 1; display: flex; gap: 6px; }
.card__dots i { width: 7px; height: 7px; border-radius: 50%; background: rgba(255,255,255,.45); transition: background .3s; }
.card__dots i.is-on { background: var(--ball); }
.card__body { padding: 16px 18px 18px; }
.card__title { margin: 0 0 .25em; font-size: 2rem; }
a.card:hover .card__title { color: var(--ball); }
.card__text { color: #c9d3ee; font-size: .95rem; }

/* Kacheln ohne Text: Titel liegt auf dem Foto (wie die Teamkarten) */
.cards--tile .card:not(:has(.card__text)) .card__body { position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 18px 14px; background: linear-gradient(to top, rgba(15,26,61,.92), transparent); }
.cards--tile .card:not(:has(.card__text)) .card__title,
.cards--place .card:not(:has(.card__text)) .card__title { margin: 0; }

.cards--person { grid-template-columns: repeat(auto-fill, minmax(min(100%, 200px), 1fr)); }
.cards--person .card { background: none; }
.cards--person .card__media { aspect-ratio: 1; border-radius: var(--radius); }
.cards--person .card__body { padding: 12px 0 0; }
.cards--person .card__title { font-family: var(--font); font-size: .95rem; font-weight: 500; text-transform: none; color: var(--muted); line-height: 1.3; }
.cards--person .card__text { color: var(--ice); font-size: 1.15rem; font-weight: 600; line-height: 1.4; }
/* E-Mail unter dem Namen: kleiner als der Name (Farbe kommt von den E-Mail-Links oben) */
.cards--person .card__text br + a { display: inline-block; margin-top: 4px; font-size: .85rem; font-weight: 400; }

.cards--logo { grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); }
.cards--logo .card { background: #fff; color: var(--navy); }
.cards--logo .card__media { aspect-ratio: 16 / 9; background: #fff; padding: 20px; }
.cards--logo .card__media img { object-fit: contain; }
.cards--logo .card__body { padding: 0 16px 14px; }
.cards--logo .card__title { font-family: var(--font); font-size: .95rem; font-weight: 600; text-transform: none; line-height: 1.3; }
.cards--logo a.card:hover .card__title { color: var(--royal); }
.cards--logo .card__text { color: #4a5571; }

/* Steckbrief: Trainingszeit, Spieler:innen, Kontakte */
.b-facts { display: grid; gap: 0 32px; grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr)); margin: 0; }
.fact { border-top: 1.5px solid var(--ice); padding: 16px 0 24px; }
.fact dt { font-family: var(--display); font-weight: 700; font-size: 1.9rem; text-transform: uppercase; line-height: 1; margin-bottom: 10px; }
.fact dd { margin: 0; color: #c9d3ee; }

/* Termine */
.b-events, .b-links { list-style: none; padding: 0; margin: 0; }
.b-events { border-top: 1.5px solid var(--ice); max-width: 60rem; display: grid; grid-template-columns: max-content 1fr; column-gap: 24px; }
.event { grid-column: 1 / -1; display: grid; grid-template-columns: subgrid; gap: 4px 24px; padding: 12px 0; border-bottom: 1px solid var(--navy-3); }
.event__date { font-weight: 600; color: var(--ball); font-variant-numeric: tabular-nums; white-space: nowrap; }
.event__wd { display: inline-block; min-width: 1.7em; margin-right: .15em; font-weight: 500; color: var(--muted); }
.event.is-next { position: relative; }
.event.is-next::before { content: ""; position: absolute; left: -14px; top: 12px; bottom: 12px; width: 3px; border-radius: 2px; background: var(--ball); }
.event.is-next .event__title { font-weight: 600; }
.event.is-next .event__title::after { content: "Als Nächstes"; display: inline-block; margin-left: 10px; padding: 1px 8px; border-radius: 99px; background: var(--ball); color: var(--navy); font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; vertical-align: 2px; }
.event.is-past, .event.is-past .event__date { color: var(--muted); }
.event.is-past .event__date { font-weight: 500; }
.events-past { max-width: 60rem; margin-top: 28px; }
.events-past summary { cursor: pointer; list-style: none; display: inline-flex; align-items: center; gap: 10px; padding: 8px 0; color: var(--muted); font-weight: 600; }
.events-past summary::-webkit-details-marker { display: none; }
.events-past summary::before { content: ""; width: 8px; height: 8px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(-45deg); transition: transform .2s; }
.events-past[open] summary::before { transform: rotate(45deg); }
.events-past summary:hover { color: var(--ice); }
.events-past__n { font-size: .8rem; padding: 0 7px; border-radius: 99px; border: 1px solid var(--navy-3); }
.events-past .b-events { margin-top: 8px; border-top-color: var(--navy-3); }
.events-empty { color: var(--muted); }
@media (max-width: 480px) { .b-events { grid-template-columns: 1fr; } .event { gap: 2px; } .event.is-next::before { left: -10px; } }

/* Linkliste */
.b-links { border-top: 1px solid var(--navy-3); max-width: 50rem; }
.b-links li { border-bottom: 1px solid var(--navy-3); }
.b-links a { display: block; padding: 14px 0; font-weight: 600; font-size: 1.1rem; text-decoration: none; }
.b-links a::after { content: ""; display: inline-block; width: 7px; height: 7px; margin: 0 0 2px 10px; border-top: 2px solid var(--ball); border-right: 2px solid var(--ball); transform: rotate(45deg); }

/* Trainingswoche (automatisch) */
.b-week { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 230px), 1fr)); border-top: 1.5px solid var(--ice); }
.week__day { padding: 18px 18px 8px 0; }
.week__day + .week__day { border-left: 1px solid var(--navy-3); padding-left: 18px; }
.week__day h3 { margin: 0 0 14px; font-size: 2.2rem; }
.week__slot { display: grid; grid-template-columns: 50px 1fr; gap: 10px; padding: 8px 0; border-top: 1px solid var(--navy-3); font-size: .95rem; text-decoration: none; }
.week__slot time { color: var(--ball); font-weight: 600; font-variant-numeric: tabular-nums; }
.week__slot small { display: block; color: var(--muted); font-size: .82rem; }
.week__slot:hover { color: var(--ball); }
@media (max-width: 560px) {
  .week__day + .week__day { border-left: 0; padding-left: 0; border-top: 1.5px solid var(--ice); }
}

/* Spiele und Resultate (automatisch von Swiss Volley) */
.b-games { display: grid; gap: 0 48px; }
.b-games.is-split { grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr)); }
.games__col h3 { margin: 0; padding: 18px 0 12px; border-top: 1.5px solid var(--ice); font-size: 2.2rem; }
.games__list { list-style: none; padding: 0; margin: 0 0 24px; }
.games__none { color: var(--muted); margin: 0 0 24px; padding: 12px 0; border-top: 1px solid var(--navy-3); }
.game { display: grid; grid-template-columns: 64px 1fr auto; gap: 14px; align-items: center; padding: 10px 0; border-top: 1px solid var(--navy-3); text-decoration: none; }
.game__date { color: var(--ball); font-weight: 600; font-variant-numeric: tabular-nums; line-height: 1.25; }
.game__date small { display: block; color: var(--muted); font-weight: 500; font-size: .82rem; }
.game__main { min-width: 0; line-height: 1.35; }
.game__team { display: block; font-size: .78rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.game__teams { display: block; color: #c9d3ee; }
.game__teams b { color: var(--ice); font-weight: 600; }
.game__cup { display: inline-block; margin-right: 8px; padding: 1px 6px; border: 1.5px solid var(--ball); border-radius: 4px; font-size: .7rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--ball); vertical-align: 2px; }
.game__tag { display: inline-block; margin-right: 8px; padding: 1px 6px; border-radius: 4px; background: var(--spieltag); font-size: .7rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--navy); vertical-align: 2px; }
.game.is-spieltag { margin: 0 -12px; padding-left: 9px; padding-right: 12px; border-left: 3px solid var(--spieltag); background: linear-gradient(90deg, rgba(255, 138, 61, .16), rgba(255, 138, 61, 0) 70%); }
.game.is-spieltag .game__date { color: var(--spieltag); }
.game__main small { display: block; color: var(--muted); font-size: .82rem; }
.game__score { min-width: 3.2em; padding: 4px 8px; border-radius: 6px; text-align: center; font-weight: 600; font-variant-numeric: tabular-nums; border: 1.5px solid var(--navy-3); color: var(--muted); }
.game__score.is-win { background: var(--ball); border-color: var(--ball); color: var(--navy); }
.game__score.is-open { font-size: .82rem; font-weight: 500; }
.game:hover .game__teams, .game:hover .game__teams b { color: var(--ball); }
.games__league { margin: 0 0 8px; font-size: 1.15rem; font-weight: 600; }
.games__league span { margin-right: 12px; font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.ranking { margin: 0 0 24px; }
.ranking h3 { margin: 0; padding: 18px 0 12px; border-top: 1.5px solid var(--ice); font-size: 2.2rem; }
.ranking h3 small { margin-left: 10px; font: 600 .78rem var(--font); letter-spacing: .06em; color: var(--muted); vertical-align: middle; }
.ranking__scroll { overflow-x: auto; }
.ranking__table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.ranking__table th, .ranking__table td { padding: 9px 8px; border-top: 1px solid var(--navy-3); text-align: right; white-space: nowrap; }
.ranking__table thead th { border-top: 0; padding-top: 0; font-size: .78rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; color: var(--muted); }
.ranking__table th:nth-child(2) { text-align: left; width: 100%; white-space: normal; font-weight: 500; color: #c9d3ee; }
.ranking__table thead th:nth-child(2) { color: var(--muted); }
.ranking__table td:first-child, .ranking__table thead th:first-child { text-align: left; padding-left: 0; color: var(--muted); }
.ranking__table td:last-child { padding-right: 0; }
.ranking__table tr.is-us th, .ranking__table tr.is-us td { color: var(--ball); font-weight: 600; }
@media (max-width: 520px) { .ranking__table .is-wide { display: none; } }
.games__more { margin: 0; }
/* U-Turniere: eingebettete Tournify-Teamseite */
.uturniere__stand { margin: 6px 0 0; color: var(--muted); font-size: .8rem; }
.uturniere__live { margin-top: 32px; }
.uturniere__head { margin: 0; padding: 18px 0 12px; border-top: 1.5px solid var(--ice); font-size: 2.2rem; }
.uturniere__head small { margin-left: 10px; font: 600 .78rem var(--font); letter-spacing: .06em; text-transform: uppercase; color: var(--muted); vertical-align: middle; }
.uturniere__frame { display: block; width: 100%; height: min(720px, 80vh); margin-bottom: 8px; border: 1px solid var(--navy-3); border-radius: 8px; background: #fff; }
.uturniere__live .games__more { margin-bottom: 24px; }
.games__more a { font-weight: 600; text-decoration: none; color: var(--ball); }
.games__more a::after { content: ""; display: inline-block; width: 7px; height: 7px; margin: 0 0 2px 8px; border-top: 2px solid currentColor; border-right: 2px solid currentColor; transform: rotate(45deg); }
.games__more a:hover { color: #fff; }

/* Instagram (automatisch, lib/instagram.js): quadratische Kacheln, Text beim Darüberfahren */
.insta__grid { list-style: none; margin: 0 0 24px; padding: 0; display: grid; gap: 12px; grid-template-columns: repeat(var(--cols, 6), 1fr); }
@media (max-width: 900px) { .insta__grid { grid-template-columns: repeat(3, 1fr); } }
.insta__post { position: relative; display: block; aspect-ratio: 1; border-radius: var(--radius); overflow: hidden; background: var(--royal); text-decoration: none; }
.insta__post img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.insta__post::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(15,26,61,.92), transparent 60%); opacity: 0; transition: opacity .25s ease; }
.insta__body { position: absolute; left: 14px; right: 14px; bottom: 12px; z-index: 1; opacity: 0; transform: translateY(6px); transition: opacity .25s ease, transform .25s ease; font-size: .9rem; line-height: 1.35; }
.insta__body time { display: block; color: var(--ball); font-weight: 600; font-size: .78rem; letter-spacing: .06em; text-transform: uppercase; }
.insta__body span { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; color: var(--ice); }
.insta__post:is(:hover, :focus-visible) img { transform: scale(1.04); }
.insta__post:is(:hover, :focus-visible)::after, .insta__post:is(:hover, :focus-visible) .insta__body { opacity: 1; transform: none; }
/* Video / mehrere Bilder: kleines Zeichen oben rechts wie auf Instagram */
.insta__kind { position: absolute; top: 10px; right: 10px; z-index: 1; width: 18px; height: 18px; filter: drop-shadow(0 1px 2px rgba(0,0,0,.6)); }
.insta__kind.is-video { border-style: solid; border-width: 9px 0 9px 15px; border-color: transparent transparent transparent #fff; width: 0; height: 0; }
.insta__kind.is-album { border: 2px solid #fff; border-radius: 3px; box-shadow: 4px -4px 0 -1px rgba(0,0,0,0), 4px -4px 0 0 #fff; width: 13px; height: 13px; top: 13px; right: 13px; }
@media (max-width: 560px) {
  .insta__grid { grid-template-columns: 1fr 1fr; gap: 8px; }
  .insta__body { display: none; }
}
@media (hover: none) { .insta__post::after, .insta__body { display: none; } }

/* Orte (Hallen): Anker-Ziel aus den Trainingszeiten und Link zur Route */
.cards--place .card { scroll-margin-top: calc(var(--header-h) + 20px); }
.cards--place .card:target { box-shadow: 0 0 0 3px var(--ball); }
.card__route { display: inline-block; margin-top: 12px; font-weight: 600; text-decoration: none; color: var(--ball); }
.card__route::after { content: ""; display: inline-block; width: 7px; height: 7px; margin: 0 0 2px 8px; border-top: 2px solid currentColor; border-right: 2px solid currentColor; transform: rotate(45deg); }
.card__route:hover { color: #fff; }
/* In Trainingszeiten verlinkte Hallen */
.fact dd a { color: var(--ice); }
/* Aufzählung im Steckbrief = Dokument-/Linkliste (z. B. Seite Dokumente): eine Zeile pro Link, Dateityp rechts */
.fact dd ul { list-style: none; padding: 0; margin: 14px 0 0; border-top: 1px solid var(--navy-3); }
.fact dd ul:first-child { margin-top: 0; }
.fact dd li { padding: 10px 0; border-bottom: 1px solid var(--navy-3); color: var(--muted); }
.fact dd li > a { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: -10px 0; padding: 10px 0; font-weight: 600; text-decoration: none; color: var(--ice); transition: color .15s; }
.fact dd li > a::after { content: "Link ↗"; flex: none; padding: 2px 8px; border: 1px solid var(--navy-3); border-radius: 99px; font-size: .7rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); transition: background .15s, border-color .15s, color .15s; }
.fact dd li > a[href$=".pdf" i]::after { content: "PDF"; }
.fact dd li > a:is([href$=".xlsx" i], [href$=".xls" i])::after { content: "Excel"; }
.fact dd li > a:is([href$=".docx" i], [href$=".doc" i])::after { content: "Word"; }
.fact dd li > a[href^="/"]:not([href*="."])::after { content: "→"; }
.fact dd li > a:hover { color: var(--ball); }
.fact dd li > a:hover::after { background: var(--ball); border-color: var(--ball); color: var(--navy); }

/* Teams (automatisch) mit Filter */
.teams__filter { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 26px; }
.teams__filter button { font: 600 .95rem var(--font); color: var(--ice); background: transparent; border: 1.5px solid #3a4b80; padding: 7px 16px; border-radius: 999px; cursor: pointer; }
.teams__filter button:hover { border-color: var(--ice); }
.teams__filter button[aria-pressed="true"] { background: var(--ice); color: var(--navy); border-color: var(--ice); }
.teams__cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 270px), 1fr)); gap: 18px; }
.tcard { position: relative; display: block; border-radius: var(--radius); overflow: hidden; aspect-ratio: 4 / 3; text-decoration: none; background: var(--royal); }
.tcard[hidden] { display: none; }
.tcard img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.tcard:hover img { transform: scale(1.04); }
.tcard::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(15,26,61,.92), transparent 55%); }
.tcard.is-empty::after { background: none; }
.tcard__body { position: absolute; left: 16px; right: 16px; bottom: 12px; z-index: 1; }
.tcard__body b { display: block; font-family: var(--display); font-size: 2rem; font-weight: 900; text-transform: uppercase; line-height: 1; }
.tcard__body span { color: #c9d3ee; font-size: .9rem; }
.tcard:hover b { color: var(--ball); }
.tcard__league { display: block; margin-bottom: 4px; color: var(--muted); font-style: normal; font-size: .82rem; }

/* Sponsoren-Raster (automatisch) */
.b-sponsors { display: grid; gap: 56px; }
.sponsors__group h3 { margin: 0 0 18px; }
.sponsors__group h3 a { text-decoration: none; }
.sponsors__grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(min(100%, 250px), 1fr)); }
.sponsors__group.is-small .sponsors__grid { grid-template-columns: repeat(auto-fill, minmax(min(100%, 180px), 1fr)); gap: 12px; }
.sponsors__grid .sponsor { aspect-ratio: 3 / 2; padding: 22px 26px; }
.sponsors__group.is-small .sponsor { padding: 16px 18px; }
.sponsor { display: flex; align-items: center; justify-content: center; background: #fff; color: var(--navy); border-radius: var(--radius); text-decoration: none; transition: transform .2s ease, box-shadow .2s ease; }
.sponsor img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; }
.sponsor__name { font-weight: 600; font-size: 1.05rem; line-height: 1.2; text-align: center; }
a.sponsor:hover { color: var(--royal); transform: translateY(-3px); box-shadow: 0 0 0 3px var(--ball); }

@media (max-width: 560px) {
  .sponsors__grid, .sponsors__group.is-small .sponsors__grid, .cards--logo { grid-template-columns: 1fr 1fr; gap: 10px; }
  .sponsors__grid .sponsor, .sponsors__group.is-small .sponsor { padding: 12px 14px; }
  .cards--logo .card__media { padding: 12px; }
}

/* Laufband über der Fusszeile */
.sponsor-band { background: #fff; color: var(--navy); padding: 22px 0 26px; overflow: hidden; }
.sponsor-band__title { max-width: var(--max); margin: 0 auto 14px; padding: 0 var(--gutter); font-weight: 600; font-size: .9rem; color: #4a5571; }
.sponsor-band__viewport { display: flex; overflow: hidden; -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.sponsor-band__track { list-style: none; margin: 0; padding: 0 28px 0 0; display: flex; align-items: center; gap: 28px; flex-shrink: 0; animation: sponsor-run calc(var(--n, 10) * 3.2s) linear infinite; }
.sponsor-band__viewport:hover .sponsor-band__track, .sponsor-band__viewport:focus-within .sponsor-band__track { animation-play-state: paused; }
.sponsor-band .sponsor { width: 170px; height: 76px; padding: 8px 12px; background: none; }
.sponsor-band a.sponsor:hover { transform: scale(1.06); box-shadow: none; }
.sponsor-band .sponsor__name { font-size: .95rem; color: #4a5571; }
@keyframes sponsor-run { to { transform: translateX(-100%); } }
@media (prefers-reduced-motion: reduce) {
  .sponsor-band__viewport { overflow-x: auto; -webkit-mask-image: none; mask-image: none; }
  .sponsor-band__track { animation: none; }
  .sponsor-band__track[aria-hidden] { display: none; }
}

/* ---------- Footer ---------- */
.site-footer { border-top: 1px solid var(--navy-3); padding: 56px 0 48px; color: var(--muted); font-size: .95rem; }
.site-footer__inner { max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.site-footer__cols { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 32px; }
.site-footer__name { font-family: var(--display); font-weight: 900; font-size: clamp(2.4rem, 5vw, 3.6rem); text-transform: uppercase; line-height: .9; color: var(--ice); margin: 0 0 14px; }
.site-footer__logo { width: min(320px, 100%); height: auto; margin-bottom: 18px; }
.site-footer__contact { font-style: normal; }
.site-footer__nav { display: flex; flex-direction: column; gap: 4px; }
.site-footer__nav b { color: var(--ice); font-weight: 600; margin-bottom: 4px; }
.site-footer a { text-decoration: none; }
.site-footer a:hover { color: var(--ice); }
@media (max-width: 700px) { .site-footer__cols { grid-template-columns: 1fr 1fr; } .site-footer__cols > :first-child { grid-column: 1 / -1; } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}

/* Titelbild: Foto zoomt leicht zurück, Titel und Buttons schweben gestaffelt herein (bei jedem Laden, nicht im Editor) */
@keyframes hero-up { from { opacity: 0; transform: translateY(28px); } }
@keyframes hero-zoom { from { transform: scale(1.12); } }
@media (prefers-reduced-motion: no-preference) {
  body:not(.cms-on) .sec--hero::before { animation: hero-zoom 1.6s cubic-bezier(.2,.7,.2,1) both; }
  body:not(.cms-on) .sec--hero .sec__inner > * { animation: hero-up .8s cubic-bezier(.2,.7,.2,1) .25s both; }
  body:not(.cms-on) .sec--hero .sec__inner > :nth-child(2) { animation-delay: .4s; }
  body:not(.cms-on) .sec--hero .sec__inner > :nth-child(3) { animation-delay: .5s; }
  body:not(.cms-on) .sec--hero .sec__inner > :nth-child(n+4) { animation-delay: .6s; }
}

/* Easter Egg: Maus 0,75 s auf dem Logo → Kopfzeile fährt nach unten, das Logo wird grösser und die Logo-Animation
   spielt an seiner Stelle über die ganze Kopfzeile ab (public/js/site.js). Der negative Abstand unten verhindert,
   dass die Seite mitrutscht. Beim Treffer blitzt die ganze Kopfzeile weiss auf. */
.site-header { transition: padding-bottom .35s ease, margin-bottom .35s ease; }
.site-logo { position: relative; transform-origin: left center; transition: transform .35s ease; }
.site-header.is-egg { padding-bottom: 85px; margin-bottom: -85px; }
.site-header.is-egg .site-logo { transform: translateY(74px) scale(1.45); }
/* Klickfläche des Logos umfasst die ganze Animation (Spielerin und Ball über dem Logo) */
.site-header.is-egg .site-logo::after { content: ""; position: absolute; top: -122%; bottom: -22%; left: -17.5%; right: -17.5%; }
.site-header.is-egg-play .site-logo img { visibility: hidden; }
.site-header.is-egg-flash::before { background: #fff; }
.logo-egg { position: fixed; z-index: 60; border: 0; background: transparent; pointer-events: none; visibility: hidden; }
.logo-egg.is-on { visibility: visible; }

/* Beim Scrollen: Inhalte schweben wie im Titelbild gestaffelt herein (nur mit JS, nicht im Editor, nicht bei reduzierter Bewegung).
   Raster (Kacheln, Galerie, Teams, Sponsoren …) kommen Element für Element, die Verzögerung setzt site.js. */
.rv-on :where(.sec:not(.sec--hero) .sec__inner > :not(.b-cards, .b-gallery, .b-teamgrid, .b-sponsors, .b-facts, .b-week, .b-instagram),
  .b-cards > *, .gallery__item, .teams__filter, .tcard, .sponsors__group h3, .sponsors__grid li, .fact, .week__day, .insta__item, .b-instagram .games__more, .site-footer__cols > *) {
  opacity: 0; transform: translateY(28px);
}
/* Keyframes statt Transition: läuft auch, wenn ein Element schon vor dem ersten Zeichnen sichtbar wird (kurze Unterseiten) */
.rv-on .is-in { opacity: 1; transform: none; animation: hero-up .8s cubic-bezier(.2,.7,.2,1) var(--rv-d, 0s) both; }
