:root {
  color-scheme: dark;
  --ink: #101315;
  --raised: #171b1e;
  --raised-soft: #1d2225;
  --paper: #f1ece2;
  --muted: #aaa79f;
  --line: #343a3d;
  --line-strong: #555c5f;
  --copper: #c78b4d;
  --copper-light: #e0ad72;
  --blue: #6fa4bc;
  --blue-light: #a2cadb;
  --green: #78a981;
  --measure: 1240px;
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { background: var(--ink); scroll-behavior: smooth; }
body {
  margin: 0;
  min-width: 320px;
  min-height: 100vh;
  color: var(--paper);
  background:
    linear-gradient(rgb(255 255 255 / 0.025) 1px, transparent 1px),
    linear-gradient(90deg, rgb(255 255 255 / 0.025) 1px, transparent 1px),
    var(--ink);
  background-size: 64px 64px;
  font-size: 16px;
  line-height: 1.55;
}

a { color: inherit; }
a:hover { color: var(--copper-light); }
a:focus-visible,
button:focus-visible { outline: 3px solid var(--copper-light); outline-offset: 4px; }

.site-shell { width: min(calc(100% - 36px), var(--measure)); margin: 0 auto; }
.site-header {
  display: flex;
  gap: 24px;
  align-items: center;
  justify-content: space-between;
  min-height: 84px;
  border-bottom: 1px solid var(--line-strong);
}
.wordmark {
  color: var(--paper);
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.35rem;
  letter-spacing: .08em;
  text-decoration: none;
  white-space: nowrap;
}
.site-nav { display: flex; flex-wrap: wrap; gap: 7px 22px; justify-content: flex-end; }
.site-nav a {
  color: var(--muted);
  font-size: .76rem;
  letter-spacing: .11em;
  text-decoration: none;
  text-transform: uppercase;
}
.site-nav a[aria-current="page"] { color: var(--copper-light); }

.eyebrow,
.section-kicker,
.label {
  color: var(--copper-light);
  font-size: .7rem;
  font-weight: 700;
  letter-spacing: .17em;
  text-transform: uppercase;
}
.eyebrow,
.section-kicker { margin: 0 0 .8rem; }
h1,
h2,
h3,
p,
dl,
figure { margin-top: 0; }
h1,
.display {
  font-family: Georgia, "Times New Roman", serif;
  font-weight: 400;
  letter-spacing: -.035em;
}
h1 { max-width: 14ch; margin-bottom: 1.25rem; font-size: clamp(3rem, 8vw, 7.3rem); line-height: .92; }
h2 { margin-bottom: 1rem; font-family: Georgia, "Times New Roman", serif; font-size: clamp(1.65rem, 4vw, 3rem); font-weight: 400; line-height: 1.05; }
h3 { margin-bottom: .55rem; font-size: 1rem; }
.lede { max-width: 56ch; color: #d5d0c7; font-size: clamp(1.08rem, 2vw, 1.4rem); }
.muted { color: var(--muted); }
.mono { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; overflow-wrap: anywhere; }

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(310px, .75fr);
  gap: clamp(36px, 8vw, 110px);
  align-items: end;
  min-height: calc(100vh - 84px);
  padding: clamp(64px, 10vw, 140px) 0 70px;
}
.hero-copy { align-self: center; }
.hero-note { max-width: 54ch; margin: 2rem 0 0; color: var(--muted); }
.result-card {
  position: relative;
  padding: 30px;
  border: 1px solid var(--line-strong);
  background: rgb(23 27 30 / 88%);
}
.result-card::before {
  position: absolute;
  top: -1px;
  left: -1px;
  width: 42%;
  border-top: 2px solid var(--copper);
  content: "";
}
.route-path { margin: 0 0 1.6rem; font-family: Georgia, "Times New Roman", serif; font-size: clamp(1.7rem, 4vw, 2.7rem); }
.result-summary { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin: 0; }
.result-summary div { padding-top: 12px; border-top: 1px solid var(--line); }
.result-summary dt,
.provenance dt,
.facts dt { color: var(--muted); font-size: .66rem; letter-spacing: .1em; text-transform: uppercase; }
.result-summary dd,
.provenance dd,
.facts dd { margin: 4px 0 0; }
.result-summary dd { font-size: 1.02rem; }

.section { padding: clamp(70px, 10vw, 130px) 0; border-top: 1px solid var(--line); }
.section-heading { display: grid; grid-template-columns: .7fr 1.3fr; gap: 42px; margin-bottom: 44px; }
.section-heading p { max-width: 58ch; color: var(--muted); }
.metric-grid { display: grid; grid-template-columns: repeat(4, 1fr); border: 1px solid var(--line); }
.metric { min-height: 150px; padding: 24px; border-right: 1px solid var(--line); }
.metric:nth-child(4n) { border-right: 0; }
.metric .value { margin: .7rem 0 .2rem; font-family: Georgia, "Times New Roman", serif; font-size: clamp(1.7rem, 3vw, 2.7rem); line-height: 1; }
.metric .unit { color: var(--muted); font-size: .78rem; }
.two-column { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(30px, 6vw, 86px); }
.facts,
.provenance { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px 30px; margin: 0; }
.facts div,
.provenance div { min-width: 0; padding-top: 13px; border-top: 1px solid var(--line); }
.facts dd,
.provenance dd { overflow-wrap: anywhere; }
.callout { padding: 25px; border-left: 3px solid var(--blue); background: var(--raised); }
.callout p:last-child { margin-bottom: 0; }
.button-link {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 16px;
  border: 1px solid var(--copper);
  color: var(--paper);
  text-decoration: none;
}
.button-link:hover { border-color: var(--copper-light); color: var(--ink); background: var(--copper-light); }
.text-link { color: var(--blue-light); text-underline-offset: 4px; }

.page-intro { max-width: 850px; padding: clamp(70px, 10vw, 130px) 0 70px; }
.page-intro h1 { max-width: 12ch; font-size: clamp(3.2rem, 8vw, 6rem); }
.card-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 18px; }
.research-card { min-height: 280px; padding: 26px; border: 1px solid var(--line); background: rgb(23 27 30 / 72%); }
.research-card h2 { font-size: 1.7rem; }
.research-card p { color: var(--muted); }

