/* ==========================================================================
   BODA LIAM & SCARLETT — PLANTILLA 10 BODAS
   Estética: Fine Art Botanical & Swan Lake Romance
   Paleta: Verde Oliva Salvia, Borgoña / Marsala, Marfil y Oro Viejo
   ========================================================================== */

/* Variables de Color y Sistema de Diseño */
:root {
  --color-olive-dark: #353f2c;
  --color-olive-mid: #4a573e;
  --color-olive-light: #6b7c5b;
  --color-olive-pale: #e8ebe4;
  
  --color-burgundy-deep: #47111c;
  --color-burgundy-mid: #681a29;
  --color-burgundy-bright: #8a2538;
  --color-burgundy-soft: #f9ecef;

  --color-gold-deep: #9d7b38;
  --color-gold-mid: #c5a059;
  --color-gold-light: #dfc285;
  --color-gold-glow: rgba(197, 160, 89, 0.35);

  --color-cream-bg: #fcf9f2;
  --color-cream-card: #ffffff;
  --color-cream-tint: #f6f1e7;
  --color-text-main: #2b2b28;
  --color-text-muted: #66645e;
  --color-border-subtle: #e6dfd1;

  --font-display: 'Playfair Display', serif;
  --font-script: 'Pinyon Script', cursive;
  --font-monogram: 'Cinzel Decorative', serif;
  --font-body: 'Montserrat', sans-serif;
  --font-serif: 'Cormorant Garamond', serif;
  --font-numbers: 'Russo One', sans-serif;

  --shadow-sm: 0 4px 12px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 10px 25px rgba(0, 0, 0, 0.08);
  --shadow-lg: 0 18px 45px rgba(0, 0, 0, 0.12);
  --shadow-seal: 0 12px 30px rgba(71, 17, 28, 0.35);

  --radius-sm: 10px;
  --radius-md: 18px;
  --radius-lg: 26px;
  --radius-pill: 9999px;
}

/* Reset y Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-body);
  background-color: var(--color-cream-bg);
  background-image: radial-gradient(circle at top, #ffffff 0%, var(--color-cream-bg) 70%, #ece5d6 100%);
  color: var(--color-text-main);
  line-height: 1.6;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

/* Canvas de Pétalos Flotantes */
.petals-canvas {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  pointer-events: none;
  z-index: 15;
}

/* Botón Flotante de Música */
.floating-music-btn {
  position: fixed;
  bottom: 24px;
  right: 20px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--color-burgundy-mid), var(--color-burgundy-deep));
  border: 2px solid var(--color-gold-mid);
  box-shadow: 0 8px 24px rgba(71, 17, 28, 0.4);
  cursor: pointer;
  z-index: 100;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 3px;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
  outline: none;
}

.floating-music-btn:hover,
.floating-music-btn:focus-visible {
  transform: scale(1.08);
  box-shadow: 0 12px 28px rgba(71, 17, 28, 0.55);
}

.music-note-icon {
  font-size: 1.1rem;
  line-height: 1;
}

.music-bars {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 14px;
}

.music-bars .bar {
  width: 3px;
  background-color: var(--color-gold-light);
  border-radius: 2px;
  height: 4px;
  transition: height 0.2s ease;
}

.floating-music-btn.playing .music-bars .bar:nth-child(1) {
  animation: equalize 1s infinite ease-in-out 0.1s;
}
.floating-music-btn.playing .music-bars .bar:nth-child(2) {
  animation: equalize 1.2s infinite ease-in-out 0.25s;
}
.floating-music-btn.playing .music-bars .bar:nth-child(3) {
  animation: equalize 0.9s infinite ease-in-out 0.4s;
}
.floating-music-btn.playing .music-bars .bar:nth-child(4) {
  animation: equalize 1.1s infinite ease-in-out 0.15s;
}

@keyframes equalize {
  0%, 100% { height: 4px; }
  50% { height: 14px; }
}

/* Contenedor Principal (Centrado Mobile-First: max 480px para smartphones de última generación) */
.invitation-container {
  width: 100%;
  max-width: 460px;
  margin: 0 auto;
  padding: 16px 12px 60px;
  position: relative;
  z-index: 1;
}

/* ==========================================================================
   1. SECCIÓN SOBRE CEREMONIAL 3D
   ========================================================================== */
.envelope-section {
  min-height: 94vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 30px 10px 20px;
  text-align: center;
  perspective: 1200px;
}

