:root {
  --ink: #24382e;
  --paper: #fffdf6;
  --cream: #f4e9d2;
  --leaf: #56725f;
  --leaf-deep: #3e5546;
  --carrot: #d9613d;
  --carrot-deep: #a7442b;
  --sun: #efcb78;
  --line: #ddd0ae;
  --shadow: rgba(78, 39, 17, 0.14);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(1100px 560px at 14% -8%, #fbeed2 0%, transparent 60%),
    radial-gradient(900px 520px at 100% 0%, #f6ddc4 0%, transparent 55%),
    var(--paper);
  color: var(--ink);
  font: 400 17px/1.65 "Andika", -apple-system, "Segoe UI", sans-serif;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { font-family: "Fraunces", Georgia, serif; letter-spacing: -0.01em; }

@keyframes rise {
  from { opacity: 0; transform: translateY(10px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* ---------- hero header (home page) ---------- */

.hero {
  position: relative;
  overflow: hidden;
  padding: 4.5rem 1.5rem 3.5rem;
  text-align: center;
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, var(--cream) 0%, #f7ecd4 100%);
}

.hero::before {
  content: "";
  position: absolute;
  inset: -40% -10% auto -10%;
  height: 140%;
  background:
    radial-gradient(420px 260px at 85% 15%, rgba(217,97,61,0.16), transparent 70%),
    radial-gradient(380px 240px at 8% 85%, rgba(86,114,95,0.14), transparent 70%);
  pointer-events: none;
}

.mark-badge {
  width: 88px; height: 88px;
  margin: 0 auto 1.4rem;
  border-radius: 22px;
  background: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 26px -14px rgba(78, 39, 17, 0.45);
  animation: rise 700ms cubic-bezier(.2,.8,.2,1) both;
}
.mark { width: 56px; height: 56px; }

.hero-title {
  position: relative;
  margin: 0 0 0.4rem;
  font-size: clamp(2.4rem, 5vw, 3.2rem);
  font-weight: 620;
  font-style: italic;
  color: var(--leaf-deep);
  animation: rise 700ms 60ms cubic-bezier(.2,.8,.2,1) both;
}

.tagline {
  position: relative;
  margin: 0;
  font-size: 1.1rem;
  color: var(--carrot-deep);
  font-weight: 700;
  animation: rise 700ms 120ms cubic-bezier(.2,.8,.2,1) both;
}

.nav-pills {
  position: relative;
  display: inline-flex; gap: 0.6rem; justify-content: center;
  margin-top: 2rem;
  padding: 0.35rem;
  background: rgba(255,253,246,0.6);
  border: 1px solid var(--line);
  border-radius: 999px;
  animation: rise 700ms 180ms cubic-bezier(.2,.8,.2,1) both;
}
.nav-pills a {
  color: var(--leaf-deep);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
  padding: 0.55rem 1.15rem;
  border-radius: 999px;
  transition: background 160ms ease, color 160ms ease;
}
.nav-pills a:hover { background: var(--carrot); color: #fff9ef; }

/* ---------- slim header (subpages) ---------- */

.subhead {
  max-width: 700px;
  margin: 0 auto;
  padding: 2.5rem 1.5rem 0;
}
.home-link {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  color: var(--carrot-deep);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
  animation: rise 500ms cubic-bezier(.2,.8,.2,1) both;
}
.home-link:hover { text-decoration: underline; }

/* ---------- main content ---------- */

main { max-width: 700px; margin: 0 auto; padding: 3.5rem 1.5rem 4rem; }

section {
  margin-bottom: 2.75rem;
  scroll-margin-top: 1.5rem;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 2.1rem 2.3rem 2.4rem;
  box-shadow: 0 18px 34px -22px var(--shadow);
  animation: rise 600ms cubic-bezier(.2,.8,.2,1) both;
}

.kicker {
  display: block;
  font-family: "Andika", sans-serif;
  font-weight: 700;
  font-size: 0.75rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--carrot-deep);
  margin-bottom: 0.5rem;
}

.page-title {
  font-size: 1.9rem;
  font-weight: 600;
  font-style: italic;
  margin: 0 0 1.2rem;
  padding-bottom: 0.9rem;
  border-bottom: 1px dashed var(--line);
  color: var(--leaf-deep);
}

h3 {
  font-size: 1.1rem;
  font-weight: 600;
  font-style: italic;
  color: var(--carrot-deep);
  margin: 1.7rem 0 0.5rem;
}

p { margin: 0.7rem 0; }

.lede::first-letter {
  font-family: "Fraunces", serif;
  font-style: italic;
  font-weight: 600;
  font-size: 2.9rem;
  float: left;
  line-height: 0.8;
  padding: 0.1rem 0.35rem 0 0.05rem;
  color: var(--carrot);
}

.email {
  display: inline-block;
  color: var(--carrot-deep);
  font-weight: 700;
  text-decoration: none;
  border-bottom: 2px solid var(--sun);
  padding-bottom: 1px;
  transition: border-color 160ms ease;
}
.email:hover { border-color: var(--carrot); }

.book-list {
  margin-top: 0.9rem;
  border-top: 1px dashed var(--line);
}
.book-list .row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 0.55rem 0;
  border-bottom: 1px dashed var(--line);
  font-size: 0.96rem;
}
.book-list .row span:first-child { font-weight: 700; }
.book-list .row span:last-child {
  color: var(--leaf);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.fact-list {
  margin: 0.9rem 0 0.4rem;
  border-top: 1px dashed var(--line);
}
.fact-list .row {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 1rem;
  padding: 0.5rem 0;
  border-bottom: 1px dashed var(--line);
  font-size: 0.94rem;
}
.fact-list .row span:last-child {
  color: var(--leaf);
  font-weight: 700;
  white-space: nowrap;
}

footer {
  text-align: center;
  color: var(--leaf);
  font-size: 0.85rem;
  padding: 2.5rem 1.5rem 3.5rem;
}

@media (prefers-color-scheme: dark) {
  :root {
    --ink: #ede3ca;
    --paper: #211a13;
    --cream: #2b2117;
    --leaf: #9ab6a1;
    --leaf-deep: #cfe3d4;
    --carrot: #f2895e;
    --carrot-deep: #ffab7e;
    --sun: #caa14f;
    --line: #43372a;
    --shadow: rgba(0,0,0,0.5);
  }
  body {
    background:
      radial-gradient(1100px 560px at 14% -8%, #33281a 0%, transparent 60%),
      radial-gradient(900px 520px at 100% 0%, #2d2013 0%, transparent 55%),
      var(--paper);
  }
  .hero { background: linear-gradient(180deg, var(--cream) 0%, #241c13 100%); }
  .nav-pills { background: rgba(33,26,19,0.6); }
  .nav-pills a:hover { color: #241c13; }
}
