/* TaleNights — shared styles */

:root {
  --plum: #1E0A3C;
  --plum-light: #2C1350;
  --plum-lighter: #3A1B66;
  --cream: #F5E6C8;
  --cream-soft: #FBF4E4;
  --gold: #C9A84C;
  --gold-light: #E0C878;
  --ink: #120626;
  --max-width: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--plum);
  color: var(--cream);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4 {
  font-family: 'Playfair Display', Georgia, 'Times New Roman', serif;
  font-weight: 700;
  line-height: 1.2;
  margin: 0 0 0.5em;
  color: var(--cream);
}

p { margin: 0 0 1em; }

a { color: var(--gold-light); }

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

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

/* Starfield backdrop */
.stars {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background-image:
    radial-gradient(1.5px 1.5px at 10% 20%, rgba(245,230,200,0.55), transparent),
    radial-gradient(1px 1px at 25% 65%, rgba(245,230,200,0.4), transparent),
    radial-gradient(2px 2px at 40% 15%, rgba(201,168,76,0.5), transparent),
    radial-gradient(1px 1px at 60% 40%, rgba(245,230,200,0.45), transparent),
    radial-gradient(1.5px 1.5px at 75% 70%, rgba(245,230,200,0.35), transparent),
    radial-gradient(1px 1px at 85% 25%, rgba(201,168,76,0.4), transparent),
    radial-gradient(2px 2px at 95% 55%, rgba(245,230,200,0.4), transparent),
    radial-gradient(1px 1px at 15% 85%, rgba(245,230,200,0.3), transparent),
    radial-gradient(1.5px 1.5px at 50% 90%, rgba(201,168,76,0.35), transparent);
  background-repeat: no-repeat;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 16px 32px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1.05rem;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
  font-family: 'Inter', sans-serif;
}

.btn-gold {
  background: var(--gold);
  color: var(--plum);
  box-shadow: 0 4px 18px rgba(201, 168, 76, 0.35);
}
.btn-gold:hover { background: var(--gold-light); transform: translateY(-2px); box-shadow: 0 8px 24px rgba(201, 168, 76, 0.45); }

.btn-outline {
  background: transparent;
  border-color: var(--gold);
  color: var(--gold-light);
}
.btn-outline:hover { background: rgba(201, 168, 76, 0.12); transform: translateY(-2px); }

.btn-block { width: 100%; }

/* Section shells */
section { position: relative; padding: 88px 0; }
.section-light { background: var(--cream-soft); color: var(--ink); }
.section-light h2, .section-light h3, .section-light h4 { color: var(--ink); }
.section-light a { color: #7A5E1D; }

.eyebrow {
  display: inline-block;
  font-family: 'Inter', sans-serif;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  font-weight: 700;
  color: var(--gold);
  margin-bottom: 14px;
}
.section-light .eyebrow { color: #96772A; }

.section-head { text-align: center; max-width: 640px; margin: 0 auto 56px; }
.section-head h2 { font-size: clamp(1.8rem, 3.5vw, 2.5rem); }
.section-head p { font-size: 1.1rem; opacity: 0.85; }

/* Nav */
header.site-nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(30, 10, 60, 0.92);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(201, 168, 76, 0.2);
}
.nav-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  max-width: var(--max-width);
  margin: 0 auto;
}
.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1.3rem;
  color: var(--cream);
  text-decoration: none;
}
.logo svg { width: 26px; height: 26px; }
.logo-mark {
  width: 32px;
  height: 32px;
  flex-shrink: 0;
  object-fit: cover;
  clip-path: circle(45% at 50% 50%);
}
.nav-links { display: flex; align-items: center; gap: 28px; }
.nav-links a {
  color: var(--cream);
  text-decoration: none;
  font-size: 0.95rem;
  opacity: 0.85;
}
.nav-links a:hover { opacity: 1; color: var(--gold-light); }
.nav-cta { display: none; }

@media (min-width: 720px) {
  .nav-cta { display: inline-flex; padding: 10px 22px; font-size: 0.92rem; }
}
@media (max-width: 719px) {
  .nav-links a:not(.nav-cta-mobile) { display: none; }
  .nav-cta-mobile { display: inline-flex; padding: 8px 16px; font-size: 0.85rem; }
}