.intro-header {
  margin-bottom: 24px;
  animation: fadeInDown 1s ease both;
  transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

.envelope-section.is-opened .intro-header {
  transform: translateY(-24px);
}

.intro-eyebrow {
  display: block;
  font-family: var(--font-body);
  font-size: 0.85rem;
  font-weight: 600;
  letter-spacing: 4px;
  color: var(--color-gold-deep);
  margin-bottom: 6px;
  text-transform: uppercase;
}

.intro-couple-name {
  font-family: var(--font-script);
  font-size: 3.4rem;
  line-height: 1.1;
  color: var(--color-olive-dark);
  margin-bottom: 4px;
  text-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.intro-monogram-badge {
  display: inline-block;
  font-family: var(--font-monogram);
  font-size: 0.85rem;
  letter-spacing: 2px;
  color: var(--color-burgundy-mid);
  padding: 2px 14px;
  border: 1px solid var(--color-gold-mid);
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(4px);
}

/* Arquitectura del Sobre 3D (Sin overflow:hidden para permitir que la carta suba libremente) */
.envelope-wrapper {
  position: relative;
  width: 320px;
  height: 220px;
  margin: 65px auto 30px;
  perspective: 1200px;
}

.envelope {
  position: relative;
  width: 100%;
  height: 100%;
  transition: transform 0.8s cubic-bezier(0.2, 0.8, 0.2, 1);
}

/* Forro interior del sobre (óleo de cisnes) */
.envelope-back-lining {
  position: absolute;
  inset: 0;
  background: var(--color-olive-dark);
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.22);
  z-index: 0;
}

.lining-oil-painting {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.88;
  filter: contrast(1.05) saturate(1.1);
}

/* Carta Interior que emerge */
.envelope-letter {
  position: absolute;
  top: 14px;
  left: 14px;
  right: 14px;
  height: 195px;
  background: var(--color-cream-card);
  background-image: radial-gradient(circle, #ffffff 40%, var(--color-cream-tint) 100%);
  border-radius: 6px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.12);
  z-index: 5;
  opacity: 0;
  transform: translateY(15px) translateZ(4px);
  transition: transform 1.0s cubic-bezier(0.16, 1, 0.3, 1) 0.45s, 
              opacity 0.4s ease 0.4s, 
              height 0.8s ease 0.45s, 
              box-shadow 0.6s ease 0.5s;
  will-change: transform, height;
}

.envelope-wrapper.opened .envelope-letter {
  height: 250px;
  transform: translateY(-125px) translateZ(35px);
  opacity: 1;
  z-index: 25; /* Al frente absoluto de la solapa y del fondo */
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.3);
}

.letter-inner {
  padding: 14px 12px;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

.letter-decor-border {
  border: 1px solid var(--color-gold-mid);
  padding: 12px 10px;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  position: relative;
  background: rgba(255, 255, 255, 0.5);
}

.letter-monogram {
  font-family: var(--font-monogram);
  font-size: 1.1rem;
  color: var(--color-gold-deep);
  line-height: 1;
  margin-bottom: 2px;
}

.letter-announcement {
  font-size: 0.65rem;
  letter-spacing: 3px;
  color: var(--color-text-muted);
  font-weight: 600;
  text-transform: uppercase;
}

.letter-names {
  font-family: var(--font-display);
  font-size: 1.55rem;
  color: var(--color-olive-dark);
  font-weight: 700;
  line-height: 1.15;
  margin: 4px 0;
}

.letter-separator {
  display: flex;
  align-items: center;
  gap: 8px;
  width: 80%;
  margin: 4px 0;
}

.letter-separator .sep-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-gold-mid), transparent);
}

.letter-separator .sep-swan {
  color: var(--color-burgundy-mid);
  font-size: 0.9rem;
}

.letter-date {
  font-family: var(--font-display);
  font-size: 0.88rem;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--color-burgundy-deep);
}

.letter-time {
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--color-text-muted);
  margin-bottom: 2px;
}

.letter-venue {
  font-size: 0.7rem;
  font-weight: 700;
  color: var(--color-olive-dark);
  letter-spacing: 1px;
  margin-top: 2px;
}

.letter-city {
  font-size: 0.65rem;
  letter-spacing: 1px;
  color: var(--color-text-muted);
}

.letter-scroll-prompt {
  margin-top: 8px;
  font-size: 0.65rem;
  color: var(--color-gold-deep);
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 4px;
  opacity: 0;
  transition: opacity 0.5s ease 1s;
}

