:root {
    --blue: #3a3a7b;
    --blue-deep: #29295d;
    --blue-soft: #eeeef7;
    --blue-accent: #0070c0;
    --orange: #f26522;
    --orange-light: #f58634;
    --ink: #20213a;
    --muted: #5c6071;
    --surface: #fff;
    --page: #f5f6f8;
    --line: #dce0e8;
    --success: #236149;
    --danger: #a32f31;
    --radius: 12px;
    --space: 4px;
    --focus: #0070c0;
    font-family: Nunito, system-ui, sans-serif;
    color: var(--ink);
    background: var(--page);
    font-synthesis: none;
    scrollbar-color: #a4a9bd var(--page)
}

* {
    box-sizing: border-box
}

body {
    margin: 0;
    font-size: 1rem;
    line-height: 1.5
}

::selection {
    background: #d9e7ff;
    color: var(--blue-deep)
}

a {
    color: var(--blue);
    text-underline-offset: .2em
}

button,
input,
select,
textarea {
    font: inherit
}

button,
a,
input,
select,
summary {
    touch-action: manipulation
}

button {
    cursor: pointer
}

a,
button,
input,
select,
summary {
    outline-offset: 4px
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
    outline: 3px solid var(--focus)
}

input,
select {
    caret-color: var(--blue)
}

[hidden] {
    display: none !important
}

.container {
    width: min(1160px, calc(100% - 64px));
    margin-inline: auto
}

main.container {
    min-height: 65vh;
    padding-top: 40px;
    padding-bottom: 72px
}

h1,
h2,
h3,
p {
    margin-top: 0
}

h1 {
    font-size: clamp(2rem, 4vw, 3.5rem);
    line-height: 1.1;
    letter-spacing: -.03em;
    font-weight: 900;
    margin-bottom: 16px;
    text-wrap: balance
}

h2 {
    font-size: 1.5rem;
    line-height: 1.25;
    font-weight: 900;
    letter-spacing: -.02em;
    margin-bottom: 8px
}

h3 {
    font-size: 1.125rem;
    font-weight: 800;
    line-height: 1.35
}

p {
    color: var(--muted)
}

.muted,
.helper {
    color: var(--muted)
}

.helper {
    font-size: .875rem;
    line-height: 1.5;
    margin: 8px 0 0
}

.text-link {
    font-weight: 800
}

.skip-link {
    position: absolute;
    top: -100px;
    left: 16px;
    background: white;
    padding: 12px;
    z-index: 10
}

.skip-link:focus {
    top: 8px
}

.site-header {
    background: var(--blue);
    border-bottom: 4px solid var(--orange);
    color: white
}

.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    min-height: 112px
}

.brand {
    display: flex;
    align-items: center;
    background: white;
    padding: 8px 16px;
    border-radius: 4px
}

.brand img {
    width: 230px;
    height: 64px;
    object-fit: contain;
    display: block
}

.event-wordmark {
    color: white;
    text-decoration: none;
    font-size: 1.125rem;
    font-weight: 900;
    letter-spacing: .04em
}

.event-wordmark strong {
    color: #ffb47e;
    margin-left: 8px
}

.session-bar {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: .875rem
}

.session-bar form {
    margin: 0
}

.header-button {
    background: transparent;
    border: 1px solid #c7c7e3;
    color: white;
    min-height: 44px;
    padding: 8px 16px;
    border-radius: 8px
}

.header-button:hover {
    background: #ffffff14
}

.site-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 24px;
    padding-block: 28px;
    border-top: 1px solid var(--line);
    font-size: .875rem;
    color: var(--muted)
}

.site-footer strong,
.site-footer span {
    display: block
}

.site-footer strong {
    color: var(--blue);
    margin-bottom: 4px
}

.site-footer a {
    color: var(--muted)
}

.page-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 32px;
    padding: 8px 0 36px
}

.page-heading p {
    margin-bottom: 0;
    max-width: 58ch;
    font-size: 1.0625rem
}

.page-heading.compact h1 {
    font-size: clamp(1.75rem, 3vw, 2.5rem)
}

.page-heading.compact {
    padding-top: 16px;
    padding-bottom: 28px
}

.edition-mark {
    display: flex;
    align-items: center;
    gap: 12px;
    white-space: nowrap;
    color: var(--blue);
    font-size: .875rem
}

.edition-mark svg {
    color: var(--orange)
}

