/* Disco Heart Shop — cosmic scroll site
   Tone: SpaceX Starbase / sparse cinematic facility pages */

:root {
  --bg: #03050a;
  --bg-2: #070b14;
  --ink: #f3efe6;
  --ink-dim: #9a9488;
  --ink-mute: #5c574f;
  --line: rgba(243, 239, 230, 0.12);
  --glow: rgba(180, 210, 255, 0.35);
  --glow-warm: rgba(255, 190, 140, 0.28);
  --magenta: rgba(220, 80, 180, 0.22);
  --cyan: rgba(80, 200, 255, 0.18);
  --nav-h: 4.25rem;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --font-display: "Cormorant Garamond", "Times New Roman", Georgia, serif;
  --font-ui: "Syne", system-ui, sans-serif;
}

*,
*::before,
*::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  background: var(--bg);
  color: var(--ink);
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
}

body {
  margin: 0;
  min-height: 100%;
  font-family: var(--font-ui);
  font-weight: 400;
  letter-spacing: 0.01em;
  background: transparent;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; }

.skip-link {
  position: absolute;
  left: -999px;
  top: 0;
  background: var(--ink);
  color: var(--bg);
  padding: 0.75rem 1rem;
  z-index: 100;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* ---------- Atmospheric layers ---------- */
.starfield {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(ellipse 120% 80% at 50% -10%, #10182a 0%, var(--bg) 55%);
}

.nebula {
  position: fixed;
  inset: -10%;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(ellipse 50% 40% at 18% 30%, var(--magenta), transparent 60%),
    radial-gradient(ellipse 45% 35% at 82% 55%, var(--cyan), transparent 55%),
    radial-gradient(ellipse 60% 50% at 50% 110%, rgba(40, 60, 120, 0.35), transparent 50%);
  opacity: 0.85;
  mix-blend-mode: screen;
  animation: nebula-drift 48s ease-in-out infinite alternate;
}

.vignette {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  background:
    radial-gradient(ellipse 70% 60% at 50% 45%, transparent 40%, rgba(0,0,0,0.55) 100%),
    linear-gradient(to bottom, rgba(0,0,0,0.35), transparent 18%, transparent 82%, rgba(0,0,0,0.5));
}

@keyframes nebula-drift {
  from { transform: translate3d(-2%, -1%, 0) scale(1); }
  to   { transform: translate3d(2%, 1.5%, 0) scale(1.06); }
}

@media (prefers-reduced-motion: reduce) {
  .nebula { animation: none; }
}

/* ---------- Nav ---------- */
.nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(1.25rem, 4vw, 3rem);
  z-index: 50;
  mix-blend-mode: difference;
}

.nav-brand {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 0.8125rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.nav-inquire {
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  opacity: 0.85;
  border-bottom: 1px solid transparent;
  transition: opacity 0.3s var(--ease), border-color 0.3s;
}
.nav-inquire:hover { opacity: 1; border-color: currentColor; }

/* ---------- Panels ---------- */
main { position: relative; z-index: 10; }

.panel {
  position: relative;
  min-height: 100svh;
  min-height: 100dvh;
  display: grid;
  align-items: center;
  padding: calc(var(--nav-h) + 1rem) clamp(1.25rem, 5vw, 4rem) 3rem;
}

/* ---------- Hero ---------- */
.hero {
  grid-template-rows: 1fr auto;
  justify-items: center;
  text-align: center;
  overflow: hidden;
}

.hero-orbit {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  pointer-events: none;
  z-index: 0;
}

.hero-heart {
  width: min(52vw, 420px);
  filter:
    drop-shadow(0 0 40px rgba(180, 120, 255, 0.35))
    drop-shadow(0 30px 60px rgba(0,0,0,0.65));
  opacity: 0.92;
  transform: translateY(-4%) rotate(-6deg);
  animation: hero-float 9s ease-in-out infinite;
}

@keyframes hero-float {
  0%, 100% { transform: translateY(-4%) rotate(-6deg); }
  50% { transform: translateY(-7%) rotate(-2deg); }
}

@media (prefers-reduced-motion: reduce) {
  .hero-heart { animation: none; }
}

.hero-copy {
  position: relative;
  z-index: 2;
  margin-top: min(38vh, 320px);
  max-width: 22ch;
}

.eyebrow {
  font-family: var(--font-ui);
  font-size: 0.6875rem;
  font-weight: 500;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin: 0 0 1.25rem;
}

.hero h1,
.piece-copy h2,
.about h2,
.inquire h2 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 0.95;
  letter-spacing: -0.02em;
  margin: 0;
}

.hero h1 {
  font-size: clamp(2.75rem, 9vw, 6.5rem);
  font-style: italic;
}

.lede {
  margin: 1.5rem auto 0;
  max-width: 28ch;
  font-size: clamp(0.95rem, 1.6vw, 1.125rem);
  line-height: 1.55;
  color: var(--ink-dim);
  font-weight: 400;
}

.scroll-hint {
  position: absolute;
  bottom: 1.75rem;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.65rem;
  font-size: 0.625rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--ink-mute);
  z-index: 3;
}

