/* ScoreProb hockey v1 (17 Nov 2026): hockey's own pieces on top of sp-basketball.css. Hockey pages carry the body
   classes "sport-bb sport-hk", so every token and component is basketball's, which since colors-v1 (owner, 16 Nov
   2026) are football's colours: home blue, away amber, totals green. Level after 60 minutes takes football's draw grey. */
body.sport-hk { --hk-level: #7e89a6; --hk-level-soft: #eef0f5; --hk-level-ink: #5d6782; }
html[data-theme="dark"] body.sport-hk { --hk-level: #8b95ad; --hk-level-soft: #1d2638; --hk-level-ink: #b3bccf; }

/* the rink lines in the heroes: a little fainter than the court */
.bb-hero svg.hk-rink { opacity: .10; }
.bb-ghero svg.hk-rink { opacity: .07; }

/* three-way bars: home, level, away */
.hk-bar3, .hk-bigbar3 { display: flex; overflow: hidden; background: var(--bb-track); gap: 2px; }
.hk-bar3 { height: 8px; border-radius: 9px; }
.hk-bigbar3 { height: 14px; border-radius: 99px; gap: 3px; }
.hk-bar3 .h, .hk-bigbar3 .h { background: var(--bb-home); }
.hk-bar3 .d, .hk-bigbar3 .d { background: var(--hk-level); }
.hk-bar3 .a, .hk-bigbar3 .a { background: var(--bb-away); flex: 1; }
.hk-pcts3 { display: grid; grid-template-columns: 1fr auto 1fr; font-size: 13px; font-weight: 700; font-variant-numeric: tabular-nums; }
.hk-pcts3 .h { color: var(--bb-home); } .hk-pcts3 .d { color: var(--hk-level-ink); text-align: center; } .hk-pcts3 .a { color: var(--bb-away); text-align: right; }
.hk-bigp3 { display: grid; grid-template-columns: 1fr auto 1fr; align-items: baseline; gap: 8px; font-variant-numeric: tabular-nums; }
.hk-bigp3 .h, .hk-bigp3 .a { font-size: 34px; font-weight: 800; letter-spacing: -.02em; }
.hk-bigp3 .h { color: var(--bb-home); } .hk-bigp3 .a { color: var(--bb-away); text-align: right; }
.hk-bigp3 .d { color: var(--hk-level-ink); font-size: 13px; font-weight: 700; text-align: center; }
@media (max-width: 640px) { .hk-bigp3 .h, .hk-bigp3 .a { font-size: 26px; } .hk-bigp3 .d { font-size: 11.5px; } }

.bb-pk-k.c-level { color: var(--hk-level-ink); }
.bb-tag.d { background: var(--hk-level-soft); color: var(--hk-level-ink); }
.bb-form .hk-otl { background: var(--hk-level-soft); color: var(--hk-level-ink); }
.bb-form.sm { display: inline-flex; gap: 3px; }
.bb-form.sm span { width: 18px; height: 18px; font-size: 9.5px; border-radius: 5px; }
.hk-tiles { grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); }
.hk-tiles .bb-tile b.t { color: var(--bb-total); }
.hk-ourline { font-style: normal; font-size: 11px; font-weight: 800; color: var(--bb-total); margin-left: 4px; text-transform: uppercase; letter-spacing: .04em; }

/* most likely scores and the margin */
.hk-two { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); }
@media (max-width: 760px) { .hk-two { grid-template-columns: minmax(0, 1fr); } }
.hk-scores { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.hk-score { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 10px 6px; border-radius: 12px; background: var(--bb-soft); border-top: 3px solid var(--bb-line); }
.hk-score b { font-size: 20px; font-weight: 800; }
.hk-score span { font-size: 12.5px; color: var(--bb-muted); font-weight: 600; }
.hk-score.h { border-top-color: var(--bb-home); } .hk-score.a { border-top-color: var(--bb-away); } .hk-score.d { border-top-color: var(--hk-level); }
.hk-margin { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 6px; align-items: end; }
.hk-mb { display: flex; flex-direction: column; align-items: center; gap: 4px; font-size: 11.5px; color: var(--bb-muted); }
.hk-mb .bar { width: 100%; height: 96px; display: flex; align-items: flex-end; background: var(--bb-soft); border-radius: 8px; overflow: hidden; }
.hk-mb .bar i { display: block; width: 100%; border-radius: 8px 8px 0 0; }
.hk-mb.h .bar i { background: var(--bb-home); } .hk-mb.a .bar i { background: var(--bb-away); } .hk-mb.d .bar i { background: var(--hk-level); }
.hk-mb b { font-size: 12px; color: var(--bb-ink); }
.hk-margin-key { display: flex; justify-content: space-between; font-weight: 700; }

/* live centre */
.hk-centre { display: flex; flex-direction: column; gap: 14px; padding: 16px 18px; }
.hk-c-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; flex-wrap: wrap; }
.hk-c-now { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 10px; }
.hk-c-tile { display: flex; flex-direction: column; gap: 6px; padding: 11px 14px; border-radius: 12px; background: var(--bb-soft); min-width: 0; }
.hk-c-split { display: flex; justify-content: space-between; gap: 8px; font-size: 18px; font-variant-numeric: tabular-nums; }
.hk-c-split .h { color: var(--bb-home); } .hk-c-split .a { color: var(--bb-away); }
.hk-c-chart { display: flex; flex-direction: column; gap: 6px; }
.hk-c-chart svg { width: 100%; height: 150px; display: block; }
.hk-c-chart .zh { fill: var(--bb-home-soft); opacity: .55; } .hk-c-chart .za { fill: var(--bb-away-soft); opacity: .55; }
.hk-c-chart .mid { stroke: var(--bb-line); stroke-dasharray: 3 4; vector-effect: non-scaling-stroke; }
.hk-c-chart .per { stroke: var(--bb-line); vector-effect: non-scaling-stroke; }
.hk-c-chart .ln { fill: none; stroke: var(--bb-ink); stroke-width: 2; stroke-linejoin: round; vector-effect: non-scaling-stroke; }
.hk-c-chart .g { stroke: var(--bb-card); stroke-width: 2; vector-effect: non-scaling-stroke; }
.hk-c-chart .g.h { fill: var(--bb-home); } .hk-c-chart .g.a { fill: var(--bb-away); }
.hk-c-axis { display: flex; justify-content: space-between; gap: 8px; font-variant-numeric: tabular-nums; }
.hk-c-ticks { position: relative; height: 18px; font-variant-numeric: tabular-nums; }
.hk-c-ticks span { position: absolute; top: 0; transform: translateX(-50%); white-space: nowrap; }
.hk-c-ticks span:first-child { transform: none; }
.hk-c-ticks span.ot { right: 0; transform: none; }
.hk-row .bb-live-badge { white-space: nowrap; }
.hk-row .bb-time .bb-live-badge { font-size: 10.5px; padding-left: 6px; padding-right: 6px; }
.hk-c-axis .k { display: inline-block; width: 10px; height: 3px; border-radius: 2px; margin: 0 4px 2px 8px; vertical-align: middle; }
.hk-c-axis .k.net { background: var(--bb-ink); } .hk-c-axis .k.att { background: var(--bb-home); } .hk-c-axis .k.def { background: var(--bb-total); }
.hk-c-periods { display: flex; flex-direction: column; border: 1px solid var(--bb-line); border-radius: 12px; overflow: hidden; font-variant-numeric: tabular-nums; }
.hk-c-periods .r { display: grid; grid-template-columns: minmax(0, 1fr) repeat(var(--hk-cols, 6), 46px); align-items: center; padding: 8px 12px; gap: 4px; border-top: 1px solid var(--bb-line); }
.hk-c-periods .r:first-child { border-top: 0; }
.hk-c-periods .r > *:not(:first-child) { text-align: center; }
.hk-c-periods .hd { background: var(--bb-soft); font-size: 11.5px; font-weight: 800; color: var(--bb-muted); letter-spacing: .04em; }
.hk-c-periods .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.hk-c-periods .nm.h { color: var(--bb-home); } .hk-c-periods .nm.a { color: var(--bb-away); }
.hk-c-events { display: flex; flex-direction: column; gap: 8px; }
.hk-ev { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.hk-ev-per { font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--bb-muted); padding: 10px 0 4px; }
.hk-ev-i { display: grid; grid-template-columns: 40px 22px minmax(0, 1fr); gap: 8px; align-items: start; padding: 8px 0; border-top: 1px solid var(--bb-line); }
.hk-ev-i .mn { font-weight: 700; font-size: 13px; color: var(--bb-muted); padding-top: 1px; }
.hk-ev-i .ic { display: grid; place-items: center; width: 22px; height: 22px; border-radius: 7px; }
.hk-ev-i.h .ic { background: var(--bb-home-soft); color: var(--bb-home); } .hk-ev-i.a .ic { background: var(--bb-away-soft); color: var(--bb-away); }
.hk-ev-i.penalty .ic { background: var(--bb-soft); color: var(--bb-muted); }
.hk-ev-i .tx { display: flex; flex-direction: column; gap: 1px; min-width: 0; font-size: 13.5px; }
.hk-ev-i.goal .tx b { font-size: 14px; }
.hk-ev-i.penalty .tx b { font-weight: 600; color: var(--bb-muted); font-size: 13px; }
.hk-tagx { font-style: normal; display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 99px; background: var(--bb-accent-soft); color: var(--bb-accent); font-size: 11px; font-weight: 800; }

