/* =========================================================
   INVITACIÓN DIGITAL DE BODA DE ALTA GAMA — MIGUEL & CLAUDIA
   Paleta: Slate Blue Real, Ivory Cálido y Oro Champagne
   Diseño Editorial & Animaciones GSAP
   ========================================================= */

:root {
  --bg-page: #ded9cd;
  --bg-app: #faf8f5;
  --bg-card: #ffffff;
  --bg-card-alt: #f3efe6;

  --slate-deep: #1e2a33;
  --slate-dark: #2d3e4d;
  --slate-main: #475d6e;
  --slate-light: #708697;
  --slate-soft: #eaf0f5;
  --slate-border: #d2dbe2;

  --gold-accent: #c5a880;
  --gold-dark: #a18155;
  --gold-bright: #e2c89d;
  --gold-light: #f9f4ea;

  --text-main: #24292d;
  --text-muted: #5a646d;
  --text-light: #87929d;

  --radius-card: 24px;
  --radius-pill: 50px;
  --shadow-lux: 0 18px 45px rgba(35, 48, 59, 0.09);
  --shadow-float: 0 10px 28px rgba(35, 48, 59, 0.12);

  --font-serif: 'Cormorant Garamond', Georgia, serif;
  --font-display: 'Cinzel', serif;
  --font-sans: 'Montserrat', -apple-system, BlinkMacSystemFont, sans-serif;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-tap-highlight-color: transparent;
}

body {
  background-color: var(--bg-page);
  color: var(--text-main);
  font-family: var(--font-sans);
  line-height: 1.6;
  display: flex;
  justify-content: center;
  min-height: 100vh;
  overflow-x: hidden;
  position: relative;
}

body.envelope-locked {
  overflow: hidden;
  height: 100vh;
}

/* Canvas para lluvia continua de pétalos de rosa */
#petals-canvas,
#particles-canvas {
  position: fixed;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 100;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

button, input, select, textarea {
  font-family: inherit;
}

/* =========================================================
   1. SOBRE CEREMONIAL 3D CON SELLO DE LACRE
   ========================================================= */
.envelope-overlay {
  position: fixed;
  inset: 0;
  z-index: 99999;
  display: flex;
  align-items: center;
  justify-content: center;
  background: radial-gradient(circle at 50% 35%, #4a5e6f 0%, #1e272f 100%);
  transition: opacity 1s cubic-bezier(0.4, 0, 0.2, 1), visibility 1s ease;
  overflow-y: auto;
  overflow-x: hidden;
  padding: 1.5rem 1rem;
}

.envelope-overlay.opened {
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
}

.envelope-ambient-bg {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(255,255,255,0.08) 1.2px, transparent 1.2px);
  background-size: 26px 26px;
  pointer-events: none;
}

.envelope-scene-wrapper,
.envelope-container {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1.1rem;
  text-align: center;
  width: 100%;
  max-width: 420px;
  perspective: 1400px;
  z-index: 2;
  position: relative;
}

.envelope-header-text {
  transition: transform 0.6s ease, opacity 0.6s ease;
}

.envelope-overlay.opening .envelope-header-text {
  opacity: 0.35;
  transform: translateY(-16px);
}

.envelope-badge {
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.35em;
  text-transform: uppercase;
  color: var(--gold-light);
  opacity: 0.95;
}

.envelope-couple-names {
  font-family: var(--font-serif);
  font-size: 2.3rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: #ffffff;
  text-shadow: 0 2px 14px rgba(0,0,0,0.35);
  margin-top: -0.2rem;
}

.envelope-date-preview {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.22em;
  color: var(--slate-soft);
  opacity: 0.9;
  margin-top: 0.2rem;
}

/* Envoltura física del Sobre 3D (Sin overflow: hidden para permitir que la carta y solapa salgan libres) */
.envelope-wrapper {
  width: 320px;
  height: 220px;
  position: relative;
  cursor: pointer;
  transform-style: preserve-3d;
  transition: transform 0.4s cubic-bezier(0.2, 0, 0, 1);
}

.envelope-wrapper:hover {
  transform: translateY(-4px) scale(1.015);
}

/* 1. Fondo Trasero del Sobre */
.envelope-back-plate {
  position: absolute;
  inset: 0;
  background: #2b3944;
  border-radius: 14px;
  box-shadow: 0 25px 55px rgba(0, 0, 0, 0.45), 0 0 0 1px rgba(255,255,255,0.08);
  z-index: 1;
}

/* 2. Solapa Superior Giratoria 3D */
.envelope-flap {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 145px;
  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: 15;
  pointer-events: none;
}

