* { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg-main: #551155;
  --bg-sidebar: #bba0bb;
  --bg-content: #fff;
  --accent: #8b3a8b;
  --btc-roster-grid-font: 0.62rem;
}

@media (min-width: 769px) {
  :root {
    --btc-roster-grid-font: 0.68rem;
  }
}

body {
  font-family: Verdana, Geneva, sans-serif;
  background: var(--bg-main);
  color: #222;
  min-height: 100vh;
  line-height: 1.5;
  padding-bottom: 60px;
}

.wrap {
  max-width: 1000px;
  margin: 0 auto;
  padding: 12px 8px;
  min-height: 100vh;
}

.main-layout {
  display: flex;
  gap: 8px;
  align-items: flex-start;
  justify-content: center;
}

.sidebar {
  width: 210px;
  min-width: 210px;
  flex-shrink: 0;
  align-self: stretch;
  min-height: 400px;
  background: var(--bg-sidebar);
  padding: 8px;
  font-size: 12px;
}

.sidebar-right .panel {
  margin-bottom: 0;
}

.sidebar .panel {
  background: #fff;
  padding: 8px;
  margin-bottom: 12px;
  width: 190px;
}

.sidebar .panel:last-child {
  margin-bottom: 0;
}

.sidebar .panel h3 {
  margin: 0 0 6px;
  font-size: 13px;
  color: #551155;
}

.sidebar .panel h3 .conf-ncaa-bids {
  font-weight: normal;
  font-size: 11px;
  color: #666;
}

.sidebar table {
  width: 100%;
  font-size: 11px;
  border-collapse: collapse;
}

.sidebar td {
  padding: 2px 4px;
  vertical-align: top;
}

