/* Increased specificity for DataTables paginator button size styling */
.dataTables_wrapper .dataTables_paginate .paginate_button {
  padding: 0.25rem 0.75rem !important;
  font-size: 1.5rem !important;
}
.dataTables_wrapper .dataTables_paginate .paginate_button .bi {
  font-size: 2rem !important;
}
/* NFL Week column layout */
.nfl-week-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  min-height: auto;
  height: auto;
}

.nfl-week-number {
  text-align: center;
  font-weight: bold;
  font-size: 6vw;
  color: #007bff;
  line-height: 1;
}

.deadline-responsive {
  font-size: 1.1em;
  color: #dc3545;
  font-weight: bold;
  margin-top: 1em;
  margin-bottom: 0;
  text-align: center;
}

@media (max-width: 576px) {
  .deadline-responsive {
    margin-top: 0.2em !important;
    margin-bottom: 0 !important;
    font-size: 1em !important;
  }
}
.strike-bottom-right {
  position: absolute;
  right: 2px;
  bottom: 2px;
  font-size: 0.85em;
  color: red;
  font-weight: bold;
}
.standings-cell {
  position: relative;
  height: 32px;
  padding: 0.25rem;
}
.points-bottom-right {
  position: absolute;
  right: 2px;
  bottom: 2px;
  font-size: 0.85em;
  font-weight: bold;
}
/* Explicit outcome colors override the default when present */
.points-win { color: #198754 !important; } /* Bootstrap success green */
.points-gray { color: #ced4da !important; } /* lighter gray for past non-win, non-strike */
.points-future { color: #ced4da !important; } /* lighter gray for current/future self points */
/* Standings strike cell: the pick's power rank left of the red X, in a muted
   red about as faint as the gray points above (Bootstrap red-200) */
.strike-points { color: #f1aeb5; margin-right: 2px; }

/* Entry summary and standings footer color coding */
.entry-summary-0-strikes {
  background-color: #d4edda !important; /* Light green - same as Bootstrap success */
}
.entry-summary-1-strike {
  background-color: #fff3cd !important; /* Light yellow - same as Bootstrap warning */
}
.entry-summary-2-strikes {
  background-color: #ffe5cc !important; /* Light orange */
}
.entry-summary-3-strikes {
  background-color: #f8d7da !important; /* Light red - same as Bootstrap danger */
}

/* Winner row highlight on year-end results tables.
   Not scoped to a specific table id - the history pages use several
   different table markups (#standingsTable, #standings, and older
   pages with no id at all), so this targets the class alone. */
tr.winner-row td,
tr.winner-row th {
  background-color: #fff3cd !important; /* Light gold - same tone as site's warning/highlight palette */
}
tr.winner-row td:first-child {
  border-left: 3px solid #ffc107;
}
.winner-row .winner-trophy {
  color: #b8860b; /* Dark goldenrod - reads clearly on the light gold background */
  margin-right: 0.35rem;
}

/* The thead's background-color (#e1e1e1, below) is nearly identical to the
   page background, and both are close to Bootstrap's default table border
   color - so the grid lines between header/footer cells wash out. Darken
   just those borders; body rows keep Bootstrap's default border color. */
#standingsTable thead th,
#standingsTable tfoot td {
  border-color: #adb5bd !important;
}

/* Thick border at top of standings table footer */
#standingsTable tfoot tr:first-child td {
  border-top: 3px solid #000 !important;
}

/* Border at bottom of standings table header */
#standingsTable thead tr:last-child th {
  border-bottom: 2px solid #000 !important;
}
body {
  background-color: #e1e1e1;
}
.form-wrapper {
  border-radius: 7px;
}

.form-wrapper label {
  font-weight: bold;
}

.errors li {
  list-style: none;
  width: 100%;
  text-align: center;
}

.errors ul {
  padding-left: 0;
  margin-bottom: 0;
}

.form-control::placeholder {
  /* Chrome, Firefox, Opera, Safari 10.1+ */
  color: lightgray;
  opacity: 1;
  /* Firefox */
}
.teamlogo {
  width: 40px;
}

@media (max-width: 768px) {
  .form-wrapper .text-right {
    text-align: center !important;
  }

  .form-wrapper .btn-primary {
    display: block;
    margin: 0 auto;
  }

  /* The login screen's Login button sits in a flex row alongside the
     Forgot Username / Reset Password buttons - the block+auto-margin
     centering above fights that layout, leaving Login centered while its
     neighbors stay left-aligned. Keep it a normal flex item there instead. */
  .form-wrapper .login-actions .btn-primary {
    display: inline-block;
    margin: 0;
  }
}

.rotate-90 {
  writing-mode: vertical-rl;
  transform: rotate(-180deg);
  white-space: nowrap;
  text-align: left;
  vertical-align: bottom;
  padding: 10px 5px;
  min-height: 100px;
  /* display: inline-block; */
}

/* Fix positioning of rotated headers in standings table */
#standingsTable thead th,
#entryStatsTable thead th {
  vertical-align: bottom !important;
}

