/* ============================================================
   For My Mansi ♡ — dreamy purple LDR love site
   ============================================================ */

:root {
  --deep-purple: #160824;
  --midnight-violet: #24103a;
  --soft-purple: #5d2d76;
  --neon-pink: #ff8fd8;
  --blush-pink: #ffc2df;
  --fairy-light: #ffd28a;
  --soft-white: #fff4fb;

  --font-cursive: 'Great Vibes', cursive;
  --font-script: 'Dancing Script', cursive;
  --font-hand: 'Caveat', cursive;
  --font-body: 'Quicksand', sans-serif;

  --glow-pink: 0 0 18px rgba(255, 143, 216, .55), 0 0 46px rgba(255, 143, 216, .25);
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--soft-white);
  cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='22' height='22' viewBox='0 0 24 24'%3E%3Cpath fill='%23ff8fd8' stroke='%23fff4fb' stroke-width='1.2' d='M12 21s-7.5-4.9-10-9.3C.3 8.6 2 5 5.5 5c2 0 3.4 1.1 4.2 2.4L12 9l2.3-1.6C15.1 6.1 16.5 5 18.5 5 22 5 23.7 8.6 22 11.7 19.5 16.1 12 21 12 21z'/%3E%3C/svg%3E") 11 11, auto;
  background:
    radial-gradient(1200px 700px at 50% -100px, #3a1b5c 0%, transparent 60%),
    radial-gradient(900px 600px at 85% 40%, rgba(93, 45, 118, .35) 0%, transparent 65%),
    radial-gradient(900px 700px at 10% 75%, rgba(74, 28, 105, .30) 0%, transparent 60%),
    linear-gradient(180deg, #1c0b30 0%, var(--deep-purple) 35%, #120620 100%);
  background-attachment: fixed;
  overflow-x: hidden;
  min-height: 100vh;
}

::selection { background: var(--neon-pink); color: var(--deep-purple); }

.pink { color: var(--neon-pink); }

/* ---------- ambient layers ---------- */
#sky-canvas {
  position: fixed; inset: 0; width: 100%; height: 100%;
  pointer-events: none; z-index: 1;
}
.amb-cloud {
  position: fixed; z-index: 0; opacity: .35; pointer-events: none;
  filter: saturate(.9);
  -webkit-mask-image: radial-gradient(ellipse 60% 60% at 50% 50%, #000 38%, transparent 75%);
  mask-image: radial-gradient(ellipse 60% 60% at 50% 50%, #000 38%, transparent 75%);
}
.amb-cloud--left  { top: -6%; left: -14%; width: 52vw; animation: drift-l 60s ease-in-out infinite alternate; }
.amb-cloud--right { bottom: -10%; right: -16%; width: 56vw; transform: scaleX(-1); animation: drift-r 75s ease-in-out infinite alternate; }
@keyframes drift-l { from { transform: translateX(0); } to { transform: translateX(5vw); } }
@keyframes drift-r { from { transform: scaleX(-1) translateX(0); } to { transform: scaleX(-1) translateX(6vw); } }

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

/* scroll progress */
#scroll-progress {
  position: fixed; top: 0; left: 0; height: 3px; width: 0; z-index: 75;
  background: linear-gradient(90deg, var(--soft-purple), var(--neon-pink), var(--blush-pink));
  box-shadow: 0 0 12px rgba(255, 143, 216, .75);
  border-radius: 0 3px 3px 0;
}

/* aurora glow blobs */
.aurora {
  position: fixed; border-radius: 50%; pointer-events: none; z-index: 0;
  filter: blur(70px); opacity: .16; will-change: transform;
}
.aurora.a1 {
  width: 46vw; height: 46vw; left: -10vw; top: 18vh;
  background: radial-gradient(circle, var(--neon-pink) 0%, transparent 65%);
  animation: aurora-drift1 36s ease-in-out infinite alternate;
}
.aurora.a2 {
  width: 52vw; height: 52vw; right: -14vw; top: 55vh;
  background: radial-gradient(circle, #8a5cf6 0%, transparent 65%);
  animation: aurora-drift2 44s ease-in-out infinite alternate;
}
@keyframes aurora-drift1 { to { transform: translate(9vw, -12vh) scale(1.15); } }
@keyframes aurora-drift2 { to { transform: translate(-10vw, -16vh) scale(.9); } }

/* wish lanterns */
.lantern {
  position: fixed; bottom: -110px; z-index: 65; pointer-events: none;
  animation: lantern-rise var(--dur) linear forwards;
}
.lantern .lbody {
  width: var(--w); height: calc(var(--w) * 1.4); position: relative;
  background: linear-gradient(180deg, #ffe9c2 0%, #ffc685 38%, #ff9d54 78%, #ff8a3c 100%);
  border-radius: 42% 42% 46% 46% / 34% 34% 58% 58%;
  box-shadow: 0 0 24px 7px rgba(255, 190, 110, .42), inset 0 -10px 16px rgba(255, 110, 30, .55);
  animation: lantern-sway 3.6s ease-in-out infinite alternate;
  display: flex; align-items: center; justify-content: center;
}
.lantern .lbody::before {
  content: ""; position: absolute; top: -4px; left: 30%; right: 30%; height: 7px;
  background: #b96a2e; border-radius: 4px;
}
.lantern .lbody::after {
  content: ""; position: absolute; bottom: -3px; left: 36%; right: 36%; height: 7px;
  background: radial-gradient(ellipse at center, #fff0b8, #ffac4d);
  border-radius: 50%; filter: blur(1.5px);
}
.lantern .lbody span {
  font-family: var(--font-hand); font-size: calc(var(--w) * .3);
  color: #8a4413; font-weight: 600; transform: rotate(-4deg);
}
@keyframes lantern-rise {
  0% { transform: translateY(0) translateX(0); opacity: 0; }
  6% { opacity: 1; }
  82% { opacity: 1; }
  100% { transform: translateY(-118vh) translateX(var(--drift)); opacity: 0; }
}
@keyframes lantern-sway {
  from { rotate: -4.5deg; } to { rotate: 4.5deg; }
}

/* ============================================================
   loading screen
   ============================================================ */
#loader {
  position: fixed; inset: 0; z-index: 100;
  background: linear-gradient(180deg, #1c0b30, var(--deep-purple));
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 22px; transition: opacity 1s ease, visibility 1s;
}
#loader.done { opacity: 0; visibility: hidden; }
.loader-hearts iconify-icon {
  display: inline-block; font-size: 2rem; margin: 0 8px; color: var(--neon-pink);
  filter: drop-shadow(0 0 10px rgba(255,143,216,.7));
  animation: float-heart 1.6s ease-in-out infinite;
}
.loader-hearts iconify-icon:nth-child(2) { animation-delay: .25s; color: var(--blush-pink); }
.loader-hearts iconify-icon:nth-child(3) { animation-delay: .5s; }
@keyframes float-heart {
  0%, 100% { transform: translateY(0) scale(1); }
  50% { transform: translateY(-16px) scale(1.15); }
}
.loader-text {
  font-family: var(--font-script); font-size: 1.7rem; color: var(--blush-pink);
  text-shadow: var(--glow-pink);
}
.loader-bar {
  width: min(280px, 60vw); height: 6px; border-radius: 6px;
  background: rgba(255, 143, 216, .15); overflow: hidden;
}
.loader-bar i {
  display: block; height: 100%; width: 40%; border-radius: 6px;
  background: linear-gradient(90deg, var(--neon-pink), var(--blush-pink));
  box-shadow: var(--glow-pink);
  animation: load-slide 1.2s ease-in-out infinite;
}
@keyframes load-slide {
  0% { transform: translateX(-110%); }
  100% { transform: translateX(360%); }
}

/* ============================================================
   floating buttons + nav
   ============================================================ */
.float-btns {
  position: fixed; right: 18px; top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 12px; z-index: 50;
}
.float-btn {
  width: 46px; height: 46px; border-radius: 50%;
  border: 1px solid rgba(255, 143, 216, .5);
  background: rgba(36, 16, 58, .75); color: var(--blush-pink);
  font-size: 1.15rem; cursor: pointer; backdrop-filter: blur(8px);
  box-shadow: 0 0 14px rgba(255, 143, 216, .25);
  transition: transform .25s, box-shadow .25s;
}
.float-btn:hover { transform: scale(1.12); box-shadow: var(--glow-pink); }

#nav-overlay {
  position: fixed; inset: 0; z-index: 60;
  background: rgba(22, 8, 36, .92); backdrop-filter: blur(12px);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 6px; opacity: 0; visibility: hidden; transition: opacity .4s, visibility .4s;
}
#nav-overlay.open { opacity: 1; visibility: visible; }
#nav-overlay a {
  font-family: var(--font-script); font-size: clamp(1.3rem, 3.4vh, 1.8rem);
  color: var(--soft-white); text-decoration: none; padding: 4px 18px;
  border-radius: 12px; transition: color .25s, text-shadow .25s, transform .25s;
}
#nav-overlay a:hover { color: var(--neon-pink); text-shadow: var(--glow-pink); transform: scale(1.07); }
.nav-close {
  position: absolute; top: 22px; right: 26px; font-size: 1.4rem;
  background: none; border: none; color: var(--blush-pink); cursor: pointer;
}

/* ============================================================
   shared
   ============================================================ */
.section { position: relative; padding: clamp(60px, 9vw, 110px) clamp(18px, 5vw, 56px); max-width: 1180px; margin: 0 auto; }

.glass {
  background: linear-gradient(160deg, rgba(60, 26, 92, .55), rgba(36, 16, 58, .65));
  backdrop-filter: blur(14px); -webkit-backdrop-filter: blur(14px);
  border: 1px solid rgba(255, 143, 216, .32);
  border-radius: 22px;
  box-shadow: 0 0 0 1px rgba(255, 143, 216, .06), 0 0 26px rgba(255, 143, 216, .14), 0 18px 50px rgba(0, 0, 0, .35);
}

.cursive-h {
  font-family: var(--font-cursive); font-weight: 400;
  font-size: clamp(2.2rem, 5.2vw, 3.1rem); color: var(--blush-pink);
  text-shadow: var(--glow-pink);
}
.cursive-h.center { text-align: center; }
.cursive-h.big-h { font-size: clamp(2.6rem, 6.2vw, 3.8rem); }

/* streamline icons */
iconify-icon { display: inline-block; vertical-align: middle; }
.float-btn iconify-icon { font-size: 1.25rem; }
.hero-heart iconify-icon { font-size: 1.7rem; color: var(--neon-pink); filter: drop-shadow(0 0 10px rgba(255,143,216,.8)); }
.t-icon iconify-icon, .dream-card span iconify-icon { font-size: 2rem; color: var(--blush-pink); }
.env-body iconify-icon { font-size: 2.1rem; color: var(--neon-pink); }
.vis-icon iconify-icon { font-size: 2.7rem; color: var(--blush-pink); }
.p-title iconify-icon { font-size: 1.35rem; color: var(--neon-pink); vertical-align: -4px; }
.lock-heart iconify-icon { font-size: 3.2rem; color: var(--neon-pink); }
.p-controls button iconify-icon { font-size: 1.1rem; }
.p-controls .pc-main iconify-icon { font-size: 1.45rem; }
.match-face iconify-icon { font-size: 1.65rem; }

.sec-title {
  text-align: center; font-weight: 600; letter-spacing: .22em;
  color: var(--blush-pink); font-size: clamp(.85rem, 2vw, 1.05rem);
  margin-bottom: 42px; text-shadow: 0 0 12px rgba(255, 143, 216, .4);
}
.sec-sub {
  text-align: center; color: rgba(255, 244, 251, .65);
  font-family: var(--font-hand); font-size: 1.25rem; margin: 10px 0 38px;
}

.btn-pink {
  font-family: var(--font-body); font-weight: 600; font-size: .95rem;
  color: var(--deep-purple);
  background: linear-gradient(135deg, var(--neon-pink), var(--blush-pink));
  border: none; border-radius: 999px; padding: 12px 26px; cursor: pointer;
  box-shadow: 0 0 16px rgba(255, 143, 216, .45);
  transition: transform .25s, box-shadow .25s;
}
.btn-pink:hover { transform: translateY(-2px) scale(1.04); box-shadow: var(--glow-pink); }
.btn-pink.big { font-size: 1.05rem; padding: 15px 30px; }

.btn-ghost {
  font-family: var(--font-body); font-weight: 600; font-size: .9rem;
  color: var(--blush-pink); background: none; cursor: pointer;
  border: 1px solid rgba(255, 143, 216, .45); border-radius: 999px; padding: 11px 22px;
  transition: background .25s, box-shadow .25s;
}
.btn-ghost:hover { background: rgba(255, 143, 216, .12); box-shadow: var(--glow-pink); }

/* scroll reveal */
.reveal { opacity: 0; transform: translateY(46px); transition: opacity .9s ease, transform .9s ease; }
.reveal.visible { opacity: 1; transform: none; }

.pulse { animation: pulse 2.2s ease-in-out infinite; }
@keyframes pulse {
  0%, 100% { transform: scale(1); filter: drop-shadow(0 0 8px rgba(255, 143, 216, .6)); }
  50% { transform: scale(1.16); filter: drop-shadow(0 0 22px rgba(255, 143, 216, .95)); }
}

/* ============================================================
   hero
   ============================================================ */
.hero {
  position: relative; min-height: 100vh; overflow: hidden;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; padding: 60px 16px 90px; z-index: 2;
}
.hero-bg {
  position: absolute; inset: -30px; z-index: -1; pointer-events: none;
  background: url(../assets/images/hero-bg.webp) center 32% / cover no-repeat;
  transform: scale(1.05);
  -webkit-mask-image: linear-gradient(180deg, #000 70%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 70%, transparent 100%);
  will-change: transform;
}
.hero-bg::before {
  content: ""; position: absolute; inset: 0;
  background:
    radial-gradient(125% 95% at 50% 38%, transparent 52%, rgba(22, 8, 36, .55) 100%),
    linear-gradient(180deg, rgba(22, 8, 36, .5) 0%, rgba(22, 8, 36, .06) 24%, transparent 52%,
      rgba(24, 9, 40, .42) 84%, rgba(22, 8, 36, .92) 100%);
}
.hero-inner { position: relative; }
.time-greet {
  font-family: var(--font-hand); font-size: clamp(1.05rem, 2.6vw, 1.35rem);
  color: var(--blush-pink); opacity: .9; margin-bottom: 4px; letter-spacing: .04em;
  text-shadow: 0 0 12px rgba(22, 8, 36, .8);
}

.doodle-hearts .doodle {
  position: absolute; color: var(--neon-pink); opacity: .7;
  font-size: 1.3rem; animation: doodle-float 5s ease-in-out infinite;
  text-shadow: 0 0 10px rgba(255, 143, 216, .8);
}
.doodle.d1 { top: -68px; left: 4%; transform: rotate(-18deg); }
.doodle.d2 { top: -34px; right: 6%; font-size: 1.7rem; animation-delay: .8s; }
.doodle.d3 { bottom: -10px; left: -34px; font-size: 1rem; animation-delay: 1.6s; }
.doodle.d4 { top: 40%; right: -44px; animation-delay: 2.4s; }
.doodle.d5 { bottom: -52px; right: 18%; font-size: 1.45rem; animation-delay: 3.2s; }
@keyframes doodle-float {
  0%, 100% { translate: 0 0; }
  50% { translate: 0 -13px; }
}

.hero-title {
  font-family: var(--font-cursive); font-weight: 400;
  font-size: clamp(2.6rem, 12vw, 6.6rem); line-height: 1.16;
  padding: 0 .18em .08em;
  background: linear-gradient(105deg,
    #fff4fb 0%, #ffc2df 24%, #ff8fd8 46%, #d9b8ff 68%, #fff4fb 88%, #ffc2df 100%);
  background-size: 220% auto;
  -webkit-background-clip: text; background-clip: text;
  color: transparent; -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 14px rgba(255, 143, 216, .5)) drop-shadow(0 6px 34px rgba(255, 143, 216, .28));
  animation: title-shimmer 7s linear infinite;
}
@keyframes title-shimmer { to { background-position: 220% center; } }
.hero-subtitle {
  margin-top: 10px; letter-spacing: .28em; text-transform: uppercase;
  font-size: clamp(.68rem, 1.9vw, .92rem); font-weight: 500; color: var(--blush-pink);
}
.hero-heart { font-size: 1.5rem; margin: 26px 0 30px; }
.met-label { letter-spacing: .3em; font-size: .78rem; color: var(--blush-pink); opacity: .9; }
.met-date {
  font-family: var(--font-script); font-weight: 600;
  font-size: clamp(2rem, 5.4vw, 2.9rem); color: var(--neon-pink);
  text-shadow: var(--glow-pink); margin-top: 8px;
}
.heart-divider { display: flex; align-items: center; gap: 14px; justify-content: center; margin-top: 22px; }
.heart-divider i { display: block; width: 90px; height: 1px; background: linear-gradient(90deg, transparent, var(--neon-pink)); }
.heart-divider i:last-child { transform: scaleX(-1); }
.heart-divider span { color: var(--neon-pink); text-shadow: var(--glow-pink); }

.scroll-hint {
  position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%);
  font-family: var(--font-hand); font-size: 1.1rem; color: rgba(255, 194, 223, .65);
  animation: hint-bob 2.4s ease-in-out infinite;
}
@keyframes hint-bob { 0%, 100% { translate: 0 0; opacity: .65; } 50% { translate: 0 8px; opacity: 1; } }

/* ============================================================
   counter
   ============================================================ */
.counter-card {
  max-width: 880px; margin: 0 auto; padding: clamp(28px, 5vw, 48px);
  text-align: center;
  border: 1.6px solid rgba(255, 143, 216, .55);
  box-shadow: 0 0 30px rgba(255, 143, 216, .25), inset 0 0 40px rgba(255, 143, 216, .05);
}
.counter-label { letter-spacing: .3em; font-size: .8rem; color: var(--blush-pink); margin-bottom: 26px; }
.counter-grid { display: flex; align-items: center; justify-content: center; gap: clamp(8px, 2.4vw, 26px); flex-wrap: wrap; }
.counter-grid i { color: rgba(255, 143, 216, .4); font-size: 1.8rem; font-style: normal; }
.cnt b {
  display: block; font-size: clamp(2rem, 6vw, 3.4rem); font-weight: 700;
  color: var(--soft-white); text-shadow: 0 0 16px rgba(255, 143, 216, .55);
  font-variant-numeric: tabular-nums; min-width: 2ch;
}
.cnt small { display: block; margin-top: 4px; letter-spacing: .18em; font-size: .64rem; color: var(--blush-pink); text-transform: uppercase; }
.counter-caption { margin-top: 28px; font-family: var(--font-script); font-size: 1.3rem; color: var(--blush-pink); }
.milestone {
  margin-top: 14px; font-size: .82rem; letter-spacing: .12em;
  color: rgba(255, 244, 251, .65); text-transform: uppercase;
}
.milestone b { color: var(--neon-pink); font-weight: 700; }

/* typewriter caret for the subtitle */
.hero-subtitle.typing::after {
  content: "▎"; color: var(--neon-pink);
  animation: caret-blink .75s steps(1) infinite;
}
@keyframes caret-blink { 50% { opacity: 0; } }

/* ============================================================
   letter + polaroid
   ============================================================ */
.letter-wrap {
  display: grid; grid-template-columns: 1.15fr .85fr;
  gap: clamp(30px, 5vw, 70px); align-items: center;
}
.letter-text p { margin: 14px 0; line-height: 1.75; color: rgba(255, 244, 251, .88); font-weight: 400; }
.letter-text .cursive-h { margin-bottom: 16px; }
.letter-sign { font-family: var(--font-script); font-size: 1.7rem; color: var(--blush-pink); margin: 20px 0 22px !important; }

.polaroid {
  background: #f7f2f4; border-radius: 6px;
  padding: 12px 12px 16px; position: relative;
  box-shadow: 0 14px 38px rgba(0, 0, 0, .45);
  display: inline-block;
}
.polaroid img { display: block; width: 100%; border-radius: 2px; }
.polaroid figcaption {
  font-family: var(--font-script); font-weight: 600; color: #4a2a5e;
  text-align: center; padding-top: 12px; font-size: 1.25rem;
}
.main-polaroid {
  transform: rotate(3deg); cursor: pointer;
  transition: transform .35s, box-shadow .35s;
  justify-self: center;
  max-width: min(400px, 88vw);
}
.main-polaroid:hover { transform: rotate(.5deg) scale(1.03); box-shadow: 0 18px 50px rgba(0,0,0,.5), 0 0 34px rgba(255,143,216,.3); }
.tape {
  position: absolute; top: -14px; left: 50%; transform: translateX(-50%) rotate(-4deg);
  width: 110px; height: 30px; background: rgba(255, 194, 223, .65);
  box-shadow: 0 2px 6px rgba(0,0,0,.18); border-radius: 2px;
}
.neon-heart {
  position: absolute; right: -18px; bottom: -16px; font-size: 3rem; color: var(--neon-pink);
  text-shadow: 0 0 12px rgba(255,143,216,.95), 0 0 34px rgba(255,143,216,.6);
  animation: pulse 2.6s ease-in-out infinite;
}

/* ============================================================
   little things
   ============================================================ */
.things-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 18px;
}
.thing-card {
  text-align: center; padding: 28px 14px 24px; cursor: default;
  transition: transform .3s, box-shadow .3s, border-color .3s;
  position: relative; overflow: hidden;
}
.thing-card:hover {
  transform: translateY(-9px);
  border-color: rgba(255, 143, 216, .65);
  box-shadow: var(--glow-pink), 0 18px 50px rgba(0,0,0,.35);
}
.t-icon { font-size: 1.9rem; display: block; margin-bottom: 12px; filter: drop-shadow(0 0 10px rgba(255,143,216,.6)); }
.thing-card h3 { font-size: .98rem; font-weight: 700; color: var(--blush-pink); margin-bottom: 8px; }
.thing-card p { font-size: .82rem; color: rgba(255,244,251,.75); line-height: 1.5; }

/* ============================================================
   spotify
   ============================================================ */
.songs-blurb {
  max-width: 640px; margin: 18px auto 40px; text-align: center;
  font-family: var(--font-hand); font-size: 1.3rem; line-height: 1.6;
  color: rgba(255, 244, 251, .8);
}
.songs-wrap {
  display: grid; grid-template-columns: 240px 1fr; gap: 26px;
  padding: clamp(22px, 4vw, 40px); align-items: center;
}
.visualizer-side { text-align: center; }
.vis-icon { display: inline-block; }
.songs-wrap.playing .vis-icon { animation: vis-bob 1.6s ease-in-out infinite; }
@keyframes vis-bob {
  0%, 100% { transform: translateY(0) rotate(-3deg); }
  50% { transform: translateY(-6px) rotate(3deg); }
}
.vis-bars { display: flex; align-items: flex-end; justify-content: center; gap: 4px; height: 56px; margin: 18px 0 12px; }
.vis-bars i {
  width: 5px; border-radius: 4px; height: 18%;
  background: linear-gradient(180deg, var(--blush-pink), var(--neon-pink));
  box-shadow: 0 0 8px rgba(255,143,216,.6);
  transition: height .4s;
}
.songs-wrap.playing .vis-bars i { animation: bounce .9s ease-in-out infinite alternate; }
.vis-bars i:nth-child(2n) { animation-delay: .15s !important; }
.vis-bars i:nth-child(3n) { animation-delay: .32s !important; }
.vis-bars i:nth-child(4n) { animation-delay: .48s !important; }
.vis-bars i:nth-child(5n) { animation-delay: .6s !important; }
@keyframes bounce { from { height: 12%; } to { height: 95%; } }
.vis-caption { font-family: var(--font-script); color: var(--blush-pink); font-size: 1.12rem; }
.vis-notes span {
  display: inline-block; margin: 6px 7px 0; color: var(--neon-pink); opacity: 0;
}
.songs-wrap.playing .vis-notes span { animation: note-rise 2.4s ease-in infinite; }
.vis-notes span:nth-child(2) { animation-delay: .8s !important; }
.vis-notes span:nth-child(3) { animation-delay: 1.6s !important; }
@keyframes note-rise {
  0% { opacity: 0; transform: translateY(6px); }
  25% { opacity: .9; }
  100% { opacity: 0; transform: translateY(-26px) rotate(14deg); }
}
.player-side { text-align: center; }

/* in-built preview player */
.player { margin-top: 6px; text-align: left; }
.np { display: flex; align-items: center; gap: 16px; margin-bottom: 16px; }
#np-cover {
  width: 86px; height: 86px; border-radius: 14px; object-fit: cover;
  border: 1px solid rgba(255,143,216,.45);
  box-shadow: 0 0 18px rgba(255,143,216,.3);
}
.songs-wrap.playing #np-cover { animation: cover-glow 2.4s ease-in-out infinite; }
@keyframes cover-glow {
  0%, 100% { box-shadow: 0 0 14px rgba(255,143,216,.3); }
  50% { box-shadow: 0 0 30px rgba(255,143,216,.6); }
}
.np-meta { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
#np-title {
  font-size: 1.06rem; color: var(--soft-white); font-weight: 700;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
#np-artist { font-size: .86rem; color: var(--blush-pink); }
.np-note { font-size: .7rem; color: rgba(255,244,251,.5); margin-top: 4px; }
.np-note a { color: rgba(255,143,216,.75); text-decoration: none; }
.np-note a:hover { text-shadow: var(--glow-pink); }

.p-progress { display: flex; align-items: center; gap: 10px; }
.p-progress span { font-size: .72rem; color: rgba(255,244,251,.6); font-variant-numeric: tabular-nums; min-width: 4ch; }
#pc-seek { flex: 1; accent-color: var(--neon-pink); height: 4px; cursor: pointer; }

.p-controls { display: flex; align-items: center; justify-content: center; gap: 14px; margin: 14px 0 18px; }
.p-controls button {
  width: 42px; height: 42px; border-radius: 50%; cursor: pointer;
  background: rgba(255,143,216,.1); color: var(--blush-pink);
  border: 1px solid rgba(255,143,216,.4); font-size: 1.05rem;
  transition: transform .2s, box-shadow .2s, background .2s;
  display: flex; align-items: center; justify-content: center;
}
.p-controls button:hover { transform: scale(1.1); box-shadow: 0 0 14px rgba(255,143,216,.4); }
.p-controls .pc-main {
  width: 56px; height: 56px; font-size: 1.25rem; color: var(--deep-purple);
  background: linear-gradient(135deg, var(--neon-pink), var(--blush-pink));
  border: none; box-shadow: 0 0 18px rgba(255,143,216,.5);
}
.p-controls #pc-shuffle.on { background: rgba(255,143,216,.45); color: var(--soft-white); box-shadow: 0 0 14px rgba(255,143,216,.55); }

#track-list {
  list-style: none; max-height: 320px; overflow-y: auto;
  border-top: 1px solid rgba(255,143,216,.18); padding-top: 8px;
  scrollbar-width: thin; scrollbar-color: rgba(255,143,216,.45) transparent;
}
#track-list::-webkit-scrollbar { width: 6px; }
#track-list::-webkit-scrollbar-thumb { background: rgba(255,143,216,.4); border-radius: 6px; }
#track-list li {
  display: flex; align-items: center; gap: 12px;
  padding: 9px 10px; border-radius: 10px; cursor: pointer;
  transition: background .2s;
}
#track-list li:hover { background: rgba(255,143,216,.09); }
#track-list li i { font-style: normal; font-size: .72rem; color: rgba(255,244,251,.45); min-width: 2ch; text-align: right; }
#track-list li div { min-width: 0; flex: 1; display: flex; flex-direction: column; }
#track-list li b { font-size: .88rem; font-weight: 600; color: rgba(255,244,251,.92); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#track-list li span { font-size: .74rem; color: rgba(255,194,223,.65); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
#track-list li em { opacity: 0; color: var(--neon-pink); }
#track-list li.active { background: rgba(255,143,216,.16); }
#track-list li.active b { color: var(--neon-pink); }
#track-list li.active em { opacity: 1; animation: pulse 1.4s ease-in-out infinite; }

