@font-face {
  font-family: "Inter";
  src: url("/public/fonts/inter/InterVariable.woff2") format("woff2");
  font-weight: 100 900;
  font-display: swap;
}

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("/public/fonts/bricolage-grotesque/bricolage-grotesque-latin-ext.woff2") format("woff2");
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "Bricolage Grotesque";
  src: url("/public/fonts/bricolage-grotesque/bricolage-grotesque-latin.woff2") format("woff2");
  font-weight: 200 800;
  font-stretch: 75% 100%;
  font-display: swap;
  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: "JetBrains Mono";
  src: url("/public/fonts/jetbrains-mono/jetbrains-mono-latin-ext.woff2") format("woff2");
  font-weight: 400 600;
  font-display: swap;
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

@font-face {
  font-family: "JetBrains Mono";
  src: url("/public/fonts/jetbrains-mono/jetbrains-mono-latin.woff2") format("woff2");
  font-weight: 400 600;
  font-display: swap;
  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;
}

/*
 * Design tokens. Every value below the token section comes from here; the rules are in DESIGN.md
 * and views/pages/design_test.go fails the build on a hard-coded color, size, weight or radius.
 */

:root {
  /* Color: light theme */
  --paper: #f3f5f2;
  --paper-raised: #ffffff;
  --ink: #15191d;
  --ink-soft: #4d555c;
  --ink-faint: #7b848b;
  --rule: #d6dbd5;
  --gopher: #007d9c;
  --gopher-bright: #00add8;
  --gopher-wash: #dcefF3;
  --live: #23935a;
  --selection: #bfe7f1;
  --logo-plate: #ffffff;
  --overlay: rgb(0 0 0 / 0.55);
  --on-overlay: #ffffff;
  --code-keyword: #b03a6f;
  --code-string: #2c7a3c;
  --code-number: #9a5b00;
  --code-builtin: #6a4fb3;

  /* Type */
  --font-display: "Bricolage Grotesque", "Inter", system-ui, sans-serif;
  --font-text: "Inter", system-ui, -apple-system, sans-serif;
  --font-code: "JetBrains Mono", ui-monospace, "SF Mono", Menlo, monospace;
  --display-width: "wdth" 100;

  --step--2: 0.75rem;
  --step--1: 0.875rem;
  --step-0: 1rem;
  --step-prose: 1.0625rem;
  --step-1: 1.1875rem;
  --step-2: 1.5rem;
  --step-3: 2rem;
  --step-4: clamp(2.25rem, 5.5vw, 3.75rem);
  --step-5: clamp(3rem, 9.5vw, 7.25rem);
  --step-print: 10.5pt;

  --weight-light: 300;
  --weight-text: 400;
  --weight-medium: 550;
  --weight-strong: 600;
  --weight-heading: 640;

  --tracking-display: -0.025em;
  --tracking-heading: -0.012em;

  --leading-display: 1;
  --leading-heading: 1.12;
  --leading-snug: 1.3;
  --leading-body: 1.6;
  --leading-prose: 1.75;

  /* Layout */
  --gutter: clamp(1rem, 4vw, 3rem);
  --measure: 68ch;
  --page: 76rem;

  /* Shape */
  --radius-xs: 4px;
  --radius-s: 8px;
  --radius-m: 14px;
  --radius-pill: 999px;
  --radius-round: 50%;

  /* Motion */
  --motion-fast: 120ms;
  --motion-reveal: 900ms;
  --motion-stagger: 70ms;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #0f1418;
    --paper-raised: #172027;
    --ink: #e6ebe7;
    --ink-soft: #a9b3b8;
    --ink-faint: #7d898f;
    --rule: #26313a;
    --gopher: #5ccbe4;
    --gopher-bright: #7fdcf0;
    --gopher-wash: #153641;
    --live: #4cc785;
    --selection: #1d4f5e;
    --code-keyword: #f08fbd;
    --code-string: #8fd19e;
    --code-number: #f0b86b;
    --code-builtin: #b9a5f2;
  }
}

:root[data-theme="dark"] {
  --paper: #0f1418;
  --paper-raised: #172027;
  --ink: #e6ebe7;
  --ink-soft: #a9b3b8;
  --ink-faint: #7d898f;
  --rule: #26313a;
  --gopher: #5ccbe4;
  --gopher-bright: #7fdcf0;
  --gopher-wash: #153641;
  --live: #4cc785;
  --selection: #1d4f5e;
  --code-keyword: #f08fbd;
  --code-string: #8fd19e;
  --code-number: #f0b86b;
  --code-builtin: #b9a5f2;
}

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

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

:root {
  color-scheme: light;
}

