/* ==========================================================
   WEDDING INVITATION THEME: MODERN WHITE & BLUSH PINK
   Groom: Trọng Tiến · Bride: Thu Hương
   Aesthetic: Luxury Romance · Minimalist Elegance · Pearlescent White & Rose Gold
   ========================================================== */

:root {
  --font-great-vibes: 'Great Vibes', cursive;
  --font-g4-lora: 'Lora', Georgia, serif;
  --font-inter: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;

  /* Modern White & Pink Romance Palette */
  --pink-primary: #E07A8B;
  --pink-primary-raw: 224, 122, 139;
  --pink-deep: #C85A70;
  --pink-deep-raw: 200, 90, 112;
  --pink-soft: #FFF0F5;
  --pink-blush: #FCE7EC;
  --pink-mist: #FFF5F7;
  --pink-border: rgba(224, 122, 139, 0.25);
  --pink-glow: rgba(224, 122, 139, 0.18);
  
  --rose-gold: #DDA7A5;
  --rose-gold-light: #F5D6D8;
  --rose-gold-dark: #B76E79;
  
  --paper: #FFFFFF;
  --paper-cream: #FFFBFD;
  --ink-dark: #2D2424;
  --ink-body: #4A3E3D;
  --ink-muted: #7E6E71;

  /* Graceful-04 Template Overrides */
  --color-primary: #E07A8B !important;
  --color-primary-raw: 224, 122, 139 !important;
  --paper: #FFFFFF !important;
  --ink: #2D2424 !important;
  --g4r-ink-accent: #C85A70 !important;
  --g4r-ink-accent-raw: 200, 90, 112 !important;
  --g4r-ink-body: #4A3E3D !important;
  --g4r-ink-body-raw: 74, 62, 61 !important;
}

body {
  margin: 0;
  padding: 0;
  background-color: #FFF9FA !important;
  background-image: 
    radial-gradient(at 0% 0%, rgba(254, 226, 235, 0.5) 0px, transparent 50%),
    radial-gradient(at 100% 100%, rgba(252, 231, 243, 0.6) 0px, transparent 50%) !important;
  color: var(--ink-body);
  font-family: var(--font-inter);
  overflow-x: hidden;
  min-height: 100vh;
}

.styles-module__WlSJYG__root {
  background-color: #FFF9FA !important;
  background-image: none !important;
  color: var(--ink-body) !important;
}

/* Ambient Canvas Particle */
#particle-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 40;
}

/* Card wrapper: 100% on mobile, modern centered card on desktop */
.styles-module__WlSJYG__card-wrapper {
  width: 100% !important;
  max-width: 480px !important;
  margin: 0 auto !important;
  background-color: #FFFFFF !important;
  box-shadow: 0 10px 40px var(--pink-glow), 0 0 0 1px var(--pink-border) !important;
  overflow: hidden !important;
}

@media (min-width: 768px) {
  .styles-module__WlSJYG__card-wrapper {
    margin: 36px auto !important;
    border-radius: 20px !important;
    box-shadow: 0 25px 70px rgba(224, 122, 139, 0.16), 0 0 0 1px rgba(224, 122, 139, 0.22) !important;
  }
}

/* Hide old sliding curtains in favor of interactive 3D envelope */
.styles-module__WlSJYG__opening-sides {
  display: none !important;
}

/* Keep inner content neatly centered and compact */
.styles-module__WlSJYG__card-banner-inner,
.styles-module__WlSJYG__card-countdown-inner,
.styles-module__WlSJYG__card-info-inner,
.styles-module__WlSJYG__card-love-story-inner,
.love-story-milestones,
.styles-module__WlSJYG__card-gallery,
.styles-module__WlSJYG__calendar-inner,
.styles-module__WlSJYG__timeline-inner,
.styles-module__WlSJYG__comments-section .styles-module__WlSJYG__inner,
.styles-module__WlSJYG__rsvp-inner,
.styles-module__WlSJYG__gift-section .styles-module__WlSJYG__inner,
.styles-module__WlSJYG__footer-content {
  max-width: 500px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  width: 100% !important;
  box-sizing: border-box !important;
}

/* Clean white background for all sections */
.styles-module__WlSJYG__card-countdown,
.styles-module__WlSJYG__card-info,
.styles-module__WlSJYG__card-love-story,
.styles-module__WlSJYG__card-calendar,
.styles-module__WlSJYG__card-gift,
.styles-module__WlSJYG__card-comments,
.styles-module__WlSJYG__rsvp-section {
  background-color: #FFFFFF !important;
}

/* Soften vintage paper background textures into light airy accents */
.styles-module__WlSJYG__card-countdown:before,
.styles-module__WlSJYG__card-info:before,
.styles-module__WlSJYG__card-info:after,
.styles-module__WlSJYG__card-comments:after {
  opacity: 0.2 !important;
  background-position: center top !important;
}

/* Full-width banners with subtle modern rose-tinted gradient overlays */
.styles-module__WlSJYG__hero-section {
  background-size: cover !important;
  background-position: center 30% !important;
  width: 100% !important;
  position: relative;
}

.styles-module__WlSJYG__hero-overlay {
  display: block !important;
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(224, 122, 139, 0.12) 0%, rgba(45, 36, 36, 0.45) 100%);
  z-index: 0;
}

.styles-module__WlSJYG__wedding-text {
  text-shadow: 0 2px 14px rgba(200, 90, 112, 0.4) !important;
}

.styles-module__WlSJYG__hero-tagline {
  color: #FFE4E9 !important;
  letter-spacing: 0.1em;
  font-size: 14.5px;
  font-weight: 400;
  margin: 0 0 10px;
}

.styles-module__WlSJYG__save-date-section {
  background-size: cover !important;
  background-position: center !important;
  width: 100% !important;
  position: relative;
}

.styles-module__WlSJYG__save-date-shade {
  display: block !important;
  position: absolute;
  inset: 0;
  background: rgba(45, 36, 36, 0.35);
}

.styles-module__WlSJYG__timeline-section {
  background-size: cover !important;
  background-position: center !important;
  width: 100% !important;
  position: relative;
}

.styles-module__WlSJYG__timeline-shade {
  display: block !important;
  position: absolute;
  inset: 0;
  background: rgba(45, 36, 36, 0.55);
}

.styles-module__WlSJYG__app-footer {
  width: 100% !important;
}

.styles-module__WlSJYG__app-footer img {
  object-fit: cover !important;
}

/* ==========================================================
   MODERN 3D ENVELOPE: WHITE & BLUSH PINK
   ========================================================== */
