/* conva — operator dashboard (/ops.html). Chart colors are roles resolved from
   the site tokens; dark (default) and light steps were validated separately
   (data-viz palette checks) — do not eyeball new ones. */
:root {
  --viz-you: #8468E0;
  --viz-them: #149968;
  --viz-ally: #BD8020;
  --viz-primary: #2A8CD4;
  --viz-warn: #C43D3D;
  --viz-muted: #556B7E;
  --viz-step-0: #16344D; --viz-step-1: #1D4867; --viz-step-2: #245D83; --viz-step-3: #2C73A0; --viz-step-4: #368ABC; --viz-step-5: #48A2D5; --viz-step-6: #6FBAE6;
  --viz-grid: rgba(255, 255, 255, 0.10);
}
:root[data-theme="light"] {
  --viz-you: #6A4FE0;
  --viz-them: #0A8A62;
  --viz-ally: #8A5800;
  --viz-primary: #0E6FB8;
  --viz-warn: #C43D3D;
  --viz-muted: #7B8B99;
  --viz-step-0: #DCEBF8; --viz-step-1: #B9D6F0; --viz-step-2: #8FBCE6; --viz-step-3: #5F9FD9; --viz-step-4: #3A82C6; --viz-step-5: #2264A6; --viz-step-6: #123F70;
  --viz-grid: rgba(18, 22, 43, 0.10);
}

.ops-main { max-width: 1120px; margin: 0 auto; padding: 24px 20px 64px; }
.ops-head { display: flex; flex-wrap: wrap; align-items: end; justify-content: space-between; gap: 12px; margin-bottom: 16px; }
.ops-head h1 { margin: 0; font-size: 1.5rem; }
.ops-head p { margin: 4px 0 0; color: var(--color-fg-muted); }
.ops-range { display: inline-flex; gap: 4px; padding: 3px; border: 1px solid var(--color-border); border-radius: 999px; background: var(--color-panel); }
.ops-range button { border: 0; background: transparent; color: var(--color-fg-muted); font: inherit; font-size: 0.85rem; padding: 6px 12px; border-radius: 999px; cursor: pointer; }
.ops-range button.is-active { background: var(--color-panel-raised); color: var(--color-fg); }
.ops-status { border: 1px solid var(--color-border); border-radius: 10px; padding: 10px 14px; margin: 0 0 16px; font-size: 0.9rem; color: var(--color-fg-muted); background: var(--color-panel); }
.ops-status--error { border-color: var(--viz-warn); }
.ops-status code { font-size: 0.85em; }
.ops-link { color: var(--color-primary); font-weight: 600; }
.ops-kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr)); gap: 12px; margin-bottom: 16px; }
.ops-tile { border: 1px solid var(--color-border); border-radius: 12px; padding: 14px 16px; background: var(--color-panel); }
.ops-tile-label { font-size: 0.78rem; color: var(--color-fg-muted); letter-spacing: 0.02em; text-transform: uppercase; }
.ops-tile-value { font-size: 2rem; font-weight: 700; line-height: 1.15; margin-top: 4px; font-variant-numeric: tabular-nums; }
.ops-tile-sub { font-size: 0.8rem; color: var(--color-fg-faint); margin-top: 4px; }
.ops-grid2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr)); gap: 12px; margin-bottom: 12px; }
.ops-card { border: 1px solid var(--color-border); border-radius: 12px; padding: 16px; background: var(--color-panel); margin-bottom: 12px; }
.ops-card h2 { margin: 0 0 10px; font-size: 1rem; }
.ops-card h3 { margin: 14px 0 6px; font-size: 0.8rem; color: var(--color-fg-muted); text-transform: uppercase; letter-spacing: 0.02em; }
.ops-note { font-size: 0.8rem; color: var(--color-fg-faint); margin: 0 0 10px; }
.ops-muted { color: var(--color-fg-faint); font-size: 0.8rem; font-weight: 400; }
.ops-empty { color: var(--color-fg-faint); font-size: 0.85rem; margin: 4px 0; }
.ops-chart { width: 100%; height: auto; display: block; overflow: visible; }
.ops-grid { stroke: var(--viz-grid); stroke-width: 1; }
.ops-grid--faint { stroke-dasharray: 2 4; }
.ops-hit { fill: transparent; }
.ops-chart g:hover .ops-hit, .ops-chart g:focus .ops-hit { fill: var(--viz-grid); }
.ops-chart g:focus { outline: none; }
.ops-bar { transition: opacity 120ms; }
.ops-chart g:hover .ops-bar { opacity: 0.85; }
.ops-axis { font-size: 11px; fill: var(--color-fg-faint); }
.ops-value { font-size: 11px; fill: var(--color-fg-muted); font-variant-numeric: tabular-nums; }
.ops-series--you { fill: var(--viz-you); background: var(--viz-you); }
.ops-series--them { fill: var(--viz-them); background: var(--viz-them); }
.ops-series--ally { fill: var(--viz-ally); background: var(--viz-ally); }
.ops-series--primary { fill: var(--viz-primary); background: var(--viz-primary); }
.ops-series--warn { fill: var(--viz-warn); background: var(--viz-warn); }
.ops-series--muted { fill: var(--viz-muted); background: var(--viz-muted); }
.ops-step--0 { fill: var(--viz-step-0); background: var(--viz-step-0); }
.ops-step--1 { fill: var(--viz-step-1); background: var(--viz-step-1); }
.ops-step--2 { fill: var(--viz-step-2); background: var(--viz-step-2); }
.ops-step--3 { fill: var(--viz-step-3); background: var(--viz-step-3); }
.ops-step--4 { fill: var(--viz-step-4); background: var(--viz-step-4); }
.ops-step--5 { fill: var(--viz-step-5); background: var(--viz-step-5); }
.ops-step--6 { fill: var(--viz-step-6); background: var(--viz-step-6); }
.ops-share { width: 100%; height: 18px; display: block; }
.ops-share rect:hover, .ops-share rect:focus { opacity: 0.85; outline: none; }
.ops-row { margin: 8px 0; }
.ops-row--sub { margin-top: 2px; margin-bottom: 14px; }
.ops-row-head { display: flex; align-items: center; gap: 8px; font-size: 0.85rem; margin-bottom: 4px; }
.ops-dot { display: inline-block; width: 10px; height: 10px; border-radius: 50%; }
.ops-legend { display: flex; flex-wrap: wrap; gap: 10px 14px; font-size: 0.78rem; color: var(--color-fg-muted); margin-top: 8px; }
.ops-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin-right: 5px; vertical-align: -1px; }
.ops-entries { list-style: none; margin: 0; padding: 0; display: grid; gap: 4px; }
.ops-entries li { display: grid; grid-template-columns: minmax(80px, 160px) 1fr 56px; align-items: center; gap: 8px; font-size: 0.85rem; }
.ops-entry-key { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ops-entry-bar { height: 8px; background: var(--viz-grid); border-radius: 4px; overflow: hidden; }
.ops-entry-bar i { display: block; height: 100%; border-radius: 4px; }
.ops-entry-val { text-align: right; font-variant-numeric: tabular-nums; color: var(--color-fg-muted); }
.ops-table-wrap summary { cursor: pointer; font-weight: 600; }
.ops-scroll { overflow-x: auto; margin-top: 10px; }
.ops-table { border-collapse: collapse; width: 100%; font-size: 0.82rem; font-variant-numeric: tabular-nums; }
.ops-table th, .ops-table td { text-align: right; padding: 6px 8px; border-bottom: 1px solid var(--color-border); white-space: nowrap; }
.ops-table th:first-child, .ops-table td:first-child { text-align: left; }
.ops-tooltip { position: absolute; z-index: 20; pointer-events: none; background: var(--color-panel-raised); color: var(--color-fg); border: 1px solid var(--color-border-strong); border-radius: 8px; padding: 6px 10px; font-size: 0.8rem; line-height: 1.4; box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25); max-width: 260px; }

