/* ============================================================
   Union _Agora Königswiesen — Stylesheet
   ============================================================ */

:root {
  --ink: #12151a;
  --ink-2: #1b2029;
  --ink-3: #262d38;
  --paper: #f4f6f4;
  --white: #ffffff;
  --text: #2c3138;
  --muted: #737a84;
  --line: #e2e6e2;
  --accent: #e2141a;
  --accent-dark: #b90f14;
  --accent-soft: rgba(226, 20, 26, 0.1);
  --green: #12894a;

  --radius: 16px;
  --radius-sm: 10px;
  --shadow: 0 1px 2px rgba(18, 21, 26, .04), 0 8px 24px -12px rgba(18, 21, 26, .18);
  --shadow-lg: 0 24px 60px -24px rgba(18, 21, 26, .35);
  --wrap: 1220px;
  --header-h: 84px;

  --font: "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Segoe UI", -apple-system, BlinkMacSystemFont, "Arial Black", Impact, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  /* das ausgeblendete Mobilmenü darf die Seite nicht breiter machen */
  overflow-x: hidden;
  overflow-x: clip;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.65;
  color: var(--text);
  background: var(--paper);
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-dark); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.1;
  margin: 0 0 .5em;
  letter-spacing: -.02em;
  font-weight: 800;
}
h1 { font-size: clamp(2.4rem, 6vw, 4.2rem); }
h2 { font-size: clamp(1.9rem, 3.6vw, 2.9rem); }
h3 { font-size: 1.32rem; }
p { margin: 0 0 1.1em; }

.wrap { width: 100%; max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }

.skip {
  position: absolute; left: -9999px; top: 0; z-index: 200;
  background: var(--accent); color: #fff; padding: 12px 18px; border-radius: 0 0 8px 0;
}
.skip:focus { left: 0; color: #fff; }

/* ---------- Header ---------- */

.site-header {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  height: var(--header-h);
  display: flex; align-items: center;
  transition: background .3s ease, box-shadow .3s ease, height .3s ease;
}
.site-header::before {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(10, 12, 16, .78), rgba(10, 12, 16, 0));
  opacity: 1; transition: opacity .3s ease;
  pointer-events: none;
}
.site-header.scrolled {
  height: 70px;
  background: rgba(18, 21, 26, .96);
  box-shadow: 0 10px 30px -18px rgba(0, 0, 0, .8);
}
.site-header.scrolled::before { opacity: 0; }
/* Der Weichzeichner liegt auf einem eigenen Element: direkt am Header würde
   backdrop-filter das fixierte Mobilmenü auf die Höhe des Headers beschneiden. */
.site-header::after {
  content: ""; position: absolute; inset: 0; z-index: -1;
  pointer-events: none;
}
.site-header.scrolled::after { backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }

.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 24px; }
.brand img { height: 46px; width: auto; transition: height .3s ease; }
.site-header.scrolled .brand img { height: 38px; }

.nav-list {
  list-style: none; margin: 0; padding: 0;
  display: flex; align-items: center; gap: 4px;
}
.nav-list > li { position: relative; }
.nav-list a, .sub-toggle {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 10px 14px;
  font-size: .84rem; font-weight: 700; letter-spacing: .09em; text-transform: uppercase;
  color: rgba(255, 255, 255, .86);
  background: none; border: 0; border-radius: 8px;
  font-family: inherit; cursor: pointer;
  transition: color .2s ease, background .2s ease;
  white-space: nowrap;
}
.nav-list a:hover, .sub-toggle:hover, .nav-list a.is-active, .sub-toggle.is-active {
  color: #fff; background: rgba(255, 255, 255, .1);
}
.nav-list a.is-active, .sub-toggle.is-active { box-shadow: inset 0 -2px 0 var(--accent); }
.caret {
  width: 7px; height: 7px; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor;
  transform: rotate(45deg) translate(-2px, -2px); transition: transform .2s ease;
}
.has-sub:hover .caret, .has-sub.open .caret { transform: rotate(-135deg) translate(-3px, -3px); }

.sub {
  position: absolute; top: calc(100% + 10px); left: 0; z-index: 10;
  min-width: 262px; margin: 0; padding: 8px; list-style: none;
  background: #fff; border-radius: 12px; box-shadow: var(--shadow-lg);
  opacity: 0; visibility: hidden; transform: translateY(8px);
  transition: opacity .2s ease, transform .2s ease, visibility .2s;
}
.has-sub:hover .sub, .has-sub.open .sub { opacity: 1; visibility: visible; transform: translateY(0); }
.sub a {
  display: block; width: 100%; color: var(--ink); font-size: .78rem;
  text-transform: none; letter-spacing: .02em; padding: 10px 12px; border-radius: 8px;
}
.sub a:hover, .sub a.is-active { background: var(--accent-soft); color: var(--accent); box-shadow: none; }

.burger {
  display: none; width: 44px; height: 44px; border: 0; border-radius: 10px;
  background: rgba(255, 255, 255, .12); cursor: pointer;
  padding: 12px 11px; flex-direction: column; justify-content: space-between;
}
.burger span { display: block; height: 2px; background: #fff; border-radius: 2px; transition: transform .25s ease, opacity .2s ease; }
.burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(9px) rotate(45deg); }
.burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-9px) rotate(-45deg); }

