/* =========================================================
   book.css — FULL REPLACEMENT
   Sections: summary · hero (unchanged) · flipbook
========================================================= */

/* =========================================
   BOOK SUMMARY SECTION
========================================= */

.book-summary-section {
  position: relative;
  overflow: hidden;
  padding-block: clamp(2.5rem, 5vh, 4.5rem);
}

.book-summary-layout {
  display: grid;
  grid-template-columns: minmax(0, 0.82fr) minmax(0, 1.18fr);
  align-items: center;
  gap: clamp(2rem, 5vw, 5rem);
  max-width: 1200px;
  margin-inline: auto;
}

/* ---------- cover ---------- */

.book-cover-container {
  position: relative;
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
}

/* warm glow behind the cover */
.book-cover-container::before {
  content: "";
  position: absolute;
  top: 44%;
  left: 50%;
  width: 90%;
  aspect-ratio: 1;
  transform: translate(-50%, -50%);
  background: radial-gradient(closest-side, rgba(192, 149, 90, 0.22), transparent);
  filter: blur(12px);
  pointer-events: none;
  z-index: 0;
}

.book-cover-frame {
  position: relative;
  z-index: 1;
  width: min(100%, 380px);
  aspect-ratio: 2 / 3;
  overflow: visible;
  background: transparent;
  border: 0;
  border-radius: 0;
  box-shadow: none !important;
  transform: none !important;
  transition: none !important;
}

.book-cover-image {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center;
  border: 0;
  /* follows the artwork's shape, so no boxy shadow */
  filter: drop-shadow(0 26px 28px rgba(0, 0, 0, 0.55));
  box-shadow: none !important;
  transform: none !important;
  animation: none !important;
}

.book-cover-stamp {
  position: absolute;
  top: 5%;
  right: -3%;
  z-index: 2;
}

.book-cover-caption {
  position: relative;
  z-index: 1;
  display: block;
  max-width: 380px;
  color: var(--paper-dim);
  font-family: var(--f-docket);
  font-size: 0.62rem;
  letter-spacing: 0.14em;
  line-height: 1.6;
  text-align: center;
}

/* ---------- content ---------- */

.book-summary-content {
  width: 100%;
  max-width: 760px;
}

.book-eyebrow {
  display: inline-block;
  margin-bottom: 0.6rem;
  color: var(--brass);
  font-family: var(--f-docket);
  font-size: 0.72rem;
  letter-spacing: 0.22em;
}

.book-summary-title {
  margin: 0;
  color: var(--paper);
  font-family: var(--f-display);
  font-size: clamp(2.1rem, 3.3vw, 3.3rem);
  font-weight: 500;
  line-height: 1.1;
}

.book-summary-title span {
  color: var(--brass);
}

.book-summary-title small {
  display: block;
  margin-top: 0.5rem;
  color: var(--paper-dim);
  font-family: var(--f-body);
  font-size: 0.42em;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  line-height: 1.45;
}

.book-title-line {
  width: 56px;
  height: 2px;
  margin: 1.1rem 0;
  background: var(--brass);
}

.book-intro {
  max-width: 640px;
  margin: 0;
  color: var(--paper);
  font-family: var(--f-body);
  font-size: 1.1rem;
  font-style: italic;
  line-height: 1.7;
}

/* ---------- book information ---------- */

.book-specifications {
  margin: 1.3rem 0;
  padding: 1rem 0;
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}

.spec-heading {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  margin-bottom: 0.9rem;
  color: var(--brass);
  font-family: var(--f-docket);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
}

.spec-line {
  flex: 1;
  height: 1px;
  background: var(--line);
}

.spec-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.9rem 0;
}

.spec-item {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  padding-inline: 1rem;
  border-left: 1px solid var(--line);
}

.spec-item:first-child {
  padding-left: 0;
  border-left: 0;
}

.spec-item span {
  color: var(--paper-dim);
  font-family: var(--f-docket);
  font-size: 0.64rem;
  letter-spacing: 0.12em;
}

