/* Matching controls and table treatment for both publishing formats and competitions. */
body.stats-layout {
  --stats-header:#142f37;
  --stats-stripe:#f3f8f4;
  --stats-hover:#e7f1eb;
  --stats-emphasis:#edf6f0;
  --stats-control-hover:#eaf3ed;
}
body.stats-layout.girls {
  --stats-header:#292640;
  --stats-stripe:#f4f1fa;
  --stats-hover:#e9e2f4;
  --stats-emphasis:#eee8f8;
  --stats-control-hover:#eee9f5;
}
body.stats-layout .leaders-heading-controls {
  display:flex; align-items:flex-start; gap:12px 16px; flex-wrap:wrap; min-width:0;
}
body.stats-layout .stats-title-group { min-width:0; }
body.stats-layout .stats-title-group h2 { margin:0; }
body.stats-layout .stats-title-group .stats-asof {
  margin:5px 0 0; font-size:11px; line-height:1.45; font-weight:400;
  letter-spacing:0; color:var(--muted); text-transform:none;
}
body.stats-layout .leaders-season-label {
  display:flex; align-items:center; gap:8px; margin:0; padding-top:2px;
  font-size:12px; color:var(--muted); white-space:nowrap;
}
body.stats-layout .leaders-season-label select { font-size:14px; }
body.stats-layout .pagination {
  display:flex; align-items:center; justify-content:flex-start; flex-wrap:wrap;
  gap:10px; margin:20px 0; padding:0; border:0;
  overflow:visible; white-space:normal; font-size:15px;
}
body.stats-layout .pagination[hidden] { display:none!important; }
body.stats-layout .pagination button, body.stats-layout .pagination select {
  padding:9px 14px; border:1px solid var(--line); border-radius:6px;
  background:var(--white); color:var(--ink); font:inherit;
}
body.stats-layout .pagination button { min-width:90px; white-space:nowrap; }
body.stats-layout .pagination button:not(:disabled):hover {
  background:var(--stats-control-hover); color:var(--ink);
}
body.stats-layout .pagination button:disabled { opacity:.45; cursor:default; }
body.stats-layout .pagination .page-status { font-size:12px; color:var(--muted); }
body.stats-layout .table-wrap {
  border:1px solid var(--line); border-radius:9px; background:var(--white); overflow:visible;
}
body.stats-layout .table-wrap table {
  width:100%; border-collapse:separate; border-spacing:0; table-layout:fixed;
  font-variant-numeric:tabular-nums;
}
body.stats-layout .table-wrap table thead th {
  background:var(--stats-header); color:#fff; border-color:var(--stats-header);
  position:sticky; top:0; z-index:10; text-transform:uppercase;
  font-size:10px; letter-spacing:0; white-space:nowrap; overflow-wrap:normal;
}
body.stats-layout .table-wrap table thead th:first-child { border-top-left-radius:8px; }
body.stats-layout .table-wrap table thead th:last-child { border-top-right-radius:8px; }
body.stats-layout .table-wrap table thead th button {
  color:inherit; border:0; background:transparent; white-space:nowrap;
  font-size:inherit; text-transform:inherit; border-radius:4px;
}
body.stats-layout .table-wrap table thead th button:is(:hover,:focus-visible),
body.stats-layout .table-wrap table thead th[aria-sort="ascending"] button,
body.stats-layout .table-wrap table thead th[aria-sort="descending"] button {
  background:var(--mint); color:var(--stats-header);
}
body.stats-layout .table-wrap table tbody td { border-top:1px solid var(--line); color:var(--ink); }
body.stats-layout .table-wrap table tbody tr:nth-child(odd) { background:var(--white); }
body.stats-layout .table-wrap table tbody tr:nth-child(even) { background:var(--stats-stripe); }
body.stats-layout .table-wrap table tbody tr:hover { background:var(--stats-hover); }
body.stats-layout .table-wrap table tbody td { background:transparent!important; }
body.stats-layout .table-wrap table tbody td:last-child { color:var(--ink); font-weight:400; }
body.stats-layout .table-wrap table tbody td a { color:var(--green); }
body.stats-layout .stats-sources { background:var(--white); border-color:var(--line); }
body.stats-layout .stats-sources p, body.stats-layout .stats-sources li { font-size:11px; line-height:1.5; }
body.stats-layout .stats-sources p { margin:0 0 8px; }
body.stats-layout .stats-sources ol { margin:0; padding-left:24px; list-style:disc outside; }
@media(max-width:720px) {
  body.stats-layout .leaders-heading-controls { gap:8px; flex-wrap:nowrap; width:100%; }
  body.stats-layout .stats-title-group { flex:1 1 0; min-width:0; }
  body.stats-layout .stats-title-group h2 { font-size:18px; line-height:30px; white-space:nowrap; letter-spacing:-.35px; }
  body.stats-layout .leaders-season-label { flex:0 0 82px; width:82px; padding-top:0; }
  body.stats-layout .leaders-season-label select { width:82px; min-width:0; height:30px; padding:5px 4px; font-size:11px; }
  body.stats-layout .stats-season-caption { position:absolute; width:1px; height:1px; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; }
  body.stats-layout .pagination { gap:8px; }
  body.stats-layout .pagination .page-status { width:100%; }
}
/* Column positions include one hidden SP cell for compatible HTML data readers. */
body.stats-layout .goalie-table :is(th,td):nth-child(7) { display:none!important; }
body.stats-layout .goalie-table :is(th,td):is(:nth-child(4),:nth-child(5),:nth-child(6),:nth-child(9),:nth-child(10),:nth-child(11)) { text-align:left; }
body.stats-layout .goalie-table :is(th,td):is(:nth-child(8),:nth-child(12),:nth-child(13)) { text-align:center; }
@media(min-width:721px) {
  body.stats-layout .goalie-table th:nth-child(6) { width:8%; }
}
@media print {
  body.stats-layout .pagination { display:none; }
  body.stats-layout .table-wrap table thead th { position:static; }
}

/* Follow aria-sort: only the active sort column receives the solid tint. */
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(1):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(1) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(2):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(2) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(3):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(3) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(4):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(4) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(5):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(5) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(6):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(6) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(7):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(7) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(8):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(8) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(9):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(9) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(10):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(10) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(11):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(11) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(12):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(12) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(13):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(13) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
body.stats-layout .table-wrap table:has(> thead > tr > th:nth-child(14):is([aria-sort="ascending"],[aria-sort="descending"])) > tbody > tr > td:nth-child(14) { background:var(--stats-emphasis)!important; color:var(--green); font-weight:700; }
/* Use the goaltending row metrics for scoring tables, including archived tables. */
body.stats-layout .table-wrap table:not(.goalie-table) tbody td{padding-top:12px;padding-bottom:12px;font-size:12px;line-height:1.5;vertical-align:middle}
body.stats-layout .table-wrap table:not(.goalie-table) .team-logo-box{width:20px;height:20px;flex-basis:20px}
@media(max-width:720px){body.stats-layout .table-wrap table:not(.goalie-table) tbody td{padding-top:10px;padding-bottom:10px;font-size:12px;line-height:1.5}body.stats-layout .table-wrap table:not(.goalie-table) .team-logo-box{width:14px;height:14px;flex-basis:14px}}

@media(max-width:720px){
 body.stats-layout .goalie-table :is(th,td):last-child{text-align:center!important}
 body.stats-layout .goalie-table th:last-child button{margin-inline:auto}
}
