/* Product / Fleet Health — app-specific views only. Shell, header, toolbar,
   and .muted come from /design-system/hive-chrome.css. */

.mono { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

/* ── Controls ─────────────────────────────────────────────────────────── */
.prod-controls { display: flex; align-items: center; flex-wrap: wrap; gap: var(--space-2) var(--space-3); }
.ctl-label { font-size: 12px; font-weight: 600; color: var(--fg-2); text-transform: uppercase; letter-spacing: 0.04em; }
.ctl-note { color: var(--fg-3); font-size: 12.5px; }
.seg { display: inline-flex; border: 1px solid var(--border-default); border-radius: var(--radius-md); overflow: hidden; }
.seg-btn { appearance: none; border: 0; background: var(--n-0); color: var(--fg-2); font: inherit; font-size: 13px; padding: 5px 12px; cursor: pointer; border-right: 1px solid var(--border-default); }
.seg-btn:last-child { border-right: 0; }
.seg-btn:hover { background: var(--bg-subtle); }
.seg-btn.is-on { background: var(--kiss-red); color: #fff; }

/* Manual refresh — pushed to the far right of the toolbar; timestamp sits
   directly below the button. */
.prod-refresh { margin-left: auto; display: flex; flex-direction: column; align-items: flex-end; gap: 3px; }
.prod-refresh-btn { appearance: none; display: inline-flex; align-items: center; gap: 6px; border: 1px solid var(--border-default); border-radius: var(--radius-md); background: var(--n-0); color: var(--fg-1); font: inherit; font-size: 13px; font-weight: 600; padding: 6px 13px; cursor: pointer; }
.prod-refresh-btn:hover { background: var(--bg-subtle); }
.prod-refresh-btn:disabled, .prod-refresh-btn.is-busy { cursor: default; color: var(--fg-3); background: var(--bg-subtle); }
.prod-refresh-btn .rf-icon { font-size: 14px; line-height: 1; }
.prod-refresh-btn .rf-icon.spin { animation: prod-spin 0.9s linear infinite; }
.prod-refresh-ts { color: var(--fg-3); font-size: 11.5px; font-variant-numeric: tabular-nums; }
@keyframes prod-spin { to { transform: rotate(360deg); } }

/* ── Versions table ───────────────────────────────────────────────────── */
.table-wrap { overflow-x: auto; border: 1px solid var(--n-200); border-radius: var(--radius-lg); margin-top: var(--space-5); }
.prod-table { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 760px; }
.prod-table th, .prod-table td { text-align: right; padding: 10px 14px; border-bottom: 1px solid var(--n-100); white-space: nowrap; }
.prod-table th:first-child, .prod-table td:first-child { text-align: left; }
.prod-table thead th { font-size: 11px; text-transform: uppercase; letter-spacing: 0.04em; color: var(--fg-3); font-weight: 600; background: var(--bg-subtle); }
.prod-table thead th [data-tip] { text-decoration: underline dotted var(--fg-3); text-underline-offset: 3px; cursor: help; }
.prod-table thead th.sortable { cursor: pointer; user-select: none; }
.prod-table thead th.sortable:hover { color: var(--fg-1); }
.prod-table tbody tr:last-child td { border-bottom: 0; }
.prod-table tbody tr:hover { background: var(--bg-subtle); }
.prod-table td.mono, .prod-table td:not(:first-child) { font-family: var(--font-mono); font-variant-numeric: tabular-nums; }

.delta { font-family: var(--font-mono); font-size: 11px; margin-left: 6px; }
.delta.up { color: #0F8250; }
.delta.down { color: #B83A2E; }
.delta.flat { color: var(--fg-3); }
.combo { font-weight: 700; }
.combo.good { color: #0F8250; }
.combo.warn { color: #B0770F; }
.combo.bad { color: #B83A2E; }
.prod-foot { margin-top: var(--space-3); max-width: 74ch; font-size: 12.5px; }
.prod-note { max-width: 78ch; margin: 0 0 var(--space-3); font-size: 12.5px; line-height: 1.5; }
/* A build with too few attempts for its percentages to mean much. Shown, not
   hidden — the volume is itself the message. */
.prod-table tr.low-vol td { color: var(--fg-3); }
.prod-table tr.low-vol .combo { color: var(--fg-3); font-weight: 600; }
.thin-flag, .nocmp {
  font-family: var(--font-mono); font-size: 10px; letter-spacing: .02em;
  padding: 1px 5px; border-radius: var(--radius-sm, 3px); margin-left: 6px;
  white-space: nowrap; cursor: help;
}
.thin-flag { color: #B0770F; background: rgba(176, 119, 15, .10); }
.nocmp { color: var(--fg-3); background: var(--n-100, rgba(0, 0, 0, .05)); }
.prod-table tr.ref-row td { color: var(--fg-3); border-top: 2px solid var(--n-200); background: var(--bg-subtle); }
.prod-table tr.ref-row .combo { color: var(--fg-2); font-weight: 600; }

/* ── Headline trend ───────────────────────────────────────────────────── */
.trend-block { margin: var(--space-5) 0 var(--space-6); }
.trend-sub { font-weight: 400; font-size: 12.5px; color: var(--fg-3); margin-left: 6px; }

/* ── Journeys view ────────────────────────────────────────────────────── */
.prod-intro { max-width: 74ch; margin: var(--space-5) 0 var(--space-2); font-size: 13.5px; line-height: 1.55; }
.ver-pick { display: flex; align-items: center; gap: var(--space-3); margin: var(--space-5) 0 var(--space-2); }
.ver-pick label { font-size: 12px; font-weight: 600; color: var(--fg-2); text-transform: uppercase; letter-spacing: 0.04em; }
.ver-pick select { font: inherit; font-size: 14px; padding: 6px 10px; border: 1px solid var(--border-default); border-radius: var(--radius-md); background: var(--n-0); color: var(--fg-1); }
.jhead { font-size: 15px; font-weight: 650; color: var(--fg-1); margin: var(--space-6) 0 var(--space-2); }
.fail-list { list-style: none; margin: 0; padding: 0; max-width: 480px; }
.fail-list li { display: flex; justify-content: space-between; gap: var(--space-4); padding: 8px 2px; border-bottom: 1px solid var(--n-100); font-size: 13.5px; }
.fail-list li:last-child { border-bottom: 0; }
.fail-list .fam { color: var(--fg-1); }
.fail-list .mono { color: var(--fg-2); }

/* ── Tooltip engine (ported from the lab) ─────────────────────────────── */
.prod-tip {
  position: absolute; z-index: 60; max-width: 300px;
  background: var(--fg-1); color: var(--n-0);
  font-family: var(--font-sans); font-size: 12.5px; font-weight: 400; line-height: 1.45;
  padding: 9px 11px; border-radius: 8px; box-shadow: 0 6px 20px rgba(0,0,0,.22);
  pointer-events: none; opacity: 0; transform: translateY(3px);
  transition: opacity .1s ease, transform .1s ease;
}
.prod-tip.show { opacity: 1; transform: translateY(0); }