/* ============================================================
   garland
   ============================================================ */
.garland { position: relative; padding-top: 30px; }
.rope { position: absolute; top: 0; left: 0; width: 100%; height: 120px; z-index: 0; }
.lights { position: absolute; top: 0; left: 0; width: 100%; height: 120px; z-index: 1; pointer-events: none; }
.lights b {
  position: absolute; width: 10px; height: 10px; border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #fff3d6, var(--fairy-light) 55%, rgba(255, 180, 90, .25));
  box-shadow: 0 0 10px 3px rgba(255, 210, 138, .55);
  animation: flicker 2.8s ease-in-out infinite;
}
@keyframes flicker {
  0%, 100% { opacity: 1; box-shadow: 0 0 10px 3px rgba(255,210,138,.55); }
  45% { opacity: .65; box-shadow: 0 0 6px 2px rgba(255,210,138,.32); }
  62% { opacity: .95; }
}
.garland-row {
  position: relative; z-index: 2;
  display: flex; justify-content: center; align-items: flex-start;
  gap: clamp(10px, 2.4vw, 30px); padding-top: 58px; flex-wrap: wrap;
}
.g-pol {
  width: clamp(128px, 16vw, 185px); padding: 8px 8px 6px;
  cursor: pointer; transform-origin: top center;
  transition: transform .3s, box-shadow .3s;
}
.g-pol figcaption { font-size: 1.02rem; padding-top: 8px; }
.g-pol:hover { box-shadow: 0 16px 40px rgba(0,0,0,.5), 0 0 26px rgba(255,143,216,.35); z-index: 3; }
.g-pol .pin {
  position: absolute; top: -16px; left: 50%; transform: translateX(-50%);
  width: 12px; height: 26px; border-radius: 3px;
  background: linear-gradient(180deg, #c98c4e, #8a5a33);
  box-shadow: 0 2px 5px rgba(0,0,0,.4);
}
.g-pol:nth-child(odd) { margin-top: 26px; }
.g-pol:nth-child(2) { margin-top: 48px; }
.g-pol:nth-child(4) { margin-top: 44px; }
.sway1 { animation: sway 5.4s ease-in-out infinite; }
.sway2 { animation: sway 6.1s ease-in-out infinite reverse; }
.sway3 { animation: sway 5s ease-in-out infinite .6s; }
.sway4 { animation: sway 6.6s ease-in-out infinite reverse .3s; }
.sway5 { animation: sway 5.8s ease-in-out infinite 1s; }
@keyframes sway {
  0%, 100% { rotate: -2.2deg; }
  50% { rotate: 2.2deg; }
}

/* ============================================================
   open when envelopes
   ============================================================ */
.env-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(195px, 1fr));
  gap: 18px; max-width: 980px; margin: 0 auto;
}
.envelope {
  position: relative; padding: 40px 16px 22px; cursor: pointer;
  background: linear-gradient(160deg, rgba(60,26,92,.6), rgba(36,16,58,.7));
  border: 1px solid rgba(255,143,216,.35); border-radius: 16px;
  color: var(--soft-white); font-family: var(--font-body);
  overflow: hidden; transition: transform .3s, box-shadow .3s;
}
.envelope:hover { transform: translateY(-7px); box-shadow: var(--glow-pink); }
.envelope .flap {
  position: absolute; top: 0; left: 0; right: 0; height: 26px;
  background: linear-gradient(180deg, rgba(255,143,216,.5), rgba(255,143,216,.08));
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transform-origin: top; transition: transform .45s;
}
.envelope:hover .flap { transform: rotateX(150deg); }
.env-body { display: block; font-size: 2rem; margin-bottom: 12px; filter: drop-shadow(0 0 10px rgba(255,143,216,.55)); }
.env-label { display: block; font-weight: 600; font-size: .92rem; color: var(--blush-pink); line-height: 1.4; }

