/* Beacon NMS. Steel-grey chrome; severity is the only saturated colour in the interface. */
@font-face { font-family: 'Atkinson Hyperlegible Next'; src: url('fonts/AtkinsonHyperlegibleNext.woff2') format('woff2'); font-weight: 200 800; font-display: swap; }
@font-face { font-family: 'Atkinson Hyperlegible Mono'; src: url('fonts/AtkinsonHyperlegibleNextMono.woff2') format('woff2'); font-weight: 200 800; font-display: swap; }

:root {
  color-scheme: dark;
  --bg: #14181d; --panel: #1b2027; --panel-2: #222831; --line: #2d353f; --grid: #262d36;
  --text: #e7eaee; --muted: #9aa4af; --link: #79adf6; --focus: #79adf6;
  --btn-bg: #262d36; --btn-hover: #2f3742; --primary-bg: #e7eaee; --primary-text: #14181d;
  --danger: #ef6b6b; --ok: #4cc070;
  --threat: #b48cf2; --sev-critical: #e5484d; --sev-major: #f07a3a; --sev-minor: #f3aa3c; --sev-warning: #e6d24d; --sev-info: #5c9ef0; --sev-normal: #46b866;
  --series-1: #3987e5; --t1: #5c9ef0; --t2: #2bb3a3; --t3: #9a86ee; --t4: #e6a23c; --t5: #8d99a6;
  --c1: #3987e5; --c2: #d95926; --c3: #199e70; --c4: #c98500; --c5: #d55181; --c6: #008300; --c7: #9085e9; --c8: #e66767; --c-other: #6f7883;
  --shadow: 0 12px 40px rgba(0, 0, 0, .45);
  --radius: 8px; --radius-sm: 6px;
  --font: 'Atkinson Hyperlegible Next', system-ui, -apple-system, 'Segoe UI', sans-serif;
  --mono: 'Atkinson Hyperlegible Mono', ui-monospace, 'Cascadia Mono', Consolas, monospace;
}
:root[data-theme="light"] {
  color-scheme: light;
  --bg: #eef1f4; --panel: #ffffff; --panel-2: #f6f8fa; --line: #d5dce3; --grid: #e8ecf0;
  --text: #17202a; --muted: #586474; --link: #1d5fc2; --focus: #1d5fc2;
  --btn-bg: #ffffff; --btn-hover: #f0f3f6; --primary-bg: #17202a; --primary-text: #ffffff;
  --danger: #c42b2b; --ok: #1d7f3a;
  --threat: #7a3fc8; --sev-critical: #d42f35; --sev-major: #e0621f; --sev-minor: #e8940f; --sev-warning: #d9bd12; --sev-info: #2a74d6; --sev-normal: #279447;
  --series-1: #2a78d6; --t1: #2a74d6; --t2: #14917f; --t3: #6c55d8; --t4: #c27c0c; --t5: #6b7684;
  --c1: #2a78d6; --c2: #eb6834; --c3: #1baf7a; --c4: #eda100; --c5: #e87ba4; --c6: #008300; --c7: #6250d6; --c8: #e34948; --c-other: #8d96a0;
  --shadow: 0 12px 40px rgba(20, 30, 45, .18);
}

* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body { background: var(--bg); color: var(--text); font: 15px/1.45 var(--font); -webkit-font-smoothing: antialiased; font-variant-numeric: tabular-nums; }
a { color: var(--link); text-decoration: none; }
a:hover { text-decoration: underline; }
h1 { font-size: 26px; line-height: 1.2; font-weight: 700; margin: 0; letter-spacing: -.01em; }
h2 { font-size: 17px; font-weight: 700; margin: 0; }
h3 { font-size: 14px; font-weight: 700; margin: 18px 0 8px; }
p { margin: 0 0 10px; }
code, .mono { font-family: var(--mono); font-size: .92em; }
.muted { color: var(--muted); }
.small { font-size: 13px; }
.nowrap { white-space: nowrap; }
.break { word-break: break-all; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
@media (prefers-reduced-motion: reduce) { * { transition: none !important; animation: none !important; } }

/* ---------- layout ---------- */
.app { display: grid; grid-template-columns: 220px 1fr; height: 100vh; }
.sidebar { background: var(--panel); border-right: 1px solid var(--line); display: flex; flex-direction: column; padding: 14px 10px; gap: 10px; }
.brand { display: flex; align-items: center; gap: 10px; color: var(--text); font-weight: 800; font-size: 19px; padding: 6px 10px 14px; letter-spacing: -.01em; }
.brand:hover { text-decoration: none; }
/* The mark is a stack of severity bands: the product's colour language in miniature. */
.brand-mark { width: 22px; height: 22px; border-radius: 5px; background: linear-gradient(var(--sev-critical) 0 25%, var(--sev-major) 25% 50%, var(--sev-minor) 50% 75%, var(--sev-normal) 75%); }
.brand-mark.big { width: 44px; height: 44px; border-radius: 9px; }
.nav-links { display: flex; flex-direction: column; gap: 2px; }
.nav-link { display: flex; align-items: center; gap: 12px; padding: 9px 12px; border-radius: var(--radius-sm); color: var(--muted); font-weight: 600; }
.nav-link:hover { background: var(--panel-2); color: var(--text); text-decoration: none; }
.nav-link.active { background: var(--panel-2); color: var(--text); box-shadow: inset 3px 0 0 var(--accent, var(--text)); }
.nav-link span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nav-foot { margin-top: auto; border-top: 1px solid var(--line); padding-top: 10px; display: flex; flex-direction: column; gap: 6px; }
.nav-tools { display: flex; gap: 4px; padding: 0 6px; }
.content { display: flex; flex-direction: column; min-width: 0; height: 100vh; }
.topbar { display: flex; align-items: stretch; gap: 12px; padding: 12px 24px; border-bottom: 1px solid var(--line); background: var(--bg); }
.main { flex: 1; overflow: auto; padding: 22px 24px 48px; outline: none; }

/* ---------- severity rail ---------- */
.rail { flex: 1; display: flex; min-height: 40px; border-radius: var(--radius); overflow: hidden; gap: 2px; background: var(--line); }
.rail:hover { text-decoration: none; }
.rail-seg { display: flex; align-items: baseline; gap: 8px; padding: 0 14px; color: #12161b; align-items: center; min-width: 96px; cursor: pointer; transition: filter .15s; }
.rail-seg:hover { filter: brightness(1.08); }
.rail-num { font-size: 22px; font-weight: 800; line-height: 1; }
.rail-label { font-weight: 700; font-size: 13px; }
.rail-clear { background: var(--panel); border: 1px solid var(--line); align-items: center; padding: 0 14px; color: var(--muted); font-weight: 600; }
.rail-handled { background: var(--panel); border: 1px solid var(--line); align-items: center; padding: 0 14px; color: var(--text, inherit); font-weight: 600; } /* 1.54 */
.rail-clear-text { display: flex; align-items: center; gap: 10px; }
.sev-bg-critical { background: var(--sev-critical); } .sev-bg-major { background: var(--sev-major); } .sev-bg-minor { background: var(--sev-minor); }
.sev-bg-warning { background: var(--sev-warning); } .sev-bg-info { background: var(--sev-info); } .sev-bg-normal { background: var(--sev-normal); }
.live { align-self: center; font-size: 13px; font-weight: 600; color: var(--muted); display: flex; align-items: center; gap: 6px; white-space: nowrap; }
.live::before { content: ''; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); }
.live-live::before { background: var(--sev-normal); }
.live-offline { color: var(--danger); } .live-offline::before { background: var(--danger); }

/* ---------- severity badge: a distinct shape per level so colour is never the only cue ---------- */
.sev { display: inline-flex; align-items: center; gap: 7px; font-weight: 700; font-size: 13px; white-space: nowrap; }
.sev-glyph { width: 12px; height: 12px; flex: none; }
.sev-critical .sev-glyph { background: var(--sev-critical); clip-path: polygon(30% 0, 70% 0, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0 70%, 0 30%); }
.sev-major .sev-glyph { background: var(--sev-major); clip-path: polygon(50% 0, 100% 100%, 0 100%); }
.sev-minor .sev-glyph { background: var(--sev-minor); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.sev-warning .sev-glyph { background: var(--sev-warning); border-radius: 2px; transform: scale(.85); }
.sev-info .sev-glyph { background: var(--sev-info); border-radius: 50%; transform: scale(.85); }
.sev-normal .sev-glyph { background: var(--sev-normal); border-radius: 50%; box-shadow: inset 0 0 0 3px var(--panel); outline: 2px solid var(--sev-normal); outline-offset: -2px; }

.status { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; white-space: nowrap; }
.status .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--muted); }
.status-up .dot { background: var(--sev-normal); }
.status-warning .dot { background: var(--sev-warning); border-radius: 2px; }
.status-down .dot { background: var(--sev-critical); clip-path: polygon(30% 0, 70% 0, 100% 30%, 100% 70%, 70% 100%, 30% 100%, 0 70%, 0 30%); border-radius: 0; }
.status-paused .dot { background: transparent; border: 2px solid var(--muted); }

/* ---------- page furniture ---------- */
.page-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.page-head .sub { display: flex; flex-wrap: wrap; gap: 6px 16px; margin-top: 8px; color: var(--muted); align-items: center; }
.head-actions, .btn-row { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.crumbs { font-size: 13px; color: var(--muted); margin-bottom: 6px; }
.lead { max-width: 70ch; }
.updated { font-size: 13px; padding-top: 8px; }
.panel { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; margin-bottom: 16px; min-width: 0; }
.panel-head { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 12px; flex-wrap: wrap; }
.panel-head a { font-size: 14px; font-weight: 600; }
.last-result { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; margin-bottom: 16px; }
.notes-text { max-width: 80ch; white-space: pre-wrap; }
.error-box, .form-error { color: var(--danger); font-weight: 600; }
.ok-text { color: var(--ok); font-weight: 600; }
.empty { text-align: center; padding: 48px 16px; color: var(--muted); }
.empty h3 { color: var(--text); font-size: 17px; margin: 0 0 6px; }
.empty .btn { margin-top: 12px; }
.empty-chart { padding: 40px 0; text-align: center; }

/* ---------- buttons & forms ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 6px; font: 600 14px var(--font); padding: 8px 14px; border-radius: var(--radius-sm);
  border: 1px solid var(--line); background: var(--btn-bg); color: var(--text); cursor: pointer; white-space: nowrap; text-decoration: none !important; }
.btn:hover { background: var(--btn-hover); }
.btn.primary { background: var(--primary-bg); color: var(--primary-text); border-color: var(--primary-bg); }
.btn.primary:hover { filter: brightness(.92); }
.btn.danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn.danger-text { color: var(--danger); }
.btn.small { padding: 4px 10px; font-size: 13px; }
.btn.block { width: 100%; padding: 11px; }
.btn:disabled { opacity: .45; cursor: default; }
.icon-btn { display: inline-flex; align-items: center; justify-content: center; width: 34px; height: 34px; border-radius: var(--radius-sm); border: 0; background: transparent; color: var(--muted); cursor: pointer; font-size: 20px; }
.icon-btn:hover { background: var(--panel-2); color: var(--text); }
.icon-btn[aria-pressed="true"] { color: var(--text); background: var(--panel-2); }
.link-btn { background: none; border: 0; color: var(--link); font: 600 14px var(--font); padding: 6px 0; cursor: pointer; }
.link-btn:disabled { color: var(--muted); cursor: default; }
input, select, textarea { font: 15px var(--font); color: var(--text); background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 10px; width: 100%; min-width: 0; }
textarea { resize: vertical; }
input:focus, select:focus, textarea:focus { border-color: var(--focus); outline: 1px solid var(--focus); }
input[type=checkbox] { width: 17px; height: 17px; accent-color: var(--text); padding: 0; }
/* 1.63: radio buttons too (they took the text-box width: 100%, squeezing their labels to nothing in Add user) */
input[type=radio] { width: 17px; height: 17px; accent-color: var(--text); padding: 0; flex: none; }
.field { display: flex; flex-direction: column; gap: 5px; min-width: 0; }
.field.wide { grid-column: 1 / -1; }
.field label { font-size: 13px; font-weight: 700; color: var(--muted); }
.help { color: var(--muted); font-size: 12.5px; }
.check { display: flex; align-items: center; gap: 9px; font-weight: 600; cursor: pointer; flex-wrap: wrap; align-self: end; padding: 8px 0; }
.check .help { flex-basis: 100%; padding-left: 26px; }
.check-row { display: flex; flex-wrap: wrap; gap: 4px 24px; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 14px 16px; margin-bottom: 14px; }
fieldset { border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px 6px; margin: 0 0 14px; min-width: 0; }
legend { font-weight: 700; padding: 0 6px; }
.help-box { background: var(--panel-2); border-radius: var(--radius-sm); padding: 10px 12px; }
.spacer { flex: 1; }

/* ---------- toolbar, tabs ---------- */
.toolbar { display: flex; gap: 10px; align-items: flex-end; flex-wrap: wrap; margin-bottom: 12px; }
.tool { display: flex; flex-direction: column; gap: 4px; font-size: 12.5px; font-weight: 700; color: var(--muted); }
.tool select { width: auto; max-width: 190px; }
.tool.grow { flex: 1; min-width: 200px; }
.tabs { display: flex; gap: 2px; border-bottom: 1px solid var(--line); margin-bottom: 14px; overflow-x: auto; }
.tab { background: none; border: 0; border-bottom: 3px solid transparent; color: var(--muted); font: 600 14px var(--font); padding: 9px 14px; cursor: pointer; white-space: nowrap; display: flex; gap: 8px; align-items: center; }
.tab:hover { color: var(--text); }
.tab[aria-selected="true"] { color: var(--text); border-bottom-color: var(--text); }
.tab-x { color: var(--muted); font-size: 16px; line-height: 1; padding: 0 2px; }
.tab-x:hover { color: var(--danger); }
.tab-add { color: var(--link); }
.seg { display: inline-flex; border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; }
.seg button { background: var(--btn-bg); color: var(--muted); border: 0; border-right: 1px solid var(--line); padding: 5px 11px; font: 600 13px var(--font); cursor: pointer; }
.seg button:last-child { border-right: 0; }
.seg button[aria-pressed="true"] { background: var(--primary-bg); color: var(--primary-text); }

/* ---------- tables ---------- */
.table-wrap { overflow-x: auto; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.panel .table-wrap, .admin-body .table-wrap { border: 0; }
table.grid { width: 100%; border-collapse: collapse; font-size: 14px; }
.grid th { text-align: left; font-size: 12.5px; font-weight: 700; color: var(--muted); padding: 9px 12px; border-bottom: 1px solid var(--line); white-space: nowrap; position: sticky; top: 0; background: var(--panel); }
.grid td { padding: 8px 12px; border-bottom: 1px solid var(--grid); vertical-align: middle; }
.grid tbody tr:last-child td { border-bottom: 0; }
.grid tr.clickable, .grid tr.ev { cursor: pointer; }
.grid tbody tr:hover td { background: var(--panel-2); }
.grid .num, .mini .num { text-align: right; }
.grid td.msg { max-width: 560px; }
.grid td.cb, .grid th.cb { width: 34px; padding-right: 0; }
.grid td.actions { text-align: right; white-space: nowrap; }
.grid td.actions .btn { margin-left: 4px; }
.table-foot { padding: 8px 12px; margin: 0; }
table.mini { width: 100%; border-collapse: collapse; font-size: 14px; }
.mini td { padding: 7px 4px; border-bottom: 1px solid var(--grid); }
.mini tr:last-child td { border-bottom: 0; }
.mini tr.clickable { cursor: pointer; }
.mini tr.clickable:hover td { background: var(--panel-2); }
.inline { display: inline-flex; align-items: center; gap: 4px; }

/* alarm rows carry a severity edge */
tr.ev td:first-child { box-shadow: inset 4px 0 0 var(--edge, transparent); }
.edge-critical { --edge: var(--sev-critical); } .edge-major { --edge: var(--sev-major); } .edge-minor { --edge: var(--sev-minor); }
.edge-warning { --edge: var(--sev-warning); } .edge-info { --edge: var(--sev-info); } .edge-normal { --edge: var(--sev-normal); }
tr.ev.dim td { color: var(--muted); }
tr.ev.dim .sev { opacity: .8; }
tr.ev.current td { background: var(--panel-2); }
tr.ev.fresh td { animation: fresh 2.5s ease-out; }
@keyframes fresh { from { background: color-mix(in srgb, var(--edge) 22%, transparent); } to { background: transparent; } }
td.state { font-size: 13px; }

.alarm-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.alarm-item { display: flex; gap: 12px; align-items: flex-start; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--panel-2); box-shadow: inset 4px 0 0 var(--edge); cursor: pointer; }
.alarm-item:hover { filter: brightness(1.06); }
.alarm-item .sev { min-width: 82px; padding-top: 1px; }
.alarm-msg { font-weight: 600; }
.alarm-text { min-width: 0; }
.alarm-list.compact .alarm-item { padding: 7px 10px; }

/* ---------- alarm browser ---------- */
.alarms-layout { display: grid; grid-template-columns: minmax(0, 1fr); gap: 16px; }
.alarms-main { min-width: 0; }
.with-detail .opt { display: none; }
.alarms-layout.with-detail { grid-template-columns: minmax(0, 1fr) 360px; }
.bulk .spacer { flex: 1; }
.bulk { display: flex; gap: 8px; align-items: center; margin-bottom: 10px; flex-wrap: wrap; min-height: 36px; }
.bulk select { width: auto; }
.detail { display: none; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; align-self: start; position: sticky; top: 0; max-height: calc(100vh - 120px); overflow: auto; }
.with-detail .detail { display: block; }
.detail-head { display: flex; justify-content: space-between; align-items: center; }
.detail-title { font-size: 18px; margin: 8px 0 12px; line-height: 1.3; }
.detail-actions { display: flex; gap: 8px; margin-bottom: 14px; }
.kvs { margin: 0; display: grid; gap: 8px; }
.kvs.cols { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 14px 20px; }
.kv dt { font-size: 12.5px; font-weight: 700; color: var(--muted); }
.kv dd { margin: 2px 0 0; overflow-wrap: anywhere; }
.notes { list-style: none; padding: 0; margin: 0 0 10px; display: flex; flex-direction: column; gap: 10px; }
.note-form { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }

/* ---------- dashboard ---------- */
.dash { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(300px, 1fr); gap: 16px; }
.dash > .panel, .dash-side > .panel { margin: 0; }
.dash-side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.attention .alarm-list { max-height: 460px; overflow: auto; }
.health-figures { display: flex; gap: 32px; margin-bottom: 12px; }
.health-figures > div { display: flex; flex-direction: column; }
.big-num { font-size: 34px; font-weight: 800; line-height: 1.05; }
.health-bar { display: flex; height: 12px; border-radius: 6px; overflow: hidden; gap: 2px; margin-bottom: 10px; }
.hb-up { background: var(--sev-normal); } .hb-warning { background: var(--sev-warning); } .hb-down { background: var(--sev-critical); } .hb-unknown { background: var(--line); }
.legend-row { list-style: none; padding: 0; margin: 0; display: flex; gap: 18px; flex-wrap: wrap; }
.poller-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 8px; }
.poller-list li { display: grid; grid-template-columns: 90px 1fr auto; gap: 8px; align-items: center; }
.days { font-weight: 700; white-space: nowrap; }
.days-critical { color: var(--sev-critical); } .days-major { color: var(--sev-major); } .days-warning { color: var(--sev-minor); } .days-ok { color: var(--muted); }

/* ---------- monitor ---------- */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(120px, 1fr)); gap: 1px; background: var(--line); border: 1px solid var(--line); border-radius: var(--radius-sm); overflow: hidden; margin-bottom: 14px; }
.stat { background: var(--panel); padding: 10px 14px; }
.stat-v { font-size: 20px; font-weight: 800; }
.stat-l { font-size: 12.5px; color: var(--muted); font-weight: 600; }
.chart { width: 100%; }
.tbar { display: flex; height: 14px; border-radius: 4px; overflow: hidden; gap: 2px; margin: 4px 0 8px; }
.tbar-0 { background: var(--t1); } .tbar-1 { background: var(--t2); } .tbar-2 { background: var(--t3); } .tbar-3 { background: var(--t4); } .tbar-4 { background: var(--t5); }
.tlegend { list-style: none; padding: 0; margin: 0 0 6px; display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; }
.tlegend li { display: flex; align-items: center; gap: 6px; }
.sw { width: 10px; height: 10px; border-radius: 2px; display: inline-block; }
.problems { color: var(--sev-major); margin: 12px 0 0; }
.problem { color: var(--sev-major); font-size: 13px; }
.screenshot { max-width: 100%; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.versions-layout { display: grid; grid-template-columns: 200px 1fr; gap: 16px; }
.versions { list-style: none; padding: 0; margin: 0; max-height: 420px; overflow: auto; }
.diff-body { font-family: var(--mono); font-size: 13px; max-height: 420px; overflow: auto; background: var(--panel-2); border-radius: var(--radius-sm); padding: 8px; }
.d-add { color: var(--ok); white-space: pre-wrap; } .d-del { color: var(--danger); white-space: pre-wrap; text-decoration: line-through; text-decoration-color: color-mix(in srgb, var(--danger) 50%, transparent); }
.d-same { color: var(--muted); font-style: italic; padding: 2px 0; }

/* ---------- certificates ---------- */
.cert-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin-bottom: 16px; }
.cert-band { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; display: flex; flex-direction: column; box-shadow: inset 4px 0 0 var(--b); }
.band-critical { --b: var(--sev-critical); } .band-warning { --b: var(--sev-minor); } .band-ok { --b: var(--sev-normal); }