.arrow-down {
  width: 14px;
  height: 14px;
  animation: bounceDown 1.5s infinite;
}

@keyframes bounceDown {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(4px); }
}

/* Bolsillo Frontal del Sobre (Verde Oliva con textura suave) */
.envelope-pocket {
  position: absolute;
  inset: 0;
  background: linear-gradient(175deg, var(--color-olive-mid) 0%, var(--color-olive-dark) 100%);
  border-radius: 8px;
  clip-path: polygon(0 0, 50% 55%, 100% 0, 100% 100%, 0 100%);
  z-index: 10;
  transform: translateZ(8px);
  box-shadow: inset 0 2px 4px rgba(255, 255, 255, 0.15), 0 8px 24px rgba(0, 0, 0, 0.18);
}

/* Solapa Triangular Superior */
.envelope-flap {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 150px;
  background: linear-gradient(180deg, var(--color-olive-mid) 0%, var(--color-olive-dark) 100%);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  transform-origin: top center;
  transform-style: preserve-3d;
  transform: rotateX(0deg) translateZ(12px);
  transition: transform 0.85s cubic-bezier(0.25, 1, 0.5, 1);
  z-index: 12;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* Sello de Cera Realista 3D Monogramado */
.wax-seal-container {
  position: absolute;
  top: 112px;
  left: 50%;
  transform: translateX(-50%) translateZ(14px);
  width: 90px;
  height: 90px;
  z-index: 20;
  cursor: pointer;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
  display: flex;
  align-items: center;
  justify-content: center;
}

.wax-seal-container:hover {
  transform: translateX(-50%) translateZ(14px) scale(1.08);
}

.seal-glow-pulse {
  position: absolute;
  inset: -12px;
  border-radius: 50%;
  background: radial-gradient(circle, var(--color-gold-glow) 0%, transparent 70%);
  animation: pulseGlow 2s infinite ease-in-out;
  pointer-events: none;
}

@keyframes pulseGlow {
  0%, 100% { transform: scale(0.9); opacity: 0.5; }
  50% { transform: scale(1.15); opacity: 1; }
}

.wax-seal-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 8px 16px rgba(0, 0, 0, 0.35));
  position: relative;
  z-index: 2;
  transition: filter 0.3s ease;
}

.seal-flower-stem {
  position: absolute;
  bottom: -22px;
  left: -28px;
  width: 75px;
  height: auto;
  pointer-events: none;
  z-index: 1;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.25));
  transform: rotate(-15deg);
  transition: transform 0.4s ease, opacity 0.4s ease;
}

/* Wrapper de la Indicación de Apertura */
.envelope-hint-wrapper {
  margin-top: 24px;
  animation: fadeInUp 1s ease both 0.5s;
}

.hint-text {
  font-size: 0.95rem;
  color: var(--color-burgundy-mid);
  font-family: var(--font-serif);
  font-style: italic;
  font-weight: 600;
  letter-spacing: 0.5px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

.hint-text .sparkle {
  color: var(--color-gold-mid);
  font-style: normal;
  animation: spinSparkle 3s infinite linear;
}

@keyframes spinSparkle {
  0% { transform: rotate(0deg) scale(0.9); }
  50% { transform: rotate(180deg) scale(1.2); }
  100% { transform: rotate(360deg) scale(0.9); }
}

/* ==========================================================================
   ESTADO ABIERTO DEL SOBRE (ACTIVADO POR CLICK)
   ========================================================================== */
.envelope-wrapper.opened .envelope-flap {
  transform: rotateX(180deg) translateZ(-6px);
  z-index: 2; /* Pasa detrás de la carta */
  background: var(--color-olive-dark) url('assets/fotos/swans_painting.jpg') center bottom / cover no-repeat;
  transition: transform 0.85s cubic-bezier(0.25, 1, 0.5, 1), z-index 0.01s linear 0.4s;
}

.envelope-wrapper.opened .wax-seal-container {
  transform: translateX(-50%) translateZ(14px) scale(0.8);
  opacity: 0;
  pointer-events: none;
  transition: transform 0.4s ease, opacity 0.4s ease;
}

.envelope-wrapper.opened .envelope-letter {
  height: 250px;
  transform: translateY(-115px);
  z-index: 25; /* Al frente de la solapa */
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.25);
}

.envelope-wrapper.opened .letter-scroll-prompt {
  opacity: 1;
}