.envelope-flap .flap-svg {
  width: 100%;
  height: 100%;
  display: block;
  filter: drop-shadow(0 6px 14px rgba(0,0,0,0.38));
}

.envelope-overlay.opening .envelope-flap {
  transform: rotateX(180deg) translateZ(-6px);
  z-index: 2; /* Cae hacia atrás detrás de la carta */
  transition: transform 0.85s cubic-bezier(0.25, 1, 0.5, 1), z-index 0.01s linear 0.4s;
}

/* 3. Carta Interior que Emerge Libremente Hacia Arriba */
.envelope-letter {
  position: absolute;
  left: 16px;
  right: 16px;
  top: 18px;
  height: 188px;
  background: #fdfbf7;
  border-radius: 10px;
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.18);
  z-index: 3;
  padding: 0.75rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  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, 
              box-shadow 0.6s ease 0.5s;
  cursor: pointer;
}

/* Al abrir, la carta se eleva alto y se ubica en z-index: 25 (DELANTE de la solapa y del bolsillo) */
.envelope-overlay.opening .envelope-letter {
  transform: translateY(-145px) translateZ(35px);
  opacity: 1;
  z-index: 25;
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.45);
}

.letter-gold-border {
  border: 1px solid var(--gold-accent);
  padding: 0.75rem 0.65rem;
  width: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.16rem;
  background: radial-gradient(circle at center, #ffffff 60%, #faf6ee 100%);
  border-radius: 6px;
}

.letter-monogram {
  font-family: var(--font-display);
  font-size: 1.25rem;
  color: var(--gold-dark);
  letter-spacing: 0.15em;
  line-height: 1;
}

.letter-heading {
  font-family: var(--font-display);
  font-size: 0.65rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--slate-main);
  font-weight: 600;
  margin-top: 0.15rem;
}

.letter-names {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  font-weight: 500;
  color: var(--slate-deep);
  line-height: 1.15;
}

.letter-divider-line {
  width: 38px;
  height: 1px;
  background: var(--gold-accent);
  margin: 0.25rem 0;
}

.letter-datetime-box {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.1rem;
}

.ld-day {
  font-family: var(--font-display);
  font-size: 0.6rem;
  letter-spacing: 0.12em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.ld-hour-highlight {
  font-family: var(--font-serif);
  font-size: 1.45rem;
  font-weight: 700;
  color: var(--gold-dark);
  letter-spacing: 0.05em;
  line-height: 1.1;
  text-shadow: 0 1px 2px rgba(161, 129, 85, 0.18);
  margin: 0.08rem 0;
}

.ld-venue {
  font-size: 0.62rem;
  color: var(--slate-main);
  font-style: italic;
  font-family: var(--font-serif);
}

/* 4. Bolsillo Delantero del Sobre (Pliegues Frontales) */
.envelope-front-pocket {
  position: absolute;
  inset: 0;
  border-radius: 14px;
  overflow: hidden;
  z-index: 8;
  transform: translateZ(8px);
  pointer-events: none;
}

.pocket-left-crease {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 0;
  width: 0;
  height: 0;
  border-top: 110px solid transparent;
  border-bottom: 110px solid transparent;
  border-left: 160px solid #364958;
  filter: drop-shadow(2px 0 5px rgba(0,0,0,0.18));
}

.pocket-right-crease {
  position: absolute;
  top: 0;
  bottom: 0;
  right: 0;
  width: 0;
  height: 0;
  border-top: 110px solid transparent;
  border-bottom: 110px solid transparent;
  border-right: 160px solid #364958;
  filter: drop-shadow(-2px 0 5px rgba(0,0,0,0.18));
}

.pocket-bottom-flap {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 140px;
}

.bottom-flap-svg {
  width: 100%;
  height: 100%;
  display: block;
  filter: drop-shadow(0 -4px 8px rgba(0,0,0,0.22));
}

.envelope-phrase {
  position: absolute;
  bottom: 12px;
  left: 0;
  right: 0;
  text-align: center;
  font-family: var(--font-serif);
  font-size: 0.95rem;
  font-style: italic;
  color: #d1dde6;
  z-index: 12;
  pointer-events: none;
  text-shadow: 0 1px 4px rgba(0,0,0,0.6);
}

/* =========================================================
   5. SELLO DE LACRE: UBICADO DIRECTAMENTE ENCIMA DEL VÉRTICE
   ========================================================= */
.wax-seal-wrapper {
  position: absolute;
  top: 142px; /* Exactamente sobre el vértice inferior de la solapa */
  left: 50%;
  transform: translate(-50%, -50%) translateZ(14px);
  width: 86px;
  height: 86px;
  z-index: 35;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: transform 0.4s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.wax-seal-wrapper:hover {
  transform: translate(-50%, -50%) translateZ(14px) scale(1.08);
}

.envelope-overlay.opening .wax-seal-wrapper {
  transform: translate(-50%, -50%) translateZ(14px) scale(0.8);
  opacity: 0;
  pointer-events: none;
}

.wax-seal-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 8px 18px rgba(0,0,0,0.5));
}

