:root {
  --paper: #fbf8f3;
  --paper2: #f3eee5;
  --card: #ffffff;
  --ink: #15120f;
  --ink2: #4a443d;
  --ink3: #857c71;
  --line: #e7e0d4;
  --accent: #e8541e;
  --accent2: #ff7a3d;
  --accent-ink: #ffffff;
  --deep: #10172a;
  --gold: #f4b740;
  --green: #12805c;
  --r: 20px;
  --serif: 'Fraunces', Georgia, serif;
  --sans: 'Inter', system-ui, -apple-system, sans-serif;
  --shadow: 0 1px 2px rgba(21, 18, 15, .04), 0 12px 32px -12px rgba(21, 18, 15, .18);
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--sans); font-size: 16px; line-height: 1.6; -webkit-font-smoothing: antialiased; overflow-x: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; }
svg { display: block; }
.wrap { width: min(1200px, 100% - 32px); margin-inline: auto; }
.narrow { width: min(780px, 100% - 32px); }

/* sale bar */
.salebar { background: var(--deep); color: #fff; font-size: 14px; overflow: hidden; }
.salebar b { color: var(--gold); }
.ticker { overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 4%, #000 96%, transparent); }
.ticker-track { display: flex; align-items: center; width: max-content; padding: 9px 0; animation: ticker 40s linear infinite; }
.salebar:hover .ticker-track { animation-play-state: paused; }
.tick-item { display: inline-flex; align-items: center; gap: 10px; white-space: nowrap; padding: 0 22px; }
.tick-star { width: 12px; height: 12px; fill: var(--gold); flex: none; }
@keyframes ticker { to { transform: translateX(-25%); } }
.countdown { display: inline-flex; gap: 6px; font-variant-numeric: tabular-nums; font-weight: 700; }
.countdown span { background: rgba(255, 255, 255, .12); border-radius: 6px; padding: 1px 7px; }

/* nav */
.nav { position: sticky; top: 0; z-index: 40; background: rgba(251, 248, 243, .82); backdrop-filter: blur(14px) saturate(1.4); -webkit-backdrop-filter: blur(14px) saturate(1.4); border-bottom: 1px solid transparent; transition: border-color .3s; }
.nav.scrolled { border-bottom-color: var(--line); }
.nav-in { display: flex; align-items: center; gap: 28px; height: 68px; }
.logo { display: flex; align-items: center; gap: 10px; text-decoration: none; font-family: var(--serif); font-weight: 800; font-size: 20px; letter-spacing: -.01em; }
/* Header lockup: "Powered by" over the foundation's name. */
.logo-txt { display: flex; flex-direction: column; line-height: 1.05; font-size: 16px; letter-spacing: .04em; }
.logo-txt small { font-family: var(--sans, Inter, system-ui, sans-serif); font-size: 10px; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--ink3); margin-bottom: 3px; }
@media (max-width: 480px) { .logo-txt { font-size: 13.5px; } .logo-txt small { font-size: 9px; } }
.logo svg { width: 26px; height: 26px; fill: none; stroke: var(--accent); stroke-width: 3.2; stroke-linecap: round; }
.nav-links { display: flex; gap: 26px; margin-left: auto; }
.nav-links a { text-decoration: none; color: var(--ink2); font-weight: 500; font-size: 15px; }
.nav-links a:hover { color: var(--ink); }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border-radius: 999px; font-weight: 700; text-decoration: none; border: 0; cursor: pointer; font-family: var(--sans); transition: transform .15s, box-shadow .2s, background .2s; white-space: nowrap; }
.btn:active { transform: scale(.98); }
.btn-sm { padding: 10px 18px; font-size: 14px; }
.btn-lg { padding: 17px 30px; font-size: 17px; }
.btn-md { padding: 13px 22px; font-size: 15px; }
.btn-dark { background: var(--ink); color: #fff; }
.btn-dark:hover { background: #2c2620; }
.btn-accent { background: linear-gradient(135deg, var(--accent2), var(--accent)); color: var(--accent-ink); box-shadow: 0 10px 30px -10px rgba(232, 84, 30, .7), inset 0 1px 0 rgba(255, 255, 255, .25); position: relative; overflow: hidden; }
.btn-accent::after { content: ''; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255, 255, 255, .35) 50%, transparent 70%); transform: translateX(-120%); animation: shine 3.8s ease-in-out infinite; }
.btn-accent:hover { box-shadow: 0 16px 40px -12px rgba(232, 84, 30, .85), inset 0 1px 0 rgba(255, 255, 255, .25); transform: translateY(-1px); }
@keyframes shine { 0%, 55% { transform: translateX(-120%); } 85%, 100% { transform: translateX(120%); } }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn-ghost:hover { box-shadow: inset 0 0 0 1.5px var(--ink); }