/* ---------- modal & toast ---------- */
.modal-backdrop { position: fixed; inset: 0; background: rgba(8, 11, 15, .6); display: flex; align-items: flex-start; justify-content: center; padding: 6vh 16px; z-index: 50; overflow: auto; }
.modal { background: var(--panel); border: 1px solid var(--line); border-radius: 12px; box-shadow: var(--shadow); width: 100%; max-width: 520px; display: flex; flex-direction: column; max-height: 88vh; }
.modal.wide { max-width: 820px; }
.modal-head { display: flex; justify-content: space-between; align-items: center; padding: 14px 18px; border-bottom: 1px solid var(--line); }
.modal-body { padding: 16px 18px; overflow: auto; }
.modal-foot { display: flex; gap: 8px; justify-content: flex-end; padding: 12px 18px; border-top: 1px solid var(--line); align-items: center; }
.toasts { position: fixed; bottom: 18px; right: 18px; display: flex; flex-direction: column; gap: 8px; z-index: 100; }
.toast { background: var(--primary-bg); color: var(--primary-text); padding: 10px 16px; border-radius: var(--radius-sm); box-shadow: var(--shadow); font-weight: 600; max-width: 420px; transition: opacity .3s; }
.toast-error { background: var(--danger); color: #fff; }
.toast.leaving { opacity: 0; }
.test-result { margin-top: 6px; }
.test-result .result-head { display: flex; gap: 12px; align-items: center; padding: 10px 12px; background: var(--panel-2); border-radius: var(--radius-sm); margin-bottom: 8px; }
.transcript, .cmd { font-family: var(--mono); font-size: 12.5px; background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px; overflow: auto; max-height: 300px; white-space: pre-wrap; word-break: break-all; }
.monitor-form fieldset .form-grid { margin-bottom: 8px; }

/* ---------- admin ---------- */
.admin-layout { display: grid; grid-template-columns: 210px 1fr; gap: 20px; align-items: start; }
.admin-nav { display: flex; flex-direction: column; gap: 2px; position: sticky; top: 0; }
.admin-nav a { padding: 8px 12px; border-radius: var(--radius-sm); color: var(--muted); font-weight: 600; }
.admin-nav a:hover { background: var(--panel); color: var(--text); text-decoration: none; }
.admin-nav a.active { background: var(--panel); color: var(--text); box-shadow: inset 3px 0 0 var(--accent, var(--text)); }
.admin-body { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 16px 18px; min-width: 0; }
.admin-body > form { max-width: 920px; }

/* ---------- login ---------- */
.login { min-height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 24px 16px; gap: 24px; }
.login-brand { display: flex; align-items: center; gap: 14px; }
.login-brand h1 { font-size: 30px; }
.login-brand p { margin: 0; color: var(--muted); }
.login-card { width: 100%; max-width: 390px; background: var(--panel); border: 1px solid var(--line); border-radius: 12px; padding: 24px; box-shadow: var(--shadow); }
.login-card form { display: flex; flex-direction: column; gap: 14px; }
.login-card h2 { margin-bottom: 4px; }
.login-card .qr { align-self: center; background: #fff; padding: 8px; border-radius: 8px; }
.or { text-align: center; color: var(--muted); margin: 14px 0; font-size: 13px; }
.codes { columns: 2; font-size: 15px; padding-left: 22px; }
.secret code { word-break: break-all; }
details summary { cursor: pointer; color: var(--link); font-weight: 600; font-size: 14px; }

/* ---------- responsive ---------- */
@media (max-width: 1100px) {
  .dash { grid-template-columns: 1fr; }
  .alarms-layout.with-detail { grid-template-columns: 1fr; }
  .detail { position: static; max-height: none; }
}
@media (max-width: 860px) {
  .app { grid-template-columns: 64px 1fr; }
  .sidebar { padding: 12px 6px; }
  .brand span:last-child, .nav-link span { display: none; }
  .nav-link { justify-content: center; padding: 10px; }
  .nav-tools { flex-direction: column; align-items: center; padding: 0; }
  .admin-layout { grid-template-columns: 1fr; }
  .admin-nav { flex-direction: row; overflow-x: auto; position: static; }
  .admin-nav a { white-space: nowrap; }
  .versions-layout { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .app { grid-template-columns: 1fr; grid-template-rows: auto 1fr; height: auto; min-height: 100vh; }
  .content { height: auto; }
  .sidebar { flex-direction: row; border-right: 0; border-bottom: 1px solid var(--line); padding: 6px 8px; overflow-x: auto; align-items: center; }
  .brand { padding: 4px 8px; }
  .nav-links { flex-direction: row; }
  .nav-foot { flex-direction: row; margin: 0 0 0 auto; border: 0; padding: 0; }
  .nav-tools { flex-direction: row; }
  .topbar { padding: 10px 16px; flex-wrap: wrap; }
  .rail-seg { min-width: 64px; padding: 0 10px; }
  .rail-label { display: none; }
  .main { padding: 16px 16px 40px; overflow: visible; }
  .cert-summary { grid-template-columns: 1fr; }
  .toolbar .tool { flex: 1 1 40%; }
  .tool select { max-width: none; width: 100%; }
  .grid .opt { display: none; }
  .dash { display: flex; flex-direction: column; }
  h1 { font-size: 22px; }
}

/* ---------- customers (tenants) ---------- */
.tenant-pick { display: flex; flex-direction: column; justify-content: center; gap: 2px; font-size: 11.5px; font-weight: 700; color: var(--muted); min-width: 170px; max-width: 240px; }
.tenant-switch { padding: 7px 10px; font-weight: 700; background: var(--panel); }
.tenant-tag { display: inline-block; font-size: 11.5px; font-weight: 800; letter-spacing: .02em; padding: 1px 6px; border-radius: 4px; background: var(--panel-2); border: 1px solid var(--line); color: var(--text); white-space: nowrap; vertical-align: 1px; }
.tenant-tag.unknown { color: var(--muted); border-style: dashed; }
.cust { display: flex; align-items: center; gap: 8px; }
.sub-line { margin: 6px 0 0; }
.down-text { color: var(--sev-critical); font-weight: 700; }
.table-wrap.flat { border: 0; }
table.overview td { padding-top: 11px; padding-bottom: 11px; }
.rail-cell { width: 34%; min-width: 180px; }
.mini-rail { display: flex; height: 24px; border-radius: 5px; overflow: hidden; gap: 2px; }
.mini-rail span { display: flex; align-items: center; padding: 0 7px; font-size: 12.5px; font-weight: 800; color: #12161b; min-width: 24px; }
.mini-clear { display: inline-flex; align-items: center; gap: 8px; color: var(--muted); font-weight: 600; font-size: 13px; }
.feeds { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
.feeds .panel { margin: 0; }
.feed .alarm-list { max-height: 560px; overflow: auto; }
.access-table { max-width: 520px; }
.access-table td { padding: 5px 4px; }
.access-table select { max-width: 200px; }

/* ---------- IPAM ---------- */
.mono-title { font-family: var(--mono); letter-spacing: -.01em; }
.ip-used, .ip-c-used .sw { background: var(--t1); }
.ip-reserved, .ip-c-reserved .sw { background: var(--t3); }
.ip-dhcp, .ip-c-dhcp .sw { background: var(--t2); }
.ip-offline, .ip-c-offline .sw { background: var(--t4); }
.ip-gateway { background: var(--text); }
.ip-free { background: transparent; box-shadow: inset 0 0 0 1px var(--line); }
.util { display: flex; align-items: center; gap: 10px; min-width: 220px; }
.util-bar { flex: 1; display: flex; height: 10px; border-radius: 5px; overflow: hidden; background: var(--grid); max-width: 220px; }
.util-bar span { height: 100%; }
.util-text { font-size: 13px; white-space: nowrap; }
.ip-chip { display: inline-flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; white-space: nowrap; }
.ip-chip .sw { width: 10px; height: 10px; border-radius: 2px; }
.ip-stats .stat-v { display: flex; align-items: center; gap: 6px; }
.ip-stats .sw { width: 12px; height: 12px; border-radius: 3px; }
.ip-map { display: grid; grid-template-columns: repeat(auto-fill, minmax(34px, 1fr)); gap: 3px; margin-bottom: 10px; }
.ip-cell { height: 26px; border: 0; border-radius: 4px; font: 600 11px var(--mono); color: var(--muted); cursor: pointer; padding: 0; }
.ip-cell.ip-used, .ip-cell.ip-reserved, .ip-cell.ip-dhcp, .ip-cell.ip-gateway { color: #fff; }
.ip-cell.ip-offline { color: #1b1408; }
:root[data-theme="dark"] .ip-cell.ip-gateway { color: var(--bg); }
.ip-cell:hover { outline: 2px solid var(--focus); outline-offset: 1px; }
@media (max-width: 1100px) { .feeds { grid-template-columns: 1fr; } }
@media (max-width: 600px) { .tenant-pick { min-width: 0; max-width: none; flex-basis: 100%; } .rail-cell { min-width: 120px; } }

/* branding */
.brand-logo { width: 26px; height: 26px; object-fit: contain; border-radius: 4px; flex: none; }
.brand-logo.big { width: 48px; height: 48px; border-radius: 8px; }
.brand span[data-brand-name] { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.brand-preview { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; padding: 14px; border: 1px solid var(--line); border-radius: 10px; background: var(--panel-2, var(--panel)); }
.brand-preview .sample-side { display: flex; align-items: center; gap: 10px; font-weight: 800; font-size: 18px; padding: 8px 12px; border-radius: 8px; background: var(--sidebar, var(--panel)); }
.brand-preview .sample-tab { display: flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 8px 8px 0 0; background: var(--bg); border: 1px solid var(--line); border-bottom: none; font-size: 13px; max-width: 240px; }
.brand-preview .sample-tab img { width: 16px; height: 16px; }
.brand-preview .sample-btn { background: var(--sample-accent); color: var(--sample-accent-text); padding: 6px 14px; border-radius: var(--radius-sm, 6px); font-weight: 600; font-size: 13px; }
.brand-preview .sample-side img { width: 26px; height: 26px; object-fit: contain; }
.img-pick { display: grid; grid-template-columns: 72px 1fr; gap: 14px; align-items: center; }
.img-pick .thumb { width: 72px; height: 72px; border-radius: 10px; border: 1px dashed var(--line); display: grid; place-items: center; background: repeating-conic-gradient(rgba(128,128,128,.12) 0 25%, transparent 0 50%) 0 0 / 12px 12px; }
.img-pick .thumb img { max-width: 60px; max-height: 60px; object-fit: contain; }
.help-tip { display: inline-grid; place-items: center; width: 18px; height: 18px; border-radius: 50%; border: 1px solid var(--muted); color: var(--muted); font-size: 11px; font-weight: 700; cursor: help; margin-left: 6px; vertical-align: middle; position: relative; background: none; padding: 0; }
.help-tip:hover::after, .help-tip:focus::after { content: attr(data-tip); position: absolute; left: 50%; bottom: calc(100% + 8px); transform: translateX(-50%); width: max-content; max-width: 280px; white-space: pre-line; text-align: left; font-weight: 400; font-size: 12.5px; line-height: 1.45; color: var(--text); background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; box-shadow: 0 6px 24px rgba(0,0,0,.25); z-index: 50; }
.badge-system { font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 999px; background: color-mix(in srgb, var(--link) 18%, transparent); color: var(--link); margin-left: 6px; }
p.note { padding: 10px 12px; border-radius: var(--radius-sm); background: var(--panel-2); border-left: 3px solid var(--link); margin: 0 0 12px; font-size: 14px; }
.inline-actions { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.form-actions { display: flex; gap: 10px; justify-content: flex-end; margin-top: 16px; }
.error-text { color: var(--danger) !important; }

/* monitor definitions */
.sub-head { font-size: 15px; margin: 18px 0 8px; }
.type-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 10px; margin-bottom: 18px; }
.type-card { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 12px; background: var(--panel-2); display: flex; flex-direction: column; gap: 6px; }
.type-card.active { border-color: var(--link); box-shadow: 0 0 0 1px var(--link) inset; }
.type-card p { margin: 0; flex: 1; }
.type-card-head { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.field .static { padding: 9px 0; color: var(--muted); }
details.overrides { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 14px; margin-top: 14px; }
details.overrides[open] summary { margin-bottom: 8px; }
.mon-body section + section { margin-top: 6px; }
.status-container .dot { background: transparent; border: 2px dashed var(--link); border-radius: 3px; }

/* ---------- 1.3: menus, view modes, tree ---------- */
.menu { position: absolute; z-index: 60; min-width: 190px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: 0 10px 30px rgba(0,0,0,.28); padding: 4px; display: flex; flex-direction: column; }
.menu button { text-align: left; background: none; border: 0; color: var(--text); padding: 8px 12px; border-radius: 6px; font: inherit; font-size: 14px; cursor: pointer; }
.menu button:hover, .menu button:focus { background: var(--panel-2); outline: none; }
.menu-sep { height: 1px; background: var(--line); margin: 4px 0; }
.menu-head { font-size: 11.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); padding: 10px 12px 4px; }
.menu-sub { font-size: 12px; font-weight: 600; color: var(--muted); padding: 8px 12px 2px; }
.menu-head + .menu-sub { padding-top: 2px; }
.menu button:has(.menu-d) { display: flex; flex-direction: column; gap: 1px; padding: 6px 12px; }
.menu .menu-d { font-size: 12px; color: var(--muted); }
.menu-filter { margin: 2px 2px 6px; padding: 6px 8px; font: inherit; font-size: 13px; }

/* Simple view hides advanced inputs and columns; a form can reveal them with "Show advanced options". */
body.view-simple .adv-col { display: none !important; }
body.view-simple .adv-nav { display: none !important; }
body.view-simple .adv-scope:not(.show-adv) .adv-only { display: none !important; }
body.view-advanced .simple-only, .adv-scope.show-adv .simple-only { display: none !important; }
.adv-toggle { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 6px 0 2px; }
body.view-advanced .adv-toggle { display: none; }
.chip-note { display: inline-flex; align-items: center; gap: 6px; font-size: 12.5px; padding: 3px 10px; border-radius: 999px; background: color-mix(in srgb, var(--link) 14%, transparent); color: var(--text); }
.linkish { background: none; border: 0; padding: 0; color: var(--link); font: inherit; font-weight: 600; cursor: pointer; }
.linkish:hover { text-decoration: underline; }

/* view switch */
.view-switch { display: inline-flex; border: 1px solid var(--line); border-radius: 999px; padding: 2px; background: var(--panel-2); }
.view-switch button { border: 0; background: none; color: var(--muted); font: inherit; font-size: 12.5px; font-weight: 700; padding: 4px 11px; border-radius: 999px; cursor: pointer; }
.view-switch button[aria-pressed=true] { background: var(--panel); color: var(--text); box-shadow: 0 1px 3px rgba(0,0,0,.2); }

/* tree grid */
.tree-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 10px; }
.chips { display: flex; gap: 6px; flex-wrap: wrap; }
.chips button { border: 1px solid var(--line); background: var(--panel); color: var(--text); border-radius: 999px; padding: 5px 12px; font: inherit; font-size: 13px; font-weight: 600; cursor: pointer; }
.chips button[aria-pressed=true] { background: var(--text); color: var(--bg); border-color: var(--text); }
.chips button .n { opacity: .7; margin-left: 5px; font-weight: 500; }
.tree { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); overflow: hidden; }
.tree.virtual { overflow-y: auto; max-height: calc(100vh - 250px); }
.tree-head, .tree-row { display: grid; grid-template-columns: var(--tree-cols); align-items: center; column-gap: 14px; padding: 0 14px; }
.tree-head { font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .03em; height: 38px; border-bottom: 1px solid var(--line); background: var(--panel-2); position: sticky; top: 0; z-index: 2; }
.tree-row { min-height: 46px; border-bottom: 1px solid var(--line); cursor: pointer; position: relative; }
.tree-row:last-child { border-bottom: 0; }
.tree-row:hover, .tree-row:focus-within { background: var(--panel-2); }
.tree-row:focus { outline: 2px solid var(--focus); outline-offset: -2px; }
.tree-row.lvl-group { background: color-mix(in srgb, var(--panel-2) 70%, transparent); min-height: 40px; font-weight: 700; }
.tree-row.lvl-customer { background: var(--panel-2); min-height: 42px; font-weight: 800; }
.tree-row.lvl-site { background: color-mix(in srgb, var(--panel-2) 85%, transparent); min-height: 41px; font-weight: 750; }
.tree-row.lvl-site svg { vertical-align: -2px; color: var(--muted); }
.tree-row.lvl-monitor { min-height: 40px; font-size: 14px; }
.tree-row.lvl-monitor .first { padding-left: 34px; }
.tree-row.highlight { box-shadow: inset 3px 0 0 var(--link); }
.tree-row .first { display: flex; align-items: center; gap: 8px; min-width: 0; }
.tree-row .first .nm { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tree-row .sub { color: var(--muted); font-size: 12.5px; font-weight: 500; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tree-row .fail { color: var(--sev-critical); font-size: 12.5px; font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tree-row .warnline { color: var(--sev-warning); }
.twisty { width: 24px; height: 24px; display: inline-grid; place-items: center; border: 0; background: none; color: var(--muted); border-radius: 6px; cursor: pointer; flex: none; padding: 0; }
.twisty svg { transition: transform .12s; }
.twisty[aria-expanded=true] svg { transform: rotate(90deg); }
.twisty.blank { visibility: hidden; }
.tree-row .cell { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 14px; }
.tree-row .cell.num { text-align: right; font-variant-numeric: tabular-nums; }
.row-actions { display: flex; gap: 2px; justify-content: flex-end; opacity: 0; transition: opacity .1s; }
.tree-row:hover .row-actions, .tree-row:focus-within .row-actions, .tree-row:focus .row-actions { opacity: 1; }
@media (hover: none) { .row-actions { opacity: 1; } }
.icon-btn.sm { width: 30px; height: 30px; }
.rollup { display: inline-flex; gap: 10px; font-size: 12.5px; font-weight: 600; color: var(--muted); }
.rollup .d { color: var(--sev-critical); } .rollup .w { color: var(--sev-warning); } .rollup .u { color: var(--sev-normal); }
.custom-mark { font-size: 11px; font-weight: 700; padding: 1px 7px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.spark { width: 90px; height: 22px; display: block; }
.bulk-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; padding: 10px 14px; margin-bottom: 10px; border-radius: var(--radius-sm); background: color-mix(in srgb, var(--link) 12%, var(--panel)); border: 1px solid var(--line); }
.sel-box { width: 18px; height: 18px; }
.tree-empty { padding: 28px; text-align: center; color: var(--muted); }
.topbar .view-switch { align-self: center; flex: none; }
.tree-tools { align-items: flex-end; } .tree-tools .icon-btn { margin-bottom: 4px; }
body.view-simple .adv-scope.show-thr .thr-sec { display: block !important; }
body.view-simple .adv-scope.show-thr .thr-summary { display: none !important; }
.thr-summary { margin: 4px 0 8px; padding: 10px 12px; border: 1px dashed var(--line); border-radius: var(--radius-sm); font-size: 14px; }
.start-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 4px 14px; max-height: 220px; overflow: auto; padding: 8px; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.start-list label { display: flex; gap: 8px; align-items: center; font-size: 14px; }
body.view-simple .nav-group.show-more .adv-nav { display: block !important; }
.admin-nav .nav-group { margin-top: 12px; display: flex; flex-direction: column; }
.admin-nav .nav-group-label { display: flex; align-items: center; gap: 4px; width: 100%; border: 0; background: transparent; cursor: pointer; text-align: left;
  font: inherit; font-size: 11.5px; font-weight: 800; letter-spacing: .05em; text-transform: uppercase; color: var(--muted); padding: 6px 8px; border-radius: var(--radius-sm); }
.admin-nav .nav-group-label:hover { color: var(--text); background: var(--panel); }
.admin-nav .nav-group-label .chev { display: inline-flex; transition: transform .15s; transform: rotate(90deg); }
.admin-nav .nav-group-label .nav-group-current { font-weight: 400; color: var(--muted); text-transform: none; letter-spacing: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; } /* 1.75 */
.admin-nav .nav-group.folded .nav-group-label .chev { transform: rotate(0deg); }
.admin-nav .nav-group.folded .nav-links { display: none; }
.admin-nav .nav-links { display: flex; flex-direction: column; gap: 2px; }
.admin-nav .nav-top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.admin-nav .nav-top a { flex: 1; }
.admin-nav .fold-all { font-size: 12.5px; white-space: nowrap; padding: 4px 6px; }
@media (prefers-reduced-motion: reduce) { .admin-nav .nav-group-label .chev { transition: none; } }
.admin-nav .more-link { text-align: left; padding: 6px 12px; font-size: 13px; }
.settings-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.settings-card { border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); padding: 16px 18px; }
.settings-card.warn { border-color: color-mix(in srgb, var(--sev-warning) 60%, var(--line)); }
.settings-card h2 { font-size: 17px; margin: 0 0 6px; }
.settings-card p { margin: 0 0 4px; font-size: 13.5px; }
.settings-card p.bad { color: var(--sev-major); font-weight: 600; }
.settings-card ul { list-style: none; padding: 0; margin: 10px 0 0; display: flex; flex-direction: column; gap: 4px; }

/* ---------- 1.4: access rules, receivers, trap definitions, correlation ---------- */
.rule-add { display: grid; grid-template-columns: minmax(220px, 2fr) minmax(140px, 1fr) auto auto; gap: 8px; align-items: center; margin: 10px 0 4px; }
.rule-add .help { grid-column: 1 / -1; }
.rule-add input, .rule-add select { min-width: 0; }
@media (max-width: 700px) { .rule-add { grid-template-columns: 1fr; } }
table.grid.rules td { vertical-align: top; }
.subrules { margin: 4px 0 12px 26px; }
.radio-list { display: flex; flex-direction: column; gap: 8px; margin: 4px 0 12px; }
.radio { display: flex; gap: 10px; align-items: flex-start; cursor: pointer; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); }
.radio:has(input:checked) { border-color: var(--text); background: var(--panel-2); }
.radio input[type=radio] { margin-top: 3px; width: auto; flex: none; padding: 0; }
.radio > span { display: flex; flex-direction: column; gap: 2px; }
.radio .help { color: var(--muted); }
.chips-inline { display: flex; gap: 4px; flex-wrap: wrap; }
.chip-note.warn { background: color-mix(in srgb, var(--sev-minor) 22%, transparent); }
.chip-note.bad { background: color-mix(in srgb, var(--danger) 22%, transparent); }
p.note.warn { border-left-color: var(--sev-minor); }
.callout { border: 1px solid var(--line); border-left: 3px solid var(--sev-major); border-radius: var(--radius-sm); padding: 10px 12px; margin: 12px 0; background: var(--panel-2); }
.callout p { margin: 0 0 8px; }
.corr { margin-top: 14px; }
.corr-list { margin: 0 0 8px; padding-left: 18px; display: flex; flex-direction: column; gap: 6px; font-size: 14px; }
.corr-list ul { margin: 4px 0 0; padding-left: 16px; }
.corr-history summary { cursor: pointer; font-weight: 600; font-size: 14px; margin: 6px 0; }
tr.group-row td { background: var(--panel-2); font-size: 12.5px; font-weight: 700; color: var(--muted); padding-top: 6px; padding-bottom: 6px; }
.grid tr.dim td { opacity: .6; }
.clamp { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 60ch; }
.mib-results { margin-top: 10px; max-height: 60vh; overflow: auto; }
.mib-results input[type=search], .modal-body > div > input[type=search] { width: 100%; }
table.v3 input, table.v3 select { width: 100%; min-width: 90px; }
.table-note { margin: 8px 12px; }
.poller-access h3 { margin: 18px 0 8px; font-size: 15px; }
.chips-inline .chip-note { white-space: nowrap; padding: 2px 8px; }
.panel .inline-actions input[type=file], .panel .inline-actions select { width: auto; flex: 1 1 220px; }

/* ---------- 1.5: sites, file previews, poller updates ---------- */
.site-group { margin-bottom: 18px; }
.site-group h3 { display: flex; align-items: center; gap: 12px; font-size: 15px; margin: 8px 0; }
.file-preview { margin: 14px 0 0; }
.file-preview img { max-width: 100%; max-height: 480px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: repeating-conic-gradient(var(--panel-2) 0 25%, var(--panel) 0 50%) 0 0 / 16px 16px; }
.chip-note.site-filter button { background: none; border: 0; color: inherit; cursor: pointer; font: inherit; padding: 0 0 0 4px; }
.site-card dd a { margin-left: 6px; }
.break { overflow-wrap: anywhere; }
.version-cell { min-width: 150px; }
.version-cell .inline-actions { margin-top: 4px; }
td.actions.stack { display: flex; flex-direction: column; gap: 4px; align-items: stretch; }
.site-card dd a { margin-left: 0; }

/* ---------- maps ---------- */
.maps-list td:first-child a { font-weight: 600; }
.map-shell { display: flex; flex-direction: column; height: calc(100vh - 160px); min-height: 460px; }
.map-tools[hidden] { display: none; }
.map-shell.fullscreen, .map-shell.fs-fallback { height: 100vh; padding: 12px 16px; background: var(--bg); }
.map-shell.fs-fallback { position: fixed; inset: 0; z-index: 50; }
.map-shell .btn-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.map-summary { margin-right: 8px; }
.map-sum-down { color: var(--sev-critical); font-weight: 700; }
.map-sum-warn { color: var(--sev-minor); font-weight: 700; }
.map-tools { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; padding: 8px; margin-bottom: 8px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); }
.map-tools .btn.active { background: var(--primary-bg); color: var(--primary-text); }
.map-tools .sep { width: 1px; align-self: stretch; background: var(--line); margin: 0 4px; }
.map-tools .grow { flex: 1; }
.map-body { flex: 1; display: grid; grid-template-columns: 1fr 280px; gap: 12px; min-height: 0; }
.map-shell.fullscreen .map-body { grid-template-columns: 1fr; }
.map-shell.fullscreen .map-side { display: none; }
.map-wrap { position: relative; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; min-height: 300px;
  background-image: radial-gradient(var(--grid) 1px, transparent 1px); background-size: 20px 20px; }
.map-shell.editing .map-wrap { outline: 2px dashed var(--line); outline-offset: -2px; }
.map-svg { width: 100%; height: 100%; display: block; touch-action: none; cursor: grab; user-select: none; }
.map-svg:active { cursor: grabbing; }
.map-svg.linking .map-node { cursor: crosshair; }
.map-side { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; overflow: auto; }
.map-side h2 { margin-bottom: 8px; word-break: break-word; }
.map-side .field { margin-bottom: 10px; }
.map-down { list-style: none; padding: 0; margin: 0 0 12px; }
.map-down li { padding: 6px 0; border-bottom: 1px solid var(--line); }
.nb-list { padding-left: 16px; margin: 0; }
.map-node { cursor: pointer; }
.map-node .box { fill: var(--panel-2); stroke: var(--line); stroke-width: 1.5; }
.map-node .box.st-down { stroke: var(--sev-critical); stroke-width: 3; }
.map-node .box.st-warning { stroke: var(--sev-minor); stroke-width: 2.5; }
.map-node .box.st-paused, .map-node .box.st-unknown { stroke-dasharray: 5 4; }
.map-node .box-stack { fill: var(--line); }
.map-node .box.net { fill: color-mix(in srgb, var(--focus) 8%, var(--panel-2)); stroke: color-mix(in srgb, var(--focus) 45%, var(--line)); stroke-dasharray: none; }
.map-node.kind-vcvm .box.st-paused { opacity: .75; }
.map-link.vc .wire { stroke-dasharray: 2 4; }
.map-node.selected .box { stroke: var(--focus); stroke-width: 3; }
.map-node.linking .box { stroke: var(--focus); stroke-dasharray: 4 3; stroke-width: 3; }
.map-node:focus { outline: none; }
.map-node:focus-visible .box { stroke: var(--focus); stroke-width: 3; }
.map-node .node-name { fill: var(--text); font: 600 13px var(--font); }
.map-node .node-sub { fill: var(--muted); font: 11px var(--mono); }
.map-st.st-up { fill: var(--sev-normal); }
.map-st.st-warning { fill: var(--sev-minor); }
.map-st.st-down { fill: var(--sev-critical); }
.map-st.hollow { fill: none; stroke: var(--muted); stroke-width: 2; }
.alarm-dot { stroke: var(--panel); stroke-width: 2; }
.alarm-dot.sev-2 { fill: var(--sev-warning); } .alarm-dot.sev-3 { fill: var(--sev-minor); } .alarm-dot.sev-4 { fill: var(--sev-major); } .alarm-dot.sev-5 { fill: var(--sev-critical); }
.alarm-count { fill: #111; font: 700 10px var(--font); pointer-events: none; }
.free-label { fill: var(--text); font: 600 15px var(--font); }
.map-node.kind-label.selected .free-label { fill: var(--focus); }
.map-link { cursor: pointer; }
.map-link .wire { stroke: var(--muted); stroke-width: 2.5; }
.map-link.disc .wire { stroke: var(--t5); }
.map-link .hit { stroke: transparent; stroke-width: 12; fill: none; } /* 1.62: a 12-point band to hover and click */
.map-link.warm .wire { stroke: var(--sev-warning); stroke-width: 3.5; }
.map-link.hot .wire { stroke: var(--sev-major); stroke-width: 4.5; }
.map-link.down .wire { stroke: var(--sev-critical); stroke-width: 4; stroke-dasharray: 8 5; }
.map-link.selected .wire { stroke: var(--focus); }
.map-link .link-label { fill: var(--text); font: 600 11px var(--font); paint-order: stroke; stroke: var(--panel); stroke-width: 4px; }
.map-link .if-label, .map-marks .if-label { fill: var(--muted); font: 10px var(--mono); paint-order: stroke; stroke: var(--panel); stroke-width: 3px; }
.map-bg { opacity: .85; }
.pick-list { max-height: 50vh; overflow: auto; margin: 10px 0; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 6px; }
.pick-row { display: block; padding: 4px 6px; cursor: pointer; }
.pick-row:hover { background: var(--btn-hover); }
@media (max-width: 900px) { .map-body { grid-template-columns: 1fr; } .map-side { max-height: 40vh; } }

/* ---------- traffic ---------- */
.traffic-tools { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 6px; }
.traffic-tools select { max-width: 420px; }
.seg { display: inline-flex; gap: 4px; flex-wrap: wrap; }
.seg .btn.active { background: var(--primary-bg); color: var(--primary-text); }
.exp-info { margin-bottom: 10px; }
.traffic-chart { height: 280px; }
.traffic-chart.small-chart { height: 180px; }
.traffic-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(480px, 100%), 1fr)); gap: 12px; margin: 12px 0; }
.traffic-grid .wide { grid-column: 1 / -1; }
.traffic-grid .panel { margin: 0; }
.top-table td { white-space: nowrap; }
.top-table .bar-cell { width: 22%; min-width: 60px; }
.tbar { display: block; height: 8px; background: var(--grid); border-radius: 4px; overflow: hidden; }
.tbar span { display: block; height: 100%; background: var(--t1); }
.top-panel { min-width: 0; overflow-x: auto; }
@media (max-width: 600px) { .traffic-grid { grid-template-columns: minmax(0, 1fr); } .top-table .bar-cell { display: none; } }
.login-alt { display: grid; gap: 8px; }
a.btn.block { display: block; text-align: center; text-decoration: none; }
.passkey-list { list-style: none; padding: 0; margin: 0 0 12px; }
.passkey-list li { display: flex; gap: 10px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); flex-wrap: wrap; }
.passkey-list li .grow { flex: 1; min-width: 160px; }
.map-rows { display: grid; gap: 6px; margin: 6px 0 10px; }
.map-row { display: grid; grid-template-columns: minmax(160px, 2fr) minmax(140px, 1.5fr) minmax(110px, 1fr) auto; gap: 6px; align-items: center; }
@media (max-width: 700px) { .map-row { grid-template-columns: 1fr 1fr; } }
.filter-chips { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; margin: 10px 0 0; }
.filter-chips .chip { font: inherit; font-size: 13px; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line); background: var(--panel-2); color: var(--text); cursor: pointer; }
.top-table .linkish.mono { font-family: var(--mono); font-weight: 400; }

/* storage */
.swatch { display: inline-block; width: 12px; height: 12px; border-radius: 3px; vertical-align: -1px; }
.plan-preview { margin-top: 12px; }
.stat-v.bad { color: var(--sev-major); }
.tag { font-family: 'Atkinson Hyperlegible Next', system-ui, sans-serif; letter-spacing: 0; display: inline-block; margin-left: 8px; padding: 1px 7px; border-radius: 999px; font-size: 11.5px; font-weight: 700; background: var(--panel-2); border: 1px solid var(--line); color: var(--muted); vertical-align: 1px; }
/* IPAM sub-pages, customer groups, VLAN status */
.subtabs { display: flex; gap: 4px; border-bottom: 1px solid var(--line); margin: 0 0 14px; overflow-x: auto; scrollbar-width: none; }
.subtabs a { white-space: nowrap; }
@media (max-width: 600px) { .subtabs a { padding: 8px 10px; } }
.subtabs a { padding: 8px 14px; color: var(--muted); font-weight: 700; text-decoration: none; border-bottom: 2px solid transparent; margin-bottom: -1px; }
.subtabs a.active { color: var(--text); border-bottom-color: var(--link); }
.subtabs a:hover { color: var(--text); }
tr.group-row th { background: var(--panel-2); text-align: left; font-size: 13px; font-weight: 800; padding: 8px 12px; }
.vchip { font-size: 12.5px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line); }
.vchip.v-active { color: var(--text); } .vchip.v-reserved { color: var(--muted); } .vchip.v-deprecated { color: var(--muted); text-decoration: line-through; }
.discovered { border-left: 3px solid var(--link); }
/* device types */
.dt-cell { display: inline-flex; align-items: center; gap: 6px; }
.dt-name { display: flex; gap: 10px; align-items: center; }
.dt-badge { display: inline-flex; width: 34px; height: 34px; align-items: center; justify-content: center; border-radius: 8px; background: var(--panel-2); border: 1px solid var(--line); flex: none; }
.icon-pick { display: flex; flex-wrap: wrap; gap: 6px; }
.icon-pick button { width: 40px; height: 40px; border-radius: 8px; border: 1px solid var(--line); background: var(--panel-2); display: inline-flex; align-items: center; justify-content: center; cursor: pointer; }
.icon-pick button.on { outline: 2px solid var(--link); outline-offset: 1px; }
.color-pick { display: flex; gap: 8px; }
.color-pick button { width: 28px; height: 28px; border-radius: 50%; border: 2px solid var(--panel); cursor: pointer; }
.color-pick button.on { outline: 2px solid var(--text); outline-offset: 2px; }
.map-node .type-bar { stroke: none; }
.vm-section { margin-top: 14px; } .vm-section input[type=search] { margin: 4px 0 8px; max-width: 360px; }
tr.muted-row td { color: var(--muted); }
/* traffic filters and applications */
.ip-search { display: inline-flex; gap: 6px; align-items: center; }
.ip-search input[type=search] { min-width: 230px; }
.filter-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; padding: 10px 14px; margin: 10px 0 14px; border-radius: var(--radius-sm); border: 1px dashed var(--line); font-size: 13.5px; }
.filter-bar.active { border: 2px solid var(--link); background: color-mix(in srgb, var(--link) 12%, var(--panel)); }
.filter-bar.active strong { margin-right: 4px; }
.fchip { display: inline-flex; align-items: center; gap: 6px; padding: 3px 4px 3px 10px; border-radius: 999px; background: var(--panel); border: 1px solid var(--link); font-weight: 600; }
.fchip .fk { color: var(--muted); font-weight: 700; font-size: 12px; text-transform: uppercase; letter-spacing: .03em; }
.fchip button { border: 0; background: transparent; color: var(--text); font-size: 16px; line-height: 1; width: 24px; height: 24px; border-radius: 50%; cursor: pointer; }
.fchip button:hover, .fchip button:focus-visible { background: var(--panel-2); }
.app-chart { height: 220px; }
.app-legend { list-style: none; display: flex; flex-wrap: wrap; gap: 6px 16px; padding: 0; margin: 8px 0 0; font-size: 13px; }
.app-legend li { display: inline-flex; align-items: center; gap: 6px; }
.app-legend .sw { width: 12px; height: 12px; border-radius: 3px; display: inline-block; }
.ex-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 8px; }
.alerting-field .al-policies { margin-top: 6px; }
.probe-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 8px; margin-bottom: 12px; }
.probe { display: flex; gap: 8px; align-items: flex-start; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel-2); cursor: pointer; }
.probe span { display: flex; flex-direction: column; gap: 2px; }
.probe small { font-size: 12px; }
.inline { display: flex; gap: 6px; } .inline input { flex: 1; }
.probe-custom { margin: 4px 0 14px; } .probe-custom[open] > summary { margin-bottom: 10px; }
/* vSphere panel */
.vsphere-panel .subtabs a .count { margin-left: 6px; font-weight: 600; color: var(--muted); font-size: .85em; }
.usebar { display: inline-block; width: 54px; height: 7px; border-radius: 4px; background: var(--line); vertical-align: middle; overflow: hidden; }
.usebar-fill { display: block; height: 100%; border-radius: 4px; }
.usebar-fill.ok { background: var(--sev-normal, #3fb950); } .usebar-fill.warn { background: var(--sev-minor); } .usebar-fill.crit { background: var(--sev-critical); }
.vm-flags { display: flex; flex-direction: column; gap: 2px; white-space: nowrap; }
.vm-flag { display: flex; align-items: center; gap: 6px; font-size: 12.5px; cursor: pointer; }
.vm-flag input { margin: 0; }
.vc-settings h3 { margin: 16px 0 6px; }
.warn-text { color: var(--sev-minor); }
.check-col { display: flex; flex-direction: column; gap: 0; }
.check-col .check { align-self: start; padding: 6px 0; }
.check-col.indent { padding-left: 26px; }
/* poller install dialog */
.cmd-block { display: flex; gap: 8px; align-items: flex-start; margin: 6px 0 10px; }
.cmd-block pre.cmd { flex: 1; margin: 0; white-space: pre-wrap; word-break: break-all; }
label.check.inline { display: inline-flex; padding: 4px 0; align-self: center; font-weight: 500; }
.check-row .small.muted { align-self: center; }
.deploy-pick { max-width: 520px; margin-bottom: 8px; }
.deploy-pick select { width: 100%; }
.dl-table th { text-align: left; padding: 6px 16px 6px 0; white-space: nowrap; vertical-align: middle; }
.dl-row { display: flex; flex-wrap: wrap; gap: 6px; padding: 3px 0; }
/* VM detail */
.vm-name { font-weight: 700; color: var(--text); text-align: left; }
.vm-name:hover { color: var(--link); }
.note-mark { color: var(--muted); }
.vm-detail h3 { margin: 18px 0 8px; }
.vm-head { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; }
.vm-head .btn { margin-left: auto; }
.vm-figs { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; margin: 10px 0; }
.vm-fig { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; background: var(--panel-2); }
.vm-fig-val { font-size: 22px; font-weight: 700; margin: 2px 0 4px; }
.vm-fig .usebar { width: 100%; margin: 2px 0 4px; }
.vm-charts { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.vm-chart { height: 200px; }
.vm-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 900px) { .vm-charts, .vm-cols { grid-template-columns: 1fr; } }
.panel-head.slim { margin: 14px 0 6px; } .panel-head.slim h3 { margin: 0; }
.seg { display: inline-flex; gap: 4px; } .seg .btn.active { background: var(--focus); color: #fff; border-color: var(--focus); }
.thr-in { display: flex; gap: 6px; align-items: center; } .thr-in input { width: 90px; }
.thr-table td { vertical-align: middle; }
.switch-label { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; font-size: 13px; }
.alarm-list.compact li { padding: 4px 0; font-size: 13px; }
tr.clickable { cursor: pointer; }
/* integrations */
.integ-panel select { max-width: 220px; }
.integ-note { margin: 4px 0 10px; display: flex; flex-wrap: wrap; gap: 2px; align-items: center; }
.indent { padding-left: 26px; }
.subtabs a .count { margin-left: 6px; font-weight: 600; color: var(--muted); font-size: .85em; }
.thr-table td:first-child .check { white-space: nowrap; flex-wrap: nowrap; }
.thr-in span { white-space: nowrap; }

/* 1.11: IP info and traffic */
.row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 8px 0; }
.test-out { margin-top: 8px; }
.test-out pre { max-height: 320px; overflow: auto; background: var(--panel-2); padding: 8px; border-radius: 6px; }
.if-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 10px; }
.if-card { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; background: var(--panel); min-width: 0; }
.if-card.active { border-color: var(--accent, var(--t1)); box-shadow: 0 0 0 1px var(--accent, var(--t1)) inset; }
.if-head { display: flex; align-items: center; gap: 6px; }
.if-head .tag { margin-left: auto; }
.if-descr { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.if-chart { height: 90px; margin-top: 4px; }
.group-chip { font-weight: 600; }
.traffic-tools .switch-label { white-space: nowrap; }
.error { color: var(--danger); }
.addr-cell { min-width: 0; }
.addr-sub { font-size: 11.5px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 260px; }

.th-sort { all: unset; cursor: pointer; display: inline-flex; gap: 4px; align-items: center; font: inherit; color: inherit; }
.th-sort:hover, .th-sort:focus-visible { color: var(--text); text-decoration: underline; }
.th-sort:focus-visible { outline: 2px solid var(--t1); outline-offset: 2px; }
.sort-ind { font-size: 9px; min-width: 8px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.top-table th.sortable .sr-only + .sort-ind { margin-left: 0; }
.top-table .asn-col { width: 1%; }
.top-table .loc-col { max-width: 120px; overflow: hidden; text-overflow: ellipsis; }
.top-table .loc-col .loc-cell { max-width: 120px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: inline-block; vertical-align: bottom; }
.top-table .addr-col { max-width: 200px; }
.top-table .addr-name { max-width: 190px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; display: inline-block; vertical-align: bottom; }
.top-table .bar-cell { width: auto; min-width: 50px; }
.kv-table th { text-align: left; width: 34%; color: var(--muted); font-weight: 600; white-space: nowrap; }
.inline-switch { display: inline-flex; vertical-align: middle; }
.top-table th, .top-table td { padding-left: 6px; padding-right: 6px; }
.top-table .addr-col { max-width: 150px; }
.top-table .addr-name { max-width: 150px; }
.top-table .loc-col, .top-table .loc-col .loc-cell { max-width: 105px; }
.top-table .bar-cell { min-width: 36px; width: 12%; }
.top-table .num { white-space: nowrap; }
.top-panel { overflow-x: hidden; }
.col-picker { position: relative; }
.col-picker > summary { list-style: none; cursor: pointer; }
.col-picker > summary::-webkit-details-marker { display: none; }
.col-menu { position: absolute; right: 0; top: calc(100% + 4px); z-index: 20; background: var(--panel); border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; box-shadow: 0 6px 24px rgba(0,0,0,.18); display: flex; flex-direction: column; gap: 4px; min-width: 170px; }
.col-menu label { display: flex; align-items: center; gap: 6px; font-size: 13px; white-space: nowrap; cursor: pointer; }
.top-table .name-col { max-width: 150px; overflow: hidden; text-overflow: ellipsis; }

/* a panel that slides out over the right of the page (Traffic › Lookup log) */
.drawer { position: fixed; top: 0; right: 0; bottom: 0; width: min(760px, 100vw); z-index: 60; background: var(--panel); border-left: 1px solid var(--line);
  box-shadow: -8px 0 24px rgba(0,0,0,.18); display: flex; flex-direction: column; animation: drawer-in .18s ease-out; }
@keyframes drawer-in { from { transform: translateX(40px); opacity: 0; } to { transform: none; opacity: 1; } }
.drawer-head { display: flex; align-items: center; gap: 10px; padding: 14px 16px; border-bottom: 1px solid var(--line); }
.drawer-head h2 { margin: 0; font-size: 16px; }
.drawer-head .icon-btn { margin-left: auto; font-size: 20px; }
.drawer-tools { display: flex; flex-wrap: wrap; gap: 8px; padding: 10px 16px; border-bottom: 1px solid var(--line); align-items: center; }
.drawer-tools input[type=search] { flex: 1 1 180px; min-width: 0; }
.drawer-body { overflow: auto; padding: 12px 16px 24px; flex: 1; }
.drawer-sum h3 { margin: 0 0 6px; font-size: 13px; }
.drawer-sum li { margin: 4px 0; }
ul.plain { list-style: none; padding: 0; margin: 0 0 12px; }
.lookup-log td.break, .break { word-break: break-word; }
button.linkish.bad { color: var(--danger); }
.pn-table input[type=text] { width: 100%; }
.pn-table .num-in { width: 7em; }
.pn-base { margin-top: 14px; }
p.bad, td.bad { color: var(--danger); }
/* Logs */
.log-area { font-size: 11px; font-weight: 700; padding: 2px 7px; border-radius: 999px; background: color-mix(in srgb, var(--danger) 14%, transparent); color: var(--danger); }
.log-area.lv-warning { background: color-mix(in srgb, var(--sev-warning) 20%, transparent); color: var(--text); }
.log-table td.break { max-width: 640px; }
.custom-range { display: inline-flex; gap: 6px; align-items: center; }
.panel-note { padding: 12px 14px 4px; margin: 0; }
/* guest disks with their alert settings take the full width; the network goes underneath */
.vm-cols:has(.disk-table) { grid-template-columns: 1fr; }
.disk-table .thr-in input { width: 70px; }
.va-test-out { margin-top: 6px; }
.va-test-out p { margin: 4px 0; }
p.ok-text { color: var(--ok); }
.field .row { display: flex; gap: 8px; }
.field .row input { flex: 1; min-width: 0; }
.form-grid > p.wide { grid-column: 1 / -1; margin: 0; }
.va-body { grid-column: 1 / -1; }

/* 1.13: show a secret while typing it; interface picker; detail tables; monitor packages; interface groups */
.secret-wrap { position: relative; display: block; flex: 0 0 auto; min-width: 0; }
.row > .secret-wrap { flex: 1 1 auto; }
.secret-wrap > input { display: block; width: 100%; padding-right: 40px; }
.secret-wrap > .reveal { position: absolute; right: 4px; top: 50%; transform: translateY(-50%); display: inline-flex; align-items: center; justify-content: center; width: 32px; height: 30px; border: 0; background: transparent; color: var(--muted); border-radius: var(--radius-sm); cursor: pointer; padding: 0; }
.secret-wrap > .reveal:hover, .secret-wrap > .reveal[aria-pressed=true] { color: var(--text); background: var(--panel); }
.secret-wrap > .reveal:focus-visible { outline: 2px solid var(--focus); }
.secret-wrap > .reveal[hidden] { display: none; }
.reveal-icon { display: inline-flex; }
.reveal-icon svg { fill: currentColor; }
.if-picked { color: var(--text); }
.pick-table { max-height: 55vh; overflow: auto; margin-top: 8px; }
tr.clickable { cursor: pointer; }
tr.clickable:hover td, tr.clickable:focus td { background: var(--panel-2); }
.choice-list { max-height: 50vh; overflow: auto; margin: 8px 0; gap: 6px; }
.pkg-list { columns: 2; margin: 6px 0 12px; padding-left: 18px; }
.if-card.if-group { border-style: dashed; }
.if-head .linkish.small { margin-left: auto; font-size: 12px; }
/* 1.14: UniFi sites */
tr.muted-row td { color: var(--muted); }
.integ-alarms h3 { margin: 16px 0 6px; }
.unifi-sites { margin-top: 12px; }
.unifi-sites .table-wrap { max-height: 50vh; overflow: auto; }
/* 1.16: Disconnected (may be offline): grey, never red */
.status-offline .dot { background: var(--muted); opacity: .7; }
.status-offline { color: var(--muted); }
.hb-offline { background: var(--muted); opacity: .55; }
.rollup .o { color: var(--muted); }
.map-node .box.st-offline { stroke: var(--muted); stroke-dasharray: 2 4; opacity: .8; }
.unifi-sites tr.group-row td { background: var(--panel-2, rgba(127,127,127,.06)); }
.unifi-sites td.indent-cell { padding-left: 1.6rem; }

/* 1.16 NAS Storage panel: chassis with bays, pools, volumes */
.nas-panel h3 { margin: 18px 0 8px; font-size: 14px; }
.nas-top { display: flex; flex-wrap: wrap; gap: 18px; align-items: flex-start; }
.nas-chassis-col { flex: 1 1 340px; min-width: 0; }
.nas-detail { flex: 1 1 300px; min-width: 0; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; background: var(--panel-2); }
.nas-detail .kvs { margin-top: 8px; }
.nas-detail-head { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.nas-encl + .nas-encl { margin-top: 12px; }
.nas-chassis { width: 100%; height: auto; display: block; }
.nas-chassis .nas-body { fill: var(--panel-2); stroke: var(--line); stroke-width: 2; }
.nas-chassis .nas-model { font-weight: 700; font-size: 14px; fill: var(--text); }
.nas-chassis .nas-sub { font-size: 11px; fill: var(--muted); }
.nas-chassis text { font-family: var(--font); }
.nas-chassis .bay { cursor: pointer; outline: none; }
.nas-chassis .bay .bay-tray { stroke-width: 2; transition: stroke-width .1s; }
.nas-chassis .bay.ok .bay-tray { fill: color-mix(in srgb, var(--ok) 13%, var(--panel)); stroke: color-mix(in srgb, var(--ok) 70%, var(--line)); }
.nas-chassis .bay.warn .bay-tray { fill: color-mix(in srgb, var(--sev-warning) 22%, var(--panel)); stroke: var(--sev-warning); }
.nas-chassis .bay.bad .bay-tray { fill: color-mix(in srgb, var(--danger) 22%, var(--panel)); stroke: var(--danger); }
.nas-chassis .bay.sel .bay-tray, .nas-chassis .bay:focus-visible .bay-tray { stroke-width: 4; stroke: var(--focus, var(--link)); }
.nas-chassis .bay:hover .bay-tray { stroke-width: 3; }
.nas-chassis .bay.empty { cursor: default; }
.nas-chassis .bay.empty rect { fill: transparent; stroke: var(--line); stroke-dasharray: 5 4; stroke-width: 1.5; }
.nas-chassis .bay-num { font-size: 12px; font-weight: 700; fill: var(--muted); }
.nas-chassis .bay-empty, .nas-chassis .bay-word, .nas-chassis .bay-pool { font-size: 10.5px; fill: var(--muted); }
.nas-chassis .bay-temp { font-size: 17px; font-weight: 700; fill: var(--text); }
.nas-chassis .bay-size, .nas-chassis .bay-m2 { font-size: 11px; fill: var(--text); }
.nas-chassis .bay-grip { stroke: var(--line); stroke-width: 2; stroke-linecap: round; }
.nas-chassis .bay.ok .bay-led { fill: var(--ok); }
.nas-chassis .bay.warn .bay-led { fill: var(--sev-warning); }
.nas-chassis .bay.bad .bay-led { fill: var(--danger); }
.nas-chassis .bay-alarm circle { fill: var(--danger); stroke: var(--panel); stroke-width: 2; }
.nas-chassis .bay-alarm text { fill: #fff; font-weight: 800; font-size: 13px; }
.nas-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; margin-right: 4px; vertical-align: -1px; background: var(--muted); }
.nas-dot.ok { background: var(--ok); } .nas-dot.warn { background: var(--sev-warning); } .nas-dot.bad { background: var(--danger); }
.nas-dot.none { background: transparent; border: 1.5px dashed var(--muted); box-sizing: border-box; }
.nas-bang { display: inline-grid; place-items: center; width: 14px; height: 14px; border-radius: 50%; background: var(--danger); color: #fff; font-weight: 800; font-size: 10px; margin-right: 4px; }
.nas-legend { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 8px; }
.nas-state { margin-left: auto; font-size: 12px; font-weight: 600; padding: 1px 8px; border-radius: 10px; background: var(--panel-2); }
.nas-state.ok { color: var(--ok); } .nas-state.warn { color: var(--sev-minor); background: color-mix(in srgb, var(--sev-warning) 18%, transparent); }
.nas-state.bad { color: var(--danger); background: color-mix(in srgb, var(--danger) 15%, transparent); }
.nas-alarms { margin: 8px 0 0; padding-left: 0; list-style: none; font-size: 13px; }
.nas-alarms a { color: var(--danger); }
.nas-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 10px; }
.nas-card { border: 1px solid var(--line); border-left: 4px solid var(--ok); border-radius: var(--radius); padding: 10px 12px; background: var(--panel); }
.nas-card.warn { border-left-color: var(--sev-warning); } .nas-card.bad { border-left-color: var(--danger); }
.nas-card p { margin: 6px 0 0; }
.nas-card-head, .nas-vol-head { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.nas-alarm-mark { color: var(--danger); font-weight: 700; font-size: 12px; margin-left: 6px; }
.nas-members { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.nas-chip { font: inherit; font-size: 12px; border: 1px solid var(--line); background: var(--panel-2); color: var(--text); border-radius: 12px; padding: 2px 9px; cursor: pointer; }
.nas-chip.bad { border-color: var(--danger); } .nas-chip.warn { border-color: var(--sev-warning); }
.nas-vols { display: grid; gap: 10px; }
.nas-vol-num { margin-left: auto; font-size: 12px; color: var(--muted); }
.nas-bar { height: 12px; border-radius: 6px; background: color-mix(in srgb, var(--muted) 18%, transparent); overflow: hidden; margin-top: 5px; }
.nas-fill { height: 100%; background: var(--ok); border-radius: 6px 0 0 6px; }
.nas-fill.warn { background: var(--sev-warning); } .nas-fill.bad { background: var(--danger); }
.nas-mons { display: flex; flex-wrap: wrap; gap: 4px 12px; margin-left: auto; }
.nas-mons a { text-decoration: none; color: var(--text); }
@media (max-width: 640px) { .nas-vol-num { margin-left: 0; width: 100%; } }
/* 1.17 remote pollers: token state under the name; actions in two columns */
td.poller-cell { min-width: 230px; }
td.poller-cell strong { white-space: nowrap; }
td.poller-actions { display: grid; grid-template-columns: repeat(2, auto); gap: 6px; justify-content: end; }
/* 1.18 System health */
.hl-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(190px, 1fr)); gap: 10px; margin-bottom: 12px; }
.hl-tile { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; }
.hl-label { font-size: 12px; color: var(--muted); font-weight: 600; }
.hl-value { font-size: 24px; font-weight: 700; margin: 2px 0; font-variant-numeric: tabular-nums; }
.hl-value.bad { color: var(--danger); }
.hl-sub { font-size: 12px; color: var(--muted); }
.hl-cores { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 14px; margin-bottom: 12px; }
.hl-corebars { display: flex; gap: 4px; align-items: flex-end; height: 70px; margin-top: 6px; overflow-x: auto; }
.hl-core { flex: 1 0 14px; max-width: 34px; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; align-items: center; background: color-mix(in srgb, var(--muted) 12%, transparent); border-radius: 4px 4px 0 0; position: relative; }
.hl-corefill { width: 100%; background: var(--c1); border-radius: 4px 4px 0 0; }
.hl-corefill.bad { background: var(--danger); }
.hl-core span { position: absolute; bottom: -16px; font-size: 10px; color: var(--muted); }
.hl-cores { padding-bottom: 22px; }
.hl-charts { display: grid; grid-template-columns: repeat(auto-fit, minmax(360px, 1fr)); gap: 12px; }
.hl-charts .panel { margin: 0; }
.hl-tables { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 12px; margin-top: 12px; }
@media (max-width: 640px) { .hl-charts { grid-template-columns: 1fr; } }
/* 1.18 adding a device */
.mon-picker .seg.wrap { display: flex; flex-wrap: wrap; margin: 4px 0 8px; }
.mon-picker .start-list.pkg label { display: flex; align-items: center; gap: 6px; }
.kind-tag { margin-left: auto; font-size: 11px; padding: 0 6px; border-radius: 8px; background: var(--panel-2); color: var(--muted); border: 1px solid var(--line); }
.cred-check .bad-callout { border-left: 4px solid var(--danger); background: color-mix(in srgb, var(--danger) 7%, var(--panel)); padding: 10px 12px; margin-top: 8px; border-radius: var(--radius-sm); }
.cred-check ol.steps { margin: 6px 0; padding-left: 18px; }
.cred-check .btn-row { margin-top: 6px; }
.detect-out { margin-top: 4px; }
.detect-out .ok-text { font-weight: 600; }
/* 1.19 Hardware panel: a server's front and back from its BMC */
.hw-top { display: flex; flex-wrap: wrap; gap: 18px; align-items: flex-start; }
.hw-views { flex: 3 1 520px; min-width: 0; }
.hw-view + .hw-view { margin-top: 10px; }
.hw-cap { margin: 0 0 3px 2px; text-transform: uppercase; letter-spacing: .06em; font-size: 11px; }
.hw-detail { flex: 1 1 260px; min-width: 0; border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 14px; background: var(--panel-2); }
.hw-detail-head { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-bottom: 6px; }
.hw-checked { margin: 8px 0 0; }
.hw-checked a { color: var(--text); }
.hw-head-actions { margin-left: auto; }
.hw-svg { width: 100%; height: auto; display: block; }
.hw-svg text { font-family: var(--font); }
.hw-body { fill: color-mix(in srgb, var(--panel-2) 70%, #000 30%); stroke: var(--line); stroke-width: 2; }
:root[data-theme="light"] .hw-body { fill: #3a4048; stroke: #2a2f36; }
.hw-face { fill: color-mix(in srgb, var(--panel-2) 85%, #000 15%); stroke: var(--line); }
:root[data-theme="light"] .hw-face { fill: #4a515a; stroke: #2a2f36; }
.hw-tiny { font-size: 9.5px; font-weight: 600; fill: #c8ced6; letter-spacing: .04em; }
.hw-tiny.muted { fill: #98a2ad; font-weight: 500; }
.hw-model { font-size: 11.5px; font-weight: 700; fill: #e8ecf0; }
.hw-note { font-size: 13px; fill: #aab3bd; }
.hw-vent { stroke: rgba(0,0,0,.35); stroke-width: 3; stroke-linecap: round; }
.hw-part { cursor: pointer; outline: none; }
.hw-part.sel > rect:first-of-type, .hw-part:focus-visible > rect:first-of-type, .hw-part.sel > circle:first-of-type, .hw-part:focus-visible > circle:first-of-type { stroke: var(--focus); stroke-width: 3.5; }
.hw-part:hover > rect:first-of-type, .hw-part:hover > circle:first-of-type { stroke-width: 3; }
.hw-part.alarm > rect:first-of-type, .hw-part.alarm > circle:first-of-type { stroke: var(--danger); stroke-width: 3; }
/* LEDs */
.hw-led { stroke: rgba(0,0,0,.5); stroke-width: 1; }
.hw-led.ok { fill: #3ddc72; filter: drop-shadow(0 0 3px #3ddc72); }
.hw-led.amber { fill: #ffb020; filter: drop-shadow(0 0 3px #ffb020); }
.hw-led.red { fill: #ff4d4d; filter: drop-shadow(0 0 3px #ff4d4d); }
.hw-led.blue { fill: #4aa3ff; filter: drop-shadow(0 0 4px #4aa3ff); }
.hw-led.dark { fill: #1c2026; }
.hw-led.blink { animation: hw-blink 1s steps(1) infinite; }
.hw-led.rebuild { animation: hw-rebuild 1.2s steps(1) infinite; fill: #3ddc72; }
@keyframes hw-blink { 50% { fill: #1c2026; filter: none; } }
@keyframes hw-rebuild { 50% { fill: #ffb020; filter: drop-shadow(0 0 3px #ffb020); } }
/* power button */
.hw-btn { fill: #2a2f36; stroke: #15181c; stroke-width: 2; }
.hw-btn-ring { fill: none; stroke-width: 3; stroke: #1c2026; }
.hw-power.ok .hw-btn-ring { stroke: #3ddc72; filter: drop-shadow(0 0 4px #3ddc72); }
.hw-power.off .hw-btn-ring { stroke: #ffb020; }
.hw-btn-sym { fill: none; stroke: #c8ced6; stroke-width: 2.2; stroke-linecap: round; }
.hw-power.ok .hw-btn-sym { stroke: #3ddc72; }
.hw-fault-box { fill: #1c2026; stroke: #15181c; }
.hw-fault-box.warn { fill: #ffb020; } .hw-fault-box.bad { fill: #ff4d4d; }
.hw-fault-txt { font-size: 8px; font-weight: 700; fill: #8a939d; }
.hw-fault-box.warn + .hw-fault-txt, .hw-fault-box.bad + .hw-fault-txt { fill: #15181c; }
/* drive carriers */
.hw-carrier { fill: #2b3037; stroke: #15181c; stroke-width: 1.5; }
.hw-bay.warn .hw-carrier { fill: color-mix(in srgb, #ffb020 22%, #2b3037); }
.hw-bay.bad .hw-carrier { fill: color-mix(in srgb, #ff4d4d 28%, #2b3037); }
.hw-bay.empty rect { fill: #23272d; stroke: #15181c; stroke-dasharray: 4 3; }
.hw-latch { fill: #3b414a; stroke: #15181c; }
.hw-grip { stroke: #1a1d22; stroke-width: 2.5; stroke-linecap: round; }
.hw-bay-num { font-size: 9px; font-weight: 700; fill: #9aa4af; }
.hw-bang circle { fill: var(--danger); stroke: #15181c; stroke-width: 1.5; }
.hw-bang text { fill: #fff; font-weight: 800; font-size: 11px; }
/* power supplies */
.hw-psu-box { fill: #2b3037; stroke: #15181c; stroke-width: 1.5; }
.hw-psu.bad .hw-psu-box { fill: color-mix(in srgb, #ff4d4d 22%, #2b3037); }
.hw-psu.warn .hw-psu-box { fill: color-mix(in srgb, #ffb020 18%, #2b3037); }
.hw-psu.none .hw-psu-box { fill: #23272d; stroke-dasharray: 4 3; }
.hw-handle { fill: #5a626c; }
.hw-inlet { fill: #15181c; }
.hw-psu-name { font-size: 12px; font-weight: 700; fill: #e8ecf0; }
.hw-psu-txt { font-size: 11px; fill: #c8ced6; }
.hw-psu-bad { font-size: 11px; font-weight: 800; fill: #ff6b6b; }
/* network ports */
.hw-port-box { fill: #15181c; stroke: #5a626c; stroke-width: 1.5; }
.hw-port.bmc .hw-port-box { stroke: #4aa3ff; }
.hw-port.down .hw-port-box { stroke: #ff4d4d; }
.hw-port-jack { fill: #2b3037; }
/* fans */
.hw-fan-ring { fill: #15181c; stroke: #5a626c; stroke-width: 1.5; }
.hw-fan.bad .hw-fan-ring { stroke: #ff4d4d; } .hw-fan.warn .hw-fan-ring { stroke: #ffb020; }
.hw-blade { fill: #5a626c; }
.hw-fan.bad .hw-blade { fill: #a04848; }
.hw-hub { fill: #8a939d; }
.hw-rotor.spin { animation: hw-spin 2s linear infinite; transform-box: fill-box; transform-origin: center; }
@keyframes hw-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .hw-rotor.spin, .hw-led.blink, .hw-led.rebuild { animation: none; } }
.hw-chips { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 10px; }
.hw-chips > .muted { min-width: 92px; }
.hw-chips .nas-chip { cursor: default; }
.hw-list { margin-top: 12px; }
.hw-list summary { cursor: pointer; color: var(--link); font-size: 13px; }
.hw-list table tr { cursor: pointer; }
@media (max-width: 640px) { .hw-chips > .muted { width: 100%; } .hw-head-actions { margin-left: 0; width: 100%; } }
.hw-hole { fill: #15181c; }
.hw-bay.empty rect { fill: #33383f; stroke: #15181c; stroke-dasharray: none; }
/* 1.20 Containers panel */
.ct-bar { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; margin-bottom: 10px; }
.ct-bar input[type=search] { width: 220px; flex: 1 1 180px; max-width: 320px; }
.ct-scroll { overflow-x: auto; }
.ct-table td { vertical-align: middle; }
.ct-table tr.group-row td { background: var(--panel-2); padding-top: 8px; }
.ct-table .ct-w { width: 52px; text-align: center; }
.ct-row { cursor: pointer; }
.ct-row:hover td, .ct-row.open td { background: color-mix(in srgb, var(--panel-2) 60%, transparent); }
.ct-row:focus-visible { outline: 2px solid var(--focus); outline-offset: -2px; }
.ct-meter { display: flex; align-items: center; gap: 6px; min-width: 120px; }
.ct-meter .nas-bar { flex: 1; margin-top: 0; height: 8px; min-width: 48px; }
.ct-meter span { font-size: 12px; white-space: nowrap; color: var(--muted); }
.ct-badge { display: inline-block; margin-left: 6px; font-size: 11px; font-weight: 700; padding: 0 6px; border-radius: 8px; background: var(--panel-2); border: 1px solid var(--line); }
.ct-badge.warn { background: color-mix(in srgb, var(--sev-warning) 25%, transparent); border-color: var(--sev-warning); }
.ct-detail-row td { background: var(--panel-2); }
.ct-detail { padding: 6px 4px 10px; }
.ct-chart-head { display: flex; align-items: center; gap: 10px; margin-top: 8px; }
.ct-charts { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 12px; margin-top: 6px; }
.ct-svg { width: 100%; height: 90px; display: block; }
.ct-line { fill: none; stroke: var(--link); stroke-width: 1.8; }
.ct-area { fill: color-mix(in srgb, var(--link) 15%, transparent); stroke: none; }
@media (max-width: 900px) { .ct-hide2 { display: none; } }
@media (max-width: 640px) { .ct-hide { display: none; } .ct-bar input[type=search] { max-width: none; } }
/* 1.21 Kubernetes panel */
.kb-nodes { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 10px; margin-bottom: 12px; }
.kb-node { border: 1px solid var(--line); border-radius: 8px; padding: 8px 10px; display: grid; gap: 4px; background: var(--panel); }
.kb-node.bad { border-color: var(--sev-critical, #c33); }
.kb-node.warn { border-color: var(--sev-warning); }
.kb-node .ct-meter { min-width: 0; }
/* 1.22: Detect's "What answered" */
.detect-found { margin-top: 6px; }
.detect-found summary { cursor: pointer; color: var(--muted); }
.detect-found table { margin-top: 4px; }
.detect-found td { vertical-align: top; }
.table-scroll { overflow-x: auto; }
/* 1.26: searchable select (customer pickers, DNS providers) */
.ssel { position: relative; min-width: 0; }
.ssel-native { display: none !important; }
.ssel-btn { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; min-width: 0; font: 15px var(--font); color: var(--text); background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 10px; text-align: left; cursor: pointer; }
.ssel-btn:disabled { opacity: .6; cursor: default; }
.ssel-btn svg { flex: none; transform: rotate(90deg); color: var(--muted); }
.ssel-label { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ssel.open .ssel-btn { border-color: var(--focus); outline: 1px solid var(--focus); }
.ssel-pop { position: absolute; z-index: 60; top: calc(100% + 4px); left: 0; min-width: 100%; width: max-content; max-width: min(420px, 92vw); background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: 0 8px 24px rgba(0,0,0,.25); padding: 6px; }
.ssel-q { margin-bottom: 6px; }
.ssel-list { list-style: none; margin: 0; padding: 0; max-height: 300px; overflow-y: auto; }
.ssel-opt { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 7px 10px; border-radius: 4px; cursor: pointer; font-weight: 500; color: var(--text); }
.ssel-opt.active, .ssel-opt:hover { background: var(--panel-2); }
.ssel-opt[aria-selected="true"] { font-weight: 700; }
.ssel-opt[aria-disabled="true"] { opacity: .5; cursor: default; }
.ssel-badge { font-size: 12px; font-weight: 700; color: var(--muted); border: 1px solid var(--line); border-radius: 4px; padding: 0 5px; }
.ssel-empty { padding: 7px 10px; color: var(--muted); }
.tenant-pick .ssel-btn { padding: 7px 10px; font-weight: 700; background: var(--panel); }
.cert-log { white-space: pre-wrap; font: 13px/1.5 var(--mono, ui-monospace, monospace); background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; margin-top: 12px; max-height: 260px; overflow: auto; }
.ssel-opt[hidden], .ssel-empty[hidden] { display: none; }

/* 1.28 alert rollups */
.status-unreachable .dot { background: transparent; border: 2px solid var(--muted); }
.status-unreachable { color: var(--muted); }
.fail.unreach { color: var(--muted); }
.badge { font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 999px; background: color-mix(in srgb, var(--muted) 16%, transparent); }
.badge.known { background: color-mix(in srgb, var(--link) 14%, transparent); color: var(--link); }
.badge.rolled { background: color-mix(in srgb, var(--muted) 16%, transparent); }
.badge.managed { background: color-mix(in srgb, var(--muted) 16%, transparent); font-weight: normal; } /* 1.53 */
td.msg .badge { margin-left: .5em; white-space: nowrap; }
.dep-chips { display: flex; flex-wrap: wrap; gap: .35em .9em; }
.dep-chip { display: inline-flex; align-items: center; gap: .2em; }
.dep-path { display: flex; flex-wrap: wrap; align-items: center; gap: .3em; }
.dep-picker .start-list { max-height: 14em; overflow: auto; }
.dep-picker input[type=search] { width: 100%; margin-bottom: .4em; }
.dep-two { display: grid; grid-template-columns: 1fr 1fr; gap: 1em; }
@media (max-width: 640px) { .dep-two { grid-template-columns: 1fr; } }
.setup-note { color: var(--warn, #a15c00); }
ul.rolled { margin: .3em 0 0; padding-left: 1.1em; max-height: 18em; overflow: auto; }
ul.plain { list-style: none; margin: 0; padding: 0; }
.callout.suggest ul.plain li { margin: .25em 0; }
.detail-actions { flex-wrap: wrap; }

/* 1.29 device merge */
.merge-preview { margin-top: 12px; }
.merge-preview h3 { margin: 14px 0 6px; }
table.merge-moves td.num { width: 3.5em; font-weight: 600; text-align: right; padding-right: 10px; vertical-align: top; }
ul.merge-notes { margin: 12px 0 0; padding-left: 1.1em; }
.callout.problem { border-left-color: var(--sev-critical, #c62828); }
.callout.problem ul { margin: 6px 0 0; padding-left: 1.1em; }
table.dups td { vertical-align: top; }

/* 1.30 network paths */
ul.plain.agents li { margin: 2px 0; }
table.paths td { vertical-align: top; }
table.paths tbody tr { cursor: pointer; }
.agent-chips { display: flex; flex-wrap: wrap; gap: 8px 22px; margin: 6px 0 14px; }
.agent-swatch { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 6px; vertical-align: 0; }
.period-bar .btn[aria-pressed="true"], .slider-row .btn[aria-pressed="true"] { background: var(--text); color: var(--bg); border-color: var(--text); }
.path-chart { height: 240px; }
.path-slider { display: grid; gap: 6px; margin-top: 8px; }
.path-slider input[type=range] { width: 100%; }
.slider-row { display: flex; align-items: center; gap: 8px; }
.moment { font-weight: 700; }
.path-layout { display: grid; grid-template-columns: 1fr; gap: 16px; }
.path-layout:has(.hop-detail:not(:empty)) { grid-template-columns: minmax(0, 1fr) 320px; }
@media (max-width: 900px) { .path-layout:has(.hop-detail:not(:empty)) { grid-template-columns: 1fr; } }
.svg-scroll { overflow-x: auto; }
.path-graph svg { display: block; }
.path-graph svg text { font: 12px var(--font); fill: var(--text); }
.path-graph svg text.ip { font-family: ui-monospace, monospace; font-size: 11.5px; }
.path-graph svg text.sub, .path-graph svg text.lat { fill: var(--muted); font-size: 11px; }
.path-graph svg text.loss { fill: var(--sev-critical); font-weight: 700; font-size: 11px; }
.path-graph svg text.alts { fill: var(--link); font-weight: 700; font-size: 11px; }
.path-graph svg text.agent { font-weight: 700; }
.path-graph g.node { cursor: pointer; }
.path-graph g.node.silent { cursor: default; }
.path-graph g.node.sel circle { stroke: var(--text); stroke-width: 3; }
.path-graph g.node:focus { outline: none; }
.path-graph g.node:focus circle { stroke: var(--link); stroke-width: 3; }
.as-legend { display: flex; flex-wrap: wrap; gap: 6px 18px; margin: 10px 0 4px; font-size: 13px; }
.lat-key { display: inline-block; width: 18px; height: 3px; margin: 0 4px 3px 8px; vertical-align: middle; }
.lat-key.ok { background: var(--ok); } .lat-key.minor { background: var(--sev-minor); } .lat-key.crit { background: var(--sev-critical); }
.compare { display: grid; grid-template-columns: 1fr; gap: 12px; }
.diff ul { padding-left: 1.1em; }
.hop-detail:empty { display: none; }
.hop-detail { border-left: 1px solid var(--line); padding-left: 16px; }
.hop-detail .detail-head { display: flex; justify-content: space-between; align-items: center; }
.path-graphs, .compare > div, .path-graph { min-width: 0; }
.compare { grid-template-columns: minmax(0, 1fr); }

/* ---------- 1.31: collapsible menu, resizable dialogs and panels, fixed settings menu ---------- */
.app { transition: grid-template-columns .15s ease; }
.app.nav-collapsed { grid-template-columns: 56px 1fr; }
.app.nav-collapsed .sidebar { padding: 14px 6px; }
.app.nav-collapsed .brand { justify-content: center; padding: 6px 0 14px; }
.app.nav-collapsed .brand span:last-child, .app.nav-collapsed .brand span[data-brand-name], .app.nav-collapsed .nav-link span { display: none; }
.app.nav-collapsed .nav-link { justify-content: center; padding: 10px; gap: 0; }
.app.nav-collapsed .nav-tools { flex-direction: column; align-items: center; padding: 0; }
.nav-tools .nav-toggle { margin-left: auto; }
.app.nav-collapsed .nav-tools .nav-toggle { margin-left: 0; }
@media (max-width: 860px) { .nav-tools .nav-toggle { display: none; } }
.nav-tip { position: fixed; z-index: 80; transform: translateY(-50%); background: var(--text); color: var(--bg); font-size: 13px; font-weight: 600; padding: 5px 9px; border-radius: 6px; white-space: nowrap; pointer-events: none; opacity: 0; transition: opacity .1s; box-shadow: var(--shadow); }
.nav-tip.show { opacity: 1; }

.modal { position: relative; min-width: min(360px, calc(100vw - 32px)); min-height: 0; }
.modal-body { flex: 1 1 auto; min-height: 0; }
.modal-head { cursor: move; user-select: none; gap: 8px; }
.modal-head h2 { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.modal-head-tools { display: flex; gap: 2px; flex: none; }
.modal.placed { position: fixed; margin: 0; }
.modal.max { position: fixed; inset: 8px !important; width: auto !important; height: auto !important; max-width: none !important; max-height: none !important; }
.modal.max .modal-grip { display: none; }
.modal.max .modal-head { cursor: default; }
.modal-grip { position: absolute; z-index: 2; }
.modal-grip.grip-e { top: 12px; right: -4px; width: 8px; bottom: 12px; cursor: ew-resize; }
.modal-grip.grip-s { left: 12px; bottom: -4px; height: 8px; right: 12px; cursor: ns-resize; }
.modal-grip.grip-se { right: -2px; bottom: -2px; width: 16px; height: 16px; cursor: nwse-resize;
  background: linear-gradient(135deg, transparent 0 55%, var(--line) 55% 62%, transparent 62% 72%, var(--line) 72% 79%, transparent 79%); border-bottom-right-radius: 12px; }
body.dragging, body.dragging * { user-select: none !important; }
@media (max-width: 600px) { .modal-grip, .modal-head-tools .modal-max { display: none; } .modal-head { cursor: default; } }

.alarms-layout.with-detail { grid-template-columns: minmax(0, 1fr) var(--panel-w, 360px); }
.alarms-layout > .panel-grip { display: none; position: absolute; top: 0; bottom: 0; right: calc(var(--panel-w, 360px) + 3px); width: 10px; cursor: ew-resize; border-radius: 4px; z-index: 3; }
.alarms-layout.with-detail > .panel-grip { display: block; }
.alarms-layout > .panel-grip::after { content: ''; position: sticky; display: block; top: 40vh; margin-left: 4px; height: 40px; width: 2px; border-radius: 2px; background: var(--line); }
.alarms-layout > .panel-grip:hover::after, .alarms-layout > .panel-grip:focus-visible::after, body.dragging .alarms-layout > .panel-grip::after { background: var(--muted); }
.alarms-layout { position: relative; }
.detail { overflow-wrap: anywhere; }
.detail pre, .detail code { white-space: pre-wrap; word-break: break-word; }
@media (max-width: 1100px) { .alarms-layout.with-detail > .panel-grip { display: none; } }

/* the settings menu stays in view and scrolls on its own */
.admin-nav { position: sticky; top: 0; max-height: calc(100vh - 84px); overflow-y: auto; overscroll-behavior: contain; padding-bottom: 12px; scrollbar-width: thin; }
@media (max-width: 860px) { .admin-nav { max-height: none; overflow-y: visible; } }
.nav-link { position: relative; }
.nav-badge { margin-left: auto; min-width: 20px; height: 20px; padding: 0 6px; border-radius: 10px; background: var(--sev-major); color: #fff; font-size: 12px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; }
.app.nav-collapsed .nav-link span.nav-badge, .nav-link span.nav-badge { overflow: visible; }
.app.nav-collapsed .nav-link span.nav-badge { display: block; position: absolute; top: 6px; right: 8px; min-width: 0; width: 9px; height: 9px; padding: 0; font-size: 0; border: 2px solid var(--panel); box-sizing: content-box; }
@media (max-width: 860px) { .nav-link span.nav-badge { display: block; position: absolute; top: 6px; right: 8px; min-width: 0; width: 9px; height: 9px; padding: 0; font-size: 0; border: 2px solid var(--panel); box-sizing: content-box; } }
.start-list .other-agents { grid-column: 1 / -1; border-top: 1px dashed var(--line); margin-top: 6px; padding-top: 8px; display: flex; flex-direction: column; gap: 6px; }
.start-list .agent-other { display: grid; grid-template-columns: minmax(0, 1fr) minmax(160px, 220px); gap: 10px; align-items: center; }
.start-list .agent-other input[type=text] { padding: 5px 8px; }
.start-list label.locked { opacity: .8; }

/* ===== 1.32: 3rd party plugins, Internet status, poller badge in Settings ===== */
.admin-nav a:has(.nav-badge) { display: flex; align-items: center; gap: 8px; }
.admin-nav a .nav-badge { height: 18px; min-width: 18px; font-size: 11px; }
.behind-note { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.plugin-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 12px; }
.plugin-card { display: flex; flex-direction: column; gap: 8px; margin: 0; }
.plugin-card h3 { margin: 0; font-size: 15px; }
.plugin-card p { margin: 0; }
.plugin-meta { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.plugin-card .inline-actions { margin-top: auto; }
.switch { position: relative; display: inline-block; width: 36px; height: 20px; flex: none; }
.switch input { opacity: 0; width: 0; height: 0; position: absolute; }
.switch .slider { position: absolute; inset: 0; border-radius: 10px; background: var(--line); cursor: pointer; transition: background .15s; }
.switch .slider::before { content: ''; position: absolute; width: 16px; height: 16px; left: 2px; top: 2px; border-radius: 50%; background: #fff; transition: transform .15s; }
.switch input:checked + .slider { background: var(--sev-normal); }
.switch input:checked + .slider::before { transform: translateX(16px); }
.switch input:focus-visible + .slider { outline: 2px solid var(--focus); outline-offset: 2px; }
.cust-pick { max-height: 180px; overflow: auto; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 6px 8px; display: grid; gap: 2px; background: var(--panel-2); }
.cust-pick.tall { max-height: 50vh; margin-top: 6px; }
.cust-pick-wrap input[type=search] { margin-bottom: 6px; width: 100%; }
.cat-list { display: grid; gap: 6px; }
.cat-row { display: flex; justify-content: space-between; gap: 12px; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--line); }
.isp-field .inline-actions { margin-top: 4px; align-items: center; }
.isp-field input[name=wan_addr] { width: 160px; }
.ext-state { display: inline-flex; align-items: center; gap: 6px; font-weight: 600; font-size: 13px; }
.ext-state .dot { width: 9px; height: 9px; border-radius: 50%; background: var(--muted); }
.ext-ok .dot { background: var(--sev-normal); } .ext-maintenance .dot { background: var(--sev-info); }
.ext-degraded .dot { background: var(--sev-warning); } .ext-partial .dot { background: var(--sev-major); } .ext-major .dot { background: var(--sev-critical); }
.ext-unavailable .dot { background: transparent; border: 2px solid var(--muted); box-sizing: border-box; }
.ext-group { margin-bottom: 12px; }
.ext-items { list-style: none; margin: 0; padding: 0; }
.ext-item { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-top: 1px solid var(--line); }
.ext-item:first-child { border-top: 0; }
.ext-main { min-width: 0; display: grid; gap: 3px; }
.ext-state-line { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ext-side { display: grid; gap: 6px; justify-items: end; align-content: start; flex: none; }
.ext-strip { display: flex; gap: 2px; }
.ext-day { width: 6px; height: 22px; border-radius: 2px; background: var(--sev-normal); opacity: .85; }
.ext-bg-maintenance { background: var(--sev-info); } .ext-bg-degraded { background: var(--sev-warning); }
.ext-bg-partial { background: var(--sev-major); } .ext-bg-major { background: var(--sev-critical); }
.ext-bg-unknown, .ext-bg-unavailable { background: var(--line); }
.ext-hist { list-style: none; padding: 0; margin: 0; display: grid; gap: 12px; }
.ext-update { margin-top: 4px; padding-left: 8px; border-left: 2px solid var(--line); white-space: pre-wrap; }
.ext-tile { display: block; color: inherit; text-decoration: none; }
.ext-tile:hover { text-decoration: none; border-color: var(--muted); }
.ext-tile-num { font-size: 30px; font-weight: 700; line-height: 1.1; }
.ext-tile-num.bad { color: var(--sev-major); } .ext-tile-num.ok { color: var(--sev-normal); }
@media (max-width: 700px) { .ext-item { flex-direction: column; } .ext-side { justify-items: start; } .ext-day { width: 5px; } }
.toolbar label.check.tool { display: inline-flex; flex-direction: row; align-items: center; gap: 6px; align-self: flex-end; padding-bottom: 9px; white-space: nowrap; }
.ext-banner { display: block; padding: 10px 16px; margin-bottom: 16px; color: inherit; text-decoration: none; border-left: 4px solid var(--sev-normal); }
.ext-banner.bad { border-left-color: var(--sev-major); }
.ext-banner:hover { text-decoration: none; }
.isp-panel { margin-bottom: 12px; border-left: 4px solid var(--sev-info); }
.isp-panel h3 { margin: 0; font-size: 15px; }
.isp-panel .inline-actions { align-items: center; flex-wrap: wrap; }
.ext-unavailable { color: var(--muted); font-weight: 500; }
.dock-choice { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 12px; margin: 8px 0; display: grid; gap: 6px; }
.dock-choice legend { font-weight: 600; padding: 0 4px; }
.dock-choice label.check { display: flex; flex-direction: row; flex-wrap: nowrap; align-items: flex-start; gap: 8px; text-align: left; }
.dock-choice label.check input[type=radio] { width: auto; flex: none; margin: 3px 0 0; }
.dock-choice label.check > span { display: block; flex: 1; min-width: 0; }

/* ===== 1.33: Add device picker, poller addresses, alert notes ===== */
.add-picker { display: grid; gap: 4px; }
.add-picker > .form-grid { margin-bottom: 4px; }
.add-sets { display: grid; gap: 8px; }
.add-modes { display: flex; gap: 20px; flex-wrap: wrap; }
.add-modes label.check { display: inline-flex; flex-direction: row; align-items: center; gap: 6px; }
.add-set { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 12px; background: var(--panel-2); }
.add-set.on { border-color: var(--muted); background: transparent; }
.add-set-head { display: flex; flex-direction: row; align-items: center; gap: 8px; cursor: pointer; }
.add-set-head input { width: auto; margin: 0; }
.add-set-head .chip-note { margin-left: 6px; }
.add-set .start-list { margin: 8px 0 4px 24px; }
.add-cred { margin: 6px 0 2px 24px; max-width: 420px; }
.add-others summary { cursor: pointer; font-size: 13px; }
.poller-addrs { display: grid; gap: 2px; }
/* 2.2.0: addresses are cut in script to a width that grows with the screen (addr220.ts); no clipping here, so the
   column keeps that width instead of being squeezed */
.poller-addrs .addr-line, .poller-addrs .addr { white-space: nowrap; }
.poller-addrs .addr-line { display: flex; align-items: baseline; gap: 2px; }
.addr-tag { font-family: var(--font, inherit); font-size: .78em; color: var(--muted); margin-left: 4px; }
.addr-copy { border: 0; background: none; padding: 0 3px; cursor: pointer; color: var(--muted); font-size: .85em; opacity: .55; }
.addr-copy:hover, .addr-copy:focus-visible { opacity: 1; color: var(--link); }
.alert-notes a { word-break: break-all; }
.form-grid > .add-picker { grid-column: 1 / -1; }
.add-modes label.check { display: inline-flex !important; flex-direction: row !important; align-items: center; gap: 6px; flex-wrap: nowrap; }
.add-modes label.check input { width: auto; margin: 0; }
.add-set .start-list { max-height: 220px; overflow: auto; }
.add-set-head > span { display: inline; }
/* 1.34: customer form "More settings" */
details.more-settings { margin-top: 16px; border: 1px solid var(--line); border-radius: 10px; padding: 8px 14px; }
details.more-settings > summary { cursor: pointer; font-weight: 600; padding: 4px 0; }
details.more-settings fieldset { margin-top: 12px; }
details.more-settings table.compact td { padding: 3px 8px 3px 0; border: none; }
details.more-settings table.compact { width: auto; }
details.more-settings table.compact input[type=time] { width: 150px; }
/* 1.35: network path graph */
.path-graph svg { max-width: 100%; height: auto; touch-action: none; cursor: grab; }
.path-graph svg:active { cursor: grabbing; }
.path-graph svg.editing g.node { cursor: move; }
.path-graph svg.editing { background-image: radial-gradient(var(--line) 1px, transparent 1px); background-size: 34px 26px; }
.path-graph g.node.dim { opacity: .22; }
.path-graph g.node.agentnode:focus rect, .path-graph g.node.target:focus circle { stroke: var(--link); stroke-width: 3; }
.path-graph svg text.lat.on { fill: var(--text); font-weight: 700; }
.path-graph svg text.nm { font-size: 11.5px; }
.path-graph svg text.badge-t { fill: #fff; font-weight: 700; font-size: 11.5px; }
.graph-tools { display: flex; gap: 4px; justify-content: flex-end; margin-bottom: 6px; flex-wrap: wrap; }
.graph-tools .btn { min-width: 34px; }
.path-tools { gap: 8px; align-items: center; flex-wrap: wrap; }
.path-tools select { width: auto; }
.chip-btn { background: none; border: 0; padding: 2px 4px; border-radius: 6px; cursor: pointer; color: inherit; font: inherit; }
.chip-btn:hover { background: var(--panel-2); }
.agent-chips li.on .chip-btn { background: var(--panel-2); box-shadow: inset 0 0 0 1px var(--line); }
.path-summary { margin-bottom: 16px; }
.path-summary .big-num { font-size: 20px; }
.path-summary .fail { color: var(--sev-critical); }
.spark { vertical-align: middle; margin-left: 6px; }
.spark path { fill: none; stroke-width: 1.5; }
.panel-head .path-tools { display: flex; flex-direction: row; }
.panel-head .path-tools select { width: auto; max-width: 220px; padding-top: 4px; padding-bottom: 4px; }

/* 1.36: searchable drop-downs: group headings */
.ssel-list li.ssel-group { padding: 6px 10px 2px; font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); cursor: default; }
/* 1.36: API reference */
details.api-op { border: 1px solid var(--line); border-radius: 8px; padding: 6px 10px; margin: 6px 0; }
details.api-op summary { cursor: pointer; }
details.api-op pre { white-space: pre-wrap; word-break: break-all; background: var(--panel-2); padding: 6px 8px; border-radius: 6px; }
details.api-op textarea { width: 100%; margin-top: 6px; }
.api-m { display: inline-block; min-width: 52px; text-align: center; font: 700 11px/18px var(--mono, monospace); border-radius: 4px; color: #fff; background: #64748b; }
.api-m.get { background: #2563eb; } .api-m.post { background: #16a34a; } .api-m.patch, .api-m.put { background: #d97706; } .api-m.delete { background: #dc2626; }
pre.api-out { max-height: 360px; overflow: auto; }
/* 1.38: ip-api flags in Traffic */
.flag-tags { margin-left: 6px; display: inline-flex; flex-wrap: wrap; gap: 3px; vertical-align: middle; }
.flag-tags .flag { margin-right: 0; }
.flag { display: inline-block; font-size: 10.5px; font-weight: 700; line-height: 16px; padding: 0 6px; border-radius: 8px; margin-right: 3px; border: 1px solid transparent; }
.flag-proxy { color: var(--sev-critical) !important; }
.flag.flag-proxy { background: color-mix(in srgb, var(--sev-critical) 14%, transparent); border-color: color-mix(in srgb, var(--sev-critical) 40%, transparent); }
.flag-hosting { color: #b7791f !important; }
.flag.flag-hosting { background: color-mix(in srgb, #e6a23c 18%, transparent); border-color: color-mix(in srgb, #e6a23c 50%, transparent); }
.flag.flag-mobile { color: var(--muted); background: var(--panel-2); border-color: var(--line); }
:root[data-theme="dark"] .flag-hosting { color: #f0b74d !important; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .flag-hosting { color: #f0b74d !important; } }
.flag-legend .flag { margin: 0 2px; }
.path-graph svg text.flagt { font-size: 10px; font-weight: 700; }
.path-graph svg text.flagt.proxy { fill: var(--sev-critical); }
.path-graph svg text.flagt.hosting { fill: #c98a1e; }

/* 1.38: provider filters and incident history */
.ext-hist li.ext-ignored { opacity: .55; filter: grayscale(1); background: var(--bg-soft, transparent); }
.ext-hist li.ext-ignored b { font-weight: 500; }
.ext-hist li.ext-ignored .ext-pill, .ext-hist li.ext-ignored [class*="pill"] { filter: grayscale(1); } /* 1.88: set aside by the filters: greyed */
.filter-preview { margin-top: 10px; }
.filter-preview ul { margin: 4px 0 8px; padding-left: 18px; }
.item-filters, .item-general { grid-column: 1 / -1; }
.cat-row .chip-note { margin-left: 8px; }
.item-filters[hidden], .item-general[hidden] { display: none !important; }
.item-filters > .wide { grid-column: 1 / -1; }
.traffic-tools select.flag-only { flex: 0 0 auto; width: auto; min-width: 0; }
.top-table td .flag-tags { display: flex; margin: 2px 0 0; }

/* 1.40: switching alarms off by scope */
.mute-scopes { border: 0; padding: 0; margin: 0 0 8px; display: grid; gap: 8px; }
.mute-scopes legend { font-weight: 600; margin-bottom: 6px; padding: 0; }
.radio-card { display: flex; gap: 10px; align-items: flex-start; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; cursor: pointer; background: var(--panel-2); }
.radio-card:has(input:checked) { border-color: var(--accent, var(--primary-bg)); box-shadow: inset 0 0 0 1px var(--accent, var(--primary-bg)); }
.radio-card input[type=radio] { margin-top: 3px; flex: none; width: auto; height: auto; min-height: 0; padding: 0; }
.radio-card { font-weight: normal; }
.radio-card > span { display: grid; gap: 2px; min-width: 0; flex: 1; overflow-wrap: anywhere; }
.mute-count { margin: 4px 0 10px; }
.toast-with-act { display: flex; align-items: center; gap: 12px; }
.toast-with-act .toast-act { flex: none; }
.alarms-off-banner { border: 1px solid var(--line); border-left: 3px solid var(--sev-major); border-radius: var(--radius-sm); padding: 10px 12px; margin: 10px 0; background: var(--panel-2); }
.alarms-off-banner .btn { margin-left: 6px; }
.alarms-off-mark { border-color: var(--sev-major); color: var(--sev-major); }
.stale-mutes ul { margin: 6px 0 0; }
.stale-mutes li { padding: 4px 0; border-top: 1px solid var(--line); }

/* 1.41: alarm templates, Monitors page, release notes */
.lvl-chips { display: inline-flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.lvl-chip { font-size: 12px; font-weight: 600; padding: 1px 7px; border-radius: 999px; border: 1px solid var(--line); white-space: nowrap; }
.lvl-chip.sev-warning { border-color: color-mix(in srgb, var(--sev-warning) 70%, var(--line)); background: color-mix(in srgb, var(--sev-warning) 14%, transparent); }
.lvl-chip.sev-minor { border-color: color-mix(in srgb, var(--sev-minor) 70%, var(--line)); background: color-mix(in srgb, var(--sev-minor) 14%, transparent); }
.lvl-chip.sev-major { border-color: color-mix(in srgb, var(--sev-major) 70%, var(--line)); background: color-mix(in srgb, var(--sev-major) 14%, transparent); }
.lvl-chip.sev-critical { border-color: color-mix(in srgb, var(--sev-critical) 70%, var(--line)); background: color-mix(in srgb, var(--sev-critical) 14%, transparent); }
.badge.sev-warning { background: color-mix(in srgb, var(--sev-warning) 20%, transparent); } .badge.sev-minor { background: color-mix(in srgb, var(--sev-minor) 20%, transparent); }
.badge.sev-major { background: color-mix(in srgb, var(--sev-major) 20%, transparent); } .badge.sev-critical { background: color-mix(in srgb, var(--sev-critical) 20%, transparent); }
.badge.ok { background: color-mix(in srgb, var(--sev-normal) 18%, transparent); margin-left: 6px; }
.notice-box { display: flex; gap: 14px; align-items: center; justify-content: space-between; flex-wrap: wrap; border: 1px solid var(--line); border-left: 3px solid var(--link); border-radius: var(--radius-sm); padding: 12px 14px; margin: 12px 0; background: var(--panel-2); }
.tpl-table table.mini td { padding: 2px 8px 2px 0; border: 0; }
.tpl-edit input.lvl-in { width: 56px; padding-left: 8px; padding-right: 4px; }
.tpl-edit th, .tpl-edit td { padding-left: 6px; padding-right: 6px; }
.tpl-edit select { width: auto; min-width: 0; }
.tpl-edit select[data-k=device_types] { max-width: 140px; }
.tpl-edit select[data-k=duration_s] { min-width: 104px; }
.table-scroll { overflow-x: auto; max-width: 100%; }
.inline-actions select { width: auto; }
.filter-bar select { width: auto; flex: 0 1 auto; max-width: 260px; }
.tpl-edit td { vertical-align: middle; }
.tpl-edit td.center { text-align: center; }
.tpl-from a { font-weight: 600; }
.lvl-sec { margin: 8px 0 14px; }
.lvl-sec .form-grid { margin-top: 8px; }
.filter-bar { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0 0 12px; }
.filter-bar input[type=search] { min-width: 240px; flex: 1 1 240px; }
.filter-bar label.check.inline { display: inline-flex; gap: 6px; align-items: center; margin: 0; }
table.mon-all tr.group-row td { background: var(--panel-2); }
table.mon-all tr.sel td { background: color-mix(in srgb, var(--link) 8%, transparent); }
table.mon-all .ellipsis { max-width: 420px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
@media (max-width: 640px) { .filter-bar input[type=search] { min-width: 0; } table.mon-all .ellipsis { max-width: 200px; } }
.rn-release { padding: 4px 0 14px; border-bottom: 1px solid var(--line); margin-bottom: 12px; }
.rn-release:last-child { border-bottom: 0; }
.rn-release h3 { margin: 6px 0 8px; }
.rn-cat h4 { margin: 10px 0 4px; font-size: 13px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); }
.rn-cat ul { margin: 0; padding-left: 20px; } .rn-cat li { margin: 3px 0; line-height: 1.45; }
.rn-features h4 { color: var(--link); } .rn-fixes h4 { color: var(--sev-normal); }
.rn-body { max-height: 60vh; overflow: auto; }
.rn-off { margin-right: auto; }
.nav-badge.rn-badge { background: var(--link); }
/* 1.42: the per-customer template overwrite */
.modal.modal-danger { border: 2px solid var(--sev-critical, #c62828); }
.modal.modal-danger .modal-head { background: color-mix(in srgb, var(--sev-critical, #c62828) 16%, var(--panel)); }
.danger-zone code { font-weight: 700; user-select: all; }
.ow-counts ul { margin: 4px 0 12px 18px; }
.notice-box.warn { border-color: var(--sev-warning, #c80); }
.nas-vol-tools { display: flex; gap: 8px; flex-wrap: wrap; margin: 0 0 8px; }
.nas-vol-tools input { flex: 1 1 220px; }
.pager { display: flex; align-items: center; gap: 8px; margin-top: 8px; }
/* 1.42: blackout windows and escalation policies */
.bo-rows { display: flex; flex-direction: column; gap: 8px; margin: 6px 0 8px; }
.bo-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; padding: 8px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel-2); }
.bo-body { display: flex; gap: 6px 12px; align-items: center; flex-wrap: wrap; flex: 1 1 320px; }
.bo-days { display: inline-flex; gap: 6px; flex-wrap: wrap; }
.bo-note { flex: 1 1 160px; min-width: 120px; }
ol.esc-steps { margin: 0; padding-left: 1.2em; }
ol.esc-edit { padding-left: 1.4em; display: flex; flex-direction: column; gap: 10px; }
li.esc-step { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 10px; }
.esc-progress li.sent { color: var(--muted); }
.badge.warn { background: color-mix(in srgb, var(--sev-warning) 22%, transparent); margin-left: 6px; }
.nas-vol-tools select { width: auto; flex: 0 0 auto; }

/* 1.43: Devices › Add › Virtualization… / Integrations… tile windows */
.picker { display: flex; flex-direction: column; gap: 14px; }
.picker-bar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.picker-bar input[type=search] { flex: 1 1 220px; min-width: 0; }
.picker-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.picker-tile { position: relative; display: flex; flex-direction: column; align-items: flex-start; gap: 6px; text-align: left; min-height: 124px; padding: 14px;
  background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); font: inherit; cursor: pointer; }
.picker-tile:hover { border-color: color-mix(in srgb, var(--accent, var(--link)) 60%, var(--line)); background: color-mix(in srgb, var(--accent, var(--link)) 6%, var(--panel-2)); }
.picker-tile:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.picker-icon { display: grid; place-items: center; width: 40px; height: 40px; border-radius: 10px; color: var(--accent, var(--link)); background: color-mix(in srgb, var(--accent, var(--link)) 15%, transparent); }
.picker-name { font-weight: 700; font-size: 14.5px; line-height: 1.25; }
.picker-desc { color: var(--muted); font-size: 12.5px; line-height: 1.35; }
.picker-badge { position: absolute; top: 10px; right: 10px; font-size: 11.5px; padding: 2px 8px; border-radius: 999px; background: color-mix(in srgb, var(--ok) 18%, transparent); color: var(--text); }
.picker-tile.g-virt { --accent: var(--c6); }
.picker-tile.g-net { --accent: var(--c1); }
.picker-tile.g-rmm { --accent: var(--c4); }
.picker-tile.g-sec { --accent: var(--c8); }
.picker-tile.g-cloud { --accent: var(--c7); }
.picker-empty { margin: 8px 0; }
.picker-back { display: inline-block; margin: -4px 0 8px; }
@media (max-width: 860px) { .picker-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media (max-width: 640px) { .picker-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .picker-tile { min-height: 112px; padding: 12px; } }

/* 1.43: Microsoft 365 sign-ins and mail */
.m365sec .ready { list-style: none; padding: 0; margin: 8px 0; display: grid; gap: 6px; }
.m365sec .ready li { display: flex; gap: 8px; align-items: flex-start; }
.m365sec .ready-mark { width: 1.2em; font-weight: 700; }
.m365sec .ready li.ok .ready-mark { color: var(--ok); }
.m365sec .ready li.bad .ready-mark { color: var(--danger); }
.m365sec details.callout summary { cursor: pointer; font-weight: 600; }
.m365sec pre.mono { white-space: pre-wrap; word-break: break-all; background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 10px; margin: 6px 0; }
.country-chips { margin: 4px 0 6px; }
.country-chips .chip-note button { background: none; border: 0; color: inherit; cursor: pointer; font: inherit; padding: 0 0 0 4px; }
table.levels .num-in { width: 7em; }
tr.row-bad td:first-child { box-shadow: inset 3px 0 0 var(--sev-critical); }
.m365-signins .toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 12px; }
.m365-signins .toolbar input, .m365-signins .toolbar select { flex: 1 1 160px; min-width: 0; }
.m365-signins td .btn.small + .btn.small { margin-left: 6px; }
.m365-exc { margin-top: 24px; }
.m365sec .inline-actions input[list] { flex: 0 1 320px; min-width: 0; }
.m365sec .inline-actions { margin-bottom: 14px; }
.m365sec select[name=scope] { min-width: 300px; max-width: 100%; }

/* 1.44 */
.ws-banner { position: sticky; top: 0; z-index: 60; display: flex; gap: 10px; align-items: center; padding: 8px 16px; background: color-mix(in srgb, var(--sev-minor) 18%, var(--panel)); color: var(--text); border-bottom: 1px solid var(--sev-minor); font-size: 14px; }
.ws-banner span { flex: 1; }
.server-tag { margin-top: 4px; display: flex; flex-wrap: wrap; gap: 4px; align-items: center; }
.server-tag .mono { color: var(--muted); }
.chip-note.warn { border-color: var(--sev-minor); color: var(--text); background: color-mix(in srgb, var(--sev-minor) 16%, transparent); }
table.blocks td { vertical-align: top; }
.pill.blk-poller { background: color-mix(in srgb, var(--sev-info) 18%, transparent); }
.pill.blk-account { background: color-mix(in srgb, var(--sev-minor) 20%, transparent); }
.pill.blk-limit { background: var(--panel-2); }
.pill.blk-manual { background: color-mix(in srgb, var(--danger) 18%, transparent); }
.passkey-fail h2 { margin-top: 0; }
.passkey-fail .btn-col { display: flex; flex-direction: column; gap: 8px; margin-top: 12px; }
.codes-view ol.codes { columns: 2; padding-left: 1.4em; }
.codes-view label.check { margin-top: 10px; }
label.check.disabled { opacity: .55; }
.inline-form { display: flex; flex-wrap: wrap; gap: 8px; align-items: flex-end; }
.inline-form .field { margin: 0; }
table.blocks .pill { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 12px; border: 1px solid var(--line); white-space: nowrap; }
.lock-mode .radio-list { margin-bottom: 8px; } .lock-mode > .field { margin-bottom: 4px; }

/* 1.45: trap rules (SNMPc-style tree), rule editor, device groups, dissector, decoded trap variables, BGP peers */
.trap-rules { display: grid; grid-template-columns: minmax(240px, 320px) minmax(0, 1fr); gap: 16px; align-items: start; }
.trap-side { display: flex; flex-direction: column; gap: 8px; position: sticky; top: 8px; max-height: calc(100vh - 140px); }
.trap-tree { overflow: auto; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel); padding: 4px 0; min-height: 200px; }
.tt-row { display: flex; align-items: center; gap: 6px; width: 100%; text-align: left; background: none; border: 0; color: var(--text); font: 13px var(--font); padding: 4px 8px; cursor: pointer; white-space: nowrap; }
.tt-row:hover { background: var(--panel-2); }
.tt-row.lvl0 { font-weight: 600; }
.tt-row.lvl1 { padding-left: 22px; color: var(--muted); }
.tt-row.lvl2 { padding-left: 40px; overflow: hidden; text-overflow: ellipsis; }
.tt-row.current { background: color-mix(in srgb, var(--link) 16%, transparent); }
.tt-row .tw { width: 12px; color: var(--muted); }
.trap-ic { color: var(--muted); font-size: 12px; }
.trap-ic.has-rules { color: var(--sev-normal); }
.count-pill { margin-left: auto; font-size: 11px; padding: 0 6px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line); }
.trap-pane { min-width: 0; }
.rule-list { list-style: none; margin: 0 0 12px; padding: 0; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel); }
.rule-item { display: flex; gap: 10px; align-items: flex-start; padding: 10px 12px; border-bottom: 1px solid var(--line); }
.rule-item:last-child { border-bottom: 0; }
.rule-item.default { background: var(--panel-2); }
.rule-item.dim { opacity: .6; }
.rule-main { flex: 1; min-width: 0; }
.rule-move { display: flex; gap: 2px; }
.rule-form h4 { margin: 16px 0 6px; font-size: 13px; }
.rule-pane { min-height: 320px; }
.cond-rows { display: flex; flex-direction: column; gap: 6px; margin-bottom: 6px; }
.cond-row { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.cond-row input, .cond-row select { flex: 1 1 140px; min-width: 0; }
.cond-row .icon-btn { flex: 0 0 auto; }
.check-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 2px 14px; margin-bottom: 8px; }
.picker { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 6px; background: var(--panel-2); }
.picker-list { max-height: 220px; overflow: auto; display: flex; flex-direction: column; gap: 2px; margin-top: 6px; }
.inline-row { display: flex; gap: 8px; margin-top: 6px; }
.idx-parts { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 3px; font-family: var(--font); }
.idx-part { font-size: 11.5px; padding: 0 6px; border: 1px solid var(--line); border-radius: 999px; background: var(--panel-2); white-space: nowrap; }
.trap-vars-panel .panel-head { display: flex; justify-content: space-between; align-items: center; gap: 8px; flex-wrap: wrap; }
table.trap-vars td { vertical-align: top; }
.menu.ctx-menu { position: absolute; z-index: 1000; min-width: 260px; }
.dissector .table-wrap { overflow-x: auto; }
table.dissect td { vertical-align: top; }
table.dissect .dis-oid, table.dissect .dis-raw { word-break: break-all; max-width: 34ch; }
table.dissect td.dis-val { min-width: 16ch; max-width: 30ch; overflow-wrap: anywhere; }
table.dissect input.small, table.dissect select.small { font-size: 12.5px; padding: 3px 6px; min-width: 120px; }
.oid-idx { color: var(--link); }
.dissect-preview { margin: 10px 0; padding: 8px 10px; border: 1px dashed var(--line); border-radius: var(--radius-sm); }
table.bgp .pill, .bgp-panel .pill { display: inline-block; padding: 1px 8px; border-radius: 999px; font-size: 12px; border: 1px solid var(--line); white-space: nowrap; }
.pill.st-up { background: color-mix(in srgb, var(--sev-normal) 20%, transparent); }
.pill.st-down { background: color-mix(in srgb, var(--sev-critical) 20%, transparent); }
.pill.st-warning { background: color-mix(in srgb, var(--sev-minor) 22%, transparent); }
.pill.st-muted { color: var(--muted); }
@media (max-width: 860px) { .trap-rules { grid-template-columns: minmax(0, 1fr); } .trap-side { position: static; max-height: none; } .trap-tree { max-height: 320px; } }

.rule-pane > [hidden] { display: none !important; }
.picker-list label.check, .check-list label.check { align-self: stretch; flex-wrap: nowrap; justify-content: flex-start; align-items: flex-start; font-weight: 500; padding: 5px 2px; text-align: left; }
.picker-list label.check input, .check-list label.check input { width: auto; flex: none; margin: 2px 0 0; }
.picker-list label.check > span, .check-list label.check > span { min-width: 0; overflow-wrap: anywhere; }

/* 1.46: bulk selection on discovered VLANs */
table.grid th.sel, table.grid td.sel { width: 32px; text-align: center; }
table.grid tr.picked td { background: color-mix(in srgb, var(--accent, #2563eb) 8%, transparent); }
.toolbar.wrap { flex-wrap: wrap; }
.bulk-bar { display: flex; align-items: center; gap: 10px; justify-content: flex-end; position: sticky; bottom: 0; background: var(--panel); padding: 10px 0; border-top: 1px solid var(--line); }
.bulk-bar > span { margin-right: auto; }
/* 1.46: integration site suggestions */
.suggest { margin-top: 6px; padding: 6px 8px; border: 1px dashed var(--line); border-radius: var(--radius-sm); display: grid; gap: 4px; }
.suggest-main { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.suggest-main input { width: auto; margin: 0; }
.suggest-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.badge.reason-account { background: color-mix(in srgb, var(--ok, #16a34a) 15%, transparent); color: var(--text); }
.badge.reason-exact { background: color-mix(in srgb, var(--ok, #16a34a) 10%, transparent); color: var(--text); }
.badge.reason-name { background: color-mix(in srgb, var(--warn, #d97706) 14%, transparent); color: var(--text); }
.suggest-bar { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 8px 0; padding: 8px 10px; background: var(--panel-2, var(--panel)); border: 1px solid var(--line); border-radius: var(--radius-sm); }
.suggest-bar > span { margin-right: auto; }
/* 1.46: interface traffic */
.if-traffic .chart { height: 300px; }
/* 1.46: network device front and back */
.faceplate-panel .fp-h { font-size: 13px; color: var(--muted); margin: 10px 0 4px; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; }
.fp-wrap { overflow-x: auto; margin-bottom: 8px; }
.fp-svg { width: 100%; height: auto; display: block; min-width: 520px; }
.fp-body { fill: color-mix(in srgb, var(--text) 8%, var(--panel)); stroke: var(--line); }
.fp-ear { fill: color-mix(in srgb, var(--text) 14%, var(--panel)); }
.fp-model { fill: var(--text); font: 700 9px var(--font); }
.fp-tiny { fill: var(--muted); font: 600 8px var(--font); }
.fp-blabel { fill: var(--muted); font: 600 8px var(--font); }
.fp-plabel { fill: var(--muted); font: 7px var(--mono); }
.fp-port { cursor: pointer; outline: none; }
.fp-port:focus-visible .fp-hole, .fp-port:hover .fp-hole { stroke: var(--focus); stroke-width: 2; }
.fp-hole { stroke: color-mix(in srgb, var(--text) 45%, var(--panel)); stroke-width: 1; fill: color-mix(in srgb, var(--text) 30%, var(--panel)); }
.fp-led { fill: color-mix(in srgb, var(--text) 25%, var(--panel)); }
.fp-up .fp-hole { fill: color-mix(in srgb, var(--ok) 35%, var(--panel)); } .fp-up .fp-led { fill: var(--ok); }
.fp-down .fp-hole { fill: color-mix(in srgb, var(--text) 16%, var(--panel)); }
.fp-admin .fp-hole { fill: color-mix(in srgb, var(--text) 55%, var(--panel)); }
.fp-warn .fp-hole { fill: color-mix(in srgb, var(--sev-warning) 55%, var(--panel)); } .fp-warn .fp-led { fill: var(--sev-warning); }
.fp-bad .fp-hole { fill: color-mix(in srgb, var(--danger) 55%, var(--panel)); } .fp-bad .fp-led { fill: var(--danger); }
.fp-empty .fp-hole { fill: none; stroke-dasharray: 2 2; }
.fp-mon .fp-hole { stroke: var(--text); }
.fp-poe { fill: var(--sev-warning); }
.fp-heat-na .fp-hole { fill: color-mix(in srgb, var(--text) 22%, var(--panel)); }
.fp-heat-0 .fp-hole { fill: color-mix(in srgb, var(--series-1) 18%, var(--panel)); }
.fp-heat-1 .fp-hole { fill: color-mix(in srgb, var(--series-1) 38%, var(--panel)); }
.fp-heat-2 .fp-hole { fill: color-mix(in srgb, var(--series-1) 60%, var(--panel)); }
.fp-heat-3 .fp-hole { fill: color-mix(in srgb, var(--sev-warning) 70%, var(--panel)); }
.fp-heat-4, .fp-heat-5 { } .fp-heat-4 .fp-hole, .fp-heat-5 .fp-hole { fill: color-mix(in srgb, var(--danger) 70%, var(--panel)); }
.fp-partbox { fill: color-mix(in srgb, var(--text) 12%, var(--panel)); stroke: var(--line); }
.fp-vent, .fp-fanblade { stroke: color-mix(in srgb, var(--text) 35%, var(--panel)); stroke-width: 2; }
.fp-fan { fill: none; stroke: color-mix(in srgb, var(--text) 35%, var(--panel)); stroke-width: 2; }
.fp-socket { fill: color-mix(in srgb, var(--text) 40%, var(--panel)); }
.fp-led2 { fill: color-mix(in srgb, var(--text) 30%, var(--panel)); }
.fp-ok .fp-led2 { fill: var(--ok); } .fp-warn .fp-led2 { fill: var(--sev-warning); } .fp-bad .fp-led2 { fill: var(--danger); }
.fp-bad .fp-partbox { stroke: var(--danger); stroke-width: 2; } .fp-unknown .fp-partbox { stroke-dasharray: 3 2; }
.fp-legend { display: flex; flex-wrap: wrap; gap: 4px 14px; font-size: 12px; color: var(--muted); margin: 2px 0 6px; }
.fp-legend span { display: inline-flex; align-items: center; gap: 5px; }
.fp-sw { width: 14px; height: 10px; border-radius: 2px; display: inline-block; border: 1px solid var(--line); }
.fp-sw.fp-up { background: color-mix(in srgb, var(--ok) 35%, var(--panel)); } .fp-sw.fp-down { background: color-mix(in srgb, var(--text) 16%, var(--panel)); }
.fp-sw.fp-admin { background: color-mix(in srgb, var(--text) 55%, var(--panel)); } .fp-sw.fp-warn { background: color-mix(in srgb, var(--sev-warning) 55%, var(--panel)); }
.fp-sw.fp-bad { background: color-mix(in srgb, var(--danger) 55%, var(--panel)); } .fp-sw.fp-empty { border-style: dashed; }
.fp-sw.fp-heat-na { background: color-mix(in srgb, var(--text) 22%, var(--panel)); }
.fp-sw.fp-heat-0 { background: color-mix(in srgb, var(--series-1) 18%, var(--panel)); } .fp-sw.fp-heat-1 { background: color-mix(in srgb, var(--series-1) 38%, var(--panel)); }
.fp-sw.fp-heat-2 { background: color-mix(in srgb, var(--series-1) 60%, var(--panel)); } .fp-sw.fp-heat-3 { background: color-mix(in srgb, var(--sev-warning) 70%, var(--panel)); }
.fp-sw.fp-heat-4 { background: color-mix(in srgb, var(--danger) 70%, var(--panel)); }
/* 1.46: ports panel */
.ports-filters .toolbar { margin-bottom: 6px; align-items: center; gap: 8px; }
.ports-table .pstate { font-size: 12px; font-weight: 600; padding: 1px 6px; border-radius: 999px; }
.pstate.up { background: color-mix(in srgb, var(--ok) 16%, transparent); }
.pstate.down { background: color-mix(in srgb, var(--muted) 16%, transparent); }
.pstate.admin { background: color-mix(in srgb, var(--text) 10%, transparent); color: var(--muted); }
.ports-bar { flex-wrap: wrap; }
.rule-dry { margin-top: 8px; }

/* 1.47: content being re-read stays in place, dimmed, so the page keeps its height */
.is-reading { opacity: .55; transition: opacity .15s; }
.is-reading .reading { opacity: 1; }
.ports-body .reading { margin: 0 0 6px; }
.empty-read { display: flex; align-items: center; gap: 12px; padding: 10px 0; }
.main { overflow-anchor: auto; }
/* 1.47: the map link sits apart from the address it opens */
.addr-map { display: inline-flex; align-items: center; gap: 3px; margin-left: .6em; white-space: nowrap; }
.addr-map svg { width: 13px; height: 13px; }
/* 1.47: MAC-only LLDP neighbours */
.mac-nb { display: inline-flex; flex-direction: column; line-height: 1.2; vertical-align: top; }
.mac-vendor { display: block; font-size: 11.5px; color: var(--muted); }
/* 1.47: click-to-zoom on time graphs */
.cz-band { position: absolute; background: color-mix(in srgb, var(--accent, #4c8dff) 18%, transparent); border-left: 1px solid var(--accent, #4c8dff); border-right: 1px solid var(--accent, #4c8dff); pointer-events: none; z-index: 2; }
.cz-line { position: absolute; width: 0; border-left: 2px solid var(--accent, #4c8dff); pointer-events: none; z-index: 2; }
.cz-tip { position: absolute; font-size: 12px; background: var(--panel); border: 1px solid var(--line); border-radius: 6px; padding: 2px 6px; pointer-events: none; z-index: 3; white-space: nowrap; color: var(--text); }
.cz-bar { position: absolute; top: 2px; right: 6px; display: flex; gap: 6px; z-index: 4; }
/* 1.47: optics (DOM) */
.opt-warn { color: var(--sev-warning); font-weight: 600; }
.opt-bad { color: var(--sev-critical); font-weight: 700; }
.fp-noopt .fp-hole { fill: var(--panel-2); stroke: var(--line); }
.fp-sw.fp-noopt { background: var(--panel-2); border: 1px solid var(--line); }
/* 1.47: threat feeds */
.flag-listed { color: var(--threat) !important; font-weight: 600; }
.flag.flag-listed { background: color-mix(in srgb, var(--threat) 20%, transparent); border-color: var(--threat); color: var(--threat); font-weight: 700; }
/* 1.48: threat-feed addresses in purple everywhere */
.threat-badge.listed, .badge.threat { background: color-mix(in srgb, var(--threat) 18%, transparent); border: 1px solid var(--threat); color: var(--threat); border-radius: 4px; padding: 0 5px; font-size: .78em; font-weight: 700; margin-left: 6px; }
.callout.bad.threat-box { border-color: var(--threat); background: color-mix(in srgb, var(--threat) 10%, transparent); }
.picker-filter { width: 9em; }
.pick-row { display: flex; gap: 4px; }
.flag.flag-tor { background: color-mix(in srgb, var(--muted) 16%, transparent); border-color: color-mix(in srgb, var(--muted) 45%, transparent); }
.threat-badge { display: inline-block; font-size: 11.5px; font-weight: 700; padding: 0 6px; border-radius: 4px; margin-left: 6px; color: var(--sev-critical); border: 1px solid var(--sev-critical); background: color-mix(in srgb, var(--sev-critical) 12%, transparent); }
.threat-badge.tor { color: var(--muted); border-color: var(--line); background: var(--panel-2); font-weight: 600; }
.feed-err { color: var(--sev-critical); }
.cz-band[hidden], .cz-line[hidden], .cz-tip[hidden], .cz-bar[hidden] { display: none !important; }

/* 1.48: compliance-based ops */
.compliance-box { border: 1px solid var(--line); border-radius: 6px; padding: 8px 10px; margin: 8px 0; }
.compliance-flag { color: var(--sev-minor); font-weight: 600; }
/* 1.48: Routing map */
.rmap-wrap { overflow: auto; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); }
svg.rmap { width: 100%; min-width: 900px; height: auto; display: block; }
.rm-edge { fill: none; stroke-width: 2; }
.rm-physical { stroke: var(--muted); stroke-width: 3; opacity: .55; }
.rm-ospf { stroke: var(--sev-info); }
.rm-isis { stroke: #1aa39a; }
.rm-bgp { stroke: var(--threat); stroke-dasharray: 6 4; }
.rm-edge.rm-down { stroke: var(--sev-critical); stroke-width: 3; opacity: 1; }
.rm-elabel { font-size: 10px; fill: var(--muted); text-anchor: middle; pointer-events: none; }
.rm-node rect { fill: var(--panel); stroke: var(--sev-normal); stroke-width: 2; }
.rm-node.st-down rect { stroke: var(--sev-critical); }
.rm-node.st-warning rect { stroke: var(--sev-warning); }
.rm-node.rm-unknown rect { stroke: var(--muted); stroke-dasharray: 4 3; }
.rm-node { cursor: grab; }
.rm-name { font-size: 12px; font-weight: 600; text-anchor: middle; fill: var(--text); }
.rm-sub { font-size: 9.5px; text-anchor: middle; fill: var(--muted); }
.rm-node.rm-stale { opacity: .6; }

/* 1.49: the device page's tabs, badges and summary cards */
.dev-tabs { position: sticky; top: -22px; z-index: 5; background: var(--bg); margin: 14px 0 16px; }
@media (max-width: 600px) { .dev-tabs { top: 0; } }
.dev-tabs .tab[hidden] { display: none; }
.tab-badge { display: inline-block; min-width: 20px; padding: 1px 6px; border-radius: 10px; font: 700 12px/16px var(--font); text-align: center; color: #fff; background: var(--muted); }
.tb-down, .tb-sev-5 { background: var(--sev-critical); }
.tb-sev-4 { background: var(--sev-major); }
.tb-sev-3 { background: var(--sev-minor); color: #1d1d1d; }
.tb-warning, .tb-sev-2 { background: var(--sev-warning); color: #1d1d1d; }
.tb-sev-1, .tb-sev-0 { background: var(--sev-info); }
.dev-pane:focus { outline: none; }
.dev-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 10px; margin-bottom: 16px; }
.dev-card { display: flex; flex-direction: column; gap: 2px; padding: 10px 14px; border: 1px solid var(--line); border-left: 4px solid var(--line); border-radius: var(--radius); background: var(--panel); color: var(--text); text-decoration: none; }
.dev-card:hover { background: var(--panel-2); text-decoration: none; }
.dev-card:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; }
.dc-t { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; font-weight: 600; }
.dc-v { font-weight: 600; }
.dev-card.tone-down, .dev-card.tone-sev-5 { border-left-color: var(--sev-critical); }
.dev-card.tone-sev-4 { border-left-color: var(--sev-major); }
.dev-card.tone-sev-3 { border-left-color: var(--sev-minor); }
.dev-card.tone-warning, .dev-card.tone-sev-2 { border-left-color: var(--sev-warning); }
.dev-card.tone-sev-1 { border-left-color: var(--sev-info); }
.read-age.stale { color: var(--text); font-weight: 600; background: color-mix(in srgb, var(--sev-warning) 35%, transparent); border-radius: 4px; padding: 0 5px; }
.filter-note { display: flex; align-items: center; gap: 8px; margin: 0 0 8px; }

/* 1.50: the BGP tab */
.bgp-strip { display: flex; flex-wrap: wrap; gap: 6px 18px; align-items: baseline; margin: 2px 0 12px; }
.bs-item strong { font-size: 18px; }
.bs-down strong, .bs-down { color: var(--sev-critical); }
.bgp-note { margin: 0 0 10px; }
.bgp-sub { font-size: 14px; margin: 16px 0 6px; }
.bgp-problems .tree { border-color: color-mix(in srgb, var(--sev-critical) 45%, var(--line)); }
.bgp-asname { color: var(--muted); font-weight: 400; }
.bgp-label { display: inline-block; margin: 2px 0 0 6px; padding: 0 7px; border-radius: 999px; font-size: 12px; line-height: 18px; border: 1px solid var(--line); background: var(--panel-2); color: var(--text); white-space: nowrap; }
.bgp-label.role-transit { border-color: color-mix(in srgb, var(--c1) 60%, var(--line)); }
.bgp-label.role-exchange { border-color: color-mix(in srgb, var(--c2) 60%, var(--line)); }
.bgp-label.role-customer { border-color: color-mix(in srgb, var(--c3) 60%, var(--line)); }
.bgp-label.role-internal { border-color: color-mix(in srgb, var(--c4) 60%, var(--line)); }
.recent-mark { color: var(--sev-minor); font-size: 12px; font-weight: 600; }
.pfx { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.pfx-short { color: var(--sev-minor); font-size: 12px; font-weight: 600; }
.pfx-bar { display: block; height: 4px; border-radius: 2px; background: var(--panel-2); overflow: hidden; max-width: 140px; }
.pfx-bar > span { display: block; height: 100%; background: var(--link); }
.bgp-panel .tree-row.lvl-peer .first { align-items: flex-start; }

/* 1.51: the devices tiles view */
.view-seg { flex: none; }
.tiles-hint { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; margin-bottom: 12px; }
.tiles-view { display: flex; flex-direction: column; gap: 14px; }
.tile-group { min-width: 0; }
.tg-head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin-bottom: 8px; }
.tg-toggle { display: inline-flex; align-items: center; gap: 6px; background: none; border: 0; padding: 4px 6px 4px 0; color: var(--text); font: 600 15px var(--font); cursor: pointer; }
.tg-toggle svg:first-child { transition: transform .12s; }
.tg-toggle[aria-expanded="true"] svg:first-child { transform: rotate(90deg); }
.tg-toggle:focus-visible { outline: 2px solid var(--focus); outline-offset: 2px; border-radius: 4px; }
.tg-l2 > .tg-head .tg-toggle, .tg-l3 > .tg-head .tg-toggle { font-size: 14px; }
.tg-l2, .tg-l3 { margin-left: 14px; }
.tg-body[hidden] { display: none; }
.tg-body { display: flex; flex-direction: column; gap: 12px; }
.tg-counts .rollup { font-size: 12px; }
.tile-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(112px, 1fr)); gap: 10px; }
.dev-tile { --tc: var(--muted); position: relative; display: flex; flex-direction: column; align-items: center; gap: 6px; aspect-ratio: 1 / 1; max-width: 100%; min-width: 0;
  padding: 14px 8px 8px; border-radius: 10px; border: 1px solid color-mix(in srgb, var(--tc) 45%, var(--line)); box-shadow: inset 0 4px 0 var(--tc);
  background: color-mix(in srgb, var(--tc) 9%, var(--panel)); color: var(--text); text-decoration: none; overflow: hidden; }
.dev-tile:hover { background: color-mix(in srgb, var(--tc) 16%, var(--panel)); text-decoration: none; }
.dev-tile:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; }
.tile-up { --tc: var(--sev-normal); }
.tile-down { --tc: var(--sev-critical); }
.tile-warning { --tc: var(--sev-warning); }
.tile-unreachable { --tc: var(--sev-minor); }
.tile-paused, .tile-unknown, .tile-container, .tile-offline { --tc: var(--muted); }
.tile-icon { display: flex; height: 28px; align-items: center; }
.tile-name { font-size: 12.5px; font-weight: 600; line-height: 1.25; text-align: center; overflow-wrap: anywhere; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; max-width: 100%; }
.tile-foot { margin-top: auto; display: flex; align-items: center; gap: 4px; font-size: 11px; color: var(--muted); max-width: 100%; }
.tile-st { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.tile-marks { display: inline-flex; gap: 2px; }
.tile-mark { display: inline-flex; align-items: center; justify-content: center; min-width: 15px; height: 15px; border-radius: 4px; background: var(--panel-2); color: var(--muted); font-size: 10px; font-weight: 700; }
.tile-badge { position: absolute; top: 7px; right: 7px; min-width: 20px; padding: 0 5px; border-radius: 10px; font: 700 11px/18px var(--font); text-align: center; color: #fff; background: var(--muted); }
.tile-match { position: absolute; top: 7px; left: 7px; font-size: 10px; font-weight: 700; padding: 0 4px; border-radius: 4px; background: var(--panel-2); color: var(--link); }
.tile-peek { position: absolute; z-index: 60; max-width: 300px; min-width: 220px; padding: 10px 12px; border-radius: 8px; border: 1px solid var(--line); background: var(--panel); color: var(--text); box-shadow: var(--shadow); font-size: 12.5px; pointer-events: none; display: flex; flex-direction: column; gap: 3px; }
.pk-name { font-weight: 700; font-size: 13.5px; margin-bottom: 2px; overflow-wrap: anywhere; }
.pk-row { display: grid; grid-template-columns: 92px 1fr; gap: 6px; }
.pk-k { color: var(--muted); }
.pk-v { min-width: 0; overflow-wrap: anywhere; }
.pk-fail { color: var(--sev-critical); font-weight: 600; overflow-wrap: anywhere; }
.pk-fail.pk-warn { color: var(--text); }
@media (max-width: 600px) { .tile-grid { grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); } }

/* 1.52: the picker (device group) */
.picker { position: relative; display: block; }
.picker-btn { display: flex; align-items: center; justify-content: space-between; gap: 8px; width: 100%; min-height: 36px; padding: 6px 10px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); color: var(--text); font: inherit; text-align: left; cursor: pointer; }
.picker-btn:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.pk-caret { color: var(--muted); }
.picker-pop { position: absolute; z-index: 70; left: 0; right: 0; top: calc(100% + 4px); padding: 6px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); box-shadow: var(--shadow); display: flex; flex-direction: column; gap: 6px; }
.picker-pop .picker-filter { width: 100%; }
.picker-list { list-style: none; margin: 0; padding: 0; max-height: 260px; overflow-y: auto; }
.picker-list li { display: flex; justify-content: space-between; gap: 8px; padding: 6px 8px; border-radius: 6px; cursor: pointer; }
.picker-list li.active, .picker-list li:hover { background: var(--panel-2); }
.picker-list li[aria-selected="true"] { font-weight: 600; }
.picker-new { display: flex; gap: 6px; align-items: center; border-top: 1px solid var(--line); padding-top: 6px; }
.picker-new input { flex: 1; min-width: 0; }
.threat-hosts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.tg-integration > .tg-head .tg-label { font-weight: 700; }

/* 1.52: a port changed by a trap pulses for 60 s (red down, green up, amber flapping); solid with reduced motion */
@keyframes pfl-pulse { 0%, 100% { opacity: 1; } 50% { opacity: .25; } }
.fp-port.pfl-down .fp-hole { stroke: var(--sev-critical); stroke-width: 3; }
.fp-port.pfl-up .fp-hole { stroke: var(--sev-normal); stroke-width: 3; }
.fp-port.pfl-flap .fp-hole { stroke: var(--sev-minor); stroke-width: 3; }
.pstate.pfl-down { outline: 2px solid var(--sev-critical); outline-offset: 2px; }
.pstate.pfl-up { outline: 2px solid var(--sev-normal); outline-offset: 2px; }
.pstate.pfl-flap { outline: 2px solid var(--sev-minor); outline-offset: 2px; }
.fp-port.pfl-down .fp-hole, .fp-port.pfl-up .fp-hole, .pstate.pfl-down, .pstate.pfl-up { animation: pfl-pulse 1s ease-in-out 60; animation-delay: var(--pfl-delay, 0s); }
.fp-port.pfl-flap .fp-hole, .pstate.pfl-flap { animation: pfl-pulse 1.6s ease-in-out infinite; }
@media (prefers-reduced-motion: reduce) { .fp-port.pfl-down .fp-hole, .fp-port.pfl-up .fp-hole, .fp-port.pfl-flap .fp-hole, .pstate.pfl-down, .pstate.pfl-up, .pstate.pfl-flap { animation: none; } }
.fp-sw.fp-ol-down { background: transparent; border: 2px solid var(--sev-critical); }
.fp-sw.fp-ol-up { background: transparent; border: 2px solid var(--sev-normal); }
.fp-sw.fp-ol-flap { background: transparent; border: 2px solid var(--sev-minor); }

/* 1.53: Settings › Reports, VM assignment */
.report-totals { display: flex; flex-wrap: wrap; gap: .5rem; margin: .5rem 0 1rem; }
.report-total { background: var(--panel-2); border: 1px solid var(--line); border-radius: 6px; padding: .5rem .8rem; min-width: 8rem; text-align: center; }
.report-total-n { font-size: 1.4rem; font-weight: 600; }
.report-customer h3 { border-bottom: 2px solid var(--link); padding-bottom: .2rem; margin-top: 1.4rem; }
.report-section h4 { margin: 1rem 0 .3rem; }
tr.long-row td { background: color-mix(in srgb, #e0a21b 14%, transparent); }
.tag.long-tag { margin-left: .4em; background: color-mix(in srgb, #e0a21b 25%, transparent); font-size: .75em; }
.report-frame { width: 100%; height: 60vh; border: 1px solid var(--line); background: #fff; }
.pick-box { max-height: 12rem; overflow: auto; border: 1px solid var(--line); border-radius: 6px; padding: .4rem .6rem; margin: .3rem 0 .6rem; }
.report-form fieldset { border: 1px solid var(--line); border-radius: 6px; margin: .8rem 0; padding: .5rem .8rem; }
.vm-rules-box { margin-top: 1.5rem; }
.vm-rule { display: flex; flex-wrap: wrap; gap: .4rem; align-items: center; margin: .3rem 0; }
.vm-rule input[type=text] { flex: 1 1 14rem; min-width: 10rem; }
.vm-rule select { width: auto; flex: 0 0 auto; }
h2.report-now { margin-top: 1.6rem; }

/* 1.54: Degraded (answering, with something down): orange, a diamond */
.status-degraded .dot { background: var(--sev-major); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); border-radius: 0; }
.pill.st-degraded { background: color-mix(in srgb, var(--sev-major) 20%, transparent); }
.map-st.st-degraded { fill: var(--sev-major); }
.map-node .box.st-degraded { stroke: var(--sev-major); stroke-width: 2.5; }
.rm-node.st-degraded rect { stroke: var(--sev-major); }
.fail.degline, .pk-fail.pk-deg { color: color-mix(in srgb, var(--sev-major) 75%, var(--text, #000)); }
.tile-degraded { --tc: var(--sev-major); }
.map-sum-deg { color: var(--sev-major); }
.deg-text { color: color-mix(in srgb, var(--sev-major) 80%, var(--text, #000)); font-weight: 600; }

/* 1.55: Devices › Show, a drop-down of tick boxes */
.chips button.show-btn.is-on { background: var(--text); color: var(--bg); border-color: var(--text); }
.check-menu { padding: 6px; box-sizing: border-box; }
.check-menu .check-all { display: block; width: 100%; text-align: left; border: 0; background: none; color: var(--text); font: inherit; font-weight: 600; padding: 6px 8px; border-radius: var(--radius-sm); cursor: pointer; }
.check-menu .check-all:hover, .check-menu .check-all:focus-visible { background: var(--panel-2); }
.check-item { display: flex; gap: 8px; align-items: flex-start; padding: 6px 8px; border-radius: var(--radius-sm); cursor: pointer; }
.check-item:hover { background: var(--panel-2); }
.check-item input { margin-top: 3px; flex: none; }
.check-item .check-text { display: flex; flex-direction: column; min-width: 0; }
.check-item .menu-l { display: flex; gap: 8px; align-items: baseline; font-weight: 600; }
.check-item .menu-l .n { color: var(--muted); font-weight: 500; font-variant-numeric: tabular-nums; }
.check-item .menu-d { font-size: 12px; color: var(--muted); }
.check-item.is-off { opacity: .55; cursor: default; }

/* 1.56: Internal (MSP staff only ever see it) and kinds of user */
.internal-tag { display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 999px; font-size: 11px; font-weight: 700; letter-spacing: .02em; line-height: 17px; vertical-align: middle;
  color: var(--text); background: color-mix(in srgb, var(--sev-warning) 22%, var(--panel)); border: 1px dashed color-mix(in srgb, var(--sev-warning) 70%, var(--line)); }
h1 .internal-tag { font-size: 12px; line-height: 20px; }
.tile-name .tile-int { display: block; width: max-content; margin: 2px auto 0; }
.kind-tag { display: inline-block; margin-left: 6px; padding: 0 6px; border-radius: 4px; font-size: 11px; font-weight: 600; line-height: 17px; vertical-align: middle; border: 1px solid var(--line); background: var(--panel-2); color: var(--muted); }
.kind-tag.kind-msp { color: var(--text); border-color: var(--text); }
.kind-tag.kind-customer { color: var(--text); background: color-mix(in srgb, var(--accent, #2563eb) 14%, var(--panel)); }
.kind-pick { display: grid; gap: 6px; }
.kind-pick label.check.kind-opt { display: flex; flex-direction: row; flex-wrap: nowrap; align-items: flex-start; gap: 10px; text-align: left; padding: 4px 0; align-self: stretch; }
.kind-pick label.check.kind-opt input { margin-top: 3px; flex: none; }
.kind-pick label.check.kind-opt > span { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.kind-pick label.check.kind-opt small.help { display: block; padding-left: 0; font-weight: 400; }
.note-share { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: space-between; margin: 4px 0; }
ul.notes li.note-internal { border-left: 3px dashed color-mix(in srgb, var(--sev-warning) 70%, var(--line)); padding-left: 8px; }

/* ---------- 1.57: the alarm panel (docked on Alarms, slide-over everywhere else) ---------- */
.alarm-slide-back { position: fixed; inset: 0; background: rgba(0, 0, 0, .28); z-index: 60; }
.alarm-slide { position: fixed; top: 0; right: 0; bottom: 0; width: min(480px, 100vw); background: var(--panel); border-left: 1px solid var(--line); box-shadow: var(--shadow);
  z-index: 61; overflow: auto; padding: 16px 18px calc(24px + env(safe-area-inset-bottom, 0px)); transform: translateX(16px); opacity: .0; transition: transform .16s ease, opacity .16s ease; overflow-wrap: anywhere; }
.alarm-slide.open { transform: none; opacity: 1; }
.alarm-slide:focus { outline: none; }
@media (prefers-reduced-motion: reduce) { .alarm-slide { transition: none; } }
.ap-sev { display: inline-flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.detail-title[class*="edge-"] { margin: 8px 0 6px; }
.ap-now { display: flex; flex-direction: column; gap: 4px; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--panel-2); margin: 6px 0 12px; }
.ap-state.st-down strong { color: var(--sev-critical); }
.ap-state.st-warning strong { color: color-mix(in srgb, var(--sev-warning) 60%, var(--text)); }
.ap-state.ok strong, .ap-state.st-up strong { color: var(--sev-normal); }
.ap-who .badge.handled { background: color-mix(in srgb, var(--sev-info) 18%, transparent); color: var(--text); }
.detail-actions select, .ap-maint select { width: auto; max-width: 100%; }
.ap-graph h3, .ap-obj h3 { display: flex; align-items: baseline; }
.ap-chart { width: 100%; }
.ap-obj { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 4px 12px 2px; margin: 12px 0; }
.ap-obj h3 { margin-top: 10px; }
.ap-pst { font-weight: 700; }
.ap-pst.pst-up { color: var(--sev-normal); } .ap-pst.pst-down { color: var(--sev-critical); } .ap-pst.pst-admin { color: var(--muted); }
.ap-tech, .ap-sent { margin-top: 14px; border-top: 1px solid var(--line); padding-top: 8px; }
.ap-tech > summary, .ap-sent > summary { cursor: pointer; font-weight: 700; font-size: 14px; padding: 4px 0; }

/* the Alarms page: More menu, shortcuts */
.tab-more[aria-selected="true"] { font-weight: 700; }
.tab.kbd-help { margin-left: auto; padding-inline: 10px; }
.kbd-pop { position: absolute; z-index: 70; width: 260px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 10px 12px; }
.kbd-pop table { width: 100%; margin-top: 6px; }
kbd { font-family: var(--mono); font-size: 12px; padding: 1px 6px; border: 1px solid var(--line); border-bottom-width: 2px; border-radius: 4px; background: var(--panel-2); }
.bulk[hidden] { display: none !important; }

/* ---------- 1.57: home by role ---------- */
.home-notices:empty { display: none; }
.home-notices { margin-bottom: 12px; }
.home { display: grid; grid-template-columns: minmax(0, 1.7fr) minmax(280px, 1fr); gap: 16px; align-items: start; }
.home-main, .home-side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.home .panel, .home-queue .panel, .status-board .panel { margin: 0; }
.home > .platform, .home > .status-board { grid-column: 1 / -1; }
.alarm-list { container-type: inline-size; }
@container (max-width: 400px) { .alarm-item { flex-wrap: wrap; } .alarm-item .alarm-text { flex: 1 1 100%; } .alarm-item .sev { min-width: 0; } }
.badge.handled { background: color-mix(in srgb, var(--sev-info) 18%, transparent); color: var(--text); margin-left: 6px; }
.queue-cols { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.queue-col { min-width: 0; }
.queue-head { display: flex; justify-content: space-between; align-items: baseline; }
.queue-head h3 { margin: 4px 0 8px; display: flex; gap: 8px; align-items: center; }
.queue-n { font-size: 12px; font-weight: 700; padding: 0 7px; border-radius: 10px; background: var(--panel-2); color: var(--muted); }
.queue-list { max-height: 480px; overflow: auto; }
.queue-empty { padding: 10px 0; }
.alarm-item .ack-btn { margin-left: auto; align-self: center; flex: none; }
.alarm-item:has(.ack-btn) { flex-wrap: wrap; }
.alarm-item:has(.ack-btn) .alarm-text { flex: 1 1 160px; }
.alarm-item .alarm-text { min-width: 0; }
.prob-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; }
.prob { display: grid; grid-template-columns: auto minmax(0, 1fr) auto; gap: 10px; align-items: start; padding: 8px 0; border-top: 1px solid var(--grid); }
.prob:first-child { border-top: 0; }
.prob-who { text-align: right; white-space: nowrap; }
.maint-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.maint-list li.ends-soon a { font-weight: 700; }
.health-slim .health-line { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; margin-bottom: 8px; }
.health-slim .health-bar { margin-bottom: 0; height: 8px; }
.traps-line { margin: 0; }
.home-queue { display: flex; flex-direction: column; gap: 10px; margin: 16px 0; }
.platform-head { margin: 8px 0 12px; font-size: 15px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.platform-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; margin-bottom: 16px; }
.platform-grid > div:empty { display: none; }
.platform-grid .panel { margin: 0; }
@media (max-width: 900px) { .home { grid-template-columns: 1fr; } }

/* the status board (viewers, customers, the wallboard) */
.status-board { display: flex; flex-direction: column; gap: 16px; }
.sb-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: 12px; }
.sb-tile { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px 16px; box-shadow: inset 0 4px 0 var(--edge, var(--line)); display: flex; flex-direction: column; }
.sb-up { --edge: var(--sev-normal); } .sb-degraded { --edge: var(--sev-major); } .sb-down { --edge: var(--sev-critical); } .sb-paused { --edge: var(--sev-info); }
.sb-n { font-size: 34px; font-weight: 800; line-height: 1.1; }
.sb-l { color: var(--muted); font-size: 13px; text-transform: uppercase; letter-spacing: .05em; }
.sb-cols { display: grid; grid-template-columns: minmax(0, 1.6fr) minmax(280px, 1fr); gap: 16px; align-items: start; }
.sb-side { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
@media (max-width: 900px) { .sb-cols { grid-template-columns: 1fr; } }

/* the wallboard: no menu, no top bar, large type */
body.board-mode .sidebar, body.board-mode .topbar { display: none !important; }
body.board-mode .app { display: block; }
body.board-mode .main { padding: 20px max(24px, env(safe-area-inset-right, 0px)) 24px max(24px, env(safe-area-inset-left, 0px)); max-width: none; }
.board-head { display: flex; align-items: baseline; gap: 20px; margin-bottom: 18px; }
.board-head h1 { font-size: 34px; }
.board-clock { color: var(--muted); font-size: 20px; }
.board-exit { margin-left: auto; color: var(--muted); }
.status-board.big { font-size: 19px; }
.status-board.big .sb-n { font-size: 64px; }
.status-board.big .sb-l { font-size: 16px; }
.status-board.big h2 { font-size: 22px; }
.status-board.big .small { font-size: 15px; }

/* ---------- 1.58: quick-jump ---------- */
.qj-open { display: inline-flex; align-items: center; gap: 8px; align-self: center; padding: 7px 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel-2); color: var(--muted); cursor: pointer; font: inherit; font-size: 14px; }
.qj-open:hover { color: var(--text); background: var(--btn-hover); }
.qj-open-k { font-size: 11px; }
@media (max-width: 900px) { .qj-open-l, .qj-open-k { display: none; } }
.qj-back { position: fixed; inset: 0; z-index: 80; background: rgba(0, 0, 0, .35); display: flex; justify-content: center; align-items: flex-start;
  padding: max(10vh, env(safe-area-inset-top, 0px)) max(16px, env(safe-area-inset-right, 0px)) 16px max(16px, env(safe-area-inset-left, 0px)); }
.qj-box { width: min(640px, 100%); background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); display: flex; flex-direction: column; max-height: 72vh; overflow: hidden; }
.qj-input { border: 0; border-bottom: 1px solid var(--line); border-radius: 0; font-size: 17px; padding: 14px 16px; background: transparent; }
.qj-input:focus { outline: none; border-color: var(--line); }
.qj-list { overflow: auto; padding: 6px 0; }
.qj-group { font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); padding: 10px 16px 4px; }
.qj-item { display: flex; align-items: baseline; gap: 10px; padding: 7px 16px; cursor: pointer; min-width: 0; }
.qj-item.on { background: var(--btn-hover); box-shadow: inset 3px 0 0 var(--focus); }
.qj-kind { font-size: 12px; color: var(--muted); min-width: 64px; }
.qj-item .sev { min-width: 64px; }
.qj-title { font-weight: 600; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; }
.qj-sub { color: var(--muted); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; flex: 1; }
.qj-empty { padding: 14px 16px; margin: 0; }
.qj-foot { display: flex; gap: 14px; padding: 8px 16px; border-top: 1px solid var(--line); }
.qj-foot kbd { margin-right: 3px; }

/* ---------- 1.58: since you were last here ---------- */
.review .rv-tools { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin-bottom: 8px; }
.review .seg.small button { font-size: 12px; padding: 3px 8px; }
.rv-counts { list-style: none; margin: 0 0 6px; padding: 0; display: flex; flex-wrap: wrap; gap: 6px 14px; font-size: 14px; }
.rv-sec { border-top: 1px solid var(--grid); padding: 4px 0; }
.rv-sec > summary { cursor: pointer; font-weight: 600; font-size: 14px; padding: 4px 0; }
.rv-list { list-style: none; margin: 0; padding: 0 0 6px; display: flex; flex-direction: column; gap: 4px; }
.rv-line { font-size: 14px; overflow-wrap: anywhere; }
.rv-empty { margin: 4px 0 0; }
.home-queue + .review, .review { margin-top: 0; }

/* ---------- 1.59: circuits ---------- */
.imp { display: inline-block; min-width: 26px; text-align: center; font-size: 12px; font-weight: 800; padding: 1px 5px; border-radius: 4px; background: var(--panel-2); border: 1px solid var(--line); }
.imp-1 { background: color-mix(in srgb, var(--sev-critical) 22%, transparent); border-color: color-mix(in srgb, var(--sev-critical) 50%, transparent); }
.imp-2 { background: color-mix(in srgb, var(--sev-major) 20%, transparent); border-color: color-mix(in srgb, var(--sev-major) 45%, transparent); }
.imp-3 { background: color-mix(in srgb, var(--sev-minor) 16%, transparent); }
.dot.st-up { background: var(--sev-normal); } .dot.st-down { background: var(--sev-critical); } .dot.st-warning { background: var(--sev-warning); } .dot.st-unknown { background: var(--line); }
.circuits .dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; vertical-align: middle; }
.circuit-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; margin-bottom: 16px; }
.circuit-grid .panel { margin: 0; }
.ends { list-style: none; margin: 0 0 8px; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.ckt-ends { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 12px; margin: 12px 0; }
.ckt-end { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.ckt-end .end-row { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.ckt-riders .check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 4px 12px; }
.ckt-chip { display: inline-block; margin: 3px 4px 0 0; font-size: 11px; font-weight: 700; padding: 1px 6px; border-radius: 10px; background: color-mix(in srgb, var(--sev-info) 16%, transparent); color: var(--text); font-family: var(--mono); }
.ap-circuit, .ap-maint { font-size: 14px; }
.badge.maint-badge { background: color-mix(in srgb, var(--sev-info) 18%, transparent); color: var(--text); margin-left: 6px; }
.badge.maint-badge.running { box-shadow: inset 3px 0 0 var(--sev-info); }
.import-out { margin-top: 10px; }

/* ---------- 1.59: maintenance calendar ---------- */
:root { --eff-suppress: #6f7f95; --eff-quiet: #5c9ef0; --eff-record: #2bb3a3; }
:root[data-theme="light"] { --eff-suppress: #64748b; --eff-quiet: #2a74d6; --eff-record: #14917f; }
.cal-bar { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 10px; }
.cal-bar .grow { flex: 1; }
.cal-title { margin: 0 6px; font-size: 18px; }
.cal-bar input[type=month], .cal-bar input[type=date] { width: auto; }
.cal-filters { margin-bottom: 12px; }
.cal-month { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--line); gap: 1px; }
.cal-dow { background: var(--panel-2); padding: 6px 8px; font-size: 12px; font-weight: 700; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.cal-day { background: var(--panel); min-height: 108px; padding: 4px 6px 6px; display: flex; flex-direction: column; gap: 3px; min-width: 0; cursor: default; }
.cal-day[tabindex="0"] { cursor: cell; }
.cal-day.other { background: var(--panel-2); }
.cal-day.other .cal-num { opacity: .55; }
.cal-day.today .cal-num button { background: var(--focus); color: var(--primary-text); border-radius: 10px; padding: 0 7px; }
.cal-num { font-size: 13px; font-weight: 700; }
.cal-chip { display: flex; gap: 6px; align-items: baseline; width: 100%; min-width: 0; text-align: left; font: inherit; font-size: 12px; border: 0; border-radius: 4px; padding: 2px 6px; cursor: pointer;
  color: var(--text); background: color-mix(in srgb, var(--eff, var(--line)) 22%, var(--panel)); box-shadow: inset 3px 0 0 var(--eff, var(--line)); }
.cal-chip:hover { filter: brightness(1.08); }
.cal-chip .cal-time { color: var(--muted); flex: none; }
.cal-chip .cal-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; min-width: 0; font-weight: 600; }
.eff-suppress { --eff: var(--eff-suppress); } .eff-quiet { --eff: var(--eff-quiet); } .eff-record { --eff: var(--eff-record); }
.cal-chip.running { background-image: repeating-linear-gradient(135deg, transparent 0 6px, color-mix(in srgb, var(--eff) 22%, transparent) 6px 10px); }
.cal-chip.cancelled .cal-name, .cal-arow.cancelled strong { text-decoration: line-through; opacity: .65; }
.cal-chip.log { --eff: var(--c-other); font-style: italic; }
.cal-msp { font-size: 10px; font-weight: 800; padding: 0 4px; border-radius: 3px; background: var(--panel-2); color: var(--muted); flex: none; }
.cal-more { text-align: left; color: var(--muted); }
.cal-legend { display: flex; gap: 14px; flex-wrap: wrap; margin-top: 10px; color: var(--muted); }
.cal-legend span { display: inline-flex; align-items: center; gap: 6px; }
.cal-sw { display: inline-block; width: 12px; height: 12px; border-radius: 3px; background: var(--eff, var(--line)); }
.cal-sw.running { background: repeating-linear-gradient(135deg, var(--line) 0 3px, transparent 3px 6px); border: 1px solid var(--line); }
.cal-sw.log { background: var(--c-other); }
.cal-tgrid { border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden; background: var(--panel); }
.cal-thead { display: grid; grid-template-columns: 56px repeat(var(--days), minmax(0, 1fr)); border-bottom: 1px solid var(--line); background: var(--panel-2); }
.cal-thday { padding: 6px 8px; font-size: 13px; font-weight: 700; border-left: 1px solid var(--line); }
.cal-thday.today { color: var(--focus); }
.cal-tscroll { display: grid; grid-template-columns: 56px minmax(0, 1fr); max-height: 70vh; overflow: auto; }
.cal-hours .cal-hour { font-size: 11px; color: var(--muted); text-align: right; padding: 0 6px; border-top: 1px solid var(--grid); box-sizing: border-box; }
.cal-tcols { display: grid; grid-template-columns: repeat(var(--days), minmax(0, 1fr)); }
.cal-tcol { position: relative; border-left: 1px solid var(--line); background-image: repeating-linear-gradient(to bottom, var(--grid) 0 1px, transparent 1px 40px); user-select: none; }
.cal-block { position: absolute; flex-direction: column; align-items: stretch; overflow: hidden; padding: 3px 6px; }
.cal-block .cal-name { white-space: normal; }
.cal-sel { position: absolute; left: 2px; right: 2px; background: color-mix(in srgb, var(--focus) 25%, transparent); border: 1px dashed var(--focus); border-radius: 4px; pointer-events: none; }
.cal-now { position: absolute; left: 0; right: 0; height: 2px; background: var(--sev-critical); pointer-events: none; z-index: 2; }
.cal-agenda { display: flex; flex-direction: column; gap: 12px; }
.cal-aday h3 { margin: 0 0 6px; }
.cal-aday ul { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.cal-arow { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 12px; box-shadow: inset 4px 0 0 var(--eff); cursor: pointer; overflow-wrap: anywhere; }
.cal-when { display: block; font-size: 13px; color: var(--muted); }
.maint-items ul { margin: 2px 0 8px; padding-left: 18px; }
.maint-occ tr.current td { font-weight: 700; }
.maint-form fieldset { margin-top: 12px; }
.mf-days { display: flex; flex-wrap: wrap; gap: 4px 14px; margin-top: 8px; }
.mf-effects { display: grid; gap: 8px; }
.mf-results ul { list-style: none; margin: 6px 0; padding: 0; max-height: 220px; overflow: auto; display: flex; flex-direction: column; gap: 4px; }
.mf-items { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; }
.mf-chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 4px 2px 8px; border-radius: 12px; background: var(--panel-2); border: 1px solid var(--line); font-size: 13px; max-width: 100%; }
.mf-rem input { width: 100%; }
.mf-preview { margin-top: 12px; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel-2); }
.mf-preview h4 { margin: 0 0 6px; }
.callout.warn { border-left: 4px solid var(--sev-major); }
.maint-banner { margin: 8px 0; }
.maint-banner.running { border-left: 4px solid var(--eff-quiet); }
.btn-select { width: auto; }
@media (max-width: 700px) { .cal-day { min-height: 70px; padding: 2px 3px; } .cal-chip .cal-time { display: none; } .cal-chip { font-size: 11px; padding: 1px 3px; } .cal-dow { padding: 4px 2px; font-size: 10px; } }
.mf-opt { display: flex !important; gap: 10px; align-items: flex-start; padding: 8px 10px; border: 1px solid var(--line); border-radius: var(--radius-sm); cursor: pointer; }
.mf-opt input { width: auto; margin-top: 3px; flex: none; }
.mf-opt span { display: flex; flex-direction: column; gap: 2px; }
.mf-opt:has(input:checked) { border-color: var(--focus); background: color-mix(in srgb, var(--focus) 8%, transparent); }
.map-link.degraded .wire { stroke: var(--sev-major); stroke-width: 3; stroke-dasharray: 6 4; } /* 1.59: a circuit with one end down */

/* 1.60: traffic for customers */
.pubip-add .row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; margin: 6px 0 4px; }
.pubip-add .row input { flex: 1; min-width: 200px; }
.pubip-add textarea { width: 100%; }
.flow-share fieldset { margin-top: 12px; }
.fs-ifs { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 2px 16px; max-height: 320px; overflow: auto; padding: 4px 0; }
.fs-ifs.dim { opacity: .5; }
.fs-bar { display: inline-block; width: 60px; margin-left: 6px; vertical-align: middle; }
.cust-traffic .msp-only { border-left: 3px solid var(--line); padding-left: 8px; }
.cust-traffic tr.selected td { background: var(--hover, rgba(127,127,127,.08)); }
.cust-scroll { overflow-x: auto; max-width: 100%; }
.cust-traffic .panel, .cust-traffic .top-panel { min-width: 0; }

/* 1.61: BGP flags, the Type column, the label shown instead of the AS name */
.bgp-imp { color: var(--sev-minor); font-size: 14px; }
.bgp-imp.down { color: var(--danger); }
.bgp-chips { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 2px; }
.bgp-flag { font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 10px; border: 1px solid var(--line); white-space: nowrap; }
.bgp-flag.important { border-color: var(--sev-minor); }
.bgp-flag.maybe { color: var(--muted); }
.bgp-type { font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 10px; background: var(--panel-2); border: 1px solid var(--line); white-space: nowrap; }
.as-pill { font: 600 11px var(--mono, monospace); padding: 1px 6px; border-radius: 10px; border: 1px solid var(--line); background: var(--panel-2); color: var(--muted); cursor: pointer; }
.as-pill:hover { color: var(--text); }
.as-shown { font-weight: 600; }
.bgp-imp-badge { border-color: var(--sev-minor); }
.imp-bgp .rv-line .status { display: inline-flex; vertical-align: middle; }

/* 1.62: a VM's vSphere card on its own Overview */
.vm-states { display: flex; gap: 6px; flex-wrap: wrap; margin: 0 0 10px; }
.vm-card .vm-figs { margin-bottom: 8px; }
/* 1.62: Ports: sortable headings, Juniper FPC / PIC groups, logical units under their port */
.ports-table th[aria-sort="ascending"], .ports-table th[aria-sort="descending"] { color: var(--text); }
.ports-table tr.port-group td { background: var(--panel-2, color-mix(in srgb, var(--text) 5%, transparent)); padding-top: 6px; padding-bottom: 6px; }
.ports-table tr.port-group.pic td { padding-left: 22px; background: color-mix(in srgb, var(--text) 2.5%, transparent); }
.ports-table .port-fold { all: unset; cursor: pointer; display: inline-flex; align-items: baseline; gap: 2px; }
.ports-table .port-fold:focus-visible { outline: 2px solid var(--link); outline-offset: 2px; border-radius: 3px; }
.ports-table tr.port-unit td:nth-child(2) strong, .ports-table tr.port-unit td:first-child:not(.sel) strong { padding-left: 18px; font-weight: 500; }
/* 1.62: map lines with shapes, bend points, the hover graph and the line's pane */
.map-link .wire { fill: none; }
.map-pt { fill: var(--panel); stroke: var(--focus); stroke-width: 2.5; cursor: grab; }
.map-pt.selected, .map-pt:focus-visible { fill: var(--focus); outline: none; }
.map-grid .grid-major { stroke: color-mix(in srgb, var(--muted) 22%, transparent); stroke-width: 1; fill: none; pointer-events: none; }
.map-wrap { position: relative; }
.map-hover { position: absolute; z-index: 5; pointer-events: none; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: 0 6px 22px rgb(0 0 0 / .18); padding: 8px 10px; font-size: 12px; width: 300px; }
.map-hover .mh-title { margin-bottom: 4px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mh-spark { display: block; }
.mh-spark .mh-in { stroke: var(--series-1); stroke-width: 1.6; fill: none; }
.mh-spark .mh-in-area { fill: color-mix(in srgb, var(--series-1) 16%, transparent); stroke: none; }
.mh-spark .mh-out { stroke: var(--t2); stroke-width: 1.6; fill: none; }
.mh-spark .mh-axis, .mh-spark .mh-empty { fill: var(--muted); font: 10px var(--font); }
.mh-legend { margin-top: 2px; color: var(--muted); }
.mh-k { font-weight: 600; } .mh-k.in { color: var(--series-1); } .mh-k.out { color: var(--t2); }
.link-ends { display: grid; gap: 2px; margin-bottom: 8px; }
.link-end { display: flex; gap: 4px; align-items: center; flex-wrap: wrap; }
.link-chart-box { height: 180px; }
.map-side .btn-row .seg + .seg { margin-left: 6px; }

/* 1.63: Create new › Test */
.cred-test { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 4px 0 10px; }
.cred-test input[type=text] { flex: 1 1 200px; width: auto; max-width: 320px; }
.cred-test p { flex-basis: 100%; margin: 0; }
/* 1.63: the back of a NAS unit and its fans; expansion units */
.nas-rear { width: 100%; display: block; margin-top: 6px; }
.nas-fan circle { fill: var(--panel); stroke: var(--muted); stroke-width: 2; }
.nas-fan line { stroke: var(--muted); stroke-width: 2; stroke-linecap: round; }
.nas-fan.ok circle, .nas-fan.ok line { stroke: var(--ok); }
.nas-fan.bad circle, .nas-fan.bad line { stroke: var(--danger); }
.nas-rear-wrap p { margin: 2px 0 10px; }
.nas-encl-kind { margin: 10px 0 4px; font-weight: 600; color: var(--muted); }
/* 1.63: poller deployment */
.deploy-preview { max-height: 360px; overflow: auto; white-space: pre; font-size: 12px; }
.deploy-files { margin: 8px 0; flex-wrap: wrap; }
.join-watch { margin: 10px 0 4px; }
.join-watch .spinner-dot { display: inline-block; width: 8px; height: 8px; border-radius: 50%; background: var(--muted); animation: joinpulse 1.2s ease-in-out infinite; }
@keyframes joinpulse { 50% { opacity: .25; } }
@media (prefers-reduced-motion: reduce) { .join-watch .spinner-dot { animation: none; } }

/* 1.64: map link ends, both ends down, parallel links, bend handles, drawing items, icons, the library */
.map-link .end-dot, .map-marks .end-dot { stroke: var(--panel); stroke-width: 1.5; }
.map-link .end-dot.es-up, .map-marks .end-dot.es-up { fill: var(--sev-normal); }
.map-link .end-dot.es-down, .map-link .end-dot.es-unknown, .map-marks .end-dot.es-down, .map-marks .end-dot.es-unknown { fill: var(--muted); }
.map-link .end-dot.es-admin, .map-marks .end-dot.es-admin { fill: var(--panel); stroke: var(--muted); stroke-width: 1.5; }
.map-link.both-down .wire { stroke: var(--sev-critical); stroke-width: 3; stroke-dasharray: 2 5; stroke-linecap: round; }
.end-word { font-weight: 600; } .end-word.es-up { color: var(--sev-normal); } .end-word.es-down, .end-word.es-unknown, .end-word.es-admin { color: var(--muted); }
.map-pt.mid { fill: var(--panel); stroke: var(--focus); stroke-width: 1.5; stroke-dasharray: 2 2; cursor: copy; }
.map-menu { position: absolute; z-index: 30; display: flex; flex-direction: column; gap: 2px; padding: 4px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 6px 18px rgb(0 0 0 / 0.18); }
.map-menu .btn { justify-content: flex-start; text-align: left; }
.pair-step { align-items: center; margin: -4px 0 6px; }
.bend-hint { margin: 6px 0; }
.map-svg.drawing { cursor: crosshair; }
.draw-tools { gap: 4px; align-items: center; }
.map-item { cursor: default; }
.map-shell.editing .map-item { cursor: move; }
.map-shell.editing .map-item.locked { cursor: not-allowed; }
.map-item .hit { stroke: transparent; stroke-width: 12; }
.map-item.selected .shape { filter: drop-shadow(0 0 2px var(--focus)); }
.map-text { white-space: pre; font-family: var(--font); }
.item-handles .sel-box { fill: none; stroke: var(--focus); stroke-width: 1; stroke-dasharray: 4 3; vector-effect: non-scaling-stroke; pointer-events: none; }
.item-handles .map-handle { fill: var(--panel); stroke: var(--focus); stroke-width: 1.5; vector-effect: non-scaling-stroke; cursor: nwse-resize; }
.item-handles .map-handle.rot { cursor: grab; }
.item-handles .rot-stem { stroke: var(--focus); stroke-width: 1; vector-effect: non-scaling-stroke; pointer-events: none; }
.icon-ring { fill: var(--panel); stroke: var(--muted); stroke-width: 3; }
.icon-ring.st-up { stroke: var(--sev-normal); } .icon-ring.st-down { stroke: var(--sev-critical); } .icon-ring.st-warning { stroke: var(--sev-warning); } .icon-ring.st-degraded { stroke: var(--sev-minor); }
.icon-ring.st-paused, .icon-ring.st-unknown, .icon-ring.st-offline { stroke-dasharray: 4 3; }
.icon-preview { width: 32px; height: 32px; object-fit: contain; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); }
.lib-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 10px; max-height: 46vh; overflow: auto; margin: 8px 0; }
.lib-item { border: 1px solid var(--line); border-radius: var(--radius); padding: 6px; display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.lib-item .small { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.lib-pick { display: block; height: 90px; padding: 4px; border: 0; background: color-mix(in srgb, var(--line) 30%, transparent); border-radius: 6px; cursor: pointer; }
.lib-pick img { width: 100%; height: 100%; object-fit: contain; }
.lib-pick:hover, .lib-pick:focus-visible { outline: 2px solid var(--focus); }
/* 1.64: poller health */
.h-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 10px; margin: 8px 0; }
.h-tile { border: 1px solid var(--line); border-radius: var(--radius); padding: 8px 10px; min-width: 0; }
.h-tile.warn { border-color: var(--sev-warning); background: color-mix(in srgb, var(--sev-warning) 8%, transparent); }
.h-tile .h-val { font-size: 20px; font-weight: 650; }
.h-tile .small { overflow: hidden; text-overflow: ellipsis; }
.h-chart { height: 220px; margin: 6px 0 12px; }
.rules-grid { display: flex; flex-direction: column; gap: 8px; margin: 6px 0; }
.rule-row { display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); padding-bottom: 6px; }
.rule-parts { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.rule-part input { width: 90px; }
.poller-health-line { margin-top: 2px; }
.warn-text { color: var(--sev-minor); font-weight: 600; }
/* 1.64: drawing panel rows and hidden rule forms */
.rules-grid[hidden] { display: none; }
.map-side .field.inline { display: flex; flex-direction: row; align-items: center; justify-content: space-between; gap: 8px; margin-bottom: 8px; }
.map-side .field.inline > label { flex: 1; margin: 0; text-align: left; font-weight: 500; }
.map-side .field.inline > input[type=number], .map-side .field.inline > select { flex: none; width: 104px; }
.map-side .field.inline > input[type=color] { flex: none; width: 44px; height: 30px; padding: 2px; }
.map-side label.check { display: flex; flex-wrap: nowrap; align-items: flex-start; gap: 8px; text-align: left; margin: 4px 0 10px; }
.map-side label.check input { flex: none; margin-top: 2px; }
.map-side .btn { margin: 0 4px 6px 0; }
.map-side label.check > span { flex: 1; min-width: 0; }
/* 1.65: link ends and labels above devices; movable in Edit */
.map-marks .end-dot.es-none { fill: var(--panel); stroke: var(--muted); stroke-width: 1.5; }
.map-shell.editing .map-marks .movable { cursor: grab; }
.map-shell.editing .map-marks .end-dot.movable { r: 6; }
/* 1.65: Windows DHCP and DNS */
.bar-mini { display: inline-block; width: 60px; height: 6px; border-radius: 3px; background: var(--line); vertical-align: middle; overflow: hidden; }
.bar-mini > span { display: block; height: 100%; background: var(--sev-normal); }
.bar-mini > span.warn { background: var(--sev-warning, #d4a106); }
.bar-mini > span.crit { background: var(--sev-critical, #c62828); }
.dhcp-counts { display: flex; flex-wrap: wrap; gap: 6px 20px; margin: 4px 0 10px; font-size: 13px; }
.dhcp-counts strong { font-size: 15px; }
.conflict-mark { color: var(--sev-warning, #d4a106); cursor: help; }
.dhcp-info p { margin: 2px 0; }
.dhcp-setup .check-col { margin-bottom: 8px; }
[hidden] { display: none !important; } /* 1.65: elements hidden by script stay hidden whatever their display */

/* 1.66: the dashboard's first load, then cards that update in place */
.home-skeleton { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; }
.skel-card { height: 180px; border-radius: var(--radius); background: var(--panel); border: 1px solid var(--line); opacity: .6; }
.dash-slot:empty { display: none; }
.grey-note { margin-left: 6px; }
.snmp-browser .toolbar .tool.grow input { width: 100%; }
.snmp-result .ran { margin: 6px 0; }
.trust-control { display: grid; gap: 8px; }
.inline-row { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.inline-row input { flex: 1 1 240px; min-width: 0; }
/* 1.66: UPS and Synology UC panels */
.ups-top { display: flex; flex-wrap: wrap; gap: 18px; margin: 8px 0 12px; }
.ups-top > div { min-width: 120px; }
.ups-val { font-size: 1.4em; font-weight: 600; }
.ups-bar { height: 6px; background: var(--line); border-radius: 3px; overflow: hidden; margin-top: 4px; }
.ups-bar span { display: block; height: 100%; background: currentColor; }
.ups-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 12px; }
.uc-ctls { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; margin-bottom: 12px; }
.uc-ctl { border: 1px solid var(--line); border-radius: var(--radius); padding: 10px 12px; }
.uc-ctl.uc-down { border-color: var(--bad, #c33); }
/* 1.67: the firewall tab's logs */
.firewall-panel .log-lines { max-height: 520px; overflow: auto; font-size: 12px; line-height: 1.45; white-space: pre-wrap; word-break: break-all; background: var(--panel-2); border: 1px solid var(--line); padding: 8px 10px; border-radius: var(--radius-sm); font-family: var(--mono); }
.firewall-panel .subtabs { margin-bottom: 10px; }
/* 1.68: the device import dialog */
.import-export { margin-top: 14px; }
.import-export .import-pick { max-height: 220px; overflow: auto; border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 6px 8px; margin-top: 6px; }
.import-export input[type=search] { width: 100%; margin-top: 8px; }
.import-result .table-wrap { max-height: 320px; overflow: auto; }
/* 1.68: integration alert levels */
.vc-levels { margin-top: 20px; }
.vc-levels table.levels input[type=number] { width: 6em; }
.level-own { margin-left: 6px; font-size: 11px; padding: 1px 6px; border-radius: 999px; background: color-mix(in srgb, var(--link) 16%, transparent); color: var(--text); font-weight: 600; }
.level-dialog { display: flex; flex-direction: column; gap: 14px; min-width: min(460px, 100%); }
.level-row { display: flex; flex-direction: column; gap: 6px; }
.level-nums { display: flex; flex-wrap: wrap; gap: 14px; }
.level-nums input { width: 6em; }
/* 1.69: silent shared poller */
.silent-badge { margin-left: 6px; }
/* 1.69: carriers */
.list-edit { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.list-edit .list-row { display: flex; flex-wrap: wrap; gap: 6px; width: 100%; }
.list-edit .list-row input { flex: 1 1 140px; min-width: 0; }
ol.escalation { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 8px; }
ul.plain { list-style: none; margin: 0; padding: 0; }
/* 1.69: Troubleshooting */
.ts-tabs { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 12px; }
.ts-tabs .tab { border: 1px solid var(--line); background: transparent; color: var(--text); padding: 6px 12px; border-radius: 6px; cursor: pointer; font: inherit; }
.ts-tabs .tab.active { background: var(--link); color: var(--bg, #fff); border-color: var(--link); }
.ts-layout { display: grid; grid-template-columns: minmax(0, 1fr) 280px; gap: 16px; align-items: start; }
@media (max-width: 1100px) { .ts-layout { grid-template-columns: minmax(0, 1fr); } }
.ts-main { display: flex; flex-direction: column; gap: 16px; min-width: 0; }
.ts-fields { display: flex; flex-direction: column; gap: 12px; }
.ts-places .ts-place-tools { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-bottom: 8px; }
.ts-place-list { display: flex; flex-wrap: wrap; gap: 12px 24px; max-height: 260px; overflow: auto; }
.ts-group { display: flex; flex-direction: column; gap: 2px; min-width: 200px; }
.ts-group-name { font-size: 12px; text-transform: uppercase; letter-spacing: .04em; color: var(--muted); margin-bottom: 2px; }
.ts-cards { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 12px; }
.ts-cards.wide { grid-template-columns: repeat(auto-fill, minmax(460px, 1fr)); }
@media (max-width: 600px) { .ts-cards, .ts-cards.wide { grid-template-columns: minmax(0, 1fr); } }
.ts-card { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.ts-card-head { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.ts-mini-chart { height: 120px; }
.ts-live-chart { height: 280px; }
.ts-chip { display: inline-block; font-size: 11px; font-weight: 600; padding: 1px 7px; border-radius: 999px; }
.ts-ok { background: color-mix(in srgb, var(--ok) 18%, transparent); color: var(--ok); }
.ts-warn { background: color-mix(in srgb, var(--sev-minor) 22%, transparent); color: var(--text); }
.ts-bad { background: color-mix(in srgb, var(--danger) 18%, transparent); color: var(--danger); }
.ts-info { background: color-mix(in srgb, var(--sev-info) 16%, transparent); color: var(--text); }
tr.ts-differs td { background: color-mix(in srgb, var(--sev-minor) 10%, transparent); }
.ts-items { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
code.ts-record { display: inline-block; margin-top: 2px; font-size: 12px; white-space: pre-wrap; word-break: break-all; color: var(--muted); }
pre.ts-raw { max-height: 360px; overflow: auto; font-size: 12px; white-space: pre-wrap; word-break: break-all; }
.ts-bar { display: flex; height: 10px; border-radius: 5px; overflow: hidden; margin: 4px 0; }
.ts-seg { min-width: 2px; }
.ts-seg.dns { background: var(--sev-info); } .ts-seg.con { background: var(--ok); } .ts-seg.tls { background: var(--threat); } .ts-seg.wait { background: var(--sev-minor); } .ts-seg.dl { background: var(--muted); }
.ts-recent h2 { margin-top: 0; }
.ts-recent-list { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 8px; }
.ts-cert { border-top: 1px solid var(--line); padding-top: 6px; }
.ts-links .btn.small { padding: 1px 8px; }
.ts-mail-area h3, .ts-result h3 { margin: 14px 0 6px; font-size: 14px; }
/* 1.69: APC PDU */
.pdu-bar { position: relative; height: 8px; background: var(--panel-2); border-radius: 4px; }
.pdu-bar > span { display: block; height: 100%; border-radius: 4px; background: currentColor; }
.pdu-mark { position: absolute; top: -3px; width: 2px; height: 14px; background: var(--sev-minor); }
.pdu-mark.over { background: var(--danger); }
.pdu-outlets { display: grid; grid-template-columns: repeat(auto-fill, minmax(130px, 1fr)); gap: 8px; }
.pdu-outlet { border: 1px solid var(--line); border-radius: 6px; padding: 6px 8px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.pdu-outlet.off { border-color: color-mix(in srgb, var(--danger) 50%, var(--line)); }
.powered-by:empty { display: none; }

/* 1.70: Security (CVE monitor) */
.cve-status { margin: 0 0 12px; color: var(--muted); }
.cve-cards { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 14px; }
.cve-card { display: flex; flex-direction: column; align-items: flex-start; gap: 2px; min-width: 110px; padding: 10px 14px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); color: var(--text); font: inherit; text-align: left; }
.cve-card:not(:disabled) { cursor: pointer; }
.cve-card:not(:disabled):hover { background: var(--btn-hover); }
.cve-card strong { font-size: 22px; font-variant-numeric: tabular-nums; line-height: 1.1; }
.cve-card span { color: var(--muted); font-size: 13px; }
.cve-card.kev strong, .cve-card.crit strong { color: var(--sev-critical); }
.cve-card.high strong { color: var(--sev-major); }
.cve-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 0 0 12px; }
.cve-filters select { width: auto; max-width: 100%; }
.cve-filters input[type=search] { width: auto; min-width: 200px; flex: 1 1 220px; }
.cve-sev { display: inline-flex; align-items: baseline; gap: 4px; padding: 1px 8px; border-radius: 999px; font-size: 12.5px; font-weight: 600; white-space: nowrap; border: 1px solid currentColor; }
.cve-sev .cve-score { font-weight: 400; font-variant-numeric: tabular-nums; }
.cve-critical { color: var(--sev-critical); }
.cve-high { color: var(--sev-major); }
.cve-medium { color: var(--sev-minor); }
.cve-low { color: var(--sev-info); }
.cve-unknown { color: var(--muted); }
.cve-kev { display: inline-block; padding: 1px 7px; border-radius: 999px; background: var(--sev-critical); color: #fff; font-size: 11.5px; font-weight: 700; letter-spacing: .02em; vertical-align: 1px; }
.cve-sum { max-width: 60ch; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.cve-table td { vertical-align: top; }
.cve-cover { margin-top: 16px; }
.cve-cover > summary { cursor: pointer; padding: 4px 0; }
.cve-reasons { margin: 8px 0; padding-left: 18px; }
.cve-dialog .table-wrap { margin-top: 8px; }
.sw-cell { display: inline-flex; gap: 6px; align-items: center; max-width: 100%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cve-count { display: inline-block; min-width: 18px; padding: 0 5px; border-radius: 999px; background: var(--sev-major); color: #fff; font-size: 11.5px; font-weight: 700; text-align: center; text-decoration: none; }
.check-inline { display: inline-flex; align-items: center; gap: 4px; }

/* 1.70.1: a check in progress */
.cve-progress { margin: 0 0 12px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); }
.cve-progress-head { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.cve-progress p { margin: 8px 0 0; }
.cve-bar { margin-top: 10px; height: 6px; border-radius: 3px; background: var(--line); overflow: hidden; }
.cve-bar > span { display: block; height: 100%; background: var(--primary-bg); border-radius: 3px; transition: width .4s ease; }
.cve-spin { width: 14px; height: 14px; border-radius: 50%; border: 2px solid var(--line); border-top-color: var(--primary-bg); animation: cvespin .9s linear infinite; }
@keyframes cvespin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .cve-bar > span { transition: none; } .cve-spin { animation: none; } }

/* 1.71: Security by device, sortable headings */
.cve-view { margin-left: auto; display: inline-flex; gap: 0; }
.cve-view .btn { border-radius: 0; }
.cve-view .btn:first-child { border-radius: var(--radius) 0 0 var(--radius); }
.cve-view .btn:last-child { border-radius: 0 var(--radius) var(--radius) 0; }
.cve-view .btn.active { background: var(--primary-bg); color: var(--primary-text); border-color: var(--primary-bg); }
.th-sort { all: unset; cursor: pointer; font-weight: inherit; white-space: nowrap; }
.th-sort:focus-visible { outline: 2px solid var(--primary-bg); outline-offset: 2px; }
.th-arrow { color: var(--muted); }
.cve-twisty { width: 18px; color: var(--muted); }
.cve-sub > td { background: var(--bg); padding-top: 0; }
.cve-counts { display: flex; flex-wrap: wrap; gap: 4px; }
.cve-n { padding: 0 7px; border: 1px solid currentColor; border-radius: 999px; font-size: 12px; white-space: nowrap; }
.cve-foot { padding: 8px 12px; margin: 0; }
/* 1.71 Troubleshooting: form head with help, Run from panel, DNS advanced, root-trace diagram, keep-ping totals */
.ts-form-head { display: flex; align-items: baseline; gap: 10px; margin-bottom: 10px; }
.ts-form-head h2 { margin: 0; }
.ts-help-btn { margin-left: auto; width: 28px; height: 28px; padding: 0; border-radius: 999px; font-weight: 700; }
.ts-help section + section { margin-top: 12px; }
.ts-help h3 { margin: 0 0 4px; font-size: 14px; }
.ts-help p { margin: 0; max-width: 65ch; line-height: 1.5; }
.ts-runfrom { border: 1px solid var(--line); border-radius: var(--radius-sm); margin: 12px 0; background: var(--panel-2); }
.ts-runfrom > summary { cursor: pointer; padding: 8px 12px; list-style-position: inside; }
.ts-runfrom-label { font-weight: 600; }
.ts-runfrom-what { color: var(--muted); }
.ts-runfrom-none .ts-runfrom-what { color: var(--danger); }
.ts-runfrom[open] > summary { border-bottom: 1px solid var(--line); }
.ts-runfrom .ts-places { border: 0; margin: 0; padding: 10px 12px; }
.ts-advanced { margin: 12px 0; }
.ts-advanced > summary { cursor: pointer; font-weight: 600; }
.ts-advanced[open] { border-left: 2px solid var(--line); padding-left: 12px; }
.ts-advanced .inline-row { margin: 8px 0; }
.ts-other { margin-top: 8px; width: 100%; max-width: 420px; }
.ts-ping-head { display: flex; flex-wrap: wrap; gap: 6px 16px; margin: 6px 0; font-size: 13px; }
.ts-ping-head strong { font-size: 16px; }
.ts-recent-row { display: flex; align-items: baseline; gap: 8px; justify-content: space-between; }
.ts-recent-row a { min-width: 0; overflow-wrap: anywhere; }
.ts-again { flex: none; }
.ts-keep { margin-bottom: 12px; }
.ts-dtrace-wrap { overflow-x: auto; max-width: 680px; }
.ts-dtrace { width: 100%; min-width: 420px; height: auto; font-family: var(--font); }
.ts-dt-box { fill: var(--panel-2); stroke: var(--line); }
.ts-dt-box.bad { stroke: var(--danger); }
.ts-dt-final.ok { fill: color-mix(in srgb, var(--ok) 14%, var(--panel)); stroke: var(--ok); }
.ts-dt-final.bad { fill: color-mix(in srgb, var(--danger) 14%, var(--panel)); stroke: var(--danger); }
.ts-dt-final.warn { fill: color-mix(in srgb, var(--sev-minor) 18%, var(--panel)); stroke: var(--sev-minor); }
.ts-dt-q { fill: var(--muted); font-size: 12px; }
.ts-dt-zone { fill: var(--text); font-size: 14px; font-weight: 600; }
.ts-dt-srv, .ts-dt-said { fill: var(--muted); font-size: 12px; font-family: var(--mono); }
.ts-dt-ms { fill: var(--text); font-size: 12px; }
.ts-dt-line { stroke: var(--muted); stroke-width: 1.5; }
.ts-dt-arrow { fill: var(--muted); }
/* 1.71 Email headers: sender checks */
.ts-intel-sum { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; padding: 10px 12px; margin-bottom: 12px; border-radius: var(--radius-sm); border: 1px solid var(--line); background: var(--panel-2); }
.ts-intel-sum.ts-risk-high { border-color: var(--danger); background: color-mix(in srgb, var(--danger) 8%, var(--panel)); }
.ts-intel-sum.ts-risk-medium { border-color: var(--sev-minor); background: color-mix(in srgb, var(--sev-minor) 10%, var(--panel)); }
.ts-intel-text { flex: 1 1 320px; min-width: 0; }
.ts-intel td .ts-chip { margin: 0 4px 2px 0; }
.hw-notes { margin: 4px 0 8px; padding-left: 18px; }
/* 1.71 maintenance: reminder recipients as chips; what a circuit brought in */
.mf-rcpt-wrap { position: relative; min-width: 260px; }
.mf-rcpt { display: flex; flex-wrap: wrap; gap: 4px; align-items: center; padding: 4px 6px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel); min-height: 34px; }
.mf-rcpt:focus-within { outline: 2px solid var(--focus); outline-offset: 1px; }
.mf-rcpt-input { flex: 1 1 140px; min-width: 120px; border: 0 !important; outline: 0; background: transparent; padding: 2px 4px; box-shadow: none !important; }
.mf-rcpt-list { position: absolute; z-index: 20; left: 0; right: 0; top: 100%; margin: 2px 0 0; padding: 4px 0; list-style: none; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius-sm); box-shadow: var(--shadow); max-height: 240px; overflow: auto; }
.mf-rcpt-list li button { display: block; width: 100%; text-align: left; padding: 6px 10px; }
.mf-rcpt-list li button:hover, .mf-rcpt-list li button:focus { background: var(--panel-2); }
.mf-via { margin-left: 2px; }
/* 1.71 operator home: a 12-column grid made once; rows of equal height; cards that fill their rows */
.dash-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 16px; align-items: stretch; }
.home:has(> .dash-grid) { display: block; }
.dash-cell { min-width: 0; display: flex; flex-direction: column; }
.dash-cell > .panel, .dash-cell > div > .panel { flex: 1 1 auto; margin: 0; display: flex; flex-direction: column; min-height: 0; }
.dash-cell > .dash-flow, .dash-cell > .dash-tiles, .dash-cell > .platform { flex: 0 0 auto; }
.dash-cell:empty { display: none; }
.c-12 { grid-column: span 12; } .c-8 { grid-column: span 8; } .c-7 { grid-column: span 7; } .c-5 { grid-column: span 5; } .c-4 { grid-column: span 4; }
.dash-cell[data-cell=queue] .queue-list, .dash-cell[data-cell=problems] .prob-list { max-height: 520px; overflow: auto; }
.dash-cell[data-cell=review] .rv-body { max-height: 320px; overflow: auto; }
.dash-chart .chart { flex: 1 1 auto; }
.dash-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px; }
.dash-tile { display: flex; flex-direction: column; gap: 2px; padding: 12px 14px; border: 1px solid var(--line); border-radius: var(--radius); background: var(--panel); color: var(--text); text-decoration: none; min-width: 0; border-top: 3px solid var(--line); }
.dash-tile:hover { text-decoration: none; border-color: var(--muted); }
.dash-tile.ok { border-top-color: var(--sev-normal); } .dash-tile.warn { border-top-color: var(--sev-minor); } .dash-tile.bad { border-top-color: var(--sev-critical); } .dash-tile.info { border-top-color: var(--link); }
.dash-tile-l { font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .05em; }
.dash-tile-n { font-size: 26px; font-weight: 700; line-height: 1.15; font-variant-numeric: tabular-nums; }
.dash-tile.bad .dash-tile-n { color: var(--sev-critical); }
.dash-tile-sub { color: var(--muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dash-tile-bar { height: 6px; margin: 6px 0 0; }
.dash-flow { display: flex; flex-wrap: wrap; gap: 16px; align-items: stretch; }
.dash-flow-item { flex: 1 1 340px; min-width: 0; display: flex; flex-direction: column; }
.dash-flow-item > div, .dash-flow-item > div > div { flex: 1 1 auto; display: flex; flex-direction: column; }
.dash-flow-item .panel { flex: 1 1 auto; margin: 0; }
.dash-flow-item:not(:has(.panel)) { display: none; }
.dash-cell[data-cell=cards]:not(:has(.panel)) { display: none; }
.dash-empty-line { margin: 10px 0 0; }
.platform .platform-head { margin-top: 0; }
@media (max-width: 1100px) { .c-8, .c-7, .c-5, .c-4 { grid-column: span 12; } }
/* 1.72: Critical (answered, over its critical threshold) apart from Down (no answer): red, a diamond rather than Down's octagon */
.status-critical .dot { background: var(--sev-critical); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); border-radius: 0; width: 10px; height: 10px; }
.hb-critical { background: var(--sev-major, var(--sev-critical)); }
/* 1.72: customer profiles */
.profile-form fieldset { border: 1px solid var(--line); border-radius: 8px; padding: 10px 14px 12px; margin: 12px 0 0; }
.profile-form legend { font-weight: 600; padding: 0 6px; }
.profile-form .check-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 6px 16px; margin-top: 6px; }
.profile-preview { margin-top: 14px; padding: 10px 14px; border-radius: 8px; background: color-mix(in srgb, var(--link) 6%, transparent); }
.profile-preview h3 { margin: 0 0 6px; font-size: 13px; }
.profile-nav { display: flex; flex-wrap: wrap; gap: 6px; }
.profile-nav .chip { padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line); font-size: 12.5px; }
.from-profile { color: var(--muted); font-style: italic; }
/* 1.72: ? help tips */
.help-q { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; border-radius: 50%; border: 1.5px solid var(--muted); background: transparent; color: var(--muted); font-size: 12px; font-weight: 700; cursor: pointer; padding: 0; margin-left: 6px; vertical-align: middle; line-height: 1; }
.help-q:hover, .help-q[aria-expanded="true"] { color: var(--text); border-color: var(--text); }
.help-q.big { width: 36px; height: 36px; font-size: 16px; margin: 0; flex: none; }
.help-pop { position: absolute; z-index: 1000; background: var(--panel, var(--bg)); color: var(--text); border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; font-size: 13.5px; line-height: 1.5; box-shadow: 0 8px 24px rgba(0,0,0,.35); }
.help-src { display: none !important; }
.field > label.with-tip { display: inline-block; }
.field > label.with-tip + .help-q { margin-bottom: 4px; }
.modal-body { position: relative; }
/* 1.72: the Add / Edit device form */
.modal.wide:has(.dev-form) { max-width: 980px; }
.dev-form { display: flex; flex-direction: column; gap: 16px; }
.dev-form .grid3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px 18px; align-items: start; }
.dev-form .grid3 > .field { margin: 0; min-width: 0; }
.dev-form .span2 { grid-column: span 2; }
.dev-form .span3 { grid-column: 1 / -1; }
.dev-form .addr-row { display: flex; gap: 10px; align-items: center; }
.dev-form .addr-row input { flex: 1; min-width: 0; }
.dev-form .addr-row .btn { flex: none; }
.dev-sect { border: 1px solid var(--line); border-radius: 10px; }
.dev-sect > summary { list-style: none; cursor: pointer; display: flex; align-items: baseline; gap: 10px; padding: 12px 16px; flex-wrap: wrap; }
.dev-sect > summary::-webkit-details-marker { display: none; }
.dev-sect .sect-chev::before { content: ""; display: inline-block; width: 7px; height: 7px; border-right: 2px solid var(--text); border-bottom: 2px solid var(--text); transform: rotate(-45deg); transition: transform .15s; margin-right: 2px; }
.dev-sect[open] .sect-chev::before { transform: rotate(45deg); }
.dev-sect .sect-sum { color: var(--muted); font-size: 13.5px; min-width: 0; overflow-wrap: anywhere; }
.dev-sect > .grid3 { padding: 4px 16px 16px; }
.add-picker .add-mon-head { margin: 0 0 8px; font-size: 15px; }
.add-picker .add-modes { display: flex; gap: 24px; flex-wrap: wrap; margin-bottom: 10px; }
.add-set { padding: 12px 16px; border-radius: 10px; }
.start-list.two-col { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px 24px; margin: 10px 0 4px 26px; }
.start-list.two-col label.check { display: flex; align-items: center; gap: 8px; }
.start-list.two-col .kind-tag { margin-left: 4px; font-weight: 600; letter-spacing: .03em; }
.add-cred { margin: 10px 0 0 26px; }
.add-cred-row { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.add-cred-row select { max-width: 340px; flex: 1 1 220px; }
.add-cred-row .spacer { flex: 1; }
select.needs { border-color: var(--sev-minor); box-shadow: 0 0 0 1px var(--sev-minor); }
.needed-by { color: var(--sev-minor); flex: 1 1 auto; }
.add-others > summary.linkish { list-style: none; display: inline-flex; gap: 8px; align-items: center; margin-top: 10px; }
.add-others > summary.linkish::before { content: "›"; font-size: 18px; }
.add-others[open] > summary.linkish::before { transform: rotate(90deg); }
/* Detect results */
.detect-results { display: flex; flex-direction: column; gap: 14px; }
.dr-card { display: flex; justify-content: space-between; align-items: center; gap: 16px; border: 1px solid var(--line); border-radius: 10px; padding: 14px 18px; background: var(--panel-2); }
.dr-label { color: var(--muted); font-size: 13px; font-weight: 600; }
.dr-title { font-size: 19px; font-weight: 700; margin: 2px 0; }
.dr-badge { flex: none; padding: 4px 12px; border-radius: 999px; font-weight: 700; font-size: 13px; border: 1.5px solid; }
.dr-badge.strong { color: var(--sev-normal); border-color: var(--sev-normal); }
.dr-badge.possible { color: var(--sev-minor); border-color: var(--sev-minor); }
.dr-table { width: 100%; border-collapse: collapse; }
.dr-table th, .dr-table td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
.dr-table thead th { color: var(--muted); font-weight: 600; }
.dr-table tbody th { font-weight: 600; white-space: nowrap; }
.dr-points { color: var(--muted); }
.dr-points.agrees { color: var(--sev-normal); }
.new-badge { background: var(--sev-info); color: #fff; font-size: 10.5px; padding: 1px 6px; border-radius: 4px; margin-left: 8px; vertical-align: middle; }
.dr-addr { font-family: var(--mono, monospace); font-weight: 400; font-size: 14px; color: var(--muted); }
@media (max-width: 720px) {
  .dev-form .grid3 { grid-template-columns: minmax(0, 1fr); }
  .dev-form .span2 { grid-column: auto; }
  .start-list.two-col { grid-template-columns: minmax(0, 1fr); margin-left: 0; }
  .add-cred { margin-left: 0; }
  .dr-card { flex-direction: column; align-items: flex-start; }
}
.label-row { display: flex; align-items: center; gap: 0; }
.label-row > label { margin: 0 !important; }
.start-list.two-col { border: 0; background: transparent; padding: 0; }
.add-cred-row .needed-by { flex: 0 1 auto; }
.add-cred-row .btn { margin-left: auto; }
.add-cred > label { display: flex; align-items: center; }
.dev-sect > summary b { color: var(--text); }
.add-cred-row { flex-wrap: nowrap; }
.add-cred-row select { width: auto; flex: 0 1 340px; min-width: 180px; }
.add-cred-row .btn, .add-cred-row .linkish { flex: none; width: auto; }
.detect-results > label.check { align-self: flex-start; }
@media (max-width: 720px) { .add-cred-row { flex-wrap: wrap; } }
.form-grid label.check:not(.inline) > input + span, .dev-form label.check:not(.inline) > input + span, .profile-form label.check > input + span { flex: 1 1 0; min-width: 0; }
/* 1.72: API tester */
.api-layout { display: grid; grid-template-columns: minmax(0, 1fr) 260px; gap: 24px; align-items: start; }
.api-main { min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.api-reqline { display: flex; gap: 10px; align-items: center; }
.api-reqline select { width: 120px; flex: none; }
.api-reqline input { flex: 1; min-width: 0; }
.api-saved { border-left: 1px solid var(--line); padding-left: 16px; }
.api-saved h3 { margin: 0 0 8px; font-size: 14px; }
.api-saved li.active { font-weight: 700; }
.api-status { font-size: 16px; display: flex; gap: 8px; align-items: baseline; }
.api-code { font-weight: 700; padding: 2px 8px; border-radius: 6px; }
.api-code.c2 { color: var(--sev-normal); } .api-code.c3 { color: var(--sev-info); } .api-code.c4 { color: var(--sev-minor); } .api-code.c5 { color: var(--sev-critical); }
.api-timing { display: flex; gap: 14px; flex-wrap: wrap; }
.api-json { font-size: 13px; line-height: 1.6; overflow-x: auto; max-height: 60vh; overflow-y: auto; border: 1px solid var(--line); border-radius: 8px; padding: 8px 12px; }
.api-json .json-kids { padding-left: 18px; }
.json-leaf { background: none; border: 0; padding: 0 2px; font: inherit; cursor: pointer; border-radius: 3px; }
.json-leaf:hover { background: color-mix(in srgb, var(--link) 18%, transparent); }
.json-string { color: var(--sev-normal); } .json-number { color: var(--sev-info); } .json-boolean { color: var(--sev-major); } .json-null { color: var(--muted); }
.json-key { color: var(--muted); }
.api-path { display: flex; gap: 8px; align-items: center; }
.api-body { max-height: 60vh; overflow: auto; white-space: pre-wrap; word-break: break-all; }
/* port scan */
.ps-progress { display: flex; gap: 10px; align-items: center; margin-bottom: 8px; }
.ps-progress progress { flex: 1; }
.ps-ok { color: var(--sev-normal); font-weight: 600; } .ps-warn { color: var(--sev-minor); } .ps-muted { color: var(--muted); }
.ps-dns { margin-bottom: 8px; }
.ps-diff { margin: 6px 0; }
@media (max-width: 900px) { .api-layout { grid-template-columns: minmax(0, 1fr); } .api-saved { border-left: 0; padding-left: 0; } }

/* 1.73: the Customer picker and Find line up: both 40 px tall, bottoms level (the picker's label sits above it) */
.topbar .tenant-pick { justify-content: flex-end; }
.topbar .tenant-switch, .topbar .tenant-pick .ssel-btn { height: 40px; box-sizing: border-box; padding-block: 0; display: inline-flex; align-items: center; }
.topbar .qj-open { align-self: flex-end; height: 40px; box-sizing: border-box; padding-block: 0; }
@media (max-width: 600px) { .topbar .qj-open { align-self: center; } }
/* 1.73: whether the device last answered with a credential */
.cred-check { display: block; margin-top: 4px; font-size: 12px; }
.cred-check.ok { color: var(--ok); }
.cred-check.bad { color: var(--danger); }

/* 1.75: Priority 0 */
.p0-banner { position: sticky; top: 0; z-index: 900; display: flex; flex-wrap: wrap; gap: 8px 16px; align-items: center; justify-content: space-between;
  padding: 8px max(16px, env(safe-area-inset-left, 0px)); background: #b00020; color: #fff; animation: p0pulse 1.2s ease-in-out infinite; }
.p0-banner .p0-body { min-width: 0; flex: 1 1 320px; overflow-wrap: anywhere; }
.p0-banner .p0-why, .p0-banner .p0-where { opacity: .9; }
.p0-banner .p0-actions { display: flex; gap: 6px; flex-wrap: wrap; align-items: center; }
.p0-banner .btn { background: #fff; color: #b00020; border-color: #fff; }
.p0-banner .btn.ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.7); }
.p0-banner .p0-ack { display: flex; gap: 6px; flex-wrap: wrap; }
.p0-banner .p0-ack input { min-width: 260px; flex: 1; color: #000; background: #fff; }
@keyframes p0pulse { 0%, 100% { background: #b00020; } 50% { background: #e0002a; } }
tr.p0-row:not(.acked) td, .alarm-row.p0-row:not(.acked) { animation: p0row 1.2s ease-in-out infinite; }
@keyframes p0row { 0%, 100% { background: color-mix(in srgb, #e0002a 22%, transparent); } 50% { background: color-mix(in srgb, #e0002a 8%, transparent); } }
.p0-badge { display: inline-block; padding: 0 6px; border-radius: 4px; background: #b00020; color: #fff; font-weight: 700; font-size: 11px; letter-spacing: .04em; margin-right: 4px; }
@media (prefers-reduced-motion: reduce) { .p0-banner, tr.p0-row td, .alarm-row.p0-row { animation: none; } }
.affected-tree { margin: 8px 0; } .affected-tree summary { cursor: pointer; } .affected-tree .aff-group { margin: 6px 0 0 12px; }
.p0-box p { margin: 4px 0; }

/* 1.76: impact and SLA */
.imp-tiles { display: flex; flex-wrap: wrap; gap: 8px; margin: 8px 0 12px; }
.imp-tile { min-width: 110px; padding: 8px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel-2); }
.imp-tile .imp-n { font-size: 22px; font-weight: 700; }
.imp-tile.bad { border-color: var(--sev-critical, #c62828); } .imp-tile.warn { border-color: var(--sev-major); }
.imp-cust { border-top: 1px solid var(--line); padding: 6px 0; } .imp-cust h4 { margin: 6px 0; }
tr.imp-cut td:first-child { border-left: 3px solid var(--sev-critical, #c62828); } tr.imp-at_risk td:first-child { border-left: 3px solid var(--sev-major); }
.imp-chips, .svc-items { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0; }
.imp-hits { max-height: 240px; overflow: auto; } .imp-hits .block, .partner-pick .block { display: block; text-align: left; padding: 2px 0; }
.partner-pick { max-height: 260px; overflow: auto; border: 1px solid var(--line); padding: 6px 8px; border-radius: var(--radius-sm); }
.svc { border-top: 1px solid var(--line); padding: 8px 0; } .bad { color: var(--sev-critical, #c62828); }
.imp-chips .chip, .svc-items .chip { display: inline-flex; align-items: center; gap: 4px; font-size: 12.5px; padding: 2px 4px 2px 10px; border-radius: 999px; background: color-mix(in srgb, var(--link) 14%, transparent); }
.imp-controls { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; } .imp-controls input[type=search] { flex: 1 1 300px; min-width: 0; width: auto; }
.imp-controls select { width: auto; } .imp-controls .imp-dur { display: inline-flex; align-items: center; gap: 6px; white-space: nowrap; } .imp-controls .imp-dur input { width: 6em; }
.impact .table-wrap table td { padding-right: 12px; }

/* 1.77: agents */
.agent-cmd { display: flex; gap: 6px; align-items: flex-start; margin: 4px 0 10px; } .agent-cmd pre { flex: 1; min-width: 0; overflow-x: auto; margin: 0; white-space: pre; }
.sw-facts { display: grid; gap: 14px; margin-bottom: 10px; } .sw-facts + p, .sw-list { margin-top: 8px; } .sw-search { max-width: 360px; }
.sw-list { max-height: 520px; overflow: auto; } .warn-row td { background: color-mix(in srgb, var(--sev-minor) 12%, transparent); }
.agents177 select { width: auto; max-width: 100%; } .agents177 td .row { flex-wrap: wrap; gap: 6px; }

/* 1.78: the wallboard fits the screen; nothing scrolls */
body.board-mode { overflow: hidden; }
body.board-mode .main { height: 100vh; box-sizing: border-box; display: flex; flex-direction: column; overflow: hidden; }
body.board-mode .board-body { flex: 1; min-height: 0; }
body.board-mode .board-body > div { height: 100%; }
.status-board.big { height: 100%; display: flex; flex-direction: column; gap: 16px; }
.status-board.big .sb-cols { flex: 1; min-height: 0; align-items: stretch; }
.status-board.big .sb-cols > section.panel, .status-board.big .sb-side > section.panel { overflow: hidden; min-height: 0; }
.status-board.big .sb-side { min-height: 0; }
.status-board.big .sb-side > section.panel { flex: 1; }
li.fit-more { list-style: none; padding: 6px 0 0; }
.prob-hidden { margin: 8px 0 0; }

/* ---------- 1.78: dashboards ---------- */
.dgrid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); grid-auto-rows: 64px; gap: 12px; }
.wcell { display: flex; flex-direction: column; min-width: 0; min-height: 0; overflow: hidden; margin: 0; position: relative; }
.w-head { display: flex; align-items: center; gap: 8px; min-height: 22px; }
.w-title { font-size: 14px; margin: 0; flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.w-body { flex: 1; min-height: 0; overflow: auto; display: flex; flex-direction: column; }
.w-body > section.panel { border: 0; box-shadow: none; padding: 0; margin: 0; background: transparent; }
.w-body > section.panel > .panel-head h2 { display: none; }
.w-fill { flex: 1; min-height: 120px; }
.w-sub { margin: 0 0 4px; }
.w-big { display: flex; flex-direction: column; justify-content: center; flex: 1; }
.w-big-n { font-size: 40px; font-weight: 800; line-height: 1.1; }
.w-counts { display: flex; gap: 16px; flex-wrap: wrap; } .w-count strong { font-size: 24px; }
.st-down strong, .st-down .w-big-n { color: var(--sev-critical); } .st-degraded strong, .st-warning .w-big-n { color: var(--sev-major); }
.w-notes p { margin: 0 0 6px; white-space: pre-wrap; }
.w-zones { display: grid; grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); gap: 4px 12px; margin-top: 8px; }
.dgrid-edit .wcell { outline: 2px dashed var(--line); }
.dgrid-edit .w-head { cursor: move; touch-action: none; }
.w-tools { display: flex; gap: 4px; }
.w-resize { position: absolute; right: 2px; bottom: 2px; width: 16px; height: 16px; cursor: nwse-resize; touch-action: none; background: linear-gradient(135deg, transparent 50%, var(--muted) 50%); opacity: .6; border-radius: 2px; }
.w-dragging { opacity: .85; z-index: 5; box-shadow: 0 8px 24px rgba(0,0,0,.25); }
.d-filters { display: flex; gap: 16px; flex-wrap: wrap; margin: 0 0 12px; } .d-filters:empty { display: none; }
.w-catalog h4 { margin: 14px 0 6px; } .w-cat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 8px; }
.w-cat-item { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; text-align: left; padding: 10px 12px; border: 1px solid var(--line); border-radius: var(--radius-sm); background: var(--panel-2); color: var(--text); cursor: pointer; font: inherit; }
.w-cat-item:hover { background: var(--btn-hover); }
.w-pick-res { display: flex; flex-direction: column; align-items: flex-start; } .w-pick-item { padding: 4px 0; }
.w-scope { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 12px; } .w-checks { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 2px 12px; max-height: 220px; overflow: auto; }
.share-list { max-height: 50vh; overflow: auto; margin-top: 8px; } .share-row { display: block; padding: 3px 0; }
@media (max-width: 760px) {
  .dgrid:not(.dgrid-wall) { grid-template-columns: 1fr; grid-auto-rows: auto; }
  .dgrid:not(.dgrid-wall) .wcell { grid-column: 1 / -1 !important; grid-row: auto !important; min-height: 220px; }
}
/* a wallboard: the grid is the screen */
.board-grid-host { flex: 1; min-height: 0; }
.dgrid-wall { height: 100%; grid-auto-rows: auto; grid-template-rows: repeat(var(--rows, 9), minmax(0, 1fr)); overflow: hidden; }
.dgrid-wall .w-body { overflow: hidden; }
.dgrid-wall .w-title { font-size: 16px; }
.dgrid-wall { font-size: 17px; }
.dgrid-wall .sb-n { font-size: 56px; }
.dgrid-wall .w-big-n { font-size: 64px; }
.board-actions { margin-left: auto; display: flex; gap: 12px; align-items: center; }
/* the menu */
.nav-new { margin-left: auto; font-size: 10px; text-transform: uppercase; letter-spacing: .05em; background: var(--accent, var(--sev-info)); color: #fff; border-radius: 8px; padding: 1px 6px; }
.nav-edit { list-style: none; padding: 0; margin: 8px 0 0; }
.nav-edit-row { display: flex; align-items: center; gap: 8px; padding: 6px 8px; border: 1px solid var(--line); border-radius: var(--radius-sm); margin-bottom: 4px; background: var(--panel); cursor: grab; }
.nav-edit-row.off { opacity: .55; } .nav-edit-row.fixed { cursor: default; background: var(--panel-2); } .nav-edit-row.dragging { opacity: .4; }
.nav-edit-l { flex: 1; } .nav-grip { color: var(--muted); width: 14px; }
.wcell .sb-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(90px, 1fr)); gap: 8px; }
.wcell .sb-tile { padding: 8px 10px; } .wcell .sb-n { font-size: 30px; }
.w-clock .w-big-n { font-size: 30px; white-space: nowrap; }
.dgrid-wall .w-clock .w-big-n { font-size: 56px; }
.wcell .summary-tiles, .wcell .tiles { margin: 0; }

/* ---------- 1.79: widgets ---------- */
.w-swatch { display: inline-block; width: 10px; height: 10px; border-radius: 2px; vertical-align: middle; }
.w-legend { overflow: auto; max-height: 40%; } .w-legend table { width: 100%; } .w-legend td { white-space: nowrap; }
.w-bars { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 6px; }
.w-bar-l { font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.w-bar { position: relative; height: 10px; background: var(--panel-2); border-radius: 5px; }
.w-bar span { position: absolute; left: 0; top: 0; bottom: 0; background: var(--series-1); border-radius: 5px; } .w-bar span.warn { background: var(--sev-major); } .w-bar span.bad { background: var(--sev-critical); }
.w-bar em { position: absolute; right: 0; top: -16px; font-size: 11px; font-style: normal; color: var(--muted); }
.w-spark { height: 48px; flex: none; }
.lv-crit .w-big-n { color: var(--sev-critical); } .lv-warn .w-big-n { color: var(--sev-major); } .lv-ok .w-big-n { color: var(--sev-normal); }
.w-tag { font-size: 10px; text-transform: uppercase; letter-spacing: .05em; border: 1px solid var(--line); border-radius: 4px; padding: 0 4px; color: var(--muted); }
.w-sla { padding: 4px 0; border-bottom: 1px solid var(--line); } .bad { color: var(--sev-critical); } .warn { color: var(--sev-major); }
.w-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-bottom: 4px; } .w-chips .chip { display: inline-flex; align-items: center; gap: 2px; border: 1px solid var(--line); border-radius: 12px; padding: 1px 4px 1px 10px; font-size: 12px; }
.w-map { width: 100%; flex: 1; min-height: 0; }
/* the ticker */
.wcell-ticker { padding-top: 6px; padding-bottom: 6px; } .wcell-ticker .w-head { display: none; } .dgrid-edit .wcell-ticker .w-head { display: flex; }
.ticker { overflow: hidden; white-space: nowrap; mask-image: linear-gradient(90deg, transparent, #000 3%, #000 97%, transparent); display: flex; align-items: center; height: 100%; }
.tk-track { display: inline-flex; gap: 36px; animation: tk-scroll linear infinite; padding-left: 100%; }
.ticker:hover .tk-track { animation-play-state: paused; }
@keyframes tk-scroll { from { transform: translateX(0); } to { transform: translateX(-100%); } }
.tk-item { color: var(--text); text-decoration: none; } .tk-i { font-weight: 800; margin-right: 6px; } .tk-t { color: var(--muted); font-variant-numeric: tabular-nums; }
.tk-down .tk-i, .tk-raised .tk-i { color: var(--sev-critical); } .tk-up .tk-i, .tk-acknowledged .tk-i { color: var(--sev-normal); } .tk-c { color: var(--muted); }
.tk-static { display: none; list-style: none; padding: 0; margin: 0; }
@media (prefers-reduced-motion: reduce) { .tk-track { animation: none; padding-left: 0; } }
@media (max-width: 760px) { .ticker { display: none; } .tk-static { display: block; } .wcell-ticker { min-height: 0 !important; } }
.dgrid-wall .ticker { font-size: 20px; }
.wcell { container-type: inline-size; }
.wcell .w-big-n { font-size: clamp(22px, 15cqi, 40px); line-height: 1.1; }
.dgrid-wall .wcell .w-big-n { font-size: clamp(28px, 16cqi, 72px); }
.w-legend { font-size: 12px; } .w-legend th, .w-legend td { padding: 2px 6px; }
.tk-track { padding-left: 40%; }

/* 1.80: won't-fix marker, folded package rows, the small drop-down menu button */
.cve-wont { display: inline-block; padding: 1px 7px; border-radius: 999px; border: 1px solid var(--muted); color: var(--muted); font-size: 11.5px; font-weight: 600; white-space: nowrap; }
tr.cve-fold > td { background: color-mix(in srgb, var(--muted) 8%, transparent); }
.menu-btn { position: relative; display: inline-block; }
.menu-btn > summary { list-style: none; cursor: pointer; }
.menu-btn > summary::-webkit-details-marker { display: none; }
.menu-btn > .menu-pop { position: absolute; right: 0; top: calc(100% + 4px); z-index: 30; display: flex; flex-direction: column; gap: 4px; min-width: 200px; padding: 6px;
  background: var(--panel); border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow); }
.menu-btn > .menu-pop > .btn { justify-content: flex-start; text-align: left; white-space: nowrap; }
.cve-maps { margin-top: 16px; }
.cve-map-results { margin-top: 10px; max-height: 50vh; overflow: auto; }
.cve-map-results tr.selected > td { background: color-mix(in srgb, var(--link) 14%, transparent); }
.modal .inline-form > input[type=search] { flex: 1 1 220px; width: auto; min-width: 0; }
/* 1.80: Reports › Versions */
.ver-filters { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; margin: 4px 0 12px; }
.ver-filters > input, .ver-filters > select { flex: 1 1 160px; min-width: 0; max-width: 260px; }
.ver-filters > input[aria-label="Find"] { max-width: none; flex-basis: 220px; }
.ver-dev tr.ver-sub > td { background: color-mix(in srgb, var(--muted) 6%, transparent); padding-top: 4px; }
.ver-cve { text-decoration: none; white-space: nowrap; }
.ver-foot { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin-top: 8px; }
/* 1.80: Settings › Trap definitions: names read left, long OIDs wrap */
table.trapdefs .linkish { text-align: left; }
table.trapdefs td.mono { overflow-wrap: anywhere; max-width: 26ch; }
/* 1.80: a fieldset grows to its widest content unless told not to (Settings › Security's Duo return address) */
fieldset { min-width: 0; }
.field code, .form-grid code { overflow-wrap: anywhere; }
/* 1.80: phones: the four severity counts all show (they shrink rather than being cut off), and a wide table scrolls inside itself */
@media (max-width: 480px) {
  .rail-seg { min-width: 0; flex: 1 1 0; padding: 0 6px; justify-content: center; }
  .rail-num { font-size: 17px; }
}
@media (max-width: 760px) {
  main > table.grid, main :not(.table-wrap) > table.grid { display: block; overflow-x: auto; max-width: 100%; }
}
/* 1.81: the ticker scrolls by script (a refresh no longer restarts it); each half is one copy of the items */
.tk-track.tk-js { animation: none; padding-left: 0; will-change: transform; }
.tk-half { display: inline-flex; gap: 36px; padding-right: 36px; flex: none; }
.ticker .tk-track.tk-js { gap: 0; }
/* 1.81: the clock's time zone picker */
.tz-pick { display: flex; flex-direction: column; gap: 8px; }
.tz-tags { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.tz-tag { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; }
.tz-tag-name { font-weight: 600; min-width: 9ch; }
.tz-tag .tz-label { flex: 1 1 140px; min-width: 0; }
.tz-box { position: relative; }
.tz-box > input { width: 100%; }
.tz-list { position: absolute; left: 0; right: 0; top: calc(100% + 2px); z-index: 40; list-style: none; margin: 0; padding: 4px; max-height: 280px; overflow: auto;
  background: var(--panel); border: 1px solid var(--line); border-radius: 8px; box-shadow: var(--shadow); }
.tz-opt { padding: 6px 8px; border-radius: 6px; cursor: pointer; }
.tz-opt.active, .tz-opt:hover { background: color-mix(in srgb, var(--link) 14%, transparent); }
.tz-day { font-size: 10px; margin-left: 2px; color: var(--muted); }
/* 1.81: playlists */
.pl-head { flex-wrap: wrap; align-items: center; position: relative; padding-bottom: 8px; margin-bottom: 12px; }
.pl-head h1 { font-size: 22px; }
.pl-now { font-size: 26px; font-weight: 700; }
.pl-pos { font-size: 14px; }
.pl-head .board-actions { margin-left: auto; display: flex; gap: 6px; align-items: center; }
.pl-btn { min-width: 38px; height: 34px; border-radius: 8px; border: 1px solid var(--line); background: var(--panel); color: var(--text); font-size: 14px; cursor: pointer; }
.pl-btn:hover { border-color: var(--muted); }
.pl-bar { position: absolute; left: 0; right: 0; bottom: 0; height: 3px; background: color-mix(in srgb, var(--muted) 18%, transparent); border-radius: 2px; overflow: hidden; }
.pl-bar-fill { height: 100%; width: 0; background: var(--link); transition: width .25s linear; }
.pl-paused .pl-bar-fill { background: var(--muted); }
.pl-stage { position: relative; flex: 1; min-height: 0; }
.pl-layer { position: absolute; inset: 0; display: flex; flex-direction: column; overflow: hidden; transition: opacity .35s ease; opacity: 1; }
.pl-layer.pl-hidden { visibility: hidden; opacity: 0; pointer-events: none; }
.pl-layer.pl-leaving { opacity: 0; }
.pl-layer > .board-grid-host { flex: 1; min-height: 0; }
.pl-layer > .pl-dash { flex: 1; min-height: 0; overflow: auto; }
@media (prefers-reduced-motion: reduce) { .pl-layer, .pl-bar-fill { transition: none; } }
.pl-items { display: flex; flex-direction: column; gap: 8px; padding-left: 22px; }
.pl-item { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.pl-item-name { flex: 1 1 260px; min-width: 0; }
.pl-item select { width: auto; }
.pl-item-acts { display: flex; gap: 4px; }
.form-grid > .field-wide { grid-column: 1 / -1; }
.tz-tag .tz-label { flex: 0 1 220px; }
/* the clock fits its zones: smaller lines, the whole box scrolls if a long list still doesn't */
.w-clock { display: flex; flex-direction: column; min-height: 0; height: 100%; overflow: auto; }
.w-clock .w-zones { margin-top: 4px; gap: 2px 12px; font-size: 12.5px; line-height: 1.35; }
/* Device tiles: the widget scrolls when the tiles don't fit */
.w-tiles { height: 100%; overflow: auto; }
.w-tiles .tiles-view { padding-bottom: 4px; }
/* 1.82: the clock: every clock the same size, its place under it; digital or analog */
.w-clock2 { display: flex; flex-direction: column; height: 100%; min-height: 0; gap: 4px; }
.clk-grid { flex: 1; min-height: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 96px), 1fr)); gap: 6px 10px; align-content: safe center; }
.w-clock2 { overflow: auto; }
.clk { container-type: inline-size; display: flex; flex-direction: column; align-items: center; justify-content: center; min-width: 0; text-align: center; }
.clk-t { font-size: var(--tfs, clamp(15px, 21cqi, 44px)); font-weight: 800; line-height: 1.05; font-variant-numeric: tabular-nums; white-space: nowrap; }
.clk-c { font-size: clamp(10.5px, 10cqi, 14px); color: var(--muted); font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.clk-day { font-size: clamp(10px, 8.5cqi, 12.5px); color: var(--muted); font-variant-numeric: tabular-nums; }
.clk-day:empty { display: none; }
.clk-face { width: min(100%, var(--face, 130px)); height: auto; aspect-ratio: 1; flex: none; }
.clk-rim { fill: var(--panel); stroke: var(--text); stroke-width: 2.5; }
.clk-night .clk-rim { fill: color-mix(in srgb, var(--text) 10%, var(--panel)); }
.clk-tick { stroke: var(--muted); stroke-width: 1.5; stroke-linecap: round; } .clk-tick-q { stroke: var(--text); stroke-width: 2.5; }
.clk-h { stroke: var(--text); stroke-width: 4.5; stroke-linecap: round; } .clk-m { stroke: var(--text); stroke-width: 3; stroke-linecap: round; }
.clk-hub { fill: var(--link); }
.clk-date { text-align: center; } .clk-date:empty { display: none; }
.dgrid-wall .clk-t { font-size: var(--tfs, clamp(18px, 22cqi, 72px)); } .dgrid-wall .clk-c { font-size: clamp(12px, 10cqi, 20px); }
.dgrid-wall .clk-face { width: min(100%, var(--face, 220px)); }
/* 1.82: the slim top bar: everything stays, at about half the height */
.slim-toggle { align-self: center; flex: none; }
body.slim-top .topbar { padding-block: 5px; gap: 8px; align-items: center; }
body.slim-top .topbar .tenant-pick { flex-direction: row; align-items: center; min-width: 150px; }
body.slim-top .topbar .tenant-pick > span { display: none; }
body.slim-top .topbar .tenant-switch, body.slim-top .topbar .tenant-pick .ssel-btn, body.slim-top .topbar .qj-open { height: 28px; font-size: 12.5px; }
body.slim-top .topbar .qj-open { align-self: center; }
body.slim-top .topbar .qj-open-k { display: none; }
body.slim-top .rail { min-height: 28px; }
body.slim-top .rail-seg { padding: 0 10px; min-width: 70px; gap: 6px; }
body.slim-top .rail-num { font-size: 15px; }
body.slim-top .rail-label { font-size: 11.5px; }
body.slim-top .view-switch button { padding: 2px 9px; font-size: 11.5px; }
body.slim-top .live { font-size: 12px; }
body.slim-top .topbar .icon-btn { width: 28px; height: 28px; }
/* 1.82: a hidden dashboard head leaves a thin handle at the top right */
.dash-handle { display: block; margin: -6px 0 6px auto; width: 44px; height: 14px; line-height: 6px; font-size: 14px; padding: 0; border: 1px solid var(--line); border-top: 0;
  border-radius: 0 0 8px 8px; background: var(--panel); color: var(--muted); cursor: pointer; opacity: .55; transition: opacity .15s; }
.dash-handle:hover, .dash-handle:focus-visible { opacity: 1; color: var(--text); }

/* 1.82: a widget's text shrinks with the widget (width and height), down to a readable floor. Each widget is a size
   container on desktop (its grid cell fixes its height); phones keep the stacked layout and normal sizes. Sizes
   inside are relative to the widget's own size, so rows, tables and labels shrink together and stay lined up. */
@media (min-width: 761px) {
  .dgrid .wcell { container: wcell / size; }
  .dgrid:not(.dgrid-wall) .wcell .w-body { font-size: clamp(11.5px, min(3.6cqi, 6.4cqb), 14px); }
  .dgrid-wall .wcell .w-body { font-size: clamp(13px, min(4cqi, 7cqb), 17px); }
  .dgrid:not(.dgrid-wall) .wcell .w-title { font-size: clamp(11px, min(3.4cqi, 6cqb), 14px); }
  .wcell .w-body .small, .wcell .w-body small { font-size: max(10.5px, .9em); }
  .wcell .w-body table.grid { font-size: inherit; }
  .wcell .w-body .grid th { font-size: max(10.5px, .88em); padding: .45em .75em; }
  .wcell .w-body .grid td { padding: .4em .75em; }
  .wcell .w-body .w-legend { font-size: max(10.5px, .86em); }
  .wcell .w-body .w-bar-l { font-size: max(10.5px, .93em); }
  .wcell .w-big-n { font-size: clamp(20px, min(15cqi, 26cqb), 40px); }
  .dgrid-wall .wcell .w-big-n { font-size: clamp(28px, min(16cqi, 28cqb), 72px); }
  .wcell .sb-n { font-size: clamp(18px, min(9cqi, 16cqb), 30px); }
  .dgrid-wall .wcell .sb-n { font-size: clamp(24px, min(10cqi, 18cqb), 56px); }
  .wcell .w-count strong { font-size: clamp(16px, min(6cqi, 11cqb), 24px); }
  .wcell .sb-tile { padding: max(5px, .55em) max(6px, .7em); }
  .wcell .rail-num { font-size: clamp(14px, min(5cqi, 9cqb), 22px); }
}
/* 1.82: long error texts (a URL a source refused) wrap instead of widening the page */
.notice-box, .notice-box li, .form-error { overflow-wrap: anywhere; }
@media (min-width: 761px) {
  /* the ticker is one row by design: its text goes by the widget's width only */
  .dgrid:not(.dgrid-wall) .wcell-ticker .w-body { font-size: clamp(12.5px, 3.6cqi, 14px); }
  .dgrid-wall .wcell-ticker .w-body { font-size: inherit; }
}

/* 1.84: the new-version badge, Settings › Upgrade and › License */
.upg-badge { display: inline-flex; align-items: center; gap: 4px; padding: 0 8px; border-radius: 999px; text-decoration: none; color: var(--accent); border: 1px solid currentColor; height: 30px; font-size: 12.5px; font-weight: 600; white-space: nowrap; }
.upg-badge.early { color: var(--sev-warning); }
.upg-badge.warn { color: var(--sev-warning); background: color-mix(in srgb, currentColor 10%, transparent); }
.upg-badge.bad { color: var(--sev-critical); background: color-mix(in srgb, currentColor 10%, transparent); }
.upg-badge[hidden] { display: none; }
body.slim-top .upg-badge { height: 24px; padding: 0 6px; }
body.slim-top .upg-badge .upg-badge-v { display: none; }
.upg-rel { border-top: 1px solid var(--line); padding: 12px 0; }
.upg-rel:first-of-type { border-top: 0; }
.upg-rel-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; }
.upg-rel-head h4 { margin: 0; font-size: 16px; }
.upg-actions { gap: 8px; align-items: center; flex-wrap: wrap; margin-top: 8px; }
.upg-actions input[type=datetime-local] { width: auto; min-width: 0; }
.upg-notes { margin: 6px 0; }
.rel-notes h4 { margin: 10px 0 4px; font-size: 13px; }
.rel-notes ul { margin: 0 0 6px 18px; padding: 0; }
.upg-log { max-height: 70vh; overflow: auto; white-space: pre-wrap; font-size: 12px; }
.upg-log-note { margin: 0 0 6px; }
.upg-progress { margin: 10px 0 8px; display: grid; gap: 6px; max-width: 640px; }
.upg-progress-head { display: flex; justify-content: space-between; gap: 12px; }
.upg-bar { height: 10px; border-radius: 999px; background: var(--panel-2); border: 1px solid var(--line); overflow: hidden; }
.upg-bar > span { display: block; height: 100%; background: var(--accent, var(--link)); transition: width .6s ease; }
.upg-progress p { margin: 0; }
.upg-upload { display: flex; flex-wrap: wrap; gap: 12px; align-items: end; }
.upg-upload label { display: grid; gap: 4px; font-size: 13px; }
.upg-confirm .field { margin-top: 10px; }
.lic-bar { display: inline-block; vertical-align: middle; width: 120px; height: 8px; margin-left: 10px; border-radius: 4px; background: var(--line); overflow: hidden; }
.lic-bar span { display: block; height: 100%; background: var(--ok); }
.lic-bar span.near { background: var(--sev-warning); }
.lic-bar span.full { background: var(--sev-critical); }
.kv-row { display: flex; gap: 12px; padding: 4px 0; flex-wrap: wrap; }
.kv-row .kv-k { width: 140px; color: var(--muted); }
.lic-warn { color: var(--sev-major); }
/* 1.85: automatic poller updates, per customer */
.poller-auto { display: grid; gap: 6px; margin: 8px 0 12px; justify-items: start; text-align: left; }
.poller-auto .inline-field { display: flex; flex-direction: row; flex-wrap: wrap; align-items: center; justify-content: flex-start; gap: 8px 12px; margin: 0; }
.poller-auto .inline-field > span { font-weight: 600; }
.poller-auto select { width: auto; min-width: 14rem; }
.poller-auto p { margin: 0; }
.poller-auto-cust summary { cursor: pointer; color: var(--muted); }
.poller-auto-cust .form-grid { margin-top: 8px; }
/* 1.86: System › Modules */
.module-list { display: grid; gap: 12px; max-width: 720px; }
.module-row { border: 1px solid var(--line); border-radius: 8px; padding: 12px 14px; display: grid; gap: 4px; }
.module-row p { margin: 0; }
.module-switch { display: flex; align-items: center; gap: 10px; }
/* 1.86: rack layouts */
.rack-layout { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 16px; align-items: start; }
.rack-layout:fullscreen { background: var(--bg); padding: 16px; overflow: auto; }
.rack-rows { display: grid; gap: 18px; min-width: 0; }
.rack-row { background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; min-width: 0; }
.rack-row h2 { margin: 0 0 8px; font-size: 1.05rem; }
.rack-row-scroll { overflow-x: auto; }
.rack-row-svg { display: block; }
.rack-row-svg .rack-item[role=button] { cursor: pointer; }
.rack-row-svg .rack-item:focus { outline: none; }
.rack-row-svg .rack-item:focus-visible > rect:first-of-type { stroke: var(--focus); stroke-width: 2.5; }
.rack-side { width: 300px; max-height: calc(100vh - 160px); overflow: auto; position: sticky; top: 8px; background: var(--panel); border: 1px solid var(--line); border-radius: var(--radius); padding: 12px; display: grid; gap: 8px; align-content: start; }
.rack-side h3 { margin: 8px 0 0; font-size: .95rem; }
.rack-side input[type=search] { width: 100%; }
.rack-unplaced { list-style: none; margin: 0; padding: 0; display: grid; gap: 2px; max-height: 40vh; overflow: auto; }
.rack-unplaced button { width: 100%; text-align: left; background: none; border: 1px solid transparent; border-radius: var(--radius-sm); padding: 5px 6px; color: var(--text); cursor: pointer; }
.rack-unplaced button:hover, .rack-unplaced button.active { border-color: var(--focus); background: var(--panel-2); }
.rack-passive { display: flex; flex-wrap: wrap; gap: 6px; }
.rack-item-form { border: 1px solid var(--focus); border-radius: var(--radius-sm); padding: 10px; }
.rack-item-form h3 { margin: 0; }
.rack-status { min-height: 1.3em; margin: 4px 0 8px; }
.rack-structure { display: grid; gap: 12px; margin-top: 12px; }
.rack-struct-row { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px; display: grid; gap: 8px; }
.rack-struct-row legend input { font-weight: 600; }
.rack-struct-row table input:not([type=checkbox]) { width: 100%; min-width: 70px; }
.rack-line { margin: 6px 0 10px; display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
@media (max-width: 900px) { .rack-layout { grid-template-columns: 1fr; } .rack-side { width: auto; position: static; max-height: none; } }
/* 1.86: drive layout dialog */
.dl-table input, .dl-table select { width: 100%; min-width: 60px; }
.dl-preview-box { overflow-x: auto; margin-top: 8px; }
.dl-preview { max-width: 100%; }
.dl-preview .dl-bay { fill: var(--panel-2); stroke: var(--line); }
.dl-preview .dl-num { fill: var(--text); font-size: 10px; }
.dl-preview .dl-side { fill: var(--muted); font-size: 11px; }
/* 1.86: MX chassis */
.mx-wrap { margin: 4px 0 8px; }
.mx-faces { display: flex; flex-wrap: wrap; gap: 16px; align-items: flex-start; }
.mx-chassis { max-width: 100%; height: auto; }
/* 1.86: a power bar's loads in the rack item panel */
.rack-loads { font-size: 12px; margin-top: 4px; }
.rack-loads td { padding: 2px 6px 2px 0; }
/* 1.86.2: the rack layout's temperature overlay */
.rack-heat-legend { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 20px; margin: 4px 0 8px; }
.rack-heat-scale { display: inline-flex; align-items: center; gap: 6px; }
.rack-heat-bar { display: inline-block; width: 120px; height: 10px; border-radius: 5px; border: 1px solid var(--line); }
.rack-temp { paint-order: stroke; stroke: var(--panel); stroke-width: 2.5px; }
/* 1.87: an alert or device of another customer than the one chosen */
.other-customer { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; justify-content: space-between; margin: 6px 0 10px; }
/* 1.87: estimated rack readings, and the bar when someone else changed the layout */
.rack-temp.est { font-style: italic; }
.rack-stale { display: flex; flex-wrap: wrap; gap: 8px 12px; align-items: center; justify-content: space-between; margin: 6px 0; }
/* 1.88: interruption marks in lists */
.int-divider td, li.int-divider { background: var(--bg-soft, transparent); color: var(--muted); font-size: 12px; font-style: italic; padding: 4px 10px; border-top: 1px dashed var(--line); border-bottom: 1px dashed var(--line); }
li.int-divider { list-style: none; }
.badge.int-tag { background: transparent; border: 1px dashed var(--muted); color: var(--muted); }
.int-note { margin: 6px 0; }
/* 1.88.1: placing an item: its height and depth first */
.rack-placing { border: 1px solid var(--line); border-radius: 6px; padding: 8px 10px; margin: 8px 0; background: var(--panel); }
.rack-placing h3 { margin: 0 0 6px; font-size: 14px; }
.rack-placing .form-grid { grid-template-columns: 1fr 1.6fr; }
/* 1.90: a button that explains why it can't act yet */
.btn.is-off { opacity: .5; }
/* 1.90: options kept out of the way */
details.not-recommended { border: 1px dashed var(--line); border-radius: 6px; padding: 6px 10px; margin-top: 8px; }
details.not-recommended > summary { cursor: pointer; font-weight: 600; color: var(--warn, #a86a00); }
details.not-recommended[open] > summary { margin-bottom: 6px; }
.setup-badge { margin-right: 6px; }

/* 1.91: Upgrading (purple): failing during a Beacon or poller upgrade, held and not notified */
.status-upgrading { color: var(--threat); }
.status-upgrading .dot { background: var(--threat); clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); border-radius: 0; width: 10px; height: 10px; }
.map-node .box.st-upgrading { stroke: var(--threat); stroke-width: 3; stroke-dasharray: 5 3; }
.map-st.st-upgrading { fill: var(--threat); }
.pill.st-upgrading { background: color-mix(in srgb, var(--threat) 20%, transparent); }
.rm-node.st-upgrading rect { stroke: var(--threat); }
.dot.st-upgrading { background: var(--threat); }
.icon-ring.st-upgrading { stroke: var(--threat); }
.st-upgrading strong, .st-upgrading .w-big-n { color: var(--threat); }
.sb-tile.sb-upgrading .sb-n { color: var(--threat); }
.rail-seg.upg-bg { background: var(--threat); }
.sev-badge.held, .badge.held { background: color-mix(in srgb, var(--threat) 18%, transparent); border: 1px solid var(--threat); color: var(--threat); border-radius: 4px; padding: 0 6px; font-size: .78em; font-weight: 700; white-space: nowrap; }
tr.ev-held td { background: color-mix(in srgb, var(--threat) 7%, transparent); }
tr.ev-held td:first-child { box-shadow: inset 3px 0 0 var(--threat); }
.hb-cell.held, .hb-bar .held { background: var(--threat) !important; }
.upg-live { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; padding: 8px 16px; background: color-mix(in srgb, var(--threat) 16%, var(--panel)); border-bottom: 2px solid var(--threat); color: var(--text); font-size: .92em; }
.upg-live.slim { padding: 4px 16px; font-size: .86em; border-bottom-width: 1px; }
.upg-live strong { color: var(--threat); }
.upg-live .ub-spin { width: 10px; height: 10px; border: 2px solid var(--threat); border-top-color: transparent; border-radius: 50%; animation: ubspin 1s linear infinite; }
@keyframes ubspin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .upg-live .ub-spin { animation: none; } }
.upg-timeline { list-style: none; margin: 8px 0; padding: 0 0 0 14px; border-left: 2px solid var(--line); display: grid; gap: 6px; }
.upg-timeline li { position: relative; }
.upg-timeline li::before { content: ''; position: absolute; left: -20px; top: .45em; width: 10px; height: 10px; border-radius: 50%; background: var(--muted); }
.upg-timeline li.k-beacon::before { background: var(--accent); } .upg-timeline li.k-poller::before { background: var(--threat); }
.upg-timeline li.k-hold::before { background: var(--threat); border-radius: 0; clip-path: polygon(50% 0, 100% 50%, 50% 100%, 0 50%); }
.upg-timeline li.k-outcome::before { background: var(--sev-normal); }
.upg-timeline time { color: var(--muted); font-variant-numeric: tabular-nums; margin-right: 8px; }
.held-sum { display: flex; gap: 16px; flex-wrap: wrap; }
.held-sum b { font-size: 1.3em; display: block; }
/* 1.91: Enter to continue: required fields left empty or invalid */
.field-bad, input.field-bad, select.field-bad, textarea.field-bad { outline: 2px solid var(--sev-critical) !important; outline-offset: 1px; border-color: var(--sev-critical) !important; }
.field-msg { color: var(--sev-critical); font-size: .85em; margin-top: 3px; }
.form-sum { color: var(--sev-critical); font-weight: 600; margin: 6px 0; }
/* 1.92: the upgrade's last check */
.last-check { margin-top: 6px; }
.lc-steps { list-style: none; padding: 0; margin: 4px 0; display: grid; gap: 3px; font-size: .92em; }
.lc-steps .lc-mark { display: inline-block; width: 1.2em; text-align: center; }
.lc-done { color: var(--text); } .lc-done .lc-mark { color: var(--sev-normal); }
.lc-now { font-weight: 600; } .lc-now .lc-mark { color: var(--accent); animation: lcpulse 1.4s ease-in-out infinite; }
.lc-next { color: var(--muted); }
@keyframes lcpulse { 50% { opacity: .35; } }
@media (prefers-reduced-motion: reduce) { .lc-now .lc-mark { animation: none; } }
.warn-text, .ub-warn { color: var(--sev-major); font-weight: 600; }
/* 1.92: the Alerts widget */
.aw { display: flex; flex-direction: column; height: 100%; min-height: 0; position: relative; }
.aw-list { flex: 1 1 auto; min-height: 0; overflow-y: auto; padding-right: 2px; }
.aw-rows { display: flex; flex-direction: column; gap: 1px; }
.aw-row { display: flex; align-items: center; gap: 8px; padding: 3px 6px 3px 0; border-left: 3px solid transparent; cursor: pointer; font-size: .9em; min-width: 0; }
.aw-row:hover, .aw-row:focus-visible { background: var(--hover, color-mix(in srgb, var(--text) 6%, transparent)); outline: none; }
.aw-row.sev-row-5 { border-left-color: var(--sev-critical); } .aw-row.sev-row-4 { border-left-color: var(--sev-major); }
.aw-row.sev-row-3 { border-left-color: var(--sev-minor); } .aw-row.sev-row-2 { border-left-color: var(--sev-warning); } .aw-row.sev-row-1 { border-left-color: var(--sev-info); }
.aw-row.held { border-left-color: var(--threat); background: color-mix(in srgb, var(--threat) 7%, transparent); }
.aw-row.acked { opacity: .55; }
.aw-row.gone .aw-msg { text-decoration: line-through; }
.aw-row.gone { opacity: .5; }
.aw-ack { flex: 0 0 22px; width: 22px; height: 22px; border-radius: 50%; border: 1.5px solid var(--line); background: transparent; color: transparent; cursor: pointer; font-size: 12px; line-height: 1; padding: 0; }
.aw-ack:hover, .aw-ack:focus-visible { border-color: var(--accent); color: var(--accent); }
.aw-ack.on { background: var(--sev-normal); border-color: var(--sev-normal); color: #fff; }
.aw-ack.none { border-color: transparent; cursor: default; }
.aw-t { color: var(--muted); font-variant-numeric: tabular-nums; white-space: nowrap; flex: 0 0 auto; }
.aw-dev { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 30%; flex: 0 0 auto; }
.aw-msg { flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aw-cust, .aw-who { white-space: nowrap; font-size: .85em; flex: 0 0 auto; }
.aw-why { font-size: .8em; border: 1px dashed var(--line); border-radius: 4px; padding: 0 5px; white-space: nowrap; color: var(--muted); }
.aw-tabs { display: flex; gap: 4px; border-top: 1px solid var(--line); padding-top: 4px; margin-top: 4px; flex: 0 0 auto; }
.aw-tab { background: none; border: 1px solid transparent; border-radius: 4px; padding: 1px 8px; font-size: .8em; color: var(--muted); cursor: pointer; }
.aw-tab.on { border-color: var(--line); color: var(--text); font-weight: 600; background: var(--panel); }
.aw-n { margin-left: 5px; font-variant-numeric: tabular-nums; opacity: .8; }
.aw-new { position: absolute; bottom: 34px; left: 50%; transform: translateX(-50%); background: var(--accent); color: #fff; border: 0; border-radius: 12px; padding: 2px 10px; font-size: .8em; cursor: pointer; box-shadow: 0 2px 6px rgba(0,0,0,.25); }
.aw-flash { animation: awflash 1.6s ease-out 1; }
@keyframes awflash { from { background: color-mix(in srgb, var(--accent) 25%, transparent); } }
@media (prefers-reduced-motion: reduce) { .aw-flash { animation: none; } }
.slider-row { display: inline-flex; align-items: center; gap: 8px; } .slider-row input[type=range] { width: 200px; }
/* 1.92: Device tiles: size, and Arrange by hand */
.w-tiles.ts-scaled .tile-grid { grid-template-columns: repeat(auto-fill, minmax(var(--ts-w), 1fr)); gap: var(--ts-gap); }
.w-tiles.ts-scaled .dev-tile { padding: calc(var(--ts-pad) + 2px) var(--ts-pad) var(--ts-pad); gap: calc(var(--ts-gap) * .6); border-radius: calc(var(--ts-pad) + 3px); }
.w-tiles.ts-scaled .tile-name { font-size: var(--ts-font); line-height: 1.15; }
.w-tiles.ts-scaled .tile-icon { height: var(--ts-icon); }
.w-tiles.ts-scaled .tile-icon svg { width: var(--ts-icon); height: var(--ts-icon); }
.w-tiles.ts-scaled .tile-foot { font-size: max(6px, calc(var(--ts-font) - 1.5px)); }
.w-tiles.ts-scaled .tile-badge { transform: scale(.75); transform-origin: top right; top: 2px; right: 2px; }
.w-tiles.ts-scaled .tg-label, .w-tiles.ts-scaled .tg-toggle { font-size: max(9px, calc(var(--ts-font) + 1px)); }
.w-tiles.ts-compact .dev-tile { aspect-ratio: auto; min-height: calc(var(--ts-font) * 2.6 + var(--ts-icon)); box-shadow: inset 0 2px 0 var(--tc); }
.w-tiles.ts-compact .tile-name { -webkit-line-clamp: 1; white-space: nowrap; text-overflow: ellipsis; display: block; }
/* 1.92.1: below 70% no status dot, word, alarm-count badge or marks; problems striped instead. Below 60% no icon */
.w-tiles.ts-nostatus .tile-foot, .w-tiles.ts-nostatus .tile-badge, .w-tiles.ts-nostatus .tile-int, .w-tiles.ts-nostatus .tile-match { display: none; }
.w-tiles.ts-nostatus .tile-down { background-image: repeating-linear-gradient(135deg, color-mix(in srgb, var(--tc) 30%, transparent) 0 2px, transparent 2px 6px); }
.w-tiles.ts-nostatus .tile-degraded, .w-tiles.ts-nostatus .tile-warning, .w-tiles.ts-nostatus .tile-unreachable { outline: 1.5px dotted var(--tc); outline-offset: -3px; }
.w-tiles.ts-noicon .tile-icon { display: none; }
/* 1.92.1: rows keep their tiles when shrinking (as many as fit at 100%) */
.w-tiles.ts-rows .tile-grid { grid-template-columns: repeat(var(--ts-cols, 1), minmax(0, var(--ts-w))); justify-content: start; }
.w-tiles { overflow-x: hidden; }
.w-tiles.ts-free .tile-grid { transform-origin: top left; }
.w-tiles.ts-noicon .dev-tile { justify-content: center; min-height: calc(var(--ts-font) * 2.4); }
.w-tiles.ts-free .tg-head { display: none; }
.w-tiles.ts-free .tile-grid { display: block; position: relative; min-height: 40px; }
.w-tiles.ts-free .dev-tile { position: absolute; transition: left .12s, top .12s; }
.w-tiles.ts-free .dev-tile.ts-moving { transition: none; z-index: 3; opacity: .85; cursor: grabbing; }
.w-tiles.ts-free.ts-dragging .tile-grid { background-image: radial-gradient(circle, color-mix(in srgb, var(--text) 25%, transparent) 1px, transparent 1.5px);
  background-size: var(--ts-unit-w) var(--ts-unit-h); }
.dgrid-edit .w-tiles.ts-free .dev-tile { cursor: grab; touch-action: none; }
.w-tiles .ts-picked { outline: 2px dashed var(--accent); outline-offset: 1px; }
.ts-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; padding: 2px 0 6px; }
@media (prefers-reduced-motion: reduce) { .w-tiles.ts-free .dev-tile { transition: none; } }
.aw-state { font-size: .78em; padding: 0 6px; border-radius: 9px; white-space: nowrap; flex: 0 0 auto; border: 1px solid var(--line); color: var(--muted); }
.aw-state.st-open { color: var(--sev-critical); border-color: color-mix(in srgb, var(--sev-critical) 50%, var(--line)); }
.aw-state.st-acked { color: var(--text); }

/* 1.92.2: Device tiles: one fixed tile size at every widget width (wrap, never stretch), steady on refresh */
.w-tiles { font-size: 13px; scrollbar-gutter: stable; }
.w-tiles.ts-rows .tile-grid { grid-template-columns: repeat(var(--ts-cols, 1), var(--ts-w, 112px)); gap: var(--ts-gap, 10px); justify-content: start; }
.w-tiles.ts-rows .dev-tile { width: var(--ts-w, 112px); }
.w-tiles.ts-free .dev-tile { height: var(--ts-h); aspect-ratio: auto; }
.dgrid-edit .w-tiles.ts-free .tile-grid { touch-action: none; user-select: none; }
.ts-box { position: absolute; border: 1px dashed var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); pointer-events: none; z-index: 4; }
.slider-row input[type=range], input[type=range] { padding: 0; border: 0; background: transparent; }
/* 1.93: Logs › Insights */
.li-tabs { margin-top: -6px; }
.li-tabs .tab { font-size: .92em; }
.li-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 10px; }
.li-tile { background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 10px 12px; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.li-tile .li-n { font-size: 24px; font-weight: 800; font-variant-numeric: tabular-nums; line-height: 1.1; }
.li-tile .li-l { font-weight: 600; font-size: .9em; }
.li-tile .li-s { color: var(--muted); font-size: .8em; }
.li-tile.bad { border-color: var(--danger); } .li-tile.bad .li-n { color: var(--danger); }
.li-tile.accent .li-n { color: var(--link); }
.li-warn { color: var(--sev-major); font-weight: 600; margin: 8px 0 0; }
.li-table td.num, .li-table th.num { text-align: right; font-variant-numeric: tabular-nums; }
.li-tpl { font-size: .85em; white-space: pre-wrap; overflow-wrap: anywhere; }
.li-sample { max-width: 80ch; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.li-reason { display: inline-block; padding: 0 7px; border-radius: 9px; font-size: .8em; font-weight: 700; border: 1px solid var(--line); }
.li-reason.r-new_template { color: var(--link); border-color: color-mix(in srgb, var(--link) 50%, var(--line)); }
.li-reason.r-rate_spike { color: var(--sev-major); border-color: color-mix(in srgb, var(--sev-major) 50%, var(--line)); }
.li-reason.r-silence { color: var(--muted); border-style: dashed; }
.li-learn { font-size: .82em; font-weight: 600; }
.li-learn.l-learning { color: var(--muted); } .li-learn.l-baseline { color: var(--sev-minor); } .li-learn.l-ready { color: var(--sev-normal); }
tr.li-done td { opacity: .6; }
.li-pre { background: var(--panel-2); border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 10px; white-space: pre-wrap; overflow-wrap: anywhere; font-size: .85em; max-height: 300px; overflow: auto; }
.li-set { display: grid; grid-template-columns: minmax(220px, 1fr) 2fr; gap: 4px 14px; align-items: center; padding: 4px 0; }
.li-set label { display: flex; align-items: center; gap: 10px; justify-content: space-between; }
.li-set-l { font-weight: 600; }
@media (max-width: 700px) { .li-set { grid-template-columns: 1fr; } }
.li-checks { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.li-chips { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 6px; }
.li-chips .chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 4px 2px 10px; border: 1px solid var(--line); border-radius: 999px; font-size: .88em; }
.li-chips .chip-x { background: none; border: 0; cursor: pointer; color: var(--muted); font-size: 1.1em; padding: 0 4px; }
.li-modes { display: grid; gap: 6px; }
/* 1.94: Log Insights Stage 1 (the local model) and AI alarms */
.li-label { display: inline-block; padding: 0 7px; border-radius: 9px; font-size: .8em; font-weight: 700; border: 1px solid var(--line); white-space: nowrap; color: var(--muted); }
.li-label.lb-worth_a_look { color: var(--sev-major); border-color: color-mix(in srgb, var(--sev-major) 55%, var(--line)); }
.li-label.lb-expected_change { color: var(--link); border-color: color-mix(in srgb, var(--link) 45%, var(--line)); }
.li-label.lb-noise { color: var(--muted); }
.li-label.lb-failed { color: var(--danger); border-style: dashed; }
.li-label.lb-waiting, .li-label.lb-working, .li-label.lb-none, .li-label.lb-skipped { border-style: dashed; font-weight: 600; }
.li-summary { white-space: pre-wrap; overflow-wrap: anywhere; }
td .li-summary { margin-top: 3px; color: var(--text); }
.li-labels { border: 1px solid var(--line); border-radius: var(--radius-sm); padding: 8px 12px; margin: 10px 0; }
.li-lab-head { display: flex; align-items: center; gap: 10px; } .li-lab-head h4 { margin: 0; flex: 1; }
.li-verdict { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 6px; }
.li-verdict .btn.on { border-color: var(--link); color: var(--link); font-weight: 700; }
.li-hist { margin-top: 8px; } .li-hist ul { margin: 4px 0 0; padding-left: 18px; }
.li-mask-sw { margin: 8px 0 0; font-weight: 600; }
.li-model .li-state { font-size: 18px; }
.li-acc ul { margin: 4px 0 0; padding-left: 18px; }
.li-ok { color: var(--sev-normal); font-weight: 600; }
.li-test-out { margin-top: 10px; }
.ai-badge { background: color-mix(in srgb, var(--link) 14%, transparent); color: var(--link); border: 1px solid color-mix(in srgb, var(--link) 45%, var(--line)); font-weight: 800; letter-spacing: .04em; margin-right: 6px; }
.ai-evidence { border: 1px solid color-mix(in srgb, var(--link) 35%, var(--line)); border-radius: var(--radius-sm); padding: 10px 12px; margin: 10px 0; }
.ai-evidence h3 { margin: 0 0 6px; font-size: 1em; }
.ai-acts { display: flex; gap: 8px; flex-wrap: wrap; margin-top: 8px; }
.li-labels dd .chip { display: inline-block; margin: 0 6px 4px 0; padding: 1px 8px; border: 1px solid var(--line); border-radius: 999px; font-size: .85em; }
/* 1.95: Next / Back on the device page */
.dev-nav-host { margin-left: auto; }
.dev-nav { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.page-head .dev-nav-host + .head-actions, .page-head .head-actions + .dev-nav-host { margin-left: 12px; }
.rack-why { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
/* 1.95: iDRAC / OS link */
.bmc-card p { margin: 4px 0 0; }
.bmc-hw { margin-top: 10px; }
.bmc-power:empty { display: none; }
/* 1.95: routing map paths and BFD */
.rm-oneend { stroke-width: 1 !important; stroke-dasharray: 4 3; }
.rm-bfd { stroke: var(--panel, #fff); stroke-width: 1.5; }
.rm-bfd-up { fill: var(--sev-normal, #2a9d5b); }
.rm-bfd-down, .rm-bfd-init { fill: var(--danger, #d33); }
.rm-bfd-admin_down { fill: var(--muted, #999); }
.rm-bfd-none { fill: var(--panel, #fff); stroke: var(--muted, #999); }
/* 1.95: OSPF tab */
.ospf-peer { margin: 12px 0; }
.ospf-peer-head { margin-bottom: 4px; }
.ospf-table tr.ospf-down td { background: color-mix(in srgb, var(--danger, #d33) 7%, transparent); }
.ospf-hist ul { margin: 6px 0 0; padding-left: 18px; }

/* 1.96: Log Insights cloud model */
.li-sides { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 16px; align-items: start; }
.li-sides > * { min-width: 0; }
.li-cloud { border-left: 3px solid var(--accent); }
.li-amber { color: var(--sev-minor); font-weight: 600; }
.li-account { display: flex; flex-direction: column; gap: 4px; }
.li-own { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 8px; }
.li-tenant-cloud .li-checks { margin: 4px 0 8px 24px; }
.li-picker { display: inline-flex; gap: 6px; align-items: center; flex-wrap: wrap; }
/* 1.97: AI usage */
.au-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(420px, 1fr)); gap: 12px; }
.au-grid > * { min-width: 0; }
.au-chart { height: 240px; }

/* 1.99: AI Insights, the case's context */
.li-context { margin-top: 12px; }
.li-context .li-ctx-addrs td { vertical-align: top; }
.li-context .chip.small { margin-left: 4px; }
.li-threat { color: var(--danger, #b42318); font-weight: 600; }
.li-ctx-changes { margin: 4px 0 8px 18px; padding: 0; }
.li-ctx-boxes .check { display: block; }

/* 2.0: AI Insights › Expected and Safe */
.row-inline { display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.li-chart { display: flex; flex-direction: column; gap: 2px; margin: 4px 0 12px; }
.li-bars { width: 100%; max-width: 640px; height: auto; }
.li-bars rect { fill: var(--accent, #2f6fb0); }
.li-bars rect:hover { opacity: .75; }
.li-bars text { font-size: 10px; fill: var(--muted, #6b7280); }
.li-devlist { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 2px 12px; max-height: 220px; overflow: auto; padding: 4px 0; }
.li-test-out ul { margin: 4px 0 8px 18px; }
.li-safe code, .li-expected code { word-break: break-all; }
.ts-list { display: flex; flex-direction: column; gap: 12px; }
.ts-summary { white-space: pre-wrap; font-size: 12.5px; background: var(--bg-soft, rgba(127,127,127,.08)); padding: 10px 12px; border-radius: 6px; max-height: 260px; overflow: auto; }
.ts-card progress { width: min(320px, 100%); vertical-align: middle; }
.ts-indent { margin-left: 22px; }

/* 2.1: Suggest a fix */
.sg-panel { margin-top: 14px; border-top: 1px solid var(--line, rgba(127,127,127,.25)); padding-top: 10px; }
.sg { border: 1px solid var(--line, rgba(127,127,127,.25)); border-radius: 8px; padding: 10px 12px; margin: 10px 0; }
.sg-head { display: flex; gap: 10px; align-items: baseline; flex-wrap: wrap; }
.sg-head h4 { margin: 0; }
.sg-head .sg-del { margin-left: auto; color: var(--danger, #c0392b); }
.sg-turn { border-top: 1px dashed var(--line, rgba(127,127,127,.25)); padding-top: 8px; margin-top: 8px; }
.sg-turn:first-child { border-top: 0; margin-top: 0; }
.sg-summary { font-weight: 500; }
.sg-causes li, .sg-steps li { margin: 4px 0; }
.sg-cmds { margin: 4px 0 2px; display: flex; flex-direction: column; gap: 3px; }
.sg-cmd { display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.sg-cmd code { background: var(--bg-soft, rgba(127,127,127,.1)); padding: 1px 6px; border-radius: 4px; word-break: break-all; }
.sg-caution { background: var(--warn-bg, rgba(230,160,0,.12)); padding: 6px 8px; border-radius: 6px; }
.sg-plain { white-space: pre-wrap; font-size: 12px; }
.sg-follow input { flex: 1 1 240px; min-width: 0; }
.sg-conf-high { background: rgba(40,160,80,.15); }
.sg-conf-low { background: rgba(230,160,0,.18); }
.sg-working { color: var(--muted, #6b7280); }
.kind-tag.kind-ai { background: rgba(120,90,220,.15); color: inherit; }
.sg-acts .on { outline: 2px solid var(--accent, #2f6fb0); border-radius: 4px; }

/* 2.2.0: Whois Live DNS, Email DNS servers */
.ts-live-dns, .ts-disagree { margin-top: 12px; }
.ts-live-dns tr.ts-differs td { background: color-mix(in srgb, var(--sev-warning) 12%, transparent); }
.ts-asked { margin: 4px 0 8px; }

/* 2.2.0: Run from dropdown (pollerselect.ts) */
.psel { position: relative; max-width: 640px; margin: 8px 0; }
.psel-field { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 6px; min-height: 36px; padding: 4px 30px 4px 10px; border: 1px solid var(--line); border-radius: 6px; background: var(--panel); cursor: pointer; position: relative; }
.psel-field:focus-visible { outline: 2px solid var(--focus); outline-offset: 1px; }
.psel-label { font-weight: 600; margin-right: 2px; }
.psel-none { color: var(--danger); }
.psel-chip { display: inline-flex; align-items: center; gap: 2px; padding: 1px 4px 1px 8px; border-radius: 999px; background: var(--panel-2); font-size: .9em; white-space: nowrap; max-width: 22ch; overflow: hidden; text-overflow: ellipsis; }
.psel-x { border: 0; background: none; cursor: pointer; padding: 0 4px; color: inherit; opacity: .7; font-size: 1.05em; line-height: 1; }
.psel-x:hover, .psel-x:focus-visible { opacity: 1; }
.psel-more { font-size: .9em; color: var(--muted); }
.psel-caret { position: absolute; right: 10px; top: 50%; transform: translateY(-50%); color: var(--muted); }
.psel-pop { position: absolute; z-index: 40; left: 0; right: 0; top: calc(100% + 4px); min-width: 280px; max-height: 420px; display: flex; flex-direction: column; gap: 6px; padding: 8px; border: 1px solid var(--line); border-radius: 8px; background: var(--panel); box-shadow: var(--shadow); }
.psel-search { width: 100%; }
.psel-tools { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }
.psel-list { overflow-y: auto; min-height: 0; flex: 1 1 auto; }
.psel-group { display: flex; align-items: center; gap: 6px; padding: 4px 2px; border-top: 1px solid var(--line); position: sticky; top: 0; background: var(--panel); }
.psel-block:first-child .psel-group { border-top: 0; }
.psel-toggle { flex: 1; display: flex; align-items: center; gap: 6px; border: 0; background: none; padding: 2px; cursor: pointer; color: inherit; text-align: left; font: inherit; }
.psel-toggle:focus-visible { outline: 2px solid var(--focus); }
.psel-gname { font-weight: 600; flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.psel-items { display: grid; gap: 2px; padding: 2px 0 6px 26px; }
.psel-item { display: flex; align-items: center; gap: 6px; cursor: pointer; }
.psel-item.psel-off { opacity: .5; cursor: not-allowed; }
.psel-nomatch { padding: 6px; }
.psel-tick-gap { display: inline-block; width: 16px; flex: none; }

/* 2.3.0: Scheduling page */
.sched-kinds { margin-top: 14px; }
.sched-kinds dd { margin-bottom: 6px; }
.sched-note .btn { margin-left: 6px; }

/* 2.3.1: Remote pollers: the buttons column stays in view at the right edge, however wide the rest of the table is */
.pollers-table > thead > tr > th:last-child, .pollers-table > tbody > tr > td:last-child { position: sticky; right: 0; z-index: 1; background: var(--panel); box-shadow: -8px 0 8px -8px rgba(0,0,0,.25); }
