:root {
  color-scheme: light;
  --bg: #fff7fb;
  --card: rgba(255, 255, 255, 0.78);
  --ink: #442236;
  --muted: #8e6377;
  --pink: #ff7eb6;
  --rose: #ff4f93;
  --lavender: #b894ff;
  --cream: #fff1cf;
  --shadow: 0 24px 70px rgba(197, 86, 138, 0.22);
}

* {
  box-sizing: border-box;
}

body {
  min-height: 100vh;
  margin: 0;
  color: var(--ink);
  font-family: "Comfortaa", system-ui, sans-serif;
  background:
    radial-gradient(circle at 12% 15%, rgba(255, 126, 182, 0.35), transparent 28rem),
    radial-gradient(circle at 84% 8%, rgba(184, 148, 255, 0.35), transparent 24rem),
    linear-gradient(135deg, #fff7fb 0%, #fff2e5 48%, #f7edff 100%);
  overflow-x: hidden;
}

body::before {
  position: fixed;
  inset: 0;
  z-index: -2;
  content: "";
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.48) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.48) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(to bottom, black, transparent 82%);
}

main {
  width: min(1120px, calc(100% - 32px));
  margin: 0 auto;
  padding: 42px 0 56px;
}

.card {
  position: relative;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 34px;
  background: var(--card);
  box-shadow: var(--shadow);
  backdrop-filter: blur(18px);
}

.hero {
  min-height: 74vh;
  display: grid;
  place-items: center;
  padding: clamp(38px, 7vw, 88px);
  text-align: center;
  overflow: hidden;
}

.hero::before,
.hero::after {
  position: absolute;
  content: "";
  border-radius: 999px;
  filter: blur(2px);
}

.hero::before {
  width: 190px;
  height: 190px;
  left: -54px;
  bottom: -48px;
  background: rgba(255, 126, 182, 0.28);
}

.hero::after {
  width: 150px;
  height: 150px;
  right: -34px;
  top: -30px;
  background: rgba(255, 241, 207, 0.92);
}