/* ==========================================================================
   2. CONTENIDO REVELADO TRAS LA APERTURA
   ========================================================================== */
.content-revealed {
  display: flex;
  flex-direction: column;
  gap: 24px;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 1s ease 0.6s, transform 1s ease 0.6s;
  pointer-events: none;
}

.content-revealed.active {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* Tarjetas Genéricas (Cards) */
.section-card {
  background: var(--color-cream-card);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-lg);
  padding: 28px 20px;
  box-shadow: var(--shadow-md);
  position: relative;
  overflow: hidden;
}

.card-ornament {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 16px;
}

.card-ornament .gold-line {
  flex: 1;
  max-width: 60px;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--color-gold-mid), transparent);
}

.card-ornament .ornament-icon {
  color: var(--color-burgundy-mid);
  font-size: 1.1rem;
}

.section-header {
  text-align: center;
  margin-bottom: 22px;
}

.section-subtitle {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 3px;
  color: var(--color-gold-deep);
  text-transform: uppercase;
  margin-bottom: 6px;
}

.section-title {
  font-family: var(--font-display);
  font-size: 1.85rem;
  color: var(--color-olive-dark);
  font-weight: 700;
  line-height: 1.2;
}

.section-description {
  font-size: 0.92rem;
  color: var(--color-text-muted);
  margin-top: 8px;
  line-height: 1.6;
}

/* Hero Card */
.hero-card {
  text-align: center;
  background-image: radial-gradient(circle at center, #ffffff 50%, var(--color-cream-tint) 100%);
}

.hero-quote {
  font-family: var(--font-serif);
  font-size: 1.15rem;
  font-style: italic;
  color: var(--color-burgundy-deep);
  line-height: 1.5;
  margin-bottom: 20px;
}

.hero-parents-intro {
  font-size: 0.8rem;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--color-gold-deep);
  font-weight: 600;
  margin-bottom: 14px;
}

.parents-grid {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-bottom: 24px;
}

.parents-block {
  flex: 1;
}

.parents-title {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 1px;
  text-transform: uppercase;
  color: var(--color-olive-mid);
  margin-bottom: 4px;
}

.parents-names {
  font-family: var(--font-display);
  font-size: 0.95rem;
  color: var(--color-text-main);
  line-height: 1.3;
}

.parents-divider {
  color: var(--color-gold-mid);
  font-size: 0.85rem;
}

.hero-invitation-badge {
  background: var(--color-olive-pale);
  border: 1px solid rgba(107, 124, 91, 0.25);
  border-radius: var(--radius-md);
  padding: 18px 14px;
}

.invitation-text {
  font-size: 0.85rem;
  color: var(--color-olive-dark);
  margin-bottom: 6px;
}

.couple-hero-title {
  font-family: var(--font-script);
  font-size: 3.2rem;
  color: var(--color-burgundy-deep);
  line-height: 1.1;
  margin-bottom: 6px;
}

.wedding-full-date {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 600;
  letter-spacing: 1px;
  color: var(--color-olive-dark);
}

/* ==========================================================================
   BOTONES DE ACCIÓN RÁPIDA (FLATLAY INTERACTIVO)
   ========================================================================== */
.quick-actions-section {
  margin: 6px 0;
}

.quick-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 14px;
}

.action-tile {
  display: flex;
  align-items: center;
  background: var(--color-cream-card);
  border: 1.5px solid var(--color-gold-mid);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  text-decoration: none;
  color: inherit;
  box-shadow: var(--shadow-sm);
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  cursor: pointer;
  text-align: left;
  width: 100%;
}

.action-tile:hover,
.action-tile:focus-visible {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: var(--color-burgundy-mid);
}

.tile-seal-icon {
  width: 58px;
  height: 58px;
  flex-shrink: 0;
  margin-right: 14px;
}

.tile-seal-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 4px 8px rgba(71, 17, 28, 0.25));
}

.tile-info {
  flex: 1;
}

.tile-tag {
  display: block;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 2px;
  color: var(--color-gold-deep);
  text-transform: uppercase;
}

.tile-title {
  font-family: var(--font-display);
  font-size: 1.15rem;
  color: var(--color-olive-dark);
  font-weight: 700;
  margin: 2px 0;
}

.tile-desc {
  font-size: 0.8rem;
  color: var(--color-text-muted);
}

.tile-arrow {
  color: var(--color-burgundy-mid);
  font-size: 1.2rem;
  margin-left: 8px;
  transition: transform 0.2s ease;
}