#entryStatsTable thead th {
  position: relative !important;
}

/* Sticky header: .standings-scroll wraps just the <table> (title/blurb live
   outside it in .standings-wrapper, so they stay put). Its height is set
   inline by footer.php to fill down to the bottom of the viewport; the
   max-height here is only a fallback for if that script doesn't run, and
   is kept close to 100vh so it never fights the JS-computed value (a
   tighter cap like 70vh would clip the box short and leave a gap below it). */
.standings-scroll {
  max-height: calc(100vh - 40px);
  overflow-y: auto;
  /* Firefox has a known bug where sticky descendants can paint slightly
     outside an overflow:auto container's edge; contain:paint forces it to
     strictly clip to this box's bounds. */
  contain: paint;
}

#standingsTable thead th {
  position: sticky !important;
  top: 0;
  z-index: 2;
  background-color: #e1e1e1;
  background-clip: padding-box;
}

/* Bootstrap's .table sets border-collapse:collapse, which lets a sliver of
   the scrolled-past first body row bleed through above a sticky thead
   (a known collapse+sticky rendering quirk). border-spacing:0 keeps cells
   touching visually while avoiding that gap. */
#standingsTable {
  border-collapse: separate;
  border-spacing: 0;
}

/* Live Game page's #standingsTable has longer rotated labels ("Entry
   Number", "Strike Out Week") than the history pages' version of the same
   table id ("Entry", "Points", "Strikes"), so it needs more header height.
   The .standings-scroll wrapper is unique to the history page markup (the
   Game page uses .standings-wrapper directly, no .standings-scroll), which
   gives a hook to size the two independently despite the shared table id. */
#standingsTable thead th {
  height: 120px !important;
}

/* History pages: sized to just fit the longest rotated label ("Strikes") */
.standings-scroll #standingsTable thead th {
  height: 65px !important;
}

#entryStatsTable thead th {
  height: 140px !important;
}

#standingsTable thead th .rotate-90,
#entryStatsTable thead th .rotate-90 {
  position: absolute !important;
  bottom: 4px !important;
  left: 50% !important;
  transform: translateX(-50%) rotate(-180deg) !important;
  transform-origin: center center !important;
  min-height: auto !important;
  padding: 0 !important;
}

/* Make Entry Stats table columns equally sized */
#entryStatsTable {
  table-layout: fixed !important;
}

#entryStatsTable thead th,
#entryStatsTable tbody td {
  width: 20% !important;
}

/* Scope changes to the CRUD area only */
.gc-tight { display: inline-block; max-width: 100%; }

/* Kill the full-width wrappers GCE adds, e.g. gc-wrapper-full-width-147 */
.gc-tight [class*="gc-wrapper-full-width-"],
.gc-tight [class^="gc-wrapper-"],
.gc-tight .gc-datagrid,
.gc-tight .gc-datagrid table {
  width: auto !important;
  max-width: max-content;
}

/* Table itself should size to content */
.gc-tight table {
  table-layout: auto !important;
  display: inline-table;
}

