:root {
  --bg: #0a0a0b;
  --bg-alt: #121214;
  --card: #17171a;
  --line: rgba(212, 175, 55, 0.22);
  --gold-1: #f6e6a8;
  --gold-2: #d9b64e;
  --gold-3: #a9791f;
  --text: #f2efe6;
  --text-muted: #a9a69d;
  --serif: "Playfair Display", Georgia, serif;
  --sans: "Inter", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --max-w: 1080px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

.wrap {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}

.gold {
  background: linear-gradient(180deg, var(--gold-1) 0%, var(--gold-2) 55%, var(--gold-3) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* ---------- Email Signup Modal ---------- */
.email-modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0, 0, 0, 0.72);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.email-modal-overlay[hidden] { display: none; }

.email-modal {
  position: relative;
  width: 100%;
  max-width: 460px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 40px 36px;
  box-shadow: 0 30px 80px -20px rgba(0, 0, 0, 0.8);
}

.email-modal h2 {
  font-family: var(--sans);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text);
  margin: 0 0 24px;
}

.email-modal-close {
  position: absolute;
  top: 14px;
  right: 16px;
  background: none;
  border: none;
  color: var(--text-muted);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  padding: 4px;
}

.email-modal-close:hover { color: var(--text); }

.email-modal .email-form {
  display: block;
}

.email-modal .email-form input {
  width: 100%;
  font-family: var(--sans);
  font-size: 0.9rem;
  background: transparent;
  border: 1px solid var(--line);
  color: var(--text);
  border-radius: 3px;
  padding: 14px 16px;
  margin-bottom: 16px;
}

.email-modal .email-form input::placeholder { color: var(--text-muted); }

.email-modal .email-form input:focus {
  outline: none;
  border-color: var(--gold-3);
}

.email-consent {
  font-size: 0.72rem;
  line-height: 1.55;
  color: var(--text-muted);
  margin: 0 0 22px;
}

.email-modal .email-form button {
  display: block;
  width: 100%;
  font-family: var(--sans);
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #14110a;
  background: linear-gradient(180deg, var(--gold-1), var(--gold-3));
  border: none;
  border-radius: 3px;
  padding: 14px 16px;
  cursor: pointer;
}

.email-modal .email-banner-msg {
  font-size: 0.9rem;
  color: var(--gold-2);
  margin: 0;
  text-align: center;
}

@media (max-width: 520px) {
  .email-modal { padding: 32px 24px; }
}

/* ---------- Header ---------- */
.site-header {
  border-bottom: 1px solid var(--line);
  background: linear-gradient(180deg, #0d0d0f, #0a0a0b);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 12px;
  padding-top: 14px;
  padding-bottom: 14px;
}

.crest-mark {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.crest-mark.small { width: 32px; height: 32px; }

.brand-name {
  font-family: var(--serif);
  font-weight: 700;
  letter-spacing: 0.04em;
  font-size: 0.95rem;
  color: var(--gold-2);
  text-transform: uppercase;
}

/* ---------- Hero ---------- */
.hero {
  background:
    radial-gradient(1200px 600px at 80% -10%, rgba(217, 182, 78, 0.10), transparent 60%),
    var(--bg);
  padding: 64px 0 56px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 56px;
  align-items: center;
}

.eyebrow {
  font-family: var(--sans);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.75rem;
  color: var(--gold-2);
  margin: 0 0 14px;
}

h1 {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(2.1rem, 4vw, 3.2rem);
  line-height: 1.08;
  margin: 0 0 18px;
  color: var(--text);
}

.tagline {
  font-family: var(--serif);
  font-style: normal;
  font-size: 1.15rem;
  color: var(--text);
  margin: 0 0 18px;
}

.tagline em {
  font-style: italic;
  color: var(--gold-2);
}

.hero-desc {
  color: var(--text-muted);
  font-size: 1rem;
  max-width: 46ch;
  margin: 0 0 32px;
}

.buy-box {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 24px;
  max-width: 380px;
}

.price-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 16px;
}

.price {
  font-family: var(--serif);
  font-weight: 800;
  font-size: 2.1rem;
  color: var(--gold-1);
}

.price-note {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.buy-btn {
  display: block;
  text-align: center;
  text-decoration: none;
  font-family: var(--sans);
  font-weight: 700;
  font-size: 1rem;
  letter-spacing: 0.02em;
  color: #14110a;
  background: linear-gradient(180deg, var(--gold-1), var(--gold-3));
  padding: 15px 20px;
  border-radius: 9px;
  box-shadow: 0 8px 24px rgba(217, 182, 78, 0.18);
  transition: transform 0.15s ease, box-shadow 0.15s ease, filter 0.15s ease;
}

.buy-btn:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  box-shadow: 0 10px 28px rgba(217, 182, 78, 0.26);
}

.secure-note {
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin: 12px 0 0;
}

.hero-cover {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 16px;
}

.book-stage {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  width: 100%;
}

.book-nav {
  flex: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--card);
  color: var(--text-muted);
  font-size: 1.2rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.15s ease, border-color 0.15s ease;
}

.book-nav:hover {
  color: var(--gold-2);
  border-color: var(--gold-3);
}

.book-scene {
  width: 100%;
  max-width: 300px;
  perspective: 1700px;
  animation: book-float 5s ease-in-out infinite;
}

@keyframes book-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.book-tilt {
  transform-style: preserve-3d;
  transition: transform 0.2s ease-out;
  will-change: transform;
}

.book-card {
  position: relative;
  width: 100%;
  aspect-ratio: 1150 / 1389;
  transform-style: preserve-3d;
  transition: transform 0.9s cubic-bezier(0.4, 0.2, 0.2, 1);
  transform: rotateY(-22deg);
  cursor: pointer;
}

.book-card.is-flipped { transform: rotateY(158deg); }

.book-face {
  position: absolute;
  inset: 0;
  background: #0a0a0b;
  backface-visibility: hidden;
  border-radius: 3px 8px 8px 3px;
  overflow: hidden;
  box-shadow: 8px 24px 50px -14px rgba(0, 0, 0, 0.75);
}

.book-face img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.book-back {
  transform: rotateY(180deg);
}

.book-back img {
  object-fit: contain;
}

.book-edge {
  position: absolute;
  top: 0;
  right: 0;
  width: 20px;
  height: 100%;
  transform-origin: right center;
  transform: rotateY(90deg);
  backface-visibility: hidden;
}

.book-pages {
  background: repeating-linear-gradient(
    to bottom,
    #efe9d8 0px, #efe9d8 2px,
    #d8d0ba 2px, #d8d0ba 3px
  );
  box-shadow: inset 4px 0 8px -4px rgba(0, 0, 0, 0.5);
}

.book-shadow {
  width: 78%;
  height: 22px;
  margin: 10px auto 0;
  background: radial-gradient(ellipse at center, rgba(0, 0, 0, 0.55) 0%, transparent 72%);
  transform: scaleY(0.5);
}

.flip-hint {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: none;
  border: 1px solid var(--line);
  color: var(--text-muted);
  font-family: var(--sans);
  font-size: 0.78rem;
  letter-spacing: 0.03em;
  border-radius: 20px;
  padding: 7px 16px;
  cursor: pointer;
  transition: border-color 0.15s ease, color 0.15s ease;
}

.flip-hint:hover {
  color: var(--gold-2);
  border-color: var(--gold-3);
}

.flip-icon { display: inline-block; }

/* ---------- What You'll Learn ---------- */
.learn {
  padding: 8px 0 48px;
}

.learn-inner {
  max-width: 720px;
  margin: 0 auto;
  text-align: center;
}

.eyebrow.center {
  text-align: center;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 1.3rem;
  letter-spacing: normal;
  text-transform: none;
  color: var(--text);
}

.learn-desc {
  color: var(--text-muted);
  margin: 14px 0 30px;
}

.learn-list {
  list-style: none;
  margin: 0 0 34px;
  padding: 0;
  display: inline-grid;
  gap: 12px;
  text-align: left;
}

.learn-list li {
  position: relative;
  padding-left: 28px;
  font-family: var(--sans);
  font-weight: 500;
  color: var(--text);
}

.learn-list li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--gold-2);
  font-weight: 700;
}

