/* ==========================================================================
   Team and player pages in the iOS app's shape (2026-11-22), drawn from
   Features/Topic (TopicV2View, TeamHomeModules, TeamRosterList,
   PlayerHomeModules, PlayerPage). Loaded by team_page.html and
   player_page.html only, after their older sheets, so it has the last word.

   Header: the pixel-field band with the crest or headshot, the mono eyebrow,
   the name and the outline tiles. Then the page tabs, pinned under the top
   bar, and each tab flat on the page, split by hairlines.
   Phone = the app. Desktop = the same content in one centred column.
   Scripts: js/app-topic.js (window.SIAppTopic), team-page.js, player-page.js.
   ========================================================================== */

.at-page {
  --at-g: 18px;                       /* the app's gutter (tlGutter) */
  --at-w: 860px;                      /* the centred column on a wide screen */
  --at-pad: max(var(--at-g), calc((100% - var(--at-w)) / 2 + var(--at-g)));
  color: var(--tl-ink); font-family: var(--tl-font);
}
.at-page [hidden] { display: none !important; }
/* Resets over the base sheets (Pico's buttons, links and sections; the lazy-image ground). */
:where(.at-band, .at-tabs, .at-panel) a { color: inherit; text-decoration: none; }
.at-page :is(.at-band, .at-tabs, .at-panel) button { margin: 0; box-shadow: none; }
.at-page :is(.at-band, .at-tabs, .at-panel) :is(a, button):focus-visible { box-shadow: var(--tl-focus-ring); }
:where(.at-band, .at-panel) :is(h1, h2, h3, p) { margin: 0; }
.at-page :is(.at-band, .at-panel) section { margin-bottom: 0; }
.at-page :is(.at-band, .at-panel) img { background: transparent; }
.at-spacer { flex: 1; min-width: 0; }