.edition-mark strong {
    font-size: 1.5rem;
    line-height: 1.1
}

.division-tabs {
    display: flex;
    gap: 4px;
    border-bottom: 1px solid var(--line)
}

.division-tabs a {
    min-height: 52px;
    padding: 14px 24px;
    text-align: center;
    color: var(--muted);
    text-decoration: none;
    font-weight: 900;
    border-bottom: 3px solid transparent;
    margin-bottom: -1px
}

.division-tabs a:hover {
    color: var(--blue);
    background: var(--blue-soft)
}

.division-tabs a.active {
    color: var(--blue);
    border-bottom-color: var(--orange)
}

.sport-nav {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    padding: 24px 0
}

.sport-nav a {
    display: flex;
    gap: 6px;
    align-items: center;
    padding: 10px 14px;
    min-height: 44px;
    font-weight: 800;
    font-size: .9375rem;
    text-decoration: none;
    color: var(--muted);
    border: 1px solid var(--line);
    border-radius: 8px;
    background: white
}

.sport-nav a:hover {
    border-color: var(--blue);
    color: var(--blue)
}

.sport-nav a.active {
    background: var(--blue);
    color: white;
    border-color: var(--blue)
}

.sport-nav a span {
    font-size: .8125rem;
    font-weight: 600;
    opacity: .9
}

.view-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 16px;
    border-bottom: 1px solid var(--line);
    margin-bottom: 20px
}

.view-nav {
    display: flex;
    gap: 24px
}

.view-nav a {
    font-weight: 800;
    text-decoration: none;
    color: var(--muted);
    padding: 12px 0;
    min-height: 48px;
    white-space: nowrap;
    border-bottom: 3px solid transparent
}

.view-nav a.active {
    color: var(--blue);
    border-bottom-color: var(--blue)
}

.refresh-status {
    font-size: .8125rem;
    color: var(--muted);
    padding-bottom: 16px;
    text-align: right
}

.refresh-error {
    color: var(--danger)
}

.filter-bar {
    display: flex;
    align-items: end;
    gap: 16px;
    flex-wrap: wrap;
    margin-bottom: 32px;
    padding-top: 4px
}

.filter-bar label {
    max-width: 360px
}

.filter-bar select {
    min-width: 190px
}

.filter-bar input {
    max-width: 200px
}

.filter-bar .text-link {
    padding: 10px 0;
    font-size: .875rem
}

.section-heading {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
    margin: 24px 0 16px
}

.section-heading h2 {
    margin-bottom: 4px
}

.section-heading p {
    margin: 0;
    font-size: .875rem
}

.section-heading .text-link {
    font-size: .875rem;
    white-space: nowrap
}

.spaced {
    margin-top: 44px
}

.game-list {
    border: 1px solid var(--line);
    background: var(--surface);
    border-radius: var(--radius);
    overflow: hidden
}

.game-row {
    display: grid;
    grid-template-columns: 112px 1fr 180px;
    column-gap: 24px;
    row-gap: 12px;
    padding: 24px;
    border-bottom: 1px solid var(--line);
    align-items: center
}

.game-row:last-child {
    border-bottom: 0
}

.game-when {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    font-variant-numeric: tabular-nums
}

.game-when .date {
    font-size: .875rem;
    color: var(--muted);
    font-weight: 700
}

.game-when>strong {
    font-size: 1.5rem;
    font-weight: 900;
    color: var(--blue);
    line-height: 1.25
}

.tag {
    display: inline-flex;
    width: fit-content;
    align-items: center;
    font-size: .75rem;
    line-height: 1.5;
    border-radius: 4px;
    padding: 2px 6px;
    background: var(--blue-soft);
    color: var(--blue);
    font-weight: 800;
    margin-top: 6px
}

.tag.done {
    background: #e4f1eb;
    color: var(--success)
}

.tag.wo {
    background: #f9e8df;
    color: #8a3913
}

.tag.champion {
    font-size: .875rem;
    background: #fbe7d4;
    color: #76330a
}

.game-meta {
    font-size: .875rem;
    color: var(--muted);
    margin-bottom: 8px
}

.game-meta span {
    margin: 0 3px
}

.matchup {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    font-size: 1.125rem;
    font-weight: 800
}

.matchup .winner {
    color: var(--blue)
}

.versus {
    font-size: .875rem;
    font-weight: 600;
    color: #707587
}

