/* Retainer Oberfläche. Ruhiges CAD-Erscheinungsbild:
   Schrift 12/14/16/22 px (Gewicht 400 und 600), Abstände im 4/8-Raster, eine Ecke (6 px), eine Akzentfarbe,
   Statusfarben nur für Status (Ergebnis, Prüfungen, Schritte), keine Verläufe, keine Schatten außer Tooltip. */
:root {
  --bg: #f4f5f7; --panel: #ffffff; --ink: #1b2430; --muted: #5d6878; --line: #dfe3e8; --line-strong: #c3cad3; --soft: #eef0f3;
  --accent: #1f6f9f; --accent-ink: #ffffff; --accent-soft: #e3eff6;
  --ok: #2f7d4f; --warn: #a86a00; --bad: #c0392b; --on-status: #ffffff;
  --c-main: #3b6fb6; --c-rf: #c98a1b; --c-power: #7d5fb0;
  --stage: #e9ecf0;
  --fs-s: 12px; --fs-m: 14px; --fs-l: 16px; --fs-xl: 22px;
  --s1: 4px; --s2: 8px; --s3: 12px; --s4: 16px; --s5: 24px; --s6: 32px;
  --r: 6px; --panel-w: 352px; --bar-h: 64px;
}
:root[data-theme="dark"] {
  --bg: #12161c; --panel: #1a1f27; --ink: #e8ecf1; --muted: #9aa5b4; --line: #2a313b; --line-strong: #3a4350; --soft: #222833;
  --accent: #5aa9d6; --accent-ink: #0b1722; --accent-soft: #1b2c3a;
  --ok: #5fc088; --warn: #e0a94a; --bad: #ef7b6f; --on-status: #10151b;
  --c-main: #6f9bd6; --c-rf: #dba548; --c-power: #a08ad0;
  --stage: #0f1318;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #12161c; --panel: #1a1f27; --ink: #e8ecf1; --muted: #9aa5b4; --line: #2a313b; --line-strong: #3a4350; --soft: #222833;
    --accent: #5aa9d6; --accent-ink: #0b1722; --accent-soft: #1b2c3a;
    --ok: #5fc088; --warn: #e0a94a; --bad: #ef7b6f; --on-status: #10151b;
    --c-main: #6f9bd6; --c-rf: #dba548; --c-power: #a08ad0;
    --stage: #0f1318;
  }
}
* { box-sizing: border-box; }
html, body { height: 100%; margin: 0; }
body { background: var(--bg); color: var(--ink); font: 400 var(--fs-m)/20px Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif; overflow: hidden; }
button, input, select, textarea { font: inherit; color: inherit; }
button { cursor: pointer; }
h1, h2, h3, p { margin: 0; }
.muted { color: var(--muted); }
.tiny { font-size: var(--fs-s); line-height: 16px; color: var(--muted); }
[hidden] { display: none !important; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
svg { flex: none; }

/* Grundgerüst */
#app { height: 100%; display: grid; grid-template-columns: minmax(0, 1fr); grid-template-rows: auto var(--bar-h) minmax(0, 1fr); }
.notice-bar, .notice { background: var(--soft); color: var(--muted); border-bottom: 1px solid var(--line); padding: var(--s1) var(--s4); font-size: var(--fs-s); line-height: 16px; text-align: center; }
.notice-bar b, .notice b { color: var(--ink); font-weight: 600; }
.bar { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: var(--s4); padding: 0 var(--s4); background: var(--panel); border-bottom: 1px solid var(--line); min-width: 0; }
.logo { display: flex; align-items: center; gap: var(--s2); font-weight: 600; font-size: var(--fs-l); line-height: 24px; }
.logo svg { color: var(--accent); }
.bar-right { display: flex; justify-content: flex-end; align-items: center; gap: var(--s3); min-width: 0; }
.user-box { display: inline-flex; align-items: center; gap: var(--s3); }
.user-link { border: 0; background: none; color: var(--accent); font-size: var(--fs-s); line-height: 16px; font-weight: 600; text-decoration: none; padding: var(--s1) 0; white-space: nowrap; }
.user-link:hover { text-decoration: underline; }
#status-chip, #user-name { white-space: nowrap; }
.icon-btn { width: 32px; height: 32px; border-radius: var(--r); border: 1px solid var(--line); background: var(--panel); display: grid; place-items: center; color: var(--muted); }
.icon-btn:hover { background: var(--soft); color: var(--ink); }

/* Schrittleiste */
.pipeline { display: grid; grid-auto-flow: column; grid-auto-columns: 72px; }
.step { position: relative; display: flex; flex-direction: column; align-items: center; gap: var(--s1); border: 0; background: none; padding: var(--s1) 0; color: var(--muted); min-width: 0; }
.step:not(:first-child)::before { content: ""; position: absolute; top: 15px; left: -50%; right: 50%; height: 1px; background: var(--line-strong); }
.step.done:not(:first-child)::before, .step.run:not(:first-child)::before, .step.bad:not(:first-child)::before, .step.warn:not(:first-child)::before { background: var(--ink); }
.step .mk { position: relative; z-index: 1; width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; background: var(--panel); border: 1px solid var(--line-strong); font-size: var(--fs-s); line-height: 16px; font-weight: 600; }
.step .mk svg { width: 12px; height: 12px; }
.step .lbl { font-size: var(--fs-s); line-height: 16px; font-weight: 600; white-space: nowrap; }
.step.ready .mk { border-color: var(--accent); color: var(--accent); }
.step.done { color: var(--ink); }
.step.done .mk { background: var(--ink); border-color: var(--ink); color: var(--panel); }
.step.run { color: var(--accent); }
.step.run .mk { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); animation: blink 1.4s ease-in-out infinite; }
.step.bad { color: var(--bad); }
.step.bad .mk { background: var(--bad); border-color: var(--bad); color: var(--on-status); }
.step.warn { color: var(--warn); }
.step.warn .mk { background: var(--warn); border-color: var(--warn); color: var(--on-status); }
.step.sel .lbl { text-decoration: underline; text-underline-offset: 4px; text-decoration-thickness: 2px; }
.step:disabled { cursor: default; }
.step:not(:disabled):hover .mk { border-color: var(--accent); }
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: .55; } }
@media (prefers-reduced-motion: reduce) { .step.run .mk, .ring.spin .fg { animation: none; } }

