:root{font-family:Arial,Helvetica,sans-serif;color:#181b18;background:#f2f3ee;font-synthesis:none;--line:#daddd3;--muted:#596055;--accent:#bde94b}
*,*::before,*::after{box-sizing:border-box}
body{margin:0;min-width:0}
button,input,select{font:inherit;color:inherit}
button,a,select{touch-action:manipulation}
button{cursor:pointer}
a{color:inherit}
button:disabled{cursor:default;opacity:.47}
:focus-visible{outline:3px solid #547700;outline-offset:3px}
h1,h2,h3,p{margin:0;overflow-wrap:anywhere}
h1{font-size:46px;line-height:1.05}
h2{font-size:25px;line-height:1.12}
h3{font-size:17px}
.top{min-height:70px;padding:10px max(24px,calc((100% - 1360px)/2));display:flex;align-items:center;gap:24px;background:#10130f;color:#fff}
.brand{display:inline-flex;align-items:center;min-width:0;gap:11px;text-decoration:none}
.brand img{width:43px;height:43px;object-fit:contain}
.brand b,.brand small{display:block;white-space:nowrap}
.brand b{font-size:15px}
.brand small{font-size:10px;color:#b8c2b4;margin-top:3px}
.environment{color:#c0c8ba;font-size:11px;font-weight:700;white-space:nowrap}
.environment i{background:var(--accent);width:7px;height:7px;border-radius:50%;display:inline-block;margin-right:5px}
.top-links{margin-left:auto;display:flex;align-items:center;gap:18px;font-size:13px}
.top-links>a:first-child{text-decoration:none}
.public-top{justify-content:space-between}
.button{min-height:42px;display:inline-flex;align-items:center;justify-content:center;gap:5px;padding:8px 14px;border:1px solid #b8beb1;border-radius:4px;background:#fff;color:#181b18;font-size:13px;font-weight:700;text-decoration:none;text-align:center}
.button:hover:not(:disabled){background:#e6eadc}
.button.dark{background:#171b14;color:#fff;border-color:#171b14}
.button.dark:hover:not(:disabled){background:#343e2c}
.top .button.dark{background:#caef6a;color:#171b14;border-color:#caef6a}
.wrap{width:min(100% - 48px,1360px);margin:auto;padding-bottom:36px}
.event-head{display:flex;align-items:end;justify-content:space-between;gap:20px;padding:34px 0 26px}
.event-head h1{margin:7px 0 10px}
.event-head p:last-child,.raffle-desk p,.winner-list p{color:var(--muted);font-size:14px}
.eyebrow{color:var(--muted);font-weight:700;font-size:11px;line-height:1.3;text-transform:uppercase}
.event-counts{display:flex;gap:20px;flex-wrap:wrap}
.event-counts div{display:grid;gap:4px;min-width:74px;padding-left:12px;border-left:1px solid #bbc2b7}
.event-counts b{font-size:27px}
.event-counts span{font-size:12px;color:var(--muted)}
.tabs{display:flex;border-block:1px solid var(--line);gap:4px;overflow:auto}
.tabs button{white-space:nowrap;padding:13px 17px;border:0;border-bottom:3px solid transparent;color:var(--muted);font-size:13px;font-weight:700;background:none;min-height:44px}
.tabs button[aria-current]{color:#181b18;border-bottom-color:#476a12;background:#e8ecd9}
.section{padding:24px 0;border-bottom:1px solid var(--line)}
.section-head,.division-title{display:flex;justify-content:space-between;align-items:end;gap:14px;margin-bottom:14px}
.section-head h2,.section>.eyebrow+h2{margin-top:5px}
.toolbar,.actions{display:flex;gap:10px;flex-wrap:wrap;align-items:end}
label{display:grid;min-width:0;gap:5px;font-size:12px;font-weight:700;color:#343d31}
select,input:not([type="checkbox"]){width:100%;min-width:0;background:#fff;border:1px solid #b8beb1;border-radius:4px;padding:9px;min-height:40px}
.toolbar label{min-width:115px}
.scroll{overflow:auto;width:100%;background:#fff;border:1px solid var(--line)}
table{width:100%;border-collapse:collapse;text-align:left;font-size:14px}
td,th{padding:12px;border-bottom:1px solid var(--line);vertical-align:middle}
tbody tr:last-child>*{border-bottom:0}
thead th{font-size:11px;text-transform:uppercase;background:#e8ebe2;color:#3b4438}
caption{text-align:left;padding:11px 12px;font-size:14px;font-weight:700}
.court-grid{table-layout:fixed;min-width:650px}
.court-grid th:first-child{width:80px}
.court-grid td{padding:7px;height:88px;border-left:1px solid var(--line)}
.court-grid tbody th{background:#f9faf7;vertical-align:top;font-size:12px;white-space:nowrap}
.tile{min-width:0;width:100%;min-height:72px;text-align:left;display:grid;align-content:start;gap:6px;background:#f5f7ee;border:1px solid #dce4ce;border-left:3px solid #869842;border-radius:4px;padding:8px;overflow-wrap:anywhere}
.tile:hover{background:#eaf0dc}
.tile>strong{font-size:13px}
.tile-top{display:flex;gap:5px;justify-content:space-between;align-items:start;flex-wrap:wrap}
.tile small,.tile-top>b,.free{color:var(--muted);font-size:11px}
.free{color:#697366}
.status{display:inline-block;font-size:10px;font-weight:700;padding:3px 5px;border-radius:3px;background:#e2e6dd;color:#373f35}
.status.on-court{background:#d9efa7;color:#253800}
.status.final{background:#dde9f3;color:#183e56}
.division{margin-top:18px;padding-top:12px;border-top:1px solid var(--line)}
.groups,.bracket,.fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.bracket{grid-template-columns:repeat(3,minmax(0,1fr));margin-top:12px}
.bracket article{border:1px solid var(--line);background:#fff;padding:10px;font-size:13px;min-width:0}
.bracket p{margin:6px 0}
.bracket small{color:var(--muted)}
.edit{max-width:950px;padding-top:16px}
.edit .fields{grid-template-columns:repeat(auto-fit,minmax(155px,1fr))}
.edit fieldset{margin:0;min-width:0;display:grid;gap:8px;border:1px solid #b8beb1;padding:8px}
.edit fieldset[hidden]{display:none}
.edit fieldset legend{font-size:12px;font-weight:700}
.hours,.actions{margin-top:14px}
.color input{padding:4px}
.check{display:flex;align-items:center}
.error{color:#8a241b;font-size:13px;margin-top:9px;min-height:1em}
.raffle-desk{display:grid;grid-template-columns:2fr 1fr;gap:24px}
.raffle-desk h2,.raffle-desk h3{margin:6px 0 10px}
.winner-list{border-left:1px solid var(--line);padding-left:20px}
.winner-list li{padding:3px}
dialog{width:min(calc(100% - 24px),520px);max-height:calc(100% - 24px);border:1px solid var(--line);color:inherit;padding:20px;border-radius:6px}
dialog::backdrop{background:#101410a0}
dialog h2,dialog p,dialog .fields{margin-bottom:10px}
dialog .fields{grid-template-columns:repeat(3,minmax(0,1fr))}
.dialog-head{display:flex;justify-content:space-between;align-items:center;gap:6px}
.icon{width:40px;height:40px;border:0;background:transparent;font-size:23px}
.score-field{margin-top:17px}
#notice{position:fixed;bottom:18px;right:18px;max-width:min(400px,calc(100% - 36px));z-index:5;background:#20261b;color:white;padding:10px 14px;border-radius:4px}
#notice:empty{display:none}
.sponsors{display:flex;align-items:center;gap:20px;flex-wrap:wrap;padding:14px 0;font-size:14px}
.sponsors>div{min-width:0}
.sponsors span{display:block;font-size:10px;font-weight:bold;margin-bottom:4px;color:var(--muted)}
.sponsors img{max-width:145px;max-height:40px;object-fit:contain;background:white}
.power{margin-left:auto}
body[data-view="tv"]{background:#121613;color:#fff}
.tv{min-height:100dvh;padding:24px min(4%,60px);display:flex;flex-direction:column;gap:16px}
.tv-head{display:flex;justify-content:space-between;align-items:center;gap:12px;border-bottom:1px solid #414940;padding-bottom:12px}
.tv h1{font-size:32px;margin-top:4px}
.tv .eyebrow{color:var(--accent)}
.tv-courts{display:grid;grid-template-columns:repeat(auto-fit,minmax(min(100%,225px),1fr));gap:10px}
.tv-courts article{background:#1e251e;padding:14px;border-top:3px solid var(--accent);min-width:0}
.tv-courts h3{font-size:24px;margin-bottom:12px}
.tv-courts strong,.tv-courts b{display:block;font-size:17px;margin:6px 0 12px;overflow-wrap:anywhere}
.tv-courts article>p:last-child{font-size:14px}
.tv .sponsors{margin-top:auto;border-top:1px solid #414940}
.tv .sponsors span{color:#b6c4b5}
.tv-result{display:flex;align-items:center;gap:10px 16px;flex-wrap:wrap;border-block:1px solid #414940;padding:12px 0}
.tv-clubhouse .division{color:#181b18;background:#ecf0e6;padding:10px}
.draw-tv{flex:1;display:grid;align-items:center;grid-template-columns:minmax(0,350px) minmax(0,600px);justify-content:center;gap:35px}
.draw-tv h2{font-size:52px;margin:8px 0}
.wheel-shell{position:relative}
.wheel-shell::after{content:"";position:absolute;right:-10px;top:calc(50% - 14px);border-right:23px solid white;border-block:14px solid transparent}
.wheel{aspect-ratio:1;border-radius:50%;border:5px solid #f3f5ee;display:grid;place-items:center;background:repeating-conic-gradient(#e7e7e7 0deg 14.4deg,#303030 14.4deg 28.8deg,#fafafa 28.8deg 43.2deg,#777 43.2deg 57.6deg,#212121 57.6deg 72deg)}
.wheel img{width:28%;border-radius:50%;border:3px solid white}
.spinning{animation:spin 3.2s cubic-bezier(.12,.76,.31,1) both}
@keyframes spin{from{transform:rotate(0)}to{transform:rotate(1654deg)}}
@media(prefers-reduced-motion:reduce){.spinning{animation:none}}
.welcome{max-width:620px;margin:48px auto}.welcome img{width:52px;height:52px;object-fit:contain;margin-bottom:14px}
.category-row{display:flex;gap:8px;align-items:end;flex-wrap:wrap;margin-top:14px}.category-row label{flex:1 1 240px}.category-row .error{flex-basis:100%;margin:0}
#connection{margin:0;padding:10px;text-align:center;background:#ffe9b4;color:#221b0e}
@media(max-width:760px){
 .top{gap:10px;padding:8px 12px}.environment{display:none}.top-links{gap:8px}.top-links a:first-child{font-size:12px}
 .wrap{width:calc(100% - 24px)}.event-head{align-items:start;flex-direction:column;padding:22px 0 15px}
 h1{font-size:34px}h2{font-size:22px}.event-counts{gap:10px}.event-counts b{font-size:22px}
 .section-head{align-items:start;flex-wrap:wrap}.tabs button{padding-inline:11px}
 .groups{grid-template-columns:1fr}.bracket{grid-template-columns:1fr}.raffle-desk{grid-template-columns:1fr}
 .winner-list{border-left:0;padding-left:0}.tv{padding:14px}.tv h1{font-size:25px}
 .draw-tv{grid-template-columns:1fr;text-align:center;gap:14px}.draw-tv h2{font-size:35px}.wheel-shell{width:min(62%,245px);margin:auto}
}