.eyebrow {
  margin: 0 0 14px;
  color: var(--rose);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.anniversary-badge {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  border: 1px solid rgba(255, 255, 255, 0.72);
  border-radius: 999px;
  padding: 12px 18px;
  color: var(--rose);
  font-weight: 700;
  background: rgba(255, 255, 255, 0.62);
  box-shadow: 0 12px 28px rgba(255, 79, 147, 0.16);
}

h1,
h2,
p {
  position: relative;
  margin-top: 0;
}

h1 {
  max-width: 850px;
  margin-bottom: 22px;
  font-family: "Pacifico", cursive;
  font-size: clamp(3rem, 10vw, 7.5rem);
  line-height: 1.05;
  text-shadow: 0 10px 32px rgba(255, 79, 147, 0.22);
}

h2 {
  margin-bottom: 14px;
  font-size: clamp(1.45rem, 3vw, 2.2rem);
  line-height: 1.15;
}

p {
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.8;
}

.hero-text {
  max-width: 720px;
  margin: 0 auto 34px;
  font-size: clamp(1rem, 2vw, 1.25rem);
}

button {
  font: inherit;
  cursor: pointer;
}

.love-button {
  border: 0;
  border-radius: 999px;
  padding: 17px 28px;
  color: white;
  font-weight: 700;
  background: linear-gradient(135deg, var(--rose), var(--lavender));
  box-shadow: 0 16px 32px rgba(255, 79, 147, 0.32);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.love-button:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 20px 40px rgba(255, 79, 147, 0.42);
}

.reasons {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
  margin: 20px 0;
}

.reason {
  padding: 28px;
}

.reason span {
  display: inline-grid;
  width: 48px;
  height: 48px;
  margin-bottom: 22px;
  place-items: center;
  border-radius: 16px;
  color: white;
  font-weight: 700;
  background: linear-gradient(135deg, var(--pink), var(--lavender));
}

.memory,
.story,
.bear-memory,
.kiss-memory,
.timer,
.letter,
.date-invite {
  margin-top: 20px;
  padding: clamp(28px, 5vw, 48px);
}

.memory {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 24px;
  align-items: center;
}

.heart {
  width: clamp(116px, 18vw, 170px);
  height: clamp(116px, 18vw, 170px);
  border: 0;
  border-radius: 46% 46% 52% 52%;
  color: white;
  font-size: clamp(3rem, 8vw, 5.4rem);
  background: linear-gradient(145deg, #ff8fbd, #ff367e);
  box-shadow: 0 22px 46px rgba(255, 54, 126, 0.34);
  animation: pulse 1.8s ease-in-out infinite;
}

.story {
  overflow: hidden;
}

.story::after {
  position: absolute;
  right: clamp(18px, 5vw, 54px);
  bottom: clamp(12px, 4vw, 34px);
  content: "❄";
  color: rgba(184, 148, 255, 0.28);
  font-size: clamp(4rem, 16vw, 9rem);
  line-height: 1;
}

.story p {
  max-width: 850px;
}

.bear-memory {
  display: grid;
  grid-template-columns: minmax(220px, 0.78fr) minmax(0, 1.22fr);
  gap: clamp(22px, 4vw, 42px);
  align-items: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 16% 24%, rgba(255, 241, 207, 0.7), transparent 16rem),
    rgba(255, 255, 255, 0.78);
}

.bear-memory.no-photo {
  grid-template-columns: 1fr;
}

.bear-memory.no-photo .bear-photo-wrap {
  display: none;
}

.bear-photo-wrap {
  position: relative;
}

.bear-photo-wrap::before {
  position: absolute;
  inset: 14px -12px -14px 12px;
  z-index: -1;
  content: "";
  border-radius: 30px;
  background: linear-gradient(135deg, rgba(255, 126, 182, 0.22), rgba(184, 148, 255, 0.22));
}

.bear-photo {
  display: block;
  width: 100%;
  max-height: 420px;
  border: 9px solid rgba(255, 255, 255, 0.86);
  border-radius: 30px;
  object-fit: cover;
  box-shadow: 0 22px 46px rgba(68, 34, 54, 0.18);
}

.bear-memory h2,
.bear-memory p {
  max-width: 900px;
}

.kiss-memory {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(220px, 0.82fr);
  gap: clamp(22px, 4vw, 42px);
  align-items: center;
  overflow: hidden;
  background:
    radial-gradient(circle at 80% 20%, rgba(255, 126, 182, 0.2), transparent 18rem),
    radial-gradient(circle at 20% 86%, rgba(184, 148, 255, 0.18), transparent 18rem),
    rgba(255, 255, 255, 0.78);
}

.kiss-photo-wrap {
  position: relative;
}

.kiss-photo-wrap::before {
  position: absolute;
  inset: -14px 12px 14px -12px;
  z-index: -1;
  content: "";
  border-radius: 30px;
  background: linear-gradient(135deg, rgba(255, 79, 147, 0.2), rgba(255, 241, 207, 0.72));
}

.kiss-photo {
  display: block;
  width: 100%;
  max-height: 390px;
  border: 9px solid rgba(255, 255, 255, 0.88);
  border-radius: 30px;
  object-fit: cover;
  box-shadow: 0 22px 46px rgba(68, 34, 54, 0.18);
}

.video-story::after {
  content: "▶";
}

.video-link {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 8px;
  border-radius: 999px;
  padding: 15px 22px;
  color: white;
  font-weight: 700;
  text-decoration: none;
  background: linear-gradient(135deg, var(--rose), #ff9b64);
  box-shadow: 0 16px 32px rgba(255, 79, 147, 0.26);
  transition: transform 180ms ease, box-shadow 180ms ease;
}

.video-link:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 38px rgba(255, 79, 147, 0.36);
}

.floating-sticker {
  position: absolute;
  z-index: 2;
  width: clamp(78px, 14vw, 142px);
  height: clamp(78px, 14vw, 142px);
  pointer-events: none;
  filter: drop-shadow(0 16px 24px rgba(197, 86, 138, 0.18));
}

.hero-sticker {
  right: clamp(12px, 4vw, 54px);
  bottom: clamp(16px, 5vw, 66px);
  transform: rotate(8deg);
}

.mini-sticker {
  top: 18px;
  right: 18px;
  width: 72px;
  height: 72px;
  opacity: 0.92;
}

.story-sticker {
  right: clamp(12px, 4vw, 40px);
  top: clamp(16px, 4vw, 34px);
}

.video-sticker {
  transform: rotate(-8deg);
}

.timer-sticker,
.letter-sticker {
  right: clamp(14px, 4vw, 44px);
  top: clamp(14px, 4vw, 34px);
  width: clamp(74px, 12vw, 120px);
  height: clamp(74px, 12vw, 120px);
}

.time-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-top: 26px;
}

.time-grid div {
  padding: 22px 14px;
  border-radius: 24px;
  text-align: center;
  background: rgba(255, 255, 255, 0.62);
}

.time-grid strong {
  display: block;
  margin-bottom: 8px;
  color: var(--rose);
  font-size: clamp(1.6rem, 5vw, 3.1rem);
}

.time-grid span,
.hint {
  color: var(--muted);
}

.hint {
  margin: 18px 0 0;
  font-size: 0.88rem;
}

