/* Win Probability Added — Data register: dense, ink-headed, heat-scaled.
   Tokens from phl-tokens.css. */

.wpa-lede {
    font-family: Georgia, 'Times New Roman', serif;
    font-size: 1rem; line-height: 1.6; color: var(--phl-text);
    max-width: 68ch; margin: 0 0 20px;
}

.wpa-grid {
    display: grid; gap: 16px; align-items: start;
    grid-template-columns: minmax(0, 1fr) 340px;
}

.wpa-card {
    background: var(--phl-card); border: 1px solid var(--phl-line);
    border-radius: 10px; padding: 16px 18px;
    box-shadow: 0 1px 3px rgba(23, 34, 46, .08);
}
.wpa-cardhead {
    display: flex; align-items: baseline; justify-content: space-between;
    gap: 12px; margin-bottom: 10px;
}
.wpa-cardhead h2 {
    font-family: 'Barlow Condensed', 'Arial Narrow', sans-serif;
    font-size: 1.5rem; font-weight: 700; margin: 0;
}
.wpa-note {
    font-size: .6875rem; text-transform: uppercase; letter-spacing: .06em;
    color: var(--phl-faint);
}

.wpa-tablewrap { overflow-x: auto; }
.wpa-table {
    width: 100%; border-collapse: collapse; font-size: .78125rem;
}
.wpa-table thead th {
    position: sticky; top: 0; z-index: 2;
    background: var(--phl-ink); color: #fff;
    font-size: .6875rem; font-weight: 600;
    text-transform: uppercase; letter-spacing: .06em;
    text-align: left; padding: 6px 8px; white-space: nowrap;
    border-bottom: 2px solid var(--phl-orange);
}
.wpa-table th.num, .wpa-table td.num {
    text-align: right; font-variant-numeric: tabular-nums;
}
.wpa-table td {
    padding: 5px 8px; border-bottom: 1px solid var(--phl-line-soft);
    white-space: nowrap;
}
.wpa-table tbody tr:hover { background: var(--phl-line-soft); }
.wpa-table td.rk { color: var(--phl-faint); width: 2.5rem; }
.wpa-table td.pl { width: 100%; }
.wpa-table td.dim { color: var(--phl-muted); }
.wpa-table td.strong { font-weight: 700; }
.wpa-table td.pos { color: var(--phl-win); }
.wpa-table td.neg { color: var(--phl-loss); }

/* Diverging heat: steel below, orange above — the brand scale */
.wpa-table td.h-hi2 { background: var(--phl-heat-hi-2); }
.wpa-table td.h-hi1 { background: var(--phl-heat-hi-1); }
.wpa-table td.h-lo1 { background: var(--phl-heat-lo-1); }
.wpa-table td.h-lo2 { background: var(--phl-heat-lo-2); }

.wpa-pos {
    display: inline-block; min-width: 28px; text-align: center;
    font-size: .625rem; font-weight: 700; color: #fff;
    border-radius: 4px; padding: 1px 4px; margin-right: 5px;
    letter-spacing: .04em;
}
.wpa-pos.p1 { background: var(--pos-qb, #A83240); }
.wpa-pos.p2 { background: var(--pos-rb, #2E7D4F); }
.wpa-pos.p3 { background: var(--pos-wr, #4682B4); }
.wpa-pos.p4 { background: var(--pos-te, #7A4FA0); }
.wpa-pos.p5 { background: var(--pos-k, #5B6673); }
.wpa-pos.p6 { background: var(--pos-dst, #6B4F3A); }

/* Biggest weeks */
.wpa-weeks { list-style: none; margin: 0; padding: 0; counter-reset: wk; }
.wpa-weeks li { counter-increment: wk; }
.wpa-week {
    display: block; padding: 7px 8px 7px 26px; position: relative;
    border-bottom: 1px solid var(--phl-line-soft);
    text-decoration: none; color: var(--phl-text);
}
.wpa-week::before {
    content: counter(wk); position: absolute; left: 6px; top: 8px;
    font-size: .625rem; font-weight: 700; color: var(--phl-faint);
    font-variant-numeric: tabular-nums;
}
.wpa-week:hover { background: var(--phl-surface); }
.wpa-wtop { display: flex; align-items: baseline; gap: 6px; }
.wpa-wname {
    font-weight: 600; flex: 1 1 auto; min-width: 0;
    overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.wpa-wval { font-variant-numeric: tabular-nums; font-weight: 700; white-space: nowrap; }
.wpa-wval.pos { color: var(--phl-win); }
.wpa-wval.neg { color: var(--phl-loss); }
.wpa-wsub {
    display: block; font-size: .6875rem; color: var(--phl-muted); margin-top: 1px;
}

@media (max-width: 980px) {
    .wpa-grid { grid-template-columns: minmax(0, 1fr); }
}

/* ---- Matchup leaderboards ---- */

.ml-tabs { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 14px; }
.ml-tab {
    padding: 5px 12px; border-radius: 999px; text-decoration: none;
    font-size: .78125rem; font-weight: 600; color: var(--phl-muted);
    background: var(--phl-card); border: 1px solid var(--phl-line);
}
.ml-tab:hover { border-color: var(--phl-orange); color: var(--phl-text); }
.ml-tab.on { background: var(--phl-orange); border-color: var(--phl-orange); color: #fff; }

.ml-table td.nw, .ml-table th.nw { white-space: nowrap; }
.ml-row { cursor: pointer; }
.ml-win { font-weight: 700; }
.ml-lose { color: var(--phl-faint); }
.ml-round {
    display: inline-block; margin-left: 4px; padding: 0 5px;
    border-radius: 4px; background: var(--phl-gold-soft); color: var(--phl-warn);
    font-size: .625rem; font-weight: 700; text-transform: uppercase;
    letter-spacing: .04em;
}
/* The column the table is currently ranked on */
.wpa-table th.hot { background: var(--phl-ink-2); color: #fff; }
.wpa-table td.hot { background: var(--phl-heat-hi-1); font-weight: 700; color: var(--phl-text); }
.ml-legend { margin-top: 10px; text-transform: none; letter-spacing: 0; line-height: 1.5; }