.learn-close {
  font-family: var(--serif);
  font-size: 1.15rem;
  color: var(--text);
  margin: 0;
  line-height: 1.5;
}

/* ---------- Sticky mini CTA ---------- */
.sticky-cta {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 800;
  background: linear-gradient(180deg, #0d0d0f, #0a0a0b);
  border-top: 1px solid var(--line);
  transform: translateY(100%);
  transition: transform 0.25s ease;
}

.sticky-cta.is-visible { transform: translateY(0); }

.sticky-cta-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 24px;
}

.sticky-cta-title {
  flex: 1;
  font-family: var(--serif);
  font-weight: 700;
  font-size: 0.9rem;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.sticky-cta-price {
  font-family: var(--serif);
  font-weight: 800;
  color: var(--gold-1);
  font-size: 1.1rem;
}

.sticky-buy-btn {
  padding: 10px 18px;
  font-size: 0.85rem;
  white-space: nowrap;
}

@media (max-width: 560px) {
  .sticky-cta-title { display: none; }
}

/* ---------- Scroll reveal ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.in-view {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Thank-you page ---------- */
.thankyou {
  padding: 72px 0 90px;
}

.thankyou-inner {
  max-width: 560px;
  margin: 0 auto;
  text-align: center;
}

.thankyou-cover {
  width: 96px;
  margin: 0 auto 28px;
  border-radius: 5px;
  box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.7), 0 0 0 1px var(--line);
}