/* Excel-like tight columns (remove if you prefer wrapping) */
.gc-tight table th,
.gc-tight table td { white-space: nowrap; }

/* If BS5 grid rows/cols exist inside the grid, stop them stretching */
.gc-tight .row { width: auto !important; }
.gc-tight [class^="col"], .gc-tight [class*=" col-"] { flex: 0 0 auto !important; width: auto !important; }

/* Compact layout for standings table */
#standingsTable { font-size: 0.9rem; }
#standingsTable td,
#standingsTable th { padding: 0.15rem 0.25rem; line-height: 1.05; }
#standingsTable .standings-cell { height: 24px; padding: 0; }
#standingsTable .standings-cell img { height: 20px !important; width: auto !important; display: block; margin: 0; }
#standingsTable .points-bottom-right,
#standingsTable .strike-bottom-right { font-size: 0.75em; right: 1px; bottom: 1px; }

/* Standings width constraints for ultra-wide screens */
.standings-wrapper {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}

/* Cap the game page's logo/NFL-week/welcome/player-info/entry-stats row to
   the same width as the standings table below it, so ultra-wide screens
   don't stretch them edge-to-edge while the table stays narrower. */
#game-info,
#info-sections {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}

/* Same cap on the navbar's content (brand/links) - the dark bar itself
   still spans full width, only what's inside it is centered/constrained. */
nav.navbar > .container-fluid {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}

/* Same cap on the Ranks page's table. */
.ranks-wrapper {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}

/* Let the table size to content instead of stretching.
   display:table + width:fit-content (rather than display:inline-table)
   avoids a Firefox bug where sticky thead cells don't composite/clip
   correctly against a scrolling ancestor inside an inline-table box. */
.standings-wrapper #standingsTable {
  width: fit-content !important;
  max-width: 100% !important;
  table-layout: auto !important;
  display: table;
}

/* Cap Player Name column (2nd column) and ellipsize overflow */
#standingsTable thead th:nth-child(2),
#standingsTable tbody td:nth-child(2) {
  max-width: 260px;
  width: 260px; /* helps prevent stretch */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* Fixed, balanced widths for week columns (columns 6 through 27 for weeks 1-22) */
#standingsTable thead th:nth-child(n+6):nth-child(-n+27),
#standingsTable tbody td:nth-child(n+6):nth-child(-n+27) {
  width: 24px;
  min-width: 24px;
  max-width: 24px;
  text-align: center;
}

/* Vertically center content for columns 1–7 in body rows (before week columns) */
#standingsTable tbody td:nth-child(-n+7) {
  vertical-align: middle !important;
}

/* Center the rank column (first column) */
#standingsTable thead th:nth-child(1),
#standingsTable tbody td:nth-child(1) {
  text-align: center !important;
}

/* Fix DataTables sort icons positioning */
#ranksTable thead th {
  position: relative !important;
}

/* Hide the default DataTables sort icons completely */
#standingsTable thead th.sorting:after,
#standingsTable thead th.sorting_asc:after,
#standingsTable thead th.sorting_desc:after,
#ranksTable thead th.sorting:after,
#ranksTable thead th.sorting_asc:after,
#ranksTable thead th.sorting_desc:after,
table.dataTable thead th.sorting:after,
table.dataTable thead th.sorting_asc:after,
table.dataTable thead th.sorting_desc:after {
  display: none !important;
  content: none !important;
}

/* Also hide any background images that might be used for sorting */
#standingsTable thead th.sorting,
#standingsTable thead th.sorting_asc,
#standingsTable thead th.sorting_desc,
#ranksTable thead th.sorting,
#ranksTable thead th.sorting_asc,
#ranksTable thead th.sorting_desc,
table.dataTable thead th.sorting,
table.dataTable thead th.sorting_asc,
table.dataTable thead th.sorting_desc {
  background-image: none !important;
  padding-right: 18px !important;
}