/* Arbeitsbereich */
.work { display: grid; grid-template-columns: var(--panel-w) minmax(0, 1fr); min-height: 0; }
.panel { background: var(--panel); border-right: 1px solid var(--line); display: flex; flex-direction: column; min-height: 0; min-width: 0; }
.panel-body { flex: 1; min-height: 0; overflow-y: auto; overflow-x: hidden; padding: var(--s4); scrollbar-width: thin; }
.panel-foot { display: grid; gap: var(--s2); padding: var(--s3) var(--s4) var(--s4); background: var(--panel); border-top: 1px solid var(--line); }
.panel-foot:empty { display: none; }
#settings.locked { opacity: .55; pointer-events: none; }

.stage { display: flex; flex-direction: column; background: var(--stage); min-width: 0; min-height: 0; }
.viewport { position: relative; flex: 1; min-height: 0; overflow: hidden; }
.viewer { position: absolute; inset: 0; }
.viewer canvas { width: 100%; height: 100%; display: block; }
.overlay { position: absolute; left: 0; right: 0; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-start; gap: var(--s2); padding: var(--s3); z-index: 5; pointer-events: none; }
.overlay > * { pointer-events: auto; }
.overlay.top { top: 0; }
.overlay.bottom { bottom: 0; align-items: flex-end; }
.tools { display: flex; flex-wrap: wrap; align-items: center; gap: var(--s2); min-width: 0; }
.chip-btn, .pill { height: 28px; border: 1px solid var(--line-strong); background: var(--panel); border-radius: var(--r); padding: 0 var(--s3); font-size: var(--fs-s); line-height: 16px; font-weight: 600; display: inline-flex; align-items: center; gap: var(--s1); white-space: nowrap; }
.chip-btn:hover, .pill:hover { background: var(--soft); }
.chip-btn svg { width: 14px; height: 14px; }
.chip-btn[aria-pressed="true"] { background: var(--accent-soft); border-color: var(--accent); color: var(--accent); }
.views { display: flex; border: 1px solid var(--line-strong); border-radius: var(--r); background: var(--panel); overflow: hidden; }
.views button { height: 26px; border: 0; background: none; padding: 0 var(--s3); font-size: var(--fs-s); line-height: 16px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.views button + button { border-left: 1px solid var(--line); }
.views button:hover { background: var(--soft); color: var(--ink); }
#viewer-info { white-space: nowrap; }
.viewer-msg { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); max-width: calc(100% - 32px); background: var(--panel); border: 1px solid var(--line); border-radius: var(--r); padding: var(--s3) var(--s4); font-weight: 600; text-align: center; z-index: 6; }
.log-drawer { position: absolute; left: var(--s3); bottom: 52px; width: min(560px, calc(100% - 24px)); max-height: 40%; overflow: auto; margin: 0; background: var(--panel); border: 1px solid var(--line-strong); border-radius: var(--r); padding: var(--s3); font: 400 var(--fs-s)/16px ui-monospace, Menlo, Consolas, monospace; white-space: pre-wrap; overflow-wrap: anywhere; z-index: 7; }