/* tables */
.hk-table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; margin: 0 -4px; }
.hk-table { width: 100%; border-collapse: collapse; font-size: 13.5px; font-variant-numeric: tabular-nums; }
.hk-table th { font-size: 11px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--bb-muted); padding: 6px 6px; text-align: center; white-space: nowrap; }
.hk-table td { padding: 7px 6px; border-top: 1px solid var(--bb-line); text-align: center; white-space: nowrap; }
.hk-tlink { display: inline-flex; align-items: center; gap: 8px; color: var(--bb-ink) !important; text-decoration: none; font-weight: 600; }
.hk-tlink span { overflow: hidden; text-overflow: ellipsis; max-width: 220px; }
.bb-crest.sm, .bb-abbr.sm { width: 22px; height: 22px; border-radius: 6px; font-size: 8px; }
.show-s { display: none; }
@media (max-width: 640px) { .hide-s { display: none; } .show-s { display: inline; } .hk-tlink span { max-width: 150px; } }

.hk-kv { display: flex; justify-content: space-between; align-items: baseline; gap: 12px; padding: 6px 0; border-top: 1px solid var(--bb-line); font-size: 13.5px; }
.hk-kv:first-of-type { border-top: 0; }
.hk-kv span { color: var(--bb-muted); }
.hk-statgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); column-gap: 18px; }
.hk-statgrid .hk-kv:first-of-type { border-top: 1px solid var(--bb-line); }
.hk-rchart { display: flex; flex-direction: column; gap: 6px; }
.hk-rchart svg { width: 100%; height: auto; display: block; }
.hk-rchart .z { stroke: var(--bb-line); stroke-dasharray: 3 4; }
.hk-rchart polyline { fill: none; stroke-width: 2; stroke-linejoin: round; }
.hk-rchart .net { stroke: var(--bb-ink); stroke-width: 2.6; } .hk-rchart .att { stroke: var(--bb-home); opacity: .8; } .hk-rchart .def { stroke: var(--bb-total); opacity: .8; }

