/* kobi.Glas – gemeinsame Grundlage für die eigenständigen Seiten (Website, Turnierplaner, Turnier-Seite, Admin App).
   Wirkt nur mit html.kg (Schalter kobi_glas, gesetzt von /kobi-glas.js im Kopf). html.kg-solid = Glas-Effekte aus.
   Seiten nutzen die Variablen --bg, --surface, --fg, --muted, --line, --acc (Website-Standard); die App hat einen eigenen Block.
   Regeln: Nachschlage-Seite /kobi-glas.html. Druck bleibt flach und hell. */
@media screen {
  html.kg {
    --kg-edge: rgba(255,255,255,.8); --kg-hi: rgba(255,255,255,.95);
    --kg-lg: rgba(255,255,255,.24); --kg-lg-strong: rgba(255,255,255,.6);
    --kg-sky: linear-gradient(180deg, color-mix(in srgb, var(--acc, #3169F3) 10%, #EEF2F7) 0%, #F1F4F6 55%, #EEF1EA 100%);
    --surface: rgba(255,255,255,.74); --bg: transparent;
    --kg-chalk: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 10' preserveAspectRatio='none'%3E%3Cpath d='M1.2 6.6 C 22 4.2, 58 3.6, 98.6 4.4 C 99.6 4.5, 99.7 5.9, 98.7 6 C 60 6.2, 26 7.2, 1.8 8.6 C 0.4 8.7, 0 6.8, 1.2 6.6 Z' fill='%23000'/%3E%3C/svg%3E");
    background: var(--kg-sky) fixed;
  }
  html.kg[data-theme="dark"] {
    --kg-edge: rgba(255,255,255,.1); --kg-hi: rgba(255,255,255,.24);
    --kg-lg: rgba(255,255,255,.07); --kg-lg-strong: rgba(20,32,54,.7);
    --kg-sky: linear-gradient(180deg, color-mix(in srgb, var(--acc, #4A7BE0) 18%, #07101E) 0%, #0B1628 55%, #10190F 100%);
    --surface: rgba(20,30,48,.72); --bg: transparent;
  }
  @media (prefers-color-scheme: dark) {
    html.kg:not([data-theme="light"]) {
      --kg-edge: rgba(255,255,255,.1); --kg-hi: rgba(255,255,255,.24);
      --kg-lg: rgba(255,255,255,.07); --kg-lg-strong: rgba(20,32,54,.7);
      --kg-sky: linear-gradient(180deg, color-mix(in srgb, var(--acc, #4A7BE0) 18%, #07101E) 0%, #0B1628 55%, #10190F 100%);
      --surface: rgba(20,30,48,.72); --bg: transparent;
    }
  }
  html.kg body { background: transparent; }
  /* Bolzplatz: Spielfeldlinien in Kreide, Himmel nach Tageszeit (html.kg-t-morgen|tag|abend|nacht, setzt das Kopf-Skript), dunkel = immer Nacht mit Flutlicht */
  html.kg { --kg-pitch: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 400 800' preserveAspectRatio='xMidYMid slice'%3E%3Cg fill='none' stroke='%23fff' stroke-width='2' vector-effect='non-scaling-stroke'%3E%3Crect x='20' y='20' width='360' height='760' rx='3'/%3E%3Cline x1='20' y1='400' x2='380' y2='400'/%3E%3Ccircle cx='200' cy='400' r='62'/%3E%3Ccircle cx='200' cy='400' r='3' fill='%23fff'/%3E%3Crect x='90' y='20' width='220' height='120'/%3E%3Crect x='145' y='20' width='110' height='45'/%3E%3Cpath d='M150 140 a56 56 0 0 0 100 0'/%3E%3Crect x='90' y='660' width='220' height='120'/%3E%3Crect x='145' y='735' width='110' height='45'/%3E%3Cpath d='M150 660 a56 56 0 0 1 100 0'/%3E%3C/g%3E%3C/svg%3E"); --kg-pitch-w: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 700' preserveAspectRatio='xMidYMid slice'%3E%3Cg fill='none' stroke='%23fff' stroke-width='2' vector-effect='non-scaling-stroke'%3E%3Crect x='20' y='20' width='1160' height='660' rx='3'/%3E%3Cline x1='600' y1='20' x2='600' y2='680'/%3E%3Ccircle cx='600' cy='350' r='90'/%3E%3Ccircle cx='600' cy='350' r='4' fill='%23fff'/%3E%3Crect x='20' y='190' width='170' height='320'/%3E%3Crect x='20' y='275' width='65' height='150'/%3E%3Cpath d='M190 290 a80 80 0 0 1 0 120'/%3E%3Crect x='1010' y='190' width='170' height='320'/%3E%3Crect x='1115' y='275' width='65' height='150'/%3E%3Cpath d='M1010 290 a80 80 0 0 0 0 120'/%3E%3C/g%3E%3C/svg%3E"); }
  html.kg.kg-t-morgen:not([data-theme="dark"]) { --kg-sky: radial-gradient(70vmax 50vmax at -8% 6%, rgba(255,196,138,.55), transparent 60%), linear-gradient(180deg, color-mix(in srgb, var(--acc, #3169F3) 6%, #FBE6D4) 0%, #F4EEE9 40%, #EEF2EA 100%); }
  html.kg.kg-t-tag:not([data-theme="dark"]) { --kg-sky: radial-gradient(60vmax 45vmax at 102% -6%, rgba(255,250,225,.9), transparent 60%), linear-gradient(180deg, color-mix(in srgb, var(--acc, #3169F3) 12%, #E2ECF8) 0%, #EEF3F8 45%, #EDF2E8 100%); }
  html.kg.kg-t-abend:not([data-theme="dark"]) { --kg-sky: radial-gradient(70vmax 50vmax at 108% 10%, rgba(255,157,107,.5), transparent 60%), linear-gradient(180deg, color-mix(in srgb, var(--acc, #3169F3) 6%, #F7D3B8) 0%, #ECDDE3 32%, #EEEBF0 60%, #E9EEE5 100%); }
  html.kg.kg-t-nacht:not([data-theme="dark"]) { --kg-sky: radial-gradient(55vmax 45vmax at -6% -10%, rgba(255,240,200,.55), transparent 60%), radial-gradient(55vmax 45vmax at 106% -10%, rgba(255,240,200,.5), transparent 60%), linear-gradient(180deg, color-mix(in srgb, var(--acc, #3169F3) 14%, #D9E0EE) 0%, #E6EAF2 45%, #E8EDE6 100%); }
  html.kg::before { content: ""; position: fixed; inset: 0; z-index: -1; pointer-events: none; background: var(--kg-pitch) center / cover no-repeat; opacity: .8;
    -webkit-mask: linear-gradient(rgba(0,0,0,.35), #000 45%); mask: linear-gradient(rgba(0,0,0,.35), #000 45%); }
  @media (min-aspect-ratio: 1/1) { html.kg::before { background-image: var(--kg-pitch-w); } }
  html.kg::after { content: ""; position: fixed; inset: 55% 0 0 0; z-index: -1; pointer-events: none; background: linear-gradient(180deg, transparent, rgba(96,140,84,0.13)); }
  html.kg[data-theme="dark"]::before { opacity: .14; -webkit-mask: none; mask: none; }
  html.kg[data-theme="dark"]::after { inset: 0; background: radial-gradient(60vmax 60vmax at -10% -25%, rgba(255,248,220,0.14), transparent 60%), radial-gradient(60vmax 60vmax at 110% -25%, rgba(255,248,220,0.12), transparent 60%), linear-gradient(180deg, transparent 55%, rgba(40,90,50,0.18)); }
  /* System dunkel (Seiten ohne data-theme): Tageszeit-Himmel aus, immer Nacht */
  @media (prefers-color-scheme: dark) {
    html.kg:is(.kg-t-morgen, .kg-t-tag, .kg-t-abend, .kg-t-nacht):not([data-theme="light"]) { --kg-sky: linear-gradient(180deg, color-mix(in srgb, var(--acc, #4A7BE0) 18%, #07101E) 0%, #0B1628 55%, #10190F 100%); }
    html.kg:not([data-theme="light"])::before { opacity: .14; -webkit-mask: none; mask: none; }
    html.kg:not([data-theme="light"])::after { inset: 0; background: radial-gradient(60vmax 60vmax at -10% -25%, rgba(255,248,220,0.14), transparent 60%), radial-gradient(60vmax 60vmax at 110% -25%, rgba(255,248,220,0.12), transparent 60%), linear-gradient(180deg, transparent 55%, rgba(40,90,50,0.18)); }
  }
  /* Bausteine zum Wiederverwenden: Milchglas (Inhalt), Liquid Glass (Bedienung) */
  html.kg .kg-milk { background: var(--surface); -webkit-backdrop-filter: blur(22px) saturate(160%); backdrop-filter: blur(22px) saturate(160%);
    box-shadow: inset 0 0 0 1px var(--kg-edge), inset 0 1px 0 var(--kg-hi), 0 14px 34px -18px rgba(18,40,60,.35); }
  html.kg .kg-lg { background: var(--kg-lg-strong); -webkit-backdrop-filter: blur(16px) saturate(190%); backdrop-filter: blur(16px) saturate(190%);
    box-shadow: inset 0 1.5px 0 var(--kg-hi), inset 0 0 0 1px var(--kg-edge), 0 10px 26px -14px rgba(18,40,60,.45); }
  /* Kopfzeile der Seiten = Liquid Glass */
  html.kg body > header, html.kg .kg-head { background: var(--kg-lg-strong) !important; -webkit-backdrop-filter: blur(16px) saturate(190%); backdrop-filter: blur(16px) saturate(190%);
    box-shadow: inset 0 -1px 0 var(--kg-edge), 0 10px 26px -18px rgba(18,40,60,.35) !important; border-color: transparent !important; }
  /* Kreide: ein Wort pro Überschrift (Website), Klasse kg-u oder em in .kg-chalk-em */
  html.kg :is(.kg-u, .kg-chalk-em em) { position: relative; white-space: nowrap; color: var(--acc, #3169F3); font-style: normal; }
  html.kg :is(.kg-u, .kg-chalk-em em)::after { content: ""; position: absolute; left: -3%; right: -3%; bottom: -.14em; height: .2em; background: var(--acc, #3169F3);
    -webkit-mask: var(--kg-chalk) no-repeat center / 100% 100%; mask: var(--kg-chalk) no-repeat center / 100% 100%; }
  /* Glas für Karten der Seiten: Klasse kg-card (oder Seiten-Klassen in der Seite selbst) */
  html.kg .kg-card { -webkit-backdrop-filter: blur(22px) saturate(160%); backdrop-filter: blur(22px) saturate(160%); box-shadow: inset 0 0 0 1px var(--kg-edge), inset 0 1px 0 var(--kg-hi), 0 14px 34px -18px rgba(18,40,60,.35); }
  /* Lesbarkeit: Textblöcke der Seiten (Kapitelkopf, Text neben Bild, Hero-Text) liegen auf Milchglas statt direkt auf den Kreidelinien.
     Neue Seite → ihre Textblock-Klasse hier in die Liste. Fließtext in den Blöcken dunkler (--muted), am Handy kleinere Kapitelabstände. */
  html.kg :is(.sec-head, .chap-head, .tp-txt, .sx-t, .ex-t, .hero-grid > div:first-child, .tp-hero-grid > div:first-child, .cv-hero-txt, .jl-hero-txt, .ai-hero-txt, .hb-head) {
    --muted: #434c68; background: var(--surface); border-radius: 22px; padding: 22px 20px; box-sizing: border-box;
    -webkit-backdrop-filter: blur(14px) saturate(1.1); backdrop-filter: blur(14px) saturate(1.1);
    box-shadow: inset 0 0 0 1px var(--kg-edge), inset 0 1px 0 var(--kg-hi), 0 10px 30px -14px rgba(20,25,60,.28); }
  html.kg[data-theme="dark"] :is(.sec-head, .chap-head, .tp-txt, .sx-t, .ex-t, .hero-grid > div:first-child, .tp-hero-grid > div:first-child, .cv-hero-txt, .jl-hero-txt, .ai-hero-txt, .hb-head) { --muted: #c4cbe0; }
  @media (prefers-color-scheme: dark) {
    html.kg:not([data-theme="light"]) :is(.sec-head, .chap-head, .tp-txt, .sx-t, .ex-t, .hero-grid > div:first-child, .tp-hero-grid > div:first-child, .cv-hero-txt, .jl-hero-txt, .ai-hero-txt, .hb-head) { --muted: #c4cbe0; }
  }
  /* Fußzeile der Turnier-/Vereinsseiten („Wir sehen uns am kobi.“) liegt sonst direkt auf den Kreidelinien */
  html.kg footer.tz-foot { background: var(--surface); border-radius: 22px; padding: 14px 18px; max-width: 560px; margin-inline: auto; box-sizing: border-box;
    -webkit-backdrop-filter: blur(14px) saturate(1.1); backdrop-filter: blur(14px) saturate(1.1);
    box-shadow: inset 0 0 0 1px var(--kg-edge), inset 0 1px 0 var(--kg-hi), 0 10px 30px -14px rgba(20,25,60,.28); }
  html.kg .tp-feat.hl .tp-txt { background: none; box-shadow: none; padding: 0; -webkit-backdrop-filter: none; backdrop-filter: none; }
  html.kg :is(.sec-head, .chap-head) { margin-bottom: 20px; }
  @media (min-width: 701px) { html.kg :is(.sec-head, .chap-head, .tp-txt, .sx-t, .ex-t, .hero-grid > div:first-child, .tp-hero-grid > div:first-child, .cv-hero-txt, .jl-hero-txt, .ai-hero-txt, .hb-head) { padding: 28px 30px; } }
  @media (max-width: 700px) { html.kg section:not(.hero):not(.tp-hero) { padding-block: 36px; } }
  /* Logo: Kurzform (Schriftzug, o = Mittelkreis), Hauptlogo Spielfeld in .kg-dmk */
  html:is(.kg,.kv) .kobi-wm { font-family: "Barlow Condensed", system-ui, sans-serif; font-weight: 800; letter-spacing: 0; align-items: center; }
  html:is(.kg,.kv) .kobi-wm:not([style*="color"]) { color: var(--fg, var(--text, #14213D)); }
  html:is(.kg,.kv) .kobi-wm { font-family: 'Barlow', 'Barlow Condensed', system-ui, sans-serif; font-weight: 800; font-style: italic; letter-spacing: -.05em; }
  html:is(.kg,.kv) .kobi-wm .kobi-o { width:.597em; height:.597em; margin:0 calc(-.0625em + var(--wg,-.008em)) 0 calc(-.063em + var(--wg,-.008em)); transform: translateY(.132em); color: var(--acc, #3169F3); }
  html:is(.kg,.kv) footer .kobi-wm:not([style*="color"]), html:is(.kg,.kv) .foot .kobi-wm:not([style*="color"]) { color: var(--acc, #3169F3); }
  .kg-dmk { display: inline-block; line-height: 0; vertical-align: middle; --dl: var(--acc, #3169F3); --dt: var(--fg, var(--text, #14213D)); }
  .kg-dmk svg { display: block; width: auto; overflow: visible; }
  /* Antippen (Rand) + Flutlicht-Schein, am Element selbst */
  .kg-tap { position: fixed; z-index: 9990; pointer-events: none; box-shadow: inset 0 0 0 1.5px color-mix(in srgb, var(--acc, #3169F3) 55%, transparent), 0 0 18px 0 color-mix(in srgb, var(--acc, #3169F3) 22%, transparent); opacity: 0; animation: kgTap 740ms cubic-bezier(.25,.7,.3,1) forwards; }
  @keyframes kgTap { 0% { opacity: 0; } 18% { opacity: 1; } 100% { opacity: 0; } }
  .kg-glow { animation: kgGlow 1400ms cubic-bezier(.3,.6,.3,1); }
  @keyframes kgGlow { 0% { box-shadow: var(--kg-bs), 0 0 0 1.5px transparent, 0 0 0 0 transparent; }
    30% { box-shadow: var(--kg-bs), 0 0 0 1.5px color-mix(in srgb, var(--acc, #3169F3) 60%, transparent), 0 0 16px 0 color-mix(in srgb, var(--acc, #3169F3) 22%, transparent); }
    100% { box-shadow: var(--kg-bs), 0 0 0 1.5px transparent, 0 0 16px 0 transparent; } }
  /* Glas-Effekte aus: feste Flächen, gleiche Farben */
  html.kg.kg-solid { --surface: #FFFFFF; --kg-lg: #F7F9FB; --kg-lg-strong: #FFFFFF; }
  html.kg.kg-solid[data-theme="dark"] { --surface: #172036; --kg-lg: #1B2638; --kg-lg-strong: #172036; }
  html.kg.kg-solid * { -webkit-backdrop-filter: none !important; backdrop-filter: none !important; }
  /* Ruhige Abschnitte (seit 2026-11-10): eine Fläche je Abschnitt (.pane) statt Kasten je Überschrift und Kachel.
     Seite: Inhalt eines Abschnitts in <div class="pane">; Kacheln darin macht die Seite selbst flach (html .pane.pane :is(…)). */
  .pane { background: var(--surface, #fff); color: var(--fg, inherit); border-radius: 28px; padding: clamp(20px, 3.6vw, 44px); box-sizing: border-box; box-shadow: var(--shadow, var(--glass-shadow, 0 10px 28px rgba(20,33,61,.08))); }
  html.kg .pane { --muted: #434c68; -webkit-backdrop-filter: blur(22px) saturate(160%); backdrop-filter: blur(22px) saturate(160%); box-shadow: inset 0 0 0 1px var(--kg-edge), inset 0 1px 0 var(--kg-hi), 0 14px 34px -18px rgba(18,40,60,.35); }
  html.kg[data-theme="dark"] .pane { --muted: #c4cbe0; }
  @media (prefers-color-scheme: dark) { html.kg:not([data-theme="light"]) .pane { --muted: #c4cbe0; } }
  html body .pane.pane.pane.pane :is(.sec-head, .chap-head, .tp-txt, .sx-t, .sx-h, .ex-t) { background: none; box-shadow: none; padding: 0; border-radius: 0; -webkit-backdrop-filter: none; backdrop-filter: none; }
}
@media (prefers-reduced-motion: reduce) { .kg-tap { display: none; } .kg-glow { animation: none; } }
@media print { html.kg, html.kg body { background: #fff !important; } html.kg::before, html.kg::after { display: none !important; } .kg-glow { animation: none !important; } .kg-tap { display: none !important; } }
/* Logo auf hellem Grund: Lücken etwas kleiner (dunkle Schrift auf hellem Grund wirkt luftiger als helle auf dunklem Grund); weiße Flächen-Logos setzen --wg:0 */
.kobi-wm > span:last-child{letter-spacing:calc(-.05em + var(--wg,-.008em));margin-right:calc(-1 * var(--wg,-.008em))}
html[data-theme="dark"] .kobi-wm{--wg:0em}
@media (prefers-color-scheme:dark){html:not([data-theme="light"]) .kobi-wm{--wg:0em}}
/* Phosphor-Symbole der Website (Sprite /kobi-phosphor.svg, erzeugt von design/kobi/build_phosphor_web.py): gefüllt statt Linie */
svg.phi{fill:currentColor!important;stroke:none!important}
/* Ruhiger Hintergrund (html.kg-bg, nur Seiten mit data-bg am Skript: Vereinsportal, Admin App) – einfarbig statt Bolzplatz und Himmel */
@media screen {
  html.kg.kg-bg.kg-bg-creme:not([data-theme="dark"]) { --kg-sky: linear-gradient(180deg, #FAF6EE 0%, #F5F0E5 100%); }
  html.kg.kg-bg.kg-bg-grau:not([data-theme="dark"]) { --kg-sky: linear-gradient(180deg, #F4F5F7 0%, #EDEFF2 100%); }
  html.kg.kg-bg.kg-bg-salbei:not([data-theme="dark"]) { --kg-sky: linear-gradient(180deg, #F0F4EE 0%, #E6ECE3 100%); }
  html.kg.kg-bg[data-theme="dark"] { --kg-sky: linear-gradient(180deg, #1E1D1B 0%, #191817 100%); }
  html.kg.kg-bg::before, html.kg.kg-bg::after { display: none !important; }
}