/* Ablegen */
.dropzone { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: var(--s4); padding: var(--s5) var(--s4); z-index: 4; pointer-events: none; }
.drop-card { pointer-events: auto; width: min(360px, 100%); padding: var(--s6) var(--s4); border: 1px dashed var(--line-strong); border-radius: var(--r); display: flex; flex-direction: column; align-items: center; gap: var(--s2); background: var(--panel); cursor: pointer; text-align: center; }
.drop-card svg { color: var(--accent); }
.drop-card strong { font-size: var(--fs-l); line-height: 24px; font-weight: 600; }
.drop-card:hover, .drop-card.over { border-color: var(--accent); background: var(--accent-soft); }
.sample-row { pointer-events: auto; display: flex; align-items: center; gap: var(--s2); max-width: 100%; }
select { height: 32px; padding: 0 var(--s2); border-radius: var(--r); border: 1px solid var(--line-strong); background: var(--panel); color: var(--ink); max-width: 100%; }

.busy { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 6; display: flex; flex-direction: column; align-items: center; gap: var(--s2); width: min(260px, calc(100% - 32px)); background: var(--panel); border: 1px solid var(--line); padding: var(--s4); border-radius: var(--r); text-align: center; }
.busy b { font-size: var(--fs-m); font-weight: 600; max-width: 100%; overflow-wrap: anywhere; }
.ring { width: 40px; height: 40px; }
.ring circle { fill: none; stroke-width: 4; }
.ring .bg { stroke: var(--soft); }
.ring .fg { stroke: var(--accent); stroke-linecap: round; transition: stroke-dashoffset .5s; transform: rotate(-90deg); transform-origin: 50% 50%; }
.ring.spin .fg { animation: spin 1.1s linear infinite; }
@keyframes spin { to { transform: rotate(270deg); } }

/* Einstellungen: flache Abschnitte, keine verschachtelten Karten */
.sec { padding: var(--s4) 0; border-top: 1px solid var(--line); }
.sec:first-child, #side-top:empty + #settings > .sec:first-child { border-top: 0; padding-top: 0; }
.sec-h { font-size: var(--fs-m); line-height: 20px; font-weight: 600; margin-bottom: var(--s3); }
.row { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: var(--s1) var(--s3); margin: 0 0 var(--s3); }
.row:last-child { margin-bottom: 0; }
.row .name { display: block; min-width: 0; color: var(--ink); overflow-wrap: anywhere; }
.row .name .nw { white-space: nowrap; }
.row .name .info { margin-left: var(--s2); vertical-align: -3px; }
.row.changed .name::after { content: ""; display: inline-block; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); margin-left: var(--s2); vertical-align: 2px; }
.row .val { font-variant-numeric: tabular-nums; font-weight: 600; display: flex; align-items: baseline; justify-content: flex-end; gap: var(--s1); }
.row .val input { width: 56px; text-align: right; border: 0; border-bottom: 1px solid var(--line-strong); background: none; font: inherit; font-weight: 600; color: inherit; padding: 0; border-radius: 0; }
.row .val .u { color: var(--muted); font-weight: 400; font-size: var(--fs-s); }
.row .ctl { grid-column: 1 / -1; min-width: 0; }
.info { flex: none; display: inline-grid; place-items: center; width: 16px; height: 16px; padding: 0; border-radius: 50%; border: 1px solid var(--line-strong); background: none; color: var(--muted); font-size: var(--fs-s); line-height: 1; font-weight: 600; cursor: help; }
.info:hover, .info:focus-visible { color: var(--accent); border-color: var(--accent); }
.tip { position: fixed; z-index: 60; max-width: 260px; background: var(--ink); color: var(--panel); padding: var(--s2) var(--s3); border-radius: var(--r); font-size: var(--fs-s); line-height: 16px; box-shadow: 0 2px 8px rgba(0, 0, 0, .25); pointer-events: none; }

