/* BadgeNews — dark StreamDatabase-style theme.
   Layout: fixed top bar, fixed left sidebar, content column, right stream drawer. */

:root {
  --bg: #000000;
  --panel: #18181b;
  --panel-2: #1f1f23;
  --panel-3: #26262c;
  --line: #2e2e33;
  --text: #efeff1;
  --muted: #adadb8;
  --label: #84848e;
  --accent: #fbd326;
  --accent-2: #dfb70c;
  --on-accent: #141410;
  --green: #3ddc63;
  --green-bar: #1ca24a;
  --gold: #ffc93d;
  --gold-bar: #d9a400;
  --red: #ff4b4b;
  --topbar-h: 60px;
  --sidebar-w: 250px;
  --drawer-w: 360px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-padding-top: calc(var(--topbar-h) + 10px); }

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
  padding-top: var(--topbar-h);
}

img { max-width: 100%; }
a { color: inherit; text-decoration: none; }
p a, dd a, .faq a, .ctx-list a, .ctx-h a { text-decoration: underline; text-underline-offset: 2px; }
p a:hover, dd a:hover, .ctx-list a:hover, .ctx-h a:hover { color: #fff; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 0.92em; }

.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--accent); color: var(--on-accent); padding: 8px 14px; font-weight: 700;
}
.skip-link:focus { left: 8px; top: 8px; }

.muted { color: var(--muted); }
.small { font-size: 13px; }

/* ---------------------------------------------------------------- top bar */

.topbar {
  position: fixed; top: 0; left: 0; right: 0; height: var(--topbar-h);
  background: var(--bg); z-index: 60;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 16px;
}

.icon-btn {
  background: none; border: 0; color: var(--text); cursor: pointer;
  width: 40px; height: 40px; border-radius: 6px;
  display: inline-flex; align-items: center; justify-content: center;
}
.icon-btn:hover { background: var(--panel-2); }
.icon-btn svg { width: 24px; height: 24px; }

.brand {
  position: absolute; left: 50%; transform: translateX(-50%);
  display: flex; align-items: center; gap: 10px;
}
.brand-logo {
  width: 38px; height: 38px; border-radius: 50%; background: var(--accent);
  display: inline-flex; align-items: center; justify-content: center; flex: none;
}
.brand-logo img { width: 30px; height: 30px; }
.brand-name {
  font-weight: 800; font-size: 15px; line-height: 1.1; letter-spacing: 0.4px;
  text-transform: uppercase; display: inline-block;
}

/* --------------------------------------------------------------- sidebar */

.sidebar {
  position: fixed; top: var(--topbar-h); left: 0; bottom: 0; width: var(--sidebar-w);
  background: var(--bg); z-index: 50; overflow-y: auto;
  padding: 14px 8px 24px;
  transition: transform 0.18s ease;
  display: flex; flex-direction: column;
}
.sidebar nav { flex: 1; }

.nav-item {
  display: flex; align-items: center; gap: 14px;
  padding: 10px 14px; border-radius: 8px; margin-bottom: 2px;
  font-weight: 800; font-size: 14px; letter-spacing: 0.5px; text-transform: uppercase;
}
.nav-item svg { width: 22px; height: 22px; flex: none; }
.nav-item .nav-ico { flex: none; }
/* portrait box art (Just Chatting): keep the 22px column, center it */
.nav-item .nav-ico-boxart { width: 17px; height: 24px; border-radius: 3px; margin: -1px 2.5px; }
.nav-item:hover { background: var(--panel-2); }
.nav-item.on { background: var(--panel-3); position: relative; }
.nav-item.on::before {
  content: ""; position: absolute; left: 0; top: 8px; bottom: 8px; width: 3px;
  background: #fff; border-radius: 2px;
}

.nav-sec {
  color: var(--muted); font-size: 12px; font-weight: 700; letter-spacing: 1px;
  text-transform: uppercase; padding: 16px 14px 6px;
}

/* mascot peeks out from behind the Watch on Twitch button */
.sidebar-cta-wrap { position: relative; margin: 84px 6px 0; }
.sidebar-mascot {
  position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%);
  width: 88px; height: 88px;
  z-index: 0; pointer-events: none; user-select: none;
}
.sidebar-cta {
  position: relative; z-index: 1;
  display: block; padding: 10px 12px; text-align: center;
  background: var(--accent); color: var(--on-accent); border-radius: 6px;
  font-weight: 800; font-size: 13px; letter-spacing: 0.5px; text-transform: uppercase;
}
.sidebar-cta:hover { background: var(--accent-2); }

