/* ═══════════════════════════════════════════════════════════════
   ANCIENT SOULS COLLECTIVE — Design System
   Celestial luxe: deep midnight, antique gold, aurora light
   ═══════════════════════════════════════════════════════════════ */

:root {
  --ink: #0a0913;
  --ink-2: #110f1f;
  --ink-3: #181430;
  --panel: rgba(24, 20, 48, 0.55);
  --panel-border: rgba(212, 169, 94, 0.22);
  --gold: #d4a95e;
  --gold-bright: #ecc987;
  --gold-dim: #9b7c45;
  --cream: #f2ecdd;
  --body-text: #cfc8bd;
  --muted: #948d9e;
  --lavender: #c9b3e6;
  --rose: #dca8c8;
  --teal: #6fd5c3;
  --violet: #8d7ad8;
  --font-display: "Cinzel", serif;
  --font-serif: "Cormorant Garamond", serif;
  --font-script: "Parisienne", cursive;
  --maxw: 1120px;
  --maxw-text: 760px;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--ink);
  color: var(--body-text);
  font-family: var(--font-serif);
  font-size: 1.22rem;
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

::selection { background: rgba(212, 169, 94, 0.35); color: var(--cream); }

img { max-width: 100%; display: block; }
a { color: var(--gold); text-decoration: none; transition: color .3s; }
a:hover { color: var(--gold-bright); }

/* ── Starfield canvas ── */
#starfield {
  position: fixed; inset: 0;
  width: 100%; height: 100%;
  z-index: 0; pointer-events: none;
}

main { position: relative; z-index: 1; }

/* ── Typography ── */
h1, h2, h3 { font-family: var(--font-display); color: var(--cream); font-weight: 500; }

.eyebrow {
  font-family: var(--font-display);
  font-size: .78rem;
  letter-spacing: .42em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 1.2rem;
}

.script { font-family: var(--font-script); color: var(--gold-bright); font-weight: 400; }

.lede {
  font-size: 1.45rem;
  font-style: italic;
  color: var(--cream);
  line-height: 1.6;
}

/* ── Layout ── */
.wrap { max-width: var(--maxw); margin: 0 auto; padding: 0 1.5rem; }
.wrap-text { max-width: var(--maxw-text); margin: 0 auto; padding: 0 1.5rem; }

section { padding: 6rem 0; position: relative; }
section.tight { padding: 3.5rem 0; }

.center { text-align: center; }

/* ── Gold ornaments ── */
.star-divider {
  display: flex; align-items: center; justify-content: center;
  gap: 1.2rem; margin: 2.6rem auto;
}
.star-divider::before, .star-divider::after {
  content: ""; height: 1px; width: min(140px, 22vw);
  background: linear-gradient(90deg, transparent, var(--gold-dim));
}
.star-divider::after { background: linear-gradient(90deg, var(--gold-dim), transparent); }
.star-divider svg { width: 22px; height: 22px; flex-shrink: 0; }

.hairline {
  height: 1px; border: 0; margin: 0 auto;
  width: min(380px, 60vw);
  background: linear-gradient(90deg, transparent, var(--gold-dim), transparent);
}

/* ── Navigation ── */
header.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  transition: background .4s, box-shadow .4s, padding .4s;
  padding: 1.4rem 0;
}
header.nav.scrolled {
  background: rgba(10, 9, 19, 0.86);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  box-shadow: 0 1px 0 rgba(212, 169, 94, 0.15);
  padding: .8rem 0;
}
.nav-inner {
  max-width: var(--maxw); margin: 0 auto; padding: 0 1.5rem;
  display: flex; align-items: center; justify-content: space-between;
}
.nav-logo img { height: 38px; width: auto; }
nav.links { display: flex; gap: 2rem; align-items: center; }
nav.links a {
  font-family: var(--font-display);
  font-size: .72rem; letter-spacing: .22em; text-transform: uppercase;
  color: var(--cream); position: relative; padding: .3rem 0;
}
nav.links a::after {
  content: ""; position: absolute; left: 0; bottom: 0;
  width: 0; height: 1px; background: var(--gold);
  transition: width .35s;
}
nav.links a:hover::after, nav.links a.active::after { width: 100%; }
nav.links a.active { color: var(--gold); }

.nav-toggle {
  display: none; background: none; border: none; cursor: pointer;
  flex-direction: column; gap: 6px; padding: 6px;
}
.nav-toggle span {
  width: 26px; height: 1.5px; background: var(--gold);
  transition: transform .3s, opacity .3s;
}

