/* ==========================================================================
   Boda Asier & Tivoni — blanco limpio + azul atlántico
   Mobile-first. En escritorio se presenta como una "app" centrada.
   ========================================================================== */
:root {
  --ink: #0F2A47;        /* azul atlántico profundo */
  --blue: #1F4E79;
  --sea: #4E83B0;
  --foam: #BFD3E6;
  --mist: #EEF3F8;
  --paper: #FFFFFF;
  --off: #FAFBFC;
  --line: #DCE5EE;
  --text: #1B2733;
  --muted: #6B7B8C;
  --sand: #C2AE8F;       /* toque cálido mínimo */
  --danger: #A6423A;

  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Jost", system-ui, -apple-system, "Segoe UI", sans-serif;

  --r: 18px;
  --ease: cubic-bezier(.22, .8, .2, 1);
  --app: 480px;
  --wrap: 1120px;
  --safe-b: env(safe-area-inset-bottom, 0px);
  --safe-t: env(safe-area-inset-top, 0px);
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--sans);
  font-weight: 300;
  color: var(--text);
  background: var(--paper);
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  -webkit-tap-highlight-color: transparent;
  overflow-x: hidden;
}
body.lock { overflow: hidden; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; padding: 0; }
a { color: inherit; text-decoration: none; }
[hidden] { display: none !important; }
svg { display: block; }
:focus-visible { outline: 2px solid var(--sea); outline-offset: 3px; border-radius: 6px; }

/* Escritorio: la web vive en una columna tipo móvil */