.seal-halo-glow {
  position: absolute;
  inset: -8px;
  border-radius: 50%;
  border: 1.5px dashed rgba(226, 200, 157, 0.7);
  animation: rotateSealGlow 14s linear infinite;
  pointer-events: none;
}

@keyframes rotateSealGlow {
  0% { transform: rotate(0deg); }
  100% { transform: rotate(360deg); }
}

/* =========================================================
   6. INDICADOR FLOTANTE DEBAJO DEL SOBRE (Separado por flujo)
   ========================================================= */
.envelope-hint-wrapper {
  margin-top: 1.2rem;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100%;
  z-index: 5;
  transition: opacity 0.4s ease;
}

.envelope-overlay.opening .envelope-hint-wrapper {
  opacity: 0;
  pointer-events: none;
}

.seal-tap-tip {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: #ffffff;
  background: rgba(22, 33, 42, 0.85);
  border: 1px solid rgba(226, 200, 157, 0.4);
  padding: 0.5rem 1.15rem;
  border-radius: 999px;
  backdrop-filter: blur(8px);
  box-shadow: 0 4px 18px rgba(0, 0, 0, 0.35);
  animation: pulseHint 2.4s ease-in-out infinite;
  cursor: pointer;
  transition: transform 0.2s ease, background-color 0.2s ease;
}

.seal-tap-tip:hover {
  transform: translateY(-2px);
  background: rgba(30, 45, 57, 0.95);
}

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

/* =========================================================
   BARRA FLOTANTE DE AUDIO
   ========================================================= */
.floating-audio-bar {
  position: fixed;
  bottom: 24px;
  right: 20px;
  z-index: 900;
}

.audio-toggle-btn {
  width: 50px;
  height: 50px;
  border-radius: 50%;
  border: 1px solid var(--gold-accent);
  background: var(--bg-card);
  color: var(--slate-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: var(--shadow-float);
  transition: transform 0.25s ease, background-color 0.25s ease;
}

.audio-toggle-btn:hover {
  transform: scale(1.08);
}

.music-wave-bars {
  display: flex;
  align-items: flex-end;
  gap: 2.5px;
  height: 16px;
}

.music-wave-bars .bar {
  width: 3px;
  background: var(--slate-main);
  border-radius: 2px;
  animation: waveBar 1.2s ease-in-out infinite;
}

.music-wave-bars .bar:nth-child(1) { height: 8px; animation-delay: 0s; }
.music-wave-bars .bar:nth-child(2) { height: 16px; animation-delay: 0.2s; }
.music-wave-bars .bar:nth-child(3) { height: 11px; animation-delay: 0.4s; }

body.audio-paused .music-wave-bars .bar {
  animation: none;
  height: 4px;
}

@keyframes waveBar {
  0%, 100% { transform: scaleY(0.4); }
  50% { transform: scaleY(1); }
}

/* =========================================================
   2. CONTENEDOR PRINCIPAL / VISTA SMARTPHONE
   ========================================================= */
.wedding-viewport {
  width: 100%;
  max-width: 470px;
  background: var(--bg-app);
  min-height: 100vh;
  box-shadow: var(--shadow-lux);
  display: flex;
  flex-direction: column;
  position: relative;
  z-index: 10;
}

/* Secciones Generales */
section, header, footer {
  padding: 3rem 1.6rem;
  text-align: center;
}

.section-badge {
  display: inline-block;
  font-family: var(--font-display);
  font-size: 0.68rem;
  letter-spacing: 0.25em;
  text-transform: uppercase;
  color: var(--gold-dark);
  margin-bottom: 0.4rem;
}

.section-title {
  font-family: var(--font-serif);
  font-size: 1.95rem;
  font-weight: 500;
  color: var(--slate-deep);
  line-height: 1.25;
  margin-bottom: 0.6rem;
}

.section-subtitle {
  font-size: 0.83rem;
  color: var(--text-muted);
  max-width: 34ch;
  margin: 0 auto 1.8rem;
}

/* 1. HERO / PORTADA */
.section-hero {
  padding-top: 1.5rem;
  padding-bottom: 2rem;
}

.hero-card {
  background: var(--bg-card);
  border-radius: var(--radius-card);
  overflow: hidden;
  box-shadow: var(--shadow-lux);
  border: 1px solid rgba(0,0,0,0.03);
}

.hero-image-container {
  width: 100%;
  height: 450px;
  position: relative;
  overflow: hidden;
}

.hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 20%;
  transition: transform 6s ease;
}

