/* ==========================================================================
   Flower of Life Tarot — Main Stylesheet
   Dark mystical premium theme
   ========================================================================== */

/* ---------- Reset & Base ---------- */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --color-bg: #000000;
  --color-bg-soft: #0a0612;
  --color-bg-card: #110a1f;
  --color-bg-elevated: #1a0d2e;
  --color-gold: #FFD28A;
  --color-gold-dim: #c9a96e;
  --color-gold-soft: rgba(255, 210, 138, 0.15);
  --color-purple-deep: #2a1a4a;
  --color-purple-glow: #4a2c5a;
  --color-text: #f5ecd9;
  --color-text-soft: #c9bfa8;
  --color-text-muted: #8a8170;
  --color-border: rgba(255, 210, 138, 0.18);
  --color-border-strong: rgba(255, 210, 138, 0.4);

  --font-display: 'Prosto One', Georgia, serif;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Cormorant Garamond', Georgia, serif;

  --container: 1200px;
  --container-narrow: 880px;

  --transition: 0.3s ease;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
  /* Offset anchor jumps so the fixed header doesn't cover the section heading */
  scroll-padding-top: 90px;
}

/* Also set scroll-margin on sections with IDs (belt and braces) */
section[id],
*[id]:not(html):not(body) {
  scroll-margin-top: 90px;
  padding-bottom: 30px;
}

body {
  font-family: var(--font-body);
  background: var(--color-bg);
  color: var(--color-text);
  line-height: 1.7;
  font-weight: 300;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
  width: 100%;
  max-width: 100vw;
}

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

a {
  color: var(--color-gold);
  text-decoration: none;
  transition: opacity var(--transition);
}

a:hover {
  opacity: 0.75;
}

