:root{
  --bg: #070a12;
  --ink: rgba(255,255,255,.88);
  --muted: rgba(255,255,255,.64);

  --glass: rgba(255,255,255,.06);
  --stroke: rgba(255,255,255,.14);

  --mint: #5bffd6;
  --rose: #ff4fd8;
  --violet: #8a5bff;
  --gold: #ffd37a;

  --shadow: 0 20px 60px rgba(0,0,0,.55);
  --radius: 22px;
}

*{ box-sizing:border-box; }
html{ scroll-behavior:smooth; }
body{
  margin:0;
  color: var(--ink);
  background: var(--bg);
  font-family: "Space Grotesk", system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  overflow-x:hidden;
}
main{ position: relative; z-index: 5; }

a{ color:inherit; text-decoration:none; }
button{ font-family: inherit; }

.bg{
  position:fixed;
  inset:0;
  z-index:-2;
  overflow:hidden;
}
.aurora{
  position:absolute;
  width: 70vmax;
  height: 70vmax;
  filter: blur(40px);
  opacity:.55;
  border-radius: 50%;
  transform: translate3d(0,0,0);
  animation: drift 18s ease-in-out infinite;
}
.a1{ left:-15vmax; top:-18vmax; background: radial-gradient(circle at 30% 30%, var(--violet), transparent 60%); }
.a2{ right:-18vmax; top:-10vmax; background: radial-gradient(circle at 60% 40%, var(--rose), transparent 62%); animation-duration: 22s; }
.a3{ left:10vmax; bottom:-22vmax; background: radial-gradient(circle at 50% 50%, var(--mint), transparent 62%); animation-duration: 26s; }

@keyframes drift{
  0%,100%{ transform: translate(0,0) scale(1); }
  50%{ transform: translate(3vmax, -2vmax) scale(1.05); }
}

.grain{
  position:absolute;
  inset:-50%;
  background-image:url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.8' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='160' height='160' filter='url(%23n)' opacity='.25'/%3E%3C/svg%3E");
  opacity:.13;
  transform: rotate(8deg);
  z-index:-1;
  pointer-events:none;
}

/* Header */
.header{
  position:sticky;
  top:0;
  z-index:1000;
  display:flex;
  align-items:center;
  justify-content:space-between;
  padding: 16px 20px;
  backdrop-filter: blur(14px);
  background: linear-gradient(to bottom, rgba(7,10,18,.75), rgba(7,10,18,.25));
  border-bottom: 1px solid rgba(255,255,255,.06);
}
.brand{
  display:flex;
  align-items:baseline;
  gap:10px;
  white-space:nowrap;
}
.brand__dot{
  width:10px; height:10px;
  border-radius:999px;
  background: radial-gradient(circle at 40% 40%, var(--mint), var(--violet));
  box-shadow: 0 0 25px rgba(91,255,214,.35);
}
.brand__text{
  font-weight:700;
  letter-spacing:.2px;
}
.brand__tag{
  color: var(--muted);
  font-size: .9rem;
}

.nav{
  display:flex;
  gap:18px;
  align-items:center;
}
.nav a{
  color: var(--muted);
  padding:10px 10px;
  border-radius: 12px;
  transition: transform .2s ease, background .2s ease, color .2s ease;
}
.nav .pill{ margin-left: 10px; cursor: pointer; }
.nav a:hover{
  color: var(--ink);
  background: rgba(255,255,255,.06);
  transform: translateY(-1px);
}
.nav__cta{
  color: var(--ink) !important;
  background: linear-gradient(135deg, rgba(255,79,216,.22), rgba(91,255,214,.16));
  border: 1px solid rgba(255,255,255,.14);
}
.musicMenu{
  position:relative;
  display:flex;
  align-items:center;
  gap:8px;
  z-index: 3000; /* keep on top within header */
  padding-bottom: 14px; /* extend hover hit-area so dropdown doesn't vanish between pill and list */
}
.musicPill, .soundPill{
  border: 1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.05);
  color: var(--ink);
  border-radius: 999px;
  padding: 8px 12px;
  font-size: .9rem;
  display:flex;
  align-items:center;
  gap:8px;
  cursor:pointer;
  transition: transform .18s ease, background .18s ease, border .18s ease;
}
.musicPill:hover, .soundPill:hover{ background: rgba(255,255,255,.08); transform: translateY(-1px); }
.musicDot{
  width:10px; height:10px;
  border-radius:999px;
  background: radial-gradient(circle at 40% 40%, var(--mint), var(--violet));
  box-shadow: 0 0 15px rgba(91,255,214,.4);
}
.musicLabel{ font-weight:600; }
.musicNow{ color: var(--muted); font-size:.85rem; }
.musicControls{ display:flex; align-items:center; gap:8px; margin-left:0; flex-wrap:wrap; }
.ctrlBtn{ border:1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.06); color: var(--ink); border-radius:10px; padding:6px 10px; cursor:pointer; transition: background .18s ease, transform .18s ease; }
.ctrlBtn:hover{ background: rgba(255,255,255,.1); transform: translateY(-1px); }
.progressWrap{ display:flex; align-items:center; gap:8px; min-width:240px; flex:1; }
#musicSeek{ width:160px; accent-color: var(--mint); }
#musicTime{ color: var(--muted); font-size:.85rem; }
.musicDropdown{
  position:absolute;
  top: calc(100% - 2px); /* reduce gap so hover path is continuous */
  right: 0;
  left: auto;
  min-width: clamp(280px, 50vw, 420px);
  max-height: 80vh;
  overflow-y: auto;
  overflow-x: hidden;
  /* Hide scrollbars cross-browser while allowing scroll */
  -ms-overflow-style: none; /* IE/Edge */
  scrollbar-width: none; /* Firefox */
  background: rgba(10,14,24,.9);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 14px;
  box-shadow: 0 18px 60px rgba(0,0,0,.55);
  backdrop-filter: blur(12px);
  padding: 12px;
  display:grid;
  gap:10px;
  opacity:0;
  transform: translateY(-10px);
  pointer-events:none;
  transition: opacity .2s ease, transform .2s ease;
  z-index: 4000; /* above header and content */
}
.musicDropdown::-webkit-scrollbar{ display:none; }
.musicDropdown::before{
  content: '';
  position: absolute;
  top: -24px;
  left: -12px;
  right: -12px;
  height: 28px;
  background: transparent;
}
.musicMenu:hover .musicDropdown,
.musicMenu.open .musicDropdown{
  opacity:1;
  transform: translateY(0);
  pointer-events:auto;
}
.musicPanel{ display:grid; gap:10px; align-items:flex-start; }
.musicList{ display:grid; gap:6px; }
.musicTrack{
  width:100%;
  text-align:left;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  color: var(--ink);
  border-radius: 10px;
  padding: 10px 12px;
  cursor:pointer;
  transition: background .18s ease, border .18s ease, transform .18s ease;
}
.musicTrack:hover{ background: rgba(255,255,255,.08); transform: translateY(-1px); }
.musicTrack.is-active{
  border-color: rgba(91,255,214,.4);
  box-shadow: 0 0 18px rgba(91,255,214,.25);
}
.musicHint{
  color: var(--muted);
  font-size: .9rem;
  min-height: 18px;
  margin: 4px 2px 6px;
}

