/* =========================================================================
   INVITACIÓN DIGITAL DE BODA — SORAYA & MANUEL
   Estilo Editorial Papelería: Pergamino Crema, Seda Champán y Marrón Espresso
   ========================================================================= */

:root {
  --paper: #efe8dc;
  --paper-soft: #f6f1e8;
  --paper-card: #fbf8f2;
  --espresso: #4a3c32;
  --espresso-deep: #3d3129;
  --taupe: #7d6958;
  --champagne: #d7c7b0;
  --gold: #b49257;
  --gold-dark: #8c6d36;
  --olive: #566b49;
  --whatsapp: #258d52;

  --ink: #3c3129;
  --ink-soft: #66584d;
  --ink-light: #f4eee4;
  --ink-light-soft: rgba(244, 238, 228, 0.84);

  --line-dark: rgba(60, 49, 41, 0.24);
  --line-light: rgba(244, 238, 228, 0.28);

  --font-display: "Cormorant Garamond", Georgia, serif;
  --font-script: "Great Vibes", cursive;
  --font-handwriting: "La Belle Aurore", cursive;
  --font-sans: "Montserrat", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;

  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --shadow-paper: 0 18px 46px rgba(56, 44, 34, 0.14);
}

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

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

body {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.6;
  color: var(--ink);
  background: #dfd7ca;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

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

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

a {
  color: inherit;
  text-decoration: none;
}

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

.text-center {
  text-align: center;
}

/* =========================================================================
   1. SOBRE DE PAPEL ANIMADO EN 3D CON SELLO DE LACRE DORADO
   ========================================================================= */

.envelope-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  overflow: hidden;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
  background: transparent;
  transition: opacity 0.65s var(--ease-out);
}

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

.skip-intro-btn {
  position: fixed;
  top: max(18px, env(safe-area-inset-top, 18px));
  left: 18px;
  z-index: 1040;
  padding: 8px 16px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.28);
  background: rgba(58, 46, 38, 0.64);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  color: #faf7f2;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.1em;
  cursor: pointer;
  transition: background-color 0.25s ease, opacity 0.4s ease;
}

.skip-intro-btn:hover {
  background: rgba(58, 46, 38, 0.85);
}

.envelope-overlay.is-opening .skip-intro-btn {
  opacity: 0;
  pointer-events: none;
}

.envelope-stage {
  position: relative;
  width: 100%;
  height: 100%;
  cursor: pointer;
}

.flap-shadow-wrap {
  position: absolute;
  inset: 0;
  will-change: transform, opacity;
  transition: transform 1.05s cubic-bezier(0.32, 0.02, 0.22, 1), opacity 0.85s ease;
}

.flap-left-wrap {
  z-index: 2;
}

.flap-right-wrap {
  z-index: 3;
}

.flap-bottom-wrap {
  z-index: 4;
}

.envelope-flap {
  position: absolute;
  inset: 0;
  background-color: #ece4d6;
  background-image: url("../assets/images/envelope-magnolia.webp");
  background-size: 100% 100%;
  background-position: center;
  background-repeat: no-repeat;
}

.flap-left {
  -webkit-clip-path: polygon(0% 0%, 6.2% 0%, 52.4% 50.2%, 0% 100%);
  clip-path: polygon(0% 0%, 6.2% 0%, 52.4% 50.2%, 0% 100%);
}

.flap-right {
  -webkit-clip-path: polygon(100% 9.2%, 52.4% 50.2%, 100% 100%);
  clip-path: polygon(100% 9.2%, 52.4% 50.2%, 100% 100%);
}

.flap-bottom {
  -webkit-clip-path: polygon(
    0% 100%,
    100% 100%,
    100% 88.2%,
    52.4% 50.2%,
    0% 89.2%
  );
  clip-path: polygon(
    0% 100%,
    100% 100%,
    100% 88.2%,
    52.4% 50.2%,
    0% 89.2%
  );
}

.flap-top-perspective {
  position: absolute;
  inset: 0;
  z-index: 6;
  perspective: 1800px;
  perspective-origin: 50% 0%;
  pointer-events: none;
}

.flap-top-3d {
  position: relative;
  width: 100%;
  height: 100%;
  transform-origin: 50% 0%;
  transform-style: preserve-3d;
  will-change: transform;
  transition: transform 1.08s cubic-bezier(0.42, 0.04, 0.22, 1);
}

.flap-top-face {
  position: absolute;
  inset: 0;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
}

.flap-top-shadow {
  filter: none;
}

.flap-top {
  -webkit-clip-path: polygon(5.6% 0%, 100% 0%, 100% 9.8%, 52.5% 51.4%);
  clip-path: polygon(5.6% 0%, 100% 0%, 100% 9.8%, 52.5% 51.4%);
}

.flap-top-back {
  transform: rotateX(180deg);
}

.flap-top-inner {
  -webkit-clip-path: polygon(5.6% 0%, 100% 0%, 100% 9.8%, 52.5% 51.4%);
  clip-path: polygon(5.6% 0%, 100% 0%, 100% 9.8%, 52.5% 51.4%);
  background-color: #ebe2d2;
  background-image: linear-gradient(
    180deg,
    rgba(215, 200, 178, 0.96) 0%,
    rgba(241, 234, 222, 0.98) 100%
  );
}

.wax-seal-btn {
  position: absolute;
  top: 50%;
  left: 52.5%;
  z-index: 12;
  transform: translate(-50%, -50%);
  width: clamp(128px, 34vw, 166px);
  height: clamp(128px, 34vw, 166px);
  padding: 0;
  border: none;
  background: transparent;
  cursor: pointer;
  display: grid;
  place-items: center;
  outline: none;
  transition: transform 0.45s var(--ease-out), opacity 0.45s ease;
}

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

.wax-seal-halo {
  position: absolute;
  inset: -4px;
  border-radius: 50%;
  border: 2.5px solid rgba(206, 162, 80, 0.86);
  box-shadow: 0 0 18px rgba(218, 176, 94, 0.62), inset 0 0 10px rgba(255, 245, 214, 0.38);
  animation: sealPulse 2.6s ease-out infinite;
  pointer-events: none;
}

@keyframes sealPulse {
  0% {
    transform: scale(0.94);
    opacity: 0.92;
  }
  72% {
    transform: scale(1.28);
    opacity: 0;
  }
  100% {
    transform: scale(1.28);
    opacity: 0;
  }
}