.action-tile:hover .tile-arrow {
  transform: translateX(4px);
}

/* ==========================================================================
   HISTORIA DE AMOR (POLAROIDS REALISTAS)
   ========================================================================== */
.polaroid-gallery {
  display: flex;
  flex-direction: column;
  gap: 20px;
  align-items: center;
  padding: 10px 0;
}

.polaroid-item {
  width: 100%;
  max-width: 290px;
  transition: transform 0.3s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.3s ease;
  cursor: pointer;
  outline: none;
}

.polaroid-tilt-left {
  transform: rotate(-3deg);
}

.polaroid-tilt-right {
  transform: rotate(3.5deg);
}

.polaroid-tilt-center {
  transform: rotate(-1deg);
}

.polaroid-item:hover,
.polaroid-item:focus-visible {
  transform: scale(1.06) rotate(0deg);
  z-index: 10;
}

.polaroid-frame {
  background: #ffffff;
  padding: 14px 14px 24px;
  border-radius: 4px;
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.14), 0 2px 6px rgba(0, 0, 0, 0.08);
  border: 1px solid #f0eae1;
}

.polaroid-frame img {
  width: 100%;
  height: 250px;
  object-fit: cover;
  border-radius: 2px;
  display: block;
  filter: contrast(1.03) brightness(0.98);
}

.polaroid-caption {
  font-family: var(--font-script);
  font-size: 1.6rem;
  color: #3b3935;
  text-align: center;
  margin-top: 14px;
  line-height: 1;
}

/* ==========================================================================
   SEDE Y UBICACIÓN
   ========================================================================== */
.venue-photo-wrapper {
  position: relative;
  border-radius: var(--radius-md);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  margin-bottom: 18px;
}

.venue-photo {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
}

.venue-badge-overlay {
  position: absolute;
  bottom: 12px;
  left: 12px;
  background: rgba(43, 51, 35, 0.85);
  color: #ffffff;
  padding: 6px 14px;
  border-radius: var(--radius-pill);
  font-size: 0.8rem;
  font-weight: 600;
  backdrop-filter: blur(4px);
  border: 1px solid rgba(223, 194, 133, 0.5);
}

.venue-details-box {
  background: var(--color-cream-tint);
  border-radius: var(--radius-md);
  padding: 16px;
  font-size: 0.92rem;
}

.venue-address {
  margin-bottom: 8px;
  color: var(--color-olive-dark);
}

.venue-note {
  font-size: 0.85rem;
  color: var(--color-text-muted);
  margin-bottom: 16px;
  line-height: 1.5;
}

.venue-buttons {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.btn-location {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 12px 16px;
  border-radius: var(--radius-pill);
  text-decoration: none;
  font-weight: 600;
  font-size: 0.88rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn-gmaps {
  background: var(--color-olive-dark);
  color: #ffffff;
}

.btn-waze {
  background: #ffffff;
  color: var(--color-olive-dark);
  border: 1.5px solid var(--color-olive-dark);
}

.btn-location:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-sm);
}

/* ==========================================================================
   CUENTA REGRESIVA Y LAGO DE CISNES
   ========================================================================== */
.countdown-card {
  padding: 0;
  color: #ffffff;
  text-align: center;
  background: var(--color-olive-dark);
}

.swans-bg-frame {
  position: absolute;
  inset: 0;
  z-index: 1;
}

.countdown-bg-painting {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.7) contrast(1.1);
}

.swans-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, rgba(20, 26, 17, 0.75) 0%, rgba(35, 43, 30, 0.6) 50%, rgba(15, 20, 12, 0.85) 100%);
}

.countdown-content {
  position: relative;
  z-index: 2;
  padding: 36px 18px;
}

.countdown-eyebrow {
  display: block;
  font-size: 0.75rem;
  letter-spacing: 3px;
  color: var(--color-gold-light);
  text-transform: uppercase;
  font-weight: 700;
  margin-bottom: 6px;
}

.countdown-title {
  font-family: var(--font-display);
  font-size: 2.1rem;
  color: #ffffff;
  margin-bottom: 24px;
}

.countdown-timer {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
  padding: 16px 10px;
  border-radius: var(--radius-md);
  border: 1px solid rgba(223, 194, 133, 0.4);
  margin-bottom: 20px;
}

.time-block {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 58px;
}

.time-number {
  font-family: var(--font-numbers);
  font-size: 1.85rem;
  color: var(--color-gold-light);
  line-height: 1;
  text-shadow: 0 0 12px rgba(223, 194, 133, 0.5);
}

