/* VH Statistik – nutzt die Farben des Templates „hurricane“, mit Ersatzwerten */
.vhs {
  --s-surface: var(--vh-surface, #1e1230);
  --s-surface-2: var(--vh-surface-2, #2a1a42);
  --s-line: var(--vh-line, rgba(127, 127, 127, .25));
  --s-fg: var(--vh-fg, inherit);
  --s-muted: var(--vh-muted, #9b8fb0);
  --s-accent: var(--vh-orange, #f08a1c);
  --s-win: #2f9e5b;
  --s-draw: #a39a2d;
  --s-loss: #c8413b;
  --s-radius: var(--vh-radius, 12px);
  --s-display: var(--vh-font-display, "Barlow Condensed", "Arial Narrow", Arial, sans-serif);
  margin: 1rem 0 2rem;
  font-variant-numeric: tabular-nums;
}
.vhs h2, .vhs h3 { font-family: var(--s-display); text-transform: uppercase; letter-spacing: .03em; }
.vhs h3 { font-size: 1.15rem; margin: 1.6rem 0 .6rem; }

/* Kennzahlen */
.vhs-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 10px; margin: 0 0 1.25rem; }
.vhs-kpi { background: var(--s-surface); border: 1px solid var(--s-line); border-radius: var(--s-radius); padding: 14px 16px; }
.vhs-kpi b { display: block; font: 800 1.9rem/1.05 var(--s-display); color: var(--s-accent); }
.vhs-kpi span { display: block; margin-top: 4px; font-size: .8rem; color: var(--s-muted); }
.vhs-kpis--small .vhs-kpi { padding: 10px 12px; }
.vhs-kpis--small .vhs-kpi b { font-size: 1.5rem; }

/* Reiter */
.vhs-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 1rem; border-bottom: 1px solid var(--s-line); }
.vhs-tab {
  font: 700 1rem/1 var(--s-display); text-transform: uppercase; letter-spacing: .03em;
  background: none; border: 0; color: var(--s-muted); padding: 12px 14px; cursor: pointer;
  border-bottom: 3px solid transparent; margin-bottom: -1px;
}
.vhs-tab:hover { color: var(--s-fg); }
.vhs-tab[aria-selected="true"] { color: var(--s-fg); border-bottom-color: var(--s-accent); }
.vhs-tabs:not(.is-ready) { display: none; } /* ohne JS: alle Bereiche untereinander */
.vhs.is-tabbed .vhs-panel { display: none; }
.vhs.is-tabbed .vhs-panel.is-active { display: block; }
.vhs.is-tabbed .vhs-panel__title { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

/* Tabellen */
.vhs-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 0 1rem; }
.vhs-table { width: 100%; border-collapse: collapse; background: var(--s-surface); border: 1px solid var(--s-line); border-radius: var(--s-radius); overflow: hidden; font-size: .92rem; }
.vhs-table th, .vhs-table td { padding: 9px 10px; border-bottom: 1px solid var(--s-line); text-align: right; white-space: nowrap; }
.vhs-table thead th { font-size: .72rem; text-transform: uppercase; letter-spacing: .06em; color: var(--s-muted); background: var(--s-surface-2); }
.vhs-table th:first-child, .vhs-table td:last-child { text-align: left; }
.vhs-table--rank td:first-child { text-align: right; color: var(--s-muted); width: 3em; }
.vhs-table--rank th[scope="row"], .vhs-table tbody th { text-align: left; font-weight: 600; }
.vhs-table--rank td:last-child { text-align: right; }
.vhs-table tbody tr:last-child th, .vhs-table tbody tr:last-child td { border-bottom: 0; }
.vhs-table tbody tr:hover { background: var(--s-surface-2); }
.vhs-table a { color: inherit; text-decoration: none; border-bottom: 1px dotted currentColor; }
.vhs-table--compact { font-size: .88rem; margin-bottom: .8rem; }
.vhs-table--compact td:last-child { text-align: right; }
.vhs .is-pos { color: var(--s-win); }
.vhs .is-neg { color: var(--s-loss); }

/* Form-Kästchen */
.vhs-label { margin: .4rem 0 .4rem; font-size: .72rem; text-transform: uppercase; letter-spacing: .08em; color: var(--s-muted); }
.vhs-form { list-style: none; margin: 0 0 1rem; padding: 0; display: flex; flex-wrap: wrap; gap: 4px; }
.vhs-form a { display: grid; place-items: center; width: 24px; height: 24px; border-radius: 5px; font: 700 .72rem/1 var(--s-display); color: #fff; text-decoration: none; }
.vhs-form a:hover { outline: 2px solid var(--s-accent); outline-offset: 1px; }
.vhs .is-S { --c: var(--s-win); }
.vhs .is-U { --c: var(--s-draw); }
.vhs .is-N { --c: var(--s-loss); }
.vhs-form a, .vhs-badge { background: var(--c, #666); }

/* Torschützen */
.vhs-scorers { list-style: none; margin: 0; padding: 0; counter-reset: sc; }
.vhs-scorers li { display: flex; justify-content: space-between; gap: 10px; padding: 6px 0; border-bottom: 1px solid var(--s-line); counter-increment: sc; }
.vhs-scorers li span::before { content: counter(sc) ". "; color: var(--s-muted); }
.vhs-scorers b { color: var(--s-accent); }

/* Spiele */
.vhs-games { list-style: none; margin: .4rem 0 0; padding: 0; }
.vhs-games li { border-bottom: 1px solid var(--s-line); }
.vhs-games a { display: flex; align-items: center; gap: 10px; padding: 7px 2px; color: inherit; text-decoration: none; }
.vhs-games a:hover { background: var(--s-surface-2); }
.vhs-badge { flex: none; display: grid; place-items: center; width: 22px; height: 22px; border-radius: 5px; color: #fff; font: 700 .7rem/1 var(--s-display); }
.vhs-games__meta { flex: none; width: 9.5em; font-size: .78rem; color: var(--s-muted); }
.vhs-games__match { flex: 1; min-width: 0; }
.vhs-games__match b { color: var(--s-accent); margin-left: 4px; }
.vhs-games__att { flex: none; font-size: .85rem; color: var(--s-muted); }

/* Saisonen */
.vhs-season, .vhs-opp { background: var(--s-surface); border: 1px solid var(--s-line); border-radius: var(--s-radius); margin: 0 0 8px; }
.vhs-season > summary, .vhs-opp > summary { cursor: pointer; padding: 12px 16px; display: flex; flex-wrap: wrap; align-items: center; gap: 4px 14px; list-style: none; }
.vhs-season > summary::-webkit-details-marker, .vhs-opp > summary::-webkit-details-marker { display: none; }
.vhs-season > summary::after, .vhs-opp > summary::after { content: "▾"; margin-left: auto; color: var(--s-muted); }
.vhs-season[open] > summary::after, .vhs-opp[open] > summary::after { content: "▴"; }
.vhs-season > summary span:first-child, .vhs-opp__name { font: 700 1.1rem/1.1 var(--s-display); text-transform: uppercase; letter-spacing: .02em; }
.vhs-season__sum, .vhs-opp__rec { font-size: .85rem; color: var(--s-muted); }
.vhs-opp__rec b { color: var(--s-fg); }
.vhs-opp__rec .is-S { color: var(--s-win); }
.vhs-opp__rec .is-N { color: var(--s-loss); }
.vhs-season__body, .vhs-opp > .vhs-games { padding: 0 16px 14px; }
.vhs-box__grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 20px; }
@media (max-width: 720px) { .vhs-box__grid { grid-template-columns: 1fr; } .vhs-games__meta { width: auto; } }

/* Verhältnisbalken S/U/N */
.vhs-ratio { display: flex; width: 100%; height: 5px; border-radius: 3px; overflow: hidden; background: var(--s-surface-2); }
.vhs-ratio i { display: block; height: 100%; background: var(--c); }

/* Zuschauerbalken */
.vhs-bars { display: grid; gap: 6px; }
.vhs-bar { display: grid; grid-template-columns: 4em 1fr 6.5em; align-items: center; gap: 10px; font-size: .88rem; }
.vhs-bar__label { color: var(--s-muted); }
.vhs-bar__track { height: 14px; background: var(--s-surface-2); border-radius: 4px; overflow: hidden; }
.vhs-bar__fill { display: block; height: 100%; background: linear-gradient(90deg, var(--vh-violet, #6b2fb3), var(--s-accent)); border-radius: 4px; }
.vhs-bar__val { text-align: right; }

/* Rekorde */
.vhs-records { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 0 28px; }
.vhs-streaks { list-style: none; margin: 0; padding: 0; }
.vhs-streaks li { padding: 8px 0; border-bottom: 1px solid var(--s-line); }
.vhs-streaks b { font: 800 1.4rem/1 var(--s-display); color: var(--s-accent); margin-right: 6px; }
.vhs-streaks span { display: block; font-size: .8rem; color: var(--s-muted); margin-top: 2px; }

/* Saisonkasten */
.vhs-box { background: var(--s-surface); border: 1px solid var(--s-line); border-radius: var(--s-radius); padding: 16px 18px 6px; }
.vhs-box__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 6px 16px; margin-bottom: 12px; }
.vhs-box__head h2 { margin: 0; font-size: 1.35rem; }
.vhs-more { font-size: .85rem; font-weight: 600; color: var(--s-accent); text-decoration: none; }
.vhs-box .vhs-kpi { background: var(--s-surface-2); border: 0; }

.vhs-note { font-size: .8rem; color: var(--s-muted); margin: 1rem 0 0; }
.vhs .vh-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

:root[data-theme="light"] .vhs { --s-accent: #b4530a; }
.vhs-opp > summary::after { order: 2; }
.vhs-opp > summary .vhs-ratio { order: 3; flex-basis: 100%; }

/* Kompakter Kasten (Startseite, Seitenleiste) */
.vhs-box--compact { padding: 14px 14px 4px; margin: 0 0 1rem; }
.vhs-box__title { margin: 0 0 10px; font-size: 1.15rem; }
.vhs-box--compact .vhs-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin-bottom: .8rem; }
.vhs-box--compact .vhs-kpi { padding: 8px 10px; }
.vhs-box--compact .vhs-kpi b { font-size: 1.35rem; }
.vhs-box--compact .vhs-scorers li { padding: 4px 0; font-size: .9rem; }
.vhs-box--compact p { margin: .6rem 0; }

/* Bilanz gegen den Gegner am Ende eines Spielberichts */
.vhs-h2h { background: var(--s-surface); border: 1px solid var(--s-line); border-radius: var(--s-radius); padding: 16px 18px 10px; margin: 2rem 0 1.5rem; }
.vhs-h2h__head { display: flex; align-items: baseline; justify-content: space-between; gap: 6px 14px; flex-wrap: wrap; margin-bottom: 12px; }
.vhs-h2h__head h2 { margin: 0; font-size: 1.35rem; }
.vhs-h2h__since { font-size: .8rem; color: var(--s-muted); }
.vhs-h2h .vhs-kpi { background: var(--s-surface-2); border: 0; }
.vhs-h2h h3 { margin: 1.1rem 0 .3rem; font-size: 1rem; }
.vhs-h2h__more { margin: .8rem 0 .2rem; font-size: .9rem; }
