/* nfl.css — the shared read-only NFL dashboard.
 *
 * Colour and type come from tokens.css and nothing is redeclared here. This
 * page is served on its own hostname but it is the same system, and the one
 * rule that file asks for is that no other stylesheet own a colour.
 */

* { box-sizing: border-box; }

/* THE hidden ATTRIBUTE MUST WIN. `.gate` and `.boot` below both set
   `display: flex`, and any explicit display rule outranks the user-agent
   stylesheet's `[hidden] { display: none }`. Without this line the page
   renders the PIN card and the "loading…" placeholder stacked ABOVE the
   dashboard after a successful login — which is exactly what it did the first
   time it was opened in a browser. */
[hidden] { display: none !important; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.mono { font-family: var(--mono); }

.label {
  font-size: 10.5px;
  letter-spacing: .14em;
  color: var(--faint);
  text-transform: uppercase;
  margin-bottom: 10px;
}

.kicker {
  font-size: 10px;
  letter-spacing: .22em;
  color: var(--acc);
  text-transform: uppercase;
}

/* ── boot / gate ──────────────────────────────────────────────────────── */

.boot {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--faint);
  font-size: 12px;
  letter-spacing: .12em;
}

.gate {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.gate-card {
  width: 100%;
  max-width: 340px;
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 14px;
  padding: 32px 28px;
  text-align: center;
}

.gate-title {
  font-size: 26px;
  font-weight: 600;
  margin: 10px 0 4px;
  letter-spacing: -.01em;
  color: var(--bright);
}

.gate-sub {
  margin: 0 0 22px;
  color: var(--muted);
  font-size: 13.5px;
}

#pinForm { display: flex; flex-direction: column; gap: 12px; }

.pin-input {
  width: 100%;
  padding: 14px 12px;
  text-align: center;
  font-size: 26px;
  letter-spacing: .5em;
  text-indent: .5em; /* centres text that carries trailing letter-spacing */
  background: var(--panel-deep);
  border: 1px solid var(--line-3);
  border-radius: 10px;
  color: var(--bright);
}

.pin-input:focus {
  outline: none;
  border-color: var(--acc);
}

.pin-go {
  padding: 12px;
  font-size: 11.5px;
  letter-spacing: .16em;
  border-radius: 10px;
  border: 1px solid var(--line-3);
  background: var(--panel-2);
  color: var(--text);
  cursor: pointer;
}

.pin-go:hover { border-color: var(--acc); color: var(--bright); }
.pin-go[disabled] { opacity: .5; cursor: default; }

.pin-err {
  margin: 16px 0 0;
  font-size: 12px;
  color: var(--bad);
}

/* ── shell ────────────────────────────────────────────────────────────── */

#dash {
  max-width: 980px;
  margin: 0 auto;
  padding: 32px 20px 64px;
}

.head {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 20px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--line);
}

.title {
  font-size: 27px;
  font-weight: 600;
  letter-spacing: -.01em;
  margin: 6px 0 0;
  color: var(--bright);
}

.asof { text-align: right; flex: none; }
.asof .label { margin-bottom: 4px; }
.asof-val { font-size: 12.5px; color: var(--text-2); }
.asof-age { font-size: 11.5px; margin-top: 2px; color: var(--ok); }
.asof-age.warn { color: var(--warn); }
.asof-age.bad { color: var(--bad); }

/* ── status band ──────────────────────────────────────────────────────── */

/* The band carries the model's own sentence about this week — the most
   important text on the page. It earns that by TYPE and surface, not by a
   coloured stripe down one edge: the only left-accent in this project
   (styles.css .palette-item) is a selection state that is transparent until a
   row is chosen, so a permanent one here would be decoration imitating
   meaning. */
.band {
  margin: 22px 0 30px;
  padding: 18px 20px;
  background: var(--panel-deep);
  border: 1px solid var(--line-2);
  border-radius: 10px;
}

.status {
  font-size: 17px;
  line-height: 1.4;
  color: var(--bright);
}

