:root {
  --night: #020617;
  --deep: #03122a;
  --ink: #0f2744;
  --ice: #9fd4ff;
  --cream: #eaf6ff;
  --paper: #f4faff;
}

* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: Nunito, system-ui, sans-serif;
  background:
    radial-gradient(circle at 18% 12%, rgba(56, 189, 248, 0.22), transparent 32%),
    radial-gradient(circle at 82% 18%, rgba(37, 99, 235, 0.28), transparent 36%),
    radial-gradient(circle at 50% 80%, rgba(14, 116, 164, 0.2), transparent 42%),
    linear-gradient(180deg, #0b1d4a 0%, var(--deep) 38%, var(--night) 100%);
  color: var(--cream);
  overflow-x: hidden;
}

#stars {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  pointer-events: none;
}

.glow {
  position: fixed;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.42;
  z-index: 0;
  pointer-events: none;
  animation: drift 14s ease-in-out infinite;
}

.glow-a {
  width: 340px;
  height: 340px;
  background: #2563eb;
  top: -70px;
  right: -50px;
}

.glow-b {
  width: 380px;
  height: 380px;
  background: #0ea5e9;
  bottom: 6%;
  left: -90px;
  animation-delay: -5s;
}

.glow-c {
  width: 260px;
  height: 260px;
  background: #1d4ed8;
  top: 42%;
  right: 8%;
  opacity: 0.28;
  animation-delay: -9s;
}

