:root {
  --ink: #161714;
  --muted: #8b8d86;
  --line: #dedfd9;
  --soft: #f5f5f1;
  --paper: #fbfbf8;
  --accent: #f2683a;
  --green: #35a16b;
  --viewer: #171917;
}

* { box-sizing: border-box; }

html, body {
  width: 100%;
  height: 100%;
  margin: 0;
  overflow: hidden;
  color: var(--ink);
  background: var(--viewer);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

button, input { font: inherit; }
button { color: inherit; }

.sprite {
  width: 0;
  height: 0;
  position: absolute;
  overflow: hidden;
}

svg {
  width: 1em;
  height: 1em;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.app { height: 100%; }

.topbar {
  height: 42px;
  border-bottom: 1px solid #2b2d2a;
  padding: 0 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #e8e9e4;
  background: #111310;
}

.brand, .header-actions {
  display: flex;
  align-items: center;
}

.brand { gap: 9px; }

.brand-mark {
  width: 25px;
  height: 25px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  color: #121410;
  background: #f2f2ec;
}

.brand-mark svg { width: 17px; height: 17px; }

.brand > strong {
  font-size: 10px;
  letter-spacing: .12em;
}

.header-actions { gap: 7px; }

.device-status {
  height: 26px;
  border: 1px solid #30332f;
  border-radius: 14px;
  padding: 0 9px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: #a8aaa4;
  font-size: 9px;
  font-weight: 600;
}

.device-status i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #d9a244;
}

.device-status.ready i {
  background: var(--green);
  box-shadow: 0 0 0 3px rgba(53, 161, 107, .13);
}

.device-status.blocked i { background: #c76049; }

.icon-button, .tool, .zoom-bar button {
  border: 0;
  display: grid;
  place-items: center;
  background: transparent;
  cursor: pointer;
}

.icon-button {
  width: 29px;
  height: 29px;
  border-radius: 6px;
  color: #999c95;
}

.icon-button:hover { background: #242622; color: white; }
.icon-button svg { width: 17px; height: 17px; }

.run-button {
  height: 30px;
  border: 0;
  border-radius: 7px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 6px;
  color: white;
  background: var(--accent);
  font-size: 10px;
  font-weight: 700;
  cursor: pointer;
}

.run-button:hover { background: #dc5327; }
.run-button svg { width: 13px; height: 13px; }

.workspace {
  height: calc(100% - 42px);
  display: grid;
  grid-template-columns: 48px 278px minmax(0, 1fr);
  transition: grid-template-columns 190ms cubic-bezier(.2,.8,.2,1);
}

.activity-rail {
  min-height: 0;
  position: relative;
  z-index: 14;
  border-right: 1px solid #2b2d2a;
  padding: 10px 6px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  background: #111310;
}

.activity-rail > span { flex: 1; }

.rail-button {
  width: 36px;
  height: 36px;
  position: relative;
  border: 0;
  border-radius: 7px;
  display: grid;
  place-items: center;
  color: #747871;
  background: transparent;
  cursor: pointer;
}

.rail-button:hover { color: #dfe1da; background: #232522; }
.rail-button.active { color: white; background: #2b2e29; }
.rail-button.active::before {
  content: "";
  width: 3px;
  height: 18px;
  position: absolute;
  left: -6px;
  border-radius: 0 3px 3px 0;
  background: var(--accent);
}
.rail-button svg { width: 17px; height: 17px; }

.rail-avatar {
  width: 27px;
  height: 27px;
  border: 1px solid #41443e;
  border-radius: 50%;
  color: #b9bcb4;
  background: #272a26;
  font-size: 8px;
  font-weight: 700;
  cursor: pointer;
}

.pipeline-panel {
  min-height: 0;
  width: 278px;
  position: relative;
  z-index: 10;
  border-right: 1px solid var(--line);
  display: grid;
  grid-template-rows: 48px 53px 24px minmax(0, 1fr) 52px;
  background: var(--paper);
  box-shadow: 12px 0 35px rgba(0, 0, 0, .08);
}

.pipeline-head {
  padding: 0 11px 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.panel-head-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.collapse-button {
  width: 27px;
  height: 29px;
  border: 0;
  border-radius: 6px;
  display: grid;
  place-items: center;
  color: #8f918a;
  background: transparent;
  font-size: 18px;
  cursor: pointer;
}

.collapse-button:hover { color: #333530; background: #eeeeea; }

.overline {
  color: #a1a39c;
  font-size: 7px;
  letter-spacing: .14em;
  font-weight: 700;
}

h1 {
  margin: 0;
  font-size: 9px;
  line-height: 1;
  letter-spacing: .12em;
  font-weight: 800;
}

.add-button {
  height: 29px;
  border: 1px solid #d8d9d3;
  border-radius: 7px;
  padding: 0 9px;
  display: flex;
  align-items: center;
  gap: 5px;
  background: white;
  font-size: 9px;
  font-weight: 700;
  cursor: pointer;
}

.add-button:hover { border-color: #bfc1ba; background: #f8f8f5; }
.add-button svg { width: 12px; height: 12px; }
.add-button.context-add > i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #8c9088;
}
.add-button.context-add.route-orange > i { background: #f2683a; }
.add-button.context-add.route-violet > i { background: #8f71eb; }
.add-button.context-add.route-green > i { background: #4cb57b; }
.add-button.context-add.route-cyan > i { background: #43b4ca; }

.source-row {
  margin: 0 12px;
  border: 1px solid #dedfd9;
  border-radius: 8px;
  padding: 5px 8px 5px 5px;
  display: grid;
  grid-template-columns: 42px 1fr 18px;
  align-items: center;
  gap: 8px;
  text-align: left;
  background: white;
  cursor: pointer;
}

.source-row:hover { border-color: #bfc1ba; }

.source-row img {
  width: 42px;
  height: 42px;
  border-radius: 5px;
  object-fit: cover;
  background: #e7e4da;
}

.source-row strong, .source-row small { display: block; }
.source-row strong { font-size: 10px; }
.source-row small {
  max-width: 165px;
  margin-top: 2px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #959790;
  font-size: 8px;
}
.source-row > svg { width: 14px; height: 14px; color: #959790; }

.flow-caption {
  padding: 0 16px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  color: #a1a39c;
  font-size: 7px;
  letter-spacing: .11em;
  font-weight: 700;
}

.step-list {
  min-height: 0;
  position: relative;
  overflow-y: auto;
  padding: 7px 9px 18px;
  scrollbar-width: thin;
  overscroll-behavior: contain;
}

.step-card {
  min-height: 48px;
  position: relative;
  z-index: 1;
  border: 1px solid transparent;
  border-radius: 8px;
  margin-bottom: 7px;
  background: transparent;
  transition: background 120ms ease, border-color 120ms ease;
}

.wire-layer {
  min-width: 100%;
  position: absolute;
  left: 0;
  top: 0;
  z-index: 0;
  overflow: visible;
  pointer-events: none;
}

.connection-wire {
  fill: none;
  stroke: var(--wire);
  stroke-width: 1;
  stroke-linecap: round;
  stroke-linejoin: round;
  opacity: .22;
  vector-effect: non-scaling-stroke;
}

.connection-wire-hit {
  fill: none;
  stroke: transparent;
  stroke-width: 10;
  pointer-events: stroke;
  cursor: pointer;
}

.connection-wire-hit:hover + .connection-wire {
  stroke-width: 2;
  opacity: 1;
}

.connection-wire.active {
  stroke-width: 1.7;
  opacity: .9;
  filter: drop-shadow(0 0 3px color-mix(in srgb, var(--wire) 45%, transparent));
}

.step-card::after {
  display: none;
}

.step-card:last-child::after { display: none; }

.step-card.dragging { opacity: .35; }
.step-card.drag-over { border-color: var(--accent); }

.step-main {
  height: 48px;
  border-radius: 7px;
  padding: 0 5px 0 2px;
  display: grid;
  grid-template-columns: 18px 28px minmax(0, 1fr) auto auto;
  align-items: center;
  gap: 5px;
  cursor: pointer;
}

.branch-child {
  width: calc(100% - 18px);
  margin-left: 18px;
  border-color: rgba(255,255,255,.055);
  background: rgba(255,255,255,.018);
}

.branch-child::before {
  display: none;
}

.branch-child.route-text::before { border-color: rgba(242,104,58,.62); }
.branch-child.route-orange::before { border-color: rgba(242,104,58,.62); }
.branch-child.route-graphics::before { border-color: rgba(143,113,235,.65); }
.branch-child.route-violet::before { border-color: rgba(143,113,235,.65); }
.branch-child.route-tables::before { border-color: rgba(76,181,123,.62); }
.branch-child.route-green::before { border-color: rgba(76,181,123,.62); }
.branch-child.route-cyan::before { border-color: rgba(67,180,202,.65); }

.branch-child::after {
  display: none;
}

.branch-tag {
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 8px;
  padding: 2px 5px;
  color: #858981;
  background: rgba(255,255,255,.035);
  font-size: 6px;
  font-weight: 800;
  letter-spacing: .04em;
  text-transform: uppercase;
}

.branch-child.route-text .branch-tag { color: #e8997d; }
.branch-child.route-orange .branch-tag { color: #e8997d; }
.branch-child.route-graphics .branch-tag { color: #b6a2f4; }
.branch-child.route-violet .branch-tag { color: #b6a2f4; }
.branch-child.route-tables .branch-tag { color: #83d2a7; }
.branch-child.route-green .branch-tag { color: #83d2a7; }
.branch-child.route-cyan .branch-tag { color: #78c8d8; }
.step-card:hover .branch-tag,
.step-card.selected .branch-tag { display: none; }

.step-card:hover .step-main { background: #f0f0ec; }
.step-card.selected { border-color: #d6d7d0; background: white; box-shadow: 0 5px 18px rgba(30, 31, 28, .07); }
.step-card.selected .step-main { background: white; }
.step-card.running { border-color: rgba(242, 104, 58, .55); }
.step-card.done .step-number { color: white; background: var(--green); }

.node-inlet {
  width: 7px;
  height: 7px;
  position: absolute;
  left: -4px;
  top: 20px;
  z-index: 3;
  border: 1px solid #686c64;
  border-radius: 50%;
  background: #20231f;
}

.node-inlet.connected {
  border-color: #a7aba3;
  background: #747870;
  box-shadow: 0 0 0 2px rgba(116,120,112,.12);
}

.step-card.disconnected {
  border-color: rgba(217,162,68,.18);
}

.step-card.disconnected .step-main { opacity: .68; }

.node-state {
  border: 1px solid rgba(217,162,68,.2);
  border-radius: 8px;
  padding: 2px 5px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: #c59c55;
  background: rgba(217,162,68,.07);
  font-size: 6px;
  white-space: nowrap;
}

.node-state b {
  font-size: inherit;
  font-weight: 800;
}

.node-state > i {
  width: 5px;
  height: 5px;
  flex: none;
  border: 1px solid currentColor;
  border-top-color: transparent;
  border-radius: 50%;
  animation: node-live-spin 720ms linear infinite;
}

.node-state.ready,
.node-state.done {
  border-color: rgba(76,181,123,.22);
  color: #72ca99;
  background: rgba(76,181,123,.08);
}

.node-state.idle,
.node-state.queued,
.node-state.stopped {
  border-color: rgba(255,255,255,.1);
  color: #8c9188;
  background: rgba(255,255,255,.04);
}

.node-state.running {
  border-color: rgba(242,104,58,.34);
  color: #ff9a78;
  background: rgba(242,104,58,.11);
}

.node-state.error {
  border-color: rgba(239,91,73,.3);
  color: #ff8c7d;
  background: rgba(239,91,73,.09);
}

.node-state.bypassed {
  border-color: rgba(255,255,255,.08);
  color: #777b73;
  background: rgba(255,255,255,.025);
}

@keyframes node-live-spin {
  to { transform: rotate(360deg); }
}

.step-card.just-added {
  animation: node-added 900ms ease;
}

@keyframes node-added {
  0%, 35% { border-color: rgba(76,181,123,.8); box-shadow: 0 0 0 3px rgba(76,181,123,.13); }
}

.drag-handle {
  height: 36px;
  border: 0;
  display: grid;
  place-items: center;
  color: #b7b9b2;
  background: transparent;
  cursor: grab;
}

.drag-handle:active { cursor: grabbing; }
.drag-handle svg { width: 14px; height: 14px; }

.step-number {
  width: 25px;
  height: 25px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  color: #6b6e67;
  background: #ecece7;
  font-size: 8px;
  font-weight: 800;
}

.step-card.selected .step-number { color: white; background: var(--ink); }
.step-title { min-width: 0; }
.step-title strong, .step-title small { display: block; }
.step-title strong { font-size: 10px; line-height: 1.2; }
.step-title small {
  margin-top: 2px;
  overflow: hidden;
  color: #969890;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.step-actions {
  display: none;
  align-items: center;
}

.step-card:hover .step-actions, .step-card.selected .step-actions { display: flex; }
.branch-child .step-actions { display: flex; }
.branch-child .step-actions [data-move] { display: none; }

.step-actions button {
  width: 20px;
  height: 22px;
  border: 0;
  border-radius: 4px;
  display: grid;
  place-items: center;
  color: #999b94;
  background: transparent;
  cursor: pointer;
}

.step-actions button:hover { color: #333530; background: #e8e9e3; }
.step-actions svg { width: 12px; height: 12px; }

.step-config {
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  padding: 0 11px 0 53px;
  transition: max-height 180ms ease, opacity 150ms ease, padding 180ms ease;
}

.step-card.selected .step-config {
  max-height: 0;
  opacity: 0;
  padding-bottom: 0;
}

.node-inputs {
  border-top: 1px solid rgba(255,255,255,.075);
  padding: 8px 8px 8px 48px;
}

.inputs-head {
  height: 18px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  color: #71756d;
  font-size: 6px;
  font-weight: 800;
  letter-spacing: .1em;
}

.inputs-head small {
  color: #646860;
  font-size: 6px;
  font-weight: 600;
  letter-spacing: 0;
}

.node-input-port {
  min-width: 0;
  min-height: 36px;
  border: 1px solid rgba(217,162,68,.18);
  border-radius: 7px;
  padding: 5px 7px;
  display: grid;
  grid-template-columns: 7px minmax(0,1fr);
  align-items: center;
  gap: 7px;
  color: #c7cac2;
  background: rgba(217,162,68,.045);
}

.node-input-port.connected {
  border-color: rgba(255,255,255,.09);
  background: rgba(255,255,255,.035);
}

.node-input-port > i {
  width: 7px;
  height: 7px;
  border: 1px solid #b68a43;
  border-radius: 50%;
  background: transparent;
}

.node-input-port.connected > i {
  border-color: #4cb57b;
  background: #4cb57b;
  box-shadow: 0 0 0 3px rgba(76,181,123,.1);
}

.node-input-port span strong,
.node-input-port span small { display: block; }
.node-input-port span strong { font-size: 7px; }
.node-input-port span small { margin-top: 2px; color: #747870; font-size: 6px; }

.node-input-port > b {
  grid-column: 2;
  margin-top: -2px;
  overflow: hidden;
  color: #9a9e96;
  font-size: 6px;
  font-weight: 600;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.node-outputs {
  border-top: 1px solid rgba(255,255,255,.075);
  padding: 8px 8px 9px 48px;
}

.outputs-head {
  height: 18px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  color: #71756d;
  font-size: 6px;
  font-weight: 800;
  letter-spacing: .1em;
}

.outputs-head button {
  border: 0;
  padding: 0;
  display: flex;
  align-items: center;
  gap: 3px;
  color: #777b73;
  background: transparent;
  font-size: 6px;
  cursor: pointer;
}

.outputs-head svg { width: 9px; height: 9px; }

.output-chips {
  display: grid;
  grid-template-columns: repeat(3, minmax(0,1fr));
  gap: 5px;
}

.output-chips.count-2,
.output-chips.count-4 {
  grid-template-columns: repeat(2, minmax(0,1fr));
}

.output-chips.count-1 {
  grid-template-columns: minmax(0,1fr);
}

.output-chip {
  min-width: 0;
  min-height: 36px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 7px;
  display: grid;
  grid-template-columns: minmax(0,1fr) 16px;
  color: #c4c7bf;
  text-align: left;
  background: rgba(255,255,255,.035);
  overflow: hidden;
}

.output-chip:hover,
.output-chip.active {
  border-color: rgba(255,255,255,.2);
  background: rgba(255,255,255,.08);
}

.output-select {
  min-width: 0;
  height: 100%;
  border: 0;
  padding: 0 2px 0 4px;
  display: grid;
  grid-template-columns: 5px minmax(0,1fr);
  align-items: center;
  gap: 3px;
  color: inherit;
  text-align: left;
  background: transparent;
  cursor: pointer;
}

.output-add {
  width: 100%;
  height: 100%;
  min-width: 0;
  border: 0;
  border-left: 1px solid rgba(255,255,255,.08);
  padding: 0;
  display: grid;
  place-items: center;
  color: #8b8f87;
  background: transparent;
  line-height: 0;
  cursor: pointer;
}

.output-add svg {
  width: 11px;
  height: 11px;
  pointer-events: none;
}

.output-add:hover {
  color: #e5e7e0;
  background: rgba(255,255,255,.08);
}

.output-add:focus-visible,
.output-select:focus-visible {
  outline: 1px solid rgba(242,104,58,.85);
  outline-offset: -2px;
}

.output-select i,
.route-detail-summary > i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #8c9088;
}

.output-chip.route-text .output-select i,
.output-chip.route-orange .output-select i,
.route-detail-summary.route-text > i { background: #f2683a; }
.output-chip.route-graphics .output-select i,
.output-chip.route-violet .output-select i,
.route-detail-summary.route-graphics > i { background: #8f71eb; }
.output-chip.route-tables .output-select i,
.output-chip.route-green .output-select i,
.route-detail-summary.route-tables > i { background: #4cb57b; }
.output-chip.route-cyan .output-select i,
.route-detail-summary.route-cyan > i { background: #43b4ca; }
.route-detail-summary.route-orange > i { background: #f2683a; }
.route-detail-summary.route-violet > i { background: #8f71eb; }
.route-detail-summary.route-green > i { background: #4cb57b; }

.output-chip span,
.output-chip strong,
.output-chip small {
  min-width: 0;
  display: block;
}

.output-chip strong {
  overflow: hidden;
  font-size: 7px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.output-chip small { margin-top: 2px; color: #747870; font-size: 6px; }

.route-composer {
  margin-top: 7px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 8px;
  padding: 7px;
  background: rgba(10,12,9,.55);
  animation: composer-in 140ms ease;
}

@keyframes composer-in {
  from { opacity: 0; transform: translateY(-4px); }
}

.route-composer > div:first-child {
  height: 19px;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  color: #8d9189;
  font-size: 7px;
  font-weight: 700;
}

.route-composer > div:first-child button {
  border: 0;
  color: #747870;
  background: transparent;
  cursor: pointer;
}

.route-option-section + .route-option-section { margin-top: 9px; }

.route-option-label {
  margin-bottom: 5px;
  display: block;
  color: #666a63;
  font-size: 6px;
  font-weight: 800;
  letter-spacing: .09em;
}

.route-existing-grid {
  display: grid;
  gap: 5px;
}

.route-existing-grid > button {
  min-width: 0;
  min-height: 38px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 6px;
  padding: 5px;
  display: grid;
  grid-template-columns: 23px minmax(0,1fr) 12px;
  align-items: center;
  gap: 6px;
  color: #d9dbd4;
  text-align: left;
  background: rgba(255,255,255,.045);
  cursor: pointer;
}

.route-existing-grid > button:hover {
  border-color: rgba(76,181,123,.42);
  background: rgba(76,181,123,.09);
}

.route-existing-grid > button > b {
  width: 23px;
  height: 23px;
  border-radius: 5px;
  display: grid;
  place-items: center;
  color: #a7d9bd;
  background: rgba(76,181,123,.13);
  font-size: 6px;
}

.route-existing-grid strong,
.route-existing-grid small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.route-existing-grid strong { font-size: 7px; }
.route-existing-grid small { margin-top: 2px; color: #71756d; font-size: 6px; }
.route-existing-grid svg { width: 11px; height: 11px; color: #777b73; }

.route-option-empty {
  min-height: 30px;
  border: 1px dashed rgba(255,255,255,.08);
  border-radius: 6px;
  display: grid;
  place-items: center;
  color: #656961;
  font-size: 6px;
}

.route-add-new {
  width: 100%;
  min-height: 40px;
  margin-top: 9px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 6px;
  padding: 5px 7px;
  display: grid;
  grid-template-columns: 18px minmax(0,1fr) 12px;
  align-items: center;
  gap: 6px;
  color: #d9dbd4;
  text-align: left;
  background: rgba(255,255,255,.045);
  cursor: pointer;
}

.route-add-new:hover {
  border-color: rgba(242,104,58,.38);
  background: rgba(242,104,58,.09);
}

.route-add-new > svg:first-child {
  width: 16px;
  height: 16px;
  border-radius: 5px;
  padding: 3px;
  color: #f0a087;
  background: rgba(242,104,58,.13);
}

.route-add-new > svg:last-child {
  width: 11px;
  height: 11px;
  color: #777b73;
}

.route-add-new strong,
.route-add-new small { display: block; }
.route-add-new strong { font-size: 7px; }
.route-add-new small { margin-top: 2px; color: #71756d; font-size: 6px; }

.route-contract {
  margin-top: 8px;
  border-top: 1px solid rgba(255,255,255,.07);
  padding-top: 7px;
  display: flex;
  align-items: center;
  gap: 5px;
  color: #62665e;
  font-size: 6px;
}

.route-contract b {
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 8px;
  padding: 2px 5px;
  color: #8d9189;
  font-weight: 700;
}

.route-contract span:last-child {
  margin-left: auto;
  text-align: right;
}

.config-row {
  min-height: 28px;
  border-top: 1px solid #edeee9;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #777a73;
  font-size: 8px;
}

.config-row:first-child { border-top: 0; }

.config-row button {
  border: 0;
  padding: 3px 5px;
  border-radius: 4px;
  color: #4d504a;
  background: #efefe9;
  font-size: 8px;
  font-weight: 600;
  cursor: pointer;
}

.mini-range {
  width: 76px;
  height: 3px;
  accent-color: var(--accent);
}

.pipeline-footer {
  border-top: 1px solid var(--line);
  padding: 9px 11px;
}

.gpu-meter {
  height: 39px;
  border-radius: 7px;
  padding: 0 8px;
  display: grid;
  grid-template-columns: 22px 1fr auto;
  align-items: center;
  gap: 6px;
  background: #f0f0eb;
}

.gpu-meter > svg { width: 15px; height: 15px; color: #7458c2; }
.gpu-meter span strong, .gpu-meter span small { display: block; }
.gpu-meter span strong { font-size: 8px; }
.gpu-meter span small { margin-top: 1px; color: #979990; font-size: 7px; }
.gpu-meter b { color: #6c6e68; font-size: 7px; }

.step-picker {
  position: absolute;
  inset: 0;
  z-index: 20;
  transform: translateX(-102%);
  padding: 13px;
  background: rgba(251, 251, 248, .98);
  backdrop-filter: blur(14px);
  overflow-y: auto;
  overscroll-behavior: contain;
  transition: transform 190ms ease;
}

.step-picker.open { transform: translateX(0); }

.section-view {
  position: absolute;
  inset: 0;
  z-index: 19;
  transform: translateX(-102%);
  padding: 14px 12px;
  background: var(--paper);
  overflow-y: auto;
  overscroll-behavior: contain;
  transition: transform 190ms cubic-bezier(.2,.8,.2,1);
}

.section-view.open { transform: translateX(0); }

.section-view-head {
  height: 36px;
  padding: 0 2px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 7px;
}

.section-view-head h2 {
  margin: 0;
  font-size: 9px;
  letter-spacing: .12em;
  font-weight: 800;
}

.section-view-head button {
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 6px;
  color: #777a73;
  background: transparent;
  font-size: 18px;
  cursor: pointer;
}

.section-view-head button:hover { background: #ecece7; }
.section-view-body { padding-top: 8px; }

.section-action {
  width: 100%;
  height: 34px;
  margin-bottom: 10px;
  border: 1px solid #d8d9d3;
  border-radius: 7px;
  background: white;
  font-size: 9px;
  font-weight: 700;
  cursor: pointer;
}

.section-row {
  min-height: 52px;
  border-bottom: 1px solid #e8e9e3;
  display: grid;
  grid-template-columns: 34px 1fr auto;
  align-items: center;
  gap: 8px;
}

.section-row-icon {
  width: 31px;
  height: 31px;
  border-radius: 7px;
  display: grid;
  place-items: center;
  color: #6550aa;
  background: #eeeaf9;
  font-size: 8px;
  font-weight: 800;
}

.section-row-icon img {
  width: 100%;
  height: 100%;
  border-radius: inherit;
  object-fit: cover;
}

.section-row strong, .section-row small { display: block; }
.section-row strong { font-size: 9px; }
.section-row small { margin-top: 2px; color: #989a93; font-size: 7px; }
.section-row > small { margin: 0; color: #898c84; }

.picker-head {
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 7px;
}

.picker-head strong { font-family: "Manrope", sans-serif; font-size: 13px; }
.picker-head button {
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 6px;
  color: #6f716b;
  background: transparent;
  font-size: 18px;
  cursor: pointer;
}

.picker-search {
  height: 34px;
  margin: 7px 0 12px;
  border: 1px solid #d9dad4;
  border-radius: 7px;
  padding: 0 9px;
  display: flex;
  align-items: center;
  gap: 7px;
  background: white;
}
.picker-search svg { width: 13px; height: 13px; color: #93958e; }
.picker-search input { min-width: 0; flex: 1; border: 0; outline: 0; font-size: 9px; }

.picker-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 13px; }

.picker-catalog-summary {
  min-width: 0;
  padding: 0 2px;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  color: #a5a9a0;
  font-size: 7px;
}

.picker-catalog-summary span {
  color: #d9dcd4;
  font-weight: 800;
  letter-spacing: .04em;
}

.picker-catalog-summary small {
  text-align: right;
  font-size: 6px;
}

.picker-category {
  min-width: 0;
}

.picker-category-head {
  min-height: 31px;
  margin: 0;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 7px;
  padding: 0 8px;
  display: grid;
  grid-template-columns: 12px minmax(0, 1fr) auto;
  align-items: center;
  gap: 5px;
  color: #888b84;
  background: rgba(255,255,255,.035);
  cursor: pointer;
  list-style: none;
}

.picker-category-head::-webkit-details-marker {
  display: none;
}

.picker-category-head strong {
  font-size: 7px;
  letter-spacing: .12em;
  text-transform: uppercase;
}

.picker-category-head span {
  font-size: 7px;
}

.picker-category-chevron {
  font-size: 13px !important;
  transform: rotate(0deg);
  transition: transform 140ms ease;
}

.picker-category[open] .picker-category-chevron {
  transform: rotate(90deg);
}

.picker-category-grid {
  margin-top: 7px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 7px;
}

.picker-empty {
  border: 1px dashed #dedfd9;
  border-radius: 8px;
  padding: 22px 12px;
  color: #8a8d86;
  font-size: 8px;
  text-align: center;
}

.picker-item {
  min-width: 0;
  border: 1px solid #dedfd9;
  border-radius: 8px;
  background: white;
  overflow: hidden;
}
.picker-item:hover { border-color: #aaaCA5; box-shadow: 0 6px 18px rgba(30, 31, 28, .07); }

.picker-item-main {
  width: 100%;
  min-height: 56px;
  border: 0;
  padding: 8px;
  display: grid;
  grid-template-columns: 28px minmax(0, 1fr) 22px;
  align-items: center;
  gap: 8px;
  color: inherit;
  text-align: left;
  background: transparent;
  cursor: pointer;
}

.picker-item-icon {
  width: 24px;
  height: 24px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  color: #6250a5;
  background: #eeeaf9;
  font-size: 8px;
  font-weight: 800;
}

.picker-item-copy {
  min-width: 0;
}

.picker-item-copy strong,
.picker-item-copy small {
  display: block;
}

.picker-item-copy strong {
  font-size: 9px;
}

.picker-item-copy small {
  margin-top: 2px;
  color: #989a93;
  font-size: 7px;
  line-height: 1.35;
}

.picker-item-add {
  width: 20px;
  height: 20px;
  border: 1px solid rgba(112,91,180,.2);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #765fc0;
  background: rgba(118,95,192,.08);
  font-size: 12px;
}

.picker-node-details {
  border-top: 1px solid #e8e9e4;
}

.picker-node-details > summary {
  min-height: 29px;
  padding: 0 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 7px;
  color: #777b73;
  cursor: pointer;
  list-style: none;
}

.picker-node-details > summary::-webkit-details-marker {
  display: none;
}

.picker-node-details > summary span {
  font-size: 7px;
  font-weight: 700;
}

.picker-node-details > summary small {
  color: #a0a39c;
  font-size: 6px;
}

.picker-node-details[open] > summary {
  background: rgba(118,95,192,.045);
}

.picker-node-detail-body {
  padding: 0 8px 9px;
}

.picker-purpose {
  margin: 7px 0;
  color: #777a74;
  font-size: 7px;
  line-height: 1.5;
}

.picker-runtime {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 8px;
}

.picker-runtime span,
.picker-port-contract code,
.picker-port-contract em {
  border-radius: 9px;
  padding: 2px 5px;
  color: #7d8079;
  background: #f0f1ed;
  font-family: inherit;
  font-size: 6px;
  font-style: normal;
}

.picker-contract-list {
  display: grid;
  gap: 6px;
}

.picker-port {
  min-width: 0;
  border: 1px solid #e6e7e2;
  border-radius: 6px;
  padding: 6px;
}

.picker-port-contract {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 4px;
}

.picker-port-contract > span {
  color: #8b6ad4;
  font-size: 6px;
  font-weight: 900;
  letter-spacing: .1em;
}

.picker-port-output .picker-port-contract > span {
  color: #d67a48;
}

.picker-port-contract strong {
  min-width: 66px;
  flex: 1;
  font-size: 7px;
}

.picker-port-contract em {
  color: #70836d;
  background: #edf3eb;
}

.picker-compatible-list {
  margin-top: 5px;
}

.picker-compatible-list > summary {
  color: #969a91;
  font-size: 6px;
  cursor: pointer;
}

.picker-compatible-names,
.picker-compatible-empty,
.picker-terminal {
  margin: 5px 0 0;
  color: #7f827b;
  font-size: 6px;
  line-height: 1.5;
}

.picker-compatible-empty,
.picker-terminal {
  color: #9b7a65;
}

.document-viewport {
  min-width: 0;
  min-height: 0;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 42%, #282b27 0, #1d201d 44%, #151714 100%);
  cursor: grab;
  touch-action: none;
}

.workspace.pipeline-hidden {
  grid-template-columns: 48px 0 minmax(0, 1fr);
}

.workspace.pipeline-hidden .pipeline-panel {
  transform: translateX(-102%);
  pointer-events: none;
}

.pipeline-panel {
  transition: transform 190ms ease;
}

.reopen-panel {
  width: 34px;
  height: 34px;
  position: absolute;
  top: 14px;
  z-index: 12;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 8px;
  display: grid;
  place-items: center;
  color: #d5d7d0;
  background: rgba(17,19,16,.88);
  box-shadow: 0 9px 30px rgba(0,0,0,.22);
  backdrop-filter: blur(12px);
  cursor: pointer;
}


.document-viewport.panning { cursor: grabbing; }

.document-viewport::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: .28;
  background-image: radial-gradient(rgba(255,255,255,.16) .5px, transparent .5px);
  background-size: 8px 8px;
}

.image-stage {
  width: 1px;
  height: 1px;
  position: absolute;
  left: 0;
  top: 0;
  transform-origin: 0 0;
  will-change: transform;
  box-shadow: 0 28px 80px rgba(0, 0, 0, .38), 0 2px 10px rgba(0,0,0,.45);
}

.image-stage img {
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
  user-select: none;
  transition: filter 170ms ease;
}

.image-stage.cleaned img { filter: contrast(1.08) saturate(.72) brightness(1.04); }

.region-layer {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 1;
  transition: opacity 140ms ease;
}

.region-layer.hidden { opacity: 0; }

.ocr-region {
  position: absolute;
  border: 2px solid rgba(255, 92, 47, .9);
  background: rgba(255, 92, 47, .035);
  transition: opacity 150ms ease, border-color 150ms ease, background 150ms ease;
}

.ocr-region.route-graphics {
  border-color: rgba(143,113,235,.95);
  background: rgba(143,113,235,.055);
}

.ocr-region.route-tables {
  border-color: rgba(76,181,123,.95);
  background: rgba(76,181,123,.055);
}

.ocr-region.muted { opacity: .075; }

.ocr-region.low {
  border-color: rgba(255, 184, 54, .95);
  background: rgba(255, 184, 54, .06);
}

.ocr-region::after {
  content: attr(data-score);
  position: absolute;
  top: -14px;
  right: -1px;
  padding: 1px 3px;
  color: white;
  background: rgba(17, 19, 16, .82);
  font-size: 7px;
  line-height: 11px;
}

.compare-reveal {
  width: 2px;
  height: 100%;
  position: absolute;
  left: 50%;
  top: 0;
  display: none;
  background: white;
  box-shadow: 0 0 0 1px rgba(0,0,0,.4);
}

.image-stage.compare .compare-reveal { display: block; }
.image-stage.compare::after {
  content: "ORIGINAL  ·  CLEANED";
  position: absolute;
  left: 50%;
  top: 10px;
  transform: translateX(-50%);
  padding: 4px 7px;
  border-radius: 4px;
  color: white;
  background: rgba(17,19,16,.82);
  font-size: 8px;
  letter-spacing: .08em;
}

.viewer-top-left, .zoom-bar, .page-status {
  position: absolute;
  z-index: 5;
  border: 1px solid rgba(255,255,255,.1);
  background: rgba(17, 19, 16, .82);
  box-shadow: 0 9px 30px rgba(0,0,0,.22);
  backdrop-filter: blur(12px);
}

.viewer-top-left {
  left: 14px;
  top: 14px;
  height: 36px;
  border-radius: 8px;
  padding: 3px;
  display: flex;
  align-items: center;
}

.viewer-top-left > span, .zoom-bar > span {
  width: 1px;
  height: 18px;
  margin: 0 3px;
  background: rgba(255,255,255,.12);
}

.tool {
  width: 29px;
  height: 29px;
  border-radius: 5px;
  color: #8f938b;
}
.tool:hover, .tool.active { color: white; background: rgba(255,255,255,.1); }
.tool svg { width: 15px; height: 15px; }

.page-status {
  top: 15px;
  left: 50%;
  transform: translateX(-50%);
  height: 32px;
  border-radius: 16px;
  padding: 0 11px;
  display: flex;
  align-items: center;
  gap: 8px;
  color: #b9bcb4;
  font-size: 8px;
  font-weight: 600;
}
.page-status i { width: 3px; height: 3px; border-radius: 50%; background: #676a64; }
.page-status button {
  width: 20px;
  height: 20px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #aeb2aa;
  font-size: 15px;
  line-height: 1;
}
.page-status button:hover:not(:disabled) {
  color: white;
  background: rgba(255,255,255,.1);
}
.page-status button:disabled {
  opacity: .28;
  cursor: default;
}

.node-config {
  display: grid;
  gap: 8px;
}

.config-control,
.config-check {
  display: grid;
  gap: 5px;
  color: #aeb2aa;
  font-size: 8px;
}

.config-control > small,
.config-check span > small {
  display: block;
  color: #777b73;
  font-size: 7px;
  font-weight: 400;
  line-height: 1.45;
}

.config-control input,
.config-control textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 8px 9px;
  color: #e7e9e4;
  background: #171916;
  font: inherit;
  resize: vertical;
}

.config-check {
  grid-template-columns: auto 1fr;
  align-items: center;
}

.source-node.file-drop-ready {
  outline: 2px solid var(--accent);
  outline-offset: 5px;
}

.zoom-bar {
  left: 50%;
  bottom: 16px;
  transform: translateX(-50%);
  height: 37px;
  border-radius: 9px;
  padding: 3px;
  display: flex;
  align-items: center;
}
.zoom-bar button {
  width: 30px;
  height: 29px;
  border-radius: 5px;
  color: #aeb1a9;
}
.zoom-bar button:hover { color: white; background: rgba(255,255,255,.1); }
.zoom-bar svg { width: 14px; height: 14px; }
.zoom-bar .zoom-value { width: 49px; font-size: 9px; font-weight: 600; }

.viewer-hint {
  position: absolute;
  left: 16px;
  bottom: 17px;
  z-index: 4;
  display: flex;
  align-items: center;
  gap: 6px;
  color: #777b74;
  font-size: 8px;
  transition: opacity 300ms ease;
}
.viewer-hint.hide { opacity: 0; }
.viewer-hint svg { width: 13px; height: 13px; }

.run-toast {
  min-width: 185px;
  height: 47px;
  position: absolute;
  right: 16px;
  bottom: 16px;
  z-index: 6;
  transform: translateY(20px);
  opacity: 0;
  pointer-events: none;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 9px;
  padding: 0 12px;
  display: flex;
  align-items: center;
  gap: 9px;
  color: white;
  background: rgba(17,19,16,.9);
  box-shadow: 0 14px 40px rgba(0,0,0,.28);
  transition: opacity 160ms ease, transform 160ms ease;
}

.details-panel {
  width: 268px;
  height: calc(100% - 28px);
  position: absolute;
  right: 14px;
  top: 14px;
  z-index: 50;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px;
  display: grid;
  grid-template-rows: 58px minmax(0,1fr) 45px;
  color: #e5e7e0;
  background: rgba(21,23,20,.92);
  box-shadow: 0 22px 65px rgba(0,0,0,.32);
  backdrop-filter: blur(18px);
  transition: transform 190ms ease, opacity 170ms ease;
}

.details-panel.closed {
  transform: translateX(calc(100% + 22px));
  opacity: 0;
  pointer-events: none;
}

.details-head {
  border-bottom: 1px solid rgba(255,255,255,.09);
  padding: 0 10px 0 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.details-head > div {
  min-width: 0;
  flex: 1;
}

.details-head .inspector-back {
  flex: none;
  margin-left: -5px;
  font-size: 20px;
}

.details-head .inspector-back[hidden] { display: none; }

.details-head h2 {
  margin: 3px 0 0;
  font-family: "Manrope", sans-serif;
  font-size: 13px;
}

.details-head button {
  width: 28px;
  height: 28px;
  border: 0;
  border-radius: 6px;
  color: #91958d;
  background: transparent;
  font-size: 18px;
  cursor: pointer;
}

.details-head button:hover { color: white; background: rgba(255,255,255,.08); }

.details-body {
  min-height: 0;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 14px;
}

.detail-field { margin-bottom: 16px; }

.fixed-model-input {
  padding: 9px 10px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 7px;
  background: rgba(255,255,255,.025);
}

.fixed-model-input strong {
  display: block;
  color: #c7cac3;
  font-size: 8px;
  font-weight: 500;
  line-height: 1.45;
}

.detail-field > label,
.detail-label-row label {
  margin-bottom: 7px;
  display: block;
  color: #9a9d96;
  font-size: 8px;
  font-weight: 600;
}

.detail-select, .detail-name {
  width: 100%;
  height: 34px;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 7px;
  padding: 0 9px;
  color: #e4e6df;
  background: rgba(255,255,255,.055);
  outline: 0;
  font-size: 9px;
}

.detail-select {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.detail-select svg { width: 12px; height: 12px; }

.detail-native-select {
  display: block;
  padding-right: 26px;
  appearance: none;
  cursor: pointer;
  color-scheme: dark;
  background-image:
    linear-gradient(45deg, transparent 50%, #858981 50%),
    linear-gradient(135deg, #858981 50%, transparent 50%);
  background-position:
    calc(100% - 13px) 14px,
    calc(100% - 9px) 14px;
  background-size: 4px 4px, 4px 4px;
  background-repeat: no-repeat;
}

.detail-engine {
  min-height: 48px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 7px;
  padding: 9px 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  background: rgba(255,255,255,.04);
}

.detail-engine span strong,
.detail-engine span small {
  display: block;
}

.detail-engine span strong { font-size: 8px; }
.detail-engine span small { margin-top: 3px; color: #7f837b; font-size: 7px; }

.engine-badge {
  flex: none;
  border-radius: 12px;
  padding: 4px 7px;
  color: #9be0ba;
  background: rgba(53,161,107,.14);
  font-size: 7px;
  font-weight: 800;
  letter-spacing: .03em;
}

.engine-badge.run-queued,
.engine-badge.run-stopped {
  color: #a1a59d;
  background: rgba(255,255,255,.07);
}

.engine-badge.run-running {
  color: #ffad90;
  background: rgba(242,104,58,.14);
}

.engine-badge.run-error {
  color: #ff9a8c;
  background: rgba(239,91,73,.14);
}

.route-detail-summary {
  min-height: 54px;
  margin-bottom: 18px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 8px;
  padding: 0 10px;
  display: grid;
  grid-template-columns: 7px minmax(0,1fr);
  align-items: center;
  gap: 9px;
  background: rgba(255,255,255,.04);
}

.route-detail-summary span strong,
.route-detail-summary span small { display: block; }
.route-detail-summary span strong { font-size: 8px; }
.route-detail-summary span small { margin-top: 3px; color: #858981; font-size: 7px; }

.route-labels {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.route-labels button {
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 12px;
  padding: 4px 7px;
  color: #888c84;
  background: transparent;
  font-size: 7px;
  cursor: pointer;
}

.route-labels button.active {
  color: #e5e7e0;
  background: rgba(255,255,255,.075);
}

.detail-unit {
  height: 34px;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 7px;
  display: grid;
  grid-template-columns: 1fr 28px;
  align-items: center;
  background: rgba(255,255,255,.055);
}

.detail-unit input {
  min-width: 0;
  border: 0;
  padding: 0 9px;
  color: #e4e6df;
  background: transparent;
  outline: 0;
  font-size: 9px;
}

.detail-unit span { color: #747870; font-size: 7px; }

.route-connections { margin-top: 16px; }

.route-connection-row {
  min-width: 0;
  margin-bottom: 6px;
  display: grid;
  grid-template-columns: minmax(0,1fr) 30px;
  gap: 5px;
}

.route-connection-row > [data-select-connected] {
  width: 100%;
  min-height: 42px;
  border: 1px solid rgba(255,255,255,.085);
  border-radius: 7px;
  padding: 5px 7px;
  display: grid;
  grid-template-columns: 26px minmax(0,1fr) 12px;
  align-items: center;
  gap: 7px;
  color: #daddd5;
  text-align: left;
  background: rgba(255,255,255,.035);
  cursor: pointer;
}

.route-connection-row > [data-select-connected]:hover {
  border-color: rgba(255,255,255,.16);
  background: rgba(255,255,255,.07);
}

.route-connection-row > [data-select-connected] > b {
  width: 25px;
  height: 25px;
  border-radius: 6px;
  display: grid;
  place-items: center;
  color: #beb0e9;
  background: rgba(143,113,235,.13);
  font-size: 7px;
}
.route-connection-row > [data-select-connected] span strong,
.route-connection-row > [data-select-connected] span small { display: block; }
.route-connection-row > [data-select-connected] span strong { font-size: 8px; }
.route-connection-row > [data-select-connected] span small { margin-top: 2px; color: #777b73; font-size: 7px; }
.route-connection-row > [data-select-connected] > svg { width: 11px; height: 11px; color: #777b73; }

.route-connection-remove {
  min-width: 0;
  border: 1px solid rgba(255,255,255,.085);
  border-radius: 7px;
  padding: 0;
  display: grid;
  place-items: center;
  color: #747870;
  background: rgba(255,255,255,.035);
  cursor: pointer;
}

.route-connection-remove:hover {
  border-color: rgba(242,104,58,.32);
  color: #ff8064;
  background: rgba(242,104,58,.1);
}

.route-connection-remove svg { width: 12px; height: 12px; }

.route-empty {
  height: 18px;
  display: flex;
  align-items: center;
  color: #686c64;
  font-size: 8px;
}

.inspector-outputs {
  margin-top: 16px;
  padding-top: 14px;
  border-top: 1px solid rgba(255,255,255,.08);
}

.inspector-outputs > button {
  width: 100%;
  min-height: 40px;
  margin-bottom: 5px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 7px;
  padding: 5px 7px;
  display: grid;
  grid-template-columns: 7px minmax(0,1fr) auto 11px;
  align-items: center;
  gap: 8px;
  color: #daddd5;
  text-align: left;
  background: rgba(255,255,255,.035);
  cursor: pointer;
}

.inspector-outputs > button:hover {
  border-color: rgba(255,255,255,.17);
  background: rgba(255,255,255,.07);
}

.inspector-outputs > button > i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #888c84;
}

.inspector-outputs > button.route-orange > i { background: #f2683a; }
.inspector-outputs > button.route-violet > i { background: #8f71eb; }
.inspector-outputs > button.route-green > i { background: #4cb57b; }
.inspector-outputs > button.route-cyan > i { background: #43b4ca; }
.inspector-outputs > button span strong,
.inspector-outputs > button span small { display: block; }
.inspector-outputs > button span strong { font-size: 8px; }
.inspector-outputs > button span small { margin-top: 2px; color: #747870; font-size: 7px; }
.inspector-outputs > button > b { color: #989c94; font-size: 8px; }
.inspector-outputs > button > svg { width: 10px; height: 10px; color: #73776f; }

.detail-label-row {
  display: flex;
  justify-content: space-between;
}

.detail-label-row output {
  color: #e7e8e2;
  font-size: 8px;
  font-weight: 700;
}

.detail-range {
  width: 100%;
  height: 3px;
  accent-color: var(--accent);
}

.detail-segments {
  height: 34px;
  border-radius: 7px;
  padding: 3px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 3px;
  background: rgba(255,255,255,.07);
}

.detail-segments button {
  border: 0;
  border-radius: 5px;
  color: #858981;
  background: transparent;
  font-size: 8px;
  font-weight: 700;
  cursor: pointer;
}

.detail-segments button.active { color: #171916; background: #e8e9e3; }

.detail-toggle {
  min-height: 42px;
  border-top: 1px solid rgba(255,255,255,.09);
  border-bottom: 1px solid rgba(255,255,255,.09);
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.detail-toggle span strong, .detail-toggle span small { display: block; }
.detail-toggle span strong { font-size: 8px; }
.detail-toggle span small { margin-top: 2px; color: #81857d; font-size: 7px; }

.switch {
  width: 28px;
  height: 16px;
  border: 0;
  border-radius: 9px;
  padding: 2px;
  background: var(--accent);
  cursor: pointer;
}

.switch i {
  width: 12px;
  height: 12px;
  margin-left: 12px;
  display: block;
  border-radius: 50%;
  background: white;
}

.detail-memory {
  margin-top: 14px;
  border-radius: 7px;
  padding: 10px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: rgba(255,255,255,.055);
}

.detail-memory span { color: #92958e; font-size: 8px; }
.detail-memory strong { font-size: 10px; }

.details-footer {
  border-top: 1px solid rgba(255,255,255,.09);
  padding: 7px 10px;
}

.details-footer button {
  height: 30px;
  border: 0;
  display: flex;
  align-items: center;
  gap: 6px;
  color: #d77c68;
  background: transparent;
  font-size: 8px;
  cursor: pointer;
}

.details-footer svg { width: 13px; height: 13px; }

.right-reopen {
  right: 14px;
  transform: translateX(52px);
  opacity: 0;
  pointer-events: none;
  transition: transform 180ms ease, opacity 180ms ease;
}

.right-reopen.show {
  transform: translateX(0);
  opacity: 1;
  pointer-events: auto;
}
.run-toast.show { opacity: 1; transform: translateY(0); }
.run-toast > span:last-child strong, .run-toast > span:last-child small { display: block; }
.run-toast strong { font-size: 9px; }
.run-toast small { margin-top: 2px; color: #8f938b; font-size: 7px; }

.run-spinner {
  width: 17px;
  height: 17px;
  border: 2px solid #484b45;
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin .7s linear infinite;
}
.run-toast.done .run-spinner {
  border: 0;
  display: grid;
  place-items: center;
  color: white;
  background: var(--green);
}
.run-toast.done .run-spinner::after { content: "✓"; font-size: 10px; }

@keyframes spin { to { transform: rotate(360deg); } }

/* Floating side panels share one visual system around the document. */
.workspace,
.workspace.pipeline-hidden {
  position: relative;
  grid-template-columns: 48px minmax(0, 1fr);
}

.document-viewport {
  grid-column: 2;
}

.pipeline-panel {
  width: 278px;
  height: calc(100% - 28px);
  min-height: 0;
  position: absolute;
  left: 62px;
  top: 14px;
  z-index: 13;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 10px;
  overflow: hidden;
  color: #e5e7e0;
  background: rgba(21,23,20,.92);
  box-shadow: 0 22px 65px rgba(0,0,0,.32);
  backdrop-filter: blur(18px);
  transform: translateX(0);
  transition: transform 190ms cubic-bezier(.2,.8,.2,1), opacity 170ms ease;
}

.workspace.pipeline-hidden .pipeline-panel {
  transform: translateX(calc(-100% - 22px));
  opacity: 0;
  pointer-events: none;
}

.pipeline-panel .overline,
.pipeline-panel .flow-caption {
  color: #7f837b;
}

.pipeline-panel .collapse-button {
  color: #8f938b;
}

.pipeline-panel .collapse-button:hover {
  color: white;
  background: rgba(255,255,255,.08);
}

.pipeline-panel .add-button {
  border-color: rgba(255,255,255,.12);
  color: #e5e7e0;
  background: rgba(255,255,255,.06);
}

.pipeline-panel .add-button:hover {
  border-color: rgba(255,255,255,.22);
  background: rgba(255,255,255,.1);
}

.pipeline-panel .source-row {
  border-color: rgba(255,255,255,.11);
  color: #e5e7e0;
  background: rgba(255,255,255,.055);
}

.pipeline-panel .source-row:hover {
  border-color: rgba(255,255,255,.22);
}

.pipeline-panel .source-row small,
.pipeline-panel .source-row > svg {
  color: #858980;
}

.pipeline-panel .step-card::after {
  background: #3d403a;
}

.pipeline-panel .step-card:hover .step-main {
  background: rgba(255,255,255,.055);
}

.pipeline-panel .step-card.selected {
  border-color: rgba(255,255,255,.14);
  background: rgba(255,255,255,.075);
  box-shadow: 0 10px 28px rgba(0,0,0,.2);
}

.pipeline-panel .step-card.selected .step-main {
  background: transparent;
}

.pipeline-panel .drag-handle {
  color: #5f635c;
}

.pipeline-panel .step-number {
  color: #a6aaa2;
  background: rgba(255,255,255,.07);
}

.pipeline-panel .step-card.selected .step-number {
  color: #151714;
  background: #e8e9e3;
}

.pipeline-panel .step-title small {
  color: #767a72;
}

.pipeline-panel .step-actions button {
  color: #777b73;
}

.pipeline-panel .step-actions button:hover {
  color: white;
  background: rgba(255,255,255,.08);
}

.pipeline-panel .step-actions .step-delete:hover {
  color: #ff8064;
  background: rgba(242,104,58,.1);
}

.pipeline-panel .pipeline-footer {
  border-color: rgba(255,255,255,.09);
}

.pipeline-panel .gpu-meter {
  background: rgba(255,255,255,.055);
}

.pipeline-panel .gpu-meter span small {
  color: #747870;
}

.pipeline-panel .gpu-meter b {
  color: #9a9e96;
}

.pipeline-panel .step-picker,
.pipeline-panel .section-view {
  color: #e5e7e0;
  background: rgba(21,23,20,.985);
}

.pipeline-panel .picker-head button,
.pipeline-panel .section-view-head button {
  color: #8b8f87;
}

.pipeline-panel .picker-head button:hover,
.pipeline-panel .section-view-head button:hover {
  color: white;
  background: rgba(255,255,255,.08);
}

.pipeline-panel .picker-search {
  border-color: rgba(255,255,255,.11);
  background: rgba(255,255,255,.055);
}

.pipeline-panel .picker-search input {
  color: #e5e7e0;
  background: transparent;
}

.pipeline-panel .picker-item,
.pipeline-panel .section-action {
  border-color: rgba(255,255,255,.11);
  color: #e5e7e0;
  background: rgba(255,255,255,.055);
}

.pipeline-panel .picker-item-main {
  color: #e5e7e0;
}

.pipeline-panel .picker-item-add {
  border-color: rgba(166,142,235,.3);
  color: #b59ce9;
  background: rgba(142,112,220,.14);
}

.pipeline-panel .picker-node-details {
  border-color: rgba(255,255,255,.08);
}

.pipeline-panel .picker-node-details > summary,
.pipeline-panel .picker-purpose,
.pipeline-panel .picker-compatible-names {
  color: #aeb2a9;
}

.pipeline-panel .picker-node-details[open] > summary {
  background: rgba(255,255,255,.035);
}

.pipeline-panel .picker-runtime span,
.pipeline-panel .picker-port-contract code {
  color: #b8bcb3;
  background: rgba(255,255,255,.07);
}

.pipeline-panel .picker-port-contract em {
  color: #afc9aa;
  background: rgba(105,145,97,.16);
}

.pipeline-panel .picker-port {
  border-color: rgba(255,255,255,.09);
}

.pipeline-panel .picker-item:hover,
.pipeline-panel .section-action:hover {
  border-color: rgba(255,255,255,.22);
  background: rgba(255,255,255,.09);
}

.pipeline-panel .section-action-secondary {
  color: #afb3aa;
  background: transparent;
}

.pipeline-panel .section-actions {
  margin-bottom: 9px;
  display: flex;
  justify-content: flex-end;
  gap: 5px;
}

.pipeline-panel .section-actions .section-action {
  width: auto;
  height: 27px;
  margin: 0;
  padding: 0 9px;
  border-radius: 6px;
  font-size: 7px;
  white-space: nowrap;
}

.pipeline-panel .section-row {
  border-color: rgba(255,255,255,.08);
}

.pipeline-panel .file-row {
  min-height: 44px;
  grid-template-columns: 29px minmax(0,1fr) auto;
  gap: 7px;
}

.pipeline-panel .file-row .section-row-icon {
  width: 27px;
  height: 27px;
  border-radius: 6px;
  font-size: 7px;
}

.pipeline-panel button.section-row {
  width: 100%;
  padding: 0;
  border-width: 0 0 1px;
  color: #e5e7e0;
  background: transparent;
  text-align: left;
  cursor: pointer;
}

.pipeline-panel button.section-row:disabled {
  cursor: default;
}

.pipeline-panel button.section-row.active,
.pipeline-panel button.section-row:not(:disabled):hover {
  background: rgba(255,255,255,.055);
}

.project-storage-summary {
  min-height: 38px;
  margin-bottom: 7px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 7px;
  padding: 6px 7px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  background: rgba(255,255,255,.025);
}

.project-storage-summary span {
  min-width: 0;
}

.project-storage-summary strong,
.project-storage-summary small {
  display: block;
}

.project-storage-summary strong {
  color: #d7dbd2;
  font-size: 8px;
}

.project-storage-summary small {
  margin-top: 2px;
  color: #747970;
  font-size: 6px;
}

.project-storage-summary b,
.project-storage-summary button {
  flex: none;
  border: 1px solid rgba(92,171,114,.2);
  border-radius: 5px;
  padding: 4px 6px;
  color: #8fb89a;
  background: rgba(76,181,123,.08);
  font-size: 6px;
}

.project-storage-summary button {
  cursor: pointer;
}

.project-explorer {
  min-width: 0;
}

.project-folder-row,
.project-asset-row,
.project-page-row {
  width: 100%;
  min-width: 0;
  position: relative;
  padding-left: calc(3px + var(--tree-depth, 0) * 13px);
}

.project-folder-row {
  height: 28px;
  border: 0;
  border-radius: 5px;
  display: grid;
  grid-template-columns: 12px 14px minmax(0, 1fr) auto;
  align-items: center;
  gap: 4px;
  color: #aeb2a9;
  text-align: left;
  background: transparent;
  cursor: pointer;
}

.project-folder-row:hover,
.project-asset-row:hover,
.project-page-row:hover {
  background: rgba(255,255,255,.045);
}

.project-folder-row > span {
  font-size: 12px;
  transform: rotate(0);
  transition: transform 120ms ease;
}

.project-folder.expanded > .project-folder-row > span {
  transform: rotate(90deg);
}

.project-folder-row svg {
  width: 12px;
  height: 12px;
  color: #b68a43;
}

.project-folder-row strong {
  min-width: 0;
  overflow: hidden;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-folder-row small {
  padding-right: 5px;
  color: #6f746c;
  font-size: 6px;
}

.project-asset-row {
  min-height: 42px;
  border-radius: 6px;
  display: grid;
  grid-template-columns: 13px minmax(0, 1fr) 14px 22px;
  align-items: center;
  gap: 3px;
  touch-action: none;
}

.project-asset-row.active,
.project-page-row.active {
  background: rgba(242,104,58,.08);
}

.project-asset-row.dragging {
  opacity: .55;
}

.project-tree-toggle,
.project-asset-delete,
.project-asset-open,
.project-page-row > button {
  border: 0;
  color: inherit;
  background: transparent;
}

.project-tree-toggle {
  height: 24px;
  padding: 0;
  color: #777d74;
  font-size: 13px;
  cursor: pointer;
  transform: rotate(0);
  transition: transform 120ms ease;
}

.project-asset-group.expanded > .project-asset-row .project-tree-toggle {
  transform: rotate(90deg);
}

.project-tree-toggle.leaf {
  color: #555a53;
  cursor: default;
}

.project-asset-open,
.project-page-row > button {
  min-width: 0;
  padding: 3px 2px;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  align-items: center;
  gap: 7px;
  text-align: left;
  cursor: pointer;
}

.project-asset-open span:last-child,
.project-page-row > button span:last-child {
  min-width: 0;
}

.project-asset-open strong,
.project-asset-open small,
.project-page-row strong,
.project-page-row small {
  display: block;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-asset-open strong,
.project-page-row strong {
  color: #cdd1c8;
  font-size: 8px;
}

.project-asset-open small,
.project-page-row small {
  margin-top: 2px;
  color: #71766e;
  font-size: 6px;
}

.project-asset-row .section-row-icon,
.project-page-row .section-row-icon {
  width: 34px;
  height: 30px;
  border-radius: 5px;
  overflow: hidden;
  display: grid;
  place-items: center;
  color: #777d74;
  background: rgba(255,255,255,.055);
  font-size: 6px;
  font-weight: 800;
}

.project-asset-row .section-row-icon img,
.project-page-row .section-row-icon img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.project-reference-count {
  color: #8f71eb;
  font-size: 6px;
  text-align: center;
}

.project-asset-delete {
  width: 22px;
  height: 24px;
  border-radius: 5px;
  display: grid;
  place-items: center;
  color: #666b63;
  cursor: pointer;
  opacity: 0;
}

.project-asset-row:hover .project-asset-delete,
.project-asset-delete:focus-visible {
  opacity: 1;
}

.project-asset-delete:hover {
  color: #ec8172;
  background: rgba(239,91,73,.1);
}

.project-asset-delete svg {
  width: 11px;
  height: 11px;
}

.project-page-row {
  min-height: 35px;
  border-radius: 5px;
  display: grid;
  grid-template-columns: 13px minmax(0, 1fr);
  align-items: center;
  touch-action: none;
}

.project-page-branch {
  color: #535850;
  font-size: 8px;
}

.project-page-row > button {
  grid-template-columns: 29px minmax(0, 1fr);
}

.project-page-row .section-row-icon {
  width: 29px;
  height: 25px;
}

.project-drag-hint {
  margin-top: 9px;
  border-top: 1px solid rgba(255,255,255,.065);
  padding: 9px 5px 3px;
  display: flex;
  align-items: flex-start;
  gap: 6px;
  color: #747970;
  font-size: 6px;
  line-height: 1.45;
}

.project-drag-hint svg {
  width: 12px;
  height: 12px;
  flex: none;
}

.project-asset-drag-ghost {
  max-width: 210px;
  position: fixed;
  z-index: 1000;
  border: 1px solid rgba(143,113,235,.46);
  border-radius: 7px;
  padding: 7px 9px;
  display: flex;
  align-items: center;
  gap: 7px;
  color: #e2dafa;
  background: rgba(31,25,43,.94);
  box-shadow: 0 12px 30px rgba(0,0,0,.38);
  pointer-events: none;
}

.project-asset-drag-ghost svg {
  width: 14px;
  height: 14px;
  flex: none;
}

.project-asset-drag-ghost span,
.project-asset-drag-ghost strong,
.project-asset-drag-ghost small {
  min-width: 0;
  display: block;
}

.project-asset-drag-ghost strong {
  overflow: hidden;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.project-asset-drag-ghost small {
  margin-top: 2px;
  color: #9a8dbb;
  font-size: 6px;
}

.graph-viewport.project-asset-drop-ready {
  box-shadow: inset 0 0 0 2px rgba(143,113,235,.56);
}

.graph-viewport.project-asset-drop-ready::after {
  content: "DROP TO CREATE INPUT";
  position: absolute;
  left: 50%;
  top: 14px;
  z-index: 30;
  border: 1px solid rgba(143,113,235,.38);
  border-radius: 6px;
  padding: 6px 9px;
  color: #c4b5ee;
  background: rgba(45,35,67,.92);
  font-size: 7px;
  font-weight: 800;
  letter-spacing: .06em;
  transform: translateX(-50%);
  pointer-events: none;
}

.section-empty {
  padding: 28px 10px;
  color: #777b73;
  font-size: 8px;
  text-align: center;
}

.model-manager-note,
.model-unavailable {
  margin: 5px 0 10px;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 7px;
  padding: 9px;
  color: #8c9188;
  background: rgba(255,255,255,.035);
  font-size: 7px;
  line-height: 1.5;
}

.model-cache-row {
  margin-bottom: 7px;
  border: 1px solid rgba(255,255,255,.08);
  border-radius: 7px;
  padding: 7px;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px;
  background: rgba(255,255,255,.025);
}

.model-cache-row > span strong,
.model-cache-row > span small,
.model-unavailable strong,
.model-unavailable span {
  display: block;
}

.model-cache-row > span strong,
.model-unavailable strong {
  color: #d7dbd2;
  font-size: 8px;
}

.model-cache-row > span small,
.model-unavailable span {
  margin-top: 3px;
  color: #747970;
  font-size: 6px;
  line-height: 1.4;
}

.model-cache-row label {
  color: #777c73;
  font-size: 6px;
}

.model-cache-controls {
  display: grid;
  grid-template-columns: minmax(78px, auto) auto;
  justify-content: end;
  align-items: end;
  gap: 5px;
  min-width: 0;
}

.model-cache-row select,
.model-fixed-precision,
.model-cache-row button {
  width: 100%;
  height: 24px;
  margin-top: 3px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 5px;
  color: #d8dcd3;
  background: #292c27;
  font-size: 7px;
}

.model-fixed-precision {
  display: flex;
  align-items: center;
  min-width: 0;
  padding: 0 6px;
  overflow: hidden;
  box-sizing: border-box;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.model-cache-row button {
  width: auto;
  min-width: 76px;
  margin: 0;
  padding: 0 8px;
  cursor: pointer;
  white-space: nowrap;
}

.model-cache-row button:disabled {
  color: #6f8976;
  cursor: default;
}

.model-cache-row progress {
  width: 100%;
  height: 4px;
  grid-column: 1 / -1;
  accent-color: #ee6b3b;
}

.model-cache-status {
  grid-column: 1 / -1;
  color: #747970;
  font-size: 6px;
}

.document-vlm-model-row {
  margin-bottom: 6px;
  border: 1px solid rgba(123,102,196,.2);
  border-radius: 7px;
  padding: 8px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 4px 8px;
  background: rgba(123,102,196,.055);
}

.document-vlm-model-row b {
  color: #d8d4ea;
  font-size: 8px;
}

.document-vlm-model-row span {
  grid-column: 1 / -1;
  color: #77758a;
  font-size: 6px;
  line-height: 1.4;
}

.document-vlm-model-row small {
  grid-column: 2;
  grid-row: 1;
  color: #9d8ee1;
  font-size: 5px;
  letter-spacing: .05em;
}

.pipeline-panel .section-row small {
  color: #777b73;
}

@media (max-width: 850px) {
  .workspace,
  .workspace.pipeline-hidden { grid-template-columns: 44px minmax(0, 1fr); }
  .activity-rail { padding-left: 4px; padding-right: 4px; }
  .rail-button { width: 34px; }
  .pipeline-panel { width: 238px; left: 56px; }
  .pipeline-panel { grid-template-rows: 48px 50px 22px minmax(0,1fr) 48px; }
  .viewer-hint, .device-status span { display: none; }
}

@media (max-width: 1100px) {
  .pipeline-panel {
    width: 252px;
  }

  .details-panel {
    width: 246px;
  }

  .page-status {
    top: 12px;
  }
}

@media (max-width: 760px) {
  .topbar {
    height: 42px;
    padding: 0 8px;
  }

  .workspace {
    height: calc(100% - 42px);
  }

  .brand > strong {
    font-size: 10px;
  }

  .crumb,
  .file-name,
  .device-status span {
    display: none;
  }

  .device-status {
    width: 27px;
    padding: 0;
    justify-content: center;
  }

  .pipeline-panel {
    width: min(278px, calc(100vw - 68px));
    height: calc(100% - 20px);
    left: 54px;
    top: 10px;
  }

  .details-panel {
    width: min(268px, calc(100% - 20px));
    height: calc(100% - 20px);
    right: 10px;
    top: 10px;
  }

  .viewer-top-left {
    left: 10px;
    top: 10px;
  }

  .page-status {
    display: none;
  }

  .zoom-bar {
    bottom: 10px;
  }

  .run-toast {
    right: 10px;
    bottom: 56px;
  }
}

@media (max-width: 620px) {
  .workspace,
  .workspace.pipeline-hidden { grid-template-columns: 44px minmax(0, 1fr); }
  .pipeline-panel {
    width: calc(100vw - 44px);
    height: 100%;
    position: absolute;
    left: 44px;
    top: 0;
    border-width: 0 1px 0 0;
    border-radius: 0;
  }

  .document-viewport { grid-column: 2; }

  .details-panel {
    width: calc(100% - 12px);
    height: calc(100% - 12px);
    right: 6px;
    top: 6px;
  }

  .viewer-top-left {
    transform: scale(.92);
    transform-origin: top left;
  }

  .zoom-bar {
    transform: translateX(-50%) scale(.92);
  }

  .run-button {
    width: 34px;
    padding: 0;
    justify-content: center;
  }

  .run-button span {
    display: none;
  }

  .header-actions .icon-button {
    display: none;
  }
}

/* Native node editor */
.pipeline-panel {
  min-width: 252px;
  max-width: min(680px, calc(100vw - 76px));
  grid-template-rows: 48px 28px minmax(0, 1fr) 52px;
}

.panel-resizer {
  width: 9px;
  height: 100%;
  position: absolute;
  right: 0;
  top: 0;
  z-index: 40;
  cursor: ew-resize;
  touch-action: none;
}

.panel-resizer::after {
  content: "";
  width: 2px;
  height: 38px;
  position: absolute;
  right: 2px;
  top: 50%;
  border-radius: 3px;
  background: rgba(255,255,255,.13);
  transform: translateY(-50%);
  transition: height 140ms ease, background 140ms ease;
}

.panel-resizer:hover::after,
.panel-resizer:focus-visible::after,
.pipeline-panel.resizing .panel-resizer::after {
  height: 58px;
  background: rgba(242,104,58,.72);
}

.panel-resizer:focus-visible {
  outline: 0;
}

.flow-caption {
  padding: 0 11px 0 15px;
  align-items: center;
}

.flow-caption > span:first-child {
  white-space: nowrap;
}

.flow-caption b {
  color: #a7aaa3;
  font-size: inherit;
}

.graph-controls {
  display: flex;
  align-items: center;
  gap: 2px;
}

.graph-controls button {
  width: 23px;
  height: 22px;
  border: 0;
  border-radius: 5px;
  padding: 0;
  display: grid;
  place-items: center;
  color: #747870;
  background: transparent;
  cursor: pointer;
}

.graph-controls button:hover {
  color: #eceee7;
  background: rgba(255,255,255,.08);
}

.graph-controls button:disabled {
  opacity: .28;
  cursor: default;
}

.graph-controls button:disabled:hover {
  color: #747870;
  background: transparent;
}

.graph-controls button svg {
  width: 11px;
  height: 11px;
}

.graph-controls .graph-disconnect {
  color: #ef8268;
  background: rgba(242,104,58,.1);
}

.graph-viewport {
  position: relative;
  overflow: hidden;
  padding: 0;
  overscroll-behavior: contain;
  touch-action: none;
  cursor: grab;
  background-color: rgba(7,9,7,.28);
  background-image:
    radial-gradient(circle, rgba(255,255,255,.10) .65px, transparent .8px);
  background-position: 0 0;
  background-size: 15px 15px;
}

.graph-viewport.panning {
  cursor: grabbing;
}

.graph-surface {
  position: absolute;
  left: 0;
  top: 0;
  transform-origin: 0 0;
  will-change: transform;
}

.graph-surface .wire-layer {
  width: 100%;
  height: 100%;
  position: absolute;
  inset: 0;
  z-index: 1;
  overflow: visible;
  pointer-events: none;
}

.graph-surface .connection-wire {
  stroke-width: 2;
  opacity: .56;
}

.graph-surface .connection-wire-hit {
  stroke-width: 15;
}

.graph-surface .connection-wire-hit:hover + .connection-wire,
.graph-surface .connection-wire.active {
  stroke-width: 2.8;
  opacity: 1;
  filter: drop-shadow(0 0 4px color-mix(in srgb, var(--wire) 55%, transparent));
}

.graph-surface .wire-preview {
  opacity: 0;
  stroke-dasharray: 4 4;
  pointer-events: none;
}

.graph-surface .wire-preview.show {
  opacity: .9;
}

.graph-node.step-card {
  min-height: 0;
  position: absolute;
  z-index: 2;
  margin: 0;
  border-color: rgba(255,255,255,.13);
  border-radius: 9px;
  color: #e2e4dd;
  background: rgba(27,30,26,.96);
  box-shadow: 0 9px 25px rgba(0,0,0,.22);
  overflow: visible;
  cursor: grab;
  user-select: none;
  transition: border-color 120ms ease, box-shadow 120ms ease, opacity 120ms ease;
}

.graph-node.step-card:hover {
  border-color: rgba(255,255,255,.23);
}

.graph-node.step-card.selected {
  border-color: rgba(242,104,58,.72);
  background: rgba(31,34,30,.98);
  box-shadow: 0 0 0 2px rgba(242,104,58,.11), 0 12px 30px rgba(0,0,0,.28);
}

.graph-node.step-card.running {
  border-color: rgba(242,104,58,.9);
  box-shadow: 0 0 0 3px rgba(242,104,58,.12), 0 12px 30px rgba(0,0,0,.28);
}

.graph-node.step-card.error {
  border-color: rgba(239, 91, 73, .82);
  box-shadow: 0 0 0 2px rgba(239, 91, 73, .1), 0 12px 30px rgba(0,0,0,.28);
}

.graph-node.step-card.disconnected {
  border-style: dashed;
  border-color: rgba(217,162,68,.35);
  opacity: .66;
}

.graph-node.step-card.bypassed {
  border-style: dashed;
  opacity: .58;
  filter: saturate(.45);
}

.graph-node.step-card.bypassed .step-title strong {
  text-decoration: line-through;
}

.graph-node.step-card.dragging {
  z-index: 8;
  opacity: .92;
  cursor: grabbing;
  box-shadow: 0 18px 44px rgba(0,0,0,.42);
}

.graph-node.branch-child {
  width: auto;
  margin-left: 0;
  background: rgba(27,30,26,.96);
}

.graph-node .step-main {
  height: 44px;
  border-top: 1px solid rgba(255,255,255,.075);
  border-radius: 0;
  padding: 0 7px;
  grid-template-columns: 28px minmax(0,1fr) auto auto auto;
  gap: 6px;
  cursor: grab;
}

.graph-node .step-main:active {
  cursor: grabbing;
}

.pipeline-panel .graph-node .step-main:hover,
.pipeline-panel .graph-node.selected .step-main {
  background: rgba(255,255,255,.025);
}

.graph-node .step-number {
  width: 26px;
  height: 26px;
  border-radius: 6px;
  font-size: 7px;
}

.graph-node .step-title strong {
  font-size: 9px;
}

.graph-node .step-title small {
  max-width: 116px;
  font-size: 7px;
}

.graph-node .branch-tag {
  max-width: 42px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.graph-node:hover .branch-tag,
.graph-node.selected .branch-tag {
  display: block;
}

.graph-node .node-state {
  padding: 2px 4px;
}

.graph-node.has-run-state .branch-tag {
  display: none;
}

.graph-node.has-run-state .step-title small {
  color: #9a9f96;
}

.graph-node.running .step-title small {
  color: #c9a08f;
}

.graph-node.error .step-title small {
  color: #d49289;
}

.graph-node .step-actions,
.graph-node.branch-child .step-actions {
  display: flex;
  opacity: 0;
}

.graph-node:hover .step-actions,
.graph-node.selected .step-actions {
  opacity: 1;
}

.graph-node .step-actions button {
  width: 20px;
  height: 22px;
}

.graph-node .node-inputs {
  border: 0;
  padding: 6px 7px 7px;
  background: rgba(255,255,255,.012);
}

.graph-node .inputs-head {
  height: 17px;
  padding: 0 2px;
  align-items: flex-start;
}

.graph-node .inputs-head small {
  color: #62665f;
  font-size: 6px;
  font-weight: 600;
  letter-spacing: 0;
}

.graph-node .node-input-port {
  --port-color: #b68a43;
  min-height: 38px;
  border: 1px solid color-mix(in srgb, var(--port-color) 18%, transparent);
  border-radius: 6px;
  padding: 4px 7px 4px 11px;
  grid-template-columns: minmax(0,1fr) auto;
  gap: 7px;
  background: color-mix(in srgb, var(--port-color) 4%, transparent);
}

.graph-node .node-input-port + .node-input-port {
  margin-top: 3px;
}

.graph-node .node-input-port.connected {
  border: 1px solid color-mix(in srgb, var(--port-color) 24%, rgba(255,255,255,.09));
  background: color-mix(in srgb, var(--port-color) 5%, transparent);
}

.graph-node .graph-input-socket {
  width: 24px;
  height: 15px;
  position: absolute;
  left: -16px;
  top: 7px;
  z-index: 4;
  border: 1px solid var(--port-color);
  border-radius: 7px;
  display: grid;
  place-items: center;
  color: color-mix(in srgb, var(--port-color) 72%, white);
  background: #1c1f1b;
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--port-color) 11%, transparent);
  font: 800 6px/1 "Manrope", sans-serif;
  font-style: normal;
  letter-spacing: .05em;
  cursor: crosshair;
}

.graph-node .node-input-port.connected .graph-input-socket {
  border-color: var(--port-color);
  color: #f5f6f2;
  background: color-mix(in srgb, var(--port-color) 44%, #1c1f1b);
}

.graph-node .node-input-port.route-orange { --port-color: #f2683a; }
.graph-node .node-input-port.route-violet { --port-color: #8f71eb; }
.graph-node .node-input-port.route-green { --port-color: #4cb57b; }
.graph-node .node-input-port.route-cyan { --port-color: #43b4ca; }

.graph-node .graph-input-socket:hover {
  color: white;
  background: color-mix(in srgb, var(--port-color) 58%, #1c1f1b);
}

.graph-node .node-input-port span {
  min-width: 0;
  display: block;
  overflow: hidden;
  white-space: nowrap;
}

.graph-node .node-input-port span small,
.graph-node .node-input-port span strong {
  display: block;
}

.graph-node .node-input-port span small {
  min-width: 0;
  margin: 2px 0 0;
  color: #747870;
  font-size: 6px;
  font-weight: 600;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.graph-node .node-input-port span strong {
  max-width: none;
  color: #c9ccc4;
  font-size: 7px;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.graph-node .node-input-port > b {
  max-width: 58px;
  grid-column: auto;
  margin: 0;
  color: #747870;
  font-size: 6px;
  text-align: right;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.graph-node .node-outputs {
  border-top: 1px solid rgba(255,255,255,.075);
  padding: 6px 7px 7px;
}

.graph-node .outputs-head {
  height: 17px;
  padding: 0 2px;
  align-items: flex-start;
}

.graph-node .outputs-head small {
  color: #62665f;
  font-size: 6px;
  font-weight: 600;
  letter-spacing: 0;
}

.graph-node .output-chips,
.graph-node .output-chips.count-1,
.graph-node .output-chips.count-2,
.graph-node .output-chips.count-4 {
  display: grid;
  grid-template-columns: minmax(0,1fr);
  gap: 3px;
}

.graph-node .output-chip {
  --port-color: #8c9088;
  min-height: 28px;
  border-color: rgba(255,255,255,.075);
  border-radius: 6px;
  grid-template-columns: minmax(0,1fr) 25px;
  overflow: visible;
}

.graph-node .output-chip.inspection-output {
  grid-template-columns: minmax(0,1fr) 34px;
}

.output-inspect-badge {
  align-self: stretch;
  border-left: 1px solid rgba(255,255,255,.07);
  display: grid;
  place-items: center;
  color: #73776f;
  font-size: 5px;
  font-weight: 900;
  letter-spacing: .08em;
}

.graph-node .output-chip.active {
  border-color: rgba(255,255,255,.26);
  background: rgba(255,255,255,.08);
}

.graph-node .output-select {
  padding: 0 5px;
  grid-template-columns: 6px minmax(0,1fr);
  gap: 6px;
}

.graph-node .output-chip strong {
  display: inline;
  font-size: 7px;
}

.graph-node .output-chip small {
  margin-left: 5px;
  display: inline;
  font-size: 6px;
}

.graph-node .output-add {
  width: 25px;
  position: relative;
  border-radius: 0 5px 5px 0;
  overflow: visible;
  cursor: crosshair;
}

.graph-node .output-chip.route-orange { --port-color: #f2683a; }
.graph-node .output-chip.route-violet { --port-color: #8f71eb; }
.graph-node .output-chip.route-green { --port-color: #4cb57b; }
.graph-node .output-chip.route-cyan { --port-color: #43b4ca; }

.graph-node .graph-output-socket {
  width: 15px;
  height: 15px;
  position: absolute;
  right: -10px;
  top: 6px;
  z-index: 4;
  border: 1px solid var(--port-color);
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #f5f6f2;
  background: color-mix(in srgb, var(--port-color) 44%, #1c1f1b);
  box-shadow: 0 0 0 3px color-mix(in srgb, var(--port-color) 11%, transparent);
  pointer-events: none;
  transition: background 120ms ease, box-shadow 120ms ease;
}

.graph-node .graph-output-socket svg {
  width: 8px;
  height: 8px;
}

.graph-node .output-add:hover .graph-output-socket {
  background: color-mix(in srgb, var(--port-color) 58%, #1c1f1b);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--port-color) 17%, transparent);
}

.graph-node .output-add::after {
  display: none;
}

.graph-node .output-add:hover::after {
  display: none;
}

.graph-node .no-outputs {
  padding-bottom: 3px;
}

.graph-source-head {
  width: 100%;
  height: 55px;
  border: 0;
  border-radius: 8px 8px 0 0;
  padding: 6px 8px;
  display: grid;
  grid-template-columns: 42px minmax(0,1fr) 16px;
  align-items: center;
  gap: 8px;
  color: #e4e6df;
  text-align: left;
  background: rgba(255,255,255,.035);
  cursor: pointer;
}

.graph-source-head:hover {
  background: rgba(255,255,255,.065);
}

.graph-source-head img {
  width: 42px;
  height: 42px;
  border-radius: 5px;
  object-fit: cover;
}

.graph-source-head span {
  min-width: 0;
}

.graph-source-head span small,
.graph-source-head span strong {
  display: block;
}

.graph-source-head span small {
  color: #777b73;
  font-size: 6px;
  font-weight: 800;
  letter-spacing: .08em;
}

.graph-source-head span strong {
  margin-top: 3px;
  overflow: hidden;
  font-size: 8px;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.graph-source-head > svg {
  width: 13px;
  height: 13px;
  color: #858980;
}

.source-node .source-output {
  padding-top: 6px;
}

.graph-canvas-hint {
  position: absolute;
  left: 10px;
  bottom: 8px;
  z-index: 9;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 12px;
  padding: 4px 7px;
  display: flex;
  align-items: center;
  gap: 4px;
  color: #676b64;
  background: rgba(15,17,14,.78);
  font-size: 6px;
  pointer-events: none;
}

.graph-canvas-hint svg {
  width: 9px;
  height: 9px;
}

.graph-composer-shell {
  width: min(250px, calc(100% - 18px));
  max-height: calc(100% - 18px);
  position: absolute;
  right: 9px;
  bottom: 9px;
  z-index: 20;
  overflow-y: auto;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 10px;
  background: rgba(17,19,16,.97);
  box-shadow: 0 18px 45px rgba(0,0,0,.42);
  backdrop-filter: blur(16px);
  overscroll-behavior: contain;
}

.graph-composer-shell .route-composer {
  margin: 0;
  border: 0;
  border-radius: inherit;
  background: transparent;
}

.graph-notice {
  position: absolute;
  left: 50%;
  top: 12px;
  z-index: 24;
  border: 1px solid rgba(242,104,58,.28);
  border-radius: 16px;
  padding: 6px 10px;
  color: #e6b4a6;
  background: rgba(44,24,19,.94);
  font-size: 7px;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, -5px);
  transition: opacity 130ms ease, transform 130ms ease;
  white-space: nowrap;
}

.graph-notice.show {
  opacity: 1;
  transform: translate(-50%, 0);
}

.graph-notice.success {
  border-color: rgba(76,181,123,.3);
  color: #a6dbbd;
  background: rgba(19,42,29,.94);
}

.wire-actions {
  position: absolute;
  z-index: 30;
  border: 1px solid rgba(255,255,255,.16);
  border-radius: 7px;
  padding: 3px;
  display: flex;
  gap: 2px;
  background: rgba(18,20,17,.97);
  box-shadow: 0 8px 24px rgba(0,0,0,.38);
  transform: translate(-50%, -50%);
}

.wire-actions[hidden] {
  display: none;
}

.wire-actions button {
  height: 24px;
  border: 0;
  border-radius: 5px;
  padding: 0 7px;
  display: flex;
  align-items: center;
  gap: 4px;
  color: #c9ccc4;
  background: transparent;
  font-size: 7px;
  cursor: pointer;
}

.wire-actions button:hover {
  color: white;
  background: rgba(255,255,255,.09);
}

.wire-actions button:last-child {
  color: #ef927c;
}

.wire-actions svg {
  width: 10px;
  height: 10px;
}

.graph-context-menu {
  width: 160px;
  position: absolute;
  z-index: 45;
  border: 1px solid rgba(255,255,255,.15);
  border-radius: 8px;
  padding: 4px;
  color: #dcdfd7;
  background: rgba(18,20,17,.985);
  box-shadow: 0 16px 38px rgba(0,0,0,.48);
  backdrop-filter: blur(14px);
}

.graph-context-menu[hidden] {
  display: none;
}

.graph-context-menu button {
  width: 100%;
  min-height: 28px;
  border: 0;
  border-radius: 5px;
  padding: 0 7px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: inherit;
  background: transparent;
  font-size: 8px;
  text-align: left;
  cursor: pointer;
}

.graph-context-menu button:hover {
  background: rgba(255,255,255,.08);
}

.graph-context-menu button:disabled {
  opacity: .35;
  cursor: default;
}

.graph-context-menu button.danger {
  color: #ef927c;
}

.graph-context-menu kbd {
  color: #747870;
  font: 6px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
}

.graph-context-menu > i {
  height: 1px;
  margin: 3px 5px;
  display: block;
  background: rgba(255,255,255,.09);
}

.project-menu {
  width: 178px;
  position: fixed;
  right: 56px;
  top: 42px;
  z-index: 80;
  border: 1px solid rgba(255,255,255,.14);
  border-radius: 8px;
  padding: 4px;
  color: #daddd5;
  background: rgba(18,20,17,.985);
  box-shadow: 0 16px 38px rgba(0,0,0,.45);
}

.project-menu[hidden] {
  display: none;
}

.project-menu button {
  width: 100%;
  height: 31px;
  border: 0;
  border-radius: 5px;
  padding: 0 8px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: inherit;
  background: transparent;
  font-size: 8px;
  cursor: pointer;
}

.project-menu button:hover {
  background: rgba(255,255,255,.08);
}

.project-menu kbd {
  color: #747870;
  font: 6px/1 ui-monospace, SFMono-Regular, Menlo, monospace;
}

.inspector-empty-state {
  min-height: 230px;
  display: grid;
  place-items: center;
  align-content: center;
  gap: 8px;
  color: #767a72;
  text-align: center;
}

.inspector-empty-state > svg {
  width: 24px;
  height: 24px;
  color: #565a53;
}

.inspector-empty-state strong {
  color: #c8cbc3;
  font-size: 9px;
}

.detail-description {
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 8px;
  padding: 10px;
  color: #a5a9a0;
  background: rgba(255,255,255,.04);
  font-size: 8px;
  line-height: 1.55;
}

.contract-list {
  display: grid;
  gap: 5px;
}

.contract-row {
  min-width: 0;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 7px;
  padding: 7px;
  display: grid;
  grid-template-columns: 7px minmax(0, 1fr) auto;
  align-items: center;
  gap: 7px;
  color: #daddd5;
  background: rgba(255,255,255,.035);
}

.contract-row > i {
  width: 7px;
  height: 7px;
  border: 2px solid #b68a43;
  border-radius: 50%;
}

.contract-row.connected > i {
  border-color: #4cb57b;
  background: #4cb57b;
}

.contract-row span,
.contract-row strong,
.contract-row small {
  min-width: 0;
  display: block;
}

.contract-row strong {
  font-size: 8px;
}

.contract-row small {
  margin-top: 2px;
  color: #858880;
  font-size: 7px;
}

.contract-row > b {
  color: #8b8e86;
  font-size: 7px;
}

.output-value-preview {
  max-height: 150px;
  overflow: auto;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 7px;
  padding: 9px;
  color: #c4c8bf;
  background: rgba(255,255,255,.04);
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 7px;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
}

.text-output-result {
  display: grid;
  gap: 7px;
}

.text-output-meta {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 9px;
}

.text-output-meta span,
.text-output-meta strong,
.text-output-meta small,
.text-generation-status span,
.text-generation-status strong,
.text-generation-status small {
  min-width: 0;
  display: block;
}

.text-output-meta strong {
  color: #daddd5;
  font-size: 8px;
}

.text-output-meta small {
  margin-top: 2px;
  color: #858a81;
  font-size: 7px;
}

.text-output-meta > b {
  flex: none;
  border: 1px solid rgba(76,181,123,.28);
  border-radius: 999px;
  padding: 4px 6px;
  color: #72ca99;
  background: rgba(76,181,123,.08);
  font-size: 6px;
  letter-spacing: .06em;
}

.output-value-preview.text-output-preview {
  width: 100%;
  min-height: 220px;
  max-height: min(42vh, 410px);
  margin: 0;
  box-sizing: border-box;
  color: #d8dcd3;
  background: rgba(8,10,8,.42);
  font-size: 8px;
  line-height: 1.65;
  cursor: text;
  user-select: text;
  scrollbar-gutter: stable;
}

.text-output-content {
  min-width: 0;
  min-height: 1em;
  display: block;
  color: #d8dcd3;
  font-family: "DejaVu Sans Mono", "Liberation Mono", monospace;
  font-size: 9px;
  font-weight: 400;
  line-height: 1.55;
  white-space: pre-wrap;
  overflow-wrap: break-word;
}

.output-value-preview.text-output-preview:focus {
  border-color: rgba(240,100,54,.55);
  outline: 2px solid rgba(240,100,54,.12);
  outline-offset: 1px;
}

.output-value-preview.text-output-preview.expanded {
  min-height: min(58vh, 580px);
  max-height: min(58vh, 580px);
}

.text-output-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
}

.text-output-actions button {
  min-height: 29px;
  border: 1px solid rgba(255,255,255,.1);
  border-radius: 6px;
  color: #c6cac1;
  background: rgba(255,255,255,.045);
  font-size: 7px;
  font-weight: 650;
  cursor: pointer;
}

.text-output-actions button:hover {
  border-color: rgba(255,255,255,.18);
  color: white;
  background: rgba(255,255,255,.08);
}

.text-generation-status {
  min-width: 0;
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 7px;
  padding: 8px;
  display: grid;
  grid-template-columns: 7px minmax(0,1fr);
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,.035);
}

.text-generation-status > i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #868b82;
}

.text-generation-status strong {
  color: #c9cdc4;
  font-size: 8px;
}

.text-generation-status small {
  margin-top: 2px;
  color: #858a81;
  font-size: 7px;
  line-height: 1.4;
}

.text-generation-status.complete > i {
  background: #4cb57b;
  box-shadow: 0 0 0 3px rgba(76,181,123,.12);
}

.text-generation-status.warning {
  border-color: rgba(218,157,71,.2);
  background: rgba(218,157,71,.05);
}

.text-generation-status.warning > i {
  background: #da9d47;
  box-shadow: 0 0 0 3px rgba(218,157,71,.11);
}

.text-generation-status.warning strong {
  color: #e2bd7e;
}

.text-generation-performance {
  min-width: 0;
  border: 1px solid rgba(123,102,196,.2);
  border-radius: 7px;
  padding: 8px;
  display: grid;
  gap: 8px;
  background: rgba(123,102,196,.05);
}

.text-performance-heading {
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.text-performance-heading span,
.text-performance-heading strong,
.text-performance-heading small {
  min-width: 0;
  display: block;
}

.text-performance-heading strong {
  color: #d9d4ed;
  font-size: 8px;
}

.text-performance-heading small {
  margin-top: 2px;
  color: #858099;
  font-size: 7px;
}

.text-performance-heading > b {
  flex: none;
  border-radius: 999px;
  padding: 4px 6px;
  color: #b5a8ef;
  background: rgba(123,102,196,.13);
  font-size: 6px;
  letter-spacing: .06em;
}

.text-performance-grid {
  min-width: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 5px;
}

.text-performance-grid > div {
  min-width: 0;
  border: 1px solid rgba(255,255,255,.07);
  border-radius: 6px;
  padding: 7px;
  display: grid;
  gap: 2px;
  background: rgba(8,10,8,.25);
}

.text-performance-grid small,
.text-performance-grid strong,
.text-performance-grid span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.text-performance-grid small {
  color: #858099;
  font-size: 6px;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.text-performance-grid strong {
  color: #e1ddef;
  font-size: 9px;
  font-variant-numeric: tabular-nums;
}

.text-performance-grid span {
  color: #777486;
  font-size: 6px;
  line-height: 1.35;
}

.analysis-report {
  display: grid;
  gap: 7px;
}

.analysis-reference,
.analysis-equations,
.analysis-region {
  border: 1px solid rgba(255,255,255,.09);
  border-radius: 7px;
  color: #bfc3ba;
  background: rgba(255,255,255,.04);
}

.analysis-reference {
  padding: 9px;
  color: #9ea39a;
  font-size: 8px;
  line-height: 1.5;
}

.analysis-equations {
  padding: 7px 9px;
  display: grid;
  gap: 5px;
}

.analysis-equations code {
  min-height: 12px;
  display: block;
  color: #a9dbe4;
  font-family: inherit;
  font-size: 8px;
  font-weight: 600;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.analysis-region {
  overflow: hidden;
}

.analysis-region summary {
  min-height: 34px;
  padding: 0 9px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  cursor: pointer;
}

.analysis-region summary span {
  min-width: 0;
  overflow: hidden;
  color: #daddd5;
  font-size: 9px;
  font-weight: 700;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.analysis-region summary b {
  flex: none;
  color: #777c73;
  font-size: 8px;
}

.analysis-metrics {
  border-top: 1px solid rgba(255,255,255,.075);
}

.analysis-metrics > div {
  min-height: 32px;
  padding: 5px 9px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}

.analysis-metrics > div + div {
  border-top: 1px solid rgba(255,255,255,.055);
}

.analysis-metrics span {
  min-width: 0;
  color: #858a81;
  font-size: 8px;
}

.analysis-metrics .analysis-value {
  width: 72px;
  min-width: 72px;
  min-height: 11px;
  flex: 0 0 72px;
  display: block;
  color: #daddd5;
  font-family: inherit;
  font-size: 8px;
  font-weight: 700;
  line-height: 1.3;
  text-align: right;
  white-space: nowrap;
}

.node-analysis-result {
  margin-top: 16px;
}

.artifact-download {
  width: 100%;
  min-height: 30px;
  margin-top: 7px;
  border: 1px solid rgba(255,255,255,.11);
  border-radius: 7px;
  color: #daddd5;
  background: rgba(255,255,255,.055);
  font-size: 8px;
  font-weight: 700;
  cursor: pointer;
}

.artifact-download:hover {
  border-color: rgba(255,255,255,.2);
  background: rgba(255,255,255,.09);
}

@media (max-width: 420px) {
  .picker-category-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.inspector-empty-state span {
  max-width: 170px;
  font-size: 7px;
  line-height: 1.55;
}

@media (max-width: 1100px) and (min-width: 621px) {
  .pipeline-panel {
    width: 278px;
  }
}

@media (max-width: 620px) {
  .pipeline-panel {
    min-width: 0;
    max-width: none;
    grid-template-rows: 48px 28px minmax(0,1fr) 52px;
  }

  .panel-resizer {
    display: none;
  }

  .graph-canvas-hint {
    max-width: calc(100% - 20px);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }
}

@media (max-width: 420px) {
  .brand > strong {
    letter-spacing: .05em;
  }

  .activity-rail {
    padding-top: 7px;
  }

  .rail-button {
    height: 34px;
  }

  .details-body {
    padding: 12px;
  }

  .zoom-bar {
    left: calc(50% - 2px);
  }
}
