* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  font: inherit;
}

h1,
h2,
h3,
h4 {
  font-weight: 500;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

img {
  display: block;
  max-width: 100%;
}

.shell {
  width: min(calc(100% - 32px), var(--shell-width));
  margin-inline: auto;
}

.page-frame {
  background: var(--bg);
  border-inline: 1px solid var(--line);
}

main section {
  position: relative;
  border-top: 1px solid var(--line);
  scroll-margin-top: calc(var(--nav-height) + 8px);
}

main section:first-child {
  border-top: 0;
}

main section:not(:first-child)::before,
main section:not(:first-child)::after {
  content: "";
  position: absolute;
  top: -4px;
  z-index: 2;
  width: 7px;
  height: 7px;
  background:
    linear-gradient(var(--line-strong), var(--line-strong)) center / 7px 1px no-repeat,
    linear-gradient(var(--line-strong), var(--line-strong)) center / 1px 7px no-repeat;
}

main section:not(:first-child)::before {
  left: -4px;
}

main section:not(:first-child)::after {
  right: -4px;
}

.hatch-band {
  height: 36px;
  border-block: 1px solid var(--line);
  background-image: repeating-linear-gradient(45deg, var(--hatch) 0 1px, transparent 1px 7px);
}

.hand {
  font-family: var(--font-hand);
  font-weight: 500;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal].is-visible {
    animation: reveal-in 520ms ease both;
  }
}

@keyframes reveal-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

@media (max-width: 700px) {
  body {
    background-image: none;
  }

  .shell {
    width: 100%;
  }

  .page-frame {
    border-inline: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
  }
}
