:root {
  color-scheme: dark;
  --bg: #07101c;
  --panel: #0c1625;
  --panel-deep: #091321;
  --raised: #111e2f;
  --line: #1b2c40;
  --line-soft: rgba(113, 148, 177, .13);
  --text: #e9f2f8;
  --muted: #74889e;
  --green: #38e5ae;
  --green-soft: rgba(56, 229, 174, .1);
  --cyan: #52c7ee;
  --amber: #f2b84b;
  --danger: #fa7180;
  --mono: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  --sans: Inter, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
}

* { box-sizing: border-box; }
html, body { width: 100%; height: 100%; margin: 0; overflow: hidden; }
body { font-family: var(--sans); color: var(--text); background: var(--bg); font-size: 13px; -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; }
button { color: inherit; cursor: pointer; }
button:disabled { cursor: wait; opacity: .6; }
button, select, input { outline: none; }
button:focus-visible, select:focus-visible, input:focus-visible, textarea:focus-visible { outline: 2px solid var(--cyan); outline-offset: 2px; }
svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; }
.svg-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.app-shell { height: 100dvh; min-height: 620px; display: flex; flex-direction: column; background: radial-gradient(circle at 49% -20%, rgba(31, 92, 120, .11), transparent 44%), var(--bg); }
.topbar { min-height: 74px; height: 74px; padding: 0 20px; display: grid; grid-template-columns: minmax(390px, 1fr) auto minmax(430px, 1fr); align-items: center; gap: 24px; border-bottom: 1px solid var(--line); background: rgba(10, 20, 34, .96); box-shadow: 0 5px 30px rgba(0, 0, 0, .2); z-index: 5; }
.brand-block { display: flex; align-items: center; gap: 12px; min-width: 0; }
.brand-mark { width: 43px; height: 43px; flex: none; position: relative; display: grid; place-items: center; border: 1px solid rgba(56, 229, 174, .4); background: linear-gradient(145deg, rgba(56, 229, 174, .13), rgba(56, 229, 174, .025)); clip-path: polygon(12% 0, 88% 0, 100% 12%, 100% 88%, 88% 100%, 12% 100%, 0 88%, 0 12%); }
.brand-mark svg { width: 29px; height: 29px; color: var(--green); opacity: .55; }
.brand-mark span { position: absolute; font: 700 10px var(--mono); color: var(--green); }
.system-title { font-size: 17px; font-weight: 650; letter-spacing: .5px; white-space: nowrap; }
.system-title > span { display: inline-block; margin-left: 5px; padding: 2px 5px; border: 1px solid rgba(82, 199, 238, .3); border-radius: 3px; color: var(--cyan); font: 600 10px var(--mono); vertical-align: 2px; }
.camera-readiness { margin-top: 6px; display: flex; align-items: center; gap: 6px; color: #9aacbd; font-size: 11px; white-space: nowrap; }
.camera-readiness b { margin-left: 7px; color: #425a70; font: 500 8px var(--mono); letter-spacing: 1.1px; }
.status-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); box-shadow: 0 0 9px var(--green); animation: breathe 2.2s ease-in-out infinite; }
.status-dot.pending { background: var(--amber); box-shadow: 0 0 9px var(--amber); }
.status-dot.error { background: var(--danger); box-shadow: 0 0 8px rgba(250, 113, 128, .5); }
.production-stats { display: flex; height: 44px; border-left: 1px solid var(--line); }
.stat { min-width: 108px; padding: 1px 22px 0; border-right: 1px solid var(--line); display: flex; flex-direction: column; justify-content: center; }
.stat > span { color: var(--muted); font-size: 10px; letter-spacing: .6px; }
.stat strong { display: flex; align-items: baseline; gap: 4px; margin-top: 2px; line-height: 1; }
.stat strong em { font: 600 22px var(--mono); font-style: normal; color: #f3f8fa; }
.stat strong small { color: #8da0b2; font-size: 10px; font-weight: 400; }
.engine-stat { min-width: 158px; position: relative; }
.engine-stat strong { color: var(--cyan); font: 600 13px var(--mono); letter-spacing: -.2px; }
.engine-stat i { position: absolute; right: 14px; top: 2px; color: var(--green); font: 500 7px var(--mono); font-style: normal; letter-spacing: .5px; }
.top-actions { display: flex; justify-content: flex-end; align-items: center; gap: 8px; min-width: 0; }
.select-wrap { height: 34px; min-width: 164px; max-width: 195px; display: flex; align-items: center; position: relative; border: 1px solid var(--line); border-radius: 5px; background: #0b1726; }
.select-wrap svg { width: 15px; height: 15px; position: absolute; left: 9px; color: #6f879a; pointer-events: none; }
.select-wrap select { width: 100%; height: 100%; padding: 0 25px 0 30px; border: 0; appearance: none; color: #9cb0c1; background: transparent; font-size: 10px; text-overflow: ellipsis; }
.select-wrap:after { content: ""; position: absolute; right: 10px; border: 4px solid transparent; border-top-color: #668096; pointer-events: none; }
.icon-button { width: 36px; height: 34px; display: inline-flex; align-items: center; justify-content: center; gap: 4px; border: 1px solid var(--line); border-radius: 5px; background: #0d1928; color: #93a8b9; transition: .2s ease; }
.icon-button:hover { color: var(--green); border-color: rgba(56, 229, 174, .4); background: var(--green-soft); }
.icon-button svg { width: 16px; height: 16px; }
.rotation-button { width: 56px; }
.rotation-button span { font: 500 9px var(--mono); }
.manage-button { height: 35px; display: flex; align-items: center; gap: 7px; padding: 0 13px; border: 1px solid #315167; border-radius: 5px; background: linear-gradient(180deg, #172a3b, #112232); color: #d8e8f1; font-size: 11px; white-space: nowrap; }
.manage-button:hover { border-color: var(--cyan); }
.manage-button svg { width: 15px; height: 15px; color: var(--cyan); }
.context-bar { height: 33px; min-height: 33px; padding: 0 19px; display: flex; align-items: center; justify-content: space-between; background: #091421; border-bottom: 1px solid rgba(55, 80, 102, .35); color: #73899c; font-size: 9px; letter-spacing: .25px; }
.context-bar > div { display: flex; align-items: center; gap: 10px; }
.context-bar i { width: 1px; height: 10px; background: #26384a; }
.context-index { padding: 2px 6px; color: var(--green); background: rgba(56, 229, 174, .07); border: 1px solid rgba(56, 229, 174, .16); border-radius: 3px; font: 600 9px var(--mono); }
.context-bar .muted { color: #4c6377; }
.tiny-dot { width: 5px; height: 5px; border-radius: 50%; background: var(--green); box-shadow: 0 0 6px rgba(56, 229, 174, .6); }
.context-right { font-family: var(--mono); }
.workspace { flex: 1; min-height: 0; display: grid; grid-template-columns: minmax(0, 29.3fr) minmax(0, 41.4fr) minmax(0, 29.3fr); gap: 11px; padding: 12px 14px 14px; }
.panel { min-width: 0; min-height: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 7px; background: linear-gradient(155deg, rgba(15, 28, 45, .98), rgba(9, 19, 32, .98)); box-shadow: 0 10px 30px rgba(0, 0, 0, .12); display: flex; flex-direction: column; position: relative; }
.panel:before { content: ""; position: absolute; left: 0; top: 0; width: 54px; height: 1px; background: var(--green); opacity: .55; z-index: 2; }
.document-panel:before { width: 90px; background: var(--cyan); }
.panel-heading { min-height: 57px; height: 57px; padding: 0 14px; display: flex; align-items: center; justify-content: space-between; gap: 8px; border-bottom: 1px solid var(--line); background: rgba(15, 27, 43, .65); }
.heading-copy { display: flex; align-items: center; gap: 10px; min-width: 0; }
.section-number { color: #334b61; font: 500 21px var(--mono); }
.heading-copy h2 { margin: 0; font-size: 13px; font-weight: 600; letter-spacing: .5px; white-space: nowrap; }
.heading-copy p { margin: 4px 0 0; color: #4f687d; font: 500 8px var(--mono); letter-spacing: 1.15px; }
.outline-badge { display: inline-flex; align-items: center; gap: 5px; min-height: 22px; padding: 0 7px; border: 1px solid rgba(56, 229, 174, .2); border-radius: 3px; background: rgba(56, 229, 174, .04); color: var(--green); font: 500 8px var(--mono); letter-spacing: .5px; white-space: nowrap; }
.outline-badge > i { width: 4px; height: 4px; border-radius: 50%; background: currentColor; box-shadow: 0 0 5px currentColor; }
.outline-badge svg { width: 12px; height: 12px; }
.outline-badge.cyan { color: var(--cyan); border-color: rgba(82, 199, 238, .2); background: rgba(82, 199, 238, .04); }
.capture-content, .document-content, .checklist-content { flex: 1; min-height: 0; padding: 13px; display: flex; flex-direction: column; }
.video-shell { width: 100%; aspect-ratio: 16 / 9; max-height: 38vh; min-height: 190px; flex: none; position: relative; overflow: hidden; border: 1px solid #253a4d; border-radius: 5px; background: #04090f; }
.video-shell video, .freeze-frame { width: 100%; height: 100%; display: block; object-fit: contain; background: #04090f; transition: transform .35s ease, opacity .25s; }
.video-shell video { opacity: 0; }
.video-shell.camera-ready video { opacity: 1; }
.freeze-frame { position: absolute; inset: 0; opacity: 0; z-index: 2; }
.freeze-frame.visible { opacity: 1; }
.camera-placeholder { position: absolute; inset: 0; z-index: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; background: radial-gradient(circle, #102638 0, #07111d 58%, #050c14 100%); }
.camera-placeholder.hidden { display: none; }
.optical-graphic { width: 80px; height: 80px; display: grid; place-items: center; position: relative; margin-bottom: 9px; }
.optical-graphic:before, .optical-graphic:after, .optical-graphic > span { content: ""; position: absolute; inset: 0; border: 1px solid rgba(82, 199, 238, .16); border-radius: 50%; }
.optical-graphic:after { inset: 12px; border-style: dashed; animation: spin 12s linear infinite; }
.optical-graphic > span:first-child { inset: 25px; border-color: rgba(56, 229, 174, .3); }
.optical-graphic > span:nth-child(2) { width: 100px; height: 1px; inset: 50% auto auto -10px; border: 0; border-top: 1px solid rgba(82, 199, 238, .1); border-radius: 0; }
.optical-graphic svg { width: 24px; height: 24px; color: #558199; }
.camera-placeholder strong { color: #b8cad6; font-size: 12px; font-weight: 500; }
.camera-placeholder p { max-width: 85%; margin: 7px 20px 4px; color: #5f788c; font-size: 10px; line-height: 1.65; }
.text-button { display: inline-flex; align-items: center; gap: 5px; padding: 4px 7px; border: 0; color: var(--cyan); background: transparent; font-size: 10px; }
.text-button svg { width: 12px; height: 12px; }
.frame-grid { position: absolute; inset: 0; z-index: 3; pointer-events: none; opacity: .12; background-image: linear-gradient(to right, transparent 33.2%, #78a0b5 33.3%, #78a0b5 33.5%, transparent 33.6%, transparent 66.4%, #78a0b5 66.5%, #78a0b5 66.7%, transparent 66.8%), linear-gradient(to bottom, transparent 33.2%, #78a0b5 33.3%, #78a0b5 33.5%, transparent 33.6%, transparent 66.4%, #78a0b5 66.5%, #78a0b5 66.7%, transparent 66.8%); }
.viewfinder-corners { position: absolute; inset: 27px 18px 26px; z-index: 5; pointer-events: none; }
.viewfinder-corners i { position: absolute; width: 20px; height: 20px; border-color: var(--green); border-style: solid; filter: drop-shadow(0 0 3px rgba(56, 229, 174, .4)); }
.viewfinder-corners i:nth-child(1) { left: 0; top: 0; border-width: 2px 0 0 2px; }
.viewfinder-corners i:nth-child(2) { right: 0; top: 0; border-width: 2px 2px 0 0; }
.viewfinder-corners i:nth-child(3) { right: 0; bottom: 0; border-width: 0 2px 2px 0; }
.viewfinder-corners i:nth-child(4) { left: 0; bottom: 0; border-width: 0 0 2px 2px; }
.video-topline, .video-bottomline { position: absolute; left: 12px; right: 12px; z-index: 6; display: flex; justify-content: space-between; align-items: center; pointer-events: none; color: #7d9aab; font: 500 7px var(--mono); letter-spacing: .5px; text-shadow: 0 1px 2px #000; }
.video-topline { top: 9px; }
.video-topline > span:first-child { display: flex; align-items: center; gap: 5px; color: #a2b7c4; font-family: var(--sans); }
.video-topline b { font-size: 8px; font-weight: 500; }
.record-dot { width: 5px; height: 5px; background: var(--green); border-radius: 50%; box-shadow: 0 0 6px var(--green); }
.video-bottomline { bottom: 8px; }
.laser-line { position: absolute; z-index: 7; left: 4%; right: 4%; top: 10%; height: 1px; opacity: 0; pointer-events: none; background: #68ffd1; box-shadow: 0 0 5px #38e5ae, 0 0 18px 4px rgba(56, 229, 174, .45); }
.video-shell.scanning .laser-line { opacity: .85; animation: laserScan 2s ease-in-out infinite; }
.video-shell.scanning:after { content: ""; position: absolute; inset: 0; z-index: 4; background: linear-gradient(180deg, transparent 45%, rgba(56, 229, 174, .04) 50%, transparent 55%); background-size: 100% 80px; animation: backgroundScan 2s linear infinite; pointer-events: none; }
.qr-tracker { display: none; position: absolute; z-index: 9; min-width: 40px; min-height: 40px; border: 1px solid var(--green); background: rgba(56, 229, 174, .05); box-shadow: 0 0 16px rgba(56, 229, 174, .15); pointer-events: none; }
.qr-tracker.visible { display: block; animation: trackerIn .35s ease; }
.qr-tracker > span { position: absolute; left: -1px; top: -17px; padding: 2px 4px; color: #06150f; background: var(--green); font: 600 7px var(--mono); white-space: nowrap; }
.qr-tracker > i { position: absolute; width: 7px; height: 7px; border-color: #c4ffeb; border-style: solid; }
.qr-tracker > i:nth-of-type(1) { left: -2px; top: -2px; border-width: 2px 0 0 2px; }
.qr-tracker > i:nth-of-type(2) { right: -2px; top: -2px; border-width: 2px 2px 0 0; }
.qr-tracker > i:nth-of-type(3) { right: -2px; bottom: -2px; border-width: 0 2px 2px 0; }
.qr-tracker > i:nth-of-type(4) { left: -2px; bottom: -2px; border-width: 0 0 2px 2px; }
.capture-actions { display: grid; grid-template-columns: 1fr auto; gap: 8px; margin-top: 12px; }
.primary-action { height: 55px; padding: 0 12px; position: relative; overflow: hidden; display: flex; align-items: center; gap: 10px; text-align: left; border: 1px solid #49f0bc; border-radius: 5px; background: linear-gradient(135deg, #18ba87, #0b956e); box-shadow: 0 5px 18px rgba(11, 181, 132, .16), inset 0 1px rgba(255, 255, 255, .14); color: #031b13; }
.primary-action:hover { filter: brightness(1.08); box-shadow: 0 5px 24px rgba(56, 229, 174, .26); }
.primary-action > svg { width: 24px; height: 24px; position: relative; }
.primary-action > span:not(.button-sheen) { position: relative; display: flex; flex-direction: column; gap: 3px; }
.primary-action b { font-size: 12px; font-weight: 700; }
.primary-action small { font: 600 7px var(--mono); letter-spacing: 1px; opacity: .68; }
.primary-action kbd { position: relative; margin-left: auto; padding: 3px 5px; border: 1px solid rgba(0, 30, 20, .22); border-radius: 3px; color: rgba(2, 34, 23, .7); background: rgba(255, 255, 255, .08); font: 600 7px var(--mono); }
.button-sheen { position: absolute; inset: 0; background: linear-gradient(105deg, transparent 35%, rgba(255, 255, 255, .13) 50%, transparent 65%); transform: translateX(-100%); animation: sheen 5s ease-in-out infinite; }
.primary-action.running { border-color: var(--amber); background: linear-gradient(135deg, #a87723, #785412); color: #fff3d4; }
.reset-action { width: 70px; border: 1px solid #2a3c4e; border-radius: 5px; background: #122030; color: #90a4b6; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 4px; font-size: 9px; }
.reset-action svg { width: 17px; height: 17px; }
.reset-action:hover { border-color: #55748a; color: #d7e5ec; }
.device-card, .readiness-card { margin-top: 12px; padding: 12px; border: 1px solid var(--line-soft); border-radius: 5px; background: rgba(8, 19, 31, .55); }
.subsection-title { display: flex; align-items: center; justify-content: space-between; padding-bottom: 9px; margin-bottom: 10px; border-bottom: 1px solid var(--line-soft); }
.subsection-title > span { color: #a7b9c6; font-size: 10px; font-weight: 600; }
.subsection-title small { color: #3e586d; font: 500 7px var(--mono); letter-spacing: .7px; }
.telemetry-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 20px; }
.telemetry-grid > div { display: flex; flex-direction: column; gap: 5px; }
.telemetry-grid span { color: #536b80; font-size: 9px; }
.telemetry-grid strong { display: flex; align-items: center; gap: 5px; color: #b7c8d3; font: 500 10px var(--mono); }
.ok-dot { display: inline-block; width: 5px; height: 5px; border-radius: 50%; background: var(--green); box-shadow: 0 0 5px rgba(56, 229, 174, .5); }
.readiness-card { padding-bottom: 8px; }
.readiness-row { display: flex; align-items: center; justify-content: space-between; padding: 5px 0; color: #71889b; font-size: 9px; }
.readiness-row > span { display: flex; align-items: center; gap: 7px; }
.readiness-row i { width: 16px; height: 16px; display: grid; place-items: center; border: 1px solid #263c4d; border-radius: 50%; color: #638094; font: 500 8px var(--mono); font-style: normal; }
.readiness-row b { color: var(--green); font: 500 7px var(--mono); letter-spacing: .5px; }
.shortcut-hint { margin-top: auto; padding: 11px 2px 0; display: flex; align-items: center; gap: 7px; color: #60788c; font-size: 9px; }
.shortcut-hint small { margin-left: auto; color: #3e566a; font: 500 8px var(--mono); }
.keyboard-icon { width: 18px; height: 18px; display: grid; place-items: center; border: 1px solid #2a4053; border-radius: 3px; font-size: 10px; }
.document-content { padding: 12px 13px 11px; }
.analysis-progress { flex: none; padding: 0 2px 11px; }
.progress-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.progress-top > div:first-child { display: flex; align-items: center; min-width: 0; }
.stage-indicator { min-width: 62px; padding: 3px 5px; margin-right: 8px; text-align: center; color: #637d91; border: 1px solid #283c4d; border-radius: 3px; font: 500 8px var(--mono); }
.stage-indicator.running { color: var(--green); border-color: rgba(56, 229, 174, .3); background: var(--green-soft); }
.progress-top strong#stageLog { overflow: hidden; color: #8da4b5; font-size: 10px; font-weight: 500; white-space: nowrap; text-overflow: ellipsis; }
.progress-numbers { display: flex; align-items: baseline; gap: 12px; }
.progress-numbers > strong { color: var(--green); font: 600 22px var(--mono); }
.progress-numbers > strong small { font-size: 10px; }
.progress-numbers > span { min-width: 42px; color: #8da5b6; font: 500 11px var(--mono); }
.progress-track { height: 5px; position: relative; border-radius: 3px; background: #17283a; box-shadow: inset 0 1px 2px rgba(0, 0, 0, .3); }
.progress-fill { width: 0; height: 100%; position: relative; border-radius: inherit; background: linear-gradient(90deg, #159d84, var(--green), #79f8d3); box-shadow: 0 0 10px rgba(56, 229, 174, .25); }
.progress-fill:after { content: ""; position: absolute; right: -2px; top: -2px; width: 3px; height: 9px; border-radius: 2px; background: #c3ffed; box-shadow: 0 0 7px var(--green); }
.progress-track > i { position: absolute; top: 0; width: 1px; height: 5px; background: #091522; }
.stage-labels { display: flex; justify-content: space-between; margin-top: 8px; color: #425d72; font-size: 8px; }
.stage-labels span { transition: color .25s; }
.stage-labels span.active { color: var(--green); }
.stage-labels span.complete { color: #8099a9; }
.document-viewport { flex: 1; min-height: 260px; position: relative; display: flex; align-items: center; justify-content: center; padding: 23px 15px 15px 26px; overflow: hidden; border: 1px solid #1c3245; border-radius: 4px; background-color: #07111c; background-image: linear-gradient(rgba(67, 101, 128, .055) 1px, transparent 1px), linear-gradient(90deg, rgba(67, 101, 128, .055) 1px, transparent 1px); background-size: 20px 20px; }
.viewport-ruler { position: absolute; z-index: 2; display: flex; justify-content: space-between; color: #355065; font: 500 7px var(--mono); pointer-events: none; }
.ruler-top { left: 27px; right: 10px; top: 7px; }
.ruler-left { left: 7px; top: 26px; bottom: 12px; flex-direction: column; }
.document-page { width: 100%; max-height: 100%; aspect-ratio: 1190.55 / 841.89; position: relative; background: #fdfdfd; box-shadow: 0 8px 30px rgba(0, 0, 0, .42), 0 0 0 1px rgba(180, 211, 224, .12); transition: opacity .4s ease; overflow: hidden; }
.document-page.idle { background: linear-gradient(135deg, rgba(20, 40, 55, .7), rgba(11, 26, 39, .9)); box-shadow: 0 8px 30px rgba(0, 0, 0, .2), 0 0 0 1px rgba(82, 199, 238, .09); }
.document-page > img { width: 100%; height: 100%; display: block; object-fit: contain; opacity: 0; transition: opacity .8s ease; }
.document-page.loaded > img { opacity: 1; }
.document-idle { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; color: #6f899c; transition: opacity .3s; }
.document-page.loaded .document-idle { opacity: 0; pointer-events: none; }
.idle-document-icon { width: 76px; height: 90px; margin-bottom: 20px; padding: 29px 15px 0; position: relative; border: 1px solid #2c4b60; border-radius: 4px; background: rgba(82, 199, 238, .03); }
.idle-document-icon:before { content: ""; position: absolute; right: -1px; top: -1px; border-style: solid; border-width: 0 0 19px 19px; border-color: transparent transparent #2c4b60 transparent; }
.idle-document-icon svg { position: absolute; top: 11px; left: 13px; width: 20px; height: 20px; color: #4c7288; }
.idle-document-icon i { display: block; height: 2px; margin-bottom: 8px; background: #284356; }
.idle-document-icon i:nth-of-type(2) { width: 75%; }
.idle-document-icon i:nth-of-type(3) { width: 88%; }
.document-idle strong { color: #9bb0be; font-size: 13px; font-weight: 500; }
.document-idle p { margin: 8px 0 17px; color: #4c687c; font-size: 10px; }
.document-idle > span { display: flex; align-items: center; gap: 6px; color: #3a776f; font: 500 7px var(--mono); letter-spacing: 1px; }
.document-idle > span i { width: 5px; height: 5px; border-radius: 50%; background: var(--green); }
.scan-zones { position: absolute; inset: 0; pointer-events: none; }
.scan-zone { position: absolute; opacity: 0; border: 1px solid var(--green); background: rgba(30, 238, 171, .085); box-shadow: inset 0 0 16px rgba(56, 229, 174, .07), 0 0 8px rgba(56, 229, 174, .16); transform: scale(.97); transition: opacity .25s, transform .25s; overflow: visible; }
.scan-zone.active { opacity: 1; transform: scale(1); }
.scan-zone:after { content: ""; position: absolute; left: 0; right: 0; height: 1px; top: 0; background: rgba(62, 255, 197, .9); box-shadow: 0 0 8px 2px rgba(56, 229, 174, .35); animation: zoneScan 1.35s ease-in-out infinite; }
.scan-zone > span { position: absolute; left: -1px; top: -20px; padding: 4px 6px; color: #06271b; background: var(--green); font: 600 8px var(--sans); letter-spacing: .2px; white-space: nowrap; box-shadow: 0 2px 6px rgba(0, 0, 0, .2); }
.scan-zone > i { position: absolute; width: 9px; height: 9px; border-color: #d0fff0; border-style: solid; }
.scan-zone > i:nth-of-type(1) { left: -2px; top: -2px; border-width: 2px 0 0 2px; }
.scan-zone > i:nth-of-type(2) { right: -2px; top: -2px; border-width: 2px 2px 0 0; }
.scan-zone > i:nth-of-type(3) { right: -2px; bottom: -2px; border-width: 0 2px 2px 0; }
.scan-zone > i:nth-of-type(4) { left: -2px; bottom: -2px; border-width: 0 0 2px 2px; }
.scan-zones.confirmed .scan-zone { opacity: .55; transform: scale(1); animation: confirmZone .6s ease; background: rgba(56, 229, 174, .04); }
.scan-zones.confirmed .scan-zone:after { display: none; }
.scan-zones.confirmed .scan-zone > span { opacity: .75; }
.page-corner-marks { display: none; position: absolute; inset: 4px; pointer-events: none; }
.document-page.loaded .page-corner-marks { display: block; }
.page-corner-marks i { position: absolute; width: 10px; height: 10px; border-color: rgba(10, 80, 65, .35); border-style: solid; }
.page-corner-marks i:nth-child(1) { left: 0; top: 0; border-width: 1px 0 0 1px; }
.page-corner-marks i:nth-child(2) { right: 0; top: 0; border-width: 1px 1px 0 0; }
.page-corner-marks i:nth-child(3) { right: 0; bottom: 0; border-width: 0 1px 1px 0; }
.page-corner-marks i:nth-child(4) { left: 0; bottom: 0; border-width: 0 0 1px 1px; }
.confidence-badge { position: absolute; right: 23px; top: 31px; z-index: 4; display: flex; align-items: center; gap: 9px; padding: 7px 9px; border: 1px solid rgba(56, 229, 174, .45); border-radius: 3px; background: rgba(5, 31, 27, .94); box-shadow: 0 5px 20px rgba(0, 0, 0, .25); opacity: 0; transform: translateY(-6px); transition: .35s ease; pointer-events: none; }
.confidence-badge.visible { opacity: 1; transform: translateY(0); }
.confidence-badge span { color: #a4c9be; font-size: 8px; }
.confidence-badge strong { color: var(--green); font: 600 15px var(--mono); }
.confidence-badge small { font-size: 8px; }
.document-footer { min-height: 52px; padding: 11px 2px 0; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.file-identity { display: flex; align-items: center; gap: 9px; min-width: 0; }
.pdf-icon { width: 30px; height: 34px; flex: none; display: grid; place-items: center; border: 1px solid #31516a; border-radius: 3px; background: rgba(82, 199, 238, .04); color: var(--cyan); font: 600 8px var(--mono); }
.file-identity > div { min-width: 0; display: flex; flex-direction: column; gap: 4px; }
.file-identity strong { max-width: 430px; overflow: hidden; color: #a7bac8; font-size: 9px; font-weight: 500; white-space: nowrap; text-overflow: ellipsis; }
.file-identity > div > span { color: #456176; font-size: 8px; }
.render-meta { display: flex; flex-direction: column; align-items: flex-end; gap: 5px; flex: none; }
.render-meta > span { display: flex; align-items: center; gap: 4px; color: #4f6a7e; font-size: 8px; }
.render-meta i { width: 4px; height: 4px; border-radius: 50%; background: var(--green); }
.render-meta b { color: var(--green); font: 500 8px var(--mono); }
.checklist-content { padding: 12px; }
.sample-summary { flex: none; padding: 12px; border: 1px solid rgba(82, 199, 238, .16); border-radius: 5px; background: linear-gradient(135deg, rgba(25, 57, 75, .36), rgba(10, 24, 38, .5)); position: relative; overflow: hidden; }
.sample-summary:after { content: ""; position: absolute; right: -35px; top: -50px; width: 120px; height: 120px; border: 1px solid rgba(82, 199, 238, .05); border-radius: 50%; box-shadow: 0 0 0 18px rgba(82, 199, 238, .018), 0 0 0 36px rgba(82, 199, 238, .012); pointer-events: none; }
.sample-summary-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 8px; position: relative; z-index: 1; }
.sample-summary-top > span { display: flex; align-items: center; gap: 5px; color: var(--cyan); font-size: 8px; }
.sample-summary-top > span i { width: 5px; height: 5px; border-radius: 50%; background: var(--cyan); box-shadow: 0 0 6px rgba(82, 199, 238, .5); }
.sample-summary-top > span.matched { color: var(--green); }
.sample-summary-top > span.matched i { background: var(--green); }
.sample-summary-top b { padding: 2px 5px; border: 1px solid #2a4356; border-radius: 3px; color: #678498; font: 500 7px var(--mono); }
.sample-summary h3 { height: 32px; margin: 0 0 8px; overflow: hidden; position: relative; z-index: 1; color: #dce9ef; font-size: 12px; font-weight: 600; line-height: 1.4; }
.sample-tags { display: flex; gap: 5px; position: relative; z-index: 1; }
.sample-tags span { max-width: 48%; padding: 3px 5px; overflow: hidden; border: 1px solid #233b4d; border-radius: 3px; color: #7e98aa; background: rgba(8, 19, 30, .4); font: 500 7px var(--mono); white-space: nowrap; text-overflow: ellipsis; }
.sample-tags span:first-child { color: var(--cyan); border-color: rgba(82, 199, 238, .18); }
.primary-code { margin-top: 10px; padding-top: 9px; display: flex; align-items: center; justify-content: space-between; gap: 8px; border-top: 1px solid rgba(82, 132, 158, .13); position: relative; z-index: 1; }
.primary-code > span { display: flex; align-items: center; gap: 5px; color: #668297; font-size: 8px; white-space: nowrap; }
.primary-code svg { width: 12px; height: 12px; }
.primary-code code { max-width: 57%; overflow: hidden; color: var(--green); font: 500 8px var(--mono); white-space: nowrap; text-overflow: ellipsis; }
.checklist-heading { min-height: 37px; display: flex; align-items: center; justify-content: space-between; padding: 0 2px; }
.checklist-heading > span { color: #879eae; font-size: 10px; font-weight: 600; }
.checklist-heading small { color: #3c566b; font: 500 7px var(--mono); letter-spacing: .7px; }
.check-items { flex: 1; min-height: 260px; display: grid; grid-template-rows: repeat(8, minmax(42px, 1fr)); gap: 5px; }
.check-item { min-height: 0; padding: 7px 9px; display: grid; grid-template-columns: 23px minmax(0, 1fr) auto; align-items: center; gap: 8px; border: 1px solid #1b2d3e; border-radius: 4px; background: rgba(11, 23, 37, .7); transition: border-color .35s, background .35s, transform .35s; }
.state-icon { width: 22px; height: 22px; display: grid; place-items: center; position: relative; border: 1px solid #293b4b; border-radius: 50%; color: #496174; background: #101e2d; }
.state-icon svg { width: 12px; height: 12px; }
.state-icon span { font: 500 8px var(--mono); }
.check-copy { min-width: 0; }
.check-title-line { display: flex; align-items: center; gap: 6px; min-width: 0; }
.check-category { flex: none; padding: 2px 4px; border-radius: 2px; color: #607b8e; background: #172737; font-size: 7px; }
.check-title-line strong { overflow: hidden; color: #96aaba; font-size: 9px; font-weight: 500; white-space: nowrap; text-overflow: ellipsis; }
.check-copy > p { margin: 5px 0 0; overflow: hidden; color: #4d687c; font-size: 8px; white-space: nowrap; text-overflow: ellipsis; }
.check-state { min-width: 49px; text-align: right; color: #435d70; font: 500 7px var(--mono); }
.check-state b { display: block; font-weight: 500; }
.check-state small { display: block; margin-top: 4px; font-size: 6px; letter-spacing: .4px; }
.check-item.active { border-color: rgba(242, 184, 75, .48); background: linear-gradient(90deg, rgba(242, 184, 75, .09), rgba(20, 28, 38, .7)); transform: translateX(-2px); }
.check-item.active .state-icon { border-color: var(--amber); border-top-color: transparent; color: var(--amber); background: rgba(242, 184, 75, .07); animation: spin 1.1s linear infinite; }
.check-item.active .check-title-line strong, .check-item.active .check-state { color: var(--amber); }
.check-item.active .check-copy > p { color: #a68c5e; }
.check-item.passed { border-color: rgba(56, 229, 174, .19); background: linear-gradient(90deg, rgba(56, 229, 174, .055), rgba(11, 24, 37, .7)); }
.check-item.passed .state-icon { border-color: rgba(56, 229, 174, .5); color: var(--green); background: rgba(56, 229, 174, .1); }
.check-item.passed .check-title-line strong { color: #bed3d9; }
.check-item.passed .check-copy > p { color: #6c8d8e; }
.check-item.passed .check-state { color: var(--green); }
.terminal-card { min-height: 83px; height: 83px; margin-top: 10px; padding: 7px 9px; flex: none; overflow: hidden; border: 1px solid #172c3b; border-radius: 4px; background: #06111b; font-family: var(--mono); }
.terminal-heading { display: flex; align-items: center; gap: 7px; padding-bottom: 6px; border-bottom: 1px solid #152635; }
.terminal-heading > span { display: flex; gap: 3px; }
.terminal-heading > span i { width: 4px; height: 4px; border-radius: 50%; background: #345065; }
.terminal-heading > span i:first-child { background: #4e806f; }
.terminal-heading b { color: #6b8596; font: 500 7px var(--sans); }
.terminal-heading small { margin-left: auto; color: #294659; font-size: 6px; }
.terminal-logs { height: 51px; padding-top: 5px; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; gap: 3px; }
.terminal-logs > div { overflow: hidden; color: #5f887e; font-size: 7px; line-height: 1.25; white-space: nowrap; text-overflow: ellipsis; animation: logIn .25s ease; }
.terminal-logs > div span { margin-right: 6px; color: #345b60; }
.terminal-logs > div:last-child { color: #83b7a4; }
.result-card { height: 78px; min-height: 78px; margin-top: 10px; padding: 9px 11px; display: grid; grid-template-columns: 39px 1fr auto; align-items: center; gap: 10px; border: 1px solid rgba(56, 229, 174, .5); border-radius: 5px; background: linear-gradient(115deg, rgba(23, 112, 85, .32), rgba(8, 39, 32, .85)); box-shadow: 0 0 24px rgba(56, 229, 174, .08), inset 0 0 22px rgba(56, 229, 174, .04); opacity: 0; transform: translateY(9px); visibility: hidden; transition: opacity .45s, transform .45s, visibility .45s; }
.result-card.visible { opacity: 1; transform: translateY(0); visibility: visible; animation: resultGlow 1.2s ease; }
.result-icon { width: 37px; height: 37px; display: grid; place-items: center; border: 1px solid var(--green); border-radius: 50%; color: var(--green); box-shadow: 0 0 12px rgba(56, 229, 174, .14); }
.result-icon svg { width: 23px; height: 23px; stroke-width: 2; }
.result-card > div:nth-child(2) > span { display: block; margin-bottom: 3px; color: #5b9d89; font: 500 6px var(--mono); letter-spacing: 1px; }
.result-card strong { color: #d5ffef; font-size: 16px; font-weight: 650; }
.result-card strong b { margin-left: 5px; color: var(--green); font: 600 13px var(--mono); }
.result-card p { display: flex; align-items: center; gap: 6px; margin: 4px 0 0; color: #78a99b; font: 500 7px var(--mono); }
.result-card p i { width: 1px; height: 7px; background: #315f52; }
.result-seal { width: 52px; height: 52px; display: flex; flex-direction: column; align-items: center; justify-content: center; border: 2px solid rgba(56, 229, 174, .5); border-radius: 50%; color: rgba(56, 229, 174, .8); font: 700 12px var(--mono); transform: rotate(-9deg); }
.result-seal small { margin-top: 2px; font-size: 5px; letter-spacing: .3px; }
.modal-backdrop { position: fixed; inset: 0; z-index: 100; display: flex; align-items: center; justify-content: center; padding: 28px; background: rgba(2, 7, 13, .82); backdrop-filter: blur(8px); opacity: 0; visibility: hidden; transition: .2s; }
.modal-backdrop.open { opacity: 1; visibility: visible; }
.manager-modal { width: min(1220px, 96vw); height: min(880px, 91vh); display: flex; flex-direction: column; overflow: hidden; border: 1px solid #2b4457; border-radius: 9px; background: #0b1725; box-shadow: 0 25px 90px rgba(0, 0, 0, .6); transform: translateY(12px) scale(.99); transition: .25s; }
.modal-backdrop.open .manager-modal { transform: translateY(0) scale(1); }
.manager-header { min-height: 78px; padding: 0 22px; display: flex; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); background: #0e1c2c; }
.manager-kicker { color: var(--green); font: 500 7px var(--mono); letter-spacing: 1.8px; }
.manager-header h2 { margin: 5px 0 0; font-size: 18px; font-weight: 600; }
.manager-header h2 small { margin-left: 12px; color: #597386; font-size: 10px; font-weight: 400; }
.manager-body { flex: 1; min-height: 0; display: grid; grid-template-columns: 280px 1fr; }
.manager-sidebar { padding: 18px; overflow-y: auto; border-right: 1px solid var(--line); background: #091421; }
.pdf-dropzone { min-height: 195px; padding: 22px 14px; display: flex; flex-direction: column; align-items: center; justify-content: center; border: 1px dashed #315469; border-radius: 6px; background: rgba(82, 199, 238, .025); text-align: center; transition: .2s; cursor: pointer; }
.pdf-dropzone:hover, .pdf-dropzone.dragging { border-color: var(--green); background: rgba(56, 229, 174, .045); }
.pdf-dropzone > svg { width: 31px; height: 31px; margin-bottom: 12px; color: var(--cyan); }
.pdf-dropzone strong { font-size: 12px; }
.pdf-dropzone p { margin: 8px 0; color: #617d91; font-size: 9px; }
.pdf-dropzone > span { color: #3f5b70; font-size: 8px; }
.secondary-button { margin-top: 15px; padding: 7px 16px; border: 1px solid #315267; border-radius: 4px; background: #132638; color: #a5bdcc; font-size: 10px; }
.upload-status { max-height: 80px; overflow: hidden; color: var(--green); font-size: 9px; line-height: 1.5; }
.manager-setting { margin-top: 20px; padding: 15px; border: 1px solid var(--line); border-radius: 5px; background: #0d1a29; }
.setting-heading { display: flex; justify-content: space-between; align-items: center; }
.setting-heading span { color: #a4b8c6; font-size: 11px; }
.setting-heading strong { color: var(--green); font: 600 12px var(--mono); }
.manager-setting input[type="range"] { width: 100%; height: 4px; margin: 20px 0 8px; appearance: none; border-radius: 3px; background: linear-gradient(90deg, var(--green) 60%, #24384a 60%); }
.manager-setting input[type="range"]::-webkit-slider-thumb { width: 14px; height: 14px; appearance: none; border: 3px solid #c0ffeb; border-radius: 50%; background: var(--green); box-shadow: 0 0 8px rgba(56, 229, 174, .4); }
.range-labels { display: flex; justify-content: space-between; color: #4b6579; font: 500 8px var(--mono); }
.manager-setting p { margin: 12px 0 0; color: #536e81; font-size: 9px; line-height: 1.5; }
.fallback-setting { margin-top: 13px; padding: 14px; display: flex; align-items: flex-start; gap: 10px; border: 1px solid var(--line); border-radius: 5px; background: #0d1a29; cursor: pointer; }
.fallback-setting > input { position: absolute; opacity: 0; pointer-events: none; }
.toggle-track { width: 32px; height: 17px; padding: 2px; flex: none; border-radius: 10px; background: #2b3e4f; transition: .2s; }
.toggle-track i { display: block; width: 13px; height: 13px; border-radius: 50%; background: #8ca0af; transition: .2s; }
.fallback-setting input:checked + .toggle-track { background: #167e63; }
.fallback-setting input:checked + .toggle-track i { transform: translateX(15px); background: #baffea; }
.fallback-setting > span:last-child { display: flex; flex-direction: column; gap: 5px; }
.fallback-setting strong { color: #b2c4d0; font-size: 10px; }
.fallback-setting small { color: #526e82; font-size: 8px; line-height: 1.55; }
.manager-help { margin-top: 16px; display: flex; gap: 10px; color: #4e6b7f; }
.manager-help svg { width: 18px; height: 18px; flex: none; color: #4d7e8a; }
.manager-help strong { color: #6d8798; font-size: 9px; }
.manager-help p { margin: 5px 0 0; font-size: 8px; line-height: 1.7; }
.sample-manager-content { min-width: 0; min-height: 0; padding: 18px 20px; display: flex; flex-direction: column; }
.sample-manager-heading { min-height: 35px; display: flex; align-items: flex-start; justify-content: space-between; }
.sample-manager-heading > div { display: flex; align-items: center; gap: 10px; }
.sample-manager-heading strong { font-size: 12px; }
.sample-manager-heading span { color: #587286; font-size: 9px; }
.sample-manager-heading > div span { padding: 2px 5px; border-radius: 3px; background: #142638; }
.sample-manager-list { flex: 1; min-height: 0; padding-right: 5px; overflow-y: auto; display: flex; flex-direction: column; gap: 8px; }
.sample-manager-list::-webkit-scrollbar, .manager-sidebar::-webkit-scrollbar { width: 5px; }
.sample-manager-list::-webkit-scrollbar-thumb, .manager-sidebar::-webkit-scrollbar-thumb { border-radius: 4px; background: #294153; }
.manager-sample { flex: none; overflow: hidden; border: 1px solid #1d3345; border-radius: 5px; background: #0e1c2b; }
.manager-sample.expanded { border-color: #315366; }
.manager-sample-row { min-height: 67px; padding: 10px 12px; display: grid; grid-template-columns: 36px minmax(0, 1fr) 88px auto; align-items: center; gap: 11px; }
.manager-hotkey { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid #2a4659; border-radius: 4px; color: var(--cyan); background: #102334; font: 600 12px var(--mono); }
.manager-sample-info { min-width: 0; }
.manager-sample-info strong { display: block; overflow: hidden; color: #bccdd8; font-size: 10px; font-weight: 500; white-space: nowrap; text-overflow: ellipsis; }
.manager-sample-info span { display: block; margin-top: 6px; overflow: hidden; color: #526e81; font: 500 8px var(--mono); white-space: nowrap; text-overflow: ellipsis; }
.qr-binding-state { color: #8a744e; font-size: 8px; line-height: 1.5; }
.qr-binding-state.bound { color: var(--green); }
.manager-sample-actions { display: flex; gap: 5px; }
.manager-sample-actions button { height: 29px; padding: 0 8px; display: inline-flex; align-items: center; gap: 4px; border: 1px solid #2a4356; border-radius: 3px; background: #122535; color: #8fa8b9; font-size: 8px; white-space: nowrap; }
.manager-sample-actions button:hover { border-color: var(--cyan); color: #d5e8f0; }
.manager-sample-actions button.bind-button { border-color: rgba(56, 229, 174, .25); color: var(--green); }
.manager-sample-actions svg { width: 11px; height: 11px; }
.manager-sample-actions .delete-sample { width: 29px; padding: 0; justify-content: center; color: #8f6470; }
.sample-editor { display: none; padding: 15px; border-top: 1px solid #1d3345; background: #0a1623; }
.manager-sample.expanded .sample-editor { display: block; }
.editor-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.editor-field { display: flex; flex-direction: column; gap: 5px; }
.editor-field.full { grid-column: 1 / -1; }
.editor-field label { color: #607d90; font-size: 8px; }
.editor-field input, .editor-field textarea { width: 100%; padding: 8px 9px; border: 1px solid #263e51; border-radius: 3px; background: #0d1d2b; color: #b9ccd7; font-size: 10px; }
.editor-field textarea { min-height: 48px; resize: vertical; line-height: 1.45; }
.editor-checks { margin-top: 14px; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.editor-check { padding: 9px; border: 1px solid #1b3446; border-radius: 4px; }
.editor-check > span { display: block; margin-bottom: 7px; color: #608196; font-size: 8px; }
.editor-check input { width: 100%; margin-top: 5px; padding: 6px; border: 1px solid #233b4d; border-radius: 3px; background: #0e1e2c; color: #9db4c2; font-size: 9px; }
.editor-footer { margin-top: 14px; display: flex; align-items: center; justify-content: space-between; }
.editor-footer span { color: #4c6a7e; font-size: 8px; }
.primary-small { padding: 8px 18px; border: 1px solid #43dcae; border-radius: 4px; background: #159c75; color: #031b13; font-size: 10px; font-weight: 600; }
.binding-panel { display: none; flex: none; margin-bottom: 10px; padding: 12px; border: 1px solid rgba(56, 229, 174, .3); border-radius: 5px; background: rgba(56, 229, 174, .045); }
.binding-panel.visible { display: block; }
.binding-panel h3 { margin: 0 0 8px; color: var(--green); font-size: 11px; }
.binding-panel p { margin: 5px 0; color: #789589; font-size: 9px; }
.binding-codes { max-height: 90px; margin: 8px 0; overflow-y: auto; display: flex; flex-direction: column; gap: 4px; }
.binding-codes code { padding: 5px 7px; border-radius: 3px; background: #0b1c25; color: #a0c8b8; font: 500 8px var(--mono); word-break: break-all; }
.binding-panel-actions { display: flex; justify-content: flex-end; gap: 7px; }
.binding-panel-actions button { padding: 6px 12px; }
.manager-footer { min-height: 57px; padding: 0 21px; display: flex; align-items: center; justify-content: space-between; border-top: 1px solid var(--line); background: #0d1a28; }
.manager-footer > span { display: flex; align-items: center; gap: 7px; color: #587386; font-size: 9px; }
.manager-footer b { font-weight: 400; }
.toast { position: fixed; left: 50%; bottom: 28px; z-index: 200; max-width: min(600px, 90vw); padding: 11px 18px; border: 1px solid #355367; border-radius: 5px; background: rgba(15, 34, 48, .97); box-shadow: 0 8px 30px rgba(0, 0, 0, .35); color: #c1d3de; font-size: 11px; line-height: 1.5; opacity: 0; visibility: hidden; transform: translate(-50%, 10px); transition: .25s; }
.toast.visible { opacity: 1; visibility: visible; transform: translate(-50%, 0); }
.toast.error { border-color: rgba(250, 113, 128, .5); color: #ffc0c7; }

@keyframes breathe { 0%, 100% { opacity: .55; } 50% { opacity: 1; } }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes laserScan { 0%, 100% { top: 10%; } 50% { top: 90%; } }
@keyframes backgroundScan { to { background-position: 0 80px; } }
@keyframes trackerIn { from { opacity: 0; transform: scale(1.3); } to { opacity: 1; transform: scale(1); } }
@keyframes sheen { 0%, 65% { transform: translateX(-100%); } 85%, 100% { transform: translateX(100%); } }
@keyframes zoneScan { 0%, 100% { top: 0; } 50% { top: calc(100% - 1px); } }
@keyframes confirmZone { 0%, 100% { box-shadow: 0 0 5px rgba(56, 229, 174, .1); } 50% { box-shadow: 0 0 20px rgba(56, 229, 174, .6); } }
@keyframes logIn { from { opacity: 0; transform: translateY(3px); } }
@keyframes resultGlow { 0% { box-shadow: 0 0 0 rgba(56, 229, 174, 0); } 45% { box-shadow: 0 0 35px rgba(56, 229, 174, .24); } 100% { box-shadow: 0 0 24px rgba(56, 229, 174, .08); } }

@media (max-width: 1550px) {
  .topbar { grid-template-columns: minmax(340px, 1fr) auto minmax(365px, 1fr); gap: 12px; padding: 0 14px; }
  .system-title { font-size: 15px; }
  .camera-readiness b { display: none; }
  .stat { min-width: 89px; padding: 1px 14px; }
  .engine-stat { min-width: 142px; }
  .select-wrap { min-width: 125px; max-width: 150px; }
  .workspace { padding: 10px; gap: 9px; }
  .capture-content, .checklist-content { padding: 10px; }
  .panel-heading { padding: 0 10px; }
  .heading-copy { gap: 7px; }
  .section-number { font-size: 18px; }
  .heading-copy h2 { font-size: 12px; }
  .outline-badge { font-size: 7px; }
  .shortcut-hint small { display: none; }
  .check-copy > p { font-size: 7px; }
  .check-title-line strong { font-size: 8px; }
  .check-item { padding: 6px; gap: 6px; }
  .manager-sample-row { grid-template-columns: 34px minmax(0, 1fr) 65px auto; }
}

@media (max-height: 850px) {
  .topbar { min-height: 64px; height: 64px; }
  .context-bar { min-height: 28px; height: 28px; }
  .workspace { padding-top: 9px; padding-bottom: 9px; }
  .panel-heading { min-height: 49px; height: 49px; }
  .video-shell { min-height: 165px; max-height: 31vh; aspect-ratio: 16 / 9; }
  .capture-actions { margin-top: 9px; }
  .primary-action { height: 48px; }
  .device-card, .readiness-card { margin-top: 8px; padding: 9px 10px; }
  .subsection-title { padding-bottom: 6px; margin-bottom: 7px; }
  .telemetry-grid { gap: 8px 15px; }
  .readiness-row { padding: 3px 0; }
  .shortcut-hint { padding-top: 7px; }
  .analysis-progress { padding-bottom: 8px; }
  .progress-top { margin-bottom: 7px; }
  .stage-labels { margin-top: 6px; }
  .document-footer { min-height: 44px; padding-top: 7px; }
  .sample-summary { padding: 9px 10px; }
  .sample-summary h3 { height: 28px; margin-bottom: 6px; font-size: 11px; }
  .primary-code { margin-top: 7px; padding-top: 7px; }
  .checklist-heading { min-height: 30px; }
  .check-items { min-height: 225px; gap: 4px; grid-template-rows: repeat(8, minmax(32px, 1fr)); }
  .check-item { padding-top: 4px; padding-bottom: 4px; }
  .check-copy > p { margin-top: 3px; }
  .terminal-card { min-height: 72px; height: 72px; margin-top: 7px; }
  .terminal-logs { height: 41px; }
  .result-card { min-height: 65px; height: 65px; margin-top: 7px; }
  .result-icon { width: 32px; height: 32px; }
  .result-card { grid-template-columns: 33px 1fr auto; }
  .result-card strong { font-size: 14px; }
  .result-seal { width: 45px; height: 45px; }
}

@media (max-width: 1180px) {
  .engine-stat { display: none; }
  .topbar { grid-template-columns: minmax(320px, 1fr) auto minmax(320px, 1fr); }
  .select-wrap { display: none; }
  .heading-copy p, .outline-badge.cyan { display: none; }
  .panel-heading { min-height: 49px; height: 49px; }
  .section-number { display: none; }
  .check-category { display: none; }
  .primary-code code { max-width: 48%; }
  .readiness-card { display: none; }
  .device-card { margin-bottom: 8px; }
  .sample-tags span:last-child { display: none; }
  .manager-body { grid-template-columns: 240px 1fr; }
  .manager-sample-row { grid-template-columns: 32px minmax(0, 1fr) auto; }
  .qr-binding-state { display: none; }
}
