:root {
  --bg: #fdfcf9;
  --text: #2a2622;
  --muted: #6b645c;
  --accent: #7a4b2a;
  --rule: #e2ddd4;
  --measure: 34rem;
}

* { box-sizing: border-box; }

html { font-size: 112.5%; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: "EB Garamond", Georgia, "Times New Roman", serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

/* Book covers across the top */
.shelf {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2rem;
  padding: 3rem 1rem 1rem;
  max-width: 60rem;
  margin: 0 auto;
}
.shelf a { display: block; line-height: 0; }
.shelf img {
  width: 160px;
  height: auto;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.18);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.shelf a:hover img,
.shelf a:focus-visible img {
  transform: translateY(-4px);
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.22);
}

main {
  max-width: var(--measure);
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
}

h1 {
  font-weight: 400;
  font-size: 2.2rem;
  letter-spacing: 0.02em;
  text-align: center;
  margin: 1.5rem 0 0.3rem;
}
.tagline {
  text-align: center;
  font-style: italic;
  font-size: 1.15rem;
  color: var(--muted);
  margin: 0 0 2.25rem;
}
h2 {
  font-weight: 400;
  font-size: 1.35rem;
  text-align: center;
  margin: 2.75rem 0 1rem;
}
h2::before {
  content: "";
  display: block;
  width: 3rem;
  margin: 0 auto 2.25rem;
  border-top: 1px solid var(--rule);
}

p { margin: 0 0 1.1rem; }

nav.back { text-align: center; margin-top: 2.5rem; }

footer {
  text-align: center;
  color: var(--muted);
  font-size: 0.85rem;
  padding: 2rem 1rem 3rem;
}

@media (max-width: 480px) {
  html { font-size: 106%; }
  .shelf { gap: 1rem; padding-top: 2rem; }
  .shelf img { width: 130px; }
  h1 { font-size: 1.8rem; }
}

/* Book pages */
.book { max-width: 56rem; margin: 0 auto; padding: 3rem 1rem 2rem; display: grid; grid-template-columns: 240px 1fr; gap: 3rem; align-items: start; }
.book-covers img { display: block; width: 100%; height: auto; box-shadow: 0 2px 10px rgba(0, 0, 0, 0.2); }
.book-covers img + img { margin-top: 1.5rem; }
.book h1 { text-align: left; font-size: 2rem; line-height: 1.2; margin: 0 0 0.4rem; }
.book .subtitle { font-style: italic; font-size: 1.15rem; color: var(--muted); margin-bottom: 0.4rem; }
.book .author { letter-spacing: 0.08em; text-transform: uppercase; font-size: 0.85rem; margin-bottom: 1.75rem; }
.book .hook { font-weight: 500; }
.book ul { padding-left: 1.2rem; margin: 0 0 1.1rem; }
.book li { margin-bottom: 0.35rem; }
.buy { display: inline-block; margin: 0.5rem 0 1.5rem; padding: 0.55rem 1.4rem; border: 1px solid var(--accent); color: var(--accent); text-decoration: none; letter-spacing: 0.05em; }
.buy:hover { background: var(--accent); color: var(--bg); }
@media (max-width: 720px) {
  .book { grid-template-columns: 1fr; gap: 2rem; padding-top: 2rem; }
  .book-covers { max-width: 220px; margin: 0 auto; }
}
/* Hide a buy button until its Amazon link is filled in */
.buy[href="#"] { display: none; }

/* Standard page: the four standards */
.standards { list-style: none; padding: 0; margin: 0.5rem 0 1.6rem; display: grid; gap: 0.9rem; }
.standards li { padding-left: 1.9rem; position: relative; }
.standards strong { font-weight: 500; }
.standards li::before { content: "✓"; position: absolute; left: 0.2rem; color: var(--accent); }