/* Custom sort indicator for better positioning */
#standingsTable thead th.sorting:before {
  content: "↕" !important;
  position: absolute !important;
  right: 2px !important;
  bottom: 4px !important;
  font-size: 1em !important;
  color: #999 !important;
  opacity: 0.7 !important;
  z-index: 1 !important;
  line-height: 1 !important;
}

#standingsTable thead th.sorting_asc:before {
  content: "↑" !important;
  position: absolute !important;
  right: 2px !important;
  bottom: 4px !important;
  font-size: 1em !important;
  color: #333 !important;
  z-index: 1 !important;
  line-height: 1 !important;
}

#standingsTable thead th.sorting_desc:before {
  content: "↓" !important;
  position: absolute !important;
  right: 2px !important;
  bottom: 4px !important;
  font-size: 1em !important;
  color: #333 !important;
  z-index: 1 !important;
  line-height: 1 !important;
}

/* Custom sort indicators for ranksTable */
#ranksTable thead th.sorting:before {
  content: "↕" !important;
  position: absolute !important;
  right: 2px !important;
  bottom: 4px !important;
  font-size: 1em !important;
  color: #999 !important;
  opacity: 0.7 !important;
  z-index: 1 !important;
  line-height: 1 !important;
}

#ranksTable thead th.sorting_asc:before {
  content: "↑" !important;
  position: absolute !important;
  right: 2px !important;
  bottom: 4px !important;
  font-size: 1em !important;
  color: #333 !important;
  z-index: 1 !important;
  line-height: 1 !important;
}

#ranksTable thead th.sorting_desc:before {
  content: "↓" !important;
  position: absolute !important;
  right: 2px !important;
  bottom: 4px !important;
  font-size: 1em !important;
  color: #333 !important;
  z-index: 1 !important;
  line-height: 1 !important;
}

/* Also hide any background images that might be used for sorting */
#standingsTable thead th.sorting,
#standingsTable thead th.sorting_asc,
#standingsTable thead th.sorting_desc,
table.dataTable thead th.sorting,
table.dataTable thead th.sorting_asc,
table.dataTable thead th.sorting_desc {
  background-image: none !important;
  padding-right: 18px !important;
}

/* ========================================
   Game View Specific Styles (moved from embedded CSS)
   ======================================== */

/* Logo utility class */
.logo-height {
    max-height: 100px;
}

/* Sortable rank columns styling */
#scheduleTable td.fw-bold.sorted-asc::after {
    content: ' ▲';
    color: var(--bs-primary);
    font-size: 0.8em;
}

#scheduleTable td.fw-bold.sorted-desc::after {
    content: ' ▼';
    color: var(--bs-primary);
    font-size: 0.8em;
}

#scheduleTable td.fw-bold:hover {
    background-color: var(--bs-light);
}

/* Let DataTables use standard Bootstrap 5 pagination */

/* Ensure toggles are stable on iOS Safari. Lives inside the DataTables
   length/filters/search row (.dt-filters), so no margin-bottom here - that
   would just misalign it against its row siblings. */
#standingsFilters {
    display: flex !important;
    align-items: center !important;
    gap: 1rem !important;
    position: relative !important;
    z-index: 10 !important;
    min-height: 40px !important;
    justify-content: center;
    flex-wrap: wrap; /* only on narrow screens - each item stays on one line */
}
/* Keep each switch (box + label) and the Pick Stats filter chip on one line */
#standingsFilters .form-check,
#standingsFilters .form-check-label,
#pickFilterChips .pick-filter-chip {
    white-space: nowrap;
    margin-bottom: 0;
}

.form-check-input[type="checkbox"] {
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    appearance: none !important;
}

/* Ensure form switches work on iOS */
.form-switch .form-check-input {
    width: 2em !important;
    margin-left: 0 !important;
    background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='3' fill='rgba(0,0,0,0.25)'/></svg>") !important;
    background-position: left center !important;
    background-repeat: no-repeat !important;
    background-size: contain !important;
    transition: background-position 0.15s ease-in-out !important;
    border-radius: 2em !important;
    border: 1px solid var(--bs-border-color) !important;
}