input[type=range] { -webkit-appearance: none; appearance: none; width: 100%; height: 20px; background: none; margin: 0; }
input[type=range]::-webkit-slider-runnable-track { height: 4px; border-radius: 2px; background: linear-gradient(to right, var(--accent) var(--p, 0%), var(--line) var(--p, 0%)); }
input[type=range]::-moz-range-track { height: 4px; border-radius: 2px; background: var(--line); }
input[type=range]::-moz-range-progress { height: 4px; border-radius: 2px; background: var(--accent); }
input[type=range]::-webkit-slider-thumb { -webkit-appearance: none; width: 16px; height: 16px; border-radius: 50%; background: var(--accent); border: 2px solid var(--panel); margin-top: -6px; }
input[type=range]::-moz-range-thumb { width: 12px; height: 12px; border-radius: 50%; background: var(--accent); border: 2px solid var(--panel); }
input[type=range].auto::-webkit-slider-thumb { background: var(--line-strong); }
.seg { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); border: 1px solid var(--line-strong); border-radius: var(--r); overflow: hidden; }
.seg button { height: 32px; border: 0; background: none; padding: 0 var(--s1); font-size: var(--fs-s); line-height: 16px; font-weight: 600; color: var(--muted); white-space: nowrap; min-width: 0; }
.seg button + button { border-left: 1px solid var(--line); }
.seg button:hover { background: var(--soft); color: var(--ink); }
.seg button[aria-checked="true"] { background: var(--accent-soft); color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.switch { position: relative; width: 32px; height: 20px; border-radius: 10px; background: var(--line-strong); border: 0; padding: 0; }
.switch::after { content: ""; position: absolute; top: 2px; left: 2px; width: 16px; height: 16px; border-radius: 50%; background: var(--panel); transition: transform .15s; }
.switch[aria-checked="true"] { background: var(--accent); }
.switch[aria-checked="true"]::after { transform: translateX(12px); }
.nudge { display: grid; grid-template-columns: 32px minmax(0, 1fr) 32px; gap: var(--s2); align-items: center; }
.nudge button { width: 32px; height: 32px; border-radius: var(--r); border: 1px solid var(--line-strong); background: var(--panel); display: grid; place-items: center; padding: 0; }
.nudge button:hover { background: var(--soft); }
.nudge svg { width: 14px; height: 14px; }
textarea, input[type=text] { width: 100%; font: 400 var(--fs-s)/16px ui-monospace, Menlo, Consolas, monospace; padding: var(--s2); border-radius: var(--r); border: 1px solid var(--line-strong); background: var(--bg); color: var(--ink); min-height: 32px; }
textarea:focus-visible, input[type=text]:focus-visible { outline-offset: 0; border-color: var(--accent); }
.reset { border: 0; background: none; color: var(--muted); font-size: var(--fs-s); padding: 0 var(--s1); }
.reset:hover { color: var(--bad); }

.chips { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s2); margin-bottom: var(--s3); }
.bchip { height: 32px; border: 1px solid var(--line-strong); background: var(--panel); border-radius: var(--r); padding: 0 var(--s1); font-size: var(--fs-s); line-height: 16px; font-weight: 600; display: flex; align-items: center; justify-content: center; gap: var(--s2); white-space: nowrap; min-width: 0; }
.bchip i { width: 8px; height: 8px; border-radius: 2px; background: var(--c); flex: none; }
.bchip:hover { background: var(--soft); }
.bchip[aria-pressed="true"] { border-color: var(--ink); box-shadow: inset 0 0 0 1px var(--ink); }
.bchip.dirty::after { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); flex: none; }
details.adv { border-top: 1px solid var(--line); margin-top: var(--s4); }
details.adv > summary { cursor: pointer; padding: var(--s4) 0; font-weight: 600; list-style: none; display: flex; align-items: center; justify-content: space-between; }
details.adv > summary::-webkit-details-marker { display: none; }
details.adv > summary::after { content: ""; width: 6px; height: 6px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: rotate(45deg); margin: -3px 3px 0 0; transition: transform .15s; flex: none; }
details.adv[open] > summary::after { transform: rotate(-135deg); margin-top: 3px; }
details.adv .inner { padding-bottom: var(--s2); }