/* Hero */
.hero {
  padding: 96px 0 110px;
  overflow: hidden;
  background: radial-gradient(ellipse at 50% -10%, var(--plum-lighter) 0%, var(--plum) 55%);
}
.hero-inner { position: relative; text-align: center; max-width: 780px; margin: 0 auto; }
.hero h1 {
  font-size: clamp(2.2rem, 5.5vw, 3.6rem);
  margin-bottom: 22px;
}
.hero h1 .accent { color: var(--gold-light); font-style: italic; }
.hero .lede {
  font-size: clamp(1.05rem, 2vw, 1.25rem);
  color: var(--cream);
  opacity: 0.88;
  max-width: 560px;
  margin: 0 auto 36px;
}
.hero-ctas { display: flex; flex-wrap: wrap; gap: 16px; justify-content: center; margin-bottom: 20px; }
.hero-note { font-size: 0.9rem; opacity: 0.65; }
.moon {
  width: 72px;
  height: 72px;
  margin: 0 auto 28px;
}

/* How it works */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 32px;
  margin-top: 8px;
}
.step-card {
  background: var(--plum-light);
  border: 1px solid rgba(201, 168, 76, 0.25);
  border-radius: 18px;
  padding: 32px 26px;
  text-align: center;
}
.step-num {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--gold);
  color: var(--plum);
  font-family: 'Playfair Display', serif;
  font-weight: 700;
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 18px;
}
.step-card h3 { font-size: 1.2rem; margin-bottom: 10px; }
.step-card p { opacity: 0.82; font-size: 0.98rem; margin: 0; }

/* The nightly struggle */
.pain-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 28px;
  margin-top: 8px;
}
.pain-card {
  background: #fff;
  border: 1px solid rgba(30,10,60,0.08);
  border-radius: 18px;
  padding: 32px 26px;
  text-align: center;
  box-shadow: 0 10px 30px rgba(30,10,60,0.06);
}
.pain-card .pain-icon { font-size: 1.8rem; margin-bottom: 14px; }
.pain-card h3 { font-size: 1.15rem; margin-bottom: 10px; color: var(--ink); }
.pain-card p { opacity: 0.75; font-size: 0.96rem; margin: 0; color: #4A3A1B; }
.struggle-transition {
  text-align: center;
  max-width: 560px;
  margin: 40px auto 0;
  font-size: 1.05rem;
  font-style: italic;
  color: #4A3A1B;
  opacity: 0.9;
}

/* Money-back guarantee */
.guarantee-banner {
  display: flex;
  align-items: center;
  gap: 16px;
  max-width: 640px;
  margin: 32px auto 0;
  background: rgba(201, 168, 76, 0.08);
  border: 1px solid rgba(201, 168, 76, 0.35);
  border-radius: 16px;
  padding: 20px 26px;
  font-size: 0.96rem;
  opacity: 0.95;
}
.guarantee-icon { font-size: 1.6rem; flex-shrink: 0; }
.guarantee-banner strong { color: var(--gold-light); }

/* Sample story */
.story-card {
  background: var(--cream-soft);
  color: var(--ink);
  border-radius: 22px;
  padding: 44px clamp(24px, 5vw, 56px);
  max-width: 760px;
  margin: 0 auto;
  box-shadow: 0 24px 60px rgba(0,0,0,0.35);
  border: 1px solid rgba(201, 168, 76, 0.4);
  position: relative;
}
.story-card .story-tag {
  display: inline-block;
  background: var(--gold);
  color: var(--plum);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 5px 14px;
  border-radius: 999px;
  margin-bottom: 18px;
}
.story-card h3 {
  font-size: 1.5rem;
  color: var(--ink);
}
.story-body {
  font-family: 'Playfair Display', Georgia, serif;
  font-size: 1.12rem;
  line-height: 1.75;
  color: #2B1E0F;
}
.story-body p { margin: 0 0 1.1em; }
.story-meta {
  margin-top: 24px;
  padding-top: 20px;
  border-top: 1px dashed rgba(30,10,60,0.25);
  font-size: 0.92rem;
  color: #6B5A38;
  display: flex;
  flex-wrap: wrap;
  gap: 6px 18px;
}

/* Pricing */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 28px;
  max-width: 780px;
  margin: 0 auto;
  align-items: stretch;
}
.price-card {
  background: var(--plum-light);
  border: 1px solid rgba(201, 168, 76, 0.25);
  border-radius: 22px;
  padding: 40px 32px;
  display: flex;
  flex-direction: column;
  position: relative;
}
.price-card.featured {
  border: 2px solid var(--gold);
  background: linear-gradient(160deg, var(--plum-lighter), var(--plum-light));
  box-shadow: 0 20px 50px rgba(201,168,76,0.18);
}
.price-badge {
  position: absolute;
  top: -14px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--gold);
  color: var(--plum);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 6px 16px;
  border-radius: 999px;
  white-space: nowrap;
}
.price-card h3 { font-size: 1.3rem; margin-bottom: 6px; }
.price-card .price-sub { opacity: 0.7; font-size: 0.92rem; margin-bottom: 20px; }
.price-amount { font-family: 'Playfair Display', serif; font-size: 2.6rem; font-weight: 700; color: var(--gold-light); }
.price-amount span { font-family: 'Inter', sans-serif; font-size: 1rem; font-weight: 500; opacity: 0.7; }
.price-card ul { list-style: none; margin: 22px 0 28px; padding: 0; flex-grow: 1; }
.price-card li { padding: 7px 0; padding-left: 28px; position: relative; opacity: 0.9; font-size: 0.97rem; }
.price-card li::before {
  content: "✦";
  position: absolute;
  left: 0;
  color: var(--gold);
}
.price-fine { text-align: center; margin-top: 28px; opacity: 0.7; font-size: 0.92rem; }