.scroll-line {
  width: 1px;
  height: 3.25rem;
  background: linear-gradient(to bottom, var(--ink-dim), transparent);
  animation: scroll-pulse 2.4s ease-in-out infinite;
}

@keyframes scroll-pulse {
  0%, 100% { opacity: 0.35; transform: scaleY(0.85); transform-origin: top; }
  50% { opacity: 1; transform: scaleY(1); }
}

@media (prefers-reduced-motion: reduce) {
  .scroll-line { animation: none; }
}

/* ---------- Piece panels ---------- */
.piece {
  grid-template-columns: 1fr;
  gap: 2rem;
  align-content: center;
}

@media (min-width: 900px) {
  .piece {
    grid-template-columns: 1.1fr 0.9fr;
    gap: clamp(2rem, 6vw, 5rem);
    align-items: center;
  }
  .piece:nth-of-type(odd) .piece-stage { order: 0; }
  .piece:nth-of-type(odd) .piece-copy { order: 1; }
  .piece:nth-of-type(even) .piece-stage { order: 1; }
  .piece:nth-of-type(even) .piece-copy { order: 0; text-align: right; }
  .piece:nth-of-type(even) .piece-actions { justify-content: flex-end; }
  .piece:nth-of-type(even) .piece-spec { margin-left: auto; }
}

.piece-stage {
  display: grid;
  place-items: center;
  perspective: 1200px;
  min-height: min(52vh, 480px);
}

.heart-rig {
  position: relative;
  width: min(72vw, 380px);
  transform-style: preserve-3d;
  will-change: transform;
}

.piece--stand .heart-rig { width: min(62vw, 320px); }

.heart-img {
  position: relative;
  z-index: 1;
  width: 100%;
  filter: drop-shadow(0 24px 48px rgba(0,0,0,0.55));
  user-select: none;
  -webkit-user-drag: none;
}

.heart-glow {
  position: absolute;
  inset: 10% 5%;
  border-radius: 50%;
  background: radial-gradient(circle, var(--glow), transparent 70%);
  filter: blur(28px);
  z-index: 0;
  opacity: 0.7;
  pointer-events: none;
}
.heart-glow--warm {
  background: radial-gradient(circle, var(--glow-warm), transparent 70%);
}

.piece-copy {
  max-width: 28rem;
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s var(--ease), transform 0.9s var(--ease);
}

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

.piece-copy h2 {
  font-size: clamp(2.5rem, 6vw, 4.25rem);
  margin-bottom: 0.35rem;
}

.piece-meta {
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--ink-dim);
  margin: 0 0 1.35rem;
}

.piece-line {
  font-family: var(--font-display);
  font-size: clamp(1.25rem, 2.4vw, 1.65rem);
  font-style: italic;
  line-height: 1.35;
  margin: 0 0 1.25rem;
  color: var(--ink);
}

.piece-spec {
  font-size: 0.8125rem;
  line-height: 1.55;
  color: var(--ink-mute);
  margin: 0 0 1.75rem;
  max-width: 34ch;
}

