:root{color-scheme:dark;--bg:#090c11;--panel:#11161e;--panel2:#0c1118;--line:#242d39;--muted:#8290a0;--text:#e6edf4;--cyan:#65d9e8;--blue:#438af5;--orange:#ffb25d;--green:#75e2a0;font-family:Manrope,-apple-system,BlinkMacSystemFont,sans-serif}*{box-sizing:border-box}body{margin:0;background:radial-gradient(ellipse at 50% -20%,#152332 0%,var(--bg) 48%);color:var(--text);min-height:100vh}.topbar{height:60px;border-bottom:1px solid #1e2630;display:flex;justify-content:space-between;align-items:center;padding:0 clamp(16px,3vw,48px);background:#090c11e8}.brand{display:flex;align-items:center;gap:10px;font-size:13px;font-weight:800;letter-spacing:.14em}.brand b{color:var(--cyan)}.brand small{border-left:1px solid #35404d;margin-left:5px;padding-left:14px;color:#6e7a88;font:10px 'DM Mono',monospace;letter-spacing:.12em}.brand-mark{display:grid;place-items:center;width:27px;height:27px;background:linear-gradient(145deg,#75e6ee,#247fbc);color:#061117;border-radius:7px;font-weight:800;font-size:14px;letter-spacing:0}.top-meta{display:flex;gap:11px;align-items:center;color:#9ba8b7;font:10px 'DM Mono',monospace;letter-spacing:.08em}.rx-dot{width:7px;height:7px;border-radius:50%;background:#536170}.rx-dot.on{background:var(--green);box-shadow:0 0 12px #61e59a}.divider{height:15px;border-left:1px solid #2d3744;margin:0 4px}.console{max-width:1600px;margin:0 auto;padding:25px clamp(14px,3vw,48px) 14px}.panel{border:1px solid var(--line);background:linear-gradient(145deg,#131a23,#0e131a);border-radius:9px;box-shadow:0 8px 32px #0002}.masthead{display:grid;grid-template-columns:1.15fr 1fr 1.25fr;gap:13px}.frequency-card,.tune-card,.meter-card{min-height:168px;padding:16px 19px}.eyebrow{display:flex;align-items:center;justify-content:space-between;color:#8593a3;font:10px 'DM Mono',monospace;letter-spacing:.12em}.eyebrow>span{letter-spacing:.04em}.live-badge{color:#778391;border:1px solid #303b48;border-radius:3px;padding:3px 6px;font-size:9px}.live-badge.on{color:var(--green);border-color:#245b43}.frequency-input{display:flex;align-items:baseline;gap:8px;border-bottom:1px solid #283441;margin-top:8px}.frequency-input input{background:none;border:0;outline:0;color:#f0f7fc;width:100%;font:clamp(22px,3vw,38px) 'DM Mono',monospace;letter-spacing:-.055em;padding:0}.frequency-input span{color:#8594a3;font:10px 'DM Mono',monospace}.freq-readout{font:14px 'DM Mono',monospace;color:#92a4b8;letter-spacing:.08em;margin-top:3px}.freq-foot{display:flex;gap:7px;margin-top:10px}.freq-foot span{font:9px 'DM Mono',monospace;color:#83a8be;background:#152330;border:1px solid #273b4a;border-radius:3px;padding:3px 6px}.freq-foot span:first-child{color:var(--cyan)}.tune-card{display:flex;flex-direction:column;justify-content:space-between}.tune-row{display:grid;grid-template-columns:42px 1fr 42px auto;gap:7px}.button,.icon-button,select,.tool-button{background:#151d27;border:1px solid #303c49;color:#d4dde7;border-radius:5px;height:36px;font:10px 'DM Mono',monospace;letter-spacing:.04em}.icon-button{font-size:20px;color:#b6c5d2;cursor:pointer}.button{padding:0 12px;cursor:pointer}.subdued{color:#aab8c7}.transport{display:flex;gap:8px}.transport .button{height:38px}.primary{background:linear-gradient(110deg,#176f86,#237baa);border-color:#3197ae;color:#efffff;font-weight:500;flex:1}.primary span{margin-right:7px}.stop{color:#ff8b80;border-color:#603c3a;background:#241817}.button:disabled{opacity:.35;cursor:not-allowed}.meter-card{display:flex;flex-direction:column;justify-content:space-between}.meter{height:38px;position:relative;border:1px solid #303b47;background:repeating-linear-gradient(90deg,#141b24 0,#141b24 calc(10% - 1px),#090d12 calc(10% - 1px),#090d12 10%);border-radius:4px;overflow:hidden;margin-top:15px}.meter-fill{height:100%;width:0;background:linear-gradient(90deg,#40bb9d 0%,#92d64b 64%,#f5bb43 82%,#ef695b 100%);transition:width .2s}.meter i{position:absolute;height:100%;border-right:1px solid #10151c;top:0}.meter i:nth-child(2){left:20%}.meter i:nth-child(3){left:40%}.meter i:nth-child(4){left:60%}.meter i:nth-child(5){left:80%}.meter-scale{display:flex;justify-content:space-between;color:#707e8c;font:9px 'DM Mono',monospace;margin-top:4px}.meter-caption{display:flex;justify-content:space-between;color:#738191;font:9px 'DM Mono',monospace;letter-spacing:.1em}.meter-caption strong{color:#94a4b5;font-weight:400}.control-grid{display:grid;grid-template-columns:1.1fr 1.35fr 1fr 1fr;gap:13px;margin-top:13px}.control-panel{padding:14px 16px;min-height:99px}.mode-grid{display:grid;grid-template-columns:repeat(6,1fr);gap:5px;margin-top:13px}.mode-grid button{background:#141b24;border:1px solid #2a3542;border-radius:4px;height:31px;color:#98a6b5;font:10px 'DM Mono',monospace;cursor:pointer}.mode-grid button.selected{background:#17313b;border-color:#348b9b;color:#8ce7ec}.wide-select{width:100%;margin-top:13px;padding:0 9px}.control-panel input[type=range]{width:100%;accent-color:var(--cyan);margin:20px 0 2px}.range-labels{display:flex;justify-content:space-between;color:#677584;font:9px 'DM Mono',monospace}.visualization{margin-top:14px;padding:15px 17px 12px}.visual-head{display:flex;justify-content:space-between;align-items:center}.tiny-live{color:var(--green);font-size:9px;margin-left:12px}.visual-sub{font:9px 'DM Mono',monospace;letter-spacing:.07em;color:#718091;margin-top:5px}.visual-sub span{color:#9fb5c3}.visual-tools{display:flex;gap:6px}.tool-button{height:25px;padding:0 9px;font-size:9px;color:#8290a0;cursor:pointer}.tool-button.active{border-color:#438af5;color:#8dbbff}.plot-wrap{height:205px;margin-top:10px;position:relative;background:#080d13;border:1px solid #1e2a36;border-radius:4px;overflow:hidden}.plot-wrap canvas,.waterfall-wrap canvas{width:100%;height:100%;display:block}.waterfall-head{display:flex;justify-content:space-between;color:#738293;font:9px 'DM Mono',monospace;letter-spacing:.1em;margin:13px 0 6px}.waterfall-head span:last-child{color:#526170}.waterfall-wrap{height:230px;background:#070b10;border:1px solid #1e2a36;border-radius:4px;overflow:hidden}.axis-labels{display:flex;justify-content:space-between;color:#6e7d8d;font:9px 'DM Mono',monospace;padding:5px 2px 0}.footer{display:flex;justify-content:space-between;color:#5f6c7b;font:9px 'DM Mono',monospace;letter-spacing:.09em;padding:13px 2px 2px}.footer i{color:#347c8e;font-style:normal;margin:0 4px}.auth-modal{position:fixed;inset:0;background:#05080de8;display:none;place-items:center;padding:20px;z-index:10;backdrop-filter:blur(8px)}.auth-modal.show{display:grid}.auth-card{width:min(380px,100%);border:1px solid #293541;background:#101720;border-radius:12px;padding:28px;box-shadow:0 20px 80px #0008}.large{width:38px;height:38px;font-size:19px;margin-bottom:22px}.auth-card h1{font-size:21px;margin:12px 0 5px}.auth-card p{font-size:12px;color:#9ba8b6;margin:0 0 18px}.auth-card input{display:block;width:100%;height:40px;background:#0b1118;border:1px solid #303b47;border-radius:5px;color:#e8f0f5;padding:0 11px;margin-bottom:10px}.auth-card .button{width:100%}.error-text{color:#ff998b;font-size:11px;margin-top:10px;min-height:14px}
:root{color-scheme:dark;--bg:#090c11;--panel:#11161e;--panel2:#0c1118;--line:#242d39;--muted:#8290a0;--text:#e6edf4;--cyan:#65d9e8;--blue:#438af5;--orange:#ffb25d;--green:#75e2a0;font-family:system-ui,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif}*{box-sizing:border-box}body{margin:0;background:radial-gradient(ellipse at 50% -20%,#152332 0%,var(--bg) 48%);color:var(--text);min-height:100vh}.topbar{height:60px;border-bottom:1px solid #1e2630;display:flex;justify-content:space-between;align-items:center;padding:0 clamp(16px,3vw,48px);background:#090c11e8}.brand{display:flex;align-items:center;gap:10px;font-size:13px;font-weight:800;letter-spacing:.14em}.brand b{color:var(--cyan)}.brand small{border-left:1px solid #35404d;margin-left:5px;padding-left:14px;color:#6e7a88;font:10px ui-monospace,monospace;letter-spacing:.12em}.brand-mark{display:grid;place-items:center;width:27px;height:27px;background:linear-gradient(145deg,#75e6ee,#247fbc);color:#061117;border-radius:7px;font-weight:800;font-size:14px;letter-spacing:0}.top-meta{display:flex;gap:11px;align-items:center;color:#9ba8b7;font:10px ui-monospace,monospace;letter-spacing:.08em}.rx-dot{width:7px;height:7px;border-radius:50%;background:#536170}.rx-dot.on{background:var(--green);box-shadow:0 0 12px #61e59a}.divider{height:15px;border-left:1px solid #2d3744;margin:0 4px}.console{max-width:1600px;margin:0 auto;padding:25px clamp(14px,3vw,48px) 14px}.panel{border:1px solid var(--line);background:linear-gradient(145deg,#131a23,#0e131a);border-radius:9px;box-shadow:0 8px 32px #0002}.masthead{display:grid;grid-template-columns:1.15fr 1fr 1.25fr;gap:13px}.frequency-card,.tune-card,.meter-card{min-height:168px;padding:16px 19px}.eyebrow{display:flex;align-items:center;justify-content:space-between;color:#8593a3;font:10px ui-monospace,monospace;letter-spacing:.12em}.eyebrow>span{letter-spacing:.04em}.live-badge{color:#778391;border:1px solid #303b48;border-radius:3px;padding:3px 6px;font-size:9px}.live-badge.on{color:var(--green);border-color:#245b43}.frequency-input{display:flex;align-items:baseline;gap:8px;border-bottom:1px solid #283441;margin-top:8px}.frequency-input input{background:none;border:0;outline:0;color:#f0f7fc;width:100%;font:clamp(22px,3vw,38px) ui-monospace,monospace;letter-spacing:-.055em;padding:0}.frequency-input span{color:#8594a3;font:10px ui-monospace,monospace}.freq-readout{font:14px ui-monospace,monospace;color:#92a4b8;letter-spacing:.08em;margin-top:3px}.freq-foot{display:flex;gap:7px;margin-top:10px}.freq-foot span{font:9px ui-monospace,monospace;color:#83a8be;background:#152330;border:1px solid #273b4a;border-radius:3px;padding:3px 6px}.freq-foot span:first-child{color:var(--cyan)}.tune-card{display:flex;flex-direction:column;justify-content:space-between}.tune-row{display:grid;grid-template-columns:42px 1fr 42px auto;gap:7px}.button,.icon-button,select,.tool-button{background:#151d27;border:1px solid #303c49;color:#d4dde7;border-radius:5px;height:36px;font:10px ui-monospace,monospace;letter-spacing:.04em}.icon-button{font-size:20px;color:#b6c5d2;cursor:pointer}.button{padding:0 12px;cursor:pointer}.subdued{color:#aab8c7}.transport{display:flex;gap:8px}.transport .button{height:38px}.primary{background:linear-gradient(110deg,#176f86,#237baa);border-color:#3197ae;color:#efffff;font-weight:500;flex:1}.primary span{margin-right:7px}.stop{color:#ff8b80;border-color:#603c3a;background:#241817}.button:disabled{opacity:.35;cursor:not-allowed}.meter-card{display:flex;flex-direction:column;justify-content:space-between}.meter{height:38px;position:relative;border:1px solid #303b47;background:repeating-linear-gradient(90deg,#141b24 0,#141b24 calc(10% - 1px),#090d12 calc(10% - 1px),#090d12 10%);border-radius:4px;overflow:hidden;margin-top:15px}.meter-fill{height:100%;width:0;background:linear-gradient(90deg,#40bb9d 0%,#92d64b 64%,#f5bb43 82%,#ef695b 100%);transition:width .2s}.meter i{position:absolute;height:100%;border-right:1px solid #10151c;top:0}.meter i:nth-child(2){left:20%}.meter i:nth-child(3){left:40%}.meter i:nth-child(4){left:60%}.meter i:nth-child(5){left:80%}.meter-scale{display:flex;justify-content:space-between;color:#707e8c;font:9px ui-monospace,monospace;margin-top:4px}.meter-caption{display:flex;justify-content:space-between;color:#738191;font:9px ui-monospace,monospace;letter-spacing:.1em}.meter-caption strong{color:#94a4b5;font-weight:400}.control-grid{display:grid;grid-template-columns:1.1fr 1.35fr 1fr 1fr;gap:13px;margin-top:13px}.control-panel{padding:14px 16px;min-height:99px}.mode-grid{display:grid;grid-template-columns:repeat(6,1fr);gap:5px;margin-top:13px}.mode-grid button{background:#141b24;border:1px solid #2a3542;border-radius:4px;height:31px;color:#98a6b5;font:10px ui-monospace,monospace;cursor:pointer}.mode-grid button.selected{background:#17313b;border-color:#348b9b;color:#8ce7ec}.wide-select{width:100%;margin-top:13px;padding:0 9px}.control-panel input[type=range]{width:100%;accent-color:var(--cyan);margin:20px 0 2px}.range-labels{display:flex;justify-content:space-between;color:#677584;font:9px ui-monospace,monospace}.visualization{margin-top:14px;padding:15px 17px 12px}.visual-head{display:flex;justify-content:space-between;align-items:center}.tiny-live{color:var(--green);font-size:9px;margin-left:12px}.visual-sub{font:9px ui-monospace,monospace;letter-spacing:.07em;color:#718091;margin-top:5px}.visual-sub span{color:#9fb5c3}.visual-tools{display:flex;gap:6px}.tool-button{height:25px;padding:0 9px;font-size:9px;color:#8290a0;cursor:pointer}.tool-button.active{border-color:#438af5;color:#8dbbff}.plot-wrap{height:205px;margin-top:10px;position:relative;background:#080d13;border:1px solid #1e2a36;border-radius:4px;overflow:hidden}.plot-wrap canvas,.waterfall-wrap canvas{width:100%;height:100%;display:block}.waterfall-head{display:flex;justify-content:space-between;color:#738293;font:9px ui-monospace,monospace;letter-spacing:.1em;margin:13px 0 6px}.waterfall-head span:last-child{color:#526170}.waterfall-wrap{height:230px;background:#070b10;border:1px solid #1e2a36;border-radius:4px;overflow:hidden}.axis-labels{display:flex;justify-content:space-between;color:#6e7d8d;font:9px ui-monospace,monospace;padding:5px 2px 0}.footer{display:flex;justify-content:space-between;color:#5f6c7b;font:9px ui-monospace,monospace;letter-spacing:.09em;padding:13px 2px 2px}.footer i{color:#347c8e;font-style:normal;margin:0 4px}.auth-modal{position:fixed;inset:0;background:#05080de8;display:none;place-items:center;padding:20px;z-index:10;backdrop-filter:blur(8px)}.auth-modal.show{display:grid}.auth-card{width:min(380px,100%);border:1px solid #293541;background:#101720;border-radius:12px;padding:28px;box-shadow:0 20px 80px #0008}.large{width:38px;height:38px;font-size:19px;margin-bottom:22px}.auth-card h1{font-size:21px;margin:12px 0 5px}.auth-card p{font-size:12px;color:#9ba8b6;margin:0 0 18px}.auth-card input{display:block;width:100%;height:40px;background:#0b1118;border:1px solid #303b47;border-radius:5px;color:#e8f0f5;padding:0 11px;margin-bottom:10px}.auth-card .button{width:100%}.error-text{color:#ff998b;font-size:11px;margin-top:10px;min-height:14px}
@media(max-width:900px){.masthead{grid-template-columns:1fr 1fr}.meter-card{grid-column:1/-1;min-height:125px}.control-grid{grid-template-columns:1fr 1fr}.modes-panel{grid-column:1/-1}.mode-grid{grid-template-columns:repeat(6,1fr)}}
@media(max-width:560px){.topbar{height:52px;padding:0 13px}.brand{font-size:11px}.brand small{display:none}.top-meta{font-size:8px;gap:7px}.console{padding:12px 10px}.masthead{grid-template-columns:1fr;gap:9px}.frequency-card,.tune-card{min-height:145px;padding:13px}.meter-card{grid-column:auto;min-height:118px;padding:13px}.control-grid{gap:8px;margin-top:9px}.control-panel{padding:12px 11px;min-height:94px}.mode-grid{grid-template-columns:repeat(3,1fr);margin-top:9px}.modes-panel{grid-column:1/-1}.mode-grid button{height:28px}.wide-select{margin-top:10px;font-size:9px}.control-panel input[type=range]{margin:17px 0 1px}.visualization{margin-top:9px;padding:12px 10px 9px}.plot-wrap{height:165px}.waterfall-wrap{height:175px}.visual-sub{font-size:8px}.footer{font-size:8px;gap:10px;line-height:1.5}.footer span:last-child{text-align:right}.tune-row{grid-template-columns:36px 1fr 36px auto;gap:5px}.button{padding:0 8px;font-size:9px}}

/* Keep receiver controls dominant and the RF views compact. */
.band-presets{margin-top:13px;padding:12px 14px}
.band-buttons{display:grid;grid-template-columns:repeat(6,minmax(0,1fr));gap:6px;margin-top:9px}
.band-presets .band-preset{min-width:0;height:auto;display:flex;flex-direction:column;align-items:flex-start;gap:4px;padding:7px 8px;background:#101821;border:1px solid #293746;border-radius:5px;color:#d7e3ed;text-align:left;cursor:pointer;font:inherit;letter-spacing:normal}
.band-preset:hover,.band-preset:focus-visible,.band-preset.selected{border-color:#348b9b;background:#14252d;outline:none}
.band-preset b{font:10px ui-monospace,monospace;color:#8ce7ec}
.band-preset small{font:9px ui-monospace,monospace;color:#8b9bab;white-space:nowrap}
.plot-wrap{height:120px}
.waterfall-wrap{height:130px}
@media(max-width:900px){.band-buttons{grid-template-columns:repeat(4,minmax(0,1fr))}}
@media(max-width:560px){.band-presets{margin-top:9px;padding:11px 10px}.band-presets>.eyebrow{font-size:8px}.band-buttons{grid-template-columns:repeat(3,minmax(0,1fr));gap:5px}.band-preset{padding:7px 6px}.band-preset small{font-size:8px}.plot-wrap{height:88px}.waterfall-wrap{height:100px}}
.nr-toggle{display:flex;justify-content:space-between;align-items:center;width:100%;height:27px;margin-top:7px;padding:0 8px;border:1px solid #303c49;border-radius:4px;background:#101720;color:#91a0ae;font:9px ui-monospace,monospace;letter-spacing:.06em;cursor:pointer}
.nr-toggle b{color:#7d8b99;font-weight:500}
.nr-toggle[aria-pressed="true"]{border-color:#348b9b;background:#14252d;color:#bceff0}
.nr-toggle[aria-pressed="true"] b{color:#8ce7ec}
.visual-tools{align-items:center;flex-wrap:wrap;justify-content:flex-end}
.span-buttons{display:flex;gap:4px;margin-right:4px}
.span-buttons .tool-button{padding:0 7px;font-size:8px}
@media(max-width:560px){.visual-head{align-items:flex-start;flex-wrap:wrap;gap:7px}.visual-tools{width:100%;justify-content:flex-start}.span-buttons{flex:1}.span-buttons .tool-button{flex:1;padding:0 4px;font-size:8px}}
.overload{margin-top:6px;padding:3px 6px;border:1px solid #2a3a33;border-radius:4px;color:#75e2a0;font:9px ui-monospace,monospace;letter-spacing:.08em;text-align:center}
.overload.on{border-color:#a8452f;background:#2a1410;color:#ff8a65}
.axis-labels{padding-left:42px;padding-right:8px}
.dsp-panel{display:grid;grid-template-columns:repeat(4,1fr);gap:18px;margin-top:13px;padding:14px 16px}
.dsp-cell{min-width:0}
.dsp-panel input[type=range]{width:100%;accent-color:var(--orange);margin:18px 0 2px}
.dsp-hint{margin-top:7px;color:#677584;font:9px ui-monospace,monospace;line-height:1.4}
.sq-status{display:flex;justify-content:space-between;margin-top:7px;color:#738191;font:9px ui-monospace,monospace;letter-spacing:.08em}
.sq-status b{color:#c5cfdb;font-weight:500}
#sq-state{color:#75e2a0}
#sq-state.closed{color:#ff8a65}
#nb-label{color:#ffb25d}
@media(max-width:900px){.dsp-panel{grid-template-columns:1fr 1fr}}
@media(max-width:560px){.dsp-panel{grid-template-columns:1fr;gap:12px}}
.legend-ham{color:#3ddc84}
.legend-bc{color:#ffa040}
.frequency-input input.invalid{color:#ff8a65}
.scan-bar{display:flex;align-items:center;flex-wrap:wrap;gap:6px;margin:10px 0 2px}
.scan-btn{height:28px;padding:0 10px;font-size:10px}
.scan-btn:disabled{opacity:.4;cursor:default}
.scan-status{flex:1;min-width:180px;color:#8392a2;font:9px ui-monospace,monospace;letter-spacing:.06em}
.scan-bar[data-state=seek] .scan-status,.scan-bar[data-state=verify] .scan-status{color:#ffb25d}
.scan-bar[data-state=listen] .scan-status{color:#75e2a0}
.mode-grid{grid-template-columns:repeat(7,1fr)}
@media(max-width:560px){.mode-grid{grid-template-columns:repeat(4,1fr)}}
#sam-sideband{margin-top:7px}
#sam-chip.locked{color:#75e2a0;border-color:#245b43}
#sam-chip.seeking{color:#ffb25d}
.legend-cb{color:#b48cff}
.log-panel{margin-top:13px;padding:12px 14px}
.log-bar{display:flex;flex-wrap:wrap;gap:6px;align-items:center;margin:10px 0 8px}
.log-toggle{width:auto;height:28px;margin:0;gap:8px}
.log-link{display:inline-flex;align-items:center;text-decoration:none}
.log-table-wrap{max-height:260px;overflow:auto;border:1px solid #1e2a36;border-radius:4px}
.log-table{width:100%;border-collapse:collapse;font:10px ui-monospace,monospace;color:#c5cfdb}
.log-table th{position:sticky;top:0;background:#0e141b;color:#7d8b99;text-align:left;font-weight:400;padding:5px 7px;letter-spacing:.06em}
.log-table td{padding:4px 7px;border-top:1px solid #18222c;white-space:nowrap}
.log-table tr.suspect td{background:#2a1a10}
.log-table tr.suspect td.flag{color:#ff9d5c}
.log-table td.freq{color:#8ce7ec;cursor:pointer;text-decoration:underline dotted}
.log-table td.flag{white-space:normal;min-width:160px;color:#7d8b99}
.log-table a{color:#75e2a0}
.log-empty{color:#677584;text-align:center;padding:14px}

/* ===== Screen-filling layout ===============================================================
 * Spectrum + waterfall share the available height 2:1 (2/3 spectrum, 1/3 waterfall).
 * Stacked (< 1280 px): the spectrum sits right under the frequency cards and scales with
 * the window height. Wide (>= 1280 px): controls in a scrolling sidebar on the left, the
 * spectrum/waterfall pinned on the right at full window height. */
.topbar{position:sticky;top:0;z-index:5;backdrop-filter:blur(6px)}
.console{display:flex;flex-direction:column}
.console>.masthead{order:1}
.console>.visualization{order:2}
.console>section:not(.masthead):not(.visualization){order:3}
.console>.footer{order:4}
.plot-wrap{height:clamp(205px,44vh,720px)}
.waterfall-wrap{height:clamp(103px,22vh,360px)}
@media(max-width:900px){.plot-wrap{height:clamp(150px,36vh,460px)}.waterfall-wrap{height:clamp(75px,18vh,230px)}}
@media(max-width:560px){.plot-wrap{height:clamp(130px,30vh,320px)}.waterfall-wrap{height:clamp(65px,15vh,160px)}}

@media(min-width:1280px) and (min-height:620px){
  .console{display:grid;max-width:none;grid-template-columns:clamp(400px,28vw,540px) minmax(0,1fr);column-gap:14px;align-items:start;padding-top:14px}
  .console>*{grid-column:1;order:0}
  .console>section:first-child{margin-top:0}
  .console>.visualization{grid-column:2;grid-row:1/span 20;position:sticky;top:74px;height:calc(100vh - 88px);margin-top:0;display:flex;flex-direction:column}
  .visualization .plot-wrap{flex:2 1 0;height:auto;min-height:180px}
  .visualization .waterfall-wrap{flex:1 1 0;height:auto;min-height:90px}
  /* the sidebar is narrow: stack and tighten its panels */
  .masthead{grid-template-columns:1fr;gap:10px}
  .frequency-card,.tune-card,.meter-card{min-height:0}
  .meter-card{gap:8px}
  .control-grid{grid-template-columns:1fr 1fr;gap:10px;margin-top:10px}
  .modes-panel{grid-column:1/-1}
  .control-panel{min-height:0}
  .dsp-panel{grid-template-columns:1fr 1fr;gap:14px;margin-top:10px}
  .band-presets,.log-panel{margin-top:10px}
  .band-buttons{grid-template-columns:repeat(4,minmax(0,1fr))}
  .log-table-wrap{max-height:340px}
  .footer{flex-direction:column;gap:4px}
}
.nr2-opts{display:grid;grid-template-columns:1fr 1fr;gap:6px;margin-top:7px}
.nr2-opts[hidden]{display:none}
.nr2-opts select{height:28px;padding:0 6px;font-size:9px;min-width:0}
.nr2-opts .nr-toggle{grid-column:1/-1;margin-top:0}
