/* Appearance only: the existing ICF structure, type and component sizes stay intact. */
.theme-toggle{display:inline-flex;align-items:center;justify-content:center;gap:5px;min-height:26px;padding:3px 7px;border:1px solid var(--edge);border-radius:4px;background:var(--surface);color:var(--secondary);font:inherit;font-size:11px;line-height:18px;white-space:nowrap;cursor:pointer}
.theme-toggle::before{content:"";width:12px;height:12px;border:1px solid #a27b4c;border-radius:2px;background:repeating-linear-gradient(8deg,#b68e5d 0 2px,#c9a779 3px 4px,#ab8050 5px 6px)}
.theme-toggle:hover{color:var(--text);border-color:var(--accent)}
.theme-toggle[aria-pressed="true"]{color:var(--accent);border-color:var(--accent)}
.theme-toggle:focus-visible{outline:2px solid var(--accent);outline-offset:3px}
.public-site .visitor-text-controls .theme-toggle{margin-right:5px}
.organizer-site .site-header>.theme-toggle{margin-left:auto}
@media(max-width:740px){
 .public-site .site-header:has(.visitor-text-controls){grid-template-columns:minmax(0,1fr) auto 44px}
 .organizer-site .site-header:has(>.theme-toggle){grid-template-columns:minmax(0,1fr) auto 44px}
 .organizer-site .site-header>.theme-toggle{grid-column:2;grid-row:1}
 .organizer-site .site-header.has-mobile-menu:has(>.theme-toggle) .menu-toggle{grid-column:3}
}
html[data-theme="wood"]{color-scheme:light;--page:#efe6d6;--surface:#fcf6e9;--surface-soft:#e9dac2;--hero:#e4cba5;--text:#392a1f;--secondary:#715a43;--accent:#805222;--accent-ink:#fff5df;--edge:#c9b391;--button-top:#926b42;--button-bottom:#69472c;--button-edge:#a78151;--button-text:#fff4df;--button-highlight:#ffffff24;--button-glow:#78512415;--control-surface:#fffaf0;--wood-grain:repeating-linear-gradient(2deg,transparent 0 5px,#8e622508 6px,transparent 7px 13px,#8e622505 14px 15px)}
html[data-theme="wood"] body{background-color:var(--page);background-image:var(--wood-grain)}
html[data-theme="wood"] .site-header-band{background-color:#e0c39a;background-image:var(--wood-grain),linear-gradient(110deg,#e5cba5,#d4b185);border-color:var(--edge)}
html[data-theme="wood"] .hero.compact{background-image:var(--wood-grain),linear-gradient(110deg,var(--hero),var(--page))}
html[data-theme="wood"] .icf-footer{background-color:#e3d3b9;background-image:var(--wood-grain);border-color:var(--edge);color:var(--secondary)}
html[data-theme="wood"] .organizer-site{--control-surface:#fffaf0}
html[data-theme="wood"] :is(.sheet-pairing-row,.sheet-names,.slam-table-card,.slam-entry,.slam-latest-list){background:var(--page);border-color:var(--edge)}
html[data-theme="wood"] :is(.sheet-names,.slam-badge){color:var(--accent)}
html[data-theme="wood"] .sheet-names::after{background:var(--edge)}
html[data-theme="wood"] .slam-table :is(th,td){border-color:var(--edge)}
html[data-theme="wood"] .slam-list-head{background:var(--surface-soft);color:var(--secondary)}
html[data-theme="wood"] .public-site .slam-view-switch .button[aria-pressed="true"]{background:var(--button-bottom);color:var(--button-text);border-color:var(--button-edge)}
html[data-theme="wood"] :is(.tournament-card:hover,.slam-entry:hover,.slam-entry:focus-within,.editable-row:hover,.editable-row:hover>td,.inline-results-table [data-inline-match]:hover,.inline-results-table [data-inline-match]:hover>td){background:var(--surface-soft);border-color:var(--button-edge);color:var(--text)}
html[data-theme="wood"] :is(.competition-info-toggle:hover,.rubber-public:hover,.inline-rubber:has(.inline-rubber-detail-link):hover,.match-card.has-board-link:hover:not(:has(.team-parts:hover))){border-color:var(--button-edge)}
html[data-theme="wood"] .match-card.has-board-link:hover:not(:has(.team-parts:hover)),html[data-theme="wood"] .match-card.has-board-link:hover:not(:has(.team-parts:hover)) > :is(.match-meta,.score-match-body,.match-bottom),
html[data-theme="wood"] .match-card.has-board-link:hover:not(:has(.team-parts:hover)) > .score-match-body :is(.score-competitors,.competitor),
html[data-theme="wood"] .rubber-public.has-rubber-sheet:hover > :is(.match-meta,.rubber-players,.match-bottom){background:var(--surface-soft)}
html[data-theme="wood"] .public-site .schedule-day-card>.schedule-result-link:hover{background:var(--surface-soft);outline-color:var(--button-edge)}
html[data-theme="wood"] .organizer-site :is(.editable-row:hover,.editable-row:focus-within,[data-inline-match]:has([data-expand-team]):hover){outline-color:var(--button-edge)}
html[data-theme="wood"] :is(.competition-gender-switch:not(.competition-discipline-switch) a:not([aria-current]):hover,.registration-switch:not(.competition-discipline-switch) .button:not([aria-current]):hover){background:var(--surface-soft);color:var(--text)}
html[data-theme="wood"] :is(.competition-discipline-switch a[aria-current],.registration-switch.competition-discipline-switch .button[aria-current]){background:linear-gradient(180deg,#7f7750,#575534);border-color:#85835c;color:#fff9e4}
html[data-theme="wood"] :is(.competition-discipline-switch a:hover,.registration-switch.competition-discipline-switch .button:hover){background:#64603c;border-color:#85835c;color:#fff9e4}
html[data-theme="wood"] .public-board-history .sheet-game{background:var(--surface);border-color:var(--edge)}
html[data-theme="wood"] .public-board-history .sheet-game:has(>summary:hover),html[data-theme="wood"] .public-board-history .sheet-game:has(>summary:focus-visible){background:var(--surface-soft);border-color:var(--button-edge)}
html[data-theme="wood"] .public-board-history .public-scoresheet :is(th,td){background:var(--surface);color:var(--text);border-color:var(--edge)}
html[data-theme="wood"] .public-board-history .public-scoresheet :is(thead tr:last-child th,tbody td.total,tfoot td.total){background:var(--surface-soft);border-color:var(--edge)}
html[data-theme="wood"] .public-board-history .public-scoresheet tbody td.sheet-board{background:var(--page)}
html[data-theme="wood"] .slam-detail-dialog{background:var(--surface);color:var(--text);border-color:var(--edge)}
html[data-theme="wood"] .slam-detail-dialog p{color:var(--secondary)}
html[data-theme="wood"] :is(.rubber-games:not(.is-rubber-winner),.sheet-pairing-row .sheet-games:not(.is-match-winner),.game-score-badge.finished,.inline-score-grid [data-result-total]:not(.is-score-winner)){background:var(--surface-soft);color:var(--text)}
html[data-theme="wood"] .inline-rubber .inline-score-grid [data-result-total]:not(.is-score-winner){background:var(--page)}
html[data-theme="wood"] :is(.competitor.winner strong,.rubber-games.is-rubber-winner,.sheet-games.is-match-winner){background:var(--accent);color:var(--accent-ink)}
html[data-theme="wood"] :is(.badge,.score-match .match-meta .badge,.public-group-matches .score-match .match-meta .badge){background:var(--surface-soft);color:var(--secondary)}
html[data-theme="wood"] :is(.badge,.score-match .match-meta .badge,.public-group-matches .score-match .match-meta .badge).live:not(.game-score-badge){background:var(--accent);color:var(--accent-ink)}
html[data-theme="wood"] :is(.badge,.score-match .match-meta .badge,.public-group-matches .score-match .match-meta .badge):is(.finished,.pending,.disputed,.coming-up):not(.game-score-badge){background:var(--surface-soft);color:var(--accent)}
html[data-theme="wood"] .game-score-badges .badge.game-score-badge.live{background:#d7e4df;color:#254e42}
html[data-theme="wood"] .match-dialog-games button:not(:disabled):hover{background:var(--surface-soft);border-color:var(--button-edge);color:var(--text)}
html[data-theme="wood"] .competition-unsaved-label{color:var(--accent)}
html[data-theme="wood"] .inline-lineup-status[data-lineup-state="submitted"]{color:#356044}
html[data-theme="wood"] .refresh-activity-panel :is(.activity-latency-warning,.activity-latency-critical){color:#8a3e26}
html[data-theme="wood"] .refresh-activity-panel .refresh-activity-warning{background:#f1d9cc;border-color:#bb8d79;color:#743823}
