.site-body {
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  padding-top: env(safe-area-inset-top);
  padding-right: env(safe-area-inset-right);
  padding-bottom: env(safe-area-inset-bottom);
  padding-left: env(safe-area-inset-left);
}

.site-main {
  flex: 1;
  min-width: 0;
}

.site-main:focus {
  outline: none;
}

.site-skip-link {
  position: absolute;
  top: var(--st-space-2);
  left: var(--st-space-4);
  z-index: var(--st-z-overlay);
  padding: var(--st-space-3) var(--st-space-4);
  background: var(--st-surface);
  transform: translateY(-200%);
}

.site-skip-link:focus {
  transform: translateY(0);
}

.site-nav-link {
  display: inline-flex;
  align-items: center;
  min-height: var(--st-touch-target);
  padding-block: var(--st-space-2);
}

.site-nav-link[aria-current="page"] {
  text-decoration: underline;
  text-underline-offset: var(--st-space-1);
}

.site-brand {
  font-weight: var(--st-fw-semibold);
}

.site-intro {
  padding-block: var(--st-space-6);
}

.site-title {
  margin: 0;
  font-size: var(--st-fs-2xl);
  font-weight: var(--st-fw-semibold);
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.site-lead {
  margin: 0;
  color: var(--st-text-secondary);
  font-size: var(--st-fs-lg);
  line-height: 1.6;
}

.site-copy {
  margin: 0;
  overflow-wrap: anywhere;
}

.site-section-title,
.site-card-title {
  margin: 0;
  font-size: var(--st-fs-base);
  font-weight: var(--st-fw-semibold);
  overflow-wrap: anywhere;
}

.site-article-list,
.site-tags,
.site-contact-list {
  padding: 0;
  margin: 0;
  list-style: none;
}

.site-article-list {
  --st-gap: var(--st-space-4);
}

.site-article-list > li {
  min-width: 0;
}

.site-tags {
  overflow-wrap: anywhere;
}

.site-meta {
  color: var(--st-text-muted);
  font-size: var(--st-fs-xs);
  font-variant-numeric: tabular-nums;
}

.site-contact-link {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--st-space-2) var(--st-space-4);
  min-height: var(--st-touch-target);
  overflow-wrap: anywhere;
}

.site-contact-link > :last-child {
  font-weight: var(--st-fw-regular);
}

.site-footer,
.site-article-footer {
  border-top: 1px solid var(--st-divider);
  padding-top: var(--st-space-4);
}

.site-article {
  --st-gap: var(--st-space-6);
}

.site-search-help {
  margin: var(--st-space-2) 0 0;
  color: var(--st-text-muted);
  font-size: var(--st-fs-xs);
}

#search-status:empty {
  display: none;
}

.site-prose {
  min-width: 0;
  color: var(--st-text-secondary);
  font-size: var(--st-fs-base);
  line-height: 1.8;
  overflow-wrap: anywhere;
}

.site-prose > :first-child {
  margin-top: 0;
}

.site-prose > :last-child {
  margin-bottom: 0;
}

.site-prose :is(h1, h2, h3, h4, h5, h6) {
  margin-block: var(--st-space-8) var(--st-space-3);
  color: var(--st-text);
  font-weight: var(--st-fw-semibold);
  line-height: 1.4;
  scroll-margin-top: var(--st-space-6);
}

.site-prose :is(h1, h2) {
  font-size: var(--st-fs-xl);
}

.site-prose :is(h3, h4, h5, h6) {
  font-size: var(--st-fs-lg);
}

.site-prose :is(p, ul, ol, dl, figure, blockquote, pre, table) {
  margin-block: var(--st-space-4);
}

.site-prose :is(ul, ol) {
  padding-left: var(--st-space-6);
}

.site-prose li + li {
  margin-top: var(--st-space-2);
}

.site-prose a {
  color: var(--st-accent);
  text-decoration: underline;
  text-underline-offset: var(--st-space-1);
}

.site-prose a:focus-visible {
  outline: 2px solid var(--st-focus);
  outline-offset: var(--st-space-1);
  border-radius: var(--st-radius-xs);
}

.site-prose :is(img, video) {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: var(--st-radius-md);
}

.site-prose figure {
  margin-inline: 0;
}

.site-prose figcaption {
  margin-top: var(--st-space-2);
  color: var(--st-text-muted);
  font-size: var(--st-fs-xs);
}

.site-prose blockquote {
  margin-inline: 0;
  padding: var(--st-space-2) var(--st-space-4);
  border-left: var(--st-space-1) solid var(--st-border-strong);
  background: var(--st-surface-muted);
}

.site-prose code {
  padding: var(--st-space-1);
  font-family: var(--st-font-mono);
  font-size: var(--st-fs-sm);
  background: var(--st-surface-muted);
  border-radius: var(--st-radius-xs);
}

.site-prose pre {
  max-width: 100%;
  padding: var(--st-space-4);
  overflow: auto;
  background: var(--st-surface-muted);
  border: 1px solid var(--st-border);
  border-radius: var(--st-radius-md);
}

.site-prose pre code {
  padding: 0;
  overflow-wrap: normal;
}

.site-prose table {
  display: block;
  max-width: 100%;
  overflow-x: auto;
  border-collapse: collapse;
  font-size: var(--st-fs-sm);
}

.site-prose :is(th, td) {
  padding: var(--st-space-2) var(--st-space-3);
  border: 1px solid var(--st-border);
  text-align: left;
}

.site-prose th {
  color: var(--st-text);
  background: var(--st-surface-muted);
}

.site-prose hr {
  margin-block: var(--st-space-8);
  border: 0;
  border-top: 1px solid var(--st-divider);
}

.site-search-excerpt mark {
  color: var(--st-text);
  background: var(--st-info-bg);
  font-weight: var(--st-fw-semibold);
}

@media (max-width: 767px) {
  .site-body {
    --st-page-padding: var(--st-space-4);
  }

  .site-intro {
    padding-block: var(--st-space-3);
  }
}
