:root {
  --maroon-dark: #2b0a12;
  --maroon: #4a0e1e;
  --maroon-light: #6d1a30;
  --gold: #d4af37;
  --gold-light: #f3e3a3;
  --cream: #fdf6e9;
  --text-light: #f6ead0;
  --shadow: rgba(0, 0, 0, 0.4);
  --font-display: 'Playfair Display', serif;
  --font-script: 'Great Vibes', cursive;
  --font-body: 'Cormorant Garamond', serif;
}

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

html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: linear-gradient(180deg, var(--maroon-dark), var(--maroon) 40%, var(--maroon-dark));
  color: var(--text-light);
  overflow-x: hidden;
  font-size: 18px;
  position: relative;
}

body::before {
  content: '';
  position: fixed;
  inset: -10% -10%;
  z-index: 0;
  pointer-events: none;
  will-change: transform;
  transform: translateY(calc(var(--parallax-offset, 0px) * -1));
  background-image:
    radial-gradient(circle at 20% 15%, rgba(212, 175, 55, 0.07), transparent 35%),
    radial-gradient(circle at 82% 30%, rgba(212, 175, 55, 0.06), transparent 40%),
    radial-gradient(circle at 30% 85%, rgba(212, 175, 55, 0.05), transparent 40%);
}

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

/* Classic ornate outer frame */
.page-frame {
  position: fixed;
  inset: 10px;
  z-index: 500;
  pointer-events: none;
  border: 1px solid rgba(212, 175, 55, 0.35);
  box-shadow: inset 0 0 0 5px rgba(43, 10, 18, 0.85), inset 0 0 0 6px rgba(212, 175, 55, 0.25);
}
.frame-corner {
  position: fixed;
  font-size: 1.4rem;
  color: var(--gold);
  opacity: 0.7;
  z-index: 501;
}
.frame-corner.tl { top: 14px; left: 14px; }
.frame-corner.tr { top: 14px; right: 14px; transform: rotate(90deg); }
.frame-corner.bl { bottom: 14px; left: 14px; transform: rotate(-90deg); }
.frame-corner.br { bottom: 14px; right: 14px; transform: rotate(180deg); }
@media (max-width: 700px) { .page-frame, .frame-corner { display: none; } }

/* Envelope opening intro */
html.intro-active, html.intro-active body { overflow: hidden; height: 100%; }

#envelopeIntro {
  position: fixed; inset: 0; z-index: 999;
  background: radial-gradient(ellipse at center, var(--maroon-light) 0%, var(--maroon-dark) 80%);
  display: flex; align-items: center; justify-content: center;
  padding: 1.5rem;
  transition: opacity 0.8s ease, visibility 0.8s ease;
  overflow: hidden;
}
#envelopeIntro.hidden { opacity: 0; visibility: hidden; pointer-events: none; }