@media (max-width: 920px) {
  .nav-toggle { display: flex; }
  nav.links {
    position: fixed; inset: 0; flex-direction: column; justify-content: center;
    background: rgba(10, 9, 19, 0.97); gap: 2.4rem;
    opacity: 0; pointer-events: none; transition: opacity .35s;
  }
  nav.links.open { opacity: 1; pointer-events: auto; }
  nav.links a { font-size: .95rem; }
  body.nav-open { overflow: hidden; }
  .nav-toggle { position: relative; z-index: 101; }
  body.nav-open .nav-toggle span:nth-child(1) { transform: translateY(7.5px) rotate(45deg); }
  body.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  body.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-7.5px) rotate(-45deg); }
}

/* ── Hero ── */
.hero {
  min-height: 100vh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center; position: relative;
  padding: 8rem 1.5rem 5rem;
  overflow: hidden;
}
.hero-aurora {
  position: absolute; inset: -20%;
  background:
    radial-gradient(ellipse 55% 45% at 22% 30%, rgba(141, 122, 216, 0.20), transparent 65%),
    radial-gradient(ellipse 50% 42% at 78% 26%, rgba(111, 213, 195, 0.11), transparent 65%),
    radial-gradient(ellipse 60% 48% at 55% 75%, rgba(212, 169, 94, 0.12), transparent 65%),
    radial-gradient(ellipse 45% 38% at 35% 65%, rgba(220, 168, 200, 0.10), transparent 65%);
  animation: aurora-drift 26s ease-in-out infinite alternate;
  pointer-events: none;
}
@keyframes aurora-drift {
  0%   { transform: rotate(0deg) scale(1); }
  50%  { transform: rotate(2.5deg) scale(1.07); }
  100% { transform: rotate(-2deg) scale(1.03); }
}
.hero > :not(.hero-aurora) { position: relative; }

.hero .star-mark { width: 92px; height: 92px; margin-bottom: 2.2rem; opacity: .95; }

.hero .script { font-size: clamp(1.9rem, 3.5vw, 2.7rem); margin-bottom: .6rem; }

.hero h1 {
  font-size: clamp(2.1rem, 5.4vw, 4.1rem);
  letter-spacing: .18em;
  line-height: 1.25;
  font-weight: 500;
  background: linear-gradient(120deg, var(--gold-bright), var(--cream) 38%, var(--gold) 72%, var(--gold-bright));
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: shimmer 9s linear infinite;
}
@keyframes shimmer { to { background-position: 220% center; } }

.hero .tagline {
  margin-top: 1.8rem;
  font-size: clamp(1.25rem, 2.2vw, 1.6rem);
  font-style: italic;
  color: var(--lavender);
  max-width: 620px;
}

.scroll-cue {
  position: absolute; bottom: 2.2rem; left: 50%;
  transform: translateX(-50%);
  color: var(--gold-dim); font-size: 1.6rem;
  animation: cue 2.6s ease-in-out infinite;
}
@keyframes cue { 0%,100% { transform: translate(-50%, 0); opacity:.6; } 50% { transform: translate(-50%, 10px); opacity:1; } }

/* ── Page hero (interior pages) ── */
.page-hero {
  padding: 11rem 1.5rem 4.5rem;
  text-align: center; position: relative; overflow: hidden;
}
.page-hero h1 {
  font-size: clamp(1.9rem, 4.2vw, 3rem);
  letter-spacing: .14em;
}
.page-hero .script { font-size: clamp(2.2rem, 4.5vw, 3.4rem); }

/* ── Buttons ── */
.btn {
  display: inline-block;
  font-family: var(--font-display);
  font-size: .78rem; letter-spacing: .3em; text-transform: uppercase;
  color: var(--ink); background: linear-gradient(135deg, var(--gold-bright), var(--gold));
  padding: 1.05rem 2.6rem;
  border: none; border-radius: 2px; cursor: pointer;
  transition: box-shadow .35s, transform .35s;
}
.btn:hover {
  box-shadow: 0 0 32px rgba(212, 169, 94, 0.45);
  transform: translateY(-2px);
  color: var(--ink);
}
.btn-ghost {
  background: transparent;
  color: var(--gold);
  border: 1px solid var(--gold-dim);
}
.btn-ghost:hover { border-color: var(--gold); color: var(--gold-bright); box-shadow: 0 0 24px rgba(212,169,94,.25); }

