/* Round 279: full-screen landscape stat mode for an open player card / profile.
   Portrait and desktop are unchanged — this only paints when html.pc-stat-on is set
   (player card open + phone landscape). */
.pc-statmode{display:none}
html.pc-stat-on .pc-statmode{
  display:flex;flex-direction:column;
  position:absolute;inset:0;z-index:80;
  padding:max(6px,var(--sa-t,0px)) 10px max(6px,var(--sa-b,0px));
  background:#121212;color:#f1f5f9;
  font-family:ui-sans-serif,system-ui,-apple-system,"Segoe UI",sans-serif;
  box-sizing:border-box;
}
/* Standalone profile page: cover the viewport (no dialog containing block). */
html.pc-stat-on body.pc-page .pc-statmode{position:fixed}
html.pc-stat-on body.pc-page .pcard>:not(.pc-statmode),
html.pc-stat-on dialog.psheet[open] .pcard>:not(.pc-statmode){display:none!important}
html.pc-stat-on dialog.psheet[open]{
  width:100vw;max-width:100vw;height:100%;height:100dvh;max-height:100dvh;margin:0;border-radius:0;
  background:#121212;padding:0;inset:0;top:0;left:0;
}
html.pc-stat-on dialog.psheet[open] .ps-pg,
html.pc-stat-on dialog.psheet[open] .pcard{
  position:relative;height:100%;min-height:100%;background:transparent;border-radius:0;
}
html.pc-stat-on #bnav,html.pc-stat-on .appbar,html.pc-stat-on footer.muted,
html.pc-stat-on #hcoach-tip,html.pc-stat-on .ptr{visibility:hidden!important}

