/* RSS Hoops Scoreboard — display styles */
.rsshb {
  --bg: #070b14;
  --panel: #0e1525;
  --panel2: #131d33;
  --ink: #f4f6fb;
  --muted: #8b97b3;
  --line: rgba(255, 255, 255, .09);
  --accent: #ff7a1a;
  --led: #ffb21e;
  --live: #ff3b3b;
  --win: #22c55e;
  --local: rgba(255, 122, 26, .12);
  --radius: 14px;
  --display: 'Oswald', 'Arial Narrow', 'Helvetica Neue', Arial, sans-serif;
  --body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
  font-family: var(--body);
  color: var(--ink);
  background: var(--bg);
  border-radius: calc(var(--radius) + 4px);
  padding: 14px;
  max-width: 1100px;
  margin: 0 auto 28px;
  box-sizing: border-box;
  line-height: 1.35;
  position: relative;
  -webkit-font-smoothing: antialiased;
}
.rsshb *, .rsshb *::before, .rsshb *::after { box-sizing: border-box; }
.rsshb svg { width: 1em; height: 1em; display: inline-block; vertical-align: -.125em; }
.rsshb button { font: inherit; color: inherit; }
.rsshb a { color: inherit; }

.rsshb.rsshb-theme-light {
  --bg: #eef1f6;
  --panel: #ffffff;
  --panel2: #f5f7fb;
  --ink: #0f172a;
  --muted: #5b6780;
  --line: rgba(15, 23, 42, .1);
  --led: #d97706;
  --local: rgba(255, 122, 26, .1);
}

/* ---------- Board ---------- */
.rsshb-board {
  background:
    radial-gradient(120% 80% at 50% -20%, rgba(255, 122, 26, .16), transparent 60%),
    linear-gradient(180deg, var(--panel2), var(--panel));
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: 0 18px 40px -18px rgba(0, 0, 0, .55);
}
.rsshb-theme-light .rsshb-board { box-shadow: 0 12px 30px -16px rgba(15, 23, 42, .25); }
.rsshb-board.is-local { border-color: rgba(255, 122, 26, .45); }