.intro-petals { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.intro-petals .petal { position: absolute; top: -10%; color: var(--gold); opacity: 0.45; font-size: 1.1rem; animation: drift 14s linear infinite; }
.intro-petals .p1 { left: 12%; animation-duration: 12s; }
.intro-petals .p2 { left: 38%; animation-duration: 17s; animation-delay: 2s; font-size: 0.8rem; }
.intro-petals .p3 { left: 64%; animation-duration: 13s; animation-delay: 4s; }
.intro-petals .p4 { left: 85%; animation-duration: 16s; animation-delay: 1s; }

.envelope-scene { display: flex; flex-direction: column; align-items: center; gap: 1.6rem; }

.envelope {
  position: relative;
  width: 280px; height: 190px;
  background: none; border: none; padding: 0;
  perspective: 900px;
  cursor: pointer;
}
.envelope-pocket-back {
  position: absolute; inset: 0;
  background: linear-gradient(135deg, var(--maroon-light), var(--maroon-dark));
  border: 1px solid var(--gold);
  border-radius: 6px;
  z-index: 1;
}
.letter {
  position: absolute;
  left: 6%; right: 6%; top: 6%; height: 88%;
  background: var(--cream);
  color: var(--maroon-dark);
  border-radius: 3px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
  z-index: 2;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 0.35rem;
  padding: 1rem;
  transform: translateY(0);
  transition: transform 1s cubic-bezier(0.4, 0, 0.2, 1) 0.4s, box-shadow 0.6s ease 0.4s;
}
.letter-monogram { font-family: var(--font-display); font-size: 1.2rem; letter-spacing: 1px; color: var(--maroon); }
.letter-monogram .amp { font-family: var(--font-script); color: var(--gold); margin: 0 0.1em; }
.letter-line { font-family: var(--font-script); font-size: 1.6rem; color: var(--maroon-light); }
.letter-sub { font-family: var(--font-display); font-size: 0.8rem; letter-spacing: 2px; text-transform: uppercase; color: var(--gold); opacity: 0.8; }
.envelope-pocket-front {
  position: absolute;
  left: 0; right: 0; bottom: 0; height: 62%;
  background: linear-gradient(180deg, var(--maroon-light), var(--maroon-dark));
  clip-path: polygon(0 100%, 0 22%, 50% 58%, 100% 22%, 100% 100%);
  border: 1px solid var(--gold);
  border-top: none;
  z-index: 3;
}
.envelope-flap {
  position: absolute;
  top: 0; left: 0; right: 0; height: 58%;
  background: linear-gradient(180deg, var(--maroon-light), var(--maroon));
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  border: 1px solid var(--gold);
  transform-origin: top center;
  transform: rotateX(0deg);
  transition: transform 0.9s ease;
  backface-visibility: hidden;
  z-index: 4;
}
.seal {
  position: absolute;
  top: 42%; left: 50%;
  transform: translate(-50%, -50%);
  width: 40px; height: 40px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, var(--gold-light), var(--gold) 70%);
  color: var(--maroon-dark);
  font-family: var(--font-display);
  font-size: 0.7rem;
  font-weight: 700;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.4);
  z-index: 5;
  transition: opacity 0.4s ease, transform 0.4s ease;
}
.envelope.open .envelope-flap { transform: rotateX(-180deg); }
.envelope.open .seal { opacity: 0; transform: translate(-50%, -50%) scale(0.4); }
.envelope.open .letter { transform: translateY(-42%) scale(1.04); box-shadow: 0 14px 34px rgba(0, 0, 0, 0.5); }
.envelope.open { pointer-events: none; }

.tap-hint {
  font-family: var(--font-display);
  color: var(--gold-light);
  letter-spacing: 1.5px;
  font-size: 0.9rem;
  text-transform: uppercase;
  text-align: center;
  max-width: 280px;
  padding: 0 1rem;
  opacity: 0.85;
  animation: hintPulse 2.4s ease-in-out infinite;
}
.tap-hint.fade-out { opacity: 0; transition: opacity 0.4s ease; }
@keyframes hintPulse { 0%, 100% { opacity: 0.55; } 50% { opacity: 1; } }