@media (max-width: 1080px) {
  /* Der Schließen-Knopf bleibt über dem aufgeklappten Menü erreichbar */
  .burger { display: flex; position: relative; z-index: 2; }
  .nav {
    position: fixed; inset: 0; width: 100%;
    height: 100vh; height: 100dvh;
    overscroll-behavior: contain;
    background: var(--ink); padding: calc(var(--header-h) + 16px) 20px calc(40px + env(safe-area-inset-bottom));
    transform: translateX(100%); transition: transform .32s cubic-bezier(.4, 0, .2, 1);
    overflow-y: auto;
  }
  /* Das Logo bleibt über dem bildschirmfüllenden Menü sichtbar */
  .brand { position: relative; z-index: 2; }
  .nav.open { transform: translateX(0); }
  .nav-list { flex-direction: column; align-items: stretch; gap: 2px; }
  .nav-list a, .sub-toggle { width: 100%; justify-content: space-between; padding: 14px 12px; font-size: .9rem; }
  .sub {
    position: static; opacity: 1; visibility: visible; transform: none;
    background: rgba(255, 255, 255, .05); box-shadow: none; margin: 4px 0 8px;
    display: none;
  }
  .has-sub.open .sub { display: block; }
  .sub a { color: rgba(255, 255, 255, .8); font-size: .84rem; }
  .sub a:hover, .sub a.is-active { background: rgba(255, 255, 255, .1); color: #fff; }
}

.nav-backdrop {
  position: fixed; inset: 0; z-index: 99; background: rgba(10, 12, 16, .55);
  opacity: 0; visibility: hidden; transition: opacity .3s ease, visibility .3s;
}
.nav-backdrop.show { opacity: 1; visibility: visible; }

/* ---------- Hero ---------- */

.hero {
  position: relative; min-height: min(60vh, 540px);
  display: flex; align-items: flex-end;
  color: #fff; overflow: hidden;
  padding: calc(var(--header-h) + 40px) 0 88px;
}
.hero-bg { position: absolute; inset: 0; }
/* <picture> darf das Bild nicht verkleinern - es fuellt den Kasten wie zuvor */
.hero-bg picture { display: block; position: absolute; inset: 0; }
.hero-bg img { width: 100%; height: 100%; object-fit: cover; object-position: center 48%; }
.hero-bg::after {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(180deg, rgba(10, 12, 16, .34) 0%, rgba(10, 12, 16, 0) 28%,
                            rgba(10, 12, 16, .28) 66%, rgba(10, 12, 16, .72) 100%),
    linear-gradient(90deg, rgba(10, 12, 16, .28), rgba(10, 12, 16, 0) 50%);
}
.hero .wrap {
  position: relative; z-index: 2;
  /* haelt die Schrift lesbar, ohne das Foto abzudunkeln */
  text-shadow: 0 2px 18px rgba(8, 10, 14, .65), 0 1px 3px rgba(8, 10, 14, .5);
}
.hero h1 {
  /* der Vereinsname steht immer in einer Zeile - die Größe richtet sich
     deshalb nach der Fensterbreite */
  color: #fff; font-size: clamp(.95rem, 4.4vw, 3.6rem);
  text-transform: uppercase; letter-spacing: -.03em; margin-bottom: .3em;
  white-space: nowrap;
}
.hero h1 em { font-style: normal; color: var(--accent); }
.hero-sub {
  font-size: clamp(1.05rem, 2vw, 1.45rem); color: rgba(255, 255, 255, .95);
  max-width: 620px; margin-bottom: 0;
}
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }


/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 15px 28px; border: 0; border-radius: 100px;
  font: inherit; font-size: .84rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  cursor: pointer; transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn-primary { background: var(--accent); color: #fff; box-shadow: 0 10px 30px -12px rgba(226, 20, 26, .9); }
.btn-primary:hover { background: var(--accent-dark); color: #fff; }
.btn-ghost { background: rgba(255, 255, 255, .12); color: #fff; box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .3); }
.btn-ghost:hover { background: rgba(255, 255, 255, .2); color: #fff; }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: var(--ink-3); color: #fff; }
.btn-outline { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 2px var(--line); }
.btn-outline:hover { box-shadow: inset 0 0 0 2px var(--ink); color: var(--ink); }

/* ---------- Page hero (Unterseiten) ---------- */

.page-hero {
  position: relative; color: #fff;
  padding: calc(var(--header-h) + 64px) 0 64px;
  overflow: hidden;
  background: var(--ink) url("/assets/img/hero.jpg") center 50% / cover no-repeat;
}
/* Abdunkeln, damit die Schrift auf dem Foto gut lesbar bleibt */
.page-hero::before {
  content: ""; position: absolute; inset: 0;
  background:
    linear-gradient(100deg, rgba(10, 12, 16, .72) 0%, rgba(10, 12, 16, .52) 45%, rgba(10, 12, 16, .26) 100%),
    radial-gradient(900px 380px at 12% -10%, rgba(226, 20, 26, .26), transparent 70%);
}
/* Auf schmalen Bildschirmen laeuft der Text ueber die ganze Breite -
   deshalb dort gleichmaessig abdunkeln statt von links nach rechts. */
@media (max-width: 900px) {
  .page-hero::before {
    background:
      linear-gradient(180deg, rgba(10, 12, 16, .7), rgba(10, 12, 16, .56)),
      radial-gradient(600px 300px at 10% -10%, rgba(226, 20, 26, .24), transparent 70%);
  }
}

.page-hero .wrap {
  position: relative;
  text-shadow: 0 2px 18px rgba(8, 10, 14, .7), 0 1px 3px rgba(8, 10, 14, .55);
}
.page-hero h1 { color: #fff; text-transform: uppercase; margin-bottom: 0; }
.eyebrow {
  display: block; font-size: .76rem; font-weight: 800; letter-spacing: .24em;
  text-transform: uppercase; color: var(--accent); margin-bottom: 14px;
}
.page-hero .eyebrow { color: rgba(255, 255, 255, .82); }
.page-hero p.lead { color: rgba(255, 255, 255, .92); max-width: 680px; margin: 18px 0 0; font-size: 1.08rem; }

.crumb { font-size: .8rem; color: rgba(255, 255, 255, .78); margin-bottom: 18px; }
.crumb a { color: #fff; }
.crumb a:hover { color: var(--accent); }

/* ---------- Sections ---------- */

.section { padding: clamp(56px, 8vw, 104px) 0; }
.section-alt { background: var(--white); }
.section-dark { background: var(--ink); color: rgba(255, 255, 255, .78); }
.section-dark h2, .section-dark h3 { color: #fff; }

.section-head {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 24px; margin-bottom: 42px; flex-wrap: wrap;
}
.section-head h2 { margin-bottom: 0; text-transform: uppercase; }
.section-head p { margin: 8px 0 0; color: var(--muted); max-width: 560px; }

.link-more {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: .82rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink);
}
.link-more::after {
  content: ""; width: 22px; height: 8px;
  background: currentColor;
  clip-path: polygon(0 40%, 70% 40%, 70% 0, 100% 50%, 70% 100%, 70% 60%, 0 60%);
  transition: transform .2s ease;
}
.link-more:hover { color: var(--accent); }
.link-more:hover::after { transform: translateX(4px); }

/* ---------- Cards ---------- */

.grid { display: grid; gap: 26px; }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 1080px) { .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 900px)  { .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px)  { .grid-4, .grid-3, .grid-2 { grid-template-columns: 1fr; } }

.card {
  position: relative; display: flex; flex-direction: column;
  background: var(--white); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); transition: transform .28s ease, box-shadow .28s ease;
}
.card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.card-media { position: relative; aspect-ratio: 16 / 11; background: var(--ink-2); overflow: hidden; }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.card:hover .card-media img { transform: scale(1.05); }
.card-media.placeholder {
  display: grid; place-items: center;
  background: linear-gradient(135deg, var(--ink-2), var(--ink-3));
}
.card-media.placeholder img { width: 68px; height: auto; opacity: .5; object-fit: contain; }

.chip {
  position: absolute; top: 14px; left: 14px; z-index: 2;
  padding: 6px 13px; border-radius: 100px;
  font-size: .68rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase;
  background: var(--accent); color: #fff;
}
.chip-news { background: var(--ink); }

.card-body { padding: 22px 24px 26px; display: flex; flex-direction: column; flex: 1; }
.card-date { font-size: .74rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-bottom: 10px; }
.card h3 { font-size: 1.16rem; margin-bottom: 10px; }
.card h3 a { color: inherit; }
.card:hover h3 a { color: var(--accent); }
.card p { font-size: .93rem; color: var(--muted); margin: 0 0 18px; }
.card .link-more { margin-top: auto; font-size: .74rem; }
.stretch::after { content: ""; position: absolute; inset: 0; }

/* ---------- Sponsoren ---------- */

.sponsor-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr));
  gap: 18px;
}
.sponsor {
  display: grid; place-items: center; min-height: 128px; padding: 24px;
  background: var(--white); border: 1px solid var(--line); border-radius: var(--radius-sm);
  transition: transform .25s ease, box-shadow .25s ease, border-color .25s ease;
}
.sponsor:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: transparent; }
.sponsor img {
  max-height: 66px; width: auto; object-fit: contain;
  filter: grayscale(1); opacity: .72; transition: filter .3s ease, opacity .3s ease;
}
.sponsor:hover img { filter: none; opacity: 1; }
/* Die Logos haben grossteils einen deckenden hellen Hintergrund - auf dunklem
   Grund daher weisse Kacheln statt Aufhellen per Filter (das bleicht sie aus). */
