:root {
  --bg-1: #07111e;
  --bg-2: #122842;
  --accent: #9bd4ff;
  --heart: #ff8fb1;
  --accent-soft: rgba(155, 212, 255, 0.16);
  --text: #f3f9ff;
  --muted: #c2d6eb;
  --glass: rgba(255, 255, 255, 0.06);
  --border: rgba(186, 226, 255, 0.22);
}

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

body {
  min-height: 100vh;
  background: radial-gradient(circle at top, var(--bg-2), var(--bg-1) 72%);
  color: var(--text);
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  overflow-x: hidden;
}

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

.particle {
  position: absolute;
  top: -10vh;
  opacity: 0.75;
  user-select: none;
  animation: fall linear infinite;
}

.particle.snow {
  color: #e3f4ff;
  filter: drop-shadow(0 0 8px rgba(180, 228, 255, 0.5));
}

.particle.heart {
  color: var(--heart);
  filter: drop-shadow(0 0 8px rgba(255, 143, 177, 0.45));
}

@keyframes fall {
  0% { transform: translateY(-10vh) translateX(0) rotate(0deg); opacity: 0; }
  10% { opacity: 0.8; }
  90% { opacity: 0.8; }
  100% { transform: translateY(115vh) translateX(28px) rotate(360deg); opacity: 0; }
}

.envelope-screen {
  position: fixed;
  inset: 0;
  z-index: 10;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.envelope-screen.fade-out {
  opacity: 0;
  transform: scale(1.04);
  pointer-events: none;
}

.envelope-wrap {
  text-align: center;
  cursor: pointer;
}

.envelope {
  width: 220px;
  height: 145px;
  background: linear-gradient(145deg, #163252, #0d1f36);
  border: 1px solid var(--border);
  border-radius: 14px;
  position: relative;
  margin: 0 auto 18px;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
  transition: transform 0.3s ease;
}

.envelope-wrap:hover .envelope {
  transform: translateY(-4px);
}

.flap {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 76px;
  background: linear-gradient(180deg, rgba(155, 212, 255, 0.24), transparent);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  border-top-left-radius: 14px;
  border-top-right-radius: 14px;
}

.seal {
  position: absolute;
  top: 52%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: linear-gradient(135deg, #7cc6ff, #ff8fb1);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 20px;
  box-shadow: 0 0 22px rgba(155, 212, 255, 0.45);
}

.hint {
  font-size: 14px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.hidden {
  display: none;
}

.content {
  position: relative;
  z-index: 1;
  max-width: 680px;
  margin: 0 auto;
  padding: 48px 20px 80px;
  display: grid;
  gap: 24px;
  animation: appear 0.8s ease-out;
}

@keyframes appear {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

.hero {
  text-align: center;
  padding: 12px 0;
}

.badge {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: #cbe9ff;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

h1, h2 {
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-weight: 600;
}

h1 {
  font-size: clamp(36px, 7vw, 52px);
  margin-bottom: 10px;
}

h2 {
  font-size: 28px;
  margin-bottom: 14px;
  color: #dcefff;
}

.subtitle {
  color: var(--muted);
  font-size: 15px;
}

.card {
  background: var(--glass);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 28px 24px;
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  box-shadow: 0 18px 45px rgba(0, 0, 0, 0.35);
}

.letter p {
  line-height: 1.75;
  color: var(--muted);
  font-size: 16px;
}

.signature {
  margin-top: 18px;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-style: italic;
  font-size: 24px;
  color: #ffd1e0 !important;
  text-align: right;
}

.timer-card {
  text-align: center;
}

.timer-line {
  font-size: clamp(18px, 3.6vw, 22px);
  line-height: 1.5;
  color: #ffffff;
  font-weight: 500;
}

.timer-note {
  margin-top: 8px;
  font-size: 13px;
  color: var(--muted);
}

.reasons-hint {
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 16px;
}

.reasons-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.reason-item {
  background: rgba(155, 212, 255, 0.08);
  border: 1px solid rgba(155, 212, 255, 0.25);
  border-radius: 14px;
  padding: 18px 14px;
  text-align: center;
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
  font-size: 14px;
  color: #dcefff;
  min-height: 82px;
  display: grid;
  place-items: center;
}

.reason-item:hover {
  transform: translateY(-2px);
  background: rgba(155, 212, 255, 0.14);
}

.reason-item.revealed {
  background: rgba(255, 255, 255, 0.08);
  border-color: var(--border);
  color: #fff;
}