.piece-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.75rem;
  padding: 0 1.35rem;
  font-size: 0.6875rem;
  font-weight: 600;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
  transition: background 0.35s var(--ease), border-color 0.35s, color 0.35s, transform 0.35s;
}
.btn:hover { border-color: rgba(243,239,230,0.45); transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn-primary {
  background: var(--ink);
  color: var(--bg);
  border-color: var(--ink);
}
.btn-primary:hover {
  background: #fff;
  border-color: #fff;
}

.btn-ghost { background: rgba(255,255,255,0.03); }
.btn-lg { min-height: 3.25rem; padding: 0 1.75rem; font-size: 0.75rem; }

.buy-stub.is-stub::after {
  content: "";
}

/* ---------- About ---------- */
.about {
  text-align: center;
  justify-items: center;
}

.about-inner { max-width: 36rem; }

.about h2 {
  font-size: clamp(2.5rem, 7vw, 5rem);
  font-style: italic;
  margin-bottom: 1.5rem;
}

.about-body {
  font-size: clamp(1rem, 1.8vw, 1.2rem);
  line-height: 1.65;
  color: var(--ink-dim);
  margin: 0 0 2.5rem;
}

.review {
  margin: 0;
  padding: 1.75rem 0 0;
  border-top: 1px solid var(--line);
}
.review p {
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 2.2vw, 1.55rem);
  font-style: italic;
  line-height: 1.4;
  margin: 0;
  color: var(--ink);
}

/* ---------- Inquire ---------- */
.inquire {
  text-align: center;
  justify-items: center;
}

.inquire-inner { max-width: 34rem; }

.inquire h2 {
  font-size: clamp(2.75rem, 8vw, 5.5rem);
  font-style: italic;
  margin-bottom: 1rem;
}

.inquire-lede {
  color: var(--ink-dim);
  font-size: 1.05rem;
  margin: 0 0 2rem;
}

.inquire-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  justify-content: center;
  margin-bottom: 1.75rem;
}

.inquire-note {
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  color: var(--ink-mute);
  max-width: 42ch;
  margin: 0 auto;
  line-height: 1.5;
}

/* ---------- Footer ---------- */
.site-footer {
  position: relative;
  z-index: 10;
  padding: 2.5rem clamp(1.25rem, 4vw, 3rem) 3rem;
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.5rem;
  justify-content: space-between;
  align-items: baseline;
  font-size: 0.75rem;
  letter-spacing: 0.06em;
  color: var(--ink-mute);
}
.footer-inner strong {
  color: var(--ink-dim);
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 0.6875rem;
}

/* ---------- Reduced motion: show copy immediately ---------- */
@media (prefers-reduced-motion: reduce) {
  .piece-copy {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .heart-rig { transform: none !important; }
}

/* ---------- Mobile polish ---------- */
@media (max-width: 899px) {
  .piece {
    padding-top: calc(var(--nav-h) + 0.5rem);
    padding-bottom: 2.5rem;
    align-content: start;
  }
  .piece-stage { min-height: 42vh; }
  .heart-rig { width: min(78vw, 300px); }
  .piece-copy { text-align: center; margin-inline: auto; }
  .piece-actions { justify-content: center; }
  .piece-spec { margin-inline: auto; }
  .hero-copy { margin-top: min(42vh, 360px); }
}

@media (max-width: 480px) {
  .hero h1 { font-size: 2.6rem; }
  .hero-heart { width: min(70vw, 280px); }
}

/* Idle shimmer when piece is in view (GSAP toggles .is-active) */
@media (prefers-reduced-motion: no-preference) {
  .heart-rig.is-active .heart-img {
    animation: heart-shimmer 5.5s ease-in-out infinite;
  }
}
@keyframes heart-shimmer {
  0%, 100% { filter: drop-shadow(0 24px 48px rgba(0,0,0,0.55)) brightness(1); }
  50% { filter: drop-shadow(0 28px 56px rgba(160,190,255,0.25)) brightness(1.06); }
}

.buy-toast {
  width: 100%;
}