.section-dark .sponsor { background: #fff; border-color: transparent; }
.section-dark .sponsor img { filter: none; opacity: 1; }

/* ---------- Matchcenter-Band unter dem Hero ---------- */

/* Ragt in das Hero-Bild hinein und schliesst eng an den naechsten Abschnitt an,
   damit die Spielberichte moeglichst weit oben stehen. */
.match-lift {
  padding-top: 0;
  padding-bottom: clamp(30px, 3.5vw, 46px);
  margin-top: clamp(-78px, -5vw, -46px);
  position: relative;
  z-index: 3;
}
.match-lift + .section { padding-top: clamp(30px, 3.5vw, 46px); }

/* ---------- Inhalt / Prose ---------- */

.prose { font-size: 1.05rem; }
.prose h2 { margin-top: 1.6em; }
.prose h3 { margin-top: 1.4em; }
.prose img { border-radius: var(--radius-sm); margin: 1.4em 0; }
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1.2em; }
.prose li { margin-bottom: .45em; }
.prose blockquote {
  margin: 1.6em 0; padding: 4px 0 4px 24px;
  border-left: 3px solid var(--accent); color: var(--ink); font-size: 1.1rem;
}
.prose a { text-decoration: underline; text-underline-offset: 3px; }

.content-card {
  background: var(--white); border-radius: var(--radius);
  padding: clamp(26px, 4vw, 54px); box-shadow: var(--shadow);
}

.split { display: grid; grid-template-columns: 1.05fr .95fr; gap: clamp(28px, 5vw, 64px); align-items: center; }
.split img { border-radius: var(--radius); box-shadow: var(--shadow); }
@media (max-width: 900px) { .split { grid-template-columns: 1fr; } }

.timeline { list-style: none; margin: 0; padding: 0; }
.timeline li { position: relative; padding: 0 0 26px 34px; border-left: 2px solid var(--line); }
.timeline li:last-child { border-left-color: transparent; padding-bottom: 0; }
.timeline li::before {
  content: ""; position: absolute; left: -8px; top: 4px;
  width: 14px; height: 14px; border-radius: 50%; background: var(--accent);
  box-shadow: 0 0 0 4px var(--paper);
}
.timeline strong { display: block; font-family: var(--font-display); color: var(--ink); font-size: 1.05rem; }
.section-alt .timeline li::before { box-shadow: 0 0 0 4px var(--white); }

/* ---------- Team ---------- */

.person {
  background: var(--white); border-radius: var(--radius); overflow: hidden;
  box-shadow: var(--shadow); text-align: center;
  transition: transform .28s ease, box-shadow .28s ease;
}
.person:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); }
.person-photo { aspect-ratio: 1 / 1; background: var(--ink-2); overflow: hidden; position: relative; }
.person-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 20%; transition: transform .5s ease; }
.person:hover .person-photo img { transform: scale(1.06); }
.person-photo.initials {
  display: grid; place-items: center;
  background: linear-gradient(140deg, var(--ink-2), var(--ink-3));
  color: rgba(255, 255, 255, .85); font-family: var(--font-display); font-size: 2.4rem; letter-spacing: .04em;
}
.person-body { padding: 18px 16px 22px; }
.person-body strong { display: block; font-family: var(--font-display); font-size: 1.05rem; color: var(--ink); }
.person-body span { font-size: .78rem; letter-spacing: .1em; text-transform: uppercase; color: var(--accent); font-weight: 700; }

/* ---------- Galerie ---------- */

/* Team-Seite: Logo der Jugend-Spielgemeinschaft und Namensliste des Kantinenteams */
.youth-badge { display: flex; flex-direction: column; align-items: center; gap: 22px; text-align: center; }
.youth-badge img {
  width: min(250px, 64vw); height: auto; padding: 24px; background: #fff;
  border-radius: var(--radius); box-shadow: var(--shadow); transition: transform .3s ease;
}
.youth-badge a:hover img { transform: translateY(-4px); }
.name-list { list-style: none; margin: 22px 0 0; padding: 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.name-list li {
  padding: 14px 16px; background: #fff; border-radius: 12px; box-shadow: var(--shadow);
  border-left: 3px solid var(--accent);
}
.name-list strong { display: block; font-family: var(--font-display); color: var(--ink); }
.name-list span { font-size: .86rem; color: var(--muted); }
@media (max-width: 480px) { .name-list { grid-template-columns: 1fr; } }

/* Mannschaftsfotos auf der Team-Seite */
/* Der Link sitzt immer am unteren Rand — beide Karten bleiben so auf gleicher Höhe */
.squad { display: flex; flex-direction: column; align-items: flex-start; }
.squad .link-more { margin-top: auto; }
.squad-photo {
  display: block; width: 100%; padding: 0; margin: 0 0 22px; border: 0; background: var(--ink);
  border-radius: 12px; overflow: hidden; cursor: zoom-in; aspect-ratio: 3 / 2;
}
.squad-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease, opacity .3s ease; }
.squad-photo:hover img, .squad-photo:focus-visible img { transform: scale(1.03); opacity: .9; }

.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; }
.gallery button {
  position: relative; padding: 0; border: 0; cursor: pointer; overflow: hidden;
  border-radius: var(--radius-sm); aspect-ratio: 4 / 3; background: var(--ink-2);
}
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease, opacity .3s ease; }
.gallery button:hover img { transform: scale(1.07); opacity: .85; }
.gallery button::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(10, 12, 16, .6));
  opacity: 0; transition: opacity .3s ease;
}
.gallery button:hover::after { opacity: 1; }