.game-outcome {
    display: flex;
    align-items: flex-end;
    justify-content: center;
    flex-direction: column;
    gap: 4px;
    text-align: right
}

.score {
    font-size: 1.75rem;
    line-height: 1.3;
    font-weight: 900;
    font-variant-numeric: tabular-nums;
    color: var(--blue);
    white-space: nowrap
}

.score span {
    font-weight: 600;
    font-size: 1rem;
    color: var(--muted);
    padding-inline: 4px
}

.penalties {
    font-size: .875rem;
    color: var(--blue);
    font-weight: 800;
    white-space: nowrap
}

.set-partials {
    font-size: .875rem;
    margin: 8px 0 0;
    line-height: 1.6;
    font-variant-numeric: tabular-nums;
    color: var(--muted)
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
    min-height: 210px;
    padding: 32px 24px
}

.empty-state svg {
    color: #7b80a2;
    margin-bottom: 16px
}

.empty-state h3 {
    margin-bottom: 8px;
    color: var(--blue)
}

.empty-state p {
    max-width: 54ch;
    margin-bottom: 0;
    font-size: .9375rem
}

.champion-banner {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 24px;
    background: #fff0e2;
    border-radius: var(--radius);
    margin: 0 0 24px;
    color: #76330a
}

.champion-banner span {
    display: block;
    font-size: .875rem
}

.champion-banner strong {
    font-size: 1.5rem;
    font-weight: 900
}

.champion-banner svg {
    color: #a64a0c
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, minmax(0, 1fr));
    border-top: 1px solid var(--line);
    border-left: 1px solid var(--line);
    border-radius: 8px;
    overflow: hidden;
    background: white
}

.weekday {
    padding: 12px;
    text-align: center;
    font-weight: 800;
    background: var(--blue-soft);
    color: var(--blue);
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line);
    font-size: .875rem
}

.calendar-day {
    min-height: 116px;
    padding: 12px;
    display: flex;
    flex-direction: column;
    gap: 8px;
    text-decoration: none;
    color: var(--ink);
    border-right: 1px solid var(--line);
    border-bottom: 1px solid var(--line)
}

.calendar-day:hover {
    background: #eef4fc
}

.calendar-day.outside {
    background: #f2f3f6;
    color: #6c7281
}

.calendar-day.today .day-number {
    color: var(--blue);
    font-weight: 900;
    text-decoration: underline;
    text-decoration-color: var(--orange);
    text-decoration-thickness: 3px;
    text-underline-offset: 5px
}

.calendar-day.selected {
    background: #e7eaf7;
    box-shadow: inset 0 0 0 2px var(--blue)
}

.day-number {
    font-weight: 700;
    line-height: 1.2
}

.day-game-count {
    font-size: .8125rem;
    font-weight: 800;
    color: var(--blue)
}

.day-preview {
    font-size: .75rem;
    color: var(--muted);
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis
}

.month-controls {
    display: flex;
    gap: 8px
}

.cup-bracket {
    margin: 32px 0 48px
}

.bracket-scroll {
    overflow-x: auto;
    padding: 8px 4px 24px;
    scrollbar-width: thin
}

.bracket {
    display: flex;
    gap: 40px;
    min-width: fit-content
}

.bracket-round {
    width: 268px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column
}

.bracket-round h3 {
    border-bottom: 2px solid var(--blue);
    padding-bottom: 12px;
    margin-bottom: 20px;
    color: var(--blue)
}

.round-games {
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    gap: 20px;
    flex: 1
}

.bracket-game {
    border: 1px solid var(--line);
    border-radius: 8px;
    background: white;
    padding: 12px;
    position: relative
}

.bracket-meta {
    font-size: .75rem;
    color: var(--muted);
    margin-bottom: 10px
}

.bracket-team {
    display: flex;
    align-items: center;
    gap: 12px;
    justify-content: space-between;
    padding: 8px;
    font-size: .875rem;
    border-radius: 4px;
    min-height: 38px
}

.bracket-team span {
    overflow-wrap: anywhere
}

.bracket-team strong {
    font-variant-numeric: tabular-nums;
    white-space: nowrap
}

.bracket-team.is-winner {
    color: var(--blue);
    background: var(--blue-soft);
    font-weight: 900
}

.bracket-note {
    font-size: .75rem;
    margin: 8px 0 0;
    color: var(--blue)
}

.management-nav {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    border-bottom: 1px solid var(--line);
    padding-top: 12px
}

