/* =====================================================================
   BETROX terminal · view-categories.css — Sportarten · Fußball-Kategorien ·
   Kategorie · Alle Kategorien (TERMINAL-CATEGORIES.md, refs 14–17).
   Prefix .cat-*. Lists, checkboxes, tabs and the sticky bar reuse the
   Top-Ligen component (.tl-* in view-home.css); only additions here.
   ===================================================================== */

.cat { width: 100%; max-width: 1160px; margin: 0 auto; display: flex; flex-direction: column; }
.cat-main { min-width: 0; display: flex; flex-direction: column; }
.cat .vh { margin-bottom: 14px; }
.cat .vh-ic .cat-ic { width: 40px; height: 40px; border-radius: 10px; }
.cat-body { display: flex; flex-direction: column; }

/* landscape: [sports sidebar | main] */
.cat--side {
  max-width: none; display: grid; grid-template-columns: 280px minmax(0, 1fr); column-gap: 20px; align-items: start;
}
@media (max-width: 1500px) { .cat--side { grid-template-columns: 240px minmax(0, 1fr); column-gap: 16px; } }
.cat-side {
  position: sticky; top: 0; z-index: 3; padding: 14px;
  border-radius: var(--r-lg); background: var(--card); border: 1px solid var(--line);
}
.cat-side .cat-sports { padding-top: 0; border-top: 0; }

