/* NBA players: /nba/players and /nba/player/:id (js/pages/nba_players.js). Builds on players.css (the college pages). */

/* ---------- /nba/players: leaders strip ---------- */
.np-leaders { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; margin: 0 0 8px; }
.np-lead { min-width: 0; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm); padding: 12px 14px 10px; }
.np-lead-k { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; font: 650 11px/1.3 var(--font-text); letter-spacing: .07em;
  text-transform: uppercase; color: var(--muted); margin-bottom: 8px; }
.np-lead-k span { flex-basis: 100%; font-weight: 500; letter-spacing: 0; text-transform: none; font-size: 11.5px; }
.np-lead ol { list-style: none; margin: 0; padding: 0; display: grid; gap: 5px; }
.np-lead li { display: flex; align-items: center; justify-content: space-between; gap: 8px; min-width: 0; font-size: 13px; }
.np-lead li a { display: flex; align-items: center; gap: 7px; min-width: 0; color: var(--text-2); text-decoration: none; }
.np-lead li a:hover .np-lead-n { color: var(--accent); text-decoration: underline; }
.np-lead li .logo { width: 18px; height: 18px; }
.np-lead-n { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.np-lead li b { font: 700 14px/1 var(--font-display); font-variant-numeric: tabular-nums; color: var(--text-2); white-space: nowrap; }
.np-lead li.np-lead-1 a { color: var(--text); font-weight: 650; }
.np-lead li.np-lead-1 b { font-size: 18px; color: var(--text); }
.np-lead-note { margin: 0 2px 18px; }

/* ---------- /nba/players: view switch ---------- */
.np-modes { display: flex; width: max-content; max-width: 100%; overflow-x: auto; margin-bottom: 6px; scrollbar-width: none; }
.np-modes::-webkit-scrollbar { display: none; }
.np-modes > button { flex: none; border: 0; background: none; font: 600 13px/1 var(--font-text); padding: 9px 14px; border-radius: 7px;
  color: var(--text-2); cursor: pointer; white-space: nowrap; }
.np-modes > button[aria-pressed="true"] { color: var(--text); background: var(--surface); }
.np-mode-note { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; margin: 0 0 12px; }
.np-stat { display: inline-block; font-size: 11.5px; font-weight: 650; padding: 2px 8px; border-radius: 999px; white-space: nowrap;
  background: var(--critical-soft); color: var(--critical); }

/* ---------- /nba/player/:id: header ---------- */
.np-idrow { display: flex; align-items: flex-end; gap: 16px; min-width: 0; }
.np-idtext { min-width: 0; }
.np-idtext h1 { overflow-wrap: anywhere; }
.np-head { flex: none; width: 120px; height: 88px; object-fit: cover; object-position: top center; border-radius: var(--radius);
  background: var(--surface-3); border: 1px solid var(--border); }
.np-head-ph { display: grid; place-items: center; width: 88px; font: 750 30px/1 var(--font-display); color: var(--muted); letter-spacing: -0.02em; }
.np-bio { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 16px 0 0; }
.np-bio > div { min-width: 0; }
.np-bio dt { font: 650 10.5px/1.3 var(--font-text); letter-spacing: .07em; text-transform: uppercase; color: var(--muted); }
.np-bio dd { margin: 2px 0 0; font-size: 14px; font-weight: 600; color: var(--text); }
.np-sub { color: var(--muted); font-weight: 500; }
.np-norate { margin: 8px 0 0; font-size: 13.5px; line-height: 1.5; color: var(--text-2); }

/* ---------- stats by season ---------- */
.np-ctl { display: flex; flex-wrap: wrap; gap: 8px; }
.np-ctl .seg { max-width: 100%; overflow-x: auto; scrollbar-width: none; }
.np-ctl .seg::-webkit-scrollbar { display: none; }
.np-ctl .seg > button { white-space: nowrap; }
.np-career-t .t-controls, #np-splits .t-controls, #np-onoff .t-controls { display: none; }
.ps-table td.np-season { white-space: nowrap; font-weight: 650; }
.ps-table tr.np-subrow td { color: var(--text-2); font-size: 13px; }
.ps-table tr.np-subrow td.np-season { font-weight: 500; padding-left: 20px; }
.np-foot { margin: 10px 0 0; }

/* ---------- rating trend ---------- */
.np-trend { min-height: 230px; }
.np-trend svg { display: block; width: 100%; height: auto; }
.np-trend-note { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 12px; margin: 8px 0 0; }
.np-key { display: inline-flex; align-items: center; gap: 5px; }
.np-key i { display: inline-block; width: 14px; height: 3px; border-radius: 2px; }

/* ---------- game log, splits ---------- */
.np-stype { font-size: 10px; font-weight: 700; color: var(--accent); border: 1px solid var(--border-strong); border-radius: 4px; padding: 1px 3px; margin-left: 4px; }
.ps-table tr.np-all td { font-weight: 650; background-color: var(--surface-2); }

@media (max-width: 1000px) {
  .np-leaders { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  /* leaders: one swipeable row instead of a tall stack */
  .np-leaders { display: grid; grid-auto-flow: column; grid-template-columns: none; grid-auto-columns: minmax(210px, 78%);
    overflow-x: auto; scroll-snap-type: x mandatory; gap: 10px; padding-bottom: 4px; }
  .np-lead { scroll-snap-align: start; }
  .np-idrow { gap: 12px; align-items: center; }
  .np-head { width: 84px; height: 62px; }
  .np-head-ph { width: 62px; font-size: 22px; }
  .np-bio { gap: 8px 16px; }
  .np-bio dd { font-size: 13.5px; }
  .np-ctl { width: 100%; }
}
@media (max-width: 640px) {
  .np-ctl .np-cmode { display: flex; width: 100%; }
  .np-ctl .np-cmode > button { flex: 1 1 0; min-width: 0; padding-left: 4px; padding-right: 4px; font-size: 12.5px; }
}
@media (max-width: 640px) {
  .np-modes { flex-wrap: wrap; width: auto; }
  .ps-table td.np-hide-sm, .ps-table th.np-hide-sm { display: none; }
}

/* ---------- on/off ---------- */
.np-oo-note { margin: 10px 0 0; }
.np-h3 { font-size: 15px; margin: 18px 0 10px; }
#np-lineups .t-controls { display: none; }
.ps-table td.np-lu { white-space: normal; min-width: 260px; line-height: 1.4; font-size: 13px; }
