@font-face {
  font-family: "Atkinson Hyperlegible";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/atkinson-hyperlegible-latin-400-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Atkinson Hyperlegible";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url("/fonts/atkinson-hyperlegible-latin-700-normal.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

@font-face {
  font-family: "Atkinson Hyperlegible";
  font-style: italic;
  font-weight: 400;
  font-display: swap;
  src: url("/fonts/atkinson-hyperlegible-latin-400-italic.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: light;
  --bg: #f6f3ec;
  --text: #1a1714;
  --muted: #3f3b36;
  --link: #0a4a73;
  --visited: #5a2d6e;
  --rule: #d2cdc2;
  --code-bg: #e7e1d6;
  --focus: #8a4b00;
  --button: #1a1714;
  --button-text: #f6f3ec;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme]) {
    color-scheme: dark;
    --bg: #141311;
    --text: #f4f0e7;
    --muted: #d0c8bb;
    --link: #9dcef5;
    --visited: #d7c4ef;
    --rule: #3c3832;
    --code-bg: #2a2622;
    --focus: #ffcc66;
    --button: #f4f0e7;
    --button-text: #141311;
  }
}

:root[data-theme="light"] {
  color-scheme: light;
  --bg: #f6f3ec;
  --text: #1a1714;
  --muted: #3f3b36;
  --link: #0a4a73;
  --visited: #5a2d6e;
  --rule: #d2cdc2;
  --code-bg: #e7e1d6;
  --focus: #8a4b00;
  --button: #1a1714;
  --button-text: #f6f3ec;
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --bg: #141311;
  --text: #f4f0e7;
  --muted: #d0c8bb;
  --link: #9dcef5;
  --visited: #d7c4ef;
  --rule: #3c3832;
  --code-bg: #2a2622;
  --focus: #ffcc66;
  --button: #f4f0e7;
  --button-text: #141311;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  background: var(--bg);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "Atkinson Hyperlegible", "Segoe UI", sans-serif;
  font-size: 1.125rem;
  line-height: 1.55;
  overflow-wrap: break-word;
}

:target {
  scroll-margin-top: 1rem;
}

.wrap {
  width: min(100%, 40rem);
  margin-inline: auto;
  padding-inline: max(1.25rem, env(safe-area-inset-left)) max(1.25rem, env(safe-area-inset-right));
}

.skip-link {
  position: absolute;
  left: 0.75rem;
  top: 0.75rem;
  z-index: 2;
  padding: 0.5rem 0.75rem;
  background: var(--bg);
  color: var(--text);
  border: 2px solid var(--text);
}

.skip-link:not(:focus):not(:focus-visible) {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

:focus {
  outline: none;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.site-header {
  padding-top: 1.25rem;
  padding-bottom: 0.25rem;
  border-bottom: 1px solid var(--rule);
}

.bar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem 1rem;
}

.wordmark {
  color: var(--text);
  font-weight: 700;
  font-size: 1.25rem;
  line-height: 1.2;
  text-decoration: none;
}

a.wordmark:visited {
  color: var(--text);
}

.wordmark:hover {
  text-decoration: underline;
  text-decoration-thickness: 2px;
  text-underline-offset: 0.15em;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.35rem 0.75rem;
  border: 1px solid var(--text);
  background: transparent;
  color: var(--text);
  font: inherit;
  cursor: pointer;
}

.theme-toggle[hidden] {
  display: none !important;
}

.theme-toggle:hover {
  background: var(--text);
  color: var(--bg);
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1rem;
  list-style: none;
  margin: 0.25rem 0 0;
  padding: 0;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  color: var(--link);
}

main {
  padding-top: 1.75rem;
  padding-bottom: 1rem;
}

main:focus {
  outline: none;
}

h1,
h2,
h3 {
  font-weight: 700;
  line-height: 1.25;
  text-wrap: balance;
}

h1 {
  margin: 0 0 0.75rem;
  font-size: 2rem;
}

h2 {
  margin: 0 0 0.75rem;
  font-size: 1.5rem;
}

h3 {
  margin: 1.25rem 0 0.35rem;
  font-size: 1.2rem;
}

p,
ul,
ol,
blockquote {
  margin: 0.75rem 0 0;
}

.lede {
  margin: 0;
  font-size: 1.25rem;
  line-height: 1.45;
}

.note {
  color: var(--muted);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.25rem;
}

a {
  color: var(--link);
  text-underline-offset: 0.15em;
}

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

a.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.4rem 0.85rem;
  border: 1px solid var(--button);
  background: transparent;
  color: var(--text);
  text-decoration: none;
}

a.button:visited {
  color: var(--text);
}

a.button-primary {
  background: var(--button);
  color: var(--button-text);
}

a.button-primary:visited {
  color: var(--button-text);
}

a.button:hover,
a.button:visited:hover {
  background: var(--button);
  color: var(--button-text);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

a.button-primary:hover,
a.button-primary:visited:hover {
  background: transparent;
  color: var(--text);
}

section {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
}

section > h2 {
  margin-top: 0;
}

ol.steps,
ol.projects {
  margin-top: 0.25rem;
  padding-left: 1.4rem;
}

ol.steps > li,
ol.projects > li {
  margin-top: 1.15rem;
  padding-top: 1.15rem;
  border-top: 1px solid var(--rule);
}

ol.steps > li:first-child,
ol.projects > li:first-child {
  margin-top: 0.75rem;
  padding-top: 0;
  border-top: 0;
}

ol.steps h3,
ol.projects h3 {
  margin: 0 0 0.35rem;
}

.role {
  margin-top: 0.15rem;
  color: var(--muted);
}

blockquote {
  margin-left: 0;
  padding: 0;
  color: var(--muted);
  font-style: italic;
}

blockquote p {
  margin: 0;
}

.by {
  color: var(--muted);
}

.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  margin-top: 0.5rem;
  padding: 0;
  list-style: none;
}

.project-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
}

code,
kbd {
  padding: 0.05em 0.3em;
  background: var(--code-bg);
  font-family: ui-monospace, "Cascadia Code", "Source Code Pro", Menlo, Consolas, monospace;
  font-size: 0.95em;
}

kbd {
  border: 1px solid var(--rule);
}

code {
  overflow-wrap: anywhere;
}

.site-footer {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  padding-bottom: max(2.5rem, env(safe-area-inset-bottom));
  border-top: 1px solid var(--rule);
}

.site-footer h2 {
  margin-top: 1.5rem;
  font-size: 1.2rem;
}

.site-footer ul {
  margin-top: 0.35rem;
  padding-left: 1.2rem;
}

.site-footer li + li {
  margin-top: 0.2rem;
}

::selection {
  background: #f0d78c;
  color: #1a1714;
}

@media (min-width: 48rem) {
  h1 {
    font-size: 2.4rem;
  }

  .site-header {
    padding-top: 1.75rem;
  }

  main {
    padding-top: 2.25rem;
  }
}

@media (forced-colors: active) {
  .button,
  .theme-toggle {
    border: 1px solid ButtonText;
  }

  :focus-visible {
    outline: 3px solid Highlight;
  }
}

@media print {
  .skip-link,
  .theme-toggle,
  .site-nav {
    display: none !important;
  }

  body {
    background: #fff;
    color: #000;
    font-size: 12pt;
  }

  a,
  a:visited {
    color: #000;
  }

  a[href^="http"]::after {
    content: " (" attr(href) ")";
    font-style: normal;
    font-size: 0.9em;
    word-break: break-all;
  }

  .site-header,
  section,
  .site-footer,
  ol.steps > li,
  ol.projects > li {
    border-color: #000;
  }
}
