/* PitchZone console — the look of the PDB baseball operator console (26baseball dashboard2, read 2026-09-21):
   black header bar (brand · subtitle · badges · tabs), an on-air strip under it, a dark control area with an
   orange top rule, flat 3 px buttons, dark input boxes, a fixed "graphic control" panel at the bottom.
   Type: GmarketSans for Korean, Roboto Condensed for numbers and URLs, Oswald for the big speed figure. */
@font-face { font-family: 'GmarketSansMedium'; src: url('/overlay/static/fonts/GmarketSansMedium.woff') format('woff'); font-weight: normal; font-style: normal; font-display: swap; }
@font-face { font-family: 'GmarketSansBold'; src: url('/overlay/static/fonts/GmarketSansBold.woff') format('woff'); font-weight: 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'Oswald'; font-style: normal; font-weight: 600; src: url('/overlay/static/fonts/Oswald-600.ttf') format('truetype'); font-display: swap; }
@font-face { font-family: 'Oswald'; font-style: normal; font-weight: 700; src: url('/overlay/static/fonts/Oswald-700.ttf') format('truetype'); font-display: swap; }
@font-face { font-family: 'Roboto Condensed'; font-style: normal; font-weight: 700; src: url('/overlay/static/fonts/RobotoCondensed-700.ttf') format('truetype'); font-display: swap; }