.suppressed {
  margin-top: 8px;
  font-size: 13px;
  color: var(--warn);
}

.thresholds {
  margin-top: 10px;
  font-size: 11.5px;
  color: var(--faint);
}

.block { margin-bottom: 34px; }

.soft { color: var(--faint); font-weight: 400; }

/* ── the way through to the current week ──────────────────────────────── */

.cta {
  display: flex;
  align-items: center;
  gap: 18px;
  margin: 22px 0 34px;
  padding: 20px 22px;
  background: var(--panel);
  border: 1px solid var(--line-3);
  border-radius: 12px;
  text-decoration: none;
  color: inherit;
}

.cta:hover { border-color: var(--acc); background: var(--panel-2); }
.cta:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }

.cta-main { flex: 1; min-width: 0; }
.cta .label { margin-bottom: 6px; }

.cta-week {
  font-size: 22px;
  font-weight: 600;
  color: var(--bright);
  letter-spacing: -.01em;
}

.cta-status { margin-top: 4px; font-size: 13.5px; color: var(--muted); }

.cta-arrow { font-size: 20px; color: var(--acc); flex: none; }

/* ── profit / loss ────────────────────────────────────────────────────── */

.pl {
  display: flex;
  align-items: baseline;
  gap: 20px;
  flex-wrap: wrap;
  padding: 20px 22px;
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 12px;
}

.pl-val {
  font-family: var(--mono);
  font-size: 42px;
  line-height: 1.05;
  letter-spacing: -.02em;
  color: var(--muted);
}

/* Green and red are load-bearing here, so they are not the ONLY signal — the
   number always carries an explicit + or − as well, for anyone who cannot
   separate the two hues. */
.pl-val.up { color: var(--ok); }
.pl-val.down { color: var(--bad); }
.pl-val.flat { color: var(--text-2); }

.pl-side { flex: 1; min-width: 160px; }
.pl-roi { font-size: 14px; color: var(--text-2); }
.pl-sub { margin-top: 3px; font-size: 11.5px; color: var(--faint); }

.pl-assumed {
  margin-top: 10px;
  font-size: 11.5px;
  color: var(--warn);
}

.wk-pl span.up { color: var(--ok); }
.wk-pl span.down { color: var(--bad); }
.wk-pl span.flat { color: var(--text-2); }
.week-sum .up { color: var(--ok); }
.week-sum .down { color: var(--bad); }

/* ── my bets ──────────────────────────────────────────────────────────── */

.pl-mine { background: var(--panel-deep); }

.mine-list { margin-top: 10px; display: grid; gap: 6px; }

.mine-row {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 11px 16px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 9px;
}

.mine-main { flex: 1; min-width: 0; }
.mine-head b { color: var(--acc); font-size: 14.5px; }
.mine-terms { font-size: 12.5px; color: var(--text-2); }
.mine-game { margin-top: 2px; font-size: 12px; color: var(--muted); }
.mine-right { display: flex; align-items: center; gap: 8px; flex: none; }
.mine-units { font-size: 12.5px; color: var(--text-2); }

/* A bet the model did not agree with. Neutral, not alarming — it is allowed,
   it just must not be mistaken for a model pick. */
.tag-solo { color: var(--mg-text); border-color: var(--line-3); }

.book-link { color: var(--acc); text-decoration: none; border-bottom: 1px solid var(--line-3); }
.book-link:hover { border-bottom-color: var(--acc); }

/* ── season totals ────────────────────────────────────────────────────── */