/* Music toggle */
.music-toggle {
  position: fixed;
  left: 1.2rem; bottom: 1.2rem;
  z-index: 1000;
  width: 46px; height: 46px;
  border-radius: 50%;
  border: 1px solid var(--gold);
  background: rgba(43, 10, 18, 0.85);
  cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.music-toggle:hover { transform: translateY(-2px); box-shadow: 0 8px 22px rgba(0, 0, 0, 0.5); }
.music-bars { display: flex; align-items: flex-end; gap: 3px; height: 16px; }
.music-bars span {
  width: 3px;
  background: var(--gold);
  border-radius: 1px;
  height: 6px;
  animation-play-state: paused;
}
.music-bars span:nth-child(1) { animation: bar1 0.9s ease-in-out infinite; }
.music-bars span:nth-child(2) { animation: bar2 0.9s ease-in-out infinite 0.2s; }
.music-bars span:nth-child(3) { animation: bar3 0.9s ease-in-out infinite 0.4s; }
.music-toggle.playing .music-bars span { animation-play-state: running; }
.music-toggle:not(.playing) .music-bars span { height: 6px; }
@keyframes bar1 { 0%, 100% { height: 6px; } 50% { height: 16px; } }
@keyframes bar2 { 0%, 100% { height: 10px; } 50% { height: 4px; } }
@keyframes bar3 { 0%, 100% { height: 5px; } 50% { height: 14px; } }
@media (max-width: 700px) { .music-toggle { left: 0.8rem; bottom: 0.8rem; width: 40px; height: 40px; } }

/* Dot nav */
#dotNav {
  position: fixed; right: 1.2rem; top: 50%; transform: translateY(-50%);
  display: flex; flex-direction: column; gap: 0.7rem; z-index: 100;
}
#dotNav .dot {
  width: 10px; height: 10px; border-radius: 50%;
  background: rgba(243, 227, 163, 0.35);
  border: 1px solid var(--gold-light);
  position: relative;
  transition: background 0.3s, transform 0.3s;
}
#dotNav .dot.active, #dotNav .dot:hover { background: var(--gold); transform: scale(1.3); }
#dotNav .dot::after {
  content: attr(data-label);
  position: absolute; right: 20px; top: 50%; transform: translateY(-50%);
  font-family: var(--font-display); font-size: 0.7rem; white-space: nowrap;
  color: var(--gold-light); opacity: 0; transition: opacity 0.2s;
  pointer-events: none;
}
#dotNav .dot:hover::after { opacity: 1; }
@media (max-width: 700px) { #dotNav { display: none; } }

/* Sections */
.section {
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: 5rem 1.5rem;
  position: relative;
  border-bottom: 1px solid rgba(212, 175, 55, 0.12);
}
.section:last-of-type { border-bottom: none; }

.section-title {
  font-family: var(--font-display);
  color: var(--gold-light);
  font-size: 1.7rem;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  margin-bottom: 3rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.2rem;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
}
.section-title::before, .section-title::after {
  content: '';
  flex: 0 0 auto;
  width: 55px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold));
}
.section-title::after { background: linear-gradient(90deg, var(--gold), transparent); }

/* Hero */
.hero { position: relative; }
.ornament {
  width: 220px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold), transparent);
  position: relative;
  opacity: 0.85;
}
.ornament::after {
  content: '\2756';
  position: absolute;
  left: 50%; top: 50%;
  transform: translate(-50%, -50%);
  background: var(--maroon-dark);
  padding: 0 14px;
  color: var(--gold);
  font-size: 0.9rem;
}
.ornament.top { margin-bottom: 2rem; }
.ornament.bottom { margin-top: 2rem; }
.eyebrow {
  font-family: var(--font-script);
  font-size: 2rem;
  color: var(--gold-light);
  letter-spacing: 1px;
}
.names {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 8vw, 5.5rem);
  font-weight: 700;
  letter-spacing: 2px;
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1.2rem;
  background: linear-gradient(120deg, var(--gold) 25%, var(--gold-light) 50%, var(--gold) 75%);
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: shine 7s ease-in-out infinite;
  filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.35));
}
@keyframes shine { 0% { background-position: 0% center; } 50% { background-position: 100% center; } 100% { background-position: 0% center; } }
.names .amp { font-family: var(--font-script); font-size: 0.55em; color: var(--gold-light); -webkit-background-clip: initial; background-clip: initial; background: none; }
.tagline {
  max-width: 480px;
  color: var(--text-light);
  font-style: italic;
  margin-top: 1.2rem;
  font-size: 1.2rem;
  letter-spacing: 0.3px;
}
.hero-date {
  margin-top: 2rem;
  display: flex; flex-direction: column; gap: 0.3rem;
  font-family: var(--font-display);
}
.hero-date .bismillah {
  font-family: 'Aref Ruqaa', serif;
  font-size: 1.8rem;
  line-height: 1.2;
  color: var(--gold-light);
  margin-bottom: 0.3rem;
}
.hero-date .day { color: var(--gold-light); letter-spacing: 3px; text-transform: uppercase; font-size: 0.9rem; }
.hero-date .full-date { font-size: 1.6rem; color: var(--gold); }
.hero-date .time { color: var(--text-light); }

