@import url('https://fonts.googleapis.com/css2?family=DM+Serif+Display:ital@0;1&family=Inter:wght@400;500;600;700;800&display=swap');

:root {
  --page-width: 33rem;
  --card: rgba(255, 255, 255, 0.72);
  --card-strong: rgba(255, 255, 255, 0.84);
  --text: #392f36;
  --muted: #7b6874;
  --pink: #f8b8d0;
  --peach: #ffd1b8;
  --lavender: #d8c6ff;
  --mint: #c9f2df;
  --butter: #fff0a8;
  --rose: #b45f83;
  --rose-dark: #8f4967;
  --shadow: 0 28px 70px rgba(184, 119, 150, 0.2);
  --shadow-strong: 0 26px 80px rgba(112, 79, 96, 0.28);
  --border: rgba(255, 255, 255, 0.72);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  color: var(--text);
  font-family: 'Inter', sans-serif;
  background:
    radial-gradient(circle at 15% 10%, rgba(248, 184, 208, 0.88), transparent 30%),
    radial-gradient(circle at 85% 14%, rgba(216, 198, 255, 0.92), transparent 28%),
    radial-gradient(circle at 16% 82%, rgba(201, 242, 223, 0.82), transparent 32%),
    radial-gradient(circle at 82% 74%, rgba(255, 209, 184, 0.85), transparent 32%),
    linear-gradient(180deg, #fff7fb 0%, #fffaf0 46%, #f9f4ff 100%);
  overflow-x: hidden;
}

body::before,
body::after {
  content: "";
  position: fixed;
  inset: auto;
  border-radius: 999px;
  pointer-events: none;
  z-index: 0;
  filter: blur(12px);
  animation: floatHalo 14s ease-in-out infinite;
}

body::before {
  width: 10rem;
  height: 10rem;
  top: 5rem;
  right: -3rem;
  background: rgba(255, 240, 168, 0.68);
}

body::after {
  width: 13rem;
  height: 13rem;
  bottom: -4rem;
  left: -4rem;
  animation-delay: -5s;
  background: rgba(248, 184, 208, 0.52);
}

.page-noise {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  opacity: 0.38;
  background:
    linear-gradient(120deg, rgba(255, 255, 255, 0.14), transparent 60%),
    radial-gradient(circle at 20% 20%, rgba(255, 255, 255, 0.18), transparent 18%),
    radial-gradient(circle at 70% 35%, rgba(255, 255, 255, 0.12), transparent 18%);
  mix-blend-mode: screen;
}

.progress-track {
  position: fixed;
  inset: 0 0 auto;
  height: 0.35rem;
  z-index: 12;
  background: rgba(255, 255, 255, 0.24);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
}

.progress-bar {
  display: block;
  width: 100%;
  height: 100%;
  transform: scaleX(0);
  transform-origin: left center;
  background: linear-gradient(90deg, var(--pink), var(--peach), var(--lavender), var(--mint));
  box-shadow: 0 0 24px rgba(216, 198, 255, 0.8);
}

.ambient-hearts {
  position: fixed;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.ambient-heart {
  position: absolute;
  bottom: -4rem;
  width: var(--size);
  height: calc(var(--size) * 1.25);
  left: var(--left);
  opacity: 0;
  border-radius: 1rem 1rem 0.55rem 0.55rem;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), var(--tone));
  box-shadow: 0 10px 28px rgba(125, 94, 109, 0.14);
  transform: translate3d(0, 0, 0) rotate(var(--rotate));
  animation: driftUp var(--duration) linear infinite;
  animation-delay: var(--delay);
}

.ambient-heart::before,
.ambient-heart::after {
  content: "";
  position: absolute;
  width: 55%;
  height: 55%;
  top: -18%;
  border-radius: 999px;
  background: inherit;
}

.ambient-heart::before {
  left: 0;
}

.ambient-heart::after {
  right: 0;
}