.wax-seal-disc {
  position: relative;
  width: 100%;
  height: 100%;
  display: block;
  filter: drop-shadow(0 3px 4px rgba(56, 40, 18, 0.34))
    drop-shadow(3px 9px 14px rgba(56, 40, 18, 0.28));
  animation: sealInviteNudge 3.4s ease-in-out infinite;
}

.envelope-overlay.phase-seal .wax-seal-disc {
  animation: none;
}

@keyframes sealInviteNudge {
  0%,
  56%,
  100% {
    transform: translateY(0) scale(1) rotate(0deg);
    filter: drop-shadow(0 3px 4px rgba(56, 40, 18, 0.34))
      drop-shadow(3px 9px 14px rgba(56, 40, 18, 0.28));
  }
  63% {
    transform: translateY(-2.5px) scale(1.055) rotate(-3deg);
    filter: drop-shadow(0 5px 7px rgba(56, 40, 18, 0.32))
      drop-shadow(5px 16px 22px rgba(56, 40, 18, 0.34));
  }
  70% {
    transform: translateY(-3.5px) scale(1.06) rotate(3deg);
    filter: drop-shadow(0 6px 8px rgba(56, 40, 18, 0.34))
      drop-shadow(6px 18px 24px rgba(56, 40, 18, 0.36));
  }
  76% {
    transform: translateY(-1.5px) scale(1.035) rotate(-2deg);
    filter: drop-shadow(0 4px 6px rgba(56, 40, 18, 0.32))
      drop-shadow(4px 13px 18px rgba(56, 40, 18, 0.3));
  }
  82% {
    transform: translateY(-0.5px) scale(1.018) rotate(1.2deg);
    filter: drop-shadow(0 3px 5px rgba(56, 40, 18, 0.32))
      drop-shadow(3px 10px 15px rgba(56, 40, 18, 0.28));
  }
  88% {
    transform: translateY(0) scale(1) rotate(0deg);
    filter: drop-shadow(0 3px 4px rgba(56, 40, 18, 0.34))
      drop-shadow(3px 9px 14px rgba(56, 40, 18, 0.28));
  }
}

.wax-seal-img {
  width: 100%;
  height: 100%;
  object-fit: contain;
  filter: contrast(1.06) brightness(1.02);
  pointer-events: none;
}

.wax-seal-sheen {
  position: absolute;
  inset: 0;
  -webkit-mask-image: url("../assets/images/wax-seal-magnolia.webp");
  mask-image: url("../assets/images/wax-seal-magnolia.webp");
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
  overflow: hidden;
  pointer-events: none;
}

.wax-seal-sheen::after {
  content: "";
  position: absolute;
  inset: -30%;
  background: linear-gradient(
    115deg,
    transparent 35%,
    rgba(255, 247, 222, 0.42) 50%,
    transparent 65%
  );
  transform: translateX(-115%);
  animation: sealSheen 5.2s ease-in-out infinite;
}

@keyframes sealSheen {
  0%,
  65% {
    transform: translateX(-115%);
  }
  100% {
    transform: translateX(115%);
  }
}

.envelope-hint {
  position: absolute;
  top: calc(51% + clamp(82px, 20vw, 108px));
  left: 50%;
  z-index: 11;
  transform: translateX(-50%);
  text-align: center;
  pointer-events: none;
  transition: opacity 0.4s ease, transform 0.45s var(--ease-out);
  width: 86%;
  max-width: 280px;
  padding: 8px 16px;
  border-radius: 999px;
  background: rgba(246, 241, 232, 0.78);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}

.envelope-hint-couple {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(1.35rem, 4.2vw, 1.8rem);
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: rgba(60, 49, 41, 0.85);
  margin-bottom: 4px;
}

.envelope-hint-cta {
  display: inline-block;
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold-dark);
  animation: gentleFloat 2.6s ease-in-out infinite;
}

@keyframes gentleFloat {
  0%,
  100% {
    transform: translateY(0);
    opacity: 0.72;
  }
  50% {
    transform: translateY(4px);
    opacity: 1;
  }
}

.seal-sparkles {
  position: absolute;
  top: 50%;
  left: 52.5%;
  z-index: 14;
  pointer-events: none;
}

.sparkle-ring {
  position: absolute;
  top: 0;
  left: 0;
  width: 120px;
  height: 120px;
  margin: -60px 0 0 -60px;
  border-radius: 50%;
  border: 2px solid rgba(220, 182, 102, 0.85);
  box-shadow: 0 0 22px rgba(230, 192, 112, 0.65), inset 0 0 14px rgba(255, 240, 196, 0.45);
  opacity: 0;
  animation: sparkleRingExpand 1.05s var(--ease-out) forwards;
}

@keyframes sparkleRingExpand {
  0% {
    transform: scale(0.65);
    opacity: 0.95;
  }
  100% {
    transform: scale(2.25);
    opacity: 0;
  }
}

