/* ============================================================
   LIVE-SEITE · ROT-GLANZ (Weiß-Rot) + Schnellfilter, Suche, Schwerpunkt/Weitere
   Nur Optik fuer /live/. Dunkelmodus: data-theme="dark".
   ============================================================ */
/* ---------- Tages-Slider ---------- */
html body .live-tag-chip { border-radius: 14px; transition: transform .15s, box-shadow .15s; }
html body .live-tag-chip:hover { transform: translateY(-1px); box-shadow: 0 4px 12px rgba(206,44,44,.18); }
html body .live-tag-chip.aktiv {
    background-color: #CE2C2C; border-color: #ff5a4a;
    background-image: linear-gradient(180deg, rgba(255,255,255,.22), rgba(255,255,255,.04) 50%, rgba(0,0,0,.08) 51%), linear-gradient(180deg, #CE2C2C, #A82222);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.3), 0 0 14px rgba(255,40,30,.45);
}

/* ---------- Werkzeugleiste: Schnellfilter + Suche ---------- */
html body .live-werkzeuge { display: flex; flex-direction: column; gap: 10px; margin: 2px 0 10px; }
html body .live-tier-chips { display: flex; gap: 8px; overflow-x: auto; -webkit-overflow-scrolling: touch; padding: 2px 2px 6px; scrollbar-width: none; }
html body .live-tier-chips::-webkit-scrollbar { display: none; }
html body .live-tier-chip {
    flex: 0 0 auto; display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 999px; cursor: pointer;
    border: 1.5px solid rgba(206,44,44,.3); background: #fff; color: #CE2C2C; font: 800 .82rem/1 inherit; white-space: nowrap;
    transition: background .15s, box-shadow .15s, transform .12s;
}
html body .live-tier-chip b { font-weight: 800; padding: 2px 7px; border-radius: 999px; background: rgba(206,44,44,.1); font-size: .72rem; }
html body .live-tier-chip:hover { background: rgba(206,44,44,.06); }
html body .live-tier-chip:active { transform: scale(.96); }
html body .live-tier-chip.aktiv {
    color: #fff; border-color: #ff5a4a; background-color: #CE2C2C;
    background-image: linear-gradient(180deg, rgba(255,255,255,.22), rgba(255,255,255,.04) 50%, rgba(0,0,0,.08) 51%), linear-gradient(180deg, #CE2C2C, #A82222);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.3), 0 0 14px rgba(255,40,30,.45);
}
html body .live-tier-chip.aktiv b { background: rgba(255,255,255,.22); color: #fff; }
html body .live-tier-live .live-jetzt-punkt { background: #d81414; box-shadow: 0 0 8px 2px rgba(216,20,20,.5); }
html body .live-tier-live.aktiv .live-jetzt-punkt { background: #fff; box-shadow: 0 0 8px 2px rgba(255,255,255,.7); }
html body .live-suche { position: relative; display: block; }
html body .live-suche i { position: absolute; left: 14px; top: 50%; transform: translateY(-50%); color: #CE2C2C; pointer-events: none; }
html body .live-suche input {
    width: 100%; box-sizing: border-box; padding: 11px 14px 11px 40px; border-radius: 999px; font-size: 16px;
    border: 1.5px solid rgba(206,44,44,.28); background: #fff; color: inherit; outline: none; transition: box-shadow .15s, border-color .15s;
}
html body .live-suche input:focus { border-color: #CE2C2C; box-shadow: 0 0 0 4px rgba(206,44,44,.12), 0 0 18px rgba(255,40,30,.25); }

/* ---------- Filter-Zustaende ---------- */
html body .live-aus-tier { display: none !important; }
html body .fb-match-wrap.live-aus-suche { display: none !important; }

/* ---------- Abschnitte ---------- */
html body .live-abschnitt-titel, html body .live-weitere summary {
    display: flex; align-items: center; gap: 10px; margin: 18px 2px 10px; font-size: 1rem; font-weight: 800; color: #CE2C2C;
}
html body .live-abschnitt-titel i { color: #CE2C2C; filter: drop-shadow(0 0 6px rgba(255,60,50,.6)); }
html body .live-abschnitt-titel span, html body .live-weitere summary span { margin-left: auto; font-size: .78rem; font-weight: 700; color: #8a7a7a; }
html body .live-weitere { margin-top: 10px; }
html body .live-weitere summary { cursor: pointer; list-style: none; padding: 12px 16px; margin: 6px 0 12px; border-radius: 14px; background: rgba(206,44,44,.06); border: 1px solid rgba(206,44,44,.22); }
html body .live-weitere summary::-webkit-details-marker { display: none; }
html body .live-weitere summary:hover { background: rgba(206,44,44,.1); }
html body .live-weitere-pfeil { transition: transform .2s; }
html body .live-weitere[open] .live-weitere-pfeil { transform: rotate(90deg); }

/* ---------- Liga-Bloecke ---------- */
html body .live-liga-block { border-radius: 16px; box-shadow: 0 0 0 1px rgba(206,44,44,.2), 0 8px 24px rgba(206,44,44,.12); }
html body .live-liga-kopf {
    position: relative; padding: 12px 16px; background-color: #CE2C2C;
    background-image: linear-gradient(180deg, rgba(255,255,255,.2) 0%, rgba(255,255,255,.05) 48%, rgba(0,0,0,.08) 50%, rgba(0,0,0,0) 100%), linear-gradient(180deg, #CE2C2C 0%, #CE2C2C 50%, #A82222 100%);
    box-shadow: inset 0 1px 0 rgba(255,255,255,.28), inset 0 -1px 0 rgba(0,0,0,.25);
}
html body .live-liga-kopf::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: -1px; height: 2px; pointer-events: none;
    background: linear-gradient(90deg, rgba(255,60,50,.3), #ff5a4a 50%, rgba(255,60,50,.3)); filter: drop-shadow(0 0 4px rgba(255,70,60,.9));
}
html body .live-liga-kopf:hover { text-decoration: none; }
html body .live-liga-anzahl { margin-left: auto; padding: 2px 10px; border-radius: 999px; background: rgba(0,0,0,.25); border: 1px solid rgba(255,255,255,.25); font-size: .72rem; font-weight: 700; white-space: nowrap; }
html body .live-liga-block-jetzt { border: 2px solid #d81414; box-shadow: 0 0 0 1px rgba(216,20,20,.3), 0 0 22px rgba(216,20,20,.3); }
html body .live-jetzt-titel { color: #CE2C2C; }
html body .live-jetzt-punkt { background: #d81414; box-shadow: 0 0 8px 2px rgba(216,20,20,.45); }

/* ---------- Spielzeilen ---------- */
html body .fb-match { transition: background .15s; }
html body a.fb-match-klickbar:hover { background: rgba(206,44,44,.07); }
html body .fb-match.fb-rwe { background: linear-gradient(90deg, rgba(206,44,44,.16), rgba(206,44,44,.04) 70%, transparent); box-shadow: inset 4px 0 0 #CE2C2C; }
html body .fb-match-score {
    min-width: 66px; padding: 5px 12px; border-radius: 10px; color: #fff; font-variant-numeric: tabular-nums; letter-spacing: .03em;
    background-image: linear-gradient(180deg, #CE2C2C, #A82222); box-shadow: inset 0 1px 0 rgba(255,255,255,.35), 0 0 12px rgba(255,40,30,.4);
}
html body .fb-match-time { min-width: 66px; padding: 5px 10px; border-radius: 10px; background: rgba(128,128,128,.14); color: inherit; opacity: .85; font-weight: 700; font-variant-numeric: tabular-nums; }
html body .spiel-live-badge.live, html body .fb-live-badge { background: #d81414; box-shadow: 0 0 10px rgba(216,20,20,.6); }

/* ---------- Dunkelmodus ---------- */
:root[data-theme="dark"] .live-tier-chip, :root[data-theme="dark"] .live-suche input { background: #241c1c; }
:root[data-theme="dark"] .live-tier-chip { color: #ff8a7a; border-color: rgba(255,120,100,.4); }
:root[data-theme="dark"] .live-abschnitt-titel, :root[data-theme="dark"] .live-weitere summary, :root[data-theme="dark"] .live-jetzt-titel { color: #ff8a7a; }
:root[data-theme="dark"] .live-suche i { color: #ff8a7a; }

/* ---------- Handy ---------- */
@media (max-width: 640px) {
    html body .live-tier-chip { padding: 8px 12px; font-size: .78rem; }
    html body .live-liga-kopf { padding: 11px 12px; }
    html body .live-liga-anzahl { padding: 2px 8px; font-size: .68rem; }
    html body .fb-match { padding: 12px 10px; gap: 6px; }
    html body .fb-match-score, html body .fb-match-time { min-width: 54px; padding: 4px 8px; font-size: .84rem; }
}
@media (prefers-reduced-motion: reduce) { html body .live-tier-chip, html body .live-tag-chip, html body .live-weitere-pfeil { transition: none; } }

/* ===== Lesbarkeit 2026-11-20: Namen umbrechen, Mindestschrift, Desktop-Zeilen straffen ===== */
@media (max-width: 600px) {
    html body .fb-match-team span { white-space: normal; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; line-height: 1.2; word-break: break-word; }
    html body .live-liga-anzahl { font-size: .75rem; }
    html body .live-tag-chip .live-tag-datum { font-size: .75rem; }
    html body .spiel-nur-endergebnis { font-size: .72rem !important; }
}
@media (min-width: 900px) {
    html body .fb-match { max-width: 760px; margin: 0 auto; }
}

/* ===== Live-Umbau 2026-11-20 ===== */
/* Spielanzahl-Pille weg */
html body .live-liga-anzahl { display: none !important; }

/* Schmaler Liga-Balken */
html body .live-liga-kopf { padding: 6px 12px; gap: 7px; font-size: .8rem; line-height: 1.2; }
html body .live-liga-kopf::after { height: 1px; }
html body .live-liga-logo, html body .live-liga-logo-platz { width: 18px; height: 18px; }
html body .live-liga-flagge { font-size: .9rem; }
html body .live-liga-kopf .live-liga-runde { font-size: .72rem; }
html body .live-liga-block { margin-bottom: .9rem; border-radius: 14px; }
html body .fb-match { padding-top: 9px; padding-bottom: 9px; }

/* Status: Live = gruen, vor dem Spiel = normal, nach dem Spiel = Ergebnis normal */
html body .fb-match-score { background-image: none; box-shadow: none; background: rgba(128,128,128,.14); color: inherit; font-weight: 800; opacity: 1; }
html body .fb-match-score.fb-score-live {
    color: #fff; background-image: linear-gradient(180deg, #34b957, #1e8e3e); box-shadow: inset 0 1px 0 rgba(255,255,255,.3), 0 0 12px rgba(40,167,69,.45);
}
html body .fb-match.fb-match-live { background: linear-gradient(90deg, rgba(40,167,69,.14), rgba(40,167,69,.03) 70%, transparent); box-shadow: inset 4px 0 0 #28a745; }
html body .spiel-live-badge.live, html body .fb-live-badge { background: #28a745; box-shadow: 0 0 10px rgba(40,167,69,.55); }
html body .live-liga-block-jetzt { border: 2px solid #28a745; box-shadow: 0 0 0 1px rgba(40,167,69,.3), 0 0 22px rgba(40,167,69,.28); }
html body .live-jetzt-titel { color: #1e8e3e; }
html body .live-jetzt-punkt, html body .live-tier-live .live-jetzt-punkt { background: #28a745; box-shadow: 0 0 8px 2px rgba(40,167,69,.5); }
html body .live-tier-live.aktiv .live-jetzt-punkt { background: #fff; }

/* Werkzeugleiste: ein Liga-Button + Vereinssuche in einer Zeile */
html body .live-werkzeuge { margin: 2px 0 12px; }
html body .live-leiste { display: flex; gap: 8px; align-items: center; }
html body .live-leiste .live-suche { flex: 1 1 auto; min-width: 0; }
html body .live-leiste .live-suche input { padding-top: 10px; padding-bottom: 10px; }
html body .live-liga-btn {
    flex: 0 1 auto; display: inline-flex; align-items: center; gap: 8px; min-height: 44px; max-width: 55%; padding: 0 14px; border-radius: 999px; cursor: pointer;
    border: 1.5px solid rgba(206,44,44,.3); background: #fff; color: #CE2C2C; font: 800 .86rem/1 inherit; white-space: nowrap;
}
html body .live-liga-btn span { overflow: hidden; text-overflow: ellipsis; }
html body .live-liga-btn.aktiv { color: #fff; border-color: #ff5a4a; background: linear-gradient(180deg, #CE2C2C, #A82222); }
html body .live-liga-btn-pfeil { font-size: .7rem; opacity: .8; }

/* Auswahlfenster */
html body .live-panel { position: fixed; inset: 0; z-index: 100000; display: flex; align-items: flex-end; justify-content: center; background: rgba(0,0,0,.5); }
html body .live-panel[hidden] { display: none; }
html body .live-panel-box { width: 100%; max-width: 680px; max-height: 88vh; display: flex; flex-direction: column; gap: 10px; padding: 14px 14px calc(14px + env(safe-area-inset-bottom)); background: #fff; color: #222; border-radius: 20px 20px 0 0; box-shadow: 0 -10px 40px rgba(0,0,0,.3); }
html body .live-panel-kopf { display: flex; align-items: center; justify-content: space-between; font-size: 1.05rem; }
html body .live-panel-kopf button { width: 44px; height: 44px; border: 0; border-radius: 50%; background: rgba(128,128,128,.15); color: inherit; cursor: pointer; font-size: 1rem; }
html body .live-panel .live-tier-chips { padding: 0; }
html body .live-panel .live-liga-filter {
    display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; overflow-y: auto; padding: 2px; margin: 0; flex: 1 1 auto; min-height: 120px; -webkit-overflow-scrolling: touch;
}
html body .live-panel .live-filter-chip, html body .live-panel .live-filter-chip.live-filter-alle {
    width: auto; height: auto; border-radius: 14px; flex-direction: column; justify-content: flex-start; gap: 6px; padding: 10px 6px; min-height: 92px;
    border: 2px solid #eee; background: #fff; color: #333; font-weight: 700; font-size: .74rem; white-space: normal; text-align: center; position: relative;
}
html body .live-filter-logo { width: 38px; height: 38px; display: flex; align-items: center; justify-content: center; font-size: 1.3rem; color: #CE2C2C; }
html body .live-filter-logo img { width: 36px; height: 36px; object-fit: contain; }
html body .live-filter-name { line-height: 1.2; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; word-break: break-word; }
html body .live-panel .live-filter-chip.aktiv, html body .live-panel .live-filter-chip.live-filter-alle.aktiv { border-color: #CE2C2C; background: rgba(206,44,44,.07); color: #CE2C2C; }
html body .live-panel .live-filter-chip.aktiv::after { content: '\f00c'; font-family: 'Font Awesome 5 Free', 'Font Awesome 6 Free'; font-weight: 900; position: absolute; top: 5px; right: 7px; font-size: .65rem; color: #CE2C2C; }
html body .live-liga-leer { grid-column: 1 / -1; text-align: center; color: #888; padding: 1rem; }
html body .live-panel-fertig { min-height: 48px; border: 0; border-radius: 999px; cursor: pointer; font: 800 1rem/1 inherit; color: #fff; background: linear-gradient(180deg, #CE2C2C, #A82222); }
html body.live-panel-offen { overflow: hidden; }
@media (min-width: 700px) {
    html body .live-panel { align-items: center; }
    html body .live-panel-box { border-radius: 20px; max-height: 80vh; }
}
@media (max-width: 480px) { html body .live-liga-btn { padding: 0 12px; max-width: 48%; } }
:root[data-theme="dark"] .live-panel-box { background: #1d1717; color: #eee; }
:root[data-theme="dark"] .live-panel .live-filter-chip { background: #241c1c; border-color: #3a2e2e; color: #eee; }
:root[data-theme="dark"] .live-liga-btn { background: #241c1c; color: #ff8a7a; }
html body .live-panel .live-tier-chips, html body .live-panel .live-panel-suche, html body .live-panel-kopf { flex: 0 0 auto; }
html body .live-panel .live-tier-chip { flex: 0 0 auto; min-height: 40px; }
html body .live-filter-name { -webkit-line-clamp: 3; word-break: normal; overflow-wrap: anywhere; hyphens: auto; }
html body .live-liga-btn { max-width: 100%; }