.spec-item strong {
  color: var(--paper);
  font-family: var(--f-body);
  font-size: 0.98rem;
  font-weight: 500;
  line-height: 1.4;
}

/* ---------- about + genres ---------- */

.book-info-label {
  display: block;
  margin-bottom: 0.7rem;
  color: var(--brass);
  font-family: var(--f-docket);
  font-size: 0.7rem;
  letter-spacing: 0.16em;
}

.book-description p {
  margin: 0 0 0.8rem;
  color: var(--paper-dim);
  font-family: var(--f-body);
  font-size: 1.04rem;
  line-height: 1.72;
}

.book-description p:last-child {
  margin-bottom: 0;
}

.book-description em {
  color: var(--paper);
  font-weight: 500;
}

.book-genres {
  margin-top: 1.2rem;
}

.genre-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.genre-tags span {
  padding: 0.45rem 0.8rem;
  color: var(--paper-dim);
  font-family: var(--f-body);
  font-size: 0.84rem;
  background: rgba(27, 33, 42, 0.4);
  border: 1px solid var(--line);
  border-radius: 2px;
  transition: color 0.3s, border-color 0.3s, background 0.3s;
}

.genre-tags span:hover {
  color: var(--brass);
  border-color: var(--brass);
  background: rgba(192, 149, 90, 0.07);
}

/* ---------- action buttons ---------- */

.book-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.8rem;
  margin-top: 1.6rem;
}

.book-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.85rem;
  min-height: 54px;
  padding: 0 1.6rem;
  font-family: var(--f-docket);
  font-size: 0.78rem;
  letter-spacing: 0.13em;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  border: 1px solid var(--brass);
  border-radius: 2px;
  cursor: pointer;
  transition: background 0.3s, color 0.3s, border-color 0.3s, transform 0.3s;
}

.book-btn svg {
  width: 1.25em;
  height: 1.25em;
  flex: none;
  transition: transform 0.3s;
}

.book-btn--primary {
  color: var(--ink);
  background: var(--brass);
}

.book-btn--primary:hover {
  color: var(--brass);
  background: transparent;
}

.book-btn--primary:hover svg {
  transform: translate(3px, -3px);
}

.book-btn--ghost {
  color: var(--paper);
  background: rgba(192, 149, 90, 0.08);
}

.book-btn--ghost:hover {
  color: var(--ink);
  background: var(--brass);
  transform: translateY(-2px);
}

.book-actions-note {
  flex-basis: 100%;
  margin: 0.4rem 0 0;
  color: var(--paper-dim);
  font-family: var(--f-body);
  font-size: 0.88rem;
  font-style: italic;
}

/* ---------- summary: responsive ---------- */

@media (min-width: 901px) and (max-height: 850px) {
  .book-summary-section { padding-block: 1.8rem; }
  .book-cover-frame { width: min(100%, 310px); }
  .book-summary-title { font-size: clamp(1.9rem, 2.8vw, 2.7rem); }
  .book-specifications { margin: 0.9rem 0; padding: 0.75rem 0; }
  .book-description p { font-size: 0.97rem; line-height: 1.6; }
  .book-actions { margin-top: 1.1rem; }
}

@media (max-width: 1000px) {
  .spec-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 0; }
  .spec-item:nth-child(3) { padding-left: 0; border-left: 0; }
}

@media (max-width: 900px) {
  .book-summary-layout { grid-template-columns: minmax(0, 1fr); gap: 2rem; }
  .book-cover-frame { width: min(70%, 320px); }
  .book-summary-content { max-width: 100%; }
}

@media (max-width: 560px) {
  .book-summary-section { padding-block: 3rem; }
  .book-cover-frame { width: min(78%, 280px); }
  .book-summary-title { font-size: clamp(2rem, 8vw, 2.5rem); }
  .book-intro { font-size: 1.05rem; }
  .book-description p { font-size: 1.04rem; line-height: 1.78; }
  .book-actions { flex-direction: column; align-items: stretch; }
  .book-btn { width: 100%; }
  .book-actions-note { text-align: center; }
  .genre-tags span { font-size: 0.78rem; padding: 0.42rem 0.65rem; }
}

