@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces-var.woff2") format("woff2");
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Fraunces";
  src: url("../fonts/fraunces-italic-var.woff2") format("woff2");
  font-weight: 100 900;
  font-style: italic;
  font-display: swap;
}

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

@font-face {
  font-family: "Atkinson Hyperlegible";
  src: url("../fonts/atkinson-400i.woff2") format("woff2");
  font-weight: 400;
  font-style: italic;
  font-display: swap;
}

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

:root {
  --paper: #f2eee6;
  --paper-raised: #f8f5ef;
  --ink: #1c1916;
  --copper: #b5532f;
  --copper-deep: #8f3f22;
  --muted: color-mix(in srgb, var(--ink) 64%, var(--paper));
  --faint: color-mix(in srgb, var(--ink) 38%, var(--paper));
  --rule: color-mix(in srgb, var(--ink) 14%, transparent);
  --rule-strong: color-mix(in srgb, var(--ink) 28%, transparent);
  --display: "Fraunces", "Palatino Linotype", Palatino, serif;
  --body: "Atkinson Hyperlegible", "Segoe UI", sans-serif;
  --measure: 40rem;
  --page: 74rem;
}

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

html {
  font-size: 112.5%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  background-color: var(--paper);
  background-image:
    radial-gradient(circle at 1px 1px, color-mix(in srgb, var(--ink) 7%, transparent) 1px, transparent 0);
  background-size: 11px 11px;
  font-family: var(--body);
  font-weight: 400;
  line-height: 1.55;
  text-rendering: optimizeLegibility;
}

::selection {
  background: var(--copper);
  color: var(--paper);
}

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

a {
  color: var(--copper);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.18em;
  transition: color 120ms ease;
}

a:hover {
  color: var(--copper-deep);
  text-decoration-thickness: 2px;
}

a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--copper);
  outline-offset: 3px;
}

h1,
h2,
h3 {
  font-family: var(--display);
  font-weight: 520;
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin: 0;
}

.skip {
  position: absolute;
  left: 0.75rem;
  top: -3rem;
  z-index: 20;
  padding: 0.4rem 0.7rem;
  background: var(--ink);
  color: var(--paper);
  text-decoration: none;
}

.skip:focus {
  top: 0.75rem;
}

.wrap {
  width: min(var(--page), calc(100% - 2.4rem));
  margin: 0 auto;
}

/* ---------- header ---------- */

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.35rem 0 1.2rem;
  border-bottom: 1px solid var(--rule-strong);
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  color: inherit;
  text-decoration: none;
}

.brand:hover {
  color: inherit;
}

.brand img {
  width: 2.05rem;
  height: 2.05rem;
  flex: 0 0 auto;
  transition: transform 220ms ease;
}

.brand:hover img {
  transform: rotate(-6deg);
}

.wordmark {
  font-family: var(--display);
  font-size: 1.42rem;
  font-weight: 520;
  font-variation-settings: "opsz" 72, "SOFT" 40, "WONK" 1;
  letter-spacing: -0.02em;
  line-height: 1;
}

.wordmark em {
  font-style: italic;
  font-weight: 480;
  color: var(--copper);
  font-variation-settings: "opsz" 72, "SOFT" 60, "WONK" 1;
}

.nav {
  display: flex;
  gap: 1.3rem;
}

.nav a {
  position: relative;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
  padding: 0.15rem 0;
}

.nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: -0.1rem;
  height: 2px;
  background: var(--copper);
  transition: right 160ms ease;
}

.nav a:hover::after,
.nav a[aria-current="page"]::after {
  right: 0;
}

.nav a[aria-current="page"] {
  color: var(--copper);
}

/* ---------- shared blocks ---------- */

main {
  padding: 0 0 4rem;
}

.hero {
  padding: 4.2rem 0 3.6rem;
}

.hero-tight {
  padding: 3.2rem 0 2.6rem;
}