.hero-card:hover .hero-img {
  transform: scale(1.04);
}

.hero-vignette {
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, rgba(0,0,0,0) 65%, rgba(255,255,255,0.98) 100%);
}

.hero-content {
  padding: 1.5rem 1.4rem 2rem;
}

.botanical-ornament {
  color: var(--slate-main);
  margin-bottom: 0.5rem;
}

.hero-pretitle {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.3em;
  color: var(--gold-dark);
  margin-bottom: 0.4rem;
}

.hero-couple-title {
  font-family: var(--font-serif);
  font-size: 2.85rem;
  font-weight: 400;
  color: var(--slate-deep);
  line-height: 1.1;
  margin-bottom: 0.8rem;
}

.hero-tagline-box {
  display: inline-block;
  border-top: 1px solid var(--gold-accent);
  border-bottom: 1px solid var(--gold-accent);
  padding: 0.35rem 1.6rem;
  margin-bottom: 1.4rem;
}

.hero-tagline {
  font-family: var(--font-display);
  font-size: 0.82rem;
  letter-spacing: 0.28em;
  color: var(--slate-main);
  font-weight: 600;
}

.hero-invitation-text {
  font-family: var(--font-serif);
  font-size: 1.08rem;
  line-height: 1.7;
  color: var(--text-muted);
  max-width: 33ch;
  margin: 0 auto 1.5rem;
}

.hero-quote {
  border-top: 1px dashed var(--slate-border);
  padding-top: 1.2rem;
  font-family: var(--font-serif);
  font-style: italic;
  font-size: 0.98rem;
  color: var(--slate-main);
}

.hero-quote span {
  display: block;
  font-family: var(--font-display);
  font-size: 0.65rem;
  font-style: normal;
  letter-spacing: 0.18em;
  color: var(--gold-dark);
  margin-top: 0.3rem;
}

/* 2. NUESTRA CANCIÓN */
.section-song {
  background: var(--bg-card);
}

.song-card {
  border-radius: var(--radius-card);
}

.song-cover-wrapper {
  width: 100%;
  max-width: 320px;
  margin: 1.2rem auto 1.5rem;
  border-radius: 18px;
  overflow: hidden;
  box-shadow: var(--shadow-float);
  position: relative;
  aspect-ratio: 4/5;
}

.song-cover-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.song-cover-wrapper:hover .song-cover-img {
  transform: scale(1.03);
}

.song-badge-overlay {
  position: absolute;
  bottom: 12px;
  left: 12px;
  right: 12px;
  background: rgba(30, 42, 51, 0.75);
  backdrop-filter: blur(8px);
  padding: 0.45rem 0.85rem;
  border-radius: 10px;
  color: #fff;
  border: 1px solid rgba(255,255,255,0.12);
}

.song-name-tag {
  font-size: 0.75rem;
  letter-spacing: 0.08em;
  font-weight: 500;
}

.custom-music-player {
  max-width: 310px;
  margin: 0 auto;
}

.player-progress-area {
  height: 6px;
  background: var(--slate-border);
  border-radius: 6px;
  cursor: pointer;
  overflow: hidden;
  position: relative;
}

.player-progress-bar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--gold-accent), var(--slate-main));
  border-radius: 6px;
  transition: width 0.15s linear;
}

.player-time-display {
  display: flex;
  justify-content: space-between;
  font-size: 0.72rem;
  color: var(--text-light);
  margin-top: 0.4rem;
  margin-bottom: 1rem;
}

.player-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1.5rem;
}

