:root{color-scheme:dark;font-family:ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",sans-serif;color:#e4e8ed;background:#11151a;font-size:13px;--line:#303740;--muted:#9ca8b5;--accent:#ff675b}
*{box-sizing:border-box}body{margin:0;height:100dvh;display:grid;grid-template-rows:auto minmax(0,1fr) auto;overflow:hidden}button,input,select{font:inherit}button{display:inline-flex;align-items:center;justify-content:center;gap:7px;min-height:34px;padding:7px 11px;color:inherit;background:#212730;border:1px solid var(--line);border-radius:6px;cursor:pointer;white-space:nowrap}button:hover{background:#303944}button:disabled{opacity:.4;cursor:default}button:focus-visible,a:focus-visible,select:focus-visible,input:focus-visible,summary:focus-visible{outline:2px solid #86baff;outline-offset:3px}.icon{width:16px;height:16px;display:block;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}.toolbar{display:flex;align-items:center;justify-content:space-between;gap:16px;padding:10px 14px;border-bottom:1px solid var(--line);min-width:0}.brand{color:var(--accent);font-size:18px;letter-spacing:-.8px;text-decoration:none;display:flex;align-items:center;gap:8px;white-space:nowrap}.brand img{width:32px;height:32px;flex:none;object-fit:contain}.brand-name{font-weight:750}.brand-name span{color:#f0f3f6;font-weight:400}.actions{display:flex;gap:6px}.primary{background:var(--accent);border-color:var(--accent);color:#17191d;font-weight:700}.primary:hover{background:#ff8b82}.stop{color:#ff9d94;border-color:#ae4c45}#scene-viewport{position:relative;display:flex;align-items:center;justify-content:center;min-height:0;min-width:0;overflow:hidden;padding:12px;background:#0c1014}#image-frame{position:relative;flex:none;overflow:hidden;background:#222;box-shadow:0 0 0 1px #46505a}#scene-image{display:block;width:100%;height:100%}#overlay{position:absolute;inset:0;width:100%;height:100%;overflow:hidden}.region-box{stroke:#d9e1e9;stroke-width:1;vector-effect:non-scaling-stroke;fill:transparent;cursor:pointer}.region-box.processing{stroke:#f5c542;stroke-width:2;fill:#f5c54250}.region-box.candidate{stroke:#32c878;stroke-width:2;fill:#32c87848}.region-box.negative{stroke:#ed655f;fill:#ed4e635e}.region-box.uncertain,.region-box.queued{stroke:#6da9ff;fill:#528ef538}.region-box.untested{stroke:#8290a0;fill:#8290a014}.region-box.error{stroke:#94a3b8;fill:#94a3b833}.region-box.selected{stroke:#fff;stroke-width:2.5}.region-box:focus-visible{outline:none;stroke:#fff;stroke-width:3}.region-label{pointer-events:none;fill:#fff;font-weight:650;letter-spacing:.1px}.status-row{cursor:pointer}.status-row rect{fill:#16212cee;stroke:#4e5b68;stroke-width:.5}.status-row.processing rect{fill:#755400ee;stroke:#f5d573}.status-row.candidate rect{fill:#145634ee;stroke:#78e7a8}.status-row.negative rect{fill:#76252fee;stroke:#ff9aa0}.status-row.uncertain rect,.status-row.queued rect{fill:#183e6aee;stroke:#95c0ff}.status-row.error rect{fill:#3c4758ee;stroke:#aebdce}.status-row text{fill:#f6f8fb;font-weight:600;pointer-events:none}.status-row:focus-visible{outline:none}.status-row:focus-visible rect{stroke:#fff;stroke-width:2}.review-dot{fill:#fff;stroke:#172d26;stroke-width:1}.target-marker{pointer-events:none}.marking{cursor:crosshair}.marking .region-box,.marking .status-row{pointer-events:none}#mark-hint,#message{position:absolute;z-index:2;max-width:calc(100% - 24px);border:1px solid #596778;background:#1d2935ee;border-radius:6px;padding:9px 12px;color:#eaf3fb}#message{top:16px;left:50%;transform:translateX(-50%)}#message.error{background:#532431;border-color:#a96075}#mark-hint{bottom:16px}#scene-empty{color:var(--muted)}.statusbar{min-height:44px;padding:6px 14px;display:flex;align-items:center;gap:10px;border-top:1px solid var(--line);min-width:0}.status-line{display:flex;align-items:center;gap:14px;flex:1;min-width:0;font-size:12px}.status-line #run-status{white-space:nowrap;font-weight:650}.status-line #stats{color:var(--muted);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.statusbar button{min-height:28px;padding:4px 8px;font-size:12px}.statusbar button.active{border-color:#ff9c83;color:#ffb39f}.subtle{color:var(--muted);font-size:12px}.dialog-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:20px}.dialog-heading h2{margin:0;font-size:17px;font-weight:650}.dialog-heading button{border:0;background:transparent;min-width:30px;padding:5px}dialog{width:440px;max-width:calc(100vw - 24px);max-height:calc(100dvh - 32px);padding:20px;background:#171d24;border:1px solid #3c4652;color:#e4e8ed;border-radius:10px;box-shadow:0 16px 80px #0009;overflow:auto}dialog::backdrop{background:#05090dbb;backdrop-filter:blur(3px)}fieldset{border:0;padding:0;margin:0;min-width:0}label{display:flex;flex-direction:column;gap:7px;margin-bottom:14px;font-size:12px;color:#cbd4de}input:not([type=checkbox]),select{background:#0f151c;border:1px solid #3a4653;border-radius:5px;padding:8px 9px;color:#edf2f7;width:100%;min-width:0}input[type=checkbox]{accent-color:var(--accent);width:15px;height:15px;margin:0}.check{flex-direction:row;align-items:center;gap:9px}.paired,.review-selectors{display:grid;grid-template-columns:1fr 1fr;gap:0 12px}.field-heading{display:flex;justify-content:space-between;margin:6px 0 12px;font-size:12px}.model-choice{display:flex;flex-direction:row;align-items:center;gap:9px;padding:8px 0;margin:0}.model-choice small{margin-left:auto;color:var(--muted)}details{margin:14px 0}summary{font-size:12px;cursor:pointer;color:#c4cdd7}details[open] summary{margin-bottom:14px}.add-model{display:flex;gap:6px}.catalog-line{display:flex;align-items:center;justify-content:space-between;color:var(--muted);margin-bottom:14px}.catalog-line button{min-height:25px;padding:4px;background:transparent;border:0}.dialog-actions{display:flex;justify-content:flex-end;margin-top:16px}#config-error{color:#ffb2aa}.review-dialog{width:820px}.review-selectors{grid-template-columns:2fr 1fr}.crop-frame{display:flex;align-items:center;justify-content:center;background:#0a0e12;border-radius:5px;min-height:100px;overflow:hidden}.crop-frame img{display:block;max-width:100%;max-height:55dvh;object-fit:contain;image-rendering:auto}.decision-line{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-top:14px}.decision-line strong{font-size:14px}#crop-meta{text-align:right}#crop-reason{font-size:13px;line-height:1.55;white-space:pre-wrap}.review-buttons{display:flex;gap:7px}.review-buttons button.selected{background:#344d42;border-color:#83bc9f}#review-feedback{min-height:16px;margin-bottom:0}.history-row{display:flex;gap:12px;width:100%;text-align:left;margin-bottom:8px;justify-content:flex-start;padding:10px;white-space:normal}.history-row img{width:60px;height:45px;object-fit:cover;border-radius:3px}.history-row div{flex:1;min-width:0}.history-row small{display:block;color:var(--muted);margin-top:4px}.history-row strong{font-weight:600}.history-row span{font-size:11px;color:var(--muted)}[hidden]{display:none!important}
@media(max-width:660px){.toolbar{padding:8px 10px;gap:8px}.brand{font-size:16px}.button-label{display:none}.actions{gap:4px}.actions button{padding:7px;gap:5px}.statusbar{padding:5px 10px;gap:5px}.status-line{gap:8px;font-size:11px}.statusbar button{padding:4px 6px}#scene-viewport{padding:7px}.decision-line{align-items:flex-start;flex-direction:column}#crop-meta{text-align:left}}
@media(prefers-reduced-motion:no-preference){.status-row.processing rect{animation:pulse 1.4s ease-in-out infinite}@keyframes pulse{50%{fill:#92700aee}}}

#reference-image{display:block;max-width:100%;height:200px;object-fit:contain;margin:0 auto;background:#fff}#prompt-preview{font:11px/1.6 ui-monospace,monospace;white-space:pre-wrap;overflow-wrap:anywhere;color:var(--muted)}

.mask-legend{position:absolute;top:9px;right:10px;display:flex;flex-wrap:wrap;gap:11px;padding:6px 9px;border:1px solid #ffffff18;border-radius:6px;background:#10151de8;color:#d9e1eb;font-size:11px;pointer-events:none}.mask-legend span{display:inline-flex;align-items:center;gap:5px}.mask-legend span:before{content:"";width:8px;height:8px;border-radius:2px;background:var(--mask-color)}.mask-legend .running{--mask-color:#f5c542}.mask-legend .discarded{--mask-color:#ed655f}.mask-legend .found{--mask-color:#32c878}.mask-legend .considered{--mask-color:#6da9ff}

body{grid-template-rows:auto minmax(0,1fr) auto auto}.benchmark-metrics{min-width:0;max-height:35dvh;overflow:auto;padding:9px 14px;border-top:1px solid var(--line);background:#141a21}.metrics-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;margin-bottom:6px}.metrics-heading h2{font-size:13px;font-weight:650;margin:0}.metrics-table-wrap{overflow-x:auto}.metrics-table{width:100%;border-collapse:collapse;font-size:12px;font-variant-numeric:tabular-nums;white-space:nowrap}.metrics-table th,.metrics-table td{padding:6px 10px;text-align:right;border-bottom:1px solid #30374080}.metrics-table thead th{font-size:11px;font-weight:500;color:var(--muted)}.metrics-table th:first-child{text-align:left;padding-left:0}.metrics-table small{display:block;font-size:10px;font-weight:400;color:var(--muted);margin-top:2px}.metrics-table tbody th{font-weight:500}.metric-model{display:block;max-width:210px;overflow:hidden;text-overflow:ellipsis;min-height:0;padding:3px 0;border:0;background:none;color:#a8caff;text-align:left;font-size:12px}.metric-model:hover{background:none;text-decoration:underline}.confusion-counts{letter-spacing:.4px}#metrics-note{font-size:11px;margin:6px 0 0}#metrics-details{margin:6px 0 0}#metrics-details summary{font-size:11px}#metrics-details[open] summary{margin-bottom:8px}.metric-definitions{display:grid;grid-template-columns:max-content 1fr;gap:4px 14px;color:var(--muted);font-size:11px}.metric-definitions dt,.metric-definitions dd{margin:0}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border:0}@media(max-width:660px){.benchmark-metrics{padding:8px 10px}.metrics-heading{align-items:flex-start;flex-direction:column;gap:3px}.metrics-table th,.metrics-table td{padding:5px 8px}.metric-model{max-width:140px}.metric-definitions{grid-template-columns:1fr}}

.paired.single{grid-template-columns:1fr}.bbox-loading{fill:#f5c54228;pointer-events:none}.bbox-status{cursor:pointer}.bbox-status rect{fill:#101820eb;stroke-width:1;vector-effect:non-scaling-stroke}.bbox-status text{font-weight:650;pointer-events:none}.bbox-status:focus-visible{outline:none}.bbox-status:focus-visible rect{stroke:#fff!important;stroke-width:2}.bbox-proposal{cursor:pointer}.bbox-proposal rect{fill:transparent;stroke-width:2.5;vector-effect:non-scaling-stroke}.bbox-proposal text{font-weight:700;paint-order:stroke;stroke:#0b121c;stroke-width:3;vector-effect:non-scaling-stroke;pointer-events:none}.bbox-proposal.uncertain rect{stroke-dasharray:6 4}.bbox-proposal:focus-visible{outline:none}.bbox-proposal:focus-visible rect{stroke-width:4}.crop-preview{position:relative;max-width:100%;line-height:0}#crop-box-overlay{position:absolute;inset:0;width:100%;height:100%;pointer-events:none}#crop-box-overlay rect{fill:transparent;stroke-width:3;vector-effect:non-scaling-stroke}