.totals { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

.total-card {
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 12px;
  padding: 18px;
}

.total-head {
  font-size: 10px;
  letter-spacing: .13em;
  color: var(--faint);
  text-transform: uppercase;
}

.total-val {
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 30px;
  color: var(--bright);
  letter-spacing: -.01em;
}

.total-sub { margin-top: 4px; font-size: 12.5px; color: var(--text-2); }

.total-note {
  margin-top: 12px;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  font-size: 12px;
  color: var(--warn);
}

/* The all-games caveat is permanent context, not a warning — it must not
   compete with the readable-rule note next to it. */
.soft-note { color: var(--faint); }

/* ── week list ────────────────────────────────────────────────────────── */

.week-list { display: grid; gap: 8px; }

.wk {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 14px 18px;
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 10px;
  text-decoration: none;
  color: inherit;
}

.wk:hover { border-color: var(--line-3); background: var(--panel-2); }
.wk:focus-visible { outline: 2px solid var(--acc); outline-offset: 2px; }

.wk-head { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 10px; flex-wrap: wrap; }
.wk-name { font-size: 16px; font-weight: 600; color: var(--text); }
.wk-games { font-size: 11.5px; color: var(--faint); }

.wk-live {
  font-size: 9.5px;
  letter-spacing: .12em;
  color: var(--acc);
  border: 1px solid var(--line-3);
  border-radius: 999px;
  padding: 2px 8px;
}

.wk-recs { display: flex; gap: 22px; flex: none; }

.wk-rec b {
  display: block;
  font-weight: 500;
  font-size: 9.5px;
  letter-spacing: .12em;
  color: var(--faint);
  margin-bottom: 3px;
}

.wk-rec span { font-size: 15px; color: var(--text-2); }
.wk-rec i { font-style: normal; font-size: 11px; color: var(--faint); margin-left: 6px; }
.wk-rec.is-bets span { color: var(--bright); }

.wk-arrow { color: var(--faint); flex: none; }
.wk:hover .wk-arrow { color: var(--acc); }

/* Needs real space beneath it: the next thing is a section label in the same
   micro type, and at 6px the two read as one stacked pair rather than as a way
   out followed by content. */
.back {
  display: inline-block;
  margin: 20px 0 26px;
  font-size: 11px;
  letter-spacing: .12em;
  color: var(--muted);
  text-decoration: none;
}

.back:hover { color: var(--acc); }

/* ── result tags ──────────────────────────────────────────────────────── */

.tag {
  display: inline-block;
  margin-left: 8px;
  padding: 1px 7px;
  border-radius: 999px;
  font-size: 9.5px;
  letter-spacing: .1em;
  border: 1px solid transparent;
}

.res-w { color: var(--ok); border-color: var(--ok-wash); background: var(--ok-wash); }
.res-l { color: var(--bad); border-color: var(--warn-edge); }
.res-p { color: var(--muted); border-color: var(--line-3); }
.res-pending { color: var(--faint); border-color: var(--line-2); }

.side-team { font-size: 12.5px; color: var(--text-2); }
.side-team.acc { color: var(--acc); font-weight: 600; }
.slate td.side, .slate td.bet { white-space: nowrap; }
.dim { color: var(--faint); }

.week-sum {
  margin-top: 12px;
  font-size: 12.5px;
  color: var(--text-2);
}

.pick-right { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }

/* ── picks ────────────────────────────────────────────────────────────── */

.picks { display: grid; gap: 12px; }

.pick-card {
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 12px;
  padding: 16px 18px;
}

.pick-top {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 14px;
  flex-wrap: wrap;
}

.pick-team {
  font-size: 20px;
  font-weight: 600;
  color: var(--acc);
  letter-spacing: -.01em;
}

.pick-game { font-size: 13px; color: var(--muted); }

.pick-edge {
  font-family: var(--mono);
  font-size: 13px;
  color: var(--text-2);
}

.pick-meta {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  font-family: var(--mono);
  font-size: 12px;
  color: var(--dim);
}

.pick-meta b {
  display: block;
  font-weight: 500;
  font-size: 10px;
  letter-spacing: .12em;
  color: var(--faint);
  margin-bottom: 3px;
}

.pick-meta span { color: var(--text-2); }

.pick-signal {
  margin-top: 10px;
  font-family: var(--mono);
  font-size: 11px;
  color: var(--faint);
  word-break: break-word;
}

.empty {
  padding: 18px;
  border: 1px dashed var(--line-3);
  border-radius: 10px;
  color: var(--muted);
  font-size: 13.5px;
}

/* .picks has no surface of its own, so an empty state there needs its own box.
   .record IS a panel already — a dashed box inside it renders as a card within
   a card, which is what week 1 (no graded picks yet) actually looked like on
   the live site. Inside a panel the empty state is just its text. */
.record .empty {
  border: none;
  padding: 0;
}

/* ── record ───────────────────────────────────────────────────────────── */

.record {
  background: var(--panel);
  border: 1px solid var(--line-2);
  border-radius: 12px;
  padding: 18px;
}

.rec-row { display: flex; flex-wrap: wrap; gap: 26px; }

.rec-cell b {
  display: block;
  font-family: var(--mono);
  font-weight: 500;
  font-size: 10px;
  letter-spacing: .12em;
  color: var(--faint);
  margin-bottom: 4px;
}

.rec-cell span {
  font-family: var(--mono);
  font-size: 21px;
  color: var(--bright);
}

/* The not-yet-readable notice. Deliberately the loudest thing in the block
   when it shows: the percentage next to it is NOT a verdict yet, and the page
   must say so louder than it shows the number. */
.rec-note {
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--line);
  font-size: 12.5px;
  color: var(--warn);
}