/* rounded category icon: medal / globe / flag */
.cat-ic {
  position: relative; flex-shrink: 0; display: flex; align-items: center; justify-content: center;
  width: 60px; height: 60px; border-radius: 14px; overflow: hidden;
}
.cat-ic::after {   /* hairline so dark / white flags keep an edge */
  content: ''; position: absolute; inset: 0; border-radius: inherit; pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .12);
}
.cat-ic--top { background: linear-gradient(180deg, #2A2414, #17150C); color: var(--accent); }
.cat-ic--top .bx-ic { stroke-width: 1.8; }
.cat-ic--int { background: linear-gradient(180deg, #2D64D8, #1A45A8); color: #FFF; }
.cat-ic--int .bx-ic { stroke-width: 1.8; }
.cat-ic--flag { background: var(--tile); }
.cat .cat-ic.cat-ic--flag .flag { display: block; width: 100%; height: 100%; border-radius: 0; }   /* beats the phone .tl-open .flag size */

/* tools row: meta + "Alle Kategorien öffnen" (link) / "Alle auswählen" */
.cat-tools { min-height: 44px; }
.cat-openall {
  display: inline-flex; align-items: center; gap: 10px; min-height: var(--bx-tap); padding: 0 10px; margin-right: -10px;
  border-radius: var(--r); color: var(--accent); text-decoration: none;
  font-family: var(--cond); font-weight: 700; font-size: 22px; letter-spacing: .04em; text-transform: uppercase; white-space: nowrap;
  touch-action: manipulation;
}
.cat-openall:hover { background: var(--tile); }
.cat-openall.is-btn {
  margin: 0; padding: 0 22px; border: 1px solid var(--line-3); background: var(--tile); color: var(--ink);
}
.cat-openall.is-btn .bx-ic { color: var(--accent); }
.cat-openall.is-btn:hover { background: var(--tile-hover); }

/* partly ticked category */
.cat .tl-check[aria-checked="mixed"] .tl-box { background: var(--accent-tint); border-color: var(--accent); color: var(--accent); }
.cat .tl-row.is-mixed { border-color: var(--accent-line); }

/* ---- category rows (portrait / phone) ---- */
.cat-row .tl-open { gap: 18px; padding-left: 14px; }

/* ---- category tile grid (landscape, ref 17) ---- */
.cat-grid { display: grid; grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 1500px) { .cat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.cat-tile {
  display: flex; flex-direction: column; align-items: center; gap: 4px; min-width: 0;
  padding: 16px 6px 8px; border-radius: var(--r-lg); border: 1px solid var(--line); background: var(--card);
  transition: background-color .15s ease, border-color .15s ease;
}
.cat-tile.is-on { background: var(--accent-tint); border-color: var(--accent-line); }
.cat-tile.is-mixed { border-color: var(--accent-line); }
.cat-tile-open {   /* flag + name = one link */
  display: flex; flex-direction: column; align-items: center; max-width: 100%;
  color: var(--ink); text-decoration: none; touch-action: manipulation;
}
.cat-tile-ic { display: block; border-radius: 26px; transition: transform .08s ease; }
.cat-tile-ic .cat-ic { width: 112px; height: 112px; border-radius: 26px; box-shadow: 0 6px 18px rgba(0, 0, 0, .35); }
.cat-tile-open:active .cat-tile-ic { transform: scale(.96); }
.cat-tile-open:hover .cat-ic::after { box-shadow: inset 0 0 0 2px var(--accent); }
.cat-tile-nm {
  max-width: 100%; margin-top: 6px; padding: 0 4px;
  text-align: center;
  font-size: 19px; font-weight: 700; line-height: 1.15;
  overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.cat-tile .tl-check { min-height: var(--bx-tap); padding: 0 14px; margin-top: auto; }

/* ---- all categories: group headers ---- */
.cat-grp + .cat-grp { margin-top: 22px; }
.cat-gh {
  display: flex; align-items: center; gap: 12px; margin: 6px 4px 10px;
  font-family: var(--cond); font-weight: 800; font-size: 26px; letter-spacing: .05em; text-transform: uppercase;
}
.cat-gh a { display: inline-flex; align-items: center; gap: 14px; min-height: var(--bx-tap); color: var(--ink); text-decoration: none; }   /* ≥ 64 px kiosk tap */
.cat-gh a:hover { color: var(--accent); }
.cat-gh .cat-ic { width: 44px; height: 44px; border-radius: 11px; }
.cat-gn { margin-left: auto; font-family: var(--sans, inherit); font-size: 16px; font-weight: 700; letter-spacing: 0; text-transform: none; color: var(--muted); }

/* ---- sports list (#/sportarten portrait / phone, ref 14) ---- */
.cat-slist { display: flex; flex-direction: column; gap: 8px; margin-top: 14px; }
.cat-srow {
  display: flex; align-items: center; gap: 18px; min-height: 92px; padding: 0 18px 0 14px;
  border-radius: var(--r); background: var(--card); border: 1px solid var(--line);
  color: var(--ink); text-decoration: none; touch-action: manipulation;
}
a.cat-srow:hover { background: var(--tile); }
a.cat-srow:hover > .bx-ic { color: var(--accent); }
.cat-sic {
  flex-shrink: 0; display: flex; align-items: center; justify-content: center; width: 60px; height: 60px;
  border-radius: 14px; background: var(--tile); color: var(--accent);
}
.cat-snm { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; }
.cat-snm b { font-size: 24px; font-weight: 700; line-height: 1.15; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cat-snm small { font-size: 15px; font-weight: 600; color: var(--muted); }
.cat-sn { font-family: var(--cond); font-size: 28px; font-weight: 700; }
.cat-srow > .bx-ic { flex-shrink: 0; color: var(--muted); }
.cat-srow.is-off { cursor: default; color: var(--muted-2); background: transparent; }
.cat-srow.is-off .cat-sic { color: var(--muted-2); background: var(--card); }
.cat-srow.is-off .cat-snm small, .cat-srow.is-off .cat-sn { color: var(--muted-2); }
.cat-srow.is-off > .bx-ic { opacity: .35; }

/* =====================================================================
   Phone (≤ 760)
   ===================================================================== */
body.is-phone .cat .vh-ic .cat-ic { width: 32px; height: 32px; border-radius: 8px; }
body.is-phone .cat-openall { min-height: 44px; font-size: 17px; }
body.is-phone .cat-tools { min-height: 44px; }
body.is-phone .cat-row .tl-open { gap: 12px; padding-left: 10px; }
body.is-phone .cat-row .cat-ic { width: 44px; height: 44px; border-radius: 11px; }
body.is-phone .cat-lrow .tl-open .flag { width: 30px; height: 20px; }
body.is-phone .cat-gh { font-size: 20px; gap: 10px; margin: 4px 2px 8px; }
body.is-phone .cat-gh a { gap: 10px; min-height: 44px; }
body.is-phone .cat-gh .cat-ic { width: 34px; height: 34px; border-radius: 9px; }
body.is-phone .cat-gn { font-size: 13px; }
body.is-phone .cat-grp + .cat-grp { margin-top: 16px; }
body.is-phone .cat-slist { gap: 6px; margin-top: 10px; }
body.is-phone .cat-srow { min-height: 64px; gap: 12px; padding: 0 10px; }
body.is-phone .cat-sic { width: 44px; height: 44px; border-radius: 11px; }
body.is-phone .cat-sic .bx-ic { width: 26px; height: 26px; }
body.is-phone .cat-snm b { font-size: 18px; }
body.is-phone .cat-snm small { font-size: 13px; }
body.is-phone .cat-sn { font-size: 20px; }
body.is-phone .cat-srow > .bx-ic { width: 22px; height: 22px; }