/* ── Cards ── */
.card {
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 4px;
  padding: 2.6rem 2.2rem;
  backdrop-filter: blur(6px);
  transition: border-color .4s, transform .4s, box-shadow .4s;
  position: relative;
}
.card:hover {
  border-color: rgba(212, 169, 94, 0.5);
  transform: translateY(-4px);
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.45);
}

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 2rem; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2rem; }
.grid-4 { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.6rem; }
@media (max-width: 920px) {
  .grid-3, .grid-4 { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 600px) {
  .grid-2, .grid-3, .grid-4 { grid-template-columns: 1fr; }
}

/* ── Offering cards ── */
.offering {
  display: flex; flex-direction: column;
  text-align: center;
}
.offering .stage-no {
  font-family: var(--font-display);
  color: var(--gold-dim); font-size: .8rem; letter-spacing: .4em;
  margin-bottom: .8rem;
}
.offering h3 {
  font-size: 1.25rem; letter-spacing: .12em; text-transform: uppercase;
  color: var(--gold-bright); margin-bottom: .4rem;
}
.offering .sub {
  font-style: italic; font-size: 1.18rem; color: var(--lavender);
  margin-bottom: 1.4rem;
}
.offering ul {
  list-style: none; text-align: left;
  margin: 0 auto 1.6rem; max-width: 330px;
  flex-grow: 1;
}
.offering ul li {
  padding-left: 1.5em; position: relative;
  margin-bottom: .55rem; font-size: 1.08rem;
}
.offering ul li::before {
  content: "✦"; position: absolute; left: 0;
  color: var(--gold-dim); font-size: .8em; top: .35em;
}
.offering .ideal {
  font-style: italic; color: var(--muted); font-size: 1.02rem;
  margin-bottom: 1.6rem;
}
.offering .price {
  font-family: var(--font-display);
  color: var(--cream); font-size: 1.05rem; letter-spacing: .14em;
  margin-bottom: 1.5rem;
}
.offering .price strong { color: var(--gold-bright); font-weight: 600; font-size: 1.3rem; }

/* ── Spiral stages strip (home) ── */
.stages { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1.4rem; margin-top: 3rem; }
@media (max-width: 920px) { .stages { grid-template-columns: 1fr 1fr; } }
@media (max-width: 560px) { .stages { grid-template-columns: 1fr; } }
.stage {
  text-align: center; padding: 2rem 1.2rem;
  border: 1px solid var(--panel-border); border-radius: 4px;
  background: var(--panel);
  transition: border-color .4s, transform .4s;
}
.stage:hover { border-color: rgba(212,169,94,.5); transform: translateY(-4px); }
.stage .n {
  font-family: var(--font-display); font-size: 2rem; color: var(--gold-dim);
  display: block; margin-bottom: .6rem;
}
.stage h3 { font-size: .95rem; letter-spacing: .22em; color: var(--gold-bright); margin-bottom: .5rem; }
.stage p { font-size: 1rem; font-style: italic; color: var(--muted); }

/* ── Flow / Where to begin ── */
.flow { max-width: 680px; margin: 3rem auto 0; }
.flow-q {
  text-align: center; font-style: italic; font-size: 1.3rem; color: var(--cream);
  margin: 2.2rem 0 1.1rem;
}
.flow-a {
  display: block;
  background: var(--panel);
  border: 1px solid var(--panel-border);
  border-radius: 4px;
  padding: 1.4rem 1.8rem;
  text-align: center;
  transition: border-color .35s, box-shadow .35s;
}
.flow-a:hover { border-color: var(--gold); box-shadow: 0 0 28px rgba(212,169,94,.18); }
.flow-a .t { font-family: var(--font-display); letter-spacing: .18em; text-transform: uppercase; font-size: .92rem; color: var(--gold-bright); }
.flow-a .d { font-size: 1.05rem; color: var(--muted); font-style: italic; margin-top: .3rem; }
.flow-arrow { text-align: center; color: var(--gold-dim); font-size: 1.5rem; margin-top: 1.6rem; }

/* ── Portal cards (home explore) ── */
.portal { text-align: center; padding: 2.8rem 1.8rem; }
.portal svg { width: 40px; height: 40px; margin: 0 auto 1.4rem; }
.portal h3 { font-size: 1.02rem; letter-spacing: .2em; text-transform: uppercase; color: var(--gold-bright); margin-bottom: .8rem; }
.portal p { font-size: 1.05rem; font-style: italic; color: var(--muted); }

/* ── Scrolls (Codex accordions) ── */
.scroll-item {
  border: 1px solid var(--panel-border);
  border-radius: 4px;
  background: var(--panel);
  margin-bottom: 1.2rem;
  overflow: hidden;
}
.scroll-item summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; gap: 1.2rem;
  padding: 1.6rem 1.8rem;
  transition: background .3s;
}
.scroll-item summary::-webkit-details-marker { display: none; }
.scroll-item summary:hover { background: rgba(212, 169, 94, 0.06); }
.scroll-item summary svg { width: 26px; height: 26px; flex-shrink: 0; }
.scroll-item summary .name {
  font-family: var(--font-display); color: var(--cream);
  font-size: 1rem; letter-spacing: .14em; flex-grow: 1;
}
.scroll-item summary .open-mark {
  color: var(--gold-dim); font-size: 1.3rem;
  transition: transform .35s;
}
.scroll-item[open] summary .open-mark { transform: rotate(45deg); }
.scroll-item[open] summary { border-bottom: 1px solid var(--panel-border); }