/* ---- Band: back and the page's controls, then who this is ---- */
.at-band.tl-band { padding: 0 var(--at-pad) 16px; border-bottom: 0; }
/* The field fades out toward the tabs, as the app's does. */
.at-band > canvas.tl-field {
  -webkit-mask-image: linear-gradient(180deg, #000, rgba(0, 0, 0, 0.55) 55%, transparent);
  mask-image: linear-gradient(180deg, #000, rgba(0, 0, 0, 0.55) 55%, transparent);
}
.at-bar { display: flex; align-items: center; gap: 8px; min-height: 44px; padding-top: 4px; }
.at-back { display: inline-flex; align-items: center; gap: 4px; min-height: 44px; margin-left: -4px; padding-right: 8px; font: 500 15px/1 var(--tl-font); color: var(--tl-ink); }
.at-back svg { width: 18px; height: 18px; }
.at-back:hover { color: var(--tl-ink-70); }
.at-follow {
  display: inline-flex; align-items: center; gap: 5px; height: 30px; padding: 0 12px;
  border-radius: 8px; border: 1px solid transparent; background: var(--tl-ink); color: var(--tl-on-ink);
  font: 600 13px/1 var(--tl-font); white-space: nowrap; cursor: pointer;
}
.at-follow svg { width: 11px; height: 11px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linejoin: round; }
.at-follow:hover { background: var(--tl-ink-hover); color: var(--tl-on-ink); }
.at-follow[aria-pressed="true"] { background: var(--tl-raised); border-color: var(--tl-line-12); color: var(--tl-ink); }
.at-follow[aria-pressed="true"] svg { fill: currentColor; }
.at-follow:disabled { opacity: 0.6; cursor: default; }
.at-icon {
  display: grid; place-items: center; width: 30px; height: 30px; padding: 0; flex: none;
  border-radius: 8px; border: 1px solid var(--tl-line-12); background: transparent; color: var(--tl-ink-60); cursor: pointer;
}
.at-icon:hover { color: var(--tl-ink); border-color: var(--tl-line-20); }
.at-icon[aria-pressed="true"] { color: var(--tl-ink); }
.at-icon[aria-pressed="true"] svg { fill: currentColor; }

.at-id { display: flex; align-items: center; gap: 14px; padding-top: 10px; }
.at-crest { flex: none; display: grid; place-items: center; width: 64px; height: 64px; }
.at-crest img { width: 56px; height: 56px; object-fit: contain; }
.at-face {
  position: relative; flex: none; display: grid; place-items: center; width: 72px; height: 72px; overflow: hidden;
  border-radius: 50%; border: 1px solid var(--tl-line-12); background: #fff;
  font: 650 26px/1 var(--tl-font); color: rgba(16, 20, 24, 0.62);
}
.at-page .at-face img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center top; background: #fff; }
.at-id-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 5px; }
.at-eyebrow { display: flex; align-items: center; gap: 6px; min-height: 16px; min-width: 0; font: 500 10px/1.2 var(--tl-mono); letter-spacing: 0.6px; text-transform: uppercase; color: var(--tl-ink-55); white-space: nowrap; overflow: hidden; }
.at-eyebrow .chip { flex: none; padding: 2px 5px; border-radius: 4px; background: var(--tl-ink); color: var(--tl-on-ink); font: 650 9.5px/1.2 var(--tl-mono); letter-spacing: 0.5px; }
.at-eyebrow img { flex: none; width: 13px; height: 13px; object-fit: contain; }
.at-eyebrow > span { overflow: hidden; text-overflow: ellipsis; }
a.at-eyebrow:hover { color: var(--tl-ink); }
.at-name { font: 750 30px/1.12 var(--tl-font); letter-spacing: -0.9px; color: var(--tl-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-name.is-player { font-size: 28px; letter-spacing: -0.8px; }
.at-bodyline { font: 400 12.5px/1.3 var(--tl-font); color: var(--tl-ink-55); }
.at-bodyline:empty { display: none; }

.at-tiles { display: flex; gap: 8px; margin-top: 14px; }
.at-tiles:empty { display: none; }
.at-tile {
  flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 5px; padding: 8px 10px;
  border-radius: 10px; border: 1px solid var(--tl-line-10);
  background: color-mix(in srgb, var(--tl-page) 70%, transparent);
}
a.at-tile:hover { border-color: var(--tl-line-20); }
.at-tile .k { font: 600 8.5px/1 var(--tl-mono); letter-spacing: 0.7px; text-transform: uppercase; color: var(--tl-ink-45); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-tile .v { display: flex; align-items: center; gap: 6px; font: 650 15px/1.15 var(--tl-font); font-variant-numeric: tabular-nums; color: var(--tl-ink); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-tile .v img, .at-tile .v .at-logo { width: 16px; height: 16px; }
.at-tile.is-game .v { font-size: 14px; }
@media (min-width: 720px) { .at-tile { max-width: 220px; } }

.at-status { margin: 0; padding: 10px var(--at-pad); border-bottom: 1px solid var(--tl-line-06); background: var(--tl-fill-03); font: 400 13px/1.45 var(--tl-font); color: var(--tl-ink-75); }

/* ---- Page tabs (TopicTabsRow): pinned under the top bar ---- */
.at-tabs.tl-tabs {
  position: sticky; top: var(--tl-topbar-h, 0px); z-index: 6;
  display: flex; align-items: stretch; gap: 20px; min-height: 42px; margin: 0; padding: 0 var(--at-pad);
  background: var(--tl-page); border-bottom: 1px solid var(--tl-line-08);
}
.at-page .at-tabs .tl-tab { padding: 0; min-height: 42px; font: 500 14px/1 var(--tl-font); color: var(--tl-ink-50); }
.at-page .at-tabs .tl-tab[aria-selected="true"] { font-weight: 650; color: var(--tl-ink); }
.at-tabs .tl-tab::after { left: 0; right: 0; bottom: 0; border-radius: 1px; transition: none; }
.at-tabs .tl-tab:focus-visible { outline: 2px solid var(--tl-ink); outline-offset: -2px; }

/* ---- Body: each tab is one column of flat rows ---- */
.at-body { padding-bottom: 48px; }
.at-panel { padding: 0 calc(var(--at-pad) - var(--at-g)); }
.at-rule { height: 1px; margin: 0; border: 0; background: var(--tl-line-06); }
.at-gap { height: 16px; }
.at-note { margin: 0; padding: 14px var(--at-g); font: 400 13px/1.45 var(--tl-font); color: var(--tl-ink-50); }
.at-band-title { padding: 13px var(--at-g) 4px; font: 650 10.5px/1.2 var(--tl-mono); letter-spacing: 0.9px; text-transform: uppercase; color: var(--tl-ink); }
.at-band-title.has-rule { margin-top: 22px; border-top: 1px solid var(--tl-line-08); }

/* Crest: an image, or the team's letters in a square when there is none. */
.at-logo { flex: none; display: inline-block; width: 24px; height: 24px; object-fit: contain; }
span.at-logo { display: inline-grid; place-items: center; overflow: hidden; border-radius: 5px; background: var(--tl-fill-06); font: 650 8.5px/1 var(--tl-mono); color: var(--tl-ink-55); }
span.at-logo:empty { background: transparent; }
/* Headshot with the initial underneath; a broken photo just disappears. */
.at-av {
  position: relative; flex: none; display: grid; place-items: center; width: var(--s, 36px); height: var(--s, 36px); overflow: hidden;
  border-radius: 50%; border: 1px solid var(--tl-line-08); background: var(--tl-fill-06);
  font: 650 13px/1 var(--tl-font); color: var(--tl-ink-50);
}
/* The photo's own ground covers the initial (a cut-out headshot is see-through). */
.at-page .at-av img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: center top; background: color-mix(in srgb, var(--tl-ink) 6%, var(--tl-page)); }

/* Segmented filter and chips rows */
.at-seg { padding: 0 var(--at-g) 12px; overflow-x: auto; scrollbar-width: none; }
.at-seg::-webkit-scrollbar, .at-chips::-webkit-scrollbar, .at-strip::-webkit-scrollbar, .at-chart::-webkit-scrollbar { display: none; }
/* (The app's sizes: the shell's 44px floor for chips and segments is lifted here.) */
.at-page .at-seg .tl-seg > button { height: 30px; min-height: 30px; padding: 0 12px; font-size: 13px; }
.at-page .at-seg .tl-seg > button[aria-pressed="true"] { font-weight: 650; }
.at-chips { display: flex; gap: 6px; padding: 14px var(--at-g); overflow-x: auto; scrollbar-width: none; border-bottom: 1px solid var(--tl-line-06); }
.at-page .at-chips .tl-chip { flex: none; height: 32px; min-height: 32px; padding: 0 13px; border-radius: 8px; font-weight: 500; }
.at-page .at-chips .tl-chip[aria-pressed="true"] { font-weight: 650; }
.at-pill {
  display: inline-flex; align-items: center; justify-content: center; height: 30px; padding: 0 12px;
  border-radius: 8px; border: 1px solid var(--tl-line-10); background: transparent;
  font: 500 13px/1 var(--tl-font); color: var(--tl-ink-62); white-space: nowrap; cursor: pointer;
}
.at-pill:hover { color: var(--tl-ink); border-color: var(--tl-line-20); }
.at-pill-row { padding: 10px var(--at-g) 0; }
.at-pill-row .at-pill { width: 100%; }
@media (min-width: 720px) { .at-pill-row .at-pill { width: auto; } }

/* ---- Schedule strip: a tile a week ---- */
.at-strip { overflow-x: auto; scrollbar-width: none; overscroll-behavior-x: contain; border-bottom: 1px solid var(--tl-line-06); }
.at-strip-row { display: flex; width: max-content; min-width: 100%; }
.at-cell {
  position: relative; flex: none; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px;
  width: 98px; height: 122px; padding: 0 4px; color: var(--tl-ink);
}
.at-strip.is-player .at-cell { height: 136px; }
.at-cell + .at-cell::before { content: ''; position: absolute; left: 0; top: 17px; bottom: 17px; width: 1px; background: var(--tl-line-06); }
.at-cell.is-next { background: var(--tl-raised); }
.at-cell.is-next::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--tl-ink); }
a.at-cell:hover { background: var(--tl-fill-03); color: var(--tl-ink); }
a.at-cell.is-next:hover { background: var(--tl-raised); }
.at-cell-k { min-height: 10px; font: 500 9.5px/1 var(--tl-mono); letter-spacing: 0.6px; text-transform: uppercase; color: var(--tl-ink-45); white-space: nowrap; }
.at-cell.is-next .at-cell-k { font-weight: 700; color: var(--tl-ink-90); }
.at-cell .at-logo { width: 32px; height: 32px; }
.at-cell span.at-logo { font-size: 10px; border-radius: 7px; }
.at-cell-bye { width: 32px; height: 32px; border-radius: 50%; border: 1px dashed var(--tl-line-18); }
.at-cell-opp { display: flex; align-items: baseline; gap: 3px; font: 650 12px/1 var(--tl-mono); white-space: nowrap; }
.at-cell-opp small { font: 400 10px/1 var(--tl-mono); color: var(--tl-ink-45); }
.at-cell-res { display: flex; align-items: center; gap: 3px; font: 500 10.5px/1 var(--tl-mono); color: var(--tl-ink-70); white-space: nowrap; }
.at-wl { padding: 1px 3px; border-radius: 3px; font: 700 10px/1.1 var(--tl-mono); background: var(--tl-fill-06); color: var(--tl-ink-60); }
.at-wl.is-w { background: var(--tl-up-bg); color: var(--tl-up); }
.at-wl.is-l { background: var(--tl-down-bg); color: var(--tl-down); }
.at-cell-date { display: flex; align-items: center; gap: 5px; font: 400 9.5px/1 var(--tl-mono); letter-spacing: 0.5px; text-transform: uppercase; color: var(--tl-ink-45); white-space: nowrap; }
.at-cell-date.is-dim { color: var(--tl-ink-40); }
.at-cell-stat { font: 700 12px/1 var(--tl-mono); white-space: nowrap; }
.at-cell-sub { max-width: 100%; min-height: 9px; font: 400 8.5px/1 var(--tl-mono); letter-spacing: 0.2px; color: var(--tl-ink-50); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---- Team leaders ---- */
.at-leader { display: flex; align-items: center; gap: 12px; min-height: 64px; padding: 8px var(--at-g); color: var(--tl-ink); }
.at-leader + .at-leader { border-top: 1px solid var(--tl-line-05); }
a.at-leader:hover { background: var(--tl-fill-03); color: var(--tl-ink); }
.at-leader-text { flex: 1; min-width: 0; }
.at-leader-text small { display: block; font: 600 8.5px/1 var(--tl-mono); letter-spacing: 0.7px; color: var(--tl-ink-45); }
.at-leader-text b { display: block; margin-top: 4px; font: 650 14.5px/1.2 var(--tl-font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-leader-v { flex: none; text-align: right; }
.at-leader-v b { display: block; font: 500 19px/1.1 var(--tl-font); font-variant-numeric: tabular-nums; }
.at-leader-v small { display: block; margin-top: 3px; font: 400 8.5px/1 var(--tl-mono); letter-spacing: 0.6px; color: var(--tl-ink-45); }

/* ---- Season at a glance: the by-game chart, then ranks on a slider ---- */
.at-glance { padding-top: 16px; border-top: 1px solid var(--tl-line-06); }
.at-glance.is-player { border-top: 0; }
.at-chart-title { padding: 0 var(--at-g) 8px; font: 650 13px/1.2 var(--tl-font); color: var(--tl-ink); }
.at-chart { --vis: 5; display: flex; padding: 0 var(--at-g) 14px; overflow-x: auto; scrollbar-width: none; overscroll-behavior-x: contain; }
@media (min-width: 720px) { .at-chart { --vis: 10; } }
.at-chart-col { flex: 0 0 calc(100% / min(var(--n, 5), var(--vis))); min-width: 0; display: flex; flex-direction: column; align-items: center; }
.at-chart-col .up { display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: 3px; height: var(--above, 102px); }
.at-chart-col .dn { display: flex; flex-direction: column; align-items: center; gap: 3px; height: var(--below, 4px); }
.at-chart-col .base { align-self: stretch; height: 1px; background: var(--tl-line-14); }
.at-chart-col b { font: 650 11px/1 var(--tl-mono); color: var(--tl-ink-90); }
.at-chart-col b.is-l { color: var(--tl-down); }
.at-chart-col i { display: block; width: 26px; min-height: 2px; border-radius: 2px; background: var(--tl-ink); }
.at-chart-col i.is-l { background: var(--tl-down); }
.at-chart-col .at-logo { width: 30px; height: 30px; margin-top: 8px; }
.at-chart.is-single { align-items: flex-end; min-height: 146px; }
.at-chart.is-single .at-chart-col { justify-content: flex-end; gap: 5px; }
.at-chart.is-single .at-logo { margin-top: 3px; }

.at-rank { padding: 11px var(--at-g); border-top: 1px solid var(--tl-line-05); }
.at-rank-line { display: flex; align-items: baseline; gap: 10px; }
.at-rank-line .k { flex: 1; min-width: 0; font: 400 13px/1.3 var(--tl-font); color: var(--tl-ink-70); }
.at-rank-line .v { font: 650 18px/1.1 var(--tl-font); font-variant-numeric: tabular-nums; }
.at-rank-line .n { min-width: 44px; text-align: right; font: 650 9.5px/1 var(--tl-mono); }
.at-track { --x: max(30px, calc(var(--p, 0) * 100%)); position: relative; height: 30px; margin-top: 10px; }
.at-track::before { content: ''; position: absolute; left: 0; right: 0; top: 12.5px; height: 5px; border-radius: 5px; background: var(--tl-line-14); }
.at-track > i { position: absolute; left: 0; top: 12.5px; width: var(--x); height: 5px; border-radius: 5px; background: var(--tl-ink); }
.at-marker { position: absolute; top: 0; left: calc(var(--x) - 30px); display: grid; place-items: center; width: 30px; height: 30px; overflow: hidden; border-radius: 50%; background: var(--tl-page); }
.at-marker img { width: 24px; height: 24px; object-fit: contain; }
.at-page .at-marker.is-face img { width: 28px; height: 28px; border-radius: 50%; object-fit: cover; object-position: center top; background: #fff; border: 1px solid var(--tl-line-12); }
.at-scale { display: flex; justify-content: space-between; padding: 8px var(--at-g) 0; font: 400 8.5px/1 var(--tl-mono); letter-spacing: 0.6px; text-transform: uppercase; color: var(--tl-ink-40); }

/* ---- Standings: five rows around the team ---- */
.at-stand { margin-top: 22px; padding-top: 12px; border-top: 1px solid var(--tl-line-06); }
.at-stand-head, .at-stand-row { display: grid; grid-template-columns: 22px 22px minmax(0, 1fr) 44px; gap: 10px; align-items: center; padding: 0 var(--at-g); }
.at-stand.has-conf :is(.at-stand-head, .at-stand-row) { grid-template-columns: 22px 22px minmax(0, 1fr) 44px 44px; }
.at-stand-head { height: 22px; font: 400 9px/1 var(--tl-mono); letter-spacing: 0.6px; color: var(--tl-ink-40); }
.at-stand-head .r, .at-stand-row .c, .at-stand-row .o { text-align: right; }
.at-stand-row { position: relative; height: 44px; border-top: 1px solid var(--tl-line-05); color: var(--tl-ink); }
a.at-stand-row:hover { background: var(--tl-fill-03); color: var(--tl-ink); }
.at-stand-row.is-me { background: var(--tl-fill-05); }
.at-stand-row.is-me::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--tl-ink); }
.at-stand-row .n { font: 600 12px/1 var(--tl-mono); }
.at-stand-row .at-logo { width: 20px; height: 20px; }
.at-stand-row .t { font: 600 14px/1.2 var(--tl-font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-stand-row.is-me .t { font-weight: 700; }
.at-stand-row .c { font: 600 12px/1 var(--tl-mono); }
.at-stand-row .o { font: 400 12px/1 var(--tl-mono); color: var(--tl-ink-60); }

/* ---- The tagged feed: All, News, Social, Video ---- */
.at-feed { margin-top: 16px; padding-top: 16px; border-top: 1px solid var(--tl-line-06); }
.at-feed.is-lead { margin-top: 0; border-top: 0; }
.at-feed .at-seg { padding-bottom: 4px; }
.at-story { display: flex; align-items: flex-start; gap: 12px; padding: 12px var(--at-g); border-bottom: 1px solid var(--tl-line-06); color: var(--tl-ink); }
a.at-story:hover { background: var(--tl-fill-03); color: var(--tl-ink); }
.at-story-text { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.at-story-meta { display: flex; align-items: center; gap: 5px; min-width: 0; font: 400 11.5px/1.2 var(--tl-font); color: var(--tl-ink-50); }
.at-story-meta .at-logo { width: 13px; height: 13px; }
.at-story-meta .src { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-story-meta .kind { flex: none; padding: 2px 5px; border-radius: 4px; background: var(--tl-fill-06); font: 600 9px/1 var(--tl-mono); letter-spacing: 0.5px; color: var(--tl-ink-60); }
.at-story-meta time { flex: none; font: 400 10px/1 var(--tl-mono); letter-spacing: 0.3px; color: var(--tl-ink-40); }
.at-story-title { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; font: 650 14.5px/1.32 var(--tl-font); letter-spacing: -0.15px; overflow-wrap: anywhere; }
.at-story-thumb { position: relative; flex: none; width: 84px; height: 84px; overflow: hidden; border-radius: 8px; border: 1px solid var(--tl-line-06); background: var(--tl-fill-06); }
.at-story-thumb img { width: 100%; height: 100%; object-fit: cover; }
.at-story-thumb.is-video::after { content: ''; position: absolute; left: 50%; top: 50%; margin: -8px 0 0 -5px; border: 8px solid transparent; border-left: 13px solid #fff; border-right: 0; filter: drop-shadow(0 1px 3px rgba(0, 0, 0, 0.6)); }

/* ---- Roster ---- */
.at-player { display: flex; align-items: center; gap: 12px; min-height: 58px; padding: 8px var(--at-g); color: var(--tl-ink); }
.at-player + .at-player { background: linear-gradient(var(--tl-line-06), var(--tl-line-06)) calc(var(--at-g) + 48px) 0 / 100% 1px no-repeat; }
a.at-player:hover { background-color: var(--tl-fill-03); color: var(--tl-ink); }
.at-player-text { flex: 1; min-width: 0; }
.at-player-text b { display: block; font: 600 14.5px/1.2 var(--tl-font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-player-text small { display: block; margin-top: 4px; font: 400 9.5px/1 var(--tl-mono); letter-spacing: 0.4px; text-transform: uppercase; color: var(--tl-ink-50); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-player .j { flex: none; font: 600 12px/1 var(--tl-mono); color: var(--tl-ink-55); }
.at-player .chev { flex: none; width: 10px; height: 10px; color: var(--tl-ink-35); }

/* ---- Schedule tab ---- */
.at-game { display: flex; align-items: center; gap: 12px; min-height: 60px; padding: 8px var(--at-g); border-bottom: 1px solid var(--tl-line-06); color: var(--tl-ink); }
.at-game:last-child { border-bottom: 0; }
a.at-game:hover { background: var(--tl-fill-03); color: var(--tl-ink); }
.at-game.is-next { background: color-mix(in srgb, var(--tl-live) 5%, transparent); }
.at-game-day { flex: none; width: 50px; }
.at-game-day small { display: block; font: 600 9px/1 var(--tl-mono); letter-spacing: 0.6px; text-transform: uppercase; color: var(--tl-ink-45); }
.at-game-day b { display: block; margin-top: 3px; font: 600 11px/1 var(--tl-mono); text-transform: uppercase; white-space: nowrap; }
.at-game-text { flex: 1; min-width: 0; }
.at-game-opp { display: flex; align-items: baseline; gap: 5px; min-width: 0; }
.at-game-opp .at { flex: none; font: 400 13.5px/1.2 var(--tl-font); color: var(--tl-ink-45); }
.at-game-opp .rk { flex: none; font: 600 10px/1 var(--tl-mono); color: var(--tl-ink-45); }
.at-game-opp b { font: 600 15px/1.2 var(--tl-font); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-game-meta { display: block; margin-top: 4px; font: 400 9.5px/1 var(--tl-mono); letter-spacing: 0.4px; text-transform: uppercase; color: var(--tl-ink-45); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.at-game-res { flex: none; display: flex; align-items: center; gap: 6px; font: 600 13px/1 var(--tl-mono); font-variant-numeric: tabular-nums; }
.at-game-res .r { font: 700 11px/1 var(--tl-mono); color: var(--tl-ink-50); }
.at-game-res .r.is-w { color: var(--tl-up); }
.at-game-res .r.is-l { color: var(--tl-down); }
.at-next-chip { flex: none; display: inline-flex; align-items: center; height: 20px; padding: 0 7px; border-radius: 5px; background: var(--tl-up-bg); font: 600 9.5px/1 var(--tl-mono); letter-spacing: 0.6px; color: var(--tl-up); }

/* ---- Tables: names stay put while the numbers scroll ---- */
.at-table { overflow-x: auto; overscroll-behavior-x: contain; scrollbar-width: thin; }
.at-table:focus-visible { outline: 2px solid var(--tl-ink); outline-offset: -2px; }
.at-trow {
  display: grid; align-items: center; padding-right: var(--at-g); color: var(--tl-ink);
  grid-template-columns: minmax(var(--name, 164px), 2fr) repeat(var(--cols, 6), minmax(60px, 1fr));
  min-width: calc(var(--name, 164px) + var(--cols, 6) * 60px + 2 * var(--at-g));
}
.at-trow > :first-child { position: sticky; left: 0; z-index: 1; align-self: stretch; display: flex; align-items: center; min-width: 0; padding-left: var(--at-g); background: var(--tl-page); }
.at-trow.is-head { height: 30px; }
.at-trow.is-head > :first-child { font: 400 9px/1 var(--tl-mono); letter-spacing: 0.6px; color: var(--tl-ink-40); }
.at-trow.is-row { min-height: 58px; border-top: 1px solid var(--tl-line-05); }
.at-trow.is-total { min-height: 50px; border-top: 1px solid var(--tl-line-12); }
.at-trow.is-total > :first-child { font: 600 10.5px/1 var(--tl-mono); letter-spacing: 0.6px; }
.at-trow .c { text-align: center; font: 400 14px/1 var(--tl-mono); font-variant-numeric: tabular-nums; color: var(--tl-ink-70); white-space: nowrap; }
.at-trow .c.is-sort, .at-trow.is-total .c { font-weight: 600; color: var(--tl-ink); }
.at-sort { display: block; width: 100%; height: 30px; padding: 0; border: 0; background: transparent; font: 400 10px/1 var(--tl-mono); letter-spacing: 0.4px; color: var(--tl-ink-40); white-space: nowrap; cursor: pointer; }
.at-sort:hover, .at-sort.is-sort { color: var(--tl-ink); }
.at-sort.is-sort { font-weight: 600; }
.at-tname { display: flex; align-items: center; gap: 9px; min-width: 0; padding: 6px 8px 6px 0; }
.at-tname .who { min-width: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font: 600 15px/1.2 var(--tl-font); }
.at-tname .who small { margin-left: 6px; font: 400 10px/1 var(--tl-mono); color: var(--tl-ink-45); }
a.at-trow:hover, a.at-trow:hover > :first-child { color: var(--tl-ink); }
@media (min-width: 720px) { .at-trow { --name: 220px; } }

/* A player's game-by-game tables: the game, then the numbers flush right. */
.at-trow.is-log { grid-template-columns: minmax(var(--name, 122px), 1fr) var(--widths); min-width: calc(var(--name, 122px) + var(--sum, 240px) + 2 * var(--at-g)); }
.at-trow.is-log.is-head { height: 26px; }
.at-trow.is-log.is-head > * { font: 400 9px/1 var(--tl-mono); letter-spacing: 0.4px; color: var(--tl-ink-40); }
.at-trow.is-log.is-row, .at-trow.is-log.is-total { min-height: 54px; }
.at-trow.is-log.is-total { border-top-color: var(--tl-line-14); }
.at-trow.is-log.is-total > :first-child { font-weight: 700; letter-spacing: 0.5px; }
.at-trow.is-log .c { text-align: right; font: 500 13.5px/1 var(--tl-mono); color: var(--tl-ink); }
.at-trow.is-log.is-total .c { font-weight: 700; }
.at-trow.is-log.is-head .c { font: 400 9px/1 var(--tl-mono); color: var(--tl-ink-40); }
@media (min-width: 720px) { .at-trow.is-log { --name: 200px; } }
.at-gcell { display: flex; align-items: center; gap: 8px; min-width: 0; padding-right: 6px; }
.at-gcell .at-logo { width: 20px; height: 20px; }
.at-gcell-text { min-width: 0; }
.at-gcell-opp { display: flex; align-items: baseline; gap: 4px; font: 600 13px/1.2 var(--tl-font); white-space: nowrap; }
.at-gcell-opp small { font: 400 11.5px/1.2 var(--tl-font); color: var(--tl-ink-45); }
.at-gcell-res { display: flex; gap: 4px; margin-top: 3px; font: 600 9px/1 var(--tl-mono); text-transform: uppercase; color: var(--tl-ink-50); white-space: nowrap; }
.at-gcell-res .is-w { color: var(--tl-up); }
.at-gcell-res .is-l { color: var(--tl-down); }

/* ---- States: empty, locked, loading ---- */
.at-empty { display: flex; flex-direction: column; align-items: center; gap: 8px; padding: 56px var(--at-g); text-align: center; }
.at-empty svg { width: 20px; height: 20px; color: var(--tl-ink-35); }
.at-empty b { font: 650 15px/1.3 var(--tl-font); color: var(--tl-ink); }
.at-empty p { font: 400 12.5px/1.45 var(--tl-font); color: var(--tl-ink-50); }
.at-lock { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 56px var(--at-g); text-align: center; }
.at-lock svg { width: 20px; height: 20px; color: var(--tl-ink-35); }
.at-lock-line { padding: 0; border: 0; background: transparent; font: 650 15px/1.35 var(--tl-font); color: var(--tl-ink); cursor: pointer; }
.at-lock-line b { font-weight: 650; color: var(--tl-pro); }
.at-lock small { font: 500 9.5px/1 var(--tl-mono); letter-spacing: 0.6px; color: var(--tl-ink-45); }
.at-lock-btn { display: inline-flex; align-items: center; justify-content: center; height: 40px; padding: 0 18px; border-radius: 10px; border: 0; background: var(--tl-ink); font: 650 14px/1 var(--tl-font); color: var(--tl-on-ink); cursor: pointer; }
.at-lock-btn:hover { background: var(--tl-ink-hover); }
.at-skel { padding: 26px var(--at-g) 0; animation: at-pulse 0.8s ease-in-out infinite alternate; }
.at-skel i { display: block; height: 12px; margin-top: 9px; border-radius: 4px; background: var(--tl-fill-07); }
.at-skel i.is-rule { height: 1px; margin-top: 0; background: var(--tl-line-06); }
.at-skel i.is-block { height: 96px; margin-top: 16px; border-radius: 12px; }
.at-skel i.is-row { height: 20px; margin-top: 24px; }
@keyframes at-pulse { from { opacity: 0.55; } to { opacity: 1; } }
@media (prefers-reduced-motion: reduce) { .at-skel { animation: none; } }

/* Recorded season numbers (server-written, for a reader with no script). */
.at-stored { padding: 14px var(--at-g); border-bottom: 1px solid var(--tl-line-06); font: 400 13px/1.55 var(--tl-font); color: var(--tl-ink-60); }
.at-stored h2 { margin-bottom: 4px; font: 650 10.5px/1.2 var(--tl-mono); letter-spacing: 0.9px; text-transform: uppercase; color: var(--tl-ink); }
.at-stored strong { color: var(--tl-ink); }

@media (max-width: 720px) {
  .at-name { font-size: 28px; }
  .at-name.is-player { font-size: 26px; }
  .at-tabs.tl-tabs { overflow-x: auto; }
}