.filters { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 32px; }
.filter {
  padding: 10px 20px; border-radius: 100px; border: 1px solid var(--line);
  background: var(--white); color: var(--ink); cursor: pointer;
  font: inherit; font-size: .8rem; font-weight: 700; letter-spacing: .06em;
  transition: all .2s ease;
}
.filter:hover { border-color: var(--ink); }
.filter.active { background: var(--ink); border-color: var(--ink); color: #fff; }

.lightbox {
  position: fixed; inset: 0; z-index: 200; display: none;
  background: rgba(8, 10, 14, .95); place-items: center; padding: 40px 20px;
}
.lightbox.open { display: grid; }
.lightbox img {
  max-width: min(1200px, 94vw); max-height: 84vh; border-radius: 8px; object-fit: contain;
  transition: filter .3s ease;
}
/* Solange das große Bild lädt, steht das Vorschaubild weichgezeichnet da -
   so sieht man sofort, dass der Klick angekommen ist. */
.lightbox.loading img { filter: blur(8px); }
.lightbox figcaption { color: rgba(255, 255, 255, .7); text-align: center; margin-top: 16px; font-size: .9rem; }
.lb-btn {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 52px; height: 52px; border-radius: 50%; border: 0; cursor: pointer;
  background: rgba(255, 255, 255, .12); color: #fff; font-size: 1.6rem; line-height: 1;
}
.lb-btn:hover { background: rgba(255, 255, 255, .24); }
.lb-prev { left: 20px; }
.lb-next { right: 20px; }
.lb-close { top: 22px; right: 22px; transform: none; }

/* ---------- Formulare ---------- */

.field { margin-bottom: 18px; }
.field label {
  display: block; font-size: .76rem; font-weight: 800; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 8px;
}
.field input, .field textarea, .field select {
  width: 100%; padding: 14px 16px;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  background: var(--white); color: var(--text); font: inherit; font-size: .98rem;
  transition: border-color .2s ease, box-shadow .2s ease;
}
.field input:focus, .field textarea:focus, .field select:focus {
  outline: 0; border-color: var(--accent); box-shadow: 0 0 0 4px var(--accent-soft);
}
.field textarea { min-height: 160px; resize: vertical; }
.hp { position: absolute; left: -9999px; }
.form-note { font-size: .85rem; color: var(--muted); }

.alert { padding: 14px 18px; border-radius: var(--radius-sm); margin-bottom: 18px; font-size: .94rem; }
.alert-ok { background: #e8f6ee; color: #10693e; }
.alert-err { background: #fdeaea; color: #a11116; }

/* ---------- Meisterschaftstabelle ---------- */

.table-scroll { overflow-x: auto; margin: 0 -6px; padding: 0 6px; }

.league { width: 100%; border-collapse: collapse; font-size: .95rem; }
.league th, .league td { padding: 12px 8px; border-bottom: 1px solid var(--line); white-space: nowrap; }
.league thead th {
  font-family: var(--font-display); font-size: .72rem; font-weight: 700;
  letter-spacing: .12em; text-transform: uppercase; color: var(--muted);
  border-bottom: 2px solid var(--line); text-align: right;
}
.league tbody tr:last-child td { border-bottom: 0; }
.league tbody tr:hover td { background: rgba(18, 21, 26, .03); }
.league .num { text-align: right; font-variant-numeric: tabular-nums; }

.league .col-rank {
  position: relative; width: 46px; padding-left: 14px; text-align: right;
  color: var(--muted); font-weight: 700;
}
.league td.col-rank[data-zone]::before {
  content: ""; position: absolute; left: 0; top: 7px; bottom: 7px;
  width: 4px; border-radius: 2px; background: var(--muted);
}
.league td.col-rank[data-zone="up"]::before { background: var(--green); }
.league td.col-rank[data-zone="up-rel"]::before { background: #7fae2f; }
.league td.col-rank[data-zone="down-rel"]::before { background: #e0912a; }
.league td.col-rank[data-zone="down"]::before { background: var(--accent); }

.league th.col-team, .league td.col-team { width: 99%; text-align: left; white-space: normal; }
.league td.col-team { font-weight: 600; color: var(--ink); }
.league .col-points { font-family: var(--font-display); font-weight: 800; color: var(--ink); }

.league .trend { margin-left: 8px; font-size: .72rem; font-weight: 700; }
.league .trend.up { color: var(--green); }
.league .trend.down { color: var(--accent); }

.league tr.is-own td { background: var(--accent-soft); }
.league tr.is-own:hover td { background: rgba(226, 20, 26, .16); }
.league tr.is-own .col-team { color: var(--accent-dark); }

.table-legend {
  list-style: none; margin: 18px 0 0; padding: 0;
  display: flex; flex-wrap: wrap; gap: 8px 22px; font-size: .82rem; color: var(--muted);
}
.table-legend li { display: flex; align-items: center; gap: 8px; }
.table-legend li::before {
  content: ""; width: 10px; height: 10px; border-radius: 3px; background: var(--muted);
}
.table-legend li[data-zone="up"]::before { background: var(--green); }
.table-legend li[data-zone="up-rel"]::before { background: #7fae2f; }
.table-legend li[data-zone="down-rel"]::before { background: #e0912a; }
.table-legend li[data-zone="down"]::before { background: var(--accent); }

@media (max-width: 640px) {
  .league { font-size: .9rem; }
  .league .col-opt { display: none; }
  .league th, .league td { padding: 11px 6px; }
}

/* ---------- Info-Boxen ---------- */

.info-list { list-style: none; margin: 0; padding: 0; }
.info-list li { display: flex; gap: 14px; padding: 16px 0; border-bottom: 1px solid var(--line); }
.info-list li:last-child { border-bottom: 0; }
.info-list strong { min-width: 132px; color: var(--ink); font-family: var(--font-display); font-size: .95rem; }

.notice {
  background: var(--accent-soft); border-left: 3px solid var(--accent);
  padding: 18px 22px; border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
}

.steps { list-style: none; counter-reset: s; margin: 0; padding: 0; display: grid; gap: 14px; }
.steps li {
  counter-increment: s; position: relative; padding: 18px 20px 18px 64px;
  background: var(--white); border-radius: var(--radius-sm); box-shadow: var(--shadow);
  font-weight: 600; color: var(--ink);
}
.steps li::before {
  content: counter(s); position: absolute; left: 18px; top: 50%; transform: translateY(-50%);
  width: 32px; height: 32px; border-radius: 50%; background: var(--accent); color: #fff;
  display: grid; place-items: center; font-family: var(--font-display); font-size: .95rem;
}

/* ---------- Footer ---------- */

.site-footer { background: var(--ink); color: rgba(255, 255, 255, .68); padding: 72px 0 0; font-size: .95rem; }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr 1fr; gap: 40px; padding-bottom: 56px; }
@media (max-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer h4 {
  color: #fff; font-size: .8rem; letter-spacing: .16em; text-transform: uppercase; margin-bottom: 18px;
}
.site-footer a { color: rgba(255, 255, 255, .78); }
.site-footer a:hover { color: var(--accent); }
.footer-brand img { height: 54px; width: auto; margin-bottom: 18px; }
.footer-brand p { max-width: 320px; color: rgba(255, 255, 255, .55); }
.footer-links { list-style: none; margin: 0 0 18px; padding: 0; }
.footer-links li { margin-bottom: 9px; }
.ig { display: inline-flex; align-items: center; gap: 8px; font-size: .86rem; }
.footer-bottom {
  display: flex; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 22px 24px; border-top: 1px solid rgba(255, 255, 255, .1);
  font-size: .82rem; color: rgba(255, 255, 255, .45);
}

/* ---------- Animationen ---------- */

.reveal { opacity: 0; transform: translateY(26px); transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .3, 1); }
.reveal.in { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  * { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
  html { scroll-behavior: auto; }
}

.empty {
  text-align: center; padding: 60px 20px; color: var(--muted);
  border: 2px dashed var(--line); border-radius: var(--radius);
}

.pagination { display: flex; justify-content: center; gap: 10px; margin-top: 46px; }
.pagination a, .pagination span {
  min-width: 44px; height: 44px; display: grid; place-items: center; padding: 0 14px;
  border-radius: var(--radius-sm); background: var(--white); color: var(--ink);
  box-shadow: var(--shadow); font-weight: 700; font-size: .9rem;
}
.pagination .current { background: var(--ink); color: #fff; }

/* ---------- Matchcenter auf der Startseite ---------- */

.matchbar {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2px;
  background: var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-lg);
}
.matchbar[data-cards="1"] { grid-template-columns: 1fr; }
.matchbar[data-cards="2"] { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 900px) { .matchbar, .matchbar[data-cards="2"] { grid-template-columns: 1fr; } }

.mb-card {
  position: relative;
  background: var(--white);
  padding: 26px 26px 22px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.mb-card::before {
  content: ""; position: absolute; inset: 0 auto 0 0; width: 3px; background: transparent;
}
.mb-result[data-outcome="win"]::before { background: var(--green); }
.mb-result[data-outcome="draw"]::before { background: #c9a227; }
.mb-result[data-outcome="loss"]::before { background: var(--accent); }

.mb-label {
  display: flex; align-items: baseline; justify-content: space-between; gap: 12px;
  margin: 0 0 2px;
  font-size: .72rem; font-weight: 800; letter-spacing: .16em; text-transform: uppercase;
  color: var(--ink);
}
.mb-label span {
  font-weight: 700; letter-spacing: .08em; color: var(--muted); text-align: right;
}
.mb-where {
  background: var(--ink); color: #fff !important;
  padding: 3px 10px; border-radius: 100px; letter-spacing: .1em; font-size: .66rem;
}

.mb-score {
  display: grid; grid-template-columns: 1fr auto 1fr;
  align-items: center; gap: 12px; margin: 4px 0;
}
.mb-team {
  font-family: var(--font-display); font-size: .98rem; line-height: 1.2; color: var(--muted);
  hyphens: auto;
}
.mb-score .mb-team:last-child { text-align: right; }
.mb-team.is-own { color: var(--ink); }
.mb-goals {
  font-family: var(--font-display); font-size: 2rem; line-height: 1;
  color: var(--ink); white-space: nowrap;
}
.mb-goals i { font-style: normal; color: var(--muted); margin: 0 3px; }
.mb-outcome { color: var(--ink); }

.mb-opponent {
  margin: 0; font-family: var(--font-display); font-size: 1.45rem;
  line-height: 1.15; color: var(--ink); letter-spacing: -.02em;
}
.mb-when { margin: 0; font-size: .95rem; color: var(--ink); font-weight: 600; }
.mb-note { margin: 0; font-size: .84rem; color: var(--muted); line-height: 1.5; }

.mb-rank-row { margin: 0; display: flex; align-items: baseline; gap: 8px; }
.mb-rank-row strong {
  font-family: var(--font-display); font-size: 2.6rem; line-height: 1; color: var(--accent);
}
.mb-rank-row span { font-size: .78rem; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); }

.mb-links { margin-top: auto; padding-top: 6px; display: flex; flex-wrap: wrap; gap: 4px 20px; }
.mb-links .mb-link { margin-top: 0; padding-top: 0; }

.mb-link {
  margin-top: auto; padding-top: 6px;
  font-size: .74rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase;
  color: var(--ink);
  display: inline-flex; align-items: center; gap: 7px;
}
.mb-link::after {
  content: ""; width: 18px; height: 7px; background: currentColor;
  clip-path: polygon(0 40%, 70% 40%, 70% 0, 100% 50%, 70% 100%, 70% 60%, 0 60%);
  transition: transform .2s ease;
}
.mb-link:hover { color: var(--accent); }
.mb-link:hover::after { transform: translateX(3px); }

.mb-stale { margin: 14px 2px 0; font-size: .8rem; color: var(--muted); }

/* ---------- Tabelle + Daten: zwei Spalten ---------- */

.data-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
  gap: 26px;
  align-items: start;
}
@media (max-width: 1000px) { .data-grid { grid-template-columns: 1fr; } }

.data-side { display: grid; gap: 22px; }
.dp-card { padding: 24px 26px; }
.dp-card + .dp-card { margin-top: 0; }

.dp-match + .dp-match { margin-top: 22px; padding-top: 22px; border-top: 1px solid var(--line); }
.dp-teams {
  margin: 6px 0 8px; font-family: var(--font-display); font-size: 1.25rem;
  line-height: 1.25; color: var(--ink); letter-spacing: -.02em;
}
.dp-teams span {
  display: block; font-family: var(--font); font-size: .74rem; font-weight: 700;
  letter-spacing: .16em; text-transform: uppercase; color: var(--muted); margin: 3px 0;
}
.dp-last[data-outcome="win"] .mb-goals { color: var(--green); }
.dp-last[data-outcome="loss"] .mb-goals { color: var(--accent); }

.table-scroll { overflow-x: auto; }

/* Kader */
.squad-table { width: 100%; border-collapse: collapse; font-size: .9rem; }
.squad-table th {
  text-align: left; padding: 8px 8px; font-size: .68rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted); border-bottom: 1px solid var(--line);
}
.squad-table td { padding: 7px 8px; border-bottom: 1px solid var(--line); }
.squad-table tr:last-child td { border-bottom: 0; }
.squad-table .num { text-align: right; }
.squad-table .sq-num { color: var(--muted); width: 34px; font-variant-numeric: tabular-nums; }
.squad-table .sq-name { color: var(--ink); font-weight: 600; }
.squad-table .sq-goals { font-weight: 700; color: var(--ink); }
.squad-table .sq-head th {
  padding-top: 16px; color: var(--accent); border-bottom: 0; font-size: .66rem;
}

/* Spielplan */
.fixture-table { width: 100%; border-collapse: collapse; font-size: .94rem; }
.fixture-table th {
  text-align: left; padding: 10px 12px; font-size: .68rem; letter-spacing: .1em;
  text-transform: uppercase; color: var(--muted); border-bottom: 1px solid var(--line);
}
.fixture-table td { padding: 11px 12px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.fixture-table tr:last-child td { border-bottom: 0; }
.fixture-table tr.is-next { background: var(--accent-soft); }
.fixture-table tr.is-next ~ tr.is-next { background: none; }
.fx-date { white-space: nowrap; color: var(--ink); font-weight: 600; font-size: .88rem; }
.fx-date span { display: block; font-weight: 400; color: var(--muted); font-size: .8rem; }
.fx-teams { color: var(--ink); }
.fx-teams i { color: var(--muted); font-style: normal; }
.fx-comp { display: block; font-size: .76rem; color: var(--muted); }
.fx-result {
  font-family: var(--font-display); font-size: 1.05rem; white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
tr[data-outcome="win"] .fx-result { color: var(--green); }
tr[data-outcome="loss"] .fx-result { color: var(--accent); }
.fx-link a { font-size: .78rem; font-weight: 700; white-space: nowrap; }
@media (max-width: 620px) { .fx-comp, .fixture-table th:last-child, .fx-link { display: none; } }

/* ---------- Cookie-Hinweis ---------- */

.consent {
  position: fixed; inset: 0; z-index: 300;
  display: grid; place-items: center; padding: 24px;
  background: rgba(8, 10, 14, .72);
  backdrop-filter: blur(3px);
}
.consent[hidden] { display: none; }

.consent-card {
  width: 100%; max-width: 560px;
  background: var(--white); border-radius: var(--radius);
  padding: clamp(26px, 4vw, 40px);
  box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .7);
}
.consent-card h2 { font-size: 1.5rem; text-transform: uppercase; margin-bottom: .5em; }
.consent-card p { font-size: .96rem; color: var(--text); }
.consent-card p:last-of-type { margin-bottom: 0; }
.consent-actions { display: flex; flex-wrap: wrap; gap: 12px; margin: 22px 0 18px; }
.consent-actions .btn { flex: 1 1 auto; justify-content: center; }
.consent-links { font-size: .84rem; color: var(--muted); }
.consent-links a { color: var(--muted); text-decoration: underline; text-underline-offset: 3px; }
.consent-links a:hover { color: var(--accent); }
body.consent-open { overflow: hidden; }

/* ---------- Interner Bereich ---------- */

.intern-gate { max-width: 520px; }
.intern-gate form { margin-top: 8px; }

.intern-nav { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.intern-nav a {
  display: inline-flex; align-items: center; padding: 9px 16px;
  border-radius: 100px; background: var(--white); box-shadow: var(--shadow);
  color: var(--ink); font-size: .82rem; font-weight: 700;
  letter-spacing: .06em; text-transform: uppercase;
}
.intern-nav a:hover { color: var(--accent); }
.intern-nav a.is-active { background: var(--ink); color: #fff; }
.intern-nav .intern-out { margin-left: auto; background: none; box-shadow: none; color: var(--muted); }
.intern-nav .intern-out:hover { color: var(--accent); }

/* Dokumentlinks im Text bekommen automatisch ein Download-Aussehen */
.intern-page a[href^="/intern/datei/"] {
  display: inline-flex; align-items: center; gap: 9px;
  padding: 9px 16px 9px 13px; margin: 2px 0;
  background: var(--accent-soft); border-radius: var(--radius-sm);
  color: var(--accent-dark); font-weight: 600; text-decoration: none;
}
.intern-page a[href^="/intern/datei/"]::before {
  content: ""; width: 15px; height: 18px; flex: none;
  background: currentColor;
  -webkit-mask: var(--doc-icon) center / contain no-repeat;
  mask: var(--doc-icon) center / contain no-repeat;
}
.intern-page a[href^="/intern/datei/"]:hover { background: rgba(226, 20, 26, .18); }
.intern-page h2 { font-size: clamp(1.35rem, 2.4vw, 1.75rem); margin-top: 1.9em; }
.intern-page h2:first-child { margin-top: 0; }
.intern-page h3 { font-size: 1.15rem; }
.intern-page li { margin-bottom: 8px; }
.intern-page hr { border: 0; border-top: 1px solid var(--line); margin: 34px 0; }

:root {
  --doc-icon: url("data:image/svg+xml;charset=utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8l-6-6Zm0 2.5L17.5 8H14V4.5ZM8 13h8v1.6H8V13Zm0 3.2h8v1.6H8v-1.6ZM8 9.8h4v1.6H8V9.8Z'/%3E%3C/svg%3E");
}

.doc-list { list-style: none; margin: 18px 0 0; padding: 0; display: grid; gap: 10px; }
.doc-list a {
  display: flex; align-items: center; gap: 14px;
  padding: 13px 18px; border-radius: var(--radius-sm);
  background: var(--paper); color: var(--ink); font-weight: 600;
}
.doc-list a:hover { background: var(--accent-soft); color: var(--accent-dark); }
.doc-kind {
  flex: none; min-width: 52px; text-align: center; padding: 3px 8px;
  border-radius: 6px; background: var(--ink); color: #fff;
  font-family: var(--font-display); font-size: .68rem; letter-spacing: .08em;
}
.doc-name { flex: 1; }
.doc-size { flex: none; color: var(--muted); font-weight: 500; font-size: .85rem; }

/* ---------- Hinweisfenster auf der Startseite ---------- */

.notice-pop {
  position: fixed; inset: 0; z-index: 250;
  display: grid; place-items: center; padding: 24px;
  background: rgba(8, 10, 14, .68);
}
.notice-pop[hidden] { display: none; }

.notice-pop-card {
  position: relative;
  width: 100%; max-width: 460px;
  background: var(--white); border-radius: var(--radius); overflow: hidden;
  box-shadow: 0 40px 90px -30px rgba(0, 0, 0, .7);
  animation: notice-in .32s cubic-bezier(.2, .7, .3, 1);
}
@keyframes notice-in {
  from { opacity: 0; transform: translateY(14px) scale(.98); }
  to   { opacity: 1; transform: none; }
}
.notice-pop-img { width: 100%; height: 180px; object-fit: cover; }
.notice-pop-body { padding: 26px 28px 30px; }
.notice-pop-body h2 { font-size: 1.45rem; margin-bottom: .45em; }
.notice-pop-body p { font-size: .95rem; color: var(--muted); margin-bottom: 22px; }

.notice-pop-close {
  position: absolute; top: 12px; right: 12px; z-index: 2;
  width: 36px; height: 36px; border: 0; border-radius: 50%; cursor: pointer;
  background: rgba(10, 12, 16, .55); color: #fff; font-size: 1.4rem; line-height: 1;
}
.notice-pop-close:hover { background: var(--accent); }