.btn { height: 40px; border: 1px solid var(--line-strong); background: var(--panel); border-radius: var(--r); padding: 0 var(--s4); font-weight: 600; display: flex; align-items: center; justify-content: center; gap: var(--s2); width: 100%; text-decoration: none; color: var(--ink); white-space: nowrap; }
.btn:hover:not(:disabled) { background: var(--soft); }
.btn.primary { background: var(--accent); color: var(--accent-ink); border-color: var(--accent); }
.btn.primary:hover:not(:disabled) { background: var(--accent); filter: brightness(1.08); }
.btn.bad { color: var(--bad); border-color: var(--bad); }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.btn svg { width: 16px; height: 16px; }
.link { border: 0; background: none; color: var(--muted); font-size: var(--fs-s); line-height: 16px; text-decoration: underline; padding: var(--s1); justify-self: center; }
.link:hover { color: var(--ink); }
.foot-note { text-align: center; }

/* Ergebnis */
.res { border: 1px solid var(--line); border-radius: var(--r); padding: var(--s4); margin-bottom: var(--s4); background: var(--panel); }
.res-head { display: flex; align-items: center; gap: var(--s3); margin-bottom: var(--s3); min-width: 0; }
.res-badge { width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; color: var(--on-status); flex: none; background: var(--muted); }
.res-badge svg { width: 18px; height: 18px; }
.res.ok .res-badge { background: var(--ok); } .res.bad .res-badge { background: var(--bad); } .res.warn .res-badge { background: var(--warn); } .res.run .res-badge { background: var(--accent); color: var(--accent-ink); }
.res-text { min-width: 0; }
.res-title { font-size: var(--fs-xl); font-weight: 600; line-height: 28px; overflow-wrap: anywhere; }
.res-sub { font-size: var(--fs-s); line-height: 16px; color: var(--muted); overflow-wrap: anywhere; }
.kv { margin: 0 0 var(--s3); padding: 0; list-style: none; border-top: 1px solid var(--line); }
.kv li { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); padding: var(--s2) 0; border-bottom: 1px solid var(--line); }
.kv .k { display: flex; align-items: center; gap: var(--s2); color: var(--muted); white-space: nowrap; }
.kv .v { font-weight: 600; font-variant-numeric: tabular-nums; white-space: nowrap; }
.res-foot { display: flex; align-items: center; justify-content: space-between; gap: var(--s3); margin-top: var(--s3); }
.res-foot a { font-size: var(--fs-s); line-height: 16px; color: var(--accent); white-space: nowrap; }
.fold-btn { border: 0; background: none; padding: var(--s1) 0; display: inline-flex; align-items: center; gap: var(--s2); font-size: var(--fs-s); line-height: 16px; font-weight: 600; color: var(--muted); white-space: nowrap; }
.fold-btn::before { content: ""; width: 6px; height: 6px; border-right: 1.5px solid var(--muted); border-bottom: 1.5px solid var(--muted); transform: rotate(-45deg); transition: transform .15s; flex: none; }
.fold-btn[aria-expanded="true"]::before { transform: rotate(45deg); }
.fold-btn:hover { color: var(--ink); }
.checks { margin: var(--s2) 0 0; padding: 0; list-style: none; max-height: 240px; overflow: auto; font-size: var(--fs-s); line-height: 16px; }
.checks li { display: flex; gap: var(--s2); padding: var(--s2) 0; border-top: 1px solid var(--line); }
.checks li i { width: 8px; height: 8px; border-radius: 50%; margin-top: 4px; flex: none; background: var(--ok); }
.checks li.fehler i { background: var(--bad); } .checks li.warnung i { background: var(--warn); }
.checks li > div { min-width: 0; overflow-wrap: anywhere; }
.checks small { display: block; color: var(--muted); font-size: var(--fs-s); }

