:root {
  --paper: #f8f4ec;
  --paper-deep: #eee5d7;
  --ink: #2b2824;
  --muted: #6f675d;
  --rule: #d8cbb8;
  --clay: #8c6a4c;
  --sage: #667760;
  color-scheme: light;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background:
    radial-gradient(circle at 12% 8%, rgba(176, 130, 96, .13), transparent 28rem),
    linear-gradient(180deg, var(--paper) 0%, #fbf8f2 42%, var(--paper) 100%);
  color: var(--ink);
  font-family: "Avenir Next", Avenir, "Segoe UI", sans-serif;
  line-height: 1.72;
  margin: 0;
  min-height: 100vh;
}

a { color: var(--clay); text-underline-offset: .18em; }
a:hover { color: var(--sage); }

.shell {
  margin: 0 auto;
  max-width: 76rem;
  padding: 2rem 1.25rem 5rem;
}

.masthead {
  align-items: center;
  border-bottom: 1px solid var(--rule);
  display: flex;
  justify-content: space-between;
  padding-bottom: 1.25rem;
}

.brand {
  color: var(--ink);
  font-family: "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  font-size: 1.18rem;
  letter-spacing: .01em;
  text-decoration: none;
}

.eyebrow {
  color: var(--sage);
  font-size: .72rem;
  font-weight: 700;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.layout {
  display: grid;
  gap: clamp(2rem, 6vw, 6rem);
  grid-template-columns: minmax(13rem, 17rem) minmax(0, 44rem);
  justify-content: center;
  padding-top: clamp(3rem, 7vw, 6rem);
}

.intro { align-self: start; position: sticky; top: 2rem; }

h1, h2 {
  font-family: "Iowan Old Style", "Palatino Linotype", Georgia, serif;
  font-weight: 400;
  line-height: 1.08;
}

h1 {
  font-size: clamp(2.7rem, 7vw, 5.6rem);
  letter-spacing: -.045em;
  margin: .75rem 0 1.35rem;
}

h2 {
  font-size: clamp(1.65rem, 3vw, 2.15rem);
  letter-spacing: -.02em;
  margin: 3.5rem 0 1rem;
}

.lede { color: var(--muted); font-size: 1.02rem; }
.meta { color: var(--muted); font-size: .82rem; margin-top: 1.5rem; }

.toc {
  border-left: 2px solid var(--rule);
  display: grid;
  gap: .55rem;
  margin-top: 2rem;
  padding-left: 1rem;
}

.toc a { color: var(--muted); font-size: .84rem; text-decoration: none; }
.toc a:hover { color: var(--clay); }

.content { max-width: 44rem; }
.content > :first-child { margin-top: 0; }
.content p, .content li { color: #443f39; }
.content li + li { margin-top: .6rem; }

.notice {
  background: rgba(102, 119, 96, .1);
  border: 1px solid rgba(102, 119, 96, .28);
  border-radius: 1rem;
  margin: 2rem 0;
  padding: 1.15rem 1.3rem;
}

.actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 2rem; }

.button {
  background: var(--ink);
  border-radius: 999px;
  color: var(--paper);
  display: inline-block;
  font-size: .86rem;
  padding: .75rem 1.1rem;
  text-decoration: none;
}

.button:hover { background: var(--clay); color: white; }
.button.secondary { background: transparent; border: 1px solid var(--rule); color: var(--ink); }

footer {
  border-top: 1px solid var(--rule);
  color: var(--muted);
  font-size: .78rem;
  margin-top: 5rem;
  padding-top: 1.25rem;
}

@media (max-width: 760px) {
  .layout { grid-template-columns: 1fr; }
  .intro { position: static; }
  .toc { display: none; }
  h1 { max-width: 10ch; }
}

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