:root {
  --paper: #f2ecdf;
  --paper-deep: #e9e0cf;
  --ink: #263229;
  --muted: #697168;
  --rule: #cbc2b2;
  --accent: #b9633f;
  --header-bg: rgba(242, 236, 223, .82);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "DM Mono", monospace;
  font-weight: 300;
  min-height: 100vh;
}

a { color: inherit; }
button { font: inherit; }

.grain {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 20;
  opacity: .18;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 180 180' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.12'/%3E%3C/svg%3E");
}

.skip-link {
  position: fixed;
  top: .8rem;
  left: .8rem;
  z-index: 100;
  padding: .7rem 1rem;
  background: var(--ink);
  color: var(--paper);
  transform: translateY(-180%);
}
.skip-link:focus { transform: translateY(0); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 70px;
  padding: 0 clamp(1.25rem, 4vw, 4.5rem);
  border-bottom: 1px solid color-mix(in srgb, var(--rule) 72%, transparent);
  background: var(--header-bg);
  backdrop-filter: blur(16px);
}

.wordmark {
  font-size: .78rem;
  font-weight: 400;
  letter-spacing: .12em;
  text-decoration: none;
  text-transform: lowercase;
}

.theme-picker {
  display: flex;
  gap: .2rem;
  padding: .2rem;
  border: 1px solid var(--rule);
  border-radius: 999px;
}
.theme-button {
  appearance: none;
  border: 0;
  border-radius: 999px;
  padding: .42rem .72rem;
  background: transparent;
  color: var(--muted);
  font-size: .65rem;
  cursor: pointer;
}
.theme-button.active { background: var(--ink); color: var(--paper); }
.theme-button:focus-visible, a:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }

main { overflow: hidden; }
.intro {
  position: relative;
  min-height: 59vh;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: clamp(5rem, 12vh, 9rem) clamp(1.25rem, 7vw, 8rem) clamp(4rem, 9vh, 7rem);
  border-bottom: 1px solid var(--rule);
  background:
    radial-gradient(circle at 76% 32%, color-mix(in srgb, var(--accent) 15%, transparent), transparent 28%),
    linear-gradient(135deg, transparent 0 68%, color-mix(in srgb, var(--rule) 36%, transparent) 68% 68.15%, transparent 68.15%);
}
.intro::after {
  content: "";
  position: absolute;
  width: clamp(12rem, 30vw, 30rem);
  aspect-ratio: 1;
  right: clamp(-9rem, -6vw, -2rem);
  top: clamp(3rem, 10vh, 7rem);
  border: 1px solid var(--rule);
  border-radius: 50%;
  opacity: .55;
}
.eyebrow, .group-number {
  margin: 0 0 1rem;
  color: var(--accent);
  font-size: .7rem;
  letter-spacing: .16em;
  text-transform: uppercase;
}
h1, h2, strong { font-family: "Newsreader", serif; }
.eyebrow {
  position: relative;
  z-index: 2;
  margin-bottom: clamp(2.25rem, 4vw, 4rem);
}
h1 {
  position: relative;
  z-index: 1;
  margin: 0;
  max-width: 7ch;
  font-size: clamp(5.5rem, 17vw, 13rem);
  font-weight: 300;
  line-height: .72;
  letter-spacing: -.055em;
}
.lede {
  margin: clamp(2rem, 4vw, 3.5rem) 0 0;
  color: var(--muted);
  font-size: clamp(.85rem, 1.1vw, 1rem);
}
.jump-link {
  width: max-content;
  margin-top: 2rem;
  padding-bottom: .35rem;
  border-bottom: 1px solid var(--ink);
  font-size: .72rem;
  text-decoration: none;
}
.jump-link span { margin-left: .6rem; color: var(--accent); }

.directory {
  width: min(1280px, 100%);
  margin: 0 auto;
  padding: 0 clamp(1.25rem, 5vw, 5rem);
}
.group {
  display: grid;
  grid-template-columns: minmax(180px, .62fr) minmax(0, 1.6fr);
  gap: clamp(2rem, 7vw, 7rem);
  padding: clamp(4rem, 8vw, 7rem) 0;
  border-bottom: 1px solid var(--rule);
}
.group-heading h2 {
  margin: 0;
  max-width: 9ch;
  font-size: clamp(2.2rem, 4vw, 4rem);
  font-weight: 300;
  line-height: .94;
  letter-spacing: -.035em;
}
.cards { border-top: 1px solid var(--ink); }
.card {
  position: relative;
  display: grid;
  grid-template-columns: 3.5rem minmax(0, 1fr) auto;
  align-items: center;
  gap: 1.25rem;
  min-height: 126px;
  padding: 1.35rem .35rem;
  border-bottom: 1px solid var(--rule);
  text-decoration: none;
  transition: padding .2s ease, background .2s ease;
}
.card:hover {
  padding-left: 1rem;
  padding-right: 1rem;
  background: color-mix(in srgb, var(--accent) 7%, transparent);
}
.card-mark {
  display: grid;
  place-items: center;
  width: 3.25rem;
  aspect-ratio: 1;
  border: 1px solid var(--rule);
  border-radius: 50%;
  color: var(--accent);
  font-size: .68rem;
  letter-spacing: .08em;
}
.card-copy { display: grid; gap: .38rem; }
.card strong {
  font-size: clamp(1.45rem, 2.4vw, 2rem);
  font-weight: 400;
  line-height: 1;
}
.card-copy > span {
  color: var(--muted);
  font-size: .7rem;
  line-height: 1.55;
}
.arrow {
  color: var(--accent);
  font-size: 1.15rem;
  transition: transform .2s ease;
}
.card:hover .arrow { transform: translate(3px, -3px); }

footer {
  display: flex;
  justify-content: space-between;
  gap: 2rem;
  padding: 2.5rem clamp(1.25rem, 5vw, 5rem);
  color: var(--muted);
  font-size: .65rem;
}
footer p { margin: 0; }
footer a { text-underline-offset: .3rem; }

body[data-theme="dark"] {
  --paper: #0d1117;
  --paper-deep: #121923;
  --ink: #f3eee3;
  --muted: #a7aba6;
  --rule: #384039;
  --accent: #f29a6f;
  --header-bg: rgba(13, 17, 23, .84);
  color-scheme: dark;
}
body[data-theme="dark"] .grain { opacity: .1; mix-blend-mode: screen; }

@media (max-width: 720px) {
  .site-header { min-height: 62px; }
  .theme-button { padding: .38rem .55rem; font-size: .58rem; }
  .intro { min-height: 52vh; }
  .group { grid-template-columns: 1fr; gap: 2rem; }
  .group-heading h2 { max-width: none; }
  .card { grid-template-columns: 2.9rem minmax(0, 1fr) auto; min-height: 110px; gap: .9rem; }
  .card-mark { width: 2.7rem; }
  .card strong { font-size: 1.35rem; }
  footer { flex-direction: column; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