.rec-pct-soft { color: var(--muted) !important; font-size: 15px !important; }

/* ── slate table ──────────────────────────────────────────────────────── */

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line-2);
  border-radius: 12px;
  background: var(--panel);
}

.slate {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  min-width: 620px;
}

.slate th {
  text-align: left;
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: .13em;
  color: var(--faint);
  padding: 12px 14px;
  border-bottom: 1px solid var(--line-2);
  white-space: nowrap;
}

.slate td {
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  color: var(--text-2);
  white-space: nowrap;
}

.slate tr:last-child td { border-bottom: none; }
.slate .num { text-align: right; font-family: var(--mono); }
.slate td.sig { white-space: normal; font-family: var(--mono); font-size: 11px; color: var(--faint); }
.slate tr.is-pick td { background: var(--ok-wash); }
.slate tr.is-pick .matchup { color: var(--acc); font-weight: 600; }
.slate .pos { color: var(--ok); }
.slate .neg { color: var(--bad); }

/* ── the slate legend ─────────────────────────────────────────────────── */

.legend {
  margin: 12px 2px 0;
  font-size: 12px;
  line-height: 1.6;
  color: var(--faint);
  max-width: 78ch;
}

.legend b { color: var(--text-2); font-weight: 500; }
.legend .mono { color: var(--text-2); }
/* The colour key reuses the table's own classes, so the swatches can never
   drift from the cells they describe. */
.legend .gap-lo { color: var(--bad); }
.legend .gap-mid { color: var(--cam-text); }
.legend .gap-hi { color: var(--ok); font-weight: 600; }

.slate th .soft {
  display: inline;
  margin-left: 4px;
  font-size: 9px;
  letter-spacing: .06em;
  text-transform: none;
  color: var(--dim);
}

/* GAP scale: how close the model's disagreement is to being bettable.
   ≤3 red, 3–5 blue, ≥5 green. Blue is the workspace accent from tokens.css
   rather than a new colour — it is the one hue in the ramp that reads as
   "notable, not yet actionable" without colliding with ok/warn/bad. */
.slate td.gap-lo { color: var(--bad); }
.slate td.gap-mid { color: var(--cam-text); }
.slate td.gap-hi { color: var(--ok); font-weight: 600; }

.slate td.line { color: var(--text-2); white-space: nowrap; }
.slate td.score { color: var(--bright); white-space: nowrap; }
.slate td.push { color: var(--muted); }
/* The results table has no forecast columns, so it can breathe more. */
.slate-played { min-width: 560px; }
.slate-played td.num { font-size: 13.5px; }
.slate .matchup .away { color: var(--muted); }
.slate .matchup .home { color: var(--text); font-weight: 600; }
.slate tr.is-pick .matchup .away { color: var(--acc); opacity: .75; }
.slate tr.is-pick .matchup .home { color: var(--acc); }

