html {
  --site-header-height: 98px;
  scroll-padding-top: calc(var(--site-header-height) + 8px);
}

html:has(body > header:not(.site-header)) {
  --site-header-height: 109px;
}

.site-header,
body > header:not(.site-header) {
  position: sticky;
  top: 0;
  z-index: 30;
}

body > header:not(.site-header) {
  background: #fff9f0;
}

body > .skip {
  z-index: 50;
}

.article-toc {
  top: calc(var(--site-header-height) + 18px);
}

@media (min-width: 801px) {
  .article-toc {
    max-height: calc(100dvh - var(--site-header-height) - 36px);
    overflow-y: auto;
    overscroll-behavior: contain;
  }
}

@media (max-width: 800px) {
  html {
    --site-header-height: 80px;
  }
}

@media (max-width: 600px) {
  html:has(body > header:not(.site-header)) {
    --site-header-height: 145px;
  }
}

@media print {
  .site-header,
  body > header:not(.site-header) {
    position: static;
  }
}