.scroll-body { padding: 2.4rem 2.4rem 2.8rem; }
.scroll-body .scroll-meta {
  text-align: center; font-style: italic; color: var(--muted);
  margin-bottom: 2rem; font-size: 1.05rem; line-height: 1.6;
}
.scroll-body h4 {
  font-family: var(--font-display); color: var(--gold);
  font-size: .92rem; letter-spacing: .2em; text-transform: uppercase;
  margin: 2rem 0 1rem;
}
.scroll-body ul { list-style: none; margin-bottom: 1.2rem; }
.scroll-body ul li { padding-left: 1.5em; position: relative; margin-bottom: .7rem; }
.scroll-body ul li::before { content: "•"; position: absolute; left: .3em; color: var(--gold-dim); }
.scroll-body ul ul { margin: .7rem 0 0; }
.scroll-body ul ul li::before { content: "–"; }
.scroll-body p { margin-bottom: 1.2rem; }
.scroll-body .seal {
  margin-top: 2.4rem; text-align: center;
  font-style: italic; color: var(--gold); font-size: 1.1rem;
}

/* ── Warning / callout ── */
.callout {
  border: 1px solid rgba(220, 168, 200, 0.3);
  border-left: 2px solid var(--rose);
  background: rgba(220, 168, 200, 0.05);
  padding: 1.6rem 2rem;
  border-radius: 4px;
  font-style: italic;
  color: var(--body-text);
}
.callout.gold {
  border-color: var(--panel-border);
  border-left-color: var(--gold);
  background: rgba(212, 169, 94, 0.05);
}

/* ── Videos ── */
.video-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.8rem; }
@media (max-width: 920px) { .video-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 600px) { .video-grid { grid-template-columns: 1fr; } }

.yt {
  position: relative; aspect-ratio: 16/9;
  border-radius: 4px; overflow: hidden;
  border: 1px solid var(--panel-border);
  cursor: pointer; background: #000;
  transition: border-color .35s, transform .35s;
}
.yt:hover { border-color: rgba(212,169,94,.55); transform: translateY(-3px); }
.yt img { width: 100%; height: 100%; object-fit: cover; opacity: .85; transition: opacity .3s, transform .6s; }
.yt:hover img { opacity: 1; transform: scale(1.04); }
.yt .play {
  position: absolute; inset: 0; display: flex;
  align-items: center; justify-content: center;
  pointer-events: none;
}
.yt .play span {
  width: 58px; height: 58px; border-radius: 50%;
  background: rgba(10, 9, 19, 0.72);
  border: 1px solid var(--gold);
  display: flex; align-items: center; justify-content: center;
  color: var(--gold-bright); font-size: 1.2rem; padding-left: 4px;
  transition: background .3s, box-shadow .3s;
}
.yt:hover .play span { background: rgba(212,169,94,.25); box-shadow: 0 0 30px rgba(212,169,94,.4); }
.yt iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.video-title {
  margin-top: .9rem; font-size: 1.05rem; color: var(--cream);
  font-style: italic; line-height: 1.45;
}
.video-feature { max-width: 860px; margin: 0 auto 4rem; }