/* ── readiness (cp17) ─────────────────────────────────────────────────────── */
.ops-readiness-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 16px; }
.ops-readiness-builds { margin: 0 0 10px; font-size: 0.82rem; color: var(--color-fg-muted); }
.ops-readiness-builds code { font-size: 0.9em; }
.ops-readiness-ok { color: var(--viz-them); }
.ops-readiness-missing { color: var(--viz-warn); }
.ops-readiness-error { color: var(--viz-muted); }
.ops-checks { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 6px 18px; }
.ops-check { display: flex; align-items: baseline; gap: 8px; font-size: 0.88rem; line-height: 1.35; min-width: 0; }
.ops-check-text { min-width: 0; overflow-wrap: anywhere; }
.ops-dot { width: 9px; height: 9px; border-radius: 50%; flex: none; position: relative; top: 1px; background: var(--viz-muted); }
.ops-check--ok .ops-dot { background: var(--viz-them); }
.ops-check--warn .ops-dot { background: var(--viz-ally); }
.ops-check--missing .ops-dot { background: var(--viz-warn); }
.ops-check--error .ops-dot { background: transparent; box-shadow: inset 0 0 0 2px var(--viz-warn); }
.ops-check-detail { color: var(--color-fg-muted); }

/* ── beta applications (cp18) ─────────────────────────────────────────────── */
.ops-app-table td, .ops-app-table th { vertical-align: top; text-align: left; white-space: normal; }
.ops-app-email { font-family: var(--font-mono, ui-monospace, monospace); font-size: 0.85rem; white-space: nowrap; }
.ops-app-count { color: var(--viz-ally); font-weight: 600; }
.ops-app-sub { color: var(--color-fg-muted); font-weight: 400; font-size: 0.8em; }
.ops-app-use { max-width: 32ch; color: var(--color-fg-muted); }
.ops-copy { font: inherit; font-size: 0.8rem; padding: 3px 8px; border-radius: 6px; border: 1px solid var(--color-border, currentColor); background: transparent; color: inherit; cursor: pointer; white-space: nowrap; }
.ops-copy:hover { background: var(--color-bg-raised, rgba(127, 127, 127, 0.12)); }