:root[data-theme="dark"] {
  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    color-scheme: dark;
  }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-text);
  font-size: var(--step-0);
  line-height: var(--leading-body);
  font-feature-settings: "cv11", "ss01";
  -webkit-font-smoothing: antialiased;
}

::selection {
  background: var(--selection);
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--gopher);
}

:focus-visible {
  outline: 2px solid var(--gopher-bright);
  outline-offset: 3px;
  border-radius: var(--radius-xs);
}

h1,
h2,
h3,
p,
ul,
ol,
dl,
dd,
figure {
  margin: 0;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  font-weight: var(--weight-heading);
  line-height: var(--leading-heading);
  letter-spacing: var(--tracking-display);
  font-variation-settings: var(--display-width);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  left: -999px;
  top: 0.5rem;
  padding: 0.5rem 0.75rem;
  background: var(--ink);
  color: var(--paper);
  z-index: 10;
}

.skip-link:focus {
  left: 0.5rem;
}

.wrap {
  width: 100%;
  max-width: var(--page);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

/* Header */

.site-header {
  border-bottom: 1px solid var(--rule);
}

.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 4rem;
}

.wordmark {
  font-family: var(--font-display);
  font-weight: var(--weight-heading);
  font-size: var(--step-1);
  letter-spacing: var(--tracking-display);
  text-decoration: none;
  white-space: nowrap;
}

.wordmark span {
  color: var(--gopher);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(0.75rem, 2.5vw, 1.75rem);
  font-size: var(--step--1);
}

.site-nav a {
  text-decoration: none;
  color: var(--ink-soft);
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--ink);
}

.site-nav a[aria-current="page"] {
  text-decoration: underline;
  text-decoration-color: var(--gopher-bright);
  text-decoration-thickness: 2px;
  text-underline-offset: 0.45em;
}

.button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1rem;
  border-radius: var(--radius-pill);
  border: 1px solid var(--ink);
  background: var(--ink);
  color: var(--paper);
  font-size: var(--step--1);
  font-weight: var(--weight-medium);
  text-decoration: none;
  white-space: nowrap;
}

.button:hover {
  background: var(--gopher);
  border-color: var(--gopher);
  color: var(--paper);
}

.button.quiet {
  background: transparent;
  color: var(--ink);
  border-color: var(--rule);
}

.button.quiet:hover {
  border-color: var(--ink);
  color: var(--ink);
}

.site-nav .button {
  color: var(--paper);
  padding: 0.45rem 0.85rem;
}

.site-nav .button:hover {
  color: var(--paper);
}

@media (max-width: 52rem) {
  .site-nav .nav-cta {
    display: none;
  }
}

.site-header .wrap {
  gap: clamp(0.75rem, 3vw, 2rem);
}

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

.site-tools {
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.tool {
  display: inline-grid;
  place-items: center;
  min-width: 2.25rem;
  height: 2.25rem;
  padding: 0 0.4rem;
  border: 1px solid transparent;
  border-radius: var(--radius-pill);
  background: none;
  color: var(--ink-soft);
  font: inherit;
  font-size: var(--step--1);
  font-weight: var(--weight-strong);
  text-decoration: none;
  cursor: pointer;
}

.tool:hover {
  color: var(--ink);
  border-color: var(--rule);
}

.theme-toggle svg {
  width: 1.1rem;
  height: 1.1rem;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.theme-toggle .icon-moon {
  fill: currentColor;
  stroke: none;
}

.theme-toggle .icon-sun {
  display: none;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .theme-toggle .icon-sun {
    display: block;
  }

  :root:not([data-theme="light"]) .theme-toggle .icon-moon {
    display: none;
  }
}

:root[data-theme="dark"] .theme-toggle .icon-sun {
  display: block;
}

:root[data-theme="dark"] .theme-toggle .icon-moon {
  display: none;
}

@media (max-width: 30rem) {
  .wordmark span {
    display: none;
  }
}

/* Sections */

main {
  display: block;
}

.section {
  padding-block: clamp(3rem, 8vw, 6rem);
  border-top: 1px solid var(--rule);
}

.section-head {
  display: grid;
  gap: 0.5rem;
  margin-bottom: clamp(1.5rem, 4vw, 2.5rem);
  max-width: 44rem;
}

.section-head h2 {
  font-size: var(--step-3);
}

.section-head p {
  color: var(--ink-soft);
}

.section-foot {
  margin-top: 2rem;
}

/* Hero */

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 2rem;
  padding-block: clamp(2.5rem, 7vw, 5.5rem) clamp(2.5rem, 6vw, 4.5rem);
  align-items: end;
}

@media (min-width: 56rem) {
  .hero {
    grid-template-columns: minmax(0, 1fr) 20rem;
  }
}

.hero h1 {
  font-size: var(--step-5);
  font-weight: var(--weight-heading);
  line-height: var(--leading-display);
  letter-spacing: var(--tracking-display);
  font-variation-settings: var(--display-width);
}

.hero h1 .surname {
  display: block;
  font-weight: var(--weight-light);
  letter-spacing: var(--tracking-display);
  font-variation-settings: var(--display-width);
}

.hero-lede {
  margin-top: 1.75rem;
  max-width: 36rem;
  font-size: var(--step-1);
  line-height: var(--leading-body);
  color: var(--ink-soft);
}

.hero-lede strong {
  color: var(--ink);
  font-weight: var(--weight-strong);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 2rem;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: var(--step--1);
  color: var(--ink-soft);
}

.status::before {
  content: "";
  width: 0.55rem;
  height: 0.55rem;
  border-radius: var(--radius-round);
  background: var(--live);
}

.hero-portrait {
  position: relative;
  justify-self: start;
  width: min(100%, 20rem);
}

.hero-portrait img {
  width: 100%;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius-m);
  mix-blend-mode: multiply;
  filter: grayscale(0.15) contrast(1.02);
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .hero-portrait img {
    mix-blend-mode: normal;
  }
}

