:root {
  --bg: #eeefe7;
  --text: #243b31;
  --muted: #607367;
  --accent: #78935d;
  --rule: #bac6b7;
  --panel: #e2e8db;
  --paper: #f5f5ed;
  --hero: #071b20;
  --hero-text: #e8eddb;
  --hero-accent: #c7dda8;
  --shadow: #203a3030;
}
html[data-theme="tokyo"] {
  --bg: #1a1b26;
  --text: #c0caf5;
  --muted: #9aa5ce;
  --accent: #7aa2f7;
  --rule: #414868;
  --panel: #24283b;
  --paper: #202331;
  --hero: #10162a;
  --hero-text: #e0e6ff;
  --hero-accent: #bbbcfa;
  --shadow: #090b1530;
}
html[data-theme="rose"] {
  --bg: #191724;
  --text: #e0def4;
  --muted: #aaa5be;
  --accent: #ebbcba;
  --rule: #524d65;
  --panel: #26233a;
  --paper: #211e30;
  --hero: #171624;
  --hero-text: #f3e4e6;
  --hero-accent: #ebbcba;
  --shadow: #0a071630;
}
html[data-theme="gruv"] {
  --bg: #282828;
  --text: #ebdbb2;
  --muted: #bdae93;
  --accent: #b8bb26;
  --rule: #665c54;
  --panel: #3c3836;
  --paper: #32302f;
  --hero: #20251e;
  --hero-text: #f1e4c0;
  --hero-accent: #d5d97b;
  --shadow: #15100b30;
}
* {
  box-sizing: border-box;
}
html {
  scroll-behavior: smooth;
}
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font:
    16px/1.6 "DM Sans",
    system-ui,
    sans-serif;
  transition:
    background 0.25s,
    color 0.25s;
}
a {
  color: inherit;
  text-decoration: none;
}
button {
  font: inherit;
}
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}
.skip {
  position: fixed;
  z-index: 100;
  left: 1rem;
  top: 1rem;
  padding: 0.7rem;
  background: var(--paper);
  transform: translateY(-200%);
}
.skip:focus {
  transform: none;
}
.eyebrow {
  font:
    10px/1.5 "DM Mono",
    monospace;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.masthead {
  height: 72px;
  position: absolute;
  z-index: 5;
  inset: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(24px, 5vw, 76px);
  color: #e8eddb;
  border-bottom: 1px solid #d5e3c52b;
}
.wordmark {
  font:
    700 21px "DM Sans",
    sans-serif;
  letter-spacing: -0.08em;
}
.wordmark span {
  font-size: 12px;
  color: #c7dda8;
  margin-left: 3px;
}
.masthead-label,
.nav-link {
  font:
    10px "DM Mono",
    monospace;
  letter-spacing: 0.09em;
}
.masthead-label {
  color: #d8e0ceaa;
}
.masthead-label span {
  padding: 0 8px;
  color: #b3d294;
}
.nav-link {
  border: 1px solid #e4efda66;
  padding: 10px 14px;
}
.nav-link:hover,
.hero-action:hover {
  background: #d8e8c8;
  color: #142b22;
}
.hero {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  min-height: 680px;
  height: 100svh;
  max-height: 1100px;
  background: var(--hero);
  color: var(--hero-text);
}
#scene {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  image-rendering: pixelated;
}
.hero-shade {
  position: absolute;
  inset: 0;
  background:
    linear-gradient(
      90deg,
      rgba(5, 19, 22, 0.92),
      rgba(5, 19, 22, 0.68) 32%,
      rgba(5, 19, 22, 0.08) 72%
    ),
    linear-gradient(0deg, rgba(4, 16, 18, 0.75), transparent 25%);
  pointer-events: none;
}
.hero-content {
  position: absolute;
  top: 50%;
  left: clamp(35px, 10vw, 150px);
  transform: translateY(-42%);
  width: min(640px, 62vw);
}
.hero-kicker {
  color: #bfd8a8;
}
.status-dot {
  display: inline-block;
  width: 6px;
  height: 6px;
  background: #b5da8c;
  margin-right: 10px;
  border-radius: 50%;
  box-shadow: 0 0 12px #b5da8c;
}
.hero h1 {
  font:
    500 clamp(76px, 7vw, 96px)/0.78 "Newsreader",
    Georgia,
    serif;
  letter-spacing: -0.073em;
  margin: 27px 0 30px;
}
.hero h1 em {
  font-weight: 400;
  color: var(--hero-accent);
}
.hero-intro {
  color: #e0e6d7;
  font-size: 17px;
  max-width: 370px;
  line-height: 1.65;
}
.hero-action {
  display: inline-flex;
  justify-content: space-between;
  gap: 40px;
  border: 1px solid #dfebd777;
  padding: 13px 15px;
  margin-top: 22px;
  font:
    10px "DM Mono",
    monospace;
  letter-spacing: 0.08em;
  transition:
    background 0.2s,
    color 0.2s;
}
.hero-bottom {
  position: absolute;
  bottom: 26px;
  left: clamp(24px, 5vw, 76px);
  right: clamp(24px, 5vw, 76px);
  display: flex;
  justify-content: space-between;
  color: #d5e0cb99;
  font:
    9px "DM Mono",
    monospace;
  letter-spacing: 0.09em;
}
.page-layout {
  max-width: 1500px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  border-left: 1px solid var(--rule);
  border-right: 1px solid var(--rule);
}
.sidebar {
  border-right: 1px solid var(--rule);
}
.sidebar-inner {
  position: sticky;
  top: 0;
  min-height: 100vh;
  padding: 50px 25px 32px;
  display: flex;
  flex-direction: column;
}
.side-name {
  font:
    500 28px/0.95 "Newsreader",
    Georgia,
    serif;
  letter-spacing: -0.04em;
}
.side-name span,
.accent {
  color: var(--accent);
}
.side-description {
  font-size: 12px;
  line-height: 1.6;
  color: var(--muted);
  margin: 18px 0 0;
}
.side-nav {
  display: grid;
  gap: 17px;
  margin-top: 70px;
  font-size: 13px;
}
.side-nav a:hover,
.footer-links a:hover,
.text-link:hover {
  color: var(--accent);
}
.side-nav a span {
  font:
    10px "DM Mono",
    monospace;
  color: var(--muted);
  margin-right: 15px;
}
.sidebar-bottom {
  margin-top: auto;
  font-size: 12px;
  color: var(--muted);
  padding-top: 50px;
}
.content {
  min-width: 0;
  padding: 36px clamp(30px, 6vw, 100px) 80px;
}
.content-top {
  display: flex;
  justify-content: space-between;
  color: var(--muted);
  padding-bottom: 17px;
  border-bottom: 1px solid var(--rule);
}
.intro-section {
  padding: 100px 0 112px;
}
.section-label {
  color: var(--muted);
  margin: 0 0 22px;
}
.section-label span {
  color: var(--accent);
  margin-right: 16px;
}
.intro-section h2,
.section-heading h2 {
  font:
    500 clamp(48px, 5.5vw, 82px)/0.96 "Newsreader",
    Georgia,
    serif;
  letter-spacing: -0.055em;
  margin: 0;
}
.intro-section h2 em,
.section-heading h2 em {
  font-weight: 400;
  color: var(--accent);
}
.intro-columns {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10%;
  margin-top: 48px;
}
.intro-lead {
  font:
    400 clamp(23px, 2.4vw, 31px)/1.22 "Newsreader",
    Georgia,
    serif;
  letter-spacing: -0.025em;
  margin: 0;
}
.prose p {
  margin: 0 0 20px;
  color: var(--muted);
  font-size: 15px;
  line-height: 1.75;
}
.content-section {
  padding: 80px 0 100px;
  border-top: 1px solid var(--rule);
  scroll-margin-top: 30px;
}
.section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 55px;
}
.section-heading h2 {
  font-size: clamp(43px, 4.6vw, 68px);
}
.section-aside {
  max-width: 210px;
  font-size: 13px;
  line-height: 1.6;
  color: var(--muted);
  margin: 0;
}
.work-list {
  border-top: 1px solid var(--rule);
}
.work-item {
  display: grid;
  grid-template-columns: minmax(180px, 0.85fr) 1.5fr;
  gap: 40px;
  padding: 29px 0;
  border-bottom: 1px solid var(--rule);
}
.work-meta .eyebrow {
  color: var(--muted);
  display: block;
}
.work-name {
  display: block;
  margin-top: 9px;
  font-size: 12px;
  color: var(--accent);
  font-weight: 600;
}
.work-item h3 {
  font:
    500 28px/1.1 "Newsreader",
    Georgia,
    serif;
  margin: 0 0 10px;
  letter-spacing: -0.025em;
}
.work-item p {
  font-size: 14px;
  line-height: 1.7;
  color: var(--muted);
  max-width: 490px;
  margin: 0;
}
.featured-essay {
  display: flex;
  justify-content: space-between;
  gap: 25px;
  padding: clamp(25px, 4vw, 48px);
  background: var(--panel);
  border: 1px solid var(--rule);
  transition: background 0.2s;
}
.featured-essay:hover {
  background: var(--paper);
}
.featured-essay .eyebrow {
  color: var(--muted);
}
.featured-essay h3 {
  font:
    500 clamp(36px, 4vw, 56px)/0.98 "Newsreader",
    Georgia,
    serif;
  letter-spacing: -0.04em;
  margin: 27px 0 20px;
}
.featured-essay p {
  font-size: 14px;
  color: var(--muted);
  max-width: 390px;
  margin: 0;
}
.essay-arrow {
  font-size: 26px;
  color: var(--accent);
}
.text-link {
  display: inline-block;
  margin-top: 24px;
  font:
    10px "DM Mono",
    monospace;
  letter-spacing: 0.08em;
}
.site-footer {
  border-top: 1px solid var(--rule);
  padding-top: 33px;
  display: flex;
  justify-content: space-between;
  gap: 30px;
}
.site-footer .eyebrow {
  color: var(--muted);
}
.site-footer p:last-child {
  font:
    500 32px "Newsreader",
    Georgia,
    serif;
  margin: 0;
}
.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-content: start;
  gap: 22px;
  font:
    10px "DM Mono",
    monospace;
  letter-spacing: 0.06em;
  padding-top: 10px;
}
.theme-picker {
  position: fixed;
  z-index: 8;
  right: 18px;
  bottom: 18px;
  background: var(--paper);
  color: var(--text);
  border: 1px solid var(--rule);
  box-shadow: 0 6px 20px var(--shadow);
  display: flex;
  align-items: center;
  gap: 5px;
  padding: 7px 8px;
}
.theme-label {
  font:
    9px "DM Mono",
    monospace;
  color: var(--muted);
  padding: 0 7px;
}
.theme-picker button {
  padding: 4px;
  border: 1px solid transparent;
  background: transparent;
  cursor: pointer;
  line-height: 0;
}
.theme-picker button[aria-pressed="true"] {
  border-color: var(--text);
}
.theme-picker button span {
  display: block;
  width: 15px;
  height: 15px;
  background: #78935d;
}
.theme-picker button[data-theme-choice="tokyo"] span {
  background: #7aa2f7;
}
.theme-picker button[data-theme-choice="rose"] span {
  background: #ebbcba;
}
.theme-picker button[data-theme-choice="gruv"] span {
  background: #b8bb26;
}
@media (max-width: 800px) {
  .page-layout {
    grid-template-columns: 1fr;
    border: 0;
  }
  .sidebar {
    border-right: 0;
    border-bottom: 1px solid var(--rule);
  }
  .sidebar-inner {
    position: static;
    min-height: 0;
    padding: 22px 25px;
    display: flex;
    flex-direction: row;
    align-items: center;
    gap: 25px;
  }
  .side-name {
    font-size: 22px;
  }
  .side-description,
  .sidebar-bottom {
    display: none;
  }
  .side-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin: 0 0 0 auto;
  }
  .side-nav a span {
    display: none;
  }
  .content {
    padding: 30px 25px 100px;
  }
  .intro-section {
    padding: 70px 0 75px;
  }
  .content-section {
    padding: 65px 0 75px;
  }
  .hero-content {
    left: 30px;
    width: min(640px, 78vw);
  }
  .hero h1 {
    font-size: clamp(62px, 9vw, 72px);
  }
  .hero-shade {
    background:
      linear-gradient(
        90deg,
        rgba(5, 19, 22, 0.9),
        rgba(5, 19, 22, 0.64) 50%,
        rgba(5, 19, 22, 0.1)
      ),
      linear-gradient(0deg, rgba(4, 16, 18, 0.72), transparent 30%);
  }
  .masthead-label {
    display: none;
  }
  .hero-bottom span:nth-child(2) {
    display: none;
  }
}
@media (max-width: 520px) {
  .hero {
    min-height: 640px;
  }
  .hero-content {
    width: 80vw;
    top: 46%;
    left: 24px;
  }
  .hero h1 {
    font-size: clamp(46px, 13vw, 64px);
  }
  .hero-intro {
    font-size: 15px;
    max-width: 295px;
  }
  .hero-bottom {
    left: 24px;
    right: 24px;
    font-size: 8px;
  }
  .side-nav {
    font-size: 12px;
    gap: 12px;
  }
  .content-top span:last-child {
    display: none;
  }
  .intro-columns {
    grid-template-columns: 1fr;
    gap: 25px;
  }
  .intro-columns {
    margin-top: 30px;
  }
  .section-heading {
    display: block;
    margin-bottom: 35px;
  }
  .section-aside {
    margin-top: 20px;
    max-width: 320px;
  }
  .work-item {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  .work-item h3 {
    font-size: 25px;
  }
  .site-footer {
    display: block;
  }
  .footer-links {
    margin-top: 25px;
  }
  .theme-label {
    display: none;
  }
}
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *:before,
  *:after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
