:root { color-scheme: dark; --bg: #101010; --panel: #171715; --paper: #eeeae0; --muted: #a49e91; --line: #3b3933; --accent: #ff8d4b; font: 14px/1.5 Arial, Helvetica, sans-serif; color: var(--paper); background: var(--bg); }
* { box-sizing: border-box; }
body { margin: 0; }
button, input, select { font: inherit; }
button, select, input[type="text"] { border: 1px solid #686358; color: var(--paper); background: #191917; border-radius: 0; }
button, select, summary, .file-button { cursor: pointer; }
button { padding: 8px 14px; }
button:hover:not(:disabled), .file-button:hover { border-color: var(--paper); background: #252521; }
button:disabled { cursor: wait; opacity: .45; }
button:focus-visible, input:focus-visible, select:focus-visible, a:focus-visible, summary:focus-visible, canvas:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
button[aria-pressed="true"] { color: #101010; background: var(--paper); }
a { color: var(--paper); text-underline-offset: 4px; }
a:hover { color: var(--accent); }
[hidden] { display: none !important; }
#impuls-app { max-width: 1480px; margin: auto; padding: 22px 26px 18px; }
.app-header { display: flex; align-items: end; justify-content: space-between; gap: 20px; margin-bottom: 16px; }
.eyebrow { font: 10px/1.5 "Courier New", monospace; letter-spacing: .14em; color: var(--accent); margin: 0 0 8px; }
h1 { font: 500 clamp(25px, 3.4vw, 39px)/1 Arial, Helvetica, sans-serif; letter-spacing: -.035em; margin: 0; }
h1 span { color: var(--muted); }
h1 small { display: inline-block; margin-left: 17px; font: 12px/1.4 "Courier New", monospace; color: var(--muted); letter-spacing: 0; }
.evidence-link { font-size: 12px; white-space: nowrap; margin-bottom: 2px; }
.research-notice { display: flex; gap: 13px; border: 1px solid var(--line); background: #1a1915; padding: 10px 14px; margin-bottom: 20px; }
.notice-marker { align-self: start; font: 16px/1.6 "Courier New", monospace; color: var(--accent); }
.research-notice p { font-size: 12px; color: var(--muted); margin: 0; }
.research-notice strong { color: var(--paper); font-weight: 500; }
.workbench { display: grid; grid-template-columns: minmax(0, 1fr) minmax(248px, 29%); gap: 24px; }
.section-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 11px; }
h2 { margin: 0; font-size: 13px; font-weight: 400; }
.indicator, .section-index, .section-bar>span { font: 10px/1.5 "Courier New", monospace; color: var(--muted); }
.indicator::before { content: ""; display: inline-block; width: 5px; height: 5px; background: var(--accent); margin-right: 7px; vertical-align: 1px; }
.indicator.paused::before { background: var(--muted); }
.screen-frame { position: relative; border: 1px solid var(--line); background: #000; padding: 14px; display: grid; place-items: center; min-height: 150px; }
#apple-screen, #pel-screen { display: block; width: 100%; max-width: 960px; height: auto; background: #000; image-rendering: pixelated; touch-action: manipulation; cursor: text; }
#apple-screen { max-width: 728px; }
.screen-frame.drag-over { outline: 2px solid var(--accent); outline-offset: -2px; }
.drop-message { position: absolute; inset: 0; display: grid; place-items: center; background: #101010e8; color: var(--paper); font-family: "Courier New", monospace; padding: 20px; text-align: center; pointer-events: none; }
.screen-caption { display: flex; align-items: center; justify-content: space-between; gap: 10px; color: var(--muted); font: 10px/1.5 "Courier New", monospace; margin: 9px 0 14px; }
.muted { color: #777268; }
.text-button { color: var(--muted); background: none; border: 0; padding: 0; font-size: 10px; }
.text-button:hover:not(:disabled) { color: var(--paper); background: none; }
.transport { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.transport button { font-size: 12px; }
.clock-control { display: flex; gap: 8px; align-items: center; color: var(--muted); font-size: 11px; margin-left: 4px; }
select { padding: 7px 27px 7px 8px; }
.clock-control select { font-size: 11px; padding: 8px 21px 8px 7px; }
.cpu-status { margin-left: auto; font: 10px/1.5 "Courier New", monospace; color: var(--muted); }
.status { font-size: 12px; color: var(--muted); margin: 12px 0 0; min-height: 18px; overflow-wrap: anywhere; }
.status.error { color: #ffa27d; }
.control-column { display: flex; flex-direction: column; gap: 21px; }
.control-section { border-top: 1px solid var(--line); padding-top: 12px; }
.control-section .section-bar { margin-bottom: 15px; }
.memory-label { display: flex; justify-content: space-between; align-items: center; gap: 14px; font-size: 12px; }
.memory-label select { min-width: 102px; font-family: "Courier New", monospace; font-size: 12px; }
.control-note { margin: 9px 0 16px; font-size: 11px; line-height: 1.6; color: var(--muted); }
.switch-row { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-top: 1px solid #2d2b26; cursor: pointer; position: relative; }
.switch-row>span:first-child { flex: 1; }
.switch-row strong { display: block; font-weight: 400; font-size: 12px; }
.switch-row small { display: block; font-size: 10px; color: var(--muted); margin-top: 3px; }
.switch-row input { appearance: none; -webkit-appearance: none; position: absolute; width: 36px; height: 20px; margin: 0; right: 0; opacity: 0; cursor: pointer; z-index: 1; }
.switch { display: block; border: 1px solid #686358; width: 34px; height: 18px; padding: 3px; flex-shrink: 0; }
.switch::before { content: ""; display: block; background: var(--muted); width: 10px; height: 10px; transition: transform 120ms; }
.switch-row input:checked+.switch { border-color: var(--accent); }
.switch-row input:checked+.switch::before { background: var(--accent); transform: translateX(16px); }
.switch-row input:focus-visible+.switch { outline: 2px solid var(--accent); outline-offset: 3px; }
.glyph-sample { border: 1px dashed var(--line); margin: 2px 0 4px; padding: 10px; }
.glyph-sample span { display: block; font: 18px/1.6 "Courier New", monospace; letter-spacing: .08em; }
.glyph-sample small { display: block; font-size: 10px; color: var(--muted); }
.primary-button { display: flex; justify-content: space-between; align-items: center; gap: 14px; width: 100%; font-size: 12px; padding: 11px 13px; background: var(--paper); color: #101010; border-color: var(--paper); }
.primary-button:hover:not(:disabled) { background: #fff8e8; color: #101010; }
.file-button { display: flex; justify-content: space-between; align-items: center; gap: 10px; position: relative; padding: 9px 12px; border: 1px solid #686358; font-size: 12px; overflow: hidden; }
.file-button input { position: absolute; inset: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }
.file-button:focus-within { outline: 2px solid var(--accent); outline-offset: 3px; }
.file-note { font-size: 10px; color: var(--muted); margin: 7px 0; }
.disk-name { font: 10px/1.5 "Courier New", monospace; overflow-wrap: anywhere; color: var(--paper); margin: 12px 0; }
.rom-panel { margin-top: 15px; border-top: 1px solid #2d2b26; padding-top: 8px; }
.rom-panel summary { font-size: 11px; color: var(--muted); }
.rom-panel p { font-size: 10px; line-height: 1.6; color: var(--muted); }
.laboratory { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); margin-top: 25px; }
.laboratory>summary { list-style: none; display: flex; gap: 20px; align-items: center; padding: 14px 0; font-size: 13px; }
.laboratory>summary::-webkit-details-marker { display: none; }
.laboratory>summary small { font: 10px/1.5 "Courier New", monospace; color: var(--muted); }
.expand-sign { margin-left: auto; font: 22px/1 "Courier New", monospace; color: var(--muted); }
.laboratory[open] .expand-sign { transform: rotate(45deg); }
.laboratory-body { padding: 9px 0 10px; display: grid; grid-template-columns: minmax(0, 1fr) minmax(248px, 29%); gap: 24px; }
#native-screen { display: block; width: 100%; height: auto; border: 1px solid var(--line); background: #000; image-rendering: pixelated; }
.bank-controls { display: grid; grid-template-columns: .7fr 1fr 1fr; gap: 8px; margin: 14px 0 12px; }
.bank-controls label { display: block; font-size: 10px; color: var(--muted); }
.bank-controls select, .bank-controls input { display: block; width: 100%; margin-top: 5px; min-width: 0; font: 12px/1.5 "Courier New", monospace; padding: 6px 7px; }
.bank-actions { display: flex; gap: 8px; }
.bank-actions button { padding: 7px 11px; font-size: 11px; }
#lab-output { display: block; font: 10px/1.6 "Courier New", monospace; color: var(--accent); margin-top: 12px; overflow-wrap: anywhere; }
.app-footer { display: flex; justify-content: space-between; gap: 16px; margin-top: 14px; font: 9px/1.6 "Courier New", monospace; color: var(--muted); }
.profile-row { display: flex; align-items: center; gap: 13px; flex-wrap: wrap; margin: 0 0 22px; }
.profile-row label { font-size: 12px; }
.profile-row select { max-width: 100%; min-width: 0; font-size: 12px; }
.profile-row>span { font-size: 10px; color: var(--muted); }
.command-form { margin-top: 20px; border-top: 1px solid var(--line); padding-top: 14px; }
.command-form>label { display: block; font-size: 11px; color: var(--muted); margin-bottom: 8px; }
.command-form>div { display: flex; gap: 8px; }
.command-form input { width: 100%; min-width: 0; padding: 8px 10px; font-family: "Courier New", monospace; }
.command-form button { flex: 0 0 auto; font-size: 12px; }
.rom-actions { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.rom-actions button { padding: 8px 10px; font: 12px/1.4 "Courier New", monospace; }
.rom-name { color: var(--accent); font: 10px/1.6 "Courier New", monospace; overflow-wrap: anywhere; margin: 14px 0; }
.documentation-link { font-size: 11px; }
@media (min-width: 1100px) { .screen-frame { padding: 18px 28px; } }
@media (max-width: 760px) { #impuls-app { padding: 16px; } .app-header { align-items: start; } .eyebrow { font-size: 9px; letter-spacing: .07em; } h1 small { display: block; margin: 8px 0 0; } .evidence-link { font-size: 10px; max-width: 90px; white-space: normal; text-align: right; } .research-notice { margin-bottom: 18px; padding: 9px 11px; gap: 9px; } .research-notice p { font-size: 11px; } .workbench, .laboratory-body { grid-template-columns: 1fr; gap: 22px; } .control-column { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; } .screen-frame { padding: 9px; } #apple-screen { max-width: 560px; } .cpu-status { margin-left: auto; } .laboratory>summary { gap: 12px; } .app-footer { flex-wrap: wrap; gap: 4px; font-size: 9px; } }
@media (max-width: 470px) { .control-column { grid-template-columns: 1fr; gap: 22px; } .screen-caption { font-size: 9px; } .text-button { font-size: 9px; } .cpu-status { width: 100%; margin: 0; } .laboratory>summary small { max-width: 135px; font-size: 9px; } .transport { gap: 7px; } .clock-control { margin-left: auto; } .profile-row { gap: 9px; } .profile-row>span { width: 100%; } }
@media (prefers-reduced-motion: reduce) { .switch::before { transition: none; } }