:root[data-theme="dark"] .hero-portrait img {
  mix-blend-mode: normal;
}

.hero-portrait figcaption {
  margin-top: 0.75rem;
  font-size: var(--step--1);
  color: var(--ink-faint);
}

@media (max-width: 55.99rem) {
  .hero-portrait {
    order: -1;
    width: 8rem;
  }

  .hero-portrait figcaption {
    display: none;
  }
}

/* Project index (home) */

.project-index {
  list-style: none;
  padding: 0;
  border-top: 1px solid var(--rule);
}

.project-index li {
  border-bottom: 1px solid var(--rule);
}

.project-index a {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 0.25rem 2rem;
  padding-block: 1.25rem;
  text-decoration: none;
}

@media (min-width: 52rem) {
  .project-index a {
    grid-template-columns: 13rem 14rem minmax(0, 1fr);
    align-items: baseline;
  }
}

.pi-name {
  font-family: var(--font-display);
  font-size: var(--step-2);
  font-weight: var(--weight-heading);
  letter-spacing: var(--tracking-display);
  font-variation-settings: var(--display-width);
}

.pi-meta {
  font-size: var(--step--1);
  color: var(--ink-faint);
}

.pi-tagline {
  color: var(--ink-soft);
}

.project-index a:hover .pi-name {
  color: var(--gopher);
}

/* Showcase (projects page) */

.showcase-list {
  display: grid;
  gap: 0;
  padding-bottom: clamp(3rem, 8vw, 6rem);
}

.showcase {
  display: grid;
  gap: 1.5rem 3rem;
  padding-block: clamp(2rem, 5vw, 3.5rem);
  border-top: 1px solid var(--rule);
  scroll-margin-top: 1rem;
}

@media (min-width: 52rem) {
  .showcase--portrait {
    grid-template-columns: 17rem minmax(0, 1fr);
    align-items: start;
  }

  .showcase--landscape .showcase-body {
    display: grid;
    grid-template-columns: 16rem minmax(0, 1fr);
    gap: 0.5rem 3rem;
  }

  .showcase--landscape .showcase-body > :not(h2):not(.showcase-meta) {
    grid-column: 2;
  }

  .showcase--landscape .showcase-body h2 {
    grid-row: 1 / span 2;
  }
}

.showcase h2 {
  font-size: var(--step-3);
}

.showcase-meta {
  margin-top: 0.35rem;
  font-size: var(--step--1);
  color: var(--ink-faint);
}

.showcase-tagline {
  margin-top: 0.75rem;
  font-size: var(--step-1);
  max-width: 40rem;
}

.showcase-body > p + p {
  margin-top: 0.75rem;
}

.showcase-body p:not(.showcase-meta):not(.showcase-tagline) {
  color: var(--ink-soft);
  max-width: var(--measure);
}

.showcase-stack {
  font-size: var(--step--1);
}

.showcase-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1.25rem;
  font-weight: var(--weight-medium);
}

/* Media */

.media {
  position: relative;
  margin: 0;
  border-radius: var(--radius-m);
  overflow: hidden;
  background: var(--paper-raised);
  border: 1px solid var(--rule);
}

.media img,
.media video {
  display: block;
  width: 100%;
  height: auto;
}

.media--portrait {
  max-width: 17rem;
}

.media--landscape {
  max-width: 50rem;
}

.media figcaption {
  padding: 0.6rem 0.9rem;
  border-top: 1px solid var(--rule);
  font-size: var(--step--1);
  color: var(--ink-faint);
}

