/* v3.css — V3 additions. Loaded only on pages that opt in via extra_css. */

.v3-secnav {
  position: sticky;
  top: var(--topbar-height, 68px);
  z-index: 20;
  background: var(--bgColor-default);
  border-bottom: 1px solid var(--borderColor-muted);
  margin: 0 0 var(--s-5);
}
.v3-secnav-list {
  display: flex;
  gap: var(--s-1);
  overflow-x: auto;
  padding: var(--s-2) 0;
  scrollbar-width: thin;
}
.v3-secnav a {
  flex: 0 0 auto;
  font-size: 13px;
  color: var(--fgColor-muted);
  text-decoration: none;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  white-space: nowrap;
}
.v3-secnav a:hover { background: var(--bgColor-neutral-muted); color: var(--fgColor-default); }
.v3-secnav a.on { background: var(--bgColor-accent-muted); color: var(--fgColor-accent); font-weight: 600; }

/* Section anchors sit under both the sticky topbar and the sticky pill nav, so
   clicking a link would otherwise land the heading right under them. Offset by
   the topbar height plus the pill nav's own row height. */
.report-section {
  scroll-margin-top: calc(var(--topbar-height, 68px) + 48px);
}

@media print {
  .v3-secnav, .v3-toolbar, .topbar, .mobile-drawer { display: none !important; }
}

.v3-toolbar { display: flex; gap: var(--s-2); flex-wrap: wrap; margin: 0 0 var(--s-5); }
.v3-toggle.on { background: var(--bgColor-accent-muted); color: var(--fgColor-accent); border-color: var(--fgColor-accent); }

.report-section.v3-folded > *:not(.report-section-head) { display: none; }
/* #snake-plot-container carries `display: flex` from an id selector in site.css,
   which outranks the attribute rule above, so the plot survived Compact view while
   its legend and controls were hidden: an approved figure rendered without its key.
   Match on the id here so the fold actually folds it. */
.report-section.v3-folded #snake-plot-container,
.report-section.v3-folded #snake-legend { display: none; }
.report-section.v3-folded { padding-bottom: var(--s-2); }
.report-section.v3-folded .report-section-head { margin-bottom: 0; cursor: pointer; }
.report-section.v3-folded .report-section-head::after {
  content: '▸'; margin-left: var(--s-2); color: var(--fgColor-muted); font-size: 12px;
}