/* Monogram seal */
.monogram {
  width: 78px; height: 78px;
  border-radius: 50%;
  border: 1px solid var(--gold);
  box-shadow: 0 0 0 5px rgba(212, 175, 55, 0.12), inset 0 0 15px rgba(212, 175, 55, 0.2);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display);
  font-size: 1.4rem;
  letter-spacing: 1px;
  color: var(--gold);
  margin-bottom: 1.6rem;
}
.monogram .amp { font-family: var(--font-script); font-size: 1.1em; color: var(--gold-light); margin: 0 0.15em; }

/* Floating petals: fixed overlay so it drifts behind every section */
.petals { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.petal {
  position: absolute;
  top: -10%;
  color: var(--gold);
  opacity: 0.5;
  font-size: 1.1rem;
  animation: drift 14s linear infinite;
}
.petal.p1 { left: 8%; animation-duration: 12s; animation-delay: 0s; }
.petal.p2 { left: 28%; animation-duration: 16s; animation-delay: 2s; font-size: 0.8rem; }
.petal.p3 { left: 52%; animation-duration: 13s; animation-delay: 4s; }
.petal.p4 { left: 72%; animation-duration: 18s; animation-delay: 1s; font-size: 0.9rem; }
.petal.p5 { left: 90%; animation-duration: 15s; animation-delay: 3s; }
@keyframes drift {
  0% { transform: translateY(-10vh) rotate(0deg); opacity: 0; }
  10% { opacity: 0.6; }
  90% { opacity: 0.5; }
  100% { transform: translateY(110vh) rotate(360deg); opacity: 0; }
}

/* Hero staggered entrance */
.hero .monogram, .hero .ornament.top, .hero .eyebrow, .hero .names,
.hero .tagline, .hero .hero-date, .hero .scroll-cue, .hero .ornament.bottom {
  opacity: 0;
  transform: translateY(24px);
}
.hero.visible .monogram { animation: fadeUp 0.9s ease forwards 0.1s; }
.hero.visible .ornament.top { animation: fadeUp 0.9s ease forwards 0.3s; }
.hero.visible .eyebrow { animation: fadeUp 0.9s ease forwards 0.5s; }
.hero.visible .names { animation: fadeUp 0.9s ease forwards 0.7s; }
.hero.visible .tagline { animation: fadeUp 0.9s ease forwards 0.9s; }
.hero.visible .hero-date { animation: fadeUp 0.9s ease forwards 1.1s; }
.hero.visible .scroll-cue { animation: fadeUp 0.9s ease forwards 1.3s; }
.hero.visible .ornament.bottom { animation: fadeUp 0.9s ease forwards 1.5s; }
@keyframes fadeUp { to { opacity: 1; transform: translateY(0); } }

.btn-outline, .btn-solid {
  font-family: var(--font-display);
  display: inline-block;
  margin-top: 2rem;
  padding: 0.8rem 2.2rem;
  border-radius: 30px;
  text-decoration: none;
  cursor: pointer;
  font-size: 0.95rem;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  transition: transform 0.35s ease, background 0.35s ease, color 0.35s ease, letter-spacing 0.35s ease, box-shadow 0.35s ease;
}
.btn-outline { border: 1px solid var(--gold); color: var(--gold-light); background: transparent; }
.btn-outline:hover { background: var(--gold); color: var(--maroon-dark); transform: translateY(-3px); letter-spacing: 2.5px; box-shadow: 0 10px 25px rgba(212, 175, 55, 0.25); }
.btn-solid { border: none; background: var(--gold); color: var(--maroon-dark); font-weight: 600; }
.btn-solid:hover { background: var(--gold-light); transform: translateY(-3px); letter-spacing: 2.5px; box-shadow: 0 10px 25px rgba(212, 175, 55, 0.25); }

/* Scroll cue */
.scroll-cue {
  margin-top: 2.4rem;
  display: flex; flex-direction: column; align-items: center; gap: 0.6rem;
  text-decoration: none;
  color: var(--gold-light);
}
.scroll-cue-mouse {
  width: 24px; height: 38px;
  border: 2px solid var(--gold);
  border-radius: 14px;
  display: flex; justify-content: center;
  padding-top: 6px;
}
.scroll-cue-wheel {
  width: 3px; height: 8px;
  border-radius: 2px;
  background: var(--gold);
  animation: scrollWheel 1.6s ease-in-out infinite;
}
@keyframes scrollWheel {
  0% { opacity: 1; transform: translateY(0); }
  70% { opacity: 0; transform: translateY(10px); }
  100% { opacity: 0; transform: translateY(10px); }
}
.scroll-cue-text {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 3px;
  text-transform: uppercase;
  opacity: 0.85;
}

/* Couple */
.couple-grid {
  display: flex; align-items: center; justify-content: center; gap: 2.5rem;
  flex-wrap: wrap;
  margin-bottom: 2.5rem;
}
.couple-card {
  background: rgba(212, 175, 55, 0.05);
  border: 1px solid rgba(212, 175, 55, 0.4);
  border-radius: 4px;
  padding: 2.2rem 2.2rem;
  width: 240px;
  position: relative;
  transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}
.couple-card:hover { transform: translateY(-8px); box-shadow: 0 16px 32px rgba(0, 0, 0, 0.35); border-color: var(--gold); }
.portrait {
  width: 90px; height: 90px;
  border-radius: 50%;
  border: 1px solid var(--gold);
  margin: 0 auto 1.2rem;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display);
  font-size: 1.6rem;
  letter-spacing: 1px;
  color: var(--gold);
  background: linear-gradient(135deg, rgba(212, 175, 55, 0.15), transparent);
  box-shadow: 0 0 0 5px rgba(212, 175, 55, 0.12), inset 0 0 18px rgba(212, 175, 55, 0.15);
}
.couple-card h3 { font-family: var(--font-display); color: var(--gold-light); font-size: 1.9rem; letter-spacing: 1px; }
.couple-card .rel { margin-top: 0.5rem; }
.couple-and { font-family: var(--font-script); font-size: 3.2rem; color: var(--gold); }
.blessing { max-width: 600px; font-style: italic; line-height: 1.8; color: var(--text-light); }