.media-toggle {
  position: absolute;
  right: 0.6rem;
  bottom: 0.6rem;
  width: 2rem;
  height: 2rem;
  border: 0;
  border-radius: var(--radius-round);
  background: var(--overlay);
  color: var(--on-overlay);
  cursor: pointer;
  opacity: 0;
  transition: opacity var(--motion-fast) ease;
}

.media:hover .media-toggle,
.media-toggle:focus-visible,
.media-toggle[data-state="paused"] {
  opacity: 1;
}

.media-toggle::before {
  content: "";
  position: absolute;
  inset: 0;
  margin: auto;
  width: 0.6rem;
  height: 0.75rem;
  border-inline: 3px solid currentColor;
  box-sizing: border-box;
}

.media-toggle[data-state="paused"]::before {
  width: 0;
  height: 0;
  border-inline: 0;
  border-left: 0.6rem solid currentColor;
  border-block: 0.4rem solid transparent;
  margin-left: calc(50% - 0.2rem);
}

/* Screenshots in articles */

.shots {
  margin: 2em 0;
}

.shots .row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(8.5rem, 1fr));
  gap: 0.75rem;
  align-items: start;
}

.shots img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius-m);
  border: 1px solid var(--rule);
  background: var(--paper-raised);
}

.shots.wide .row {
  grid-template-columns: minmax(0, 1fr);
}

.shots.wide img {
  border-radius: var(--radius-s);
}

.shots figcaption {
  margin-top: 0.75rem;
  font-size: var(--step--1);
  color: var(--ink-faint);
}

/* Diagrams */

.diagram {
  margin: 2em 0;
  padding: 1.25rem;
  border: 1px solid var(--rule);
  border-radius: var(--radius-m);
  background: var(--paper-raised);
  overflow-x: auto;
}

.diagram svg {
  display: block;
  width: 100%;
  min-width: 34rem;
  height: auto;
  font-family: var(--font-text);
}

.diagram figcaption {
  margin-top: 0.75rem;
  font-size: var(--step--1);
  color: var(--ink-faint);
}

.diagram .box {
  fill: var(--paper);
  stroke: var(--ink-faint);
  stroke-width: 1.25;
}

.diagram .box.accent {
  fill: var(--gopher-wash);
  stroke: var(--gopher);
}

.diagram .box.dashed {
  fill: none;
  stroke-dasharray: 5 4;
}

.diagram .label {
  fill: var(--ink);
  font-size: var(--step--1);
  font-weight: var(--weight-strong);
}

.diagram .note {
  fill: var(--ink-soft);
  font-size: var(--step--2);
}

.diagram .edge {
  fill: none;
  stroke: var(--ink-soft);
  stroke-width: 1.25;
}

.diagram .edge.accent {
  stroke: var(--gopher);
}

.diagram .arrow {
  fill: var(--ink-soft);
}

.diagram .arrow.accent {
  fill: var(--gopher);
}

.diagram .grid {
  stroke: var(--rule);
  stroke-width: 1;
}

.diagram .bar {
  fill: var(--ink-faint);
}

.diagram .bar.accent {
  fill: var(--gopher);
}

.diagram .bar.soft {
  fill: color-mix(in srgb, var(--gopher) 45%, var(--paper));
}

.diagram .bar.cut {
  fill: var(--rule);
  stroke: var(--ink-faint);
  stroke-dasharray: 3 3;
}

/* Post list */

.post-list {
  list-style: none;
  padding: 0;
}

.post-item {
  display: grid;
  gap: 0.35rem 2rem;
  padding-block: 1.5rem;
  border-top: 1px solid var(--rule);
}

@media (min-width: 48rem) {
  .post-item {
    grid-template-columns: 9rem minmax(0, 1fr);
  }
}

.post-item time {
  font-size: var(--step--1);
  color: var(--ink-faint);
  padding-top: 0.3rem;
}

.post-item h3 {
  font-size: var(--step-2);
}

.post-item h3 a {
  text-decoration: none;
}

.post-item p {
  margin-top: 0.4rem;
  max-width: var(--measure);
  color: var(--ink-soft);
}

/* Page heads */

.page-head {
  padding-block: clamp(2.5rem, 7vw, 5rem) clamp(2rem, 5vw, 3rem);
}

.page-head h1 {
  font-size: var(--step-4);
  font-variation-settings: var(--display-width);
  letter-spacing: var(--tracking-display);
}

.page-foot {
  padding-bottom: clamp(3rem, 8vw, 6rem);
}

.page-head p {
  margin-top: 1rem;
  max-width: 40rem;
  font-size: var(--step-1);
  color: var(--ink-soft);
}

/* Article */

.article-head {
  padding-block: clamp(2.5rem, 7vw, 5rem) 2rem;
  max-width: 50rem;
}