.management-nav a {
    padding: 10px 12px;
    min-height: 44px;
    text-decoration: none;
    font-weight: 800;
    font-size: .875rem
}

.management-nav a:hover {
    background: var(--blue-soft);
    border-radius: 8px
}

.competition-directory {
    margin-bottom: 32px
}

.competition-directory>details {
    border-top: 1px solid var(--line)
}

.competition-directory>details:last-child {
    border-bottom: 1px solid var(--line)
}

summary {
    cursor: pointer;
    min-height: 44px;
    font-weight: 800;
    padding-block: 10px;
    color: var(--blue)
}

.competition-directory summary {
    padding: 16px 8px;
    font-size: 1.125rem
}

.competition-links {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0 32px;
    padding: 0 8px 16px
}

.competition-links a {
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-decoration: none;
    padding: 14px 0;
    border-top: 1px solid var(--line)
}

.competition-links a:hover strong {
    text-decoration: underline
}

.competition-links a span {
    font-size: .875rem;
    color: var(--muted)
}

label {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-weight: 800;
    font-size: .875rem
}

input,
select,
textarea {
    background: white;
    border: 1px solid #aeb4c3;
    border-radius: 8px;
    min-height: 46px;
    padding: 10px 12px;
    color: var(--ink);
    max-width: 100%;
    width: 100%
}

input:hover,
select:hover {
    border-color: var(--blue)
}

input[type=checkbox] {
    width: 20px;
    height: 20px;
    min-height: 20px;
    accent-color: var(--blue)
}

input:disabled {
    background: #eee;
    color: #777
}

select {
    appearance: none;
    background-image: url('chevron.svg');
    background-position: right 12px center;
    background-repeat: no-repeat;
    padding-right: 36px
}

input::placeholder {
    color: #727688;
    font-weight: 400
}

.button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    border: 1px solid transparent;
    border-radius: 8px;
    background: var(--blue);
    color: white;
    text-decoration: none;
    font-weight: 800;
    font-size: .9375rem;
    line-height: 1.4;
    min-height: 46px;
    padding: 11px 20px;
    white-space: normal;
    text-align: center
}

.button:hover {
    background: var(--blue-deep)
}

.button:disabled {
    opacity: .5;
    cursor: wait
}

.button.secondary {
    border-color: #bdc2d2;
    background: white;
    color: var(--blue)
}

.button.secondary:hover {
    background: var(--blue-soft);
    border-color: var(--blue)
}

.button.small {
    font-size: .8125rem;
    padding: 9px 12px;
    min-height: 40px
}

.button.danger {
    background: var(--danger);
    color: white
}

.button-row {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap
}

.text-button {
    background: none;
    border: 0;
    text-decoration: underline;
    min-height: 44px;
    font-weight: 800;
    padding: 8px 4px
}

.danger-text {
    color: var(--danger)
}

.stack-form {
    display: flex;
    flex-direction: column;
    gap: 20px
}

.inline-form {
    display: flex;
    align-items: end;
    gap: 16px;
    flex-wrap: wrap
}

.inline-form>label {
    flex: 1;
    min-width: 160px;
    max-width: 360px
}

.inline-form .helper {
    flex-basis: 100%
}

.form-section {
    padding: 24px;
    background: white;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    margin: 20px 0
}

.form-section p {
    font-size: .9375rem
}

.form-section h2 {
    font-size: 1.25rem
}

.auth-panel {
    max-width: 520px;
    margin: 32px auto 56px;
    padding: 32px;
    background: white;
    border: 1px solid var(--line);
    border-radius: var(--radius)
}

.auth-panel h1 {
    font-size: 2rem
}

.auth-panel .text-link {
    display: inline-block;
    margin-top: 20px
}

.notice {
    padding: 16px 20px;
    background: #e9eef9;
    color: var(--blue);
    border-radius: 8px;
    margin-bottom: 24px;
    line-height: 1.6
}

.notice.success {
    background: #e5f3eb;
    color: var(--success)
}

.notice.error {
    background: #fbe9e9;
    color: #8a2428
}

.simple-list {
    background: white;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    overflow: hidden
}

.simple-row {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 24px;
    padding: 16px 24px;
    border-bottom: 1px solid var(--line)
}

.simple-row:last-child {
    border-bottom: 0
}

.simple-row>strong {
    padding-top: 10px;
    overflow-wrap: anywhere
}

