/* ── Nav ── */
nav {
  position: sticky; top: 0;
  background: var(--bg);
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 2rem;
  z-index: 100;
}
nav a { color: var(--dim); text-decoration: none; font-size: .85rem; font-family: var(--body); transition: color .15s; }
nav a:hover { color: var(--ink); }
nav .buy-btn {
  background: var(--ink); color: var(--bg);
  padding: .4rem 1rem; border-radius: 2px;
  font-size: .8rem; font-weight: 600; letter-spacing: .03em;
  transition: opacity .15s;
}
nav .buy-btn:hover { opacity: .8; color: var(--bg); }

/* ── Book header ── */
.book-header {
  max-width: 640px; margin: 4rem auto 3rem;
  padding: 0 2rem;
}
.book-header h1 {
  font-family: var(--serif);
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 400;
  line-height: 1.2;
  margin-bottom: .75rem;
}
.book-header .subtitle {
  font-family: var(--serif);
  color: var(--dim);
  font-size: 1.1rem;
  font-style: italic;
  margin-bottom: .5rem;
}
.book-header .meta {
  color: var(--dim);
  font-size: .8rem;
  letter-spacing: .05em;
  text-transform: uppercase;
}

.divider {
  max-width: 640px; margin: 0 auto 3rem;
  padding: 0 2rem;
  border: none; border-top: 1px solid var(--line);
}

/* ── Book content ── */
.book-content {
  max-width: 640px;
  margin: 0 auto 6rem;
  padding: 0 2rem;
  font-family: var(--serif);
  font-size: 1rem;
  color: var(--ink);
}
.book-content h1 {
  font-size: 1.6rem; font-weight: 400;
  margin: 3rem 0 1rem;
  line-height: 1.3;
}
.book-content h2 {
  font-size: 1.15rem; font-weight: 400;
  margin: 2.5rem 0 .75rem;
  color: var(--ink);
}
.book-content h3 {
  font-style: italic;
  font-size: .95rem; font-weight: 400;
  color: var(--dim);
  margin: 2rem 0 1rem;
  padding-left: 1.5rem;
  border-left: 2px solid var(--line);
  line-height: 1.6;
}
.book-content h4, .book-content h5, .book-content h6 {
  font-size: 1rem; font-weight: 400;
  color: var(--dim); margin: 2rem 0 .5rem;
}
.book-content p {
  margin-bottom: 1.2rem;
  text-align: justify;
}
.book-content p:empty,
.book-content p:has(> br:only-child) { margin-bottom: .3rem; }
.book-content ul, .book-content ol { margin: 1rem 0 1.2rem 1.5rem; }
.book-content li { margin-bottom: .6rem; line-height: 1.6; }
.book-content hr { border: none; border-top: 1px solid var(--line); margin: 3rem 0; }
.book-content b, .book-content strong { font-weight: 700; color: var(--ink); }
.book-content i, .book-content em { font-style: italic; }
.book-content .title { display: none; }

/* ── Footer ── */
.book-footer {
  max-width: 640px; margin: 0 auto 4rem;
  padding: 2rem 2rem 0;
  border-top: 1px solid var(--line);
  display: flex; align-items: center; justify-content: space-between;
  flex-wrap: wrap; gap: 1rem;
}
.book-footer span { color: var(--dim); font-size: .8rem; }
.book-footer a {
  color: var(--dim); text-decoration: none; font-size: .8rem;
  transition: color .15s;
}
.book-footer a:hover { color: var(--ink); }
