/* dashboard screen styles (team round, 23.11.2026). Loaded after screens.css; prefix screen-only classes. */

/* Layout: two columns; cards side by side in one row share the row height. */
.dash { grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); align-items: stretch; }
.dash .widget { display: flex; flex-direction: column; }
.dash .widget > .card { flex: 1 1 auto; height: auto; }

/* Key numbers: five in one row from 992 px. */
.dash-kpis { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: var(--sp-3); }
.dash-kpi-w { position: relative; display: flex; min-width: 0; }
.dash-kpi-w > .kpi { flex: 1 1 auto; min-width: 0; }
.dash-kpis .kpi { padding: var(--sp-3) var(--sp-4); }
.dash-kpis .kpi .l { white-space: normal; }
.dash-kpis .kpi .v { font-size: var(--fs-2xl); }
.dash-kpis .kpi .u { white-space: normal; }
.dash-na { font-size: var(--fs-md); font-weight: 700; color: var(--text-muted); letter-spacing: 0; }

/* Attention: description up to two lines, full text in the tip. */
.dash-att-d { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; white-space: normal; }
.attention-item .grow { min-width: 0; }
.attention-item .btn { flex: none; white-space: nowrap; }

/* Health: one row per item, label left, value right. */
.dash-health { display: flex; flex-direction: column; }
.dash-hrow { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center; gap: var(--sp-3); padding: var(--sp-2) 0; border-bottom: 1px solid var(--border-subtle); font-size: var(--fs-sm); }
.dash-hrow:last-child { border-bottom: none; }
.dash-hrow[data-go] { cursor: pointer; }
.dash-hrow[data-go]:hover .dash-hl > span:last-child { color: var(--accent); }
.dash-hl { display: flex; align-items: center; gap: var(--sp-2); min-width: 0; font-weight: 600; }
.dash-hl > span:last-child { overflow-wrap: break-word; min-width: 0; }
.dash-hl .dot-status { flex: none; }
.dash-hv { text-align: right; color: var(--text-secondary); white-space: nowrap; }

/* Throughput */
.dash-chart .chart-x span:last-child { display: flex; justify-content: flex-end; }

/* Devices */
.dash-dev { min-width: 0; }
.dash-dev .n { display: flex; align-items: center; gap: var(--sp-2); flex-wrap: wrap; }
.device-row .cnt { flex: none; white-space: nowrap; }

/* Queues: one row per queue, text left, number right. */
.dash-queues { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: var(--sp-2); }
.dash-q { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-3); padding: var(--sp-2) var(--sp-3); border-radius: var(--r-md); background: var(--bg-elevated); border: 1px solid var(--border-subtle); cursor: pointer; }
.dash-q:hover { border-color: var(--border-strong); }
.dash-q.alert { border-color: rgba(239, 68, 68, 0.4); }
.dash-qtxt { display: flex; flex-direction: column; gap: 2px; min-width: 0; font-size: var(--fs-sm); }
.dash-qtxt > span:first-child { overflow-wrap: break-word; }
.dash-q b { flex: none; font-family: var(--font-mono); font-size: var(--fs-lg); font-variant-numeric: tabular-nums; }

/* Live feed: five fixed columns; nothing is cut, the status column has a fixed width. */
.dash-feed-head, .dash-frow { display: grid; grid-template-columns: 72px minmax(120px, 1fr) minmax(120px, 1fr) minmax(140px, 2fr) 128px; align-items: center; column-gap: var(--sp-3); }
.dash-feed-head { padding: 0 10px var(--sp-1); font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.06em; color: var(--text-muted); border-bottom: 1px solid var(--border-subtle); margin-bottom: var(--sp-1); }
.dash-frow > span { min-width: 0; white-space: normal; overflow: visible; overflow-wrap: break-word; }
.dash-frow > span.dv, .dash-frow > span.bc { flex: none; overflow: visible; text-overflow: clip; }
.dash-frow .dv { font-family: var(--font-ui); font-size: var(--fs-xs); font-weight: 600; }
.dash-frow .bc { font-variant-ligatures: none; }
.dash-frow .dash-msg { font-family: var(--font-ui); font-size: var(--fs-xs); }
.dash-frow .dash-msg > span[data-tip] { overflow: visible; text-overflow: clip; }
.dash-frow .st { margin-left: 0; }
.dash-feed-empty { padding: var(--sp-6); }

/* Customize: tools sit inside the card, top right; the card's own head actions are hidden meanwhile. */
.dash-wtools { top: var(--sp-3); left: auto; right: var(--sp-3); gap: var(--sp-2); justify-content: flex-end; }
.dash-wtools .handle { padding: 4px; border-radius: var(--r-sm, 6px); }
.dash.editing .widget { margin-top: 0; }
.widget.editing .card-head > :not(h3):not(div:first-child) { visibility: hidden; }
.dash-frow .st, .dash-frow .st .pill { font-family: var(--font-ui); }
.device-row .cnt .xs { font-family: var(--font-ui); font-weight: 600; }

/* Customize, Key Numbers: each card has its own tools in a band above its title (nothing covers the title). */
.dash-kpi-w.editing { outline: 1px dashed var(--border-strong); outline-offset: 3px; border-radius: var(--r-lg); cursor: grab; }
.dash-kpi-w.editing:hover { outline-color: var(--primary); }
.dash-kpi-w.editing.dragging { opacity: 0.4; cursor: grabbing; }
.dash-kpi-w.editing.over { outline: 2px solid var(--accent); }
.dash-kpi-w.editing > .kpi { padding-top: calc(var(--sp-3) + 30px); pointer-events: none; }
.dash-kpi-w .dash-wtools { top: var(--sp-2); right: var(--sp-2); }
.widget.editing.dash-kpi-strip { outline: none; cursor: default; }