.player-btn {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.player-btn:hover {
  transform: scale(1.1);
}

.player-btn.btn-secondary {
  color: var(--slate-light);
}

.player-btn.btn-primary {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  background: var(--slate-dark);
  color: #ffffff;
  box-shadow: 0 6px 18px rgba(35, 48, 59, 0.25);
}

/* 3. CUENTA REGRESIVA */
.section-countdown {
  background: var(--bg-card-alt);
}

.date-capsule {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.4rem;
  margin-bottom: 1.8rem;
}

.capsule-city {
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  color: var(--slate-main);
  font-weight: 600;
}

.capsule-box {
  background: var(--bg-card);
  border: 1px solid var(--slate-border);
  border-radius: 30px;
  padding: 1.1rem 2.4rem;
  box-shadow: var(--shadow-lux);
  display: flex;
  flex-direction: column;
  align-items: center;
}

.capsule-day-name {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  color: var(--text-muted);
}

.capsule-day-number {
  font-family: var(--font-serif);
  font-size: 3.2rem;
  font-weight: 600;
  color: var(--slate-deep);
  line-height: 1;
  margin: 0.2rem 0;
}

.capsule-month-year {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.18em;
  color: var(--gold-dark);
  font-weight: 600;
}

.countdown-heading {
  font-family: var(--font-display);
  font-size: 0.75rem;
  letter-spacing: 0.28em;
  color: var(--slate-main);
  margin-bottom: 1.2rem;
  font-weight: 600;
}

.countdown-timer-grid {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  margin-bottom: 2rem;
}

.timer-box {
  background: var(--bg-card);
  border: 1px solid var(--slate-border);
  border-radius: 14px;
  padding: 0.85rem 0.65rem;
  min-width: 60px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}

.timer-digits {
  font-family: var(--font-serif);
  font-size: 2.1rem;
  font-weight: 600;
  color: var(--slate-deep);
  display: block;
  line-height: 1;
}

.timer-label {
  font-size: 0.62rem;
  letter-spacing: 0.15em;
  color: var(--text-light);
  display: block;
  margin-top: 0.35rem;
}

.timer-separator {
  font-family: var(--font-serif);
  font-size: 1.8rem;
  color: var(--gold-accent);
  margin-top: -1.2rem;
}

.btn-calendar {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  background: var(--bg-card);
  border: 1px solid var(--slate-main);
  color: var(--slate-dark);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.05em;
  padding: 0.75rem 1.6rem;
  border-radius: var(--radius-pill);
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.04);
  transition: all 0.25s ease;
}

.btn-calendar:hover {
  background: var(--slate-main);
  color: #ffffff;
  border-color: var(--slate-main);
}