/* =========================================
   BOOK HERO SECTION (unchanged)
========================================= */

.phero {
  position: relative;
  min-height: 100vh;
  min-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8rem 0 6rem;
  overflow: hidden;
}

.phero .wrap {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.phero .docket { margin-bottom: 1.5rem; }

.phero h1 {
  margin: 0;
  font-size: clamp(3.5rem, 8vw, 7rem);
  line-height: 1.05;
}

.phero .lede {
  max-width: 750px;
  margin: 1.5rem auto 0;
  font-size: clamp(1.05rem, 1.5vw, 1.3rem);
  line-height: 1.8;
}

@media (max-width: 900px) {
  .phero { min-height: 100svh; padding: 7rem 0 5rem; }
  .phero h1 { font-size: clamp(3rem, 9vw, 5rem); }
}

@media (max-width: 600px) {
  .phero { min-height: 100svh; padding: 6rem 1rem 4rem; }
  .phero h1 { font-size: clamp(2.6rem, 11vw, 4rem); }
  .phero .lede { font-size: 1rem; line-height: 1.7; }
}

/* =========================================================
   FLIPBOOK
   State is driven by  #flipbookBook[data-state]:
     front = closed, cover only (book shifted so cover is centred)
     open  = two-page spread
     back  = closed, back cover (book shifted the other way)
========================================================= */

.flipbook-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 64px 16px 20px;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 50% 38%, rgba(48, 40, 30, 0.96), rgba(9, 9, 11, 0.99) 72%);
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.45s ease, visibility 0.45s ease;
}

.flipbook-overlay.active {
  opacity: 1;
  visibility: visible;
}

.flipbook-container {
  /* page size: limited by screen height AND width, ratio 6 : 9 */
  --page-w: max(110px, min(400px, calc((100svh - 260px) / 1.5), calc((100vw - 32px) / 2)));
  --page-h: calc(var(--page-w) * 1.5);

  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
}

/* ---------- top bar ---------- */

.flipbook-topbar {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  z-index: 5;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px clamp(16px, 3vw, 32px);
}

.flipbook-top-title {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #d9bd8a;
  font-family: "Inter", sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 2px;
}

.flipbook-top-title svg {
  width: 20px;
  height: 20px;
}

/* big, bright, always-visible close button (inline SVG, no icon font needed) */
.flipbook-close {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  padding: 0;
  color: #f4e7cd;
  background: rgba(192, 149, 90, 0.18);
  border: 1.5px solid #c0955a;
  border-radius: 50%;
  cursor: pointer;
  transition: background 0.3s, color 0.3s, transform 0.3s;
}

.flipbook-close svg {
  width: 20px;
  height: 20px;
}

.flipbook-close:hover,
.flipbook-close:focus-visible {
  color: #11141a;
  background: #c0955a;
  transform: rotate(90deg);
}

/* ---------- stage + book ---------- */

.flipbook-stage {
  width: 100%;
  display: flex;
  justify-content: center;
  padding-bottom: 30px;
}

.flipbook-book {
  position: relative;
  width: calc(var(--page-w) * 2);
  height: var(--page-h);
  font-size: max(9px, calc(var(--page-w) / 26));
  perspective: 2600px;
  transform-style: preserve-3d;
  transition: transform 1.2s cubic-bezier(0.45, 0.05, 0.2, 1);
}

/* closed: shift so the single visible page sits in the centre */
.flipbook-book[data-state="front"] { transform: translateX(-25%); }
.flipbook-book[data-state="open"]  { transform: translateX(0); }
.flipbook-book[data-state="back"]  { transform: translateX(25%); }

.flipbook-book.no-anim,
.flipbook-book.no-anim * {
  transition: none !important;
  animation: none !important;
}

/* soft floor shadow */
.flipbook-shadow {
  position: absolute;
  bottom: -28px;
  left: 50%;
  width: 104%;
  height: 40px;
  transform: translateX(-50%);
  background: radial-gradient(closest-side, rgba(0, 0, 0, 0.65), transparent);
  filter: blur(7px);
  pointer-events: none;
  transition: left 1.2s cubic-bezier(0.45, 0.05, 0.2, 1), width 1.2s cubic-bezier(0.45, 0.05, 0.2, 1);
}

