/* Content area keeps its scrollbar gutter, so switching between short and long pages (device tabs) does not shift the layout. */
#content { scrollbar-gutter: stable; }
/* ===== Dashboard ===== */
.dash { display: grid; grid-template-columns: 1.4fr 1fr; gap: var(--sp-4); }
.dash .full { grid-column: 1 / -1; }
.widget { min-width: 0; position: relative; }
.widget > .card { height: 100%; }
.widget.editing { outline: 1px dashed var(--border-strong); outline-offset: 4px; border-radius: var(--r-lg); cursor: grab; transition: outline-color var(--dur-fast), transform var(--dur-fast), opacity var(--dur-fast); }
.widget.editing:hover { outline-color: var(--primary); }
.widget.editing.dragging { opacity: 0.4; cursor: grabbing; }
.widget.editing.over { outline: 2px solid var(--accent); transform: scale(0.99); }
.widget.editing .card, .widget.editing .kpi { pointer-events: none; }
.wtools { position: absolute; top: -12px; left: 10px; right: 10px; display: flex; align-items: center; justify-content: space-between; z-index: 5; pointer-events: none; }
.wtools .handle { display: inline-flex; align-items: center; gap: 6px; padding: 2px 10px 2px 6px; border-radius: 999px; background: var(--bg-elevated); border: 1px solid var(--border-strong); font-size: 11px; font-weight: 700; color: var(--text-muted); pointer-events: auto; }
.wtools .btn { pointer-events: auto; background: var(--bg-elevated); border: 1px solid var(--border-strong); color: var(--text-muted); }
.wtools .btn:hover { color: var(--danger); border-color: var(--danger); }
.dash.editing .widget { margin-top: 8px; }
.attention-item { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r-md); background: var(--bg-elevated); border: 1px solid var(--border-subtle); margin-bottom: 8px; }
.attention-item .t { font-weight: 600; font-size: var(--fs-sm); }
.attention-item .d { font-size: var(--fs-xs); color: var(--text-muted); }
.attention-item .btn { margin-left: auto; }
.health-item { display: flex; align-items: center; gap: 10px; padding: 10px 12px; border-radius: var(--r-md); background: var(--bg-elevated); border: 1px solid var(--border-subtle); font-size: var(--fs-sm); }
.health-item .v { margin-left: auto; font-family: var(--font-mono); font-size: 11px; color: var(--text-muted); white-space: nowrap; display: inline-flex; align-items: center; gap: 6px; }
.device-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border-subtle); cursor: pointer; }
.device-row:last-child { border-bottom: none; }
.device-row:hover .n { color: var(--accent); }
.device-row .n { font-weight: 700; }
.device-row .meta { font-size: var(--fs-xs); color: var(--text-muted); }
.device-row .cnt { margin-left: auto; font-family: var(--font-mono); font-weight: 700; }
.feed { display: flex; flex-direction: column; gap: 4px; max-height: 320px; overflow: auto; font-family: var(--font-mono); font-size: 12px; }
.feed-row { display: flex; align-items: center; gap: 10px; padding: 7px 10px; border-radius: 8px; border: 1px solid transparent; min-width: 0; }
.feed-row > span { white-space: nowrap; }
.feed-row:hover { background: var(--bg-hover); cursor: pointer; }
.feed-row .ts { color: var(--text-disabled); }
.feed-row .dv { color: var(--accent); flex: 0 1 110px; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.feed-row .arrow { color: var(--text-disabled); }
.feed-row .bc { color: var(--text-primary); flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
.feed-row .st { margin-left: auto; flex: none; }
.chart-wrap { display: grid; grid-template-columns: 34px 1fr; gap: 2px 6px; }
.chart-y { display: flex; flex-direction: column; justify-content: space-between; align-items: flex-end; height: 220px; padding: 10px 0 0; font-size: 10px; color: var(--text-disabled); font-family: var(--font-mono); }
.chart { height: 220px; display: flex; align-items: flex-end; gap: 3px; padding: 10px 0 0; position: relative; border-bottom: 1px solid var(--border-default); border-left: 1px solid var(--border-default); background-image: repeating-linear-gradient(to top, transparent 0, transparent calc(25% - 1px), var(--border-subtle) calc(25% - 1px), var(--border-subtle) 25%); background-size: 100% calc(100% - 10px); background-position: 0 100%; background-repeat: no-repeat; }
.chart .tcol { flex: 1; height: 100%; display: flex; align-items: flex-end; border-radius: 4px 4px 0 0; cursor: default; transition: background var(--dur-fast); }
.chart .tcol:hover { background: rgba(255,255,255,0.05); }
.chart .tcol:hover .bar { filter: brightness(1.25); }
.chart .tcol.now .bar { box-shadow: 0 0 0 1px rgba(43,211,224,0.5); }
.chart .bar { width: 100%; flex: none; display: flex; flex-direction: column-reverse; gap: 1px; border-radius: 3px 3px 0 0; overflow: hidden; }
.chart .bar span { display: block; width: 100%; }
.chart-x { display: flex; gap: 3px; font-size: 10px; color: var(--text-disabled); font-family: var(--font-mono); margin-top: 4px; }
.chart-x span { flex: 1; min-width: 0; text-align: center; white-space: nowrap; overflow: visible; }
.btn.spin svg { animation: spin 0.8s linear infinite; }
.legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: var(--fs-xs); color: var(--text-muted); }
.legend span { display: inline-flex; align-items: center; gap: 6px; }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }

