/* ==========================================================================
   Invitación XV — "Jardín de grabado y acuarela"
   Composición: una tarjeta vertical de 460 px (pantalla de móvil) centrada,
   con escenas a pantalla completa que se revelan al desplazarse.
   Los colores del tema se inyectan desde config.js (variables --f0…--f4).
   ========================================================================== */
/* Tipografías alojadas en la propia invitación (no dependen de servicios externos) */
@font-face { font-family: "Cormorant Garamond"; font-weight: 500; font-style: normal; font-display: swap; src: url("../fonts/cormorant-garamond-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-weight: 500; font-style: italic; font-display: swap; src: url("../fonts/cormorant-garamond-latin-500-italic.woff2") format("woff2"); }
@font-face { font-family: "Cormorant Garamond"; font-weight: 600; font-style: normal; font-display: swap; src: url("../fonts/cormorant-garamond-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Pinyon Script"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/pinyon-script-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Cinzel"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/cinzel-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Cinzel"; font-weight: 500; font-style: normal; font-display: swap; src: url("../fonts/cinzel-latin-500-normal.woff2") format("woff2"); }

:root {
  /* Flor (se sobrescriben según el tema) */
  --f0: #FFF4F2; --f1: #F8DCDB; --f2: #EDB7BC; --f3: #D9919C; --f4: #B56B7A;
  --leaf1: #C9D3C1; --leaf2: #8D9F86;
  --wing1: #F4D6D8; --wing2: #C99AA4;
  /* Papel, tinta y oro */
  --paper: #FFFBFA;
  --paper-2: #FBEFEE;
  --backdrop: #EFD9D9;
  --ink: #5B3B43;
  --ink-soft: #7E5D65;
  --accent: #9E5466;
  --gold: #C29D5C;
  --gold-ink: #876628;
  --line: rgba(194, 157, 92, .55);
  /* Tipografía */
  --script: "Pinyon Script", "Snell Roundhand", "Apple Chancery", cursive;
  --serif: "Cormorant Garamond", "Cormorant", Garamond, "Times New Roman", serif;
  --caps: "Cinzel", "Trajan Pro", "Cormorant Garamond", serif;
  --card-w: 460px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background:
    radial-gradient(1200px 700px at 15% 10%, var(--f1), transparent 60%),
    radial-gradient(900px 700px at 90% 80%, var(--paper-2), transparent 60%),
    var(--backdrop);
  color: var(--ink);
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.55;
  font-weight: 500;
  -webkit-font-smoothing: antialiased;
  min-height: 100%;
}
body.is-locked { overflow: hidden; }
img, svg { max-width: 100%; }
p, h1, h2, h3, figure { margin: 0; }
button, input, select, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 4px; }

/* ---------- Tarjeta ---------- */
.card {
  position: relative;
  max-width: var(--card-w);
  margin: 0 auto;
  background-color: var(--paper);
  background-image: var(--grain);
  overflow: hidden;
  box-shadow: 0 0 0 1px rgba(194, 157, 92, .18), 0 30px 80px -30px rgba(120, 60, 70, .35);
}
@media (max-width: 480px) { .card { box-shadow: none; } }

.demo-band {
  position: relative; z-index: 5; padding-right: 70px !important; padding-left: 70px !important;
  font-family: var(--caps); font-size: 10.5px; letter-spacing: .22em; text-transform: uppercase;
  text-align: center; padding: 7px 12px; color: var(--gold-ink);
  background: var(--paper-2); border-bottom: 1px solid var(--line);
}

/* ---------- Escenas ---------- */
.scene {
  position: relative;
  min-height: 100vh; min-height: 100svh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center;
  padding: 150px 34px;
  isolation: isolate;
}
.scene + .scene::before { /* costura entre escenas */
  content: ""; position: absolute; top: 0; left: 50%; width: 1px; height: 46px;
  background: linear-gradient(var(--line), transparent); transform: translateX(-50%);
}
.scene__inner { position: relative; z-index: 2; width: 100%; display: flex; flex-direction: column; align-items: center; }

.deco { position: absolute; left: -7%; width: 114%; z-index: 1; pointer-events: none; }
.deco--top { top: -10px; }
.deco--bottom { bottom: -12px; }
.deco svg { display: block; width: 100%; height: auto; }
.deco--corner-tl { top: -16px; left: -26px; width: 58%; }
.deco--corner-br { bottom: -16px; right: -26px; left: auto; width: 58%; transform: rotate(180deg); }
.deco--corner-tr { top: -16px; right: -26px; left: auto; width: 54%; transform: scaleX(-1); }
.deco--sm { width: 42% !important; }
.scene--intro { padding-bottom: 190px; }
.deco--corner-bl { bottom: -16px; left: -26px; width: 54%; transform: scaleY(-1); }

/* Tipografía */
.label {
  font-family: var(--caps); font-weight: 500; font-size: 12px; letter-spacing: .32em;
  text-transform: uppercase; color: var(--gold-ink); margin: 0;
}
.script {
  font-family: var(--script); font-weight: 400; color: var(--accent); margin: 0;
  line-height: 1.1; text-wrap: balance;
}
.h-script { font-size: 46px; }
.lead { font-size: 21px; line-height: 1.5; max-width: 30ch; margin: 0; text-wrap: pretty; font-style: italic; color: var(--ink-soft); }
.body { font-size: 19px; max-width: 32ch; margin: 0; text-wrap: pretty; }
.muted { color: var(--ink-soft); }
.gold-text {
  background: linear-gradient(135deg, #D8BC82 0%, #A9833F 40%, #E6CF98 60%, #9C7634 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}

/* ---------- Piezas ilustradas ---------- */
.art { display: block; }
.art--corner, .art--garland, .art--stem { overflow: visible; }
.crown { width: 128px; margin: 0 auto 10px; position: relative; }
.crown .spark { position: absolute; width: 14px; }
.divider { width: 170px; margin: 18px auto; }
.spark { display: block; }

/* ---------- Portada ---------- */
.scene--hero { padding-top: 190px; padding-bottom: 210px; }
.arch-wrap { position: absolute; inset: 120px 22px 70px; z-index: 1; pointer-events: none; }
.arch-wrap svg { width: 100%; height: 100%; }
.hero-xv {
  font-family: var(--caps); font-weight: 400; font-size: 96px; line-height: .9; letter-spacing: .06em;
  margin: 4px 0 0; position: relative;
}
.hero-pre { margin-bottom: 6px; }
.hero-post { margin-top: 12px; }
.hero-name { font-size: clamp(64px, 19vw, 88px); margin-top: 18px; padding: 0 .1em; }
.hero-second { font-size: 40px; margin-top: -4px; }
.hero-last { margin-top: 10px; }
.hero-date { margin-top: 22px; font-family: var(--caps); font-size: 13px; letter-spacing: .3em; color: var(--ink-soft); }
.pass-note {
  margin-top: 20px; font-style: italic; color: var(--ink-soft); font-size: 18px;
  padding: 8px 18px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
}
.scroll-cue {
  position: relative; margin-top: 26px; z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  font-family: var(--caps); font-size: 10px; letter-spacing: .3em; color: var(--gold-ink);
  background: none; border: 0; cursor: pointer; padding: 8px;
}
.scroll-cue i { width: 1px; height: 30px; background: linear-gradient(var(--gold), transparent); display: block; }

/* ---------- Presentación ---------- */
.dress { width: min(230px, 62vw); margin: 4px auto 22px; }
.scene--intro .script.big { font-size: 58px; margin-top: 8px; }

/* ---------- Mensaje ---------- */
.frame-wrap { position: absolute; inset: 70px 18px; z-index: 1; pointer-events: none; }
.frame-wrap svg { width: 100%; height: 100%; }
.stem-l { position: absolute; left: 4px; bottom: 60px; width: 74px; z-index: 2; pointer-events: none; }
.stem-r { position: absolute; right: 4px; top: 60px; width: 74px; z-index: 2; pointer-events: none; transform: rotate(180deg); }
.quote-mark { font-family: var(--script); font-size: 80px; line-height: .5; color: var(--f3); margin-bottom: 10px; }
.signature { font-family: var(--script); font-size: 38px; color: var(--accent); margin-top: 16px; }

/* ---------- Familia ---------- */
.family { display: grid; gap: 30px; width: 100%; margin-top: 8px; }
.family__group { display: grid; gap: 6px; }
.family__group .script { font-size: 40px; }
.family__names { display: grid; gap: 2px; font-size: 21px; }

/* ---------- Celebración ---------- */
.date-block { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; gap: 14px; margin: 14px 0 6px; width: 100%; max-width: 320px; }
.date-block__side { font-family: var(--caps); font-size: 14px; letter-spacing: .24em; color: var(--ink); padding: 8px 0; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
.date-block__day { font-family: var(--caps); font-size: 58px; line-height: 1; padding: 0 6px; }
.date-year { font-family: var(--caps); letter-spacing: .4em; font-size: 13px; color: var(--ink-soft); margin-top: 6px; }
.date-tbd { font-style: italic; color: var(--ink-soft); }
.countdown { display: grid; grid-template-columns: repeat(4, 62px); gap: 10px; justify-content: center; margin: 24px 0 8px; }
.countdown__unit {
  width: 62px; height: 62px; border-radius: 50%; border: 1px solid var(--line);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .55);
}
.countdown__num { font-family: var(--caps); font-size: 20px; line-height: 1; font-variant-numeric: tabular-nums; color: var(--accent); }
.countdown__lab { font-size: 9px; font-family: var(--caps); letter-spacing: .14em; color: var(--ink-soft); margin-top: 4px; }

.events { display: grid; gap: 22px; width: 100%; margin-top: 26px; }
.event {
  position: relative; padding: 26px 22px 24px;
  background: rgba(255, 255, 255, .62);
  border: 1px solid var(--line); border-radius: 160px 160px 14px 14px;
  display: flex; flex-direction: column; align-items: center; gap: 4px;
}
.event .ico { width: 40px; height: 40px; margin-bottom: 4px; }
.event .script { font-size: 34px; }
.event__time { font-family: var(--caps); font-size: 13px; letter-spacing: .22em; color: var(--gold-ink); margin: 4px 0 6px; }
.event__place { font-weight: 600; font-size: 19px; }
.event__addr { font-size: 17px; color: var(--ink-soft); margin-bottom: 12px; }

/* ---------- Botones ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-family: var(--caps); font-size: 11.5px; letter-spacing: .2em; text-transform: uppercase; text-decoration: none;
  padding: 13px 22px; min-height: 46px; border-radius: 999px; cursor: pointer;
  border: 1px solid var(--gold); color: var(--ink); background: rgba(255, 255, 255, .7);
  transition: background .25s, color .25s, transform .25s, box-shadow .25s;
}
.btn:hover { background: var(--paper-2); }
.btn:active { transform: scale(.98); }
.btn--solid { background: var(--accent); color: #fff; border-color: var(--accent); box-shadow: 0 8px 20px -10px var(--accent); }
.btn--solid:hover { background: var(--f4); }
.btn .ico-s { width: 17px; height: 17px; flex: none; }
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; justify-content: center; margin-top: 16px; }

/* ---------- Vestimenta ---------- */
.dress-code { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; width: 100%; max-width: 300px; margin: 22px 0 12px; }
.dress-code__item { display: flex; flex-direction: column; align-items: center; gap: 8px; }
.dress-code__item .ico { width: 70px; height: 86px; }
.dress-code__who { font-family: var(--caps); font-size: 12px; letter-spacing: .3em; color: var(--gold-ink); }
.dress-code__what { font-size: 18px; color: var(--ink-soft); font-style: italic; margin-top: -4px; }
.swatch-note { display: flex; align-items: center; gap: 12px; margin-top: 18px; max-width: 30ch; text-align: left; font-size: 18px; }
.swatch { flex: none; width: 34px; height: 34px; border-radius: 50%; background: radial-gradient(circle at 35% 30%, var(--f1), var(--f3)); box-shadow: 0 0 0 1px var(--gold), 0 0 0 4px var(--paper), 0 0 0 5px var(--line); }

/* ---------- Regalos y confirmación ---------- */
.gifts { display: grid; gap: 14px; width: 100%; margin: 20px 0 0; }
.gift { display: grid; grid-template-columns: 52px 1fr; gap: 14px; align-items: center; text-align: left; padding: 14px 16px; border-top: 1px solid var(--line); }
.gift:last-child { border-bottom: 1px solid var(--line); }
.gift .ico { width: 48px; height: 48px; }
.gift__t { font-weight: 600; font-size: 19px; }
.gift__d { font-size: 17px; color: var(--ink-soft); }
.gift a { color: var(--accent); }

.rsvp {
  width: 100%; margin-top: 40px; padding: 30px 22px 26px; text-align: left;
  background: rgba(255, 255, 255, .72); border: 1px solid var(--line); border-radius: 14px;
  display: grid; gap: 16px;
}
.rsvp__head { text-align: center; display: grid; gap: 6px; }
.rsvp__head .script { font-size: 40px; }
.field { display: grid; gap: 6px; }
.field > span, .field legend { font-family: var(--caps); font-size: 11px; letter-spacing: .2em; color: var(--gold-ink); text-transform: uppercase; padding: 0; }
.field input, .field select, .field textarea {
  width: 100%; border: 0; border-bottom: 1px solid var(--line); background: transparent;
  padding: 8px 2px; font-size: 19px; border-radius: 0; color: var(--ink);
}
.field textarea { resize: vertical; min-height: 64px; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-bottom-color: var(--accent); box-shadow: 0 1px 0 var(--accent); }
.field select { appearance: none; -webkit-appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--gold) 50%), linear-gradient(135deg, var(--gold) 50%, transparent 50%); background-position: calc(100% - 14px) 55%, calc(100% - 9px) 55%; background-size: 5px 5px; background-repeat: no-repeat; }
fieldset.field { border: 0; margin: 0; padding: 0; }
.choice { display: flex; gap: 10px; flex-wrap: wrap; margin-top: 4px; }
.choice label { flex: 1 1 130px; }
.choice input { position: absolute; opacity: 0; pointer-events: none; }
.choice span {
  display: block; text-align: center; padding: 11px 10px; border: 1px solid var(--line); border-radius: 999px;
  font-size: 17px; cursor: pointer; transition: all .2s;
}
.choice input:checked + span { background: var(--accent); color: #fff; border-color: var(--accent); }
.choice input:focus-visible + span { outline: 2px solid var(--accent); outline-offset: 2px; }
.form-error { color: #A23A4A; font-size: 16px; min-height: 1em; margin: 0; text-align: center; }
.rsvp .btn { width: 100%; }
.rsvp__fine { font-size: 15px; color: var(--ink-soft); text-align: center; margin: 0; }

/* ---------- Cierre ---------- */
.scene--end { padding-bottom: 230px; }
.bow { width: 150px; margin: 0 auto -6px; }
.end-name { font-size: 62px; margin-top: 18px; }
.made-by { position: absolute; bottom: 14px; left: 0; right: 0; text-align: center; font-family: var(--caps); font-size: 9.5px; letter-spacing: .25em; color: var(--ink-soft); opacity: .7; z-index: 3; }

/* ---------- Capa ambiental (mariposas y pétalos) ---------- */
.ambient {
  position: fixed; top: 0; bottom: 0; left: 50%; transform: translateX(-50%);
  width: min(100%, var(--card-w)); pointer-events: none; z-index: 30; overflow: hidden;
}
.ambient canvas { position: absolute; inset: 0; width: 100%; height: 100%; }
.ambient .flyer { position: absolute; top: 0; left: 0; width: 46px; will-change: transform; }
.bf { display: block; width: 100%; height: auto; overflow: visible; }
.bf__w { transform-box: view-box; transform-origin: 50% 50%; animation: flap .32s ease-in-out infinite alternate; }
.perch .bf__w { animation: flapSlow 3.6s ease-in-out infinite; }
@keyframes flap { from { transform: scaleX(1); } to { transform: scaleX(.28); } }
@keyframes flapSlow { 0%, 70%, 100% { transform: scaleX(1); } 78% { transform: scaleX(.35); } 86% { transform: scaleX(1); } 92% { transform: scaleX(.5); } }
.perch { position: absolute; z-index: 3; width: 40px; pointer-events: none; }

/* destellos */
.twinkle circle, .spark { animation: twinkle 3.2s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
.twinkle circle:nth-child(2n) { animation-delay: 1.1s; }
.twinkle circle:nth-child(3n) { animation-delay: 2.1s; }
@keyframes twinkle { 0%, 100% { opacity: .25; transform: scale(.7); } 50% { opacity: 1; transform: scale(1.1); } }

/* ---------- Controles fijos ---------- */
.ui-music {
  position: fixed; z-index: 40;
  top: calc(env(safe-area-inset-top, 0px) + 14px);
  right: max(14px, calc((100vw - var(--card-w)) / 2 + 14px), env(safe-area-inset-right, 0px));
  width: 46px; height: 46px; border-radius: 50%;
  border: 1px solid var(--gold); background: rgba(255, 251, 250, .85);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  display: grid; place-items: center; cursor: pointer; color: var(--accent);
  box-shadow: 0 6px 18px -8px rgba(120, 60, 70, .4);
}
.ui-music svg { width: 20px; height: 20px; }
.ui-music .bars { display: none; gap: 2px; align-items: flex-end; height: 16px; }
.ui-music .bars i { width: 2px; height: 9px; background: currentColor; border-radius: 1px; animation: bar 1s ease-in-out infinite; }
.ui-music .bars i:nth-child(2) { animation-delay: .2s; } .ui-music .bars i:nth-child(3) { animation-delay: .4s; } .ui-music .bars i:nth-child(4) { animation-delay: .1s; }
@keyframes bar { 0%, 100% { height: 4px; } 50% { height: 15px; } }
.ui-music[aria-pressed="true"] .bars { display: flex; }
.ui-music[aria-pressed="true"] .note { display: none; }

.ui-nav {
  position: fixed; z-index: 40; top: 50%; transform: translateY(-50%);
  right: max(8px, calc((100vw - var(--card-w)) / 2 + 8px), env(safe-area-inset-right, 0px));
  display: grid; gap: 4px;
}
.ui-nav button {
  width: 22px; height: 22px; border: 0; background: none; padding: 0; cursor: pointer;
  display: grid; place-items: center;
}
.ui-nav button::before {
  content: ""; width: 6px; height: 6px; border-radius: 50%;
  border: 1px solid var(--gold); background: rgba(255, 251, 250, .8); transition: all .3s;
}
.ui-nav button[aria-current="true"]::before { background: var(--gold); transform: scale(1.35); }

.toast {
  position: fixed; left: 50%; bottom: calc(24px + env(safe-area-inset-bottom, 0px)); transform: translate(-50%, 20px);
  z-index: 60; background: var(--ink); color: #fff; padding: 10px 18px; border-radius: 999px;
  font-size: 16px; opacity: 0; transition: all .35s; pointer-events: none; max-width: calc(100vw - 32px); text-align: center;
}
.toast.is-on { opacity: 1; transform: translate(-50%, 0); }

/* ---------- Apertura (gatefold de encaje) ---------- */
.gate {
  position: fixed; inset: 0; z-index: 100; display: flex; justify-content: center;
  background: var(--backdrop);
  perspective: 1600px;
}
.gate__stage { position: relative; width: min(100%, var(--card-w)); height: 100%; transform-style: preserve-3d; }
.gate__door {
  position: absolute; top: 0; bottom: 0; width: 50%;
  background-color: var(--f1);
  background-image:
    radial-gradient(circle at 50% 50%, rgba(255,255,255,.55) 1.2px, transparent 1.8px),
    radial-gradient(circle at 50% 50%, rgba(255,255,255,.35) 1px, transparent 1.6px),
    linear-gradient(180deg, var(--f1), var(--f2));
  background-size: 14px 14px, 14px 14px, 100% 100%;
  background-position: 0 0, 7px 7px, 0 0;
  transition: transform 1.6s cubic-bezier(.6, .02, .2, 1);
  backface-visibility: hidden;
}
.gate__door::before { /* filete dorado interior */
  content: ""; position: absolute; inset: 14px; border: 1px solid rgba(194, 157, 92, .8);
}
.gate__door--l { left: 0; transform-origin: left center; }
.gate__door--l::before { right: 26px; border-right: 0; }
.gate__door--r { right: 0; transform-origin: right center; }
.gate__door--r::before { left: 26px; border-left: 0; }
.gate__lace { position: absolute; top: 0; bottom: 0; width: 26px; background-image: var(--lace); background-size: 26px 30px; background-repeat: repeat-y; }
.gate__door--l .gate__lace { right: 0; }
.gate__door--r .gate__lace { left: 0; transform: scaleX(-1); }
.gate__ribbon {
  position: absolute; left: 0; right: 0; height: 30px; top: 58%;
  background: linear-gradient(180deg, var(--f2), var(--f1) 40%, #fff 50%, var(--f1) 60%, var(--f3));
  box-shadow: 0 2px 6px rgba(120, 60, 70, .2);
  transition: transform 1s cubic-bezier(.6, 0, .3, 1), opacity .8s;
}
.gate__ribbon--l { right: 50%; }
.gate__ribbon--r { left: 50%; }
.gate__center {
  position: absolute; left: 50%; top: 58%; transform: translate(-50%, -50%); z-index: 3;
  display: flex; flex-direction: column; align-items: center;
  transition: transform .8s cubic-bezier(.5, 0, .5, 1), opacity .6s;
}
.gate__center .bow { width: 230px; margin: 0; }
.seal {
  position: absolute; left: 50%; top: 39%; transform: translate(-50%, -50%);
  width: 62px; height: 62px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #fff, var(--paper) 55%, var(--f1));
  box-shadow: 0 0 0 1.5px var(--gold), 0 0 0 5px rgba(255,255,255,.7), 0 0 0 6px var(--line), 0 6px 14px -4px rgba(120,60,70,.35);
  display: grid; place-items: center;
  font-family: var(--script); font-size: 38px; line-height: 1; padding-top: 5px; color: var(--gold-ink);
}
.gate__top {
  position: absolute; top: 15%; left: 0; right: 0; z-index: 3; text-align: center; padding: 0 30px;
  display: grid; gap: 10px; transition: opacity .6s, transform .8s;
}
.gate__top .crown { width: 92px; margin: 0 auto; }
.gate__top .script { font-size: 34px; color: var(--accent); }
.gate__guest { font-size: 20px; font-style: italic; color: var(--ink); margin: 0; }
.gate__bottom {
  position: absolute; left: 0; right: 0; bottom: calc(9% + env(safe-area-inset-bottom, 0px)); z-index: 3;
  display: flex; flex-direction: column; align-items: center; gap: 12px; transition: opacity .5s;
}
.gate__hint { font-size: 15px; color: var(--ink-soft); font-style: italic; margin: 0; }
.gate .btn--solid { min-width: 220px; }

.gate.is-opening .gate__top, .gate.is-opening .gate__bottom { opacity: 0; transform: translateY(-8px); }
.gate.is-opening .gate__center { transform: translate(-50%, -50%) scale(.6); opacity: 0; }
.gate.is-opening .gate__ribbon--l { transform: translateX(-105%); transition-delay: .35s; }
.gate.is-opening .gate__ribbon--r { transform: translateX(105%); transition-delay: .35s; }
.gate.is-opening .gate__door--l { transform: rotateY(-108deg); transition-delay: .75s; }
.gate.is-opening .gate__door--r { transform: rotateY(108deg); transition-delay: .75s; }
.gate.is-opening { background: transparent; transition: background .6s .7s; }
.gate.is-gone { display: none; }
.anim .gate .draw { stroke-dashoffset: 0; }
.gate__top { width: min(78%, 300px); left: 50% !important; right: auto !important; transform: translateX(-50%);
  padding: 22px 18px 20px !important; background: rgba(255, 251, 250, .94); border: 1px solid var(--line);
  border-radius: 140px 140px 10px 10px; box-shadow: 0 10px 30px -18px rgba(120, 60, 70, .45); }
.gate.is-opening .gate__top { transform: translate(-50%, -8px); }

/* ---------- Animaciones de entrada (solo con JS y movimiento permitido) ---------- */
.anim [data-r] {
  opacity: 0; transform: translateY(16px);
  transition: opacity 1.2s ease, transform 1.2s cubic-bezier(.2, .7, .2, 1), clip-path 2s cubic-bezier(.4, 0, .2, 1), filter 2s ease;
  transition-delay: calc(var(--d, 0) * 1ms);
}
.anim .is-in [data-r] { opacity: 1; transform: none; }
.anim [data-r="write"] { opacity: 1; transform: none; clip-path: inset(-30% 100% -30% -10%); filter: blur(3px); }
.anim .is-in [data-r="write"] { clip-path: inset(-30% -10% -30% -10%); filter: blur(0); }
.anim [data-r="rise"] { transform: translateY(26px) scale(.94); }
.anim [data-r="fade"] { transform: none; }

.anim .fl { opacity: 0; transform: scale(.35) rotate(-24deg); transform-box: fill-box; transform-origin: center;
  transition: opacity 1.2s ease, transform 1.8s cubic-bezier(.2, .8, .2, 1); transition-delay: calc(var(--i) * 60ms + var(--fd, 0ms)); }
.anim .is-in .fl { opacity: 1; transform: none; }
.anim .fl--flower { transform: scale(.2) rotate(-50deg); }

.anim .draw { stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 2.4s cubic-bezier(.45, 0, .2, 1); transition-delay: calc(var(--dd, 300) * 1ms); }
.anim .is-in .draw { stroke-dashoffset: 0; }
.anim .wash { opacity: 0; transition: opacity 2s ease 1.2s; }
.anim .is-in .wash { opacity: 1; }

.anim .perch { opacity: 0; transition: opacity 1.4s ease 1.4s; }
.anim .is-in .perch { opacity: 1; }

/* ---------- Movimiento reducido ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; animation-iteration-count: 1 !important; transition-duration: .001ms !important; transition-delay: 0ms !important; }
  .ambient { display: none; }
}

/* Pantallas bajas: compactar escenas */
@media (max-height: 700px) {
  .scene { padding-top: 120px; padding-bottom: 120px; }
  .hero-xv { font-size: 80px; }
}
@media (max-width: 360px) {
  .scene { padding-left: 22px; padding-right: 22px; }
  .countdown { grid-template-columns: repeat(4, 56px); gap: 8px; }
  .countdown__unit { width: 56px; height: 56px; }
}

/* ---------- Fotografías ---------- */
.photo-arch {
  position: relative; width: min(250px, 64vw); aspect-ratio: 3 / 4; margin: 10px auto 26px;
  border-radius: 999px 999px 14px 14px; overflow: hidden; background: var(--f1);
  box-shadow: 0 0 0 1px var(--gold), 0 0 0 7px var(--paper), 0 0 0 8px var(--line), 0 26px 40px -26px rgba(30, 50, 38, .55);
}
.photo-arch img, .gallery__item img, .end-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; width: 100%; margin-top: 22px; padding-bottom: 36px; }
.gallery__item {
  position: relative; display: block; padding: 0; border: 0; cursor: zoom-in; background: var(--f1);
  aspect-ratio: 3 / 4; border-radius: 10px; overflow: hidden;
  box-shadow: 0 0 0 1px var(--line), 0 16px 28px -20px rgba(30, 50, 38, .5);
}
.gallery__item:nth-child(4n+1) { border-radius: 200px 200px 10px 10px; }
.gallery__item:nth-child(4n+0) { border-radius: 10px 10px 200px 200px; }
.gallery__item:nth-child(even) { transform: translateY(36px); }
.gallery__item:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
.gallery__hint { margin-top: 20px; font-size: 15px; font-style: italic; color: var(--ink-soft); }
.scene--end.has-photo { padding-top: 0; justify-content: flex-start; }
.end-photo {
  width: calc(100% + 68px); margin: 0 -34px 6px; aspect-ratio: 3 / 2; position: relative; z-index: 1;
  -webkit-mask-image: linear-gradient(180deg, #000 62%, transparent 100%); mask-image: linear-gradient(180deg, #000 62%, transparent 100%);
}
.scene--end.has-photo .scene__inner { margin-top: -30px; }
.rsvp--solo { margin-top: 0; }

.anim [data-r="photo"] { opacity: 0; transform: translateY(18px) scale(.97); transition: opacity 1.4s ease, transform 1.6s cubic-bezier(.2, .7, .2, 1); transition-delay: calc(var(--d, 0) * 1ms); }
.anim .is-in [data-r="photo"] { opacity: 1; transform: none; }
.anim .is-in .gallery__item[data-r="photo"]:nth-child(even) { transform: translateY(36px); }
.anim [data-r="photo"] img { transform: scale(1.1); transition: transform 3s cubic-bezier(.2, .7, .2, 1); transition-delay: calc(var(--d, 0) * 1ms); }
.anim .is-in [data-r="photo"] img { transform: none; }

.lightbox { position: fixed; inset: 0; z-index: 120; background: rgba(22, 32, 26, .94); display: grid; place-items: center; padding: 56px 12px; }
.lightbox[hidden] { display: none !important; }
.lightbox img { max-width: min(94vw, 720px); max-height: 82vh; object-fit: contain; border-radius: 6px; box-shadow: 0 30px 60px -20px rgba(0,0,0,.6); }
.lb-btn { position: absolute; width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(255,255,255,.4); background: rgba(255,255,255,.08); color: #fff; font-size: 28px; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.lb-close { top: calc(12px + env(safe-area-inset-top, 0px)); right: max(12px, env(safe-area-inset-right, 0px)); }
.lb-prev { left: max(8px, env(safe-area-inset-left, 0px)); top: 50%; transform: translateY(-50%); }
.lb-next { right: max(8px, env(safe-area-inset-right, 0px)); top: 50%; transform: translateY(-50%); }
.lb-count { position: absolute; bottom: calc(16px + env(safe-area-inset-bottom, 0px)); left: 0; right: 0; text-align: center; color: rgba(255,255,255,.8); font-family: var(--caps); font-size: 12px; letter-spacing: .2em; margin: 0; }

/* Paleta de vestimenta */
.palette { display: flex; justify-content: center; gap: 34px; margin-top: 18px; }
.palette__item { display: flex; flex-direction: column; align-items: center; gap: 10px; }
.palette__dot { width: 54px; height: 54px; border-radius: 50%; box-shadow: 0 0 0 1px var(--gold), 0 0 0 5px var(--paper), 0 0 0 6px var(--line), 0 10px 18px -10px rgba(30, 50, 38, .5); }
.palette__name { font-family: var(--caps); font-size: 12px; letter-spacing: .28em; text-transform: uppercase; color: var(--gold-ink); }
.palette__text { margin-top: 18px; font-size: 18px; font-style: italic; }

/* =====================================================================
   ESTILO "MEDALLÓN" — sobre con lacre, retratos en medallón, marco dorado
   Se activa con  estilo: "medallon"  en config.js
   ===================================================================== */
@font-face { font-family: "Great Vibes"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/great-vibes-latin-400-normal.woff2") format("woff2"); }
.estilo-medallon { --script: "Great Vibes", "Pinyon Script", "Snell Roundhand", cursive; }

/* Marco dorado continuo alrededor de toda la tarjeta */
.estilo-medallon .card::before,
.estilo-medallon .card::after { content: ""; position: absolute; pointer-events: none; z-index: 4; }
.estilo-medallon .card::before { inset: 10px; border: 1px solid var(--line); }
.estilo-medallon .card::after { inset: 15px; border: 1px dashed rgba(194, 157, 92, .35); }
.estilo-medallon .scene + .scene::before { display: none; }
.estilo-medallon .scene + .scene { border-top: 0; }
.estilo-medallon .scene + .scene .scene__inner::before { /* rombo separador entre escenas */
  content: ""; position: absolute; top: -110px; left: 50%; width: 9px; height: 9px; transform: translateX(-50%) rotate(45deg);
  border: 1px solid var(--gold); background: var(--paper);
}

/* Portada con medallón */
.scene--hero-m { padding-top: 120px; padding-bottom: 150px; }
.hero-m__top { font-size: 13px; letter-spacing: .42em; margin-bottom: 26px; }
.hero-m__xv { font-family: var(--caps); font-size: 22px; letter-spacing: .12em; vertical-align: -2px; padding: 0 .3em; }
.medallion { position: relative; width: min(232px, 60vw); margin: 0 auto 6px; padding-top: 34px; }
.medallion__crown { position: absolute; top: 0; left: 50%; width: 96px; transform: translateX(-50%); z-index: 2; }
.medallion__ring {
  aspect-ratio: 4 / 5; border-radius: 50%; overflow: hidden; background: var(--f1);
  box-shadow: 0 0 0 2px var(--gold), 0 0 0 9px var(--paper), 0 0 0 10px var(--line), 0 0 0 14px var(--paper), 0 0 0 15px rgba(194,157,92,.35), 0 30px 50px -28px rgba(87, 41, 60, .55);
}
.medallion__ring img { width: 100%; height: 100%; object-fit: cover; display: block; }
.scene--hero-m .hero-name { margin-top: 24px; font-size: clamp(66px, 20vw, 92px); }
.scene--hero-m .hero-second { font-size: 42px; margin-top: -10px; }
.scene--hero-m .divider { margin: 14px auto 6px; }
.scene--hero-m .hero-date { margin-top: 6px; }
.scene--hero-m .deco--corner-tl, .scene--hero-m .deco--corner-br { width: 50%; }

/* Retrato de presentación con marco desfasado */
.photo-offset { position: relative; width: min(240px, 62vw); aspect-ratio: 3 / 4; margin: 16px auto 34px; }
.photo-offset::before { content: ""; position: absolute; inset: 0; transform: translate(12px, 12px); border: 1px solid var(--gold); border-radius: 6px; }
.photo-offset img { position: relative; width: 100%; height: 100%; object-fit: cover; border-radius: 6px; display: block; box-shadow: 0 22px 36px -24px rgba(87, 41, 60, .6); }

/* Galería tipo tarjetas con paspartú */
.estilo-medallon .gallery { gap: 18px 14px; padding-bottom: 10px; }
.estilo-medallon .gallery__item,
.estilo-medallon .gallery__item:nth-child(4n+1),
.estilo-medallon .gallery__item:nth-child(4n+0) { border-radius: 4px; padding: 7px 7px 22px; background: #fff; box-shadow: 0 0 0 1px var(--line), 0 14px 24px -18px rgba(87, 41, 60, .55); }
.estilo-medallon .gallery__item img { border-radius: 2px; }
.estilo-medallon .gallery__item:nth-child(even),
.estilo-medallon.anim .is-in .gallery__item[data-r="photo"]:nth-child(even) { transform: rotate(1.6deg); }
.estilo-medallon .gallery__item:nth-child(odd),
.estilo-medallon.anim .is-in .gallery__item[data-r="photo"]:nth-child(odd) { transform: rotate(-1.4deg); }
.estilo-medallon .gallery__item:nth-child(3n) { aspect-ratio: auto; grid-column: span 2; height: 230px; }

/* Cierre: foto en óvalo apaisado */
.estilo-medallon .end-photo { width: 100%; margin: 120px 0 0; aspect-ratio: 4 / 3; border-radius: 50%; overflow: hidden; -webkit-mask-image: none; mask-image: none;
  box-shadow: 0 0 0 2px var(--gold), 0 0 0 8px var(--paper), 0 0 0 9px var(--line); }
.estilo-medallon .scene--end.has-photo .scene__inner { margin-top: 30px; }

/* Cuenta regresiva solo en días cuando no hay hora */
.countdown--day { grid-template-columns: 74px; }
.countdown--day .countdown__unit { width: 74px; height: 74px; }
.countdown--day .countdown__unit:not(:first-child) { display: none; }

/* ---------- Apertura: sobre con sello de lacre ---------- */
.gate--sobre { background: var(--backdrop); align-items: center; perspective: 1400px; }
.env { position: relative; width: min(100%, var(--card-w)); height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 30px; padding: 24px 24px calc(24px + env(safe-area-inset-bottom, 0px)); }
.env__top { text-align: center; display: grid; gap: 8px; transition: opacity .6s, transform .8s; }
.env__top .script { font-size: 40px; color: var(--accent); }
.env__body { position: relative; width: min(330px, 86vw); aspect-ratio: 3 / 2.1; transform-style: preserve-3d; }
.env__back { position: absolute; inset: 0; border-radius: 6px; background: linear-gradient(160deg, var(--f2), var(--f3)); box-shadow: 0 30px 50px -26px rgba(87, 41, 60, .6); }
.env__card { position: absolute; left: 7%; right: 7%; top: 8%; height: 84%; background: var(--paper); border-radius: 4px; z-index: 1;
  display: flex; align-items: center; justify-content: center; box-shadow: 0 0 0 1px var(--line); transition: transform 1.2s cubic-bezier(.3, .7, .2, 1) .9s; }
.env__card-in { text-align: center; padding: 10px; }
.env__card .crown { width: 70px; margin: 0 auto 2px; }
.env__name { font-size: 40px; }
.env__pocket { position: absolute; inset: 0; z-index: 2; border-radius: 6px; pointer-events: none;
  background:
    linear-gradient(to top right, var(--f2) 49.6%, transparent 50%) left bottom / 50.2% 100% no-repeat,
    linear-gradient(to top left, var(--f2) 49.6%, transparent 50%) right bottom / 50.2% 100% no-repeat,
    linear-gradient(to top, var(--f3) 0, var(--f3) 1px, transparent 1px) bottom / 100% 100% no-repeat; }
.env__pocket::after { content: ""; position: absolute; inset: 8px; border: 1px solid rgba(255, 255, 255, .55); border-radius: 3px; }
.env__flap { position: absolute; left: 0; right: 0; top: 0; height: 62%; z-index: 3; transform-origin: top center; transition: transform 1s cubic-bezier(.5, 0, .2, 1) .35s, z-index 0s .85s; }
.env__flap-in { position: absolute; inset: 0; clip-path: polygon(0 0, 100% 0, 50% 100%); background: linear-gradient(180deg, var(--f1), var(--f2)); filter: drop-shadow(0 3px 3px rgba(87, 41, 60, .2)); }
.env__flap-in::after { content: ""; position: absolute; inset: 0; clip-path: polygon(3% 0, 97% 0, 50% 94%); background: linear-gradient(180deg, transparent 60%, rgba(194, 157, 92, .5)); opacity: .35; }
.wax { position: absolute; left: 50%; top: 62%; width: 66px; height: 66px; transform: translate(-50%, -50%); z-index: 4; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #D97A9E, var(--accent) 55%, #7C2A4D);
  box-shadow: inset 0 0 0 5px rgba(0,0,0,.08), inset 0 0 0 7px rgba(255,255,255,.18), 0 6px 12px -4px rgba(60, 20, 35, .55);
  display: grid; place-items: center; transition: transform .6s cubic-bezier(.5, 0, .5, 1), opacity .5s; }
.wax span { font-family: var(--script); color: #FCE6EE; font-size: 36px; line-height: 1; padding-top: 4px; text-shadow: 0 -1px 0 rgba(0,0,0,.25); }
.env__bottom { position: static; transition: opacity .5s; }
.gate--sobre.is-opening .wax { transform: translate(-50%, -50%) scale(.4); opacity: 0; }
.gate--sobre.is-opening .env__flap { transform: rotateX(180deg); z-index: 0; }
.gate--sobre.is-opening .env__card { transform: translateY(-58%); }
.gate--sobre.is-opening .env__top, .gate--sobre.is-opening .env__bottom { opacity: 0; }
.gate--sobre.is-opening .env { transition: opacity .6s 1.8s; opacity: 0; }
.gate--sobre.is-opening { background: transparent; transition: background .7s 1.6s; }
.env__card-in { opacity: 0; transition: opacity .6s ease 1.1s; }
.gate--sobre.is-opening .env__card-in { opacity: 1; }

.rsvp__note { justify-self: center; margin: 6px 0 0; padding: 5px 16px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line);
  font-family: var(--caps); font-size: 11px; letter-spacing: .26em; text-transform: uppercase; color: var(--accent); }
.field[hidden] { display: none !important; }

/* Acabado plateado (metal: "plata") */
.metal-plata .gold-text { background-image: linear-gradient(135deg, #E9EBEF 0%, #9DA2AC 40%, #F4F5F7 60%, #868B95 100%); }
.metal-plata .wax { background: radial-gradient(circle at 35% 30%, #E58AB0, var(--accent) 55%, #7E1F4A); }
.metal-plata .gate__door::before { border-color: rgba(170, 175, 186, .85); }
.metal-plata .seal { color: var(--gold-ink); }

/* =====================================================================
   ESTILO "EDITORIAL" — portada de revista, foto a sangre, texto alineado
   a la izquierda, galería deslizable, eventos como boletos, destellos.
   Se activa con  estilo: "editorial"  en config.js
   ===================================================================== */
@font-face { font-family: "Playfair Display"; font-weight: 400; font-style: italic; font-display: swap; src: url("../fonts/playfair-display-latin-400-italic.woff2") format("woff2"); }
@font-face { font-family: "Playfair Display"; font-weight: 500; font-style: normal; font-display: swap; src: url("../fonts/playfair-display-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Allura"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/allura-latin-400-normal.woff2") format("woff2"); }
.estilo-editorial { --script: "Allura", "Great Vibes", "Pinyon Script", cursive; --display: "Playfair Display", "Cormorant Garamond", Georgia, serif; }

/* Sin flores, arcos ni mariposas posadas: el protagonista es la foto */
.estilo-editorial .deco, .estilo-editorial .perch, .estilo-editorial .arch-wrap,
.estilo-editorial .frame-wrap, .estilo-editorial .stem-l, .estilo-editorial .stem-r,
.estilo-editorial .divider, .estilo-editorial .scene .crown, .estilo-editorial .quote-mark,
.estilo-editorial .scene + .scene::before { display: none !important; }

/* Escenas alineadas a la izquierda, con titular en serif */
.estilo-editorial .scene { text-align: left; align-items: stretch; justify-content: center; padding: 96px 30px; min-height: auto; }
.estilo-editorial .scene__inner { align-items: flex-start; }
.estilo-editorial .scene .label { display: flex; align-items: center; gap: 12px; }
.estilo-editorial .scene .label::before { content: ""; width: 28px; height: 1px; background: var(--gold); }
.estilo-editorial .h-script,
.estilo-editorial .family__group .script,
.estilo-editorial .event .script,
.estilo-editorial .rsvp__head .script,
.estilo-editorial .end-name { font-family: var(--display); font-style: italic; font-weight: 400; color: var(--ink); letter-spacing: -.01em; line-height: 1.05; }
.estilo-editorial .h-script { font-size: 44px; margin-top: 10px; }
.estilo-editorial .lead, .estilo-editorial .body { max-width: 34ch; }
.estilo-editorial .scene + .scene { border-top: 1px solid var(--line); margin: 0 30px; padding-left: 0; padding-right: 0; }

/* Portada: foto a sangre con el nombre encima */
.estilo-editorial .scene--hero-e { padding: 0 !important; min-height: 100vh; min-height: 100svh; justify-content: flex-end !important; margin: 0; border-top: 0; }
.hero-e__photo { position: absolute; inset: 0; margin: 0; }
.hero-e__photo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hero-e__photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(40, 14, 26, .25) 0%, transparent 22%, transparent 42%, rgba(255, 252, 253, .55) 62%, var(--paper) 86%); }
.hero-e__badge { position: absolute; top: calc(64px + env(safe-area-inset-top, 0px)); left: 26px; z-index: 3; display: flex; align-items: center; gap: 12px;
  font-family: var(--caps); font-size: 13px; letter-spacing: .3em; color: #fff; text-shadow: 0 1px 8px rgba(0,0,0,.35); }
.hero-e__badge .gold-text { font-size: 30px; letter-spacing: .08em; background-image: linear-gradient(135deg, #fff, #E4E6EA 50%, #fff); text-shadow: none; filter: drop-shadow(0 1px 6px rgba(0,0,0,.35)); }
.hero-e__badge i { width: 30px; height: 1px; background: rgba(255,255,255,.8); }
.hero-e__text { position: relative; z-index: 2; padding: 0 28px 64px; }
.scene--hero-e .hero-name { font-size: clamp(76px, 24vw, 108px); line-height: .95; margin: 6px 0 0 -4px; color: var(--accent); }
.hero-e__second { font-family: var(--caps); font-size: 13px; letter-spacing: .34em; text-transform: uppercase; color: var(--ink); margin: 14px 0 0; }
.hero-e__date { font-family: var(--display); font-style: italic; font-size: 20px; color: var(--ink-soft); margin: 10px 0 0; }
.scene--hero-e .scroll-cue { margin-top: 30px; align-items: flex-start; padding-left: 0; }

/* Foto de presentación: rectangular, a todo lo ancho, con pie de foto */
.photo-editorial { width: calc(100% + 60px); margin: 22px -30px 26px; aspect-ratio: 4 / 5; overflow: hidden; }
.photo-editorial img { width: 100%; height: 100%; object-fit: cover; display: block; }
.estilo-editorial .scene--intro .script.big { font-size: 54px; }
.estilo-editorial .signature { margin-top: 18px; }

/* Mensaje con una gran comilla de serif */
.estilo-editorial .scene--message .body { font-family: var(--display); font-style: italic; font-size: 21px; line-height: 1.55; color: var(--ink); max-width: none; position: relative; padding-top: 40px; }
.estilo-editorial .scene--message .body::before { content: "“"; position: absolute; top: -18px; left: -6px; font-size: 96px; line-height: 1; color: var(--f3); font-family: var(--display); }

/* Familia en dos columnas */
.estilo-editorial .family { grid-template-columns: 1fr; gap: 26px; margin-top: 18px; }
.estilo-editorial .family__group { gap: 4px; padding-left: 16px; border-left: 1px solid var(--gold); }
.estilo-editorial .family__group .script { font-size: 26px; }

/* Galería deslizable */
.gallery--strip { display: flex !important; gap: 14px; overflow-x: auto; scroll-snap-type: x mandatory; width: calc(100% + 60px); margin: 22px -30px 0; padding: 0 30px 8px !important; scrollbar-width: none; }
.gallery--strip::-webkit-scrollbar { display: none; }
.estilo-editorial .gallery--strip .gallery__item { flex: 0 0 78%; aspect-ratio: 4 / 5; height: auto; scroll-snap-align: center; border-radius: 2px !important; padding: 0 !important; transform: none !important; box-shadow: 0 18px 30px -22px rgba(77, 38, 56, .6); grid-column: auto; background: var(--f1); }
.strip-nav { display: flex; align-items: center; gap: 16px; margin-top: 18px; }
.strip-btn { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--gold); background: transparent; color: var(--ink); font-size: 24px; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.strip-count { font-family: var(--caps); font-size: 12px; letter-spacing: .24em; color: var(--ink-soft); font-variant-numeric: tabular-nums; min-width: 56px; text-align: center; }

/* Fecha y cuenta regresiva */
.estilo-editorial .date-block { margin-left: 0; }
.estilo-editorial .countdown { justify-content: start; }
.estilo-editorial .countdown__unit { border-radius: 4px; }

/* Eventos como boletos */
.estilo-editorial .events { gap: 18px; }
.estilo-editorial .event { border-radius: 10px; align-items: flex-start; text-align: left; padding: 22px 22px 20px; background: #fff; border: 0; box-shadow: 0 0 0 1px var(--line), 0 16px 28px -22px rgba(77, 38, 56, .5);
  -webkit-mask: radial-gradient(circle 11px at 0 calc(100% - 84px), transparent 98%, #000), radial-gradient(circle 11px at 100% calc(100% - 84px), transparent 98%, #000);
  -webkit-mask-composite: source-in; mask: radial-gradient(circle 11px at 0 calc(100% - 84px), transparent 98%, #000) intersect, radial-gradient(circle 11px at 100% calc(100% - 84px), transparent 98%, #000); }
.estilo-editorial .event::after { content: ""; position: absolute; left: 16px; right: 16px; bottom: 84px; border-top: 1px dashed var(--line); }
.estilo-editorial .event .ico { position: absolute; top: 18px; right: 18px; width: 34px; height: 34px; margin: 0; }
.estilo-editorial .event .script { font-size: 30px; }
.estilo-editorial .event__addr { margin-bottom: 38px; }
.estilo-editorial .event .btn { margin-top: 4px; }

/* Vestimenta, regalos y confirmación */
.estilo-editorial .palette { justify-content: flex-start; }
.estilo-editorial .gifts { margin-top: 18px; }
.estilo-editorial .gift { padding-left: 0; }
.estilo-editorial .rsvp { background: #fff; border-radius: 6px; }
.estilo-editorial .rsvp__head { text-align: left; }
.estilo-editorial .rsvp__note { justify-self: start; }
.estilo-editorial .btn-row { justify-content: flex-start; }

/* Cierre: foto a sangre con texto encima */
.estilo-editorial .scene--end { margin: 0 !important; border-top: 0 !important; padding: 0 30px 110px !important; }
.estilo-editorial .scene--end .bow { display: none; }
.estilo-editorial .end-photo { width: calc(100% + 60px); margin: 0 -30px; aspect-ratio: 4 / 5; border-radius: 0; box-shadow: none;
  -webkit-mask-image: linear-gradient(180deg, #000 55%, transparent 100%); mask-image: linear-gradient(180deg, #000 55%, transparent 100%); }
.estilo-editorial .scene--end.has-photo .scene__inner { margin-top: -90px; position: relative; z-index: 2; }
.estilo-editorial .end-name { font-size: 54px; }

/* ---------- Apertura: portada de revista que se voltea como página ---------- */
.gate--revista { background: var(--ink); perspective: 1800px; }
.rev { position: relative; width: min(100%, var(--card-w)); height: 100%; transform-style: preserve-3d; }
.rev__page--under { position: absolute; inset: 0; background: var(--paper); }
.rev__cover { position: absolute; inset: 0; overflow: hidden; transform-origin: left center; transition: transform 1.5s cubic-bezier(.6, .05, .25, 1), box-shadow 1.5s; backface-visibility: hidden; box-shadow: 0 0 0 rgba(0,0,0,0); background: var(--f2); }
.rev__cover img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.rev__shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(30, 10, 20, .45) 0%, transparent 28%, transparent 48%, rgba(30, 10, 20, .7) 100%); }
.rev__mast { position: absolute; top: calc(28px + env(safe-area-inset-top, 0px)); left: 24px; right: 24px; display: flex; justify-content: space-between; align-items: flex-start; color: #fff; }
.rev__xv { font-family: var(--display); font-size: 108px; line-height: .8; letter-spacing: -.02em; text-shadow: 0 2px 18px rgba(0,0,0,.25); }
.rev__issue { font-family: var(--caps); font-size: 11px; letter-spacing: .3em; margin-top: 10px; border-top: 1px solid rgba(255,255,255,.7); border-bottom: 1px solid rgba(255,255,255,.7); padding: 6px 0; }
.rev__guest { position: absolute; top: calc(150px + env(safe-area-inset-top, 0px)); left: 24px; color: #fff; font-family: var(--display); font-style: italic; font-size: 20px; margin: 0; text-shadow: 0 1px 8px rgba(0,0,0,.4); }
.rev__foot { position: absolute; left: 24px; right: 24px; bottom: calc(34px + env(safe-area-inset-bottom, 0px)); color: #fff; display: flex; flex-direction: column; align-items: flex-start; }
.rev__kicker { font-family: var(--caps); font-size: 11px; letter-spacing: .28em; text-transform: uppercase; margin: 0; }
.rev__name { font-size: 82px; line-height: 1; color: #fff; margin: 4px 0 18px -2px; text-shadow: 0 2px 16px rgba(0,0,0,.3); }
.rev__btn { background: #fff; color: var(--accent); border-color: #fff; min-width: 220px; }
.rev__hint { color: rgba(255,255,255,.85); margin-top: 10px; }
.gate--revista.is-opening .rev__cover { transform: rotateY(-115deg); box-shadow: 40px 0 60px rgba(0,0,0,.35); }
.gate--revista.is-opening .rev__page--under { transition: opacity .5s 1.2s; opacity: 0; }
.gate--revista.is-opening { background: transparent; transition: background .4s .5s; }

/* =====================================================================
   ESTILO "PRINCESA" — telón de tul, guirnalda de estrellas, marcos de
   perlas, franjas con borde ondulado y galería en abanico.
   Se activa con  estilo: "princesa"  en config.js
   ===================================================================== */
@font-face { font-family: "Parisienne"; font-weight: 400; font-style: normal; font-display: swap; src: url("../fonts/parisienne-latin-400-normal.woff2") format("woff2"); }
.estilo-princesa { --script: "Parisienne", "Pinyon Script", cursive; --tul: linear-gradient(180deg, var(--f1), var(--f0)); }

/* Sin flores ilustradas ni mariposas posadas */
.estilo-princesa .deco, .estilo-princesa .perch, .estilo-princesa .arch-wrap,
.estilo-princesa .frame-wrap, .estilo-princesa .stem-l, .estilo-princesa .stem-r,
.estilo-princesa .scene + .scene::before { display: none !important; }

/* Franjas alternadas con borde ondulado (como el filo de un pastel) */
.estilo-princesa .scene { background: var(--paper); padding-top: 110px; padding-bottom: 110px; min-height: auto; }
.estilo-princesa .scene:nth-of-type(even) {
  background:
    radial-gradient(circle at 20% 30%, rgba(255,255,255,.55) 0 1.2px, transparent 1.6px) 0 0 / 22px 22px,
    radial-gradient(circle at 70% 80%, rgba(255,255,255,.45) 0 1px, transparent 1.4px) 0 0 / 30px 30px,
    linear-gradient(180deg, var(--f1), var(--f0));
}
.estilo-princesa .scene + .scene::after {
  content: ""; position: absolute; left: 0; right: 0; top: -13px; height: 14px; z-index: 3; pointer-events: none;
  background: radial-gradient(circle at 50% 100%, var(--paper) 13px, transparent 13.5px) 0 0 / 26px 14px repeat-x;
}
.estilo-princesa .scene:nth-of-type(even)::after { background: radial-gradient(circle at 50% 100%, var(--f1) 13px, transparent 13.5px) 0 0 / 26px 14px repeat-x; }
.estilo-princesa .scene .h-script { font-size: 52px; }
.estilo-princesa .divider { width: 120px; }

/* Portada: guirnalda colgante + XV de fondo + marco de perlas */
.scene--hero-p { padding-top: 150px !important; padding-bottom: 90px !important; background: linear-gradient(180deg, var(--f1) 0%, var(--paper) 46%) !important; min-height: 100vh; min-height: 100svh; }
.hero-p__garl { position: absolute; top: 0; left: 0; right: 0; z-index: 1; pointer-events: none; }
.garl { width: 100%; height: auto; display: block; overflow: visible; }
.garl__h { animation: swing var(--sw) ease-in-out var(--dl) infinite alternate; transform-box: view-box; }
@keyframes swing { from { transform: rotate(-4deg); } to { transform: rotate(4deg); } }
.hero-p__xv { position: absolute; top: -30px; left: 50%; transform: translateX(-50%); z-index: -1;
  font-family: var(--caps); font-size: 190px; line-height: 1; letter-spacing: .02em; color: transparent;
  -webkit-text-stroke: 1px var(--line); opacity: .9; }
.scene--hero-p .hero-name { font-size: clamp(70px, 21vw, 96px); margin-top: 4px; }
.scene--hero-p .hero-second { font-size: 40px; margin-top: -14px; }
.scene--hero-p .hero-last { margin-top: 18px; }
.scene--hero-p .hero-date { margin-top: 10px; }

.pearl { position: relative; width: min(230px, 60vw); aspect-ratio: 4 / 5; margin: 22px auto 6px; border-radius: 26px; }
.pearl img { position: relative; z-index: 1; width: 100%; height: 100%; object-fit: cover; display: block; border-radius: 22px; }
.pearl::before { /* sarta de perlas alrededor */
  content: ""; position: absolute; inset: -13px; border-radius: 34px; z-index: 0;
  background: radial-gradient(circle at 50% 50%, #fff 0 2.2px, #E9DDE3 3px, rgba(180,170,180,.55) 4.2px, transparent 4.8px) 0 0 / 11px 11px;
  padding: 9px;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0);
}
.pearl::after { content: ""; position: absolute; inset: -4px; border-radius: 26px; border: 1px solid var(--gold); z-index: 0; }
.pearl--intro { width: min(250px, 64vw); margin: 18px auto 30px; }

/* Mensaje con monograma */
.estilo-princesa .scene--message .body { font-style: italic; font-size: 20px; }

/* Galería en abanico */
.gallery--deck { display: block !important; position: relative; width: min(250px, 64vw); aspect-ratio: 4 / 5; margin: 36px auto 0; padding: 0 !important; }
.estilo-princesa .gallery--deck .gallery__item {
  position: absolute; inset: 0; width: 100%; height: 100%; aspect-ratio: auto; border-radius: 14px !important; padding: 8px !important; background: #fff;
  box-shadow: 0 0 0 1px var(--line), 0 18px 30px -20px rgba(77, 38, 56, .55);
  transform: translateX(calc(var(--k) * 10px)) rotate(calc(var(--k) * 4deg)) scale(calc(1 - var(--k) * .03)) !important;
  transition: transform .45s cubic-bezier(.3, .7, .2, 1), opacity .45s; opacity: 1 !important;
}
.estilo-princesa .gallery--deck .gallery__item img { border-radius: 8px; }
.estilo-princesa .gallery--deck .gallery__item:not(.is-top) { pointer-events: none; }
.estilo-princesa .gallery--deck .gallery__item:nth-child(n) { grid-column: auto; height: 100%; }
.estilo-princesa .gallery--deck .gallery__item.is-out { transform: translateX(-130%) rotate(-18deg) !important; opacity: 0 !important; }
.deck-nav { justify-content: center; margin-top: 26px; }
.strip-nav { display: flex; align-items: center; gap: 16px; }
.strip-btn { width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--gold); background: rgba(255,255,255,.7); color: var(--ink); font-size: 24px; line-height: 1; cursor: pointer; display: grid; place-items: center; }
.strip-count { font-family: var(--caps); font-size: 12px; letter-spacing: .24em; color: var(--ink-soft); font-variant-numeric: tabular-nums; min-width: 56px; text-align: center; }

/* Familia: nombres en tarjetas de perla */
.estilo-princesa .family__group { padding: 18px 16px; border-radius: 18px; background: rgba(255,255,255,.7); box-shadow: 0 0 0 1px var(--line); }

/* Eventos con borde ondulado arriba */
.estilo-princesa .event { border-radius: 20px; background: #fff; border: 0; box-shadow: 0 0 0 1px var(--line), 0 16px 28px -22px rgba(77, 38, 56, .5); }
.estilo-princesa .countdown__unit { background: #fff; }

/* Cierre con foto en marco de perlas */
.estilo-princesa .scene--end.has-photo { padding-top: 110px; }
.estilo-princesa .end-photo { width: min(250px, 64vw); margin: 0 auto 26px; aspect-ratio: 4 / 5; border-radius: 22px; overflow: visible; -webkit-mask-image: none; mask-image: none; position: relative; }
.estilo-princesa .end-photo img { border-radius: 22px; position: relative; z-index: 1; }
.estilo-princesa .end-photo::before { content: ""; position: absolute; inset: -13px; border-radius: 34px;
  background: radial-gradient(circle at 50% 50%, #fff 0 2.2px, #E9DDE3 3px, rgba(180,170,180,.55) 4.2px, transparent 4.8px) 0 0 / 11px 11px; padding: 9px;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0); -webkit-mask-composite: xor;
  mask: linear-gradient(#000 0 0) content-box exclude, linear-gradient(#000 0 0); }
.estilo-princesa .scene--end.has-photo .scene__inner { margin-top: 0; }

/* ---------- Apertura: telón de tul que sube ---------- */
.gate--telon { background: var(--paper); }
.tel { position: relative; width: min(100%, var(--card-w)); height: 100%; overflow: hidden; }
.tel__curtain { position: absolute; inset: 0 0 -30px; z-index: 1; transition: transform 1.5s cubic-bezier(.65, 0, .25, 1) .55s;
  background: repeating-linear-gradient(90deg, rgba(255,255,255,0) 0 18px, rgba(255,255,255,.35) 26px, rgba(255,255,255,0) 40px), linear-gradient(180deg, var(--f2), var(--f1) 60%, var(--f2));
  -webkit-mask: radial-gradient(circle at 50% 0, transparent 15px, #000 15.5px) bottom / 32px 30px repeat-x, linear-gradient(#000 0 0) top / 100% calc(100% - 29px) no-repeat;
  mask: radial-gradient(circle at 50% 0, transparent 15px, #000 15.5px) bottom / 32px 30px repeat-x, linear-gradient(#000 0 0) top / 100% calc(100% - 29px) no-repeat; }
.tel__folds { position: absolute; inset: 0; background:
  radial-gradient(circle at 30% 20%, rgba(255,255,255,.7) 0 1.2px, transparent 1.8px) 0 0 / 24px 24px,
  radial-gradient(circle at 70% 60%, rgba(255,255,255,.5) 0 1px, transparent 1.5px) 0 0 / 34px 34px; }
.tel__ribbon { position: absolute; top: 56%; height: 26px; width: 52%; z-index: 2; transition: transform .9s cubic-bezier(.6, 0, .3, 1), opacity .7s;
  background: linear-gradient(180deg, var(--f3), var(--f2) 40%, #fff 50%, var(--f2) 60%, var(--f4)); box-shadow: 0 2px 6px rgba(77, 38, 56, .2); }
.tel__ribbon--l { left: 0; } .tel__ribbon--r { right: 0; }
.tel__bow { position: absolute; left: 50%; top: 56%; z-index: 3; transform: translate(-50%, -50%); width: 220px; transition: transform .8s cubic-bezier(.5, 0, .5, 1), opacity .6s; }
.tel__bow .bow { width: 220px; margin: 0; }
.tel__mono { position: absolute; left: 50%; top: 38%; transform: translate(-50%, -50%); width: 54px; height: 54px; border-radius: 50%; display: grid; place-items: center;
  background: radial-gradient(circle at 35% 30%, #fff, var(--paper) 55%, var(--f1)); box-shadow: 0 0 0 1.5px var(--gold), 0 4px 10px -3px rgba(77,38,56,.35);
  font-family: var(--script); font-size: 34px; color: var(--accent); padding-top: 4px; }
.tel__top { position: absolute; top: 13%; left: 0; right: 0; z-index: 3; text-align: center; display: grid; gap: 8px; padding: 0 30px; transition: opacity .5s, transform .8s; }
.tel__top .crown { width: 86px; margin: 0 auto; }
.tel__title { font-size: 44px; color: var(--accent); }
.tel__bottom { z-index: 3; transition: opacity .5s; }
.gate--telon.is-opening .tel__top, .gate--telon.is-opening .tel__bottom { opacity: 0; transform: translateY(-10px); }
.gate--telon.is-opening .tel__bow { transform: translate(-50%, -80%) scale(.5); opacity: 0; }
.gate--telon.is-opening .tel__ribbon--l { transform: translateX(-105%); transition-delay: .2s; }
.gate--telon.is-opening .tel__ribbon--r { transform: translateX(105%); transition-delay: .2s; }
.gate--telon.is-opening .tel__curtain { transform: translateY(-110%); }
.gate--telon.is-opening { background: transparent; transition: background .4s .7s; }

.estilo-princesa .gallery--deck .gallery__item img { transition: opacity .3s; }
.estilo-princesa .gallery--deck .gallery__item:not(.is-top) img { opacity: 0; }
.estilo-princesa .gallery--deck .gallery__item:not(.is-top) { background: linear-gradient(160deg, #fff, var(--f0)); }
.hero-p__garl { top: 0; }

/* =====================================================================
   ESTILO "GALA" — noche de gala: fondo vino profundo, plata y luz.
   Apertura con reflector, portada cinematográfica, nombre con brillo
   de foil, galería en presentación con zoom lento y luces bokeh.
   Se activa con  estilo: "gala"  y  tema: "nochegala"  en config.js
   ===================================================================== */
.estilo-gala { --script: "Parisienne", "Pinyon Script", cursive; color-scheme: dark; }
.estilo-gala body { background: radial-gradient(900px 600px at 50% 0%, #3A1A2C, transparent 70%), var(--backdrop); }
.estilo-gala .card { box-shadow: 0 0 0 1px rgba(220, 224, 232, .12), 0 40px 90px -30px rgba(0, 0, 0, .8); }

/* Sin flores ilustradas ni mariposas */
.estilo-gala .deco, .estilo-gala .perch, .estilo-gala .arch-wrap, .estilo-gala .frame-wrap,
.estilo-gala .stem-l, .estilo-gala .stem-r, .estilo-gala .scene + .scene::before,
.estilo-gala .scene--end .bow { display: none !important; }

/* Escenas: aire, plata y una línea de luz entre secciones */
.estilo-gala .scene { min-height: auto; padding-top: 120px; padding-bottom: 120px; }
.estilo-gala .scene + .scene { background: linear-gradient(90deg, transparent, rgba(220, 224, 232, .35), transparent) top / 70% 1px no-repeat; }
.estilo-gala .label { color: #D6DAE1; }
.estilo-gala .h-script { font-size: 54px; color: var(--accent); }
.estilo-gala .lead, .estilo-gala .muted { color: var(--ink-soft); }
.estilo-gala .gold-text { background-image: linear-gradient(135deg, #F4F5F7 0%, #A9AEB8 40%, #FFFFFF 55%, #8E939D 100%); }

/* Texto con brillo de foil que recorre las letras */
.foil {
  background: linear-gradient(100deg, #B9BEC7 0%, #F7F8FA 18%, #9DA2AC 32%, #E9ECF0 46%, #F7D9E5 58%, #A9AEB8 72%, #FFFFFF 86%, #B9BEC7 100%);
  background-size: 250% 100%; -webkit-background-clip: text; background-clip: text; color: transparent;
  animation: foil 6s ease-in-out infinite;
}
@keyframes foil { 0%, 100% { background-position: 0% 50%; } 50% { background-position: 100% 50%; } }

/* Portada cinematográfica */
.estilo-gala .scene--hero-g { padding: 0 !important; min-height: 100vh; min-height: 100svh; justify-content: flex-end; overflow: hidden; background: none; }
.hero-g__photo { position: absolute; inset: 0; margin: 0; overflow: hidden; }
.hero-g__photo img { width: 100%; height: 100%; object-fit: cover; display: block; transform: scale(1.14); animation: kenburns 16s ease-out forwards; }
.anim .hero-g__photo img { animation-play-state: paused; }
.anim .is-in .hero-g__photo img { animation-play-state: running; }
@keyframes kenburns { to { transform: scale(1); } }
.hero-g__photo::after { content: ""; position: absolute; inset: 0;
  background: radial-gradient(120% 80% at 50% 30%, transparent 40%, rgba(14, 6, 11, .55) 100%),
              linear-gradient(180deg, rgba(14, 6, 11, .35) 0%, transparent 25%, transparent 45%, rgba(28, 14, 23, .85) 72%, var(--paper) 96%); }
.hero-g__text { position: relative; z-index: 2; padding: 0 26px 70px; }
.hero-g__crown { width: 78px; margin: 0 auto 2px; filter: drop-shadow(0 2px 10px rgba(255,255,255,.25)); }
.hero-g__kicker { font-size: 36px; color: var(--accent); margin: 0; }
.hero-g__name { font-family: var(--caps); font-weight: 400; font-size: clamp(50px, 15.5vw, 70px); letter-spacing: .12em; line-height: 1; margin: 4px 0 0; padding-left: .12em; }
.hero-g__last { font-family: var(--caps); font-size: 12px; letter-spacing: .34em; text-transform: uppercase; color: var(--ink-soft); margin: 14px 0 0; }
.hero-g__date { display: flex; align-items: center; justify-content: center; gap: 14px; margin: 20px 0 0; font-family: var(--caps); font-size: 13px; letter-spacing: .3em; color: var(--ink); }
.hero-g__date i { width: 34px; height: 1px; background: linear-gradient(90deg, transparent, #D6DAE1); }
.hero-g__date i:last-child { transform: scaleX(-1); }
.scene--hero-g .scroll-cue { margin-top: 30px; }

/* Foto de presentación con doble filete plateado */
.photo-gala { position: relative; width: min(260px, 66vw); aspect-ratio: 3 / 4; margin: 20px auto 34px; padding: 10px; border: 1px solid rgba(220, 224, 232, .5); }
.photo-gala::before { content: ""; position: absolute; inset: 4px; border: 1px solid rgba(220, 224, 232, .25); pointer-events: none; }
.photo-gala img { width: 100%; height: 100%; object-fit: cover; display: block; }

/* Mensaje */
.estilo-gala .scene--message .crown { width: 70px; }
.estilo-gala .quote-mark { color: var(--accent); opacity: .5; }

/* Galería en presentación: fundido con zoom lento */
.gallery--show { display: block !important; position: relative; width: calc(100% + 68px); margin: 26px -34px 0; aspect-ratio: 4 / 5; overflow: hidden; padding: 0 !important; }
.estilo-gala .gallery--show .gallery__item { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0 !important; border-radius: 0 !important; background: #000; box-shadow: none;
  opacity: 0 !important; transform: none !important; transition: opacity 1.4s ease !important; pointer-events: none; }
.estilo-gala .gallery--show .gallery__item.is-on { opacity: 1 !important; pointer-events: auto; }
.estilo-gala .gallery--show .gallery__item img { transform: scale(1.12) !important; transition: transform 6s linear !important; border-radius: 0; }
.estilo-gala .gallery--show .gallery__item.is-on img { transform: scale(1) !important; }
.gallery--show::after { content: ""; position: absolute; inset: 0; pointer-events: none; background: linear-gradient(180deg, var(--paper) 0%, transparent 14%, transparent 86%, var(--paper) 100%); }
.show-dots { display: flex; gap: 8px; justify-content: center; margin-top: 18px; }
.show-dot { width: 26px; height: 26px; border: 0; background: none; padding: 0; cursor: pointer; display: grid; place-items: center; }
.show-dot::before { content: ""; width: 7px; height: 7px; border-radius: 50%; border: 1px solid #D6DAE1; transition: all .3s; }
.show-dot[aria-current="true"]::before { background: #F4F5F7; transform: scale(1.3); }

/* Tarjetas y controles sobre fondo oscuro */
.estilo-gala .family__group .script { color: var(--accent); }
.estilo-gala .event, .estilo-gala .rsvp { background: rgba(255, 255, 255, .04); border-color: rgba(220, 224, 232, .3); }
.estilo-gala .event { border-radius: 4px; }
.estilo-gala .countdown__unit { background: rgba(255, 255, 255, .04); border-color: rgba(220, 224, 232, .35); }
.estilo-gala .countdown__num { color: #F4F5F7; }
.estilo-gala .btn { background: rgba(255, 255, 255, .04); color: var(--ink); border-color: rgba(220, 224, 232, .6); }
.estilo-gala .btn:hover { background: rgba(255, 255, 255, .1); }
.estilo-gala .btn--solid { background: linear-gradient(135deg, #F7F8FA, #C9CED6); color: #2A1321; border-color: transparent; box-shadow: 0 10px 26px -12px rgba(255, 255, 255, .35); }
.estilo-gala .field input, .estilo-gala .field textarea { color: var(--ink); border-bottom-color: rgba(220, 224, 232, .35); }
.estilo-gala .choice span { border-color: rgba(220, 224, 232, .35); }
.estilo-gala .choice input:checked + span { background: var(--accent); color: #2A1321; border-color: var(--accent); }
.estilo-gala .rsvp__note { color: var(--accent); }
.estilo-gala .ui-music { background: rgba(28, 14, 23, .75); color: #F4F5F7; border-color: rgba(220, 224, 232, .6); }
.estilo-gala .ui-nav button::before { background: rgba(28, 14, 23, .6); border-color: rgba(220, 224, 232, .6); }
.estilo-gala .ui-nav button[aria-current="true"]::before { background: #F4F5F7; }
.estilo-gala .toast { background: #F4F5F7; color: #2A1321; }
.estilo-gala .demo-band { color: #D6DAE1; }
.estilo-gala .swatch { box-shadow: 0 0 0 1px #D6DAE1, 0 0 0 4px var(--paper), 0 0 0 5px rgba(220,224,232,.35); }
.estilo-gala .palette__dot { box-shadow: 0 0 0 1px #D6DAE1, 0 0 0 5px var(--paper), 0 0 0 6px rgba(220,224,232,.35); }

/* Cierre: foto a sangre con fundido */
.estilo-gala .scene--end.has-photo { padding-top: 0; }
.estilo-gala .end-photo { width: calc(100% + 68px); margin: 0 -34px; aspect-ratio: 4 / 5; border-radius: 0; box-shadow: none; overflow: hidden;
  -webkit-mask-image: linear-gradient(180deg, transparent 0%, #000 18%, #000 55%, transparent 100%); mask-image: linear-gradient(180deg, transparent 0%, #000 18%, #000 55%, transparent 100%); }
.estilo-gala .scene--end.has-photo .scene__inner { margin-top: -70px; position: relative; z-index: 2; }
.estilo-gala .end-name { color: var(--accent); }

/* ---------- Apertura: reflector sobre terciopelo ---------- */
.gate--gala { background: radial-gradient(120% 70% at 50% 120%, #2A1321, #0E060B 60%); }
.gg { position: relative; width: min(100%, var(--card-w)); height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; overflow: hidden; }
.gg__beam { position: absolute; top: -10%; left: 50%; width: 140%; height: 95%; transform: translateX(-50%); pointer-events: none;
  background: conic-gradient(from 180deg at 50% 0%, transparent 160deg, rgba(255, 236, 245, .16) 172deg, rgba(255, 245, 250, .22) 180deg, rgba(255, 236, 245, .16) 188deg, transparent 200deg);
  -webkit-mask: linear-gradient(180deg, #000 30%, transparent 100%); mask: linear-gradient(180deg, #000 30%, transparent 100%);
  animation: beam 4s ease-in-out infinite alternate; transition: opacity .8s; }
@keyframes beam { from { opacity: .7; } to { opacity: 1; } }
.gg__center { position: relative; text-align: center; display: grid; gap: 8px; justify-items: center; padding: 0 24px; margin-top: -40px; transition: opacity .7s, transform 1s; }
.gg__crown { width: 96px; filter: drop-shadow(0 0 14px rgba(255, 255, 255, .35)); }
.gg__kicker { font-family: var(--caps); font-size: 11px; letter-spacing: .34em; text-transform: uppercase; color: #D6DAE1; margin: 6px 0 0; }
.gg__guest { color: #F4F5F7; }
.gg__xv { font-size: 34px; color: var(--accent); margin: 0; }
.gg__name { font-family: var(--caps); font-size: clamp(46px, 14vw, 62px); letter-spacing: .14em; margin: 0; padding-left: .14em; line-height: 1.1; }
.gg__bottom { transition: opacity .5s; }
.gg__flash { position: absolute; left: 50%; top: 45%; width: 30px; height: 30px; border-radius: 50%; transform: translate(-50%, -50%) scale(0); pointer-events: none;
  background: radial-gradient(circle, rgba(255, 248, 252, .95), rgba(242, 182, 205, .55) 45%, transparent 70%); transition: transform 1.3s cubic-bezier(.5, 0, .2, 1) .3s, opacity .7s 1.2s; }
.gate--gala.is-opening .gg__center { opacity: 0; transform: scale(1.06); }
.gate--gala.is-opening .gg__bottom, .gate--gala.is-opening .gg__beam { opacity: 0; }
.gate--gala.is-opening .gg__flash { transform: translate(-50%, -50%) scale(70); opacity: 0; }
.gate--gala.is-opening { background: transparent; transition: background .6s 1s; }
/* Plata clara para textos pequeños sobre fondo oscuro */
:root.estilo-gala { --gold-ink: #D6DAE1 !important; --line: rgba(220, 224, 232, .35) !important; }

/* ---------- Animaciones avanzadas del estilo GALA ---------- */
/* Letras que caen y se enfocan una por una */
.estilo-gala .ch { display: inline-block; white-space: pre; }
.anim.estilo-gala [data-r="split"] { opacity: 1; transform: none; }
.anim.estilo-gala [data-r="split"] .ch { opacity: 0; transform: translateY(.45em) rotateX(-75deg) scale(.9); filter: blur(8px); transform-origin: 50% 100%;
  transition: opacity .9s ease, transform 1.1s cubic-bezier(.2, .8, .2, 1), filter 1s ease; transition-delay: calc(var(--d, 0) * 1ms + var(--ci) * 60ms); }
.anim.estilo-gala .is-in [data-r="split"] .ch { opacity: 1; transform: none; filter: none; }
.estilo-gala .hero-g__name .ch { background: inherit; -webkit-background-clip: text; background-clip: text; animation-delay: calc(var(--ci) * -.35s); }
.estilo-gala .hero-g__name.foil { animation: none; }
.estilo-gala .hero-g__name .ch:not(.ch--sp) { background-image: linear-gradient(100deg, #B9BEC7 0%, #F7F8FA 18%, #9DA2AC 32%, #E9ECF0 46%, #F7D9E5 58%, #A9AEB8 72%, #FFFFFF 86%, #B9BEC7 100%);
  background-size: 400% 100%; color: transparent; animation: foil 5s ease-in-out infinite; animation-delay: calc(var(--ci) * -.4s); }
/* Palabras que aparecen como si se escribieran */
.estilo-gala .w { display: inline-block; }
.anim.estilo-gala [data-r="split"] .w { opacity: 0; transform: translateY(10px); filter: blur(4px); transition: opacity .7s ease, transform .8s ease, filter .7s ease; transition-delay: calc(var(--d, 0) * 1ms + 300ms + var(--wi) * 34ms); }
.anim.estilo-gala .is-in [data-r="split"] .w { opacity: 1; transform: none; filter: none; }

/* Fotos que se revelan con barrido de telón */
.anim.estilo-gala .photo-gala[data-r="photo"], .anim.estilo-gala .end-photo[data-r="photo"] { opacity: 1; transform: none; clip-path: inset(0 0 100% 0); transition: clip-path 1.8s cubic-bezier(.75, 0, .2, 1); transition-delay: calc(var(--d, 0) * 1ms); }
.anim.estilo-gala .is-in .photo-gala[data-r="photo"], .anim.estilo-gala .is-in .end-photo[data-r="photo"] { clip-path: inset(0 0 0 0); }
.anim.estilo-gala .photo-gala img { transform: scale(1.3); transition: transform 2.6s cubic-bezier(.2, .7, .2, 1); }
.anim.estilo-gala .is-in .photo-gala img { transform: scale(1); }
.estilo-gala .photo-gala { overflow: hidden; }

/* Brillo que recorre las líneas divisorias */
.estilo-gala .scene + .scene { background-image: linear-gradient(90deg, transparent, rgba(255, 255, 255, .9), transparent), linear-gradient(90deg, transparent, rgba(220, 224, 232, .35), transparent);
  background-size: 22% 1px, 70% 1px; background-repeat: no-repeat; background-position: -30% 0, 50% 0; animation: sweep 5s ease-in-out infinite; }
@keyframes sweep { 0% { background-position: -30% 0, 50% 0; } 60%, 100% { background-position: 130% 0, 50% 0; } }

/* Cuenta regresiva que gira como reloj de aeropuerto */
.estilo-gala .countdown__unit { perspective: 300px; }
.countdown__num.flip { display: inline-block; animation: flip .6s cubic-bezier(.3, .7, .2, 1); }
@keyframes flip { 0% { transform: rotateX(-90deg); opacity: .2; } 60% { transform: rotateX(12deg); opacity: 1; } 100% { transform: rotateX(0); } }

/* Carrusel 3D */
.gallery--flow { display: block !important; position: relative; width: 100%; height: 330px; margin: 30px 0 0; padding: 0 !important; perspective: 1000px; transform-style: preserve-3d; }
.estilo-gala .gallery--flow .gallery__item { position: absolute; left: 50%; top: 0; width: 210px; height: 290px; margin-left: -105px; padding: 0 !important; border-radius: 6px !important; aspect-ratio: auto;
  background: #000; box-shadow: 0 30px 40px -22px rgba(0, 0, 0, .9), 0 0 0 1px rgba(220, 224, 232, .25);
  opacity: calc(1 - var(--a) * .22) !important; filter: brightness(calc(1 - var(--a) * .25));
  transform: translateX(calc(var(--d) * 62%)) translateZ(calc(var(--a) * -150px)) rotateY(calc(var(--d) * -36deg)) !important;
  transition: transform .9s cubic-bezier(.25, .8, .25, 1), opacity .9s, filter .9s !important; clip-path: none !important; }
.estilo-gala .gallery--flow .gallery__item.is-far { opacity: 0 !important; pointer-events: none; }
.estilo-gala .gallery--flow .gallery__item img { transform: none !important; border-radius: 6px; }
.estilo-gala .gallery--flow .gallery__item.is-center::after { content: ""; position: absolute; inset: 0; border-radius: 6px; pointer-events: none;
  background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, .28) 50%, transparent 65%) -150% 0 / 250% 100% no-repeat; animation: gleam 3.8s ease-in-out infinite; }
@keyframes gleam { 0%, 30% { background-position: -150% 0; } 70%, 100% { background-position: 150% 0; } }
.gallery--flow::before { content: ""; position: absolute; left: 10%; right: 10%; bottom: -14px; height: 30px; background: radial-gradient(closest-side, rgba(242, 182, 205, .25), transparent); }

/* Apertura: corona que se dibuja y destellos del nombre */
.gg__dust { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 2; }
.anim .gate--gala .draw { stroke-dashoffset: 1; }
.anim .gate--gala.is-in .draw { stroke-dashoffset: 0; }
.gg__name { transition: opacity .4s; }
.ambient .trail { position: absolute; inset: 0; width: 100%; height: 100%; }

/* Palabras que no se parten al animar letra por letra */
.estilo-gala .wd { display: inline-block; white-space: nowrap; }

/* ===== Gala en tonos rosas (tema "galarosa") ===== */
:root.estilo-gala.tema-galarosa { --gold-ink: #FFF0F6 !important; --line: rgba(255, 240, 246, .45) !important; color-scheme: light; }
.tema-galarosa.estilo-gala body { background: radial-gradient(900px 640px at 50% 0%, #D77AA3, transparent 70%), radial-gradient(700px 500px at 50% 100%, #9C3466, transparent 70%), var(--backdrop); }
.tema-galarosa.estilo-gala .card { box-shadow: 0 0 0 1px rgba(255, 240, 246, .18), 0 40px 90px -30px rgba(80, 10, 40, .7); }
.tema-galarosa.estilo-gala .label, .tema-galarosa.estilo-gala .demo-band { color: #FFF0F6; }
.tema-galarosa .hero-g__photo::after {
  background: radial-gradient(120% 80% at 50% 30%, transparent 45%, rgba(94, 24, 58, .45) 100%),
              linear-gradient(180deg, rgba(94, 24, 58, .3) 0%, transparent 25%, transparent 45%, rgba(150, 50, 95, .82) 72%, var(--paper) 96%); }
.tema-galarosa.estilo-gala .event, .tema-galarosa.estilo-gala .rsvp { background: rgba(255, 255, 255, .09); border-color: rgba(255, 240, 246, .4); }
.tema-galarosa.estilo-gala .countdown__unit { background: rgba(255, 255, 255, .1); border-color: rgba(255, 240, 246, .45); }
.tema-galarosa.estilo-gala .btn { background: rgba(255, 255, 255, .1); border-color: rgba(255, 240, 246, .7); }
.tema-galarosa.estilo-gala .btn--solid { background: linear-gradient(135deg, #FFFFFF, #FBD9E7); color: #8E2F5C; border-color: transparent; box-shadow: 0 10px 26px -12px rgba(90, 10, 45, .55); }
.tema-galarosa.estilo-gala .choice input:checked + span { background: #FFFFFF; color: #8E2F5C; border-color: #FFFFFF; }
.tema-galarosa.estilo-gala .ui-music { background: rgba(122, 38, 80, .8); border-color: rgba(255, 240, 246, .7); }
.tema-galarosa.estilo-gala .ui-nav button::before { background: rgba(122, 38, 80, .6); border-color: rgba(255, 240, 246, .7); }
.tema-galarosa.estilo-gala .toast { color: #8E2F5C; }
.tema-galarosa.estilo-gala .gallery--show .gallery__item { background: #5E1C3E; }
.tema-galarosa .gate--gala { background: radial-gradient(120% 70% at 50% 120%, #D77AA3, #9C3466 45%, #6A1F45 80%); }
.tema-galarosa .gate--gala.is-opening { background: transparent; }
.estilo-gala .rsvp__head .script { font-size: clamp(34px, 10.2vw, 46px); line-height: 1.15; }

/* ===== Gala en rosa claro (tema "rosaclaro") ===== */
:root.estilo-gala.tema-rosaclaro { --gold-ink: #A2436F !important; --line: rgba(162, 67, 111, .3) !important; color-scheme: light; }
.tema-rosaclaro.estilo-gala body { background: radial-gradient(900px 640px at 50% 0%, #FFF3F8, transparent 70%), radial-gradient(700px 500px at 50% 100%, #EDB0CA, transparent 70%), var(--backdrop); }
.tema-rosaclaro.estilo-gala .card { box-shadow: 0 0 0 1px rgba(162, 67, 111, .12), 0 40px 90px -30px rgba(156, 52, 102, .45); }
.tema-rosaclaro.estilo-gala .label, .tema-rosaclaro.estilo-gala .demo-band { color: #A2436F; }
.tema-rosaclaro.estilo-gala .gold-text { background-image: linear-gradient(135deg, #8E2F5C 0%, #D77AA3 40%, #B23A72 55%, #7A2650 100%); }
.tema-rosaclaro.estilo-gala .scene + .scene { background-image: linear-gradient(90deg, transparent, rgba(184, 60, 118, .55), transparent), linear-gradient(90deg, transparent, rgba(162, 67, 111, .25), transparent); }
.tema-rosaclaro.estilo-gala .event, .tema-rosaclaro.estilo-gala .rsvp { background: rgba(255, 255, 255, .55); border-color: rgba(162, 67, 111, .25); }
.tema-rosaclaro.estilo-gala .countdown__unit { background: rgba(255, 255, 255, .6); border-color: rgba(162, 67, 111, .3); }
.tema-rosaclaro.estilo-gala .countdown__num { color: #7A2650; }
.tema-rosaclaro.estilo-gala .btn { background: rgba(255, 255, 255, .6); color: #7A2650; border-color: rgba(162, 67, 111, .5); }
.tema-rosaclaro.estilo-gala .btn:hover { background: #fff; }
.tema-rosaclaro.estilo-gala .btn--solid { background: linear-gradient(135deg, #C9548A, #9C3466); color: #fff; border-color: transparent; box-shadow: 0 10px 26px -12px rgba(156, 52, 102, .6); }
.tema-rosaclaro.estilo-gala .field input, .tema-rosaclaro.estilo-gala .field textarea, .tema-rosaclaro.estilo-gala .field select { color: var(--ink); border-bottom-color: rgba(162, 67, 111, .35); }
.tema-rosaclaro.estilo-gala .choice span { border-color: rgba(162, 67, 111, .4); }
.tema-rosaclaro.estilo-gala .choice input:checked + span { background: #B83C76; color: #fff; border-color: #B83C76; }
.tema-rosaclaro.estilo-gala .ui-music { background: rgba(255, 243, 248, .88); color: #9C3466; border-color: rgba(162, 67, 111, .5); }
.tema-rosaclaro.estilo-gala .ui-nav button::before { background: rgba(255, 255, 255, .7); border-color: rgba(162, 67, 111, .5); }
.tema-rosaclaro.estilo-gala .ui-nav button[aria-current="true"]::before { background: #B83C76; }
.tema-rosaclaro.estilo-gala .toast { background: #9C3466; color: #fff; }
.tema-rosaclaro.estilo-gala .swatch { box-shadow: 0 0 0 1px #A2436F, 0 0 0 4px var(--paper), 0 0 0 5px rgba(162, 67, 111, .3); }
.tema-rosaclaro.estilo-gala .gallery--show .gallery__item { background: #F2BFD5; }
.tema-rosaclaro .hero-g__photo::after {
  background: radial-gradient(120% 80% at 50% 30%, transparent 50%, rgba(122, 38, 80, .25) 100%),
              linear-gradient(180deg, rgba(122, 38, 80, .22) 0%, transparent 22%, transparent 42%, rgba(251, 227, 237, .78) 64%, var(--paper) 86%); }
.tema-rosaclaro .hero-g__date i { background: linear-gradient(90deg, transparent, #A2436F); }
.tema-rosaclaro .hero-g__crown, .tema-rosaclaro .gg__crown { filter: drop-shadow(0 2px 8px rgba(156, 52, 102, .35)); }
.tema-rosaclaro.estilo-gala .hero-g__name .ch:not(.ch--sp) { background-image: linear-gradient(100deg, #8E2F5C 0%, #C9548A 18%, #7A2650 32%, #D77AA3 46%, #F2B6CD 56%, #9C3466 70%, #C24E84 86%, #8E2F5C 100%); }
.tema-rosaclaro .gate--gala { background: radial-gradient(120% 75% at 50% 110%, #F2BFD5, #FBE3ED 55%, #FFF5F9 100%); }
.tema-rosaclaro .gate--gala.is-opening { background: transparent; }
.tema-rosaclaro .gg__beam { background: conic-gradient(from 180deg at 50% 0%, transparent 160deg, rgba(255, 255, 255, .55) 172deg, rgba(255, 255, 255, .8) 180deg, rgba(255, 255, 255, .55) 188deg, transparent 200deg); }
.tema-rosaclaro .gg__kicker { color: #A2436F; }
.tema-rosaclaro .gg__guest { color: #5E1A3C; }
.tema-rosaclaro .gg__flash { background: radial-gradient(circle, rgba(255, 255, 255, .98), rgba(247, 211, 226, .7) 45%, transparent 70%); }
