.match-editor{width:min(1720px,98vw)}.match-top{display:flex;align-items:center;justify-content:space-between;gap:20px}.match-live-score{display:flex;align-items:center;gap:20px;font-size:16px}.match-live-score b{font-size:34px;padding:8px}.match-sides{display:grid;grid-template-columns:1fr 1fr;gap:16px}.match-side{min-width:0;border:1px solid #d7e3d9;border-radius:10px;overflow:hidden}.match-side h3{margin:0;padding:15px;background:#e7f3eb}.match-side:nth-child(2) h3{background:#edf1f8}.match-roster-scroll{overflow:auto;max-height:52vh}.match-editor table{width:100%;border-collapse:collapse}.match-editor th{position:sticky;top:0;background:#f5f8f5;padding:8px 4px;z-index:1;font-size:14px}.match-editor td{padding:6px 3px;border-bottom:1px solid #e8eee9;vertical-align:top}.match-editor td:first-child{min-width:132px;max-width:170px}.match-editor td label,.match-editor th label{display:flex;align-items:center;gap:5px}.match-editor td small{display:block;font-size:8px;color:#718277}.match-editor td input[type=number]{width:38px;min-height:30px;padding:2px;margin:0;border-radius:4px;font-size:12px;appearance:textfield}.match-editor td input[type=number]::-webkit-inner-spin-button{appearance:none}.match-editor td select{width:84px;font-size:10px;padding:4px;margin:0;min-height:30px}.match-editor td input[data-note]{width:126px;min-height:24px;font-size:10px;padding:3px;margin:5px 0 0}.match-editor td output{display:block;padding:6px;text-align:center}.match-editor [hidden]{display:none!important}.match-editor .match-goal{display:flex;justify-content:space-between;align-items:center;gap:16px;padding:8px 12px;background:#f0f5f1;margin:6px 0;border-radius:6px}.match-goal label{min-width:180px}.match-goal select{margin:4px 0}.match-legacy{background:#fff2c7;padding:12px}.tactical-layout{display:grid;grid-template-columns:180px minmax(280px,620px) 180px;justify-content:center;gap:12px}.tactical-pitch{position:relative;aspect-ratio:0.67;background:repeating-linear-gradient(0deg,#20693d 0%,#20693d 10%,#257745 10%,#257745 20%);border:3px solid #fff;outline:2px solid #267449;border-radius:3px;margin:12px 2px}.pitch-half{position:absolute;top:50%;left:0;width:100%;border-top:2px solid #ffffffb0}.pitch-circle{position:absolute;left:34%;top:39%;width:32%;height:22%;border:2px solid #ffffffb0;border-radius:50%}.pitch-box{position:absolute;left:20%;width:60%;height:16%;border:2px solid #ffffffb0}.pitch-box.top{top:0}.pitch-box.bottom{bottom:0}.pitch-goal{position:absolute;left:36%;width:28%;height:6%;border:2px solid #ffffffb0}.pitch-goal.top{top:0}.pitch-goal.bottom{bottom:0}.pitch-watermark{position:absolute;left:28%;width:44%;height:28%;object-fit:contain;opacity:.12;pointer-events:none}.pitch-watermark.top{top:12%}.pitch-watermark.bottom{bottom:12%}.pitch-team{position:absolute;left:6px;font-size:10px;color:#ffffffa0}.pitch-team.top{top:3px}.pitch-team.bottom{bottom:3px}.tactical-player{display:flex;flex-direction:column;align-items:center;gap:2px;width:82px;border:0;background:transparent;padding:0;color:#fff;touch-action:none;cursor:grab;user-select:none}.tactical-pitch>.tactical-player{position:absolute;transform:translate(-50%,-50%);z-index:2}.player-photo{width:46px;height:46px;border:3px solid #e6f28e;border-radius:50%;background:#204530;display:grid;place-items:center;overflow:hidden;font-weight:bold;box-shadow:0 2px 6px #0005}.side-b .player-photo{border-color:#aad0ff;background:#29445d}.player-photo img{width:100%;height:100%;object-fit:cover;pointer-events:none}.player-name{max-width:94px;font-size:9px;background:#102d23de;padding:3px;border-radius:3px;line-height:1.2}.player-name b{color:#e6f28e}.tactical-bench{background:#f0f4f0;border-radius:10px;padding:12px;min-height:180px}.tactical-bench h3{font-size:12px}.tactical-bench [data-slots]{display:flex;flex-wrap:wrap;gap:10px;align-content:start}.tactical-bench .tactical-player{width:65px}.tactical-player:focus-visible{outline:3px solid #ffdb50;border-radius:8px}.tactical-dialog{width:min(1120px,98vw)}@media(max-width:1100px){.match-sides{grid-template-columns:1fr}.tactical-layout{grid-template-columns:110px minmax(240px,520px) 110px}.tactical-bench{padding:6px}}@media(max-width:650px){.match-top{flex-wrap:wrap;gap:8px}.match-live-score{font-size:12px;gap:4px}.match-live-score b{font-size:25px}.match-goal{flex-direction:column;align-items:stretch!important}.tactical-layout{grid-template-columns:1fr 1fr}.tactical-pitch{grid-column:1/-1;grid-row:1}.tactical-bench{grid-row:2}.player-photo{width:36px;height:36px}.tactical-player{width:65px}.player-name{font-size:8px}}
.match-editor td:first-child span{overflow-wrap:anywhere}.tactical-bench [data-slots]{min-height:90px}.tactical-bench [data-slots]:empty::after{content:'Arraste atletas para cá';font-size:11px;color:#718277}

/* Controle de campo, cronômetro e operação offline. */
.match-editor .match-top{display:grid;grid-template-columns:minmax(180px,1fr) minmax(360px,1.6fr) minmax(180px,1fr);align-items:center;gap:20px}
.match-editor .match-control{grid-column:2;text-align:center}
.match-editor .match-live-score{display:grid;grid-template-columns:1fr auto 1fr;align-items:center;gap:16px}
.match-editor .match-live-score span:first-child{text-align:right}.match-editor .match-live-score span:last-child{text-align:left}
.match-editor [data-clock]{font-variant-numeric:tabular-nums;font-size:34px;line-height:1;color:#fff;background:#087a48;border:1px solid #42d68f;border-radius:10px;padding:8px 16px;min-width:135px}
.match-editor [data-clock].time-up{color:#fff2b5;background:#9a381f;border-color:#ff7c55}
.match-clock-controls{display:flex;justify-content:center;align-items:end;gap:8px;margin-top:8px}.match-clock-controls label{font-size:10px;text-align:left}.match-clock-controls input{width:72px;margin:2px 0 0}
.clock-button{min-width:48px;min-height:40px;border:1px solid #35c980;border-radius:8px;background:#0a8d52;color:#fff;font-weight:900;font-size:18px}.match-control>small{display:block;margin-top:6px}
.match-period{display:flex;align-items:end;justify-content:center;gap:16px;margin-bottom:8px}.match-period>b{color:#f0bd55;letter-spacing:.08em}.match-period label{display:grid;text-align:left;font-size:10px}.match-period input{width:76px;margin:2px 0 0}.match-clock-pair{display:grid;grid-template-columns:1fr 1fr;gap:8px}.match-clock-pair>span{display:grid;gap:3px}.match-clock-pair small{font-size:8px;color:#abc2d8}.match-clock-pair strong{font-variant-numeric:tabular-nums;font-size:28px;line-height:1;color:#fff;background:#087a48;border:1px solid #42d68f;border-radius:10px;padding:8px 12px;min-width:118px}.match-clock-pair strong.time-up{color:#fff2b5;background:#9a381f;border-color:#ff7c55}.clock-effective{display:block;color:#dceaf6;margin:7px 0 0}.clock-button.pause{background:#a76d0b;border-color:#f0bd55}.clock-button:disabled,.stop-button:disabled{opacity:.42;cursor:not-allowed}.stop-button{min-height:40px;padding:0 14px;border:1px solid #ff816d;border-radius:8px;background:#9d2e25;color:#fff;font-weight:800}.clock-period-history{display:flex;justify-content:center;gap:8px;flex-wrap:wrap;margin-top:8px}.clock-period-history span{padding:5px 8px;border:1px solid #315a7d;border-radius:7px;color:#c8d8e7;font-size:9px}.lineup-events-head{display:flex;align-items:center;justify-content:space-between;gap:12px}.lineup-events-head h3{margin:0}
.match-help{position:relative;margin:8px 0}.match-help summary{display:grid;place-items:center;width:32px;height:32px;border:1px solid #4e9b77;border-radius:50%;cursor:pointer;font-weight:900;color:#fff;background:#0b5c3a;list-style:none}.match-help summary::-webkit-details-marker{display:none}.match-help p{margin:8px 0;padding:10px;border:1px solid #355d4b;border-radius:8px}
.offline-match-bar{display:flex;align-items:center;justify-content:flex-end;gap:8px;flex-wrap:wrap;margin:8px 0 12px}.offline-match-bar [data-connectivity]{margin-right:auto;font-size:12px}.file-button{display:inline-flex;align-items:center;cursor:pointer}.file-button input{position:absolute;width:1px;height:1px;opacity:0;pointer-events:none}
.own-goal-dot{display:inline-block;width:.8em;height:.8em;border-radius:50%;background:#e22f3d;border:1px solid #fff;box-shadow:0 0 0 1px #9d1420;vertical-align:middle}
.guest-suggestions button small{display:block;margin-top:2px}
@media(max-width:1100px){.match-editor .match-top{grid-template-columns:1fr}.match-editor .match-date-guest,.match-editor .match-control{grid-column:1}}
@media(max-width:650px){.match-editor .match-live-score{font-size:12px;gap:4px}.match-clock-pair strong{font-size:20px;min-width:88px;padding:7px}.match-clock-controls{flex-wrap:wrap}.match-period{align-items:center;flex-wrap:wrap}.offline-match-bar{align-items:stretch}.offline-match-bar .outline-btn{flex:1}.offline-match-bar [data-connectivity]{flex-basis:100%}}
@media(min-width:651px){.tactical-dialog .tactical-layout{grid-template-columns:150px minmax(240px,min(620px,46vh)) 150px}}

/* Súmula compacta: operação, modo de lançamento e relógio no mesmo bloco. */
.match-editor{width:min(1900px,99vw)}
.match-editor .match-form{display:grid;gap:8px}
.match-utility-row{display:flex;align-items:center;justify-content:space-between;gap:12px;border-bottom:1px solid #244a3a;padding-bottom:7px}
.match-utility-row .offline-match-bar{margin:0;flex:1;justify-content:flex-start}
.match-mode-switch{display:flex;align-items:center;gap:5px;margin:0;padding:3px;border:1px solid #315a4b;border-radius:9px}
.match-mode-switch legend{position:absolute;width:1px;height:1px;overflow:hidden;clip-path:inset(50%)}
.match-mode-switch label{display:flex;align-items:center;gap:5px;margin:0;padding:7px 10px;border-radius:6px;cursor:pointer;font-size:12px;font-weight:800}
.match-mode-switch label:has(input:checked){background:#087a48;color:#fff}
.match-mode-switch input{margin:0;accent-color:#15b76b}
.match-editor .match-top{grid-template-columns:minmax(230px,.8fr) minmax(480px,1.5fr);justify-content:center;gap:12px;margin:0}
.match-editor .match-date-guest{align-self:start;justify-content:flex-start}
.match-editor .match-control{grid-column:2;padding:7px 10px;border:1px solid #315a4b;border-radius:10px;background:#071d31}
.match-editor .match-period{margin-bottom:4px}.match-editor .match-clock-controls{margin-top:5px}
.clock-auto-summary{color:#f2cf75;font-size:10px;margin-top:5px}
.manual-match-control{display:none;align-items:end;justify-content:center;gap:10px;flex-wrap:wrap}
.manual-match-control label{display:grid;text-align:left;font-size:10px}.manual-match-control select{margin:2px 0 0;min-width:120px}
.manual-match-control small{flex-basis:100%;color:#abc2d8}
.manual-match-control .lineup-correction-ready{background:#9a6510;border-color:#f0bd55;color:#fff}
.mode-manual .manual-match-control{display:flex}
.mode-manual .match-clock-pair,.mode-manual .clock-effective,.mode-manual .match-clock-controls,.mode-manual .clock-auto-summary{display:none!important}
.mode-manual .match-period{margin-bottom:6px}
.match-editor .match-help{position:absolute;right:16px;margin:0;z-index:2}
.match-editor .lineup-inline{margin:0 0 8px}.match-editor .lineup-inline>.series-heading{margin-bottom:4px}
.match-editor .lineup-inline>.series-heading h2{font-size:17px}
.match-editor .match-sides{gap:8px}.match-editor .match-side h3{padding:9px 12px}
.match-editor .match-goals h3{margin:3px 0}.match-editor .match-goals>p{margin:3px 0 6px}
@media(max-width:1100px){.match-utility-row{align-items:stretch;flex-direction:column}.match-mode-switch{align-self:flex-start}.match-editor .match-top{grid-template-columns:1fr}.match-editor .match-date-guest,.match-editor .match-control{grid-column:1}}
@media(max-width:650px){.match-mode-switch{width:100%}.match-mode-switch label{flex:1;justify-content:center}.match-editor .match-help{position:relative;right:auto}.match-utility-row .offline-match-bar{width:100%}}

/* Cabeçalho operacional alinhado aos dois quadros de equipe. */
.match-editor .match-top{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:0;align-items:stretch;margin:0 0 -1px}
.match-editor .match-date-guest{grid-column:1;align-self:stretch;align-items:center;justify-content:center;gap:8px;padding:8px 12px;border:1px solid #315a4b;border-right:0;border-radius:10px 0 0 0;background:#071d31}
.match-editor .match-date-guest label{font-size:10px}.match-editor .match-date-guest input{min-height:34px;margin:2px 0 0}
.match-editor .match-control{grid-column:2/4;display:grid;grid-template-columns:1fr 1fr;grid-template-rows:auto auto auto auto;gap:3px 12px;padding:7px 10px;border-radius:0 10px 0 0;text-align:center}
.match-editor .match-period{grid-column:1;grid-row:1;margin:0;align-self:end}
.match-editor .match-live-score{grid-column:1;grid-row:2;display:block}
.match-editor .clock-effective{grid-column:1;grid-row:3;margin:1px 0 0}
.match-editor .match-clock-controls{grid-column:2;grid-row:1/3;align-self:center;justify-content:flex-start;align-items:center;flex-wrap:wrap;margin:0}
.match-editor [data-clock-status]{grid-column:2;grid-row:3;margin:1px 0 0;text-align:left}
.match-editor .clock-auto-summary{grid-column:2;grid-row:4;text-align:left;margin:1px 0 0}
.match-editor .clock-period-history{grid-column:1/3;grid-row:5;margin:3px 0 0}
.match-editor .manual-match-control{grid-column:2;grid-row:1/4;align-self:center}
.match-editor .mode-manual .match-clock-controls{display:flex!important;grid-row:4;justify-content:center}
.match-editor .mode-manual .match-clock-controls>:not(.finalize-button):not(.print-report-button){display:none!important}
.match-editor .mode-manual .manual-match-control{grid-row:1/4}
.match-editor .match-clock-pair{max-width:410px;margin:auto}
.match-editor .match-clock-pair strong{font-size:32px;padding:8px 10px;background:#063b2c;box-shadow:inset 0 0 12px #0008,0 0 10px #22e58533}
.finalize-button{min-height:40px;padding:0 14px;border:1px solid #ff967f;border-radius:8px;background:#b63b2d;color:#fff;font-weight:900;box-shadow:0 0 10px #ff503a33;cursor:pointer}
.finalize-button:hover{background:#d44837}.finalize-button:disabled{opacity:.45;cursor:not-allowed}.bottom-finalize{justify-self:end;margin-top:5px}
.print-report-button{min-height:40px;font-weight:800}
.match-editor .compact-lineup-heading{display:flex;align-items:center;min-height:38px;margin:0;padding:5px 8px;border:1px solid #315a4b;border-bottom:0;background:#071d31}
.match-editor .compact-lineup-heading h2{margin:0}.match-editor .lineup-guest-button{margin-left:auto;min-height:32px;padding:5px 12px}.match-editor .compact-lineup-heading .match-help{position:static;margin:0 0 0 7px}
.match-editor .lineup-inline>.series-heading{margin-bottom:0}.match-editor .lineup-inline{margin-top:0}
@media(max-width:1100px){.match-editor .match-top{grid-template-columns:1fr}.match-editor .match-date-guest{grid-column:1;border-right:1px solid #315a4b;border-radius:10px 10px 0 0}.match-editor .match-control{grid-column:1;border-radius:0}.match-editor .match-clock-controls{justify-content:center}.match-editor [data-clock-status],.match-editor .clock-auto-summary{text-align:center}}
@media(max-width:650px){.match-editor .match-control{grid-template-columns:1fr}.match-editor .match-period,.match-editor .match-live-score,.match-editor .clock-effective,.match-editor .match-clock-controls,.match-editor [data-clock-status],.match-editor .clock-auto-summary,.match-editor .clock-period-history,.match-editor .manual-match-control{grid-column:1}.match-editor .match-period{grid-row:1}.match-editor .match-live-score{grid-row:2}.match-editor .clock-effective{grid-row:3}.match-editor .match-clock-controls,.match-editor .manual-match-control{grid-row:4}.match-editor [data-clock-status]{grid-row:5}.match-editor .clock-auto-summary{grid-row:6}.match-editor .clock-period-history{grid-row:7}.match-editor .match-clock-controls{justify-content:center}.bottom-finalize{justify-self:stretch}.match-editor .lineup-guest-button{font-size:10px;padding:4px 7px}}

@media print{
 @page{size:A4 landscape;margin:8mm}
 html,body{background:#fff!important;color:#111!important;overflow:visible!important}
 body>*:not(dialog.match-editor[open]){display:none!important}
 dialog.match-editor[open]{position:static!important;display:block!important;width:100%!important;max-width:none!important;height:auto!important;max-height:none!important;margin:0!important;padding:0!important;overflow:visible!important;border:0!important;background:#fff!important;color:#111!important;box-shadow:none!important}
 dialog.match-editor::backdrop{display:none!important}
 .match-editor [data-close],.match-editor .match-utility-row,.match-editor .match-clock-controls,.match-editor .manual-match-control,.match-editor .match-help,.match-editor .match-item-tools,.match-editor .lineup-guest-button,.match-editor .bottom-finalize,.match-editor .print-report-button,.match-editor [data-error]{display:none!important}
 .match-editor .match-form{display:block!important}.match-editor .match-top{margin-bottom:4mm!important}.match-editor .match-date-guest,.match-editor .match-control,.match-editor .compact-lineup-heading,.match-editor .tactical-team,.match-editor .match-side,.match-editor .match-goal{print-color-adjust:exact;-webkit-print-color-adjust:exact}
 .match-editor .match-roster-scroll{max-height:none!important;overflow:visible!important}.match-editor .tactical-team,.match-editor .match-side,.match-editor .match-goal{break-inside:avoid}.match-editor .lineup-events{break-inside:avoid}
 .match-editor input,.match-editor select,.match-editor textarea{border:1px solid #aaa!important;color:#111!important;background:#fff!important}
}
.separate-pitches{width:min(1500px,98vw)}.tactical-teams{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:20px}.tactical-team{min-width:0;border:1px solid #d9e3db;border-radius:12px;padding:12px;background:#fafcf9}.tactical-team-heading{display:flex;align-items:center;gap:12px;min-height:62px}.tactical-team-heading img,.crest-placeholder{width:52px;height:52px;object-fit:contain;display:grid;place-items:center}.tactical-team-heading h3{margin:0;font-size:17px}.tactical-team-heading small{color:#617368;font-size:11px}.tactical-team-layout{display:grid;grid-template-columns:minmax(0,1fr) 100px;gap:12px;align-items:stretch}.tactical-team-layout .tactical-bench{margin:12px 0;padding:8px}.separate-pitches .pitch-watermark.own-crest{top:30%;left:20%;width:60%;height:40%;opacity:.14}.tactical-team-layout .tactical-pitch{min-width:0}.tactical-team-layout .tactical-bench [data-slots]{justify-content:center}@media(max-width:1000px){.tactical-teams{grid-template-columns:1fr}.tactical-team-layout{grid-template-columns:minmax(0,1fr) 120px;max-width:650px;margin:auto}}@media(max-width:650px){.tactical-team-layout{grid-template-columns:1fr}.tactical-team-layout .tactical-bench{grid-row:2}.tactical-team-layout .tactical-bench [data-slots]{justify-content:flex-start}.tactical-team{padding:8px}.tactical-team-heading h3{font-size:15px}}
.separate-pitches .tactical-team-heading{height:auto;margin:0;padding:0 0 10px;border:0;min-height:62px}.separate-pitches .tactical-team-layout{padding:0}
@media(min-width:1001px){.separate-pitches .tactical-team-layout{grid-template-columns:minmax(0,min(500px,42vh)) 100px;justify-content:center}}

/* Cabeçalho final compacto e sem sobreposição no lançamento manual. */
.series-dialog.match-editor{padding:12px 14px}
.match-editor>.series-heading{min-height:38px;margin-bottom:7px}
.match-editor>.series-heading h2{font-size:20px;line-height:1.25}
.match-editor .match-utility-row{min-height:42px;padding:4px 0 7px}
.match-editor .mode-manual .match-control{grid-template-columns:minmax(120px,.42fr) minmax(420px,1.58fr);grid-template-rows:auto auto;min-height:106px;align-items:center}
.match-editor .mode-manual .match-period{grid-column:1;grid-row:1/3;align-self:center}
.match-editor .mode-manual .manual-match-control{grid-column:2;grid-row:1;display:grid;grid-template-columns:minmax(130px,180px) auto;align-items:end;justify-content:center;gap:4px 10px}
.match-editor .mode-manual .manual-match-control small{grid-column:1/-1;margin:0;line-height:1.35;text-align:center}
.match-editor .mode-manual .match-clock-controls{grid-column:2;grid-row:2;justify-content:center;align-self:center;margin:2px 0 0}
.match-editor .mode-manual [data-clock-status],.match-editor .mode-manual .clock-period-history{display:none!important}
@media(max-width:1100px){.match-editor .mode-manual .match-control{grid-template-columns:minmax(110px,.38fr) minmax(340px,1.62fr)}}
@media(max-width:650px){.series-dialog.match-editor{padding:10px}.match-editor .mode-manual .match-control{grid-template-columns:1fr;grid-template-rows:auto auto auto}.match-editor .mode-manual .match-period{grid-column:1;grid-row:1}.match-editor .mode-manual .manual-match-control{grid-column:1;grid-row:2;grid-template-columns:1fr}.match-editor .mode-manual .manual-match-control small{grid-column:1}.match-editor .mode-manual .match-clock-controls{grid-column:1;grid-row:3}.match-editor>.series-heading h2{font-size:17px}}
.match-editor .match-save-feedback{position:sticky;top:0;z-index:12;display:flex;gap:12px;align-items:center;justify-content:space-between;padding:12px 16px;border:1px solid #74b9d5;border-radius:8px;background:#e8f5ff;color:#0a3650;box-shadow:0 3px 12px #0002}
.match-editor .match-save-feedback span{white-space:pre-line;font-size:13px;line-height:1.45;font-weight:700}
.match-editor .match-save-feedback[data-state=error]{background:#fff0eb;color:#8a210d;border-color:#f4a18a}
.match-editor .match-save-feedback[data-state=success]{background:#e4f5e9;color:#145c32;border-color:#75c08f}
.match-editor .match-save-feedback button{flex-shrink:0;background:#fff;color:#183328}
.match-editor .is-saving{cursor:progress}
.match-editor .is-saving>:not(.match-save-feedback){pointer-events:none}
.match-editor .is-saving [data-save-final]{opacity:.65;cursor:progress}
.match-editor .match-save-feedback[data-state=saving] span::before{content:"";display:inline-block;width:13px;height:13px;margin-right:9px;border:2px solid currentColor;border-right-color:transparent;border-radius:50%;vertical-align:-2px;animation:match-saving 1s linear infinite}
.match-editor .match-sides.show-validation{display:grid!important}
.match-editor .match-goals.show-validation{display:block!important}
@keyframes match-saving{to{transform:rotate(360deg)}}
@media(max-width:650px){.match-editor .match-save-feedback{flex-direction:column;align-items:stretch;padding:10px}.match-editor .match-save-feedback span{font-size:12px}}
@media(prefers-reduced-motion:reduce){.match-editor .match-save-feedback[data-state=saving] span::before{animation:none}}
@media print{.match-editor .match-save-feedback{display:none!important}}