.form-switch .form-check-input:checked {
    background-position: right center !important;
    background-image: url("data:image/svg+xml,<svg xmlns='http://www.w3.org/2000/svg' viewBox='-4 -4 8 8'><circle r='3' fill='rgba(255,255,255,1.0)'/></svg>") !important;
    background-color: var(--bs-primary) !important;
    border-color: var(--bs-primary) !important;
}

/* Let DataTables use standard Bootstrap 5 pagination */

/* Fix DataTables entries dropdown styling */
.dataTables_length select {
    display: inline-block !important;
    width: auto !important;
    padding: 0.375rem 2.25rem 0.375rem 0.75rem !important;
    font-size: 0.875rem !important;
    font-weight: 400 !important;
    line-height: 1.5 !important;
    color: #212529 !important;
    background-color: #fff !important;
    background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16'%3e%3cpath fill='none' stroke='%23343a40' stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='m1 6 7 7 7-7'/%3e%3c/svg%3e") !important;
    background-repeat: no-repeat !important;
    background-position: right 0.75rem center !important;
    background-size: 16px 12px !important;
    border: 1px solid #ced4da !important;
    border-radius: 0.375rem !important;
    transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out !important;
    appearance: none !important;
    -webkit-appearance: none !important;
    -moz-appearance: none !important;
    margin: 0 0.5rem !important;
}

.dataTables_length select:focus {
    border-color: #86b7fe !important;
    outline: 0 !important;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25) !important;
}

.dataTables_length select:hover {
    border-color: #b0b8c1 !important;
}

.dataTables_length label {
    font-weight: 400 !important;
    margin-bottom: 0 !important;
    display: flex !important;
    align-items: center !important;
    font-size: 0.875rem !important;
    color: #6c757d !important;
}

/* Win/Loss styling for team logos */
.team-win {
    background-color: var(--bs-success-bg-subtle) !important;
    border-radius: var(--bs-border-radius-sm) !important;
}

.team-loss {
    background-color: var(--bs-danger-bg-subtle) !important;
    border-radius: var(--bs-border-radius-sm) !important;
}

/* Fix DataTables info and length menu styling */
.dataTables_info {
    font-size: 0.875rem;
    padding-top: 0.75rem;
}

.dataTables_length select {
    font-size: 0.875rem;
    padding: 0.375rem 0.75rem;
}

/* Entry Summary table strike color customization */
.entry-summary-0-strikes {
    background-color: var(--bs-success-bg-subtle) !important;
    border-color: var(--bs-success-border-subtle) !important;
}

.entry-summary-1-strike {
    background-color: #fff3cd !important; /* Light yellow */
    border-color: #ffecb5 !important;
}

.entry-summary-2-strikes {
    background-color: #ffe0b3 !important; /* Orange */
    border-color: #ffd699 !important;
}

.entry-summary-3-strikes {
    background-color: var(--bs-danger-bg-subtle) !important;
    border-color: var(--bs-danger-border-subtle) !important;
}
/* Analytics "Player Performance" table - same look as the Game page's
   standings table (compact rows, gray header with darker grid
   lines, capped name column, capped width, logged-in player's row bold). */
.player-summary-wrapper {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}
#playerSummaryTable {
  font-size: 0.9rem;
  width: fit-content !important;
  max-width: 100% !important;
}
#playerSummaryTable td,
#playerSummaryTable th {
  padding: 0.15rem 0.25rem;
  line-height: 1.05;
  vertical-align: middle;
}
#playerSummaryTable thead th {
  background-color: #e1e1e1;
  border-color: #adb5bd !important;
}
#playerSummaryTable thead tr:last-child th {
  border-bottom: 2px solid #000 !important;
}
#playerSummaryTable thead th:first-child,
#playerSummaryTable tbody td:first-child {
  max-width: 260px;
  width: 260px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
