/* Trust but Verify widget. Theme colors only; ruled rows, no cards. */

.w-demo { margin: 10px 0 8px; padding: 4px 0 8px; border-bottom: 1px solid var(--light-gray); }
.w-demo:not(.w-ready)::before { content: "This demo needs JavaScript."; color: var(--gray); font-size: 0.9rem; }

.w-note { margin: 8px 0; font-size: 0.88rem; color: var(--dark-gray); max-width: 72ch; }
.w-mono { font-family: var(--code); font-size: 0.78rem; color: var(--gray); }
.w-source { font-family: var(--code); font-size: 0.75rem; color: var(--gray); margin: 4px 0 8px; }
.w-big { margin: 8px 0; font-family: var(--heading); font-size: 1.05rem; }
.w-big strong { color: var(--accent); }

/* buttons */
.w-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 10px; margin: 10px 0; }
.w-btn {
  appearance: none; min-height: 38px; padding: 7px 14px; border: 1px solid var(--primary);
  background: var(--primary); color: var(--background); font: inherit; font-family: var(--heading);
  font-size: 0.88rem; font-weight: var(--semi-bold); cursor: pointer; border-radius: 0;
}
.w-btn:hover { background: transparent; color: var(--primary); }
.w-btn-quiet { background: transparent; color: var(--primary); }
.w-btn-quiet:hover { background: var(--primary); color: var(--background); }
.w-btn:focus-visible, .seg-option:focus-visible, .tv-pick:focus-visible, .tv-select:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* segmented options */
.seg { display: inline-flex; flex-wrap: wrap; border: 1px solid var(--light-gray); }
.seg-option {
  appearance: none; padding: 6px 10px; border: 0; border-right: 1px solid var(--light-gray);
  background: transparent; color: var(--text); font: inherit; font-family: var(--code); font-size: 0.78rem;
  cursor: pointer; border-radius: 0; min-height: 34px;
}
.seg-option:last-child { border-right: 0; }
.seg-option[aria-checked="true"] { background: var(--light-gray); color: var(--accent); }

/* demo 1 picks */
.tv-picks { display: flex; flex-wrap: wrap; gap: 6px 8px; margin: 8px 0; }
.tv-pick {
  appearance: none; padding: 5px 10px; min-height: 34px; border: 1px solid var(--light-gray); background: transparent;
  color: var(--primary); font-family: var(--code); font-size: 0.76rem; cursor: pointer; border-radius: 0;
}
.tv-pick[aria-pressed="true"] { background: var(--light-gray); color: var(--accent); border-color: var(--accent); }

.tv-select {
  appearance: auto; min-height: 38px; max-width: 100%; padding: 6px 8px; border: 1px solid var(--light-gray);
  background: var(--background); color: var(--text); font-family: var(--code); font-size: 0.8rem; border-radius: 0;
}

/* charts */
.tv-chart { margin: 6px 0; }
.tv-svg { display: block; width: 100%; max-width: 760px; height: auto; overflow: visible; }
.c-grid { stroke: var(--light-gray); stroke-width: 1; }
.c-tick { fill: var(--gray); font-family: var(--code); font-size: 11px; }
.c-label { fill: var(--dark-gray); font-family: var(--code); font-size: 11px; }
.tv-val { fill: var(--text); font-family: var(--code); font-size: 11px; }
.tv-mine { fill: var(--accent); }
.tv-track { fill: var(--light-gray); opacity: 0.45; }
.tv-bar { fill: var(--primary); }
.tv-bar-mine { fill: var(--accent); }
.tv-seg-yes { fill: var(--accent); stroke: var(--background); stroke-width: 1; }
.tv-seg-no { fill: var(--gray); stroke: var(--background); stroke-width: 1; }
.tv-cutline { stroke: var(--text); stroke-width: 2; }
.tv-mark { stroke: var(--text); stroke-width: 1.5; stroke-dasharray: 2 3; }

.c-legend { display: flex; flex-wrap: wrap; gap: 4px 14px; margin: 6px 0 0; }
.tv-lg { display: inline-flex; align-items: center; gap: 6px; }
.tv-sw { display: inline-block; width: 12px; height: 10px; }
.tv-sw-yes { background: var(--accent); }
.tv-sw-no { background: var(--gray); }
.tv-sw-mark { display: inline-block; width: 0; height: 12px; border-left: 2px dotted var(--text); }

.tv-readout p { max-width: 72ch; }
.tv-match { color: var(--accent); font-family: var(--code); font-size: 0.8rem; }

/* demo 5 */
.tv-table-wrap { overflow-x: auto; }
.paper-body .results-table, .tv-table { width: 100%; min-width: 560px; border-collapse: collapse; margin: 10px 0; overflow-wrap: normal; }
.paper-body .results-table th, .paper-body .results-table td, .tv-table th, .tv-table td { padding: 6px 8px; border-bottom: 1px solid var(--light-gray); text-align: left; vertical-align: top; font-size: 0.86rem; }
.paper-body .results-table th, .tv-table th { font-family: var(--code); font-size: 0.74rem; color: var(--gray); font-weight: 500; }
.tv-table td:not(:first-child) { font-family: var(--code); font-size: 0.8rem; }
.tv-diff { color: var(--accent); }

.tv-study-wrap { overflow-x: auto; }
.paper-body li { text-align: left; }