.article-head h1 {
  font-size: var(--step-4);
  font-variation-settings: var(--display-width);
  letter-spacing: var(--tracking-display);
}

.article-head .summary {
  margin-top: 1.25rem;
  font-size: var(--step-1);
  color: var(--ink-soft);
  max-width: 42rem;
}

.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
  margin-top: 1.5rem;
  font-size: var(--step--1);
  color: var(--ink-faint);
}

.back-link {
  display: inline-block;
  margin-bottom: 1.5rem;
  font-size: var(--step--1);
  color: var(--ink-soft);
}

.article-layout {
  display: grid;
  gap: 2.5rem;
  padding-bottom: clamp(3rem, 8vw, 6rem);
}

@media (min-width: 64rem) {
  .article-layout {
    grid-template-columns: minmax(0, var(--measure)) minmax(0, 16rem);
    justify-content: space-between;
  }
}

.article-media {
  margin-bottom: 2.5rem;
}

.article-aside {
  display: grid;
  gap: 1.25rem;
  align-content: start;
}

@media (min-width: 64rem) {
  .article-aside {
    position: sticky;
    top: 1.5rem;
    align-self: start;
  }
}

.project-card {
  align-self: start;
  padding: 1.25rem;
  border: 1px solid var(--rule);
  border-radius: var(--radius-m);
  background: var(--paper-raised);
  font-size: var(--step--1);
}

.project-card h2 {
  font-size: var(--step-2);
  margin-bottom: 0.35rem;
}

.project-card p {
  color: var(--ink-soft);
}

.project-card dl {
  display: grid;
  gap: 0.75rem;
  margin-top: 1rem;
}

.project-card dt {
  color: var(--ink-faint);
}

.project-card dd {
  margin-top: 0.15rem;
}

/* Prose */

.prose {
  font-size: var(--step-prose);
  line-height: var(--leading-prose);
  max-width: var(--measure);
  min-width: 0;
}

.prose > * + * {
  margin-top: 1.25em;
}

.prose h2 {
  font-size: var(--step-3);
  margin-top: 2.25em;
}

.prose h3 {
  font-size: var(--step-2);
  margin-top: 1.75em;
}

.prose h2 + *,
.prose h3 + * {
  margin-top: 0.75em;
}

.prose a {
  color: var(--gopher);
}

.prose ul,
.prose ol {
  padding-left: 1.25em;
}

.prose li + li {
  margin-top: 0.4em;
}

.prose li::marker {
  color: var(--ink-faint);
}

.prose blockquote {
  margin: 1.5em 0;
  padding-left: 1.25em;
  border-left: 3px solid var(--gopher-bright);
  color: var(--ink-soft);
}

.prose code {
  font-family: var(--font-code);
  font-size: 0.86em;
  padding: 0.1em 0.35em;
  border-radius: var(--radius-xs);
  background: color-mix(in srgb, var(--gopher-wash) 70%, var(--paper));
}

.prose pre {
  margin-top: 1.5em;
  padding: 1rem 1.25rem;
  overflow-x: auto;
  border-radius: var(--radius-m);
  border: 1px solid var(--rule);
  background: var(--paper-raised);
  font-size: var(--step--1);
  line-height: var(--leading-body);
}

.prose pre code {
  padding: 0;
  background: none;
  font-size: inherit;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--step--1);
  display: block;
  overflow-x: auto;
}

.prose th,
.prose td {
  text-align: left;
  padding: 0.5rem 0.75rem 0.5rem 0;
  border-bottom: 1px solid var(--rule);
  vertical-align: top;
}

.prose th {
  font-weight: var(--weight-strong);
}

.prose hr {
  border: 0;
  border-top: 1px solid var(--rule);
  margin-block: 2.5em;
}

.post-nav {
  display: grid;
  gap: 1rem;
  margin-top: 3.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--rule);
  font-size: var(--step--1);
}

@media (min-width: 40rem) {
  .post-nav {
    grid-template-columns: 1fr 1fr;
  }

  .post-nav .older {
    text-align: right;
  }
}

.post-nav a {
  display: block;
  text-decoration: none;
}

.post-nav span {
  color: var(--ink-faint);
}

.post-nav strong {
  display: block;
  margin-top: 0.2rem;
  font-family: var(--font-display);
  font-size: var(--step-1);
  font-weight: var(--weight-strong);
  line-height: var(--leading-snug);
}

/* Syntax highlighting (chroma classes) */

.chroma .c,
.chroma .c1,
.chroma .cm,
.chroma .cs {
  color: var(--ink-faint);
  font-style: italic;
}

.chroma .k,
.chroma .kd,
.chroma .kn,
.chroma .kr,
.chroma .kt,
.chroma .kc {
  color: var(--code-keyword);
}