.thankyou-title {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  margin: 0 0 16px;
}

.thankyou-sub {
  color: var(--text-muted);
  margin: 0 0 32px;
}

.thankyou-steps {
  list-style: none;
  margin: 0 0 36px;
  padding: 0;
  display: inline-grid;
  gap: 12px;
  text-align: left;
}

.thankyou-steps li {
  position: relative;
  padding-left: 28px;
  font-family: var(--sans);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--text);
}

.thankyou-steps li::before {
  content: "\2713";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--gold-2);
  font-weight: 700;
}

.thankyou .ornament-divider {
  margin: 0 0 36px;
  padding: 0;
}

.email-modal--static {
  margin: 0 auto;
  text-align: left;
}

.email-modal--static h2 { text-align: left; }

.back-home {
  display: inline-block;
  margin-top: 28px;
  color: var(--text-muted);
  font-size: 0.85rem;
  text-decoration: none;
}

.back-home:hover { color: var(--gold-2); }

/* ---------- Divider ---------- */
.ornament-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 18px;
  max-width: var(--max-w);
  margin: 8px auto 8px;
  padding: 0 24px;
}

.ornament-divider span {
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, transparent, var(--line), transparent);
}

.ornament-divider img {
  width: 52px;
  height: 52px;
  object-fit: contain;
  opacity: 0.9;
}

/* ---------- About ---------- */
.about {
  padding: 56px 0 40px;
}

.about-inner { max-width: 760px; }

.about h2 {
  font-family: var(--serif);
  font-size: 1.9rem;
  color: var(--gold-2);
  margin: 0 0 22px;
}

.bio p {
  color: var(--text-muted);
  font-size: 1rem;
  margin: 0 0 16px;
}

.bio p:first-child {
  color: var(--text);
  font-size: 1.05rem;
}

.pull-quote {
  margin: 36px 0 0;
  padding: 22px 26px;
  border-left: 3px solid var(--gold-3);
  background: var(--bg-alt);
  border-radius: 0 10px 10px 0;
  font-family: var(--serif);
  font-style: italic;
  font-size: 1.15rem;
  color: var(--gold-1);
  line-height: 1.5;
}

/* ---------- Final CTA ---------- */
.final-cta {
  padding: 60px 0 80px;
  text-align: center;
  border-top: 1px solid var(--line);
  margin-top: 24px;
  background: radial-gradient(900px 400px at 50% 0%, rgba(217, 182, 78, 0.08), transparent 60%);
}

.final-cta h2 {
  font-family: var(--serif);
  font-size: clamp(1.6rem, 3vw, 2.2rem);
  margin: 0 0 12px;
}

.cta-sub {
  color: var(--text-muted);
  margin: 0 0 28px;
}

.buy-btn-lg {
  display: inline-block;
  padding: 17px 36px;
}

/* ---------- Footer ---------- */
.site-footer {
  border-top: 1px solid var(--line);
  padding: 24px 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
}

.footer-inner p {
  margin: 0;
  font-size: 0.8rem;
  color: var(--text-muted);
}

/* ---------- Responsive ---------- */
@media (max-width: 860px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .hero-cover { order: -1; max-width: 300px; margin: 0 auto; }
  .book-scene { max-width: 220px; }
  .hero-desc { max-width: none; }
  .buy-box { max-width: none; }
}