/* ============================================================
   puzzles
   ============================================================ */
.puzzle { max-width: 760px; margin: 0 auto 30px; padding: clamp(24px, 4vw, 40px); text-align: center; }
.p-title { font-size: 1.15rem; color: var(--blush-pink); letter-spacing: .06em; margin-bottom: 8px; }
.p-q { font-family: var(--font-hand); font-size: 1.35rem; color: rgba(255,244,251,.85); margin-bottom: 20px; }
.p-row { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
.p-row input, .code-digit {
  background: rgba(22, 8, 36, .6); color: var(--soft-white);
  border: 1px solid rgba(255,143,216,.4); border-radius: 12px;
  padding: 12px 16px; font-family: var(--font-body); font-size: 1rem; outline: none;
  transition: border-color .25s, box-shadow .25s;
}
.p-row input:focus, .code-digit:focus { border-color: var(--neon-pink); box-shadow: 0 0 12px rgba(255,143,216,.4); }
#date-input { width: min(300px, 70vw); }
.p-result { margin-top: 18px; font-family: var(--font-script); font-size: 1.3rem; color: var(--blush-pink); min-height: 1.6em; }
.p-result.ok { color: var(--neon-pink); text-shadow: var(--glow-pink); }

.heart-lock { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.lock-heart { font-size: 3.4rem; filter: drop-shadow(0 0 14px rgba(255,143,216,.7)); transition: transform .3s; }
.heart-lock.unlocked .lock-heart { animation: pulse 1.2s ease-in-out infinite; }
.code-row { display: flex; gap: 10px; }
.code-digit { width: 52px; height: 58px; text-align: center; font-size: 1.5rem; font-weight: 700; }
.heart-lock.shake { animation: shake .5s; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-9px); } 40% { transform: translateX(8px); }
  60% { transform: translateX(-6px); } 80% { transform: translateX(5px); }
}

