/* t_learner_stats_html, root .ts-wrap. The root rule stays bare; every other
   rule is scoped :where(.ts-wrap), which adds no specificity. The chart svg
   sits in a span.ts-chart (the designer cannot class an svg); the span holds
   the box and the svg fills it. */
.ts-wrap {
  font-family: var(--ch-font-primary);
  color: var(--ch-text-primary);
}
:where(.ts-wrap) .ts-summary {
  display: flex;
  gap: 24px;
  flex-wrap: wrap;
  margin-bottom: 12px;
  font-size: 13px;
  color: var(--ch-text-secondary);
}
:where(.ts-wrap) .ts-summary-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
:where(.ts-wrap) .ts-summary-value {
  font-size: 18px;
  font-weight: 700;
  color: var(--ch-text-primary);
}
:where(.ts-wrap) .ts-summary-label {
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.4px;
  color: var(--ch-text-muted);
}
:where(.ts-wrap) .ts-chart {
  width: 100%;
  height: 200px;
  display: block;
  line-height: 0;
}
:where(.ts-wrap) .ts-chart > svg {
  display: block;
  width: 100%;
  height: 100%;
}
:where(.ts-wrap) .ts-empty {
  display: none;
  padding: 16px;
  color: var(--ch-text-muted);
  font-size: 13px;
  text-align: center;
}
:where(.ts-wrap) .ts-empty.ts-visible {
  display: block;
}
:where(.ts-wrap) .ts-chart-wrap.ts-hidden {
  display: none;
}
:where(.ts-wrap) .ts-legend {
  display: flex;
  gap: 16px;
  font-size: 12px;
  color: var(--ch-text-secondary);
  margin-top: 8px;
  flex-wrap: wrap;
}
:where(.ts-wrap) .ts-legend-item {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
:where(.ts-wrap) .ts-legend-swatch {
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
}
:where(.ts-wrap) .ts-legend-swatch.ts-rate {
  background: var(--ch-accent-primary);
}
:where(.ts-wrap) .ts-legend-swatch.ts-cumulative {
  background: var(--ch-success);
}