.sparkle-dot {
  position: absolute;
  top: 0;
  left: 0;
  width: var(--sz, 9px);
  height: var(--sz, 9px);
  margin-left: calc(var(--sz, 9px) * -0.5);
  margin-top: calc(var(--sz, 9px) * -0.5);
  border-radius: 50%;
  background: radial-gradient(circle, #fffbe8 0%, #e5be6b 55%, rgba(196, 148, 62, 0) 100%);
  box-shadow: 0 0 12px rgba(226, 186, 104, 0.95), 0 0 4px rgba(255, 248, 220, 0.9);
  opacity: 0;
  animation: sparkleBurst var(--dur, 1.35s) var(--ease-out) forwards;
}

.sparkle-star {
  border-radius: 0;
  background: linear-gradient(135deg, #fffbe8 0%, #dfb258 60%, #b5842e 100%);
  clip-path: polygon(
    50% 0%,
    62% 38%,
    100% 50%,
    62% 62%,
    50% 100%,
    38% 62%,
    0% 50%,
    38% 38%
  );
  filter: drop-shadow(0 0 6px rgba(230, 188, 98, 0.95));
  box-shadow: none;
}

@keyframes sparkleBurst {
  0% {
    transform: translate(0, 0) scale(0.25) rotate(0deg);
    opacity: 1;
  }
  28% {
    opacity: 1;
  }
  100% {
    transform: translate(var(--tx), var(--ty)) scale(0.1) rotate(var(--rot, 140deg));
    opacity: 0;
  }
}

.envelope-overlay.phase-seal .wax-seal-btn {
  transform: translate(-50%, -32%) scale(0.72) rotate(-14deg);
  opacity: 0;
  pointer-events: none;
}

.envelope-overlay.phase-seal .envelope-hint {
  opacity: 0;
  transform: translate(-50%, 14px);
}

.envelope-overlay.phase-flap .flap-top-3d {
  transform: rotateX(176deg);
}

.envelope-overlay.phase-reveal .flap-top-perspective {
  opacity: 0;
  transform: translateY(-28%);
  transition: opacity 0.6s ease, transform 0.9s var(--ease-out);
}

.envelope-overlay.phase-reveal .flap-left-wrap {
  transform: translateX(-105%);
  opacity: 0.25;
}

.envelope-overlay.phase-reveal .flap-right-wrap {
  transform: translateX(105%);
  opacity: 0.25;
}

.envelope-overlay.phase-reveal .flap-bottom-wrap {
  transform: translateY(108%);
  opacity: 0.25;
}

/* =========================================================================
   NAVEGACIÓN FLOTANTE & BOTÓN MÚSICA
   ========================================================================= */

.site-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 90;
  padding: 10px 16px;
  transform: translateY(-110%);
  opacity: 0;
  transition: transform 0.45s var(--ease-out), opacity 0.4s ease;
}

.site-nav.is-visible {
  transform: translateY(0);
  opacity: 1;
}

.nav-inner {
  max-width: 600px;
  margin: 0 auto;
  padding: 8px 18px;
  border-radius: 999px;
  background: rgba(246, 241, 232, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(180, 146, 87, 0.3);
  box-shadow: 0 10px 28px rgba(60, 49, 41, 0.12);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.nav-brand {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  color: var(--ink);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 14px;
}

.nav-links a {
  font-family: var(--font-sans);
  font-size: 0.64rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.nav-links a:hover {
  color: var(--ink);
}

.nav-links a.nav-cta {
  padding: 6px 12px;
  border-radius: 999px;
  background: var(--espresso);
  color: var(--ink-light);
}

.nav-menu-btn {
  display: none;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--line-dark);
  background: transparent;
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
}

.nav-menu-btn span {
  display: block;
  width: 16px;
  height: 1.5px;
  background: var(--ink);
  transition: transform 0.3s ease;
}

.nav-menu-btn.is-open span:first-child {
  transform: translateY(3.25px) rotate(45deg);
}

.nav-menu-btn.is-open span:last-child {
  transform: translateY(-3.25px) rotate(-45deg);
}

.mobile-drawer {
  position: fixed;
  inset: 0;
  z-index: 85;
  background: rgba(239, 232, 220, 0.97);
  backdrop-filter: blur(14px);
  display: grid;
  place-items: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.35s ease;
}

.mobile-drawer.is-open {
  opacity: 1;
  pointer-events: auto;
}

.mobile-drawer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
}

.mobile-drawer a {
  font-family: var(--font-display);
  font-size: 1.75rem;
  letter-spacing: 0.06em;
  color: var(--ink);
}

.yt-music-host {
  position: fixed;
  width: 1px;
  height: 1px;
  right: 0;
  bottom: 0;
  opacity: 0.001;
  pointer-events: none;
  overflow: hidden;
  z-index: -1;
}

.music-control-wrap[hidden] {
  display: none;
}

.music-control-wrap {
  position: fixed;
  right: 18px;
  bottom: max(18px, env(safe-area-inset-bottom, 18px));
  z-index: 80;
  display: flex;
  align-items: center;
  gap: 10px;
}

.music-tip {
  position: relative;
  padding: 7px 13px;
  border-radius: 999px;
  border: 1px solid rgba(180, 146, 87, 0.42);
  background: rgba(251, 248, 242, 0.94);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  box-shadow: 0 8px 22px rgba(60, 49, 41, 0.14);
  color: var(--espresso);
  font-family: var(--font-sans);
  font-size: 0.66rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  white-space: nowrap;
  cursor: pointer;
  opacity: 0;
  transform: translateX(10px);
  pointer-events: none;
  transition: opacity 0.55s var(--ease-out), transform 0.55s var(--ease-out);
}

.music-tip::after {
  content: "";
  position: absolute;
  top: 50%;
  right: -5px;
  width: 8px;
  height: 8px;
  background: rgba(251, 248, 242, 0.94);
  border-top: 1px solid rgba(180, 146, 87, 0.42);
  border-right: 1px solid rgba(180, 146, 87, 0.42);
  transform: translateY(-50%) rotate(45deg);
}

.music-tip.is-visible {
  opacity: 1;
  transform: translateX(0);
  pointer-events: auto;
}

.music-toggle {
  width: 46px;
  height: 46px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1px solid rgba(180, 146, 87, 0.45);
  background: rgba(246, 241, 232, 0.94);
  backdrop-filter: blur(10px);
  box-shadow: 0 8px 22px rgba(60, 49, 41, 0.18);
  display: grid;
  place-items: center;
  cursor: pointer;
  color: var(--espresso);
}

.music-toggle svg {
  width: 19px;
  height: 19px;
}

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

.music-bars i {
  display: block;
  width: 2.5px;
  background: var(--espresso);
  border-radius: 2px;
  animation: eqBar 0.9s ease-in-out infinite alternate;
}

.music-bars i:nth-child(2) {
  animation-delay: 0.25s;
}

.music-bars i:nth-child(3) {
  animation-delay: 0.5s;
}

.music-toggle.is-playing .icon-music-on {
  display: none;
}

.music-toggle.is-playing .music-bars {
  display: flex;
}

@keyframes eqBar {
  from {
    height: 4px;
  }
  to {
    height: 14px;
  }
}

/* =========================================================================
   CONTENEDOR DE TARJETÓN VERTICAL CONTINUO
   ========================================================================= */

.invitation-sheet {
  width: 100%;
  max-width: 580px;
  margin: 0 auto;
  background-color: var(--paper);
  background-image: linear-gradient(
      rgba(239, 232, 220, 0.84),
      rgba(239, 232, 220, 0.86)
    ),
    url("../assets/images/envelope-paper.jpg");
  background-size: auto, 460px auto;
  background-repeat: repeat;
  box-shadow: 0 0 80px rgba(48, 38, 30, 0.2);
  overflow: hidden;
  position: relative;
}

.sheet-block {
  position: relative;
  overflow: hidden;
}

.sheet-light {
  background: transparent;
  color: var(--ink);
}

.sheet-dark {
  background-color: var(--espresso);
  background-image: radial-gradient(
    circle at 30% 20%,
    rgba(110, 92, 76, 0.24) 0%,
    rgba(61, 49, 41, 0.96) 80%
  );
  color: var(--ink-light);
}

.sheet-inner {
  padding: 46px 28px;
  position: relative;
  z-index: 2;
}

/* Tipografía editorial compartida */
.editorial-heading {
  margin: 0 0 10px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(1.9rem, 6.5vw, 2.55rem);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  line-height: 1.15;
  color: var(--ink);
}

.heading-light {
  color: var(--ink-light);
}

.ornament-rule {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin: 0 auto 22px;
  width: 150px;
  color: var(--taupe);
  font-size: 0.72rem;
}

.ornament-rule::before,
.ornament-rule::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--line-dark);
}