.letter-page {
  position: relative;
  z-index: 1;
  width: min(100%, var(--page-width));
  margin: 0 auto;
  padding: 1rem 1rem 3rem;
}

[data-reveal] {
  opacity: 0;
  transform: translateY(2rem) scale(0.98);
  transition:
    opacity 0.8s ease,
    transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
  transition-delay: var(--reveal-delay, 0ms);
}

[data-reveal].is-visible {
  opacity: 1;
  transform: translateY(0) scale(1);
}

.hero {
  position: relative;
  min-height: 94vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  padding: 2rem 1.2rem 4rem;
  border-radius: 0 0 2.5rem 2.5rem;
  text-align: center;
  isolation: isolate;
  box-shadow: var(--shadow-strong);
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.24), rgba(255, 247, 251, 0.82)),
    url("../photos/foto-1.ee9c91719a55.jpg");
  background-size: cover;
  background-position: center;
}

.hero::before,
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
}

.hero::before {
  background:
    radial-gradient(circle at 22% 20%, rgba(248, 184, 208, 0.56), transparent 35%),
    radial-gradient(circle at 78% 14%, rgba(216, 198, 255, 0.44), transparent 32%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.1), rgba(255, 247, 251, 0.76));
  backdrop-filter: blur(1.8px);
  -webkit-backdrop-filter: blur(1.8px);
}

.hero::after {
  background:
    linear-gradient(180deg, transparent 50%, rgba(255, 247, 251, 0.55) 84%, rgba(255, 247, 251, 0.95) 100%);
}

.hero > * {
  position: relative;
  z-index: 1;
}

.hero-orbit {
  position: absolute;
  border-radius: 999px;
  pointer-events: none;
  transition: transform 0.35s ease;
}

.orbit-one {
  width: 12rem;
  height: 12rem;
  top: -2rem;
  left: -4rem;
  border: 1px solid rgba(255, 255, 255, 0.54);
  background: radial-gradient(circle, rgba(255, 255, 255, 0.48), rgba(248, 184, 208, 0.12));
  box-shadow: inset 0 0 0 1rem rgba(255, 255, 255, 0.08);
}

.orbit-two {
  width: 9rem;
  height: 9rem;
  right: -1.6rem;
  bottom: 6rem;
  background:
    radial-gradient(circle at 30% 30%, rgba(255, 255, 255, 0.78), rgba(216, 198, 255, 0.24)),
    linear-gradient(180deg, rgba(255, 255, 255, 0.26), rgba(255, 255, 255, 0.05));
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.44),
    0 22px 55px rgba(116, 78, 101, 0.18);
}

.hero-sparkles {
  position: absolute;
  inset: 0;
  pointer-events: none;
}

.hero-sparkles span {
  position: absolute;
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 0 22px rgba(255, 255, 255, 0.8);
  animation: twinkle 4.8s ease-in-out infinite;
}

.hero-sparkles span:nth-child(1) {
  top: 18%;
  left: 15%;
}

.hero-sparkles span:nth-child(2) {
  top: 26%;
  right: 18%;
  width: 0.45rem;
  height: 0.45rem;
  animation-delay: -1.3s;
}

.hero-sparkles span:nth-child(3) {
  bottom: 21%;
  right: 24%;
  width: 0.55rem;
  height: 0.55rem;
  animation-delay: -2.1s;
}

.eyebrow {
  margin: 0 0 1rem;
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.26em;
  text-transform: uppercase;
  color: #a86e8a;
}

h1,
h2 {
  font-family: 'DM Serif Display', serif;
  font-weight: 400;
}

h1 {
  margin: 0;
  font-size: clamp(3.4rem, 16vw, 5.7rem);
  line-height: 0.9;
  letter-spacing: -0.07em;
  color: #3f3039;
  text-wrap: balance;
}