/* ===== Devices ===== */
.device-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); grid-auto-rows: 1fr; gap: var(--sp-4); }
.device-card { padding: 16px; display: flex; flex-direction: column; gap: 12px; }
.device-card .hd { display: flex; align-items: center; gap: 12px; height: 64px; min-height: 64px; }
.device-card .hd .grow { min-width: 0; }
.device-card .hd .nm { font-weight: 800; font-size: var(--fs-lg); }
.device-card .hd .bp { font-size: var(--fs-xs); color: var(--text-muted); white-space: nowrap; }
.device-card .stats { display: grid; grid-template-columns: 1fr 2fr; gap: 8px; }
.dev-toolbar .input-wrap { flex: 0 1 230px; min-width: 160px; }
.dev-toolbar .select { width: auto; flex: 0 1 auto; min-width: 110px; max-width: 170px; }
.dev-toolbar .chips { flex: none; }
.device-card .stats > div { background: var(--bg-app); border: 1px solid var(--border-subtle); border-radius: 9px; padding: 8px 10px; }
.device-card .stats .l { font-size: 10px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-disabled); font-weight: 700; }
.device-card .stats .v { font-weight: 700; font-family: var(--font-mono); font-size: 13px; }
.bp-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); grid-auto-rows: 1fr; gap: 10px; }
.bp-card { padding: 14px; display: flex; flex-direction: column; gap: 8px; cursor: pointer; border: 1px solid var(--border-default); border-radius: var(--r-lg); background: var(--bg-surface); position: relative; transition: all var(--dur-fast); }
.bp-card:hover { border-color: var(--border-strong); transform: translateY(-1px); }
.bp-card.on { border-color: var(--primary); background: var(--primary-soft); box-shadow: inset 0 0 0 1px var(--primary); }
.bp-card .nm { font-weight: 700; font-size: var(--fs-sm); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bp-card .d { font-size: 11px; color: var(--text-muted); line-height: 1.4; min-height: 15px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.bp-card .io { font-size: var(--fs-xs); line-height: 1.4; min-height: 2.8em; color: var(--text-secondary, var(--text-muted)); padding-top: 6px; border-top: 1px solid var(--border-subtle); }
.wiz-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 24px; align-items: start; }
.wiz-layout .steps { position: sticky; top: 0; }
details.adv { border: 1px solid var(--border-subtle); border-radius: var(--r-md); padding: 10px 14px; background: var(--bg-app); }
details.adv > summary { cursor: pointer; list-style: none; display: flex; align-items: center; gap: 6px; font-size: var(--fs-sm); font-weight: 600; color: var(--text-muted); }
details.adv > summary::-webkit-details-marker { display: none; }
details.adv > summary svg.ic { width: 14px; height: 14px; transition: transform var(--dur-fast); }
details.adv[open] > summary svg.ic { transform: rotate(90deg); }
.bp-card .ph { position: absolute; top: 10px; right: 10px; }
.chain { display: flex; align-items: center; gap: 8px; padding: 16px; background: var(--bg-elevated); border-radius: var(--r-lg); overflow-x: auto; }
.chain .node { display: flex; flex-direction: column; align-items: center; gap: 6px; min-width: 120px; padding: 12px; border-radius: var(--r-md); background: var(--bg-surface); border: 1px solid var(--border-subtle); text-align: center; }
.chain .node .nm { font-weight: 700; font-size: var(--fs-sm); }
.chain .node .d { font-size: 11px; color: var(--text-muted); }
.chain .node .ic-box { width: 36px; height: 36px; }
.chain .link { flex: 1; min-width: 40px; height: 2px; background: repeating-linear-gradient(90deg, var(--accent) 0 8px, transparent 8px 14px); position: relative; animation: flowSlide 1s linear infinite; }
@keyframes flowSlide { to { background-position: 14px 0; } }
.chain .link.bad { background: repeating-linear-gradient(90deg, var(--danger) 0 8px, transparent 8px 14px); animation: none; }
.probe-steps { display: flex; flex-direction: column; gap: 6px; }
.probe-step { display: flex; align-items: center; gap: 10px; padding: 8px 10px; border-radius: 8px; background: var(--bg-elevated); font-size: var(--fs-sm); }
.probe-step .ms { margin-left: auto; font-family: var(--font-mono); font-size: 11px; color: var(--text-muted); }
.probe-step .ic-s { width: 20px; height: 20px; border-radius: 50%; display: flex; align-items: center; justify-content: center; flex: none; }
.probe-step .ic-s svg { width: 12px; height: 12px; }
.probe-step.ok .ic-s { background: var(--success-soft); color: var(--success); }
.probe-step.fail .ic-s { background: var(--danger-soft); color: var(--danger); }
.probe-step.run .ic-s { color: var(--accent); }
.probe-step.wait .ic-s { background: var(--bg-hover); color: var(--text-disabled); }
.preview-table { font-family: var(--font-mono); font-size: 12px; }
.preview-table th { background: var(--bg-elevated); }
.preview-table td.ok { color: #86EFAC; }
.preview-table td.bad { color: #FCA5A5; }
.file-row { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 8px; border-bottom: 1px solid var(--border-subtle); font-size: var(--fs-sm); }
.file-row > svg.ic { flex: none; }
.file-row > div { min-width: 0; flex: 1 1 auto; }
.file-row > div .nm { display: block; }
.file-row .nm { font-family: var(--font-mono); font-size: 12px; min-width: 0; flex: 1 1 auto; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.file-row .meta { margin-left: auto; font-size: 11px; color: var(--text-muted); display: flex; gap: 12px; align-items: center; flex: none; white-space: nowrap; }

/* ===== Agents ===== */
.agent-card { padding: 16px; display: flex; flex-direction: column; gap: 12px; height: 100%; }
.agent-card .hd { display: flex; align-items: center; gap: 12px; }
.agent-card .host { font-weight: 800; }
.agent-card .ip { font-family: var(--font-mono); font-size: 11px; color: var(--text-muted); }
.caps { display: flex; gap: 4px; flex-wrap: wrap; }
.caps span { font-family: var(--font-mono); font-size: 10px; padding: 2px 6px; border-radius: 5px; background: var(--bg-elevated); color: var(--text-muted); border: 1px solid var(--border-subtle); }

/* ===== LIS ===== */
.behavior-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }

/* ===== Workflows list ===== */

.version-row { display: flex; gap: 12px; align-items: flex-start; padding: 12px 0; border-bottom: 1px solid var(--border-subtle); }
.version-row .v { width: 42px; height: 28px; border-radius: 7px; background: var(--bg-elevated); display: flex; align-items: center; justify-content: center; font-family: var(--font-mono); font-weight: 800; font-size: 12px; }
.version-row.current .v { background: var(--primary); color: #fff; }

/* ===== Mapper ===== */

/* ===== Queues ===== */

/* ===== Transactions ===== */
.tx-detail { display: grid; grid-template-columns: 1fr 1.2fr; gap: var(--sp-4); }
.tx-head { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 16px 18px; }
.tx-head .bc { font-family: var(--font-mono); font-size: var(--fs-xl); font-weight: 800; }
.tx-head .tot { margin-left: auto; display: flex; gap: 18px; }
.tx-head .tot div { text-align: right; }
.tx-head .tot .l { font-size: 10px; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-disabled); font-weight: 700; }
.tx-head .tot .v { font-family: var(--font-mono); font-weight: 800; }
.journey { display: flex; align-items: center; gap: 6px; overflow-x: auto; padding: 4px 0; }
.journey .j { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px; border-radius: 10px; background: var(--bg-elevated); border: 1px solid var(--border-subtle); min-width: 150px; cursor: pointer; }
.journey .j.cur { border-color: var(--accent); }
.journey .j .d { font-weight: 700; font-size: var(--fs-xs); }
.journey .j .t { font-size: 10px; color: var(--text-muted); font-family: var(--font-mono); }
.journey .ar { color: var(--text-disabled); }
.live-badge { display: inline-flex; align-items: center; gap: 6px; font-size: 11px; font-weight: 700; color: var(--accent); }
.live-badge i { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); animation: pulse 1.2s infinite; }

/* ===== Device Center ===== */
.station { aspect-ratio: 1; border-radius: 5px; display: flex; align-items: center; justify-content: center; font-size: 10px; font-family: var(--font-mono); font-weight: 700; cursor: default; }
.station.A, .station.E { background: var(--success-soft); color: #86EFAC; }
.station.P { background: var(--primary-soft); color: #93C5FD; }
.station.U { background: var(--paused-soft); color: var(--text-disabled); }

/* ===== Labels ===== */

/* ===== Logs ===== */

/* ===== Settings ===== */
.settings { display: grid; grid-template-columns: 220px 1fr; gap: var(--sp-5); }
.settings-nav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: 0; }
.settings-nav a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 9px; color: var(--text-muted); font-weight: 600; font-size: var(--fs-sm); }
.settings-nav a:hover { background: var(--bg-hover); color: var(--text-primary); text-decoration: none; }
.settings-nav a.on { background: var(--primary-soft); color: var(--text-primary); }
.settings-nav a svg { width: 16px; height: 16px; }
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 14px 18px; }
.form-grid .full { grid-column: 1 / -1; }
.form-grid.three { grid-template-columns: repeat(3, 1fr); }

/* ===== Tools ===== */
.tool-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--sp-4); }
.tool-card { padding: 18px; display: flex; gap: 14px; align-items: flex-start; }
.tool-card .t { font-weight: 800; }
.tool-card .d { font-size: var(--fs-xs); color: var(--text-muted); margin-top: 3px; }
.scope-chip { display: inline-flex; align-items: center; gap: 6px; padding: 6px 10px; border-radius: 8px; background: var(--bg-elevated); border: 1px solid var(--border-subtle); font-family: var(--font-mono); font-size: 11px; }
.scope-chip.on { border-color: rgba(34,197,94,0.4); color: #86EFAC; }
.scope-chip.off { color: var(--text-disabled); text-decoration: line-through; }
.checklist-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 9px; background: var(--bg-elevated); border: 1px solid var(--border-subtle); margin-bottom: 6px; }
.checklist-row .t { font-weight: 600; font-size: var(--fs-sm); }
.checklist-row .d { font-size: 11px; color: var(--text-muted); }

