.schedule-page{max-width:1060px;padding-top:12px;padding-bottom:24px}
.schedule-page [hidden]{display:none!important}
.schedule-panel{background:#fff;border-radius:18px;padding:18px;box-shadow:var(--shadow-soft);margin-bottom:10px}
.schedule-kicker{font-size:9px;font-weight:950;color:var(--orange);letter-spacing:1.2px;text-transform:uppercase}
.schedule-page h1{margin:7px 0;font-size:27px;line-height:1.1;letter-spacing:-.6px}
.schedule-description{font-size:12px;line-height:1.5;color:var(--grey);margin:8px 0}
.schedule-facts{display:flex;flex-wrap:wrap;gap:6px;margin:12px 0}
.schedule-fact{padding:7px 10px;border-radius:999px;background:#f4f4f4;font-size:11px;font-weight:850}
.schedule-state{padding:10px 12px;border-radius:12px;background:var(--blue-light);color:#155f75;font-size:11px;line-height:1.45}
.schedule-state.error{background:#ffe3de;color:#942814}
.schedule-tabs{display:grid;grid-template-columns:1fr 1fr;gap:6px;background:#eee9df;border-radius:14px;padding:5px;margin-bottom:12px}
.schedule-tab{min-height:46px;border:0;border-radius:10px;background:transparent;color:#65605a;font-size:12px;font-weight:900;cursor:pointer}
.schedule-tab[aria-selected="true"]{background:#101010;color:white;box-shadow:0 3px 8px #0002}
.schedule-page :focus-visible{outline:3px solid #147b9a;outline-offset:3px}
.schedule-panel h2{font-size:17px;line-height:1.2;margin:0 0 7px}
.schedule-legend{display:flex;flex-wrap:wrap;gap:8px;margin-top:12px;font-size:10px;font-weight:850}
.court-label{display:inline-flex;align-items:center;gap:5px}
.court-label:before{content:'';width:7px;height:7px;border-radius:50%;background:#14819d;flex-shrink:0}
.court-label.court-1:before{background:#b44370}
.schedule-scroll{overflow-x:auto;padding:3px 3px 12px;overscroll-behavior-x:contain}
.schedule-tree{min-width:940px;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:24px}
.schedule-tree.consolation{min-width:620px;grid-template-columns:repeat(2,minmax(0,1fr))}
.schedule-round{display:flex;flex-direction:column;min-width:0}
.schedule-round h3{font-size:10px;letter-spacing:.8px;text-transform:uppercase;color:#73777a;margin:10px 0 13px}
.schedule-round-body{display:grid;gap:16px;flex:1;position:relative}
.schedule-round-body.quarters{grid-template-rows:repeat(4,1fr)}
.schedule-round-body.semis{grid-template-rows:repeat(2,1fr)}
.schedule-round-body.finals{grid-template-rows:1fr 1fr}
.schedule-tree .schedule-round:not(:first-child) .match-card{align-self:center;position:relative}
.schedule-tree .schedule-round:not(:first-child) .match-card:before{content:'';position:absolute;width:24px;left:-25px;top:50%;border-top:2px solid #ddd}
.match-card{min-width:0;border:1px solid #e6e8e9;border-top:3px solid #14819d;border-radius:12px;background:#fff;padding:11px;box-shadow:0 3px 10px #00000006}
.match-card.court-1{border-top-color:#b44370}
.match-card.highlight{background:#fffaf0;border-color:#e4ba58}
.match-meta{display:flex;align-items:baseline;justify-content:space-between;gap:8px;margin-bottom:5px}
.match-id{font-size:10px;font-weight:950;color:#74797e}
.match-time{font-size:13px;font-weight:950;white-space:nowrap}
.match-card h4{font-size:12px;margin:7px 0 10px;line-height:1.3}
.match-court{font-size:9px;line-height:1.4;color:#62696d;font-weight:800}
.match-team{display:flex;align-items:center;gap:6px;padding:8px 0;font-size:12px;line-height:1.3;min-height:43px}
.match-team+.match-team{border-top:1px solid #eee}
.match-team.pending{color:#80878b;font-style:italic}
.match-team strong{font-weight:850;overflow-wrap:anywhere}
.match-team small{display:block;font-size:9px;margin-top:3px;color:#85898d;font-weight:600;font-style:normal}
.match-seed{margin-left:auto;flex-shrink:0;font-size:8px;background:#101010;color:white;padding:4px 5px;border-radius:5px;white-space:nowrap}
.schedule-time-group{margin-bottom:18px}
.schedule-time-heading{display:flex;align-items:center;gap:10px;margin:0 0 9px;font-size:18px;letter-spacing:-.4px}
.schedule-time-heading span{font-size:10px;color:#777;font-weight:650;letter-spacing:0}
.schedule-time-heading:after{content:'';height:1px;flex:1;background:#e6e6e6}
.schedule-court-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}
.schedule-actions{display:flex;gap:8px;flex-wrap:wrap}
.schedule-link{padding:12px 16px;min-height:44px;border-radius:12px;background:#101010;color:white;font-size:12px;font-weight:900;display:inline-flex;align-items:center}
.schedule-link.primary{background:var(--orange)}
.schedule-note{background:#fff2c7;color:#6d5200;padding:12px;border-radius:12px;font-size:11px;line-height:1.5;margin:10px 0}
@media(max-width:520px){.schedule-panel{padding:14px}.schedule-page h1{font-size:24px}.schedule-court-grid{grid-template-columns:repeat(2,minmax(0,1fr));gap:6px}.schedule-actions .schedule-link{flex:1;justify-content:center}.schedule-fact{font-size:10px}.schedule-tree{min-width:870px}}
.schedule-tree{position:relative}
.schedule-connections{position:absolute;left:0;top:0;pointer-events:none;overflow:visible}
.schedule-connections path{fill:none;stroke:#c4c9cc;stroke-width:1.5}
.schedule-round{position:relative;z-index:1}
.schedule-tree .schedule-round:not(:first-child) .match-card:before{display:none}

/* Court colours stay consistent in both views. */
.visually-hidden:not(.error){position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
.match-card.court-0{background:#ffe1dd;border-color:#d94232;border-top-color:#d94232}
.match-card.court-1{background:#fff2ad;border-color:#d6af22;border-top-color:#d6af22}
.match-card.highlight{box-shadow:0 0 0 2px #101010}
.match-court,.match-id,.match-team.pending,.match-team small{color:#51483d}
.match-team+.match-team{border-top-color:#0002}
.court-label:before{display:none}
.schedule-court-grid .match-card{grid-column:var(--court-column)}
@media(max-width:520px){
 #panelChronologique{padding:10px}
 .schedule-court-grid .match-card{padding:8px;border-radius:10px}
 .schedule-court-grid .match-time{font-size:11px}
 .schedule-court-grid .match-id{font-size:9px}
 .schedule-court-grid .match-court{font-size:10px;min-height:28px;align-items:flex-start}
 .schedule-court-grid .match-card h4{font-size:11px;min-height:29px}
 .schedule-court-grid .match-team{font-size:11px;align-items:flex-start;flex-wrap:wrap;gap:3px}
 .schedule-court-grid .match-team small{font-size:9px;overflow-wrap:anywhere}
 .schedule-court-grid .match-seed{margin-left:0}
 .schedule-court-grid .match-meta{gap:3px}
}
/* Compact cards shared by the tree and chronological view. */
.match-card{padding:8px}
.match-meta{gap:4px;margin-bottom:4px}
.match-id{font-size:9px;line-height:1.25;font-weight:800}
.match-time{font-size:11px}
.match-court{font-size:9px;line-height:1.25;margin-bottom:4px}
.match-team{padding:5px 0;min-height:29px;font-size:11px;gap:4px}
.match-team>div{min-width:0;flex:1}
.match-seed{font-size:7px;padding:3px 4px}
@media(max-width:700px){
 .schedule-tree{min-width:0;width:calc(150% + 6px);grid-template-columns:repeat(3,minmax(0,1fr));gap:12px}
 .schedule-tree.consolation{min-width:0;width:100%;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
 .schedule-round h3{font-size:9px;letter-spacing:.2px;margin:6px 0 9px}
 .schedule-round-body{gap:10px}
 .schedule-tree .match-card{padding:6px;border-radius:9px}
 .schedule-tree .match-meta{gap:3px}
 .schedule-tree .match-id{font-size:8px}
 .schedule-tree .match-time{font-size:10px}
 .schedule-tree .match-court{font-size:9px;min-height:23px}
 .schedule-tree .match-team{font-size:10px;min-height:28px;flex-wrap:wrap}
 .schedule-court-grid .match-court{font-size:9px;min-height:0}
 .schedule-court-grid .match-team{min-height:29px;padding:5px 0;flex-wrap:nowrap;align-items:center}
 .schedule-court-grid .match-seed{margin-left:auto}
}
.match-team.winner strong{font-weight:1000}
.match-team.winner strong:after{content:' ✓';color:#176533}
.match-score{font-size:9px;font-weight:850;margin-top:5px;border-top:1px solid #0002;padding-top:5px;line-height:1.4}
.results-grid{display:grid;grid-template-columns:1fr;gap:12px}
.score-card{background:#fff;border:1px solid #ddd;border-radius:14px;padding:14px}
.score-card.court-0{border-top:4px solid #d94232;background:#fff5f3}
.score-card.court-1{border-top:4px solid #d6af22;background:#fffbea}
.score-card-head{display:flex;justify-content:space-between;gap:10px;font-size:13px}
.score-card-head span{white-space:nowrap;font-weight:900}
.current-set{font-size:12px;font-weight:850;margin:10px 0}
.set-history{display:flex;flex-wrap:wrap;gap:5px;margin:8px 0}
.set-chip{padding:5px 8px;background:#fff;border:1px solid #ddd;border-radius:7px;font-size:11px;font-weight:850}
.score-team-row{display:flex;align-items:center;justify-content:space-between;gap:8px;min-height:54px;border-top:1px solid #0001}
.score-team-row>strong{min-width:0;overflow-wrap:anywhere;font-size:13px;line-height:1.3}
.score-stepper{display:flex;gap:5px;align-items:center;flex-shrink:0}
.score-stepper button{width:42px;height:42px;border:1px solid #bbb;border-radius:10px;background:white;font-size:24px;font-weight:800;cursor:pointer}
.score-stepper output{min-width:27px;text-align:center;font-size:22px;font-weight:950}
.score-actions{display:flex;gap:7px;flex-wrap:wrap;margin-top:10px}
.score-button{min-height:42px;padding:9px 12px;border:0;border-radius:10px;background:#101010;color:white;font-size:12px;font-weight:850;cursor:pointer}
.score-button.secondary{background:#eee;color:#333}
.score-card button:disabled,.score-dialog button:disabled{opacity:.4;cursor:not-allowed}
#scoreNotice{font-size:12px;line-height:1.5;margin:7px 0 0;color:#586b59}
#scoreNotice.error,#scoreDialogError{color:#a42d23}
.score-dialog{border:0;border-radius:20px;padding:22px;max-width:430px;width:calc(100% - 28px);color:#101010;box-shadow:0 18px 50px #0004}
.score-dialog::backdrop{background:#0008}
.score-dialog h2{font-size:21px;margin:0 0 12px}
.score-dialog p{font-size:13px;line-height:1.5}
.score-dialog .score-winner{font-size:22px;font-weight:950}
.score-summary{display:block;font-size:22px;margin:14px 0}
@media(min-width:760px){.results-grid{grid-template-columns:1fr 1fr}}
@media(max-width:350px){.score-card{padding:10px}.score-stepper{gap:3px}.score-stepper button{width:36px;height:42px}.score-stepper output{min-width:23px}.score-team-row>strong{font-size:12px}}

.planning-controls{display:flex;justify-content:space-between;gap:4px;margin-top:7px;border-top:1px solid #0002;padding-top:6px}
.planning-controls button{min-width:0;flex:1;height:36px;border:1px solid #0002;border-radius:8px;background:#fffc;color:#161616;font-size:21px;cursor:pointer}
.planning-controls button:disabled{opacity:.28;cursor:not-allowed}
.planning-controls button:focus-visible{outline:3px solid #101010;outline-offset:2px}
#planningNotice{font-size:11px;line-height:1.5;color:#526552;margin:8px 0 14px}
#planningNotice.error{color:#a42d23}

.score-button.reset-score{margin-top:10px;background:#fff;color:#9d2b22;border:1px solid #c98c85;font-size:11px}

.results-section{margin:18px 0 24px}
.results-section>h2{display:flex;align-items:center;gap:8px;font-size:18px;margin:0 0 12px}
.results-section>h2 span{font-size:12px;padding:4px 8px;border-radius:20px;background:#eee;color:#555}
.results-empty{font-size:12px;color:#70757a;padding:14px;background:white;border-radius:12px}