/* ---------- Layout ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 2rem;
}

.container-narrow {
  max-width: var(--container-narrow);
}

section {
  padding: 7rem 0;
  position: relative;
}

@media (max-width: 768px) {
  section {
    padding: 4.5rem 0;
  }
  .container {
    padding: 0 1.25rem;
  }
}

/* ---------- Typography ---------- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.2;
  color: var(--color-text);
  overflow-wrap: break-word;
  word-wrap: break-word;
  hyphens: auto;
  padding-bottom: 20px;
}

h1 { font-size: clamp(2rem, 5vw, 3.25rem); }
h2 { font-size: clamp(1.75rem, 4vw, 2.5rem); }
h3 { font-size: clamp(1.25rem, 2.5vw, 1.5rem); }
h4 { font-size: 1.125rem; }

.eyebrow {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 5px;
  color: var(--color-gold);
  text-transform: uppercase;
  margin-bottom: 1.5rem;
  display: block;
}

.lead {
  font-size: 1.125rem;
  color: var(--color-text-soft);
  font-weight: 300;
  line-height: 1.8;
}

p {
  color: var(--color-text-soft);
}

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

.gold {
  color: var(--color-gold);
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  padding: 14px 32px;
  font-family: var(--font-display);
  font-size: 0.875rem;
  font-weight: 400;
  letter-spacing: 1px;
  text-transform: uppercase;
  border: 1px solid var(--color-gold);
  border-radius: 4px;
  cursor: pointer;
  transition: all var(--transition);
  text-align: center;
}

.btn-primary {
  background: var(--color-gold);
  color: #1a0d2e;
}

.btn-primary:hover {
  background: transparent;
  color: var(--color-gold);
  opacity: 1;
}

.btn-secondary {
  background: transparent;
  color: var(--color-text);
}

.btn-secondary:hover {
  background: var(--color-gold-soft);
  color: var(--color-gold);
  opacity: 1;
}

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  padding: 1.25rem 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--color-border);
  transition: background var(--transition);
}

.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  flex-wrap: nowrap;
}

.logo {
  font-family: var(--font-display);
  font-size: 0.85rem;
  letter-spacing: 3px;
  color: var(--color-gold);
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 0;
  flex-shrink: 1;
}

@media (max-width: 480px) {
  .logo {
    font-size: 0.7rem;
    letter-spacing: 2px;
    gap: 0.5rem;
  }
  .logo-mark {
    width: 28px;
    height: 28px;
  }
}

.logo-mark {
  width: 32px;
  height: 32px;
  display: block;
  object-fit: contain;
  flex-shrink: 0;
}

.nav-links {
  display: flex;
  list-style: none;
  gap: 2.25rem;
  align-items: center;
}

.nav-links a {
  color: var(--color-text-soft);
  font-size: 0.85rem;
  font-weight: 400;
  letter-spacing: 0.5px;
  text-transform: uppercase;
  font-family: var(--font-body);
}

.nav-links a:hover {
  color: var(--color-gold);
}

.lang-switch {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  font-size: 0.75rem;
  letter-spacing: 1px;
  color: var(--color-text-muted);
}

.lang-switch a {
  color: var(--color-text-muted);
  padding: 4px 8px;
  border-radius: 3px;
}

.lang-switch a.active {
  color: var(--color-gold);
  background: var(--color-gold-soft);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--color-gold);
  cursor: pointer;
  font-size: 1.5rem;
}

@media (max-width: 860px) {
  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--color-bg-soft);
    padding: 1.5rem 2rem;
    gap: 1.25rem;
    border-bottom: 1px solid var(--color-border);
  }
  .nav-links.open { display: flex; }
  .nav-toggle { display: block; }
}

/* ---------- Hero ---------- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  overflow: hidden;
  padding: 9rem 1.5rem 5rem;
  background: #32000b;
}

.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
}

.hero-bg svg {
  width: 100%;
  height: 100%;
}

.hero-content {
  position: relative;
  z-index: 2;
  max-width: 720px;
}

.hero h1 {
  font-size: clamp(2.25rem, 5.5vw, 3.75rem);
  margin-bottom: 1.75rem;
  line-height: 1.2;
}

.hero .lead {
  margin-bottom: 2.5rem;
  max-width: 580px;
  margin-left: auto;
  margin-right: auto;
}

.hero-cta {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

.scroll-cue {
  position: absolute;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%);
  color: var(--color-gold);
  font-size: 0.7rem;
  letter-spacing: 4px;
  text-transform: uppercase;
  font-family: var(--font-display);
  opacity: 0.6;
  animation: bounce 2.5s ease-in-out infinite;
}

@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* ---------- Section header ---------- */
.section-header {
  text-align: center;
  max-width: 720px;
  margin: 0 auto 4rem;
}

.section-header h2 {
  margin-bottom: 1.25rem;
}

/* ---------- Card gallery ---------- */
.gallery {
  background: var(--color-bg);
  position: relative;
  overflow: hidden;
}

.gallery-track {
  display: flex;
  gap: 1.5rem;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  margin: 3rem auto 0;
  max-width: 100%;
}

.gallery-card {
  position: relative;
  width: 180px;
  height: 320px;
  border-radius: 8px;
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.4s ease, box-shadow 0.4s ease;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
  background: #110a1f;
  flex-shrink: 0;
}

.gallery-card:hover,
.gallery-card.is-playing {
  transform: translateY(-8px) scale(1.03);
  box-shadow: 0 12px 36px rgba(255, 210, 138, 0.25);
}

/* Static image always visible */
.gallery-card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  position: absolute;
  inset: 0;
  top: 0;
  left: 0;
  z-index: 1;
}

/* Video on top, hidden until hover/tap */
.gallery-card video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  position: absolute;
  inset: 0;
  top: 0;
  left: 0;
  z-index: 2;
  opacity: 0;
  transition: opacity 0.4s ease;
  pointer-events: none;
}

.gallery-card:hover video,
.gallery-card.is-playing video {
  opacity: 1;
}