/* section pages */
.hk-lcards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.hk-lcard { display: flex; flex-direction: column; gap: 8px; text-decoration: none; color: var(--bb-ink) !important; }
.hk-lcard:hover { border-color: var(--bb-accent); }
.hk-minis { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.hk-minis span { display: flex; flex-direction: column; gap: 1px; padding: 8px 10px; border-radius: 10px; background: var(--bb-soft); font-size: 11.5px; color: var(--bb-muted); }
.hk-minis b { font-size: 16px; color: var(--bb-ink); }
.hk-mcard { display: flex; flex-direction: column; gap: 10px; }
.hk-mrow { display: grid; grid-template-columns: 70px minmax(0, 1fr) auto; gap: 10px; align-items: center; padding: 9px 0; border-top: 1px solid var(--bb-line); text-decoration: none; color: var(--bb-ink) !important; }
.hk-mrow .t, .hk-mrow .m { display: flex; flex-direction: column; min-width: 0; }
.hk-mrow .m b { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.hk-mrow .p { display: flex; flex-direction: column; align-items: flex-end; }
.hk-mrow .p b { font-size: 13.5px; white-space: nowrap; }
.hk-mrow .p em { font-style: normal; font-size: 12.5px; color: var(--bb-muted); }
.hk-mrow .p.c-h b { color: var(--bb-home); } .hk-mrow .p.c-a b { color: var(--bb-away); } .hk-mrow .p.c-d b { color: var(--hk-level-ink); } .hk-mrow .p.c-t b { color: var(--bb-total); }
.hk-mrow .p.ok b { color: var(--bb-hit); font-size: 18px; } .hk-mrow .p.no b { color: var(--bb-miss); font-size: 18px; }
@media (hover: hover) { .hk-mrow:hover .m b { text-decoration: underline; } }
.hk-prose p { margin: 0 0 10px; max-width: 68ch; line-height: 1.6; font-size: 14.5px; }
.hk-prose p:last-child { margin-bottom: 0; }
.hk-prose h2 { margin-bottom: 8px; }
.hk-rules { margin: 0; padding-left: 18px; display: flex; flex-direction: column; gap: 8px; font-size: 13.5px; line-height: 1.5; }

/* QA round 2 (17 Nov): quiet rows without a pick, values that do not break, three tiles, titles that wrap on phones */
.hk-nopick { display: block; font-size: 12px; color: var(--bb-muted); }
.bb-r3 > .bb-pk.is-empty { visibility: hidden; }
.hk-kv b { white-space: nowrap; }
.hk-tiles3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 860px) {
  .bb-row.bb-r3.hk-row[data-nopick] { grid-template-areas: "top top" "teams teams" "bar bar"; }
  .bb-r3 > .bb-pk.is-empty { display: none; }
  body.sport-hk .bb-hero h1.hk-h1w { white-space: normal; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
}
@media (max-width: 640px) {
  .hk-tiles3 { gap: 8px; }
  .hk-tiles3 .bb-tile { padding: 10px; min-width: 0; }
  .hk-tiles3 .bb-tile b { font-size: 18px; }
  .hk-tiles3 .bb-eyebrow { font-size: 9.5px; letter-spacing: .04em; }
}
@media (max-width: 420px) {
  .hk-table th, .hk-table td { padding-left: 4px; padding-right: 4px; }
  .hk-tlink { gap: 6px; }
  .hk-tlink span { max-width: 104px; }
}

/* phase 4: follow stars in the hockey tables, next to the team link */
.hk-table td .sp-st { margin-left: 2px; vertical-align: middle; position: relative; z-index: 3; }
.hk-table td .hk-tlink { vertical-align: middle; }
