@font-face{font-family:'Sebang Broadcast';src:local('SEBANG Gothic Bold'),url('assets/SEBANGbold.ttf') format('truetype');font-weight:700;font-style:normal;font-display:swap}
@font-face{font-family:'Tournament KBL Court';src:url('assets/KBLCourt-EB.woff') format('woff');font-weight:800;font-display:swap}
.overlay{font-family:'Sebang Broadcast','Malgun Gothic',sans-serif;font-weight:700}
.overlay .stage-title:before{display:none}

.overlay .stage-title h1{font-family:'Tournament KBL Court',sans-serif;font-weight:800;font-size:80.5px;line-height:1.2;letter-spacing:2px;background:none;color:#f5faff;-webkit-text-stroke:0;filter:none;text-shadow:0 2px 3px #000b,0 0 8px #ed927ecc,0 0 20px #ed927e99,0 0 40px #ed927e66}
.overlay .stage-title p{font-family:'Tournament KBL Court',sans-serif;font-weight:800;font-size:27.6px;line-height:1.4;letter-spacing:5px;background:none;color:#ed927e;-webkit-text-stroke:0;filter:none;text-shadow:0 1px 2px #000a;display:flex;align-items:center;justify-content:center;gap:20px;margin:7px auto 0;max-width:1400px}
.overlay .stage-title p:not(:empty):before,.overlay .stage-title p:not(:empty):after{content:'';flex:0 0 64px;height:1px;background:linear-gradient(90deg,transparent,#ed927e66)}
.overlay .stage-title p:not(:empty):after{transform:scaleX(-1)}
.overlay .stage-title p:empty{display:none}

.overlay .swiss-stage .stage-title h1{font-size:56.35px!important}

/* Sebang Bold's visible glyphs sit high inside its line box. */
.overlay .slot .name{position:relative;top:.07em;line-height:1.15}
/* Broadcast non-final knockout: adjust only the upper player's name. */
.overlay #stage:not(.swiss-stage):not(.double-stage) .match-card:not(.final)>.slot:first-child:not(.empty) .name{translate:0 -1px}
.overlay .slot .score-value{padding-top:.14em;line-height:1.15}
.overlay .round-label{padding-top:2px}
.overlay .champion strong{position:relative;top:2px}
.overlay .champion strong,.overlay .slot,.overlay .round-label{font-weight:700;font-synthesis:none}
.admin #stage:not(.swiss-stage):not(.double-stage) .match-card .slot,.overlay #stage:not(.swiss-stage):not(.double-stage) .match-card .slot{height:var(--row-height);font-size:var(--player-font)}
.admin #stage:not(.swiss-stage):not(.double-stage) .match-card .slot.empty,.overlay #stage:not(.swiss-stage):not(.double-stage) .match-card .slot.empty{font-size:calc(var(--player-font) * .72);letter-spacing:2px}
.overlay #stage:not(.swiss-stage):not(.double-stage) .score-value{font-size:var(--player-font)!important;width:36px;flex-basis:36px}
.overlay #stage:not(.swiss-stage):not(.double-stage) .slot[data-race]:not(.lose):after{right:35px}
.admin #stage:not(.swiss-stage):not(.double-stage) .score-value{width:32px;flex-basis:32px;font-size:calc(var(--player-font) * .9)}
#score-popover{width:190px;padding:8px;font-size:11px;border-radius:6px}
.score-pop-title{margin-bottom:5px;font-size:11px}.score-pop-title button{height:21px;font-size:14px;padding:0 5px}
.score-pop-row{grid-template-columns:minmax(0,1fr) 34px 28px;gap:6px;margin:4px 0}
.score-pop-row .inline-score{appearance:textfield;background:#111b24;color:#e6f2fa;border:1px solid #455b6c;border-radius:4px;text-align:center;padding:0}
.score-pop-row .inline-score::-webkit-inner-spin-button,.score-pop-row .inline-score::-webkit-outer-spin-button{-webkit-appearance:none;margin:0}
.score-pop-row button{height:25px;font-size:11px}.score-pop-row .inline-score{height:25px;font-size:14px}
.score-pop-actions{margin-top:6px;padding-top:6px;gap:4px}.score-pop-actions button{padding:3px 7px;font-size:11px}
#confirm-dialog{position:fixed;inset:0;margin:auto;width:420px;max-width:calc(100vw - 32px);padding:24px;border:1px solid #70889b;background:#1c252e;color:#e7eef5;box-shadow:0 20px 80px #0008}
#confirm-dialog p{line-height:1.7;white-space:pre-line;color:#bdcbd8}#confirm-dialog .dialog-actions{justify-content:flex-end}#confirm-dialog::backdrop{background:#050a10b8}
/* Compact horizontal score controls. */
/* Draw small +/- icons geometrically, independent of font baselines. */
#add-player button[type=submit],#score-popover [data-step]{position:relative;font-size:0;line-height:1}
#add-player button[type=submit]::before,#score-popover [data-step]::before{content:'';position:absolute;left:50%;top:50%;width:10px;height:2px;background:currentColor;transform:translate(-50%,-50%);pointer-events:none}
#add-player button[type=submit]::after,#score-popover [data-step$=",1"]::after{content:'';position:absolute;left:50%;top:50%;width:2px;height:10px;background:currentColor;transform:translate(-50%,-50%);pointer-events:none}
/* Controller dialogs share a single content edge and control height. */
.admin dialog{padding:20px;max-width:calc(100vw - 32px);max-height:calc(100dvh - 32px);overflow:auto}
.admin dialog .dialog-actions{gap:8px;align-items:center;justify-content:flex-end;margin-top:16px}
.admin dialog .dialog-actions button{height:34px;min-height:34px;padding:0 10px;white-space:nowrap}
.admin dialog input,.admin dialog select{height:36px;padding:0 9px;vertical-align:middle}
.admin #edit-player{display:grid;grid-template-columns:minmax(0,1fr) 48px;gap:8px}
.admin #edit-player h2{grid-column:1/-1;margin:0 0 6px}
.admin #edit-player>#edit-name,.admin #edit-player>#edit-race{width:100%;margin:0}
.admin #edit-player .dialog-actions{grid-column:1/-1;margin-top:8px}
.admin #format-form>label{gap:12px}
.admin #format-form select,.admin #format-form input{max-width:60%;min-width:0}
.admin .format-presets button{height:34px;min-width:0;padding:0 4px}
.admin .bulk-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
.admin .bulk-grid textarea{min-width:0;display:block}
@media(max-width:520px){.admin .bulk-grid{grid-template-columns:repeat(2,minmax(0,1fr))}}
/* Swiss cards have shorter rows; center Sebang glyphs without moving borders. */
.overlay .swiss-card .slot{height:31px!important;padding-left:7px;align-items:center}
.overlay .swiss-card .slot .race{position:relative;top:-1px;transform:none;align-self:center;margin-top:0;margin-bottom:0}
.admin #stage:not(.swiss-stage):not(.double-stage) .slot:not(.empty) .name,.overlay #stage:not(.swiss-stage):not(.double-stage) .slot:not(.empty) .name{font-size:calc(var(--player-font) * .9)}
.overlay .swiss-card .slot .name{top:1px;line-height:1}
.overlay .swiss-card .slot:nth-child(2) .name{top:2px}
.admin .ko-win{flex:0 0 24px;width:24px;height:25px;padding:0;margin:0 3px 0 0;font-size:12px;background:#304b62;border:1px solid #516b80;border-radius:4px}
.admin .ko-win:hover{background:#456c88;border-color:#9cdcff}
.overlay .swiss-card .slot .score-value{font-size:18px!important;line-height:1;padding-top:4px;padding-bottom:0}
#score-popover{width:184px;padding:6px}
.score-pop-row{grid-template-columns:minmax(0,1fr) 26px 20px 20px 23px;gap:3px;margin:3px 0}
.score-pop-row>span{min-width:0;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;font-size:10px}
.score-pop-row button{padding:0;height:23px;font-size:11px}
.score-pop-row .inline-score{height:23px;font-size:12px}
.score-pop-actions{margin-top:4px;padding-top:4px;gap:3px}.score-pop-actions button{padding:2px 6px;font-size:10px}



/* Broadcast is a non-interactive display; do not affect controller dragging. */
.overlay,.overlay *{user-select:none;-webkit-user-select:none;-webkit-user-drag:none}


