
/* Shared content width: match the Gallery's 1510px outer container with 28px gutters.
   The inner usable width is 1454px. All Home sections use the same limit. */
html[data-page="home"] .wrap,
html[data-page="home"] header.site-header .wrap,
html[data-page="gallery"] header.site-header .wrap,
html[data-page="home"] .site-footer .wrap,
html[data-page="gallery"] .site-footer .wrap {
  width:min(1454px, calc(100% - 56px));
  margin-inline:auto;
}
@media (max-width:740px) {
  html[data-page="home"] .wrap,
  html[data-page="home"] header.site-header .wrap,
  html[data-page="gallery"] header.site-header .wrap,
  html[data-page="home"] .site-footer .wrap,
  html[data-page="gallery"] .site-footer .wrap {
    width:calc(100% - 32px);
  }
}

/* Gallery sidebar must stay below the sticky global navigation.  A shared
   script measures the actual header height to cover responsive nav wrapping. */
html[data-page="gallery"] main.container .case-list {
  position:sticky;
  top:calc(var(--showcase-nav-height, 84px) + 16px);
  max-height:calc(100vh - var(--showcase-nav-height, 84px) - 32px);
  max-height:calc(100dvh - var(--showcase-nav-height, 84px) - 32px);
  scroll-margin-top:calc(var(--showcase-nav-height, 84px) + 16px);
}
@media (max-width:740px) {
  html[data-page="gallery"] main.container .case-list {
    position:static;
    top:auto;
    max-height:none;
  }
}

/* Distinct dark-violet label on the light theme: better than the prior pastel. */
html[data-theme="light"][data-page="gallery"] .counter.stat-groups .counter-value small[data-i18n="gStatGroupsSuffix"] {
  color:#4b2d76;
}