.flipbook-book[data-state="front"] .flipbook-shadow { left: 75%; width: 54%; }
.flipbook-book[data-state="back"]  .flipbook-shadow { left: 25%; width: 54%; }

/* ---------- left paper (under flipped pages) ---------- */

.flipbook-left-base {
  position: absolute;
  top: 0;
  left: 0;
  width: 50%;
  height: 100%;
  background: linear-gradient(270deg, #cfc4ac 0%, #efe8d6 6%, #f6f0e2 100%);
  border-radius: 6px 0 0 6px;
  transform: translateZ(-2px);
  opacity: 0;
  transition: opacity 0.6s ease 0.2s;
}

/* stacked page edges on the left */
.flipbook-left-base::before {
  content: "";
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: -6px;
  width: 7px;
  background: repeating-linear-gradient(to left, #f1ead9 0 1px, #d6cbb3 1px 2px);
  border-radius: 3px 0 0 3px;
}

.flipbook-book[data-state="open"] .flipbook-left-base { opacity: 1; }
.flipbook-book[data-state="back"] .flipbook-left-base { opacity: 0; }

/* ---------- right side (sheet stack) ---------- */

.flipbook-right-page {
  position: absolute;
  top: 0;
  left: 50%;
  width: 50%;
  height: 100%;
  transform-style: preserve-3d;
}

/* paper block under the sheets + stacked page edges on the right */
.flipbook-right-page::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, #cfc4ac 0%, #f6f0e2 6%, #f1ead9 100%);
  border-radius: 0 6px 6px 0;
  transform: translateZ(-2px);
  transition: opacity 0.5s ease 0.3s;
}

.flipbook-right-page::after {
  content: "";
  position: absolute;
  top: 3px;
  bottom: 3px;
  right: -6px;
  width: 7px;
  background: repeating-linear-gradient(to right, #f1ead9 0 1px, #d6cbb3 1px 2px);
  border-radius: 0 3px 3px 0;
  transform: translateZ(-3px);
  transition: opacity 0.5s ease 0.3s;
}

.flipbook-book[data-state="back"] .flipbook-right-page::before,
.flipbook-book[data-state="back"] .flipbook-right-page::after {
  opacity: 0;
}

.flipbook-sheet {
  position: absolute;
  inset: 0;
  transform-origin: left center;
  transform-style: preserve-3d;
  transition: transform 1.2s cubic-bezier(0.45, 0.05, 0.2, 1);
  cursor: pointer;
}

.flipbook-sheet.flipped {
  transform: rotateY(-180deg);
}

/* gentle "peek" when hovering the page that will turn next */
@media (hover: hover) {
  .flipbook-sheet.is-next:not(.flipped):hover {
    transform: rotateY(-7deg);
  }
  .flipbook-sheet.is-prev.flipped:hover {
    transform: rotateY(-173deg);
  }
}

/* ---------- paper faces ---------- */

.flipbook-face {
  position: absolute;
  inset: 0;
  overflow: hidden;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  background-color: #f6f0e2;
}

.flipbook-front {
  border-radius: 0 6px 6px 0;
  background-image:
    linear-gradient(90deg, rgba(70, 48, 15, 0.24) 0, rgba(70, 48, 15, 0.07) 3.5%, rgba(255, 255, 255, 0) 10%),
    linear-gradient(90deg, rgba(255, 255, 255, 0) 80%, rgba(120, 90, 50, 0.1) 100%);
}

.flipbook-back {
  transform: rotateY(180deg);
  border-radius: 6px 0 0 6px;
  background-image:
    linear-gradient(270deg, rgba(70, 48, 15, 0.24) 0, rgba(70, 48, 15, 0.07) 3.5%, rgba(255, 255, 255, 0) 10%),
    linear-gradient(270deg, rgba(255, 255, 255, 0) 80%, rgba(120, 90, 50, 0.1) 100%);
}

/* moving shadow while a page is turning */
.flipbook-face::after {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.38));
}

