/* The Visualizations page (src/visualize/viz-twin.js). Cards, tables, pills, tabs, pager and the pop-up are the shared
   .wqx-* classes in wq-twin.css; only what this page adds is here. Colour comes from tokens only; no gradients, no blur,
   no coloured edge stripes, no keyframes (styles/motion.css owns those). */

.vz { display: grid; gap: 18px; }
.vz-trust { margin: 0 0 10px; font-size: var(--guide-fs-sm); line-height: 1.5; color: var(--guide-color-ink-soft); max-width: 62em; }
.vz-lede { margin: 0 0 8px; font-size: var(--guide-fs-md); line-height: 1.5; font-weight: 600; }
.vz-steps { margin: 10px 0; padding-left: 22px; display: grid; gap: 8px; font-size: var(--guide-fs-md); line-height: 1.5; max-width: 62em; }
.vz-facts { margin: 8px 0 0; padding-left: 20px; display: grid; gap: 8px; font-size: var(--guide-fs-sm); line-height: 1.5; max-width: 62em; }

/* the statements you can paste */
.vz-stmts { list-style: none; margin: 0 0 12px; padding: 0; display: grid; gap: 12px; max-width: 52em; }
.vz-stmt p { margin: 0 0 2px; font-size: clamp(16px, 2.6vw, 20px); line-height: 1.45; }
.vz-stmt small { display: block; color: var(--guide-color-ink-muted); font-size: var(--guide-fs-xs); line-height: 1.4; }
.vz-stamp { margin-top: 10px; }

/* how far back: one row of thin bars per record set */
.vz-cov-list { list-style: none; margin: 0; padding: 0; display: grid; gap: 6px; }
.vz-cov-row, .vz-axis { display: grid; grid-template-columns: minmax(150px, 1.1fr) minmax(220px, 2fr) minmax(150px, 1.1fr); gap: 4px 14px; align-items: center; }
.vz-cov-row { padding: 8px 0; border-top: 1px solid var(--guide-color-border-default); }
.vz-cov-name b { display: block; font-size: var(--guide-fs-sm); }
.vz-cov-name span, .vz-cov-nd span { color: var(--guide-color-ink-soft); font-size: var(--guide-fs-xs); line-height: 1.4; }
.vz-cov-nd { display: grid; gap: 4px; justify-items: start; }
.vz-nd-hi { color: var(--guide-color-ink); font-weight: 600; }
.vz-cov-none { color: var(--guide-color-ink-muted); font-size: var(--guide-fs-xs); }
.vz-axis { padding-bottom: 2px; }
.vz-axis-in { display: grid; grid-template-columns: repeat(15, 1fr); font-size: var(--guide-fs-xs); color: var(--guide-color-ink-muted); }
.vz-axis-in span { white-space: nowrap; }
.vz-ax3 { grid-column: 3; } .vz-ax8 { grid-column: 8; } .vz-ax13 { grid-column: 13; } .vz-ax15 { grid-column: 15; justify-self: end; }
.vz-cov-svg { width: 100%; height: 30px; display: block; }
.vz-bar { fill: var(--guide-color-lake); }
.vz-base { stroke: var(--guide-color-border-strong); stroke-width: 1; }
.vz-hit { fill: transparent; }
.vz-hit:hover { fill: color-mix(in srgb, var(--guide-color-lake) 10%, transparent); }
.vz-flag { display: inline-block; font-size: var(--guide-fs-xs); line-height: 1.3; padding: 2px 8px; border-radius: 999px; border: 1px solid var(--guide-color-border-strong); color: var(--guide-color-ink); background: var(--guide-color-bg-2); }