/* FAQ */
.faq-list { max-width: 760px; margin: 0 auto; }
.faq-item {
  border-bottom: 1px solid rgba(201,168,76,0.25);
}
.faq-question {
  width: 100%;
  background: none;
  border: none;
  color: var(--cream);
  text-align: left;
  font-family: 'Inter', sans-serif;
  font-size: 1.05rem;
  font-weight: 600;
  padding: 22px 4px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
}
.faq-question .icon {
  flex-shrink: 0;
  width: 22px;
  height: 22px;
  border: 1.5px solid var(--gold);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-light);
  font-size: 1rem;
  transition: transform 0.2s ease;
}
.faq-item[open] .faq-question .icon { transform: rotate(45deg); }
.faq-answer {
  padding: 0 4px 22px;
  opacity: 0.85;
  font-size: 0.98rem;
  max-width: 640px;
}
.faq-answer a { font-weight: 600; }
.faq-item summary { list-style: none; }
.faq-item summary::-webkit-details-marker { display: none; }

/* Final CTA */
.final-cta {
  text-align: center;
  background: radial-gradient(ellipse at 50% 30%, var(--plum-lighter), var(--plum));
}
.final-cta h2 { font-size: clamp(1.8rem, 4vw, 2.6rem); max-width: 620px; margin: 0 auto 18px; }
.final-cta p { opacity: 0.8; margin-bottom: 32px; }

/* Footer */
footer {
  background: var(--ink);
  padding: 56px 0 32px;
  font-size: 0.9rem;
  color: rgba(245,230,200,0.7);
}
.footer-top {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 32px;
  padding-bottom: 32px;
  border-bottom: 1px solid rgba(201,168,76,0.18);
  margin-bottom: 24px;
}
.footer-brand .logo { margin-bottom: 12px; }
.footer-brand p { max-width: 280px; opacity: 0.7; font-size: 0.88rem; }
.footer-cols { display: flex; gap: 56px; flex-wrap: wrap; }
.footer-col h4 {
  font-family: 'Inter', sans-serif;
  font-size: 0.82rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--gold);
  margin-bottom: 14px;
}
.footer-col a {
  display: block;
  color: rgba(245,230,200,0.75);
  text-decoration: none;
  margin-bottom: 10px;
  font-size: 0.9rem;
}
.footer-col a:hover { color: var(--gold-light); }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px;
  opacity: 0.55;
  font-size: 0.82rem;
}
.footer-social {
  display: flex;
  gap: 14px;
  align-items: center;
}
.footer-social a {
  color: inherit;
  display: inline-flex;
  line-height: 0;
}
.footer-social svg {
  width: 15px;
  height: 15px;
  fill: currentColor;
  transition: opacity 0.15s ease;
}
.footer-social a:hover svg { opacity: 0.7; }

/* Legal pages */
.legal-page { padding: 64px 0 100px; }
.legal-page .wrap { max-width: 760px; }
.legal-page h1 { font-size: 2.2rem; margin-bottom: 8px; }
.legal-updated { opacity: 0.6; font-size: 0.88rem; margin-bottom: 40px; }
.legal-page h2 { font-size: 1.3rem; margin-top: 40px; color: var(--gold-light); }
.legal-page p, .legal-page li { opacity: 0.88; font-size: 0.98rem; }
.legal-page a { color: var(--gold-light); }
.legal-page ul { padding-left: 22px; }
.back-home { display: inline-flex; align-items: center; gap: 6px; margin-bottom: 28px; font-size: 0.92rem; color: var(--gold-light); text-decoration: none; }

@media (max-width: 640px) {
  section { padding: 64px 0; }
  .footer-top { flex-direction: column; }
}
