:root {
  --bg: #000;
  --text: #f3f0ea;
  --muted: #8f8a84;
  --line: hsla(0, 22%, 16%, 1);
  --accent: hsla(0, 57%, 46%, 1);
  --accent-bright: hsla(0, 57%, 62%, 1);
  --accent-wash: hsla(0, 57%, 46%, 0.14);
  --column: 58rem;
}

html {
  color-scheme: dark;
  height: 100%;
  background: #000;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100%;
  min-height: 100vh;
  background: #000;
  color: var(--text);
  font-family: "Space Grotesk", Helvetica, Arial, sans-serif;
}

::selection {
  background: var(--accent);
  color: #fff;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -3rem;
  background: #fff;
  color: #000;
  padding: 0.4rem 0.6rem;
}

.skip:focus {
  top: 0.5rem;
}

.main,
.site-footer {
  width: min(var(--column), calc(100% - 3rem));
  margin-right: auto;
  margin-left: auto;
}

.site-header {
  display: flex;
  align-items: center;
  width: 100%;
  padding: 1vw 4vw;
  background: #000;
}

.site-logo img {
  display: block;
  height: 26px;
  width: auto;
}

.site-header > nav {
  margin-left: auto;
}

.header-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.7vw;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 16px;
  line-height: 1;
}

.header-nav a {
  color: #fff;
  font-weight: 600;
  text-decoration: none;
}

.header-nav a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-color: #fff;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.45em;
}

a:focus-visible {
  outline: 1px solid #fff;
  outline-offset: 3px;
}

.main {
  padding: 2.5rem 0 5rem;
}

.github-link {
  display: inline-flex;
  color: var(--accent);
  line-height: 0;
}

.github-link svg {
  width: 20px;
  height: 20px;
}

.github-link:hover {
  color: var(--accent-bright);
}

.posts {
  list-style: none;
  margin: 1.75rem 0 0;
  padding: 0;
}

.posts li {
  display: grid;
  grid-template-columns: 7.5rem 1fr;
  gap: 1rem;
  align-items: baseline;
  padding: 0.9rem 0;
}

.posts time,
.post-header time {
  color: var(--muted);
  font-family: "PT Mono", ui-monospace, monospace;
  font-size: 0.85rem;
}

.posts a {
  color: var(--text);
  font-weight: 600;
  font-size: 1.05rem;
  text-decoration: none;
}

.posts a:hover {
  color: var(--accent);
}

.post-header h1 {
  margin: 0 0 0.4rem;
  font-size: 2rem;
  font-weight: 600;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.post-body {
  margin-top: 2rem;
}

.post-body p,
.post-body li {
  font-size: 1.0625rem;
  line-height: 1.7;
}

.post-body h1,
.post-body h2 {
  margin-top: 2.2rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.post-body h1 {
  font-size: 1.6rem;
}

.post-body h2 {
  font-size: 1.35rem;
}

.post-body a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
}

.post-body a:hover {
  color: var(--accent-bright);
}

.post-body img {
  display: block;
  max-width: 100%;
  height: auto;
  margin: 1.25rem 0;
}

.post-body code {
  font-family: "PT Mono", ui-monospace, monospace;
  font-size: 0.92em;
}

.post-body :not(pre) > code {
  background: #000;
  padding: 0.1em 0.35em;
}

.post-body pre {
  background: #000;
  border: 1px solid var(--line);
  padding: 1rem 1.1rem;
  overflow: auto;
  font-family: "PT Mono", ui-monospace, monospace;
  font-size: 0.9rem;
  line-height: 1.5;
}

.site-footer {
  padding: 0 0 2.5rem;
  color: #8d8d8d;
  font-size: 0.85rem;
}

.site-footer p {
  margin: 0;
}

@media (max-width: 47.9375em) {
  .site-header {
    flex-wrap: wrap;
    gap: 14px 0;
    padding: 16px 20px;
  }

  .site-header > nav {
    width: 100%;
    margin-left: 0;
  }

  .header-nav {
    width: 100%;
    gap: 14px 18px;
    font-size: 14px;
  }

  .main {
    padding: 2rem 0 4rem;
  }

  .posts li {
    grid-template-columns: 1fr;
    gap: 0.25rem;
  }

  .site-footer {
    padding: 0 0 2rem;
  }
}