.navToggle{
  display:none;
  width:44px; height:44px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  backdrop-filter: blur(10px);
  box-shadow: 0 10px 40px rgba(0,0,0,.35);
}
.navToggle span{
  display:block;
  height:2px;
  margin:7px 10px;
  background: rgba(255,255,255,.75);
}

/* Sections */
.section{ padding: 64px 20px; }
#romantic-garden.section { padding: 20px 20px 0; }
.container{ max-width: 1100px; margin: 0 auto; }

.sectionHead{
  margin-bottom: 22px;
}
.sectionHead h2{
  font-family: "Playfair Display", serif;
  letter-spacing: .2px;
  font-size: clamp(28px, 4vw, 42px);
  margin: 0 0 8px;
}
.sectionHead p{
  margin:0;
  color: var(--muted);
  max-width: 70ch;
}

/* Hero */
.hero{
  padding-top: 46px;
  min-height: calc(100vh - 76px);
  display:grid;
  grid-template-columns: 1.2fr .9fr;
  align-items:center;
  gap: 26px;
  max-width: 1100px;
  margin: 0 auto;
}
.kicker{
  display:inline-block;
  color: rgba(255,255,255,.7);
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.04);
  padding: 8px 12px;
  border-radius: 999px;
  margin: 0 0 14px;
}
.title{
  margin: 0 0 12px;
  font-size: clamp(34px, 5vw, 60px);
  line-height: 1.03;
}
.title__accent{
  background: linear-gradient(90deg, var(--mint), var(--rose), var(--violet));
  -webkit-background-clip:text;
  background-clip:text;
  color: transparent;
}
.subtitle{
  margin:0 0 18px;
  color: var(--muted);
  max-width: 60ch;
  font-size: 1.05rem;
  line-height: 1.6;
}

.hero__actions{
  display:flex;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 18px;
}

.hero__stats{
  display:flex;
  gap: 14px;
  flex-wrap:wrap;
  margin-top: 10px;
}
.stat{
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.10);
  padding: 12px 14px;
  border-radius: 18px;
  min-width: 150px;
}
.stat__num{
  display:block;
  font-weight: 700;
  font-size: 1.3rem;
}
.stat__label{
  color: var(--muted);
  font-size: .92rem;
}

.scrollHint{
  position:absolute;
  left: 50%;
  transform: translateX(-50%);
  bottom: 22px;
  color: rgba(255,255,255,.6);
  display:flex;
  align-items:center;
  gap:10px;
  font-size:.92rem;
}
.scrollHint__line{
  width: 54px;
  height: 1px;
  background: rgba(255,255,255,.28);
}

/* Cards / UI */
.glassCard{
  background: linear-gradient(180deg, rgba(255,255,255,.08), rgba(255,255,255,.04));
  border: 1px solid rgba(255,255,255,.12);
  border-radius: var(--radius);
  padding: 18px 18px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}
.glassCard__top{
  display:flex;
  gap:10px;
  justify-content:flex-start;
  margin-bottom: 10px;
}
.pill{
  font-size:.78rem;
  letter-spacing:.12em;
  padding: 7px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,.12);
  background: rgba(255,255,255,.05);
  color: rgba(255,255,255,.72);
}
.pill--rose{
  background: rgba(255,79,216,.12);
  border-color: rgba(255,79,216,.22);
  color: rgba(255,255,255,.78);
}
.glassCard__title{
  margin: 8px 0 8px;
  font-size: 1.25rem;
}
.glassCard__text{
  margin:0;
  color: var(--muted);
  line-height: 1.65;
}
.divider{
  height:1px;
  background: rgba(255,255,255,.10);
  margin: 14px 0;
}
.glassCard__mini{ display:grid; gap: 10px; }
.miniRow{
  display:flex; align-items:center; gap:10px;
  color: rgba(255,255,255,.76);
}
.dot{
  width:10px; height:10px; border-radius:999px;
  box-shadow: 0 0 18px rgba(255,255,255,.12);
}
.dot--mint{ background: var(--mint); }
.dot--rose{ background: var(--rose); }
.dot--violet{ background: var(--violet); }

/* Buttons */
.btn{
  cursor:pointer;
  border-radius: 16px;
  padding: 12px 16px;
  border: 1px solid rgba(255,255,255,.14);

.player-wrap {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  z-index: 1000;
}

#yt-player { width: 0; height: 0; overflow: hidden; }

.enable-sound {
  display: none;
  padding: 0.6rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(255,255,255,0.25);
  background: rgba(7, 11, 20, 0.6);
  backdrop-filter: blur(8px);
  color: #fff;
  font-weight: 600;
  letter-spacing: 0.02em;
  cursor: pointer;
}

.enable-sound.enabled {
  opacity: 0.7;
  cursor: default;
}
  background: rgba(255,255,255,.05);
  color: var(--ink);
  transition: transform .18s ease, background .18s ease, border .18s ease;
}
.btn:hover{ transform: translateY(-1px); background: rgba(255,255,255,.08); }
.btn--primary{
  border: 1px solid rgba(255,255,255,.18);
  background: linear-gradient(135deg, rgba(91,255,214,.18), rgba(255,79,216,.16), rgba(138,91,255,.16));
}
.btn--ghost{
  background: rgba(255,255,255,.03);
}

