/* NextBall map editor (/editor.html). Fonts: the same files the game loads (arena.css). */
@font-face { font-family: 'Chakra Petch'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/chakra-petch-latin-ext-500-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Chakra Petch'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/chakra-petch-latin-500-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Chakra Petch'; font-style: italic; font-weight: 500; font-display: swap; src: url('fonts/chakra-petch-latin-ext-500-italic.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Chakra Petch'; font-style: italic; font-weight: 500; font-display: swap; src: url('fonts/chakra-petch-latin-500-italic.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Chakra Petch'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/chakra-petch-latin-ext-600-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Chakra Petch'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/chakra-petch-latin-600-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Chakra Petch'; font-style: italic; font-weight: 600; font-display: swap; src: url('fonts/chakra-petch-latin-ext-600-italic.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Chakra Petch'; font-style: italic; font-weight: 600; font-display: swap; src: url('fonts/chakra-petch-latin-600-italic.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Chakra Petch'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/chakra-petch-latin-ext-700-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Chakra Petch'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/chakra-petch-latin-700-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Chakra Petch'; font-style: italic; font-weight: 700; font-display: swap; src: url('fonts/chakra-petch-latin-ext-700-italic.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Chakra Petch'; font-style: italic; font-weight: 700; font-display: swap; src: url('fonts/chakra-petch-latin-700-italic.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/exo-2-latin-ext-400-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/exo-2-latin-400-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/exo-2-latin-ext-500-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/exo-2-latin-500-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/exo-2-latin-ext-600-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/exo-2-latin-600-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/exo-2-latin-ext-700-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/exo-2-latin-700-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 800; font-display: swap; src: url('fonts/exo-2-latin-ext-800-normal.woff2') format('woff2'); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Exo 2'; font-style: normal; font-weight: 800; font-display: swap; src: url('fonts/exo-2-latin-800-normal.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Exo 2'; font-style: italic; font-weight: 700; font-display: swap; src: url('fonts/exo-2-latin-700-italic.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }
@font-face { font-family: 'Exo 2'; font-style: italic; font-weight: 800; font-display: swap; src: url('fonts/exo-2-latin-800-italic.woff2') format('woff2'); unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD; }

:root {
    --bg-0: #0F1115; --bg-1: #15181D; --bg-2: #1B1F26; --bg-3: #242932; --bg-4: #2F3641;
    --line: rgba(255,255,255,.07); --line-strong: rgba(255,255,255,.14);
    --fg-0: #fff; --fg-1: #DDE0E6; --fg-2: #9BA1AC; --fg-3: #666D79;
    --orange: #FF6A13; --orange-hi: #FF8A45; --orange-ink: #1A0900; --red: #E0322E; --blue: #2E7BE0;
    --f-display: 'Chakra Petch', 'Arial Narrow', sans-serif; --f-body: 'Exo 2', system-ui, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; background: var(--bg-0); color: var(--fg-1); font: 500 13px/1.4 var(--f-body); overflow: hidden; }
button, input, select { font: inherit; color: inherit; }
.hidden { display: none !important; }
.ed { display: grid; grid-template-columns: 64px 1fr 300px; grid-template-rows: 56px 1fr; height: 100vh; height: 100dvh; }
.ed-top { grid-column: 1 / -1; display: flex; align-items: center; gap: 18px; padding: 0 14px; background: var(--bg-1); border-bottom: 1px solid var(--line-strong); min-width: 0; }
.ed-logo { display: flex; align-items: center; gap: 8px; color: var(--fg-0); text-decoration: none; font: 700 16px/1 var(--f-display); letter-spacing: .04em; flex: none; }
.ed-logo svg { width: 26px; height: 26px; }
.ed-logo b { font: 600 12px/1 var(--f-body); letter-spacing: .14em; text-transform: uppercase; color: var(--orange-hi); margin-left: 6px; padding-left: 10px; border-left: 1px solid var(--line-strong); }
.ed-meta { display: flex; gap: 10px; min-width: 0; flex: 1; }
.ed-field { display: flex; align-items: center; gap: 6px; min-width: 0; }
.ed-field span { color: var(--fg-3); font-size: 11px; letter-spacing: .1em; text-transform: uppercase; }
.ed-field input { width: 150px; min-width: 0; height: 32px; padding: 0 10px; border-radius: 4px; border: 1px solid var(--line-strong); background: var(--bg-0); outline: none; }
.ed-field input:focus { border-color: var(--orange); }
.ed-actions { display: flex; gap: 8px; flex: none; }
.ed-btn { height: 34px; padding: 0 14px; border-radius: 4px; border: 1px solid var(--line-strong); background: var(--bg-3); cursor: pointer; font-weight: 600; }
.ed-btn:hover { background: var(--bg-4); }
.ed-btn--primary { background: var(--orange); border-color: var(--orange); color: var(--orange-ink); font-weight: 700; }
.ed-btn--primary:hover { background: var(--orange-hi); }
.ed-btn--test.is-on { background: #1F7A3D; border-color: #38D66B; color: #fff; }
.ed-tools { display: flex; flex-direction: column; align-items: center; gap: 6px; padding: 10px 0; background: var(--bg-1); border-right: 1px solid var(--line); }
.ed-tool { width: 52px; padding: 7px 0 5px; display: grid; justify-items: center; gap: 3px; border-radius: 6px; border: 1px solid transparent; background: none; cursor: pointer; color: var(--fg-2); }
.ed-tool svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.ed-tool span { font-size: 10px; letter-spacing: .04em; }
.ed-tool:hover { background: var(--bg-3); color: var(--fg-0); }
.ed-tool.is-on { background: rgba(255,106,19,.14); border-color: rgba(255,106,19,.5); color: var(--orange-hi); }
.ed-tool:disabled { opacity: .35; cursor: default; }
.ed-tools-sep { width: 32px; height: 1px; background: var(--line-strong); margin: 4px 0; }
.ed-snap { display: grid; justify-items: center; gap: 3px; font-size: 10px; color: var(--fg-2); cursor: pointer; margin-top: 4px; }
.ed-stage { position: relative; overflow: hidden; background: #0B0E14; }
.ed-stage canvas { display: block; width: 100%; height: 100%; touch-action: none; }
.ed-status { position: absolute; left: 10px; bottom: 8px; font-size: 11px; color: var(--fg-3); pointer-events: none; background: rgba(11,14,20,.7); padding: 3px 8px; border-radius: 4px; }
.ed-test-hud { position: absolute; top: 10px; left: 50%; transform: translateX(-50%); padding: 7px 14px; border-radius: 999px; background: rgba(11,14,20,.85); border: 1px solid #38D66B; font-size: 12px; white-space: nowrap; }
.ed-test-hud b { color: #38D66B; margin-right: 8px; letter-spacing: .1em; }
.ed-test-hud kbd { font: 600 11px var(--f-body); padding: 1px 5px; border: 1px solid var(--line-strong); border-radius: 3px; }
.ed-test-hud span { margin-left: 10px; font-weight: 700; color: var(--fg-0); }
.ed-panel { background: var(--bg-1); border-left: 1px solid var(--line); overflow-y: auto; display: flex; flex-direction: column; }
.ed-tabs { display: grid; grid-template-columns: 1fr 1fr; border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--bg-1); z-index: 1; }
.ed-tab { padding: 12px 0; background: none; border: 0; border-bottom: 2px solid transparent; cursor: pointer; color: var(--fg-2); font-weight: 600; letter-spacing: .06em; text-transform: uppercase; font-size: 11px; }
.ed-tab.is-on { color: var(--fg-0); border-bottom-color: var(--orange); }
.ed-tabpanel { padding: 6px 14px 10px; }
.ed-group { padding: 10px 0 12px; border-bottom: 1px solid var(--line); }
.ed-group:last-child { border-bottom: 0; }
.ed-group h3 { margin: 0 0 8px; font: 700 11px/1 var(--f-display); letter-spacing: .14em; text-transform: uppercase; color: var(--fg-2); }
.ed-row { display: grid; grid-template-columns: 96px 1fr; align-items: center; gap: 8px; margin: 6px 0; }
.ed-row > span { color: var(--fg-2); font-size: 12px; }
.ed-row input[type=number], .ed-row input[type=text], .ed-row select { width: 100%; height: 30px; padding: 0 8px; border-radius: 4px; border: 1px solid var(--line-strong); background: var(--bg-0); outline: none; }
.ed-row input:focus, .ed-row select:focus { border-color: var(--orange); }
.ed-row .ed-range { display: grid; grid-template-columns: 1fr 48px; gap: 8px; align-items: center; }
.ed-row input[type=range] { width: 100%; accent-color: var(--orange); }
.ed-row .ed-range output { text-align: right; font-variant-numeric: tabular-nums; color: var(--fg-1); }
.ed-row input[type=color] { width: 44px; height: 28px; padding: 0; border: 1px solid var(--line-strong); border-radius: 4px; background: none; cursor: pointer; }
.ed-row label.ed-check { display: flex; align-items: center; gap: 6px; cursor: pointer; }
.ed-row input[type=checkbox] { accent-color: var(--orange); width: 16px; height: 16px; }
.ed-empty { color: var(--fg-3); padding: 18px 0; line-height: 1.6; }
.ed-del { margin-top: 10px; width: 100%; height: 32px; border-radius: 4px; border: 1px solid rgba(224,50,46,.5); background: rgba(224,50,46,.12); color: #ff8a87; cursor: pointer; font-weight: 600; }
.ed-del:hover { background: rgba(224,50,46,.22); }
.ed-count { color: var(--fg-3); font-size: 11px; margin-top: 4px; }
.ed-help { margin: auto 14px 14px; padding: 10px 12px; border-radius: 6px; background: var(--bg-2); color: var(--fg-2); font-size: 12px; line-height: 1.5; }
.ed-help b { color: var(--fg-1); }
.ed-toast { position: fixed; left: 50%; bottom: 22px; transform: translateX(-50%); padding: 10px 16px; border-radius: 6px; background: var(--bg-3); border: 1px solid var(--line-strong); color: var(--fg-0); font-weight: 600; z-index: 10; box-shadow: 0 10px 30px rgba(0,0,0,.5); }
@media (max-width: 900px) {
    .ed { grid-template-columns: 56px 1fr; grid-template-rows: auto 1fr 40vh; }
    .ed-top { flex-wrap: wrap; padding: 8px 10px; gap: 8px; }
    .ed-meta { order: 3; flex-basis: 100%; }
    .ed-field input { width: 100%; }
    .ed-tool { width: 46px; }
    .ed-panel { grid-column: 1 / -1; border-left: 0; border-top: 1px solid var(--line); }
}
.ed-beta { font: 700 10px/1 var(--f-body); font-style: normal; letter-spacing: .12em; text-transform: uppercase; padding: 3px 6px; border-radius: 3px; background: rgba(255,106,19,.16); color: var(--orange-hi); border: 1px solid rgba(255,106,19,.45); margin-left: 8px; }
.ed-ctl { display: grid; grid-template-columns: 1fr 26px; gap: 6px; align-items: center; min-width: 0; }
.ed-ctl > :first-child { min-width: 0; }
.ed-reset { width: 26px; height: 26px; padding: 0; border-radius: 4px; border: 1px solid var(--line-strong); background: var(--bg-3); color: var(--orange-hi); cursor: pointer; font-size: 14px; line-height: 1; }
.ed-reset:hover:not(:disabled) { background: var(--bg-4); }
.ed-reset:disabled { opacity: .25; cursor: default; color: var(--fg-3); }
.ed-reset-gap { width: 26px; }