/* ---------- Tipografía y comunes ---------- */
.eyebrow {
  font-family: var(--sans); font-weight: 400; font-size: .72rem;
  letter-spacing: .32em; text-transform: uppercase; color: var(--sea); margin: 0 0 .8rem;
}
.title { font-family: var(--serif); font-weight: 400; font-size: clamp(2.3rem, 10vw, 3rem); line-height: 1.05; color: var(--ink); margin: 0 0 1rem; }
.lead { font-size: 1.02rem; color: var(--muted); margin: 0 0 2rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5rem;
  min-height: 52px; padding: 0 1.6rem; border-radius: 999px;
  font-size: .82rem; letter-spacing: .18em; text-transform: uppercase; font-weight: 400;
  transition: transform .25s var(--ease), background .25s, color .25s, box-shadow .25s, opacity .25s;
}
.btn:active { transform: scale(.96); }
.btn--primary { background: var(--ink); color: #fff; box-shadow: 0 10px 24px -12px rgba(15, 42, 71, .6); }
.btn--primary:hover { background: var(--blue); }
.btn--primary[disabled] { opacity: .45; pointer-events: none; }
.btn--ghost { border: 1px solid var(--line); color: var(--ink); background: #fff; }
.btn--ghost:hover { border-color: var(--sea); }
.btn--text { color: var(--muted); padding: 0 .6rem; letter-spacing: .14em; }
.btn.is-loading { pointer-events: none; }
.btn.is-loading::after { content: ""; width: 14px; height: 14px; border-radius: 50%; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; animation: spin .8s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* ==========================================================================
   SOBRE
   ========================================================================== */
.intro {
  position: fixed; inset: 0; z-index: 50;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2.2rem;
  background: radial-gradient(120% 80% at 50% 30%, #fff 0%, var(--mist) 100%);
  transition: opacity .9s var(--ease), visibility .9s;
  padding: 24px;
}
.intro.is-leaving { opacity: 0; visibility: hidden; }
.intro__para { font-family: var(--serif); font-style: italic; font-size: 1.35rem; color: var(--blue); margin: 0; opacity: 0; animation: fadeUp 1s .3s var(--ease) forwards; }
.intro__hint { font-size: .7rem; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); margin: 0; opacity: 0; animation: fadeUp 1s 1s var(--ease) forwards, breathe 2.6s 2s ease-in-out infinite; }
.intro.is-open .intro__hint, .intro.is-open .intro__para { animation: none; opacity: 0; transition: opacity .4s; }

.envelope {
  position: relative; width: min(84vw, 360px); aspect-ratio: 1.45;
  perspective: 1400px; opacity: 0; animation: envIn 1.1s .1s var(--ease) forwards;
}
@keyframes envIn { from { opacity: 0; transform: translateY(30px) rotate(-3deg); } to { opacity: 1; transform: none; } }
.envelope__back { position: absolute; inset: 0; background: #E4ECF4; border-radius: 6px; box-shadow: 0 30px 60px -28px rgba(15, 42, 71, .45); }
.letter {
  position: absolute; left: 6%; right: 6%; top: 6%; height: 88%; z-index: 2;
  background: #fff; border-radius: 4px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .35rem; text-align: center;
  box-shadow: 0 6px 18px -10px rgba(15, 42, 71, .3);
  transition: transform 1.1s .55s var(--ease);
}
.letter::before { content: ""; position: absolute; inset: 8px; border: 1px solid var(--foam); border-radius: 2px; pointer-events: none; }
.letter__kicker { font-size: .58rem; letter-spacing: .32em; text-transform: uppercase; color: var(--sea); }
.letter__names { font-family: var(--serif); font-size: 1.8rem; color: var(--ink); line-height: 1.1; }
.letter__names em, .names__amp { font-style: italic; color: var(--sea); }
.letter__rule { width: 28px; height: 1px; background: var(--sand); margin: .2rem 0; }
.letter__date { font-size: .7rem; letter-spacing: .08em; color: var(--muted); }
.envelope__front {
  position: absolute; inset: 0; z-index: 3; border-radius: 6px;
  background: linear-gradient(180deg, #F3F7FB, #EAF1F7);
  clip-path: polygon(0 0, 50% 54%, 100% 0, 100% 100%, 0 100%);
}
.envelope__front::after { /* pliegues */
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(to top right, transparent 49.6%, rgba(15,42,71,.06) 50%, transparent 50.4%),
              linear-gradient(to top left, transparent 49.6%, rgba(15,42,71,.06) 50%, transparent 50.4%);
}
.envelope__flap {
  position: absolute; left: 0; right: 0; top: 0; height: 58%; z-index: 4;
  background: linear-gradient(180deg, #DDE7F1, #E9F0F6);
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  transform-origin: 50% 0;
  transition: transform .8s var(--ease), z-index 0s .4s;
}
.seal {
  position: absolute; left: 50%; top: 58%; z-index: 5;
  width: 72px; height: 72px; margin: -36px 0 0 -36px; border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #2C5E8F, var(--ink) 70%);
  color: #fff; font-family: var(--serif); font-size: 1.25rem; font-style: italic; letter-spacing: .02em;
  box-shadow: 0 8px 20px -6px rgba(15, 42, 71, .6), inset 0 0 0 3px rgba(255,255,255,.12), inset 0 0 0 5px var(--ink), inset 0 0 0 6px rgba(255,255,255,.18);
  transition: transform .5s var(--ease), opacity .5s;
}
.seal::after { content: ""; position: absolute; inset: -10px; border-radius: 50%; border: 1px solid var(--sea); opacity: .5; animation: ripple 2.4s ease-out infinite; }
@keyframes ripple { from { transform: scale(.8); opacity: .6; } to { transform: scale(1.5); opacity: 0; } }
@keyframes breathe { 50% { opacity: .35; } }
.intro.is-open .seal { transform: scale(.2) rotate(-40deg); opacity: 0; }
.intro.is-open .envelope__flap { transform: rotateX(180deg); z-index: 1; }
.intro.is-open .letter { transform: translateY(-62%); }

/* ==========================================================================
   HERO
   ========================================================================== */
.hero {
  position: relative; min-height: 100svh; display: flex; align-items: center; justify-content: center;
  text-align: center; padding: calc(56px + var(--safe-t)) 24px 140px; overflow: hidden;
  background: radial-gradient(90% 60% at 50% 0%, var(--mist) 0%, #fff 70%);
}
.hero__inner { position: relative; z-index: 2; display: flex; flex-direction: column; align-items: center; }
.names { font-family: var(--serif); font-weight: 400; color: var(--ink); margin: .4rem 0 1.4rem; line-height: .9; display: flex; flex-direction: column; align-items: center; }
.names__a, .names__b { font-size: clamp(3.6rem, 19vw, 5.2rem); }
.names__amp { font-size: clamp(2.2rem, 10vw, 3rem); margin: .3rem 0 .1rem; }
.hero__date { font-family: var(--serif); font-size: 1.3rem; color: var(--ink); margin: 0; }
.hero__place { font-size: .78rem; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); margin: .4rem 0 2rem; }
.hero__limit { font-size: .78rem; color: var(--muted); margin: .9rem 0 0; }

.countdown { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; width: min(100%, 330px); margin: 0 0 2rem; }
.cd { background: rgba(255,255,255,.75); border: 1px solid var(--line); border-radius: 14px; padding: 12px 0 8px; backdrop-filter: blur(6px); }
.cd__n { display: block; font-family: var(--serif); font-size: 1.9rem; line-height: 1; color: var(--ink); font-variant-numeric: tabular-nums; }
.cd__n.tick { animation: tick .5s var(--ease); }
@keyframes tick { from { transform: translateY(-6px); opacity: .2; } to { transform: none; opacity: 1; } }
.cd__l { font-size: .62rem; letter-spacing: .2em; text-transform: uppercase; color: var(--muted); }

.waves { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 90px; z-index: 1; }
.wave { animation: drift 14s linear infinite; }
.wave--1 { fill: var(--mist); }
.wave--2 { fill: #DCE7F1; animation-duration: 10s; animation-direction: reverse; }
.wave--3 { fill: #fff; animation-duration: 18s; }
@keyframes drift { from { transform: translateX(0); } to { transform: translateX(-200px); } }

/* entrada escalonada del hero tras abrir el sobre */
.reveal-up { opacity: 0; transform: translateY(18px); }
body.is-ready .reveal-up { animation: fadeUp 1s var(--ease) forwards; }
body.is-ready .reveal-up:nth-child(1) { animation-delay: .1s; }
body.is-ready .names .reveal-up:nth-child(1) { animation-delay: .25s; }
body.is-ready .names .reveal-up:nth-child(2) { animation-delay: .45s; }
body.is-ready .names .reveal-up:nth-child(3) { animation-delay: .65s; }
body.is-ready .hero__date { animation-delay: .9s; }
body.is-ready .hero__place { animation-delay: 1s; }
body.is-ready .countdown { animation-delay: 1.15s; }
body.is-ready .hero__inner > .btn { animation-delay: 1.3s; }
body.is-ready .hero__limit { animation-delay: 1.4s; }
@keyframes fadeUp { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }

/* ==========================================================================
   HUB
   ========================================================================== */
.hub { display: grid; gap: 12px; padding: 8px 20px 24px; }
.hub__card {
  position: relative; display: grid; grid-template-columns: auto 1fr auto; grid-template-rows: auto auto; column-gap: 16px;
  text-align: left; padding: 20px 20px; border: 1px solid var(--line); border-radius: var(--r); background: #fff;
  transition: transform .3s var(--ease), border-color .3s, box-shadow .3s;
}
.hub__card:active { transform: scale(.98); }
.hub__card:hover { border-color: var(--foam); box-shadow: 0 16px 30px -22px rgba(15, 42, 71, .45); }
.hub__num { grid-row: 1 / 3; font-family: var(--serif); font-style: italic; font-size: 1.6rem; color: var(--sea); line-height: 1; padding-top: 2px; }
.hub__title { font-family: var(--serif); font-size: 1.5rem; color: var(--ink); line-height: 1.1; }
.hub__text { grid-column: 2; font-size: .85rem; color: var(--muted); }
.hub__arrow { grid-row: 1 / 3; grid-column: 3; align-self: center; color: var(--sea); transition: transform .3s var(--ease); }
.hub__card:hover .hub__arrow { transform: translateX(4px); }

/* ==========================================================================
   BLOQUES
   ========================================================================== */
.block { padding: 72px 24px 24px; scroll-margin-top: 10px; }
[data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
[data-reveal].is-in { opacity: 1; transform: none; }

/* Estado RSVP */
.rsvp { border-radius: 22px; padding: 28px 24px; background: var(--ink); color: #fff; position: relative; overflow: hidden; }
.rsvp::before { content: ""; position: absolute; right: -60px; top: -60px; width: 200px; height: 200px; border-radius: 50%; border: 1px solid rgba(255,255,255,.12); box-shadow: 0 0 0 30px rgba(255,255,255,.04), 0 0 0 60px rgba(255,255,255,.03); }
.rsvp h3 { font-family: var(--serif); font-weight: 400; font-size: 2rem; line-height: 1.1; margin: 0 0 .6rem; }
.rsvp p { margin: 0 0 1.4rem; color: var(--foam); font-size: .95rem; }
.rsvp .btn--primary { background: #fff; color: var(--ink); }
.rsvp .btn--text { color: var(--foam); }
.rsvp__row { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.rsvp__meta { display: flex; gap: 24px; margin: 0 0 1.4rem; }
.rsvp__meta div { display: flex; flex-direction: column; }
.rsvp__meta b { font-family: var(--serif); font-weight: 400; font-size: 2.4rem; line-height: 1; }
.rsvp__meta span { font-size: .66rem; letter-spacing: .22em; text-transform: uppercase; color: var(--foam); }

/* ---------- Carta (menú) ---------- */
.carta { position: relative; border: 1px solid var(--line); border-radius: 24px; padding: 36px 22px 30px; text-align: center; background: linear-gradient(180deg, #fff, var(--off)); }
.carta::before { content: ""; position: absolute; inset: 8px; border: 1px solid var(--mist); border-radius: 18px; pointer-events: none; }
.curso { margin: 0 0 30px; }
.curso:last-child { margin-bottom: 0; }
.curso__tipo { font-size: .68rem; letter-spacing: .3em; text-transform: uppercase; color: var(--sea); margin: 0 0 10px; }
.curso__plato { font-family: var(--serif); font-size: 1.25rem; color: var(--ink); margin: 0 0 4px; line-height: 1.3; }
.orn { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 0 0 30px; color: var(--sand); }
.orn::before, .orn::after { content: ""; height: 1px; width: 40px; background: currentColor; opacity: .7; }
.orn i { width: 5px; height: 5px; transform: rotate(45deg); border: 1px solid currentColor; }
.mains { display: grid; gap: 10px; margin-top: 6px; }
.main {
  display: flex; gap: 14px; align-items: center; text-align: left;
  padding: 14px 16px; border: 1px solid var(--line); border-radius: 16px; background: #fff;
}
.main svg { width: 34px; height: 34px; flex: none; stroke: var(--sea); fill: none; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.main b { display: block; font-family: var(--serif); font-weight: 500; font-size: 1.15rem; color: var(--ink); line-height: 1.2; }
.main span { font-size: .82rem; color: var(--muted); }
.mains__note { font-size: .8rem; color: var(--muted); margin: 12px 0 0; font-style: italic; }
.bodega { margin-top: 28px; padding-top: 22px; border-top: 1px dashed var(--line); font-size: .9rem; color: var(--muted); }

/* ---------- Lugar ---------- */
.place { border: 1px solid var(--line); border-radius: 24px; overflow: hidden; background: #fff; }
.place__art { width: 100%; height: auto; background: linear-gradient(180deg, #F4F8FB, #fff); }
.pa-sun { fill: none; stroke: var(--sand); stroke-width: 1.2; }
.pa-lawn { fill: #E5EDF5; }
.pa-house { fill: #fff; stroke: var(--blue); stroke-width: 1.3; stroke-linejoin: round; }
.pa-line { fill: none; stroke: var(--blue); stroke-width: 1.2; stroke-linecap: round; stroke-linejoin: round; }
.pa-tree { fill: #fff; stroke: var(--blue); stroke-width: 1.2; }
.place__media { position: relative; }
.place__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: opacity .8s; }
.place.has-photo .place__img { opacity: 1; }
.place__addr { font-family: var(--serif); font-size: 1.2rem; color: var(--ink); margin: 18px 22px 6px; line-height: 1.35; }
.place__note { font-size: .88rem; color: var(--muted); margin: 0 22px 18px; }
.place__actions { display: grid; gap: 10px; padding: 0 22px 22px; }

.timeline { list-style: none; margin: 40px 0 0; padding: 0 0 0 4px; position: relative; }
.timeline::before { content: ""; position: absolute; left: 25px; top: 10px; bottom: 10px; width: 1px; background: var(--line); }
.tl { position: relative; display: grid; grid-template-columns: 44px 1fr; gap: 16px; padding: 0 0 28px; }
.tl__icon { width: 44px; height: 44px; border-radius: 50%; background: #fff; border: 1px solid var(--line); display: grid; place-items: center; position: relative; z-index: 1; transition: background .5s, border-color .5s; }
.tl__icon svg { width: 22px; height: 22px; stroke: var(--sea); fill: none; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.tl.is-in .tl__icon { background: var(--mist); border-color: var(--foam); }
.tl__hora { font-family: var(--serif); font-size: 1.6rem; color: var(--ink); line-height: 1; }
.tl__titulo { font-size: .72rem; letter-spacing: .26em; text-transform: uppercase; color: var(--sea); margin: 4px 0 2px; }
.tl__texto { font-size: .9rem; color: var(--muted); margin: 0; }

/* ---------- Footer ---------- */
.foot { text-align: center; padding: 56px 24px calc(110px + var(--safe-b)); }
.foot__mono { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; border: 1px solid var(--foam); font-family: var(--serif); font-style: italic; font-size: 1.2rem; color: var(--ink); }
.foot__tag { font-family: var(--serif); font-size: 1.3rem; color: var(--ink); margin: 14px 0 2px; }
.foot__small { font-size: .78rem; color: var(--muted); margin: 0; }

/* ==========================================================================
   TABBAR
   ========================================================================== */
.tabbar {
  position: fixed; left: 12px; right: 12px; bottom: calc(12px + var(--safe-b)); z-index: 20;
  display: grid; grid-template-columns: repeat(6, 1fr);
  background: rgba(255,255,255,.86); backdrop-filter: blur(14px) saturate(1.4); -webkit-backdrop-filter: blur(14px) saturate(1.4);
  border: 1px solid var(--line); border-radius: 22px; padding: 6px;
  box-shadow: 0 18px 40px -22px rgba(15, 42, 71, .5);
  animation: fadeUp .8s 1.6s var(--ease) both;
}
.tabbar a { display: flex; flex-direction: column; align-items: center; gap: 2px; padding: 8px 0 6px; border-radius: 16px; font-size: .62rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); transition: background .3s, color .3s; }
.tabbar svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.tabbar a.is-active { background: var(--ink); color: #fff; }

/* ==========================================================================
   HISTORIA (formulario)
   ========================================================================== */
.story {
  position: fixed; inset: 0; z-index: 40; background: #fff;
  display: flex; flex-direction: column;
  padding: calc(12px + var(--safe-t)) 0 calc(12px + var(--safe-b));
  animation: storyIn .5s var(--ease);
}
@keyframes storyIn { from { opacity: 0; transform: translateY(30px); } to { opacity: 1; transform: none; } }
.story.is-closing { animation: storyOut .35s var(--ease) forwards; }
@keyframes storyOut { to { opacity: 0; transform: translateY(30px); } }
.story__top { display: flex; align-items: center; gap: 12px; padding: 0 16px 0 20px; }
.story__bars { flex: 1; display: flex; gap: 4px; }
.story__bars span { flex: 1; height: 3px; border-radius: 3px; background: var(--line); overflow: hidden; position: relative; }
.story__bars span::after { content: ""; position: absolute; inset: 0; background: var(--ink); transform: scaleX(0); transform-origin: left; transition: transform .5s var(--ease); }
.story__bars span.done::after { transform: scaleX(1); }
.story__bars span.now::after { transform: scaleX(.5); }
.story__close { width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; }
.story__close svg { width: 22px; height: 22px; stroke: var(--ink); stroke-width: 1.5; fill: none; }
.story__stage { position: relative; flex: 1; overflow: hidden; }
.slide {
  position: absolute; inset: 0; overflow-y: auto; -webkit-overflow-scrolling: touch;
  padding: 28px 24px 24px; display: flex; flex-direction: column;
  transition: transform .5s var(--ease), opacity .5s var(--ease);
}
.slide.in-right { transform: translateX(40px); opacity: 0; }
.slide.in-left { transform: translateX(-40px); opacity: 0; }
.slide.out-left { transform: translateX(-40px); opacity: 0; pointer-events: none; }
.slide.out-right { transform: translateX(40px); opacity: 0; pointer-events: none; }
.story__nav { display: flex; justify-content: space-between; align-items: center; gap: 12px; padding: 10px 20px 0; }
.story__nav .btn--primary { flex: 1; max-width: 240px; margin-left: auto; }

.q-kicker { font-size: .7rem; letter-spacing: .3em; text-transform: uppercase; color: var(--sea); margin: 0 0 .8rem; }
.q-title { font-family: var(--serif); font-weight: 400; font-size: clamp(2.1rem, 9vw, 2.6rem); line-height: 1.08; color: var(--ink); margin: 0 0 .6rem; }
.q-sub { color: var(--muted); margin: 0 0 1.6rem; font-size: .98rem; }
.q-label { font-size: .7rem; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); margin: 1.4rem 0 .6rem; }
.q-error { color: var(--danger); font-size: .86rem; min-height: 1.3em; margin: .6rem 0 0; }
.shake { animation: shake .4s; }
@keyframes shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }

.field { position: relative; }
.input, .textarea {
  width: 100%; border: 0; border-bottom: 1px solid var(--line); background: transparent;
  font-family: var(--serif); font-size: 1.6rem; color: var(--ink); padding: 10px 0; border-radius: 0;
  transition: border-color .3s; outline: none;
}
.input:focus, .textarea:focus { border-color: var(--ink); }
.input::placeholder, .textarea::placeholder { color: #B3C0CC; }
.input--sm { font-size: 1.25rem; }
.textarea { font-size: 1.2rem; min-height: 120px; resize: none; border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px; }

.suggest { list-style: none; margin: 8px 0 0; padding: 0; }
.suggest li button { width: 100%; text-align: left; padding: 12px 4px; border-bottom: 1px solid var(--mist); font-size: 1rem; color: var(--ink); display: flex; justify-content: space-between; }
.suggest li button::after { content: "→"; color: var(--sea); }
.found { display: flex; gap: 10px; align-items: center; margin-top: 18px; padding: 12px 14px; border-radius: 14px; background: var(--mist); color: var(--ink); font-size: .92rem; animation: fadeUp .5s var(--ease); }
.found svg { width: 20px; height: 20px; stroke: var(--sea); fill: none; stroke-width: 2; flex: none; }
.found--warn { background: #F8F4EE; }

.choices { display: grid; gap: 12px; }
.choice {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px; text-align: left;
  padding: 20px 22px; border: 1px solid var(--line); border-radius: 18px; background: #fff;
  transition: border-color .25s, background .25s, transform .25s var(--ease), color .25s;
}
.choice:active { transform: scale(.98); }
.choice b { font-family: var(--serif); font-weight: 500; font-size: 1.45rem; color: var(--ink); line-height: 1.15; }
.choice span { font-size: .86rem; color: var(--muted); }
.choice.is-on { border-color: var(--ink); background: var(--ink); }
.choice.is-on b, .choice.is-on span { color: #fff; }
.choice--row { flex-direction: row; align-items: center; gap: 14px; }
.choice--row svg { width: 34px; height: 34px; flex: none; stroke: var(--sea); fill: none; stroke-width: 1.4; stroke-linecap: round; stroke-linejoin: round; }
.choice--row.is-on svg { stroke: #fff; }
.choice--row div { display: flex; flex-direction: column; }

.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { padding: 10px 16px; border-radius: 999px; border: 1px solid var(--line); font-size: .9rem; color: var(--ink); background: #fff; transition: all .25s var(--ease); }
.chip.is-on { background: var(--ink); color: #fff; border-color: var(--ink); transform: scale(1.03); }

/* vinilo */
.vinyl { position: relative; width: 170px; height: 170px; margin: 4px auto 18px; }
.vinyl__disc { width: 100%; height: 100%; border-radius: 50%;
  background: repeating-radial-gradient(circle, #13283F 0 2px, #1A3350 2px 4px);
  box-shadow: 0 18px 36px -18px rgba(15,42,71,.7);
  animation: spin 6s linear infinite; display: grid; place-items: center; }
.vinyl__disc.fast { animation-duration: 1.2s; }
.vinyl__label { width: 44%; height: 44%; border-radius: 50%; background: radial-gradient(circle, #fff 0 6%, var(--foam) 7% 100%); display: grid; place-items: center; text-align: center; padding: 8px; font-family: var(--serif); font-size: .72rem; color: var(--ink); line-height: 1.1; overflow: hidden; }
.vinyl__arm { position: absolute; right: -14px; top: 6px; width: 70px; height: 8px; background: var(--sand); border-radius: 4px; transform-origin: right center; transform: rotate(-58deg); transition: transform .8s var(--ease); }
.vinyl.is-playing .vinyl__arm { transform: rotate(-32deg); }
.notes { position: absolute; inset: 0; pointer-events: none; }
.notes i { position: absolute; left: 50%; top: 40%; font-style: normal; color: var(--sea); font-family: var(--serif); font-size: 1.2rem; opacity: 0; animation: note 2.2s ease-out forwards; }
@keyframes note { 0% { opacity: 0; transform: translate(0,0) scale(.6); } 20% { opacity: 1; } 100% { opacity: 0; transform: translate(var(--x), -90px) scale(1.2); } }

/* sandalias */
.sandal-wrap { display: grid; place-items: center; height: 150px; margin: 0 0 6px; }
.sandal { width: 64px; height: auto; transform: rotate(-14deg); transition: transform .45s var(--ease); }
.sandal path { fill: none; stroke-linecap: round; stroke-linejoin: round; }
.sandal .sole { fill: var(--mist); stroke: var(--foam); stroke-width: 1.4; }
.sandal .strap { stroke: var(--ink); stroke-width: 5; }
.sandal .buckle { fill: var(--sand); }
.sizes { display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; padding: 8px 2px 14px; margin: 0 -24px; padding-left: 24px; padding-right: 24px; scrollbar-width: none; }
.sizes::-webkit-scrollbar { display: none; }
.size { flex: none; width: 58px; height: 64px; border-radius: 16px; border: 1px solid var(--line); scroll-snap-align: center; font-family: var(--serif); font-size: 1.5rem; color: var(--ink); background: #fff; transition: all .25s var(--ease); }
.size.is-on { background: var(--ink); color: #fff; border-color: var(--ink); transform: translateY(-4px); box-shadow: 0 12px 20px -12px rgba(15,42,71,.7); }

/* resumen */
.sum { list-style: none; margin: 0; padding: 0; border-top: 1px solid var(--line); }
.sum li { display: grid; grid-template-columns: 1fr auto; gap: 4px 12px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.sum small { grid-column: 1; font-size: .66rem; letter-spacing: .22em; text-transform: uppercase; color: var(--muted); }
.sum b { grid-column: 1; font-family: var(--serif); font-weight: 500; font-size: 1.15rem; color: var(--ink); line-height: 1.3; }
.sum button { grid-column: 2; grid-row: 1 / 3; align-self: center; font-size: .72rem; letter-spacing: .16em; text-transform: uppercase; color: var(--sea); padding: 8px; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; }

/* ==========================================================================
   REVELADO DE MESA
   ========================================================================== */
.reveal { position: fixed; inset: 0; z-index: 45; background: #fff; overflow-y: auto; animation: storyIn .5s var(--ease); }
.reveal__inner { min-height: 100%; display: flex; flex-direction: column; align-items: center; text-align: center; padding: calc(40px + var(--safe-t)) 20px calc(28px + var(--safe-b)); }
.reveal__title { font-family: var(--serif); font-weight: 400; font-size: clamp(2.2rem, 10vw, 2.8rem); line-height: 1.05; color: var(--ink); margin: 0 0 18px; }
.salon { width: 100%; max-width: 400px; border-radius: 24px; background: linear-gradient(180deg, var(--off), var(--mist)); border: 1px solid var(--line); overflow: hidden; }
#salon { width: 100%; height: auto; aspect-ratio: 360 / 440; }
.s-label { font-family: var(--sans); font-size: 8px; letter-spacing: .25em; text-transform: uppercase; fill: var(--muted); }
.s-floor { fill: none; stroke: var(--foam); stroke-dasharray: 3 4; }
.s-t { opacity: 0; transform-box: fill-box; transform-origin: center; }
.salon.go .s-t { animation: popIn .6s var(--ease) forwards; }
@keyframes popIn { from { opacity: 0; transform: scale(.6); } to { opacity: 1; transform: none; } }
.s-table { fill: #fff; stroke: var(--foam); stroke-width: 1.2; }
.s-num { font-family: var(--serif); font-size: 13px; fill: var(--muted); text-anchor: middle; dominant-baseline: central; }
.s-seat { fill: #fff; stroke: var(--foam); stroke-width: 1; }
.s-t.me .s-table { stroke: var(--ink); stroke-width: 1.6; fill: var(--mist); }
.s-t.me .s-num { fill: var(--ink); font-weight: 600; }
.s-seat.me { fill: var(--ink); stroke: var(--ink); }
.s-seat.plus { fill: var(--sea); stroke: var(--sea); }
.s-pulse { fill: none; stroke: var(--ink); stroke-width: 1; animation: pulse 1.8s ease-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes pulse { from { opacity: .8; transform: scale(1); } to { opacity: 0; transform: scale(2.6); } }
.s-tag { font-family: var(--sans); font-size: 6px; fill: #fff; text-anchor: middle; dominant-baseline: central; }

.reveal__card { width: 100%; max-width: 400px; margin: 18px 0 0; opacity: 0; transform: translateY(16px); transition: all .8s var(--ease); }
.reveal__card.is-in { opacity: 1; transform: none; }
.rc-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.rc { border: 1px solid var(--line); border-radius: 18px; padding: 16px 12px; }
.rc small { display: block; font-size: .64rem; letter-spacing: .24em; text-transform: uppercase; color: var(--muted); }
.rc b { display: block; font-family: var(--serif); font-weight: 400; font-size: 2.4rem; line-height: 1.05; color: var(--ink); }
.rc span { font-size: .85rem; color: var(--sea); font-family: var(--serif); font-style: italic; }
.rc--wide { grid-column: 1 / -1; }
.rc-mates { margin: 14px 0 0; font-size: .9rem; color: var(--muted); }
.rc-mates b { color: var(--ink); font-weight: 400; }
.reveal__actions { display: grid; gap: 10px; width: 100%; max-width: 400px; margin-top: 18px; }

/* ---------- Confeti / toast ---------- */
#confetti { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 60; }
.toast { position: fixed; left: 50%; bottom: calc(96px + var(--safe-b)); z-index: 70; transform: translate(-50%, 20px); opacity: 0; background: var(--ink); color: #fff; padding: 12px 20px; border-radius: 999px; font-size: .88rem; transition: all .4s var(--ease); pointer-events: none; max-width: calc(100% - 40px); text-align: center; }
.toast.is-in { opacity: 1; transform: translate(-50%, 0); }


/* ==========================================================================
   GALERÍA
   ========================================================================== */
.gal__head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; }
.gal__count { font-family: var(--serif); font-style: italic; color: var(--sea); font-size: 1.1rem; margin: 0 0 1.2rem; white-space: nowrap; }
.gal { position: relative; display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; margin: 0 -24px; padding: 4px 24px 8px; scroll-padding: 0 24px; scrollbar-width: none; }
.gal::-webkit-scrollbar { display: none; }
.gal__item { flex: none; width: 78%; margin: 0; scroll-snap-align: start; }
.gal__btn { position: relative; display: block; width: 100%; aspect-ratio: 4 / 5; border-radius: 20px; overflow: hidden; background: linear-gradient(160deg, var(--mist), #fff); border: 1px solid var(--line); }
.gal__btn img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; opacity: 0; transition: transform .9s var(--ease), opacity .6s; }
.gal__item.has-img img { opacity: 1; }
.gal__item.has-img .ph { display: none; }
.gal__item.has-img .gal__btn { border-color: transparent; }
.gal__btn:hover img { transform: scale(1.04); }
.gal__item figcaption { font-family: var(--serif); font-style: italic; color: var(--ink); font-size: 1.08rem; margin: 10px 4px 0; }
.ph { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; color: var(--muted); font-size: .62rem; letter-spacing: .26em; text-transform: uppercase; }
.ph svg { width: 58%; max-width: 190px; height: auto; }

/* Lightbox */
.lb { position: fixed; inset: 0; z-index: 55; display: flex; flex-direction: column; background: rgba(9, 24, 41, .96); color: #fff; opacity: 0; transition: opacity .3s; padding: calc(10px + var(--safe-t)) 0 calc(16px + var(--safe-b)); }
.lb.is-in { opacity: 1; }
.lb__top { display: flex; justify-content: space-between; align-items: center; padding: 0 12px 0 24px; font-family: var(--serif); font-style: italic; font-size: 1.1rem; color: var(--foam); }
.lb__close { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 50%; }
.lb__close svg { width: 24px; height: 24px; stroke: #fff; stroke-width: 1.5; fill: none; }
.lb__stage { flex: 1; min-height: 0; display: flex; align-items: center; justify-content: center; padding: 12px 16px; }
.lb__fig { position: relative; margin: 0; width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; transition: transform .45s var(--ease), opacity .45s; }
.lb__fig.from-r { transform: translateX(40px); opacity: 0; }
.lb__fig.from-l { transform: translateX(-40px); opacity: 0; }
.lb__fig img { max-width: 100%; max-height: 100%; object-fit: contain; border-radius: 10px; }
.lb__fig .ph { position: relative; inset: auto; width: min(100%, 520px); max-height: 100%; aspect-ratio: 4 / 5; border-radius: 22px; border: 1px solid rgba(255,255,255,.14); background: rgba(255,255,255,.05); color: var(--foam); }
.lb__fig.has-img .ph { display: none; }
.lb__bottom { display: grid; grid-template-columns: 52px 1fr 52px; align-items: center; gap: 12px; padding: 0 16px; }
.lb__bottom p { margin: 0; text-align: center; font-family: var(--serif); font-size: 1.25rem; }
.lb__nav { width: 52px; height: 52px; border-radius: 50%; border: 1px solid rgba(255,255,255,.25); color: #fff; font-size: 1.2rem; transition: background .25s; }
.lb__nav:hover { background: rgba(255,255,255,.1); }

/* Fondo de los diálogos (visible en tablet y ordenador) */
.scrim { position: fixed; inset: 0; z-index: 39; background: rgba(15, 42, 71, .35); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); opacity: 0; transition: opacity .35s; }
.scrim.is-in { opacity: 1; }

/* Revelado: en móvil el lateral se "disuelve" y se reordena */
.reveal__side { display: contents; }
#revealKicker { order: 1; }
.reveal__title { order: 2; }
.salon { order: 3; }
.reveal__card { order: 4; }
.reveal__actions { order: 5; }

.block__head { margin-bottom: .4rem; }
.tabbar a { letter-spacing: .08em; }

/* ==========================================================================
   TABLET (≥ 768px)
   ========================================================================== */
@media (min-width: 768px) {
  .envelope { width: min(70vw, 480px); }
  .letter__names { font-size: 2.5rem; }
  .letter__kicker { font-size: .7rem; }
  .letter__date { font-size: .85rem; }
  .seal { width: 84px; height: 84px; margin: -42px 0 0 -42px; font-size: 1.45rem; }

  .hero { padding-top: 110px; }
  .countdown { width: min(100%, 440px); gap: 12px; }
  .cd { padding: 16px 0 10px; }
  .cd__n { font-size: 2.5rem; }

  .hub { grid-template-columns: repeat(3, 1fr); gap: 16px; max-width: var(--wrap); margin: 0 auto; padding: 16px 40px 32px; }
  .hub__card { grid-template-columns: 1fr auto; grid-template-rows: auto auto auto; row-gap: 6px; padding: 28px; min-height: 190px; align-content: start; }
  .hub__num { grid-row: auto; grid-column: 1 / -1; margin-bottom: 14px; }
  .hub__title { font-size: 1.8rem; }
  .hub__text { grid-column: 1; }
  .hub__arrow { grid-row: 2 / 4; grid-column: 2; align-self: end; }

  .block { max-width: var(--wrap); margin: 0 auto; padding: 104px 40px 24px; }
  .title { font-size: clamp(2.8rem, 5vw, 3.8rem); }
  #rsvpStatus { max-width: 760px; }
  .rsvp { padding: 40px 44px; }

  .carta { padding: 52px 48px 44px; }
  .mains { grid-template-columns: repeat(3, 1fr); }
  .main { flex-direction: column; text-align: center; padding: 22px 16px; }

  .place__actions { grid-template-columns: 1fr 1fr; }
  .gal { display: grid; grid-template-columns: repeat(3, 1fr); grid-auto-rows: 220px; grid-auto-flow: dense; gap: 16px; overflow: visible; margin: 0; padding: 0; }
  .gal__item { width: auto; display: flex; flex-direction: column; min-height: 0; }
  .gal__btn { aspect-ratio: auto; flex: 1; min-height: 0; }
  .gal__item:nth-child(6n+1) { grid-row: span 2; }
  .gal__item:nth-child(6n+4) { grid-column: span 2; }
  .gal__count { display: none; }

  /* Formulario y revelado como ventanas centradas */
  .story { width: min(640px, 92vw); height: min(860px, 92vh); margin: auto; border-radius: 28px; box-shadow: 0 40px 100px -30px rgba(15, 42, 71, .55); padding: 22px 0 22px; overflow: hidden; }
  .story__top { padding: 0 22px 0 40px; }
  .slide { padding: 40px 48px 24px; }
  .story__nav { padding: 12px 40px 4px; }
  .sizes { flex-wrap: wrap; overflow: visible; margin: 0; padding: 8px 0 14px; }
  .reveal { width: min(1000px, 94vw); height: min(780px, 92vh); margin: auto; border-radius: 28px; box-shadow: 0 40px 100px -30px rgba(15, 42, 71, .55); }
  .lb__stage { padding: 20px 40px; }
  .lb__bottom { max-width: 760px; width: 100%; margin: 0 auto; }
}

/* ==========================================================================
   ORDENADOR (≥ 1024px)
   ========================================================================== */
@media (min-width: 1024px) {
  .tabbar { top: 20px; bottom: auto; left: 0; right: 0; margin: 0 auto; width: max-content; grid-template-columns: repeat(6, auto); gap: 4px; border-radius: 999px; }
  .tabbar a { flex-direction: row; gap: 8px; padding: 10px 18px; border-radius: 999px; font-size: .68rem; letter-spacing: .14em; }
  .tabbar a:hover:not(.is-active) { color: var(--ink); background: var(--mist); }
  .tabbar svg { width: 18px; height: 18px; }
  .toast { bottom: 32px; }
  .foot { padding-bottom: 72px; }

  .names { flex-direction: row; align-items: baseline; gap: .25em; }
  .names__a, .names__b { font-size: clamp(5.5rem, 9vw, 8.5rem); }
  .names__amp { font-size: clamp(3rem, 5vw, 4.5rem); margin: 0; }
  .hero__date { font-size: 1.6rem; }

  #menu { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.55fr); column-gap: 72px; align-items: start; }
  #menu .block__head { position: sticky; top: 110px; }
  .lugar__grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); column-gap: 72px; align-items: start; }
  .lugar__grid .timeline { margin-top: 8px; }
  .gal { grid-template-columns: repeat(4, 1fr); grid-auto-rows: 240px; }

  .reveal__inner { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 48px; align-items: center; text-align: left; padding: 40px 52px; min-height: 100%; }
  .reveal__side { display: flex; flex-direction: column; align-items: stretch; }
  .salon { max-width: 460px; justify-self: center; }
  .reveal__card, .reveal__actions { max-width: none; }
  .reveal__actions { grid-template-columns: 1fr 1fr; }
}


/* ==========================================================================
   REGALOS
   ========================================================================== */
.gifts__sub { font-family: var(--serif); font-weight: 400; font-size: 1.8rem; color: var(--ink); margin: 2.4rem 0 .2rem; }
.gifts__note { color: var(--muted); font-size: .92rem; margin: 0 0 1.2rem; }
.gifts__loading { display: flex; gap: 8px; justify-content: center; padding: 40px 0; }
.gifts__loading span { width: 8px; height: 8px; border-radius: 50%; background: var(--foam); animation: breathe 1.2s infinite; }
.gifts__loading span:nth-child(2) { animation-delay: .2s; } .gifts__loading span:nth-child(3) { animation-delay: .4s; }
.gifts__error { text-align: center; padding: 30px 0; color: var(--muted); }

.fondos { display: grid; gap: 14px; }
.fondo { display: flex; flex-direction: column; text-align: left; border: 1px solid var(--line); border-radius: 24px; overflow: hidden; background: #fff; transition: transform .35s var(--ease), box-shadow .35s, border-color .35s; }
.fondo:hover { transform: translateY(-3px); border-color: var(--foam); box-shadow: 0 22px 40px -28px rgba(15, 42, 71, .55); }
.fondo:active { transform: scale(.98); }
.fondo__art { position: relative; height: 150px; display: grid; place-items: center; overflow: hidden; background: radial-gradient(120% 90% at 30% 10%, #fff 0%, #E6EEF6 60%, #D6E3EF 100%); }
.fondo:nth-child(3n+2) .fondo__art { background: radial-gradient(120% 90% at 70% 10%, #fff 0%, #F3ECE2 60%, #E8DCCB 100%); }
.fondo:nth-child(3n+3) .fondo__art { background: radial-gradient(120% 90% at 50% 0%, #fff 0%, #E9EEF3 55%, #DCE4EC 100%); }
.fondo__art::before, .fondo__art::after { content: ""; position: absolute; border-radius: 50%; border: 1px solid rgba(15, 42, 71, .08); }
.fondo__art::before { width: 220px; height: 220px; }
.fondo__art::after { width: 140px; height: 140px; }
.fondo__art svg { position: relative; width: 84px; height: 84px; fill: none; stroke: var(--ink); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; transition: transform .6s var(--ease); }
.fondo:hover .fondo__art svg { transform: scale(1.06) rotate(-2deg); }
.fondo__art img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.fondo__body { display: flex; flex-direction: column; gap: 6px; padding: 20px 22px 22px; flex: 1; }
.fondo__title { font-family: var(--serif); font-size: 1.5rem; color: var(--ink); line-height: 1.15; }
.fondo__desc { font-size: .9rem; color: var(--muted); }
.bar { display: block; height: 4px; border-radius: 4px; background: var(--mist); overflow: hidden; margin-top: 10px; }
.bar span { display: block; height: 100%; width: 0; background: linear-gradient(90deg, var(--sea), var(--ink)); border-radius: inherit; transition: width 1.6s var(--ease); }
.bar span.go { width: var(--p); }
.fondo__meta { font-size: .78rem; color: var(--muted); }
.fondo__meta b { color: var(--ink); font-weight: 500; }
.fondo__cta { margin-top: auto; padding-top: 12px; font-size: .72rem; letter-spacing: .22em; text-transform: uppercase; color: var(--sea); }
.fondo__cta i { font-style: normal; display: inline-block; transition: transform .3s var(--ease); }
.fondo:hover .fondo__cta i { transform: translateX(4px); }

.compras { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; }
.compra { position: relative; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 4px; padding: 22px 12px 16px; border: 1px solid var(--line); border-radius: 20px; background: #fff; transition: transform .3s var(--ease), border-color .3s, opacity .3s, box-shadow .3s; }
.compra:hover { border-color: var(--foam); box-shadow: 0 16px 30px -24px rgba(15, 42, 71, .5); }
.compra:active { transform: scale(.97); }
.compra__art { width: 64px; height: 64px; display: grid; place-items: center; border-radius: 50%; background: var(--mist); margin-bottom: 8px; overflow: hidden; }
.compra__art svg { width: 40px; height: 40px; fill: none; stroke: var(--ink); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.compra__art img { width: 100%; height: 100%; object-fit: cover; }
.compra__title { font-family: var(--serif); font-size: 1.15rem; color: var(--ink); line-height: 1.2; }
.compra__price { font-size: .8rem; color: var(--muted); }
.pill { margin-top: 8px; padding: 4px 10px; border-radius: 999px; background: var(--mist); color: var(--blue); font-size: .62rem; letter-spacing: .14em; text-transform: uppercase; }
.compra.is-taken { opacity: .6; }
.compra.is-taken .pill { background: #F3ECE2; color: #7C6440; }
.compra.is-mine { border-color: var(--ink); }
.compra.is-mine .pill { background: var(--ink); color: #fff; }

/* Diálogo de regalo: hoja inferior en móvil */
.gift { position: fixed; left: 0; right: 0; bottom: 0; z-index: 46; max-height: 94vh; overflow-y: auto; -webkit-overflow-scrolling: touch; background: #fff; border-radius: 28px 28px 0 0; box-shadow: 0 -20px 60px -20px rgba(15, 42, 71, .4); animation: sheetUp .5s var(--ease); padding-bottom: var(--safe-b); }
.gift.is-closing { animation: sheetDown .33s var(--ease) forwards; }
@keyframes sheetUp { from { transform: translateY(100%); } to { transform: none; } }
@keyframes sheetDown { to { transform: translateY(100%); } }
.gift::before { content: ""; display: block; width: 40px; height: 4px; border-radius: 4px; background: var(--line); margin: 10px auto 0; }
.gift__close { position: absolute; top: 12px; right: 12px; z-index: 2; width: 42px; height: 42px; border-radius: 50%; display: grid; place-items: center; background: rgba(255,255,255,.9); }
.gift__close svg { width: 22px; height: 22px; stroke: var(--ink); stroke-width: 1.5; fill: none; }
.gh { text-align: center; padding: 22px 26px 4px; }
.gh__art { width: 104px; height: 104px; margin: 0 auto 16px; border-radius: 50%; display: grid; place-items: center; overflow: hidden; background: radial-gradient(circle at 30% 25%, #fff, var(--mist) 70%); box-shadow: 0 0 0 10px rgba(238, 243, 248, .6); animation: popIn .6s var(--ease); }
.gh__art svg { width: 60px; height: 60px; fill: none; stroke: var(--ink); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.gh__art img { width: 100%; height: 100%; object-fit: cover; }
.gh__title { font-family: var(--serif); font-weight: 400; font-size: clamp(1.9rem, 7vw, 2.3rem); line-height: 1.1; color: var(--ink); margin: 0 0 .5rem; }
.gh__desc { color: var(--muted); margin: 0 auto; max-width: 420px; font-size: .95rem; }
.gform { padding: 6px 26px 28px; }
.gform .q-label { margin-top: 1.3rem; }
.opt { text-transform: none; letter-spacing: 0; }
.otra { margin-top: 10px; }
.btn--block { width: 100%; margin-top: 18px; }
.gform__hint { font-size: .8rem; color: var(--muted); text-align: center; margin: 10px 0 0; }
.gmeta { display: flex; justify-content: space-between; align-items: center; gap: 12px; flex-wrap: wrap; padding: 14px 0; margin-top: 12px; border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); font-size: .88rem; color: var(--muted); }
.gmeta b { font-family: var(--serif); font-weight: 500; font-size: 1.15rem; color: var(--ink); margin-left: 6px; }
.gmeta a { color: var(--sea); font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; }
.state { display: flex; gap: 14px; align-items: center; padding: 16px 18px; border-radius: 18px; background: var(--mist); margin-top: 18px; animation: fadeUp .5s var(--ease); }
.state svg { width: 30px; height: 30px; flex: none; fill: none; stroke: var(--sea); stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.state b { display: block; font-family: var(--serif); font-weight: 500; font-size: 1.25rem; color: var(--ink); }
.state span { font-size: .85rem; color: var(--muted); }
.state--mine { background: var(--ink); }
.state--mine b, .state--mine span { color: #fff; }
.state--mine svg { stroke: #fff; }

.thanks { text-align: center; padding: 26px 26px 6px; }
.thanks__heart { width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 50%; display: grid; place-items: center; background: var(--mist); animation: popIn .6s var(--ease); }
.thanks__heart svg { width: 30px; height: 30px; fill: var(--sea); animation: beat 1.4s .6s ease-in-out infinite; }
@keyframes beat { 0%, 100% { transform: scale(1); } 15% { transform: scale(1.18); } 30% { transform: scale(1); } 45% { transform: scale(1.1); } }
.ticket { position: relative; margin: 18px 20px 4px; border-radius: 22px; background: linear-gradient(160deg, #163A60, var(--ink) 60%); color: #fff; overflow: hidden; box-shadow: 0 24px 40px -24px rgba(15, 42, 71, .8); animation: fadeUp .7s .15s var(--ease) both; }
.ticket::before { content: ""; position: absolute; right: -50px; top: -50px; width: 180px; height: 180px; border-radius: 50%; border: 1px solid rgba(255,255,255,.08); box-shadow: 0 0 0 26px rgba(255,255,255,.03); }
.ticket__top { display: flex; justify-content: space-between; align-items: center; padding: 20px 22px 6px; }
.ticket__brand span { display: block; font-family: var(--serif); font-style: italic; font-size: 1.7rem; line-height: 1; }
.ticket__brand small { font-size: .6rem; letter-spacing: .3em; text-transform: uppercase; color: var(--foam); }
.ticket__icon svg { width: 46px; height: 46px; fill: none; stroke: var(--foam); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }
.ticket__grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px 16px; padding: 12px 22px 20px; }
.ticket small { display: block; font-size: .58rem; letter-spacing: .26em; text-transform: uppercase; color: var(--foam); margin-bottom: 2px; }
.ticket__grid b { font-family: var(--serif); font-weight: 400; font-size: 1.2rem; line-height: 1.25; word-break: break-word; }
.ticket__wide { grid-column: 1 / -1; }
.ticket__cut { position: relative; margin: 0 20px; border-top: 2px dashed rgba(255,255,255,.25); }
.ticket__cut::before, .ticket__cut::after { content: ""; position: absolute; top: -12px; width: 22px; height: 22px; border-radius: 50%; background: #fff; }
.ticket__cut::before { left: -32px; } .ticket__cut::after { right: -32px; }
.ticket__iban { padding: 18px 22px 22px; }
.ticket__iban > b { display: block; font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace; font-weight: 500; font-size: clamp(.8rem, 3.9vw, 1.05rem); letter-spacing: .02em; word-break: break-word; }
.ticket__btns { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 16px; }
.ticket__btns .btn { min-height: 46px; padding: 0 10px; font-size: .68rem; letter-spacing: .12em; }
.ticket .btn--primary { background: #fff; color: var(--ink); box-shadow: none; }
.ticket .btn--ghost { background: transparent; color: #fff; border-color: rgba(255,255,255,.3); }
.ticket__bizum { margin: 14px 0 0; font-size: .85rem; color: var(--foam); }
.ticket__bizum b { color: #fff; font-weight: 500; }
#gDone { margin: 10px 0 18px; }

@media (max-width: 420px) {
  .tabbar { padding: 5px; }
  .tabbar a { font-size: .52rem; letter-spacing: .02em; padding: 7px 0 5px; }
  .tabbar svg { width: 20px; height: 20px; }
}
@media (min-width: 768px) {
  .hub { grid-template-columns: repeat(2, 1fr); }
  .fondos { grid-template-columns: repeat(3, 1fr); gap: 18px; }
  .fondo__art { height: 170px; }
  .compras { grid-template-columns: repeat(3, 1fr); gap: 16px; }
  .gift { top: 0; bottom: 0; margin: auto; left: 0; right: 0; width: min(560px, 92vw); height: fit-content; max-height: 92vh; border-radius: 28px; animation: storyIn .45s var(--ease); box-shadow: 0 40px 100px -30px rgba(15, 42, 71, .55); }
  .gift.is-closing { animation: storyOut .33s var(--ease) forwards; }
  .gift::before { display: none; }
  .gh { padding-top: 40px; }
}
@media (min-width: 1024px) {
  .hub { grid-template-columns: repeat(4, 1fr); }
  .compras { grid-template-columns: repeat(4, 1fr); }
  .tabbar a { padding: 10px 14px; }
}

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