/* Layout helpers */
.grid2{
  display:grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.grid3{
  display:grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 16px;
}

@media (max-width: 1100px){
  .grid3{
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px){
  .grid3{
    grid-template-columns: 1fr;
  }
}

/* Timeline */
.timeline{
  display:grid;
  gap: 14px;
}
.tItem{
  display:grid;
  grid-template-columns: 20px 1fr;
  gap: 14px;
  align-items:flex-start;
}
.tDot{
  width:14px; height:14px;
  border-radius: 999px;
  margin-top: 16px;
  background: radial-gradient(circle at 40% 40%, var(--gold), var(--rose));
  box-shadow: 0 0 22px rgba(255,211,122,.22);
}
.tCard{
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 18px;
  padding: 14px 14px;
}
.tCard h3{ margin: 0 0 6px; }
.tCard p{ margin: 0 0 8px; color: var(--muted); line-height: 1.6; }
.tMeta{ color: rgba(255,255,255,.55); font-size: .9rem; }

/* Letter */
.letter{
  max-width: 820px;
}
.letter__title{
  font-family: "Playfair Display", serif;
  font-size: 1.6rem;
  margin: 0 0 10px;
}
.letter p{ color: rgba(255,255,255,.78); line-height: 1.8; }
.letter__sign{ color: rgba(255,255,255,.68); margin-top: 14px; }
.letter__actions{ display:flex; gap:12px; flex-wrap:wrap; margin-top: 14px; }
.tiny{ margin-top: 10px; color: rgba(255,255,255,.55); min-height: 1.2em; }

/* Gallery */
.gallery{
  display:grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.gCard{
  background: rgba(255,255,255,.05);
  border: 1px solid rgba(255,255,255,.10);
  border-radius: 18px;
  overflow:hidden;
  box-shadow: 0 16px 50px rgba(0,0,0,.4);
}
.gImg{
  height: 600px;
  background-size: cover;
  background-position: center;
  display:block;
  overflow:hidden;
}

/* Ensure inserted <img> shows the full photo (no cropping). */
.gImg img{
  width:100%;
  height:100%;
  display:block;
  object-fit: contain; /* show full image with letterboxing if needed */
  object-position: center;
  background-color: rgba(0,0,0,.04);
}
.g1{ background-image: radial-gradient(circle at 30% 30%, rgba(255,79,216,.45), transparent 55%), radial-gradient(circle at 70% 60%, rgba(91,255,214,.35), transparent 55%), linear-gradient(135deg, rgba(138,91,255,.25), rgba(0,0,0,.3)); }
.g2{ background-image: radial-gradient(circle at 40% 40%, rgba(91,255,214,.42), transparent 55%), radial-gradient(circle at 70% 30%, rgba(255,211,122,.26), transparent 55%), linear-gradient(135deg, rgba(255,79,216,.18), rgba(0,0,0,.35)); }
.g3{ background-image: radial-gradient(circle at 35% 40%, rgba(255,79,216,.40), transparent 58%), radial-gradient(circle at 70% 60%, rgba(138,91,255,.30), transparent 55%), linear-gradient(135deg, rgba(91,255,214,.12), rgba(0,0,0,.38)); }

.gText{ padding: 12px 12px; }
.gText h3{ margin:0 0 6px; }
.gText p{ margin:0; color: var(--muted); line-height:1.6; }

/* Finale */
.finale{
  padding-bottom: 90px;
}
.finale__wrap{
  text-align:center;
  padding: 26px 18px;
}
.finale__wrap h2{
  margin: 0 0 10px;
  font-family: "Playfair Display", serif;
  font-size: clamp(30px, 4.5vw, 50px);
}
.finale__wrap p{
  margin: 0 auto 14px;
  max-width: 70ch;
  color: var(--muted);
  line-height:1.7;
}

/* Footer */
.footer{
  padding: 15px 20px;
  text-align:center;
  color: rgba(255,255,255,.55);
  border-top: none;
  background: rgba(0,0,0,.6);
}
.sep{ margin: 0 10px; opacity:.5; }

/* Reveal animations */
.reveal{
  opacity:0;
  transform: translateY(12px);
  transition: opacity .7s ease, transform .7s ease;
}
.reveal.is-visible{
  opacity:1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce){
  html{ scroll-behavior:auto; }
  .aurora{ animation:none; }
  .reveal{ transition:none; }
}

/* Floating hearts */
.hearts{
  position:fixed;
  inset:0;
  pointer-events:none;
  z-index:10;
}
.heart{
  position:absolute;
  font-size: 14px;
  opacity: .0;
  transform: translateY(0) scale(1);
  animation: floatUp 2.4s ease forwards;
  filter: drop-shadow(0 10px 30px rgba(255,79,216,.18));
}
.heart.rose{ color: var(--rose); }
.heart.violet{ color: var(--violet); filter: drop-shadow(0 10px 30px rgba(138,91,255,.22)); }
.heart.mint{ color: var(--mint); filter: drop-shadow(0 10px 30px rgba(91,255,214,.22)); }
@keyframes floatUp{
  0%{ opacity:0; transform: translateY(12px) scale(.9); }
  10%{ opacity:.75; }
  100%{ opacity:0; transform: translateY(-160px) scale(1.12); }
}

/* Responsive */
@media (max-width: 920px){
  .hero{
    grid-template-columns: 1fr;
    min-height: auto;
  }
}

@media (max-width: 820px){
  .grid2{ grid-template-columns: 1fr; }
  .gallery{ grid-template-columns: 1fr; }

  .navToggle{ display:inline-block; }
  .nav{
    position: fixed;
    top: 74px;
    right: 14px;
    left: 14px;
    display:none;
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    border-radius: 18px;
    border: 1px solid rgba(255,255,255,.12);
    background: rgba(10,14,24,.75);
    backdrop-filter: blur(14px);
  }
  .nav.is-open{ display:flex; }
  .nav a{ background: rgba(255,255,255,.04); }
}
/* Keep content above the garden */
main{ padding-bottom: 0; }

/* Cinematic romantic garden (pixel-drawn) */
.garden{
  position: relative;
  left: 0; right: 0;
  width: 100vw;
  margin-left: calc(-50vw + 50%);
  height: min(35vh, 320px);
  padding-bottom: 0;
  pointer-events: none;
  z-index: 4;
  overflow: visible;
  background:
    linear-gradient(180deg, rgba(7,10,18,0), rgba(7,10,18,.85)),
    radial-gradient(70% 80% at 50% 90%, rgba(91,255,214,.12), transparent 70%),
    radial-gradient(50% 60% at 20% 80%, rgba(255,79,216,.12), transparent 60%),
    radial-gradient(45% 55% at 80% 75%, rgba(138,91,255,.12), transparent 60%);
}
.garden::after{
  content:"";
  position:absolute;
  inset:0;
  background: linear-gradient(180deg, transparent, rgba(7,10,18,.6));
  pointer-events:none;
}
@media (max-width: 768px) {
  .garden {
    height: min(25vh, 200px);
  }
}
.pflower{
  position:absolute;
  bottom: var(--bottom, 0);
  left: var(--left, 50%);
  border:none;
  background:none;
  padding:0;
  cursor:pointer;
  transform: translateX(-50%) translateY(-14px) scale(var(--scale,1));
  transition: transform .5s ease, filter .5s ease;
  filter: drop-shadow(0 12px 30px rgba(0,0,0,.5));
  pointer-events:auto;
  z-index: var(--z-index, 100);
}
.pflower:focus-visible{
  outline:2px solid rgba(91,255,214,.6);
  outline-offset:4px;
}
.pflower.is-blooming{
  transform: translateX(-50%) translateY(-20px) scale(calc(var(--scale,1)*1.05));
  filter: drop-shadow(0 16px 40px rgba(0,0,0,.55)) saturate(1.08);
}
.pflower[data-grid-row="0"] {
  opacity: 0.75;
  filter: drop-shadow(0 8px 20px rgba(0,0,0,.35)) brightness(0.92);
}

.pflower[data-grid-row="1"] {
  opacity: 0.92;
  filter: drop-shadow(0 12px 30px rgba(0,0,0,.5));
}

.pflower[data-grid-row="2"] {
  opacity: 1;
  filter: drop-shadow(0 14px 40px rgba(0,0,0,.6)) brightness(1.05);
}
.pflower canvas{
  display:block;
  width: var(--w, 80px);
  height: var(--h, 120px);
  pointer-events:none;
}

.phraseLayer{
  position:fixed;
  inset:0;
  pointer-events:none;
  z-index:14;
  overflow:hidden;
}
.floatingPhrase{
  position:absolute;
  color: var(--ink);
  font-family: "Playfair Display", serif;
  font-size: clamp(16px, 2vw, 26px);
  max-width: 26ch;
  padding: 8px 12px;
  border-radius: 14px;
  background: rgba(0,0,0,.6);
  border: 1px solid rgba(255,255,255,.14);
  backdrop-filter: blur(8px);
  box-shadow: 0 14px 30px rgba(0,0,0,.45);
  animation: floatPhrase 2.4s ease forwards;
}
@keyframes floatPhrase{
  0%{ opacity:0; transform: translate(-50%, 16px) scale(.96); }
  18%{ opacity:1; }
  100%{ opacity:0; transform: translate(-50%, -90px) scale(1); }
}

.phraseStream{
  position:fixed;
  inset:0;
  display:grid;
  place-items:center;
  padding:20px;
  pointer-events:none;
  z-index:15;
  opacity:0;
  transition: opacity .3s ease;
}
.phraseStream.is-visible{ opacity:1; }
.phraseStream .text{
  max-width: 24ch;
  color: var(--ink);
  font-family: "Playfair Display", serif;
  font-size: clamp(20px, 3vw, 40px);
  line-height:1.6;
  background: rgba(0,0,0,.55);
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 18px;
  padding: 14px 18px;
  backdrop-filter: blur(12px);
  box-shadow: 0 20px 60px rgba(0,0,0,.5);
  transform: translateY(120px);
}

/* Interactive choices */
.choiceGame{ display:grid; gap:16px; }
.choiceGame__top{
  display:flex;
  flex-wrap:wrap;
  align-items:center;
  justify-content:space-between;
  gap:12px;
}
.choiceGame__controls{ display:flex; gap:12px; align-items:center; }
.choiceGame__status{ color: var(--muted); font-size:.95rem; }
.choiceGame__scenarios{ display:flex; gap:10px; flex-wrap:wrap; }
.scenarioBtn{
  border:1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.05);
  color: var(--ink);
  padding:10px 12px;
  border-radius: 12px;
  cursor:pointer;
  transition: background .18s ease, transform .18s ease, border .18s ease;
}
.scenarioBtn:hover{ background: rgba(255,255,255,.08); transform: translateY(-1px); }
.scenarioBtn.is-active{
  border-color: rgba(91,255,214,.45);
  background: linear-gradient(135deg, rgba(91,255,214,.12), rgba(255,79,216,.10));
  box-shadow: 0 8px 30px rgba(0,0,0,.35);
}
.choiceGame__progress{ display:flex; align-items:center; gap:12px; }
.choiceGame__progressTrack{
  flex:1;
  height: 8px;
  background: rgba(255,255,255,.06);
  border-radius: 999px;
  overflow:hidden;
}
.choiceGame__progressBar{
  height:100%;
  width:0%;
  background: linear-gradient(90deg, var(--mint), var(--rose));
  border-radius: 999px;
  transition: width .25s ease;
}
.choiceGame__progressText{ color: var(--muted); font-size:.95rem; }
.choiceGame__body{ display:grid; gap:14px; }
.choiceGame__prompt{ font-size: 1.15rem; font-weight:600; line-height:1.5; }
.choiceGame__options{ display:grid; gap:10px; }
.choiceOption{
  width:100%;
  text-align:left;
  border:1px solid rgba(255,255,255,.14);
  background: rgba(255,255,255,.05);
  color: var(--ink);
  border-radius: 12px;
  padding: 12px 14px;
  cursor:pointer;
  transition: background .18s ease, border .18s ease, transform .18s ease;
}
.choiceOption:hover:enabled{ background: rgba(255,255,255,.08); transform: translateY(-1px); }
.choiceOption:disabled{ opacity:.8; cursor:not-allowed; }
.choiceOption.is-selected{ border-color: rgba(91,255,214,.45); box-shadow: 0 6px 18px rgba(0,0,0,.28); }
.choiceOption.is-correct{ background: rgba(91,255,214,.12); }
.choiceOption.is-wrong{ background: rgba(255,79,216,.06); }
.choiceGame__feedback{ min-height: 22px; color: var(--muted); font-weight:600; }
.choiceGame__actions{ display:flex; gap:10px; }
.choiceGame__summary{ color: var(--muted); font-size: .98rem; min-height: 20px; }
.choiceGame__reward{
  border: 1px solid rgba(255,255,255,.16);
  background: rgba(255,255,255,.05);
  border-radius: 14px;
  padding: 12px 14px;
  box-shadow: 0 12px 36px rgba(0,0,0,.35);
}
.choiceGame__rewardBadge{
  display:inline-block;
  padding: 6px 10px;
  border-radius: 999px;
  background: linear-gradient(135deg, rgba(91,255,214,.2), rgba(255,79,216,.2));
  border: 1px solid rgba(255,255,255,.14);
  font-weight:700;
  margin-bottom: 6px;
}

/* Reward rose */
.rose {
  position: relative;
  width: 120px;
  height: 220px;
  margin: 40px auto 20px;
}

.stem {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 6px;
  height: 0;
  background: linear-gradient(#2f7d32, #1b5e20);
  border-radius: 3px;
  transform: translateX(-50%);
  transition: height 1.2s ease-out;
}

.leaf {
  position: absolute;
  width: 40px;
  height: 20px;
  background: linear-gradient(#388e3c, #2e7d32);
  border-radius: 50% 50% 50% 0;
  opacity: 0;
  transition: opacity 0.6s ease-out 0.8s, transform 0.6s ease-out 0.8s;
}

.leaf.left {
  left: calc(50% - 40px);
  bottom: 60px;
  transform: rotate(-30deg) scale(0);
}

.leaf.right {
  left: 50%;
  bottom: 90px;
  transform: rotate(30deg) scale(0);
}

.bloom {
  position: absolute;
  bottom: 140px;
  left: 50%;
  width: 60px;
  height: 60px;
  transform: translateX(-50%) scale(0);
  transition: transform 1s ease-out 1.4s;
}

.petal {
  position: absolute;
  width: 30px;
  height: 40px;
  background: radial-gradient(circle at 30% 30%, #ff6f91, #c2185b);
  border-radius: 50% 50% 50% 50%;
  transform-origin: bottom center;
}

.p1 { transform: rotate(0deg); }
.p2 { transform: rotate(45deg); }
.p3 { transform: rotate(90deg); }
.p4 { transform: rotate(135deg); }
.p5 { transform: rotate(180deg); }

.rose.grow .stem {
  height: 140px;
}

.rose.grow .leaf {
  opacity: 1;
  transform: scale(1) rotate(var(--angle));
}

.rose.grow .leaf.left {
  --angle: -30deg;
}

.rose.grow .leaf.right {
  --angle: 30deg;
}

.rose.grow .bloom {
  transform: translateX(-50%) scale(1);
}

/* ===== Cinematic reward scene ===== */
.rewardScene {
  position: relative;
  margin: 18px auto 0;
  padding: 22px 16px 18px;
  border-radius: 18px;
  max-width: 740px;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.rewardBackdrop {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 600ms ease;
  background:
    radial-gradient(1200px 700px at 50% 70%, rgba(255,105,180,0.14), transparent 60%),
    radial-gradient(900px 520px at 30% 20%, rgba(255,255,255,0.10), transparent 55%),
    radial-gradient(900px 520px at 70% 20%, rgba(255,255,255,0.08), transparent 55%),
    radial-gradient(1200px 900px at 50% 50%, rgba(0,0,0,0.45), rgba(0,0,0,0.70));
  backdrop-filter: blur(3px);
}

.rewardScene.isOn .rewardBackdrop { opacity: 1; }

.rewardInner {
  position: relative;
  width: min(420px, 92vw);
  height: min(520px, 95vh);
  display: grid;
  place-items: center;
}

.rewardGlow {
  position: absolute;
  inset: -20%;
  pointer-events: none;
  opacity: 0;
  transition: opacity 900ms ease 300ms;
  background:
    radial-gradient(closest-side at 50% 60%, rgba(255,105,180,0.22), transparent 65%),
    radial-gradient(closest-side at 50% 55%, rgba(255,255,255,0.10), transparent 70%);
  filter: blur(2px);
}
.rewardScene.isOn .rewardGlow { opacity: 1; }

/* Rose SVG scale-in */
.roseSvg {
  width: 100%;
  height: 100%;
  overflow: visible;
  transform: translateY(10px) scale(0.98);
  opacity: 0;
  transition: opacity 700ms ease 250ms, transform 1200ms cubic-bezier(.2,.9,.2,1) 250ms;
}
.rewardScene.isOn .roseSvg {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* Draw animation */
.stemPath {
  stroke-dasharray: 1200;
  stroke-dashoffset: 1200;
  animation: drawStem 1600ms ease-out 350ms forwards;
}
@keyframes drawStem { to { stroke-dashoffset: 0; } }

.leafGroup {
  opacity: 0;
  transform-origin: center;
  animation: leafIn 900ms cubic-bezier(.2,1,.2,1) 1150ms forwards;
}
@keyframes leafIn {
  0% { opacity: 0; transform: translateY(10px) scale(0.75); }
  100% { opacity: 1; transform: translateY(0) scale(1); }
}

.petal {
  opacity: 0;
  transform-origin: 50% 55%;
  filter: drop-shadow(0 10px 14px rgba(0,0,0,0.28));
}
.rewardScene.isOn .petal {
  animation: bloom 1400ms cubic-bezier(.16,1,.24,1) forwards;
}
@keyframes bloom {
  0% { opacity: 0; transform: translateY(18px) scale(0.65) rotate(var(--r)); }
  55% { opacity: 1; transform: translateY(0) scale(1.05) rotate(calc(var(--r) * 0.5)); }
  100% { opacity: 1; transform: translateY(0) scale(1) rotate(0deg); }
}

/* Stagger petals */
.petal[data-i="0"] { animation-delay: 1450ms; }
.petal[data-i="1"] { animation-delay: 1550ms; }
.petal[data-i="2"] { animation-delay: 1650ms; }
.petal[data-i="3"] { animation-delay: 1750ms; }
.petal[data-i="4"] { animation-delay: 1850ms; }
.petal[data-i="5"] { animation-delay: 1950ms; }
.petal[data-i="6"] { animation-delay: 2050ms; }
.petal[data-i="7"] { animation-delay: 2150ms; }
.petal[data-i="8"] { animation-delay: 2250ms; }

/* Phrase reveal after bloom */
.rewardText {
  margin-top: -22px;
  text-align: center;
  max-width: 520px;
  font-size: 20px;
  font-weight: 700;
  line-height: 1.55;
  letter-spacing: 0.3px;
  background: linear-gradient(120deg, rgba(255,255,255,0.96), rgba(255,225,240,0.92), rgba(255,142,198,0.9));
  -webkit-background-clip: text;
  background-clip: text;
  color: #ffe9f5;
  text-shadow: 0 6px 20px rgba(0,0,0,0.45);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 800ms ease, transform 800ms ease;
}
.rewardScene.showText .rewardText {
  opacity: 1;
  transform: translateY(0);
}

/* Sparkles + hearts */
.particles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

/* Diagnosis modal */
.spark {
  position: absolute;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.95), rgba(255,105,180,0.55), transparent 70%);
  opacity: 0;
  animation: twinkle 2200ms ease-in-out infinite;
}
@keyframes twinkle {
  0%, 100% { transform: scale(0.6); opacity: 0; }
  35% { opacity: 1; }
  50% { transform: scale(1.25); opacity: 0.9; }
}

.heart {
  position: absolute;
  width: 10px;
  height: 10px;
  opacity: 0;
  animation: floatUp 2800ms ease-in-out infinite;
  filter: drop-shadow(0 6px 10px rgba(0,0,0,0.25));
}
.heart::before, .heart::after {
  content: "";
  position: absolute;
  width: 10px; height: 10px;
  background: radial-gradient(circle at 30% 30%, rgba(255,255,255,0.35), rgba(255,105,180,0.95));
  border-radius: 50%;
  top: 0;
}
.heart::before { left: 4px; }
.heart::after { left: 0; }
.heart {
  transform: rotate(45deg);
}
.heart::before, .heart::after {
  transform: rotate(-45deg);
}
@keyframes floatUp {
  0% { transform: translateY(20px) rotate(45deg) scale(0.9); opacity: 0; }
  15% { opacity: 0.85; }
  100% { transform: translateY(-160px) rotate(45deg) scale(1.15); opacity: 0; }
}

/* Cheer burst after text */
.burst {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
}
.rewardScene.burstOn .burst {
  opacity: 1;
  animation: burstFade 900ms ease-out forwards;
}
@keyframes burstFade { to { opacity: 0; } }
.burst i {
  position: absolute;
  width: 3px;
  height: 16px;
  border-radius: 2px;
  background: linear-gradient(rgba(255,255,255,0.95), rgba(255,105,180,0.8));
  transform-origin: bottom center;
  animation: burstRay 900ms cubic-bezier(.2,1,.2,1) forwards;
}
@keyframes burstRay {
  0% { transform: translate(-50%, -50%) rotate(var(--a)) scaleY(0.2); opacity: 0; }
  45% { opacity: 1; }
  100% { transform: translate(-50%, -50%) rotate(var(--a)) scaleY(1.05); opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .stemPath, .leafGroup, .petal, .spark, .heart, .burst i { animation: none !important; }
  .rewardBackdrop { transition: none; }
  .roseSvg { transition: none; opacity: 1; transform: none; }
  .rewardText { transition: none; opacity: 1; transform: none; }
}

@media (max-width: 700px){
  .choiceGame__top{ align-items:flex-start; }
  .choiceGame__controls{ width:100%; justify-content:space-between; }
}

.center-flower{
  position:fixed;
  transform: translate(0,0) scale(1);
  transition: transform .7s cubic-bezier(.2,.9,.2,1), opacity .7s ease, filter .7s ease;
  pointer-events:none;
  z-index:16;
  filter: drop-shadow(0 18px 50px rgba(0,0,0,.55));
}
.center-flower.to-center{
  transform: translate(var(--dx,0), var(--dy,0)) scale(1.12);
  opacity:1;
  filter: drop-shadow(0 24px 70px rgba(0,0,0,.65)) saturate(1.1);
}

@media (prefers-reduced-motion: reduce){
  .pflower{ transition:none; transform: translateX(-50%) translateY(0) scale(var(--scale,1)); }
  .pflower.is-blooming{ transform: translateX(-50%) translateY(0) scale(var(--scale,1)); }
  .floatingPhrase{ animation: none; opacity:1; transform: translate(-50%, -30px); }
  .center-flower{ transition:none; transform: translate(0,0) scale(1); }
}

#ytPlayer{
  position:fixed;
  width:1px; height:1px;
  left:-9999px; top:-9999px;
}

.moment {
  position: fixed;
  inset: 0;
  margin: 0;
  padding: 0;
  border-radius: 0;
  max-width: none;
  overflow: hidden;
  display: grid;
  place-items: center;
  z-index: 9000;
  pointer-events: auto;
  background:
    radial-gradient(160% 160% at 50% 50%, rgba(0,0,0,0.55), rgba(0,0,0,0.82)),
    radial-gradient(120% 110% at 50% 50%, rgba(34,0,51,0.35), rgba(4,6,10,0.9));
  backdrop-filter: blur(7px);
  opacity: 0;
  transition: opacity 400ms ease;
}

.moment.isOn { opacity: 1; }
.moment.fadeOut { opacity: 0; pointer-events: none; }

.momentOverlay {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 1;
  opacity: 0;
  transition: opacity 650ms ease;
  background:
    radial-gradient(1200px 700px at 50% 55%, rgba(255,105,180,0.15), transparent 60%),
    radial-gradient(900px 520px at 30% 20%, rgba(255,255,255,0.10), transparent 55%),
    radial-gradient(900px 520px at 70% 20%, rgba(255,255,255,0.08), transparent 55%),
    radial-gradient(1200px 900px at 50% 50%, rgba(0,0,0,0.35), rgba(0,0,0,0.68));
  backdrop-filter: blur(3px);
}

.moment.isOn .momentOverlay { opacity: 1; }

.momentInner {
  position: relative;
  width: min(96vw, 1280px);
  height: min(96vh, 980px);
  display: grid;
  place-items: center;
  z-index: 2;
}

.momentCanvas {
  width: 100%;
  height: 100%;
  display: block;
  border-radius: 0;
  box-shadow: 0 26px 100px rgba(0,0,0,0.6);
  opacity: 0;
  transform: translateY(10px) scale(0.98);
  transition: opacity 700ms ease 150ms, transform 1200ms cubic-bezier(.2,.9,.2,1) 150ms;
}

.moment.isOn .momentCanvas {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.momentText {
  margin-top: -10px;
  text-align: center;
  max-width: 620px;
  font-size: 18px;
  line-height: 1.55;
  letter-spacing: 0.2px;
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 900ms ease, transform 900ms ease;
  z-index: 3;
}

.moment.showText .momentText {
  opacity: 1;
  transform: translateY(0);
}

@media (prefers-reduced-motion: reduce) {
  .momentOverlay, .momentCanvas, .momentText { transition: none !important; }
}

body.moment-active {
  overflow: hidden;
}

body.moment-active main,
body.moment-active header,
body.moment-active footer,
body.moment-active .bg,
body.moment-active .hearts,
body.moment-active .phraseLayer,
body.moment-active .phraseStream {
  filter: blur(7px) brightness(0.6);
  transform: scale(0.985);
  transition: filter 320ms ease, transform 320ms ease;
}

/* === Fullscreen 3D moment overlay === */
.momentLayer {
  position: fixed;
  inset: 0;
  z-index: 12000;
  display: grid;
  place-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 300ms ease;
}
.momentLayer.on {
  opacity: 1;
  pointer-events: auto;
}

.momentDim {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(120% 110% at 50% 40%, rgba(255,105,180,0.18), rgba(10,6,20,0.82)),
    radial-gradient(90% 80% at 20% 60%, rgba(91,255,214,0.08), transparent 65%),
    radial-gradient(90% 80% at 80% 70%, rgba(138,91,255,0.08), transparent 65%),
    linear-gradient(180deg, rgba(0,0,0,0.45), rgba(0,0,0,0.75));
  backdrop-filter: blur(8px) saturate(1.1);
}

.momentCenter {
  position: relative;
  width: min(96vw, 1280px);
  height: min(96vh, 980px);
  display: grid;
  place-items: center;
  perspective: 1400px;
}

.momentGlow {
  position: absolute;
  inset: 10%;
  background:
    radial-gradient(closest-side at 50% 55%, rgba(255,105,180,0.28), transparent 70%),
    radial-gradient(closest-side at 50% 45%, rgba(255,255,255,0.16), transparent 70%);
  filter: blur(20px);
  opacity: 0;
  transition: opacity 900ms ease;
}
.momentLayer.on .momentGlow { opacity: 1; }

.rose3d {
  position: relative;
  width: min(52vw, 620px);
  height: min(60vh, 720px);
  transform-style: preserve-3d;
  transform: rotateX(18deg) rotateY(-12deg);
  filter: drop-shadow(0 24px 80px rgba(0,0,0,0.55));
}

.roseStage {
  position: absolute;
  inset: 0;
  transform-style: preserve-3d;
  animation: stageTilt 14s ease-in-out infinite alternate;
}

@keyframes stageTilt {
  0% { transform: rotateX(-4deg) rotateY(-4deg); }
  50% { transform: rotateX(6deg) rotateY(8deg); }
  100% { transform: rotateX(-6deg) rotateY(-2deg); }
}

/* SVG Rose Container for Variant Roses */
.momentRoseContainer {
  position: relative;
  width: 380px;
  height: 480px;
  display: grid;
  place-items: center;
  transform-style: preserve-3d;
  filter: drop-shadow(0 24px 80px rgba(0,0,0,0.55));
  overflow: visible;
}

.momentRose {
  max-width: 380px;
  max-height: 480px;
  width: 380px !important;
  height: 480px !important;
  object-fit: contain;
  opacity: 0;
  transform: scale(0.5) translateY(20px);
  animation: roseBloom 2200ms cubic-bezier(0.23, 1, 0.32, 1) forwards;
}

.momentRose svg {
  width: 100%;
  height: 100%;
}

.momentRose .roseSvg {
  width: 100%;
  height: 100%;
}

@keyframes roseBloom {
  0% {
    opacity: 0;
    transform: scale(0.5) translateY(20px);
  }
  50% {
    opacity: 1;
    transform: scale(1.02) translateY(0);
  }
  100% {
    opacity: 1;
    transform: scale(1) translateY(0);
  }
}

/* Animate petals blooming */
.momentRose .petal {
  opacity: 0;
  animation: petalUnfold 1800ms ease-out forwards;
}

.momentRose .petal[data-i="0"] { animation-delay: 100ms; }
.momentRose .petal[data-i="1"] { animation-delay: 200ms; }
.momentRose .petal[data-i="2"] { animation-delay: 300ms; }
.momentRose .petal[data-i="3"] { animation-delay: 400ms; }
.momentRose .petal[data-i="4"] { animation-delay: 500ms; }
.momentRose .petal[data-i="5"] { animation-delay: 600ms; }
.momentRose .petal[data-i="6"] { animation-delay: 700ms; }
.momentRose .petal[data-i="7"] { animation-delay: 800ms; }
.momentRose .petal[data-i="8"] { animation-delay: 900ms; }

@keyframes petalUnfold {
  0% {
    opacity: 0;
    transform: scale(0.3) rotate(var(--r, 0deg));
  }
  60% {
    opacity: 1;
    transform: scale(1.05) rotate(var(--r, 0deg));
  }
  100% {
    opacity: 1;
    transform: scale(1) rotate(var(--r, 0deg));
  }
}

.stem3d {
  position: absolute;
  bottom: 0;
  left: 50%;
  width: 14px;
  height: 0;
  background: linear-gradient(180deg, #2f9b45, #1b5e20);
  border-radius: 999px;
  transform: translateX(-50%) translateZ(2px);
  box-shadow: 0 0 22px rgba(0,0,0,0.4);
  transform-origin: bottom;
  animation: stemGrow 1600ms ease-out forwards;
}

@keyframes stemGrow {
  0% { height: 0; }
  100% { height: 420px; }
}

.leaf3d {
  position: absolute;
  width: 120px;
  height: 70px;
  background: radial-gradient(40% 40% at 30% 30%, #57c66a, #1b5e20);
  border-radius: 120px 120px 60px 60px;
  opacity: 0;
  transform-style: preserve-3d;
  filter: drop-shadow(0 12px 24px rgba(0,0,0,0.45));
  transform-origin: bottom center;
  animation: leafIn 900ms cubic-bezier(.25,1,.25,1) forwards;
}

.leaf3d.left {
  bottom: 160px;
  left: calc(50% - 40px);
  transform: translateX(-100%) rotateY(38deg) rotateZ(-24deg) translateZ(-18px) scale(0.8);
  animation-delay: 1100ms;
}
.leaf3d.right {
  bottom: 210px;
  left: 50%;
  transform: translateX(40%) rotateY(-32deg) rotateZ(24deg) translateZ(12px) scale(0.85);
  animation-delay: 1250ms;
}

@keyframes leafIn {
  0% { opacity: 0; transform: translateZ(-40px) translateY(20px) scale(0.7) rotateZ(-12deg); }
  100% { opacity: 1; }
}

.bloom3d {
  position: absolute;
  width: 420px;
  height: 420px;
  left: 50%;
  bottom: 320px;
  transform: translateX(-50%) translateZ(20px) scale(0.85) translateY(12px);
  transform-style: preserve-3d;
  opacity: 0.6;
  transition: opacity 500ms ease 600ms, transform 900ms cubic-bezier(.2,.9,.2,1) 600ms;
  z-index: 1;
}
.bloom3d::after {
  content: "";
  position: absolute;
  inset: 26% 26% auto auto;
  width: 140px;
  height: 140px;
  border-radius: 50%;
  background: radial-gradient(circle at 40% 40%, rgba(255,255,255,0.35), rgba(255,90,140,0.18) 45%, rgba(90,0,20,0.65) 90%);
  filter: blur(2px);
  opacity: 0.55;
  transform: translate(-50%, -30%) scale(0.9);
  box-shadow:
    0 0 40px rgba(255, 90, 140, 0.35),
    inset 0 -12px 28px rgba(90, 0, 20, 0.45);
  z-index: 0;
  pointer-events: none;
}
.momentLayer.on .bloom3d {
  opacity: 1;
  transform: translateX(-50%) translateZ(20px) scale(1) translateY(0);
}

.petal3d {
  position: absolute;
  width: 150px;
  height: 210px;
  top: 58px;
  left: 110px;
  background:
    radial-gradient(120% 110% at 60% 32%, rgba(255,235,240,0.28), transparent 45%),
    radial-gradient(80% 80% at 46% 64%, rgba(255,96,130,0.95), rgba(205,28,70,0.98) 55%, rgba(95,10,30,0.95) 88%),
    linear-gradient(155deg, rgba(255,210,220,0.35), transparent 55%, rgba(60,0,10,0.65) 90%);
  border-radius: 58% 70% 46% 62%;
  opacity: 0;
  transform-origin: bottom center;
  transform-style: preserve-3d;
  filter: drop-shadow(0 18px 34px rgba(0,0,0,0.46));
  box-shadow:
    inset 0 6px 16px rgba(255,255,255,0.12),
    inset 0 -12px 28px rgba(60,0,10,0.42);
  z-index: 2;
}

.petal3d:nth-child(odd) { filter: drop-shadow(0 20px 32px rgba(0,0,0,0.4)); }

.petal3d {
  --rot: calc(var(--i) * 20deg);
  --tilt: calc(8deg + var(--i) * 0.2deg);
  --depth: calc(16px + var(--i) * 1.1px);
  --lift: calc(var(--i) * -1px);
  --scale: calc(1 - var(--i) * 0.01);
  --yaw: 0deg;
  transform: rotateZ(var(--rot)) rotateX(var(--tilt)) rotateY(var(--yaw)) translateZ(var(--depth)) translateY(var(--lift)) scale(var(--scale,1));
  animation-fill-mode: forwards;
  opacity: 0;
}

.momentLayer.on .petal3d {
  animation: petalIn 1400ms cubic-bezier(.16,1,.24,1) forwards;
  animation-delay: calc(800ms + var(--i) * 70ms);
}

@keyframes petalIn {
  0% { opacity: 0; transform: rotateZ(var(--rot)) rotateX(46deg) rotateY(var(--yaw)) translateZ(0px) scale(0.25) translateY(18px); }
  55% { opacity: 1; transform: rotateZ(var(--rot)) rotateX(calc(var(--tilt) * 0.6)) rotateY(var(--yaw)) translateZ(calc(var(--depth) * 1.12)) translateY(calc(var(--lift) * 0.5)) scale(calc(var(--scale,1) * 1.05)); }
  100% { opacity: 1; transform: rotateZ(var(--rot)) rotateX(var(--tilt)) rotateY(var(--yaw)) translateZ(var(--depth)) translateY(var(--lift)) scale(var(--scale,1)); }
}

.momentText {
  position: absolute;
  bottom: 8%;
  width: min(80vw, 780px);
  text-align: center;
  font-size: 22px;
  font-weight: 700;
  line-height: 1.65;
  letter-spacing: 0.4px;
  background: linear-gradient(120deg, rgba(255,255,255,0.96), rgba(255,213,237,0.92), rgba(255,128,192,0.9));
  -webkit-background-clip: text;
  background-clip: text;
  color: #ffe9f5;
  text-shadow: 0 8px 24px rgba(0,0,0,0.55);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 800ms ease, transform 800ms ease;
  z-index: 3;
}
.momentLayer.showText .momentText {
  opacity: 1;
  transform: translateY(0);
}

.momentParticles {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 2;
}
.momentParticles span {
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255,255,255,0.9), rgba(255,105,180,0.6));
  opacity: 0;
  animation: floatParticle linear infinite;
  animation-duration: calc(2200ms + var(--d,0ms));
  animation-delay: var(--delay, 0ms);
  transform: translate(-50%, -50%) scale(0.8);
}

@keyframes floatParticle {
  0% { opacity: 0; transform: translate(var(--x,50%) , 105%) scale(0.6); }
  15% { opacity: 0.9; }
  100% { opacity: 0; transform: translate(calc(var(--x,50%)), -10%) scale(1.2); }
}

.momentBurst {
  position: absolute;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  z-index: 4;
}
.momentLayer.burst .momentBurst { opacity: 1; }
.momentBurst i {
  position: absolute;
  width: 3px;
  height: 28%;
  background: linear-gradient(rgba(255,255,255,0.95), rgba(255,105,180,0.0));
  left: 50%;
  top: 52%;
  transform-origin: top center;
  transform: translate(-50%, -50%) rotate(calc(var(--i) * 15deg)) scaleY(0);
  animation: burstRay 900ms cubic-bezier(.2,1,.2,1) forwards;
}
@keyframes burstRay {
  0% { opacity: 0; transform: translate(-50%, -50%) rotate(calc(var(--i) * 15deg)) scaleY(0.2); }
  40% { opacity: 1; }
  100% { opacity: 0; transform: translate(-50%, -50%) rotate(calc(var(--i) * 15deg)) scaleY(1.1); }
}
