/* The free projection pages (/projections/rest-of-season, /projections/daily: drawn by the Worker, billing
   src/publicPages.ts), on pk.css: the H1 and its line, the top 10's table, then the next 10 blurred and fading (owner,
   19 Nov 2026: "you can kinda make out the next 10"; the numbers are the real ones, only blurred) under the call to
   connect a league. The table reads like a stats product (owner, 18 Nov 2026: "make the table look better"): the rank first, each
   player's face (pk.css .pf, the homepage's), name, team chip and position or game, then the nine categories only;
   numbers right-aligned in tabular figures; hairline rows with a quiet zebra; a column's three best of the 10 bold on a
   soft tint (bold too, never the colour alone). On a phone the table scrolls
   sideways inside its own frame, the rank and the player held at the left; on a wide screen it needs no scroll, so its
   head stays under the top bar as you read down. Colours from tokens.css only, so dark mode follows. No script. */
.pj-hero { padding-bottom: 16px; }
.pj-hero h1 { margin-top: 12px; font-size: clamp(34px, 4.2vw, 54px); line-height: 1.06; letter-spacing: -.025em; max-width: 22ch; }
.pj-hero .answer { margin-top: 12px; }
.pj-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 0 24px; margin-top: 8px; font-size: 15px; color: var(--dim); }
.pj-meta > span { display: block; padding: 4px 0; }
.pj-meta b { color: var(--text); font-weight: 650; }
.pj-meta a { display: inline-flex; align-items: center; min-height: 44px; margin-left: .3em; }
@media (min-width: 980px) { .pj-hero { padding: 16px 0 24px; } }

.pj-table { padding: 0 0 calc(var(--space) * .75); }
.pj-h { font: 650 15px/1.3 var(--font-body); color: var(--dim); margin-bottom: 8px; }
.pj-none { padding: 20px; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-box); color: var(--dim); max-width: 64ch; }

/* The table: its own sideways scroll, Pikola rank and the player held at the left */
.pj-scroll { --rank-w: 44px; position: relative; overflow-x: auto; overscroll-behavior-x: contain; background: var(--surface); border: 1px solid var(--line); border-radius: var(--r-box); }
.pj-scroll:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }
.pj { --zebra: color-mix(in srgb, var(--surface-2) 40%, var(--surface)); width: 100%; border-collapse: separate; border-spacing: 0; font-size: 15px; font-variant-numeric: tabular-nums; }
.pj th, .pj td { padding: 10px 12px; text-align: right; white-space: nowrap; border-bottom: 1px solid var(--line); background: var(--surface); }
.pj tbody tr:nth-child(even) > * { background: var(--zebra); }
.pj tbody tr:last-child > * { border-bottom: 0; }
.pj thead th { z-index: 2; background: var(--surface-2); font: 650 13px/1.2 var(--font-body); color: var(--dim); vertical-align: bottom; border-bottom-color: var(--line-strong); }
.pj abbr[title] { text-decoration: none; }
/* The first two columns, held: Pikola rank, then the player */
.pj .pj-rank { position: sticky; left: 0; z-index: 1; width: var(--rank-w); min-width: var(--rank-w); max-width: var(--rank-w); padding-right: 4px; text-align: center; white-space: normal; }
.pj thead .pj-rank { z-index: 3; }
.pj td.pj-rank b { font: 800 18px/1 var(--font-display); color: var(--text); letter-spacing: .02em; }
.pj tbody th, .pj thead .pj-player { position: sticky; left: var(--rank-w); z-index: 1; text-align: left; box-shadow: inset -1px 0 0 var(--line); min-width: 150px; max-width: 48vw; white-space: normal; }
.pj thead .pj-player { z-index: 3; }
.pj tbody th { font-weight: 400; }
.pj-who { display: flex; align-items: center; gap: 8px; min-width: 0; }
.pj-who .pf { --s: 28px; }
.pj-who > span:last-child { display: grid; gap: 2px; min-width: 0; }
.pj-who b { font-weight: 650; color: var(--text); line-height: 1.25; }
.pj-sub { display: flex; flex-wrap: wrap; align-items: center; gap: 2px 6px; font-size: 13px; color: var(--dim); line-height: 1.3; white-space: nowrap; }
/* A column's three best of the 10: bold on a soft tint (the bold says it without the colour) */
.pj td.hi { background: var(--go-tint); color: var(--go-text); }
.pj tbody tr:nth-child(even) > td.hi { background: var(--go-tint); }
.pj td.hi b { font-weight: 750; }
@media (max-width: 719px) { .pj th, .pj td { padding: 10px 8px; } .pj-scroll { --rank-w: 44px; } }
@media (min-width: 720px) { .pj tbody th, .pj thead .pj-player { min-width: 220px; } .pj-scroll { --rank-w: 64px; } .pj-who .pf { --s: 36px; } }
/* Wide enough for the whole table: no sideways scroll, so the head can stay under the top bar */
@media (min-width: 1180px) {
  .pj-scroll { overflow: clip; }
  .pj thead th { position: sticky; top: var(--bar-h); }
  .pj thead .pj-rank, .pj thead .pj-player { left: auto; }
  .pj tbody .pj-rank, .pj tbody th { position: static; }
}

/* After the 10: the next 10, blurred and fading row by row, so they read as more of the table and can't be read (a
   name kept to one line, so each row is --lock-row tall); the zebra carries on from the 10 (each body counts its own
   rows: ten is even). Over them, the call to connect a league: a card in the middle of the blurred rows that lets a
   swipe through to the table's own sideways scroll. */
.pj-lock { --lock-row: 60px; position: relative; }
.pj .pj-locked tr { height: var(--lock-row); opacity: calc(.8 - var(--i) * .065); }
.pj .pj-locked tr > * { filter: blur(3.5px); user-select: none; border-bottom: 1px solid var(--line); }
.pj tbody:not(.pj-locked) tr:last-child > * { border-bottom: 1px solid var(--line); }
.pj-locked .pj-who b, .pj-locked .pj-sub { white-space: nowrap; flex-wrap: nowrap; overflow: hidden; }
.pj-unlock { position: absolute; left: 0; right: 0; bottom: 0; height: calc(var(--lock-row) * 10); display: grid; place-items: center; padding: 16px; pointer-events: none; }
.pj-unlock-card { pointer-events: auto; display: grid; justify-items: center; gap: 10px; max-width: 460px; padding: 24px 24px 20px; text-align: center; background: var(--surface); border: 1px solid var(--line-strong); border-radius: var(--r-box); box-shadow: var(--shadow-pop); }
.pj-gate-h { font-family: var(--font-brand); font-weight: 800; font-variation-settings: 'opsz' 144, 'SOFT' 100, 'WONK' 1; font-size: clamp(22px, 2.4vw, 28px); line-height: 1.15; letter-spacing: -.02em; max-width: 20ch; text-wrap: balance; }
.pj-unlock-card p { color: var(--dim); max-width: 46ch; text-wrap: pretty; }
.pj-unlock-card .btn { margin-top: 4px; }
.pj-unlock-card .pj-free { font-size: 14px; font-weight: 650; color: var(--text); }

.pj-notes .prose b { color: var(--text); }
