/* Feli y Andy — styles from the illustrated design ("web.pdf", December 2026).
   The page is one fluid layout. Sizes use container query units (cqi) on .page. */

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

html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body { margin: 0; background: #fff; }

a { color: #111; }
a:hover { color: #444; }

.page {
  container-type: inline-size;
  background: #fff;
  color: #111;
  font-family: 'Baskervville', 'Baskerville', 'Libre Baskerville', Georgia, serif;
  font-weight: 700;
  font-variant-numeric: lining-nums;
  line-height: 1.25;
  text-align: center;
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}

.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* ---------- Header / nav ---------- */
.site-header {
  max-width: 1200px; margin: 0 auto;
  padding: clamp(24px, 3.6cqi, 48px) clamp(24px, 5cqi, 64px) 0;
}
.nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px clamp(20px, 3.4cqi, 52px); }
.nav-link {
  display: inline-flex; align-items: flex-end; min-height: 44px;
  padding: 0 clamp(10px, 1.4cqi, 20px) 4px;
  border-bottom: 2px solid #111;
  font-style: italic; font-size: clamp(18px, 2cqi, 28px); text-decoration: none;
}

main {
  position: relative;
  max-width: 1200px; margin: 0 auto;
  padding: clamp(40px, 5cqi, 72px) clamp(24px, 5cqi, 64px) 0;
  display: flex; flex-direction: column; gap: clamp(50px, 6.4cqi, 88px);
}
section[id] { scroll-margin-top: 24px; }

/* A small hand-drawn separator between sections: two wavy ink strokes and a heart.
   It sits in main's flex column, so the space between two sections is two gaps plus the separator. */
.sep {
  align-self: center; flex: none;
  width: clamp(120px, 14cqi, 190px); aspect-ratio: 200 / 24;
  background: no-repeat center / contain url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 24'%3E%3Cg fill='none' stroke='%23111' stroke-width='1.8' stroke-linecap='round'%3E%3Cpath d='M6 12C18 6 28 17 42 12S68 6 84 13'/%3E%3Cpath d='M116 13C132 6 146 18 158 12S184 7 194 12'/%3E%3C/g%3E%3Cpath fill='%23111' d='M100 19C96.5 15.5 91 12 91 7.8 91 4.5 95 3.3 98 5.8L100 7.6 102 5.8C105 3.3 109 4.5 109 7.8 109 12 103.5 15.5 100 19Z'/%3E%3C/svg%3E");
  pointer-events: none;
}

/* ---------- Shared bits ---------- */
.hand {
  margin: 0;
  font-family: 'Chalkduster', 'Short Stack', 'Comic Sans MS', cursive; font-weight: 400;
  font-size: clamp(15px, 1.45cqi, 19px); line-height: 1.3;
}
.rule { width: clamp(84px, 9cqi, 128px); height: 2px; background: #111; border-radius: 2px; }

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: clamp(54px, 4.6cqi, 66px); padding: 0 28px;
  border: 0; border-radius: 18px; background-color: #111; color: #fff;
  font-family: inherit; font-weight: 700; font-size: clamp(19px, 1.8cqi, 24px);
  text-decoration: none; cursor: pointer;
  transition: background-color .15s ease, color .15s ease, transform .15s ease;
}
.btn:hover { background-color: #333; color: #fff; }
.btn:active { transform: translateY(1px); }
.btn:focus-visible, .nav-link:focus-visible {
  outline: 2px solid #111; outline-offset: 4px;
}
.btn[disabled] { opacity: .55; cursor: progress; }
.btn-wide { min-width: clamp(200px, 22cqi, 300px); padding: 0 36px; font-size: clamp(19px, 1.9cqi, 26px); }
.btn-outline { background: #fff; color: #111; box-shadow: inset 0 0 0 2px #111; }
.btn-outline:hover { background: #111; color: #fff; }

h2 { margin: 0; font-size: clamp(24px, 2.7cqi, 36px); font-weight: 700; text-wrap: balance; }
.mark { margin: 0; font-size: clamp(24px, 2.5cqi, 34px); line-height: 1; }
.subrayado { text-decoration: underline; text-decoration-thickness: 1.5px; text-underline-offset: .35em; }

.stack { display: flex; flex-direction: column; align-items: center; }

/* ---------- Hero ---------- */
.hero { display: flex; justify-content: center; }
.hero h1 { margin: 0; line-height: 0; }
.hero-art { position: relative; display: block; width: clamp(240px, 34cqi, 480px); aspect-ratio: 1306 / 1440; }
.hero-art img, .art img { position: absolute; }
.hero-art svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }

/* ---------- Illustrations: layers cut from the design, animated one by one ---------- */
.capa { position: absolute; inset: 0; }
.art-boda { width: min(88%, clamp(280px, 60cqi, 720px)); aspect-ratio: 1170 / 995; }
/* The couple's joined hands sit at about 61% of the drawing's width; this puts them over the centre of the text below.
   The 88% cap keeps the grass on the left inside the page on phones after the shift. */
.art-boda { translate: -11% 0; }
.art-regalo { width: min(100%, clamp(280px, 56cqi, 680px)); aspect-ratio: 1079 / 914; }
.art-moto { width: min(100%, clamp(280px, 64cqi, 780px)); aspect-ratio: 1450 / 1000; }
.art-auto { width: min(100%, clamp(280px, 62cqi, 740px)); aspect-ratio: 1005 / 775; }

/* ---------- Intro ---------- */
.intro { gap: clamp(14px, 1.6cqi, 22px); max-width: 60em; margin: 0 auto; }
.intro h2 { font-size: clamp(28px, 3.4cqi, 44px); margin-bottom: 4px; }
.intro p { text-wrap: balance; }
@container (max-width: 760px) { .br-ancho { display: none; } }

/* ---------- Fecha / lugar ---------- */
.sec-fecha { gap: clamp(20px, 2.6cqi, 34px); }
.botonera { display: flex; flex-wrap: wrap; justify-content: center; gap: 24px clamp(32px, 6cqi, 96px); margin-top: 6px; }
.boton-con-nota { gap: 12px; }

/* Hearts on a vine at the page edges. app.js draws them and moves the hearts as you scroll. */
.intro, .sec-fecha, .dress, .sec-regalo, .sec-sorteo, .sec-gracias { position: relative; }
.enredadera {
  position: absolute; top: 0; z-index: 0; pointer-events: none;
  width: clamp(26px, 3.8cqi, 64px); aspect-ratio: 80 / 720;
}
.enredadera.izq { left: calc(50% - 50cqi + clamp(4px, 4cqi, 110px)); }
.enredadera.der { right: calc(50% - 50cqi + clamp(4px, 4cqi, 110px)); }
.enredadera.baja { top: auto; bottom: 0; }
.dress .enredadera { top: 40%; }
.enredadera svg { display: block; width: 100%; height: 100%; overflow: visible; }
.enredadera path { fill: none; stroke: #111; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; }
.enredadera .tallo { stroke-width: 2; }
.intro > :not(.enredadera), .sec-fecha > :not(.enredadera), .dress > :not(.enredadera),
.sec-regalo > :not(.enredadera), .sec-sorteo > :not(.enredadera), .sec-gracias > :not(.enredadera) { position: relative; z-index: 1; }
@container (max-width: 700px) {
  main { padding-left: 30px; padding-right: 30px; }
  .enredadera { width: 20px; }
  .enredadera.izq { left: calc(50% - 50cqi + 2px); }
  .enredadera.der { right: calc(50% - 50cqi + 2px); }
}

/* ---------- Horarios ---------- */
.horarios {
  position: relative; width: 100%;
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(40px, 4cqi, 48px) clamp(16px, 3cqi, 40px); align-items: end;
}
@container (min-width: 880px) { .horarios { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
/* The hand-drawn thread that joins the four times (wide layout only) */
.hilo { display: none; position: absolute; left: 0; width: 100%; font-size: clamp(21px, 2.2cqi, 31px); bottom: -1.45em; height: 3.95em; overflow: visible; pointer-events: none; }
.hilo path { fill: none; stroke: #111; stroke-width: 1.6; stroke-linecap: round; vector-effect: non-scaling-stroke; }
@container (min-width: 880px) { .hilo { display: block; } }
.hora { gap: clamp(16px, 2.4cqi, 32px); }
.hora-txt { gap: 2px; }
.hora-txt h3, .hora-txt p { margin: 0; font-size: clamp(21px, 2.2cqi, 31px); font-weight: 700; }
.art { position: relative; }
.art svg { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.art-copas { width: min(100%, calc(clamp(120px, 15cqi, 200px) * 1.151)); aspect-ratio: 791 / 687; }
.art-ceremonia { width: min(100%, calc(clamp(120px, 15cqi, 200px) * 1.032)); aspect-ratio: 419 / 406; }
.art-cena { width: min(100%, calc(clamp(120px, 15cqi, 200px) * 1.349)); aspect-ratio: 533 / 395; }
.art-fiesta { width: min(100%, calc(clamp(120px, 15cqi, 200px) * 0.873)); aspect-ratio: 425 / 487; }

/* ---------- Dress code ---------- */
.dress { gap: 6px; }
.dress h2 { margin: 0; font-size: clamp(22px, 2.3cqi, 32px); font-weight: 700; }

/* ---------- Regalo / cuentas ---------- */
.sec-regalo, .sec-confirmar, .sec-sorteo, .sec-gracias { gap: clamp(28px, 3.6cqi, 52px); }
.sec-regalo .titulo, .sec-sorteo .titulo { gap: 8px; margin-top: calc(-1 * clamp(8px, 1.6cqi, 24px)); }
.cuentas {
  width: 100%; max-width: 920px; display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(280px, 100%), 1fr));
  gap: clamp(40px, 4cqi, 56px) 32px;
}
.cuenta { gap: 4px; }
.cuenta .btn { margin-bottom: 14px; }
.cuenta .hand.status { order: 5; }
.cuenta[data-cuenta="moto"] .hand.status { order: 0; margin: -6px 0 8px; }
.cuenta p.dato { margin: 0; font-size: clamp(20px, 2cqi, 28px); overflow-wrap: anywhere; }
.cuenta .hand.status { margin-top: 4px; }
.cuenta .nota { margin-top: 8px; max-width: 20em; line-height: 1.15; text-wrap: balance; }

/* ---------- Forms ---------- */
.titulo { gap: 10px; }

.confirmar-row {
  width: 100%; display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: clamp(32px, 5cqi, 72px);
}
.form {
  flex: 1 1 520px; min-width: 0; max-width: 640px;
  display: flex; flex-direction: column; gap: 18px; text-align: left;
}
.field { display: grid; grid-template-columns: minmax(0, 15rem) minmax(0, 1fr); gap: 8px 20px; align-items: center; }
.field > label, .field > .label { text-align: right; font-style: italic; font-size: clamp(18px, 1.6cqi, 22px); line-height: 1.2; text-wrap: balance; }
.field-top { align-items: start; }
.field-top > label { padding-top: 14px; }
.input {
  width: 100%; height: 58px; padding: 0 20px;
  border: 1px solid #111; border-radius: 18px; background: #fff; color: #111;
  font-family: inherit; font-weight: 600; font-size: 18px;
  transition: box-shadow .15s ease;
}
textarea.input { display: block; height: auto; min-height: 128px; padding: 16px 20px; line-height: 1.35; resize: vertical; }
.input:focus { outline: none; box-shadow: 0 0 0 2px #111; }
.submit-col { display: flex; flex-direction: column; align-items: center; gap: 12px; padding-top: 6px; text-align: center; }
.status:empty { display: none; }
.status.error { color: #a10000; }

@container (max-width: 640px) {
  .field { grid-template-columns: minmax(0, 1fr); }
  .field > label, .field > .label { text-align: left; }
  .field-top > label { padding-top: 0; }
  .field-spacer { display: none; }
}

.art-brindis { flex: 0 1 420px; width: min(420px, 80%); aspect-ratio: 785 / 790; }

[hidden] { display: none !important; }

/* ---------- Gracias ---------- */
.sec-gracias h2 { margin-top: calc(-1 * clamp(4px, 1cqi, 16px)); }
.corazones { display: flex; gap: clamp(6px, .9cqi, 12px); margin-top: -4px; }
.corazones svg { width: clamp(20px, 2.1cqi, 28px); height: auto; fill: #111; overflow: visible; will-change: transform; }

/* ---------- Footer ---------- */
footer { padding: clamp(72px, 10cqi, 144px) 24px; }
footer p {
  display: inline-block; margin: 0; transform: rotate(-4deg);
  font-family: 'Chalkduster', 'Short Stack', 'Comic Sans MS', cursive; font-weight: 400;
  font-size: clamp(24px, 3.1cqi, 42px); line-height: 1.6;
}

/* ---------- Animations (from the design) ---------- */
@keyframes k-novia{0%,100%{transform:rotate(-4deg)}25%{transform:rotate(-1deg) translateY(-2.2%)}50%{transform:rotate(2deg)}75%{transform:rotate(-1deg) translateY(-2.2%)}}
@keyframes k-novio{0%,100%{transform:rotate(-3deg) translateY(-2%)}25%{transform:rotate(-.5deg)}50%{transform:rotate(2.5deg) translateY(-2%)}75%{transform:rotate(-.5deg)}}
@keyframes k-pendulo{0%,100%{transform:rotate(-2deg)}50%{transform:rotate(2deg)}}
@keyframes k-rayo{0%,100%{opacity:.12}50%{opacity:1}}
@keyframes k-destello{0%,100%{opacity:0;transform:scale(.2) rotate(-20deg)}50%{opacity:1;transform:scale(1) rotate(15deg)}}
@keyframes k-copa-izq{0%,85%,100%{transform:rotate(-5deg)}30%,55%{transform:rotate(0deg)}}
@keyframes k-copa-der{0%,85%,100%{transform:rotate(5deg)}30%,55%{transform:rotate(0deg)}}
@keyframes k-chin{0%,27%{opacity:0;transform:scale(.4)}34%{opacity:1;transform:scale(1.2)}42%,58%{opacity:1;transform:scale(1)}72%,100%{opacity:0;transform:scale(1)}}
@keyframes k-ramo{0%,100%{transform:rotate(-2.5deg)}50%{transform:rotate(2.5deg)}}
@keyframes k-anillos{0%,100%{transform:rotate(-1.5deg)}50%{transform:rotate(1.5deg)}}
@keyframes k-llama{0%{transform:scale(1,1) skewX(0deg)}30%{transform:scale(.82,1.3) skewX(-10deg)}60%{transform:scale(1.15,.85) skewX(8deg)}100%{transform:scale(.9,1.2) skewX(-5deg)}}
@keyframes k-humo{0%{opacity:0;transform:translateY(40%)}35%{opacity:1}100%{opacity:0;transform:translateY(-70%) scaleX(1.3)}}
@keyframes k-dj{0%{transform:translateY(0) rotate(-.8deg)}100%{transform:translateY(-1.6%) rotate(.8deg)}}
.a-novia{transform-origin:50% 100%;animation:k-novia 1.5s ease-in-out infinite}
.a-novio{transform-origin:50% 100%;animation:k-novio 1.5s ease-in-out infinite}
.a-bola{animation:k-pendulo 3.2s ease-in-out infinite}
.a-rayo{animation:k-rayo 1.1s ease-in-out infinite}
.a-rayo-b{animation:k-rayo 1.1s ease-in-out -.55s infinite}
.a-destello{transform-box:fill-box;transform-origin:center;animation:k-destello 2.4s ease-in-out infinite}
.a-copa-izq{animation:k-copa-izq 2.6s ease-in-out infinite}
.a-copa-der{animation:k-copa-der 2.6s ease-in-out infinite}
.a-chin{transform-origin:50% 100%;animation:k-chin 2.6s ease-out infinite}
.a-ramo{animation:k-ramo 4s ease-in-out infinite}
.a-anillos{transform-origin:50% 100%;animation:k-anillos 4s ease-in-out -2s infinite}
.a-llama{transform-origin:50% 100%;animation:k-llama .8s ease-in-out infinite alternate}
.a-humo{animation:k-humo 2.6s linear infinite}
.a-dj{transform-origin:50% 100%;animation:k-dj .55s ease-in-out infinite alternate}
.a-ritmo{animation:k-rayo 1.1s ease-in-out infinite}
/* New illustrations */
@keyframes k-saludo{0%{transform:rotate(-10deg)}100%{transform:rotate(12deg)}}
@keyframes k-puno{0%,100%{transform:rotate(5deg)}50%{transform:rotate(-7deg)}}
@keyframes k-flores{0%,100%{transform:scale(1) rotate(-1deg)}50%{transform:scale(1.06) rotate(1.5deg)}}
@keyframes k-petalo{0%{opacity:0;transform:translate(var(--x),40px) rotate(0deg)}10%{opacity:1}50%{transform:translate(calc(var(--x) + 30px),500px) rotate(200deg)}90%{opacity:1}100%{opacity:0;transform:translate(calc(var(--x) - 10px),960px) rotate(400deg)}}
@keyframes k-manteo{0%,100%{transform:translateY(4%) rotate(1.5deg)}45%{transform:translateY(-7%) rotate(-2deg)}55%{transform:translateY(-7%) rotate(-2deg)}}
@keyframes k-manos{0%,100%{transform:translateY(0) rotate(0deg)}40%{transform:translateY(-5%) rotate(-2deg)}}
@keyframes k-brinda-izq{0%,85%,100%{transform:rotate(-1.2deg)}30%,55%{transform:rotate(0deg)}}
@keyframes k-brinda-der{0%,85%,100%{transform:rotate(1.2deg)}30%,55%{transform:rotate(0deg)}}
@keyframes k-fuego{0%{opacity:0;transform:scale(.25)}18%{opacity:1;transform:scale(1)}60%{opacity:1;transform:scale(1.06)}85%,100%{opacity:0;transform:scale(1.14)}}
@keyframes k-motor{0%{transform:translate(0,0) rotate(0deg)}50%{transform:translate(.12%,-.35%) rotate(-.25deg)}100%{transform:translate(-.1%,0) rotate(.1deg)}}
@keyframes k-puff{0%{opacity:0;transform:translate(0,0) scale(.4)}20%{opacity:1}100%{opacity:0;transform:translate(-120px,-50px) scale(1.6)}}
@keyframes k-andar{0%{transform:translateY(0) rotate(0deg)}100%{transform:translateY(-1.3%) rotate(-.6deg)}}
@keyframes k-latas{0%{transform:rotate(-3deg)}100%{transform:rotate(4deg) translateY(1.5%)}}
@keyframes k-ruta{0%,100%{opacity:1}50%{opacity:.45}}
@keyframes k-papelitos{0%,100%{opacity:1;transform:scale(1)}50%{opacity:.55;transform:scale(1.02)}}
.a-flores{animation:k-flores 3s ease-in-out infinite}
.a-flores-der{animation-delay:-1.4s;animation-duration:3.6s}
.a-ramo-alto{animation:k-saludo .9s ease-in-out infinite alternate}
.a-puno{animation:k-puno 1.1s ease-in-out infinite}
.a-petalo{transform-box:view-box;animation:k-petalo var(--t,6s) linear var(--d,0s) infinite;opacity:0}
.a-manteo{animation:k-manteo 1.8s ease-in-out infinite}
.a-manos-izq{transform-origin:50% 100%;animation:k-manos 1.8s ease-in-out infinite}
.a-manos-der{transform-origin:50% 100%;animation:k-manos 1.8s ease-in-out -.15s infinite}
.a-brinda-novia{animation:k-brinda-izq 2.6s ease-in-out infinite}
.a-brinda-novio{animation:k-brinda-der 2.6s ease-in-out infinite}
.a-fuego{animation:k-fuego 2.6s ease-out infinite}
.a-motor{animation:k-motor .24s ease-in-out infinite alternate}
.a-puff{transform-box:fill-box;transform-origin:center;animation:k-puff 2.1s ease-out infinite;opacity:0}
.a-andar{animation:k-andar .42s ease-in-out infinite alternate}
.a-latas{animation:k-latas .32s ease-in-out infinite alternate}
.a-papelitos{animation:k-papelitos 1.8s ease-in-out infinite}
.a-ruta{animation:k-ruta .9s steps(2,jump-none) infinite}
.a-saludo{animation:k-saludo .55s ease-in-out infinite alternate}
.a-ramo-auto{animation:k-saludo .7s ease-in-out -.3s infinite alternate}
@media (prefers-reduced-motion: reduce) { [class^="a-"], [class*=" a-"] { animation: none !important; } }

.cuenta-datos { gap: 4px; }
