@font-face {
  font-family: "Source Serif 4";
  src: url("/https/alterae.github.io/fonts/SourceSerif4-Regular.otf") format("opentype");
  font-display: swap;
}

@font-face {
  font-family: "Source Serif 4";
  src: url("/https/alterae.github.io/fonts/SourceSerif4-Bold.otf") format("opentype");
  font-weight: bold;
  font-display: swap;
}

@font-face {
  font-family: "Source Serif 4";
  src: url("/https/alterae.github.io/fonts/SourceSerif4-It.otf") format("opentype");
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "Source Serif 4";
  src: url("/https/alterae.github.io/fonts/SourceSerif4-BoldIt.otf") format("opentype");
  font-weight: bold;
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Serif";
  src: url("/https/alterae.github.io/fonts/IBMPlexSerif-Regular.otf") format("opentype");
  font-weight: normal;
  font-display: swap;
}

@font-face {
  font-family: "IBM Plex Serif";
  src: url("/https/alterae.github.io/fonts/IBMPlexSerif-Bold.otf") format("opentype");
  font-weight: bold;
  font-display: swap;
}

@font-face {
  font-family: "Input Mono Narrow";
  src: url("/https/alterae.github.io/fonts/InputMonoNarrow-Regular.ttf") format("truetype");
  font-display: swap;
}

@font-face {
  font-family: "Input Mono Narrow";
  src: url("/https/alterae.github.io/fonts/InputMonoNarrow-Bold.ttf") format("truetype");
  font-weight: bold;
  font-display: swap;
}

@font-face {
  font-family: "Input Mono Narrow";
  src: url("/https/alterae.github.io/fonts/InputMonoNarrow-Italic.ttf") format("truetype");
  font-style: italic;
  font-display: swap;
}

@font-face {
  font-family: "Input Mono Narrow";
  src: url("/https/alterae.github.io/fonts/InputMonoNarrow-BoldItalic.ttf") format("truetype");
  font-weight: bold;
  font-style: italic;
  font-display: swap;
}

:root {
  --bg: #fff;
  --fg: #111;

  font-family: "Source Serif 4", serif;
  line-height: 1.5;
  /* text-justify: inter-word; */

  background-color: var(--bg);
  color: var(--fg);
}

@media screen and (prefers-color-scheme: dark) {
  :root {
    --bg: #111;
    --fg: #eee;
  }
}

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

main {
  max-width: 80ch;
  margin: auto;
}

@media (max-width: calc(80ch + 3rem)) {
  main {
    margin-left: 1.5rem;
    margin-right: 1.5rem;
  }
}

body > header {
  display: flex;
  padding: 1.5rem;
  justify-content: space-between;
}

nav ul {
  list-style: none;
  display: flex;
  gap: 1rem;
}

header > h1 > a {
  text-decoration: none;
}

h1 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
}

h2 {
  font-size: 1.25rem;
  margin-top: 0.8rem;
  margin-bottom: 0.4rem;
}

h3 {
  font-size: 1rem;
  margin-top: 0.6rem;
  margin-bottom: 0.3rem;
}

h1,
h2,
h3 {
  font-family: "IBM Plex Serif", serif;
  font-weight: bold;
}

body > header h1 {
  font-size: 1rem;
  margin: 0;
  font-weight: normal;
}

body > header h1 > a:first-child {
  font-weight: bold;
}

pre,
code {
  font-family: "Input Mono Narrow", monospace;
  font-size: 0.95em;
}

p,
aside {
  margin-bottom: 0.5rem;
  /* text-align: justify; */
  hyphens: auto;
}

a {
  color: var(--fg);
}

abbr {
  letter-spacing: 0.04rem;
  text-decoration: none;
}

address {
  font-style: unset;
}

dt {
  font-style: italic;
}

dt::after {
  content: ":";
}

dd {
  margin-left: 2rem;
}

aside {
  border-left: 0.1rem solid var(--fg);
  padding-left: 2rem;
}

ol,
ul {
  margin-left: 2rem;
}