.lede {
  max-width: 24ch;
  margin: 0 0 1.2rem;
  font-size: clamp(2.5rem, 7vw, 4.9rem);
  font-weight: 500;
  font-variation-settings: "opsz" 144, "SOFT" 30, "WONK" 1;
  line-height: 0.98;
  letter-spacing: -0.035em;
  text-wrap: balance;
}

.lede em {
  font-style: italic;
  font-weight: 460;
  color: var(--copper);
  font-variation-settings: "opsz" 144, "SOFT" 60, "WONK" 1;
}

.lede-body {
  margin: 0;
  max-width: var(--measure);
  font-size: 1.18rem;
  line-height: 1.55;
  color: var(--muted);
}

.lede-body a {
  color: var(--copper);
}

.kicker {
  margin: 0 0 1rem;
  color: var(--copper);
  font-weight: 700;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.hero-cta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.3rem;
  margin: 2rem 0 0;
}

.button {
  display: inline-block;
  padding: 0.7rem 1.35rem;
  background: var(--ink);
  color: var(--paper);
  font-weight: 700;
  font-size: 0.95rem;
  text-decoration: none;
  border: 1px solid var(--ink);
  transition: background 140ms ease, border-color 140ms ease;
}

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

.quiet-link {
  font-weight: 700;
  font-size: 0.95rem;
}

/* ---------- numbered bands ---------- */

.band {
  padding: 3rem 0;
  border-top: 1px solid var(--rule-strong);
}

.band-head {
  display: flex;
  align-items: baseline;
  gap: 1rem;
  margin: 0 0 1.8rem;
}

.band-head .index {
  font-family: var(--display);
  font-style: italic;
  font-size: 1.05rem;
  color: var(--copper);
  font-variation-settings: "opsz" 36, "SOFT" 50, "WONK" 1;
}

.band-head h2 {
  font-size: clamp(1.6rem, 3.4vw, 2.2rem);
  font-variation-settings: "opsz" 72, "SOFT" 25, "WONK" 1;
}

.duo {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 2.4rem;
  max-width: 62rem;
}

.duo h3,
.split h3 {
  margin: 0 0 0.55rem;
  font-size: 1.55rem;
  font-variation-settings: "opsz" 36, "SOFT" 20, "WONK" 1;
}

.duo p,
.split p,
.prose p,
.steps p {
  margin: 0 0 0.9rem;
  max-width: var(--measure);
  color: var(--muted);
}

.duo p:last-child,
.split p:last-child,
.prose p:last-child,
.steps p:last-child {
  margin-bottom: 0;
}

.split {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0;
}

.split article {
  padding: 0 1.5rem 0 0;
  margin-right: 1.5rem;
  border-right: 1px solid var(--rule);
}

.split article:last-child {
  margin-right: 0;
  padding-right: 0;
  border-right: 0;
}

.steps {
  list-style: none;
  counter-reset: step;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 1.7rem;
  max-width: 46rem;
}

.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 3.4rem;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: -0.25rem;
  font-family: var(--display);
  font-style: italic;
  font-size: 2.1rem;
  font-weight: 480;
  color: var(--copper);
  font-variation-settings: "opsz" 72, "SOFT" 50, "WONK" 1;
}

.steps h3 {
  margin: 0 0 0.3rem;
  font-size: 1.3rem;
  font-variation-settings: "opsz" 36, "SOFT" 20, "WONK" 1;
}

.plain-list {
  list-style: none;
  margin: 0;
  padding: 0;
  max-width: var(--measure);
  display: grid;
  gap: 0.75rem;
}

.plain-list li {
  position: relative;
  padding-left: 1.5rem;
  color: var(--muted);
}

.plain-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.72em;
  width: 0.75rem;
  height: 2px;
  background: var(--copper);
}

.prose {
  max-width: var(--measure);
}

.entry-title {
  margin: 0 0 0.5rem;
  font-size: 1.55rem;
  font-variation-settings: "opsz" 36, "SOFT" 20, "WONK" 1;
}

.after-list {
  margin-top: 1.4rem;
}

/* ---------- closer + email ---------- */