@media (max-width: 768px) {
  .gallery-card {
    width: 140px;
    height: 249px;
  }
  .gallery-track { gap: 0.75rem; }
}

@media (max-width: 480px) {
  .gallery-card {
    width: 120px;
    height: 213px;
  }
}

.gallery-caption {
  text-align: center;
  margin-top: 3rem;
  color: var(--color-text-muted);
  font-size: 0.85rem;
  font-style: italic;
  letter-spacing: 1px;
  padding: 0 1rem;
}

/* ---------- Lightbox (mobile fullscreen card view) ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.92);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.lightbox.is-open {
  opacity: 1;
  visibility: visible;
}

.lightbox-content {
  position: relative;
  width: min(420px, 85vw);
  height: min(746px, 85vh);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 20px 60px rgba(255, 210, 138, 0.2), 0 0 0 1px var(--color-border-strong);
  transform: scale(0.9);
  transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
  background: #110a1f;
}

.lightbox.is-open .lightbox-content {
  transform: scale(1);
}

.lightbox-content img,
.lightbox-content video {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.lightbox-content img {
  z-index: 1;
}

.lightbox-content video {
  z-index: 2;
}

.lightbox-close {
  position: absolute;
  top: 0.75rem;
  right: 0.75rem;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border: 1px solid var(--color-gold);
  color: var(--color-gold);
  width: 40px;
  height: 40px;
  border-radius: 50%;
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-body);
  transition: all var(--transition);
  z-index: 10;
  padding: 0;
}

.lightbox-close:hover,
.lightbox-close:active {
  background: var(--color-gold);
  color: var(--color-bg);
}

/* Lock body scroll when lightbox is open */
body.lightbox-open {
  overflow: hidden;
}

/* ---------- Pillars ---------- */
.pillars {
  background: #1b0837;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  position: relative;
}

.pillars-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
}

@media (max-width: 980px) {
  .pillars-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 540px) {
  .pillars-grid { grid-template-columns: 1fr; }
}

.pillar {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 2.25rem 1.75rem;
  transition: all var(--transition);
  position: relative;
  overflow: hidden;
}

.pillar:hover {
  border-color: var(--color-border-strong);
  transform: translateY(-4px);
}

.pillar-icon {
  width: 44px;
  height: 44px;
  margin-bottom: 1.5rem;
  color: var(--color-gold);
}

.pillar h3 {
  font-size: 1.125rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: 1rem;
}

.pillar p {
  font-size: 0.95rem;
  line-height: 1.7;
}

/* ---------- Discovery (Origin story) ---------- */
.discovery {
  position: relative;
  overflow: hidden;
}

.discovery-bg {
  position: absolute;
  right: -10%;
  top: 50%;
  transform: translateY(-50%);
  width: min(600px, 80vw);
  height: min(600px, 80vw);
  max-width: 600px;
  opacity: 0.08;
  pointer-events: none;
}

@media (max-width: 860px) {
  .discovery-bg {
    right: -30%;
    width: 70vw;
    height: 70vw;
  }
}

.discovery-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4rem;
  align-items: center;
  position: relative;
  z-index: 2;
}

@media (max-width: 860px) {
  .discovery-grid { grid-template-columns: 1fr; }
}

.discovery-text h2 {
  margin-bottom: 1.5rem;
}

.discovery-text p + p {
  margin-top: 1.25rem;
}

.discovery-visual {
  display: flex;
  align-items: center;
  justify-content: center;
}

.discovery-visual svg {
  max-width: 100%;
  height: auto;
}

/* ---------- Distinguishers (What makes it different) ---------- */
.distinguishers {
  background: #1d1134;
  border-top: 1px solid var(--color-border);
}

.distinguishers-list {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 2rem 3rem;
  max-width: var(--container-narrow);
  margin: 0 auto;
  counter-reset: dist-counter;
}

@media (max-width: 720px) {
  .distinguishers-list { grid-template-columns: 1fr; }
}

