@font-face {
  font-family: "Source Serif 4";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/source-serif-4-latin-400-normal.woff2") format("woff2");
}

@font-face {
  font-family: "Source Serif 4";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/source-serif-4-latin-600-normal.woff2") format("woff2");
}

@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url("/assets/fonts/source-sans-3-latin-400-normal.woff2") format("woff2");
}

@font-face {
  font-family: "Source Sans 3";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url("/assets/fonts/source-sans-3-latin-600-normal.woff2") format("woff2");
}

:root {
  --paper: #f4f1ea;
  --paper-raised: #fffcf7;
  --ink: #1a1714;
  --muted: #3f3a34;
  --line: #ddd6c8;
  --accent: #0a4550;
  --focus: #0a4550;
  --serif: "Source Serif 4", Georgia, "Times New Roman", serif;
  --sans: "Source Sans 3", Arial, sans-serif;
  color-scheme: light;
}

:root[data-theme="dark"] {
  --paper: #141210;
  --paper-raised: #1e1b17;
  --ink: #f3efe6;
  --muted: #d2c9bb;
  --line: #3d3832;
  --accent: #a9dbe3;
  --focus: #f3efe6;
  color-scheme: dark;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #141210;
    --paper-raised: #1e1b17;
    --ink: #f3efe6;
    --muted: #d2c9bb;
    --line: #3d3832;
    --accent: #a9dbe3;
    --focus: #f3efe6;
    color-scheme: dark;
  }
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 1.0625rem;
  line-height: 1.55;
  overflow-wrap: break-word;
}

:focus {
  outline: none;
}

:focus-visible,
[tabindex="-1"]:focus {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

::selection {
  background: var(--accent);
  color: var(--paper);
}

.skip {
  position: absolute;
  left: 1rem;
  top: 0.5rem;
  transform: translateY(-200%);
  background: var(--accent);
  color: var(--paper);
  padding: 0.6rem 1rem;
  z-index: 5;
  text-decoration: none;
}

.skip:focus {
  transform: none;
}

.wrap {
  width: min(72rem, calc(100% - 2.5rem));
  margin-inline: auto;
}

.draft-note {
  max-width: none;
  margin: 0;
  padding: 0.65rem 0;
  background: var(--paper-raised);
  border-bottom: 1px solid var(--line);
  font-size: 1rem;
}

.site-header {
  border-bottom: 1px solid var(--line);
}

.header-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.25rem 1.25rem;
  padding-block: 0.35rem;
}

.brand {
  font-family: var(--serif);
  font-weight: 600;
  font-size: 1.45rem;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.015em;
  padding: 0.55rem 0;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.brand:hover,
.brand:focus-visible {
  text-decoration: underline;
  text-underline-offset: 0.18em;
}

.site-nav ul,
.footer-nav ul,
.page-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.35rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav a,
.footer-nav a,
.page-nav a,
.theme-toggle {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0.35rem 0.55rem;
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 0.18em;
  text-decoration-thickness: 1px;
}

.site-nav a[aria-current="page"] {
  font-weight: 600;
  text-decoration-thickness: 2px;
}

.theme-toggle {
  margin-left: auto;
  font: inherit;
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 2px;
  cursor: pointer;
  text-decoration: none;
}

.theme-toggle:hover {
  border-color: var(--accent);
}

main {
  padding-bottom: 4rem;
}

h1,
h2,
h3,
h4 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.015em;
  scroll-margin-top: 1rem;
}

h1 {
  margin: 2.5rem 0 1rem;
  font-size: clamp(2.15rem, 4.6vw, 3.35rem);
  max-width: 18ch;
}

h2 {
  margin: 0 0 0.85rem;
  font-size: clamp(1.7rem, 3vw, 2.15rem);
}

h3 {
  margin: 2rem 0 0.6rem;
  font-size: 1.45rem;
}

h4 {
  margin: 1.6rem 0 0.4rem;
  font-size: 1.25rem;
}

p,
li {
  max-width: 38rem;
}

.lede,
.source-text p,
.source-text li {
  font-family: var(--serif);
  font-size: 1.25rem;
  line-height: 1.6;
}

.lede {
  margin-top: 0;
}

a {
  color: var(--accent);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}

a:hover {
  text-decoration-thickness: 2px;
}

.section {
  margin-top: 4.25rem;
}

.opening {
  margin-top: 2.5rem;
}

.opening h1 {
  margin-top: 0;
}

@media (min-width: 68rem) {
  .opening {
    display: grid;
    grid-template-columns: minmax(0, 38rem) minmax(14rem, 20rem);
    column-gap: 3rem;
    align-items: start;
  }

  .opening .page-nav {
    grid-column: 2;
    grid-row: 1;
    margin-top: 0.35rem;
  }

  .opening .page-nav ul {
    flex-direction: column;
    align-items: flex-start;
  }
}

.page-nav {
  margin: 1.75rem 0 0;
}