.subtitle {
  width: min(100%, 23rem);
  margin: 1.5rem auto 0;
  padding: 1rem 1.05rem;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 1.6rem;
  background: rgba(255, 255, 255, 0.58);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  font-size: 1rem;
  line-height: 1.78;
  color: #614757;
  box-shadow: 0 18px 44px rgba(125, 87, 104, 0.14);
}

.scroll-cue {
  position: absolute;
  left: 50%;
  bottom: 1.3rem;
  width: 3.2rem;
  height: 3.2rem;
  border: 0;
  padding: 0;
  cursor: pointer;
  transform: translateX(-50%);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.68);
  box-shadow: 0 14px 30px rgba(91, 65, 81, 0.16);
  backdrop-filter: blur(12px);
  -webkit-tap-highlight-color: transparent;
}

.scroll-cue span,
.scroll-cue span::before {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

.scroll-cue span {
  top: 0.78rem;
  width: 1.05rem;
  height: 1.55rem;
  border: 2px solid rgba(120, 82, 101, 0.56);
  border-radius: 999px;
}

.scroll-cue span::before {
  content: "";
  top: 0.28rem;
  width: 0.24rem;
  height: 0.4rem;
  border-radius: 999px;
  background: rgba(120, 82, 101, 0.8);
  animation: scrollDot 1.5s ease-in-out infinite;
}

.letter-card,
.song-section,
.proposal-section,
.final-note {
  position: relative;
  overflow: hidden;
  margin: 1.3rem 0;
  padding: 1.4rem;
  border: 1px solid var(--border);
  border-radius: 2rem;
  background: var(--card);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  box-shadow: var(--shadow);
}

.letter-card::before,
.proposal-section::before,
.song-section::before,
.final-note::before {
  content: "";
  position: absolute;
  width: 9rem;
  height: 9rem;
  top: -3.5rem;
  right: -3.2rem;
  border-radius: 999px;
  background: rgba(216, 198, 255, 0.34);
}

.letter-card::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.14), transparent 28%),
    repeating-linear-gradient(180deg, transparent 0 1.85rem, rgba(180, 95, 131, 0.045) 1.85rem 1.92rem);
  pointer-events: none;
  opacity: 0.7;
}

.letter-card p {
  position: relative;
  z-index: 1;
  margin: 0 0 1.35rem;
  font-size: 1.02rem;
  line-height: 1.9;
  color: #493d45;
}

.letter-card p:last-child {
  margin-bottom: 0;
}

.signature {
  margin-top: 2rem !important;
  font-family: 'DM Serif Display', serif;
  font-size: 1.95rem !important;
  line-height: 1.2 !important;
  color: var(--rose) !important;
  text-align: right;
}

.proposal-section {
  text-align: center;
  padding: 1.7rem 1.2rem;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.84), rgba(255, 244, 250, 0.84)),
    radial-gradient(circle at top right, rgba(248, 184, 208, 0.5), transparent 45%),
    radial-gradient(circle at bottom left, rgba(216, 198, 255, 0.52), transparent 45%);
}

.proposal-section h2 {
  position: relative;
  z-index: 1;
  margin: 0;
  font-size: 2.2rem;
  line-height: 1.08;
  color: #3f3039;
  text-wrap: balance;
}

.proposal-text {
  position: relative;
  z-index: 1;
  margin: 1rem auto 1.5rem;
  max-width: 22rem;
  font-size: 0.99rem;
  line-height: 1.75;
  color: var(--muted);
}

.proposal-actions {
  position: relative;
  z-index: 1;
  min-height: 8rem;
  padding: 0.8rem 0.2rem 0;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 0.8rem;
}