.simple-row>div,
.simple-row>details {
    max-width: 60%
}

.simple-row details .inline-form {
    margin-top: 8px
}

.destructive {
    padding-top: 20px;
    margin-top: 16px;
    border-top: 1px solid var(--line)
}

.count {
    font-weight: 600;
    color: var(--muted);
    font-size: 1rem;
    margin-left: 4px
}

.schedule-editor {
    grid-column: 2/-1
}

.schedule-editor summary {
    font-size: .875rem;
    padding-top: 0;
    min-height: 32px
}

.schedule-editor .inline-form {
    padding: 12px 0
}

.danger-zone {
    border: 1px solid #dfb2b4;
    background: #fff7f7;
    padding: 16px 24px;
    border-radius: 8px;
    margin: 32px 0
}

.danger-zone summary {
    color: var(--danger)
}

.danger-zone h2 {
    font-size: 1.25rem;
    margin-top: 16px
}

.danger-zone li {
    margin-bottom: 8px;
    font-size: .875rem
}

.checkbox-label {
    display: flex;
    flex-direction: row;
    align-items: center;
    margin-block: 16px
}

.draw-pairs {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 24px;
    margin: 24px 0
}

.draw-pairs fieldset {
    background: white
}

.draw-pairs label+label {
    margin-top: 12px
}

fieldset {
    padding: 20px;
    border: 1px solid var(--line);
    border-radius: 8px;
    margin: 0;
    min-width: 0
}

legend {
    color: var(--blue);
    font-weight: 900;
    padding: 0 8px
}

.result-form {
    max-width: 700px
}

.match-title {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 24px;
    background: var(--blue-soft);
    padding: 24px;
    border-radius: var(--radius);
    margin-bottom: 28px;
    font-size: 1.25rem;
    color: var(--blue)
}

.match-title>strong {
    flex: 1;
    text-align: center;
    overflow-wrap: anywhere
}

.match-title>span {
    color: var(--muted)
}

.score-inputs {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 20px minmax(0, 1fr);
    gap: 12px;
    align-items: end
}

.score-inputs>span {
    padding-bottom: 16px;
    text-align: center;
    color: var(--muted)
}

.score-inputs input {
    font-size: 1.5rem;
    font-weight: 900;
    text-align: center
}

.penalty-fields {
    margin-top: 24px
}

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

.set-table th {
    padding: 12px;
    font-size: .875rem;
    text-align: center;
    overflow-wrap: anywhere
}

.set-table th:first-child {
    width: 60px
}

.set-table td {
    padding: 6px 12px
}

.set-table td input {
    text-align: center;
    font-size: 1.25rem;
    font-weight: 800
}

.result-form>h2,
.result-form [data-normal-score]>h2 {
    font-size: 1.25rem;
    margin: 12px 0
}

.review-panel {
    max-width: 760px;
    margin: 24px auto;
    background: white;
    border: 1px solid var(--line);
    border-radius: var(--radius);
    padding: 32px;
    text-align: center
}

.review-panel h1 {
    font-size: 2rem
}

.review-score {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px
}

.review-score .score {
    font-size: 3rem
}

.review-winner {
    margin-block: 24px;
    color: var(--blue);
    font-size: 1.125rem
}

.review-panel .button-row {
    justify-content: center
}

.history-list details {
    padding: 12px 0;
    border-bottom: 1px solid var(--line)
}

.history-list summary {
    display: flex;
    flex-direction: column;
    gap: 4px
}

.history-list summary span {
    font-size: .875rem;
    color: var(--muted);
    font-weight: 600
}

.history-list pre {
    background: white;
    padding: 16px;
    white-space: pre-wrap;
    overflow-wrap: anywhere;
    font-size: .875rem;
    max-height: 320px;
    overflow-y: auto
}

@media(min-width:801px) {
    .bracket-round:not(:last-child) .bracket-game::after {
        content: '';
        position: absolute;
        width: 40px;
        right: -41px;
        top: 50%;
        height: 1px;
        background: var(--line)
    }
}

@media(max-width:1000px) {
    .header-inner {
        gap: 16px
    }

    .event-wordmark {
        font-size: 1rem
    }

    .view-toolbar {
        align-items: start;
        flex-direction: column;
        gap: 0
    }

    .refresh-status {
        padding: 4px 0 12px;
        text-align: left
    }

    .game-row {
        grid-template-columns: 90px 1fr 150px;
        gap: 16px;
        padding: 20px
    }

    .sport-nav {
        gap: 6px
    }

    .sport-nav a {
        font-size: .875rem;
        padding: 10px 12px
    }

    .game-meta {
        font-size: .8125rem
    }
}