/* ---------------------------------------------------------------- layout */

.layout {
  margin-left: var(--sidebar-w);
  transition: margin-left 0.18s ease;
}
.layout-inner {
  max-width: 1240px; padding: 10px 28px 70px;
}

body.nav-closed .sidebar { transform: translateX(-100%); }
body.nav-closed .layout { margin-left: 0; }

.backdrop {
  position: fixed; inset: var(--topbar-h) 0 0 0; background: rgba(0,0,0,0.6); z-index: 45;
}

@media (max-width: 1023px) {
  .layout { margin-left: 0; }
  .sidebar { transform: translateX(-100%); box-shadow: 4px 0 24px rgba(0,0,0,0.7); }
  body.nav-open .sidebar { transform: none; }
  body.nav-closed .sidebar { transform: translateX(-100%); }
  .brand-name { font-size: 13px; }
  .layout-inner { padding: 8px 14px 60px; }
}

/* --------------------------------------------------------------- banners */

.banner {
  display: flex; align-items: stretch; border-radius: 4px; overflow: hidden;
  margin: 6px 0; font-weight: 700; color: #fff;
}
.banner-link {
  flex: 1; display: flex; align-items: center; justify-content: center; gap: 10px;
  padding: 10px 14px; text-align: center;
}
.banner-link svg { width: 16px; height: 16px; flex: none; }
.banner-x {
  background: none; border: 0; color: #fff; cursor: pointer; font-size: 18px;
  padding: 0 14px; font-weight: 700;
}
.banner-x:hover, .banner-link:hover { filter: brightness(1.1); }
.banner-yellow { background: var(--accent); color: var(--on-accent); }
.banner-yellow .banner-x { color: var(--on-accent); }
.banner-green { background: #14a53c; }
.banner-black { background: #0d0d0d; border: 1px solid var(--line); }
.banner[hidden] { display: none; }

/* ---------------------------------------------------------- cookie notice */

.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 70;
  display: flex; align-items: center; justify-content: center; gap: 16px; flex-wrap: wrap;
  padding: 14px 18px; background: var(--panel-2); border-top: 1px solid var(--line);
  font-size: 14px;
}
.cookie-banner p { margin: 0; max-width: 720px; }
.cookie-banner a { color: var(--accent); text-decoration: underline; }
.cookie-banner .btn { flex: none; }
.cookie-banner[hidden] { display: none; }

/* ------------------------------------------------------------ breadcrumbs */

.crumb-row {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  margin: 14px 0 4px; flex-wrap: wrap;
}
.back-arrow {
  flex: none; width: 30px; height: 30px; border: 0; cursor: pointer; border-radius: 6px;
  background: var(--panel); color: var(--muted);
  display: inline-flex; align-items: center; justify-content: center;
}
.back-arrow:hover { background: var(--panel-2); color: #fff; }
.back-arrow svg { width: 18px; height: 18px; }
.back-arrow + .crumbs { flex: 1; }
.crumbs {
  font-size: 14px; font-weight: 700; letter-spacing: 0.5px; text-transform: uppercase;
  color: var(--muted);
}
.crumbs a:hover { color: #fff; }
.crumbs .sep { margin: 0 8px; color: var(--label); }
.crumbs [aria-current] { color: #fff; }
.crumb-social { display: flex; gap: 14px; align-items: center; }
.crumb-social a { color: var(--text); display: inline-flex; }
.crumb-social svg { width: 20px; height: 20px; }
.crumb-social a:hover { color: var(--accent); }

/* -------------------------------------------------------------- headings */

h1 {
  font-size: 34px; font-weight: 800; letter-spacing: 0.5px; text-transform: uppercase;
  margin: 6px 0 14px;
}
.page-sub { color: var(--muted); margin: -10px 0 18px; }

.sec-title {
  font-size: 24px; font-weight: 800; letter-spacing: 0.5px; text-transform: uppercase;
  margin: 26px 0 12px;
}
.sec-link {
  font-size: 13px; font-weight: 700; letter-spacing: 0.4px; color: var(--label);
  text-decoration: underline; text-underline-offset: 2px; vertical-align: middle; margin-left: 8px;
}
.sec-link:hover { color: var(--text); }

/* small neutral back button under the breadcrumbs */
.back-link {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 13px; font-weight: 700; letter-spacing: 0.4px; text-transform: uppercase;
  color: var(--muted); background: var(--panel); border-radius: 4px;
  padding: 6px 12px; margin: 2px 0 12px;
}
.back-link:hover { background: var(--panel-2); color: var(--text); }

/* ------------------------------------------------------------------ FAQ */

.faq { background: var(--panel); border-radius: 6px; padding: 16px 20px; margin-bottom: 18px; }
.faq dt {
  color: var(--label); font-weight: 800; font-size: 13.5px; letter-spacing: 0.5px;
  text-transform: uppercase; margin-top: 12px;
}
.faq dt:first-child { margin-top: 0; }
.faq dd { margin: 2px 0 0; }

/* ---------------------------------------------------------------- toolbar */

.toolbar {
  display: flex; align-items: flex-end; gap: 34px; flex-wrap: wrap;
  padding: 14px 2px 16px;
}
.toolbar .tb-field { display: flex; flex-direction: column; gap: 4px; }
.toolbar label {
  color: var(--label); font-size: 12.5px; font-weight: 800;
  letter-spacing: 0.8px; text-transform: uppercase;
}
.toolbar select, .toolbar input {
  background: none; border: 0; border-bottom: 1px solid var(--muted);
  color: var(--text); font-size: 15px; font-weight: 600; padding: 4px 2px;
  min-width: 150px; border-radius: 0;
}
.toolbar select:focus, .toolbar input:focus { outline: none; border-bottom-color: var(--accent); }
.toolbar select option { background: var(--panel); color: var(--text); }
.toolbar input::placeholder { color: var(--label); }
.tb-search { margin-left: auto; }
@media (max-width: 700px) { .tb-search { margin-left: 0; } }

.result-note { color: var(--muted); font-size: 13px; margin: 0 0 10px; }

/* ------------------------------------------------------------- badge rows */

.rows { display: flex; flex-direction: column; gap: 3px; }

.row {
  display: block; background: var(--panel); border-radius: 4px;
  padding: 14px 18px 16px;
}
.row:hover { background: var(--panel-2); }
.row[hidden] { display: none; }

.row-meta {
  display: flex; flex-wrap: wrap; gap: 8px 44px; margin-bottom: 8px;
  font-size: 13.5px; font-weight: 800; letter-spacing: 0.5px; text-transform: uppercase;
}
.row-meta .m { display: inline-flex; align-items: center; gap: 7px; }
.row-meta svg { width: 15px; height: 15px; flex: none; }
.m-green { color: var(--green); }
.m-grey { color: var(--muted); }
.m-red { color: var(--red); }
.row-meta .m-free { font-size: 17px; }

.row-title {
  display: flex; align-items: center; gap: 12px;
  font-size: 23px; font-weight: 800; letter-spacing: 0.5px; text-transform: uppercase;
  line-height: 1.2;
}
.row-title img { width: 44px; height: 44px; flex: none; }
@media (max-width: 700px) { .row-title { font-size: 18px; } .row-meta { gap: 6px 18px; } }

/* -------------------------------------------------------------- detail page */

.detail-cols {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 26px;
  align-items: start; margin-top: 10px;
}
@media (max-width: 900px) {
  .detail-cols { grid-template-columns: 1fr; }
  /* stacked (mobile) view: context reads first, availability after it */
  .detail-cols .col-avail { order: 2; }
}

.panel { background: var(--panel); border-radius: 6px; padding: 18px 20px; }

.pv-tabs {
  font-weight: 800; font-size: 15px; letter-spacing: 0.5px; text-transform: uppercase;
  margin-bottom: 14px; color: var(--label);
}
.pv-tabs button {
  background: none; border: 0; cursor: pointer; color: var(--label);
  font: inherit; letter-spacing: inherit; text-transform: inherit; padding: 0;
}
.pv-tabs button.on { color: #fff; }
.pv-tabs .sep { margin: 0 6px; }

.pv-stage { border-radius: 6px; padding: 30px 16px 22px; text-align: center; }
.pv-stage.light { background: #f7f7f8; color: #0e0e10; }

.pv-sizes { display: flex; align-items: flex-end; justify-content: center; gap: 34px; }
.pv-size { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.pv-size .pv-label { font-weight: 800; font-size: 14px; color: var(--muted); }
.pv-stage.light .pv-label { color: #53535f; }

.pv-chatline {
  margin-top: 26px; display: flex; align-items: center; justify-content: center; gap: 6px;
  font-size: 15px;
}
.pv-chatline img { width: 18px; height: 18px; }
.pv-chatline b { color: var(--accent); }

/* label/value field lists */
.fields div { margin-bottom: 14px; }
.fields dt {
  color: var(--label); font-weight: 800; font-size: 13px;
  letter-spacing: 0.8px; text-transform: uppercase;
}
.fields dd { margin: 1px 0 0; overflow-wrap: anywhere; }

/* availability */
.avail { padding: 0; overflow: hidden; }
.avail-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 10px;
  padding: 10px 16px; font-weight: 800; font-size: 16px; letter-spacing: 0.5px;
  text-transform: uppercase; color: #fff;
}
.avail-bar.st-active { background: var(--green-bar); }
.avail-bar.st-upcoming { background: var(--gold-bar); }
.avail-bar.st-ended { background: #c02626; }
.avail-bar.st-removed { background: #7f1d1d; }
.avail-bar.st-available { background: var(--accent); color: var(--on-accent); }
.avail-body { padding: 16px 16px 6px; }
.avail-body.has-cover { display: flex; gap: 18px; align-items: flex-start; }
.avail-body.has-cover .fields { flex: 1; min-width: 0; }
.avail-cover { flex: none; width: 150px; text-align: center; margin-bottom: 10px; }
.avail-cover img { display: block; width: 100%; height: auto; border-radius: 4px; }
.avail-cover span { display: block; margin-top: 5px; }
.avail-cover:hover span { color: var(--accent); text-decoration: underline; }
.avail-channels {
  display: flex; flex-wrap: wrap; gap: 4px 16px;
  max-height: 190px; overflow-y: auto; padding-right: 6px;
}
.avail-channels a {
  text-decoration: underline; text-underline-offset: 2px; font-weight: 600;
  display: inline-flex; align-items: center; gap: 6px;
}
.avail-channels a:hover { color: var(--accent); }
.ch-avatar { border-radius: 50%; flex: none; }
.avail-dates { display: grid; grid-template-columns: 1fr 1fr; }

/* eligible live streams (cards revealed by app.js when a channel is live) */
.live-channels[hidden] { display: none; }
.live-note { margin: 0 0 10px; }
.live-note a { text-decoration: underline; text-underline-offset: 2px; }
.live-cards { display: flex; flex-wrap: wrap; gap: 12px; }
.live-card {
  display: block; width: 220px; background: var(--panel-2); border-radius: 6px;
  overflow: hidden;
}
.live-card[hidden] { display: none; }
.live-card:hover { background: var(--panel-3); }
.live-thumb { position: relative; display: block; aspect-ratio: 16 / 9; background: #0d0d0d; }
.live-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.live-chip {
  position: absolute; top: 6px; left: 6px; z-index: 1; background: #e91916; color: #fff;
  font-size: 11px; font-weight: 800; letter-spacing: 0.5px; border-radius: 3px; padding: 1px 6px;
}
.live-name {
  display: flex; align-items: center; gap: 8px; padding: 8px 10px;
  font-weight: 700; font-size: 14px; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.live-card:hover .live-name { color: var(--accent); }

.tag {
  display: inline-block; background: var(--panel-3); color: var(--text);
  border-radius: 999px; padding: 2px 12px; font-size: 13px; font-weight: 700;
  margin-bottom: 10px;
}

.tag + .tag { margin-left: 6px; }

/* long words/URLs must wrap inside panels instead of overflowing */
.panel p, .panel .ctx-list li, .panel .ctx-h { overflow-wrap: anywhere; }

/* context markup: ### headings and - bullet lists */
.panel .ctx-h { font-size: 15px; font-weight: 800; margin: 12px 0 4px; }
.panel .ctx-list { margin: 8px 0; padding-left: 30px; }
.panel .ctx-list li { margin: 3px 0; }
.panel .ctx-list + p, .panel .ctx-h + p { margin-top: 6px; }
.panel .ctx-gap { height: 14px; }

.sources { margin: 0; padding-left: 20px; }
.sources li { margin: 4px 0; overflow-wrap: anywhere; }
.sources a { text-decoration: underline; text-underline-offset: 2px; }
.sources a:hover { color: var(--accent); }

.ctx-banner { margin: 14px 0 2px; }
.ctx-banner img { display: block; width: 100%; height: auto; border-radius: 4px; }
.ctx-banner figcaption { margin-top: 6px; }

/* ------------------------------------------------------------- home page */

.home-hero {
  display: flex; align-items: center; justify-content: center; gap: 18px;
  padding: 40px 0 30px;
}
.home-logo {
  width: 96px; height: 96px; border-radius: 50%; background: var(--accent);
  display: flex; align-items: center; justify-content: center; flex: none;
}
.home-logo img { width: 74px; height: 74px; }
.home-hero .home-name {
  font-size: 42px; font-weight: 800; letter-spacing: 1px; line-height: 1.05;
  text-transform: uppercase;
}
@media (max-width: 700px) {
  .home-hero { flex-direction: column; text-align: center; }
  .home-hero .home-name { font-size: 32px; }
}

.home-q { font-size: 26px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.5px; margin: 22px 0 6px; }

.notify-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 12px; margin: 16px 0 8px; max-width: 640px;
}
.notify-btn {
  display: flex; align-items: center; gap: 14px; border-radius: 6px; padding: 12px 16px;
  font-weight: 800; letter-spacing: 0.5px; color: #fff;
}
.notify-btn svg, .notify-btn img { width: 26px; height: 26px; flex: none; }
.notify-btn .nb-main { font-size: 16px; text-transform: uppercase; line-height: 1.2; }
.notify-btn .nb-sub { display: block; font-size: 12.5px; font-weight: 600; opacity: 0.85; text-transform: none; }
.notify-btn:hover { filter: brightness(1.12); }
.nb-yellow { background: var(--accent); color: var(--on-accent); }
.nb-dark { background: var(--panel-2); border: 1px solid var(--line); }

.tools-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px; margin-top: 6px;
}
.tool-card { background: var(--panel); border-radius: 6px; padding: 16px 18px; display: block; }
.tool-card:hover { background: var(--panel-2); }
.tool-card h3 { font-size: 16px; font-weight: 800; letter-spacing: 0.5px; text-transform: uppercase; }
.tool-card .tool-sub {
  color: var(--label); font-size: 12.5px; font-weight: 800; letter-spacing: 0.6px;
  text-transform: uppercase; margin: 2px 0 14px;
}
.tool-row { display: flex; align-items: center; gap: 10px; }
.tool-row img { width: 36px; height: 36px; }
.tool-row .tool-arrow { margin-left: auto; font-size: 22px; color: var(--text); }

/* -------------------------------------------------------- categories page */

.cat-tabs { display: flex; gap: 10px; flex-wrap: wrap; margin: 6px 0 18px; }
.cat-tab {
  background: var(--panel); border: 0; color: var(--muted); cursor: pointer;
  border-radius: 4px; padding: 8px 16px; font-weight: 800; font-size: 13.5px;
  letter-spacing: 0.5px; text-transform: uppercase;
}
.cat-tab:hover { background: var(--panel-2); color: var(--text); }
.cat-tab.on { background: var(--accent); color: var(--on-accent); }

.cat-grid {
  display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 16px 14px;
}
.cat-grid[hidden] { display: none; }

.cat-card { display: block; }
.cat-cover {
  position: relative; display: block; aspect-ratio: 264 / 374;
  background: var(--panel); border-radius: 6px; overflow: hidden;
}
.cat-cover img { width: 100%; height: 100%; object-fit: cover; display: block; }
.cat-card:hover .cat-cover { outline: 2px solid var(--accent); }
.cat-rank {
  position: absolute; top: 6px; left: 6px; background: rgba(0,0,0,0.75); color: #fff;
  border-radius: 4px; padding: 1px 7px; font-weight: 800; font-size: 12.5px;
}
.cat-rating {
  position: absolute; top: 6px; right: 6px; background: var(--accent); color: var(--on-accent);
  border-radius: 4px; padding: 1px 7px; font-weight: 800; font-size: 12.5px;
}
.cat-name {
  display: block; margin-top: 8px; font-weight: 800; font-size: 14px;
  letter-spacing: 0.3px; text-transform: uppercase; line-height: 1.25;
}
.cat-card:hover .cat-name { color: var(--accent); }
.cat-date { display: block; color: var(--muted); font-size: 12.5px; margin-top: 2px; }

/* ------------------------------------------------------------ events page */

.sched { padding: 16px 0 6px; margin-bottom: 26px; }
.sched-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 0 16px 10px; flex-wrap: wrap;
}
.sched-head h2 { font-size: 18px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.5px; }
.sched-legend { display: flex; align-items: center; gap: 16px; font-size: 13px; color: var(--text); flex-wrap: wrap; }
.leg { display: inline-flex; align-items: center; gap: 6px; }
.leg i { width: 12px; height: 12px; border-radius: 50%; display: inline-block; }
.leg .now-i { width: 3px; height: 14px; border-radius: 1px; background: #ff3b30; }
.leg .conf-i { background: var(--accent); }
.leg .spec-i { background: transparent; border: 1.5px dashed #9a9aa4; }

.sched-scroll { overflow-x: auto; }
.sched-inner { min-width: 760px; position: relative; }

.sched-days { display: flex; }
.sched-days span {
  flex: 1 0 0; padding: 8px 10px; font-weight: 800; font-size: 13.5px;
  border-left: 1px solid #101013;
}
.sched-days span:nth-child(odd) { background: #141417; }
.sched-days span:nth-child(even) { background: #0f0f11; }

.sched-rows { position: relative; padding: 4px 0 10px; }
.sched-stripes { position: absolute; inset: 0; display: flex; pointer-events: none; }
.sched-stripes i { flex: 1 0 0; border-left: 1px solid #101013; }
.sched-stripes i:nth-child(odd) { background: #141417; }
.sched-stripes i:nth-child(even) { background: #0f0f11; }

.sched-bar {
  position: relative; display: block; margin: 5px 0; min-height: 52px;
}
.sched-bar-in {
  position: absolute; top: 0; bottom: 0; border-radius: 6px;
  background: var(--bar, var(--accent)); color: var(--bar-text, var(--on-accent));
  padding: 0 12px 0 7px; overflow: hidden;
  display: flex; align-items: center; gap: 10px;
}
.sched-bar-in:hover { filter: brightness(1.12); }
.sched-bar-in.spec { border: 1.5px dashed currentColor; }
.sched-bar-in .sb-ico {
  flex: 0 0 auto; width: 38px; height: 38px; border-radius: 8px;
  background: #131316; display: flex; align-items: center; justify-content: center;
}
.sched-bar-in .sb-ico img { width: 28px; height: 28px; }
.sched-bar-in .sb-title {
  font-weight: 800; font-size: 14px; letter-spacing: 0.2px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

.sched-now {
  position: absolute; top: 0; bottom: 0; width: 2px; background: #ff3b30; z-index: 5;
  pointer-events: none;
}

.event-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.event-card { background: var(--panel); border-radius: 6px; overflow: hidden; display: block; }
.event-card:hover { background: var(--panel-2); }
.ec-bar {
  padding: 5px 14px; font-weight: 800; font-size: 13px; letter-spacing: 0.6px;
  text-transform: uppercase; color: #fff;
}
.ec-bar.live { background: var(--green-bar); }
.ec-bar.upcoming { background: var(--gold-bar); }
.ec-body { padding: 12px 14px 14px; }
.ec-title { display: flex; align-items: center; gap: 10px; font-size: 17px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.4px; }
.ec-title img { width: 24px; height: 24px; }
.ec-desc { color: var(--muted); font-size: 13.5px; margin-top: 6px; }
.ec-dates { display: grid; grid-template-columns: 1fr 1fr; margin-top: 12px; }
.ec-dates dt { color: var(--label); font-weight: 800; font-size: 12px; letter-spacing: 0.7px; text-transform: uppercase; }
.ec-dates dd { margin: 0; font-weight: 700; font-size: 14px; }

/* -------------------------------------------------------------- API docs */

pre {
  background: #0d0d0f; border: 1px solid var(--line); border-radius: 6px;
  padding: 12px 14px; overflow-x: auto; margin: 10px 0;
  font-size: 13.5px; line-height: 1.55;
}
.endpoint { margin-bottom: 14px; }
.endpoint .ep-head {
  display: flex; align-items: center; gap: 10px; margin-bottom: 6px;
  font-size: 15px; overflow-wrap: anywhere;
}
.method {
  background: var(--green-bar); color: #fff; border-radius: 4px; padding: 1px 9px;
  font-weight: 800; font-size: 12.5px; letter-spacing: 0.5px; flex: none;
}
.panel p + p { margin-top: 8px; }

/* ------------------------------------------------------------ legal pages */

.prose { max-width: 760px; }
.prose h1 { text-transform: none; font-size: 26px; letter-spacing: 0; }
.prose h2 { font-size: 18px; margin: 22px 0 6px; }
.prose p, .prose ul { margin: 12px 0; color: var(--text); }
.prose ul { padding-left: 22px; }

/* --------------------------------------------------------------- drawer */

.drawer {
  position: fixed; top: var(--topbar-h); right: 0; bottom: 0; width: var(--drawer-w);
  max-width: 100vw; background: var(--bg); z-index: 55;
  transform: translateX(100%); transition: transform 0.18s ease;
  display: flex; flex-direction: column; border-left: 1px solid #131316;
}
.drawer.open { transform: none; box-shadow: -6px 0 30px rgba(0,0,0,0.7); }

/* On wide screens the drawer is part of the layout and open by default. */
@media (min-width: 1280px) {
  .drawer { transform: none; }
  .layout { margin-right: var(--drawer-w); }
  body.drawer-closed .drawer { transform: translateX(100%); }
  body.drawer-closed .layout { margin-right: 0; }
}

.drawer-head {
  display: flex; align-items: center; justify-content: space-between;
  padding: 10px 12px;
}
.drawer-title {
  background: var(--panel-2); border-radius: 4px; padding: 5px 12px;
  font-weight: 800; font-size: 14px; letter-spacing: 0.6px; text-transform: uppercase;
}
.drawer-sub {
  display: inline-block; background: var(--accent); color: var(--on-accent); border-radius: 4px;
  padding: 6px 14px; font-weight: 800; font-size: 13px; letter-spacing: 0.6px;
  text-transform: uppercase;
}
.drawer-sub:hover { background: var(--accent-2); }
.drawer-close { font-size: 22px; }

.stream-embed { background: #0e0e10; aspect-ratio: 16 / 9; position: relative; }
.stream-embed iframe { width: 100%; height: 100%; border: 0; display: block; }
.chat-embed { flex: 1; background: #0e0e10; min-height: 200px; }
.chat-embed iframe { width: 100%; height: 100%; border: 0; display: block; }

.stream-cta {
  position: absolute; inset: 0; display: flex; flex-direction: column; gap: 10px;
  align-items: center; justify-content: center;
}
.btn {
  display: inline-block; border: 0; cursor: pointer; border-radius: 4px;
  padding: 9px 16px; font-weight: 800; font-size: 14px; letter-spacing: 0.4px;
  text-transform: uppercase; color: #fff; background: var(--panel-3);
}
.btn-primary { background: var(--accent); color: var(--on-accent); }
.btn-primary:hover { background: var(--accent-2); }

.drawer-foot { padding: 10px 12px; }
.drawer-foot a { color: var(--muted); font-size: 13px; }
.drawer-foot a:hover { color: #fff; }

/* --------------------------------------------------------------- footer */

.site-footer {
  border-top: 1px solid #131316; margin-top: 50px; padding: 18px 4px 0;
  color: var(--label); font-size: 12.5px;
}
.site-footer a { color: var(--muted); }
.site-footer a:hover { color: #fff; }

/* --------------------------------------------------------------- misc */

.live-dot {
  width: 8px; height: 8px; border-radius: 50%; background: #ff3b30; display: inline-block;
  animation: pulse 1.6s ease-in-out infinite;
}
@keyframes pulse { 50% { opacity: 0.35; } }
@media (prefers-reduced-motion: reduce) { .live-dot { animation: none; } }
