/* love2.us — sample recipient card page (Birthday · Cute, M0).
 * Mobile-first, CSS-only art, no autoplay media, no data collection.
 * Confetti is pure CSS/JS shapes; honors prefers-reduced-motion.
 */
.card-page {
  min-height: 100dvh;
  background: linear-gradient(180deg, #ffeef4 0%, #f1ecff 48%, #fff9f0 100%);
  display: flex; flex-direction: column;
  padding-bottom: env(safe-area-inset-bottom);
}
.card-topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 14px 20px;
}
.card-topbar .logo { font-size: 24px; }

/* ---- envelope stage ---- */
.envelope-stage { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 20px; text-align: center; }
.envelope-stage h1 { font-family: var(--font-display); font-weight: 400; font-size: 36px; margin: 6px 0 4px; }
.envelope-stage p { color: var(--ink-soft); margin: 0 0 22px; }
.envelope {
  width: 260px; height: 170px; position: relative; cursor: pointer;
  background: #fff; border-radius: 10px; box-shadow: var(--shadow);
  transition: transform 0.3s ease;
}
.envelope:active { transform: scale(0.97); }
.envelope .flap {
  position: absolute; inset: 0 0 auto 0; height: 90px;
  background: var(--pink); clip-path: polygon(0 0, 100% 0, 50% 100%);
  border-radius: 10px 10px 0 0; transform-origin: top;
  transition: transform 0.6s ease; z-index: 2;
}
.envelope.open .flap { transform: rotateX(180deg); }
.envelope .seal {
  position: absolute; left: 50%; top: 74px; transform: translateX(-50%);
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--pink-ink); color: #fff; font-size: 20px;
  display: flex; align-items: center; justify-content: center; z-index: 3;
}
.envelope .hint { position: absolute; left: 0; right: 0; bottom: 16px; font-size: 13px; color: var(--ink-soft); }

/* ---- revealed card ---- */
.card-reveal { display: none; flex: 1; padding: 8px 20px 24px; text-align: center; }
.card-reveal.show { display: block; }
.balloons { font-size: 44px; letter-spacing: 4px; line-height: 1.1; }
.balloons span { display: inline-block; animation: floaty 3s ease-in-out infinite; }
.balloons span:nth-child(2) { animation-delay: 0.5s; }
.balloons span:nth-child(3) { animation-delay: 1s; }
@keyframes floaty { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
.card-reveal h1 { font-family: var(--font-display); font-weight: 400; font-size: 40px; line-height: 1.2; margin: 8px 0; }
.card-reveal .msg { font-family: var(--font-serif); font-size: 18px; max-width: 36ch; margin: 0 auto 20px; }
.photo-frames { display: flex; gap: 12px; justify-content: center; margin: 0 0 20px; }
.frame {
  width: 96px; height: 120px; border-radius: 12px; background: #fff;
  box-shadow: var(--shadow); display: flex; align-items: center; justify-content: center;
  font-size: 34px; transform: rotate(-3deg);
}
.frame:nth-child(2) { transform: rotate(2deg); background: linear-gradient(160deg, #f1ecff, #fff); }
.frame:nth-child(3) { transform: rotate(-1deg); background: linear-gradient(160deg, #eef6ee, #fff); }
.signature { font-family: var(--font-display); font-size: 26px; color: var(--pink-ink); margin: 0 0 24px; }

/* share */
.share-box { background: rgba(255, 255, 255, 0.75); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow); }
.share-box h3 { margin: 0 0 10px; font-size: 17px; }
.link-chip {
  display: inline-block; background: #fff; border: 1.5px dashed var(--gold);
  border-radius: 999px; padding: 8px 16px; font-weight: 700; margin-bottom: 14px;
}
.share-row { display: flex; gap: 10px; justify-content: center; flex-wrap: wrap; }
.share-row .btn { min-width: 140px; }
.copied-msg { font-size: 14px; color: var(--sage-deep); font-weight: 700; min-height: 20px; margin: 10px 0 0; }

/* confetti pieces */
.confetti { position: fixed; inset: 0; pointer-events: none; overflow: hidden; z-index: 5; }
.confetti i {
  position: absolute; top: -16px; width: 10px; height: 14px; border-radius: 2px;
  animation: fall linear forwards;
}
@keyframes fall { to { transform: translateY(105vh) rotate(720deg); opacity: 0.2; } }

.card-footer { text-align: center; padding: 18px 20px calc(20px + env(safe-area-inset-bottom)); color: var(--ink-soft); font-size: 13px; }
.card-footer a { color: var(--pink-ink); font-weight: 700; text-decoration: none; }

@media (prefers-reduced-motion: reduce) {
  .balloons span, .confetti i { animation: none !important; }
  .envelope .flap { transition: none; }
}