@media(max-width:700px) {
    .container {
        width: calc(100% - 32px)
    }

    main.container {
        padding-top: 28px;
        padding-bottom: 48px
    }

    .header-inner {
        min-height: 96px;
        flex-wrap: wrap;
        padding-block: 16px;
        gap: 12px
    }

    .brand {
        padding: 5px 8px
    }

    .brand img {
        width: 164px;
        height: 48px
    }

    .event-wordmark {
        font-size: .8125rem;
        letter-spacing: 0
    }

    .event-wordmark strong {
        margin-left: 4px
    }

    .session-bar {
        width: 100%;
        justify-content: space-between;
        font-size: .875rem
    }

    .page-heading {
        padding: 0 0 28px;
        gap: 16px;
        align-items: start
    }

    .page-heading p {
        font-size: 1rem
    }

    .page-heading h1 {
        max-width: 14ch
    }

    .edition-mark {
        display: none
    }

    .page-heading.compact {
        flex-direction: column;
        padding-top: 12px;
        gap: 20px
    }

    .page-heading.compact h1 {
        max-width: none
    }

    .division-tabs a {
        flex: 1;
        padding: 12px 8px;
        font-size: .9375rem;
        min-height: 56px;
        display: flex;
        align-items: center;
        justify-content: center
    }

    .sport-nav {
        padding-block: 20px;
        gap: 8px
    }

    .sport-nav a {
        font-size: .875rem;
        padding: 8px 10px;
        min-height: 42px
    }

    .sport-nav a span {
        font-size: .75rem
    }

    .view-toolbar {
        margin-bottom: 16px
    }

    .view-nav {
        width: 100%;
        overflow-x: auto;
        gap: 20px;
        scrollbar-width: thin
    }

    .view-nav a {
        font-size: .875rem;
        min-height: 44px;
        padding: 10px 0
    }

    .refresh-status {
        font-size: .75rem;
        padding-top: 10px;
        padding-bottom: 10px
    }

    .filter-bar {
        gap: 12px;
        margin-bottom: 24px
    }

    .filter-bar label {
        flex: 1;
        min-width: 130px
    }

    .filter-bar select,
    .filter-bar input {
        min-width: 0;
        width: 100%;
        max-width: none
    }

    .filter-bar .button {
        min-height: 44px
    }

    .section-heading {
        align-items: start;
        gap: 16px
    }

    .section-heading h2 {
        font-size: 1.25rem
    }

    .section-heading .text-link {
        font-size: .8125rem;
        white-space: normal;
        text-align: right;
        max-width: 100px
    }

    .game-row {
        grid-template-columns: 68px minmax(0, 1fr);
        column-gap: 16px;
        row-gap: 12px;
        padding: 20px 16px;
        align-items: start
    }

    .game-when>strong {
        font-size: 1.25rem
    }

    .game-when .date {
        font-size: .8125rem
    }

    .tag {
        font-size: .6875rem;
        padding: 2px 4px
    }

    .game-meta {
        font-size: .75rem;
        line-height: 1.6;
        margin-bottom: 6px
    }

    .matchup {
        gap: 6px 8px;
        font-size: 1rem;
        line-height: 1.5
    }

    .game-outcome {
        grid-column: 2;
        align-items: flex-start;
        text-align: left;
        flex-direction: row;
        flex-wrap: wrap;
        justify-content: flex-start;
        gap: 8px;
        align-items: center
    }

    .game-outcome .muted {
        font-size: .8125rem
    }

    .game-outcome .score {
        font-size: 1.5rem
    }

    .game-outcome .button {
        margin-top: 4px
    }

    .game-outcome .penalties {
        font-size: .8125rem
    }

    .set-partials {
        font-size: .8125rem
    }

    .schedule-editor {
        grid-column: 1/-1;
        padding-top: 8px
    }

    .schedule-editor .inline-form {
        gap: 12px
    }

    .schedule-editor .inline-form>label {
        min-width: 180px
    }

    .empty-state {
        min-height: 210px;
        padding: 28px 20px
    }

    .empty-state p {
        font-size: .875rem
    }

    .empty-state h3 {
        font-size: 1rem
    }

    .empty-state svg {
        width: 36px;
        height: 36px
    }

    .calendar-day {
        min-height: 76px;
        padding: 8px 4px;
        gap: 8px
    }

    .weekday {
        padding: 8px 2px;
        font-size: .75rem
    }

    .day-number {
        font-size: .875rem
    }

    .day-game-count {
        font-size: .6875rem;
        line-height: 1.3
    }

    .day-preview {
        display: none
    }

    .calendar-section .section-heading {
        align-items: center
    }

    .calendar-section h2 {
        font-size: 1.125rem
    }

    .month-controls {
        gap: 4px
    }

    .month-controls .button.small {
        font-size: .75rem;
        padding: 8px;
        min-height: 40px
    }

    .champion-banner {
        padding: 20px 16px
    }

    .champion-banner strong {
        font-size: 1.25rem
    }

    .bracket {
        gap: 20px
    }

    .bracket-round {
        width: 252px;
        scroll-snap-align: start
    }

    .bracket-scroll {
        scroll-snap-type: x proximity
    }

    .cup-bracket>.section-heading {
        flex-direction: column;
        gap: 4px
    }

    .competition-links {
        grid-template-columns: 1fr
    }

    .management-nav {
        gap: 0
    }

    .management-nav a {
        font-size: .8125rem;
        padding: 10px 8px
    }

    .form-section {
        padding: 20px 16px
    }

    .inline-form>label {
        min-width: 100%;
        max-width: none
    }

    .inline-form .button {
        width: 100%
    }

    .auth-panel {
        padding: 24px 20px;
        margin: 16px auto 32px
    }

    .auth-panel h1 {
        font-size: 1.75rem
    }

    .simple-row {
        padding: 16px;
        flex-direction: column;
        gap: 8px
    }

    .simple-row>div,
    .simple-row>details {
        max-width: none;
        width: 100%
    }

    .danger-zone {
        padding: 16px
    }

    .draw-pairs {
        grid-template-columns: 1fr;
        gap: 20px
    }

    .draw-pairs fieldset {
        padding: 16px
    }

    .match-title {
        gap: 12px;
        padding: 20px 12px;
        font-size: 1rem
    }

    .set-table th {
        padding: 8px 4px;
        font-size: .75rem
    }

    .set-table td {
        padding: 6px
    }

    .set-table th:first-child {
        width: 40px
    }

    .result-form fieldset {
        padding: 16px 12px
    }

    .score-inputs {
        gap: 8px
    }

    .review-panel {
        padding: 24px 16px
    }

    .review-panel h1 {
        font-size: 1.75rem
    }

    .site-footer {
        align-items: start;
        flex-direction: column;
        gap: 16px;
        font-size: .8125rem
    }

    .notice {
        padding: 16px;
        font-size: .9375rem
    }

    .section-heading.spaced {
        margin-top: 36px
    }
}