/* Corner-frame accents for card elements */
.couple-card::before, .couple-card::after,
.venue-card::before, .venue-card::after {
  content: '';
  position: absolute;
  width: 16px; height: 16px;
  border-color: var(--gold);
  opacity: 0.75;
  transition: opacity 0.4s ease;
}
.couple-card::before, .venue-card::before {
  top: -1px; left: -1px;
  border-top: 2px solid var(--gold);
  border-left: 2px solid var(--gold);
}
.couple-card::after, .venue-card::after {
  bottom: -1px; right: -1px;
  border-bottom: 2px solid var(--gold);
  border-right: 2px solid var(--gold);
}
.couple-card:hover::before, .couple-card:hover::after,
.venue-card:hover::before, .venue-card:hover::after { opacity: 1; }

/* Scratch */
.hint { color: rgba(246, 234, 208, 0.65); margin-bottom: 1.8rem; font-style: italic; letter-spacing: 0.3px; }
.scratch-wrap {
  position: relative;
  width: 320px; height: 320px;
  border-radius: 4px;
  overflow: hidden;
  border: 1px solid rgba(212, 175, 55, 0.5);
  box-shadow: 0 0 40px rgba(0, 0, 0, 0.45), 0 0 0 6px rgba(212, 175, 55, 0.08);
}
.scratch-reveal-content {
  position: absolute; inset: 0;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--maroon-light), var(--maroon-dark));
  z-index: 0;
}
.reveal-text { font-family: var(--font-script); font-size: 2.4rem; color: var(--gold-light); }
.reveal-sub { font-family: var(--font-display); color: var(--gold); margin-top: 0.6rem; letter-spacing: 2px; }
#scratchCanvas { position: absolute; inset: 0; z-index: 1; cursor: grab; touch-action: none; transition: opacity 0.5s ease 0.2s; }
#scratchCanvas.cleared { opacity: 0; pointer-events: none; }