/* 4. UBICACIONES */
.section-locations {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.location-card {
  background: var(--bg-card);
  border-radius: var(--radius-card);
  padding: 2.2rem 1.6rem;
  box-shadow: var(--shadow-lux);
  border: 1px solid rgba(0,0,0,0.03);
}

.location-icon-bubble {
  width: 62px;
  height: 62px;
  border-radius: 50%;
  background: var(--slate-soft);
  color: var(--slate-main);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.2rem;
  border: 1px solid var(--slate-border);
}

.location-type {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.22em;
  color: var(--gold-dark);
  display: block;
  margin-bottom: 0.4rem;
  font-weight: 600;
}

.location-name {
  font-family: var(--font-serif);
  font-size: 1.55rem;
  font-weight: 500;
  color: var(--slate-deep);
  margin-bottom: 0.4rem;
}

.location-schedule {
  font-weight: 600;
  font-size: 0.92rem;
  color: var(--slate-main);
  margin-bottom: 0.3rem;
}

.location-address {
  font-size: 0.82rem;
  color: var(--text-muted);
  max-width: 32ch;
  margin: 0 auto 1.5rem;
}

.location-btn-group {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.btn-map, .btn-waze {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 500;
  padding: 0.72rem 1.4rem;
  border-radius: var(--radius-pill);
  transition: all 0.25s ease;
}

.btn-map {
  background: var(--slate-main);
  color: #ffffff;
}

.btn-map:hover {
  background: var(--slate-dark);
}

.btn-waze {
  background: var(--slate-soft);
  color: var(--slate-dark);
  border: 1px solid var(--slate-border);
}

.btn-waze:hover {
  background: var(--slate-border);
}

/* =========================================================
   5. ITINERARIO: REDISEÑADO CON ICONOS Y HORAS SIN RECORTES
   ========================================================= */
.section-itinerary {
  background: var(--bg-card);
}

.itinerary-card {
  padding: 0.5rem 0.2rem;
}

.itinerary-timeline {
  position: relative;
  max-width: 380px;
  margin: 2.2rem auto 0;
  display: flex;
  flex-direction: column;
  gap: 1.8rem;
}

/* Línea conectora central vertical */
.itinerary-spine-line {
  position: absolute;
  left: 104px; /* Alineada al centro del círculo del nodo */
  top: 25px;
  bottom: 25px;
  width: 2px;
  background: linear-gradient(to bottom, var(--gold-accent) 0%, var(--slate-border) 100%);
  transform-origin: top center;
  z-index: 1;
}

.itinerary-row {
  display: flex;
  align-items: flex-start;
  position: relative;
  z-index: 2;
  transition: transform 0.25s ease;
}

.itinerary-row:hover {
  transform: translateX(4px);
}

/* Columna de la Hora (Con espacio suficiente para no cortarse jamás) */
.itinerary-time-column {
  width: 82px;
  flex-shrink: 0;
  text-align: right;
  padding-right: 0.85rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: 0.35rem;
}

.itinerary-hour {
  font-family: var(--font-serif);
  font-size: 1.35rem;
  font-weight: 700;
  color: var(--slate-deep);
  line-height: 1;
}

.itinerary-period {
  font-family: var(--font-display);
  font-size: 0.65rem;
  letter-spacing: 0.12em;
  color: var(--gold-dark);
  font-weight: 600;
  margin-top: 0.15rem;
}

/* Nodo con el Icono Circular SVG */
.itinerary-node {
  width: 46px;
  flex-shrink: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 3;
}

.itinerary-icon-circle {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #ffffff;
  border: 1.5px solid var(--gold-accent);
  box-shadow: 0 4px 12px rgba(35, 48, 59, 0.08);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--slate-main);
  transition: transform 0.3s ease, border-color 0.3s ease, box-shadow 0.3s ease;
}

.itinerary-row:hover .itinerary-icon-circle {
  transform: scale(1.15) rotate(5deg);
  border-color: var(--slate-dark);
  color: var(--slate-deep);
  box-shadow: 0 6px 16px rgba(197, 168, 128, 0.3);
}

/* Columna de Título y Descripción */
.itinerary-details {
  flex: 1;
  text-align: left;
  padding-left: 0.85rem;
  padding-top: 0.25rem;
}

.itinerary-details h4 {
  font-family: var(--font-serif);
  font-size: 1.25rem;
  font-weight: 600;
  color: var(--slate-deep);
  line-height: 1.2;
  margin-bottom: 0.2rem;
}

.itinerary-details p {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.45;
}

/* 6. CÓDIGO DE VESTIMENTA */
.section-dresscode {
  background: var(--bg-card-alt);
}

.dresscode-card {
  background: var(--bg-card);
  border-radius: var(--radius-card);
  padding: 2.2rem 1.6rem;
  box-shadow: var(--shadow-lux);
}

.dresscode-icon {
  color: var(--slate-main);
  margin-bottom: 1rem;
}

.dresscode-main-style {
  font-family: var(--font-serif);
  font-size: 1.65rem;
  color: var(--slate-deep);
  font-weight: 500;
  margin-bottom: 0.4rem;
}

.dresscode-instruction {
  font-size: 0.82rem;
  color: var(--text-muted);
  max-width: 30ch;
  margin: 0 auto 1.6rem;
}

.color-palette-warning {
  border-top: 1px solid var(--slate-border);
  padding-top: 1.4rem;
}

.warning-title {
  font-family: var(--font-display);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--gold-dark);
  display: block;
  margin-bottom: 0.8rem;
  font-weight: 600;
}

.reserved-colors-row {
  display: flex;
  justify-content: center;
  gap: 1.8rem;
  margin-bottom: 0.9rem;
}

.reserved-swatch {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
}

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

.swatch-white {
  background: #ffffff;
  border-color: #ddd;
}

.swatch-red {
  background: #c93b3b;
}

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

.warning-note {
  font-size: 0.78rem;
  color: var(--text-light);
  font-style: italic;
}

/* 7. GALERÍA FOTOGRÁFICA */
.section-gallery {
  background: var(--bg-card);
}

.gallery-mosaic {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.85rem;
  max-width: 380px;
  margin: 0 auto;
}

.gallery-item {
  position: relative;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow-float);
  cursor: pointer;
  background: #111;
}

.gallery-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.6s cubic-bezier(0.33, 1, 0.68, 1), opacity 0.4s ease;
}

.gallery-item:hover img {
  transform: scale(1.06);
  opacity: 0.88;
}

.gallery-item.item-large {
  grid-column: span 2;
  height: 260px;
}

.gallery-item.item-medium {
  height: 200px;
}

.item-overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.28);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s ease;
}

.gallery-item:hover .item-overlay {
  opacity: 1;
}

/* 8. SUGERENCIA DE REGALOS */
.section-gifts {
  background: var(--bg-card-alt);
}

.gifts-card {
  background: var(--bg-card);
  border-radius: var(--radius-card);
  padding: 1.6rem 1.4rem 2.2rem;
  box-shadow: var(--shadow-lux);
}

.gift-hero-photo-wrap {
  width: 100%;
  height: 240px;
  border-radius: 18px;
  overflow: hidden;
  margin-bottom: 1.5rem;
  box-shadow: var(--shadow-float);
}