.sm-top{display:flex;align-items:center;gap:10px;flex:none;min-height:44px;padding:0 2px 6px}
.sm-shot{width:52px;height:38px;object-fit:cover;object-position:top;border-radius:6px;background:#1c1c1c;flex:none}
.sm-id{min-width:0}
.sm-id b{display:block;font-size:16px;font-weight:800;letter-spacing:-.02em;line-height:1.15;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.sm-id span{display:block;font-size:11px;color:#9aa3b0;font-weight:600}
.sm-tot{margin-left:auto;text-align:right;min-width:0}
.sm-tot b{display:block;font-size:16px;font-weight:800;font-variant-numeric:tabular-nums;line-height:1.1}
.sm-tot span{display:block;font-size:10px;color:#9aa3b0;font-weight:600;white-space:nowrap}
.sm-yr{flex:none;padding:3px 8px;border-radius:999px;font-size:11px;font-weight:800;background:#1f1f1f;color:#cbd5e1}
.sm-yr.on{background:#1f6bff;color:#fff}
.sm-seasons{display:flex;gap:4px;flex:none}

.sm-scroll{flex:1 1 auto;min-height:0;overflow:auto;overscroll-behavior:contain;touch-action:pan-x pan-y;-webkit-overflow-scrolling:touch}
.sm-table{border-collapse:separate;border-spacing:0;font-size:11px;font-variant-numeric:tabular-nums;width:max-content;min-width:100%}
.sm-table th,.sm-table td{padding:3px 6px;text-align:center;white-space:nowrap;line-height:1.2;border-right:1px solid rgba(255,255,255,.06);font-weight:650}
.sm-table thead th{position:sticky;top:0;z-index:2;background:#1a1a1a;color:#9aa3b0;font-size:9.5px;letter-spacing:.04em;text-transform:uppercase;font-weight:800}
.sm-table thead .sm-grp th{border-bottom:1px solid rgba(255,255,255,.1);padding-top:4px;padding-bottom:2px;color:#cbd5e1}
.sm-table thead .sm-labs th{border-bottom:1px solid rgba(255,255,255,.14);padding-top:2px}
.sm-table .sm-sticky{position:sticky;left:0;z-index:3;text-align:left;background:#161616;min-width:7.4em;font-weight:750;color:#e8edf4;border-right:1px solid rgba(255,255,255,.16)}
.sm-table thead .sm-sticky{z-index:4;background:#1a1a1a;text-transform:none;letter-spacing:0;font-size:11px}
.sm-wk{opacity:.6;font-weight:700;margin-right:.15em}
.sm-sticky i{display:block;font-style:normal;font-size:9px;font-weight:600;color:#9aa3b0}
.sm-table tbody tr:nth-child(even) td{filter:brightness(1.06)}
.sm-table tbody tr.sm-bye .sm-sticky,.sm-table tbody tr.sm-fut .sm-sticky,.sm-table tbody tr.sm-dnp .sm-sticky{color:#7a8490}
.sm-table tbody tr.sm-live .sm-sticky{color:#7ee2a8}

/* heatmap — higher (or inverted-lower) is greener, like the reference log */
.sm-table td[data-h=lo]{background:#5c1f1c;color:#fecaca}
.sm-table td[data-h=mid]{background:#5a3d12;color:#fde68a}
.sm-table td[data-h=hi]{background:#3b4a12;color:#e8f5a8}
.sm-table td[data-h=top]{background:#14532d;color:#bbf7d0}

.sm-chart{flex:none;padding:4px 2px 0}
.sm-chart-h{font-size:10px;font-weight:800;letter-spacing:.06em;text-transform:uppercase;color:#9aa3b0;margin-bottom:2px}
.sm-bars{display:flex;align-items:flex-end;gap:2px;height:58px}
.sm-bar{flex:1 1 0;min-width:0;height:100%;display:flex;flex-direction:column;align-items:center;justify-content:flex-end}
.sm-bar span{display:block;width:70%;max-width:14px;min-height:2px;border-radius:2px 2px 0 0;background:#4b5563}
.sm-bar em{font-style:normal;font-size:8px;font-weight:700;color:#7a8490;line-height:1.2;margin-top:1px}
.sm-bar[data-h=lo] span{background:#ef4444}
.sm-bar[data-h=mid] span{background:#f59e0b}
.sm-bar[data-h=hi] span{background:#a3e635}
.sm-bar[data-h=top] span{background:#16a34a}
.sm-bar.sm-bye span,.sm-bar.sm-empty span{background:#2a2a2a;min-height:2px;height:6%!important}
.sm-bar.sm-proj span{background:#64748b;opacity:.7}


/* Round 279b: Stats button on the portrait card + close on the overlay */
.pc-statbtn{
  display:inline-flex;align-items:center;gap:5px;margin-left:auto;
  background:rgba(255,255,255,.16);color:#fff;border:1px solid rgba(255,255,255,.28);
  border-radius:9px;padding:5px 10px;font:inherit;font-size:12px;font-weight:800;
  letter-spacing:.02em;cursor:pointer;line-height:1.2;-webkit-appearance:none;
}
.pc-statbtn svg{width:14px;height:14px;stroke:currentColor;fill:none;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.pc-x + .pc-statbtn{margin-left:8px}
@media (min-width:1100px){
  .pc-statbtn{display:none!important}
}
html[data-theme=light] .pc-statbtn{background:rgba(15,20,28,.08);color:#0f141c;border-color:rgba(15,20,28,.18)}
.sm-x{
  flex:none;width:36px;height:36px;margin-right:4px;border:0;border-radius:10px;
  background:rgba(255,255,255,.1);color:#f1f5f9;font-size:22px;font-weight:700;
  line-height:1;cursor:pointer;-webkit-appearance:none;
}
html[data-theme=light] .sm-x{background:rgba(15,20,28,.08);color:#0f141c}

/* Day */
html[data-theme=light].pc-stat-on .pc-statmode,
html[data-theme=light].pc-stat-on dialog.psheet[open]{background:#f3f5f8;color:#0f141c}
html[data-theme=light] .sm-shot{background:#e8ebf0}
html[data-theme=light] .sm-id span,html[data-theme=light] .sm-tot span,html[data-theme=light] .sm-chart-h,html[data-theme=light] .sm-bar em{color:#5c6570}
html[data-theme=light] .sm-yr{background:#e8ebf0;color:#334155}
html[data-theme=light] .sm-yr.on{background:#1c3f94;color:#fff}
html[data-theme=light] .sm-table th,html[data-theme=light] .sm-table td{border-right-color:rgba(15,20,28,.08)}
html[data-theme=light] .sm-table thead th{background:#e8ebf0;color:#5c6570}
html[data-theme=light] .sm-table thead .sm-grp th{color:#0f141c;border-bottom-color:rgba(15,20,28,.12)}
html[data-theme=light] .sm-table .sm-sticky{background:#eef1f5;color:#0f141c;border-right-color:rgba(15,20,28,.14)}
html[data-theme=light] .sm-table thead .sm-sticky{background:#e8ebf0}
html[data-theme=light] .sm-sticky i{color:#5c6570}
html[data-theme=light] .sm-table td[data-h=lo]{background:#fecaca;color:#7f1d1d}
html[data-theme=light] .sm-table td[data-h=mid]{background:#fde68a;color:#78350f}
html[data-theme=light] .sm-table td[data-h=hi]{background:#d9f99d;color:#3f6212}
html[data-theme=light] .sm-table td[data-h=top]{background:#86efac;color:#14532d}
html[data-theme=light] .sm-bar.sm-bye span,html[data-theme=light] .sm-bar.sm-empty span{background:#d5dae2}

/* Night keeps the default dark + blue year chip already used above.
   T3 year chip stays red; DP stays teal. */
html[data-skin=t3] .sm-yr.on{background:#c3181f;color:#fff}
html[data-skin=dp] .sm-yr.on{background:#3c8979;color:#fff}
html[data-skin=night] .sm-yr.on{background:#1f6bff;color:#fff}
html[data-skin=heritage] .sm-yr.on{background:#3f4f2c;color:#f3ecd8}

/* R333 (Jared t1038u): the same weekly-points chart sits on the portrait game-log
   pane, in place of the P / asterisk footnotes. Bar colors, heights, and markup
   are the shared weekly_points_chart / .sm-chart rules above. */
.pc-wkchart{padding:8px 10px 10px;border-top:1px solid var(--line,#e3e8ef)}
.pc-wkchart .sm-chart{padding:0}
