:root {
  --ink: #171814;
  --muted: #66685f;
  --line: #d9d9d1;
  --paper: #f5f4ec;
  --card: #fffef8;
  --accent: #294e3b;
  --accent-light: #dce8df;
  --highlight: #f0df66;
  --error: #9f2d20;
  color: var(--ink);
  background: var(--paper);
  font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-synthesis: none;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body { margin: 0; min-height: 100vh; }
a { color: inherit; text-underline-offset: 3px; }
button, input, textarea { font: inherit; }

.site-header,
footer {
  display: flex;
  align-items: center;
  max-width: 1180px;
  margin: 0 auto;
  padding: 24px 32px;
}

.site-header { justify-content: space-between; }
.site-header nav { display: flex; align-items: center; gap: 22px; }
.wordmark { font-size: 20px; font-weight: 750; letter-spacing: -0.04em; text-decoration: none; }
.highlight {
  padding: 0.08em 0.12em;
  border-radius: 0.04em;
  color: inherit;
  background: var(--highlight);
}
.quiet-link { color: var(--muted); font-size: 14px; }
.header-button {
  padding: 9px 13px;
  border-radius: 2px;
  color: #fff;
  background: var(--accent);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}
main { max-width: 1180px; margin: 0 auto; padding: 70px 32px 120px; }
.intro { max-width: 820px; margin-bottom: 70px; }

.eyebrow {
  margin: 0 0 10px;
  color: var(--accent);
  font-size: 12px;
  font-weight: 750;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

h1 {
  margin: 0;
  max-width: 780px;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(48px, 7vw, 84px);
  font-weight: 400;
  letter-spacing: -0.055em;
  line-height: 0.98;
}

.lede {
  max-width: 720px;
  margin: 30px 0 0;
  color: var(--muted);
  font-size: clamp(17px, 2vw, 20px);
  line-height: 1.55;
}

.project-intro { max-width: 900px; margin-bottom: 110px; }
.project-intro h1 { max-width: 900px; }
.try-intro { margin-bottom: 70px; }
.hero-actions { display: flex; align-items: center; gap: 22px; margin-top: 34px; }
.primary-link, .secondary-link {
  display: inline-block;
  font-size: 14px;
  font-weight: 700;
}
.primary-link {
  padding: 13px 17px;
  border-radius: 2px;
  color: #fff;
  background: var(--accent);
  text-decoration: none;
}
.secondary-link { color: var(--muted); }

.project-section {
  padding: 90px 0;
  border-top: 1px solid var(--line);
}
.section-heading { max-width: 690px; margin-bottom: 42px; }
.section-heading h2, .closing-section h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(34px, 5vw, 58px);
  font-weight: 400;
  letter-spacing: -0.045em;
  line-height: 1.03;
}
.section-heading > p:last-child {
  margin: 20px 0 0;
  color: var(--muted);
  font-size: 17px;
  line-height: 1.55;
}
.metric-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border: 1px solid var(--line);
  background: var(--card);
}
.metric-grid article { min-height: 255px; padding: 30px; }
.metric-grid article + article { border-left: 1px solid var(--line); }
.metric-value {
  display: block;
  margin-bottom: 54px;
  color: var(--accent);
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(44px, 5vw, 68px);
  letter-spacing: -0.055em;
}
.metric-grid h3 { font-size: 15px; }
.metric-grid p, .scope-note, .split-content p {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.55;
}
.scope-note { max-width: 760px; margin: 22px 0 0; }
.split-content {
  display: grid;
  grid-template-columns: 0.8fr 1.2fr;
  gap: 80px;
  align-items: start;
}
.split-content > div p { margin: 0 0 24px; font-size: 16px; }
.step-list { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--line); }
.step-list li {
  display: grid;
  grid-template-columns: 45px 1fr;
  gap: 16px;
  padding: 18px 0;
  border-bottom: 1px solid var(--line);
  font-size: 15px;
}
.step-list span { color: var(--accent); font-family: ui-monospace, monospace; font-size: 11px; }
.resource-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.resource-grid a {
  display: flex;
  flex-direction: column;
  min-height: 190px;
  padding: 24px;
  border: 1px solid var(--line);
  background: var(--card);
  text-decoration: none;
  transition: border-color 120ms, transform 120ms;
}
.resource-grid a:hover { border-color: var(--accent); transform: translateY(-2px); }
.resource-grid span { color: var(--accent); font-size: 11px; font-weight: 750; letter-spacing: 0.08em; text-transform: uppercase; }
.resource-grid strong { margin-top: auto; font-size: 17px; line-height: 1.35; }
.people-section { padding-bottom: 70px; }
.people-section .section-heading { margin-bottom: 30px; }
.people-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 48px; max-width: 900px; }
.people-grid p { margin: 0; color: var(--muted); font-size: 14px; line-height: 1.6; }
.people-grid strong { color: var(--ink); }
.closing-section { padding: 100px 0 20px; border-top: 1px solid var(--line); }
.closing-section h2 { margin-bottom: 30px; }

.workspace { max-width: 960px; }
.screen-form, .report-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 3px;
  box-shadow: 0 12px 35px rgb(24 30 21 / 5%);
}

.screen-form { padding: 30px; }
.form-heading, .form-footer, .results-heading, .report-heading, .report-heading > div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