.time-label {
  font-size: 0.65rem;
  letter-spacing: 1.5px;
  color: #ffffff;
  font-weight: 600;
  margin-top: 4px;
}

.time-colon {
  font-family: var(--font-numbers);
  font-size: 1.5rem;
  color: var(--color-gold-mid);
  margin-bottom: 12px;
}

.countdown-footer-date {
  font-family: var(--font-display);
  font-size: 0.95rem;
  letter-spacing: 2px;
  color: var(--color-gold-light);
  margin-bottom: 18px;
}

.btn-scroll-envelope {
  background: rgba(255, 255, 255, 0.15);
  border: 1px solid var(--color-gold-light);
  color: #ffffff;
  font-size: 0.8rem;
  padding: 8px 18px;
  border-radius: var(--radius-pill);
  cursor: pointer;
  backdrop-filter: blur(4px);
  transition: background 0.2s ease, transform 0.2s ease;
}

.btn-scroll-envelope:hover {
  background: rgba(255, 255, 255, 0.25);
  transform: translateY(-2px);
}

/* ==========================================================================
   SECCIÓN DE REGALOS
   ========================================================================== */
.gifts-grid {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.gift-box {
  background: var(--color-cream-tint);
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-md);
  padding: 20px 16px;
  text-align: center;
}

.gift-icon {
  font-size: 2.2rem;
  margin-bottom: 8px;
}

.gift-box-title {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--color-olive-dark);
  margin-bottom: 6px;
}

.gift-box-desc {
  font-size: 0.88rem;
  color: var(--color-text-muted);
  line-height: 1.5;
  margin-bottom: 14px;
}

.bank-details-card {
  background: #ffffff;
  border-radius: var(--radius-sm);
  border: 1px solid var(--color-border-subtle);
  padding: 12px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-align: left;
}

.bank-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.84rem;
  flex-wrap: wrap;
  gap: 6px;
}

.bank-label {
  font-weight: 600;
  color: var(--color-olive-mid);
}

.bank-val {
  font-family: monospace;
  font-weight: 700;
  color: var(--color-text-main);
}

