/* Same system as Blueline (tokens, topbar, drawer, chips, tables, price boxes, pop-ups); the accent is
   the court orange and the second colour the blue, so the two sites read as siblings. */
:root {
  color-scheme: light;
  --bg: #f6f4f1; --surface: #ffffff; --surface-2: #f1ede8; --border: #ddd6cd;
  --text: #1c1710; --text-muted: #6b6257;
  --accent: #e0662a; --accent-rgb: 224,102,42;
  --accent-2: #2a78d6; --accent-2-rgb: 42,120,214;
  --good: #0ca30c; --critical: #d03b3b;
  --shadow: 0 1px 2px rgba(28,23,16,.06), 0 1px 3px rgba(28,23,16,.08);
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
    --bg: #14110e; --surface: #1d1915; --surface-2: #2a251f; --border: #3a342b;
    --text: #efe9e0; --text-muted: #a99e8f;
    --accent: #f07a3a; --accent-rgb: 240,122,58;
    --accent-2: #3987e5; --accent-2-rgb: 57,135,229;
    --good: #2fbf4f; --critical: #e66767;
    --shadow: 0 1px 2px rgba(0,0,0,.3), 0 4px 12px rgba(0,0,0,.35);
  }
}
[hidden] { display: none !important; }
button { font: inherit; }
.nav-title { flex: 1 1 40px; font-weight: 700; font-size: 15px; color: color-mix(in srgb, var(--gc) 72%, var(--text)); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.nav-title::before { content: "/"; margin-right: 10px; color: var(--gc); }
.nav-head button { border: 0; background: var(--surface-2); color: var(--text-muted); width: 30px; height: 30px; border-radius: 8px; cursor: pointer; font-size: 14px; }
[data-g="players"] { --gc: #3b82d6; }
[data-g="props"] { --gc: #2fa26f; }
.tab-group-label { margin: 14px 8px 4px; font-size: 11px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
  color: color-mix(in srgb, var(--gc) 72%, var(--text)); display: flex; align-items: center; gap: 8px; }
.tab-group-label::after { content: ""; flex: 1; height: 2px; border-radius: 2px; background: color-mix(in srgb, var(--gc) 35%, transparent); }
.tab-btn { display: block; width: 100%; text-align: left; border: none; background: transparent; color: var(--text); font-weight: 600; font-size: 15px; padding: 10px 12px; border-radius: 9px; cursor: pointer; }
.tab-btn[data-g]::before { content: ""; display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--gc); margin-right: 11px; vertical-align: 1px; }
.tab-btn.active { background: color-mix(in srgb, var(--gc) 13%, var(--surface)); box-shadow: inset 3px 0 0 var(--gc); color: color-mix(in srgb, var(--gc) 75%, var(--text)); }
.tab-btn:hover:not(.active) { background: var(--surface-2); }
.tab-btn[disabled] { opacity: .5; cursor: default; }
section[data-view] { display: none; }
section[data-view].active { display: block; }
.grid2 { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 14px; }
@media (max-width: 700px) { .grid2 { grid-template-columns: 1fr; } .card { padding: 16px; } }
.search-input { width: 100%; padding: 13px 16px; border-radius: 11px; border: 1.5px solid var(--border); background: var(--surface); color: var(--text); font: inherit; font-size: 15px; }
.search-input:focus { outline: none; border-color: var(--accent); }
.ac-item:hover, .ac-item.hi { background: var(--surface-2); }
.ac-item.hi { box-shadow: inset 3px 0 0 var(--accent); }
.field-lbl { margin-bottom: 5px; text-transform: uppercase; letter-spacing: .04em; font-size: 11px; color: var(--text-muted); }
.step-btn { border: 1px solid var(--border); background: var(--surface-2); color: var(--text); border-radius: 8px; width: 34px; height: 36px; font-size: 14px; line-height: 1; cursor: pointer; padding: 0; }
.step-btn:hover:not(:disabled) { border-color: var(--accent); color: var(--accent); }
.step-btn:disabled { opacity: .35; cursor: not-allowed; }
.chip.active { background: var(--accent); border-color: var(--accent); color: #fff; }
.chip:hover:not(.active) { color: var(--text); }
.chip:disabled { opacity: .45; cursor: not-allowed; }
.chip-row.scroll-x .chip { flex: none; }
.team-logo { width: 22px; height: 22px; vertical-align: middle; margin-right: 5px; object-fit: contain; }
a.chip.game-link { text-decoration: none; display: inline-flex; align-items: center; color: var(--accent); border-color: var(--accent); background: transparent; }
a.chip.game-link.active { background: var(--accent); color: #fff; }
.pill { display: inline-flex; align-items: center; gap: 5px; padding: 3px 10px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); font-size: 12.5px; font-weight: 600; color: var(--text-muted); }
.stat-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(110px,1fr)); gap: 10px; margin-top: 14px; }
.player-link { background: none; border: 0; border-bottom: 1px dotted var(--text-muted); padding: 0; color: var(--text); font: inherit; font-weight: 600; cursor: pointer; text-align: left; }
.player-link:hover { color: var(--accent); border-bottom-color: var(--accent); }

.tbl-wrap { overflow-x: auto; max-width: 100%; }
/* Narratives page: a player on the left, the note beside it (under it on a phone). */
.gn-row { display: flex; flex-wrap: wrap; gap: 2px 14px; padding: 5px 0 5px 8px; margin: 3px 0; }
.gn-who { flex: 0 0 230px; }
.gn-what { flex: 1 1 260px; font-size: 13.5px; }
th, td { padding: 8px 10px; text-align: right; border-bottom: 1px solid var(--border); white-space: nowrap; }
th:first-child, td:first-child { text-align: left; }
thead th { color: var(--text-muted); font-weight: 600; font-size: 11.5px; text-transform: uppercase; letter-spacing: .04em; }
thead th.sortable { cursor: pointer; user-select: none; }
thead th.sortable:hover { color: var(--text); }
thead th.sortable::after { content: ""; display: inline-block; width: .7em; margin-left: 3px; opacity: .35; }
thead th.sort-desc::after { content: "▾"; opacity: 1; }
thead th.sort-asc::after { content: "▴"; opacity: 1; }
tbody tr:last-child td { border-bottom: none; }
td.hit-cell { border-radius: 6px; font-weight: 600; }
.prop-table th, .prop-table td { text-align: center; padding: 7px 5px; }
.prop-table th:first-child, .prop-table td.player-cell { position: sticky; left: 0; z-index: 1; background: var(--surface); text-align: left; padding-left: 2px; padding-right: 10px; box-shadow: 1px 0 0 var(--border); }
.prop-table td.player-cell { white-space: normal; min-width: 124px; max-width: 170px; line-height: 1.25; }
.prop-table .player-team { font-size: 11px; color: var(--text-muted); margin-top: 2px; }
.prop-table tr.alt-row td { background: color-mix(in srgb, var(--surface-2) 55%, var(--surface)); }
.prop-table tr.alt-row td.player-cell { background: color-mix(in srgb, var(--surface-2) 55%, var(--surface)); }
.alt-toggle { border: 1px solid var(--border); background: var(--surface-2); color: var(--text-muted); border-radius: 6px; font-size: 11px; font-weight: 700; padding: 1px 6px; cursor: pointer; margin-right: 5px; }
.alt-toggle:hover { color: var(--text); border-color: var(--accent); }
.spot-edge { font-size: 11px; font-weight: 700; margin-top: 2px; }
.price-box { display: inline-block; min-width: 54px; padding: 6px 5px; border-radius: 8px; border: 1px solid color-mix(in srgb, var(--accent) 45%, var(--border));
  color: var(--accent); font-weight: 700; font-size: 13px; text-align: center; cursor: pointer; }
.price-box.empty { border-color: var(--border); color: var(--text-muted); font-weight: 400; opacity: .6; cursor: default; }
.price-box.hit { border-color: var(--good); color: var(--good); }
.price-box.miss { border-color: var(--critical); color: var(--critical); }
.price-box.pop-active { outline: 2px solid var(--accent); outline-offset: 1px; }
td[data-bhit], td[data-thit] { cursor: pointer; }
td[data-bhit].pop-active, td[data-thit].pop-active { outline: 2px solid var(--accent); outline-offset: -2px; }
.cell-pop { position: absolute; z-index: 60; width: 270px; max-width: calc(100vw - 16px); background: var(--surface); color: var(--text); border: 1px solid var(--border);
  border-radius: 12px; box-shadow: 0 8px 28px rgba(16,24,40,.22); padding: 12px 14px; font-size: 13px; }
.cell-pop.wide { width: 450px; }
/* A long list (By The Odds): fixed in the middle of the screen, never past its edges; the table scrolls inside it, both ways, with the header row kept. */
.cell-pop.list { position: fixed; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(640px, calc(100vw - 16px)); max-height: calc(100dvh - 24px); display: flex; flex-direction: column; box-sizing: border-box; }
.cell-pop.list .pop-head { flex: none; }
.cell-pop.list .pop-body { flex: 1 1 auto; min-height: 0; overflow: auto; -webkit-overflow-scrolling: touch; overscroll-behavior: contain; margin-top: 8px; }
.cell-pop.list .pop-games { margin-top: 0; white-space: nowrap; }
.cell-pop.list .pop-games thead td { position: sticky; top: 0; background: var(--surface); z-index: 1; }
td[data-lpop] { cursor: pointer; }
td[data-lpop].pop-active { outline: 2px solid var(--accent); outline-offset: -2px; }
.cell-pop .pop-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 10px; }
.cell-pop .pop-title { font-weight: 700; }
.cell-pop .pop-x { border: 0; background: var(--surface-2); color: var(--text-muted); width: 24px; height: 24px; border-radius: 6px; cursor: pointer; font-size: 12px; flex: none; }
.cell-pop .pop-x:hover { color: var(--text); }
.cell-pop .pop-big { font-size: 17px; font-weight: 700; margin: 8px 0 2px; }
.cell-pop .pop-games { width: 100%; margin-top: 8px; font-size: 12.5px; }
.cell-pop .pop-games td { padding: 4px 4px; text-align: left; border-bottom: 1px solid var(--border); }
.cell-pop .pop-games tr:last-child td { border-bottom: none; }
.cell-pop .pop-mark { text-align: center !important; font-weight: 800; }
.cell-pop .pop-mark.hit { color: var(--good); }
.cell-pop .pop-mark.miss { color: var(--critical); }
#returnBar { margin-bottom: 14px; }
[data-g="teams"] { --gc: #e8743b; }
[data-g="stats"] { --gc: #14a3b8; }
[data-g="spots"] { --gc: #d6457a; }
[data-g="ask"] { --gc: #8b6bd8; }
[data-g="premium"] { --gc: #c9a227; }
.tiles-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; align-items: start; }
.game-tile table th, .game-tile table td { padding: 5px 8px; }
.gt-dd { margin-top: 10px; display: grid; grid-template-columns: minmax(0, 1fr); gap: 4px; }
.gt-det { border: 1px solid var(--border); border-radius: 9px; background: var(--surface-2); }
.gt-det summary { cursor: pointer; padding: 7px 11px; font-size: 13px; font-weight: 600; color: var(--text-muted); }
.gt-det[open] summary { color: var(--text); border-bottom: 1px solid var(--border); }
.gt-body { padding: 8px 10px; min-width: 0; overflow-x: auto; }
.game-tile { min-width: 0; overflow: hidden; }
.inj-row { padding: 6px 0; border-bottom: 1px solid var(--border); }
.inj-row:last-child { border-bottom: none; }
.inj-top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.inj-note { white-space: normal; margin-top: 3px; line-height: 1.35; }
.gt-body .lines-table td { white-space: normal; }
.gt-body .lines-table th, .gt-body .lines-table td { padding: 5px 5px; }
.cmp-val { text-align: center; line-height: 1.15; min-width: 58px; white-space: nowrap; }
.cmp-rank { font-size: 10.5px; font-weight: 600; }
.cmp-h { text-align: center; white-space: nowrap; }
.gt-team { margin: 8px 0 4px; display: flex; align-items: center; gap: 4px; }
.lines-table th, .lines-table td { padding: 5px 8px; font-size: 13px; }
.gbadge { display: inline-block; font-size: 10.5px; font-weight: 700; letter-spacing: .03em; padding: 1px 6px; border-radius: 999px; border: 1px solid currentColor; white-space: nowrap; }
.ll-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.ll-title { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); margin-right: 4px; }
.ctx-chip { display: inline-flex; padding: 3px 10px; border-radius: 999px; background: var(--surface-2); border: 1px solid var(--border); font-size: 12.5px; font-weight: 600; }
.ctx-chip.date { background: color-mix(in srgb, var(--accent-2) 14%, var(--surface)); border-color: var(--accent-2); color: var(--accent-2); }
.sec-lbl { margin: 18px 0 6px; text-transform: uppercase; letter-spacing: .04em; font-size: 11px; color: var(--text-muted); }
.def-panel { margin-top: 10px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 12px; background: var(--surface-2); }
.def-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(92px, 1fr)); gap: 8px; }
.def-tile { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 8px 10px; }
.def-val { font-size: 20px; font-weight: 700; }
.def-lbl { white-space: normal; font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: .03em; }
.def-rank { font-size: 12px; font-weight: 700; margin-top: 2px; }
.ctl-row { display: flex; flex-wrap: wrap; gap: 12px; align-items: flex-end; margin-top: 12px; }
.ctl-row label { display: flex; flex-direction: column; gap: 4px; font-size: 11px; text-transform: uppercase; letter-spacing: .04em; color: var(--text-muted); }
.ctl-row select, .ctl-row input[type=text] { padding: 7px 10px; border-radius: 8px; border: 1px solid var(--border); background: var(--surface); color: var(--text); font: inherit; font-size: 13.5px; text-transform: none; letter-spacing: 0; }
.rank-badge { display: inline-flex; width: 22px; height: 22px; border-radius: 50%; align-items: center; justify-content: center; background: var(--surface-2); border: 1px solid var(--border); font-size: 11px; font-weight: 700; color: var(--text-muted); }
table.sortable-table th[data-k] { cursor: pointer; user-select: none; }
table.sortable-table th[data-k]:hover { color: var(--text); }
.range-box input { width: 70px; padding: 5px 8px; font-size: 13px; }
.props-table th, .props-table td { text-align: center; padding: 7px 6px; }
.props-table th:first-child, .props-table td:first-child { text-align: left; }
.props-table.pin-first th:first-child, .props-table.pin-first td:first-child { position: sticky; left: 0; z-index: 1; background: var(--surface); box-shadow: 1px 0 0 var(--border); }
.props-table tr.alt-row td { background: color-mix(in srgb, var(--surface-2) 55%, var(--surface)); }
.props-table td.price { white-space: nowrap; }
.props-table td.spot-cell { line-height: 1.15; min-width: 56px; }
.props-table th.spot-head { white-space: normal; min-width: 56px; line-height: 1.2; }
#propsCard td[data-bhit].pop-active { outline: 2px solid var(--accent); outline-offset: -2px; }
@media (max-width: 600px) { .props-table th, .props-table td { padding: 6px 4px; font-size: 12.5px; } }
.bars-note { margin-top: 6px; }
svg text { fill: var(--text-muted); font-size: 10px; }
select.search-input { width: auto; }
.shot-panel { background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px; padding: 12px 14px; min-width: 0; }
.shot-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; flex-wrap: wrap; font-weight: 700; font-size: 14px; margin-bottom: 6px; }
.shot-sel { padding: 7px 10px; font-size: 13px; }
.mu-note { margin-top: 8px; font-size: 12.5px; color: var(--text-muted); }
.pos-mini { width: 100%; border-collapse: collapse; font-size: 13px; }
.pos-mini th, .pos-mini td { padding: 5px 6px; text-align: right; border-bottom: 1px solid var(--border); }
.pos-mini th:first-child, .pos-mini td:first-child { text-align: left; }
.court-svg { width: 100%; max-width: 460px; display: block; margin: 0 auto; }
.court-svg .ct-line { fill: none; stroke: var(--text-muted); stroke-width: .35; opacity: .8; }
.court-svg .ct-dash { stroke-dasharray: 1.2 1.2; }
.court-svg .ct-board { stroke: var(--text-muted); stroke-width: .6; }
.court-svg .ct-hoop { fill: none; stroke: var(--critical); stroke-width: .35; }
.court-svg .ct-made { fill: var(--good); stroke: var(--surface); stroke-width: .15; opacity: .9; }
.court-svg .ct-miss { fill: none; stroke: var(--text-muted); stroke-width: .3; opacity: .75; }
.court-svg .ct-heat { fill: var(--accent); }
.ct-key { display: inline-flex; align-items: center; gap: 4px; margin-right: 12px; }
.ct-key i { display: inline-block; width: 9px; height: 9px; font-style: normal; line-height: 9px; text-align: center; }
.ct-key i.ct-made-k { border-radius: 50%; background: var(--good); }
.ct-key i.ct-miss-k { color: var(--text-muted); font-weight: 700; }
@media (max-width: 600px) { .pos-mini th, .pos-mini td { padding: 5px 3px; font-size: 12px; } .shot-panel { padding: 10px; } }

