.teams-section { background: #eee9df; }
.league-capacity { display: grid; grid-template-columns: auto 1fr; gap: 40px; align-items: center; background: var(--navy); color: white; padding: 28px; border-radius: 22px; }
.league-capacity strong { font-size: clamp(2.7rem, 6vw, 4rem); color: var(--gold); display: block; letter-spacing: -.04em; }
.league-capacity .capacity-divider { color: #b9c1c6; font-size: .65em; }
.league-capacity p { font-weight: 700; margin-bottom: 16px; }
.league-capacity small { display: block; line-height: 1.6; margin-top: 14px; color: #cdd5d8; }
.league-demo-note { margin: 20px 0 26px; padding: 14px 18px; border: 1px solid #ccb476; background: #fff6db; border-radius: 14px; color: #634823; line-height: 1.6; font-size: .85rem; }
.league-filters { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 16px; }
.league-filters label, .editor-grid label { display: flex; flex-direction: column; gap: 8px; font-size: .84rem; font-weight: 700; min-width: 0; }
.league-filters input, .league-filters select, .editor-grid input, .editor-grid select, .capacity-form input { min-height: 48px; min-width: 0; width: 100%; padding: 10px 12px; border: 1px solid #b8afa0; border-radius: 12px; background: #fffdf7; color: var(--ink); font: inherit; font-size: 16px; }
.league-result { margin: 18px 0; color: #525c60; font-size: .85rem; min-height: 20px; }
.league-table-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 18px; background: var(--cream); }
.league-table { width: 100%; border-collapse: collapse; text-align: left; font-size: .85rem; }
.league-table th { background: var(--navy); color: #fff; font-size: .76rem; padding: 17px 15px; }
.league-table td { padding: 20px 15px; vertical-align: top; border-bottom: 1px solid var(--line); }
.league-table tr:last-child td { border-bottom: 0; }
.league-table td > small { display: block; color: var(--muted); margin-top: 6px; }
.league-team { display: flex; align-items: center; gap: 12px; font-size: 1rem; margin-bottom: 12px; }
.league-team strong, .league-members li > span:first-child { overflow-wrap: anywhere; min-width: 0; }
.league-avatar { flex: 0 0 46px; width: 46px; height: 46px; display: grid; place-items: center; color: var(--gold); background: var(--navy); border-radius: 12px; overflow: hidden; }
.league-avatar svg, .league-avatar img { width: 38px; height: 38px; object-fit: contain; }
.league-members { list-style: none; padding: 0; margin: 0; }
.league-members li { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 10px; }
.league-members li > small { flex-basis: 100%; color: var(--muted); }
.status-pill, .group-pill { display: inline-block; border-radius: 9px; padding: 6px 9px; font-size: .7rem; font-weight: 700; color: #674715; background: #f7e5be; line-height: 1.4; }
.status-pill.is-active { color: #174c35; background: #d8eddf; }
.group-pill { color: #253d56; background: #e0e8f3; font-size: .9rem; }
.league-explainer { font-size: .86rem; line-height: 1.7; color: var(--muted); margin: 22px 0; }
.league-empty { padding: 32px; background: var(--cream); border-radius: 16px; }
.admin-section { background: var(--paper); border-top: 1px solid var(--line); }
.admin-section h2 { font-size: clamp(2.5rem, 5vw, 4rem); }
.admin-metrics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 26px 0; }
.admin-metrics > div { background: white; padding: 22px; border: 1px solid var(--line); border-radius: 16px; }
.admin-metrics strong { display: block; font-size: 2.2rem; margin-bottom: 8px; }
.admin-metrics span { color: var(--muted); font-size: .85rem; }
.capacity-form { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.capacity-form input { width: 95px; }
.audit-box { margin-top: 25px; padding: 20px; background: var(--cream); border-radius: 14px; font-size: .85rem; }
.audit-box summary { cursor: pointer; min-height: 28px; font-weight: 700; }
.audit-box li { margin: 12px 0; }
#team-editor { max-width: 760px; width: calc(100% - 24px); max-height: 90dvh; border: 1px solid #c8bdac; border-radius: 22px; padding: 28px; background: var(--cream); color: var(--ink); }
#team-editor::backdrop { background: #111b29aa; }
#editor-title { font-size: 1.8rem; margin-bottom: 12px; }
.editor-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.editor-help { line-height: 1.6; font-size: .85rem; color: #64605a; margin: 18px 0; }
.member-editor { margin: 24px 0; padding: 18px; border: 1px solid #d4c9b6; border-radius: 14px; min-width: 0; }
.member-editor legend { font-weight: 700; padding: 0 8px; }
.schedule-editor { margin: 18px 0; border: 0; padding: 0; min-width: 0; }
.schedule-editor legend { padding: 0; font-size: .85rem; }
.editor-check { display: flex; align-items: center; gap: 10px; min-height: 48px; font-size: .9rem; }
.editor-check input { width: 22px; height: 22px; accent-color: var(--red); }
.editor-actions { display: flex; justify-content: flex-end; flex-wrap: wrap; gap: 12px; padding-top: 15px; }
@media (max-width: 700px) {
  .site-header nav { flex-wrap: wrap; justify-content: center; }
  .league-capacity { grid-template-columns: 1fr; gap: 18px; padding: 22px; }
  .league-filters { grid-template-columns: 1fr 1fr; }
  .league-filters label:first-child { grid-column: 1/-1; }
  .league-table, .league-table tbody, .league-table tr, .league-table td { display: block; }
  .league-table thead { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }
  .league-table tr { padding: 18px; border-bottom: 2px solid var(--line); }
  .league-table tr:last-child { border-bottom: 0; }
  .league-table td { border: 0; padding: 9px 0; }
  .league-table td::before { content: attr(data-label); display: block; color: var(--muted); font-size: .7rem; font-weight: 700; margin-bottom: 6px; }
  .admin-metrics { grid-template-columns: 1fr; gap: 10px; }
  .admin-metrics > div { display: flex; gap: 18px; align-items: center; padding: 16px; }
  .admin-metrics strong { margin: 0; }
  .editor-grid { grid-template-columns: 1fr; }
  #team-editor { padding: 20px 16px; }
  .member-editor { padding: 14px; }
  .editor-actions .button { flex: 1; justify-content: center; }
}