.btn-copy {
  background: var(--color-olive-pale);
  border: 1px solid var(--color-olive-mid);
  color: var(--color-olive-dark);
  padding: 4px 10px;
  border-radius: var(--radius-pill);
  font-size: 0.72rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-copy:hover {
  background: var(--color-olive-mid);
  color: #ffffff;
}

.copy-feedback-msg {
  font-size: 0.82rem;
  color: #1e7e34;
  font-weight: 600;
  margin-top: 6px;
  min-height: 18px;
  text-align: center;
}

/* ==========================================================================
   SECCIÓN RSVP (CONFIRMACIÓN DUAL)
   ========================================================================== */
.rsvp-card {
  background: #ffffff;
  border: 1.5px solid var(--color-gold-mid);
}

.rsvp-form {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.form-group {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-label {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-olive-dark);
}

.form-input {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--color-border-subtle);
  border-radius: var(--radius-sm);
  font-family: var(--font-body);
  font-size: 0.95rem;
  background-color: var(--color-cream-bg);
  color: var(--color-text-main);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  outline: none;
}

.form-input:focus {
  border-color: var(--color-olive-dark);
  box-shadow: 0 0 0 3px rgba(74, 87, 62, 0.15);
  background-color: #ffffff;
}

.form-select {
  cursor: pointer;
}

.form-textarea {
  resize: vertical;
  min-height: 75px;
}

.form-error-msg {
  color: #c02b2b;
  font-size: 0.78rem;
  font-weight: 600;
  display: none;
}

.form-group.has-error .form-input {
  border-color: #c02b2b;
}

.form-group.has-error .form-error-msg {
  display: block;
}

.radio-options-grid {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.radio-card {
  display: flex;
  align-items: center;
  padding: 10px 14px;
  border: 1.5px solid var(--color-border-subtle);
  border-radius: var(--radius-sm);
  background: var(--color-cream-bg);
  cursor: pointer;
  transition: all 0.2s ease;
}

.radio-card:hover {
  border-color: var(--color-gold-mid);
}

.radio-card input {
  position: absolute;
  opacity: 0;
}

.radio-custom {
  width: 18px;
  height: 18px;
  border-radius: 50%;
  border: 2px solid var(--color-olive-mid);
  margin-right: 10px;
  position: relative;
  flex-shrink: 0;
}

.radio-card input:checked ~ .radio-custom::after {
  content: '';
  position: absolute;
  inset: 3px;
  border-radius: 50%;
  background: var(--color-burgundy-mid);
}

.radio-card:has(input:checked) {
  border-color: var(--color-burgundy-mid);
  background: var(--color-burgundy-soft);
}

.radio-text {
  font-size: 0.88rem;
  font-weight: 600;
  color: var(--color-text-main);
}

/* Botones Duales RSVP */
.rsvp-buttons-row {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-top: 10px;
}

.btn-rsvp {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  border-radius: var(--radius-pill);
  border: none;
  cursor: pointer;
  font-family: var(--font-body);
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  position: relative;
  text-decoration: none;
}

.btn-rsvp-direct {
  background: linear-gradient(135deg, var(--color-olive-dark), var(--color-olive-mid));
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(53, 63, 44, 0.3);
}

.btn-rsvp-wa {
  background: linear-gradient(135deg, #1f7a43, #25d366);
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(37, 211, 102, 0.3);
}

.btn-rsvp:hover,
.btn-rsvp:focus-visible {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.18);
}

.btn-rsvp .btn-text {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.5px;
}

.btn-rsvp .btn-subtext {
  font-size: 0.72rem;
  opacity: 0.9;
  margin-top: 2px;
}

.rsvp-status-container {
  min-height: 24px;
  margin-top: 12px;
  text-align: center;
}

.rsvp-success-box {
  background: #e8f5e9;
  border: 1px solid #81c784;
  color: #1b5e20;
  padding: 16px;
  border-radius: var(--radius-md);
  font-size: 0.92rem;
  line-height: 1.5;
  animation: fadeIn 0.4s ease;
}

.rsvp-loading-spinner {
  display: inline-block;
  width: 24px;
  height: 24px;
  border: 3px solid rgba(74, 87, 62, 0.25);
  border-top-color: var(--color-olive-dark);
  border-radius: 50%;
  animation: spin 0.8s infinite linear;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* ==========================================================================
   PIE DE PÁGINA
   ========================================================================== */
.invitation-footer {
  text-align: center;
  padding: 30px 10px 20px;
}

.footer-monogram {
  font-family: var(--font-monogram);
  font-size: 1.8rem;
  color: var(--color-gold-deep);
  margin-bottom: 8px;
}

.footer-blessing {
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 1.25rem;
  color: var(--color-burgundy-deep);
  margin-bottom: 6px;
}

.footer-thanks {
  font-size: 0.85rem;
  color: var(--color-text-muted);
}

.footer-date-tag {
  font-size: 0.75rem;
  letter-spacing: 2px;
  color: var(--color-gold-deep);
  margin-top: 8px;
  text-transform: uppercase;
}

/* ==========================================================================
   3. MODAL DE DETALLES DEL GRAN DÍA
   ========================================================================== */
.modal-details-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(18, 22, 14, 0.65);
  backdrop-filter: blur(8px);
  z-index: 200;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

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

.modal-details-window {
  background: var(--color-cream-card);
  width: 100%;
  max-width: 460px;
  max-height: 90vh;
  border-top-left-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-lg);
  overflow-y: auto;
  position: relative;
  transform: translateY(100%);
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 -10px 40px rgba(0, 0, 0, 0.3);
}

.modal-details-backdrop.active .modal-details-window {
  transform: translateY(0);
}

.modal-header-bar {
  position: sticky;
  top: 0;
  right: 0;
  z-index: 10;
  display: flex;
  justify-content: flex-end;
  padding: 12px 14px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.95) 60%, transparent 100%);
}

.btn-close-modal {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  border: 1px solid var(--color-border-subtle);
  background: var(--color-cream-bg);
  color: var(--color-olive-dark);
  font-size: 1.1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-sm);
  transition: all 0.2s ease;
}

.btn-close-modal:hover {
  background: var(--color-burgundy-mid);
  color: #ffffff;
}

.modal-hero-banner {
  position: relative;
  height: 160px;
  margin-top: -50px;
  overflow: hidden;
}

.modal-banner-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: brightness(0.65) contrast(1.1);
}

.modal-banner-text {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  text-align: center;
  padding: 10px;
}

.modal-eyebrow {
  font-size: 0.72rem;
  letter-spacing: 3px;
  color: var(--color-gold-light);
  font-weight: 700;
  text-transform: uppercase;
}