#playerSummaryTable tbody tr.my-row td {
  font-weight: bold;
  --bs-table-bg-type: #fffacd; /* same yellow as the standings' own-entry row */
}
/* Earlier names under a player's or team's current name (analytics tables) */
.aka-names {
  white-space: normal;
  font-size: 0.75rem;
  font-weight: normal;
  color: #6c757d;
  margin-top: 0.1rem;
}
.aka-years {
  white-space: nowrap;
}
/* Player table: other names live in a Notes column at the far right */
#playerSummaryTable td.player-notes {
  font-size: 0.75rem;
  font-weight: normal;
  color: #6c757d;
  white-space: normal;
  min-width: 14rem;
}
/* Analytics "Fun Stats" cards at the top of the page */
.fun-stats-wrapper {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}
.fun-stat ol {
  padding-left: 1.25rem;
  font-size: 0.9rem;
}
.fun-stat li {
  margin-bottom: 0.3rem;
}
.fun-stat .card-title .bi {
  color: #b8860b; /* same goldenrod as the winner trophy */
}
/* Analytics "League History" tiles + table */
.league-history-wrapper {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}
.history-tile-value {
  font-size: 1.4rem;
  font-weight: 700;
  line-height: 1.2;
}
.history-tile-label {
  font-size: 0.8rem;
  font-weight: 600;
}
.history-tile-note {
  font-size: 0.7rem;
  color: #6c757d;
}
#leagueHistoryTable {
  font-size: 0.9rem;
}
.league-season-summary {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}
/* Space between a trophy icon and its text everywhere on the analytics page
   (the winner-row rule above only covers the history pages' gold rows) */
.league-history-wrapper .winner-trophy,
.league-season-summary .winner-trophy,
.fun-stats-wrapper .winner-trophy,
#playerSummaryTable .winner-trophy {
  margin-right: 0.4rem;
  color: #b8860b; /* same goldenrod as the history pages */
}
/* Ranks > Rank History */
.rank-history-wrapper {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}
#rankHistoryTable,
#rankOverallTable {
  font-size: 0.85rem;
}
#rankHistoryTable td,
#rankHistoryTable th,
#rankOverallTable td,
#rankOverallTable th {
  padding: 0.15rem 0.3rem;
}
#rankHistoryTable td.rank-cell,
#rankOverallTable td.rank-cell {
  min-width: 1.9rem;
  font-variant-numeric: tabular-nums;
}
/* Team Success When Picked: the No Pick row is always a strike */
#pickedTeamTable tr.no-pick-row td {
  --bs-table-bg-type: #f8d7da; /* same red as strike cells on the game page */
  color: #842029;
  font-weight: 600;
}
#pickedTeamTable tr.no-pick-row .bi-x-circle-fill {
  color: #dc3545;
}
/* History page: links to the same season's rank history / analytics */
.history-season-links {
  padding-top: 0.5rem;
}
.history-season-links .bi {
  margin-right: 0.25rem;
}
/* Analytics > player career page */
.player-career-wrapper,
.activity-wrapper {
  max-width: min(95vw, 1400px);
  margin-left: auto;
  margin-right: auto;
}
.player-career-wrapper .winner-trophy {
  margin-right: 0.4rem;
  color: #b8860b;
}
#careerSeasonsTable {
  font-size: 0.9rem;
}
/* Player names link to their career page without looking like loud links */
#playerSummaryTable a.player-career-link {
  color: inherit;
  text-decoration: none;
  border-bottom: 1px dotted #6c757d;
}
#playerSummaryTable a.player-career-link:hover {
  color: #0d6efd;
  border-bottom-color: #0d6efd;
}
/* Playoff round abbreviations (WC/DV/CH/SB, "Final") - hover shows the full name */
abbr.round-abbr {
  text-decoration: underline dotted;
  cursor: help;
}
/* History pages: playoff-week column headers show the round's full name on hover */
th.round-head {
  cursor: help;
  text-decoration: underline dotted;
}
/* Game page > standings footer: "No Pick Strikes" is part of the Strikes row
   above it, so its label is indented */