.chroma .s,
.chroma .s1,
.chroma .s2,
.chroma .sb,
.chroma .sr {
  color: var(--code-string);
}

.chroma .m,
.chroma .mi,
.chroma .mf,
.chroma .mh {
  color: var(--code-number);
}

.chroma .nf,
.chroma .fm {
  color: var(--gopher);
}

.chroma .nb,
.chroma .bp {
  color: var(--code-builtin);
}

/* Footer */

.site-footer {
  border-top: 1px solid var(--rule);
  padding-block: clamp(3rem, 8vw, 5rem) 2rem;
}

.footer-grid {
  display: grid;
  gap: 2.5rem;
}

@media (min-width: 52rem) {
  .footer-grid {
    grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr);
    align-items: end;
  }
}

.footer-grid h2 {
  font-size: var(--step-4);
  font-variation-settings: var(--display-width);
  letter-spacing: var(--tracking-display);
}

.footer-grid p {
  margin-top: 1rem;
  color: var(--ink-soft);
  max-width: 32rem;
}

.footer-links {
  list-style: none;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem 1.5rem;
}

.footer-links a {
  text-decoration: none;
  color: var(--ink-soft);
}

@media (max-width: 30rem) {
  .footer-links {
    grid-template-columns: minmax(0, 1fr);
  }
}

.footer-links li {
  overflow-wrap: anywhere;
}

.footer-links a:hover {
  color: var(--gopher);
}

.footer-small {
  margin-top: 3rem;
  font-size: var(--step--1);
  color: var(--ink-faint);
}

/* CV */

.cv-head {
  display: grid;
  gap: 1.5rem;
  padding-block: clamp(2.5rem, 7vw, 4.5rem) 2rem;
}

@media (min-width: 52rem) {
  .cv-head {
    grid-template-columns: 9rem minmax(0, 1fr) auto;
    align-items: end;
    gap: 2rem;
  }
}

.cv-head img {
  width: 9rem;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: var(--radius-m);
  mix-blend-mode: multiply;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) .cv-head img {
    mix-blend-mode: normal;
  }
}

.cv-head h1 {
  font-size: var(--step-4);
  font-variation-settings: var(--display-width);
  letter-spacing: var(--tracking-display);
}

.cv-head .role {
  margin-top: 0.5rem;
  font-size: var(--step-1);
  color: var(--ink-soft);
}

.cv-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.cv-layout {
  display: grid;
  gap: 3rem;
  padding-bottom: 5rem;
}

@media (min-width: 60rem) {
  .cv-layout {
    grid-template-columns: 17rem minmax(0, 1fr);
    gap: 4rem;
  }
}

.cv-aside {
  display: grid;
  gap: 2rem;
  align-content: start;
  font-size: var(--step--1);
}

.cv-aside h2,
.cv-main h2 {
  font-size: var(--step-2);
  margin-bottom: 1rem;
}

.cv-aside p {
  color: var(--ink-soft);
  line-height: var(--leading-body);
  white-space: pre-line;
}

.cv-aside dl {
  display: grid;
  gap: 1rem;
}

.cv-aside dt {
  font-weight: var(--weight-strong);
  margin-bottom: 0.35rem;
}

.cv-contact {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.35rem;
}

.cv-main {
  display: grid;
  gap: 3.5rem;
  align-content: start;
}

.timeline {
  list-style: none;
  padding: 0;
}

.job {
  display: grid;
  grid-template-columns: 2.5rem minmax(0, 1fr);
  gap: 1rem;
  padding-block: 1.5rem;
  border-top: 1px solid var(--rule);
  break-inside: avoid;
}

.job .logo {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--radius-s);
  object-fit: contain;
  background: var(--logo-plate);
  border: 1px solid var(--rule);
}

.job h3 {
  font-family: var(--font-text);
  font-size: var(--step-1);
  font-weight: var(--weight-strong);
  letter-spacing: var(--tracking-heading);
  font-variation-settings: normal;
}

.job-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem 1rem;
  margin-top: 0.25rem;
  font-size: var(--step--1);
  color: var(--ink-faint);
}

.job-meta .company {
  color: var(--ink-soft);
  font-weight: var(--weight-medium);
}

.job ul {
  margin-top: 0.75rem;
  padding-left: 1.1rem;
  color: var(--ink-soft);
  max-width: var(--measure);
}

.job li + li {
  margin-top: 0.4rem;
}

.job-stack {
  margin-top: 0.75rem;
  font-size: var(--step--1);
  color: var(--ink-faint);
}

/* Design system reference (/design) */

.ds {
  padding-bottom: clamp(3rem, 8vw, 6rem);
}

.ds-section {
  display: grid;
  gap: 1rem;
  padding-block: 2.5rem;
  border-top: 1px solid var(--rule);
}