.ornament-light {
  color: var(--champagne);
}

.ornament-light::before,
.ornament-light::after {
  background: var(--line-light);
}

.editorial-copy {
  margin: 0 auto 22px;
  max-width: 430px;
  font-size: 1.1rem;
  line-height: 1.62;
  color: var(--ink-soft);
}

.copy-light {
  color: var(--ink-light-soft);
}

/* Botones rectangulares elegantes en marrón espresso (estilo referencia) */
.btn-espresso {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 190px;
  padding: 13px 30px;
  border-radius: 6px;
  border: 1px solid var(--espresso);
  background: var(--espresso);
  color: var(--ink-light);
  font-family: var(--font-sans);
  font-size: 0.74rem;
  font-weight: 500;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(60, 49, 41, 0.22);
  transition: transform 0.25s var(--ease-out), background-color 0.25s ease;
}

.btn-espresso:hover {
  background: var(--espresso-deep);
  transform: translateY(-2px);
}

.btn-wa-solid {
  background: var(--whatsapp);
  border-color: var(--whatsapp);
}

.btn-outline-espresso {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 22px;
  border-radius: 6px;
  border: 1px solid var(--espresso);
  background: transparent;
  color: var(--espresso);
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
}

.btn-light-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 24px;
  border-radius: 6px;
  border: 1px solid rgba(244, 238, 228, 0.55);
  background: rgba(244, 238, 228, 0.08);
  color: var(--ink-light);
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-color 0.25s ease;
}

.btn-light-pill:hover {
  background: rgba(244, 238, 228, 0.18);
}

.link-btn {
  background: none;
  border: none;
  padding: 0;
  cursor: pointer;
  font: inherit;
  color: inherit;
  text-decoration: underline;
  text-underline-offset: 4px;
}

/* =========================================================================
   2. PORTADA EDITORIAL + FOTO + TARJETA INCLINADA
   ========================================================================= */

.hero-editorial {
  padding-top: max(30px, env(safe-area-inset-top, 30px));
  padding-bottom: 34px;
  overflow: visible;
  z-index: 5;
}

.decor-img {
  pointer-events: none;
  user-select: none;
  filter: drop-shadow(0 6px 12px rgba(48, 36, 26, 0.16));
}

.corner-floral {
  position: absolute;
  top: -14px;
  pointer-events: none;
  z-index: 1;
}

.corner-tl-under {
  left: -10px;
  top: 34px;
  width: 114px;
  transform: rotate(136deg);
  z-index: 1;
}

.corner-tl {
  left: -24px;
  top: -16px;
  width: 142px;
  transform: rotate(12deg);
  z-index: 2;
}

.corner-mr-olive {
  right: -28px;
  top: 138px;
  width: 124px;
  transform: rotate(-28deg);
  z-index: 3;
}

.hero-top-header {
  position: relative;
  z-index: 2;
  text-align: center;
  padding: 4px 24px 24px;
}

.hero-script-kicker {
  margin: 0 0 6px;
  font-family: var(--font-script);
  font-size: clamp(1.85rem, 6.2vw, 2.35rem);
  color: var(--taupe);
  line-height: 1.1;
}

.hero-editorial-names {
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(2.9rem, 11vw, 3.9rem);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  line-height: 1.05;
  color: var(--ink);
}

.hero-conjunction {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  width: 180px;
  font-size: 1.25rem;
  letter-spacing: 0.2em;
  color: var(--taupe);
  margin: 2px 0;
}

.hero-conjunction i {
  flex: 1;
  height: 1px;
  background: var(--line-dark);
}

.hero-photo-stage {
  position: relative;
  width: 100%;
  aspect-ratio: 3 / 3.7;
  overflow: hidden;
  transform: scale(0.98);
  transition: transform 1.3s var(--ease-out);
}

body.envelope-opened .hero-photo-stage {
  transform: scale(1);
}

.hero-editorial-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center 45%;
  /* Etalonaje cálido suave acorde al papel crema y marrón espresso */
  filter: brightness(0.96) contrast(0.94) saturate(0.88) sepia(0.16);
}

.hero-photo-arrow {
  position: absolute;
  left: 50%;
  bottom: 54px;
  transform: translateX(-50%);
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(251, 248, 242, 0.72);
  color: var(--espresso);
  display: grid;
  place-items: center;
  z-index: 3;
  transition: opacity 0.4s ease, transform 0.4s var(--ease-out);
}

.hero-photo-arrow.is-hidden {
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 10px);
}

.hero-photo-arrow svg {
  width: 20px;
  height: 20px;
  animation: arrowBob 2.1s ease-in-out infinite;
}

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

/* Tarjeta blanca inclinada solapada bajo la foto */
.welcome-note-wrap {
  position: relative;
  z-index: 4;
  margin: -42px auto 12px;
  padding: 0 22px;
  max-width: 440px;
}

.note-floral-top {
  position: relative;
  z-index: 3;
  width: min(86%, 310px);
  margin: 0 auto -26px;
  display: block;
}

.note-floral-bl {
  position: absolute;
  left: -4px;
  bottom: -40px;
  width: 132px;
  z-index: 4;
  transform: rotate(-12deg);
}