/* Celebration confetti burst */
.confetti-piece {
  position: absolute;
  top: 50%; left: 50%;
  width: 8px; height: 8px;
  border-radius: 2px;
  z-index: 2;
  pointer-events: none;
  animation: confettiBurst 1s ease-out forwards;
}
@keyframes confettiBurst {
  0% { transform: translate(-50%, -50%) rotate(0deg); opacity: 1; }
  100% { transform: translate(calc(-50% + var(--tx)), calc(-50% + var(--ty))) rotate(var(--rot)); opacity: 0; }
}

/* Countdown */
.countdown { display: flex; gap: 1.4rem; flex-wrap: wrap; justify-content: center; }
.cd-box {
  background: rgba(212, 175, 55, 0.06);
  border: 1px solid rgba(212, 175, 55, 0.5);
  border-radius: 4px;
  width: 92px; height: 92px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  box-shadow: inset 0 0 20px rgba(212, 175, 55, 0.06);
}
.cd-box span { font-family: var(--font-display); font-size: 2rem; color: var(--gold); }
.cd-box small { text-transform: uppercase; letter-spacing: 1.5px; font-size: 0.68rem; color: rgba(246, 234, 208, 0.8); margin-top: 0.2rem; }

/* Timeline */
.timeline { display: flex; flex-direction: column; gap: 2.2rem; max-width: 500px; width: 100%; }
.tl-item {
  border-left: 1px solid rgba(212, 175, 55, 0.5);
  padding-left: 1.8rem;
  text-align: left;
  position: relative;
}
.tl-dot {
  position: absolute; left: -6px; top: 4px;
  width: 11px; height: 11px; border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 0 4px rgba(212, 175, 55, 0.15);
}
.tl-item h4 { font-family: var(--font-display); color: var(--gold-light); font-size: 1.3rem; letter-spacing: 0.5px; }
.tl-date { color: var(--gold); font-size: 0.92rem; margin: 0.3rem 0; letter-spacing: 0.5px; }
.tl-desc { color: var(--text-light); }

/* Venue / dress */
.program-venue-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 3rem; align-items: start; width: min(900px, 100%); }
.program-venue-column { min-width: 0; }
.program-venue-heading { margin: 0 0 1.4rem; font-family: var(--font-display); color: var(--gold-light); font-size: 1.3rem; }
.venue-card {
  border: 1px solid rgba(212, 175, 55, 0.4);
  border-radius: 4px;
  padding: 2.2rem;
  max-width: 420px;
  margin: 0 auto;
  position: relative;
  transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}
.venue-card:hover { transform: translateY(-8px); box-shadow: 0 16px 32px rgba(0, 0, 0, 0.35); border-color: var(--gold); }
.venue-card h3 { font-family: var(--font-display); color: var(--gold-light); font-size: 1.7rem; letter-spacing: 1px; margin-bottom: 0.6rem; }
.program-venue-column .venue-card + .venue-card { margin-top: 1.25rem; }

@media (max-width: 700px) {
  .program-venue-grid { grid-template-columns: 1fr; gap: 2.5rem; }
}