.proposal-btn {
  border: 0;
  cursor: pointer;
  border-radius: 999px;
  padding: 1rem 1.2rem;
  font-family: 'Inter', sans-serif;
  font-size: 0.95rem;
  font-weight: 800;
  box-shadow: 0 16px 32px rgba(87, 63, 78, 0.16);
  transition:
    transform 0.22s ease,
    box-shadow 0.22s ease,
    left 0.28s cubic-bezier(0.18, 0.72, 0.2, 1),
    top 0.28s cubic-bezier(0.18, 0.72, 0.2, 1),
    opacity 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.proposal-btn:hover {
  transform: translateY(-0.18rem) scale(1.02);
  box-shadow: 0 22px 40px rgba(87, 63, 78, 0.18);
}

.yes-btn {
  position: relative;
  color: #fff;
  background: linear-gradient(135deg, #d86f9a, #b45f83);
}

.yes-btn::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  background: linear-gradient(120deg, rgba(255, 255, 255, 0.18), transparent 55%);
  pointer-events: none;
}

.yes-btn.is-accepted {
  box-shadow:
    0 0 0 0.45rem rgba(248, 184, 208, 0.22),
    0 22px 46px rgba(180, 95, 131, 0.28);
  animation: acceptedPulse 1.1s ease;
}

.no-btn {
  position: relative;
  color: #7b6874;
  background: rgba(255, 255, 255, 0.92);
}

.no-btn.is-running {
  position: absolute;
  z-index: 2;
}

.no-btn.is-hidden {
  opacity: 0;
  transform: scale(0.84);
}

.proposal-btn:active {
  transform: scale(0.96);
}

.celebration-burst {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.burst-petal {
  position: absolute;
  width: var(--size);
  height: calc(var(--size) * 1.25);
  left: var(--x);
  top: var(--y);
  border-radius: 1rem 1rem 0.5rem 0.5rem;
  opacity: 0;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.9), var(--tone));
  transform: translate(-50%, -50%) rotate(var(--rotate));
  animation: burstOut 1.2s cubic-bezier(0.2, 0.75, 0.2, 1) forwards;
}

.burst-petal::before,
.burst-petal::after {
  content: "";
  position: absolute;
  width: 55%;
  height: 55%;
  top: -18%;
  border-radius: 999px;
  background: inherit;
}

.burst-petal::before {
  left: 0;
}

.burst-petal::after {
  right: 0;
}

.proposal-answer {
  display: none;
  position: relative;
  z-index: 1;
  margin-top: 1.35rem;
  padding: 1.15rem;
  border: 1px solid rgba(255, 255, 255, 0.5);
  border-radius: 1.6rem;
  background: rgba(255, 255, 255, 0.7);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.48);
}

.proposal-answer.show {
  display: block;
  animation: answerReveal 0.62s cubic-bezier(0.2, 0.85, 0.2, 1) both;
}

.proposal-answer h3 {
  margin: 0 0 0.5rem;
  font-family: 'DM Serif Display', serif;
  font-size: 1.68rem;
  font-weight: 400;
  color: var(--rose);
}

.proposal-answer p {
  margin: 0 0 0.8rem;
  line-height: 1.65;
  color: #493d45;
}

.proposal-answer span {
  font-weight: 800;
  color: var(--rose);
}

.song-section {
  text-align: center;
  padding: 1.65rem 1.2rem;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.78), rgba(255, 240, 248, 0.72)),
    radial-gradient(circle at top left, rgba(255, 209, 184, 0.48), transparent 44%);
}

.song-section h2 {
  margin: 0;
  font-size: 2.8rem;
  line-height: 1;
  color: #3f3039;
}

.song-note {
  margin: 0.45rem 0 1.2rem;
  color: var(--muted);
  font-size: 0.95rem;
}

audio {
  width: 100%;
  height: 3rem;
  margin-bottom: 1rem;
  border-radius: 999px;
  filter: saturate(0.92);
}

.song-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  min-width: min(100%, 15rem);
  padding: 0.95rem 1.2rem;
  border-radius: 999px;
  color: #fff;
  text-decoration: none;
  font-weight: 800;
  background: linear-gradient(135deg, #d888a8, #bb6e96, #9c81c7);
  box-shadow: 0 18px 36px rgba(136, 93, 123, 0.2);
  transition: transform 0.22s ease, box-shadow 0.22s ease, filter 0.22s ease;
}

