@font-face {
  font-family: "Hack";
  src: url("/assets/fonts/HackDejavu.woff2") format("woff2");
  font-style: normal;
  font-weight: 400;
  font-display: swap;
}

@font-face {
  font-family: "Hack";
  src: url("/assets/fonts/HackDejavuBold.woff2") format("woff2");
  font-style: normal;
  font-weight: 700;
  font-display: swap;
}

:root {
  color-scheme: light;
  --paper: #f5f5f4;
  --ink: #292524;
  --muted: #66635f;
  --accent: #249b62;
  --line: #d6d3d1;
  --font: "Hack", "SFMono-Regular", Consolas, monospace;
  --font-body: var(--font);
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font);
  font-size: 100%;
  -webkit-text-size-adjust: 100%;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-size: 1.125rem;
  line-height: 1.777777778;
  -webkit-font-smoothing: antialiased;
}

::selection { background: color-mix(in srgb, var(--accent) 20%, var(--paper)); color: var(--ink); }

a {
  color: inherit;
  text-decoration: none;
  transition: color 140ms ease;
}

a:hover { color: var(--accent); }
a:focus-visible { color: var(--accent); outline: 2px solid var(--accent); outline-offset: 5px; }

.page {
  width: min(100% - 4rem, 68rem);
  margin-inline: auto;
}

.site-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: .75rem 1.5rem;
  padding-block: 1.75rem 1.25rem;
  border-bottom: 1px solid var(--line);
}

.wordmark { font-size: 1.125rem; text-decoration: none; }

.site-header nav {
  display: flex;
  flex-wrap: wrap;
  gap: .5rem 1.5rem;
  font-size: .875rem;
}

.site-header nav a {
  padding-block: .375rem;
  color: var(--muted);
  text-decoration: none;
}

.site-header nav a:hover, .site-header nav a:focus-visible { color: var(--accent); }

main {
  max-width: 48rem;
  margin: 3.5rem auto 0;
}
h1, p { margin: 0; }

h1 {
  margin-bottom: 1.5rem;
  font-size: 2.25rem;
  font-weight: 700;
  line-height: 1.25;
  letter-spacing: -.035em;
}

.intro p {
  font-family: var(--font-body);
  line-height: 1.7;
  text-wrap: pretty;
}

.intro p + p { margin-top: 1.25rem; }
.keep-together { white-space: nowrap; }

.intro-heading {
  display: flex;
  align-items: center;
  gap: .75rem;
  margin-bottom: 1.75rem;
}

.intro-heading h1 { margin-bottom: 0; }
.intro-heading .doodle { flex-shrink: 0; }

.site-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 3.5rem;
  padding-block: 1.25rem 2rem;
  border-top: 1px solid var(--line);
  color: var(--muted);
}

.site-footer small { font-size: .8125rem; line-height: 1.5; }
.doodle { color: var(--accent); transform: rotate(-7deg); }

.skip-link {
  position: absolute;
  top: .5rem;
  left: 1rem;
  padding: .5rem 1rem;
  background: var(--paper);
  transform: translateY(-200%);
}

.skip-link:focus { transform: translateY(0); }
.not-found { padding-bottom: 2rem; }
.not-found p { margin-bottom: 1rem; }

@media (max-width: 700px) {
  body { font-size: 1rem; line-height: 1.75; }
  .page { width: calc(100% - 3rem); }
  .site-header { padding-block: 1.25rem 1rem; }
  .site-header nav { gap: .5rem 1rem; }
  main { margin-top: 2.5rem; }
  h1 { font-size: 1.75rem; letter-spacing: -.025em; }
  .intro-heading { margin-bottom: 1.25rem; }
  .intro p { line-height: 1.75; }
  .site-footer { margin-top: 2.5rem; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; }
}