.welcome-note-card {
  background: var(--paper-card);
  padding: 34px 28px 28px;
  border: 1px solid rgba(180, 146, 87, 0.22);
  box-shadow: var(--shadow-paper);
  transform: rotate(-1.5deg);
  text-align: center;
}

.welcome-note-card h2 {
  margin: 0 0 12px;
  font-family: var(--font-display);
  font-weight: 500;
  font-size: clamp(1.55rem, 5.5vw, 1.95rem);
  letter-spacing: 0.1em;
  color: var(--ink);
}

.welcome-note-card p {
  margin: 0 0 18px;
  font-size: 1.08rem;
  line-height: 1.56;
  color: var(--ink-soft);
}

.welcome-note-action {
  margin: 4px 0 18px;
}

.welcome-note-sign {
  display: flex;
  justify-content: center;
  padding: 4px 18px 0;
  font-family: var(--font-handwriting);
  font-size: clamp(1.22rem, 4.2vw, 1.48rem);
  line-height: 1.45;
  color: var(--taupe);
  text-align: center;
}

/* Corazoncito dibujado a mano trazo a trazo al deslizar */
.hand-heart {
  display: inline-block;
  width: 0.96em;
  height: 0.86em;
  margin-left: 0.14em;
  vertical-align: -0.1em;
  overflow: visible;
  color: currentColor;
}

.hand-heart-path {
  fill: none;
  stroke: currentColor;
  stroke-width: 2.05;
  stroke-linecap: round;
  stroke-linejoin: round;
  stroke-dasharray: 102;
  stroke-dashoffset: 102;
  opacity: 0;
}

.hand-heart.is-drawn {
  animation: heartSettle 0.55s var(--ease-out) 1.55s both;
}

.hand-heart.is-drawn .hand-heart-path {
  opacity: 1;
  animation: drawHeartStroke 1.35s cubic-bezier(0.36, 0.04, 0.24, 1) 0.28s forwards;
}

@keyframes drawHeartStroke {
  0% {
    stroke-dashoffset: 102;
  }
  100% {
    stroke-dashoffset: 0;
  }
}

@keyframes heartSettle {
  0% {
    transform: scale(1);
  }
  45% {
    transform: scale(1.16) rotate(-4deg);
  }
  100% {
    transform: scale(1) rotate(0deg);
  }
}

/* =========================================================================
   3. FECHA (TABLA 3 COLUMNAS) + CUENTA ATRÁS + ASISTIRÉ
   ========================================================================= */

.section-date .sheet-inner {
  padding-top: 26px;
  padding-bottom: 18px;
}

.date-ledger {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  border-top: 1px solid var(--line-dark);
  border-bottom: 1px solid var(--line-dark);
  margin: 8px auto 12px;
  max-width: 440px;
}

.date-ledger-col {
  padding: 16px 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 2px;
}

.date-ledger-mid {
  border-left: 1px solid var(--line-dark);
  border-right: 1px solid var(--line-dark);
}

.ledger-top {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--ink-soft);
}

.ledger-big {
  font-family: var(--font-display);
  font-size: clamp(1.85rem, 6.2vw, 2.35rem);
  font-weight: 400;
  line-height: 1.1;
  color: var(--ink);
}

.date-subnote {
  margin: 0 0 24px;
  font-size: 0.96rem;
  letter-spacing: 0.08em;
  color: var(--taupe);
}

.countdown-strip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 14px 22px;
  margin-bottom: 24px;
  border: 1px solid rgba(180, 146, 87, 0.3);
  background: rgba(251, 248, 242, 0.72);
  border-radius: 6px;
}

.countdown-cell {
  min-width: 46px;
}

.countdown-num {
  display: block;
  font-family: var(--font-display);
  font-size: 1.75rem;
  font-weight: 500;
  line-height: 1;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}

.countdown-label {
  display: block;
  margin-top: 4px;
  font-family: var(--font-sans);
  font-size: 0.58rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--taupe);
}

.countdown-colon {
  font-size: 1.35rem;
  color: var(--gold);
  margin-top: -12px;
}

.countdown-finished {
  margin: 18px 0;
  font-size: 1.45rem;
  font-style: italic;
  color: var(--taupe);
}