.gift-hero-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 30%;
  transition: transform 0.6s ease;
}

.gift-hero-photo-wrap:hover .gift-hero-img {
  transform: scale(1.04);
}

.gift-icon-bubble {
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: var(--gold-light);
  color: var(--gold-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: -38px auto 1rem;
  position: relative;
  z-index: 2;
  box-shadow: 0 4px 14px rgba(0,0,0,0.1);
  border: 1px solid var(--gold-accent);
}

.gifts-text {
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.6;
  max-width: 32ch;
  margin: 0 auto 1.4rem;
}

/* Opción 1: Lluvia de Sobres */
.gift-sealed-envelope-card {
  background: var(--bg-app);
  border: 1px solid var(--gold-accent);
  border-radius: 18px;
  padding: 1.4rem 1.2rem;
  margin-bottom: 1.2rem;
  box-shadow: 0 4px 15px rgba(181, 148, 98, 0.08);
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 0.5rem;
}

.gift-sealed-icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  background: #ffffff;
  color: var(--gold-dark);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
  border: 1px solid var(--gold-accent);
}

.gift-option-title {
  font-family: var(--font-serif);
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--slate-dark);
  letter-spacing: 0.02em;
}

.gift-option-desc {
  font-size: 0.84rem;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 36ch;
}

/* Divisor Ornamental */
.gift-or-divider {
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  margin: 1.4rem 0 1.1rem;
  position: relative;
}

.gift-or-divider::before,
.gift-or-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--slate-border);
}

.gift-or-divider span {
  padding: 0 0.8rem;
  font-family: var(--font-display);
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  color: var(--text-muted);
  text-transform: uppercase;
}

.digital-gift-note {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.55;
  margin-bottom: 0.8rem;
  text-align: center;
}

.bank-accounts-box {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  text-align: left;
}

.bank-item {
  background: var(--bg-app);
  border: 1px solid var(--slate-border);
  border-radius: 16px;
  padding: 1.2rem;
}

.bank-header {
  margin-bottom: 0.5rem;
}

.bank-name {
  font-family: var(--font-display);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  color: var(--slate-dark);
  font-weight: 600;
}

.bank-data-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.4rem;
  font-size: 0.82rem;
  margin-top: 0.4rem;
}

.data-label {
  color: var(--text-muted);
  width: 55px;
  flex-shrink: 0;
}

.data-val {
  color: var(--text-main);
  font-family: monospace;
  font-size: 0.88rem;
  flex: 1;
  word-break: break-all;
}