.window-key { display: flex; flex-wrap: wrap; gap: 10px 20px; margin-bottom: 18px; color: var(--muted); font-size: .75rem; }
.window-key span::before { display: inline-block; width: 9px; height: 9px; margin-right: 7px; background: var(--key); content: ""; }
.window-grid { display: grid; grid-template-columns: repeat(12, minmax(12px, 1fr)); gap: 4px; }
.window-month { aspect-ratio: 1; border: 0; background: var(--line); }
.window-month.direct { background: var(--blue); }
.window-month.earth_jupiter_titan { background: var(--copper); }
.window-month.earth_venus_earth_titan { background: var(--green); }
.window-month:focus-visible { outline-offset: 2px; }
.survey-caption { margin: 18px 0 0; color: var(--muted); }
.year-table { width: 100%; border-collapse: collapse; font-variant-numeric: tabular-nums; }
.year-table th,
.year-table td { padding: 11px 9px; border-bottom: 1px solid var(--line); text-align: left; }
.year-table th { color: var(--muted); font-size: .68rem; letter-spacing: .08em; text-transform: uppercase; }
.table-wrap { overflow-x: auto; }
.table-toolbar {
  display: grid;
  grid-template-columns: auto minmax(250px, 380px) minmax(260px, 1fr);
  gap: 12px 18px;
  align-items: center;
  margin-bottom: 22px;
  padding: 18px;
  border: 1px solid var(--line);
  background: rgb(23 27 30 / 72%);
}
.table-toolbar label {
  color: var(--muted);
  font-size: .68rem;
  font-weight: 700;
  letter-spacing: .1em;
  text-transform: uppercase;
}
.table-toolbar select {
  width: 100%;
  min-height: 42px;
  padding: 8px 34px 8px 11px;
  border: 1px solid var(--line-strong);
  border-radius: 2px;
  color: var(--paper);
  background: var(--raised-soft);
  font: inherit;
}
.table-toolbar select:focus-visible { outline: 3px solid var(--copper-light); outline-offset: 3px; }
.table-toolbar p { margin: 0; color: var(--muted); font-size: .82rem; }
.no-family-result { color: var(--muted); font-style: italic; }

.method-list { display: grid; gap: 0; }
.method-step { display: grid; grid-template-columns: 48px 1fr; gap: 18px; padding: 23px 0; border-top: 1px solid var(--line); }
.method-step .number { color: var(--copper-light); font-family: Georgia, serif; font-size: 1.5rem; }
.limitations { margin: 0; padding-left: 1.15rem; }
.limitations li { margin: .45rem 0; }

.site-footer { padding: 34px 0 45px; border-top: 1px solid var(--line-strong); color: var(--muted); font-size: .78rem; }
.site-footer p { max-width: 88ch; margin-bottom: .35rem; }
.loading-error { padding: 14px; border-left: 3px solid #d27b70; background: var(--raised); }
.not-found { display: grid; place-items: center; min-height: 100vh; text-align: center; }
.not-found h1 { max-width: none; margin-bottom: 1rem; font-size: clamp(3rem, 10vw, 7rem); }

@media (max-width: 900px) {
  .hero { grid-template-columns: 1fr; min-height: auto; }
  .hero-copy { padding-top: 30px; }
  .section-heading { grid-template-columns: 1fr; gap: 8px; }
  .metric-grid { grid-template-columns: repeat(2, 1fr); }
  .metric:nth-child(2n) { border-right: 0; }
  .card-grid { grid-template-columns: 1fr; }
}

@media (max-width: 620px) {
  body { background-size: 42px 42px; }
  .site-header { flex-direction: column; align-items: flex-start; gap: 14px; padding: 20px 0; }
  .site-nav { justify-content: flex-start; }
  .site-nav { gap: 6px 13px; }
  .site-nav a { font-size: .68rem; }
  .hero { padding-top: 74px; }
  .result-card { padding: 22px; }
  .result-summary,
  .facts,
  .provenance,
  .two-column { grid-template-columns: 1fr; }
  .metric-grid { grid-template-columns: 1fr; }
  .metric { min-height: 125px; border-right: 0; }
  .window-grid { gap: 3px; }
  .table-toolbar { grid-template-columns: 1fr; }
  .page-intro { padding-top: 60px; }
}

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