.match-grid {
  display: grid; grid-template-columns: repeat(4, minmax(58px, 86px));
  gap: 10px; justify-content: center; margin-top: 6px;
}
.match-card { aspect-ratio: 1; perspective: 600px; cursor: pointer; border: none; background: none; padding: 0; }
.match-inner {
  position: relative; display: block; width: 100%; height: 100%;
  transform-style: preserve-3d; transition: transform .45s;
}
.match-card.flipped .match-inner, .match-card.matched .match-inner { transform: rotateY(180deg); }
.match-face {
  position: absolute; inset: 0; backface-visibility: hidden; -webkit-backface-visibility: hidden;
  display: flex; align-items: center; justify-content: center;
  border-radius: 12px; font-size: 1.55rem;
}
.match-front {
  background: linear-gradient(150deg, rgba(93,45,118,.85), rgba(36,16,58,.95));
  border: 1px solid rgba(255,143,216,.4); color: var(--neon-pink);
}
.match-back {
  background: linear-gradient(150deg, rgba(255,143,216,.25), rgba(93,45,118,.6));
  border: 1px solid var(--neon-pink); transform: rotateY(180deg);
}
.match-card.matched .match-back { box-shadow: 0 0 16px rgba(255,143,216,.55); }
.match-card.wrong .match-inner { animation: shake .4s; }

