:root { color-scheme: dark; background: #000; }

body {
  margin: 0;
}

main {
  position: relative;
  isolation: isolate;
  touch-action: pan-y pinch-zoom;
}

.date-reveal {
  --light-radius: clamp(78px, 13vw, 185px);
  position: fixed;
  inset: 0;
  pointer-events: none;
  opacity: 0;
  transition: opacity 260ms ease-out;
  mask-image: radial-gradient(circle var(--light-radius) at var(--light-x, 50%) var(--light-y, 50%),
    #000 10%, rgb(0 0 0 / 0.65) 47%, transparent 100%);
}

.date-reveal.is-lit {
  opacity: 1;
  transition: none;
}

.date-reveal canvas { display: block; width: 100%; height: 100%; }

@media (prefers-reduced-motion: reduce) {
  .date-reveal { transition: none; }
}

.bouquet-track {
  position: fixed;
  z-index: 2;
  top: 50svh;
  left: 50%;
  width: min(96vw, 548px, 76svh);
  aspect-ratio: 880 / 1120;
  translate: -50% -50%;
  pointer-events: none;
}

#bouquet {
  display: block;
  width: 100%;
  height: auto;
}

@media (prefers-reduced-motion: no-preference) {
  main:not(.is-timeline) #bouquet {
    animation: bouquet-breath 6s ease-in-out infinite;
  }

  @keyframes bouquet-breath {
    0%, 100% { transform: scale(calc(1 - 0.015 * var(--home-presence, 1))); }
    50% { transform: scale(calc(1 + 0.03 * var(--home-presence, 1))); }
  }
}

@media (max-height: 600px) {
  .bouquet-track {
    width: min(96vw, 548px, 64svh);
  }
}

.ambient-effects {
  position: fixed;
  z-index: 3;
  inset: 0;
  overflow: hidden;
  pointer-events: none;
  opacity: var(--home-presence, 1);
}

.heart-burst,
.heart-burst span,
.floating-shape {
  position: absolute;
}

.heart-burst span,
.floating-shape {
  translate: -50% -50%;
  font: bold clamp(9px, 2.6vw, 12px) / 0.85 "Courier New", monospace;
  white-space: pre;
  text-shadow: 0 0 4px #100d15, 0 0 9px currentColor;
}

.heart-burst span {
  left: 0;
  top: 0;
}

.heart-burst .heart-spark {
  font-size: 15px;
}