.song-link::after {
  content: "↗";
  font-size: 1rem;
}

.song-link:hover {
  transform: translateY(-0.18rem) scale(1.01);
  box-shadow: 0 24px 44px rgba(136, 93, 123, 0.24);
  filter: saturate(1.05);
}

.photos-section {
  display: grid;
  gap: 1.2rem;
  margin: 1.3rem 0;
}

.photo-card {
  position: relative;
  margin: 0;
  padding: 1.15rem 1rem 1rem;
  border-radius: 2rem;
  background: rgba(255, 255, 255, 0.58);
  border: 1px solid rgba(255, 255, 255, 0.58);
  box-shadow: 0 22px 48px rgba(87, 63, 78, 0.14);
  backdrop-filter: blur(16px);
  transform: rotate(var(--tilt));
  transition: transform 0.28s ease, box-shadow 0.28s ease;
}

.photo-card:hover {
  transform: translateY(-0.3rem) rotate(var(--tilt));
  box-shadow: 0 30px 58px rgba(87, 63, 78, 0.2);
}

.photo-card--one {
  --tilt: -1.6deg;
}

.photo-card--two {
  --tilt: 1.2deg;
}

.photo-card--three {
  --tilt: -0.8deg;
}

.photo-tape {
  position: absolute;
  top: 0.35rem;
  left: 50%;
  width: 5rem;
  height: 1.3rem;
  transform: translateX(-50%) rotate(-3deg);
  border-radius: 0.45rem;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.82), rgba(255, 255, 255, 0.48)),
    repeating-linear-gradient(90deg, rgba(255, 255, 255, 0.14) 0 0.5rem, rgba(255, 255, 255, 0.32) 0.5rem 1rem);
  opacity: 0.8;
}

.photo-frame {
  position: relative;
  display: block;
  width: 100%;
  border: 0;
  padding: 0;
  cursor: pointer;
  background: transparent;
  border-radius: 1.55rem;
  overflow: hidden;
}

.photo-frame::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(125deg, rgba(255, 255, 255, 0.18), transparent 35%),
    linear-gradient(180deg, transparent 55%, rgba(32, 22, 30, 0.12));
  pointer-events: none;
}

.photo-frame img {
  display: block;
  width: 100%;
  min-height: 17rem;
  max-height: 28rem;
  object-fit: cover;
  border: 0.6rem solid rgba(255, 255, 255, 0.86);
  border-radius: 1.55rem;
  box-shadow: 0 18px 38px rgba(87, 63, 78, 0.14);
}

.photo-frame:focus-visible,
.proposal-btn:focus-visible,
.scroll-cue:focus-visible,
.song-link:focus-visible,
.lightbox-close:focus-visible,
.lightbox-nav:focus-visible {
  outline: 2px solid rgba(180, 95, 131, 0.9);
  outline-offset: 0.22rem;
}

.final-note {
  margin-top: 1.6rem;
  text-align: center;
  background:
    linear-gradient(135deg, rgba(255, 255, 255, 0.82), rgba(248, 242, 255, 0.82));
}

.final-note p {
  margin: 0;
  font-family: 'DM Serif Display', serif;
  font-size: 1.58rem;
  line-height: 1.35;
  color: #614757;
}

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 0.75rem;
  padding: 1rem;
  opacity: 0;
  pointer-events: none;
  background:
    radial-gradient(circle at top, rgba(248, 184, 208, 0.22), transparent 30%),
    rgba(41, 30, 40, 0.58);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  transition: opacity 0.3s ease;
}

.lightbox.is-open {
  opacity: 1;
  pointer-events: auto;
}

body.lightbox-open {
  overflow: hidden;
}

.lightbox-figure {
  margin: 0;
  width: 100%;
  display: flex;
  justify-content: center;
}