.page-nav p {
  margin: 0 0 0.2rem;
  font-size: 0.95rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--muted);
}

.kicker {
  margin: 0 0 0.35rem;
  font-weight: 600;
  color: var(--accent);
}

.intro {
  color: var(--ink);
}

.status {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem 0.75rem;
  align-items: baseline;
  margin: 0.4rem 0 1rem;
  max-width: 38rem;
}

.status-label {
  font-weight: 600;
  border: 1px solid var(--accent);
  color: var(--accent);
  padding: 0.1rem 0.45rem;
  border-radius: 2px;
}

.evidence {
  padding: 0;
  margin: 1rem 0 0;
}

.evidence div {
  display: grid;
  grid-template-columns: minmax(7rem, 11rem) minmax(0, 1fr);
  gap: 0.35rem 1rem;
  padding: 0.7rem 0;
  border-top: 1px solid var(--line);
  max-width: 44rem;
}

.evidence dt,
.evidence dd {
  margin: 0;
}

.evidence dt {
  font-weight: 600;
}

.evidence dd {
  max-width: none;
}

.shot {
  margin: 1.25rem 0 1.75rem;
  max-width: 56rem;
}

.shot-phone {
  max-width: 22rem;
}

.shot img {
  display: block;
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  background: var(--paper-raised);
}

.shot figcaption {
  margin-top: 0.45rem;
  max-width: 40rem;
  color: var(--muted);
  font-size: 1rem;
}

.planned {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr));
  gap: 1rem;
  margin: 1rem 0 0;
  padding: 0;
  list-style: none;
  max-width: 56rem;
}

.planned li {
  margin: 0;
  max-width: none;
  background: var(--paper-raised);
  border: 1px solid var(--line);
  padding: 1rem 1.1rem 1.15rem;
}

.planned h3 {
  margin: 0.55rem 0 0.35rem;
  font-size: 1.3rem;
}

.steps {
  padding-left: 1.25rem;
}

.steps li {
  margin: 0.7rem 0;
}

.steps li p {
  margin: 0.2rem 0 0;
}

.toc {
  margin: 1.5rem 0 2rem;
  padding: 1rem 0 0.25rem;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  max-width: 38rem;
}

.toc p {
  margin: 0 0 0.4rem;
  font-weight: 600;
}

.toc ol {
  margin: 0.2rem 0 0.8rem;
  padding-left: 1.3rem;
}

.toc li {
  margin: 0.28rem 0;
  font-family: var(--sans);
  font-size: 1rem;
  line-height: 1.4;
  max-width: none;
}

.toc-principles {
  list-style: none;
  padding-left: 0;
  margin-top: 0.35rem;
}

@media (min-width: 68rem) {
  .manifesto-layout {
    display: grid;
    grid-template-columns: minmax(0, 38rem) minmax(14rem, 20rem);
    column-gap: 3rem;
    align-items: start;
  }

  .manifesto-layout .toc {
    grid-column: 2;
    grid-row: 1;
    position: sticky;
    top: 1rem;
    max-width: none;
    margin: 0;
    max-height: calc(100vh - 2rem);
    overflow: auto;
  }

  .manifesto-layout .source-text {
    grid-column: 1;
    grid-row: 1;
  }
}

.source-text {
  max-width: 38rem;
}

.doc-title {
  font-family: var(--serif);
  font-size: clamp(1.6rem, 3vw, 2rem);
  font-weight: 600;
  letter-spacing: 0.01em;
  line-height: 1.25;
  margin: 0.4rem 0 0.4rem;
}

.doc-note {
  color: var(--muted);
  font-family: var(--sans);
  font-size: 1.0625rem;
}

.source-text ul {
  padding-left: 1.25rem;
}

.source-text li {
  margin: 0.45rem 0;
}

.note {
  color: var(--muted);
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0 3rem;
  background: var(--paper-raised);
}

.site-footer p,
.site-footer li {
  max-width: 44rem;
}

.footer-nav {
  margin: 0.5rem 0 1rem;
}

@media (max-width: 40rem) {
  .wrap {
    width: min(72rem, calc(100% - 2rem));
  }

  h1 {
    margin-top: 1.75rem;
  }

  .section {
    margin-top: 3rem;
  }

  .theme-toggle {
    margin-left: 0;
  }

  .evidence div {
    grid-template-columns: 1fr;
    gap: 0.15rem;
  }
}

@media (forced-colors: active) {
  .status-label,
  .theme-toggle,
  .shot img,
  .planned li {
    border: 1px solid CanvasText;
  }

  :focus-visible,
  [tabindex="-1"]:focus {
    outline: 3px solid Highlight;
  }
}

@media print {
  .draft-note,
  .theme-toggle,
  .skip,
  .page-nav {
    display: none;
  }

  body {
    background: #fff;
    color: #000;
  }

  a {
    color: #000;
  }

  .shot {
    break-inside: avoid;
  }
}