/* ── model.md ─────────────────────────────────────────────────────────── */

/* A reading column, not a dashboard column. The rest of this page is scannable
   data at 980px; prose at that measure is genuinely harder to read, so the
   document narrows to something closer to 70 characters. */
.doc { max-width: 74ch; }

.doc-lede {
  margin: 0 0 34px;
  font-size: 17px;
  line-height: 1.55;
  color: var(--text);
}

.doc h2 {
  margin: 40px 0 14px;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--acc);
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
}

.doc p {
  margin: 0 0 14px;
  font-size: 14.5px;
  line-height: 1.65;
  color: var(--text-2);
}

.doc b { color: var(--bright); font-weight: 600; }
.doc em { color: var(--text); font-style: italic; }

.doc code,
.doc .mono {
  font-family: var(--mono);
  font-size: .92em;
  color: var(--text);
}

.doc-code {
  margin: 0 0 16px;
  padding: 14px 16px;
  background: var(--panel-deep);
  border: 1px solid var(--line-2);
  border-radius: 8px;
  font-size: 12.5px;
  line-height: 1.6;
  color: var(--text-2);
  overflow-x: auto;
  white-space: pre;
}

.doc-table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 18px;
  font-size: 13px;
}

.doc-table th {
  text-align: left;
  font-family: var(--mono);
  font-size: 9.5px;
  font-weight: 500;
  letter-spacing: .12em;
  text-transform: uppercase;
  color: var(--faint);
  padding: 9px 12px;
  border-bottom: 1px solid var(--line-2);
}

.doc-table td {
  padding: 9px 12px;
  border-bottom: 1px solid var(--line);
  color: var(--text-2);
  vertical-align: top;
}

.doc-table tr:last-child td { border-bottom: none; }
.doc-table .num { text-align: right; font-family: var(--mono); white-space: nowrap; }
.doc-table .pos { color: var(--ok); }
.doc-table .neg { color: var(--bad); }
.doc-table .soft { font-size: .9em; }

/* Something the reader should not skim past — a stated limitation or a refusal
   to tune. Warm, not alarming: these are the model being honest, not errors. */
.doc-flag {
  padding: 14px 16px;
  background: var(--panel);
  border: 1px solid var(--warn-edge);
  border-radius: 8px;
  color: var(--text-2) !important;
}

.doc-note {
  font-size: 12.5px !important;
  color: var(--faint) !important;
}

.doc-list {
  margin: 0 0 14px;
  padding-left: 20px;
  font-size: 14.5px;
  line-height: 1.65;
  color: var(--text-2);
}

.doc-list li { margin-bottom: 9px; }

/* The model card sits below the week list, so it needs air above it and should
   not shout as loudly as the current-week link at the top of the page. */
.cta-doc { margin: 30px 0 0; background: var(--panel-deep); }

/* ── footer ───────────────────────────────────────────────────────────── */

.foot {
  margin-top: 40px;
  padding-top: 20px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12.5px;
}

.foot p { margin: 0 0 8px; }
.dimline { font-size: 11px; color: var(--faint); letter-spacing: .04em; }

@media (max-width: 620px) {
  #dash { padding: 24px 14px 48px; }
  .head { flex-direction: column; gap: 14px; }
  .asof { text-align: left; }
  .title { font-size: 23px; }

  /* Two record cards side by side stop being readable well before this width. */
  .totals { grid-template-columns: 1fr; }

  /* The week row's records need the full width once stacked, and the arrow
     stops earning its place. */
  .wk { flex-wrap: wrap; gap: 12px; }
  .wk-recs { width: 100%; justify-content: space-between; gap: 12px; }
  .wk-arrow { display: none; }
}
