:root{color-scheme:light;--page:#f5f2e9;--ink:#1c3326;--panel:#fffdf8;--line:#d8ddcf;--muted:#5c695e;--poster:#1c3326;--poster-end:#254936;--status:#e5e9df}
:root[data-theme=dark]{color-scheme:dark;--page:#10251b;--ink:#f2f1e9;--panel:#193527;--line:#395341;--muted:#b5c5b8;--poster:#234732;--poster-end:#31563d;--status:#294636}
@media(prefers-color-scheme:dark){:root:not([data-theme=light]){color-scheme:dark;--page:#10251b;--ink:#f2f1e9;--panel:#193527;--line:#395341;--muted:#b5c5b8;--poster:#234732;--poster-end:#31563d;--status:#294636}}
body{background:var(--page);color:var(--ink);font-family:Inter,Manrope,system-ui,sans-serif}a{color:inherit}header{border-color:var(--line)}article{background:var(--panel)}footer{max-width:960px;margin:auto;padding:24px;border-top:1px solid var(--line)}footer label{display:flex;gap:12px;align-items:center}footer select{width:auto}input,textarea,select{background:var(--panel);color:var(--ink);border:1px solid var(--line);border-radius:6px}button{border-radius:7px}header>a:first-child{font-size:1.35rem;font-weight:800}header form{margin:0}.status-box{padding:16px;background:var(--status);border-radius:8px}.match-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:18px}.match-grid[data-count='2']{grid-template-columns:repeat(2,minmax(0,1fr))}.match-grid[data-count='1']{grid-template-columns:1fr}.match-poster{position:relative;overflow:hidden;margin:0;padding:24px;color:#fffdf5;border:1px solid #45624a;border-radius:14px;background:repeating-linear-gradient(164deg,transparent 0 34px,#ffffff04 35px 36px),linear-gradient(120deg,var(--poster),var(--poster-end));box-shadow:0 8px 24px #071a1214;display:flex;flex-direction:column;min-width:0}.poster-top{display:flex;gap:8px;align-items:center;justify-content:space-between}.category-badge{color:#192c25;background:#f2f1e9;border-left:4px solid var(--accent);padding:4px 10px;border-radius:5px;font-size:.8rem;font-weight:750}.league-name{min-height:3em;margin:12px 0 8px;font-size:.85rem;line-height:1.5;color:#e3e9e1}.elite-badge{display:inline-block;margin-left:4px;padding:2px 6px;border:1px solid #b8c5b5;border-radius:4px;font-size:.7rem}.poster-teams{display:grid;grid-template-columns:1fr;gap:10px;margin:14px 0 20px;font-size:1.15rem;font-weight:750;line-height:1.3}.team{display:flex;align-items:center;gap:10px;min-width:0}.team span:last-child{overflow-wrap:anywhere}.team-mark{flex:none;display:grid;place-items:center;width:44px;height:44px;border-radius:50%;border:1px solid #91a790;background:#ffffff0d;font-size:1.1rem;color:#ecebe2}.poster-teams a{text-decoration:none}.poster-teams a:hover{text-decoration:underline}.versus{color:#b3c6b1;font-size:.65rem;letter-spacing:.16em;padding-left:54px}.poster-date{margin-top:auto;background:#8b1e2d;margin-left:-24px;margin-right:-24px;padding:12px 24px;font-weight:700;font-size:.9rem}.poster-venue{font-size:.8rem;color:#dce5d9;margin-bottom:0}.poster-state{font-size:.7rem;border:1px solid #8aa085;border-radius:5px;padding:3px 7px;max-width:50%}.poster-state.is-now{background:#f3e1af;color:#26352a;border:0}.share-button{background:transparent;color:inherit;border:1px solid #8fa38b;padding:6px 10px;font-size:.8rem;white-space:nowrap}.share-result{font-size:.8rem}.share-fallback{width:100%;font:inherit}.match-grid[data-count='1'] .match-poster{padding:28px 32px}.match-grid[data-count='1'] .poster-teams{grid-template-columns:1fr auto 1fr;align-items:center;font-size:1.55rem;margin:20px 0 28px}.match-grid[data-count='1'] .versus{padding:0}.match-grid[data-count='1'] .team-mark{width:64px;height:64px;font-size:1.5rem}.match-grid[data-count='1'] .category-badge{background:var(--accent);border:0;color:var(--accent-ink);padding:8px 16px}.match-grid[data-count='1'] .league-name{min-height:0}.match-grid[data-count='1'] .poster-date{margin-left:-32px;margin-right:-32px;padding-left:32px}.match-list{display:grid;gap:18px}.match-list .match-poster{max-width:680px}
@media(max-width:700px){header,main,footer{padding:18px}.match-grid,.match-grid[data-count='2']{grid-template-columns:1fr}.match-grid[data-count='1'] .poster-teams{grid-template-columns:1fr;font-size:1.25rem}.match-grid[data-count='1'] .versus{padding-left:74px}.match-grid[data-count='1'] .match-poster{padding:24px}.match-grid[data-count='1'] .poster-date{margin-left:-24px;margin-right:-24px;padding-left:24px}.league-name{min-height:0}}

.match-type{align-self:flex-start;font-size:.7rem;padding:3px 8px;border-left:3px solid var(--type-accent);background:#f1f0e8;color:#28382c;border-radius:4px;margin-top:10px}
@media(min-width:701px){.match-grid[data-count='1'] .match-poster{display:grid;grid-template-columns:minmax(0,1.65fr) minmax(0,1fr);column-gap:32px;align-items:center}.match-grid[data-count='1'] .poster-top{grid-column:1/-1;grid-row:1}.match-grid[data-count='1'] .match-type{grid-column:1;grid-row:2;justify-self:start}.match-grid[data-count='1'] .league-name{grid-column:1;grid-row:3}.match-grid[data-count='1'] .poster-teams{grid-column:1;grid-row:4;grid-template-columns:1fr;gap:12px;font-size:1.3rem}.match-grid[data-count='1'] .versus{padding-left:74px}.match-grid[data-count='1'] .poster-date{grid-column:2;grid-row:3;margin:0;padding:16px;border-radius:7px}.match-grid[data-count='1'] .poster-venue{grid-column:2;grid-row:4;align-self:start;line-height:1.8}.match-grid[data-count='1'] .match-poster>div:last-child{grid-column:1/-1;grid-row:6}.match-grid[data-count='1'] .match-poster>p:not(.league-name):not(.poster-venue){grid-column:1/-1;grid-row:5}}

.category-badge{background:color-mix(in srgb,var(--accent) 15%,#faf8f0)}.poster-teams{grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);text-align:center;font-size:.9rem;gap:8px}.team{flex-direction:column;gap:10px}.team-mark{width:62px;height:62px;background:#f5f2e9;color:#1c3326;border:3px solid #d6cbaa;font-size:1.25rem}.versus{padding:0;font-size:.9rem}.poster-teams a:first-child::after{content:'';position:absolute;inset:0;z-index:1}.share-button,.share-result{position:relative;z-index:2}.match-grid[data-count='2'] .team-mark{width:78px;height:78px}.match-grid[data-count='1'] .team-mark{width:86px;height:86px}.match-grid[data-count='1'] .poster-teams{grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);font-size:1rem}.match-grid[data-count='1'] .versus{padding:0}.poster-notice{font-size:.85rem}.poster-date{line-height:1.5}.share-button{margin-top:12px}
@media(min-width:701px){.match-grid[data-count='1'] .poster-date,.match-grid[data-count='1'] .poster-venue{text-align:center}.match-grid[data-count='1'] .league-name{text-align:center}.match-grid[data-count='1'] .poster-notice{grid-column:1/-1;grid-row:5}.match-grid[data-count='1'] .poster-teams{grid-template-columns:minmax(0,1fr) auto minmax(0,1fr);font-size:1rem}.match-grid[data-count='1'] .versus{padding:0}}
@media(max-width:420px){.match-grid[data-count='1'] .team-mark{width:62px;height:62px}.match-grid[data-count='1'] .poster-teams{font-size:.9rem}.match-grid[data-count='2'] .team-mark{width:62px;height:62px}}

/* Shared history tables follow the active theme. */
.history-table-wrap{overflow-x:auto;margin-top:1rem}
.history-table{width:100%;border-collapse:collapse;table-layout:fixed;min-width:480px;color:var(--ink);background:var(--panel)}
.history-table th,.history-table td{text-align:left;vertical-align:top;padding:14px 18px;border-bottom:1px solid var(--line);overflow-wrap:anywhere;line-height:1.5;color:var(--ink)}
.history-table thead th{background:var(--status);font-weight:700}
.history-table tbody th{background:var(--panel);font-weight:600}
.history-table th:first-child{width:28%}
.match-list{gap:0;border-top:1px solid var(--line)}
.match-row{display:grid;grid-template-columns:140px minmax(0,1fr) 110px;gap:20px;position:relative;margin:0;padding:20px 16px;border-radius:0;border-bottom:1px solid var(--line);border-left:3px solid var(--accent);background:var(--panel);color:var(--ink)}
.match-row-date{display:flex;flex-direction:column;font-size:.9rem;gap:3px}
.match-row h3{font-size:1.05rem;margin:0;overflow-wrap:anywhere}
.match-row h3 a::after{content:'';position:absolute;inset:0;z-index:1}
.match-row-main p{margin:6px 0 0;font-size:.85rem;overflow-wrap:anywhere}
.match-row .category-badge{display:inline-block;font-size:.75rem}
.row-type{color:var(--muted);font-size:.8rem}.row-venue{color:var(--muted)}
.match-row-actions{display:flex;flex-direction:column;align-items:flex-end;gap:8px}
.row-status{font-size:.8rem;background:var(--status);color:var(--ink);border-radius:5px;padding:3px 8px}
.row-status.is-now{background:#f3e1af;color:#26352a}
.match-row .share-button{margin:0;border-color:var(--line)}
.match-row .share-fallback{position:relative;z-index:2}
@media(max-width:700px){.match-row{grid-template-columns:minmax(0,1fr) auto;gap:12px;padding:16px 12px}.match-row-date{grid-column:1;flex-direction:row;flex-wrap:wrap;gap:8px}.match-row-main{grid-column:1/-1;grid-row:2}.match-row-actions{grid-column:2;grid-row:1}.match-row .share-button{padding:4px 8px}.history-table th,.history-table td{padding:10px 12px}}

.day-card-image{display:block;width:100%;height:170px;object-fit:contain;margin:14px 0;background:#10251b;border-radius:7px}
.day-card h2{font-size:1.1rem;margin:8px 0 16px}.day-card-link::after{content:'';position:absolute;inset:0;z-index:1}
.day-poster-image{display:block;width:100%;max-height:900px;object-fit:contain;background:var(--panel);border-radius:8px}
.day-program{background:var(--status);padding:12px 18px;border-radius:8px;white-space:normal;overflow-wrap:anywhere}
.match-grid[data-count='1'] .day-card{display:grid;grid-template-columns:200px minmax(0,1fr);gap:12px 24px}
.match-grid[data-count='1'] .day-card .poster-top{grid-column:2;grid-row:1}
.match-grid[data-count='1'] .day-card .day-card-image{grid-column:1;grid-row:1/7;height:230px;margin:0}
.match-grid[data-count='1'] .day-card .league-name{grid-column:2;grid-row:2;text-align:left}
.match-grid[data-count='1'] .day-card h2{grid-column:2;grid-row:3;margin:0}
.match-grid[data-count='1'] .day-card .poster-date{grid-column:2;grid-row:4;text-align:left;margin:0;padding:10px 14px}
.match-grid[data-count='1'] .day-card .poster-venue{grid-column:2;grid-row:5;text-align:left}
.match-grid[data-count='1'] .day-card>p:not(.league-name):not(.poster-venue){grid-column:2;grid-row:6;margin:0}
.match-grid[data-count='1'] .day-card>div:last-child{grid-column:2;grid-row:7}
@media(max-width:700px){.match-grid[data-count='1'] .day-card{display:flex}.match-grid[data-count='1'] .day-card .day-card-image{height:200px;width:100%}.match-grid[data-count='1'] .day-card .poster-date{width:auto;margin:10px 0 0}.match-grid[data-count='1'] .day-card>div:last-child{width:100%}}

.match-form-section{border:1px solid var(--line);border-radius:8px;padding:12px 16px;margin:20px 0;min-width:0}
.match-form-section legend{font-weight:700;padding:0 8px}
.match-form-section .field-row small{display:block;margin-top:4px;line-height:1.45}
.quick-entry-note{border-left:4px solid #8b1e2d;padding:8px 16px}

[hidden]{display:none!important}.league-category-note{padding:12px;background:var(--status);border-radius:6px}.editor-response{color:var(--ink);overflow-wrap:anywhere}

.match-fields-grid{display:grid;grid-template-columns:minmax(0,1fr);column-gap:20px;align-items:start}.match-fields-grid>.field-row,.match-fields-grid>.league-category-note{min-width:0}.match-fields-grid .field-row{box-sizing:border-box}.match-fields-grid input,.match-fields-grid select{min-width:0;max-width:100%;width:100%}
@media(min-width:760px){.match-fields-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.match-fields-grid>.field-row,.match-fields-grid>.league-category-note{grid-column:1/-1}.match-fields-grid>.match-paired-field{grid-column:auto}}

.match-fields-grid>.match-optional{grid-column:1/-1;min-width:0;padding:10px 12px;margin:10px 0;border:1px solid var(--line);border-radius:6px;background:var(--panel);box-sizing:border-box}.match-optional>summary{cursor:pointer;font-weight:600;overflow-wrap:anywhere}.match-optional>summary small{font-weight:400;color:var(--muted)}.match-optional>.field-row{margin-bottom:0!important}.match-optional[open]>summary{margin-bottom:8px}

.article-image{display:block;max-width:100%;max-height:720px;width:auto;height:auto;margin:auto}.article-cover-card{display:block;width:100%;height:280px;object-fit:contain}.article-text{overflow-wrap:anywhere}figure{margin:24px 0}

.article-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}.article-grid article{margin:16px 0;min-width:0}.article-grid h3{overflow-wrap:anywhere}@media(max-width:760px){.article-grid{grid-template-columns:1fr}}
/* Archive image information stays on its image in either theme. */
.media-frame{position:relative}.media-info{position:absolute;right:12px;bottom:12px;max-width:calc(100% - 24px);border-radius:8px;background:var(--panel);color:var(--ink);z-index:1}.media-info summary{padding:6px 12px;cursor:pointer;font-size:1.25rem}.media-info>div{padding:0 14px 12px;max-width:320px;max-height:200px;overflow:auto;overflow-wrap:anywhere}.media-figure{margin:20px 0}.media-figure figcaption{font-size:.875rem;overflow-wrap:anywhere}