.invite-cta-inline {
  margin: 4px 0 18px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.invite-cta-script {
  margin: 0;
  font-family: var(--font-script);
  font-size: clamp(2.1rem, 6.8vw, 2.6rem);
  color: var(--espresso);
  line-height: 1.1;
}

.calendar-mini-links {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  color: var(--ink-soft);
}

.calendar-mini-links a {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.wax-divider {
  margin: 28px auto 4px;
  width: 54px;
  height: 54px;
  filter: drop-shadow(0 6px 12px rgba(60, 49, 41, 0.24));
}

/* =========================================================================
   4. EL LUGAR (POLAROID + BOTÓN MAPA SUPERPUESTO)
   ========================================================================= */

.section-venue .sheet-inner {
  padding-top: 14px;
  padding-bottom: 36px;
}

.venue-script-name {
  margin: 4px 0 8px;
  font-family: var(--font-script);
  font-size: clamp(2rem, 6.5vw, 2.55rem);
  color: var(--taupe);
  line-height: 1.1;
}

.venue-address-line {
  margin: 0 auto 10px;
  max-width: 380px;
  font-size: 1.04rem;
  font-weight: 500;
  color: var(--ink);
}

.venue-intro-copy {
  margin: 0 auto 24px;
  max-width: 410px;
  font-size: 1rem;
  color: var(--ink-soft);
}

.polaroid-venue {
  position: relative;
  max-width: 420px;
  margin: 0 auto 26px;
  padding-bottom: 18px;
}

.polaroid-frame {
  background: var(--paper-card);
  padding: 12px 12px 34px;
  box-shadow: var(--shadow-paper);
  border: 1px solid rgba(180, 146, 87, 0.18);
}

.polaroid-frame img {
  width: 100%;
  aspect-ratio: 4 / 3;
  object-fit: cover;
  filter: sepia(0.1) contrast(0.96);
}

.polaroid-blossom-bl {
  position: absolute;
  left: -24px;
  bottom: -6px;
  width: 112px;
  z-index: 4;
  transform: rotate(-14deg);
}

.polaroid-map-btn {
  position: absolute;
  left: 50%;
  bottom: 0;
  transform: translateX(-50%);
  white-space: nowrap;
}

.polaroid-map-btn:hover {
  transform: translateX(-50%) translateY(-2px);
}

.venue-extra-links {
  margin-bottom: 14px;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--taupe);
}

.venue-extra-links a {
  text-decoration: underline;
  text-underline-offset: 4px;
}

.map-accordion {
  max-width: 420px;
  margin: 0 auto;
}

.map-accordion summary {
  cursor: pointer;
  font-family: var(--font-sans);
  font-size: 0.7rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
  padding: 8px;
}

.venue-map-frame {
  margin-top: 10px;
  height: 240px;
  border-radius: 6px;
  overflow: hidden;
  border: 1px solid var(--line-dark);
}

.venue-map-frame iframe {
  width: 100%;
  height: 100%;
  border: 0;
  filter: sepia(18%) saturate(82%);
}

/* =========================================================================
   TRANSICIONES DE SEDA CHAMPÁN REAL
   ========================================================================= */

.silk-transition {
  position: relative;
  width: 100%;
  height: clamp(92px, 24vw, 146px);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: -1px 0;
  overflow: visible;
  z-index: 4;
}

.silk-to-dark {
  background: linear-gradient(180deg, var(--paper) 0%, var(--paper) 49%, var(--espresso) 51%, var(--espresso) 100%);
}

.silk-to-light {
  background: linear-gradient(180deg, var(--espresso) 0%, var(--espresso) 49%, var(--paper) 51%, var(--paper) 100%);
}

.silk-drape-img {
  position: relative;
  width: 108%;
  max-width: none;
  height: auto;
  display: block;
  filter: drop-shadow(0 8px 16px rgba(42, 30, 20, 0.22));
  z-index: 2;
}

.silk-flip {
  transform: scaleX(-1);
}

.silk-with-garland {
  margin-top: 20px;
}

.silk-garland-top {
  position: absolute;
  top: -36px;
  left: 50%;
  transform: translateX(-50%);
  width: min(78%, 310px);
  z-index: 3;
}

.silk-seal {
  position: absolute;
  top: 52%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 48px;
  height: 48px;
  z-index: 5;
  filter: drop-shadow(0 5px 12px rgba(42, 32, 24, 0.38));
}

/* =========================================================================
   5. PROGRAMA DEL DÍA (MARRÓN ESPRESSO)
   ========================================================================= */

.side-olive-branch {
  position: absolute;
  right: -28px;
  top: 42%;
  width: 132px;
  pointer-events: none;
  z-index: 2;
  transform: rotate(-18deg);
  filter: drop-shadow(0 8px 16px rgba(20, 14, 10, 0.35));
}

.side-olive-left {
  position: absolute;
  left: -34px;
  bottom: 18%;
  width: 126px;
  pointer-events: none;
  z-index: 2;
  transform: scaleX(-1) rotate(-14deg);
  filter: drop-shadow(0 8px 16px rgba(20, 14, 10, 0.35));
}

.program-header {
  position: relative;
  margin-bottom: 32px;
}

.program-script-sub {
  margin: -8px 0 0;
  font-family: var(--font-script);
  font-size: 2.1rem;
  color: var(--champagne);
  line-height: 1;
}

.program-heart {
  position: absolute;
  top: 16px;
  right: 12px;
  font-size: 1.5rem;
  color: rgba(244, 238, 228, 0.55);
}

.espresso-timeline {
  position: relative;
  max-width: 420px;
  margin: 0 auto;
  padding-left: 56px;
}

.timeline-rail {
  position: absolute;
  left: 20px;
  top: 14px;
  bottom: 14px;
  width: 1.5px;
  background: rgba(244, 238, 228, 0.24);
}

.timeline-rail-fill {
  width: 100%;
  height: 0%;
  background: var(--champagne);
  transition: height 0.18s linear;
}

.program-row {
  position: relative;
  padding-bottom: 26px;
}

.program-row:last-child {
  padding-bottom: 0;
}

.program-dot {
  position: absolute;
  left: -56px;
  top: 4px;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: var(--paper-card);
  color: var(--espresso);
  display: grid;
  place-items: center;
  border: 1.5px solid transparent;
  box-shadow: 0 6px 16px rgba(0, 0, 0, 0.22);
  transition: transform 0.42s var(--ease-out), box-shadow 0.42s var(--ease-out),
    border-color 0.35s ease, background-color 0.35s ease;
}

.program-dot svg {
  width: 19px;
  height: 19px;
  transform-origin: center;
  transition: transform 0.35s var(--ease-out);
}

.program-row.is-passed .program-dot {
  border-color: rgba(215, 195, 165, 0.7);
}

.program-row.is-active .program-dot {
  transform: scale(1.1);
  border-color: var(--champagne);
  background: #fffcf6;
  box-shadow: 0 0 0 5px rgba(215, 195, 165, 0.22), 0 8px 20px rgba(0, 0, 0, 0.28);
}

/* Micro-animaciones temáticas por icono al pasar con el scroll (arriba o abajo) */
.espresso-timeline .program-row:nth-child(2).is-active .program-dot svg {
  animation: iconClockTick 0.9s var(--ease-out) both;
}

.espresso-timeline .program-row:nth-child(3).is-active .program-dot svg {
  animation: iconHeartBeat 0.95s ease-in-out both;
}

.espresso-timeline .program-row:nth-child(4).is-active .program-dot svg {
  animation: iconToastTilt 0.95s var(--ease-out) both;
}

.espresso-timeline .program-row:nth-child(5).is-active .program-dot svg {
  animation: iconBanquetWiggle 0.9s ease-in-out both;
}

.espresso-timeline .program-row:nth-child(6).is-active .program-dot svg {
  animation: iconMusicBounce 0.95s ease-in-out both;
}

.espresso-timeline .program-row:nth-child(7).is-active .program-dot svg {
  animation: iconMoonSway 1.05s ease-in-out both;
}

@keyframes iconClockTick {
  0% { transform: rotate(0deg) scale(0.92); }
  25% { transform: rotate(-18deg) scale(1.12); }
  55% { transform: rotate(16deg) scale(1.12); }
  80% { transform: rotate(-6deg) scale(1.04); }
  100% { transform: rotate(0deg) scale(1); }
}

@keyframes iconHeartBeat {
  0% { transform: scale(1); }
  20% { transform: scale(1.28); }
  38% { transform: scale(0.96); }
  58% { transform: scale(1.22); }
  100% { transform: scale(1); }
}

@keyframes iconToastTilt {
  0% { transform: rotate(0deg) translateY(0); }
  30% { transform: rotate(-16deg) translateY(-2px) scale(1.1); }
  62% { transform: rotate(12deg) translateY(-1px) scale(1.08); }
  100% { transform: rotate(0deg) translateY(0) scale(1); }
}

@keyframes iconBanquetWiggle {
  0% { transform: scale(0.94) rotate(0deg); }
  30% { transform: scale(1.14) rotate(10deg); }
  60% { transform: scale(1.14) rotate(-10deg); }
  82% { transform: scale(1.05) rotate(4deg); }
  100% { transform: scale(1) rotate(0deg); }
}

@keyframes iconMusicBounce {
  0% { transform: translateY(0) rotate(0deg); }
  25% { transform: translateY(-4px) rotate(-10deg) scale(1.12); }
  52% { transform: translateY(1px) rotate(8deg) scale(1.05); }
  76% { transform: translateY(-3px) rotate(-5deg) scale(1.08); }
  100% { transform: translateY(0) rotate(0deg) scale(1); }
}

@keyframes iconMoonSway {
  0% { transform: rotate(0deg) scale(0.94); }
  35% { transform: rotate(-20deg) scale(1.14); }
  72% { transform: rotate(10deg) scale(1.08); }
  100% { transform: rotate(0deg) scale(1); }
}

.program-hour {
  display: block;
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 400;
  line-height: 1.05;
  color: var(--ink-light);
}

.program-info h3 {
  margin: 2px 0 4px;
  font-family: var(--font-sans);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.16em;
  color: var(--champagne);
}

.program-info p {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.48;
  color: var(--ink-light-soft);
}

/* =========================================================================
   6. VESTIMENTA (PALETA DE 6 CÍRCULOS) + SOBRE DETALLES
   ========================================================================= */

.tiny-heart {
  display: block;
  margin: -10px 0 18px;
  color: var(--taupe);
  font-size: 1.1rem;
}

.palette-swatches {
  display: grid;
  grid-template-columns: repeat(3, 64px);
  justify-content: center;
  gap: 14px 18px;
  margin: 0 auto 42px;
}

.swatch {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  background: var(--sw);
  border: 2px solid rgba(251, 248, 242, 0.75);
  box-shadow: 0 8px 18px rgba(60, 49, 41, 0.16);
}

/* Mini sobre decorativo "DETALLES" */
.details-envelope-emblem {
  position: relative;
  width: 196px;
  height: 122px;
  margin: 12px auto -58px;
  z-index: 3;
}

.mini-env-card {
  position: absolute;
  top: 0;
  left: 18px;
  right: 18px;
  height: 82px;
  background: var(--paper-card);
  border: 1px solid rgba(180, 146, 87, 0.25);
  box-shadow: 0 8px 20px rgba(60, 49, 41, 0.12);
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 16px;
  font-family: var(--font-display);
  font-size: 1.25rem;
  letter-spacing: 0.16em;
  color: var(--ink);
  transform: rotate(-3deg);
}

.mini-env-front {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 76px;
  background: linear-gradient(180deg, #e5dac9 0%, #f3ece0 100%);
  clip-path: polygon(0 0, 50% 42%, 100% 0, 100% 100%, 0 100%);
  box-shadow: 0 10px 22px rgba(40, 30, 22, 0.24);
}

.mini-env-seal {
  position: absolute;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  width: 34px;
  height: 34px;
  filter: drop-shadow(0 3px 6px rgba(42, 32, 24, 0.3));
}

.mini-env-floral {
  position: absolute;
  left: -46px;
  bottom: -24px;
  width: 96px;
  z-index: 4;
  transform: rotate(-18deg);
}

/* =========================================================================
   7. HISTORIA + DETALLES (BANDA OSCURA ESPRESSO)
   ========================================================================= */

.section-details .sheet-inner {
  padding-top: 68px;
}

.espresso-quote {
  margin: 22px auto 34px;
  padding: 18px 20px;
  max-width: 440px;
  border-top: 1px solid var(--line-light);
  border-bottom: 1px solid var(--line-light);
  font-size: 1.2rem;
  font-style: italic;
  line-height: 1.5;
  color: var(--ink-light);
}

.espresso-quote strong {
  color: var(--champagne);
  font-weight: 600;
}

.espresso-quote cite {
  display: block;
  margin-top: 8px;
  font-family: var(--font-sans);
  font-style: normal;
  font-size: 0.68rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--champagne);
}

.espresso-details-list {
  display: grid;
  gap: 28px;
  max-width: 430px;
  margin: 0 auto;
}

.espresso-detail-block h3 {
  margin: 0 0 8px;
  font-family: var(--font-display);
  font-weight: 400;
  font-size: 1.55rem;
  letter-spacing: 0.16em;
  color: var(--ink-light);
}

.espresso-detail-block p {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.56;
  color: var(--ink-light-soft);
}

.gift-iban-card {
  margin-top: 14px;
  padding: 14px;
  border: 1px solid var(--line-light);
  border-radius: 6px;
  background: rgba(244, 238, 228, 0.06);
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

.gift-iban-label {
  font-family: var(--font-sans);
  font-size: 0.65rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--champagne);
}

.gift-iban-value {
  font-family: ui-monospace, SFMono-Regular, Consolas, monospace;
  font-size: 0.9rem;
  color: var(--ink-light);
}

/* =========================================================================
   8. GALERÍA POLAROID + FORMULARIO RSVP
   ========================================================================= */

.section-gallery .sheet-inner {
  padding-bottom: 18px;
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  margin-top: 22px;
}

.gallery-item {
  border: none;
  padding: 7px 7px 20px;
  background: var(--paper-card);
  box-shadow: 0 10px 26px rgba(60, 49, 41, 0.12);
  cursor: pointer;
  overflow: hidden;
  transition: transform 0.35s var(--ease-out);
}

.gallery-item:nth-child(even) {
  transform: rotate(1deg);
}

.gallery-item:nth-child(odd) {
  transform: rotate(-1deg);
}

.gallery-item:hover {
  transform: rotate(0deg) scale(1.02);
}

.gallery-item img {
  width: 100%;
  aspect-ratio: 4 / 4.6;
  object-fit: cover;
  filter: sepia(0.08);
}

/* Formulario estilo referencia */
.section-rsvp .sheet-inner {
  padding-top: 24px;
}

.rsvp-editorial-shell {
  max-width: 440px;
  margin: 20px auto 0;
}

.rsvp-form {
  display: grid;
  gap: 16px;
}

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

.form-label {
  font-family: var(--font-sans);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--taupe);
}