/* ============================================================
   reasons + jar
   ============================================================ */
.reasons-wrap {
  display: grid; grid-template-columns: 1.1fr .9fr;
  gap: clamp(30px, 5vw, 60px); align-items: center;
}
.reasons-card {
  padding: clamp(28px, 4.5vw, 46px); transform: rotate(-2deg);
  border: 1.6px solid rgba(255,143,216,.5);
  box-shadow: 0 0 30px rgba(255,143,216,.22), 0 22px 60px rgba(0,0,0,.4);
  transition: transform .35s;
}
.reasons-card:hover { transform: rotate(-.6deg) scale(1.015); }
.r-title { letter-spacing: .2em; font-size: 1.02rem; color: var(--soft-white); margin-bottom: 22px; text-shadow: 0 0 12px rgba(255,143,216,.5); }
#reasons-list { list-style: none; }
#reasons-list li {
  padding: 7px 0; color: rgba(255,244,251,.88); font-size: .98rem;
}
#reasons-list li.typed { overflow: hidden; white-space: nowrap; }
.r-everything { font-family: var(--font-script); font-size: 1.6rem; color: var(--neon-pink); text-align: right; margin: 14px 6px 22px 0; text-shadow: var(--glow-pink); }
.reasons-card .btn-pink { margin-right: 10px; margin-bottom: 8px; }