.moon {
  position: fixed;
  top: 13vh;
  right: -22px;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: radial-gradient(circle at 34% 32%, #ffffff, #cfe6ff 58%, #a7cdf5 100%);
  box-shadow:
    0 0 40px rgba(191, 219, 254, 0.5),
    0 0 120px rgba(59, 130, 246, 0.35);
  opacity: 0.55;
  z-index: 0;
  pointer-events: none;
  animation: breathe 9s ease-in-out infinite;
}

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

.hero {
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 48px 24px;
}

.eyebrow {
  letter-spacing: 0.22em;
  text-transform: uppercase;
  font-size: 0.72rem;
  color: var(--ice);
  margin: 0 0 12px;
  animation: fade-in 1.4s ease both;
}

h1 {
  font-family: "Great Vibes", cursive;
  font-size: clamp(3.4rem, 12vw, 7rem);
  margin: 0;
  font-weight: 400;
  color: #f4fbff;
  background: linear-gradient(100deg, #ffffff 20%, #bfdbfe 45%, #ffffff 70%);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  filter: drop-shadow(0 0 26px rgba(125, 211, 252, 0.45));
  animation: shimmer 6s linear infinite;
}

.hero-sub {
  max-width: 28rem;
  line-height: 1.7;
  color: #d7ecff;
  margin: 8px 0 36px;
  animation: fade-in 1.8s ease both;
}

.envelope-btn,
.yes-btn,
.wa-btn,
.modal-card button {
  font-family: inherit;
  cursor: pointer;
  border: 0;
}

.envelope-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: linear-gradient(180deg, #ffffff 0%, #cfe9ff 100%);
  color: #123a66;
  border-radius: 999px;
  padding: 14px 26px;
  font-weight: 700;
  box-shadow:
    0 0 0 1px rgba(147, 197, 253, 0.45),
    0 12px 30px rgba(2, 6, 23, 0.35);
  animation: float 3.2s ease-in-out infinite;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}

.envelope-btn:hover {
  transform: translateY(-3px) scale(1.03);
  box-shadow:
    0 0 0 1px rgba(147, 197, 253, 0.65),
    0 18px 40px rgba(2, 6, 23, 0.45);
}

.seal {
  font-size: 1.2rem;
}

.hint {
  margin-top: 16px;
  font-size: 0.85rem;
  opacity: 0.75;
}

.scroll-cue {
  margin-top: 26px;
  width: 22px;
  height: 36px;
  border: 1px solid rgba(191, 219, 254, 0.5);
  border-radius: 999px;
  display: grid;
  place-items: start center;
  padding-top: 7px;
}

.scroll-cue span {
  width: 3px;
  height: 7px;
  border-radius: 999px;
  background: rgba(191, 219, 254, 0.9);
  animation: cue 1.8s ease-in-out infinite;
}

.letter {
  padding: 12px 18px 90px;
  max-width: 720px;
  margin: 0 auto;
}

.reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity 0.9s ease, transform 0.9s cubic-bezier(0.22, 1, 0.36, 1);
}

.reveal.visible {
  opacity: 1;
  transform: none;
}

.paper {
  position: relative;
  background: linear-gradient(180deg, #f9fcff 0%, #e8f3ff 100%);
  color: var(--ink);
  border-radius: 28px;
  padding: 34px 28px 28px;
  margin-bottom: 22px;
  box-shadow:
    0 0 0 1px rgba(147, 197, 253, 0.3),
    0 30px 80px rgba(2, 6, 23, 0.45);
}

.paper::after {
  content: "";
  position: absolute;
  inset: 10px;
  border-radius: 20px;
  border: 1px solid rgba(147, 197, 253, 0.35);
  pointer-events: none;
}

.from {
  font-family: "Great Vibes", cursive;
  font-size: 1.7rem;
  color: #2563eb;
  margin: 0 0 4px;
}

.paper h2 {
  font-family: "Cormorant Garamond", serif;
  font-size: 1.95rem;
  margin: 0 0 18px;
  color: #0b2c52;
}

.paper p {
  font-family: "Cormorant Garamond", serif;
  font-size: 1.24rem;
  line-height: 1.8;
  margin: 0 0 1em;
}

.dropcap::first-letter {
  font-family: "Great Vibes", cursive;
  font-size: 3.2rem;
  line-height: 0.9;
  float: left;
  padding: 6px 10px 0 0;
  color: #2563eb;
}

.quote {
  margin: 8px 0 24px;
  padding: 24px 22px;
  font-family: "Cormorant Garamond", serif;
  font-size: 1.32rem;
  line-height: 1.75;
  font-style: italic;
  text-align: center;
  color: #eaf6ff;
  border-radius: 24px;
  border: 1px solid rgba(147, 197, 253, 0.32);
  background: rgba(30, 64, 175, 0.16);
  backdrop-filter: blur(10px);
  text-shadow: 0 0 22px rgba(59, 130, 246, 0.35);
}

.divider {
  display: flex;
  align-items: center;
  gap: 14px;
  margin: 6px 0 24px;
  color: var(--ice);
}

.divider i {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(147, 197, 253, 0.6), transparent);
}

.divider span {
  font-size: 0.9rem;
  animation: twinkle 2.6s ease-in-out infinite;
}

.soft {
  background: #e0f0ff;
  border-left: 3px solid #3b82f6;
  padding: 12px 14px;
  border-radius: 0 14px 14px 0;
}

.telugu {
  font-style: italic;
  color: #1d4ed8;
  font-size: 1.36rem !important;
  text-align: center;
}

.ask {
  text-align: center;
  font-weight: 600;
  font-size: 1.44rem !important;
}

.italic-line,
.closing {
  font-style: italic;
}

.closing-paper {
  background: linear-gradient(180deg, #eef6ff 0%, #dceaff 100%);
}

.closing {
  font-size: 1.32rem !important;
  text-align: center;
  margin: 0 !important;
}

.respect-paper {
  text-align: center;
  background: linear-gradient(180deg, #f5f9ff 0%, #e4efff 100%);
}

.respect {
  font-style: italic;
  font-size: 1.28rem !important;
}

.respect.selfish {
  font-family: Caveat, cursive !important;
  font-style: normal;
  font-size: 1.6rem !important;
  color: #1d4ed8;
  margin: 0 !important;
}

.story {
  position: relative;
  display: flex;
  flex-direction: column;
}

.memory {
  order: 2;
  position: relative;
  z-index: 2;
  width: min(260px, 78%);
  margin: 18px auto 34px;
}

.memory-inner {
  position: relative;
  will-change: transform;
}

.polaroid {
  background: #fdfdfb;
  padding: 10px 10px 34px;
  border-radius: 4px;
  box-shadow:
    0 0 0 1px rgba(15, 39, 68, 0.08),
    0 22px 50px rgba(2, 6, 23, 0.55);
  transform: rotate(-2.5deg);
}

.memory-right .polaroid {
  transform: rotate(2.5deg);
}

.polaroid img {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 2px;
}

.sticky-note {
  position: absolute;
  z-index: 3;
  top: -22px;
  right: -26px;
  max-width: 170px;
  margin: 0;
  padding: 14px 14px 12px;
  font-family: Caveat, cursive;
  font-weight: 700;
  font-size: 1.22rem;
  line-height: 1.15;
  color: #3b2a07;
  background: linear-gradient(180deg, #fff6b8 0%, #ffe98a 100%);
  border-radius: 2px 2px 10px 2px;
  box-shadow: 0 10px 22px rgba(2, 6, 23, 0.35);
  transform: rotate(6deg);
}

.sticky-note::before {
  content: "";
  position: absolute;
  top: -9px;
  left: 50%;
  width: 54px;
  height: 18px;
  margin-left: -27px;
  background: rgba(219, 234, 254, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.5);
  transform: rotate(-4deg);
}

.memory-right .sticky-note {
  right: auto;
  left: -26px;
  transform: rotate(-6deg);
}

.memory-song {
  display: block;
  width: 100%;
  height: 38px;
  margin-top: 14px;
  color-scheme: dark;
}

@media (min-width: 1200px) {
  .memory {
    position: absolute;
    top: 40px;
    width: 210px;
    margin: 0;
  }

  .memory-left {
    right: calc(100% + 34px);
  }

  .memory-right {
    left: calc(100% + 34px);
  }
}

.promises-title {
  text-align: center;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  font-size: 0.72rem;
  color: var(--ice);
  margin: 34px 0 14px;
}

.promises {
  list-style: none;
  padding: 0;
  margin: 0 0 34px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.promises li {
  background: rgba(191, 219, 254, 0.1);
  border: 1px solid rgba(147, 197, 253, 0.28);
  border-radius: 18px;
  padding: 18px 12px;
  text-align: center;
  font-size: 0.92rem;
  backdrop-filter: blur(8px);
  transition: transform 0.3s ease, background 0.3s ease, box-shadow 0.3s ease;
}

.promises li:hover {
  transform: translateY(-4px);
  background: rgba(191, 219, 254, 0.18);
  box-shadow: 0 14px 30px rgba(2, 6, 23, 0.4);
}

.promises span {
  display: block;
  font-size: 1.5rem;
  margin-bottom: 8px;
}

.finale {
  text-align: center;
  padding: 16px 8px 8px;
}

.finale-kicker {
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-size: 0.7rem;
  color: var(--ice);
}

.finale h2 {
  font-family: "Cormorant Garamond", serif;
  font-weight: 400;
  font-size: clamp(1.6rem, 5vw, 2.4rem);
  margin: 8px 0 24px;
}

.yes-btn {
  background: linear-gradient(180deg, #dbeafe, #60a5fa);
  color: #082f49;
  font-weight: 800;
  border-radius: 999px;
  padding: 16px 28px;
  font-size: 1rem;
  box-shadow: 0 16px 40px rgba(37, 99, 235, 0.4);
  animation: pulse 2.8s ease-in-out infinite;
  transition: transform 0.25s ease;
}

.yes-btn:hover {
  transform: translateY(-3px) scale(1.04);
}

.tiny {
  opacity: 0.7;
  font-size: 0.8rem;
}

.modal {
  position: fixed;
  inset: 0;
  z-index: 5;
  background: rgba(2, 8, 23, 0.78);
  backdrop-filter: blur(6px);
  display: grid;
  place-items: center;
  padding: 24px;
}

.modal-card {
  background: var(--paper);
  color: var(--ink);
  max-width: 420px;
  border-radius: 24px;
  padding: 28px 24px;
  text-align: center;
  animation: rise 0.45s ease;
  box-shadow: 0 0 60px rgba(56, 189, 248, 0.25);
}

.sparkle {
  margin: 0;
  color: #2563eb;
  letter-spacing: 0.16em;
}

.modal-card h3 {
  font-family: "Cormorant Garamond", serif;
  font-size: 1.7rem;
  margin: 8px 0 12px;
}

.wa-btn {
  display: block;
  margin: 16px 0 4px;
  background: linear-gradient(180deg, #34d399, #059669);
  color: #fff;
  text-decoration: none;
  font-weight: 800;
  border-radius: 999px;
  padding: 13px 18px;
  box-shadow: 0 12px 28px rgba(5, 150, 105, 0.35);
}

.modal-card button {
  margin-top: 8px;
  background: #0b2a4a;
  color: #fff;
  border-radius: 999px;
  padding: 10px 18px;
}

.peek {
  position: fixed;
  right: 12px;
  bottom: 12px;
  z-index: 9;
  background: rgba(2, 8, 23, 0.82);
  border: 1px solid rgba(147, 197, 253, 0.3);
  border-radius: 12px;
  padding: 8px 12px;
  font-size: 0.76rem;
  letter-spacing: 0.04em;
  color: #cfe6ff;
  backdrop-filter: blur(6px);
}

.heart {
  position: fixed;
  z-index: 6;
  pointer-events: none;
  animation: float-up 2.6s ease-out forwards;
  font-size: 1.4rem;
}

@keyframes float {
  0%,
  100% {
    transform: translateY(0);
  }
  50% {
    transform: translateY(-8px);
  }
}

@keyframes drift {
  0%,
  100% {
    transform: translate3d(0, 0, 0);
  }
  50% {
    transform: translate3d(18px, -22px, 0);
  }
}

@keyframes breathe {
  0%,
  100% {
    opacity: 0.45;
  }
  50% {
    opacity: 0.7;
  }
}

@keyframes shimmer {
  to {
    background-position: 200% center;
  }
}

@keyframes twinkle {
  0%,
  100% {
    opacity: 0.4;
  }
  50% {
    opacity: 1;
  }
}

@keyframes cue {
  0% {
    transform: translateY(0);
    opacity: 0;
  }
  35% {
    opacity: 1;
  }
  100% {
    transform: translateY(14px);
    opacity: 0;
  }
}

@keyframes pulse {
  0%,
  100% {
    box-shadow: 0 16px 40px rgba(37, 99, 235, 0.4);
  }
  50% {
    box-shadow: 0 16px 54px rgba(96, 165, 250, 0.7);
  }
}

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes rise {
  from {
    opacity: 0;
    transform: translateY(24px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes float-up {
  to {
    transform: translateY(-90vh) rotate(20deg);
    opacity: 0;
  }
}

@media (max-width: 640px) {
  .promises {
    grid-template-columns: 1fr;
  }

  .paper {
    padding: 28px 22px 24px;
  }

  .moon {
    width: 58px;
    height: 58px;
    opacity: 0.4;
  }

  .dropcap::first-letter {
    font-size: 2.7rem;
  }

  .sticky-note {
    right: -14px;
    font-size: 1.12rem;
  }

  .memory-right .sticky-note {
    left: -14px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