/* Account link in the top bar, and the email notice (shown until the account has an email; no dismiss button on purpose). */
.acct-box { flex: none; display: flex; align-items: center; gap: 8px; }
.acct-name { font-size: 13px; color: var(--text-muted, var(--text)); }
.acct-link { font-size: 13px; padding: 6px 12px; border-radius: 99px; border: 1px solid var(--border); background: var(--surface); color: var(--text); text-decoration: none; white-space: nowrap; }
.acct-link:hover { border-color: var(--accent); color: var(--accent); }
.email-banner { margin: 8px 12px; padding: 10px 14px; border-radius: 8px; font-size: 13.5px; border: 1px solid var(--accent); background: color-mix(in srgb, var(--accent) 10%, var(--surface)); display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.email-banner[hidden] { display: none; }

/* ---- Career stats / Recent game logs panel on the profile (ESPN) ---- */
button.pill.espn-btn { background: transparent; font: inherit; font-size: 12.5px; font-weight: 600; color: var(--accent); border-color: var(--accent); cursor: pointer; }
button.pill.espn-btn.active { background: var(--accent); color: #fff; }
.espn-panel[hidden] { display: none; }
.espn-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.espn-table th, .espn-table td { padding: 6px 8px; white-space: nowrap; text-align: right; border-bottom: 1px solid var(--border); }
.espn-table th:nth-child(-n+3), .espn-table td:nth-child(-n+3) { text-align: left; }
.espn-table .team-logo { width: 20px; height: 20px; margin-right: 4px; }
.lh-dialog { background: var(--surface); color: var(--text); border: 1px solid var(--border); border-radius: 14px; box-shadow: 0 12px 40px rgba(0,0,0,.35); padding: 16px 18px; width: 100%; max-width: 1040px; max-height: 88vh; display: flex; flex-direction: column; min-width: 0; }
.lh-dialog .pop-x { border: 0; background: var(--surface-2); color: var(--text-muted); width: 28px; height: 28px; border-radius: 7px; cursor: pointer; font-size: 13px; flex: none; }
.lh-dialog .pop-x:hover { color: var(--text); }
.lh-table th, .lh-table td { padding: 6px 8px; text-align: center; }
.lh-table th:first-child, .lh-table td:first-child { text-align: left; }
.lh-table thead th { position: sticky; top: 0; background: var(--surface); z-index: 1; box-shadow: 0 1px 0 var(--border); }
.lh-table tr.alt-row td { background: color-mix(in srgb, var(--surface-2) 55%, var(--surface)); }
.lh-menu[hidden], .lh-sub[hidden] { display: none; }
.lh-menu button { display: block; width: 100%; text-align: left; border: 0; background: none; color: var(--text); font: inherit; font-size: 13.5px; padding: 7px 10px; border-radius: 7px; cursor: pointer; }
.lh-menu button:hover { background: var(--surface-2); }
.lh-menu .lh-grp-head { font-weight: 800; letter-spacing: .01em; }
.lh-grp-head .tg { display: inline-block; width: 1em; color: var(--text-muted); }
.lh-sub { padding-left: 16px; }
.lh-pick.active { color: var(--accent); font-weight: 700; }
body.lh-open { overflow: hidden; }
.odds-step:focus-within { border-color: var(--accent); }
.odds-step input.search-input { border: 0 !important; border-radius: 0 !important; width: 84px !important; padding: 8px 2px !important; font-size: 13.5px; text-align: center; background: transparent; box-shadow: none; }
.odds-step input.search-input:focus { outline: none; }
.odds-step button { border: 0; background: var(--surface-2); color: var(--text); width: 26px; font-size: 15px; line-height: 1; cursor: pointer; padding: 0; }
.odds-step button:hover { color: var(--accent); }
.odds-step button.odds-x { width: 22px; font-size: 14px; color: var(--text-muted); background: transparent; }
.odds-step input:placeholder-shown ~ .odds-x { visibility: hidden; }

/* Best Value */
.val-ctl { display: flex; flex-wrap: wrap; gap: 12px 14px; align-items: flex-end; margin-top: 12px; }
.val-ctl .field-lbl { margin-bottom: 4px; }
.val-ctl .pair { display: inline-flex; align-items: center; gap: 6px; }
.val-ctl input.search-input.mm { width: 74px; padding: 8px 8px; font-size: 13.5px; }
.val-table td.vt-edge { font-weight: 800; }
.val-table .vt-sub { font-size: 12px; }
.help-btn:hover { border-color: var(--accent); color: var(--accent); }
@media (max-width: 560px) { .help-txt { display: none; } .help-btn { padding: 0 6px; } }
.lh-dialog.tut-dialog { max-width: 640px; }
.tut-steps li::before { content: counter(tut); position: absolute; left: 0; top: 1px; width: 26px; height: 26px; border-radius: 50%; background: var(--accent); color: #fff; font-size: 13px; font-weight: 800; display: flex; align-items: center; justify-content: center; }
.tut-tips li { margin-bottom: 4px; }
body.tut-open { overflow: hidden; }

/* Analysis: Best edges and the backtest */
table.be-table th, table.be-table td { padding: 7px 6px; }
table.be-table th.l, table.be-table td.l { text-align: left; }
table.be-table td.wrap-ok { white-space: normal; min-width: 90px; max-width: 190px; line-height: 1.25; }
a.rank-link { text-decoration: none; cursor: pointer; }
a.rank-link:hover .rank-badge { outline: 2px solid var(--accent); }
.be-active.on { color: var(--good); font-weight: 700; }
td[data-bpop], td[data-apop] { cursor: pointer; }
td[data-bpop].pop-active, td[data-apop].pop-active { outline: 2px solid var(--accent); outline-offset: -2px; }
#anRoot .error-box { padding: 10px 12px; border: 1px solid var(--critical); border-radius: 8px; color: var(--critical); }

/* Toast and My Picks */
.toast { position: fixed; bottom: 22px; left: 50%; transform: translateX(-50%); z-index: 80; background: var(--text); color: var(--bg); padding: 10px 18px; border-radius: 10px; font-size: 13.5px; font-weight: 600; box-shadow: 0 8px 24px rgba(0,0,0,.3); max-width: calc(100vw - 32px); }
.toast a { color: inherit; text-decoration: underline; }
.add-pick { padding: 2px 9px; font-size: 12px; white-space: nowrap; }
.add-pick[disabled] { color: var(--good); border-color: var(--good); opacity: 1; cursor: default; }
.cup-c { display: inline-block; margin-left: 3px; padding: 0 4px; border-radius: 3px; font-size: 10px; font-weight: 800; line-height: 1.5; vertical-align: 1px; color: var(--bg, #fff); background: var(--good); cursor: help; }
.cup-c + .blowout-b { margin-left: 1px; }
.blowout-b { display: inline-block; margin-left: 3px; padding: 0 4px; border-radius: 3px; font-size: 10px; font-weight: 800; line-height: 1.5; vertical-align: 1px; color: var(--bg, #fff); background: var(--accent); cursor: help; }

/* phones: the same tighter top bar as Blueline, so the account button stays on the first row */
@media (max-width: 600px) { .topbar { gap: 10px; } }

/* A phone: a table of rows with a long note, or with many small numbers (injuries, Returning, the game page's game props and past matchups), becomes a card per row: the first cells side by side,
   each other number under its own label (data-l), the last cell on its own line. No sideways scroll; the column headers are hidden, so these tables cannot be re-sorted on a phone. */
@media (max-width: 600px) {
  table.stack-rows, table.stack-rows tbody, table.stack-rows tr, table.stack-rows td { display: block; }
  table.stack-rows thead { display: none; }
  table.stack-rows tr[hidden] { display: none; }      /* (the flex layout would otherwise show the alternate-line rows that are folded away) */
  table.stack-rows tr { display: flex; flex-wrap: wrap; align-items: baseline; gap: 2px 12px; padding: 9px 0; border-top: 1px solid var(--border); }
  table.stack-rows tr:first-child { border-top: 0; }
  table.stack-rows td { padding: 0; border: 0; white-space: normal; text-align: left; width: auto !important; min-width: 0 !important; max-width: none !important; }
  table.stack-rows td:first-child { flex: 1 1 auto; }
  table.stack-rows td:last-child { flex: 1 0 100%; }
  table.stack-rows td[data-l]::before { content: attr(data-l) " "; font-size: 11.5px; font-weight: 400; color: var(--text-muted); }
  table.stack-rows td.price { text-align: left; }
  /* the dialog's injuries and the Returning list: the team and the player on the first line (the player takes the rest of it), then the numbers side by side, the note below */
  table.ret-rows td:first-child, table.inj-rows td:first-child { flex: 0 0 auto; }
  table.ret-rows td:nth-child(2), table.inj-rows td:nth-child(2) { flex: 1 1 60%; }
  table.ret-rows td:last-child { flex: 0 0 auto; }
  /* the game page's game props: the team or market on its own line, then line and prices, then the hit rates two to a line */
  #gameLevelCard table.stack-rows tr { gap: 6px 10px; }
  #gameLevelCard table.stack-rows td:first-child { flex: 1 0 100%; font-weight: 600; }
  #gameLevelCard table.stack-rows td { flex: 0 0 auto; }
  #gameLevelCard table.stack-rows td.hit-cell, #gameLevelCard table.stack-rows td:last-child { flex: 1 1 40%; padding: 4px 8px; border-radius: 6px; }
}

/* A phone: the profile's Droughts & streaks table becomes a card per row: the stat and line first (on Blueline the stat and line controls take the whole first line), then right now, longest drought, longest streak and hit rate under their labels. */
@media (max-width: 600px) {
  table.strk-rows td:last-child { flex: 0 0 auto; }
  table.strk-ctl td:first-child { flex: 1 0 100%; }
  table.strk-ctl td:last-child { margin-left: auto; }
}

.spots-toggle-row { display: none; }
/* A phone: the player profile's Props & Odds tables become cards (the numbers carry their column's heading as data-l: /shared/js/table-labels.js). The prop ladder is one card per prop:
   the prop on the first line, then its price(s), implied chance and result, then each spot / split hit rate as a small tile, two to a line (a split with no games is left out).
   The other three tables (situations, record by prop, line history) are plain stacked rows. */
@media (max-width: 600px) {
  table.lbl-rows td:last-child { flex: 0 0 auto; }
  table.lbl-rows.pin-first td:first-child, table.lbl-rows.pin-first td:nth-child(2) { position: static; box-shadow: none; min-width: 0; background: transparent; }
  table.lbl-rows td[data-empty] { display: none; }
  .latest-lines-wrap { overflow: visible; max-height: none; }
  table.prop-cards tr { gap: 6px 8px; padding: 10px 0; }
  table.prop-cards td:first-child { flex: 1 0 100%; font-size: 14px; font-weight: 700; order: 1; }
  table.prop-cards td.price { order: 2; flex: 0 0 auto; text-align: left; }
  table.prop-cards td[data-l="Implied"] { order: 3; flex: 0 0 auto; }
  table.prop-cards td.hit-cell { order: 5; flex: 1 1 calc(33% - 6px); min-width: 0; padding: 3px 8px; text-align: left; display: flex; flex-wrap: wrap; align-items: baseline; gap: 0 6px; line-height: 1.2; }
  /* the spot / split tiles stay folded until "Show spot splits" is on: the prices and the L10 / season / all rates are what a card shows by default */
  table.prop-cards td.spot-cell { display: none; order: 6; flex: 1 1 calc(50% - 6px); }
  .spots-open table.prop-cards td.spot-cell { display: flex; }
  .spots-toggle-row { display: flex; gap: 10px; align-items: center; margin: 0 0 8px; }
  .spots-toggle-row .chip { flex: none; white-space: nowrap; }
  table.prop-cards td.hit-cell::before { flex: 1 0 100%; font-size: 10px; text-transform: uppercase; letter-spacing: .03em; }
  table.prop-cards td.hit-cell .spot-edge { margin-top: 0; }
  table.prop-cards tr.alt-row td:first-child { padding-left: 14px; }
}

/* the note that holds the standard / main line's place in an opened ladder */
tr.alt-std td { font-size: 12px; font-style: italic; padding: 4px 8px 4px 30px; }
@media (max-width: 600px) {
  table.prop-cards tr.alt-std { padding: 2px 0; border-top: 0; }
  table.prop-cards tr.alt-std td:first-child { flex: 1 0 100%; font-size: 12px; font-weight: 400; font-style: italic; padding-left: 14px; }
}

/* A phone: the team profile's market chips (Moneyline / Spread / Total ...) wrap instead of scrolling sideways. */
@media (max-width: 600px) {
  .chip-row.scroll-x:has(> [data-market]) { flex-wrap: wrap; overflow: visible; }
}

/* A phone: Biggest Movers is a card per move. Rank, selection and the probability shift on the first line, the prop and matchup under it,
   then the opening / baseline price, the latest price and the result. */
@media (max-width: 600px) {
  table.mov-rows tr { gap: 3px 10px; padding: 10px 0; }
  table.mov-rows td { order: 3; }
  table.mov-rows td:first-child { order: 1; flex: 0 0 auto; }
  table.mov-rows td:nth-child(2) { order: 1; flex: 1 1 calc(100% - 120px); font-weight: 600; }
  table.mov-rows td:nth-last-child(2) { order: 1; flex: 0 0 auto; margin-left: auto; font-size: 14px; }
  table.mov-rows tr::after { content: ""; order: 2; flex: 1 0 100%; height: 0; }
  table.mov-rows td[data-l="Prop"], table.mov-rows td[data-l="Line"], table.mov-rows td[data-l="Matchup"] { order: 2; flex: 0 0 auto; font-size: 12px; }
  table.mov-rows td:last-child { order: 2; flex: 0 0 auto; margin-left: auto; font-weight: 700; font-size: 12px; }      /* the result rides the prop / matchup line */
  table.mov-rows td:last-child::before { display: none; }
  table.mov-rows td[data-l="Selection"]::before, table.mov-rows td[data-l="Prop"]::before, table.mov-rows td[data-l="Line"]::before, table.mov-rows td[data-l="Matchup"]::before,
  table.mov-rows td[data-l="Prob Shift"]::before, table.mov-rows td[data-l="Prob shift"]::before, table.mov-rows td[data-l="Move"]::before { display: none; }
  table.mov-rows td[data-empty] { display: none; }
}

/* A phone: the referee tables are cards (stack-rows). A table with sort-heads keeps its sortable headings as a row of small buttons above the cards. */
@media (max-width: 600px) {
  table.sort-heads thead { display: block; }
  table.sort-heads thead tr { display: flex; flex-wrap: wrap; gap: 6px; padding: 0 0 10px; border: 0; }
  table.sort-heads thead th { display: block; width: auto; padding: 4px 10px; border: 1px solid var(--border); border-radius: 999px; font-size: 12px; white-space: nowrap; position: static; }
  table.sort-heads thead th:not([data-k]):not([data-sk]) { display: none; }
  table.ref-crew td:nth-child(2) { flex: 1 0 100%; }
  table.ref-crew td:last-child, table.ref-all td:last-child { flex: 0 0 auto; }
  table.ref-all td:first-child { font-weight: 700; }
  table.stack-rows td[colspan]::before { display: none; }
  table.ref-crew td[colspan] { flex: 1 1 100%; }
}

/* By The Odds' example pop-up on a phone: each example is three lines (player and result; date, game, rank; line, price, what he got) instead of a nine-column row that scrolled sideways.
   Cells in order: 1 date, 2 player, 3 team, 4 opponent, 5 line, 6 over price, 7 rank, 8 got, 9 result. */
@media (max-width: 600px) {
  .cell-pop.list.bo-pop .pop-games, .cell-pop.list.bo-pop .pop-games tbody { display: block; white-space: normal; }
  .cell-pop.list.bo-pop .pop-games thead { display: none; }
  .cell-pop.list.bo-pop .pop-body { padding-right: 8px; }                  /* room for the scroll bar */
  .cell-pop.list.bo-pop .pop-games tr { display: grid; grid-template-columns: auto auto auto 1fr; column-gap: 10px; row-gap: 2px; align-items: center; padding: 7px 0; border-bottom: 1px solid var(--border); }
  .cell-pop.list.bo-pop .pop-games tr:last-child { border-bottom: none; }
  .cell-pop.list.bo-pop .pop-games td { padding: 0; border: 0; white-space: nowrap; min-width: 0; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(2) { grid-area: 1 / 1 / 2 / 4; white-space: normal; font-weight: 600; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(9) { grid-area: 1 / 4; justify-self: end; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(1) { grid-area: 2 / 1; color: var(--text-muted); }
  .cell-pop.list.bo-pop .pop-games td:nth-child(3) { grid-area: 2 / 2; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(3) img { width: 16px; height: 16px; object-fit: contain; vertical-align: middle; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(4) { grid-area: 2 / 3; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(4)::before { content: "vs "; color: var(--text-muted); }
  .cell-pop.list.bo-pop .pop-games td:nth-child(7) { grid-area: 2 / 4; justify-self: end; color: var(--text-muted); }
  .cell-pop.list.bo-pop .pop-games td:nth-child(5) { grid-area: 3 / 1; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(5)::before { content: "Line "; color: var(--text-muted); }
  .cell-pop.list.bo-pop .pop-games td:nth-child(6) { grid-area: 3 / 2; font-weight: 700; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(6)::before { content: "Over "; color: var(--text-muted); font-weight: 400; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(8) { grid-area: 3 / 3 / 4 / 5; }
  .cell-pop.list.bo-pop .pop-games td:nth-child(8)::before { content: "Got "; color: var(--text-muted); }
}