.jar-wrap { position: relative; text-align: center; }
#jar-img {
  width: min(330px, 72vw); filter: drop-shadow(0 18px 40px rgba(255,180,90,.18));
  transition: transform .4s;
}
.jar-wrap:hover #jar-img { transform: scale(1.04) rotate(1.5deg); }
.jar-extra-notes { position: absolute; inset: 0; pointer-events: none; }
.jar-note {
  position: absolute; font-family: var(--font-hand); font-size: 1.15rem;
  color: var(--blush-pink); opacity: 0; transition: all 1.4s ease;
  text-shadow: 0 0 10px rgba(255,143,216,.6);
}
.jar-note.n1 { left: 4%; top: 38%; }
.jar-note.n2 { right: 2%; top: 26%; }
.jar-note.n3 { right: 6%; bottom: 18%; }
.jar-wrap.spill .jar-note { opacity: 1; transform: translateY(-30px) rotate(-4deg); }
.jar-wrap.spill .jar-note.n2 { transition-delay: .25s; transform: translateY(-44px) rotate(5deg); }
.jar-wrap.spill .jar-note.n3 { transition-delay: .5s; transform: translateY(-26px) rotate(-7deg); }

/* ============================================================
   dreams
   ============================================================ */
.dreams-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr));
  gap: 18px; margin-bottom: 50px;
}
.dream-card {
  text-align: center; padding: 30px 16px 24px;
  transition: transform .3s, box-shadow .3s, border-color .3s;
}
.dream-card:hover { transform: translateY(-8px) scale(1.02); border-color: rgba(255,143,216,.6); box-shadow: var(--glow-pink); }
.dream-card span { font-size: 2rem; display: block; margin-bottom: 12px; filter: drop-shadow(0 0 12px rgba(255,143,216,.5)); }
.dream-card p { font-size: .92rem; font-weight: 600; color: rgba(255,244,251,.9); line-height: 1.5; }
.dream-card small { display: block; margin-top: 10px; font-family: var(--font-hand); font-size: 1.05rem; color: var(--neon-pink); }

