/* =========================================================
   La Biblia Temachera — estilos base
   (paleta y decoración provisorias hasta tener referencias)
   ========================================================= */
:root {
  --bg: #0b0a08;
  --bg-2: #13110d;
  --card: #18150f;
  --line: rgba(212, 175, 55, .18);
  --gold: #d4af37;
  --gold-2: #f3d77a;
  --red: #b3261e;
  --text: #f4efe4;
  --muted: #a89f8c;
  --radius: 18px;
  --serif: "Cinzel", Georgia, serif;
  --sans: "Inter", system-ui, sans-serif;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  background: var(--bg);
  color: var(--text);
  font: 400 17px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { display: block; max-width: 100%; }
a { color: inherit; }
::selection { background: var(--gold); color: #000; }
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: linear-gradient(var(--gold), #8a6d1c); border-radius: 10px; }

.wrap { width: min(1200px, 100% - 32px); margin-inline: auto; }
.wrap--narrow { width: min(780px, 100% - 32px); }

/* ---------- Tipografía ---------- */
.eyebrow {
  font: 700 13px/1 var(--sans);
  letter-spacing: .22em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 18px;
}
.eyebrow--c, .h2--c, .lead--c { text-align: center; }
.h2 {
  font: 800 clamp(30px, 4.5vw, 52px)/1.1 var(--serif);
  margin-bottom: 20px;
}
.h2 em, .hero__title em {
  font-style: normal;
  background: linear-gradient(100deg, var(--gold-2), var(--gold) 50%, #9c7a1e);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.h3 { font: 800 24px/1.2 var(--serif); margin-bottom: 8px; }
.lead { color: var(--muted); font-size: 19px; max-width: 680px; }
.lead--c { margin-inline: auto; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 18px 34px;
  border-radius: 999px;
  background: linear-gradient(180deg, var(--gold-2), var(--gold) 55%, #a8861f);
  color: #1a1305;
  font: 800 17px/1 var(--sans);
  text-decoration: none;
  letter-spacing: .02em;
  box-shadow: 0 10px 30px -8px rgba(212, 175, 55, .55), inset 0 1px 0 rgba(255,255,255,.5);
  transition: transform .25s, box-shadow .25s;
}
.btn:hover { transform: translateY(-3px); box-shadow: 0 16px 40px -8px rgba(212, 175, 55, .7), inset 0 1px 0 rgba(255,255,255,.5); }
.btn--sm { padding: 11px 20px; font-size: 14px; }
.btn--block { width: 100%; }

/* ---------- Nav ---------- */
.nav {
  position: fixed; inset: 0 0 auto; z-index: 50;
  padding: 18px 0;
  transition: background .3s, padding .3s, border-color .3s;
  border-bottom: 1px solid transparent;
}
.nav.is-scrolled {
  background: rgba(11, 10, 8, .75);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  padding: 10px 0;
  border-color: var(--line);
}
.nav__in { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.nav__logo { font: 800 16px/1 var(--serif); letter-spacing: .08em; text-decoration: none; }
.nav__logo span { color: var(--gold); }
.nav__links { display: flex; gap: 28px; }
.nav__links a { text-decoration: none; color: var(--muted); font-size: 15px; font-weight: 500; transition: color .2s; }
.nav__links a:hover { color: var(--gold); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  min-height: 100svh;
  display: flex; align-items: center;
  padding: 120px 0 80px;
  overflow: hidden;
}
.hero__glow {
  position: absolute; inset: -20% -10% auto auto;
  width: 900px; height: 900px;
  background: radial-gradient(circle, rgba(212,175,55,.22), transparent 60%);
  pointer-events: none;
}
.hero__grain {
  position: absolute; inset: 0;
  background-image: radial-gradient(rgba(255,255,255,.035) 1px, transparent 1px);
  background-size: 3px 3px;
  pointer-events: none;
}
.hero__grid { position: relative; display: grid; grid-template-columns: 1.1fr .9fr; gap: 40px; align-items: center; }
.hero__title {
  font: 900 clamp(48px, 8vw, 104px)/.95 var(--serif);
  letter-spacing: -.01em;
  margin-bottom: 22px;
}
.hero__sub { color: var(--muted); font-size: 20px; max-width: 520px; margin-bottom: 26px; }
.hero__gift {
  display: inline-flex; align-items: center; gap: 12px;
  padding: 10px 16px 10px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(212,175,55,.06);
  font-weight: 500; font-size: 15px;
  margin-bottom: 32px;
}
.tag { background: var(--red); color: #fff; font: 800 12px/1 var(--sans); letter-spacing: .1em; padding: 7px 10px; border-radius: 999px; }
.hero__secure { margin-top: 14px; font-size: 14px; color: var(--muted); }
.hero__books { position: relative; height: 520px; }
.hero__books .book--main { position: absolute; left: 6%; top: 0; width: 300px; z-index: 2; }
.hero__books .book--gift { position: absolute; right: 0; bottom: 0; width: 230px; z-index: 1; }
.hero__scroll {
  position: absolute; left: 50%; bottom: 28px; translate: -50% 0;
  width: 26px; height: 42px; border: 2px solid var(--line); border-radius: 20px;
}
.hero__scroll span {
  position: absolute; left: 50%; top: 8px; translate: -50% 0;
  width: 4px; height: 8px; border-radius: 4px; background: var(--gold);
  animation: scrollDot 1.8s infinite;
}
@keyframes scrollDot { 0% { opacity: 0; transform: translateY(0); } 40% { opacity: 1; } 100% { opacity: 0; transform: translateY(14px); } }

/* ---------- Libros (mockup CSS) ---------- */
.book {
  position: relative;
  aspect-ratio: 2 / 3;
  transform: perspective(1200px) rotateY(-18deg) rotateX(3deg);
  transform-style: preserve-3d;
  transition: transform .6s cubic-bezier(.2,.7,.2,1);
}
.book:hover { transform: perspective(1200px) rotateY(-6deg) rotateX(1deg) translateY(-8px); }
.book--gift { transform: perspective(1200px) rotateY(-14deg) rotateZ(4deg); }
.book__cover {
  position: absolute; inset: 0;
  border-radius: 4px 10px 10px 4px;
  overflow: hidden;
  background:
    linear-gradient(90deg, rgba(0,0,0,.45), transparent 8%),
    radial-gradient(circle at 70% 20%, #3b2f12, #120f08 70%);
  box-shadow: 30px 40px 60px -20px rgba(0,0,0,.85), 0 0 0 1px rgba(212,175,55,.35) inset;
}
.book--gift .book__cover {
  background:
    linear-gradient(90deg, rgba(0,0,0,.45), transparent 8%),
    radial-gradient(circle at 70% 20%, #4a1512, #140807 70%);
}
.book__cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: 2; }
.book__fallback {
  position: absolute; inset: 10%;
  border: 1px solid rgba(212,175,55,.5);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
  text-align: center;
}
.book__small { font: 600 12px/1 var(--serif); letter-spacing: .3em; color: var(--gold-2); }
.book__big { font: 900 clamp(20px, 2.6vw, 30px)/1.05 var(--serif); color: var(--gold); padding: 0 8px; }
.book__rule { width: 40%; height: 1px; background: var(--gold); }
.book__spine {
  position: absolute; left: 0; top: 0; bottom: 0; width: 22px;
  transform: rotateY(90deg) translateZ(-11px) translateX(-11px);
  transform-origin: left;
  background: linear-gradient(90deg, #0a0805, #2a2210);
}
.book__ribbon {
  position: absolute; top: 18px; right: -10px; z-index: 3;
  background: var(--red); color: #fff;
  font: 800 13px/1 var(--sans); letter-spacing: .14em;
  padding: 9px 14px; border-radius: 4px;
  box-shadow: 0 8px 20px -6px rgba(179,38,30,.7);
}

/* ---------- Marquee ---------- */
.marquee { border-block: 1px solid var(--line); background: var(--bg-2); overflow: hidden; padding: 18px 0; }
.marquee__track { display: flex; gap: 32px; width: max-content; animation: marquee 30s linear infinite; }
.marquee__track span { font: 800 15px/1 var(--serif); letter-spacing: .14em; color: var(--gold); white-space: nowrap; }
@keyframes marquee { to { transform: translateX(-50%); } }

/* ---------- Secciones ---------- */
.section { position: relative; padding: 120px 0; }
.section--tight { padding: 40px 0 100px; }

.chapters { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; margin-top: 56px; }
.chapter {
  position: relative;
  padding: 32px 28px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, var(--card), var(--bg));
  transition: transform .35s, border-color .35s, box-shadow .35s;
}
.chapter:hover { transform: translateY(-6px); border-color: rgba(212,175,55,.5); box-shadow: 0 20px 40px -20px rgba(212,175,55,.35); }
.chapter__n { font: 900 40px/1 var(--serif); color: rgba(212,175,55,.35); display: block; margin-bottom: 14px; }
.chapter h3 { font: 700 20px/1.3 var(--sans); margin-bottom: 8px; }
.chapter p { color: var(--muted); font-size: 16px; }

/* Regalo */
.section--gift { background: var(--bg-2); overflow: hidden; border-block: 1px solid var(--line); }
.gift__bg {
  position: absolute; left: 50%; top: 50%; translate: -50% -50%;
  font: 900 min(26vw, 340px)/1 var(--serif);
  color: transparent; -webkit-text-stroke: 1px rgba(212,175,55,.08);
  white-space: nowrap; pointer-events: none;
}
.gift { position: relative; display: grid; grid-template-columns: .8fr 1.2fr; gap: 60px; align-items: center; }
.gift__book { display: flex; justify-content: center; }
.book--lg { width: min(320px, 70vw); }
.checks { list-style: none; margin: 26px 0; display: grid; gap: 12px; }
.checks li { position: relative; padding-left: 34px; }
.checks li::before {
  content: "✓"; position: absolute; left: 0; top: 1px;
  width: 22px; height: 22px; border-radius: 50%;
  background: var(--gold); color: #000; font-size: 13px; font-weight: 800;
  display: grid; place-items: center;
}
.gift__note { color: var(--gold-2); font-weight: 600; }

/* Oferta */
.offer {
  position: relative;
  max-width: 520px; margin: 56px auto 0;
  padding: 44px 36px 36px;
  border-radius: 24px;
  background: linear-gradient(180deg, #1d1810, #0f0d09);
  border: 1px solid rgba(212,175,55,.45);
  box-shadow: 0 40px 80px -30px rgba(212,175,55,.35);
}
.offer__seal {
  position: absolute; top: -28px; right: 28px;
  width: 64px; height: 64px; border-radius: 50%;
  background: var(--red); color: #fff;
  display: grid; place-items: center;
  font: 900 20px/1 var(--serif);
  box-shadow: 0 10px 24px -8px rgba(179,38,30,.8);
  rotate: 10deg;
}
.offer__list { list-style: none; display: grid; gap: 12px; margin-bottom: 28px; }
.offer__list li { display: flex; justify-content: space-between; gap: 12px; padding: 14px 0; border-bottom: 1px dashed var(--line); }
.offer__list b { color: var(--muted); font-weight: 500; font-size: 14px; white-space: nowrap; }
.offer__list b.free { color: var(--gold); font-weight: 800; letter-spacing: .1em; }
.offer__price { text-align: center; margin-bottom: 26px; }
.offer__price small { display: block; color: var(--muted); text-transform: uppercase; letter-spacing: .2em; font-size: 12px; }
.offer__price strong { display: block; font: 900 64px/1.1 var(--serif); color: var(--gold); }
.offer__price span { color: var(--muted); font-size: 14px; }
.offer__trust { list-style: none; margin-top: 22px; display: grid; gap: 6px; text-align: center; color: var(--muted); font-size: 14px; }

/* Garantía */
.guarantee {
  display: flex; gap: 28px; align-items: center;
  max-width: 820px;
  padding: 32px;
  border: 1px solid var(--line); border-radius: var(--radius);
  background: var(--card);
}
.guarantee p { color: var(--muted); }
.guarantee__badge {
  flex: none;
  width: 110px; height: 110px; border-radius: 50%;
  border: 3px double var(--gold);
  display: grid; place-content: center; text-align: center;
  color: var(--gold);
}
.guarantee__badge b { font: 900 40px/1 var(--serif); }
.guarantee__badge span { font-size: 12px; letter-spacing: .2em; }

/* FAQ */
.faq { margin-top: 48px; display: grid; gap: 12px; }
.faq details { border: 1px solid var(--line); border-radius: 14px; background: var(--card); }
.faq summary {
  cursor: pointer; list-style: none;
  padding: 20px 24px; font-weight: 700;
  display: flex; justify-content: space-between; gap: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; color: var(--gold); font-size: 24px; line-height: 1; transition: rotate .25s; }
.faq details[open] summary::after { rotate: 45deg; }
.faq details p { padding: 0 24px 22px; color: var(--muted); }

/* CTA final */
.final {
  padding: 120px 0;
  background: radial-gradient(ellipse at center, rgba(212,175,55,.16), transparent 65%);
}
.final__in { text-align: center; }
.final .lead { margin-bottom: 34px; }
.final .lead b { color: var(--gold); }

/* Footer */
.footer { border-top: 1px solid var(--line); padding: 36px 0 110px; }
.footer__in { text-align: center; color: var(--muted); font-size: 14px; display: grid; gap: 6px; }
.footer__small a { color: var(--gold); }

/* Barra fija móvil */
.sticky-cta {
  position: fixed; left: 12px; right: 12px; bottom: 12px; z-index: 60;
  display: none; align-items: center; justify-content: space-between; gap: 12px;
  padding: 10px 10px 10px 18px;
  border-radius: 999px;
  background: rgba(24, 21, 15, .92);
  backdrop-filter: blur(12px);
  border: 1px solid rgba(212,175,55,.4);
  transform: translateY(140%);
  transition: transform .35s;
}
.sticky-cta b { color: var(--gold); }
.sticky-cta.is-visible { transform: none; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(34px); transition: opacity .8s cubic-bezier(.2,.7,.2,1), transform .8s cubic-bezier(.2,.7,.2,1); transition-delay: var(--d, 0s); }
.reveal.is-in { opacity: 1; transform: none; }
.book.reveal { transform: perspective(1200px) rotateY(-40deg) translateY(40px); }
.book.reveal.is-in { transform: perspective(1200px) rotateY(-18deg) rotateX(3deg); }
.book--gift.reveal.is-in { transform: perspective(1200px) rotateY(-14deg) rotateZ(4deg); }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .nav__links { display: none; }
  .hero { padding-top: 100px; }
  .hero__grid, .gift { grid-template-columns: 1fr; }
  .hero__text { text-align: center; }
  .hero__sub { margin-inline: auto; }
  .hero__books { height: 400px; max-width: 380px; width: 100%; margin: 0 auto; order: -1; }
  .hero__books .book--main { width: 220px; left: 0; }
  .hero__books .book--gift { width: 170px; }
  .chapters { grid-template-columns: 1fr 1fr; }
  .gift__text { text-align: center; }
  .gift__text .lead { margin-inline: auto; }
  .checks { justify-items: center; }
  .sticky-cta { display: flex; }
  .hero__scroll { display: none; }
}
@media (max-width: 560px) {
  body { font-size: 16px; }
  .chapters { grid-template-columns: 1fr; }
  .hero__gift { font-size: 13px; text-align: left; }
  .guarantee { flex-direction: column; text-align: center; }
  .offer { padding: 40px 22px 28px; }
  .section { padding: 90px 0; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; }
}