.ds-section > h2,
.ds-h2 {
  font-size: var(--step-3);
}

.ds-h3 {
  font-size: var(--step-2);
}

.ds-note,
.ds-label,
.ds-small {
  font-size: var(--step--1);
  color: var(--ink-faint);
}

.ds-specimens {
  display: grid;
  gap: 0.5rem;
}

.ds-specimens .hero,
.ds-specimens .page-head {
  padding: 0;
  border: 0;
}

.ds-tokens {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 0.5rem;
}

.ds-tokens li {
  display: grid;
  grid-template-columns: 3rem minmax(9rem, 14rem) minmax(0, 1fr);
  align-items: center;
  gap: 1rem;
  font-size: var(--step--1);
  color: var(--ink-soft);
}

.ds-swatch,
.ds-shape {
  width: 3rem;
  height: 2rem;
  border: 1px solid var(--rule);
}

.ds-swatch {
  border-radius: var(--radius-s);
}

.ds-shape {
  background: var(--gopher-wash);
}

.ds-weight {
  font-family: var(--font-display);
  font-size: var(--step-2);
  color: var(--ink);
}

.ds-row {
  display: flex;
  gap: 0.5rem;
}

/* 404 */

.not-found {
  padding-block: clamp(4rem, 12vw, 9rem);
}

.not-found h1 {
  font-size: var(--step-5);
  font-variation-settings: var(--display-width);
  letter-spacing: var(--tracking-display);
}

.not-found p {
  margin-top: 1.25rem;
  font-size: var(--step-1);
  color: var(--ink-soft);
  max-width: 34rem;
}

.not-found .hero-actions {
  margin-top: 2rem;
}