.meter-card { max-width: 560px; margin: 0 auto; padding: 30px clamp(20px, 4vw, 40px); text-align: center; }
.meter-label { font-family: var(--font-hand); font-size: 1.3rem; color: rgba(255,244,251,.85); margin-bottom: 18px; }
#miss-meter {
  width: 100%; accent-color: var(--neon-pink); cursor: pointer; height: 6px;
}
.meter-hearts { min-height: 34px; margin-top: 14px; font-size: 1.15rem; letter-spacing: 4px; color: var(--neon-pink); text-shadow: 0 0 10px rgba(255,143,216,.7); }
.meter-text { font-family: var(--font-script); font-size: 1.2rem; color: var(--blush-pink); margin-top: 8px; }

/* ============================================================
   final
   ============================================================ */
.final-panel {
  position: relative; text-align: center;
  padding: clamp(46px, 7vw, 80px) clamp(22px, 5vw, 70px);
  overflow: visible;
}
.final-sticky {
  position: absolute; width: clamp(110px, 14vw, 170px);
  top: -34px; right: clamp(-10px, 1vw, 30px); transform: rotate(9deg);
  filter: drop-shadow(0 10px 24px rgba(0,0,0,.4));
}
.final-text { max-width: 620px; margin: 16px auto 0; line-height: 1.8; color: rgba(255,244,251,.85); font-size: 1.02rem; }
.final-text.strong { font-weight: 700; color: var(--soft-white); }
.final-sign { margin-top: 34px; font-family: var(--font-script); font-size: 1.5rem; color: var(--blush-pink); line-height: 1.5; }
.final-sign span { font-family: var(--font-cursive); font-size: 2.2rem; color: var(--neon-pink); text-shadow: var(--glow-pink); }
.big-neon-heart {
  font-size: 4.6rem; color: var(--neon-pink); margin-top: 30px;
  text-shadow: 0 0 18px rgba(255,143,216,.9), 0 0 60px rgba(255,143,216,.5);
}
.final-foot { margin-top: 34px; font-size: .92rem; color: rgba(255,244,251,.7); line-height: 1.8; }
.final-foot b { color: var(--blush-pink); }
#secret-heart {
  background: none; border: none; color: rgba(255,143,216,.3);
  font-size: .85rem; cursor: pointer; margin-left: 6px;
  transition: color .3s, text-shadow .3s;
}
#secret-heart:hover { color: var(--neon-pink); text-shadow: var(--glow-pink); }

/* ============================================================
   modal
   ============================================================ */