.input-espresso-bar {
  width: 100%;
  padding: 14px 16px;
  border-radius: 6px;
  border: 1px solid var(--espresso);
  background: var(--espresso);
  color: var(--ink-light);
  font-family: var(--font-sans);
  font-size: 0.88rem;
}

.input-espresso-bar::placeholder {
  color: rgba(244, 238, 228, 0.72);
}

.rsvp-form input[type="text"]:not(.input-espresso-bar),
.rsvp-form input[type="tel"],
.rsvp-form select,
.rsvp-form textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 6px;
  border: 1px solid rgba(60, 49, 41, 0.22);
  background: var(--paper-card);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 0.86rem;
}

.rsvp-form input:focus,
.rsvp-form select:focus,
.rsvp-form textarea:focus {
  outline: none;
  border-color: var(--gold-dark);
  box-shadow: 0 0 0 3px rgba(180, 146, 87, 0.2);
}

.radio-stack {
  display: grid;
  gap: 10px;
  padding: 6px 2px;
}

.radio-line {
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
  font-size: 1.08rem;
  color: var(--ink);
}

.radio-line input[type="radio"] {
  accent-color: var(--espresso);
  width: 17px;
  height: 17px;
}

.attending-fields {
  display: grid;
  gap: 16px;
}

.attending-fields.is-collapsed {
  display: none;
}