.modal-title {
  font-family: var(--font-display);
  font-size: 1.9rem;
  color: #ffffff;
}

.modal-body-content {
  padding: 24px 20px 40px;
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.modal-subcard {
  background: var(--color-cream-tint);
  border-radius: var(--radius-md);
  padding: 20px 16px;
  border: 1px solid var(--color-border-subtle);
}

.modal-section-title {
  font-family: var(--font-display);
  font-size: 1.3rem;
  color: var(--color-olive-dark);
  margin-bottom: 10px;
  border-bottom: 1.5px solid var(--color-gold-mid);
  padding-bottom: 4px;
  display: inline-block;
}

.modal-text-lead {
  font-size: 0.92rem;
  color: var(--color-text-main);
  line-height: 1.55;
  margin-bottom: 10px;
}

.modal-text-sub {
  font-size: 0.88rem;
  color: var(--color-text-muted);
  line-height: 1.55;
}

/* Timeline Stepper Ilustrado */
.timeline-stepper {
  display: flex;
  flex-direction: column;
  gap: 16px;
  margin-top: 14px;
  position: relative;
  padding-left: 8px;
}

.timeline-step {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  position: relative;
}

.timeline-step::before {
  content: '';
  position: absolute;
  left: 20px;
  top: 40px;
  bottom: -16px;
  width: 2px;
  background: var(--color-gold-mid);
}

.timeline-step:last-child::before {
  display: none;
}

.step-icon-badge {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #ffffff;
  border: 2px solid var(--color-gold-mid);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
  position: relative;
  z-index: 2;
}

.step-content {
  flex: 1;
}

.step-time {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--color-burgundy-mid);
  background: var(--color-burgundy-soft);
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  margin-bottom: 4px;
}

.step-label {
  font-family: var(--font-display);
  font-size: 1.05rem;
  color: var(--color-olive-dark);
  margin-bottom: 2px;
}

.step-desc {
  font-size: 0.82rem;
  color: var(--color-text-muted);
  line-height: 1.4;
}

.transport-list {
  padding-left: 18px;
  font-size: 0.88rem;
  color: var(--color-text-muted);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.hotels-buttons-col {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 14px;
}

.btn-hotel-pill {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: #ffffff;
  border: 1px solid var(--color-border-subtle);
  border-radius: var(--radius-pill);
  text-decoration: none;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--color-olive-dark);
  transition: all 0.2s ease;
}

.btn-hotel-pill:hover {
  background: var(--color-olive-pale);
  border-color: var(--color-olive-mid);
}

.modal-dress-badge {
  display: inline-block;
  background: var(--color-olive-dark);
  color: #ffffff;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 1px;
  padding: 4px 14px;
  border-radius: var(--radius-pill);
  margin-bottom: 12px;
}

.swatches-row {
  display: flex;
  align-items: center;
  justify-content: space-around;
  margin-top: 18px;
  flex-wrap: wrap;
  gap: 10px;
}

.color-swatch-item {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
}

.swatch-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
  border: 2px solid #ffffff;
}

.color-sage { background-color: #8c9a7b; }
.color-olive { background-color: #556247; }
.color-blush { background-color: #d89fa3; }
.color-burgundy { background-color: #7b1d2e; }
.color-wine { background-color: #480f1b; }

.swatch-name {
  font-size: 0.7rem;
  font-weight: 600;
  color: var(--color-text-muted);
}

.modal-footer-action {
  text-align: center;
  margin-top: 10px;
}

.btn-close-modal-bottom {
  width: 100%;
  padding: 14px;
  border-radius: var(--radius-pill);
  background: var(--color-olive-dark);
  color: #ffffff;
  border: none;
  font-size: 0.95rem;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease;
}

.btn-close-modal-bottom:hover {
  background: var(--color-olive-mid);
}

/* ==========================================================================
   ANIMACIONES CLAVE
   ========================================================================== */
@keyframes fadeInDown {
  from { opacity: 0; transform: translateY(-20px); }
  to { opacity: 1; transform: translateY(0); }
}

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

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

/* Scroll Reveal con IntersectionObserver */
.scroll-reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s cubic-bezier(0.16, 1, 0.3, 1), transform 0.8s cubic-bezier(0.16, 1, 0.3, 1);
  will-change: opacity, transform;
}

.scroll-reveal.is-revealed {
  opacity: 1;
  transform: translateY(0);
}

/* Accesibilidad y Reduced Motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