.envelope-screen {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: 
    radial-gradient(circle at 50% 30%, #FFF5F7 0%, #FCE4EC 55%, #F8BBD0 100%);
  overflow: hidden;
  transition: opacity 0.85s cubic-bezier(0.16, 1, 0.3, 1), transform 0.85s cubic-bezier(0.16, 1, 0.3, 1);
}

.envelope-screen.opened {
  opacity: 0;
  transform: scale(1.08) translateY(-20px);
  pointer-events: none;
}

.envelope-wrapper {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 20px;
  width: 100%;
  max-width: 440px;
  perspective: 1000px;
}

.envelope-header {
  text-align: center;
  margin-bottom: 24px;
  animation: fadeInDown 1s ease forwards;
}

.envelope-eyebrow {
  color: #C85A70;
  font-size: 13px;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  margin: 0 0 6px;
  font-weight: 600;
}

.envelope-couple-names {
  font-family: var(--font-great-vibes);
  font-size: clamp(2.6rem, 8vw, 3.5rem);
  color: #8F1D2C;
  margin: 0;
  text-shadow: 0 2px 14px rgba(200, 90, 112, 0.25);
  line-height: 1.1;
}

/* Envelope Card 3D Box */
.envelope-card-3d {
  position: relative;
  width: 320px;
  height: 210px;
  background: #FFFFFF;
  border-radius: 14px;
  box-shadow: 0 24px 60px rgba(200, 90, 112, 0.22), 0 0 45px rgba(254, 226, 235, 0.85);
  border: 1px solid rgba(224, 122, 139, 0.35);
  cursor: pointer;
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  transform-style: preserve-3d;
}

.envelope-card-3d:hover {
  transform: translateY(-6px) scale(1.02);
}

/* Back of Envelope */
.envelope-back {
  position: absolute;
  inset: 0;
  background: #FFF5F7;
  border-radius: 14px;
  border: 1px solid rgba(224, 122, 139, 0.25);
  z-index: 1;
}

/* Letter sneaking out */
.envelope-letter {
  position: absolute;
  top: 15px;
  left: 15px;
  right: 15px;
  height: 180px;
  background: #FFFFFF;
  border: 1px solid rgba(224, 122, 139, 0.35);
  border-radius: 10px;
  z-index: 2;
  box-shadow: 0 6px 20px rgba(200, 90, 112, 0.12);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 16px;
  text-align: center;
  transition: transform 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.envelope-letter.slide-up {
  transform: translateY(-90px);
}

.letter-monogram {
  font-family: var(--font-g4-lora);
  font-size: 24px;
  color: #C85A70;
  font-weight: 600;
  letter-spacing: 0.1em;
  border-bottom: 1.5px solid #E07A8B;
  padding-bottom: 4px;
  margin-bottom: 6px;
}

.letter-save-date {
  font-family: var(--font-great-vibes);
  font-size: 28px;
  color: #C85A70;
  margin: 0;
}

.letter-date {
  font-size: 13px;
  color: #7E6E71;
  letter-spacing: 0.15em;
  margin: 4px 0 0;
}

/* Front Pocket of Envelope */
.envelope-front-pocket {
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  overflow: hidden;
  border-radius: 14px;
}

.envelope-pocket-bottom {
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 0;
  border-style: solid;
  border-width: 0 160px 125px 160px;
  border-color: transparent transparent #FCE7EC transparent;
  filter: drop-shadow(0 -3px 6px rgba(200, 90, 112, 0.08));
}

.envelope-pocket-left {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 0;
  border-style: solid;
  border-width: 105px 0 105px 160px;
  border-color: transparent transparent transparent #FFF0F3;
  opacity: 0.95;
}

.envelope-pocket-right {
  position: absolute;
  top: 0;
  bottom: 0;
  right: 0;
  width: 0;
  border-style: solid;
  border-width: 105px 160px 105px 0;
  border-color: transparent #FFF0F3 transparent transparent;
  opacity: 0.95;
}

/* Guest Name Badge */
.envelope-guest-badge {
  position: absolute;
  bottom: 26px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 5;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(224, 122, 139, 0.35);
  border-radius: 999px;
  padding: 8px 24px;
  text-align: center;
  box-shadow: 0 6px 20px rgba(200, 90, 112, 0.14);
  min-width: 200px;
}

.guest-label {
  display: block;
  font-size: 11px;
  color: #C85A70;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  font-weight: 600;
  margin-bottom: 2px;
}

.guest-name-display {
  font-family: var(--font-g4-lora);
  font-size: 15px;
  color: #2D2424;
  font-weight: 600;
  white-space: nowrap;
}

/* Flap (Nắp phong bì lật 3D) */
.envelope-flap {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 0;
  border-style: solid;
  border-width: 120px 160px 0 160px;
  border-color: #FAD2E1 transparent transparent transparent;
  transform-origin: top center;
  transform: rotateX(0deg);
  transition: transform 0.65s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 4;
  filter: drop-shadow(0 4px 8px rgba(200, 90, 112, 0.12));
}

.envelope-flap.opened {
  transform: rotateX(180deg);
  z-index: 1;
}

/* Wax Seal (Rose Gold / Blush Pink) */
.wax-seal {
  position: absolute;
  top: 105px;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #FFE4E9 0%, #E07A8B 45%, #C85A70 85%);
  box-shadow: 0 8px 24px rgba(200, 90, 112, 0.4), inset 0 0 0 2px rgba(255, 255, 255, 0.65);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 6;
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), opacity 0.3s ease;
}

.wax-seal:hover {
  transform: translate(-50%, -50%) scale(1.12);
}

.wax-seal.broken {
  opacity: 0;
  transform: translate(-50%, -50%) scale(1.4);
}

.wax-seal-inner {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1.5px dashed rgba(255, 255, 255, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-family: var(--font-g4-lora);
  font-size: 13.5px;
  font-weight: 700;
  letter-spacing: 0.05em;
  text-shadow: 0 1px 3px rgba(143, 29, 44, 0.4);
}

.wax-seal-pulse {
  position: absolute;
  inset: -6px;
  border-radius: 50%;
  border: 1.5px solid rgba(224, 122, 139, 0.65);
  animation: sealPulse 2s cubic-bezier(0.24, 0, 0.38, 1) infinite;
  pointer-events: none;
}

@keyframes sealPulse {
  0% { transform: scale(0.95); opacity: 0.8; }
  50% { transform: scale(1.2); opacity: 0; }
  100% { transform: scale(1.2); opacity: 0; }
}

/* Open Button */
.envelope-action {
  margin-top: 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: fadeInUp 1s 0.3s ease both;
}

.open-invitation-btn {
  background: linear-gradient(135deg, #E07A8B 0%, #C85A70 100%);
  color: #fff;
  border: none;
  padding: 14px 36px;
  border-radius: 999px;
  font-size: 15px;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  box-shadow: 0 10px 28px rgba(200, 90, 112, 0.38), 0 0 20px rgba(254, 226, 235, 0.6);
  display: flex;
  align-items: center;
  gap: 10px;
  transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

.open-invitation-btn:hover {
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 14px 34px rgba(200, 90, 112, 0.5), 0 0 25px rgba(254, 226, 235, 0.8);
}

.open-invitation-btn .btn-icon {
  font-size: 18px;
  animation: bounceSlow 2s infinite ease-in-out;
}

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

.envelope-hint {
  color: #7E6E71;
  font-size: 12.5px;
  margin-top: 10px;
  letter-spacing: 0.02em;
}

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

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

@media (max-width: 360px) {
  .envelope-card-3d {
    transform: scale(0.9);
  }
  .envelope-card-3d:hover {
    transform: scale(0.92);
  }
}

/* ==========================================================
   FLOATING AUDIO DISC PLAYER
   ========================================================== */
.audio-player-control {
  position: fixed;
  bottom: 24px;
  right: 24px;
  z-index: 90;
  display: flex;
  align-items: center;
  gap: 10px;
}

.vinyl-disc-btn {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: radial-gradient(circle, #FFF0F5 28%, #E07A8B 72%, #C85A70 100%);
  border: 2px solid #FAD2E1;
  box-shadow: 0 8px 24px rgba(200, 90, 112, 0.35);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
  position: relative;
  overflow: hidden;
}

.vinyl-disc-btn:hover {
  transform: scale(1.08);
  box-shadow: 0 10px 28px rgba(200, 90, 112, 0.5);
}

.vinyl-disc-btn.spinning {
  animation: spinDisc 6s linear infinite;
}

.vinyl-disc-btn.paused {
  animation-play-state: paused;
}

@keyframes spinDisc {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

.vinyl-disc-center {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  background: #C85A70;
  border: 2px solid #fff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.sound-waves {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 16px;
  position: absolute;
  top: -12px;
  right: 0;
  background: rgba(255, 255, 255, 0.95);
  border: 1px solid rgba(224, 122, 139, 0.35);
  box-shadow: 0 2px 8px rgba(200, 90, 112, 0.15);
  padding: 3px 6px;
  border-radius: 10px;
  backdrop-filter: blur(4px);
}

.wave-bar {
  width: 3px;
  height: 100%;
  background: #E07A8B;
  border-radius: 2px;
  animation: waveBar 1.2s ease-in-out infinite alternate;
}

.wave-bar:nth-child(2) { animation-delay: 0.2s; }
.wave-bar:nth-child(3) { animation-delay: 0.4s; }
.wave-bar:nth-child(4) { animation-delay: 0.6s; }

@keyframes waveBar {
  0% { height: 3px; }
  100% { height: 14px; }
}

.paused .sound-waves {
  display: none;
}

/* ==========================================================
   COUNTDOWN TIMER (WHITE & PINK MODERN CARDS)
   ========================================================== */
.styles-module__WlSJYG__monogram-initial {
  color: #C85A70 !important;
}

.styles-module__WlSJYG__countdown-section h3 {
  color: #7E6E71 !important;
}

.styles-module__WlSJYG__countdown-piece .styles-module__WlSJYG__box {
  background: #FFFFFF !important;
  border: 1px solid rgba(224, 122, 139, 0.28) !important;
  box-shadow: 0 4px 14px rgba(200, 90, 112, 0.08) !important;
  border-radius: 12px !important;
}

.styles-module__WlSJYG__countdown-piece .styles-module__WlSJYG__value {
  color: #C85A70 !important;
  font-weight: 600 !important;
}

.styles-module__WlSJYG__countdown-piece .styles-module__WlSJYG__colon {
  color: #E07A8B !important;
}

/* ==========================================================
   SIDE SWITCHER (NHÀ GÁI / NHÀ TRAI)
   ========================================================== */
.styles-module__WlSJYG__side-switch {
  background: #FFF0F3 !important;
  border: 1px solid rgba(224, 122, 139, 0.25) !important;
  border-radius: 999px !important;
  padding: 4px !important;
}

.styles-module__WlSJYG__side-switch button {
  color: #7E6E71 !important;
  font-weight: 600 !important;
  border-radius: 999px !important;
  transition: all 0.25s ease !important;
}

.styles-module__WlSJYG__side-switch button.styles-module__WlSJYG__active {
  background: linear-gradient(135deg, #E07A8B, #C85A70) !important;
  color: #FFFFFF !important;
  box-shadow: 0 4px 12px rgba(200, 90, 112, 0.35) !important;
}

/* ==========================================================
   PARENTS & COUPLE INFO
   ========================================================== */
.styles-module__WlSJYG__parent .styles-module__WlSJYG__label {
  color: #C85A70 !important;
  font-weight: 600 !important;
}

.styles-module__WlSJYG__v-divider {
  background: rgba(224, 122, 139, 0.3) !important;
}

.styles-module__WlSJYG__names .styles-module__WlSJYG__name {
  color: #C85A70 !important;
}

.styles-module__WlSJYG__names .styles-module__WlSJYG__and {
  color: #E07A8B !important;
}

.styles-module__WlSJYG__invitation-guest-name {
  color: #C85A70 !important;
}

/* ==========================================================
   EVENT CARDS (VU QUY & TIỆC CƯỚI)
   ========================================================== */
.styles-module__WlSJYG__invitation-event-block {
  background: #FFFFFF !important;
  border: 1px solid rgba(224, 122, 139, 0.22) !important;
  border-radius: 18px !important;
  padding: 24px 20px !important;
  margin: 16px 20px !important;
  box-shadow: 0 8px 24px rgba(200, 90, 112, 0.06) !important;
}

.styles-module__WlSJYG__event-title {
  color: #C85A70 !important;
  font-family: var(--font-g4-lora) !important;
  font-size: 20px !important;
  font-weight: 600 !important;
}

.styles-module__WlSJYG__date-and-time-inner {
  border-top-color: rgba(224, 122, 139, 0.25) !important;
  border-bottom-color: rgba(224, 122, 139, 0.25) !important;
}

.styles-module__WlSJYG__time {
  color: #C85A70 !important;
}

.styles-module__WlSJYG__date {
  color: #2D2424 !important;
}

.styles-module__WlSJYG__location-button {
  background: linear-gradient(135deg, #E07A8B, #C85A70) !important;
  color: #FFFFFF !important;
  border-radius: 999px !important;
  padding: 10px 22px !important;
  box-shadow: 0 4px 14px rgba(200, 90, 112, 0.3) !important;
  border: none !important;
  display: inline-flex !important;
  align-items: center !important;
  gap: 6px !important;
  font-weight: 500 !important;
}

/* ==========================================================
   CALENDAR & TIMELINE
   ========================================================== */
.styles-module__WlSJYG__calendar-heart {
  color: #E07A8B !important;
}

.styles-module__WlSJYG__calendar-inner .styles-module__WlSJYG__year,
.styles-module__WlSJYG__calendar-inner .styles-module__WlSJYG__month {
  color: #C85A70 !important;
}

.styles-module__WlSJYG__mini-calendar th {
  color: #7E6E71 !important;
}

/* ==========================================================
   LOVE STORY MILESTONES
   ========================================================== */
.story-card-item {
  background: #FFFFFF !important;
  border: 1px solid rgba(224, 122, 139, 0.22) !important;
  border-radius: 16px !important;
  margin: 12px 20px;
  padding: 18px;
  box-shadow: 0 6px 18px rgba(200, 90, 112, 0.05) !important;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.story-card-item:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(200, 90, 112, 0.12) !important;
}

.story-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.story-card-year {
  display: inline-block;
  background: #FFF0F3 !important;
  color: #C85A70 !important;
  border: 1px solid rgba(224, 122, 139, 0.25) !important;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.05em;
}

.story-card-title {
  font-size: 16.5px;
  font-weight: 600;
  color: #2D2424 !important;
  margin: 0;
  font-family: var(--font-g4-lora);
}

.story-card-body {
  margin-top: 10px;
  font-size: 14px;
  line-height: 1.6;
  color: #4A3E3D !important;
}

/* ==========================================================
   MODALS (GIFT BOX & BANKING QR)
   ========================================================== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(30, 20, 25, 0.75);
  backdrop-filter: blur(8px);
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.modal-container {
  background: #FFFFFF !important;
  border: 1px solid rgba(224, 122, 139, 0.3) !important;
  box-shadow: 0 25px 60px rgba(200, 90, 112, 0.25) !important;
  border-radius: 20px !important;
  max-width: 440px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  transform: scale(0.92) translateY(20px);
  transition: transform 0.35s cubic-bezier(0.34, 1.56, 0.64, 1);
  padding: 24px;
}

.modal-overlay.active .modal-container {
  transform: scale(1) translateY(0);
}

.modal-close-btn {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid rgba(224, 122, 139, 0.3) !important;
  background: #FFF0F3 !important;
  color: #C85A70 !important;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.2s ease;
  z-index: 10;
}

.modal-close-btn:hover {
  background: #C85A70 !important;
  color: #fff !important;
  border-color: #C85A70 !important;
  transform: rotate(90deg);
}

.tab-switcher {
  display: flex;
  background: #FFF0F3 !important;
  border: 1px solid rgba(224, 122, 139, 0.2) !important;
  border-radius: 999px;
  padding: 4px;
  gap: 4px;
  margin-bottom: 20px;
}

.tab-btn {
  flex: 1;
  padding: 10px 14px;
  border-radius: 999px;
  border: none;
  background: transparent;
  color: #7E6E71 !important;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.25s ease;
}

.tab-btn.active {
  background: linear-gradient(135deg, #E07A8B, #C85A70) !important;
  color: #fff !important;
  box-shadow: 0 4px 12px rgba(200, 90, 112, 0.35) !important;
}

.bank-card {
  background: linear-gradient(145deg, #FFFFFF, #FFF5F7) !important;
  border: 1px solid rgba(224, 122, 139, 0.3) !important;
  border-radius: 16px;
  padding: 18px;
  text-align: center;
  margin-bottom: 16px;
  position: relative;
}

.bank-qr-img {
  width: 220px;
  height: 220px;
  object-fit: contain;
  margin: 0 auto 12px;
  border-radius: 12px;
  border: 2px dashed rgba(224, 122, 139, 0.4) !important;
  padding: 6px;
  background: #fff;
}

.bank-info-line {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 8px 12px;
  background: rgba(255, 255, 255, 0.9) !important;
  border-radius: 8px;
  margin-bottom: 8px;
  font-size: 14px;
}

.copy-btn {
  background: linear-gradient(135deg, #E07A8B, #C85A70) !important;
  color: #fff !important;
  border: none;
  padding: 6px 14px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: all 0.2s;
}

.copy-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 4px 10px rgba(200, 90, 112, 0.3);
}

/* ==========================================================
   GUESTBOOK & WISHES SYSTEM
   ========================================================== */
.guest-wish-card {
  background: #FFFFFF !important;
  border: 1px solid rgba(224, 122, 139, 0.22) !important;
  border-left: 3.5px solid #E07A8B !important;
  border-radius: 12px;
  padding: 14px;
  margin-bottom: 12px;
  box-shadow: 0 4px 12px rgba(200, 90, 112, 0.05);
  animation: wishFadeIn 0.4s ease;
}

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

.guest-wish-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 6px;
}

.guest-wish-name {
  font-weight: 600;
  color: #2D2424 !important;
  font-size: 14px;
}

.guest-wish-tag {
  font-size: 11px;
  padding: 3px 10px;
  border-radius: 999px;
  background: #FFF0F3 !important;
  color: #C85A70 !important;
  font-weight: 500;
}

.guest-wish-content {
  font-size: 13.5px;
  color: #4A3E3D !important;
  line-height: 1.5;
  white-space: pre-line;
}

.guest-wish-time {
  font-size: 11px;
  color: #7E6E71 !important;
  margin-top: 6px;
  text-align: right;
}

.styles-module__WlSJYG__form-button,
#submitWishBtn,
.styles-module__WlSJYG__guestbook-start-button {
  background: linear-gradient(135deg, #E07A8B 0%, #C85A70 100%) !important;
  color: #fff !important;
  border-radius: 999px !important;
  box-shadow: 0 6px 18px rgba(200, 90, 112, 0.32) !important;
  border: none !important;
}

.styles-module__WlSJYG__rsvp-options button.styles-module__WlSJYG__active,
.styles-module__WlSJYG__guest-side-fields button.styles-module__WlSJYG__active {
  background: linear-gradient(135deg, #E07A8B, #C85A70) !important;
  color: #fff !important;
  border-color: transparent !important;
}

/* Toast Container */
#toast-container {
  position: fixed;
  top: 24px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 150;
  display: flex;
  flex-direction: column;
  gap: 10px;
  pointer-events: none;
}

.toast-msg {
  background: #FFFFFF !important;
  border: 1px solid rgba(224, 122, 139, 0.35) !important;
  color: #2D2424 !important;
  padding: 12px 22px;
  border-radius: 999px;
  box-shadow: 0 10px 30px rgba(200, 90, 112, 0.18) !important;
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 500;
  opacity: 0;
  transform: translateY(-15px);
  animation: toastIn 0.35s cubic-bezier(0.16, 1, 0.3, 1) forwards, toastOut 0.4s 3s forwards;
}

@keyframes toastIn {
  to { opacity: 1; transform: translateY(0); }
}

@keyframes toastOut {
  to { opacity: 0; transform: translateY(-10px); }
}

/* Lightbox Modal */
.lightbox-overlay {
  position: fixed;
  inset: 0;
  background: rgba(20, 15, 18, 0.94);
  z-index: 120;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

.lightbox-overlay.active {
  opacity: 1;
  pointer-events: auto;
}

.lightbox-img {
  max-width: 90vw;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
  transform: scale(0.95);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.lightbox-overlay.active .lightbox-img {
  transform: scale(1);
}

.lightbox-nav-btn {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.18);
  border: 1px solid rgba(255, 255, 255, 0.35);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}

.lightbox-nav-btn:hover {
  background: rgba(255, 255, 255, 0.35);
  transform: translateY(-50%) scale(1.1);
}

.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }

.lightbox-counter {
  position: absolute;
  bottom: 24px;
  color: rgba(255, 255, 255, 0.85);
  font-size: 14px;
  letter-spacing: 0.1em;
}

/* Cursor pointer on interactive items */
.styles-module__WlSJYG__photo,
.styles-module__WlSJYG__gallery-image,
.styles-module__WlSJYG__present-box button,
.styles-module__WlSJYG__guestbook-start-button,
.styles-module__WlSJYG__side-switch button {
  cursor: pointer;
}

/* ===== Fix: Ergisa font lacks Vietnamese glyphs (e.g. "Ế") -> use Lora for couple names ===== */
.styles-module__WlSJYG__name[data-fit-text] {
  font-family: 'Lora', Georgia, serif !important;
  letter-spacing: 0.5px;
}

/* ===== Monogram: two initials side by side with a small ampersand (no overlap) ===== */
.styles-module__WlSJYG__monogram-text {
  display: flex !important;
  align-items: center;
  justify-content: center;
  gap: 2px;
}
.styles-module__WlSJYG__monogram-initial {
  font-family: 'Lora', Georgia, serif !important;
  font-style: italic;
  font-weight: 500 !important;
  font-size: 2.3rem !important;
  -webkit-text-stroke: 0 !important;
  text-shadow: none !important;
  transform: none !important;
  line-height: 1 !important;
}
.styles-module__WlSJYG__monogram-bride::before {
  content: '&';
  font-family: 'Lora', serif;
  font-style: italic;
  font-size: 1.1rem;
  margin: 0 6px;
  opacity: 0.7;
  vertical-align: middle;
}
.styles-module__WlSJYG__monogram-groom { margin-right: 8px !important; }

/* ===== Fix: wax seal overlapping the guest badge on the envelope ===== */
.wax-seal { top: 86px; width: 52px; height: 52px; }
.envelope-guest-badge { bottom: 12px; padding: 7px 22px; }
.guest-label { white-space: nowrap; letter-spacing: 0.08em; font-size: 10.5px; }

/* ===== Monogram v2: interlaced script initials (overrides earlier monogram rules) ===== */
.styles-module__WlSJYG__monogram-text {
  position: relative;
  width: 124px !important; height: 124px !important;
  border: 1px solid rgba(181, 101, 111, .35) !important;
  box-shadow: inset 0 0 0 5px #fff, inset 0 0 0 6px rgba(181, 101, 111, .18);
  gap: 0 !important;
}
.styles-module__WlSJYG__monogram-initial {
  font-family: 'Great Vibes', cursive !important;
  font-style: normal !important;
  font-weight: 400 !important;
  font-size: 4.1rem !important;
  line-height: 1 !important;
  color: #b5566a !important;
  margin: 0 !important;
}
.styles-module__WlSJYG__monogram-groom { transform: translate(10px, -9px) !important; z-index: 1; }
.styles-module__WlSJYG__monogram-bride { transform: translate(-10px, 9px) !important; z-index: 2; color: #8f6f4e !important; }
.styles-module__WlSJYG__monogram-bride::before { content: none !important; }

/* ===== Typography: one script font + one serif across sections ===== */
.styles-module__WlSJYG__card-section-title,
.styles-module__WlSJYG__card-section-title.styles-module__WlSJYG__font1 {
  font-family: 'Great Vibes', cursive !important;
  font-weight: 400 !important;
  font-size: clamp(2.6rem, 11vw, 3.4rem) !important;
  line-height: 1.25 !important;
  letter-spacing: 0 !important;
  color: #b5566a !important;
  margin: 0 0 10px !important;
  padding: 0 12px;
  text-align: center;
}
.styles-module__WlSJYG__font1 { font-family: 'Great Vibes', cursive !important; font-weight: 400 !important; }
.styles-module__WlSJYG__rsvp-eyebrow { letter-spacing: .14em; margin-bottom: 4px; }

/* Calendar header: year + month no longer overlap */
.styles-module__WlSJYG__year {
  font-family: 'Lora', Georgia, serif !important;
  font-size: 1.05rem !important;
  letter-spacing: .4em !important;
  margin: 0 0 2px !important;
  line-height: 1.4 !important;
  color: #8f6f4e !important;
}
.styles-module__WlSJYG__month {
  font-family: 'Great Vibes', cursive !important;
  font-size: clamp(2.8rem, 13vw, 3.6rem) !important;
  line-height: 1.15 !important;
  color: #b5566a !important;
}
.styles-module__WlSJYG__monogram-initial { font-size: 3.5rem !important; }
.styles-module__WlSJYG__monogram-groom { transform: translate(12px, -8px) !important; }
.styles-module__WlSJYG__monogram-bride { transform: translate(-12px, 8px) !important; }
/* "The story of love" heading -> same script style as other section titles */
.styles-module__WlSJYG__card-love-story h2 {
  font-family: 'Great Vibes', cursive !important;
  text-transform: none !important;
  font-weight: 400 !important;
  font-size: clamp(2.6rem, 11vw, 3.4rem) !important;
  letter-spacing: 0 !important;
  line-height: 1.25 !important;
  color: #b5566a !important;
}

/* ===== Monogram v3 (mẫu E): Parisienne + small "&" inside a diamond frame — overrides earlier versions ===== */
.styles-module__WlSJYG__monogram-text {
  position: relative;
  width: 140px !important; height: 140px !important;
  border: 0 !important; border-radius: 0 !important;
  box-shadow: none !important;
  display: flex !important; align-items: center; justify-content: center;
  gap: 0 !important;
}
.styles-module__WlSJYG__monogram-text::before {
  content: ""; position: absolute; inset: 22px;
  border: 1px solid rgba(181, 86, 106, .4);
  transform: rotate(45deg);
  pointer-events: none;
}
.styles-module__WlSJYG__monogram-initial {
  font-family: 'Parisienne', cursive !important;
  font-style: normal !important; font-weight: 400 !important;
  font-size: 3.3rem !important; line-height: 1 !important;
  color: #b5566a !important;
  transform: none !important; margin: 0 !important;
  position: relative;
}
.styles-module__WlSJYG__monogram-bride::before {
  content: '&' !important;
  font-family: 'Cormorant Garamond', Georgia, serif;
  font-style: normal; font-size: 1.4rem;
  color: #8f6f4e; opacity: 1;
  margin: 0 4px; vertical-align: middle;
}

/* ===== Hero: short top shade only (no longer covers the groom's face) ===== */
.styles-module__WlSJYG__hero-overlay {
  inset: 0 0 auto 0 !important;
  height: 26% !important;
  background: linear-gradient(180deg, rgba(45, 36, 36, .32) 0%, rgba(45, 36, 36, 0) 100%) !important;
}
/* Text over the white dress: dark rose with a soft light halo */
.styles-module__WlSJYG__hero-tagline,
.styles-module__WlSJYG__wedding-name,
.styles-module__WlSJYG__wedding-name span,
.styles-module__WlSJYG__wedding-date {
  color: #7a3346 !important;
  text-shadow: 0 0 8px rgba(255, 255, 255, .9), 0 0 2px rgba(255, 255, 255, .9) !important;
}
.styles-module__WlSJYG__hero-tagline { font-weight: 500 !important; }

/* ===== Save the Date: smaller, single line ===== */
.styles-module__WlSJYG__save-date-section h2 {
  white-space: nowrap !important;
  font-size: clamp(26px, 8.5vw, 38px) !important;
  line-height: 1.1 !important;
  padding: 0 0 14px 20px !important;
}

/* ===== "Hai Bên Gia Đình" heading above the parents ===== */
.family-title { margin: 0 0 18px !important; }

/* ===== Couple names: even spacing around "and" ===== */
.styles-module__WlSJYG__and {
  display: block;
  margin: 10px 0 6px !important;
  line-height: 1 !important;
}

/* ===== Album: iPhone-style horizontal swipe with snap + dots ===== */
.styles-module__WlSJYG__photo-grid {
  display: flex !important;
  gap: 12px !important;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  padding: 4px 9% 8px !important;
  scrollbar-width: none;
}
.styles-module__WlSJYG__photo-grid::-webkit-scrollbar { display: none; }
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo {
  flex: 0 0 82% !important;
  aspect-ratio: 3 / 4 !important;
  scroll-snap-align: center;
  scroll-snap-stop: always;
  border-radius: 14px !important;
  overflow: hidden;
  transform: none !important;
  box-shadow: 0 8px 22px rgba(60, 30, 40, .16) !important;
  transition: transform .35s ease, opacity .35s ease;
}
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo:not(.is-active) { transform: scale(.94) !important; opacity: .75; }
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo img { width: 100%; height: 100%; object-fit: cover; }
.album-dots { display: flex; justify-content: center; gap: 7px; padding: 12px 0 4px; }
.album-dots button { width: 7px; height: 7px; padding: 0; border: 0; border-radius: 999px; background: rgba(181, 86, 106, .3); cursor: pointer; transition: width .25s, background .25s; }
.album-dots button.on { width: 20px; background: #b5566a; }
@media (prefers-reduced-motion: reduce) {
  .styles-module__WlSJYG__photo-grid { scroll-behavior: auto; }
  .styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo { transition: none; }
}

/* ===== Album v2: iPhone app-switcher style (JS sets per-card transform) ===== */
.styles-module__WlSJYG__photo-grid {
  gap: 0 !important;
  padding: 16px 18% 18px !important;
  cursor: grab;
  user-select: none;
  -webkit-user-select: none;
  overscroll-behavior-x: contain;
}
.styles-module__WlSJYG__photo-grid.is-dragging { cursor: grabbing; scroll-snap-type: none !important; scroll-behavior: auto !important; }
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo,
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo:not(.is-active) {
  flex: 0 0 64% !important;
  opacity: 1;
  transition: none !important;
  will-change: transform;
  transform-origin: center center;
  outline: none !important;
  border: 0 !important;
  box-shadow: 0 14px 34px rgba(40, 20, 28, .28) !important;
}
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo:focus-visible { box-shadow: 0 0 0 3px #fff, 0 0 0 5px #b5566a !important; }
.styles-module__WlSJYG__photo-grid img { pointer-events: none; -webkit-user-drag: none; }
/* Card width independent of padding so first/last card can sit exactly in the center */
.styles-module__WlSJYG__photo-grid { --card-w: min(62vw, 300px); padding-left: calc(50% - var(--card-w) / 2) !important; padding-right: calc(50% - var(--card-w) / 2) !important; }
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo,
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo:not(.is-active) { flex: 0 0 var(--card-w) !important; }
/* Album v3: GPU-only motion (transform/opacity), dim via overlay instead of filter */
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo { position: relative; backface-visibility: hidden; contain: layout paint; scroll-snap-stop: normal !important; }
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo::after {
  content: ""; position: absolute; inset: 0; border-radius: inherit;
  background: #1a0f13; opacity: var(--dim, 0); pointer-events: none;
}

/* ===== Tighten spacing: story portraits -> album header -> swipe album ===== */
.styles-module__WlSJYG__card-love-story.styles-module__WlSJYG__love-story-section { padding-bottom: 8px !important; }
.styles-module__WlSJYG__gallery-header { padding-top: 6px !important; padding-bottom: 0 !important; }
.styles-module__WlSJYG__photo-grid { margin-top: -6px !important; padding-top: 6px !important; }
.styles-module__WlSJYG__gallery-header-background { margin-bottom: -80px !important; }

/* ===== Shorter gaps between sections ===== */
.styles-module__WlSJYG__countdown-section,
.styles-module__WlSJYG__info-section,
.styles-module__WlSJYG__rsvp-section,
.styles-module__WlSJYG__gift-section { padding-top: 26px !important; padding-bottom: 26px !important; }
.styles-module__WlSJYG__love-story-section { padding-top: 24px !important; }
.styles-module__WlSJYG__calendar-section { padding-top: 18px !important; padding-bottom: 8px !important; }
/* Hero title: move down from the top edge */
.styles-module__WlSJYG__card-banner-inner { padding-top: 56px !important; }
/* Film-strip ribbon only showed as a sliver at the left edge and added ~140px of empty space */
.styles-module__WlSJYG__film-frame { display: none !important; }
/* Slower, controlled swipe: one card per flick on touch */
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo { scroll-snap-stop: always !important; }
/* Slower, controlled swipe: one card per flick on touch */
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo { scroll-snap-stop: always !important; }
/* Swipe handled in JS (slower momentum): allow vertical page scroll only, no native horizontal fling */
.styles-module__WlSJYG__photo-grid { touch-action: pan-y; }
.styles-module__WlSJYG__photo-grid .styles-module__WlSJYG__photo { scroll-snap-stop: normal !important; }

/* ===== Inline validation (replaces browser alert) ===== */
.field-error {
  border-color: #c4566d !important;
  box-shadow: 0 0 0 3px rgba(196, 86, 109, .14) !important;
  animation: fieldShake .42s cubic-bezier(.36, .07, .19, .97);
}
.field-error-msg {
  display: flex; align-items: center; gap: 6px;
  margin: 6px 2px 0;
  font-family: 'Lora', Georgia, serif; font-style: italic;
  font-size: 13px; color: #b5566a;
  animation: toastIn .3s ease forwards;
  opacity: 0; transform: translateY(-4px);
}
.field-error-msg::before {
  content: '!'; flex: none;
  width: 16px; height: 16px; border-radius: 50%;
  display: inline-grid; place-items: center;
  background: #b5566a; color: #fff;
  font: 700 11px/1 'Lora', Georgia, serif; font-style: normal;
}
@keyframes fieldShake {
  10%, 90% { transform: translateX(-1px); }
  20%, 80% { transform: translateX(2px); }
  30%, 50%, 70% { transform: translateX(-4px); }
  40%, 60% { transform: translateX(4px); }
}
@media (prefers-reduced-motion: reduce) { .field-error { animation: none; } }

/* ===== Calendar: number exactly centered inside the heart ===== */
.styles-module__WlSJYG__today {
  position: relative !important;
  display: inline-grid !important;
  place-items: center;
  width: 38px; height: 38px;
  vertical-align: middle;
}
.styles-module__WlSJYG__calendar-heart {
  position: absolute !important;
  inset: 0 !important; margin: auto !important;
  top: 0 !important; left: 0 !important;
  width: 38px !important; height: 38px !important;
  transform-origin: 50% 50%;
}
.styles-module__WlSJYG__today .styles-module__WlSJYG__day {
  padding: 0 !important;
  line-height: 1 !important;
  font-size: 13px;
  transform: translateY(-1px); /* heart's visual center sits slightly above its box center */
}

/* ===== Gift box: idle nudge + gentle unwrap on tap ===== */
.styles-module__WlSJYG__present-box button { transform-origin: 50% 80%; animation: giftIdle 4.5s ease-in-out 2s infinite; }
.styles-module__WlSJYG__present-box button img { transition: filter .4s ease; }
@keyframes giftIdle {
  0%, 82%, 100% { transform: translateY(0) rotate(0); }
  86% { transform: translateY(-5px) rotate(-3deg); }
  90% { transform: translateY(-5px) rotate(3deg); }
  94% { transform: translateY(0) rotate(0); }
}
.styles-module__WlSJYG__present-box button.gift-opening { animation: giftOpen 1.05s cubic-bezier(.34, 1.4, .64, 1) forwards; }
.styles-module__WlSJYG__present-box button.gift-opening img { filter: drop-shadow(0 0 18px rgba(232, 160, 120, .75)) brightness(1.06); }
@keyframes giftOpen {
  0%   { transform: scale(1) rotate(0); }
  12%  { transform: scale(.96) rotate(-6deg); }
  24%  { transform: scale(.98) rotate(6deg); }
  36%  { transform: scale(1) rotate(-3deg); }
  55%  { transform: translateY(-14px) scale(1.12) rotate(0); }
  100% { transform: translateY(-6px) scale(1.06); }
}
.gift-burst { position: absolute; left: 50%; top: 45%; width: 0; height: 0; pointer-events: none; z-index: 5; }
.gift-spark, .gift-petal {
  position: absolute; left: 0; top: 0; opacity: 0;
  animation: giftFly 1.1s cubic-bezier(.2, .7, .3, 1) var(--d) forwards;
}
.gift-spark {
  width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 50%;
  background: radial-gradient(circle, #fff7e0 0%, #f2c46d 45%, rgba(242, 196, 109, 0) 70%);
}
.gift-petal {
  width: 10px; height: 14px; margin: -7px 0 0 -5px;
  border-radius: 80% 0 80% 0;
  background: linear-gradient(135deg, #f7c6d0, #e07a8b);
}
@keyframes giftFly {
  0%   { opacity: 0; transform: translate(0, 0) scale(.4) rotate(0); }
  15%  { opacity: 1; }
  100% { opacity: 0; transform: translate(var(--x), var(--y)) scale(1) rotate(var(--r)); }
}
@media (prefers-reduced-motion: reduce) {
  .styles-module__WlSJYG__present-box button { animation: none; }
}

/* ===== Envelope opening v2: room for flap + letter, smoother staging ===== */
.envelope-couple-names {
  white-space: nowrap;
  font-size: clamp(2rem, 9vw, 2.9rem) !important;
}
.envelope-header { transition: transform .8s cubic-bezier(.22, 1, .36, 1), opacity .8s ease; }
.envelope-card-3d { transition: transform .9s cubic-bezier(.22, 1, .36, 1) !important; }
.envelope-action { transition: opacity .5s ease, transform .6s ease; }

/* While opening: names lift, envelope drops so the flap/letter never cover the names */
.envelope-screen.is-opening .envelope-header { transform: translateY(-34px); }
.envelope-screen.is-opening .envelope-card-3d { transform: translateY(78px) !important; }
.envelope-screen.is-opening .envelope-action { opacity: 0; transform: translateY(20px); pointer-events: none; }

/* Flap: flip slower, swap layer halfway through instead of at the start */
.envelope-flap { transition: transform .75s cubic-bezier(.45, 0, .2, 1), z-index 0s linear 0s !important; }
.envelope-flap.opened { transition: transform .75s cubic-bezier(.45, 0, .2, 1), z-index 0s linear .37s !important; }

/* Letter rises fully out of the envelope with a soft lift */
.envelope-letter { transition: transform 1s cubic-bezier(.22, 1, .36, 1), box-shadow 1s ease !important; }
.envelope-letter.slide-up {
  transform: translateY(-118px) scale(1.04) !important;
  box-shadow: 0 18px 40px rgba(200, 90, 112, .22) !important;
  z-index: 5 !important;
}
.wax-seal.broken { transition: transform .45s ease, opacity .45s ease !important; }

/* Final reveal: slower, softer fade */
.envelope-screen { transition: opacity 1s cubic-bezier(.22, 1, .36, 1), transform 1s cubic-bezier(.22, 1, .36, 1) !important; }
.envelope-screen.opened { transform: scale(1.04) !important; }

/* ===== Envelope screen: names on two lines with script "&" (matches invitation name block) ===== */
.envelope-couple-names {
  white-space: normal !important;
  display: flex; flex-direction: column; align-items: center;
  font-size: inherit !important;
  line-height: 1 !important;
  text-shadow: none !important;
}
.envelope-couple-names .env-name {
  font-family: 'Lora', Georgia, serif;
  text-transform: uppercase;
  font-weight: 400;
  font-size: clamp(1.9rem, 8.5vw, 2.4rem);
  letter-spacing: .02em;
  color: #c0566d;
  line-height: 1.15;
}
.envelope-couple-names .env-amp {
  font-family: 'Great Vibes', cursive;
  font-size: clamp(1.7rem, 7vw, 2.1rem);
  color: #e07a8b;
  line-height: 1;
  margin: 2px 0 4px;
}
.envelope-header { margin-bottom: 20px !important; }

/* ===== Album v4: transform-only carousel (JS positions cards; no native scroll / snap) ===== */
.styles-module__WlSJYG__photo-grid.album-js {
  overflow: hidden !important;
  scroll-snap-type: none !important;
  scroll-behavior: auto !important;
  touch-action: pan-y;
}
.styles-module__WlSJYG__photo-grid.album-js .styles-module__WlSJYG__photo {
  scroll-snap-align: none !important;
  box-shadow: 0 8px 20px rgba(40, 20, 28, .22) !important; /* lighter shadow = cheaper on phones */
  contain: paint;
}

/* ===== Music muted: diagonal slash over the disc (does not rotate with it) ===== */
.audio-player-control { position: fixed; }
.mute-slash {
  position: absolute; right: 0; bottom: 0;
  width: 52px; height: 52px; border-radius: 50%;
  pointer-events: none; z-index: 2;
  opacity: 0; transform: scale(.6);
  transition: opacity .25s ease, transform .3s cubic-bezier(.34, 1.56, .64, 1);
}
.mute-slash::before {
  content: ""; position: absolute; left: 50%; top: 50%;
  width: 62px; height: 4px; margin: -2px 0 0 -31px;
  border-radius: 4px;
  background: #b5566a;
  box-shadow: 0 0 0 2px #fff;
  transform: rotate(-45deg);
}
.audio-player-control.is-muted .mute-slash { opacity: 1; transform: scale(1); }
.audio-player-control.is-muted .vinyl-disc-btn { filter: grayscale(.55) brightness(.97); }
.audio-player-control.is-muted .sound-waves { opacity: 0; }

/* ===== Smaller music disc on phones ===== */
@media (max-width: 640px) {
  .audio-player-control {
    right: max(14px, env(safe-area-inset-right, 0px)) !important;
    bottom: calc(14px + env(safe-area-inset-bottom, 0px)) !important;
    gap: 6px !important;
  }
  .vinyl-disc-btn {
    width: 38px !important; height: 38px !important;
    box-shadow: 0 4px 12px rgba(200, 90, 112, .3) !important;
  }
  .vinyl-disc-center { width: 13px !important; height: 13px !important; }
  .vinyl-disc-center svg { width: 7px; height: 7px; }
  .sound-waves { height: 11px !important; padding: 3px 5px !important; }
  .wave-bar { width: 2px !important; }
  .mute-slash { width: 38px; height: 38px; }
  .mute-slash::before { width: 46px; height: 3px; margin: -1.5px 0 0 -23px; }
}
/* Hero title higher on phones (was close to the groom's head) */
@media (max-width: 640px) {
  .styles-module__WlSJYG__card-banner-inner { padding-top: 26px !important; }
}

/* ===== Envelope: monogram matches the main diamond logo ===== */
.letter-monogram.mono-diamond {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  width: 70px; height: 70px;
  margin: 0 auto 4px !important;
  padding: 0 !important; border: 0 !important;
  letter-spacing: 0 !important;
}
.letter-monogram.mono-diamond::before {
  content: ""; position: absolute; inset: 12px;
  border: 1px solid rgba(181, 86, 106, .45);
  transform: rotate(45deg);
}
.mono-diamond .mono-l { font-family: 'Parisienne', cursive; font-weight: 400; font-size: 26px; color: #b5566a; line-height: 1; position: relative; }
.mono-diamond .mono-amp { font-family: 'Cormorant Garamond', Georgia, serif; font-size: 13px; color: #8f6f4e; margin: 0 2px; position: relative; }

/* Wax seal: same script letters */
.seal-mono { display: inline-flex; align-items: center; line-height: 1; }
.seal-mono span { font-family: 'Parisienne', cursive; font-weight: 400; font-size: 17px; }
.seal-mono i { font-family: 'Cormorant Garamond', Georgia, serif; font-style: normal; font-size: 10px; margin: 0 1px; opacity: .9; }

/* ===== Opening: keep the rising letter clear of "THU HƯƠNG" ===== */
.envelope-couple-names .env-name { line-height: 1.05 !important; }
.envelope-couple-names .env-amp { margin: 0 0 2px !important; }
.envelope-screen.is-opening .envelope-header { transform: translateY(-64px) !important; }
.envelope-screen.is-opening .envelope-card-3d { transform: translateY(70px) !important; }
.envelope-letter.slide-up { transform: translateY(-96px) scale(1.03) !important; }
/* Button: its entrance animation (fill-mode both) was overriding the hide rule */
.envelope-screen.is-opening .envelope-action { animation: none !important; opacity: 0 !important; transform: translateY(20px) !important; pointer-events: none; }

/* ===== Envelope screen: softer type ===== */
.envelope-eyebrow {
  font-family: 'Lora', Georgia, serif !important;
  font-style: italic;
  font-weight: 400 !important;
  text-transform: none !important;
  letter-spacing: .08em !important;
  font-size: 15px !important;
  color: #b5566a !important;
  margin-bottom: 8px !important;
}
.guest-label {
  font-family: 'Lora', Georgia, serif !important;
  font-style: italic;
  font-weight: 400 !important;
  text-transform: none !important;
  letter-spacing: .03em !important;
  font-size: 12.5px !important;
  color: #b5566a !important;
}
.open-invitation-btn, .open-invitation-btn .btn-text {
  font-family: 'Lora', Georgia, serif !important;
  font-weight: 500 !important;
  letter-spacing: .03em !important;
}
/* More air around the "&" between the names */
.envelope-couple-names .env-name { line-height: 1.1 !important; }
.envelope-couple-names .env-amp { margin: 8px 0 6px !important; }

/* Countdown heading ("Our Next Chapter"): softer serif italic instead of uppercase sans */
.styles-module__WlSJYG__card-countdown h3 {
  font-family: 'Lora', Georgia, serif !important;
  font-style: italic !important;
  font-weight: 400 !important;
  text-transform: none !important;
  letter-spacing: .04em !important;
  font-size: clamp(1.15rem, 5vw, 1.4rem) !important;
  line-height: 1.5 !important;
  color: #8f6f4e !important;
}
/* Countdown digits: thinner */
.styles-module__WlSJYG__countdown-piece .styles-module__WlSJYG__value {
  font-family: 'Lora', Georgia, serif !important;
  font-weight: 400 !important;
  font-variant-numeric: lining-nums tabular-nums;
  letter-spacing: .02em;
}

/* ===== Lightbox: arrows always above the photo; compact on phones ===== */
.lightbox-nav-btn, .lightbox-close, .lightbox-counter { z-index: 3; }
.lightbox-img { position: relative; z-index: 1; touch-action: pan-y; user-select: none; -webkit-user-drag: none; }
@media (max-width: 640px) {
  .lightbox-img { max-width: 94vw; max-height: 78vh; }
  .lightbox-nav-btn {
    width: 38px; height: 38px;
    background: rgba(20, 15, 18, .45);
    border-color: rgba(255, 255, 255, .5);
    backdrop-filter: blur(4px);
  }
  .lightbox-prev { left: max(8px, env(safe-area-inset-left, 0px)); }
  .lightbox-next { right: max(8px, env(safe-area-inset-right, 0px)); }
}

/* Gift modal fits one phone screen without scrolling */
@media (max-width: 640px) {
  #giftModal .modal-container { padding: 18px 16px 14px !important; max-height: 94dvh; }
  #giftModal .modal-close-btn { top: 10px; right: 10px; width: 30px; height: 30px; }
  #giftModal h3 { font-size: 28px !important; margin: 0 !important; }
  #giftModal h3 + p { font-size: 12px !important; margin-bottom: 10px !important; line-height: 1.4; }
  #giftModal .tab-switcher { margin-bottom: 10px; padding: 3px; }
  #giftModal .tab-btn { padding: 7px 8px; font-size: 12.5px; white-space: nowrap; }
  #giftModal .bank-card { padding: 10px; margin-bottom: 0; }
  #giftModal .bank-qr-img { width: auto; height: min(30dvh, 190px); margin-bottom: 8px; padding: 3px; }
  #giftModal .bank-info-line { padding: 5px 10px; margin-bottom: 5px; font-size: 13px; }
  #giftModal .copy-btn { padding: 4px 10px; }
}
/* Compact single-line toasts */
.toast-msg { padding: 7px 16px !important; font-size: 13px !important; gap: 6px !important; white-space: nowrap; max-width: calc(100vw - 32px); overflow: hidden; text-overflow: ellipsis; display: block !important; }

/* Side switch sits between the couple names and the event card */
.styles-module__WlSJYG__side-switch-wrap { margin: 18px 0 14px !important; }