:root {
  --theme-mid: #a73b16;
  --theme-bright: #e65724;
  --font-ko: 'GmarketSansMedium', 'Malgun Gothic', 'Apple SD Gothic Neo', sans-serif;
  --font-ko-bold: 'GmarketSansBold', 'Malgun Gothic', 'Apple SD Gothic Neo', sans-serif;
  --font-num: 'Roboto Condensed', 'GmarketSansMedium', sans-serif;
  --font-big: 'Oswald', 'Roboto Condensed', sans-serif;
  --led-on: #00ff41;
  --led-warn: #ffcc00;
  --led-bad: #ff1a1a;
  --led-off: #1a1a1a;
  --bottom-h: 0px;   /* measured height of the fixed bottom panel, set by script */
}
* { box-sizing: border-box; }
html { color-scheme: dark; }
body { margin: 0; background: #111; color: #eee; font-family: var(--font-ko); font-size: 14px; line-height: 1.4; -webkit-font-smoothing: antialiased; }
a { color: #8fc7ff; text-decoration: none; }
a:hover { text-decoration: underline; }
.num { font-family: var(--font-num); font-variant-numeric: tabular-nums; }
[hidden] { display: none !important; }

/* ---- header bar ------------------------------------------------------------------ */
.top-bar { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; padding: 8px 15px; background: #000; color: #b8b8b8; font-size: 16px; border-bottom: 1px solid #333; }
.top-bar .left { display: flex; align-items: center; gap: 10px; min-width: 0; white-space: nowrap; }
.brand { color: #fff; font-family: var(--font-ko-bold); font-size: 20px; font-weight: 700; letter-spacing: .02em; }
.brand-sep { color: #555; }
.subtitle { color: #b8b8b8; font-size: 16px; }
.badge { display: inline-flex; align-items: center; justify-content: center; min-width: 54px; height: 28px; padding: 0 10px 1px; border: 1px solid #a73b16; border-radius: 3px; background: #4a1f13; color: #fff3ec; font-family: var(--font-ko-bold); font-size: 14px; line-height: 1; white-space: nowrap; }
.badge.grey { border-color: #555; background: #222; color: #ccc; }
.presence { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 9px; border: 1px solid #3d5144; border-radius: 3px; background: #172019; color: #a9d9b8; font-size: 14px; line-height: 1; white-space: nowrap; max-width: 320px; overflow: hidden; text-overflow: ellipsis; }
.presence.warn { border-color: #a86a28; background: #2a1d10; color: #ffc16b; }
.presence.bad { border-color: #ff5252; background: #4a1717; color: #fff; }
.header-nav { display: flex; gap: 8px; flex-wrap: wrap; justify-content: flex-end; }
.nav-tab { display: inline-flex; align-items: center; justify-content: center; min-width: 84px; padding: 7px 12px 5px; background: #222; border: 1px solid #444; border-radius: 3px; color: #aaa; font-size: 15px; line-height: 1; white-space: nowrap; cursor: pointer; text-decoration: none; transition: background .15s, color .15s; }
.nav-tab:hover { background: #333; color: #fff; text-decoration: none; }
.nav-tab.active { background: var(--theme-mid); border-color: #ff5722; color: #fff; font-family: var(--font-ko-bold); }
.nav-tab.dim { color: #666; border-style: dashed; }
.nav-tab.dim:hover { color: #aaa; }
.nav-tab.danger { color: #ff9d79; border-color: #7a3a2e; }

/* ---- on-air strip ---------------------------------------------------------------- */
/* one row: every item is a nowrap inline-flex box of the same 28 px height, all centred on the
   same axis (mixed fonts are given explicit line-height so their ink sits on one centre line) */
.onair-strip { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 16px; min-height: 44px; padding: 6px 15px; background: #161616; border-bottom: 1px solid #333; font-size: 15px; line-height: 1; color: #ddd; }
.onair-strip > * { flex: 0 0 auto; }
.onair-big { display: inline-flex; align-items: center; height: 28px; font-family: var(--font-ko-bold); font-size: 20px; color: #fff; white-space: nowrap; }
.onair-item { display: inline-flex; align-items: center; height: 28px; gap: 6px; white-space: nowrap; }
.onair-item .who { color: #bdbdbd; font-size: 14px; }
.onair-item b { color: #fff; font-family: var(--font-num); font-size: 18px; line-height: 28px; font-weight: 700; font-variant-numeric: tabular-nums; }
.onair-item b small { font-size: 13px; color: #bdbdbd; font-family: var(--font-ko); font-weight: normal; margin-left: 2px; }
.onair-speed { display: inline-flex; align-items: center; height: 28px; gap: 6px; color: #ffd21f; font-family: var(--font-big); font-size: 22px; line-height: 28px; font-weight: 700; white-space: nowrap; }
.onair-speed .who, .onair-speed .unit { color: #bdbdbd; font-family: var(--font-ko); font-size: 14px; line-height: 28px; font-weight: normal; }
.onair-speed.idle { color: #8a8a8a; }
.onair-right { display: flex; flex: 1 1 auto; align-items: center; justify-content: flex-end; flex-wrap: wrap; gap: 6px 10px; min-width: 0; margin-left: auto; }
.onair-right > * { flex: 0 0 auto; }
.onair-none { display: inline-flex; align-items: center; height: 28px; }
@media (max-width: 1360px) { .onair-item.opt { display: none; } .nav-tab { min-width: 0; padding: 7px 9px 5px; font-size: 14px; } .header-nav { gap: 5px; } .subtitle { display: none; } }
.onair-none { color: #bdbdbd; font-size: 15px; }
.led { display: inline-flex; align-items: center; height: 28px; gap: 4px; white-space: nowrap; }
.led b { font-family: var(--font-ko); font-size: 15px; font-weight: normal; color: #bdbdbd; margin-right: 3px; }
.led i { display: inline-block; width: 13px; height: 13px; border-radius: 50%; background: var(--led-off); border: 1px solid #555; }
.led i.on { background: var(--led-on); border-color: var(--led-on); box-shadow: 0 0 5px var(--led-on); }
.led i.warn { background: var(--led-warn); border-color: var(--led-warn); box-shadow: 0 0 5px var(--led-warn); }
.led i.bad { background: var(--led-bad); border-color: var(--led-bad); box-shadow: 0 0 5px var(--led-bad); }
.chip { display: inline-flex; align-items: center; gap: 6px; height: 28px; padding: 0 8px; border: 1px solid #444; border-radius: 3px; background: #222; color: #ddd; font-size: 14px; line-height: 1; white-space: nowrap; }
.chip::before { content: ''; flex: 0 0 auto; width: 6px; height: 6px; border-radius: 50%; background: #ff5252; box-shadow: 0 0 5px #ff5252; }
.chip.ok::before { background: #00e676; box-shadow: 0 0 5px #00e676; }
.chip.warn { border-color: #a67c00; background: #3a2e00; color: #ffe58a; }
.chip.warn::before { background: #ffd54f; box-shadow: 0 0 5px #ffd54f; }
.chip.off { color: #999; }
.chip.off::before { background: #444; box-shadow: none; }
.chip.bad { border-color: #ff5252; background: #4a1717; color: #fff; }
.notice-bar { padding: 0 15px; background: #161616; color: #ffbc73; font-size: 14px; line-height: 1.35; }
.notice-bar:not(:empty) { padding: 6px 15px 7px; border-bottom: 1px solid #333; }
.notice-bar.bad { color: #ff8a80; }

/* ---- control area ---------------------------------------------------------------- */
.control-area { background: #1a1a1a; border-top: 4px solid var(--theme-mid); padding: 15px; padding-bottom: calc(15px + var(--bottom-h)); min-height: calc(100vh - 100px); }
.frame { background: #202020; border: 1px solid #333; border-radius: 4px; padding: 10px 12px 12px; min-width: 0; }
.frame-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; flex-wrap: wrap; padding-bottom: 7px; margin-bottom: 9px; border-bottom: 1px solid #333; }
.frame-title { display: flex; align-items: center; gap: 8px; font-family: var(--font-ko-bold); font-size: 15px; color: #fff; white-space: nowrap; }
.frame-title .id { color: #8a8a8a; font-family: var(--font-num); font-size: 13px; font-weight: 400; }
.frame-title .sub { color: #999; font-family: var(--font-ko); font-size: 13px; }
.section-label { font-size: 14px; color: #b8b8b8; font-family: var(--font-ko-bold); margin: 0 0 4px; display: flex; justify-content: space-between; align-items: center; }
.grid-2 { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
@media (max-width: 980px) { .grid-2 { grid-template-columns: 1fr; } }
.stack { display: flex; flex-direction: column; gap: 12px; min-width: 0; }

.kv { display: grid; grid-template-columns: 86px minmax(0, 1fr); gap: 6px 10px; align-items: center; font-size: 14px; }
.kv > b { color: #b8b8b8; font-family: var(--font-ko-bold); font-weight: 400; white-space: nowrap; }
.kv > span, .kv > div { min-width: 0; }
.kv > span.num { color: #eee; }
.urlbox { display: flex; align-items: center; gap: 6px; min-width: 0; }
.urlbox .url { flex: 1; min-width: 0; height: 30px; display: flex; align-items: center; padding: 0 9px; border: 1px solid #494949; border-radius: 3px; background: #0f0f0f; color: #fff; font-family: var(--font-num); font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.urlbox .url.dim { color: #8a8a8a; }
.stats { color: #aaa; font-size: 13px; margin-top: 8px; line-height: 1.6; }
.stats b { color: #eee; font-family: var(--font-num); font-weight: 700; font-variant-numeric: tabular-nums; }
.hint { color: #aaa; font-size: 13px; line-height: 1.55; }
.hint b { color: #ddd; }
.empty { color: #8a8a8a; font-size: 13.5px; }
.row { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.button-pair { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:8px; }
.button-pair > .btn { width:100%; min-width:0; min-height:36px; }
.practice-select { display:block; width:100%; max-width:100%; margin:12px 0 8px; }

/* ---- buttons --------------------------------------------------------------------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 5px; padding: 6px 12px 5px; border: 1px solid #555; border-radius: 3px; background: #2b2b2b; color: #ddd; font-family: var(--font-ko); font-size: 14px; line-height: 1.15; white-space: nowrap; cursor: pointer; text-decoration: none; transition: background .12s, border-color .12s, color .12s; }
.btn:hover { background: #353535; border-color: #777; color: #fff; text-decoration: none; }
.btn:active { transform: translateY(1px); }
.btn:focus-visible { outline: 2px solid var(--theme-mid); outline-offset: 1px; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn.sm { padding: 4px 8px 3px; font-size: 13px; }
.btn.accent { background: linear-gradient(#c64b1e, #9f3211); border-color: #e45b28; color: #fff; font-family: var(--font-ko-bold); }
.btn.accent:hover { filter: brightness(1.08); }
.btn.on { background: linear-gradient(#009624, #006418); border-color: #00c853; color: #fff; font-family: var(--font-ko-bold); }
.btn.off { background: linear-gradient(#9b0000, #640000); border-color: #ff1744; color: #fff; font-family: var(--font-ko-bold); }
.btn.emergency { background: #c91616; border-color: #ff5252; color: #fff; font-family: var(--font-ko-bold); }
.btn.emergency:hover { background: #e01c1c; }
.btn.big { padding: 10px 12px 9px; font-size: 14px; font-family: var(--font-ko-bold); box-shadow: 0 4px 6px rgba(0, 0, 0, .5); }
.btn.big:active { transform: translateY(2px); box-shadow: 0 1px 2px rgba(0, 0, 0, .5); }
.btn.lit { border-color: #00c853; box-shadow: inset 0 0 0 1px rgba(0, 230, 118, .55); color: #fff; }
.btn.warnlit { border-color: #ffd54f; box-shadow: inset 0 0 0 1px rgba(255, 213, 79, .55); color: #ffe58a; }

/* ---- inputs ---------------------------------------------------------------------- */
input[type=text], input[type=number], input[type=password], select { height: 30px; padding: 0 9px; border: 1px solid #494949; border-radius: 3px; background: #0f0f0f; color: #fff; font-family: var(--font-ko); font-size: 14px; outline: none; min-width: 0; }
input[type=number] { font-family: var(--font-num); width: 88px; }
input:focus, select:focus { border-color: var(--theme-bright); box-shadow: 0 0 0 2px rgba(230, 87, 36, .18); }
input::placeholder { color: #7d848b; opacity: 1; }
select option { background: #1b1b1b; }
label.field { display: flex; align-items: center; justify-content: space-between; gap: 8px; font-size: 14px; color: #ddd; }
input[type=checkbox] { width: 16px; height: 16px; accent-color: #e65724; margin: 0; }

/* ---- tables ---------------------------------------------------------------------- */
table.list { width: 100%; border-collapse: collapse; font-size: 14px; }
table.list th, table.list td { padding: 5px 7px; border-bottom: 1px solid #2e2e2e; text-align: left; white-space: nowrap; }
table.list th { color: #b8b8b8; font-family: var(--font-ko-bold); font-weight: 400; font-size: 13px; background: #1b1b1b; }
table.list td { font-family: var(--font-num); font-variant-numeric: tabular-nums; }
table.list td.ko { font-family: var(--font-ko); }
tr.shown td.cls { color: #69f0ae; }
tr.held td.cls { color: #ffd54f; }
tr.notpitch td { color: #8a8a8a; }
.table-wrap { overflow-x: auto; }

/* ---- bottom "graphic control" panel ----------------------------------------------- */
.bottom-panel { position: fixed; left: 0; right: 0; bottom: 0; z-index: 900; background: #111; border-top: 2px solid #444; box-shadow: 0 -5px 20px rgba(0, 0, 0, .5); padding: 8px 15px 12px; }
.bottom-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.bottom-head .t { font-family: var(--font-ko-bold); font-size: 15px; color: #fff; }
.bottom-head .s { color: #8a8a8a; font-size: 13px; margin-left: 8px; }
.graphic-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 8px; }
.graphic-item { background: #252525; border: 1px solid #333; border-radius: 3px; padding: 6px 8px 7px; display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.graphic-item .glabel { display: flex; align-items: center; justify-content: space-between; gap: 6px; font-family: var(--font-ko-bold); font-size: 14px; color: #eee; white-space: nowrap; overflow: hidden; }
.graphic-item .glabel small { color: #8a8a8a; font-family: var(--font-num); font-weight: 400; font-size: 12px; }
.graphic-item.on-air { border-color: #e53935; box-shadow: 0 0 0 1px rgba(229, 57, 53, .45), 0 0 10px rgba(229, 57, 53, .25); }
.graphic-item.on-air .glabel > span:first-child::before { content: '●'; color: #ff5252; font-size: 13px; margin-right: 5px; vertical-align: 1px; text-shadow: 0 0 6px rgba(255, 82, 82, .9); }
.graphic-item .grow { display: grid; grid-template-columns: 1fr 1fr; gap: 5px; }
.graphic-item .grow .btn { padding-left: 4px; padding-right: 4px; }

/* ---- login ----------------------------------------------------------------------- */
.login-wrap { position: fixed; inset: 0; z-index: 1000; display: grid; place-items: center; padding: 18px; background: radial-gradient(circle at 50% 18%, rgba(182, 64, 24, .13), transparent 34%), #101010; }
.login-card { width: min(420px, 100%); overflow: hidden; border: 1px solid #3b3b3b; border-top: 3px solid #b64018; border-radius: 4px; background: #1b1b1b; box-shadow: 0 24px 70px rgba(0, 0, 0, .56); }
.login-heading { padding: 20px 22px 17px; border-bottom: 1px solid #303030; background: #171717; }
.login-heading .brand { display: block; margin: 0 0 7px; }
.login-heading p { margin: 0; color: #999; font-size: 13px; }
.login-card form { padding: 20px 22px 22px; }
.login-card label { display: block; margin-bottom: 8px; color: #c8c8c8; font-size: 13px; font-family: var(--font-ko-bold); }
.login-card input { width: 100%; height: 48px; padding: 0 13px; font-size: 18px; font-family: var(--font-num); }
.login-card button { width: 100%; height: 48px; margin-top: 12px; border: 1px solid #e45b28; border-radius: 3px; background: linear-gradient(#c64b1e, #9f3211); color: #fff; font-family: var(--font-ko-bold); font-size: 16px; cursor: pointer; }
.login-card button:hover { filter: brightness(1.08); }
.login-card button:active { transform: translateY(1px); }
.login-card .status { min-height: 20px; margin: 11px 0 0; color: #ff9d79; font-size: 13px; line-height: 1.45; text-align: center; }

@media (max-width: 760px) {
  .top-bar { flex-direction: column; align-items: flex-start; }
  .header-nav { justify-content: flex-start; }
  .control-area { padding: 12px; }
  .kv { grid-template-columns: 74px minmax(0, 1fr); }
}
/* KZONE: connect accounts first, then operate each park. */
.parks-grid { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:16px; }
.connection-guide { display:flex; flex-wrap:wrap; align-items:center; gap:10px; margin:0 0 18px; padding:4px 0 14px; border-bottom:1px solid #383838; font-size:14px; color:#eee; }
.connection-guide > span { color:#a65b3e; }
.connection-guide p { flex-basis:100%; margin:0; font-size:13px; line-height:1.6; color:#aaa; }
.park { scroll-margin-top:16px; }
.park .frame-title { font-size:20px; }
.rf-heading { display:flex; flex-wrap:wrap; align-items:center; justify-content:space-between; gap:8px; font-size:14px; margin-top:10px; }
.rf-help { margin:8px 0 12px; color:#aaa; font-size:13px; line-height:1.6; }
.rf-login { display:grid; grid-template-columns:repeat(2,minmax(0,1fr)); gap:10px; }
.rf-login label, .rf-label { display:block; min-width:0; color:#ccc; font-size:13px; line-height:1.5; }
.rf-login input, .rf-label select { display:block; width:100%; min-width:0; margin-top:6px; height:38px; }
.rf-login > button { grid-column:1/-1; min-height:38px; }
.rf-label { margin:0 0 10px; }
.rf-publish { border-left:3px solid #a73b16; padding:12px; background:#181818; margin:14px 0; }
.rf-publish > b { display:block; font-size:13px; margin-bottom:8px; }
.rf-publish input, .output-address input { width:100%; min-width:0; flex:1; font-family:var(--font-num); }
.rf-result { margin:10px 0 0; color:#efbe84; font-size:13px; line-height:1.6; overflow-wrap:anywhere; }
.rf-result:empty { display:none; }
.rf-result.bad { color:#ff9292; }
[aria-busy=true] [data-login] input, [aria-busy=true] [data-stream] { opacity:.65; pointer-events:none; }
.park-operation { margin-top:14px; border-top:1px solid #383838; padding-top:12px; }
.park-video-state { display:flex; flex-wrap:wrap; gap:8px 16px; font-size:13px; margin-bottom:12px; color:#aaa; }
.park-video-state b { color:#ddd; }
.park-primary { display:grid; grid-template-columns:2fr 1fr; gap:8px; }
.park-broadcast { margin-top:12px; border:1px solid #424242; background:#191919; padding:12px; }
.park-broadcast.is-on { border-color:#b74739; }
.park-broadcast-label { display:flex; justify-content:space-between; gap:8px; font-size:13px; color:#aaa; margin-bottom:10px; }
.park-broadcast-label b { color:#ddd; }
.park-broadcast .row { display:grid; grid-template-columns:repeat(3,minmax(0,1fr)); }
.output-address { margin-top:12px; border-top:1px solid #333; padding-top:10px; font-size:13px; }
.output-address > b { color:#eee; }
.qr-dialog { color:#eee; background:#1b1b1b; border:1px solid #666; padding:20px; width:430px; max-width:calc(100vw - 32px); max-height:calc(100dvh - 32px); box-sizing:border-box; }
.qr-dialog::backdrop { background:rgba(0,0,0,.8); }
.qr-dialog .qr-picture { background:#fff; color:#111; display:flex; align-items:center; justify-content:center; aspect-ratio:1; width:min(100%,300px); margin:16px auto; }
.qr-dialog img { width:100%; height:100%; }
.qr-dialog input { width:100%; min-width:0; box-sizing:border-box; }
.input-action { margin-top:12px; display:flex; flex-wrap:wrap; gap:10px; align-items:center; }
#others { margin-top:16px; }
.bottom-head .s { line-height:1.5; }
[hidden] { display:none !important; }
@media(max-width:850px) { .parks-grid { grid-template-columns:1fr; } .bottom-head .s { display:none; } .header-nav { width:100%; justify-content:flex-start; } }
@media(max-width:480px) { .rf-login { grid-template-columns:1fr; } .onair-strip { gap:5px 10px; } .onair-big { font-size:17px; } .top-bar { padding:8px 10px; } .control-area { padding:10px; padding-bottom:calc(10px + var(--bottom-h)); } }

.kv .chip { white-space:normal; height:auto; min-height:28px; line-height:1.5; overflow-wrap:anywhere; }
.frame-title { min-width:0; overflow-wrap:anywhere; }
.stack { min-width:0; }