.flipbook-back::after {
  background: linear-gradient(270deg, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.38));
}

.flipbook-sheet.turning .flipbook-face::after {
  animation: page-shade 1.2s ease-in-out;
}

@keyframes page-shade {
  0%   { opacity: 0; }
  50%  { opacity: 1; }
  100% { opacity: 0; }
}

/* ---------- page content (everything scales with the book) ---------- */

.flipbook-page-content {
  position: relative;
  height: 100%;
  padding: 3.4em 2.8em;
  display: flex;
  flex-direction: column;
  justify-content: center;
  color: #39352e;
}

.flipbook-small-label {
  display: block;
  margin-bottom: 1.6em;
  color: #a47a43;
  font-family: "Inter", sans-serif;
  font-size: max(7px, 0.62em);
  font-weight: 700;
  letter-spacing: 0.28em;
}

.flipbook-page-content h2 {
  margin: 0 0 0.75em;
  color: #302a22;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 2.3em;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: 0;
}

.flipbook-page-content p {
  margin: 0 0 0.9em;
  color: #5f564a;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.12em;
  line-height: 1.7;
}

.flipbook-page-number {
  position: absolute;
  bottom: 1.8em;
  left: 50%;
  transform: translateX(-50%);
  color: #9a8b75;
  font-family: "Inter", sans-serif;
  font-size: max(7px, 0.66em);
  letter-spacing: 0.1em;
}

/* ---------- cover ---------- */

.flipbook-front.flipbook-cover {
  border-radius: 4px 10px 10px 4px;
  color: #d7bd8e;
  background-color: #17140f;
  background-image:
    linear-gradient(135deg, rgba(255, 255, 255, 0.07), transparent 42%),
    radial-gradient(ellipse at 70% 20%, #2e2a22, #11110f 78%);
  box-shadow:
    inset 0 0 0 1px rgba(202, 170, 112, 0.35),
    inset 0 0 40px rgba(0, 0, 0, 0.55);
}

/* spine hinge on the cover */
.flipbook-cover::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 7%;
  background: linear-gradient(90deg, rgba(0, 0, 0, 0.6), rgba(255, 255, 255, 0.08) 45%, rgba(0, 0, 0, 0.4) 75%, transparent);
  z-index: 2;
  pointer-events: none;
}

/* ---------- cover image layer ---------- */

.flipbook-cover-art {
  position: absolute;
  inset: 0;
  z-index: 1;
  background: #17140f;
}

.flipbook-cover-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}

/* hardcover sheen: light catching the board + darker edges */
.flipbook-cover-art::after {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    linear-gradient(115deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0) 32%),
    linear-gradient(270deg, rgba(0, 0, 0, 0.28), rgba(0, 0, 0, 0) 7%),
    linear-gradient(0deg, rgba(0, 0, 0, 0.22), rgba(0, 0, 0, 0) 12%);
}

/* keep the spine hinge above the image */
.flipbook-cover::before {
  z-index: 3;
}

.flipbook-cover-inner {
  position: relative;
  height: calc(100% - 2.2em);
  margin: 1.1em 1.1em 1.1em 2em;
  padding: 2.5em 1.6em;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border: 1px solid rgba(202, 170, 112, 0.45);
}

.flipbook-cover-label {
  margin-bottom: 2.4em;
  color: #c8a878;
  font-family: "Inter", sans-serif;
  font-size: max(7px, 0.6em);
  font-weight: 600;
  letter-spacing: 0.4em;
}

.flipbook-cover h2 {
  margin: 0;
  color: #ead8b5;
  font-family: "Cinzel", Georgia, serif;
  font-size: 2em;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.08em;
  text-shadow: 0 1px 0 rgba(0, 0, 0, 0.6), 0 0 18px rgba(192, 149, 90, 0.25);
}

.flipbook-cover h2 span {
  display: block;
  margin-top: 0.2em;
  color: #c7a46f;
}

.flipbook-cover-divider {
  width: 3.6em;
  height: 1px;
  margin: 1.8em 0;
  background: #b58b50;
}