/* Verlauf */
.history { height: 96px; background: var(--panel); border-top: 1px solid var(--line); display: flex; gap: var(--s2); align-items: center; padding: 0 var(--s3); overflow-x: auto; overflow-y: hidden; scrollbar-width: thin; flex: none; }
.hc { position: relative; flex: none; width: 216px; height: 72px; border: 1px solid var(--line); background: var(--panel); border-radius: var(--r); padding: var(--s2); display: grid; grid-template-columns: 54px minmax(0, 1fr); gap: var(--s2); text-align: left; }
.hc:hover { background: var(--soft); }
.hc.sel { border-color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.hc .th { border-radius: 4px; background: var(--soft); overflow: hidden; display: grid; place-items: center; color: var(--muted); height: 54px; }
.hc .th img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hc .th svg { width: 24px; height: 24px; }
.hc .tx { min-width: 0; display: flex; flex-direction: column; justify-content: center; gap: var(--s1); }
.hc .t1 { font-weight: 600; font-size: var(--fs-s); line-height: 16px; overflow-wrap: anywhere; padding-right: var(--s4); display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
.hc .t2 { font-size: var(--fs-s); line-height: 16px; color: var(--muted); display: flex; align-items: center; gap: var(--s2); white-space: nowrap; }
.hc .st { width: 8px; height: 8px; border-radius: 50%; background: var(--muted); flex: none; }
.hc .st.ok { background: var(--ok); } .hc .st.bad { background: var(--bad); } .hc .st.run { background: var(--accent); animation: blink 1.4s ease-in-out infinite; } .hc .st.warn { background: var(--warn); }
.hc .x { position: absolute; top: var(--s1); right: var(--s1); width: 20px; height: 20px; padding: 0; border-radius: 4px; border: 0; background: none; color: var(--muted); display: none; place-items: center; }
.hc .x svg { width: 12px; height: 12px; }
.hc:hover .x, .hc.sel .x, .hc:focus-within .x { display: grid; }
.hc .x:hover { background: var(--line); color: var(--bad); }
.hnew { flex: none; width: 72px; height: 72px; border: 1px dashed var(--line-strong); border-radius: var(--r); background: none; color: var(--muted); display: grid; place-items: center; }
.hnew svg { width: 20px; height: 20px; }
.hnew:hover { border-color: var(--accent); color: var(--accent); }
.hint-empty { color: var(--muted); font-size: var(--fs-s); line-height: 16px; white-space: nowrap; }

.toast { position: fixed; bottom: 112px; left: 50%; transform: translateX(-50%); background: var(--ink); color: var(--panel); padding: var(--s2) var(--s4); border-radius: var(--r); z-index: 50; width: max-content; max-width: calc(100vw - 32px); font-size: var(--fs-m); }

@media (max-width: 1100px) { #status-chip { display: none; } }
@media (max-width: 900px) {
  body { overflow: auto; }
  #app { height: auto; min-height: 100%; grid-template-rows: auto auto auto; }
  .bar { grid-template-columns: minmax(0, 1fr) auto; grid-template-rows: auto auto; row-gap: var(--s1); padding: var(--s2) var(--s4) 0; }
  .pipeline { grid-column: 1 / -1; grid-row: 2; grid-auto-columns: minmax(0, 1fr); }
  .work { grid-template-columns: minmax(0, 1fr); }
  .stage { height: 70vh; min-height: 420px; order: -1; border-bottom: 1px solid var(--line); }
  .panel { border-right: 0; }
  .panel-body { overflow: visible; }
  .panel-foot { position: sticky; bottom: 0; z-index: 8; }
  .toast { bottom: 24px; }
}
@media (max-width: 480px) {
  .bar-right { gap: var(--s2); }
  .user-box { gap: var(--s2); }
  .hc { width: 200px; }
}