.lightbox-figure img {
  width: min(100%, 34rem);
  max-height: 82vh;
  object-fit: cover;
  border-radius: 1.8rem;
  border: 0.65rem solid rgba(255, 255, 255, 0.82);
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.26);
}

.lightbox-close,
.lightbox-nav {
  position: relative;
  width: 3rem;
  height: 3rem;
  border: 0;
  padding: 0;
  cursor: pointer;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  box-shadow: 0 14px 34px rgba(0, 0, 0, 0.18);
}

.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
}

.lightbox-close::before,
.lightbox-close::after,
.lightbox-prev::before,
.lightbox-next::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 1rem;
  height: 0.16rem;
  border-radius: 999px;
  background: #6f5462;
}

.lightbox-close::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.lightbox-close::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.lightbox-prev::before {
  transform: translate(-60%, -50%) rotate(-35deg);
  width: 0.8rem;
}

.lightbox-prev::after,
.lightbox-next::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0.8rem;
  height: 0.16rem;
  border-radius: 999px;
  background: #6f5462;
}

.lightbox-prev::after {
  transform: translate(-60%, -50%) rotate(35deg);
}

.lightbox-next::before {
  transform: translate(-40%, -50%) rotate(35deg);
  width: 0.8rem;
}

.lightbox-next::after {
  transform: translate(-40%, -50%) rotate(-35deg);
}

@keyframes scrollDot {
  0%,
  100% {
    transform: translate(-50%, 0);
    opacity: 0.45;
  }

  50% {
    transform: translate(-50%, 0.42rem);
    opacity: 1;
  }
}

@keyframes floatHalo {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }

  50% {
    transform: translate3d(0.8rem, -1rem, 0) scale(1.04);
  }
}

@keyframes twinkle {
  0%,
  100% {
    opacity: 0.45;
    transform: scale(0.9);
  }

  50% {
    opacity: 1;
    transform: scale(1.18);
  }
}

@keyframes acceptedPulse {
  0% {
    transform: scale(1);
  }

  35% {
    transform: scale(1.05);
  }

  100% {
    transform: scale(1);
  }
}

@keyframes answerReveal {
  from {
    opacity: 0;
    transform: translateY(0.8rem) scale(0.96);
  }

  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

@keyframes driftUp {
  0% {
    opacity: 0;
    transform: translate3d(0, 0, 0) rotate(var(--rotate));
  }

  10%,
  80% {
    opacity: 0.55;
  }

  100% {
    opacity: 0;
    transform: translate3d(var(--drift), -112vh, 0) rotate(calc(var(--rotate) + 28deg));
  }
}

@keyframes burstOut {
  0% {
    opacity: 0;
    transform: translate(-50%, -50%) scale(0.3) rotate(var(--rotate));
  }

  18% {
    opacity: 1;
  }

  100% {
    opacity: 0;
    transform:
      translate(
        calc(-50% + var(--travel-x)),
        calc(-50% + var(--travel-y))
      )
      scale(1.05)
      rotate(calc(var(--rotate) + 38deg));
  }
}

@media (max-width: 640px) {
  .letter-page {
    padding-inline: 0.85rem;
  }

  .letter-card,
  .song-section,
  .proposal-section,
  .final-note {
    border-radius: 1.8rem;
  }

  .proposal-section h2 {
    font-size: 2rem;
  }

  .lightbox {
    grid-template-columns: 1fr;
    justify-items: center;
  }

  .lightbox-nav {
    position: absolute;
    bottom: 1rem;
  }

  .lightbox-prev {
    left: calc(50% - 4rem);
  }

  .lightbox-next {
    right: calc(50% - 4rem);
  }
}

@media (max-width: 360px) {
  .letter-page {
    padding-inline: 0.8rem;
  }

  .letter-card,
  .song-section,
  .proposal-section,
  .final-note {
    padding: 1.15rem;
  }

  .letter-card p {
    font-size: 0.98rem;
  }

  .proposal-section h2 {
    font-size: 1.86rem;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
  }
}