.modal { position: fixed; inset: 0; z-index: 80; display: flex; align-items: center; justify-content: center; padding: 20px; }
.modal[hidden] { display: none; }
.modal-backdrop { position: absolute; inset: 0; background: rgba(12, 4, 22, .78); backdrop-filter: blur(6px); }
.modal-card {
  position: relative; max-width: 560px; width: 100%; max-height: 82vh; overflow-y: auto;
  background: linear-gradient(165deg, #fdf3f8, #f6e7f0);
  color: #3c1f52; border-radius: 18px; padding: clamp(28px, 5vw, 46px);
  box-shadow: 0 0 0 1px rgba(255,143,216,.5), 0 0 50px rgba(255,143,216,.35), 0 30px 80px rgba(0,0,0,.5);
  animation: modal-in .45s cubic-bezier(.2, .9, .3, 1.2);
  background-image:
    linear-gradient(165deg, rgba(253,243,248,.97), rgba(246,231,240,.97)),
    repeating-linear-gradient(0deg, transparent 0 30px, rgba(93,45,118,.12) 30px 31px);
}
@keyframes modal-in { from { opacity: 0; transform: translateY(34px) scale(.94); } to { opacity: 1; transform: none; } }
.modal-close {
  position: absolute; top: 14px; right: 16px; background: none; border: none;
  font-size: 1.15rem; color: #8a5fa8; cursor: pointer;
}
.modal-card h3 { font-family: var(--font-script); font-size: 1.8rem; color: #b34a8c; margin-bottom: 16px; }
.modal-card p { font-family: var(--font-hand); font-size: 1.35rem; line-height: 1.65; margin: 12px 0; }
.modal-card .modal-heart { text-align: center; font-size: 2rem; margin-top: 16px; color: #ff6fc4; }

/* ============================================================
   hug overlay / cursor hearts / falling hearts
   ============================================================ */
#hug-overlay {
  position: fixed; inset: 0; z-index: 90;
  background: rgba(16, 5, 30, .88); backdrop-filter: blur(8px);
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 26px;
}
#hug-overlay[hidden] { display: none; }
#hug-overlay p { font-family: var(--font-script); font-size: clamp(1.4rem, 4vw, 2rem); color: var(--blush-pink); text-shadow: var(--glow-pink); text-align: center; padding: 0 20px; }
.hug-anim { position: relative; }
.hug-anim iconify-icon {
  font-size: 6rem; display: inline-block; color: var(--neon-pink);
  filter: drop-shadow(0 0 26px rgba(255,143,216,.8));
  animation: hug-pop 1.2s cubic-bezier(.2, .9, .3, 1.4);
}
@keyframes hug-pop { 0% { transform: scale(0); } 60% { transform: scale(1.25); } 100% { transform: scale(1); } }

.cursor-heart, .fall-heart, .burst-heart {
  position: fixed; pointer-events: none; z-index: 70; color: var(--neon-pink);
  text-shadow: 0 0 8px rgba(255,143,216,.8); user-select: none;
}
.cursor-heart { animation: ch-fade 1.1s ease-out forwards; font-size: .9rem; }
@keyframes ch-fade {
  0% { opacity: .9; transform: translateY(0) scale(1); }
  100% { opacity: 0; transform: translateY(-34px) scale(.5) rotate(18deg); }
}
.burst-heart { animation: bh 1s ease-out forwards; }
@keyframes bh {
  0% { opacity: 1; transform: translate(0, 0) scale(.6); }
  100% { opacity: 0; transform: translate(var(--dx), var(--dy)) scale(1.25); }
}
.fall-heart { top: -40px; animation: fh linear forwards; }
@keyframes fh {
  0% { opacity: 1; transform: translateY(0) rotate(0); }
  90% { opacity: .9; }
  100% { opacity: 0; transform: translateY(105vh) rotate(var(--rot)); }
}

/* ============================================================
   little poems
   ============================================================ */
.poems-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
  gap: 20px; max-width: 920px; margin: 0 auto;
}
.poem-card { perspective: 1000px; cursor: pointer; min-height: 250px; outline: none; }
.poem-inner {
  position: relative; width: 100%; height: 100%; min-height: 250px;
  transform-style: preserve-3d;
  transition: transform .7s cubic-bezier(.25, .85, .3, 1.08);
}
.poem-card.flipped .poem-inner { transform: rotateY(180deg); }
.poem-card:hover .poem-inner { box-shadow: none; }
.poem-face {
  position: absolute; inset: 0;
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  border-radius: 18px; padding: 24px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px;
}
.poem-front {
  background: linear-gradient(160deg, rgba(60, 26, 92, .55), rgba(36, 16, 58, .68));
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 143, 216, .32);
  box-shadow: 0 0 22px rgba(255, 143, 216, .12), 0 14px 40px rgba(0, 0, 0, .3);
  transition: border-color .3s, box-shadow .3s, transform .3s;
}
.poem-card:hover .poem-front { border-color: rgba(255, 143, 216, .6); box-shadow: var(--glow-pink); }
.poem-front iconify-icon { font-size: 2.1rem; color: var(--neon-pink); filter: drop-shadow(0 0 10px rgba(255,143,216,.5)); }
.poem-front h3 { font-family: var(--font-script); font-size: 1.55rem; font-weight: 600; color: var(--blush-pink); }
.poem-front span { font-family: var(--font-hand); font-size: 1.05rem; color: rgba(255, 244, 251, .55); }
.poem-back {
  transform: rotateY(180deg);
  background:
    linear-gradient(165deg, rgba(253, 243, 248, .97), rgba(246, 231, 240, .97)),
    repeating-linear-gradient(0deg, transparent 0 26px, rgba(93, 45, 118, .14) 26px 27px);
  border: 1px solid rgba(255, 143, 216, .55);
  box-shadow: 0 0 26px rgba(255, 143, 216, .25);
}
.poem-back p {
  font-family: var(--font-hand); font-size: 1.22rem; line-height: 1.75;
  color: #3c1f52; text-align: center;
}

/* ============================================================
   responsive
   ============================================================ */
@media (max-width: 880px) {
  .letter-wrap, .reasons-wrap { grid-template-columns: 1fr; }
  .main-polaroid { margin-top: 26px; }
  .songs-wrap { grid-template-columns: 1fr; }
  .visualizer-side { order: 2; }
  .float-btns { right: 10px; gap: 9px; }
  .float-btn { width: 40px; height: 40px; font-size: 1rem; }
  .amb-cloud--left { width: 80vw; }
  .amb-cloud--right { width: 86vw; }
  .g-pol:nth-child(n) { margin-top: 0; }
  .garland-row { gap: 16px; }
  .g-pol { width: clamp(124px, 38vw, 165px); }
  .rope, .lights { display: none; }
  .g-pol .pin { display: none; }
  .final-sticky { top: -28px; right: 4px; }
  .match-grid { grid-template-columns: repeat(4, minmax(54px, 74px)); }
}

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