body[data-page="invite"] {
  background: #17151b;
}

.invite-experience {
  min-height: 100vh;
}
.unpublished-invite { align-items: center; background: #fffaf7; display: flex; flex-direction: column; justify-content: center; min-height: 100vh; padding: 28px; text-align: center; }
.unpublished-invite h1 { font-family: Georgia, serif; font-size: clamp(2rem, 5vw, 3.5rem); max-width: 680px; }
.unpublished-invite > p:last-child { color: var(--muted); }

.envelope-screen {
  align-items: center;
  background-image: var(--opening-image);
  background-position: center;
  background-size: cover;
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 100vh;
  padding: 32px 20px;
  text-align: center;
  perspective: 1200px;
  position: relative;
}

.envelope-screen::before { background: var(--opening-tint, #211820); content: ""; inset: 0; opacity: .68; position: absolute; }
.envelope-screen > * { position: relative; z-index: 1; }

.envelope-screen[hidden],
.invitation-page[hidden] {
  display: none !important;
}

.envelope-title {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.4rem, 4vw, 2.3rem);
  font-weight: 500;
  margin-bottom: 24px;
}

.envelope {
  aspect-ratio: 3 / 2;
  background-color: #d7a5aa;
  background-image: url("assets/envelope-closed-crop.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  border: 1px solid rgba(255, 255, 255, 0.45);
  box-shadow: 0 28px 80px rgba(0, 0, 0, 0.42);
  cursor: pointer;
  height: auto;
  max-width: 620px;
  overflow: hidden;
  position: relative;
  width: min(90vw, 620px);
  transition: transform 0.35s ease;
}

.envelope:hover {
  transform: translateY(-5px);
}

.envelope-marfil { filter: sepia(.18) saturate(.55) brightness(1.16); }
.envelope-noche { filter: grayscale(.7) hue-rotate(170deg) brightness(.72) contrast(1.12); }
.envelope-champagne { filter: sepia(.48) saturate(.75) brightness(1.08) hue-rotate(350deg); }
.envelope-azul { filter: hue-rotate(145deg) saturate(.85) brightness(.72); }
.envelope-esmeralda { filter: hue-rotate(75deg) saturate(.82) brightness(.7); }
.envelope-vino { filter: hue-rotate(320deg) saturate(1.15) brightness(.68); }
.opening-ninguna .envelope { transition: none; }
.opening-ninguna.opening .envelope,
.opening-ninguna.opening .envelope::before,
.opening-ninguna.opening .envelope-copy { animation-duration: .01ms !important; animation-delay: 0ms !important; }
.opening-suave.opening .envelope::before { animation-duration: .3s; }

.envelope::before,
.envelope::after {
  content: "";
  position: absolute;
}

.envelope::before {
  background-color: #d7a5aa;
  background-image: url("assets/envelope-open-crop.png");
  background-position: center;
  background-repeat: no-repeat;
  background-size: cover;
  clip-path: polygon(50% 0, 100% 32%, 100% 100%, 0 100%, 0 32%);
  inset: 0;
  opacity: 0;
  z-index: 1;
}

.envelope::after {
  display: none;
}

.envelope-copy {
  color: var(--envelope-text-color, #32252a);
  left: 50%;
  position: absolute;
  top: 36%;
  transform: translate(-50%, -50%);
  width: 80%;
  z-index: 3;
}

.envelope-copy strong {
  color: inherit;
  display: block;
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.5rem, 5vw, 3rem);
  font-weight: 500;
}

.envelope-copy span {
  color: inherit;
  display: block;
  margin-top: 12px;
}

.wax-seal {
  align-items: center;
  background: #a94b62;
  border: 5px double #d98aa0;
  border-radius: 50%;
  bottom: 25%;
  box-shadow: 0 8px 18px rgba(66, 22, 34, 0.34);
  color: #fff4f6;
  display: none;
  font-family: Georgia, serif;
  font-size: 1.4rem;
  height: 72px;
  justify-content: center;
  left: 50%;
  position: absolute;
  transform: translateX(-50%);
  width: 72px;
  z-index: 4;
}

.envelope-meta {
  display: flex;
  font-family: Georgia, "Times New Roman", serif;
  font-size: 1.15rem;
  justify-content: space-between;
  margin-top: 20px;
  max-width: 620px;
  width: min(90vw, 620px);
}

.open-hint {
  color: rgba(255, 255, 255, 0.72);
  margin-top: 18px;
}

.envelope-screen.opening .envelope {
  animation: envelope-leave 0.55s ease 0.85s forwards;
  pointer-events: none;
}

.envelope-screen.opening .envelope::before {
  animation: envelope-open-state 0.65s ease forwards;
}

.envelope-screen.opening .envelope-copy {
  animation: letter-rise 0.75s ease 0.35s forwards;
}

.envelope-screen.opening .envelope-title,
.envelope-screen.opening .envelope-meta,
.envelope-screen.opening .open-hint {
  animation: surrounding-fade 0.35s ease 0.75s forwards;
}

@keyframes envelope-open-state {
  from { opacity: 0; transform: scale(0.985); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes letter-rise {
  0% { opacity: 1; transform: translate(-50%, -50%); }
  100% { opacity: 0; transform: translate(-50%, -125%); }
}

@keyframes envelope-leave {
  0% { opacity: 1; transform: translateY(0) scale(1); }
  100% { opacity: 0; transform: translateY(38px) scale(0.92); }
}

@keyframes surrounding-fade {
  to { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .envelope-screen.opening * ,
  .envelope-screen.opening .envelope::before {
    animation-duration: 0.01ms !important;
    animation-delay: 0ms !important;
  }
}

.invitation-page {
  background: #fffaf7;
  color: var(--ink);
}

.font-clasica { font-family: Georgia, "Times New Roman", serif; }
.font-moderna { font-family: Inter, ui-sans-serif, system-ui, sans-serif; }
.font-juvenil { font-family: "Trebuchet MS", ui-sans-serif, sans-serif; }
.font-editorial h1, .font-editorial h2, .font-clasica h1, .font-clasica h2 { font-family: Georgia, "Times New Roman", serif; }
.texture-papel { background-color: #fffaf2; background-image: radial-gradient(rgba(90,68,60,.06) .7px, transparent .7px); background-size: 7px 7px; }
.texture-fotografica .invitation-section { background: rgba(255,250,247,.9); }
.ornament-floral .invitation-section::before { color: var(--accent); content: "❦"; display: block; font-size: 2rem; margin-bottom: 14px; }
.ornament-religioso .family-section::before { color: #d9a64f; content: "✝"; display: block; font-size: 1.8rem; margin-bottom: 14px; }
.ornament-geometrico .invitation-section { border-top: 1px solid rgba(193,63,104,.24); }

.invitation-cover {
  align-items: center;
  background:
    linear-gradient(rgba(34, 25, 32, 0.34), rgba(34, 25, 32, 0.72)),
    url("https://images.unsplash.com/photo-1523438885200-e635ba2c371e?auto=format&fit=crop&w=1800&q=85") center/cover;
  color: #fff;
  display: flex;
  flex-direction: column;
  justify-content: center;
  min-height: 78vh;
  padding: 64px 20px 48px;
  text-align: center;
}

.invitation-page.revealing .invitation-cover {
  animation: invitation-arrive 0.9s ease both;
}

.invitation-page.revealing .invitation-cover > * {
  animation: invitation-copy-arrive 0.8s ease 0.3s both;
}

@keyframes invitation-arrive {
  from { opacity: 0; transform: scale(1.025); }
  to { opacity: 1; transform: scale(1); }
}

@keyframes invitation-copy-arrive {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

.invitation-cover h1 {
  color: #fff;
  font-size: clamp(3rem, 8vw, 5.6rem);
  line-height: 1.02;
  margin: 10px 0 14px;
  max-width: 900px;
}

.invitation-cover p {
  color: rgba(255, 255, 255, 0.86);
}

.invitation-cover .cover-kicker {
  color: #f6d9e1;
  font-size: .75rem;
  font-weight: 900;
  letter-spacing: 0;
  margin: 0;
  text-transform: uppercase;
}

.cover-message { font-family: Georgia, "Times New Roman", serif; font-size: clamp(1.05rem, 2.2vw, 1.4rem); font-style: italic; margin: 0; max-width: 620px; }
.cover-divider { align-items: center; display: flex; gap: 12px; margin: 24px 0 14px; width: min(280px, 70vw); }
.cover-divider i { background: rgba(255,255,255,.48); height: 1px; width: 100%; }
.cover-divider span { color: #f6d9e1; font-size: .72rem; }
.invitation-cover .cover-date { color: #fff; font-size: .84rem; font-weight: 850; margin: 0 0 26px; text-transform: uppercase; }
.guest-dedication { background: rgba(20,18,25,.4); border: 1px solid rgba(255,255,255,.28); border-radius: 8px; backdrop-filter: blur(8px); display: grid; gap: 3px; min-width: min(330px, 88vw); padding: 13px 22px; }
.guest-dedication small { color: rgba(255,255,255,.7); font-size: .65rem; font-weight: 800; text-transform: uppercase; }
.guest-dedication strong { color: #fff; font-family: Georgia, serif; font-size: 1.15rem; font-weight: 500; }
.guest-dedication span { color: #f6d9e1; font-size: .75rem; }
.invitation-welcome { padding-bottom: 58px; padding-top: 58px; }
.invitation-welcome > p:last-child { color: var(--muted); font-family: Georgia, serif; font-size: 1.08rem; line-height: 1.75; margin: 0 auto; max-width: 640px; }

.invitation-section {
  margin: 0 auto;
  max-width: 820px;
  padding: 50px 24px;
  text-align: center;
}

.invitation-section h2 {
  font-family: Georgia, "Times New Roman", serif;
  font-size: clamp(1.7rem, 4vw, 2.5rem);
  font-weight: 500;
}

.event-facts {
  display: grid;
  gap: 14px;
  grid-template-columns: repeat(3, 1fr);
  margin-top: 30px;
}

.event-facts article {
  border-top: 2px solid #d9a64f;
  padding: 22px 12px;
}

.event-facts strong,
.event-facts span {
  display: block;
}

.narrative-photo { margin: 0; max-height: 540px; overflow: hidden; }
.narrative-photo img { display: block; height: min(60vh, 540px); object-fit: cover; width: 100%; }
.family-section { background: linear-gradient(180deg, #fff, #fff8f5); max-width: none; padding: 66px max(24px, calc((100vw - 920px) / 2)); }
.family-intro { margin: 0 auto 36px; max-width: 680px; }
.family-intro h2 { margin: 8px 0 12px; }
.family-intro > p:last-child { color: var(--muted); font-family: Georgia, serif; font-size: 1.05rem; line-height: 1.7; }
.family-ornament { color: #c13f68; display: block; font-family: Georgia, serif; font-size: 2.1rem; margin-bottom: 10px; }
.family-honors { display: grid; gap: 18px; justify-content: center; }
.family-honors.two-groups { grid-template-columns: repeat(2, minmax(260px, 1fr)); }
.honor-group { background: rgba(255,255,255,.82); border: 1px solid rgba(193,63,104,.16); border-radius: 8px; padding: 30px 24px; position: relative; }
.honor-group::before { background: #d9a64f; content: ""; height: 2px; left: 50%; position: absolute; top: 0; transform: translateX(-50%); width: 68px; }
.honor-symbol { align-items: center; background: #f8edf0; border-radius: 50%; color: #c13f68; display: flex; font-size: 1.25rem; height: 46px; justify-content: center; margin: 0 auto 14px; width: 46px; }
.godparents-group .honor-symbol { background: #edf8f6; color: #168c83; }
.honor-group > p { color: var(--muted); font-size: .72rem; font-weight: 800; margin: 0 0 7px; text-transform: uppercase; }
.honor-group h3 { font-family: Georgia, serif; font-size: 1.55rem; font-weight: 500; margin: 0 0 17px; }
.names-list { display: flex; flex-wrap: wrap; gap: 8px 28px; justify-content: center; }
.names-list span { color: var(--ink); font-family: Georgia, serif; font-size: 1.18rem; }
.names-list span + span::before { color: #d9a64f; content: "·"; margin-right: 28px; }
.family-closing { color: #9c6d75; font-family: Georgia, serif; font-style: italic; margin: 30px 0 0; }
.countdown-section { background: radial-gradient(circle at 50% 15%, color-mix(in srgb, var(--event-color) 34%, #211c25), #17151b 66%); color: #fff; overflow: hidden; padding: 68px 24px 58px; position: relative; text-align: center; }
.countdown-section::before, .countdown-section::after { border: 1px solid rgba(255,255,255,.08); border-radius: 50%; content: ""; height: 340px; position: absolute; width: 340px; }
.countdown-section::before { left: -210px; top: -190px; }
.countdown-section::after { bottom: -240px; right: -190px; }
.countdown-section p, .countdown-section h2 { color: #fff; position: relative; z-index: 1; }
.countdown-heading { margin: 0 auto; max-width: 620px; }
.countdown-heading .countdown-kicker { color: color-mix(in srgb, var(--event-color) 38%, #fff); font-size: .72rem; font-weight: 900; margin: 0 0 9px; text-transform: uppercase; }
.countdown-heading h2 { font-size: clamp(2rem, 5vw, 3.2rem); margin: 0 0 10px; }
.countdown-heading > p:last-child { color: rgba(255,255,255,.7); font-family: Georgia, serif; font-size: 1rem; }
.countdown-date { align-items: center; display: flex; flex-direction: column; margin: 30px 0 22px; position: relative; z-index: 1; }
.countdown-date span { color: rgba(255,255,255,.58); font-size: .68rem; font-weight: 850; text-transform: uppercase; }
.countdown-date strong { color: #fff; font-family: Georgia, serif; font-size: clamp(1.2rem, 3vw, 1.7rem); font-weight: 500; margin-top: 5px; }
.countdown-grid { align-items: center; display: grid; gap: 10px; grid-template-columns: minmax(84px, 126px) 12px minmax(84px, 126px) 12px minmax(84px, 126px); justify-content: center; margin: 0 auto 26px; position: relative; z-index: 1; }
.countdown-grid div { background: rgba(255,255,255,.08); border: 1px solid rgba(255,255,255,.14); border-top: 3px solid var(--event-color); border-radius: 8px; backdrop-filter: blur(7px); padding: 18px 8px 15px; }
.countdown-grid strong, .countdown-grid span { display: block; }
.countdown-grid strong { font-family: Georgia, serif; font-size: clamp(2.2rem, 6vw, 3.4rem); font-weight: 500; line-height: 1; }
.countdown-grid span { color: rgba(255,255,255,.64); font-size: .65rem; font-weight: 850; margin-top: 8px; text-transform: uppercase; }
.countdown-grid > i { color: rgba(255,255,255,.38); font-family: Georgia, serif; font-size: 1.8rem; font-style: normal; transform: translateY(-8px); }
.countdown-section .countdown-closing { color: rgba(255,255,255,.62); font-family: Georgia, serif; font-size: .9rem; font-style: italic; margin: 0; }
.interlude-photo { background-attachment: fixed; background-position: center; background-size: cover; height: min(42vh, 420px); margin: 0; }
.locations-section { max-width: 980px; padding-bottom: 62px; padding-top: 62px; }
.locations-heading { margin: 0 auto; max-width: 650px; }
.locations-heading h2 { margin: 8px 0 10px; }
.locations-heading > p:last-child { color: var(--muted); font-family: Georgia, serif; }
.location-grid { display: grid; gap: 22px; grid-template-columns: 1fr 1fr; margin-top: 34px; position: relative; }
.location-grid::before { border-top: 1px dashed rgba(193,63,104,.3); content: ""; left: 42%; position: absolute; right: 42%; top: 36px; }
.location-card { background: #fff; border: 1px solid var(--line); border-radius: 8px; overflow: hidden; padding: 28px 24px 30px; position: relative; }
.location-card::after { background: linear-gradient(90deg, #c13f68, #d9a64f); bottom: 0; content: ""; height: 3px; left: 0; position: absolute; right: 0; }
.reception-card::after { background: linear-gradient(90deg, #20c7b5, #2e86de); }
.location-order { align-items: center; display: flex; justify-content: space-between; }
.location-order span { align-items: center; background: #f8edf0; border-radius: 50%; color: #c13f68; display: flex; font-size: .72rem; font-weight: 900; height: 40px; justify-content: center; margin: 0; width: 40px; }
.reception-card .location-order span { background: #eaf8f6; color: #168c83; }
.location-order small { color: var(--muted); font-size: .65rem; font-weight: 900; text-transform: uppercase; }
.location-illustration { display: block; height: 105px; margin: 5px auto 10px; object-fit: contain; width: 136px; }
.toast-illustration { height: 95px; margin-bottom: 20px; }
.location-card .location-type { color: #c13f68; font-size: .7rem; font-weight: 900; margin: 0 0 5px; text-transform: uppercase; }
.reception-card .location-type { color: #168c83; }
.location-card time { color: var(--ink); display: block; font-family: Georgia, serif; font-size: 1.8rem; margin-bottom: 12px; }
.location-card h3 { font-family: Georgia, serif; font-size: 1.45rem; font-weight: 500; margin: 0 auto 8px; max-width: 330px; }
.location-card .location-address { color: var(--muted); font-size: .84rem; margin: 0 auto 22px; max-width: 340px; min-height: 2.6em; }
.gift-section::before { align-items: center; background: rgba(193,63,104,.1); border-radius: 50%; color: var(--accent); display: flex; font-family: Georgia, serif; font-size: 1.55rem; height: 48px; justify-content: center; margin: 0 auto 16px; width: 48px; }
.gift-section::before { content: "✧"; }
.location-grid a { align-items: center; background: #0f172a; border-radius: 8px; color: #fff; display: inline-flex; font-size: .82rem; font-weight: 800; gap: 7px; padding: 11px 16px; }
.location-grid a span { color: #83e8dc; font-size: 1rem; }
.locations-closing { color: #9c6d75; font-family: Georgia, serif; font-style: italic; margin: 30px 0 0; }
.dress-section { background: linear-gradient(145deg, #f7f2f5, #fff 48%, #eef8f7); padding: 52px max(22px, calc((100vw - 940px) / 2)); text-align: center; }
.dress-heading { margin: 0 auto 24px; max-width: 650px; }
.dress-heading h2 { font-family: Georgia, serif; font-size: clamp(2.2rem, 5vw, 3.4rem); font-weight: 500; margin: 7px 0 12px; }
.dress-heading > p:last-child { color: var(--muted); font-family: Georgia, serif; line-height: 1.7; }
.dress-reference { display: grid; gap: 16px; grid-template-columns: 1fr 1fr; }
.dress-reference article { align-items: center; background: rgba(255,255,255,.85); border: 1px solid var(--line); border-radius: 8px; display: grid; grid-template-columns: 76px 1fr; padding: 14px 18px; text-align: left; }
.dress-reference article > span { align-self: end; color: #168c83; display: block; font-size: .66rem; font-weight: 900; grid-column: 2; margin: 0 0 4px; text-transform: uppercase; }
.dress-reference article > strong { align-self: start; display: block; font-family: Georgia, serif; font-size: .92rem; font-weight: 500; grid-column: 2; line-height: 1.4; }
.attire-reference { display: block; filter: saturate(.62) contrast(.9); grid-row: 1 / 3; height: 92px; margin: 0; mix-blend-mode: multiply; object-fit: contain; opacity: .72; width: 62px; }
.reserved-palette { align-items: center; background: #17151b; border-radius: 8px; color: #fff; display: grid; gap: 20px; grid-template-columns: auto 1fr; margin-top: 14px; padding: 20px 26px; text-align: left; }
.reserved-palette h3, .reserved-palette p { color: #fff; }
.reserved-palette small { color: #83e8dc; font-size: .68rem; font-weight: 900; text-transform: uppercase; }
.reserved-palette h3 { font-family: Georgia, serif; font-size: 1.45rem; font-weight: 500; margin: 3px 0; }
.reserved-palette p { font-weight: 800; margin: 0 0 4px; }
.reserved-palette span { color: rgba(255,255,255,.62); font-size: .78rem; }
.palette-swatches { display: flex; }
.palette-swatches i { background: #ead8b1; border: 3px solid #17151b; border-radius: 50%; height: 48px; width: 48px; }
.palette-swatches i:nth-child(2) { background: #d9a64f; margin-left: -12px; }
.palette-swatches i:nth-child(3) { background: #e9a4b8; margin-left: -12px; }
.gift-section { background: #fff; }

.event-facts span {
  color: var(--muted);
  margin-top: 7px;
}

.rsvp-band { background: radial-gradient(circle at 50% 0, color-mix(in srgb, var(--rsvp-color) 68%, #fff), var(--rsvp-color) 45%, #17151b 120%); color: #fff; overflow: hidden; padding: 74px 24px; position: relative; text-align: center; }
.rsvp-band::before { border: 1px solid rgba(255,255,255,.12); border-radius: 50%; content: ""; height: 520px; left: 50%; position: absolute; top: -330px; transform: translateX(-50%); width: 820px; }
.rsvp-content { margin: 0 auto; max-width: 620px; position: relative; z-index: 1; }
.rsvp-symbol { align-items: center; background: #fff; border-radius: 50%; box-shadow: 0 12px 32px rgba(20,18,25,.25); color: var(--rsvp-color); display: flex; font-size: 1.5rem; height: 58px; justify-content: center; margin: 0 auto 18px; width: 58px; }
.rsvp-kicker { color: rgba(255,255,255,.76) !important; font-size: .72rem; font-weight: 900; margin: 0 0 8px; text-transform: uppercase; }
.rsvp-band h2 { font-size: clamp(2.4rem, 6vw, 4rem); margin: 0 0 12px; }
.rsvp-message { color: rgba(255,255,255,.82) !important; font-family: Georgia, serif; font-size: 1.05rem; line-height: 1.65; margin: 0 auto 24px; max-width: 540px; }
.rsvp-reservation { background: rgba(20,18,25,.25); border: 1px solid rgba(255,255,255,.2); border-radius: 8px; backdrop-filter: blur(8px); display: grid; grid-template-columns: 1fr 150px; margin: 0 auto 16px; max-width: 500px; text-align: left; }
.rsvp-reservation div { padding: 13px 18px; }
.rsvp-reservation div + div { border-left: 1px solid rgba(255,255,255,.16); text-align: center; }
.rsvp-reservation small, .rsvp-reservation strong { display: block; }
.rsvp-reservation small { color: rgba(255,255,255,.62); font-size: .62rem; font-weight: 850; text-transform: uppercase; }
.rsvp-reservation strong { color: #fff; font-family: Georgia, serif; font-size: 1.05rem; margin-top: 3px; }
.rsvp-deadline { color: rgba(255,255,255,.72) !important; font-size: .8rem; margin: 0 0 20px; }
.rsvp-deadline strong { color: #fff; }
.rsvp-main-button { align-items: center; background: #fff; border: 0; border-radius: 8px; box-shadow: 0 16px 38px rgba(20,18,25,.3); color: #17151b; cursor: pointer; display: inline-flex; font: inherit; font-size: 1rem; font-weight: 900; gap: 24px; justify-content: space-between; min-height: 58px; min-width: min(100%, 330px); padding: 0 12px 0 24px; transition: transform .25s ease, box-shadow .25s ease; }
.rsvp-main-button i { align-items: center; background: var(--rsvp-color); border-radius: 6px; color: #fff; display: flex; font-size: 1.25rem; font-style: normal; height: 38px; justify-content: center; width: 38px; }
.rsvp-main-button:hover { box-shadow: 0 20px 46px rgba(20,18,25,.38); transform: translateY(-3px); }
.rsvp-main-button:disabled { cursor: not-allowed; opacity: .6; }
.rsvp-note { color: rgba(255,255,255,.55) !important; font-size: .7rem; margin: 13px 0 0; }

.embed-section { background: #fff; padding: 18px; }
.embed-section iframe { border: 0; display: block; height: min(72vh, 720px); width: 100%; }

.gallery-section { background: #17151b; color: #fff; padding: 66px max(20px, calc((100vw - 1120px) / 2)); }
.gallery-editorial { position: relative; }
.gallery-statement { align-items: center; display: flex; gap: 12px; margin: 0 0 22px; }
.gallery-statement span { align-items: center; border: 1px solid rgba(255,255,255,.24); border-radius: 50%; color: #f1c9d5; display: flex; flex: 0 0 38px; height: 38px; justify-content: center; }
.gallery-statement p { color: rgba(255,255,255,.84); font-family: Georgia, serif; font-size: clamp(1.2rem, 2.5vw, 1.65rem); margin: 0; }
.invitation-gallery { display: grid; gap: 12px; grid-auto-rows: 190px; grid-template-columns: repeat(4, 1fr); }
.gallery-item { background: #27242c; border: 0; border-radius: 8px; cursor: zoom-in; min-height: 0; overflow: hidden; padding: 0; position: relative; }
.gallery-item:first-child { grid-column: span 2; grid-row: span 2; }
.gallery-item:nth-child(2), .gallery-item:nth-child(3) { grid-column: span 1; }
.gallery-item:nth-child(4) { grid-column: span 2; }
.gallery-item:nth-child(n+5) { grid-column: span 1; }
.gallery-item::after { background: linear-gradient(180deg, transparent 58%, rgba(15,13,18,.5)); content: ""; inset: 0; opacity: .55; position: absolute; transition: opacity .35s ease; }
.gallery-item img { display: block; height: 100%; object-fit: cover; transition: transform .55s ease; width: 100%; }
.gallery-item:hover img { transform: scale(1.045); }
.gallery-item:hover::after { opacity: .85; }
.gallery-zoom { align-items: center; background: rgba(255,255,255,.9); border-radius: 50%; bottom: 14px; color: #17151b; display: flex; font-size: 1.15rem; height: 38px; justify-content: center; opacity: 0; position: absolute; right: 14px; transform: translateY(8px); transition: opacity .3s ease, transform .3s ease; width: 38px; z-index: 2; }
.gallery-item:hover .gallery-zoom, .gallery-item:focus-visible .gallery-zoom { opacity: 1; transform: translateY(0); }
.gallery-caption { color: rgba(255,255,255,.5); font-size: .7rem; margin: 15px 0 0; text-align: right; }
.gallery-dialog { background: transparent; border: 0; height: 100vh; max-height: none; max-width: none; padding: 0; width: 100vw; }
.gallery-dialog::backdrop { background: rgba(12,11,15,.94); }
.gallery-lightbox { align-items: center; display: grid; height: 100%; justify-items: center; padding: 54px 70px; position: relative; }
.gallery-lightbox img { max-height: calc(100vh - 108px); max-width: calc(100vw - 140px); object-fit: contain; }
.gallery-close, .gallery-nav { align-items: center; background: rgba(255,255,255,.12); border: 1px solid rgba(255,255,255,.2); border-radius: 50%; color: #fff; cursor: pointer; display: flex; justify-content: center; position: absolute; z-index: 2; }
.gallery-close { font-size: 1.7rem; height: 42px; right: 18px; top: 18px; width: 42px; }
.gallery-nav { font-size: 2rem; height: 48px; top: 50%; transform: translateY(-50%); width: 48px; }
.gallery-prev { left: 14px; }
.gallery-next { right: 14px; }
.gallery-counter { bottom: 18px; color: #fff; position: absolute; }

.invitation-music {
  bottom: 14px;
  max-width: calc(100% - 28px);
  position: fixed;
  right: 14px;
  z-index: 5;
}

.rsvp-band h2,
.rsvp-band p {
  color: #fff;
}

.rsvp-dialog {
  border: 0;
  border-radius: 8px;
  max-width: 520px;
  padding: 0;
  width: calc(100% - 28px);
}

.rsvp-dialog::backdrop {
  background: rgba(20, 18, 25, 0.72);
  backdrop-filter: blur(6px);
}

.rsvp-form {
  padding: 30px;
  position: relative;
}

.rsvp-form h2 { font-family: Georgia, serif; font-size: 2rem; margin-bottom: 8px; }
.rsvp-form fieldset { border: 0; display: grid; gap: 9px; margin: 20px 0; padding: 0; }
.rsvp-form legend { font-size: .78rem; font-weight: 850; margin-bottom: 9px; }
.rsvp-form .radio-row { align-items: center; background: var(--soft); border: 1px solid var(--line); border-radius: 8px; cursor: pointer; display: flex; flex-direction: row; gap: 10px; padding: 12px 14px; }
.rsvp-form .radio-row:has(input:checked) { background: #e9f7f5; border-color: #20a996; color: #087f72; }
.rsvp-form .radio-row input { accent-color: #168c83; width: auto; }
#confirmedGroup { display: block; margin: 20px 0; }
#confirmedGroup > span { display: block; font-size: .84rem; font-weight: 850; }
#confirmedGroup > small { color: var(--muted); display: block; font-size: .72rem; margin-top: 3px; }
.guest-count-selector { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 13px; }
.guest-count-button { align-items: center; background: #fff; border: 1px solid var(--line); border-radius: 8px; color: var(--ink); cursor: pointer; display: flex; font: inherit; font-size: 1rem; font-weight: 900; height: 46px; justify-content: center; transition: background .2s ease, border-color .2s ease, color .2s ease, transform .2s ease; width: 46px; }
.guest-count-button:hover { border-color: #20a996; transform: translateY(-2px); }
.guest-count-button.selected { background: #168c83; border-color: #168c83; box-shadow: 0 8px 18px rgba(22,140,131,.2); color: #fff; }
.rsvp-form > .button[type="submit"] { justify-content: center; min-height: 52px; width: 100%; }

.entry-pass { background: #fff; border: 0; border-radius: 8px; max-width: 430px; padding: 0; width: calc(100% - 28px); }
.entry-pass::backdrop { background: rgba(20,18,25,.78); backdrop-filter: blur(6px); }
.entry-pass-card { padding: 30px; position: relative; text-align: center; }
.entry-pass-card h2 { font-family: Georgia, serif; margin-bottom: 6px; }
.entry-pass-card > p { color: var(--muted); }
.entry-qr { background: #fff; border: 1px solid var(--line); border-radius: 8px; display: block; margin: 20px auto; max-width: 230px; padding: 10px; width: 70%; }
.pass-details { background: var(--soft); border-radius: 8px; display: grid; gap: 6px; padding: 15px; }
.pass-code { color: var(--muted); font-family: monospace; font-size: .78rem; }

.reserved-summary {
  background: var(--soft);
  border-left: 4px solid var(--accent);
  padding: 14px;
}

.dialog-close {
  background: var(--soft);
  border: 0;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.5rem;
  height: 38px;
  position: absolute;
  right: 16px;
  top: 16px;
  width: 38px;
}

@media (max-width: 640px) {
  .event-facts {
    grid-template-columns: 1fr;
  }

  .location-grid { grid-template-columns: 1fr; }
  .location-grid::before { border-left: 1px dashed rgba(193,63,104,.3); border-top: 0; bottom: 42%; left: 20px; right: auto; top: 36%; }
  .family-honors.two-groups { grid-template-columns: 1fr; }
  .names-list { flex-direction: column; gap: 7px; }
  .names-list span + span::before { content: none; }
  .countdown-section { padding: 54px 14px 48px; }
  .countdown-grid { gap: 5px; grid-template-columns: minmax(72px, 1fr) 7px minmax(72px, 1fr) 7px minmax(72px, 1fr); }
  .countdown-grid div { padding: 15px 4px 13px; }
  .dress-reference { grid-template-columns: 1fr; }
  .reserved-palette { grid-template-columns: 1fr; text-align: center; }
  .palette-swatches { justify-content: center; }
  .rsvp-band { padding: 58px 16px; }
  .rsvp-reservation { grid-template-columns: 1fr 112px; }
  .rsvp-reservation div { padding: 12px; }
  .rsvp-main-button { width: 100%; }
  .interlude-photo { background-attachment: scroll; }

  .envelope-meta {
    font-size: 0.95rem;
  }

  .gallery-section { padding: 48px 14px; }
  .invitation-gallery { grid-auto-rows: 145px; grid-template-columns: repeat(2, 1fr); }
  .gallery-item:first-child { grid-column: span 2; grid-row: span 2; }
  .gallery-item:nth-child(n+2) { grid-column: span 1; }
  .gallery-item:nth-child(4) { grid-column: span 2; }
  .gallery-zoom { opacity: 1; transform: none; }
  .gallery-lightbox { padding: 60px 12px; }
  .gallery-lightbox img { max-height: calc(100vh - 120px); max-width: 100%; }
  .gallery-nav { bottom: 18px; top: auto; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
  .invitation-page.revealing .invitation-cover,
  .invitation-page.revealing .invitation-cover > * {
    animation-duration: 0.01ms !important;
    animation-delay: 0ms !important;
  }
}