.form-error {
  margin: 0;
  padding: 10px 14px;
  border-radius: 6px;
  background: rgba(154, 62, 54, 0.14);
  color: #7a2923;
  font-family: var(--font-sans);
  font-size: 0.8rem;
}

.form-submit-row {
  text-align: center;
  margin-top: 8px;
}

.rsvp-success {
  text-align: center;
  padding: 12px 0;
}

.rsvp-success h3 {
  margin: 0 0 8px;
  font-size: 1.85rem;
  font-weight: 500;
}

.rsvp-summary-box {
  margin: 16px 0 20px;
  padding: 16px;
  border-radius: 6px;
  background: var(--paper-card);
  border: 1px dashed rgba(140, 109, 54, 0.45);
  text-align: left;
  font-family: var(--font-sans);
  font-size: 0.82rem;
  line-height: 1.65;
  white-space: pre-line;
}

.rsvp-success-actions {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
}

/* =========================================================================
   9. CONTACTO & 10. CIERRE POLAROID
   ========================================================================= */

.contact-wa-buttons {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 8px;
}

.closing-polaroid {
  position: relative;
  max-width: 410px;
  margin: 0 auto 28px;
}

.closing-blossom-bl {
  position: absolute;
  left: -22px;
  bottom: -16px;
  width: 118px;
  z-index: 4;
  transform: rotate(-10deg);
}

.closing-polaroid .polaroid-frame {
  padding: 12px 12px 38px;
  transform: none;
}

.closing-polaroid .polaroid-frame img,
.closing-polaroid .closing-video {
  display: block;
  width: 100%;
  aspect-ratio: 3 / 2;
  object-fit: cover;
  background: #eae4da;
}

.closing-waiting {
  margin: 0 0 10px;
  font-size: 1.3rem;
  letter-spacing: 0.04em;
  color: var(--ink);
}

.closing-sign {
  margin: 0 0 26px;
  font-family: var(--font-handwriting);
  font-size: 1.65rem;
  line-height: 1.42;
  color: var(--taupe);
}

.btn-replay {
  padding: 10px 20px;
  border-radius: 999px;
  border: 1px solid var(--line-dark);
  background: transparent;
  color: var(--ink-soft);
  font-family: var(--font-sans);
  font-size: 0.68rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  cursor: pointer;
}

.btn-replay:hover {
  background: rgba(60, 49, 41, 0.06);
}

/* =========================================================================
   LIGHTBOX & TOAST
   ========================================================================= */

.lightbox {
  position: fixed;
  inset: 0;
  z-index: 1200;
  background: rgba(32, 25, 20, 0.94);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}

.lightbox[hidden] {
  display: none;
}

.lightbox-figure {
  margin: 0;
  max-width: min(92vw, 900px);
  max-height: 86dvh;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.lightbox-figure img {
  max-width: 100%;
  max-height: 76dvh;
  border-radius: 8px;
  object-fit: contain;
}

.lightbox-figure figcaption {
  margin-top: 14px;
  font-family: var(--font-display);
  font-size: 1.25rem;
  font-style: italic;
  color: var(--ink-light);
}

.lightbox-close,
.lightbox-nav {
  position: fixed;
  border: 1px solid rgba(255, 255, 255, 0.25);
  background: rgba(255, 255, 255, 0.08);
  color: #ffffff;
  border-radius: 50%;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.lightbox-close {
  top: 20px;
  right: 20px;
  width: 44px;
  height: 44px;
  font-size: 1.7rem;
}

.lightbox-nav {
  top: 50%;
  transform: translateY(-50%);
  width: 46px;
  height: 46px;
}

.lightbox-nav svg {
  width: 22px;
  height: 22px;
}

.lightbox-prev {
  left: 16px;
}

.lightbox-next {
  right: 16px;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 1300;
  transform: translate(-50%, 24px);
  padding: 12px 22px;
  border-radius: 999px;
  background: var(--espresso-deep);
  color: var(--ink-light);
  font-family: var(--font-sans);
  font-size: 0.78rem;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, transform 0.35s var(--ease-out);
}

.toast.is-visible {
  opacity: 1;
  transform: translate(-50%, 0);
}

/* =========================================================================
   ANIMACIONES AL SCROLL & RESPONSIVE
   ========================================================================= */

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s var(--ease-out), transform 0.8s var(--ease-out);
}

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

@media (max-width: 620px) {
  .nav-links {
    display: none;
  }

  .nav-menu-btn {
    display: flex;
  }

  .lightbox-nav {
    top: auto;
    bottom: 20px;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }
  .hand-heart-path {
    stroke-dashoffset: 0;
    opacity: 1;
    animation: none;
  }
}
