:root {
  --ink: #102823;
  --muted: #60736f;
  --paper: #f4f3ec;
  --card: #fbfaf5;
  --river: #0a756d;
  --deep: #074a48;
  --lime: #c7e35d;
  --line: #d7ddd5;
  --focus: #9ecf23;
  --radius: 22px;
  --shadow-card: 0 0 0 1px #0000000f, 0 1px 2px -1px #0000000f, 0 2px 4px #0000000a;
  --shadow-card-hover: 0 0 0 1px #00000018, 0 2px 3px -1px #00000016, 0 8px 18px #074a4814;
}

* { box-sizing: border-box; }

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  line-height: 1.6;
}

::selection { background: var(--lime); color: var(--ink); }
a { text-underline-position: from-font; text-decoration-thickness: from-font; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 3px; }

.skip { position: absolute; inset-inline-start: -9999px; }
.skip:focus { inset-inline-start: 1rem; top: 1rem; background: #fff; padding: .7rem 1rem; z-index: 20; border-radius: 10px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap; border: 0; }

.topbar {
  min-height: 84px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1220px;
  margin: auto;
  padding-inline: 28px;
  border-bottom: 1px solid var(--line);
}

.brand { font-weight: 800; font-size: 25px; color: var(--ink); text-decoration: none; letter-spacing: -1px; }
.brand span { display: inline-grid; place-items: center; background: var(--deep); color: var(--lime); width: 34px; height: 34px; border-radius: 50%; margin-inline-end: 3px; }
.brand--small { font-size: 20px; }
.brand--small span { width: 28px; height: 28px; }
.topbar nav { display: flex; gap: 28px; }
.topbar nav a, .text-link, .back { color: var(--ink); text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 5px; font-weight: 650; min-height: 44px; display: inline-flex; align-items: center; }
.topbar nav a:hover, .text-link:hover, .back:hover { text-decoration-color: currentColor; }

main { max-width: 1220px; margin: auto; padding-inline: 28px; }
.hero { min-height: 620px; display: grid; grid-template-columns: 1.1fr .9fr; gap: 80px; align-items: center; padding-block: 70px; }
.eyebrow { text-transform: uppercase; letter-spacing: .16em; font-size: 12px; font-weight: 800; color: var(--river); margin: 0 0 14px; }
.hero h1, .article h1 { font-family: Georgia, serif; font-size: clamp(48px, 7vw, 88px); line-height: .98; letter-spacing: -.055em; margin: 0; text-wrap: balance; }
.hero h1 em { color: var(--river); font-weight: 400; }
.lead { font-size: clamp(18px, 2vw, 23px); color: var(--muted); max-width: 65ch; text-wrap: pretty; }
.hero__actions { display: flex; align-items: center; flex-wrap: wrap; gap: 18px 26px; margin-top: 34px; }
.button { display: inline-flex; align-items: center; justify-content: center; min-height: 46px; background: var(--deep); color: #fff; padding: 12px 22px; border-radius: 999px; text-decoration: none; font-weight: 750; transition-property: scale, background-color; transition-duration: 150ms; transition-timing-function: ease-out; }
.button:hover { background: var(--river); }
.button:active { scale: .96; }

.water-card { height: 420px; border-radius: 48% 48% 43% 57% / 38% 42% 58% 62%; position: relative; overflow: hidden; background: linear-gradient(160deg, #b6dad0 0 34%, #4aa198 34% 56%, #0b6863 56%); box-shadow: 0 30px 70px #164f4930; }
.water-card::after { content: ""; position: absolute; inset: 54% -20% -20%; background: repeating-radial-gradient(ellipse at 40% 0, transparent 0 25px, #ffffff24 27px 29px, transparent 31px 50px); }
.water-card__sun { position: absolute; width: 88px; height: 88px; border-radius: 50%; background: var(--lime); top: 70px; inset-inline-end: 80px; }
.water-card > p { position: absolute; bottom: 18px; inset-inline-end: 42px; color: #fff; font-size: 13px; z-index: 2; }
.float { position: absolute; z-index: 3; inset-inline-start: 38px; bottom: 95px; background: #fff; padding: 18px 24px; border-radius: 16px; box-shadow: 0 16px 40px #083a3545; }
.float b { display: block; font: 700 34px Georgia; font-variant-numeric: tabular-nums; }
.float span { color: var(--muted); font-size: 13px; }
.float--two { inset-inline-start: auto; inset-inline-end: 30px; bottom: 150px; }

.manifest { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); padding-block: 65px; display: grid; grid-template-columns: 1fr 2fr; gap: 40px; }
.manifest p { color: var(--river); font-weight: 750; }
.manifest h2, .section-title h2, .portal-tools h2 { font: 500 clamp(31px, 4vw, 52px) / 1.08 Georgia; margin: 0; letter-spacing: -.035em; text-wrap: balance; }
.knowledge { padding-block: 90px; scroll-margin-top: 1rem; }
.section-title { display: flex; justify-content: space-between; align-items: end; gap: 32px; margin-bottom: 34px; }
.search { display: grid; gap: 6px; color: var(--muted); font-size: 13px; }
.search input { width: min(340px, 80vw); min-height: 46px; border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 11px 18px; font: inherit; font-size: 16px; caret-color: var(--river); }
.search:focus-within span { color: var(--ink); }
.grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; }
.card { background: var(--card); border-radius: var(--radius); padding: 25px; min-height: 260px; display: flex; flex-direction: column; box-shadow: var(--shadow-card); transition-property: transform, box-shadow; transition-duration: 180ms; transition-timing-function: ease-out; overflow-wrap: break-word; }
.card:hover { transform: translateY(-3px); box-shadow: var(--shadow-card-hover); }
.card h3 { font: 600 25px / 1.18 Georgia; margin: 0 0 13px; text-wrap: balance; }
.card h3 a { color: var(--ink); text-decoration: underline; text-decoration-color: transparent; text-underline-offset: 4px; }
.card h3 a:hover { text-decoration-color: currentColor; }
.card > p:not(.eyebrow) { color: var(--muted); margin: 0; text-wrap: pretty; }
.card__meta { margin-top: auto; display: flex; justify-content: space-between; gap: 12px; padding-top: 22px; color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.empty { padding: 30px; border: 1px dashed var(--line); border-radius: var(--radius); color: var(--muted); }

.portal-tools { margin: 10px 0 100px; padding: 55px; background: var(--deep); color: #fff; border-radius: 32px; scroll-margin-top: 1rem; }
.portal-tools .eyebrow { color: var(--lime); }
.section-title--tools { align-items: start; }
.section-title--tools > p { color: #c6d8d5; max-width: 42ch; margin: 0; }
.tool-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.tool-card { display: flex; flex-direction: column; min-height: 245px; padding: 28px; border: 1px solid #ffffff26; border-radius: var(--radius); background: #ffffff0d; }
.tool-card h3 { font: 600 29px / 1.15 Georgia; margin: 0 0 14px; text-wrap: balance; }
.tool-card h3 a { color: #fff; text-decoration-color: transparent; text-underline-offset: 5px; }
.tool-card h3 a:hover { text-decoration-color: currentColor; }
.tool-card > p:not(.eyebrow) { color: #c6d8d5; margin: 0; }
.tool-card__action { color: var(--lime); font-weight: 750; margin-top: auto; padding-top: 24px; min-height: 44px; display: inline-flex; align-items: center; gap: 8px; }

.article { max-width: 70ch; margin: 80px auto 120px; overflow-wrap: break-word; }
.article h1 { font-size: clamp(43px, 7vw, 76px); margin-top: 25px; }
.article .lead { margin-block: 30px; }
.tags { display: flex; gap: 8px; flex-wrap: wrap; margin: 28px 0 50px; }
.tags span { background: #dce9e4; border-radius: 999px; padding: 6px 12px; font-size: 13px; white-space: nowrap; }
.prose { font: 19px / 1.7 Georgia, serif; }
.prose h2 { font: 600 33px / 1.2 Georgia; margin-top: 50px; text-wrap: balance; }
.sources { margin-top: 55px; padding: 28px; border-radius: var(--radius); background: #e5ebe5; }
.sources h2 { font: 600 24px Georgia; margin-top: 0; }
.sources a { color: var(--deep); overflow-wrap: anywhere; }
.sources p { font-size: 13px; color: var(--muted); }

.tool-page { max-width: 850px; margin: 80px auto 120px; overflow-wrap: break-word; }
.tool-page > h1 { font: 600 clamp(43px, 7vw, 72px) / 1 Georgia; letter-spacing: -.05em; margin: 25px 0 0; text-wrap: balance; }
.tool-page > .lead { margin-block: 28px 45px; }
.tool-body, .journal-form, .journal-history { display: grid; gap: 22px; }
.check-progress { position: sticky; top: 12px; z-index: 4; display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: 14px 22px; padding: 18px 22px; border: 1px solid var(--line); border-radius: 18px; background: #fbfaf5f2; box-shadow: var(--shadow-card); backdrop-filter: blur(10px); }
.check-progress p { margin: 0; white-space: nowrap; }
.check-progress progress { width: 100%; accent-color: var(--river); }
.tool-section { padding: 26px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow-card); }
.tool-section h2, .journal-history h2 { font: 600 28px / 1.2 Georgia; margin: 0 0 20px; }
.check-list, .reference-list { display: grid; gap: 2px; margin: 0; padding: 0; list-style: none; }
.check-list li { display: grid; grid-template-columns: 28px 1fr; align-items: start; gap: 12px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.check-list li:last-child, .reference-list li:last-child { border-bottom: 0; }
.check-list input { width: 22px; height: 22px; margin: 2px 0 0; accent-color: var(--river); }
.check-list label { cursor: pointer; }
.check-list input:checked + label { color: var(--muted); text-decoration: line-through; text-decoration-thickness: 1px; }
.reference-list li { padding: 13px 0 13px 28px; border-bottom: 1px solid var(--line); position: relative; }
.reference-list li::before { content: "→"; position: absolute; inset-inline-start: 0; color: var(--river); font-weight: 800; }
.quiet-button { min-height: 44px; padding: 8px 14px; border: 1px solid #afbbb5; border-radius: 999px; background: transparent; color: var(--ink); font: inherit; font-size: 14px; font-weight: 700; cursor: pointer; }
.quiet-button:hover { background: #e5ebe5; }
.button--control { border: 0; font: inherit; font-weight: 750; cursor: pointer; justify-self: start; }
.journal-form { padding: 28px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow-card); }
.journal-form label { display: grid; gap: 7px; color: var(--ink); font-weight: 700; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.journal-form input, .journal-form textarea { width: 100%; min-height: 46px; padding: 11px 13px; border: 1px solid #afbbb5; border-radius: 11px; background: #fff; color: var(--ink); font: inherit; font-size: 16px; font-weight: 400; }
.journal-form textarea { resize: vertical; }
.privacy-note, .empty-note { color: var(--muted); font-size: 14px; margin: 0; }
.journal-history { margin-top: 45px; }
.tool-section__head { display: flex; justify-content: space-between; align-items: center; gap: 18px; }
.tool-section__head h2 { margin: 0; }
[data-journal-list] { display: grid; gap: 14px; }
.journal-entry { padding: 22px; border-radius: 16px; background: var(--card); box-shadow: var(--shadow-card); }
.journal-entry h3 { font: 600 24px/1.2 Georgia; margin: 0 0 8px; }
.journal-entry > p { white-space: pre-wrap; }
.journal-entry__details { color: var(--river); font-weight: 700; }

.timeline-page { max-width: 900px; margin: 80px auto 120px; }
.timeline-page > h1 { font: 600 clamp(43px, 7vw, 72px) / 1 Georgia; letter-spacing: -.05em; margin: 0; text-wrap: balance; }
.timeline-page > .lead { margin-block: 28px 44px; }
.current-work { display: flex; justify-content: space-between; align-items: center; gap: 32px; padding: 28px; border-radius: var(--radius); background: var(--deep); color: #fff; box-shadow: 0 20px 45px #074a4824; }
.current-work h2 { font: 600 28px / 1.2 Georgia; margin: 0; text-wrap: balance; }
.current-work p:not(.eyebrow) { color: #c6d8d5; margin: 8px 0 0; }
.quiet-button--light { flex: 0 0 auto; color: #fff; border-color: #ffffff66; }
.quiet-button--light:hover { background: #ffffff14; }
.quiet-button:disabled { cursor: wait; opacity: .65; }
.timeline-note { max-width: 70ch; margin: 28px 0 55px; color: var(--muted); }
.roadmap-preview { margin-bottom: 70px; }
.roadmap-preview > div { margin-bottom: 24px; }
.roadmap-preview h2 { font: 600 clamp(30px, 4vw, 42px) / 1.1 Georgia; margin: 0; text-wrap: balance; }
.roadmap-preview > ol { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin: 0; padding: 0; list-style: none; }
.roadmap-item { padding: 22px; border-radius: 18px; background: var(--card); box-shadow: var(--shadow-card); }
.roadmap-item--completed { background: #e5ebe5; }
.roadmap-item__top { display: flex; justify-content: space-between; gap: 12px; margin-bottom: 14px; color: var(--muted); font-size: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: .08em; }
.roadmap-item__status { color: var(--river); }
.roadmap-item h3 { font: 600 23px / 1.2 Georgia; margin: 0 0 10px; text-wrap: balance; }
.roadmap-item p { color: var(--muted); margin: 0; }
.timeline-list { position: relative; display: grid; gap: 34px; margin: 0; padding: 0; list-style: none; }
.timeline-list::before { content: ""; position: absolute; inset-block: 10px; inset-inline-start: 9px; width: 2px; background: var(--line); }
.timeline-entry { position: relative; display: grid; grid-template-columns: 20px minmax(0, 1fr); gap: 22px; }
.timeline-entry__marker { position: relative; z-index: 1; width: 20px; height: 20px; margin-top: 24px; border: 5px solid var(--paper); border-radius: 50%; background: var(--river); box-shadow: 0 0 0 2px var(--river); }
.timeline-entry__content { min-width: 0; padding: 24px; border-radius: var(--radius); background: var(--card); box-shadow: var(--shadow-card); }
.timeline-entry__content h2 { font: 600 25px / 1.2 Georgia; margin: 12px 0 18px; overflow-wrap: anywhere; }
.timeline-entry__meta { display: flex; align-items: center; justify-content: space-between; gap: 14px; color: var(--muted); font-size: 13px; font-variant-numeric: tabular-nums; }
.timeline-entry__meta code { padding: 4px 8px; border-radius: 7px; background: #e5ebe5; color: var(--deep); }
.timeline-entry details { color: var(--muted); }
.timeline-entry summary { min-height: 44px; display: flex; align-items: center; color: var(--deep); font-weight: 700; cursor: pointer; }
.timeline-entry details ul { margin: 10px 0 0; padding-inline-start: 24px; font: 13px/1.7 ui-monospace, SFMono-Regular, Consolas, monospace; overflow-wrap: anywhere; }
.timeline-empty { padding: 28px; border-radius: var(--radius); background: var(--card); color: var(--muted); box-shadow: var(--shadow-card); }

.map-figure { margin: 0 0 45px; }
.map-scheme { display: block; width: 100%; height: auto; border-radius: var(--radius); background: linear-gradient(160deg, #d9ece5, #a7d3cb); box-shadow: var(--shadow-card); }
.map-scheme > rect { fill: #f7fbf7aa; stroke: #ffffffaa; stroke-width: 2; }
.map-scheme > path { fill: none; stroke: #0a756d22; stroke-width: 2; stroke-dasharray: 8 12; }
.map-scheme g circle { fill: var(--deep); stroke: var(--lime); stroke-width: 5; }
.map-scheme g text { fill: #fff; font: 700 14px ui-sans-serif, system-ui, sans-serif; }
.map-figure figcaption { color: var(--muted); font-size: 13px; margin-top: 12px; }
.map-location-list { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.map-location { display: grid; grid-template-columns: 38px minmax(0, 1fr); gap: 14px; padding: 22px; border-radius: 18px; background: var(--card); box-shadow: var(--shadow-card); }
.map-location__number { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; background: var(--deep); color: #fff; font-weight: 800; }
.map-location h2 { font: 600 24px / 1.2 Georgia; margin: 0 0 10px; }
.map-location p { color: var(--muted); }
.map-location__coords { font-size: 13px; font-variant-numeric: tabular-nums; }
.map-location a { color: var(--deep); font-weight: 750; min-height: 44px; display: inline-flex; align-items: center; }

footer { max-width: 1220px; margin: auto; border-top: 1px solid var(--line); padding: 45px 28px 60px; display: flex; justify-content: space-between; gap: 60px; color: var(--muted); font-size: 13px; }
footer > p { max-width: 450px; }

@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

@media (prefers-reduced-motion: reduce) {
  .card, .button { transition-duration: .01ms; }
  .card:hover { transform: none; }
  .button:active { scale: 1; }
}

@media (max-width: 53rem) {
  .topbar nav { gap: 16px; }
  .topbar nav a:nth-child(-n+2) { display: none; }
  .hero { grid-template-columns: 1fr; gap: 35px; padding-block: 55px; }
  .water-card { height: 330px; }
  .manifest { grid-template-columns: 1fr; gap: 20px; }
  .grid { grid-template-columns: 1fr 1fr; }
  .section-title { align-items: start; flex-direction: column; gap: 25px; }
  .check-progress { grid-template-columns: 1fr auto; }
  .check-progress progress { grid-column: 1 / -1; grid-row: 2; }
}

@media (max-width: 35rem) {
  .topbar, main { padding-inline: 18px; }
  .hero { min-height: auto; }
  .hero h1 { font-size: 49px; }
  .water-card { height: 285px; }
  .water-card__sun { inset-inline-end: 45px; top: 44px; width: 68px; height: 68px; }
  .float { inset-inline-start: 20px; bottom: 65px; }
  .float--two { inset-inline-end: 16px; inset-inline-start: auto; bottom: 122px; }
  .manifest { padding-block: 45px; }
  .knowledge { padding-block: 60px; }
  .search, .search input { width: 100%; }
  .grid { grid-template-columns: 1fr; }
  .portal-tools { padding: 30px; margin-bottom: 65px; }
  .tool-grid, .form-grid { grid-template-columns: 1fr; }
  .tool-page { margin-top: 50px; }
  .timeline-page { margin-top: 50px; }
  .current-work { align-items: start; flex-direction: column; gap: 20px; padding: 24px; }
  .timeline-entry { gap: 14px; }
  .timeline-entry__content { padding: 20px; }
  .timeline-entry__meta { align-items: start; flex-direction: column; gap: 8px; }
  .roadmap-preview > ol, .map-location-list { grid-template-columns: 1fr; }
  .article { margin-top: 50px; }
  .article h1 { font-size: 43px; }
  footer { flex-direction: column; gap: 15px; padding-inline: 18px; }
}

@media (max-width: 21rem) {
  .hero h1, .article h1 { font-size: 40px; }
  .water-card { display: none; }
  .portal-tools { padding: 24px; }
  .tool-section, .journal-form { padding: 20px; }
  .check-progress { position: static; grid-template-columns: 1fr; }
  .check-progress progress { grid-column: auto; grid-row: auto; }
}