/* Device detail (04.11.2026): capture chain shows direction; bidirectional devices draw two lines. */
.chain .link-wrap { flex: 1; min-width: 48px; display: flex; flex-direction: column; justify-content: center; gap: 12px; }
.chain .flow { position: relative; height: 2px; margin: 0 6px; background: repeating-linear-gradient(90deg, var(--accent) 0 8px, transparent 8px 14px); animation: flowSlide 1s linear infinite; }
.chain .flow.back { background: repeating-linear-gradient(90deg, #A78BFA 0 8px, transparent 8px 14px); animation-direction: reverse; }
.chain .flow::after { content: ''; position: absolute; top: 50%; transform: translateY(-50%); border-top: 5px solid transparent; border-bottom: 5px solid transparent; }
.chain .flow.fwd::after { right: -6px; border-left: 8px solid var(--accent); }
.chain .flow.back::after { left: -6px; border-right: 8px solid #A78BFA; }
.chain .flow.bad { background: repeating-linear-gradient(90deg, var(--danger) 0 8px, transparent 8px 14px); animation: none; }
.chain .flow.bad.fwd::after { border-left-color: var(--danger); }
.chain .flow.bad.back::after { border-right-color: var(--danger); }
.chain .flow.idle { opacity: 0.35; animation: none; }
.chain-legend { display: flex; gap: 18px; margin-top: 10px; font-size: 11px; color: var(--text-muted); }
.chain-legend .k { display: inline-flex; align-items: center; gap: 8px; }
.field > .segmented { align-self: flex-start; }

/* Device Center (04.11.2026): fixed order cards, panel members, station legend, barcode parts. */
.legend i.st-A { background: var(--success-soft); border: 1px solid #86EFAC; }
.legend i.st-P { background: var(--primary-soft); border: 1px solid #93C5FD; }
.legend i.st-U { background: var(--paused-soft); border: 1px solid var(--text-disabled); }
.tpl-chips { display: flex; flex-wrap: wrap; gap: 6px; padding: 8px; border-radius: var(--r-md); background: var(--bg-input); border: 1px solid var(--border-default); min-height: 44px; }
.tpl-chip { display: inline-flex; align-items: center; gap: 4px; height: 26px; padding: 0 8px; border-radius: 7px; font-size: var(--fs-xs); font-weight: 600; background: var(--bg-elevated); border: 1px solid var(--border-default); }
.tpl-chip.text { background: var(--accent-soft); color: #67E8F9; border-color: transparent; }
.tpl-chip .x { border: none; background: transparent; color: var(--text-muted); cursor: pointer; padding: 0; display: inline-flex; }
.tpl-chip .x svg { width: 12px; height: 12px; }
.tpl-chip .x:hover { color: var(--danger); }
.tbl [data-errtext] { width: 100%; min-width: 230px; }

/* Genie Center catalog editing (04.11.2026) */

/* Optional instrument files not sent (Stations & inventory). */
.empty.compact { padding: 28px 16px; }
.empty.compact .art { width: 56px; height: 56px; border-radius: 16px; }
.empty.compact .art svg { width: 24px; height: 24px; }
.empty.compact h3 { font-size: var(--fs-md); }

/* Orders board: columns have a fixed height and scroll inside, so the page stays short. */

/* Queues (04.11.2026): flow lanes + decision cards. */
/* Direction arrows: one SVG (line and head together) as a mask, centred by flex, so they stay level with the text at any zoom. */
.lane-key, .chain-legend i { display: block; flex: none; width: 24px; height: 10px; background: var(--accent); -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 10'%3E%3Crect x='0' y='4' width='18' height='2'/%3E%3Cpath d='M17 0.5 24 5 17 9.5z'/%3E%3C/svg%3E") center / 100% 100% no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 10'%3E%3Crect x='0' y='4' width='18' height='2'/%3E%3Cpath d='M17 0.5 24 5 17 9.5z'/%3E%3C/svg%3E") center / 100% 100% no-repeat; }
.lane-key.back, .chain-legend i.back { background: #A78BFA; }
.chain-legend i.back { transform: scaleX(-1); }
.warning-border { border-color: rgba(245, 158, 11, 0.45) !important; }

/* Transaction Explorer (04.11.2026): extra filters row, header key-values. */
.tx-kv { display: flex; flex-wrap: wrap; gap: 6px 22px; font-size: var(--fs-sm); }
.tx-kv > div { display: flex; gap: 8px; min-width: 0; }
.tx-kv .k { color: var(--text-muted); }
.tx-kv .v { color: var(--text-primary); white-space: nowrap; }
.tx-head { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: start; column-gap: 16px; row-gap: 12px; }
.tx-head > .banner, .tx-head > .row:last-child { grid-column: 1 / -1; }
.tx-head .tot { margin-left: 0; }
.tx-head .dropdown { min-width: 250px; }
.tx-head .dropdown .item { white-space: nowrap; }
/* Transaction header timings: four equal right-aligned columns, values are always durations. */
.tx-head .tot { display: grid; grid-template-columns: repeat(4, 72px); gap: 12px; }
.tx-head .tot .v { white-space: nowrap; }

/* Alerts (04.11.2026): single-line rows, source links, rule editor. */
.al-row { display: flex; align-items: center; gap: 10px; min-width: 0; }
.sev-ic { width: 26px; height: 26px; flex: none; border-radius: 8px; display: inline-flex; align-items: center; justify-content: center; }
.sev-ic svg { width: 15px; height: 15px; }
.sev-ic.sev-critical { background: var(--danger-soft); color: #FCA5A5; }
.sev-ic.sev-warning { background: var(--warning-soft); color: #FCD34D; }
.sev-ic.sev-info { background: var(--info-soft, var(--primary-soft)); color: #93C5FD; }

/* Logs (04.11.2026): standard tables, single-line rows. */
.log-tbl td, .audit-tbl td { font-size: var(--fs-sm); }
.log-tbl .lv { font-weight: 700; font-size: var(--fs-xs); }
.log-tbl .lv.info { color: #67E8F9; } .log-tbl .lv.warn { color: #FCD34D; } .log-tbl .lv.error { color: #FCA5A5; } .log-tbl .lv.debug { color: var(--text-disabled); }
.log-tbl .lg-msg { width: 100%; max-width: 0; min-width: 240px; }
.danger-text { color: #FCA5A5; }

/* Agents (04.11.2026): fixed card rows, pairing, assignments. */
.agent-card .ag-facts { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.agent-card .ag-facts > div { display: flex; flex-direction: column; gap: 2px; padding: 8px 10px; border-radius: 9px; background: var(--bg-app); border: 1px solid var(--border-subtle); min-width: 0; }
.agent-card .ag-facts .k { font-size: 11px; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.agent-card .ag-facts b { font-family: var(--font-mono); font-size: var(--fs-sm); }
.agent-card .ag-facts b.warning { color: #FCD34D; }
.agent-card.waiting { border-style: dashed; }
.ok-text { color: #86EFAC; }
/* Chips that must fit one line: names shrink with "…", the +N chip never shrinks. */
.chip-line .pill.fit { flex: 0 1 auto; min-width: 0; max-width: 100%; }
.chip-line .pill.fit .t { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.chip-line .pill.fit svg { flex: none; }
.installer-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 12px; border-radius: var(--r-md); background: var(--bg-elevated); border: 1px solid var(--border-subtle); }

/* Add agent / Scan network (04.11.2026): numbered steps with room to breathe. */
.modal.md { width: min(640px, 94vw); }
.add-steps { display: flex; flex-direction: column; gap: 22px; }
.add-step { display: flex; gap: 14px; align-items: flex-start; }
.add-step .num { width: 28px; height: 28px; flex: none; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-weight: 800; font-size: var(--fs-sm); background: var(--primary-soft); color: #93C5FD; border: 1px solid rgba(59,130,246,0.35); }
.add-step .t { font-weight: 700; margin-top: 3px; }
.add-step .d { color: var(--text-muted); font-size: var(--fs-sm); margin-top: 4px; line-height: 1.5; }
.add-step .installer-row { justify-content: flex-start; }
.installer-row .ic-s { display: inline-flex; align-items: center; justify-content: center; color: var(--accent); }
.installer-row .ic-s svg { width: 18px; height: 18px; }
.scan-run { display: flex; align-items: center; gap: 14px; padding: 8px 0; }
.scan-sum { font-size: var(--fs-sm); margin-bottom: 12px; }

/* Add Agent (04.11.2026 b): address row, waiting line, found-agent card. */
.addr-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 8px; }
.find-wait { display: flex; align-items: center; gap: 10px; padding: 12px 14px; border-radius: var(--r-md); background: var(--bg-app); border: 1px solid var(--border-subtle); color: var(--text-muted); font-size: var(--fs-sm); }
.found-card { padding: 16px; border-radius: var(--r-md); background: var(--bg-app); border: 1px solid rgba(34,197,94,0.35); }
.found-card .fc-head { display: flex; align-items: center; gap: 12px; }

/* LIS Connections (04.11.2026): one connection, two directions. */
.dir-ic { width: 30px; height: 30px; flex: none; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; background: var(--primary-soft); color: #67E8F9; }
.dir-ic.in { color: #C4B5FD; background: rgba(167, 139, 250, 0.15); }
.dir-ic svg { width: 15px; height: 15px; }
.toggle.locked { opacity: 0.6; cursor: not-allowed; }
details.adv > summary { cursor: pointer; color: var(--text-muted); font-size: var(--fs-sm); display: inline-flex; align-items: center; gap: 6px; list-style: none; }
details.adv > summary::-webkit-details-marker { display: none; }
details.adv > summary svg { width: 14px; height: 14px; }
.used-list { display: flex; flex-direction: column; gap: 8px; }
.used-row { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: var(--r-md); background: var(--bg-app); border: 1px solid var(--border-subtle); color: var(--text-primary); }
a.used-row:hover { border-color: var(--border-strong); }

/* ===== S6 Workflows (05.11.2026 redesign: step list instead of canvas) ===== */

.version-row.clickable { cursor: pointer; padding-left: 8px; padding-right: 8px; border-radius: var(--r-md); }
.version-row.clickable:hover { background: var(--bg-elevated); }
.version-row .grow { min-width: 0; }
.warning-text { color: var(--warning); display: flex; align-items: center; gap: 4px; }
.warning-text svg { width: 12px; height: 12px; }

/* ===== S7 Mapper (27. tur): field list on the left, live message on the right ===== */


  
  

/* Centred on the tab row; the tabs keep their 20px gap to the cards below, so does this. */


b.warning-text { display: inline-flex; }

/* 30. tur: Mapper show options, changes, ready lines, status rows */


.modal-foot .spacer { flex: 1; }
/* 31. tur: remove fields and lines added in the message view */

/* Head rows with and without a button are the same height, so the titles of side-by-side cards line up. */
#mp-preview .card-head { min-height: 30px; }
 /* 20px top padding + 30px row */
/* 34. tur: admin pages */
.insp-seg { border: 1px solid var(--border-subtle); border-radius: var(--r-md); margin-bottom: 8px; overflow: hidden; }
.insp-h { display: flex; align-items: center; gap: 8px; padding: 8px 12px; cursor: pointer; font-size: 13px; background: var(--bg-surface); }
.insp-h:hover { background: var(--bg-hover); }
.insp-h svg { width: 14px; height: 14px; color: var(--text-muted); flex-shrink: 0; }
.insp-h > span:first-of-type { flex: 1; min-width: 0; color: var(--text-secondary); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.insp-f { padding: 4px 0; border-top: 1px solid var(--border-subtle); }
.insp-r { display: grid; grid-template-columns: 96px minmax(0, 1fr) minmax(0, 1.2fr); gap: 12px; padding: 4px 12px; font-size: 12.5px; align-items: baseline; }
.insp-r .mono { overflow-wrap: anywhere; }
.insp-r.sub { padding-left: 28px; grid-template-columns: 80px minmax(0, 1fr) minmax(0, 1.2fr); color: var(--text-secondary); }
.perm-tbl td.c, .perm-tbl th.c { text-align: center; width: 120px; }
.perm-tbl tr.grp td, .grp-tbl tr.grp td { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); background: var(--bg-surface); height: 34px; }
.perm-yes { display: inline-flex; color: var(--success); } .perm-yes svg { width: 16px; height: 16px; }
.perm-no { color: var(--text-disabled); }
.lic-scopes { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
.lic-scope { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border: 1px solid var(--border-subtle); border-radius: var(--r-md); }
.lic-scope .ic { display: inline-flex; color: var(--text-disabled); } .lic-scope.on .ic { color: var(--success); }
.lic-scope .ic svg { width: 16px; height: 16px; }
.lic-scope .t { font-weight: 600; font-size: 13px; } .lic-scope .d { font-size: 12px; color: var(--text-muted); }
.lic-scope:not(.on) .t { color: var(--text-secondary); }
.lt-stats { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; }
.lt-stat { padding: 10px 12px; border: 1px solid var(--border-subtle); border-radius: var(--r-md); background: var(--bg-surface); min-width: 0; }
.lt-stat .l { font-size: 11px; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; color: var(--text-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.lt-stat .v { font-size: 22px; font-weight: 700; margin-top: 4px; font-variant-numeric: tabular-nums; }
/* Side-by-side cards: a head with a small button and one without are the same height, so the titles line up. */
.grid > .card > .card-head:first-child, .grid > .col > .card:first-child > .card-head:first-child { min-height: 30px; }
.lic-limits { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
/* 36. tur: boxed rows stacked outside a .probe-steps list keep the same 6px gap */
:not(.probe-steps) > .probe-step + .probe-step { margin-top: 6px; }
:not(.grid):not(.probe-steps) > .health-item + .health-item { margin-top: 6px; }
/* 38. tur: role in the Users table, members on the Roles tab */
.perm-lock { display: inline-flex; color: var(--text-disabled); } .perm-lock svg { width: 14px; height: 14px; }
.perm-tbl td.c .toggle { vertical-align: middle; }
/* 40. tur: with the menu open at 1280px the live feed row is narrower; the message type gives way, the state stays whole */
.feed-row > span[data-tip] { flex: 0 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; }