/* ── Forms (Flame Gate) ── */
form .field { margin-bottom: 1.7rem; }
form label {
  display: block;
  font-family: var(--font-display);
  font-size: .72rem; letter-spacing: .26em; text-transform: uppercase;
  color: var(--gold); margin-bottom: .6rem;
}
form input, form select, form textarea {
  width: 100%;
  background: rgba(10, 9, 19, 0.6);
  border: 1px solid var(--panel-border);
  border-radius: 3px;
  color: var(--cream);
  font-family: var(--font-serif);
  font-size: 1.15rem;
  padding: .95rem 1.1rem;
  transition: border-color .3s, box-shadow .3s;
}
form input:focus, form select:focus, form textarea:focus {
  outline: none; border-color: var(--gold);
  box-shadow: 0 0 18px rgba(212, 169, 94, 0.18);
}
form textarea { min-height: 170px; resize: vertical; }
form select option { background: var(--ink-2); }
.form-note {
  margin-top: 1.4rem; font-style: italic; color: var(--muted); font-size: 1rem;
  text-align: center;
}
.form-sent {
  display: none; text-align: center; padding: 3rem 1rem;
  font-style: italic; font-size: 1.3rem; color: var(--gold-bright);
}

/* ── About ── */
.about-photo {
  border: 1px solid var(--panel-border); border-radius: 4px;
  padding: 10px; background: rgba(212, 169, 94, 0.04);
}
.about-photo img { border-radius: 2px; }
.titles-line {
  font-family: var(--font-display);
  font-size: .8rem; letter-spacing: .3em; text-transform: uppercase;
  color: var(--gold); text-align: center; line-height: 2.2;
}
.bio p { margin-bottom: 1.5rem; }
.bio .em { color: var(--cream); font-style: italic; }

/* ── Diary entries ── */
.entry-card { display: grid; grid-template-columns: 340px 1fr; gap: 0; overflow: hidden; padding: 0; }
@media (max-width: 760px) { .entry-card { grid-template-columns: 1fr; } }
.entry-card .cover { position: relative; min-height: 240px; }
.entry-card .cover img { width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0; }
.entry-card .body { padding: 2.6rem 2.4rem; }
.entry-card .body h3 { font-size: 1.2rem; letter-spacing: .14em; color: var(--gold-bright); margin-bottom: 1rem; }
.entry-card .body p { font-style: italic; margin-bottom: 1.6rem; }

.entry-text { font-size: 1.3rem; line-height: 1.95; }
.entry-text p { margin-bottom: 1.7rem; }
.entry-sig {
  margin-top: 3rem; text-align: right;
  font-family: var(--font-script); font-size: 2rem; color: var(--gold-bright);
}

/* ── Footer ── */
footer {
  position: relative; z-index: 1;
  border-top: 1px solid rgba(212, 169, 94, 0.15);
  padding: 4.5rem 1.5rem 3rem;
  text-align: center;
  background: linear-gradient(180deg, transparent, rgba(17, 15, 31, 0.8));
}
footer .star-mark { width: 44px; height: 44px; margin: 0 auto 1.8rem; opacity: .8; }
footer .socials { display: flex; justify-content: center; gap: 1.8rem; margin-bottom: 2rem; }
footer .socials a {
  width: 44px; height: 44px; border-radius: 50%;
  border: 1px solid var(--gold-dim);
  display: flex; align-items: center; justify-content: center;
  transition: border-color .3s, box-shadow .3s, transform .3s;
}
footer .socials a:hover { border-color: var(--gold-bright); box-shadow: 0 0 20px rgba(212,169,94,.3); transform: translateY(-2px); }
footer .socials svg { width: 18px; height: 18px; fill: var(--gold); }
footer .copy { font-size: 1rem; color: var(--muted); font-style: italic; line-height: 1.9; }
footer .copy .protect { font-size: .95rem; }

/* ── Reveal on scroll ── */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity .9s ease, transform .9s ease; }
.reveal.visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
  .hero-aurora, .hero h1, .scroll-cue { animation: none; }
}

/* ── Misc ── */
.mt-1 { margin-top: 1rem; } .mt-2 { margin-top: 2rem; } .mt-3 { margin-top: 3rem; }
.mb-1 { margin-bottom: 1rem; } .mb-2 { margin-bottom: 2rem; } .mb-3 { margin-bottom: 3rem; }
.section-title { text-align: center; margin-bottom: 1rem; font-size: clamp(1.6rem, 3.2vw, 2.3rem); letter-spacing: .12em; }
.section-sub { text-align: center; font-style: italic; color: var(--lavender); font-size: 1.25rem; max-width: 640px; margin: 0 auto; }
.fine-print { font-size: 1rem; color: var(--muted); font-style: italic; line-height: 1.8; }
