/* The public book pages, generated by scripts/build_books.py (Knowingo decision 212).
   Built on site.css. Every colour, radius and shadow comes from css/tokens.css; never
   write a literal colour here. */

.book { padding: clamp(40px, 6vw, 72px) 0 var(--gap-section); }

.book-hero {
  display: grid;
  grid-template-columns: minmax(0, 260px) minmax(0, 1fr);
  gap: clamp(28px, 5vw, 64px);
  align-items: start;
}

.book-hero .cover {
  display: block;
  width: 100%;
  border-radius: var(--radius-control);
  box-shadow: var(--shadow-floating);
}

.book-hero h1 { margin-bottom: 12px; }

.byline {
  font-family: var(--font-serif);
  font-size: 20px;
  color: var(--muted-strong);
  margin-bottom: 22px;
}

.book-hero .note { margin-top: 18px; }

@media (max-width: 760px) {
  .book-hero { grid-template-columns: minmax(0, 1fr); }
  .book-hero .cover { width: min(52%, 200px); }
}

/* Three short links fit beside the brand on a phone only when none of them wraps. */
.topnav a { white-space: nowrap; }

@media (max-width: 420px) {
  .topnav { gap: 16px; }
}

.book-section { max-width: 760px; margin-top: clamp(52px, 7vw, 84px); }
.book-section h2 { font-size: clamp(25px, 2.8vw, 33px); margin-bottom: 20px; }
.book-section ul,
.book-section ol { margin: 0; padding-left: 22px; color: var(--muted-strong); }
.book-section li { margin-bottom: 10px; }

.book-section .parts { padding-left: 0; list-style: none; counter-reset: part; }

.parts li {
  counter-increment: part;
  display: flex;
  gap: 16px;
  align-items: baseline;
  padding: 12px 0;
  margin: 0;
  border-bottom: 1px solid var(--line);
}

.parts li::before {
  content: counter(part);
  min-width: 1.6em;
  font-family: var(--font-serif);
  color: var(--coral);
}

.parts li span:first-child { flex: 1; color: var(--ink); }
.parts .minutes { color: var(--muted); font-size: 15px; white-space: nowrap; }

.book-section .people { padding-left: 0; list-style: none; }

.person {
  display: flex;
  gap: 18px;
  align-items: flex-start;
  padding: 18px 0;
  margin: 0;
  border-bottom: 1px solid var(--line);
}

.person strong { display: block; color: var(--ink); }
.person .credential { display: block; color: var(--muted); font-size: 15px; }

.person blockquote {
  margin: 12px 0 0;
  font-family: var(--font-serif);
  font-size: 18px;
  line-height: 1.6;
  color: var(--ink);
}

.person .bio { margin-top: 10px; font-size: 15px; }
.person .bio li { margin-bottom: 4px; }

.face {
  flex: none;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  object-fit: cover;
  display: grid;
  place-items: center;
  background: var(--surface-deep);
  color: var(--muted-strong);
  font-family: var(--font-serif);
  font-size: 22px;
}

.book-section .links { padding-left: 0; list-style: none; }
.links li { padding: 16px 0; margin: 0; border-bottom: 1px solid var(--line); }
.links a { font-family: var(--font-serif); font-size: 20px; color: var(--ink); }
.links p { margin: 6px 0 0; }

.kind {
  display: inline-block;
  margin-right: 12px;
  padding: 2px 10px;
  border-radius: var(--radius-control);
  background: var(--coral-soft);
  color: var(--coral-dark);
  font-size: 14px;
  font-weight: 600;
  vertical-align: 3px;
}

.shelf {
  list-style: none;
  padding: 0;
  margin: 28px 0 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 32px 24px;
}

.book .shelf { padding-left: 0; }
.shelf li { margin: 0; }
.shelf a { display: block; text-decoration: none; color: var(--ink); }

.shelf img {
  display: block;
  width: 100%;
  border-radius: var(--radius-control);
  box-shadow: var(--shadow-card);
  transition: transform 0.2s ease;
}

.shelf a:hover img { transform: translateY(-3px); }
.shelf span { display: block; margin-top: 10px; font-family: var(--font-serif); line-height: 1.3; }
.shelf .by { margin-top: 4px; font-family: var(--font-ui); font-size: 14px; color: var(--muted); }

@media (max-width: 520px) {
  .shelf { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px 16px; }
}