.rsshb-board-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 12px 16px;
  border-bottom: 1px solid var(--line);
  background: rgba(0, 0, 0, .18);
}
.rsshb-theme-light .rsshb-board-head { background: rgba(15, 23, 42, .03); }
.rsshb-brand { display: flex; align-items: center; gap: 10px; min-width: 0; }
.rsshb-brand > svg { width: 26px; height: 26px; color: var(--accent); flex: none; }
.rsshb-brand img { width: 34px; height: 34px; object-fit: contain; flex: none; }
.rsshb-brand b { display: block; font-family: var(--display); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; font-size: 15px; }
.rsshb-brand small { display: block; color: var(--muted); font-size: 12px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rsshb-head-right { display: flex; align-items: center; gap: 8px; flex: none; }

.rsshb-pill {
  display: inline-flex; align-items: center; gap: 6px;
  font-family: var(--display); font-weight: 600; letter-spacing: .1em; font-size: 12px;
  padding: 4px 10px; border-radius: 999px;
  background: var(--panel2); border: 1px solid var(--line); color: var(--muted);
}
.rsshb-pill.rsshb-live { background: var(--live); border-color: transparent; color: #fff; }
.rsshb-pill.rsshb-live i { width: 7px; height: 7px; border-radius: 50%; background: #fff; animation: rsshb-pulse 1.2s infinite; }
.rsshb-pill.rsshb-half { background: var(--led); color: #1a1205; border-color: transparent; }
.rsshb-pill.rsshb-final { background: transparent; color: var(--ink); }
.rsshb-pill.rsshb-pp { color: #f59e0b; }
@keyframes rsshb-pulse { 50% { opacity: .25; } }

.rsshb-tag {
  font-family: var(--display); font-size: 11px; letter-spacing: .1em; font-weight: 600;
  padding: 3px 8px; border-radius: 6px; background: rgba(34, 197, 94, .15); color: var(--win);
}
.rsshb-tag-local { background: rgba(255, 122, 26, .16); color: var(--accent); }

.rsshb-fs {
  background: transparent; border: 1px solid var(--line); border-radius: 8px;
  width: 30px; height: 30px; display: inline-grid; place-items: center; cursor: pointer; color: var(--muted);
}
.rsshb-fs:hover { color: var(--ink); }

.rsshb-headline {
  text-align: center; font-family: var(--display); letter-spacing: .08em; text-transform: uppercase;
  font-size: 14px; padding: 8px 14px; color: var(--accent); border-bottom: 1px solid var(--line);
}

.rsshb-main {
  display: grid; grid-template-columns: 1fr auto 1fr; align-items: stretch;
}
.rsshb-team {
  position: relative; padding: 20px 20px 16px;
  display: flex; flex-direction: column; gap: 8px;
  border-top: 6px solid var(--tc);
  background: linear-gradient(180deg, color-mix(in srgb, var(--tc) 18%, transparent), transparent 70%);
}
.rsshb-away { align-items: flex-end; text-align: right; }
.rsshb-team-id { display: flex; align-items: center; gap: 12px; min-width: 0; max-width: 100%; }
.rsshb-away .rsshb-team-id { flex-direction: row-reverse; }
.rsshb-logo { width: 54px; height: 54px; border-radius: 12px; object-fit: contain; flex: none; background: rgba(255, 255, 255, .06); }
.rsshb-mono {
  display: grid; place-items: center; background: var(--tc); color: var(--tc2);
  font-family: var(--display); font-weight: 700; font-size: 18px; letter-spacing: .04em;
}
.rsshb-team-name { min-width: 0; }
.rsshb-team-name b {
  display: block; font-family: var(--display); font-weight: 600; text-transform: uppercase;
  font-size: clamp(16px, 2.3vw, 24px); letter-spacing: .03em; line-height: 1.1;
}
.rsshb-team-name small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.rsshb-score {
  font-family: var(--display); font-weight: 700; font-variant-numeric: tabular-nums;
  font-size: clamp(64px, 11vw, 128px); line-height: .95; letter-spacing: -.01em;
  text-shadow: 0 0 28px color-mix(in srgb, var(--tc) 45%, transparent);
}
.rsshb-theme-light .rsshb-score { text-shadow: none; }
.rsshb-flash { animation: rsshb-flash 1.1s ease-out; }
@keyframes rsshb-flash {
  0% { color: var(--led); transform: scale(1.12); }
  100% { color: inherit; transform: scale(1); }
}
.rsshb-team-stats { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; font-size: 12px; }
.rsshb-away .rsshb-team-stats { justify-content: flex-end; }
.rsshb-team-stats > span { display: inline-flex; align-items: center; gap: 6px; }
.rsshb-team-stats em { font-style: normal; color: var(--muted); font-family: var(--display); letter-spacing: .1em; }
.rsshb-team-stats b { font-family: var(--display); font-size: 16px; color: var(--led); }
.rsshb-dots { display: inline-flex; gap: 3px; }
.rsshb-dots i { width: 8px; height: 8px; border-radius: 2px; background: var(--line); }
.rsshb-dots i.on { background: var(--led); }
.rsshb-bonus { font-family: var(--display); letter-spacing: .1em; background: var(--led); color: #1a1205; border-radius: 4px; padding: 1px 6px; font-weight: 600; }
.rsshb-poss { color: var(--accent); font-size: 18px; }

.rsshb-center {
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  padding: 16px 18px; min-width: 150px;
  border-left: 1px solid var(--line); border-right: 1px solid var(--line);
  background: rgba(0, 0, 0, .25);
}
.rsshb-theme-light .rsshb-center { background: rgba(15, 23, 42, .03); }
.rsshb-period { font-family: var(--display); font-weight: 600; letter-spacing: .14em; font-size: 18px; color: var(--muted); }
.rsshb-clock {
  font-family: var(--display); font-weight: 600; font-variant-numeric: tabular-nums;
  font-size: clamp(34px, 5.5vw, 58px); color: var(--led); line-height: 1.05;
  padding: 4px 12px; border-radius: 10px; background: rgba(0, 0, 0, .35);
  border: 1px solid rgba(255, 178, 30, .25); min-width: 4.2ch; text-align: center;
  text-shadow: 0 0 18px rgba(255, 178, 30, .45);
}
.rsshb-theme-light .rsshb-clock { background: #0f172a; color: #ffb21e; }
.rsshb-clock.low { color: var(--live); border-color: rgba(255, 59, 59, .4); text-shadow: 0 0 18px rgba(255, 59, 59, .5); }
.rsshb-clock.zero { animation: rsshb-pulse 1s infinite; }
.rsshb-clock.done { font-size: clamp(22px, 3.5vw, 34px); color: var(--ink); text-shadow: none; }
.rsshb-theme-light .rsshb-clock.done { color: #fff; }
.rsshb-tip { text-align: center; font-family: var(--display); font-size: 18px; letter-spacing: .04em; margin-top: 4px; }
.rsshb-countdown { margin-top: 8px; font-family: var(--display); font-variant-numeric: tabular-nums; color: var(--led); font-size: 16px; letter-spacing: .06em; }

/* Line score */
.rsshb-linescore {
  width: 100%; border-collapse: collapse; font-family: var(--display); font-variant-numeric: tabular-nums;
  border-top: 1px solid var(--line); font-size: 15px; margin: 0;
}
.rsshb-linescore th, .rsshb-linescore td { padding: 7px 8px; text-align: center; border: 0; background: none; color: inherit; }
.rsshb-linescore th { color: var(--muted); font-weight: 500; letter-spacing: .1em; font-size: 12px; }
.rsshb-linescore tbody tr + tr td { border-top: 1px solid var(--line); }
.rsshb-ls-team { text-align: left !important; padding-left: 16px !important; letter-spacing: .06em; }
.rsshb-ls-team i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 8px; }
.rsshb-ls-tot { font-weight: 700; color: var(--led); font-size: 17px; }

/* Info + sponsors */
.rsshb-info {
  display: flex; flex-wrap: wrap; gap: 8px 22px; padding: 12px 16px;
  border-top: 1px solid var(--line); font-size: 13px;
}
.rsshb-info-item { display: inline-flex; align-items: center; gap: 7px; }
.rsshb-info-item svg { color: var(--accent); }
.rsshb-info-item em { font-style: normal; color: var(--muted); font-family: var(--display); letter-spacing: .1em; font-size: 11px; }
.rsshb-sponsors {
  display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 10px 18px;
  padding: 12px 16px; border-top: 1px solid var(--line); background: rgba(255, 255, 255, .03);
}
.rsshb-sponsors > em { font-style: normal; color: var(--muted); font-family: var(--display); letter-spacing: .16em; font-size: 11px; }
.rsshb-sponsor { display: inline-flex; align-items: center; gap: 8px; text-decoration: none; }
.rsshb-sponsor img { height: 34px; max-width: 150px; object-fit: contain; }
.rsshb-sponsor b { font-family: var(--display); font-weight: 600; letter-spacing: .06em; font-size: 16px; text-transform: uppercase; }
.rsshb-sponsor small { color: var(--muted); font-size: 12px; }
.rsshb-amp { color: var(--muted); }
.rsshb-watch {
  display: block; text-align: center; padding: 11px; font-family: var(--display); letter-spacing: .12em;
  background: var(--accent); color: #fff !important; text-decoration: none; font-weight: 600;
}

/* Next up wrapper */
.rsshb-nextup { position: relative; }
.rsshb-nextup-label {
  display: inline-block; font-family: var(--display); letter-spacing: .16em; font-size: 12px; color: var(--accent);
  margin: 0 0 8px 4px;
}
.rsshb-empty-board {
  display: flex; flex-direction: column; align-items: center; gap: 6px; text-align: center;
  padding: 44px 16px; border: 1px dashed var(--line); border-radius: var(--radius); color: var(--muted);
}
.rsshb-empty-board svg { width: 40px; height: 40px; color: var(--accent); }
.rsshb-empty-board b { font-family: var(--display); color: var(--ink); font-size: 22px; letter-spacing: .06em; text-transform: uppercase; }

/* Other live games / ticker view */
.rsshb-others { margin-top: 14px; }
.rsshb-others h4, .rsshb-standings h4 {
  font-family: var(--display); font-weight: 500; letter-spacing: .14em; text-transform: uppercase;
  font-size: 13px; color: var(--muted); margin: 0 0 8px;
}
.rsshb-strip { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 10px; }
.rsshb-mini {
  text-align: left; background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
  padding: 10px 12px; cursor: pointer; display: flex; flex-direction: column; gap: 4px;
}
.rsshb-mini:hover { border-color: var(--accent); }
.rsshb-mini.is-local { background: linear-gradient(0deg, var(--local), var(--local)), var(--panel); }
.rsshb-mini-row { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.rsshb-mini-row i, .rsshb-matchup i, .rsshb-res-row i, .rsshb-standings td i {
  width: 10px; height: 10px; border-radius: 2px; flex: none; display: inline-block;
}
.rsshb-mini-row span { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rsshb-mini-row b { font-family: var(--display); font-size: 18px; font-variant-numeric: tabular-nums; }
.rsshb-mini-row.win b, .rsshb-mini-row.win span { color: var(--ink); font-weight: 700; }
.rsshb-mini-foot { display: flex; justify-content: flex-end; margin-top: 2px; font-size: 12px; color: var(--muted); }
.rsshb-mini-clock b { color: var(--live); font-family: var(--display); letter-spacing: .08em; }
.rsshb-mini-clock span { font-family: var(--display); color: var(--led); font-variant-numeric: tabular-nums; }

/* Ticker */
.rsshb-ticker {
  display: flex; align-items: stretch; margin-top: 12px; border-radius: 10px; overflow: hidden;
  background: var(--panel); border: 1px solid var(--line); font-size: 13px;
}
.rsshb-tk-label {
  flex: none; display: flex; align-items: center; gap: 6px; padding: 8px 12px;
  background: var(--accent); color: #fff; font-family: var(--display); letter-spacing: .12em; font-weight: 600; font-size: 12px;
}
.rsshb-tk-track { overflow: hidden; flex: 1; position: relative; mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); }
.rsshb-tk-move { display: inline-flex; align-items: center; gap: 16px; white-space: nowrap; padding: 8px 0; animation: rsshb-scroll linear infinite; }
.rsshb-tk-move b { font-family: var(--display); letter-spacing: .08em; color: var(--muted); font-weight: 600; }
.rsshb-tk-move em { color: var(--led); font-style: normal; }
.rsshb-tk-live { color: var(--live) !important; }
.rsshb-tk-ann { color: var(--accent); font-weight: 600; }
.rsshb-tk-sep { color: var(--line); font-size: 8px; }
.rsshb-ticker:hover .rsshb-tk-move { animation-play-state: paused; }
@keyframes rsshb-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* Tabs + lists */
.rsshb-tabs { display: flex; gap: 6px; margin: 18px 0 10px; border-bottom: 1px solid var(--line); }
.rsshb-tabs button {
  background: none; border: 0; border-bottom: 3px solid transparent; padding: 10px 14px; cursor: pointer;
  font-family: var(--display); letter-spacing: .12em; text-transform: uppercase; font-size: 14px; color: var(--muted);
}
.rsshb-tabs button.on { color: var(--ink); border-bottom-color: var(--accent); }
.rsshb-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.rsshb-item {
  display: flex; align-items: center; gap: 14px; padding: 10px 14px; margin: 0;
  background: var(--panel); border: 1px solid var(--line); border-radius: 12px;
}
.rsshb-item.is-local { background: linear-gradient(0deg, var(--local), var(--local)), var(--panel); border-color: rgba(255, 122, 26, .35); }
.rsshb-date { flex: none; width: 58px; text-align: center; font-family: var(--display); line-height: 1.05; }
.rsshb-date em { display: block; font-style: normal; color: var(--accent); letter-spacing: .12em; font-size: 12px; text-transform: uppercase; }
.rsshb-date b { display: block; font-size: 26px; }
.rsshb-date small { display: block; color: var(--muted); font-size: 11px; }
.rsshb-item-body { flex: 1; min-width: 0; }
.rsshb-item-body small { color: var(--muted); font-size: 12px; display: block; margin-top: 2px; }
.rsshb-matchup { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; font-weight: 600; font-size: 15px; }
.rsshb-matchup span { color: var(--muted); font-weight: 400; font-size: 12px; text-transform: uppercase; margin: 0 2px; }
.rsshb-res-row { display: flex; align-items: center; gap: 8px; font-size: 14px; color: var(--muted); }
.rsshb-res-row b { margin-left: auto; font-family: var(--display); font-size: 18px; font-variant-numeric: tabular-nums; }
.rsshb-res-row.win { color: var(--ink); font-weight: 700; }
.rsshb-result .rsshb-pill { flex: none; }
.rsshb-empty { color: var(--muted); padding: 16px 4px; margin: 0; }

.rsshb-standings + .rsshb-standings { margin-top: 18px; }
.rsshb-table-wrap { overflow-x: auto; border: 1px solid var(--line); border-radius: 12px; background: var(--panel); }
.rsshb-standings table { width: 100%; border-collapse: collapse; font-size: 14px; margin: 0; }
.rsshb-standings th, .rsshb-standings td { padding: 9px 10px; text-align: center; border: 0; border-bottom: 1px solid var(--line); background: none; color: inherit; font-variant-numeric: tabular-nums; }
.rsshb-standings th { font-family: var(--display); letter-spacing: .1em; font-weight: 500; color: var(--muted); font-size: 12px; }
.rsshb-standings tr:last-child td { border-bottom: 0; }
.rsshb-standings .l { text-align: left; }
.rsshb-standings td.l { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.rsshb-standings td.l small { color: var(--muted); font-size: 12px; }
.rsshb-standings tr.is-local td { background: var(--local); }
.rsshb-standings .pos { color: var(--win); }
.rsshb-standings .neg { color: var(--live); }
.rsshb-foot { color: var(--muted); font-size: 12px; margin: 12px 4px 0; }

.rsshb-status {
  font-size: 12px; color: #f59e0b; text-align: center; padding: 4px 0 10px; font-family: var(--display); letter-spacing: .08em;
}
.rsshb-loading { padding: 30px; text-align: center; color: #8b97b3; font-family: system-ui, sans-serif; }

/* Ticker-only view (sidebar / header strip) */
.rsshb-view-ticker { padding: 10px; }
.rsshb-view-ticker .rsshb-strip { grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); }

/* Arena / fullscreen (TV at the court) */
.rsshb-view-arena, .rsshb.rsshb-is-fs {
  max-width: none; min-height: 100vh; border-radius: 0; margin: 0; padding: 2vw;
  display: flex; flex-direction: column; justify-content: center;
}
.rsshb-view-arena .rsshb-score, .rsshb-is-fs .rsshb-score { font-size: clamp(90px, 17vw, 300px); }
.rsshb-view-arena .rsshb-clock, .rsshb-is-fs .rsshb-clock { font-size: clamp(50px, 8vw, 150px); }
.rsshb-view-arena .rsshb-team-name b, .rsshb-is-fs .rsshb-team-name b { font-size: clamp(22px, 3.2vw, 56px); }
.rsshb-view-arena .rsshb-period, .rsshb-is-fs .rsshb-period { font-size: clamp(20px, 2.5vw, 44px); }
.rsshb-view-arena .rsshb-logo, .rsshb-is-fs .rsshb-logo { width: clamp(54px, 6vw, 110px); height: clamp(54px, 6vw, 110px); }
.rsshb-view-arena .rsshb-linescore, .rsshb-is-fs .rsshb-linescore { font-size: clamp(15px, 1.6vw, 28px); }
.rsshb-view-arena .rsshb-info, .rsshb-is-fs .rsshb-info { font-size: clamp(13px, 1.3vw, 22px); }
.rsshb-view-arena .rsshb-sponsor img, .rsshb-is-fs .rsshb-sponsor img { height: clamp(34px, 4vw, 80px); max-width: 300px; }
.rsshb-is-fs .rsshb-slot-lists { display: none; }

/* Phones */
@media (max-width: 640px) {
  .rsshb { padding: 10px; border-radius: 14px; }
  .rsshb-board-head { padding: 10px 12px; }
  .rsshb-brand small { max-width: 46vw; }
  .rsshb-team { padding: 14px 10px 12px; gap: 6px; }
  .rsshb-logo { width: 38px; height: 38px; border-radius: 9px; }
  .rsshb-mono { font-size: 13px; }
  .rsshb-team-id { flex-direction: column; align-items: flex-start; gap: 6px; }
  .rsshb-away .rsshb-team-id { flex-direction: column; align-items: flex-end; }
  .rsshb-team-name b { font-size: 15px; }
  .rsshb-team-name small { font-size: 11px; }
  .rsshb-score { font-size: 56px; }
  .rsshb-center { min-width: 0; padding: 10px 8px; }
  .rsshb-period { font-size: 14px; }
  .rsshb-clock { font-size: 26px; padding: 3px 7px; }
  .rsshb-tip { font-size: 14px; }
  .rsshb-team-stats { gap: 8px; font-size: 11px; }
  .rsshb-linescore { font-size: 13px; }
  .rsshb-linescore th, .rsshb-linescore td { padding: 6px 4px; }
  .rsshb-ls-team { padding-left: 10px !important; }
  .rsshb-fs { display: none; }
  .rsshb-tabs button { padding: 9px 9px; font-size: 13px; }
  .rsshb-item { padding: 9px 10px; gap: 10px; }
  .rsshb-standings small { display: none; }
  .rsshb-sponsor small { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .rsshb-tk-move { animation: none; }
  .rsshb-tk-track { overflow-x: auto; }
  .rsshb-flash, .rsshb-pill.rsshb-live i { animation: none; }
}