.btn-copy-small {
  background: #ffffff;
  border: 1px solid var(--slate-main);
  color: var(--slate-dark);
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.32rem 0.7rem;
  border-radius: 20px;
  font-size: 0.72rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-copy-small:hover {
  background: var(--slate-main);
  color: #ffffff;
}

.bank-titular {
  font-size: 0.72rem;
  color: var(--text-light);
  margin-top: 0.5rem;
}

.bank-yape {
  background: #fbf5ef;
  border-color: #eeddcc;
}

.gift-envelope-note {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 1.5rem;
  font-style: italic;
}

/* 9. SOLO ADULTOS */
.section-adults {
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.adults-card {
  background: var(--bg-card);
  border-radius: var(--radius-card);
  padding: 1.9rem 1.6rem;
  border: 1px dashed var(--slate-border);
}

.adults-icon {
  color: var(--gold-dark);
  margin-bottom: 0.6rem;
}

.adults-title {
  font-family: var(--font-serif);
  font-size: 1.4rem;
  color: var(--slate-deep);
  margin-bottom: 0.4rem;
}

.adults-text {
  font-size: 0.82rem;
  color: var(--text-muted);
  line-height: 1.55;
  max-width: 32ch;
  margin: 0 auto;
}

/* 10. CONFIRMACIÓN RSVP */
.section-rsvp {
  background: var(--bg-card);
}

.rsvp-card {
  border-radius: var(--radius-card);
}

.rsvp-icon {
  color: var(--slate-main);
  margin-bottom: 0.6rem;
}

.rsvp-deadline {
  font-size: 0.83rem;
  color: var(--text-muted);
  max-width: 32ch;
  margin: 0 auto 1.8rem;
}

.rsvp-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
  max-width: 330px;
  margin: 0 auto;
  text-align: left;
}

.input-group {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
}

.input-group label {
  font-size: 0.75rem;
  font-weight: 500;
  color: var(--slate-deep);
}

.input-group input,
.input-group select,
.input-group textarea {
  border: 1px solid var(--slate-border);
  border-radius: 12px;
  padding: 0.78rem 0.95rem;
  font-size: 0.88rem;
  background: #ffffff;
  color: var(--text-main);
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.input-group input:focus,
.input-group select:focus,
.input-group textarea:focus {
  outline: none;
  border-color: var(--slate-main);
  box-shadow: 0 0 0 3px rgba(71, 93, 110, 0.14);
}

.rsvp-buttons-stack {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  margin-top: 0.6rem;
}

.btn-confirm-direct,
.btn-confirm-whatsapp {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  border: none;
  padding: 0.92rem 1.4rem;
  border-radius: var(--radius-pill);
  font-size: 0.88rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  cursor: pointer;
  transition: all 0.25s ease;
  box-shadow: var(--shadow-float);
}

.btn-confirm-direct {
  background: var(--slate-dark);
  color: #ffffff;
}

.btn-confirm-direct:hover {
  background: #1c2730;
  transform: translateY(-2px);
}

.btn-confirm-whatsapp {
  background: #25d366;
  color: #ffffff;
}

.btn-confirm-whatsapp:hover {
  background: #1ebc57;
  transform: translateY(-2px);
}

.rsvp-success-panel {
  margin-top: 1.5rem;
  padding: 1.8rem;
  background: var(--slate-soft);
  border-radius: 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.5rem;
}

.success-icon-badge {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  background: var(--slate-main);
  color: #ffffff;
  font-size: 1.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rsvp-success-panel h3 {
  font-family: var(--font-serif);
  font-size: 1.55rem;
  color: var(--slate-deep);
}

.rsvp-success-panel p {
  font-size: 0.82rem;
  color: var(--text-muted);
}

/* 11. PIE DE PÁGINA / CIERRE */
.section-footer {
  background: var(--slate-deep);
  color: #ffffff;
  padding: 3.8rem 1.4rem 3.2rem;
  position: relative;
}

.footer-seal-emblem {
  width: 72px;
  height: 72px;
  margin: 0 auto 1.2rem;
}

.footer-seal-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: drop-shadow(0 6px 14px rgba(0,0,0,0.35));
}

.footer-title {
  font-family: var(--font-serif);
  font-size: 2.3rem;
  font-weight: 400;
  margin-bottom: 0.4rem;
}

.footer-names {
  font-family: var(--font-display);
  font-size: 0.9rem;
  letter-spacing: 0.25em;
  color: var(--gold-light);
  margin-bottom: 0.4rem;
}

.footer-date-line {
  font-size: 0.78rem;
  letter-spacing: 0.18em;
  opacity: 0.75;
}

.footer-monogram-text {
  font-family: var(--font-serif);
  font-size: 2.2rem;
  letter-spacing: 0.2em;
  opacity: 0.2;
  margin-top: 1.6rem;
}

/* =========================================================
   MODAL LIGHTBOX
   ========================================================= */
.lightbox-modal {
  position: fixed;
  inset: 0;
  z-index: 999999;
  background: rgba(10, 15, 20, 0.94);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1.5rem;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.lightbox-modal.active {
  opacity: 1;
  visibility: visible;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 25px;
  background: none;
  border: none;
  color: #ffffff;
  font-size: 2.8rem;
  line-height: 1;
  cursor: pointer;
  z-index: 10;
}

.lightbox-body {
  max-width: 92vw;
  max-height: 88vh;
}

.lightbox-image {
  max-width: 100%;
  max-height: 85vh;
  object-fit: contain;
  border-radius: 14px;
  box-shadow: 0 12px 45px rgba(0,0,0,0.7);
  transform: scale(0.95);
  transition: transform 0.3s ease;
}

.lightbox-modal.active .lightbox-image {
  transform: scale(1);
}

/* Notificación Toast */
.toast-notice {
  position: fixed;
  bottom: 85px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: rgba(30, 42, 51, 0.94);
  color: #ffffff;
  font-size: 0.82rem;
  padding: 0.65rem 1.5rem;
  border-radius: 25px;
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
  border: 1px solid rgba(197, 168, 128, 0.3);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
  z-index: 9999;
  white-space: nowrap;
}

.toast-notice.show {
  opacity: 1;
  visibility: visible;
  transform: translateX(-50%) translateY(0);
}

/* Responsividad de Escritorio */
@media (min-width: 480px) {
  .wedding-viewport {
    margin: 25px auto;
    border-radius: 30px;
    overflow: hidden;
  }
}
:where(button, a, input, select, textarea, [tabindex]):focus-visible {
  outline: 3px solid #b9cddd;
  outline-offset: 3px;
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    scroll-behavior: auto !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