/* the animation cards */
.vz-setgrid { display: grid; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); gap: 14px; }
.vz-set { display: grid; gap: 8px; align-content: start; padding: 12px; border: 1px solid var(--guide-color-border-default); border-radius: 12px; background: var(--guide-color-paper); scroll-margin-top: 80px; }
.vz-set.is-on { border-color: var(--guide-color-ink); border-width: 2px; padding: 11px; }
.vz-set .viz-launch-card { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr) auto; align-items: center; column-gap: 12px; margin: 0; padding: 10px 12px; border-radius: 10px; background: var(--guide-color-bg-1); border: 1px solid var(--guide-color-border-strong); box-shadow: none; cursor: pointer; transform: none; }
.vz-set .viz-launch-card:hover { border-color: var(--guide-color-ink); transform: none; box-shadow: none; }
.vz-set .viz-launch-card:focus-visible { outline: 2px solid var(--guide-color-signal); outline-offset: 2px; }
.vz-set .viz-launch-preview { position: static; display: grid; place-items: center; width: 32px; height: 32px; min-height: 0; background: none; }
.vz-set .viz-launch-icon { width: 22px; height: 22px; color: var(--guide-color-lake); filter: none; }
.vz-set .viz-launch-body { padding: 0; }
.vz-set .viz-launch-body h3 { margin: 0 0 2px; font-size: var(--guide-fs-md); font-weight: 700; color: var(--guide-color-ink); }
.vz-set .viz-launch-body p { margin: 0; font-size: var(--guide-fs-sm); line-height: 1.4; color: var(--guide-color-ink-soft); }
.vz-set .viz-launch-arrow { position: static; display: grid; place-items: center; width: 32px; height: 32px; padding: 0; border-radius: 999px; border: 1px solid var(--guide-color-border-strong); color: var(--guide-color-ink); background: none; filter: none; }
.vz-set .viz-launch-arrow svg, .vz-set .viz-launch-arrow i { width: 14px; height: 14px; }
.vz-own { margin: 0; font-size: var(--guide-fs-sm); line-height: 1.45; }
.vz-read { color: var(--guide-color-ink-muted); font-size: var(--guide-fs-xs); }
.vz-spark .vz-cov-svg { height: 26px; }
.vz-means { margin: 0; display: grid; gap: 2px; font-size: var(--guide-fs-sm); line-height: 1.45; }
.vz-means dt { font-size: var(--guide-fs-xs); font-weight: 700; color: var(--guide-color-ink-soft); margin-top: 6px; }
.vz-means dd { margin: 0; }
.vz-flags { margin: 0; display: flex; flex-wrap: wrap; gap: 6px; }
.vz-flags:empty { display: none; }
.vz-pill { white-space: normal; }

/* snowpack: two lines on one axis, the second dashed so colour is not the only difference */
.vz-key { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 14px; margin: 8px 0; font-size: var(--guide-fs-sm); }
.vz-sw { display: inline-block; width: 26px; height: 0; border-top: 2px solid var(--guide-color-lake); vertical-align: middle; margin-right: 6px; }
.vz-sw-all { border-top: 2px dashed var(--guide-color-ochre); }
.vz-snow { width: 100%; max-width: 480px; height: auto; display: block; }
.vz-grid { stroke: var(--guide-color-border-default); stroke-width: 1; }
.vz-tick { fill: var(--guide-color-ink-muted); font-size: 12px; }
.vz-line { fill: none; stroke-width: 2; stroke-linejoin: round; stroke-linecap: round; }
.vz-line-fixed { stroke: var(--guide-color-lake); }
.vz-line-all { stroke: var(--guide-color-ochre); stroke-dasharray: 5 3; }
.vz-end-fixed { fill: var(--guide-color-lake); stroke: var(--guide-color-paper); stroke-width: 2; }
.vz-rostercap { margin: 10px 0 2px; }
.vz-rostersvg { width: 100%; max-width: 480px; height: 44px; display: block; }
.vz-roster { fill: var(--guide-color-ink-muted); }

@media (max-width: 720px) {
  .vz-cov-row { grid-template-columns: 1fr; gap: 4px; }
  .vz-axis { grid-template-columns: 1fr; }
  .vz-axis > span { display: none; }
  .vz-setgrid { grid-template-columns: 1fr; }
}

/* the printed page: the finder, role tabs and buttons are left off; every card is kept whole */
@media print {
  .vz-finder, #vz-roles, .vz .wqx-actions, .vz .wqx-tabs { display: none !important; }
  .vz { gap: 10px; }
  .vz-set, .vz-stmt, .vz-cov-row { break-inside: avoid; }
  .vz-setgrid { grid-template-columns: 1fr 1fr; }
}

/* the older tools, kept in a closed fold under the page */
.vz-tools { margin: 24px 0 0; }
.vz-tools > summary { cursor: pointer; padding: 12px 16px; border: 1px solid var(--guide-color-border-strong); border-radius: 12px; background: var(--guide-color-paper); font-size: var(--guide-fs-md); font-weight: 600; }
.vz-tools[open] > summary { margin-bottom: 14px; }