@media(prefers-reduced-motion:no-preference) {

    .button,
    .sport-nav a,
    .division-tabs a {
        transition: background-color .16s ease-out, border-color .16s ease-out
    }

    .champion-banner {
        animation: champion-reveal .3s ease-out
    }

    @keyframes champion-reveal {
        from {
            clip-path: inset(0 8% 0 0)
        }

        to {
            clip-path: inset(0)
        }
    }
}

@media print {

    .site-header,
    .site-footer,
    .management-nav,
    .filter-bar,
    .view-toolbar,
    .sport-nav,
    .division-tabs,
    .schedule-editor,
    .button {
        display: none !important
    }

    body {
        background: white
    }

    .container {
        width: 100%
    }

    .game-row {
        break-inside: avoid
    }

    .bracket-scroll {
        overflow: visible
    }

    .bracket {
        flex-wrap: wrap
    }
}

.qa-banner {
    background: #fff0d4;
    color: #68410c;
    text-align: center;
    font-size: .875rem;
    font-weight: 800;
    padding: 8px 16px
}

@media(max-width:700px) {
    .view-nav {
        gap: 12px;
        flex-wrap: wrap;
        overflow: visible
    }

    .view-nav a {
        font-size: .8125rem
    }
}

.calendar-grid{display:table;width:100%;table-layout:fixed;border-collapse:collapse}.calendar-grid td{padding:0;vertical-align:top}.advance-winner{font-size:.875rem;font-weight:800;color:var(--blue)}