/* hero */
.hero { position: relative; padding: 56px 0 30px; overflow: hidden; }
.hero::before { content: ''; position: absolute; width: 900px; height: 900px; right: -260px; top: -380px; background: radial-gradient(circle, rgba(255, 122, 61, .22), transparent 62%); pointer-events: none; }
.hero::after { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: .5;
  background-image: radial-gradient(rgba(21, 18, 15, .07) 1px, transparent 1px); background-size: 22px 22px;
  mask-image: radial-gradient(ellipse 70% 60% at 30% 30%, #000, transparent 75%); -webkit-mask-image: radial-gradient(ellipse 70% 60% at 30% 30%, #000, transparent 75%); }
.hero-in { position: relative; z-index: 1; display: grid; grid-template-columns: 1.05fr .95fr; gap: 56px; align-items: center; }
.pill { display: inline-flex; align-items: center; gap: 10px; padding: 7px 14px 7px 10px; border-radius: 999px; background: #fff; box-shadow: var(--shadow), inset 0 0 0 1px var(--line); font-size: 14px; font-weight: 600; text-decoration: none; color: var(--ink2); }
.pill-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 0 rgba(232, 84, 30, .6); animation: pulse 2s infinite; }
@keyframes pulse { 70% { box-shadow: 0 0 0 9px rgba(232, 84, 30, 0); } 100% { box-shadow: 0 0 0 0 rgba(232, 84, 30, 0); } }
.hero h1 { font-family: var(--serif); font-weight: 800; font-size: clamp(42px, 6.2vw, 78px); line-height: .98; letter-spacing: -.035em; margin: 22px 0 20px; }
.hero h1 em { font-style: italic; color: var(--accent); }
.lede { font-size: clamp(17px, 1.6vw, 20px); color: var(--ink2); max-width: 560px; margin: 0 0 30px; }
.hero-cta { display: flex; gap: 12px; flex-wrap: wrap; }
.trust { list-style: none; padding: 0; margin: 30px 0 0; display: flex; flex-wrap: wrap; gap: 10px 22px; color: var(--ink2); font-size: 14px; font-weight: 500; }
.trust li { display: flex; align-items: center; gap: 8px; }
.trust svg { width: 18px; height: 18px; fill: none; stroke: var(--green); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }

.hero-art { position: relative; min-height: 520px; }
.portrait { position: relative; width: min(440px, 88%); margin-left: auto; aspect-ratio: 1; border-radius: 32px; overflow: hidden; box-shadow: 0 40px 80px -30px rgba(21, 18, 15, .55); transform: rotate(1.5deg); }
.portrait img { width: 100%; height: 100%; object-fit: cover; }
.portrait::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 55%, rgba(16, 23, 42, .75)); }
.portrait-tag { position: absolute; left: 22px; bottom: 20px; z-index: 2; color: #fff; display: flex; flex-direction: column; line-height: 1.25; }
.portrait-tag b { font-family: var(--serif); font-size: 26px; }
.portrait-tag span { font-size: 14px; opacity: .85; }
.hero-books { position: absolute; left: 0; bottom: -10px; display: flex; z-index: 3; }
.hero-books .book3d { width: 128px; margin-right: -34px; }
.hero-books .book3d:nth-child(1) { transform: rotate(-8deg) translateY(10px); }
.hero-books .book3d:nth-child(2) { transform: rotate(-1deg) translateY(-6px); z-index: 2; }
.hero-books .book3d:nth-child(3) { transform: rotate(7deg) translateY(12px); }
.float-card { position: absolute; left: 4%; top: 6%; z-index: 4; background: #fff; border-radius: 16px; padding: 14px 16px; box-shadow: 0 20px 40px -18px rgba(21, 18, 15, .35); display: flex; gap: 12px; align-items: center; animation: bob 5s ease-in-out infinite; }
.float-card .big { font-family: var(--serif); font-weight: 800; font-size: 30px; color: var(--accent); line-height: 1; }
.float-card small { display: block; color: var(--ink3); font-size: 12.5px; line-height: 1.3; }
.float-card b { font-size: 14px; }
@keyframes bob { 50% { transform: translateY(-8px); } }

/* 3d book */
.book3d { position: relative; aspect-ratio: 5 / 8; border-radius: 3px 8px 8px 3px; transform-style: preserve-3d; transition: transform .5s cubic-bezier(.2, .8, .2, 1);
  box-shadow: 0 1px 1px rgba(0, 0, 0, .15), 0 18px 30px -12px rgba(21, 18, 15, .45), 0 30px 60px -30px rgba(21, 18, 15, .5); background: var(--deep); }
.book3d img { width: 100%; height: 100%; object-fit: cover; border-radius: inherit; }
.book3d::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 7%; border-radius: 3px 0 0 3px; background: linear-gradient(90deg, rgba(0, 0, 0, .35), rgba(255, 255, 255, .18) 45%, rgba(0, 0, 0, .1)); z-index: 2; }
.book3d::after { content: ''; position: absolute; inset: 0; border-radius: inherit; background: linear-gradient(115deg, rgba(255, 255, 255, .28), transparent 35%); z-index: 2; pointer-events: none; }

/* stats */
.stats { position: relative; z-index: 1; margin-top: 54px; }
.stats-in { display: grid; grid-template-columns: repeat(4, 1fr); background: #fff; border-radius: var(--r); box-shadow: var(--shadow), inset 0 0 0 1px var(--line); }
.stat { padding: 22px 26px; border-left: 1px solid var(--line); }
.stat:first-child { border-left: 0; }
.stat b { display: block; font-family: var(--serif); font-size: 34px; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; }
.stat span { color: var(--ink3); font-size: 14px; }

.trust-row { display: inline-flex; align-items: center; gap: 10px; margin-top: 10px; padding: 0 4px; }
.stars { display: inline-flex; gap: 2px; }
.stars svg { width: 20px; height: 20px; filter: drop-shadow(0 1px 1px rgba(180, 120, 0, .25)); }
.trust-score { font-size: 16px; font-weight: 800; color: var(--ink); }
.trust-sep { width: 1px; height: 20px; background: var(--line); }
.trust-readers { font-size: 15px; font-weight: 600; color: #2563eb; text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: 3px; }
.trust-readers b { color: inherit; }
@media (max-width: 680px) { .trust-row { gap: 8px; padding: 0 2px; flex-wrap: wrap; } .stars svg { width: 17px; height: 17px; } .trust-readers { font-size: 13.5px; } }

/* marquee */
.marquee { padding: 54px 0 10px; overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 10%, #000 90%, transparent); }
.marquee-track { display: flex; gap: 26px; width: max-content; animation: scroll 60s linear infinite; padding: 16px 0 30px; }
.marquee:hover .marquee-track { animation-play-state: paused; }
.marquee .book3d { width: 150px; flex: none; }
.marquee a:hover .book3d { transform: translateY(-8px) rotate(-2deg); }
@keyframes scroll { to { transform: translateX(-50%); } }

/* best sellers banner */
.bs { padding: 84px 0 40px; overflow: hidden; }
.bs-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 26px; }
.bs-head h2 { max-width: 720px; }
.bs-rail { overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); -webkit-mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.bs-track { display: flex; gap: 22px; width: max-content; padding: 18px 0 34px; animation: scroll 55s linear infinite; }
.bs-rail:hover .bs-track { animation-play-state: paused; }
.bs-card { position: relative; flex: none; width: 230px; text-decoration: none; background: #fff; border-radius: 22px; padding: 18px 18px 16px; box-shadow: var(--shadow), inset 0 0 0 1px var(--line); transition: transform .35s cubic-bezier(.2, .8, .2, 1), box-shadow .35s; }
.bs-card:hover { transform: translateY(-8px); box-shadow: 0 30px 60px -26px rgba(21, 18, 15, .45), inset 0 0 0 1px var(--line); }
.bs-card .book3d { width: 74%; margin: 4px auto 16px; }
.bs-card:hover .book3d { transform: perspective(900px) rotateY(-14deg); }
.bs-rank { position: absolute; left: 14px; top: 12px; z-index: 3; font-family: var(--serif); font-weight: 800; font-size: 30px; color: var(--accent); }
.bs-meta b { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; font-size: 15px; line-height: 1.3; min-height: 39px; }
.bs-meta span { display: flex; align-items: center; justify-content: space-between; margin-top: 8px; }
.bs-meta .price { font-size: 18px; }
.bs-meta em { font-style: normal; font-size: 12px; font-weight: 800; color: var(--accent); background: #fff1ea; padding: 3px 8px; border-radius: 999px; }

/* sections */
.section { padding: 96px 0; }
.section.alt { background: var(--paper2); }
.head { margin-bottom: 42px; max-width: 760px; }
.head.row { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; max-width: none; flex-wrap: wrap; }
.eyebrow { display: inline-block; font-size: 13px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; }
h2 { font-family: var(--serif); font-weight: 800; font-size: clamp(32px, 4.2vw, 52px); line-height: 1.04; letter-spacing: -.03em; margin: 0; }
h3 { font-size: 19px; margin: 0 0 6px; letter-spacing: -.01em; }

.bento { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: minmax(190px, auto); gap: 16px; }
.card { background: var(--card); border-radius: var(--r); padding: 28px; box-shadow: var(--shadow), inset 0 0 0 1px var(--line); transition: transform .3s, box-shadow .3s; }
.card:hover { transform: translateY(-3px); box-shadow: 0 24px 50px -24px rgba(21, 18, 15, .35), inset 0 0 0 1px var(--line); }
.card p { color: var(--ink2); margin: 0; font-size: 15.5px; }
.b-big { grid-row: span 2; background: radial-gradient(120% 80% at 100% 0%, rgba(255, 122, 61, .35), transparent 60%), var(--deep); color: #fff; display: flex; flex-direction: column; justify-content: flex-end; }
.b-big p { color: rgba(255, 255, 255, .78); }
.b-big .num { font-family: var(--serif); font-weight: 800; font-size: clamp(80px, 10vw, 128px); line-height: .9; letter-spacing: -.05em; margin-bottom: 16px; background: linear-gradient(180deg, #fff, #ffb38a); -webkit-background-clip: text; background-clip: text; color: transparent; }
.ico { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; margin-bottom: 18px; position: relative;
  box-shadow: 0 10px 22px -10px var(--ico-glow, rgba(0,0,0,.3)), inset 0 1px 0 rgba(255,255,255,.35); }
.ico svg { width: 26px; height: 26px; fill: none; stroke: #fff; stroke-width: 2.1; stroke-linecap: round; stroke-linejoin: round; }
.ico-pink   { background: linear-gradient(135deg, #f472b6, #db2777); --ico-glow: rgba(219, 39, 119, .55); }
.ico-blue   { background: linear-gradient(135deg, #60a5fa, #2563eb); --ico-glow: rgba(37, 99, 235, .55); }
.ico-yellow { background: linear-gradient(135deg, #fcd34d, #f59e0b); --ico-glow: rgba(245, 158, 11, .55); }
.ico-green  { background: linear-gradient(135deg, #4ade80, #16a34a); --ico-glow: rgba(22, 163, 74, .55); }
.card:hover .ico { transform: translateY(-2px) rotate(-3deg); transition: transform .3s; }
/* 150+ card: real library photo behind a dark fade so the text stays readable;
   the big number sits top left, the copy stays at the bottom */
.b-big.b-photo { justify-content: flex-start; }
.b-big.b-photo .num { margin-bottom: auto; text-shadow: 0 6px 30px rgba(16, 23, 42, .55); }
.b-big.b-photo h3 { margin-top: 24px; }
.b-big.b-photo { background: linear-gradient(180deg, rgba(16, 23, 42, .62) 0%, rgba(16, 23, 42, .18) 30%, rgba(16, 23, 42, .5) 55%, rgba(16, 23, 42, .94) 82%), url('/assets/library.jpg?v=2') 42% 40% / cover; }

/* catalog */
.filters { display: inline-flex; background: #fff; border-radius: 999px; padding: 5px; box-shadow: inset 0 0 0 1px var(--line); }
.filters button { border: 0; background: transparent; padding: 9px 18px; border-radius: 999px; font: 600 14px var(--sans); color: var(--ink2); cursor: pointer; }
.filters button.on { background: var(--ink); color: #fff; }
.grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 34px 26px; }
.prod { text-decoration: none; display: flex; flex-direction: column; }
.prod .book3d { margin: 0 8% 18px; }
.prod:hover .book3d { transform: perspective(900px) rotateY(-12deg) translateY(-6px); }
.prod .ribbon { position: absolute; top: 12px; right: -8px; z-index: 3; background: var(--accent); color: #fff; font-size: 12px; font-weight: 800; padding: 5px 10px; border-radius: 6px 6px 0 6px; box-shadow: 0 6px 14px -6px rgba(232, 84, 30, .8); }
.prod .ribbon::after { content: ''; position: absolute; right: 0; bottom: -6px; border: 3px solid #9c3410; border-right-color: transparent; border-bottom-color: transparent; }
.meta-row { display: flex; gap: 8px; align-items: center; font-size: 12.5px; color: var(--ink3); font-weight: 600; margin-bottom: 6px; }
.chip { display: inline-block; padding: 3px 9px; border-radius: 999px; background: #fff; box-shadow: inset 0 0 0 1px var(--line); font-size: 11.5px; font-weight: 700; letter-spacing: .04em; text-transform: uppercase; color: var(--ink2); }
.chip.e { color: #6d28d9; } .chip.g { color: var(--accent); }
.prod h3 { font-size: 17px; line-height: 1.3; margin-bottom: 6px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.prod p { margin: 0 0 12px; color: var(--ink2); font-size: 14px; line-height: 1.5; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.price-row { margin-top: auto; display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.price { font-weight: 800; font-size: 20px; letter-spacing: -.01em; }
.price s { font-weight: 500; color: var(--ink3); font-size: 14px; margin-left: 6px; }
.buy-mini { font-size: 13px; font-weight: 700; padding: 8px 14px; border-radius: 999px; background: var(--ink); color: #fff; transition: background .2s; }
.prod:hover .buy-mini { background: var(--accent); }
.empty-lib { text-align: center; padding: 40px 20px; color: var(--ink2); }

/* library: full width, 6 per row, paged */
.wrap.wide { width: min(1680px, 100% - 48px); }
.lib-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); gap: 36px 22px; }
.lib-grid .prod .book3d { margin: 0 6% 16px; }
.pager { display: flex; justify-content: center; align-items: center; gap: 8px; margin-top: 48px; flex-wrap: wrap; }
.pager button { min-width: 44px; height: 44px; padding: 0 14px; border-radius: 999px; border: 0; background: #fff; box-shadow: inset 0 0 0 1px var(--line); font: 700 15px var(--sans); color: var(--ink2); cursor: pointer; transition: background .2s, color .2s, box-shadow .2s; }
.pager button:hover:not(:disabled) { box-shadow: inset 0 0 0 1.5px var(--ink); color: var(--ink); }
.pager button.on { background: var(--ink); color: #fff; box-shadow: none; }
.pager button:disabled { opacity: .4; cursor: default; }
.coming { margin-top: 64px; }
.coming h3 { font-family: var(--serif); font-size: 26px; margin-bottom: 6px; }
.coming > p { color: var(--ink2); margin: 0 0 22px; }
.press { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; }
.press-item { background: #fff; border-radius: 16px; padding: 18px 20px; box-shadow: inset 0 0 0 1px var(--line); }
.press-item b { display: block; font-size: 15px; line-height: 1.35; margin: 6px 0 12px; }
.bar { height: 6px; border-radius: 6px; background: var(--paper2); overflow: hidden; }
.bar i { display: block; height: 100%; border-radius: 6px; background: linear-gradient(90deg, var(--accent2), var(--accent)); }
.press-item small { display: block; color: var(--ink3); margin-top: 8px; font-size: 12.5px; }

/* founder */
.founder { display: grid; grid-template-columns: .85fr 1.15fr; gap: 64px; align-items: center; }
.founder-img { border-radius: 28px; overflow: hidden; box-shadow: 0 40px 80px -36px rgba(21, 18, 15, .5); transform: rotate(-1.5deg); }
.founder-img { max-width: 440px; aspect-ratio: 1 / 1; justify-self: center; width: 100%; }
.founder-img img { width: 100%; height: 100%; object-fit: cover; object-position: center 40%; }
.founder-copy p { font-size: 18px; color: var(--ink2); margin: 0 0 16px; }
.founder-copy h2 { margin-bottom: 24px; }
.sig { margin-top: 26px; display: flex; flex-direction: column; }
.sig-name { font-family: var(--serif); font-style: italic; font-size: 40px; font-weight: 700; color: var(--accent); line-height: 1; }
.sig span:last-child { color: var(--ink3); font-size: 14px; margin-top: 6px; }

.steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; counter-reset: s; }
.steps li { background: #fff; border-radius: var(--r); padding: 28px; box-shadow: inset 0 0 0 1px var(--line); }
.steps li > span { display: grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; background: var(--ink); color: #fff; font-weight: 800; margin-bottom: 18px; }
.steps p { margin: 0; color: var(--ink2); }

.faq details { border-bottom: 1px solid var(--line); padding: 4px 0; }
.faq summary { list-style: none; cursor: pointer; padding: 18px 40px 18px 0; font-weight: 700; font-size: 18px; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: '+'; position: absolute; right: 4px; top: 12px; font-size: 28px; font-weight: 400; color: var(--accent); transition: transform .25s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 0 0 20px; color: var(--ink2); }

.final { padding: 30px 0 96px; }
.final-in { text-align: center; padding: 72px 28px; border-radius: 32px; color: #fff; position: relative; overflow: hidden;
  /* A field of pink flowers at golden hour (CC0, rawpixel via Openverse), under
     a dusk wash so the white type keeps its contrast. */
  background:
    radial-gradient(70% 110% at 50% 45%, rgba(20, 12, 34, .30), transparent 75%),
    linear-gradient(180deg, rgba(28, 16, 44, .52) 0%, rgba(28, 16, 44, .64) 100%),
    url(/assets/flowers.jpg) center 62% / cover no-repeat,
    var(--deep);
  box-shadow: 0 24px 60px -28px rgba(40, 20, 60, .55); }
.final-in h2, .final-in p { text-shadow: 0 2px 18px rgba(20, 10, 30, .45); }
.final-in p { color: rgba(255, 255, 255, .8); font-size: 18px; max-width: 560px; margin: 16px auto 30px; }

.foot { border-top: 1px solid var(--line); padding: 34px 0 50px; }
.foot-in { display: flex; align-items: center; justify-content: space-between; gap: 18px; flex-wrap: wrap; color: var(--ink3); font-size: 14px; }
.foot-in p { margin: 0; }

.sticky-cta { position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 50; display: none; }
.sticky-cta .btn { width: 100%; }

/* product page */
.pp { padding: 46px 0 80px; }
.crumbs { font-size: 14px; color: var(--ink3); margin-bottom: 26px; }
.crumbs a { color: var(--ink3); text-decoration: none; } .crumbs a:hover { color: var(--ink); }
.pp-grid { display: grid; grid-template-columns: .8fr 1.2fr; gap: 64px; align-items: start; }
.pp-cover { position: sticky; top: 96px; }
.pp-cover .book3d { width: min(380px, 100%); margin: 0 auto; transform: perspective(1200px) rotateY(-10deg); }
.pp h1 { font-family: var(--serif); font-size: clamp(32px, 4vw, 50px); line-height: 1.04; letter-spacing: -.03em; margin: 10px 0 12px; }
.pp .sub { font-size: 19px; color: var(--ink2); margin: 0 0 22px; }
.buybox { background: #fff; border-radius: 22px; padding: 24px; box-shadow: var(--shadow), inset 0 0 0 1px var(--line); margin: 6px 0 30px; }
.buybox .p-now { font-size: 40px; font-weight: 800; letter-spacing: -.02em; }
.buybox .p-was { font-size: 18px; color: var(--ink3); text-decoration: line-through; margin-left: 8px; }
.buybox .save { display: inline-block; margin-left: 10px; background: #fff1ea; color: var(--accent); font-weight: 800; font-size: 13px; padding: 4px 10px; border-radius: 999px; vertical-align: 6px; }
.buybox .ends { color: var(--ink2); font-size: 14px; margin: 6px 0 18px; }
.buybox .btn { width: 100%; }
.buybox ul { list-style: none; padding: 0; margin: 18px 0 0; display: grid; grid-template-columns: 1fr 1fr; gap: 8px 14px; font-size: 14px; color: var(--ink2); }
.buybox li::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--green); margin-right: 8px; vertical-align: 2px; }
.facts { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-bottom: 30px; }
.fact { background: #fff; border-radius: 14px; padding: 14px 16px; box-shadow: inset 0 0 0 1px var(--line); }
.fact b { display: block; font-size: 22px; font-family: var(--serif); }
.fact span { font-size: 13px; color: var(--ink3); }
.desc { font-size: 17px; color: var(--ink2); }
.desc h2, .desc h3 { font-family: var(--serif); color: var(--ink); font-size: 26px; margin: 30px 0 10px; letter-spacing: -.02em; }
.desc strong { color: var(--ink); }
.toc { counter-reset: c; list-style: none; padding: 0; margin: 0; border-radius: 18px; overflow: hidden; box-shadow: inset 0 0 0 1px var(--line); background: #fff; }
.toc li { counter-increment: c; padding: 13px 18px; border-top: 1px solid var(--line); display: flex; gap: 14px; font-weight: 600; }
.toc li:first-child { border-top: 0; }
.toc li::before { content: counter(c, decimal-leading-zero); color: var(--accent); font-variant-numeric: tabular-nums; font-weight: 800; }
.preview { position: relative; background: #fff; border-radius: 18px; padding: 28px; box-shadow: inset 0 0 0 1px var(--line); font-family: Georgia, serif; font-size: 17px; line-height: 1.75; color: #2b2622; max-height: 520px; overflow: hidden; }
.preview::after { content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 180px; background: linear-gradient(transparent, #fff); }
.preview h4 { font-family: var(--sans); margin: 0 0 12px; font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--accent); }
.block { margin-top: 44px; }
.block > h2 { font-size: 30px; margin-bottom: 16px; }
.thanks { text-align: center; padding: 80px 0; }
.thanks .book3d { width: 180px; margin: 0 auto 30px; }
.thanks h1 { font-family: var(--serif); font-size: clamp(36px, 5vw, 56px); letter-spacing: -.03em; margin: 0 0 12px; }
.thanks p { color: var(--ink2); font-size: 18px; max-width: 560px; margin: 0 auto 26px; }
.note { font-size: 14px !important; color: var(--ink3) !important; }

/* checkout step */
.co { padding: 40px 0 90px; }
.co-grid { display: grid; grid-template-columns: minmax(0, 1.4fr) minmax(0, 1fr); gap: 40px; align-items: start; }
.co-h { font-family: var(--serif); font-size: clamp(32px, 4vw, 46px); letter-spacing: -.03em; margin: 0 0 22px; }
.co-item { display: grid; grid-template-columns: 96px 1fr; gap: 20px; align-items: center; background: #fff; border-radius: 20px; padding: 18px; box-shadow: inset 0 0 0 1px var(--line); margin-bottom: 14px; position: relative; }
.co-item .book3d { width: 96px; }
.co-item h3 { font-size: 17px; margin: 6px 0 4px; line-height: 1.3; }
.co-item p { margin: 0; color: var(--ink2); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.co-price { margin-top: 8px; font-weight: 800; font-size: 19px; }
.co-price s { color: var(--ink3); font-weight: 500; font-size: 14px; }
.co-price em { font-style: normal; font-size: 12px; font-weight: 800; color: var(--accent); background: #fff1ea; padding: 3px 8px; border-radius: 999px; vertical-align: 2px; }
.co-up-head { margin: 34px 0 16px; }
.co-up-head h2 { font-size: clamp(26px, 3vw, 34px); }
.co-up-head p { color: var(--ink2); margin: 8px 0 0; }
.co-item.up { grid-template-columns: 30px 96px 1fr; cursor: pointer; border: 2px dashed #f3b79c; box-shadow: none; background: #fffaf6; transition: border-color .2s, background .2s, transform .2s; }
.co-item.up:hover { transform: translateY(-2px); }
.co-item.up.on { border: 2px solid var(--accent); background: #fff3ec; }
.co-item.up input { position: absolute; opacity: 0; pointer-events: none; }
.tick { width: 26px; height: 26px; border-radius: 8px; border: 2px solid var(--accent); background: #fff; display: grid; place-items: center; }
.co-item.up.on .tick { background: var(--accent); }
.co-item.up.on .tick::after { content: ''; width: 7px; height: 13px; border: solid #fff; border-width: 0 3px 3px 0; transform: rotate(45deg) translate(-1px, -1px); }
.co-sum { position: sticky; top: 96px; }
.co-sum .card { padding: 26px; }
.co-sum h3 { font-family: var(--serif); font-size: 22px; margin-bottom: 14px; }
.co-line { display: flex; justify-content: space-between; gap: 14px; padding: 10px 0; border-bottom: 1px solid var(--line); font-size: 14.5px; color: var(--ink2); }
.co-line b { color: var(--ink); white-space: nowrap; }
.co-line.add span::before { content: '+ '; color: var(--accent); font-weight: 800; }
.co-total { display: flex; justify-content: space-between; align-items: baseline; padding: 16px 0 18px; font-weight: 700; }
.co-total b { font-size: 30px; letter-spacing: -.02em; }
.co-sum .btn { width: 100%; }
.co-trust { list-style: none; padding: 0; margin: 16px 0 0; color: var(--ink2); font-size: 13.5px; display: grid; gap: 6px; }
.co-trust li::before { content: ''; display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: var(--green); margin-right: 8px; vertical-align: 2px; }
.dl-list { display: flex; flex-direction: column; gap: 12px; align-items: center; }

@media (max-width: 1240px) { .lib-grid { grid-template-columns: repeat(5, minmax(0, 1fr)); } }
@media (max-width: 1080px) { .lib-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 980px) {
  .co-grid { grid-template-columns: 1fr; }
  .co-sum { position: static; }
  .hero-in, .founder, .pp-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-art { min-height: 0; }
  .portrait { margin: 0 auto; width: min(420px, 100%); }
  .hero-books { left: 2%; bottom: -26px; }
  .hero-books .book3d { width: 92px; }
  .float-card { left: 0; top: -10px; }
  .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .bento { grid-template-columns: 1fr 1fr; }
  .b-big { grid-column: span 2; grid-row: auto; min-height: 260px; }
  .press { grid-template-columns: 1fr 1fr; }
  .pp-cover { position: static; }
  .founder-img { max-width: 420px; }
}
@media (max-width: 680px) {
  .nav-links, .nav .btn { display: none; }
  .hero { padding-top: 34px; }
  .stats-in { grid-template-columns: 1fr 1fr; }
  .stat:nth-child(3) { border-left: 0; }
  .stat:nth-child(n+3) { border-top: 1px solid var(--line); }
  .stat { padding: 16px 18px; } .stat b { font-size: 26px; }
  .grid, .lib-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 28px 14px; }
  .wrap.wide { width: min(1680px, 100% - 32px); }
  .pager .pg-step { padding: 0 12px; }
  .prod .book3d { margin: 0 4% 14px; }
  .bento, .steps, .press, .facts { grid-template-columns: 1fr; }
  .b-big { grid-column: auto; }
  .section { padding: 68px 0; }
  .buy-mini { display: none; }
  .buybox ul { grid-template-columns: 1fr; }
  .sticky-cta { display: block; }
  .co-item, .co-item.up { grid-template-columns: 70px 1fr; } .co-item.up { grid-template-columns: 26px 70px 1fr; } .co-item .book3d { width: 70px; }
  .foot { padding-bottom: 100px; }
  .marquee .book3d { width: 110px; }
  .bs { padding-top: 60px; }
  .bs-card { width: 180px; padding: 14px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; } html { scroll-behavior: auto; } }
