@font-face { font-family: "Quicksand"; src: url("Quicksand.ttf") format("truetype"); font-display: swap; }
:root {
  --cream: #fbf5e9; --paper: #fffdf8; --ink: #3d2b1f; --soft: #6b5646;
  --red: #a82d23; --sky: #cfe6f7; --grass: #8fbf4a; --sun: #f4c430; --line: #eadfca;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--cream); color: var(--ink); font: 18px/1.6 "Quicksand", system-ui, sans-serif; font-weight: 500; }
img { max-width: 100%; height: auto; display: block; }
a { color: var(--red); }
.top { padding: 18px 20px; text-align: center; background: linear-gradient(var(--sky), var(--cream)); }
.brand { font-weight: 700; font-size: 20px; color: var(--ink); text-decoration: none; letter-spacing: .3px; }
.brand span { color: var(--red); }
main { max-width: 1080px; margin: 0 auto; padding: 0 16px 40px; }
.hero { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: start; padding: 28px 0 10px; }
.cover { border-radius: 14px; box-shadow: 0 18px 40px rgba(61,43,31,.22); }
.series { margin: 0; color: var(--soft); font-size: 15px; text-transform: uppercase; letter-spacing: 1.2px; font-weight: 700; }
h1 { font-size: 46px; line-height: 1.1; margin: 6px 0 4px; color: var(--red); }
.by { margin: 0 0 18px; color: var(--soft); }
.lead { font-size: 22px; }
.shout { font-size: 22px; font-weight: 700; background: var(--paper); border-left: 6px solid var(--sun); padding: 10px 16px; border-radius: 8px; }
h2 { font-size: 26px; margin: 0 0 6px; }
.buy { display: grid; gap: 14px; margin-top: 22px; }
.option { background: var(--paper); border: 2px solid var(--line); border-radius: 16px; padding: 18px 20px; }
.option h2 { font-size: 21px; display: flex; justify-content: space-between; gap: 10px; }
.option h2 span { color: var(--red); white-space: nowrap; }
.option p { margin: 0 0 12px; font-size: 16px; color: var(--soft); }
.soon { font-weight: 700; color: var(--ink) !important; }
.amazon { margin: 0; font-size: 16px; }
.btn { display: inline-block; border: 0; cursor: pointer; background: var(--red); color: #fff; font: inherit; font-weight: 700; font-size: 18px; padding: 13px 24px; border-radius: 999px; text-decoration: none; box-shadow: 0 4px 0 #7d1f17; }
.btn:hover { filter: brightness(1.08); }
.btn:active { transform: translateY(2px); box-shadow: 0 2px 0 #7d1f17; }
.btn:disabled { opacity: .6; cursor: wait; }
.checkout { background: var(--paper); border: 2px solid var(--line); border-radius: 18px; padding: 24px; margin: 30px auto; max-width: 560px; }
.checkout label { display: block; margin-bottom: 14px; font-weight: 700; }
.checkout input, .checkout textarea { display: block; width: 100%; margin-top: 4px; font: inherit; font-weight: 500; padding: 11px 12px; border: 2px solid var(--line); border-radius: 10px; background: #fff; color: var(--ink); }
.checkout small { display: block; font-weight: 500; color: var(--soft); font-size: 14px; }
#payment-element { margin: 8px 0 16px; min-height: 40px; }
.error { color: var(--red); font-weight: 700; min-height: 1em; }
.small { font-size: 14px; color: var(--soft); }
.inside { padding: 30px 0 10px; text-align: center; }
.pages { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-top: 14px; }
.pages img { border-radius: 10px; box-shadow: 0 8px 20px rgba(61,43,31,.15); }
.hint { color: var(--soft); }
.author { display: flex; gap: 24px; align-items: center; background: var(--paper); border-radius: 18px; padding: 22px; margin-top: 30px; }
.author img { width: 150px; border-radius: 50%; flex: none; }
.author p { margin: 0; }
footer { text-align: center; padding: 26px 16px 40px; font-size: 14px; color: var(--soft); }
.thanks { max-width: 560px; margin: 0 auto; padding: 30px 16px 60px; text-align: center; }
.thanks .brand { display: block; margin-bottom: 26px; }
.thanks-cover { margin: 0 auto 16px; border-radius: 12px; box-shadow: 0 12px 28px rgba(61,43,31,.2); }
@media (max-width: 820px) {
  .hero { grid-template-columns: 1fr; gap: 22px; }
  h1 { font-size: 36px; }
  .pages { grid-template-columns: repeat(2, 1fr); }
  .author { flex-direction: column; text-align: center; }
}
[hidden] { display: none !important; }
.ways { display: grid; gap: 12px; margin: 18px 0; text-align: left; }
.way { display: block; background: var(--paper); border: 2px solid var(--line); border-radius: 16px; padding: 14px 18px; color: var(--ink); text-decoration: none; }
.way:first-child { border-color: var(--red); background: #fff; }
.way strong { display: block; font-size: 20px; color: var(--red); }
.way span { font-size: 15px; color: var(--soft); }
.way:hover { border-color: var(--red); }
.more { padding: 34px 0 6px; }
.more > h2 { text-align: center; font-size: 32px; color: var(--red); }
.more > .hint { text-align: center; margin: 0 auto 10px; max-width: 640px; }
.book > * { min-width: 0; }
.book { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 30px; align-items: start; background: var(--paper); border: 2px solid var(--line); border-radius: 20px; padding: 22px; margin-top: 22px; }
.book h3 { font-size: 32px; line-height: 1.15; margin: 4px 0 8px; color: var(--red); }
.book .lead { margin: 0 0 8px; }
.book p { margin: 0 0 12px; }
.peek { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin: 6px 0 16px; }
.peek img { border-radius: 8px; box-shadow: 0 6px 14px rgba(61,43,31,.13); }
@media (max-width: 820px) {
  .book { grid-template-columns: minmax(0, 1fr); gap: 16px; padding: 16px; }
  .book .cover { max-width: min(340px, 100%); margin: 0 auto; }
  .book h3 { font-size: 27px; }
  .book .btn { width: 100%; text-align: center; }
}

/* All 5 books set */
.set { text-align: center; background: var(--paper); border: 3px solid var(--red); border-radius: 22px; padding: 24px 18px; margin: 26px 0 10px; }
.set h2 { font-size: 32px; color: var(--red); margin: 2px 0 14px; }
.set-covers { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; max-width: 760px; margin: 0 auto 14px; }
.set-covers img { width: 100%; height: auto; border-radius: 8px; box-shadow: 0 6px 14px rgba(61,43,31,.18); }
.set p { max-width: 560px; margin: 0 auto 16px; }
@media (max-width: 700px) { .set h2 { font-size: 26px; } .set-covers { gap: 6px; } .set .btn { width: 100%; } }
.setbook { display: grid; grid-template-columns: 120px minmax(0, 1fr); gap: 14px; align-items: start; text-align: left; margin: 22px 0; }
.setbook img { border-radius: 8px; box-shadow: 0 6px 14px rgba(61,43,31,.18); }
.setbook h2 { font-size: 20px; margin: 0; color: var(--ink); }
.setbook .ways { margin: 8px 0 0; gap: 8px; }
.setbook .way { padding: 10px 14px; }
.setbook .way strong { font-size: 17px; }
@media (max-width: 480px) { .setbook { grid-template-columns: 70px minmax(0, 1fr); } .setbook img { width: 70px; height: 70px; } }
/* Series links at the top + Hugo section */
.series-nav { display: flex; gap: 10px; flex-wrap: wrap; justify-content: center; margin-top: 8px; }
.series-nav a { background: var(--paper); border: 2px solid var(--line); border-radius: 16px; padding: 8px 12px 10px; color: var(--ink); text-decoration: none; font-weight: 600; font-size: 15px; display: flex; flex-direction: column; align-items: center; gap: 7px; }
.series-nav a:hover { border-color: var(--red); }
.nav-covers { display: flex; gap: 4px; }
.nav-covers img { width: 40px; height: 40px; border-radius: 4px; box-shadow: 0 1px 3px rgba(0,0,0,.18); display: block; }
@media (max-width: 520px) { .series-nav a { width: 100%; max-width: 330px; } .nav-covers img { width: 48px; height: 48px; } }
.series-nav em { font-style: normal; color: var(--red); }
.hugo { border-top: 3px dashed var(--line); margin-top: 34px; }
.hugo > .series { text-align: center; margin: 0; }

/* ===== "All the books" gift banner (top of page) ===== */
.gift { position: relative; overflow: hidden; color: #fff; background: radial-gradient(ellipse at 30% 20%, #3a4fd0 0%, #1d2a8a 45%, #120f4a 100%); padding: 34px 16px 40px; }
.gift-sky { position: absolute; inset: 0; pointer-events: none; }
.gift-sky i { position: absolute; top: -20px; left: calc(var(--x) * 1%); width: 9px; height: 14px; background: var(--c); border-radius: 2px; opacity: .9; animation: confetti 6s linear var(--d) infinite; }
@keyframes confetti { to { transform: translateY(560px) rotate(540deg); } }
.gift-inner { position: relative; max-width: 1080px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1.15fr; gap: 34px; align-items: center; }
.gift-art img { border-radius: 18px; box-shadow: 0 20px 50px rgba(0,0,0,.45); }
.gift-box { position: relative; aspect-ratio: 1; max-width: 430px; margin: 0 auto; }
.gift-covers { display: grid; grid-template-columns: repeat(5, 1fr); gap: 5px; padding: 12px; background: #c0392b; border-radius: 16px; box-shadow: 0 20px 50px rgba(0,0,0,.45), inset 0 0 0 6px #f4c430; }
.gift-covers img { border-radius: 5px; }
.gift-box .lid { position: absolute; z-index: 2; left: -4%; right: -4%; top: -6%; height: 16%; background: #d84a3a; border-radius: 10px; box-shadow: inset 0 0 0 6px #f4c430, 0 8px 18px rgba(0,0,0,.3); }
.gift-box .bow { position: absolute; z-index: 3; left: 50%; top: -15%; width: 110px; height: 60px; margin-left: -55px; background: radial-gradient(circle at 25% 60%, #f4c430 0 28%, transparent 30%), radial-gradient(circle at 75% 60%, #f4c430 0 28%, transparent 30%), radial-gradient(circle at 50% 70%, #e0a800 0 14%, transparent 16%); }
.gift-kicker { margin: 0; font-weight: 700; text-transform: uppercase; letter-spacing: 2px; color: #f4c430; font-size: 16px; }
.gift-nots { list-style: none; margin: 8px 0 4px; padding: 0; font-size: 30px; font-weight: 700; line-height: 1.35; }
.gift-nots li { position: relative; display: table; color: #cfd8ff; }
.gift-nots li::after { content: ""; position: absolute; left: -4px; right: -4px; top: 52%; height: 5px; background: #ff5a4a; border-radius: 3px; transform: rotate(-4deg); }
.gift-yes { font-size: 46px; line-height: 1.1; margin: 10px 0 8px; color: #fff; }
.gift-yes span { color: #9be15d; display: inline-block; }
.gift-yes strong { color: #f4c430; white-space: nowrap; font-size: 1.25em; }
.gift-small { margin: 0 0 18px; color: #e3e8ff; font-size: 17px; }
.gift-btn { font-size: 21px; padding: 15px 28px; background: #f4c430; color: #3d2b1f; box-shadow: 0 5px 0 #b88c00; }
.gift-btn:active { box-shadow: 0 2px 0 #b88c00; }
.gift-again { display: block; margin-top: 12px; background: none; border: 0; color: #cfd8ff; font: inherit; font-size: 14px; cursor: pointer; text-decoration: underline; padding: 0; }
/* the show: lid pops, each "Not…" slams in and is crossed out, then the YES lands */
.gift.go .lid { animation: lid 1s cubic-bezier(.3,1.6,.5,1) .3s both; }
@keyframes lid { 0% { transform: none; } 60% { transform: translateY(-60%) rotate(-12deg); } 100% { transform: translateY(-34%) rotate(-8deg); } }
.gift.go .gift-covers { animation: pop .9s cubic-bezier(.3,1.6,.5,1) .5s both; }
@keyframes pop { from { transform: scale(.6); opacity: 0; } to { transform: none; opacity: 1; } }
.gift.go .gift-nots li { animation: slam .45s cubic-bezier(.3,1.6,.5,1) both; }
.gift.go .gift-nots li::after { animation: strike .35s ease-out both; transform-origin: left; }
.gift.go .gift-nots li:nth-child(1) { animation-delay: 1.0s; } .gift.go .gift-nots li:nth-child(1)::after { animation-delay: 1.6s; }
.gift.go .gift-nots li:nth-child(2) { animation-delay: 2.2s; } .gift.go .gift-nots li:nth-child(2)::after { animation-delay: 2.8s; }
.gift.go .gift-nots li:nth-child(3) { animation-delay: 3.4s; } .gift.go .gift-nots li:nth-child(3)::after { animation-delay: 4.0s; }
@keyframes slam { from { opacity: 0; transform: scale(1.8); } to { opacity: 1; transform: none; } }
@keyframes strike { from { transform: rotate(-4deg) scaleX(0); } to { transform: rotate(-4deg) scaleX(1); } }
.gift.go .gift-yes, .gift.go .gift-small, .gift.go .gift-btn { animation: rise .7s cubic-bezier(.3,1.6,.5,1) 4.7s both; }
.gift.go .gift-yes span { animation: boing 1s ease-in-out 5.4s 3; }
@keyframes rise { from { opacity: 0; transform: translateY(30px) scale(.9); } to { opacity: 1; transform: none; } }
@keyframes boing { 50% { transform: scale(1.25) rotate(-6deg); } }
.gift.go .gift-btn { animation: rise .7s cubic-bezier(.3,1.6,.5,1) 5s both, glow 1.6s ease-in-out 6s infinite; }
@keyframes glow { 50% { box-shadow: 0 5px 0 #b88c00, 0 0 0 10px rgba(244,196,48,.35); } }
.gift.still .gift-sky { display: none; }
@media (max-width: 820px) {
  .gift-inner { grid-template-columns: 1fr; gap: 26px; text-align: center; }
  .gift-art { max-width: 300px; margin: 22px auto 0; width: 100%; order: 2; }
  .gift-nots li { margin: 0 auto; } .gift-nots { font-size: 24px; }
  .gift-yes { font-size: 34px; } .gift-btn { width: 100%; } .gift-again { margin: 12px auto 0; }
}
.gift.go .gift-art img { animation: pop 1s cubic-bezier(.3,1.6,.5,1) .3s both, float 4s ease-in-out 1.5s infinite; }
@keyframes float { 50% { transform: translateY(-8px) rotate(-1deg); } }
