:root {
  --night: #140d38;
  --deep: #1d1450;
  --indigo: #2b1b6b;
  --cream: #fff7e8;
  --gold: #ffc93c;
  --coral: #ff5a5f;
  --muted: #b8afdf;
  --display: "Bricolage Grotesque", system-ui, sans-serif;
  --serif: "Literata", Georgia, serif;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--night);
  color: var(--cream);
  font-family: var(--serif);
  font-size: 18px;
  line-height: 1.65;
}
img { max-width: 100%; display: block; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

.wrap { width: min(1120px, 100% - 40px); margin-inline: auto; }

/* header */
.top {
  display: flex; align-items: center; justify-content: space-between;
  padding: 22px 0;
}
.logo {
  font-family: var(--display); font-weight: 800; font-size: 26px;
  letter-spacing: -0.02em; text-decoration: none; display: inline-flex; align-items: center; gap: 10px;
}
.logo img { width: 36px; height: 36px; border-radius: 50%; }
.logo b { font-weight: 800; }
.logo span { color: var(--gold); }
.social { display: flex; gap: 6px; }
.social a {
  font-family: var(--display); font-weight: 600; font-size: 15px;
  text-decoration: none; padding: 6px 12px; border-radius: 999px;
  border: 1px solid rgba(255, 247, 232, .25);
}
.social a:hover { border-color: var(--gold); color: var(--gold); }

/* hero */
.hero { padding: 40px 0 28px; }
.hero h1 {
  font-family: var(--display); font-weight: 800;
  font-size: clamp(64px, 13vw, 168px); line-height: .86; letter-spacing: -0.045em;
  margin: 0;
}
.hero h1 .speed { display: block; color: var(--gold); font-style: italic; transform: skewX(-6deg); transform-origin: left; }
.hero p { font-size: 20px; color: var(--muted); max-width: 34ch; margin: 22px 0 0; }

/* poster rail */
.rail {
  display: grid; grid-auto-flow: column; grid-auto-columns: min(240px, 62vw);
  gap: 16px; overflow-x: auto; scroll-snap-type: x mandatory;
  padding: 24px 20px 30px; margin-inline: -20px;
  scrollbar-width: thin; scrollbar-color: var(--indigo) transparent;
}
.poster {
  scroll-snap-align: start; position: relative; aspect-ratio: 9 / 16;
  border-radius: 22px; overflow: hidden; text-decoration: none;
  background: var(--deep);
}
.poster img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.poster:hover img { transform: scale(1.04); }
.poster .cap {
  position: absolute; inset: auto 0 0 0; padding: 70px 16px 16px;
  background: linear-gradient(transparent, rgba(12, 8, 34, .95));
}
.poster .t { font-family: var(--display); font-weight: 800; font-size: 26px; line-height: 1; letter-spacing: -0.02em; }
.poster .h { font-size: 15px; line-height: 1.35; color: var(--gold); margin-top: 6px; font-style: italic; }

/* series shelves */
.shelf { padding: 26px 0; border-top: 1px solid rgba(255, 247, 232, .12); }
.shelf h2 { font-family: var(--display); font-weight: 800; font-size: 34px; letter-spacing: -0.02em; margin: 0; }
.shelf .count { color: var(--muted); font-size: 16px; }

/* book page */
.book {
  display: grid; grid-template-columns: minmax(260px, 380px) 1fr; gap: 56px;
  padding: 26px 0 40px; align-items: start;
  grid-template-areas: "phone intro" "phone rest";
}
.book .phone { grid-area: phone; }
.book .intro { grid-area: intro; }
.book .rest { grid-area: rest; }
.rest .premise { margin-top: 0; }
.phone {
  position: sticky; top: 20px; aspect-ratio: 9 / 16; border-radius: 30px; overflow: hidden;
  background: #000; border: 8px solid var(--deep); box-shadow: 0 30px 80px rgba(0, 0, 0, .45);
}
.phone iframe { width: 100%; height: 100%; border: 0; display: block; }
.phone .ph { position: relative; width: 100%; height: 100%; }
.phone .ph img { width: 100%; height: 100%; object-fit: cover; filter: brightness(.6); }
.phone .ph .go {
  position: absolute; inset: auto 16px 16px; display: grid; gap: 10px;
}
.crumb { font-family: var(--display); font-weight: 600; font-size: 16px; color: var(--muted); text-decoration: none; }
.crumb:hover { color: var(--gold); }
.book h1 {
  font-family: var(--display); font-weight: 800; font-size: clamp(48px, 7vw, 92px);
  line-height: .92; letter-spacing: -0.04em; margin: 10px 0 6px;
}
.by { color: var(--muted); margin: 0; }
.hook {
  font-family: var(--serif); font-style: italic; font-weight: 500;
  font-size: clamp(26px, 3.4vw, 38px); line-height: 1.2; color: var(--gold);
  margin: 26px 0 28px; max-width: 22ch;
}
.buy { display: flex; flex-wrap: wrap; gap: 12px; }
.btn {
  font-family: var(--display); font-weight: 800; font-size: 18px; text-decoration: none;
  padding: 15px 22px; border-radius: 14px; display: inline-flex; align-items: center; justify-content: center; gap: 8px;
}
.btn.primary { background: var(--gold); color: var(--night); }
.btn.primary:hover { background: #ffd866; }
.btn.ghost { border: 2px solid rgba(255, 247, 232, .35); }
.btn.ghost:hover { border-color: var(--cream); }
.btn.small { font-size: 16px; padding: 12px 16px; }
.disclose { font-size: 14px; color: var(--muted); margin: 12px 0 0; max-width: 52ch; }
.premise { margin-top: 30px; max-width: 62ch; }

details.spoil {
  margin-top: 26px; border-radius: 18px; background: var(--deep);
  border: 1px solid rgba(255, 90, 95, .35); max-width: 66ch;
}
details.spoil summary {
  cursor: pointer; list-style: none; padding: 18px 22px;
  font-family: var(--display); font-weight: 800; font-size: 20px; color: var(--coral);
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
}
details.spoil summary::-webkit-details-marker { display: none; }
details.spoil summary::after { content: "+"; font-size: 28px; line-height: 1; transition: transform .25s ease; }
details.spoil[open] summary::after { transform: rotate(45deg); }
details.spoil .body { padding: 0 22px 10px; }
details.spoil h3 { font-family: var(--display); font-weight: 800; font-size: 24px; margin: 26px 0 4px; color: var(--cream); }

.next {
  display: grid; grid-template-columns: 90px 1fr; gap: 18px; align-items: center;
  margin-top: 34px; padding: 14px; border-radius: 18px; text-decoration: none;
  background: var(--indigo); max-width: 520px;
}
.next img { width: 90px; aspect-ratio: 9 / 16; object-fit: cover; border-radius: 10px; }
.next .l { color: var(--muted); font-size: 15px; }
.next .t { font-family: var(--display); font-weight: 800; font-size: 26px; line-height: 1.05; }
.next:hover { outline: 2px solid var(--gold); }

footer { border-top: 1px solid rgba(255, 247, 232, .12); margin-top: 40px; padding: 30px 0 50px; color: var(--muted); font-size: 15px; }
footer p { margin: 6px 0; max-width: 70ch; }

@media (max-width: 820px) {
  .book { grid-template-columns: 1fr; gap: 28px; }
  .book { grid-template-areas: "intro" "phone" "rest"; }
  .phone { position: relative; top: 0; width: min(300px, 100%); margin-inline: auto; }
  .book .next { margin-inline: auto; }
  .logo { font-size: 22px; }
}
@media (max-width: 560px) {
  .social { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  * { transition: none !important; }
}