.flipbook-cover-inner > p {
  margin: 0;
  color: #d8c4a0;
  font-family: "Inter", sans-serif;
  font-size: max(7px, 0.6em);
  font-weight: 600;
  letter-spacing: 0.3em;
}

.flipbook-cover-bottom {
  position: absolute;
  bottom: 1.8em;
  left: 0;
  right: 0;
  padding-inline: 1em;
  color: #9f8b6a;
  font-family: "Inter", sans-serif;
  font-size: max(6px, 0.46em);
  letter-spacing: 0.2em;
}

/* ---------- back cover ---------- */

.flipbook-back.flipbook-ending {
  border-radius: 10px 4px 4px 10px;
  color: #d8c19a;
  background-color: #141311;
  background-image: radial-gradient(circle at center, #302b22, #141311 75%);
  box-shadow: inset 0 0 40px rgba(0, 0, 0, 0.55);
}

.flipbook-ending-content {
  height: calc(100% - 2.2em);
  margin: 1.1em 2em 1.1em 1.1em;
  padding: 2em;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  border: 1px solid rgba(202, 170, 112, 0.35);
}

.flipbook-ending-content span {
  color: #b58b50;
  font-family: "Inter", sans-serif;
  font-size: max(7px, 0.6em);
  font-weight: 700;
  letter-spacing: 0.4em;
}

.flipbook-ending-content h2 {
  margin: 1.2em 0;
  color: #ead9b9;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 2em;
  font-style: italic;
  font-weight: 500;
  line-height: 1.2;
}

.flipbook-ending-content p {
  margin: 0;
  color: #b7a487;
  font-family: "Cormorant Garamond", Georgia, serif;
  font-size: 1.05em;
  font-style: italic;
}

/* ---------- controls ---------- */

.flipbook-controls {
  width: min(560px, 100%);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 1rem;
  margin-top: 14px;
}

.flipbook-nav-button {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  min-height: 46px;
  padding: 0 1.2rem;
  color: #ecdcc0;
  background: transparent;
  border: 1px solid rgba(236, 220, 192, 0.35);
  border-radius: 2px;
  font-family: "Inter", sans-serif;
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.16em;
  cursor: pointer;
  transition: background 0.3s, color 0.3s, border-color 0.3s, opacity 0.3s;
}

.flipbook-nav-button svg {
  width: 16px;
  height: 16px;
  flex: none;
}

#flipbookPrev { justify-self: start; }
#flipbookNext { justify-self: end; }

.flipbook-nav-button--primary {
  color: #11141a;
  background: #c0955a;
  border-color: #c0955a;
}

.flipbook-nav-button:hover:not(:disabled) {
  color: #11141a;
  background: #d9b27a;
  border-color: #d9b27a;
}

.flipbook-nav-button:disabled {
  opacity: 0.28;
  cursor: not-allowed;
}

.flipbook-progress {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.55rem;
  min-width: 90px;
  text-align: center;
}

.flipbook-status {
  color: #e8d6b4;
  font-family: "Inter", sans-serif;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  white-space: nowrap;
}

.flipbook-dots {
  display: flex;
  gap: 6px;
}

.flipbook-dots i {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(236, 220, 192, 0.25);
  transition: background 0.3s, transform 0.3s;
}

.flipbook-dots i.on {
  background: #c0955a;
  transform: scale(1.35);
}

.flipbook-hint {
  margin: 16px 0 0;
  color: rgba(255, 255, 255, 0.5);
  font-family: "Inter", sans-serif;
  font-size: 11px;
  letter-spacing: 0.04em;
  text-align: center;
}

.flipbook-hint b {
  color: #c0955a;
  font-weight: 600;
}

/* ---------- flipbook: mobile ---------- */

@media (max-width: 560px) {
  .flipbook-overlay { padding-top: 60px; }
  .flipbook-page-content { padding: 2.4em 1.6em; }
  .flipbook-page-content h2 { font-size: 1.9em; margin-bottom: 0.6em; }
  .flipbook-page-content p { font-size: 1.1em; line-height: 1.55; }
  .flipbook-page-content p:nth-of-type(2) { display: none; }
  .flipbook-small-label { margin-bottom: 1.1em; }
  .flipbook-cover-inner { padding: 1.6em 0.8em; margin-left: 1.6em; }
  .flipbook-cover-label { margin-bottom: 1.6em; letter-spacing: 0.25em; }
  .flipbook-cover h2 { font-size: 1.7em; }
  .flipbook-cover-bottom { display: none; }
  .flipbook-ending-content { padding: 1em; }
  .flipbook-nav-button { padding: 0 0.9rem; gap: 0.5rem; letter-spacing: 0.1em; }
  .flipbook-top-title { font-size: 9px; letter-spacing: 1.4px; }
}

@media (max-width: 380px) {
  .flipbook-nav-button span { display: none; }
  .flipbook-nav-button { padding: 0 1rem; }
}

/* ---------- reduced motion ---------- */

@media (prefers-reduced-motion: reduce) {
  .flipbook-overlay,
  .flipbook-book,
  .flipbook-shadow,
  .flipbook-sheet,
  .book-btn,
  .flipbook-nav-button {
    transition-duration: 0.01ms !important;
  }
  .flipbook-sheet.turning .flipbook-face::after { animation: none; }
}







































/* =========================================================
   BOOK TRAILER SECTION
========================================================= */

.book-trailer-section {
  position: relative;
  overflow: hidden;
  padding-block: clamp(4rem, 8vw, 7rem);
}

.book-trailer-heading {
  max-width: 800px;
  margin: 0 auto 3rem;
  text-align: center;
}

.book-trailer-eyebrow {
  display: inline-block;
  margin-bottom: 1rem;
  color: var(--brass);
  font-family: var(--f-docket);
  font-size: 0.72rem;
  letter-spacing: 0.24em;
}

.book-trailer-heading h2 {
  margin: 0;
  color: var(--paper);
  font-family: var(--f-display);
  font-size: clamp(2.3rem, 5vw, 4rem);
  font-weight: 500;
  line-height: 1.15;
}

.book-trailer-heading h2 span {
  color: var(--brass);
}

.book-trailer-heading p {
  max-width: 650px;
  margin: 1rem auto 0;
  color: var(--paper-dim);
  font-family: var(--f-body);
  font-size: 1.05rem;
  line-height: 1.8;
}

.book-trailer-heading p em {
  color: var(--paper);
}

/* Video frame */

.book-trailer-frame {
  position: relative;
  width: min(100%, 1000px);
  margin-inline: auto;
  padding: 10px;
  background: rgba(192, 149, 90, 0.08);
  border: 1px solid rgba(192, 149, 90, 0.4);
  box-shadow: 0 25px 70px rgba(0, 0, 0, 0.4);
}

.book-trailer-video {
  position: relative;
  width: 100%;
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: #090909;
}

.book-trailer-video iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}

/* Decorative footer */

.book-trailer-footer {
  width: min(100%, 1000px);
  margin: 1.4rem auto 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  color: var(--paper-dim);
  font-family: var(--f-docket);
  font-size: 0.65rem;
  letter-spacing: 0.17em;
  text-align: center;
}

.trailer-divider {
  width: 35px;
  height: 1px;
  background: var(--brass);
}

/* Responsive */

@media (max-width: 600px) {
  .book-trailer-section {
    padding-block: 3.5rem;
  }

  .book-trailer-heading {
    margin-bottom: 2rem;
  }

  .book-trailer-heading p {
    font-size: 0.98rem;
  }

  .book-trailer-frame {
    padding: 5px;
  }

  .book-trailer-footer {
    gap: 0.6rem;
    font-size: 0.55rem;
    letter-spacing: 0.1em;
  }

  .trailer-divider {
    width: 20px;
  }
}




















/* Center CTA Section */
.cta {
  text-align: center;
}

.cta .wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.cta .rule {
  width: 100%;
}

.cta h2 {
  text-align: center;
  margin-inline: auto;
}

.cta .row {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  width: 100%;
}