h2, h3 { margin: 0; letter-spacing: -0.025em; }
h2 { font-size: 24px; }
h3 { font-size: 19px; }
.text-button, .copy-button {
  border: 0;
  padding: 5px 0;
  color: var(--muted);
  background: transparent;
  cursor: pointer;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.field-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 20px;
  margin: 30px 0 20px;
}

label { display: grid; gap: 7px; }
label > span { color: var(--muted); font-size: 13px; font-weight: 650; }
label b { color: #9a9b93; font-size: 10px; letter-spacing: 0.06em; text-transform: uppercase; }

input, textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: 2px;
  padding: 12px 13px;
  color: var(--ink);
  background: #fff;
  outline: none;
  transition: border-color 120ms, box-shadow 120ms;
}

input:focus, textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-light);
}

textarea { resize: vertical; line-height: 1.5; }
.form-footer { align-items: end; margin-top: 24px; }
.form-footer p { margin: 0; color: var(--muted); font-size: 13px; }
.primary-button {
  border: 0;
  border-radius: 2px;
  padding: 12px 18px;
  color: #fff;
  background: var(--accent);
  font-weight: 700;
  cursor: pointer;
}
.primary-button:disabled { cursor: wait; opacity: 0.62; }

.status {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 20px;
  padding: 22px 24px;
  border: 1px solid var(--line);
  background: var(--accent-light);
}
.status[hidden] { display: none; }
.status p { margin: 4px 0 0; color: var(--muted); font-size: 13px; }
.spinner {
  width: 20px;
  height: 20px;
  border: 2px solid rgb(41 78 59 / 20%);
  border-top-color: var(--accent);
  border-radius: 50%;
  animation: spin 800ms linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.results { padding-top: 72px; scroll-margin-top: 20px; }
.results[hidden] { display: none; }
.results-heading { margin-bottom: 22px; }
.duration { color: var(--muted); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 13px; }
.report-card { margin-bottom: 18px; padding: 28px 30px; }
.report-heading { padding-bottom: 22px; border-bottom: 1px solid var(--line); }
.report-number { color: var(--accent); font-family: ui-monospace, SFMono-Regular, Menlo, monospace; font-size: 12px; }
.copy-button { font-size: 12px; }

.markdown { padding-top: 18px; color: #2c2d28; line-height: 1.55; }
.markdown h3, .markdown h4, .markdown h5 { margin: 24px 0 8px; font-size: 16px; }
.markdown p { margin: 10px 0; }
.markdown ul { padding-left: 22px; }
.markdown code { padding: 2px 4px; background: var(--paper); font-family: ui-monospace, monospace; font-size: 12px; }
.source-ref { color: var(--accent); font-family: ui-monospace, monospace; font-size: 12px; white-space: nowrap; }
.source-ref.unsupported { color: var(--error); }
.citation-warning { padding: 10px 12px; border: 1px solid #e5bdb7; color: var(--error); background: #fff0ed; font-size: 12px; }
.table-scroll { overflow-x: auto; margin: 15px 0 24px; }
table { width: 100%; border-collapse: collapse; font-size: 13px; }
th, td { min-width: 115px; padding: 11px 12px; border: 1px solid var(--line); text-align: left; vertical-align: top; }
th { color: var(--muted); background: var(--paper); font-size: 11px; letter-spacing: 0.04em; text-transform: uppercase; }

details { margin-top: 12px; border-top: 1px solid var(--line); padding-top: 14px; }
summary { color: var(--muted); font-size: 12px; cursor: pointer; }
details ol { display: grid; gap: 7px; padding-left: 30px; }
details li { padding-left: 5px; color: var(--muted); font-family: ui-monospace, monospace; font-size: 11px; }
details li span { display: inline-block; min-width: 62px; color: var(--accent); }
.review-note { max-width: 700px; margin: 24px 0 0; color: var(--muted); font-size: 13px; line-height: 1.55; }
.error { margin-top: 20px; padding: 16px 18px; border: 1px solid #e5bdb7; color: var(--error); background: #fff0ed; font-size: 14px; }
.error[hidden] { display: none; }
.consent {
  grid-template-columns: 17px 1fr;
  align-items: start;
  gap: 10px;
  margin-top: 20px;
}
.consent input { width: 17px; height: 17px; margin: 1px 0 0; }
.consent span { font-weight: 400; line-height: 1.45; }

footer {
  gap: 22px;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 12px;
}
footer span { margin-right: auto; }

@media (max-width: 680px) {
  .site-header, main, footer { padding-left: 20px; padding-right: 20px; }
  main { padding-top: 45px; }
  .intro { margin-bottom: 45px; }
  .site-header nav .quiet-link { display: none; }
  .project-intro { margin-bottom: 70px; }
  .hero-actions { align-items: flex-start; flex-direction: column; }
  .project-section { padding: 65px 0; }
  .metric-grid, .split-content, .resource-grid, .people-grid { grid-template-columns: 1fr; }
  .people-grid { gap: 24px; }
  .metric-grid article { min-height: auto; }
  .metric-grid article + article { border-left: 0; border-top: 1px solid var(--line); }
  .metric-value { margin-bottom: 26px; }
  .split-content { gap: 42px; }
  .field-grid { grid-template-columns: 1fr; }
  .screen-form, .report-card { padding: 22px 18px; }
  .form-footer { align-items: stretch; flex-direction: column; }
  .primary-button { width: 100%; }
  .results-heading, .report-heading { align-items: flex-start; }
  footer { flex-wrap: wrap; }
  footer span { flex-basis: 100%; }
}
