/* LUCIUS • Meditazione Spirituale — design system
   Brand: Nero Inferno, Ultravioletto, Oro. Dark only by design. */
:root {
  --inferno: #050307;
  --abyss: #0b0612;
  --night: #120a1f;
  --uv: #7a1fe0;
  --uv-glow: #9b4dff;
  --uv-deep: #2a0a52;
  --gold: #e8bf6a;
  --gold-soft: #f4dca6;
  --text: #ece6f5;
  --muted: #a99cbd;
  --line: rgba(232, 191, 106, .18);
  --radius: 18px;
  --serif: "Cormorant Garamond", Georgia, serif;
  --sans: "Josefin Sans", system-ui, sans-serif;
  --ease: cubic-bezier(.22, 1, .36, 1);
  --wrap: min(1160px, 100% - 32px);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--inferno);
  color: var(--text);
  font: 300 1.0625rem/1.75 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img, svg, canvas { display: block; max-width: 100%; }
a { color: var(--gold); text-underline-offset: 3px; }
a:hover { color: var(--gold-soft); }
::selection { background: var(--uv); color: #fff; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 3px; border-radius: 4px; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 100; background: var(--gold); color: var(--inferno); padding: 10px 16px; border-radius: 8px; }
.skip:focus { top: 16px; }

/* ---------- Typography ---------- */
h1, h2, h3 { font-family: var(--serif); font-weight: 500; line-height: 1.08; margin: 0 0 .5em; letter-spacing: -.01em; text-wrap: balance; }
h1 { font-size: clamp(2.6rem, 7vw, 5.6rem); }
h2 { font-size: clamp(2.1rem, 4.6vw, 3.6rem); }
h3 { font-size: clamp(1.45rem, 2.4vw, 1.9rem); }
p { margin: 0 0 1.1em; text-wrap: pretty; }
em, .gold { color: var(--gold); font-style: italic; }
.eyebrow {
  display: inline-flex; align-items: center; gap: .7em;
  font: 400 .78rem/1 var(--sans); letter-spacing: .32em; text-transform: uppercase; color: var(--gold);
  margin-bottom: 1.4rem;
}
.eyebrow::before { content: ""; width: 9px; height: 9px; border: 1px solid var(--gold); border-radius: 50%; box-shadow: inset 0 0 0 2.5px var(--inferno), inset 0 0 0 5px var(--gold); }
.lead { font-size: clamp(1.1rem, 1.6vw, 1.3rem); color: var(--muted); max-width: 62ch; }
.center { text-align: center; margin-inline: auto; }

/* ---------- Layout ---------- */
.wrap { width: var(--wrap); margin-inline: auto; }
section { position: relative; padding: clamp(80px, 12vw, 160px) 0; scroll-margin-top: 72px; }
.grid { display: grid; gap: clamp(20px, 3vw, 32px); }
@media (min-width: 760px) {
  .grid-2 { grid-template-columns: 1fr 1fr; align-items: center; }
  .grid-3 { grid-template-columns: repeat(3, 1fr); }
  .grid-4 { grid-template-columns: repeat(4, 1fr); }
}
@media (min-width: 560px) and (max-width: 759px) { .grid-4, .grid-3 { grid-template-columns: 1fr 1fr; } }
.divider { height: 1px; background: linear-gradient(90deg, transparent, var(--line), transparent); border: 0; margin: 0; }

/* ---------- Header ---------- */
.site-header {
  position: fixed; inset: 0 0 auto; z-index: 50;
  transition: background .4s var(--ease), backdrop-filter .4s;
}
.site-header.scrolled { background: rgba(5, 3, 7, .72); backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px); border-bottom: 1px solid var(--line); }
.nav { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.brand { display: flex; align-items: center; gap: 12px; text-decoration: none; color: var(--text); }
.brand { color: var(--gold); }
.brand:hover { color: var(--gold-soft); }
.brand-name { font: 400 .8rem/1.15 var(--sans); letter-spacing: .24em; text-align: center; }
.brand-name small { display: block; font-size: .6rem; letter-spacing: .34em; margin-top: 4px; opacity: .85; }
.nav-links { display: flex; gap: 28px; list-style: none; margin: 0; padding: 0; }
.nav-links a { color: var(--text); text-decoration: none; font-size: .8rem; letter-spacing: .2em; text-transform: uppercase; opacity: .8; transition: opacity .3s, color .3s; }
.nav-links a:hover { opacity: 1; color: var(--gold); }
.nav-toggle { display: none; background: none; border: 0; color: var(--text); width: 44px; height: 44px; cursor: pointer; }
@media (max-width: 900px) {
  .nav-toggle { display: grid; place-items: center; }
  .nav-links {
    position: fixed; inset: 72px 0 auto; flex-direction: column; gap: 0; padding: 12px 16px 24px;
    background: rgba(5, 3, 7, .96); border-bottom: 1px solid var(--line);
    transform: translateY(-8px); opacity: 0; pointer-events: none; transition: .35s var(--ease);
  }
  .nav-links a { display: block; padding: 14px 0; border-bottom: 1px solid rgba(255,255,255,.05); }
  .nav-open .nav-links { transform: none; opacity: 1; pointer-events: auto; }
  .nav .btn-sm { display: none; }
}

/* ---------- Buttons ---------- */
.btn {
  --b: var(--gold);
  display: inline-flex; align-items: center; justify-content: center; gap: .7em;
  min-height: 52px; padding: 0 30px; border-radius: 999px;
  font: 400 .82rem/1 var(--sans); letter-spacing: .22em; text-transform: uppercase; text-decoration: none;
  cursor: pointer; border: 1px solid var(--b); transition: transform .4s var(--ease), box-shadow .4s, background .4s, color .4s;
}
.btn-gold { background: var(--gold); color: var(--inferno); box-shadow: 0 0 0 0 rgba(232,191,106,.5), 0 10px 40px -10px rgba(155,77,255,.7); }
.btn-gold:hover { color: var(--inferno); transform: translateY(-2px); box-shadow: 0 0 0 6px rgba(232,191,106,.12), 0 18px 50px -10px rgba(155,77,255,.9); }
.btn-ghost { background: transparent; color: var(--text); --b: rgba(236,230,245,.3); }
.btn-ghost:hover { color: var(--gold); --b: var(--gold); }
.btn-sm { min-height: 40px; padding: 0 20px; font-size: .72rem; }
.btn:active { transform: scale(.97); }
.btn[disabled] { opacity: .5; pointer-events: none; }

/* ---------- Sigil (logo) ---------- */
.sigil { position: relative; width: var(--s, 40px); aspect-ratio: 1; border-radius: 50%; flex: none;
  background: radial-gradient(circle at 50% 50%, var(--gold) 0 13%, #000 13.5% 100%);
  box-shadow: inset 0 0 0 calc(var(--s, 40px) * .04) var(--gold), 0 0 calc(var(--s, 40px) * .35) rgba(122,31,224,.75); }
.sigil.breathe { animation: breathe 8s var(--ease) infinite; }
@keyframes breathe {
  0%, 100% { box-shadow: inset 0 0 0 calc(var(--s) * .035) var(--gold), 0 0 calc(var(--s) * .18) rgba(122,31,224,.55), 0 0 calc(var(--s) * .5) rgba(122,31,224,.25); }
  50% { box-shadow: inset 0 0 0 calc(var(--s) * .035) var(--gold), 0 0 calc(var(--s) * .32) rgba(155,77,255,.85), 0 0 calc(var(--s) * 1) rgba(122,31,224,.45); }
}

/* ---------- Hero ---------- */
.hero { min-height: 100svh; display: grid; place-items: center; padding: 120px 0 80px; text-align: center; overflow: hidden; }
.hero::after { content: ""; position: absolute; inset: auto 0 0; height: 30%; background: linear-gradient(transparent, var(--inferno)); pointer-events: none; }
#stars { position: absolute; inset: 0; width: 100%; height: 100%; }
.hero-glow { position: absolute; width: 120vmax; aspect-ratio: 1; left: 50%; top: 42%; translate: -50% -50%;
  background: radial-gradient(circle, rgba(122,31,224,.32), rgba(42,10,82,.15) 35%, transparent 60%); pointer-events: none; }
.hero-inner { position: relative; z-index: 2; }
.hero .sigil { --s: clamp(110px, 18vw, 170px); margin: 0 auto 44px; }
.hero h1 { max-width: 15ch; margin-inline: auto; font-size: clamp(2.3rem, 5.4vw, 4.4rem); }

/* Lockup del logo: disco nero, alone UV, sigillo + wordmark oro */
.emblem {
  width: min(400px, 46svh, 84vw); aspect-ratio: 1; border-radius: 50%; margin: 0 auto 40px;
  container-type: inline-size; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: #000; color: var(--gold); font-family: var(--sans); font-weight: 400; line-height: 1.12; text-align: center;
  box-shadow: 0 0 50px 8px rgba(106, 10, 196, .8), 0 0 140px 40px rgba(76, 0, 150, .38);
}
.emblem .sigil { --s: 17cqw; margin: -6cqw 0 5cqw; }
.emblem b { display: block; font-weight: 400; font-size: 7.6cqw; letter-spacing: .21em; margin-right: -.21em; }
.emblem b + b { font-size: 9.8cqw; letter-spacing: .13em; margin-right: -.13em; }
.emblem small { margin-top: 3.5cqw; font-size: 4.4cqw; letter-spacing: .32em; margin-right: -.32em; }
.hero .lead { margin: 0 auto 2.4rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 14px; justify-content: center; }
.hero-note { margin-top: 22px; font-size: .82rem; color: var(--muted); letter-spacing: .06em; }
.scroll-cue { position: absolute; z-index: 2; bottom: 28px; left: 50%; translate: -50% 0; width: 1px; height: 54px; background: linear-gradient(var(--gold), transparent); animation: cue 2.4s var(--ease) infinite; }
@keyframes cue { 0% { transform: scaleY(0); transform-origin: top; } 50% { transform: scaleY(1); transform-origin: top; } 51% { transform-origin: bottom; } 100% { transform: scaleY(0); transform-origin: bottom; } }

/* ---------- Cards ---------- */
.card {
  position: relative; padding: clamp(24px, 3vw, 36px); border-radius: var(--radius);
  background: linear-gradient(160deg, rgba(42,10,82,.35), rgba(11,6,18,.6) 60%);
  border: 1px solid rgba(155,77,255,.16);
  transition: transform .5s var(--ease), border-color .5s, box-shadow .5s;
}
.card:hover { transform: translateY(-4px); border-color: rgba(232,191,106,.35); box-shadow: 0 24px 60px -30px rgba(122,31,224,.7); }
.card h3 { margin-bottom: .35em; }
.card p { color: var(--muted); font-size: .98rem; margin: 0; }
.card .tag { display: block; font-size: .7rem; letter-spacing: .26em; text-transform: uppercase; color: var(--gold); margin-bottom: 14px; }

/* ---------- Mirror (identificazione) ---------- */
.mirror-list { list-style: none; margin: 2.4rem 0 0; padding: 0; display: grid; gap: 14px; }
.mirror-list li { display: flex; gap: 16px; align-items: flex-start; font-family: var(--serif); font-size: clamp(1.25rem, 2.2vw, 1.6rem); line-height: 1.35; }
.mirror-list li::before { content: ""; flex: none; margin-top: .45em; width: 10px; height: 10px; border-radius: 50%; background: var(--gold); box-shadow: 0 0 14px var(--uv-glow); }

/* ---------- Breath orb ---------- */
.breath { display: grid; justify-items: center; gap: 28px; text-align: center; }
.orb-stage { position: relative; width: min(320px, 78vw); aspect-ratio: 1; display: grid; place-items: center; }
.orb-ring { position: absolute; inset: 0; border-radius: 50%; border: 1px solid var(--line); }
.orb {
  width: 34%; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle at 50% 50%, var(--gold) 0 18%, #000 19% 100%);
  box-shadow: inset 0 0 0 3px var(--gold), 0 0 50px rgba(122,31,224,.8), 0 0 120px rgba(122,31,224,.4);
  transition: transform var(--dur, 4s) cubic-bezier(.45, 0, .55, 1);
}
.orb.in { transform: scale(2.6); }
.breath-label { font-family: var(--serif); font-size: clamp(1.6rem, 3vw, 2.2rem); min-height: 1.3em; }
.breath-count { font-size: .8rem; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); min-height: 1.2em; }

/* ---------- Serpente / tradizioni ---------- */
.serpent-track { display: grid; gap: 16px; grid-auto-flow: column; grid-auto-columns: minmax(250px, 1fr); overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px 2px 24px; scrollbar-width: thin; scrollbar-color: var(--uv) transparent; }
.serpent-track .card { scroll-snap-align: start; }
.glyph { font-family: var(--serif); font-size: 2.6rem; line-height: 1; color: var(--gold); margin-bottom: 18px; text-shadow: 0 0 24px rgba(155,77,255,.8); }

/* ---------- Chakra ---------- */
.chakra-wrap { display: grid; gap: 40px; align-items: center; }
@media (min-width: 860px) { .chakra-wrap { grid-template-columns: 300px 1fr; gap: 80px; } }
.nadi { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none;
  filter: drop-shadow(0 0 3px rgba(232,191,106,.9)) drop-shadow(0 0 10px rgba(155,77,255,.75)); animation: nadi 3.2s ease-in-out infinite; }
.nadi path { fill: none; stroke: url(#nadi-gold); stroke-width: 2.5; stroke-linecap: round; }
.nadi .head { fill: #fff3d0; }
@keyframes nadi { 50% { filter: drop-shadow(0 0 5px rgba(244,220,166,1)) drop-shadow(0 0 16px rgba(155,77,255,.95)); } }
.spine.awake .chakra-btn:last-of-type { animation: crown 2.4s ease-in-out infinite; }
@keyframes crown { 50% { box-shadow: 0 0 60px 12px var(--c), 0 0 0 4px var(--inferno), 0 0 0 5px var(--gold); } }
.spine { position: relative; display: flex; flex-direction: column-reverse; align-items: center; gap: 18px; width: 150px; padding: 10px 0; margin-inline: auto; }
.spine::before { content: ""; position: absolute; top: 0; bottom: 0; left: 50%; width: 2px; translate: -50% 0; background: linear-gradient(var(--uv-deep), var(--uv-deep)); }
.spine-fill { position: absolute; bottom: 0; left: 50%; width: 2px; translate: -50% 0; height: var(--rise, 0%); background: linear-gradient(to top, var(--gold), var(--uv-glow)); box-shadow: 0 0 12px var(--uv-glow); transition: height 1.2s var(--ease); }
.chakra-btn {
  position: relative; z-index: 1; width: 52px; height: 52px; border-radius: 50%; cursor: pointer;
  border: 1px solid color-mix(in srgb, var(--c) 60%, transparent);
  background: radial-gradient(circle, color-mix(in srgb, var(--c) 55%, transparent), var(--inferno) 70%);
  color: #fff; font: 400 .72rem/1 var(--sans); letter-spacing: .05em;
  transition: transform .4s var(--ease), box-shadow .4s;
}
.chakra-btn:hover, .chakra-btn[aria-pressed="true"] { transform: scale(1.18); box-shadow: 0 0 28px var(--c), 0 0 0 4px rgba(5,3,7,1), 0 0 0 5px var(--c); }
.chakra-panel { min-height: 340px; }
.chakra-panel .meta { display: flex; flex-wrap: wrap; gap: 10px; margin: 18px 0 22px; }
.pill { font-size: .72rem; letter-spacing: .18em; text-transform: uppercase; padding: 8px 14px; border-radius: 999px; border: 1px solid var(--line); color: var(--muted); }
.pill b { color: var(--gold); font-weight: 400; }
.chakra-panel h3 { color: var(--c, var(--gold)); font-size: clamp(2rem, 4vw, 3rem); }

/* ---------- Path steps ---------- */
.steps { counter-reset: s; }
.step { padding-top: 26px; border-top: 1px solid var(--line); }
.step::before { counter-increment: s; content: "0" counter(s); display: block; font-family: var(--serif); font-size: 3.4rem; line-height: 1; color: transparent; -webkit-text-stroke: 1px var(--gold); margin-bottom: 18px; }
.step ul { margin: 14px 0 0; padding-left: 1.1em; color: var(--muted); font-size: .96rem; }

/* ---------- Quote ---------- */
.quote { font-family: var(--serif); font-style: italic; font-size: clamp(1.8rem, 4vw, 3.1rem); line-height: 1.2; max-width: 22ch; margin: 0 auto; text-align: center; }
.quote cite { display: block; margin-top: 22px; font: 400 .76rem/1 var(--sans); font-style: normal; letter-spacing: .3em; text-transform: uppercase; color: var(--gold); }

/* ---------- Streak ---------- */
.streak { display: inline-flex; align-items: center; gap: 14px; padding: 14px 22px; border-radius: 999px; border: 1px solid var(--line); background: rgba(42,10,82,.25); font-size: .9rem; }
.streak-dots { display: flex; gap: 6px; }
.streak-dots i { width: 9px; height: 9px; border-radius: 50%; border: 1px solid var(--gold); }
.streak-dots i.on { background: var(--gold); box-shadow: 0 0 10px var(--gold); }

/* ---------- Forms ---------- */
.form { display: grid; gap: 14px; }
.field { display: grid; gap: 6px; }
.field label { font-size: .74rem; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }
input, textarea {
  width: 100%; padding: 15px 18px; border-radius: 12px; border: 1px solid rgba(155,77,255,.25); background: rgba(5,3,7,.6);
  color: var(--text); font: inherit; font-size: 1rem; transition: border-color .3s, box-shadow .3s;
}
input:focus, textarea:focus { outline: none; border-color: var(--gold); box-shadow: 0 0 0 4px rgba(232,191,106,.12); }
textarea { min-height: 140px; resize: vertical; }
.check { display: flex; gap: 12px; align-items: flex-start; font-size: .86rem; color: var(--muted); line-height: 1.5; }
.check input { width: 18px; height: 18px; margin-top: 2px; accent-color: var(--gold); flex: none; padding: 0; }
.hp { position: absolute; left: -9999px; }
.form-msg { min-height: 1.5em; font-size: .92rem; margin: 0; }
.form-msg.ok { color: var(--gold); }
.form-msg.err { color: #ff9b9b; }
.panel { padding: clamp(28px, 5vw, 56px); border-radius: 28px; border: 1px solid var(--line);
  background: radial-gradient(120% 120% at 0% 0%, rgba(122,31,224,.28), transparent 55%), var(--abyss); }

/* ---------- FAQ ---------- */
details { border-bottom: 1px solid var(--line); }
summary { list-style: none; cursor: pointer; display: flex; justify-content: space-between; gap: 20px; padding: 24px 0; font-family: var(--serif); font-size: clamp(1.2rem, 2vw, 1.5rem); }
summary::-webkit-details-marker { display: none; }
summary::after { content: "+"; color: var(--gold); font-family: var(--sans); font-weight: 200; font-size: 1.6rem; line-height: 1; transition: transform .4s var(--ease); }
details[open] summary::after { transform: rotate(45deg); }
details p { color: var(--muted); padding-bottom: 20px; max-width: 70ch; }

/* ---------- Footer ---------- */
.site-footer { padding: 70px 0 40px; border-top: 1px solid var(--line); color: var(--muted); font-size: .88rem; }
.footer-grid { display: flex; flex-wrap: wrap; gap: 30px; justify-content: space-between; align-items: flex-start; }
.footer-links { display: flex; flex-wrap: wrap; gap: 22px; list-style: none; padding: 0; margin: 0; }
.footer-links a { color: var(--muted); text-decoration: none; }
.footer-links a:hover { color: var(--gold); }
.disclaimer { margin-top: 36px; font-size: .78rem; opacity: .75; max-width: 90ch; }

/* ---------- Reveal ---------- */
.reveal { opacity: 0; transform: translateY(28px); transition: opacity 1.1s var(--ease), transform 1.1s var(--ease); transition-delay: var(--d, 0s); }
.reveal.in { opacity: 1; transform: none; }

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