.closer {
  padding: 3.4rem 0 0.6rem;
  border-top: 1px solid var(--rule-strong);
}

.closer-line {
  margin: 0 0 1.4rem;
  max-width: 34rem;
  font-family: var(--display);
  font-size: clamp(1.35rem, 2.8vw, 1.8rem);
  font-weight: 500;
  font-variation-settings: "opsz" 48, "SOFT" 25, "WONK" 1;
  line-height: 1.25;
  letter-spacing: -0.015em;
  text-wrap: balance;
}

.email-block {
  margin: 0;
}

.email-block a {
  font-family: var(--display);
  font-size: clamp(1.45rem, 4vw, 2.15rem);
  font-weight: 500;
  font-variation-settings: "opsz" 48, "SOFT" 35, "WONK" 0;
  text-decoration-thickness: 1px;
  overflow-wrap: anywhere;
}

.contact-panel {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.4rem;
  margin: 0 0 1rem;
  padding: 1.8rem 2rem;
  border: 1px solid var(--rule-strong);
  background: var(--paper-raised);
}

.email-hero a {
  font-size: clamp(1.6rem, 4.6vw, 2.6rem);
}

.copy-button {
  padding: 0.55rem 1rem;
  border: 1px solid var(--rule-strong);
  background: transparent;
  color: var(--ink);
  font-family: var(--body);
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  transition: border-color 140ms ease, color 140ms ease;
}

.copy-button:hover {
  border-color: var(--copper);
  color: var(--copper);
}

/* ---------- footer ---------- */

.site-footer {
  padding: 1.6rem 0 2.4rem;
  border-top: 1px solid var(--rule-strong);
  color: var(--muted);
  font-size: 0.92rem;
}

.site-footer .wrap {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.9rem 1.4rem;
}

.foot-brand {
  display: flex;
  align-items: baseline;
  gap: 0.8rem;
}

.site-footer .wordmark {
  font-size: 1.05rem;
}

.foot-note {
  color: var(--faint);
}

.foot-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.3rem;
}

.foot-nav a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 700;
}

.foot-nav a:hover {
  color: var(--copper);
  text-decoration: underline;
  text-underline-offset: 0.22em;
}

.lost .lede-body a {
  font-weight: 700;
}

/* ---------- motion ---------- */

@media (prefers-reduced-motion: no-preference) {
  .hero > * {
    animation: rise 560ms cubic-bezier(0.2, 0.7, 0.2, 1) both;
  }

  .hero > *:nth-child(2) {
    animation-delay: 70ms;
  }

  .hero > *:nth-child(3) {
    animation-delay: 140ms;
  }

  .hero > *:nth-child(4) {
    animation-delay: 210ms;
  }

  html.js-anim .band,
  html.js-anim .closer,
  html.js-anim .contact-panel {
    opacity: 0;
    transform: translateY(14px);
    transition: opacity 480ms ease, transform 480ms cubic-bezier(0.2, 0.7, 0.2, 1);
  }

  html.js-anim .band.in,
  html.js-anim .closer.in,
  html.js-anim .contact-panel.in {
    opacity: 1;
    transform: none;
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(16px);
  }

  to {
    opacity: 1;
    transform: none;
  }
}

/* ---------- breakpoints ---------- */

@media (max-width: 860px) {
  .duo {
    grid-template-columns: 1fr;
    gap: 1.7rem;
  }

  .split {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .split article {
    margin: 0;
    padding: 0 0 1.5rem;
    border-right: 0;
    border-bottom: 1px solid var(--rule);
  }

  .split article:last-child {
    padding-bottom: 0;
    border-bottom: 0;
  }
}

@media (max-width: 560px) {
  html {
    font-size: 100%;
  }

  .wrap {
    width: min(var(--page), calc(100% - 1.6rem));
  }

  .site-header {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.85rem;
  }

  .hero {
    padding: 3rem 0 2.6rem;
  }

  .contact-panel {
    padding: 1.3rem 1.2rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .brand img {
    transition: none;
  }
}
