@font-face {
  font-family: "Redaction";
  src: url("lib/Redaction-Regular.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Redaction";
  src: url("lib/Redaction-Italic.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "Redaction";
  src: url("lib/Redaction-Bold.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}

html,
body {
  position: relative;
  height: 100%;
  margin: 0;
  padding: 0;
  font-family: "Redaction", serif;
  color: #111;
  background: #fff;
}

a,
a:visited {
  color: inherit;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* Home / stub pages: vertically centered. */
main.center {
  position: relative;
  top: 40%;
  transform: translateY(-50%);
  text-align: center;
}
main.center h1 {
  margin: 0;
  display: inline;
}

/* Long-form pages. */
.prose {
  max-width: 42rem;
  margin: 0 auto;
  padding: 2.5rem 1.25rem 4rem;
  line-height: 1.6;
  font-size: 1.125rem;
}

.masthead {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1rem;
  justify-content: space-between;
  align-items: baseline;
  margin-bottom: 2.5rem;
  font-size: 1rem;
}
.masthead .site {
  font-weight: 700;
}
.masthead nav {
  color: #666;
}

.prose h1 {
  font-weight: 700;
  font-size: 2rem;
  line-height: 1.15;
  margin: 0 0 1.75rem;
}
.prose h2 {
  font-weight: 700;
  font-size: 1.5rem;
  margin: 2.5rem 0 0.75rem;
}
.prose h3 {
  font-weight: 700;
  font-size: 1.2rem;
  margin: 2rem 0 0.5rem;
}
.prose h4 {
  font-weight: 700;
  font-size: 1.05rem;
  margin: 1.5rem 0 0.5rem;
}

.prose p {
  margin: 0 0 1.1rem;
}
.prose a {
  text-decoration: underline;
  text-decoration-color: #bbb;
  text-underline-offset: 2px;
}
.prose a:hover {
  text-decoration-color: currentColor;
}

.prose ul,
.prose ol {
  padding-left: 1.4rem;
  margin: 0 0 1.1rem;
}
.prose li {
  margin: 0.25rem 0;
}

.prose blockquote {
  margin: 0 0 1.1rem;
  padding-left: 1rem;
  border-left: 2px solid #ddd;
  color: #555;
  font-style: italic;
}

.prose pre,
.prose code {
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.9em;
}
.prose code {
  background: #f4f4f4;
  padding: 0.1em 0.3em;
  border-radius: 3px;
}
.prose pre {
  background: #f4f4f4;
  padding: 0.75rem 1rem;
  border-radius: 4px;
  overflow-x: auto;
  line-height: 1.4;
}
.prose pre code {
  background: none;
  padding: 0;
}

.prose hr {
  border: none;
  border-top: 1px solid #ddd;
  margin: 2.5rem 0;
}

/* Figures and media. */
.prose figure {
  margin: 1.75rem 0;
  text-align: center;
}
.prose figure img {
  max-width: 100%;
  height: auto;
}
.prose p img {
  max-width: 100%;
  height: auto;
}
.prose figcaption {
  margin-top: 0.5rem;
  font-size: 0.9rem;
  color: #666;
}
.prose figure.video {
  margin: 1.75rem 0;
}
.prose figure.video iframe {
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
}

/* Native MathML: let wide display equations scroll instead of overflowing. */
.prose math[display="block"] {
  display: block;
  overflow-x: auto;
  overflow-y: hidden;
  max-width: 100%;
  margin: 1.25rem 0;
}

/* Footnotes. */
.prose .footnotes {
  margin-top: 3rem;
  font-size: 0.95rem;
  color: #444;
}
.prose .footnote-ref {
  text-decoration: none;
}
.prose .footnote-back {
  text-decoration: none;
}

/* Post index. */
.post-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.post-list li {
  margin: 0 0 1.5rem;
}
.post-list a {
  font-size: 1.25rem;
  font-weight: 700;
  text-decoration: none;
}
.post-list a:hover {
  text-decoration: underline;
}
.post-list p {
  margin: 0.25rem 0 0;
  color: #555;
}