#standingsTable tfoot td.summary-subrow,
td.summary-subrow {
  padding-left: 1.75rem !important;
}
/* ...and the whole row is a touch smaller (about 1.5pt) */
#standingsTable tfoot tr.summary-subrow-tr td {
  font-size: 0.875em;
}
.summary-hint {
  cursor: help;
  text-decoration: underline dotted;
  text-decoration-thickness: 1px;
}
/* Game page > schedule table: final score in the middle "vs" cell, as a small
   grey pill so it doesn't read as the bold rank numbers either side of it */
.game-score {
  display: inline-block;
  padding: 0.05rem 0.45rem;
  font-size: 0.85em;
  font-weight: 400;
  color: #212529;
  background-color: #e9ecef;
  border: 1px solid #dee2e6;
  border-radius: 1rem;
  white-space: nowrap;
}
.game-score strong {
  font-weight: 700;
}
/* ...clickable: filters the standings to who picked either team that week */
.game-score.game-score-filter {
  cursor: pointer;
}
.game-score.game-score-filter:hover {
  border-color: #6ea8fe;
  background-color: #e7f1ff;
}
/* Game page > schedule table "Picked" column: the week the team was picked,
   in the same pill as the score; the text colour says how that pick went */
.pick-week-pill {
  display: inline-block;
  min-width: 1.6rem;
  padding: 0 0.4rem;
  font-weight: 600;
  line-height: 1.4;
  background-color: #e9ecef;
  border: 1px solid #dee2e6;
  border-radius: 1rem;
  text-align: center;
}
/* ...the pill of the team picked for the week being viewed: a blue border to
   match its blue (table-primary) row cells */
/* Pill background by how the pick went - the logo cells' green/red
   (Bootstrap success/danger subtle); undecided picks stay grey */
.pick-week-pill.pick-pill-win {
  background-color: #d1e7dd;
  border-color: #a3cfbb;
}
.pick-week-pill.pick-pill-loss {
  background-color: #f8d7da;
  border-color: #f1aeb5;
}
/* The pill for the week being viewed keeps its result colour, with a blue border */
.pick-week-pill.pick-week-current {
  border: 2px solid #6ea8fe;
}
/* ...and its logo cell once the game has a result: keep the green/red
   (team-win/team-loss) and ring it in the same blue */
#scheduleTable td.pick-this-week-ring {
  box-shadow: inset 0 0 0 2px #6ea8fe !important;
}
/* Game page > Pick Stats: logos are clickable - they filter the standings to
   the entries that picked that team that week; the active one is outlined */
#pick-stats .pick-filter-logo {
  cursor: pointer;
}
#pick-stats td.pick-filter-active {
  box-shadow: inset 0 0 0 3px #0d6efd;
}
/* Game page > Pick Stats: Expected Minimum Strikes - hover explains the total */
.min-strikes-total {
  cursor: help;
  text-decoration: underline dotted;
  text-decoration-thickness: 1px;
}
/* Game page > Pick Stats: the logged-in player's own picks get a small badge
   with their entry number(s) in the logo cell's top-left corner (the points
   badge sits bottom-right) */
.my-pick-badge {
  position: absolute;
  left: 1px;
  top: 1px;
  min-width: 1rem;
  padding: 0 0.2rem;
  font-size: 0.65em;
  font-weight: 700;
  line-height: 1.3;
  /* Muted blue from the same Bootstrap table palette as the win/strike cells
     (table-success #d1e7dd, table-danger #f8d7da): table-primary */
  color: #084298;
  background-color: #cfe2ff;
  border: 1px solid #9ec5fe;
  border-radius: 0.5rem;
  text-align: center;
  cursor: help;
}

/* Schedule pick buttons: a darker ring so open picks stand out */
#scheduleTable .form-check-input[type="radio"] {
  border: 2px solid #6c757d;
  cursor: pointer;
}
#scheduleTable .form-check-input[type="radio"]:hover {
  border-color: #0d6efd;
}

/* Standings colors (server-side classes; LMS set these in JS). Bootstrap 5.3
   paints striped rows with an inset shadow, so the colors use one too. */
