:root{
  --bg:#050b14; --panel:#081523cc; --line:#0e2c40;
  --cyan:#00e5ff; --cyan-dim:#0a7f96; --teal:#19f0d8;
  --amber:#ffb300; --red:#ff4d5e; --txt:#9fd8e8; --txt-dim:#4d7d92;
}
*{box-sizing:border-box;margin:0;padding:0}
html,body{height:100%}
body{
  background:radial-gradient(ellipse at 50% 38%, #0a1a2c 0%, var(--bg) 65%);
  color:var(--txt); font-family:'Rajdhani',sans-serif; overflow:hidden;
}
body::after{ /* scanlines */
  content:""; position:fixed; inset:0; pointer-events:none; z-index:9;
  background:repeating-linear-gradient(0deg, transparent 0 2px, #00e5ff05 2px 4px);
}
#grid{display:grid; grid-template-columns:320px 1fr 320px; grid-template-rows:54px 1fr 26px; height:100vh; gap:8px; padding:8px}
header{
  grid-column:1/4; display:flex; align-items:center; justify-content:space-between;
  border:1px solid var(--line); background:var(--panel); padding:0 18px;
  clip-path:polygon(0 0,100% 0,100% 70%,calc(100% - 16px) 100%,16px 100%,0 70%);
}
header h1{font-family:'Orbitron'; font-size:27.6px; font-weight:700; line-height:1.1; letter-spacing:8px; text-transform:uppercase; flex-shrink:0; color:var(--cyan); text-shadow:0 0 8px #00e5ffbb,0 0 20px #00e5ff88,0 0 28px #00e5ff44}
header .sub{font-size:12px; letter-spacing:3px; color:var(--txt-dim)}
#clock{font-family:monospace; font-size:15px; font-variant-numeric:tabular-nums; letter-spacing:2px; color:var(--teal); width:calc(8ch + 16px); flex-shrink:0; text-align:left; white-space:nowrap}
.col{display:flex; flex-direction:column; gap:8px; overflow-y:auto; scrollbar-width:thin; scrollbar-color:var(--line) transparent}
.panel{
  border:1px solid var(--line); background:var(--panel); padding:10px 12px; position:relative;
  clip-path:polygon(0 0,calc(100% - 12px) 0,100% 12px,100% 100%,12px 100%,0 calc(100% - 12px));
}
.panel h2{
  font-family:'Orbitron'; font-size:10px; letter-spacing:3px; color:var(--cyan);
  border-bottom:1px solid var(--line); padding-bottom:5px; margin-bottom:7px;
  display:flex; justify-content:space-between;
}
.panel h2 .num{color:var(--txt-dim)}
.kv{display:flex; justify-content:space-between; font-size:13px; padding:1.5px 0}
.kv b{color:var(--teal); font-weight:600; text-align:right; max-width:60%; overflow:hidden; text-overflow:ellipsis; white-space:nowrap}
.ok{color:var(--teal)} .warn{color:var(--amber)} .err{color:var(--red)}
.dot{display:inline-block;width:7px;height:7px;border-radius:50%;margin-right:6px;background:var(--txt-dim)}
.dot.on{background:var(--teal); box-shadow:0 0 6px var(--teal)}
.dot.off{background:var(--red); box-shadow:0 0 6px var(--red)}
#center{display:flex; flex-direction:column; align-items:center; justify-content:flex-start; position:relative; overflow:hidden}
#reactorWrap{position:relative; width:min(46vh,440px); height:min(46vh,440px); cursor:pointer; flex-shrink:0; transform:translateY(40px);}
#reactor{width:100%; height:100%; position:relative; z-index:1}
/* Lucy-inspired portrait field: decoration only, never intercepts the voice control.
   Scarlett Johansson photograph by Gage Skidmore, CC BY-SA 2.0; see assets/CREDITS.txt. */
#lucyBackdrop{position:fixed; inset:0; z-index:-1; overflow:hidden; pointer-events:none}
#lucyPortrait{position:absolute; inset:0; width:90%; height:90%; left:5%; top:5%; object-fit:cover; object-position:center 15%; opacity:.65; mix-blend-mode:screen; filter:brightness(.95) contrast(1.02) saturate(1.05); transform:translateX(40px);}
#lucyOverlay{position:absolute; inset:0; z-index:1; pointer-events:none; background:rgba(0,30,50,.15); mix-blend-mode:soft-light}
#lucyCode{position:absolute; inset:0; overflow:hidden; opacity:.55; z-index:2;
  -webkit-mask-image:linear-gradient(90deg,#000 12%,#0005 36%,#0003 64%,#000 88%);
  mask-image:linear-gradient(90deg,#000 12%,#0005 36%,#0003 64%,#000 88%)}
.lucy-code-stream{position:absolute; top:-100%; height:200%; width:1.4ch;
  white-space:pre; font:13px/1.7 monospace; color:#159cd1;
  text-shadow:0 0 3px #159cd1,0 0 6px rgba(21,156,209,.5); user-select:none;
  animation:lucyCodeFall var(--fall-time) linear infinite; animation-delay:var(--fall-delay)}
@keyframes lucyCodeFall{from{transform:translateY(-15%)}to{transform:translateY(50%)}}
body.lucy-motion-paused .lucy-code-stream{animation-play-state:paused}
#coreState{z-index:2}
#portraitCredit{font-size:9px; letter-spacing:.3px; color:var(--txt-dim); text-decoration:none}
#portraitCredit:hover,#portraitCredit:focus-visible{color:var(--cyan); text-decoration:underline}
@media (prefers-reduced-motion:reduce){
  .lucy-code-stream{animation:none; transform:translateY(25%)}
}

#coreState{
  position:absolute; inset:0; display:flex; flex-direction:column; align-items:center; justify-content:center;
  pointer-events:none; font-family:'Orbitron';
}
#coreState .st{font-size:15px; letter-spacing:6px; color:var(--cyan); text-shadow:0 0 14px #00e5ffaa}
#coreState .hint{font-size:9px; letter-spacing:2px; color:var(--txt-dim); margin-top:6px}
/* Hintergrundagent: eigener Kanal neben Lucy, amber statt cyan, im Ruhezustand
   hidden (kein zusaetzliches Element im Layout, Reactor bleibt zentriert). */
#coreState .bg-state{margin-top:8px; padding-top:6px; border-top:1px solid var(--cyan-dim); display:flex; gap:8px; align-items:baseline; justify-content:center}
#coreState .bg-state[hidden]{display:none}
#coreState .bg-state .bst{font-size:11px; letter-spacing:4px; color:var(--amber); text-shadow:0 0 10px #ffb30066}
#coreState .bg-state .bhint{font-size:9px; letter-spacing:2px; color:var(--txt-dim)}
@media (max-width:640px){
  #coreState .bg-state{margin-top:5px; padding-top:4px; gap:6px}
  #coreState .bg-state .bst{font-size:9px; letter-spacing:2px}
  #coreState .bg-state .bhint{font-size:8px; letter-spacing:1px}
}
#feed{
  width:100%; max-width:680px; flex:1; overflow-y:auto; margin-top:4px; padding:0 10px;
  display:flex; flex-direction:column; gap:6px; scrollbar-width:thin;
}
.msg{font-size:14.5px; line-height:1.35; padding:7px 11px; border:1px solid var(--line); background:#08152399; max-width:88%}
.msg.you{align-self:flex-end; border-color:#205a6e; color:#cfeefb}
.msg.jarvis{align-self:flex-start; border-left:2px solid var(--cyan)}
.msg.sys{align-self:center; color:var(--txt-dim); font-size:12px; border:none; background:none; padding:2px}
#chatRow{display:flex; gap:8px; align-items:center; width:100%; max-width:680px; padding:8px 10px}
#chatInput{
  flex:1 1 auto; min-width:0; height:39px; background:#06101c; border:1px solid var(--line); color:#cfeefb; padding:0 12px;
  font-family:'Rajdhani'; font-size:15px; outline:none;
}
#chatInput:focus{border-color:var(--cyan-dim); box-shadow:0 0 8px #00e5ff33}
/* chat controls — BILD / SEND / COPY / CLEAR all live in the one bar directly
   underneath the chat window, in that order (input between BILD and SEND). No
   control is layered over the voice HUD above the transcript any more, so the
   ring and the buttons can no longer swallow each other's taps. */
#chatRow .btn{height:39px; padding:0 16px; flex:0 0 auto; display:inline-flex; align-items:center; justify-content:center}
#chatRow .btn.iconOnly{
  display:inline-flex; align-items:center; justify-content:center;
  width:44px; min-width:44px; padding:0;
}
#chatRow .btn.iconOnly .icon{width:17px; height:17px; flex-shrink:0; fill:none; stroke:currentColor;
  stroke-width:1.7; stroke-linecap:round; stroke-linejoin:round}
#chatRow .btn.iconOnly:disabled{opacity:.4; cursor:not-allowed; box-shadow:none}
#chatRow .btn.iconOnly:disabled:hover{background:#0a2435; box-shadow:none}
/* feedback line for COPY/CLEAR: zero-height row so showing a message never
   moves the chat window or the button bar. */
#chatToolRow{position:relative; height:0; width:100%; max-width:680px; padding:0}
#chatToolMsg{
  position:absolute; left:10px; right:10px; top:4px; display:block; text-align:right;
  font-size:11px; letter-spacing:2px; color:var(--teal);
  overflow:hidden; text-overflow:ellipsis; white-space:nowrap;
}
#chatToolMsg.err{color:var(--red)}
/* Voice-input abort banner (message + retry) under the chat row. Every abort
   path of the voice input must be visible: never a silent drop. */
#voiceStatus{
  display:flex; align-items:center; gap:10px; flex-wrap:wrap;
  margin:6px 0; padding:7px 10px; width:100%; max-width:680px;
  font-size:12.5px; line-height:1.35;
  border:1px solid var(--amber); background:#1a1305f2; color:var(--txt);
}
#voiceStatus[hidden]{display:none}
#voiceStatus.is-error{border-color:var(--red); background:#1c070bf2}
#voiceStatus.is-info{border-color:var(--cyan-dim); background:#061825f2}
#voiceStatus .vf-body{flex:1 1 auto; min-width:0}
#voiceStatus .vf-title{color:var(--amber)}
#voiceStatus.is-error .vf-title{color:var(--red)}
#voiceStatus.is-info .vf-title{color:var(--cyan)}
#voiceStatus .vf-detail{color:var(--txt-dim); font-size:11px}
#voiceStatus .vf-retry{flex:0 0 auto; padding:6px 12px}
button.btn{
  background:#0a2435; color:var(--cyan); border:1px solid var(--cyan-dim); padding:9px 16px;
  font-family:'Orbitron'; font-size:11px; letter-spacing:2px; cursor:pointer;
}
button.btn:hover{background:#0e3349; box-shadow:0 0 10px #00e5ff44}
button.btn.danger{color:var(--red); border-color:#7a2a33; background:#240a0e}
button.btn.danger:hover{background:#3a0e15; box-shadow:0 0 10px #ff4d5e55}
button.btn.amber{color:var(--amber); border-color:#7a5a1a; background:#241c0a}
#stopBtn{display:none}
#approvals{position:absolute; top:8px; left:50%; transform:translateX(-50%); z-index:20; width:min(560px,92%); display:flex; flex-direction:column; gap:8px}
.appr{border:1px solid var(--amber); background:#1a1305f2; padding:12px 14px;
  box-shadow:0 0 24px #ffb30044; animation:apprIn .25s ease-out}
@keyframes apprIn{from{transform:translateY(-12px);opacity:0}to{transform:none;opacity:1}}
.appr h3{font-family:'Orbitron'; font-size:11px; letter-spacing:3px; color:var(--amber); margin-bottom:6px}
.appr .appr-meta{font-size:11px; letter-spacing:1px; color:#b79452; margin:-2px 0 8px; word-break:break-all}
.appr pre{font-size:12px; color:#ffd98a; white-space:pre-wrap; word-break:break-all; max-height:90px; overflow-y:auto; margin-bottom:9px}
.appr .row{display:flex; gap:10px; flex-wrap:wrap}
.appr .approval-actions{align-items:flex-start}
.appr .btn.approval-always{border-color:#c85; color:#ffd4a8; background:#2a1808}
.appr .approval-always-hint{font-size:11px; color:#c9a; margin:8px 0 0; line-height:1.35}
.msg.live{opacity:.65; font-style:italic}
/* ---- pop-up viewer (kanban / dashboard) ---- */
#viewer{position:fixed; inset:0; z-index:40; display:none; align-items:center; justify-content:center;
  background:#02060cd9; backdrop-filter:blur(4px)}
#viewer.open{display:flex}
#viewerBox{width:90%; height:90%; position:relative; background:#050b14;
  border:1px solid var(--cyan-dim); box-shadow:0 0 60px #00e5ff2e, inset 0 0 40px #00e5ff08;
  animation:viewIn .32s cubic-bezier(.2,.9,.3,1.2);
  clip-path:polygon(0 0,calc(100% - 22px) 0,100% 22px,100% 100%,22px 100%,0 calc(100% - 22px))}
@keyframes viewIn{from{transform:scale(.88) translateY(20px);opacity:0}to{transform:none;opacity:1}}
#viewerBar{display:flex; align-items:center; justify-content:space-between; height:40px;
  padding:0 14px; border-bottom:1px solid var(--line); background:#081523}
#viewerBar h3{font-family:'Orbitron'; font-size:12px; letter-spacing:4px; color:var(--cyan);
  text-shadow:0 0 10px #00e5ff66}
#viewerBar .vbtns{display:flex; gap:8px}
#viewerIframe{width:100%; height:calc(100% - 40px); border:0; background:#0a1420}
#viewerBox::before,#viewerBox::after{content:""; position:absolute; width:26px; height:26px;
  border:2px solid var(--cyan); pointer-events:none}
#viewerBox::before{top:-2px; left:-2px; border-right:none; border-bottom:none}
#viewerBox::after{bottom:-2px; right:-2px; border-left:none; border-top:none}
.viewBtn{display:block; width:100%; text-align:left; margin-bottom:6px}

/* ---------------- boot sequence ---------------- */
#boot{position:fixed; inset:0; z-index:100; background:#020509; display:flex;
  flex-direction:column; align-items:center; justify-content:center; transition:opacity .7s}
#boot.done{opacity:0; pointer-events:none}
#boot::after{content:""; position:absolute; inset:0; pointer-events:none;
  background:repeating-linear-gradient(0deg, transparent 0 3px, #00e5ff06 3px 6px)}
#bootLogo{font-family:'Orbitron'; font-size:clamp(22px,5vw,38px); letter-spacing:14px;
  color:var(--cyan); text-shadow:0 0 34px #00e5ff99; animation:bootPulse 1.4s ease-in-out infinite}
#bootSub{font-size:11px; letter-spacing:6px; color:var(--txt-dim); margin-top:10px}
#bootLines{margin-top:30px; font-size:13px; letter-spacing:2px; color:var(--txt-dim);
  width:min(360px,80vw); min-height:140px; font-family:'Rajdhani'}
#bootLines div{opacity:0; animation:lineIn .2s forwards; padding:2px 0}
#bootLines div b{color:var(--teal); float:right}
@keyframes lineIn{to{opacity:1}}
@keyframes bootPulse{50%{opacity:.5}}
body.booting .panel, body.booting header, body.booting footer,
body.booting #chatRow, body.booting #chatToolRow, body.booting #reactorWrap, body.booting #feed{opacity:0}
body.booted .panel{animation:panelIn .55s backwards}
body.booted header{animation:panelIn .4s backwards}
@keyframes panelIn{0%{opacity:0; transform:translateY(10px)}55%{opacity:.45}65%{opacity:.95}
  75%{opacity:.35}85%{opacity:1}100%{opacity:1; transform:none}}

/* ---------------- holographic media panels ---------------- */
#holoStage{position:fixed; inset:0; z-index:38; pointer-events:none;
  perspective:1200px; transform-style:preserve-3d; overflow:hidden}
#grid{transition:transform .45s ease, filter .45s ease}
#grid.dolly{transform:scale(1.02); filter:brightness(.7)}
.holo{position:absolute; pointer-events:auto; transform-style:preserve-3d;
  --enterRotY:-20deg; --bankX:0px;
  width:min(62vw,900px); height:min(58vh,540px);
  left:50%; top:45%; translate:-50% -50%;
  background:#081523f2; border:1px solid var(--cyan-dim);
  box-shadow:0 0 40px #00e5ff33, inset 0 0 60px #00e5ff0a;
  clip-path:polygon(0 0,calc(100% - 18px) 0,100% 18px,100% 100%,18px 100%,0 calc(100% - 18px));
  animation:holoApproach .65s cubic-bezier(.34,1.56,.64,1) both}
.holo.pos-left{left:19%; --enterRotY:38deg; --bankX:-55vw; width:min(31vw,480px); height:min(40vh,380px)}
.holo.pos-right{left:81%; --enterRotY:-38deg; --bankX:55vw; width:min(31vw,480px); height:min(40vh,380px)}
@keyframes holoApproach{
  0%{opacity:0; filter:blur(10px) brightness(2.2);
     transform:translateX(var(--bankX)) translateZ(-800px) rotateX(35deg) rotateY(var(--enterRotY)) scale(.3)}
  55%{opacity:.85; filter:blur(2px) brightness(1.45);
     transform:translateX(calc(var(--bankX)*.15)) translateZ(-160px) rotateX(8deg) rotateY(calc(var(--enterRotY)*.35)) scale(.92)}
  100%{opacity:1; filter:none; transform:translateX(0) translateZ(0) rotateX(0) rotateY(0) scale(1)}}
.holo.idle{animation:holoIdle 4s ease-in-out infinite}
@keyframes holoIdle{
  0%,100%{transform:translateY(0); box-shadow:0 0 40px #00e5ff33, inset 0 0 60px #00e5ff0a}
  50%{transform:translateY(-3px); box-shadow:0 0 54px #00e5ff4d, inset 0 0 60px #00e5ff14}}
.holo.dismiss{animation:holoDismiss .6s cubic-bezier(.55,0,.85,.36) both}
.holo.dismiss .holoContentWrap{filter:saturate(0) brightness(1.6) contrast(1.4)}
@keyframes holoDismiss{
  0%{opacity:1; transform:none; filter:none}
  35%{opacity:.9; filter:blur(1px) brightness(1.5)}
  100%{opacity:0; filter:blur(14px);
    transform:translateX(calc(var(--bankX)*-.3)) translateZ(-900px) rotateX(-25deg) rotateY(calc(var(--enterRotY)*-1)) scale(.25)}}
.holoFrame{position:absolute; inset:0; width:100%; height:100%; pointer-events:none}
.holoFrame rect{fill:none; stroke:var(--cyan); stroke-width:1.5; opacity:.9;
  stroke-dasharray:100; stroke-dashoffset:100; animation:holoTrace .5s linear .15s forwards}
@keyframes holoTrace{to{stroke-dashoffset:0}}
.holoFrame path{fill:none; stroke:var(--cyan); stroke-width:2.5; opacity:0;
  filter:drop-shadow(0 0 5px var(--cyan)); animation:holoCorner .12s steps(2) .55s forwards}
@keyframes holoCorner{to{opacity:1}}
.holoBar{position:absolute; top:0; left:0; right:0; height:30px; z-index:3; display:flex;
  align-items:center; justify-content:space-between; padding:0 12px;
  border-bottom:1px solid var(--line); background:#08152399;
  font-family:'Orbitron'; font-size:10px; letter-spacing:3px; color:var(--cyan)}
.holoBar .hx{cursor:pointer; color:var(--red); font-size:13px; padding:0 4px}
.holoContentWrap{position:absolute; inset:30px 8px 8px 8px; opacity:0;
  animation:holoBodyIn .3s steps(3) .35s forwards; overflow:hidden; background:#050b14}
@keyframes holoBodyIn{0%{opacity:0}45%{opacity:.35}70%{opacity:.85}100%{opacity:1}}
.holoContent{width:100%; height:100%; border:0; object-fit:contain; background:#050b14}
.holoHex{position:absolute; inset:30px 8px 8px 8px; pointer-events:none; opacity:.5;
  background:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='28' height='32'%3E%3Cpath d='M14 1 27 8.5v15L14 31 1 23.5v-15z' fill='none' stroke='%2300e5ff' stroke-opacity='.3'/%3E%3C/svg%3E");
  animation:holoHexOut .4s ease .65s forwards}
@keyframes holoHexOut{to{opacity:0}}
.holoScan{position:absolute; inset:30px 8px 8px 8px; pointer-events:none; z-index:2; opacity:0;
  background:linear-gradient(180deg, transparent 0%, #00e5ff22 44%, #00e5ffbb 50%, #00e5ff22 56%, transparent 100%);
  background-size:100% 300%; animation:holoScanSweep .42s linear .33s}
@keyframes holoScanSweep{0%{opacity:1; background-position:0 -100%}100%{opacity:0; background-position:0 200%}}
.holoChroma{position:absolute; inset:0; pointer-events:none; z-index:2; mix-blend-mode:screen;
  opacity:0; animation:holoChromaFlick .38s steps(4) .35s}
.holoChroma.c1{box-shadow:inset 0 0 0 2px #ff00ff66; transform:translateX(2px)}
.holoChroma.c2{box-shadow:inset 0 0 0 2px #00ffff66; transform:translateX(-2px)}
@keyframes holoChromaFlick{0%{opacity:.85}60%{opacity:.4}100%{opacity:0}}
.holoBoot{position:absolute; right:12px; bottom:8px; z-index:3; pointer-events:none;
  font-family:monospace; font-size:9px; line-height:1.3; color:var(--teal);
  text-align:right; opacity:.85; transition:opacity .6s}

/* ---------------- mobile / narrow screens ---------------- */
@media (max-width:880px){
  .holo,.holo.pos-left,.holo.pos-right{width:94vw; height:50vh; left:50%}
  body{overflow-y:auto; overflow-x:hidden}
  #grid{display:flex; flex-direction:column; height:auto; min-height:100dvh; gap:8px}
  header{position:sticky; top:0; z-index:15; flex-shrink:0}
  header h1{font-size:15px; letter-spacing:4px}
  header .sub{display:none}
  #clock{font-size:12px}
  #center{order:1; min-height:0}
  #reactorWrap{width:min(62vw,260px); height:min(62vw,260px)}
  #coreState .st{font-size:12px; letter-spacing:4px}
  #coreState .hint{font-size:8px}
  #feed{max-height:34dvh; min-height:90px}
  #chatRow{gap:6px; padding:10px 8px}
  #chatRow .btn{height:44px; padding:0 14px}   /* touch-friendly, all four still fit 320px */
  #chatRow .btn.iconOnly{width:44px; min-width:44px; padding:0}
  #chatInput{height:44px; padding:0 10px}
  .col{order:2; overflow:visible; flex-shrink:0}
  .col:last-of-type{order:3}
  footer{order:4; flex-shrink:0; padding:6px 14px}
  #viewerBox{width:97%; height:94%}
  #approvals{width:94%}
}

/* ---------------- very narrow phones: grow the input, slide the bar to SEND --
   Nachbesserung 2 — only below 500px. Under the chat window the bar reads
   BILD | input | SEND | COPY | CLEAR. As soon as the input takes focus (the
   user starts writing) the row is widened by the room COPY and CLEAR take up
   (44 + 44 + the two 6px gaps = 100px) plus the row's own 8px right padding,
   so the flexible input grows by 108px and pushes the two icon buttons plus
   SEND to the right: SEND comes to rest exactly on the right edge of the chat
   column, COPY and CLEAR glide past it out of the visible area. Not one button
   changes its size — SEND keeps its 73px, the icons their 44px; only the
   input's width animates. #center clips the overflow (it already has
   overflow:hidden), so nothing leaves the page and no horizontal scrollbar
   appears. Blur runs the transition backwards. Height never changes, so the
   chat window keeps its exact size; >=500px widths, tablets and desktop never
   match this block. */
@media (max-width:499.98px){
  #chatRow{align-self:flex-start; transition:width .32s ease}
  #chatRow.chat-collapsed{width:calc(100% + 108px)}
}
#activity{max-height:150px; overflow-y:auto; font-size:12.5px}
#activity div{padding:2px 0; color:var(--txt-dim)}
#activity div b{color:var(--amber)}
#skillsList,#jobsList{max-height:130px; overflow-y:auto; font-size:12.5px}
#toolsetList{max-height:170px; overflow-y:auto; scrollbar-width:thin}
#skillsList div,#jobsList div{padding:1.5px 0; white-space:nowrap; overflow:hidden; text-overflow:ellipsis}
footer{
  grid-column:1/4; display:flex; align-items:center; justify-content:space-between;
  font-size:11px; letter-spacing:2px; color:var(--txt-dim); padding:0 14px;
}
.bar{height:3px; background:#0a2435; margin-top:3px}
.bar i{display:block; height:100%; background:linear-gradient(90deg,var(--cyan-dim),var(--cyan)); width:0%; transition:width .4s}
.run-strip{margin-top:8px; display:flex; flex-direction:column; gap:4px; max-height:120px; overflow-y:auto}
.run-chip{
  display:flex; align-items:center; gap:6px; padding:4px 6px; border:1px solid var(--line);
  background:#06101c88; font-size:11px; letter-spacing:1px;
}
.run-chip .rid{font-family:'Orbitron'; font-size:9px; color:var(--cyan-dim); flex-shrink:0}
.run-chip .rtitle{flex:1; overflow:hidden; text-overflow:ellipsis; white-space:nowrap; color:var(--txt)}
.run-chip .rstatus{font-size:9px; color:var(--teal); flex-shrink:0}
.run-chip.queued{border-style:dashed; opacity:.92}
.run-chip.queued .rstatus{color:var(--cyan-dim)}
.run-chip.failed{border-color:#ff6b6b88}
.run-chip.failed .rstatus{color:#ff6b6b}
.run-chip button{padding:2px 8px; font-size:9px; letter-spacing:1px; flex-shrink:0}
/* ALERTS panel — master switch for the tone/vibration approval signal.
   Pure additive block: only the .alert-toggle* classes are styled here, the
   surrounding .panel/.kv layout stays untouched. */
.alert-toggle{
  display:flex; align-items:center; gap:8px; cursor:pointer; user-select:none;
  font-size:13px; color:var(--txt); padding:2px 0;
}
.alert-toggle input{
  position:absolute; width:1px; height:1px; opacity:0; margin:-1px; padding:0;
  border:0; overflow:hidden; clip:rect(0 0 0 0); clip-path:inset(50%); white-space:nowrap;
}
.alert-toggle-track{
  flex-shrink:0; width:38px; height:20px; border:1px solid var(--cyan-dim); border-radius:10px;
  background:#06101c; position:relative; transition:background .2s, border-color .2s;
}
.alert-toggle-knob{
  position:absolute; top:2px; left:2px; width:14px; height:14px; border-radius:50%;
  background:var(--teal); box-shadow:0 0 6px var(--teal); transition:transform .2s, background .2s, box-shadow .2s;
}
.alert-toggle input:checked + .alert-toggle-track{background:#0b2f3d; border-color:var(--teal)}
.alert-toggle input:checked + .alert-toggle-track .alert-toggle-knob{transform:translateX(18px)}
.alert-toggle input:focus-visible + .alert-toggle-track{outline:2px solid var(--cyan); outline-offset:2px}
.alert-toggle.is-off .alert-toggle-track{border-color:var(--txt-dim); background:#0a1219}
.alert-toggle.is-off .alert-toggle-knob{background:var(--txt-dim); box-shadow:none}
.alert-toggle-label{flex:1; min-width:0}
.alert-toggle-state{
  flex-shrink:0; font-family:'Orbitron'; font-size:9px; letter-spacing:2px;
  color:var(--teal); border:1px solid var(--line); padding:1px 6px;
}
.alert-toggle.is-off .alert-toggle-state{color:var(--txt-dim)}
.alert-toggle-hint{font-size:11px; color:var(--txt-dim); padding:6px 0 0; line-height:1.35}
.alert-toggle-note{
  font-size:11px; color:var(--amber,#ffb300); padding:5px 0 0; line-height:1.35;
  opacity:.85;
}
.alert-toggle-note[hidden]{display:none}
@media (max-width:760px){
  .alert-toggle{font-size:14px; gap:10px}
  .alert-toggle-hint{font-size:12px}
  .alert-toggle-note{font-size:12px}
}