.sidebar td.num {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.sidebar tr.highlight td {
  font-weight: 700;
  background: #fff0ec;
}

.sidebar-empty {
  margin: 0;
  font-size: 12px;
  color: #888;
  font-style: italic;
}

.sidebar-min {
  font-size: 11px;
  color: #666;
  font-weight: normal;
}

.sidebar-nil-note {
  margin: 0.35rem 0 0.5rem;
  line-height: 1.45;
}

.content-col {
  flex: 0 0 560px;
  width: 560px;
  min-width: 0;
  max-width: 560px;
}

.btc-header {
  position: relative;
  text-align: center;
  background: #fff;
  padding: 16px;
  border-radius: 8px;
  margin-bottom: 12px;
  border: 2px solid #8b3a8b;
}

.jsv-title {
  font-size: 1.75rem;
  color: #551155;
  margin: 0.5rem 0 0;
}

.btc-header-logo {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 0 auto;
}

.btc-header-tagline {
  color: #555;
  font-size: 0.9rem;
  margin: 0.25rem 0 0;
}

.btc-header-build {
  color: #4a3528;
  font-size: 0.85rem;
  line-height: 1.45;
  margin: 0.65rem auto 0;
  max-width: 42rem;
  padding: 0.5rem 0.75rem;
  background: #fff8f0;
  border: 1px dashed #c9a882;
  border-radius: 6px;
}

.btc-header-build a {
  color: #a02818;
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.btc-header-build a:hover {
  color: #6b1000;
}

.btc-message-area {
  text-align: center;
  font-size: 14px;
  line-height: 1.45;
  margin: 0 0 10px;
  padding: 12px 14px;
  background: linear-gradient(180deg, #fff9f0 0%, #ffe8d4 100%);
  border: 1px solid #c9a882;
  border-radius: 8px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
  color: #3d2010;
}

.btc-message-area--empty {
  display: none;
}

.btc-message-area--error {
  background: linear-gradient(180deg, #fff0ee 0%, #ffd6d0 100%);
  border-color: #c44030;
  color: #6b1000;
}

/* Initial HTML for crawlers/ad context; removed when the app renders */
.seo-crawler-copy {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.seo-home-copy {
  background: #fff;
  padding: 4px 2px 8px;
}
.seo-home-copy h1 {
  font-size: 1.6rem;
  margin: 0 0 10px;
  color: #1a1a1a;
}
.seo-home-copy h2 {
  font-size: 1.15rem;
  margin: 16px 0 8px;
  color: #6b1000;
}
.seo-home-copy p {
  margin: 0 0 10px;
  line-height: 1.6;
  color: #333;
}

.btc-main {
  background: #fff;
  border-radius: 8px;
  padding: 16px;
  border: 1px solid #ddd;
  min-height: 400px;
}

.screen { display: none; }
.screen.active { display: block; }

.btc-nav {
  position: absolute;
  top: 10px;
  right: 10px;
  margin: 0;
  z-index: 1;
}

.btn-main-menu {
  padding: 4px 10px;
  font-size: 0.78rem;
  font-weight: 600;
  background: #f5f5f5;
  color: #666;
  border: 1px solid #ccc;
  border-radius: 4px;
  cursor: pointer;
  font-family: inherit;
}

.btn-main-menu:hover {
  background: #eee;
  color: #444;
}

.btn {
  padding: 8px 16px;
  border: none;
  border-radius: 6px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  touch-action: manipulation;
}

.btn:disabled { opacity: 0.5; cursor: not-allowed; }

.btn-primary {
  background: #c44030;
  color: #fff;
}

.btn-primary:hover:not(:disabled) { background: #a33528; }

.btn-secondary {
  background: #eee;
  color: #333;
}

.btn-secondary:hover:not(:disabled) { background: #ddd; }

.hot-seat-banner,
.vote-of-confidence-banner {
  margin: 0 0 12px;
  padding: 10px 12px;
  border-radius: 6px;
  font-size: 0.92rem;
  line-height: 1.4;
}

.hot-seat-banner {
  border: 1px solid #c9a070;
  background: linear-gradient(180deg, #fff6e8 0%, #f5e0c8 100%);
  color: #5c2e0a;
}

.hot-seat-banner--final {
  border-color: #b53a2a;
  background: linear-gradient(180deg, #fff0ee 0%, #f5d0c8 100%);
  color: #6b1000;
}

.vote-of-confidence-banner {
  border: 1px solid #7a9e6a;
  background: linear-gradient(180deg, #f4faf0 0%, #e2f0dc 100%);
  color: #2d5016;
}

.contract-line {
  margin: 0 0 4px;
  font-size: 11px;
  line-height: 1.3;
}

.contract-line--hot { color: #8a3b00; font-weight: 600; }
.contract-line--confidence { color: #2d5016; font-weight: 600; }
.contract-line--final,
.contract-line--expired { color: #b53a2a; font-weight: 700; }

.form-group { margin-bottom: 12px; }

.form-group label {
  display: block;
  font-weight: 600;
  margin-bottom: 4px;
}

.form-group select {
  width: 100%;
  padding: 8px;
  font-size: 1rem;
}

.panel {
  margin: 16px 0;
  padding: 12px;
  background: #faf8f6;
  border-radius: 6px;
  border: 1px solid #e8ddd8;
}

.panel h3 {
  color: #6b1000;
  margin-bottom: 8px;
  font-size: 1.1rem;
}

.roster-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
  gap: 8px;
}

.tryout-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr));
  grid-auto-flow: row;
}

.player-card {
  border: 2px solid #ddd;
  border-radius: 6px;
  padding: 8px;
  cursor: default;
  background: #fff;
}

.player-card.selectable { cursor: pointer; }

.player-card.selected {
  border-color: #c44030;
  background: #fff5f3;
  box-shadow: 0 0 0 2px #c44030;
}

.player-card.recruit-prospect .player-meta {
  color: #5d4037;
}

.player-name { font-weight: 700; font-size: 0.9rem; }

.player-meta { font-size: 0.8rem; color: #666; margin-top: 4px; }

.player-attrs {
  font-size: 0.72rem;
  color: #444;
  margin-top: 5px;
  line-height: 1.35;
}

.player-stats {
  font-size: 0.75rem;
  color: #6b1000;
  margin-top: 4px;
  font-weight: 600;
}

.standings-table {
  width: auto;
  max-width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  line-height: 1.15;
}

.standings-table th,
.standings-table td {
  border: 1px solid #ccc;
  padding: 1px 3px;
  text-align: left;
  white-space: nowrap;
}

.standings-table th { background: #6b1000; color: #fff; }

.standings-table tr.highlight { background: #fff0ec; }

/* Week result replay (Next Game) */
.btc-notice-modal {
  position: fixed;
  inset: 0;
  z-index: 10001;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.btc-notice-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(35, 10, 5, 0.65);
  cursor: pointer;
}

.btc-notice-modal-panel {
  position: relative;
  max-width: 420px;
  width: 100%;
  background: #fff;
  border-radius: 10px;
  border: 3px solid #c44030;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  overflow: hidden;
}

.btc-notice-modal-head {
  background: linear-gradient(180deg, #f5e6e3 0%, #ecd4cf 100%);
  border-bottom: 2px solid #c44030;
  padding: 12px 16px;
  font-weight: 700;
  font-size: 1rem;
  color: #6b1000;
}

.btc-notice-modal-body {
  padding: 16px 18px;
  font-size: 0.92rem;
  line-height: 1.45;
  color: #333;
  white-space: pre-line;
}

.btc-notice-modal-actions {
  padding: 0 18px 16px;
  text-align: right;
}

.scoreboard-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
}

.scoreboard-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(35, 10, 5, 0.65);
}

.scoreboard-panel {
  position: relative;
  width: min(420px, 100%);
  background: #fff;
  border-radius: 10px;
  border: 3px solid #c44030;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.35);
  padding: 18px 20px 16px;
}

.scoreboard-volleyball-panel {
  width: min(620px, 100%);
}

.scoreboard-set-status {
  margin: -6px 0 10px;
  min-height: 1.3em;
  text-align: center;
  color: #5d4037;
  font-size: 0.9rem;
  font-weight: 700;
}

.scoreboard-set-table-wrap {
  overflow-x: auto;
}

.scoreboard-set-table {
  width: 100%;
  border-collapse: collapse;
  table-layout: fixed;
  font-variant-numeric: tabular-nums;
}

.scoreboard-set-table th,
.scoreboard-set-table td {
  padding: 8px 6px;
  border-bottom: 1px solid #ddd;
  text-align: center;
}

.scoreboard-set-table thead th {
  color: #666;
  font-size: 0.75rem;
  text-transform: uppercase;
}

.scoreboard-set-table th:first-child {
  width: 38%;
  text-align: left;
}

.scoreboard-set-score {
  color: #999;
  font-weight: 600;
}

.scoreboard-set-score.scoreboard-set-revealed {
  color: #444;
  animation: scoreboard-set-pop 0.25s ease-out;
}

.scoreboard-set-score.scoreboard-set-winner {
  color: #2e7d32;
  font-weight: 800;
  background: #edf7ee;
}

.scoreboard-match-sets {
  font-size: 1.2rem;
  font-weight: 800;
  border-left: 2px solid #c8b7b2;
}

@keyframes scoreboard-set-pop {
  from {
    transform: scale(0.75);
    opacity: 0.35;
  }
  to {
    transform: scale(1);
    opacity: 1;
  }
}

.scoreboard-team-stats {
  margin-top: 12px;
}

.scoreboard-team-stats h3 {
  margin: 0 0 5px;
  text-align: center;
  font-size: 0.85rem;
}

.scoreboard-team-stats table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.78rem;
  font-variant-numeric: tabular-nums;
}

.scoreboard-team-stats th,
.scoreboard-team-stats td {
  padding: 4px 5px;
  border-bottom: 1px solid #eee;
  text-align: center;
}

.scoreboard-team-stats th:first-child {
  text-align: left;
}

.scoreboard-panel.scoreboard-win {
  border-color: #2e7d32;
}

.scoreboard-panel.scoreboard-loss {
  border-color: #c62828;
}

.scoreboard-meta {
  margin: 0 0 16px;
  font-size: 0.85rem;
  color: #666;
  text-align: center;
}

.scoreboard-row {
  margin-bottom: 14px;
}

.scoreboard-row:last-of-type {
  margin-bottom: 10px;
}

.scoreboard-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 4px;
  gap: 8px;
}

.scoreboard-name {
  font-weight: 700;
  font-size: 0.9rem;
  min-width: 0;
  line-height: 1.3;
}

.scoreboard-spread {
  font-weight: 700;
  color: #444;
  white-space: nowrap;
}

.scoreboard-num {
  font-size: 1.35rem;
  font-weight: 800;
  font-variant-numeric: tabular-nums;
  flex-shrink: 0;
}

.scoreboard-bar-track {
  height: 14px;
  background: #eee;
  border-radius: 7px;
  overflow: hidden;
}

.scoreboard-bar-fill {
  height: 100%;
  width: 0;
  border-radius: 7px;
  transition: width 0.18s linear;
}

.scoreboard-bar-us {
  background: linear-gradient(90deg, #c44030, #e06050);
}

.scoreboard-bar-opp {
  background: linear-gradient(90deg, #5b6770, #88929a);
}

.scoreboard-result {
  margin: 12px 0 0;
  text-align: center;
  font-weight: 700;
  font-size: 1rem;
}

.scoreboard-game-leaders {
  margin: 8px 0 0;
  text-align: center;
  font-size: 0.82rem;
  color: #444;
  line-height: 1.4;
}

.scoreboard-actions {
  margin-top: 14px;
  text-align: center;
}

.text-success { color: #2e7d32; font-weight: 600; }
.text-danger { color: #c62828; font-weight: 600; }
.gpa-ineligible { color: #a01818; font-weight: 600; }
.muted.gpa-ineligible,
p.gpa-ineligible { color: #a01818; font-weight: 600; }
.gpa-low,
td.gpa-col .gpa-low {
  color: #a01818;
  font-weight: 600;
}
.tryout-team-gpa { font-weight: 700; }
.tryout-team-gpa.gpa-ineligible { color: #a01818; }

.postseason-team-banner {
  display: flex;
  align-items: baseline;
  gap: 0.55rem;
  margin: 0.25rem 0 0.65rem;
  padding: 0.55rem 0.75rem;
  color: #fff;
  background: #6b1000;
  border-radius: 6px;
}

.postseason-team-banner span {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  opacity: 0.8;
}

.postseason-team-banner strong {
  font-size: 1.2rem;
  line-height: 1.15;
}

.postseason-outcome {
  margin: 0 0 16px;
  padding: 10px 14px;
  border-radius: 6px;
  font-size: 1.05rem;
  text-align: center;
}

.postseason-outcome--champion {
  color: #8a6d00;
  background: #fff8e6;
  border: 1px solid #c9a227;
}

.postseason-outcome--runner-up {
  color: #6b1000;
  background: #fff3f1;
  border: 1px solid #c44030;
}

.postseason-outcome--ncaa {
  color: #6b1000;
  background: #faf8f6;
  border: 1px solid #b85c38;
}

.postseason-outcome--conf {
  color: #2c5282;
  background: #f0f5fa;
  border: 1px solid #5c7a9e;
}

.postseason-outcome--default {
  color: #444;
  background: #f5f5f5;
  border: 1px solid #ccc;
}

.contract-renewal-banner {
  margin: 0 0 14px;
  padding: 10px 14px;
  border-radius: 6px;
  border: 1px solid #2f6b3a;
  background: linear-gradient(180deg, #f3faf4 0%, #e4f2e6 100%);
  color: #1e4d28;
  font-size: 1.05rem;
  line-height: 1.35;
  text-align: center;
  font-weight: 600;
}

.contract-renewal-banner--fired {
  border-color: #b53a2a;
  background: linear-gradient(180deg, #fff0ee 0%, #f5d0c8 100%);
  color: #6b1000;
}

.muted { color: #666; font-size: 0.85rem; }

.disclaimer {
  font-size: 0.75rem;
  color: #888;
  font-style: italic;
  margin-top: 12px;
}

.button-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 16px;
}

.recruit-header {
  margin-bottom: 8px;
}

.recruit-coach-line,
.recruit-team-line {
  margin: 0 0 2px;
  line-height: 1.25;
}

.recruit-team-line {
  font-size: 1.05rem;
  font-weight: 700;
}

.recruit-instructions {
  margin: 0 0 6px;
  font-size: 0.88rem;
  line-height: 1.3;
  color: #444;
}

.portal-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 4px;
}

.btn-coach-rename-ad {
  display: block;
  box-sizing: border-box;
  width: 100%;
  max-width: 100%;
  margin-top: 10px;
  padding: 8px 10px;
  font-size: 0.8rem;
  line-height: 1.3;
  white-space: normal;
  text-align: center;
  background: linear-gradient(180deg, #fff 0%, #f5ebe8 100%);
  color: #6b1000;
  border: 2px solid #c44030;
  border-radius: 6px;
  box-shadow: 0 2px 4px rgba(107, 16, 0, 0.18);
  font-weight: 700;
}

.btn-coach-rename-ad:hover:not(:disabled) {
  background: linear-gradient(180deg, #fff5f3 0%, #ecd4cf 100%);
  border-color: #a33528;
  box-shadow: 0 3px 6px rgba(107, 16, 0, 0.24);
}

.btn-coach-rename-ad:active:not(:disabled) {
  transform: translateY(1px);
  box-shadow: 0 1px 2px rgba(107, 16, 0, 0.16);
}

.btn-coach-rename-ad:disabled {
  opacity: 1;
  background: #ececec;
  border-color: #bbb;
  color: #666;
  box-shadow: none;
  cursor: not-allowed;
}

.portal-panel-head h3 {
  margin: 0;
}

.btn-nil-ad,
.btn-academic-advisor-ad {
  flex: 0 1 auto;
  font-size: 0.88rem;
  white-space: nowrap;
  padding: 8px 14px;
  background: linear-gradient(180deg, #fff 0%, #f5ebe8 100%);
  color: #6b1000;
  border: 2px solid #c44030;
  border-radius: 6px;
  box-shadow: 0 2px 4px rgba(107, 16, 0, 0.18);
  font-weight: 700;
}

.btn-nil-ad:hover:not(:disabled),
.btn-academic-advisor-ad:hover:not(:disabled) {
  background: linear-gradient(180deg, #fff5f3 0%, #ecd4cf 100%);
  border-color: #a33528;
  box-shadow: 0 3px 6px rgba(107, 16, 0, 0.24);
}

.btn-nil-ad:active:not(:disabled),
.btn-academic-advisor-ad:active:not(:disabled) {
  transform: translateY(1px);
  box-shadow: 0 1px 2px rgba(107, 16, 0, 0.16);
}

.btn-nil-ad:disabled,
.btn-academic-advisor-ad:disabled {
  opacity: 1;
  background: #ececec;
  border-color: #bbb;
  color: #666;
  box-shadow: none;
  cursor: not-allowed;
}

.tryout-action-row {
  flex-wrap: wrap;
  gap: 10px;
}

.tryout-action-row .btn-academic-advisor-ad {
  flex: 1 1 auto;
  min-width: min(100%, 220px);
  white-space: normal;
  line-height: 1.3;
  text-align: center;
}

.nil-balance {
  margin: 0 0 8px;
  font-size: 0.95rem;
}

.nil-earn-note {
  margin: 0 0 8px;
  font-size: 0.88rem;
}

.nil-badge {
  display: inline-block;
  flex: 0 0 auto;
  margin-right: 0.35rem;
  padding: 0.05rem 0.35rem;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #6b1000;
  background: #f5e6e3;
  border: 1px solid #c9a09a;
  border-radius: 3px;
  vertical-align: middle;
}

.recruit-nil-count {
  margin: 4px 0 0;
  font-size: 0.85rem;
}

.recruit-row.nil-blocked {
  opacity: 0.55;
}

.tryout-skills-breakout {
  margin: 0.35rem 0 0.65rem;
  font-variant-numeric: tabular-nums;
}

.recruit-count {
  margin: 6px 0 0;
  font-size: 0.85rem;
}

.portal-recruit-meta {
  margin-top: 6px;
}

.portal-recruit-meta .recruit-count {
  margin: 0;
}

.portal-recruit-meta .recruit-nil-count {
  margin: 2px 0 0;
}

.portal-recruit-meta .recruit-rate {
  margin: 2px 0 0;
}

.portal-recruit-actions {
  margin-top: 8px;
  margin-bottom: 0;
}

.roster-table-scroll {
  overflow-x: auto;
  max-width: 100%;
  -webkit-overflow-scrolling: touch;
}

/* Shared compact table base (rosters, schedule, sidebars, results) */
.btc-compact-table {
  width: auto;
  max-width: 100%;
  table-layout: auto;
  border-collapse: collapse;
  font-size: 0.78rem;
  line-height: 1.1;
  background: #fff;
}

.btc-compact-table th,
.btc-compact-table td {
  border: 1px solid #ccc;
  padding: 1px 2px;
  text-align: left;
  vertical-align: middle;
}

.btc-compact-table th {
  background: #f5ebe0;
  color: #6b1000;
  font-weight: 700;
  font-size: 0.72rem;
}

.btc-compact-table td.num,
.btc-compact-table th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.btc-compact-table tr.highlight td {
  font-weight: 700;
  background: #fff0ec;
}

.btc-compact-table tr.row-win td {
  background: #e8f5e9;
}

.btc-compact-table tr.row-loss td {
  background: #ffebee;
}

.btc-compact-table tr.roster-aggregate-row td {
  border-top: 2px solid var(--border, #ccc);
  background: rgba(0, 0, 0, 0.04);
  font-variant-numeric: tabular-nums;
}

.btc-compact-table tr.roster-aggregate-row td.roster-aggregate-label {
  text-align: left;
  white-space: nowrap;
}

.btc-compact-table tr.row-graduated td {
  color: #777;
  font-style: italic;
}

.btc-compact-table tr.row-graduated td.name-col {
  text-decoration: line-through;
  text-decoration-color: rgba(0, 0, 0, 0.25);
}

.attr-improved {
  font-weight: 700;
  color: #2e7d32;
}

.sidebar .btc-compact-table {
  width: 100%;
}

.sidebar-standings-table {
  width: 100%;
  table-layout: fixed;
  font-size: 0.68rem;
  line-height: 1.15;
}

.sidebar-standings-table th,
.sidebar-standings-table th.num {
  text-align: center;
}

.sidebar-standings-table th,
.sidebar-standings-table td {
  padding: 1px 2px;
}

.sidebar-standings-table th.num,
.sidebar-standings-table td.num {
  width: 4ch;
  min-width: 4ch;
  max-width: 4ch;
  padding-left: 1px;
  padding-right: 1px;
  white-space: nowrap;
  box-sizing: border-box;
}

.sidebar-standings-table td.num {
  text-align: right;
}

.sidebar-standings-table th.standings-team-col,
.sidebar-standings-table td.standings-team-col {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  width: auto;
}

.sidebar-standings-table td.standings-team-col .standings-team-stack {
  white-space: normal;
  overflow: visible;
  text-overflow: clip;
}

.standings-team-stack {
  display: block;
  line-height: 1.2;
}

.standings-team-name {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.standings-team-rating {
  display: block;
  font-size: 0.62rem;
  color: #888;
  font-weight: 600;
}

.sidebar-standings-table .conf-flag {
  margin-left: 1px;
}

.regional-bracket-table {
  width: 100%;
  table-layout: fixed;
  margin-bottom: 4px;
}

.regional-bracket-table td {
  padding: 3px 2px;
  font-size: 10px;
  line-height: 1.3;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.regional-matchup-team {
  display: block;
}

.regional-matchup-vs {
  display: block;
  font-size: 9px;
  color: #888;
  line-height: 1;
  margin: 1px 0;
}

.regional-matchup-spread {
  font-weight: 700;
  color: #6b1000;
}

.regional-matchup-result {
  margin-top: 2px;
  text-align: right;
  font-size: 10px;
  line-height: 1.2;
}

.regional-bracket .sidebar-min {
  margin-top: 6px;
  margin-bottom: 2px;
}

.regional-bracket .sidebar-min:first-child {
  margin-top: 0;
}

.schedule-table {
  width: 100%;
}

/* Season schedule: full list, no inner scroll box */
#schedule-list {
  overflow: visible;
  max-height: none;
}

#schedule-list .roster-table-scroll {
  overflow: visible;
  max-height: none;
}

.schedule-list {
  overflow: visible !important;
  max-height: none !important;
}

.schedule-table .schedule-play-col {
  width: 1.35rem;
  text-align: center;
  padding: 0.1rem 0.05rem;
}

.schedule-table .schedule-play-cb {
  width: 1rem;
  height: 1rem;
  cursor: pointer;
  vertical-align: middle;
}

.schedule-table tr.schedule-play-row:not(.row-win):not(.row-loss) {
  cursor: pointer;
}

.schedule-table tr.schedule-play-checked:not(.highlight) {
  background: rgba(93, 64, 55, 0.06);
}

.schedule-table .spread-col {
  text-align: center;
  white-space: nowrap;
  width: 2rem;
  font-variant-numeric: tabular-nums;
}

.schedule-table .spread-line {
  font-weight: 600;
  color: #5d4037;
}

.spread-cover-badge {
  margin-left: 0.15em;
  font-size: 0.95em;
  line-height: 1;
}

.scoreboard-name .spread-cover-badge {
  margin-left: 0.25em;
}

.schedule-table .result-col {
  text-align: right;
  white-space: nowrap;
}

.schedule-table tr.schedule-section-divider td {
  padding: 0.55rem 0.35rem 0.35rem;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #8b3a2a;
  background: #f3ebe4;
  border-top: 6px solid #fffaf5;
  border-bottom: 1px solid #d4b8a8;
  cursor: default;
  box-shadow: inset 0 2px 0 #c44030;
}

.conf-flag {
  margin-left: 0.2em;
  font-size: 0.85em;
  font-weight: 700;
  line-height: 1;
}

.conf-flag-regular {
  color: #b8860b;
}

.conf-flag-tourney {
  color: #1565c0;
}

.franchise-nat-champ {
  display: inline-block;
  margin-right: 0.15em;
  font-size: 1.05em;
  line-height: 1;
  vertical-align: middle;
  filter: drop-shadow(0 1px 0 rgba(0, 0, 0, 0.12));
}

.franchise-history-row--nat-champ td {
  background: linear-gradient(90deg, #fff9e6 0%, #fffdf5 100%);
}

.franchise-history-row--nat-champ td.num {
  font-weight: 700;
}

.conf-tournament-table .tag-col {
  white-space: nowrap;
}

.legacy-roster-table {
  width: auto;
  max-width: 100%;
  table-layout: auto;
  border-collapse: collapse;
  font-family: inherit;
  font-size: var(--btc-roster-grid-font);
  line-height: 1.1;
  background: #fff;
}

.btc-compact-table.legacy-roster-table {
  font-size: var(--btc-roster-grid-font);
}

.btc-compact-table.legacy-roster-table th,
.btc-compact-table.legacy-roster-table td,
.btc-compact-table.legacy-roster-table .roster-sort-btn,
.btc-compact-table.legacy-roster-table .nil-badge,
.btc-compact-table.legacy-roster-table td.name-col .name-col-text,
.btc-compact-table.legacy-roster-table .roster-sort-indicator,
.btc-compact-table.legacy-roster-table td strong {
  font-family: inherit;
  font-size: var(--btc-roster-grid-font);
}

.legacy-roster-table th,
.legacy-roster-table td {
  border: 1px solid #ccc;
  padding: 1px 2px;
  text-align: left;
  vertical-align: middle;
}

.legacy-roster-table th.src-col,
.legacy-roster-table td.src-col {
  width: 1.35rem;
  padding: 1px 1px;
  text-align: center;
  font-weight: 700;
  white-space: nowrap;
}

.legacy-roster-table td.src-col {
  color: #5d4037;
}

.legacy-roster-table th.name-col,
.legacy-roster-table td.name-col {
  width: auto;
  min-width: 0;
  max-width: none;
  padding-left: 2px;
  padding-right: 4px;
}

.legacy-roster-table td.name-col {
  display: flex;
  align-items: center;
  gap: 0;
  overflow: visible;
  white-space: nowrap;
}

.legacy-roster-table td.name-col .name-col-text {
  white-space: nowrap;
  flex: 0 0 auto;
  min-width: 0;
}

.legacy-roster-table th.class-col,
.legacy-roster-table td.class-abbr {
  width: auto;
  min-width: 2.5rem;
  max-width: 3.25rem;
  padding: 1px 2px;
  text-align: center;
  white-space: nowrap;
}

.legacy-roster-table th.attr-col,
.legacy-roster-table td.attr-col,
.legacy-roster-table th.avg-col,
.legacy-roster-table td.avg-col,
.legacy-roster-table th.gpa-col,
.legacy-roster-table td.gpa-col {
  text-align: center;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.legacy-roster-table th.attr-col,
.legacy-roster-table td.attr-col {
  width: 1.4rem;
  padding: 0 1px;
}

.legacy-roster-table th.attr-col {
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.05;
  padding-top: 2px;
  padding-bottom: 2px;
}

.legacy-roster-table th.avg-col,
.legacy-roster-table td.avg-col {
  width: 1.75rem;
  padding: 0 1px;
}

.legacy-roster-table th.gpa-col,
.legacy-roster-table td.gpa-col {
  width: 1.75rem;
  padding: 0 1px;
}

.legacy-roster-table th.stat-pg-col,
.legacy-roster-table td.stat-pg-col {
  width: 1.65rem;
  padding: 0 1px;
}

.legacy-roster-table td.avg-col strong {
  font-weight: 700;
}

.legacy-roster-table th.num,
.legacy-roster-table td.num {
  text-align: center;
  font-variant-numeric: tabular-nums;
}

.legacy-roster-table th {
  background: #f5ebe0;
  color: #6b1000;
  font-weight: 700;
}

.legacy-roster-table th.roster-sort-th {
  padding: 0;
  vertical-align: middle;
}

.legacy-roster-table .roster-sort-btn {
  display: block;
  width: 100%;
  margin: 0;
  padding: 1px 2px;
  border: none;
  background: transparent;
  font: inherit;
  font-weight: 700;
  color: inherit;
  text-align: inherit;
  cursor: pointer;
  touch-action: manipulation;
}

.legacy-roster-table th.num .roster-sort-btn {
  text-align: center;
}

/* Career stats hover (player name) */
.career-hover {
  cursor: help;
  border-bottom: 1px dotted rgba(0, 0, 0, 0.35);
}
@media (hover: none) {
  .career-hover {
    cursor: pointer;
    touch-action: manipulation;
    -webkit-tap-highlight-color: rgba(196, 64, 48, 0.15);
  }
}
.player-name .career-hover,
.name-col-text .career-hover {
  border-bottom-color: rgba(0, 0, 0, 0.45);
}

.btc-career-tooltip {
  position: fixed;
  z-index: 10050;
  max-width: min(320px, calc(100vw - 16px));
  padding: 10px 12px;
  background: #fff;
  border: 1px solid #333;
  border-radius: 6px;
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.2);
  font-size: 12px;
  line-height: 1.35;
  pointer-events: none;
  color: #222;
}
.btc-career-tooltip[hidden] {
  display: none !important;
}
.btc-career-tooltip-title {
  margin: 0 0 4px;
}
.btc-career-tooltip-meta {
  font-weight: normal;
  color: #555;
}
.btc-career-tooltip-years {
  margin: 0 0 8px;
  font-size: 11px;
  color: #555;
}
.btc-career-tooltip-muted {
  margin: 0;
  color: #666;
  font-size: 11px;
}
.btc-career-tooltip-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 11px;
}
.btc-career-tooltip-table td {
  padding: 2px 8px 2px 0;
  vertical-align: top;
}
.btc-career-tooltip-table td.num {
  text-align: right;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}

.legacy-roster-table th.name-col .roster-sort-btn {
  text-align: left;
}

.legacy-roster-table .roster-sort-btn:hover {
  background: rgba(196, 64, 48, 0.12);
}

.legacy-roster-table .roster-sort-btn:focus-visible {
  outline: 2px solid #c44030;
  outline-offset: -2px;
}

.legacy-roster-table th.roster-sort-th--active .roster-sort-btn {
  color: #a02818;
}

.legacy-roster-table .roster-sort-indicator {
  font-size: inherit;
  opacity: 0.9;
}

.legacy-roster-table td.class-abbr {
  text-align: center;
}

.legacy-roster-table .recruit-pick {
  text-align: center;
  width: 1.1rem;
  padding: 0;
}

.legacy-roster-table .recruit-pick input[type='checkbox'] {
  margin: 0;
  width: 0.75rem;
  height: 0.75rem;
  vertical-align: middle;
}

.legacy-roster-table .recruit-row {
  cursor: pointer;
  touch-action: manipulation;
}

.legacy-roster-table .recruit-row:hover {
  background: #fff8f5;
}

.legacy-roster-table .recruit-row.selected {
  background: #fff0ec;
}

.panel-roster-tables {
  margin: 6px 0;
  padding: 4px 4px;
}

.panel-roster-tables h3 {
  margin: 0 0 4px;
  font-size: 1rem;
}

.recruit-results-label {
  font-weight: 600;
  margin: 8px 0 4px;
  color: #6b1000;
}

.recruit-results-label:first-child {
  margin-top: 0;
}

.recruit-result {
  padding: 6px 8px;
  margin: 4px 0;
  border-radius: 4px;
  background: #fff;
  border: 1px solid #ddd;
}

.recruit-result.failed { opacity: 0.85; }

.recruit-rate {
  font-size: 0.9rem;
  font-weight: 600;
  margin: 4px 0 10px;
  color: #6b1000;
}

.recruit-rate.muted {
  font-weight: normal;
  color: #666;
}

.program-picker {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  margin: 16px 0;
}

.picker-pane {
  display: flex;
  flex-direction: column;
  min-height: 0;
  background: #faf8f6;
  border: 1px solid #e8ddd8;
  border-radius: 6px;
  overflow: hidden;
}

.picker-pane h3 {
  margin: 0;
  padding: 6px 10px;
  font-size: 0.85rem;
  color: #6b1000;
  background: #fff;
  border-bottom: 1px solid #e8ddd8;
}

.picker-list {
  list-style: none;
  flex: 1;
  margin: 0;
  padding: 2px 4px;
  overflow-y: visible;
}

.picker-item {
  padding: 1px 6px;
  margin: 0;
  border-radius: 2px;
  cursor: pointer;
  font-size: 0.7rem;
  line-height: 1.1;
  touch-action: manipulation;
}

.picker-item:hover { background: #fff0ec; }

.picker-item:focus {
  outline: 2px solid #c44030;
  outline-offset: -2px;
}

.picker-item.selected {
  background: #c44030;
  color: #fff;
  font-weight: 600;
}

.picker-item.selected:hover { background: #a33528; }

.picker-empty {
  padding: 2px 6px;
  cursor: default;
  font-size: 0.7rem;
  line-height: 1.1;
}

.footer {
  text-align: center;
  font-size: 12px;
  padding: 16px 0 8px;
  color: rgba(255, 255, 255, 0.75);
}
.footer a {
  color: rgba(255, 255, 255, 0.9);
}
.footer a:hover {
  color: #fff;
}

/* Gatekeeper/Ezoic persistent CMP gear — footer link replaces it */
#ez-privacy-settings-button {
  position: fixed !important;
  left: -9999px !important;
  width: 1px !important;
  height: 1px !important;
  opacity: 0 !important;
  overflow: hidden !important;
  pointer-events: none !important;
  z-index: -1 !important;
}

@media (max-width: 820px) {
  .content-col {
    flex: 1;
    width: auto;
    max-width: none;
  }
}

/* --- Mobile / small screens (pattern from baseballcenturyconvert) --- */
@media (max-width: 768px) {
  body {
    padding-bottom: 90px;
  }

  html {
    font-size: 17px;
  }

  .roster-table--mobile-compact .legacy-roster-table th.attr-col,
  .roster-table--mobile-compact .legacy-roster-table td.attr-col {
    display: none;
  }

  .roster-table--mobile-hide-career .legacy-roster-table th.stat-pg-col,
  .roster-table--mobile-hide-career .legacy-roster-table td.stat-pg-col {
    display: none;
  }

  .wrap {
    padding: 12px 8px;
  }

  .main-layout {
    flex-direction: column;
    gap: 12px;
  }

  .sidebar {
    width: 100%;
    min-width: 0;
    min-height: 0;
    order: 2;
    font-size: 13px;
  }

  .sidebar-right {
    order: 3;
    margin-top: -4px;
  }

  .sidebar .panel {
    width: 100%;
    max-width: 100%;
  }

  .sidebar .panel h3 {
    font-size: 14px;
  }

  .sidebar table,
  .sidebar .btc-compact-table {
    font-size: 12px;
  }

  .content-col {
    order: 1;
    max-width: 100%;
  }

  .btc-header {
    padding: 12px 10px 14px;
  }

  .btc-header-tagline {
    font-size: 0.88rem;
    padding-right: 4.5rem;
  }

  .btc-header-build {
    font-size: 0.82rem;
    margin-top: 0.5rem;
  }

  .btc-nav {
    top: 8px;
    right: 8px;
  }

  .btn-main-menu {
    min-height: 44px;
    padding: 8px 12px;
    font-size: 0.82rem;
  }

  .btc-main {
    padding: 12px;
  }

  .btc-message-area {
    font-size: 15px;
    padding: 10px 12px;
  }

  .panel {
    padding: 10px;
  }

  .panel h3 {
    font-size: 1rem;
  }

  .btn {
    padding: 10px 18px;
    min-height: 44px;
    font-size: 15px;
  }

  .button-row {
    gap: 10px;
  }

  .button-row .btn {
    flex: 1 1 auto;
    min-width: min(100%, 140px);
  }

  .form-group select {
    min-height: 44px;
    font-size: 16px;
  }

  .program-picker {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .picker-item {
    font-size: 0.82rem;
    line-height: 1.25;
    padding: 8px 8px;
    min-height: 36px;
  }

  .picker-pane h3 {
    font-size: 0.9rem;
    padding: 8px 10px;
  }

  .roster-grid {
    grid-template-columns: 1fr 1fr;
  }

  .tryout-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .btc-compact-table {
    font-size: 0.74rem;
    width: 100%;
    table-layout: auto;
  }

  .legacy-roster-table {
    font-size: var(--btc-roster-grid-font);
    width: 100%;
    table-layout: auto;
  }

  .btc-compact-table th,
  .btc-compact-table td,
  .legacy-roster-table th,
  .legacy-roster-table td {
    padding: 0 1px;
  }

  .legacy-roster-table th.name-col,
  .legacy-roster-table td.name-col {
    width: 1%;
    max-width: 5.75rem;
    min-width: 0;
    padding-left: 1px;
    padding-right: 1px;
  }

  .legacy-roster-table td.name-col {
    display: table-cell;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .legacy-roster-table td.name-col .name-col-text {
    overflow: hidden;
    text-overflow: ellipsis;
    display: inline;
    vertical-align: middle;
    max-width: 100%;
  }

  .legacy-roster-table td.name-col .nil-badge {
    vertical-align: middle;
  }

  .legacy-roster-table th.class-col,
  .legacy-roster-table td.class-abbr {
    min-width: 1.75rem;
    max-width: 2.35rem;
    width: 2.35rem;
    padding: 0 1px;
  }

  .legacy-roster-table th.attr-col,
  .legacy-roster-table td.attr-col {
    width: 1.25rem;
  }

  .legacy-roster-table th.avg-col,
  .legacy-roster-table td.avg-col,
  .legacy-roster-table th.gpa-col,
  .legacy-roster-table td.gpa-col,
  .legacy-roster-table th.stat-pg-col,
  .legacy-roster-table td.stat-pg-col {
    width: 1.5rem;
  }

  .legacy-roster-table .recruit-pick {
    width: 1rem;
  }

  .legacy-roster-table .recruit-pick input[type='checkbox'] {
    width: 0.7rem;
    height: 0.7rem;
  }

  .standings-table {
    font-size: 11px;
    width: 100%;
    table-layout: fixed;
  }

  .standings-table th,
  .standings-table td {
    padding: 0 2px;
  }

  .sidebar-standings-table th.num,
  .sidebar-standings-table td.num {
    width: 4ch;
    min-width: 4ch;
    max-width: 4ch;
  }

  .sidebar-standings-table th.standings-team-col,
  .sidebar-standings-table td.standings-team-col {
    width: auto;
    max-width: none;
    padding-left: 1px;
    padding-right: 1px;
    font-size: 0.62rem;
  }

  .schedule-table .schedule-play-col {
    width: 1.15rem;
  }

  .schedule-table .spread-col {
    width: 1.75rem;
  }

  .panel-roster-tables {
    padding: 2px 2px;
    margin: 4px 0;
  }

  .roster-table-scroll,
  .standings-table {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin-left: -4px;
    margin-right: -4px;
    padding-left: 4px;
    padding-right: 4px;
  }

  #schedule-list .roster-table-scroll {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
  }

  .schedule-table .schedule-play-col input[type='checkbox'] {
    width: 1.15rem;
    height: 1.15rem;
  }

  .scoreboard-modal {
    padding: 10px;
    align-items: center;
  }

  .scoreboard-panel {
    width: 100%;
    max-width: 100%;
    padding: 14px 14px 12px;
    border-radius: 10px;
  }

  .scoreboard-meta {
    font-size: 0.8rem;
    line-height: 1.35;
  }

  .scoreboard-name {
    font-size: 0.85rem;
  }

  .scoreboard-num {
    font-size: 1.25rem;
  }

  .scoreboard-actions .btn {
    width: 100%;
    max-width: 280px;
  }

  .footer {
    padding: 12px 0;
    font-size: 12px;
  }
}

@media (max-width: 480px) {
  html {
    font-size: 16px;
  }

  .wrap {
    padding: 8px 6px;
  }

  .btc-header-tagline {
    padding-right: 0;
    margin-top: 2.75rem;
  }

  .btc-nav {
    top: 6px;
    right: 6px;
    left: 6px;
    display: flex;
    justify-content: flex-end;
  }

  .btc-main {
    padding: 10px;
  }

  .picker-item {
    font-size: 0.78rem;
    padding: 7px 6px;
  }

  .btc-compact-table,
  .standings-table {
    font-size: 10px;
  }

  .legacy-roster-table {
    font-size: var(--btc-roster-grid-font);
  }

  .btc-compact-table th,
  .btc-compact-table td,
  .legacy-roster-table th,
  .legacy-roster-table td,
  .standings-table th,
  .standings-table td {
    padding: 0 1px;
  }

  .legacy-roster-table th.name-col,
  .legacy-roster-table td.name-col {
    max-width: 5rem;
  }

  .legacy-roster-table th.class-col,
  .legacy-roster-table td.class-abbr {
    min-width: 1.6rem;
    max-width: 2.15rem;
    width: 2.15rem;
  }

  .sidebar-standings-table th.standings-team-col,
  .sidebar-standings-table td.standings-team-col {
    width: auto;
    max-width: none;
    font-size: 0.58rem;
  }

  .sidebar-standings-table th.num,
  .sidebar-standings-table td.num {
    width: 4ch;
    min-width: 4ch;
    max-width: 4ch;
  }

  .scoreboard-modal {
    padding: 10px;
  }

  .scoreboard-panel {
    border-radius: 12px;
    padding: 12px;
  }

  .scoreboard-meta {
    font-size: 0.75rem;
  }
}