/* Footer */
.footer {
  text-align: center;
  padding: 3.5rem 1rem 2.5rem;
  color: var(--gold-light);
  font-family: var(--font-script);
  font-size: 1.8rem;
  border-top: 1px solid rgba(212, 175, 55, 0.3);
}
.footer-note { font-family: var(--font-body); font-size: 0.85rem; color: rgba(246, 234, 208, 0.55); margin-top: 0.6rem; letter-spacing: 0.5px; font-style: italic; }

/* Reveal-on-scroll animation */
.section {
  opacity: 0;
  transform: translateY(45px) scale(0.97);
  filter: blur(4px);
  transition: opacity 1s cubic-bezier(0.16, 1, 0.3, 1), transform 1s cubic-bezier(0.16, 1, 0.3, 1), filter 1s ease;
}
.section.visible { opacity: 1; transform: translateY(0) scale(1); filter: blur(0); }

/* Staggered card entrance */
.couple-card, .cd-box {
  opacity: 0;
  transform: translateY(24px);
}
.section.visible .couple-card,
.section.visible .cd-box {
  opacity: 1;
  transform: translateY(0);
  transition: opacity 0.6s ease, transform 0.6s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}
.section.visible .couple-card:nth-child(1),
.section.visible .cd-box:nth-child(1) { transition-delay: 0.05s; }
.section.visible .couple-card:nth-child(2),
.section.visible .cd-box:nth-child(2) { transition-delay: 0.2s; }
.section.visible .couple-card:nth-child(3), .section.visible .cd-box:nth-child(3) { transition-delay: 0.35s; }
.section.visible .cd-box:nth-child(4) { transition-delay: 0.5s; }

/* Staggered timeline entrance */
.tl-item { opacity: 0; transform: translateX(-24px); }
.section.visible .tl-item {
  opacity: 1;
  transform: translateX(0);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.section.visible .tl-item:nth-child(1) { transition-delay: 0.1s; }
.section.visible .tl-item:nth-child(2) { transition-delay: 0.3s; }
.section.visible .tl-item:nth-child(3) { transition-delay: 0.5s; }

/* Countdown digit pulse on change */
@keyframes pulseDigit {
  0% { transform: scale(1); color: var(--gold); }
  40% { transform: scale(1.25); color: var(--gold-light); }
  100% { transform: scale(1); color: var(--gold); }
}
.cd-box span.pulse { animation: pulseDigit 0.5s ease; }

@media (max-width: 500px) {
  .scratch-wrap { width: 260px; height: 260px; }
  #scratchCanvas { width: 260px; height: 260px; }
}

@media (max-width: 480px) {
  .section { padding: 3.5rem 1.2rem; }
  .names { gap: 0.5rem 0.9rem; letter-spacing: 1px; }
  .ornament { width: 150px; }
  .ornament::after { font-size: 0.75rem; padding: 0 10px; }
  .monogram { width: 62px; height: 62px; font-size: 1.1rem; margin-bottom: 1.2rem; }
  .eyebrow { font-size: 1.6rem; }
  .tagline { font-size: 1.05rem; }
  .hero-date .full-date { font-size: 1.3rem; }

  .envelope { width: 230px; height: 158px; }
  .letter-monogram { font-size: 1rem; }
  .letter-line { font-size: 1.3rem; }
  .letter-sub { font-size: 0.7rem; }
  .seal { width: 32px; height: 32px; font-size: 0.6rem; }

  .couple-grid { flex-direction: column; }
  .couple-card { width: 100%; max-width: 260px; padding: 1.8rem 1.6rem; }
  .couple-and { font-size: 2.2rem; }

  .countdown { gap: 0.9rem; }
  .cd-box { width: 74px; height: 74px; }
  .cd-box span { font-size: 1.6rem; }

  .venue-card { padding: 1.6rem; }
  .btn-outline, .btn-solid { padding: 0.7rem 1.7rem; font-size: 0.85rem; }
  .section-title { font-size: 1.35rem; gap: 0.8rem; }
  .section-title::before, .section-title::after { width: 32px; }
}