.distinguisher {
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  counter-increment: dist-counter;
}

.distinguisher::before {
  content: counter(dist-counter, decimal-leading-zero);
  font-family: var(--font-display);
  font-size: 1.5rem;
  color: var(--color-gold);
  line-height: 1;
  min-width: 2.5rem;
  padding-top: 0.25rem;
}

.distinguisher h4 {
  color: var(--color-text);
  margin-bottom: 0.5rem;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.distinguisher p {
  font-size: 0.95rem;
}

/* ---------- Waitlist (Brevo embed area) ---------- */
.waitlist {
  background: linear-gradient(180deg, var(--color-bg) 0%, #341564 100%);
  text-align: center;
  position: relative;
  overflow: hidden;
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
}

.waitlist-bg {
  position: absolute;
  inset: 0;
  opacity: 0.15;
  z-index: 0;
  pointer-events: none;
}

.waitlist-content {
  position: relative;
  z-index: 2;
  max-width: 640px;
  margin: 0 auto;
}

.waitlist h2 {
  margin-bottom: 1.5rem;
}

.waitlist .lead {
  margin-bottom: 2.5rem;
}

.waitlist-form-wrap {
  background: var(--color-bg-card);
  border: 1px solid var(--color-border);
  border-radius: 12px;
  padding: 0.5rem 0.5rem;
  margin-top: 1rem;
}

/* Style placeholder for Brevo form */
.waitlist-form-wrap input[type="email"],
.waitlist-form-wrap input[type="text"] {
  width: 100%;
  padding: 14px 16px;
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 4px;
  color: var(--color-text);
  font-family: var(--font-body);
  font-size: 1rem;
  margin-bottom: 1rem;
  transition: border var(--transition);
}

.waitlist-form-wrap input:focus {
  outline: none;
  border-color: var(--color-gold);
}

/* ---------- Creator ---------- */
.creator {
  text-align: center;
}

.creator-portrait {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: var(--color-bg-card);
  border: 1px solid var(--color-border-strong);
  margin: 0 auto 2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--color-gold);
  font-family: var(--font-display);
  font-size: 2rem;
  overflow: hidden;
}

.creator-portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.creator h2 {
  margin-bottom: 0.5rem;
}

.creator-role {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: 2rem;
}

.creator-bio {
  max-width: 620px;
  margin: 0 auto;
}

/* ---------- Closing quote ---------- */
.closing {
  text-align: center;
  background: var(--color-bg);
  border-top: 1px solid var(--color-border);
  padding: 8rem 1.5rem;
}

.closing blockquote {
  font-family: var(--font-serif);
  font-size: clamp(1.5rem, 3.5vw, 2.25rem);
  line-height: 1.4;
  color: var(--color-text);
  font-style: italic;
  font-weight: 300;
  max-width: 760px;
  margin: 0 auto;
  position: relative;
}

.closing blockquote::before,
.closing blockquote::after {
  content: '';
  display: block;
  width: 40px;
  height: 1px;
  background: var(--color-gold);
  margin: 2rem auto;
}

/* ---------- Footer ---------- */
.site-footer {
  background: #130007;
  border-top: 1px solid var(--color-border);
  padding: 4rem 0 2rem;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 3rem;
  margin-bottom: 3rem;
}

@media (max-width: 760px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
  }
}

.footer-brand p {
  margin-top: 1rem;
  font-size: 0.875rem;
  max-width: 280px;
}

.footer-col h4 {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: var(--color-gold);
  margin-bottom: 1.25rem;
}

.footer-col ul {
  list-style: none;
}

.footer-col li {
  margin-bottom: 0.625rem;
}

.footer-col a {
  color: var(--color-text-soft);
  font-size: 0.9rem;
}

.footer-col a:hover { color: var(--color-gold); }

.footer-bottom {
  padding-top: 2rem;
  border-top: 1px solid var(--color-border);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

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

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}