/* Journey: the career on a timeline, each job as wide as its duration. */
.journey-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  margin-top: 1.5rem;
  padding: 0;
  list-style: none;
  font-size: var(--step--1);
  color: var(--ink-soft);
}
.journey-swatch {
  display: inline-block;
  width: 1.4rem;
  height: 0.6rem;
  margin-right: 0.45rem;
  border-radius: var(--radius-pill);
  vertical-align: middle;
  background: var(--ink-soft);
}
.journey-swatch.is-freelance {
  background: var(--gopher);
}
.journey-swatch.is-study {
  background: var(--gopher-wash);
}
.journey-swatch.is-project {
  border: 2px solid var(--gopher);
  background: transparent;
}
.journey-swatch.is-tech {
  background: var(--gopher);
  opacity: 0.45;
}
.journey-chart {
  position: relative;
  margin-block: 1rem 3rem;
  padding-top: 2rem;
}
.journey-axis {
  position: relative;
  height: 1.5rem;
  border-bottom: 1px solid var(--rule);
  font-size: var(--step--2);
  font-variant-numeric: tabular-nums;
  color: var(--ink-faint);
}
.journey-axis span {
  position: absolute;
  left: var(--x);
  bottom: 0.3rem;
  transform: translateX(-50%);
}
.journey-grid {
  position: absolute;
  inset: 2rem 0 0;
  pointer-events: none;
}
.journey-grid i {
  position: absolute;
  top: 0;
  bottom: 0;
  left: var(--x);
  border-left: 1px dashed var(--rule);
}
.journey-now {
  position: absolute;
  top: 2rem;
  bottom: 0;
  left: var(--x);
  border-left: 2px solid var(--live);
}
.journey-now span {
  position: absolute;
  top: -1.6rem;
  right: 0.3rem;
  font-size: var(--step--2);
  font-weight: var(--weight-strong);
  color: var(--live);
  white-space: nowrap;
}
.journey-lane {
  position: relative;
  padding-block: 0.6rem;
}
.journey-lane-name {
  margin-bottom: 0.4rem;
  font-size: var(--step--1);
  color: var(--ink-faint);
}
.journey-track {
  position: relative;
  height: 1.7rem;
}
.journey-missions .journey-track {
  height: 8.2rem;
}
.journey-studies .journey-track {
  height: 3.6rem;
}
.journey-bar {
  position: absolute;
  top: calc(var(--row, 0) * 4rem);
  left: var(--x);
  width: var(--w);
  height: 1.9rem;
  border-radius: var(--radius-s);
  background: var(--ink-soft);
  transform-origin: left center;
  animation: journey-grow var(--motion-reveal) cubic-bezier(0.2, 0.7, 0.2, 1) both;
  animation-delay: calc(var(--i, 0) * var(--motion-stagger));
}
.journey-bar.is-freelance {
  background: var(--gopher);
}
.journey-bar.is-study {
  background: var(--gopher-wash);
}
.journey-label {
  position: absolute;
  top: calc(var(--row, 0) * 4rem + 2.15rem);
  left: var(--x);
  font-size: var(--step--2);
  line-height: var(--leading-snug);
  color: var(--ink-soft);
  white-space: nowrap;
}
.journey-label b {
  display: block;
  font-size: var(--step--1);
  font-weight: var(--weight-strong);
  color: var(--ink);
}
.journey-cert {
  position: absolute;
  top: 0.35rem;
  left: var(--x);
  width: 0.9rem;
  height: 0.9rem;
  border: 2px solid var(--gopher);
  border-radius: var(--radius-round);
  background: var(--paper);
  transform: translateX(-50%);
}
.journey-tech-name {
  position: absolute;
  top: 0.05rem;
  right: calc(100% - var(--x));
  padding-right: 0.6rem;
  font-size: var(--step--1);
  font-weight: var(--weight-strong);
  white-space: nowrap;
}
.journey-line {
  position: absolute;
  top: 0.5rem;
  left: var(--x);
  width: var(--w);
  height: 0.6rem;
  border-radius: var(--radius-pill);
  background: var(--gopher);
  opacity: 0.45;
  transform-origin: left center;
  animation: journey-grow var(--motion-reveal) cubic-bezier(0.2, 0.7, 0.2, 1) both;
  animation-delay: calc(var(--i, 0) * var(--motion-stagger) + var(--motion-reveal) / 2);
}
.journey-project {
  position: absolute;
  top: 0.3rem;
  left: var(--x);
  width: var(--w);
  min-width: 0.5rem;
  height: 1.1rem;
  border: 2px solid var(--gopher);
  border-radius: var(--radius-s);
  transform-origin: left center;
  animation: journey-grow var(--motion-reveal) cubic-bezier(0.2, 0.7, 0.2, 1) both;
  animation-delay: calc(var(--i, 0) * var(--motion-stagger));
}
@keyframes journey-grow {
  from {
    transform: scaleX(0);
  }
}
.journey-readings {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2rem;
  padding-block: 2rem 4rem;
  border-top: 1px solid var(--rule);
}
.journey-readings h2 {
  font-size: var(--step-2);
  letter-spacing: var(--tracking-heading);
}
.journey-readings p {
  margin-top: 0.6rem;
  color: var(--ink-soft);
}
.journey-list-title {
  margin-block: 2.5rem 1rem;
  font-size: var(--step-2);
  letter-spacing: var(--tracking-heading);
}
.journey-list {
  margin: 0;
  padding: 0;
  list-style: none;
  border-top: 1px solid var(--rule);
}
.journey-list li {
  display: grid;
  grid-template-columns: 12rem 9rem minmax(0, 1fr);
  gap: 0.25rem 1.5rem;
  padding-block: 0.9rem;
  border-bottom: 1px solid var(--rule);
}
.journey-list-bar {
  display: none;
}
.journey-list-period {
  font-size: var(--step--1);
  font-variant-numeric: tabular-nums;
  color: var(--ink-faint);
}
.journey-list b {
  font-weight: var(--weight-strong);
}
.journey-list-summary {
  color: var(--ink-soft);
}
.journey-cv {
  margin-block: 2rem 4rem;
}
@media (max-width: 1100px) {
  .journey-label span {
    display: none;
  }
}
@media (max-width: 760px) {
  .journey-axis span:nth-child(even),
  .journey-grid i:nth-child(even) {
    display: none;
  }
  .journey-missions {
    display: none;
  }
  .journey-readings {
    grid-template-columns: 1fr;
  }
  .journey-list li {
    grid-template-columns: 0.5rem minmax(0, 1fr);
    gap: 0.15rem 1rem;
  }
  .journey-list-bar {
    display: block;
    grid-row: 1 / span 3;
    min-height: max(2.5rem, calc(var(--years) * 1.6rem));
    border-radius: var(--radius-pill);
    background: var(--ink-soft);
  }
  .journey-list .is-freelance .journey-list-bar {
    background: var(--gopher);
  }
  .journey-list.is-projects .journey-list-bar {
    border: 2px solid var(--gopher);
    background: transparent;
  }
}

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

@media print {
  @page {
    margin: 14mm 12mm;
  }

  :root {
    --paper: #fff;
    --ink: #000;
    --ink-soft: #222;
    --ink-faint: #555;
    --rule: #ccc;
  }

  body {
    font-size: var(--step-print);
  }

  .site-header,
  .site-footer,
  .cv-actions,
  .skip-link {
    display: none !important;
  }

  .cv-head {
    padding-top: 0;
    grid-template-columns: 6rem minmax(0, 1fr);
  }

  .cv-head img {
    width: 6rem;
  }

  .cv-layout {
    grid-template-columns: 14rem minmax(0, 1fr);
    gap: 2rem;
  }

  a {
    text-decoration: none;
  }
}