.letter {
  background:
    linear-gradient(rgba(255, 255, 255, 0.74), rgba(255, 255, 255, 0.74)),
    repeating-linear-gradient(#fff 0 34px, #ffe1ee 35px 36px);
}

.signature {
  margin-bottom: 0;
  color: var(--rose);
  font-family: "Pacifico", cursive;
  font-size: 2rem;
}

.date-invite {
  padding: clamp(18px, 3vw, 26px);
  text-align: center;
  background:
    radial-gradient(circle at 18% 18%, rgba(79, 183, 255, 0.22), transparent 18rem),
    radial-gradient(circle at 86% 24%, rgba(255, 126, 182, 0.26), transparent 18rem),
    rgba(255, 255, 255, 0.78);
  overflow: hidden;
}

.invite-shell {
  max-width: 860px;
  margin: 0 auto;
  border: 1px solid rgba(255, 255, 255, 0.68);
  border-radius: 28px;
  padding: clamp(28px, 5vw, 48px);
  background: rgba(255, 255, 255, 0.54);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.76);
}

.date-invite p {
  max-width: 760px;
  margin-right: auto;
  margin-left: auto;
}

.boat-mark {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 18px;
  border-radius: 999px;
  padding: 11px 18px;
  color: #5a4a83;
  font-size: 0.86rem;
  font-weight: 700;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.82), rgba(235, 246, 255, 0.9));
  box-shadow: 0 12px 28px rgba(79, 183, 255, 0.14);
}

.invite-button {
  position: relative;
  border: 0;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: min(100%, 280px);
  margin-top: 10px;
  padding: 18px 30px;
  color: white;
  font-weight: 700;
  text-decoration: none;
  background: linear-gradient(135deg, #4fb7ff, var(--lavender), var(--rose));
  box-shadow: 0 16px 34px rgba(79, 183, 255, 0.28);
  transition: transform 180ms ease, box-shadow 180ms ease, filter 180ms ease;
  appearance: none;
  -webkit-tap-highlight-color: transparent;
  isolation: isolate;
}

.invite-button::before {
  position: absolute;
  inset: 3px;
  z-index: -1;
  content: "";
  border-radius: inherit;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.28), transparent);
}

.invite-button:hover {
  transform: translateY(-3px) scale(1.02);
  box-shadow: 0 22px 44px rgba(79, 183, 255, 0.38);
  filter: saturate(1.08);
}

.invite-note {
  margin: 14px auto 0;
  font-size: 0.86rem;
  line-height: 1.6;
}

.invite-note.is-copied {
  color: var(--rose);
  font-weight: 700;
}

.sparkles span {
  position: fixed;
  z-index: -1;
  top: -30px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: rgba(255, 126, 182, 0.72);
  animation: fall linear forwards;
}

.modal {
  position: fixed;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 18px;
  background: rgba(68, 34, 54, 0.24);
  opacity: 0;
  pointer-events: none;
  transition: opacity 200ms ease;
}

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

.modal-card {
  width: min(460px, 100%);
  position: relative;
  padding: 34px;
  border-radius: 30px;
  text-align: center;
  background: #fff;
  box-shadow: var(--shadow);
}

.modal-photo {
  display: none;
  width: min(220px, 72vw);
  aspect-ratio: 4 / 5;
  margin: 0 auto 18px;
  border: 8px solid #fff4fa;
  border-radius: 28px;
  object-fit: cover;
  box-shadow: 0 16px 38px rgba(197, 86, 138, 0.24);
}

.modal-photo.is-visible {
  display: block;
}

.modal-kicker {
  min-height: 1.4em;
  margin-bottom: 8px;
  color: var(--rose);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.1em;
  line-height: 1.4;
  text-transform: uppercase;
}

.close {
  position: absolute;
  top: 12px;
  right: 14px;
  border: 0;
  color: var(--muted);
  font-size: 1.8rem;
  background: transparent;
}

@keyframes pulse {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.06); }
}

@keyframes fall {
  to {
    transform: translate3d(var(--drift), 110vh, 0) rotate(360deg);
    opacity: 0;
  }
}

@media (max-width: 780px) {
  main {
    width: min(100% - 22px, 1120px);
    padding-top: 16px;
  }

  .hero {
    min-height: 86vh;
    border-radius: 28px;
  }

  .reasons,
  .memory,
  .bear-memory,
  .kiss-memory,
  .time-grid {
    grid-template-columns: 1fr;
  }

  .memory {
    text-align: center;
  }

  .heart {
    justify-self: center;
  }

  .bear-photo {
    max-height: 360px;
  }

  .kiss-photo-wrap {
    order: -1;
  }

  .kiss-photo {
    max-height: 340px;
  }

  .hero-sticker {
    right: 8px;
    bottom: 8px;
    width: 64px;
    height: 64px;
    opacity: 0.42;
  }

  .story-sticker,
  .timer-sticker,
  .letter-sticker {
    position: relative;
    top: auto;
    right: auto;
    float: right;
    margin: -8px -8px 8px 12px;
    width: 86px;
    height: 86px;
  }
}