#standingsTable td.cell-win     { box-shadow: inset 0 0 0 9999px #d4edda; }
#standingsTable td.cell-strike,
#standingsTable td.cell-unpaid  { box-shadow: inset 0 0 0 9999px #f8d7da; }
#standingsTable .wk-current     { box-shadow: inset 0 0 0 9999px #fffacd; }
#standingsTable tr.strikeout-row > td {
  box-shadow: inset 0 0 0 9999px #6c757d;
  color: #fff;
}
#standingsTable tr.strikeout-row > td.cell-strike { box-shadow: inset 0 0 0 9999px #f8d7da; color: inherit; }

/* The schedule's selected entry: the same yellow as the selected week, a
   deeper one where they cross, and a grayed-out yellow (dark enough for the
   white strike-out text) if the entry struck out. */
#standingsTable tr.entry-current:not(.strikeout-row) > td:not(.cell-win):not(.cell-strike):not(.cell-unpaid) { box-shadow: inset 0 0 0 9999px #fffacd; }
#standingsTable tr.entry-current:not(.strikeout-row) > td.wk-current { box-shadow: inset 0 0 0 9999px #ffe680; }
#standingsTable tr.strikeout-row.entry-current > td:not(.cell-strike) { box-shadow: inset 0 0 0 9999px #7a7244; }

/* 2nd Chance standings columns: Player Name, Entry, Weeks 10-SB (3-15), Out
   Week (16). LMS's rules above assume Rank first, so these reset them. */
#standingsTable.sc-grid thead th:nth-child(2),
#standingsTable.sc-grid tbody td:nth-child(2) {
  width: 2.2em;
  max-width: none;
  overflow: visible;
}
#standingsTable.sc-grid thead th:nth-child(1),
#standingsTable.sc-grid tbody td:nth-child(1) {
  width: 11rem;
  max-width: 260px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  text-align: left !important;
}
/* Week columns split whatever width is left evenly (fixed layout below).
   Clears LMS's 24px rule for its columns 6-27, which hit Weeks 13 and later. */
#standingsTable.sc-grid thead th:nth-child(n+3):nth-child(-n+15),
#standingsTable.sc-grid tbody td:nth-child(n+3):nth-child(-n+15) {
  width: auto;
  min-width: 0;
  max-width: none;
  text-align: center;
}
#standingsTable.sc-grid .standings-cell img { margin: 0 auto; }

/* Game page: the standings fill the same width as the schedule below them.
   #game-stack is as wide as its widest child (the schedule), and the table
   stretches to it. The min-width makes phones scroll instead of squashing. */
#game-stack {
  width: fit-content;
  max-width: 100%;
  margin-left: auto;
  margin-right: auto;
}
/* The standings leave their own width out of that measurement, so only the
   schedule sets it, then they fill it. */
#game-stack > #standings { contain: inline-size; }
/* Room for both toggles between Show and Search at the schedule's width:
   a narrower search box, and toggle labels the same size as Show/Search.
   Phones can still wrap. */
#standings .dataTables_filter input { width: 9rem; }
#standings #standingsFilters .form-check-label { font-size: 0.875rem; }
/* The switch already sits beside its label (margin-left: 0 above), so the
   form-switch padding that's meant to hold it only adds empty space. */
#standings #standingsFilters .form-check {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  padding-left: 0;
}
#standings #standingsFilters .form-check-input { float: none; margin-top: 0; }
@media (min-width: 768px) {
  #standings #standingsFilters { flex-wrap: nowrap; }
}

.standings-wrapper #standingsTable.sc-grid {
  width: 100% !important;
  min-width: 540px;
  table-layout: fixed !important;
}
#standingsTable.sc-grid thead th:nth-child(16),
#standingsTable.sc-grid tbody td:nth-child(16) {
  width: 2.2em;
  min-width: 0;
  max-width: none;
}

/* DataTables lays out its controls in Bootstrap rows, whose negative gutter
   margins poke past the scroll box and cause a needless horizontal scrollbar. */
.standings-wrapper .dataTables_wrapper > .row {
  margin-left: 0;
  margin-right: 0;
}
