:root {
  --oxblood: #420303;
  --black-cherry: #170909;
  --wine: #630c12;
  --gold: #d8b56a;
  --gold-bright: #f1d894;
  --gold-deep: #9b6c2c;
  --champagne: #e7cea0;
  --ivory: #f7f0e4;
  --ink: #0c0304;
  --ease-royal: cubic-bezier(.2,.76,.25,1);
}

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

html { scroll-behavior: smooth; scrollbar-color: var(--gold) var(--ink); }

body {
  margin: 0;
  overflow-x: hidden;
  background: var(--ink);
  color: var(--ivory);
  font-family: "Palatino Linotype", "Book Antiqua", Palatino, Georgia, serif;
}

body.gate-locked { overflow: hidden; }

button, a { font: inherit; }
button { color: inherit; }
button:focus-visible, a:focus-visible { outline: 2px solid var(--ivory); outline-offset: 6px; }

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

body.motion-paused * { animation-play-state: paused !important; }
body.auto-paused .advance-note { visibility: hidden; }
.gate-scene.skip-motion *, .gate-scene.skip-motion *::before, .gate-scene.skip-motion *::after { transition-duration: .01ms !important; transition-delay: 0s !important; }

.skip-link {
  position: fixed;
  z-index: 100;
  top: 12px;
  left: 12px;
  padding: 10px 14px;
  border: 1px solid var(--gold);
  background: var(--black-cherry);
  color: var(--ivory);
  transform: translateY(-160%);
}
.skip-link:focus { transform: translateY(0); }

.gate-scene {
  position: relative;
  min-height: 100vh;
  min-height: 100dvh;
  overflow: hidden;
  isolation: isolate;
  background: var(--black-cherry);
  perspective: 1800px;
}

.palace-view, .palace-vignette, .gate-frame, .door-stage {
  position: absolute;
  inset: 0;
}

.palace-view {
  z-index: -3;
  background: url("assets/palace-courtyard.webp") center / cover no-repeat;
  filter: brightness(.7) saturate(.85);
  transform: scale(1.04);
  transition: filter 2s ease 1s, transform 5s var(--ease-royal);
}

.palace-vignette {
  z-index: -2;
  background:
    radial-gradient(ellipse at 50% 58%, transparent 10%, rgba(14,2,3,.13) 46%, rgba(10,1,2,.82) 100%),
    linear-gradient(180deg, rgba(11,2,2,.3), transparent 35%, rgba(9,1,2,.42));
  transition: opacity 1.5s ease 1s;
}

.reveal-copy {
  position: absolute;
  z-index: 1;
  top: 50%;
  left: 50%;
  display: grid;
  justify-items: center;
  width: min(680px, 85vw);
  text-align: center;
  opacity: 0;
  transform: translate(-50%, -44%);
  transition: opacity 1.2s ease 1.25s, transform 1.8s var(--ease-royal) 1.05s;
  text-shadow: 0 3px 30px rgba(0,0,0,.9);
}

.eyebrow, .family-line, .date-line, .name-plaque span, .gate-control > p, .gate-prompt {
  text-transform: uppercase;
  letter-spacing: .24em;
}

.eyebrow {
  margin: 0 0 18px;
  color: var(--gold-bright);
  font-size: clamp(.76rem, 1.05vw, .94rem);
  font-weight: 600;
  line-height: 1.5;
  text-shadow: 0 2px 16px #000, 0 0 28px rgba(0,0,0,.9);
}
.mini-crest { display: inline-grid; width: 60px; aspect-ratio: 1; place-items: center; border: 1px solid var(--gold-bright); border-radius: 50%; color: var(--gold-bright); font-size: .82rem; background: rgba(12,3,4,.2); box-shadow: 0 0 0 5px rgba(216,181,106,.055), 0 8px 28px rgba(0,0,0,.35); }
.reveal-copy h1 {
  display: grid;
  row-gap: .1em;
  margin: 20px 0 10px;
  font-size: clamp(3.1rem, 7.5vw, 6.8rem);
  font-weight: 400;
  line-height: .82;
  letter-spacing: -.055em;
}
.reveal-copy h1 span { display: block; white-space: nowrap; }
.reveal-copy h1.couple-heading { width: 100%; row-gap: .12em; font-size: clamp(2rem, 3.9vw, 3.8rem); line-height: .94; letter-spacing: -.045em; }
.reveal-copy h1 .title-person { font-size: 1em; }
.reveal-copy h1 .title-weds { width: fit-content; margin: .78em 0 .5em; padding: .46em .9em .42em; border: 1px solid rgba(216,181,106,.25); border-radius: 2px; color: var(--gold-bright); background: rgba(19,2,3,.72); box-shadow: inset 0 0 18px rgba(0,0,0,.24), 0 5px 18px rgba(0,0,0,.2); font-size: clamp(.72rem, 1.05vw, .9rem); font-weight: 600; letter-spacing: .32em; line-height: 1.2; text-transform: uppercase; justify-self: start; }
.reveal-copy h1:focus { outline: none; }
.family-line {
  width: fit-content;
  max-width: 100%;
  margin: 22px 0 20px;
  padding: 9px 18px;
  color: #fff1cb;
  background: linear-gradient(90deg, transparent, rgba(9,1,2,.74) 12%, rgba(9,1,2,.74) 88%, transparent);
  font-size: clamp(.82rem, 1.14vw, 1rem);
  font-weight: 600;
  line-height: 1.45;
  letter-spacing: .18em;
  text-shadow: 0 2px 12px #000, 0 0 22px #000;
}
.royal-rule { display: flex; align-items: center; justify-content: center; gap: 14px; color: var(--gold); }
.royal-rule i { width: min(120px, 22vw); height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.royal-rule i:last-child { transform: rotate(180deg); }
.date-line { margin: 18px 0 0; color: #fff7e8; font-size: clamp(.94rem, 1.45vw, 1.18rem); font-weight: 600; text-shadow: 0 2px 15px #000, 0 0 22px #000; }
.date-line b { color: var(--gold); }

.hero-flourish {
  position: absolute;
  z-index: 1;
  top: 50%;
  display: grid;
  justify-items: center;
  gap: 11px;
  color: var(--gold);
  opacity: 0;
  transform: translateY(-42%) scale(.82);
  transition: opacity 1.2s ease 1.65s, transform 1.6s var(--ease-royal) 1.55s;
  pointer-events: none;
  text-shadow: 0 0 16px rgba(216,181,106,.45);
}
.hero-flourish-left { left: clamp(72px, 8vw, 150px); }
.hero-flourish-right { right: clamp(72px, 8vw, 150px); transform: translateY(-42%) scale(-.82,.82); }
.hero-flourish span { font-size: .72rem; }
.hero-flourish i { width: 1px; height: clamp(72px, 13vh, 126px); background: linear-gradient(transparent, var(--gold), transparent); }
.hero-flourish b { font-size: 1.7rem; font-weight: 400; }
.gate-scene.is-open .hero-flourish-left { opacity: .7; transform: translateY(-50%) scale(1); }
.gate-scene.is-open .hero-flourish-right { opacity: .7; transform: translateY(-50%) scale(-1,1); }

.name-plaque {
  position: absolute;
  z-index: 8;
  top: max(26px, env(safe-area-inset-top));
  right: max(32px, 4vw);
  display: grid;
  gap: 7px;
  max-width: 430px;
  padding: 17px 24px;
  border: 1px solid rgba(216,181,106,.58);
  background: linear-gradient(135deg, rgba(66,3,3,.93), rgba(20,2,3,.86));
  box-shadow: inset 0 0 0 4px rgba(216,181,106,.08), 0 12px 34px rgba(0,0,0,.38);
  text-align: center;
  transition: opacity .7s ease, transform .9s var(--ease-royal);
}
.name-plaque span { color: var(--gold); font-size: .52rem; }
.name-plaque strong { font-size: clamp(.82rem, 1.35vw, 1.12rem); font-weight: 400; letter-spacing: .07em; }

.gate-frame { z-index: 5; pointer-events: none; }
.gate-frame::before {
  position: absolute;
  inset: 18px;
  border: 1px solid rgba(216,181,106,.42);
  box-shadow: inset 0 0 0 5px rgba(53,19,4,.25), inset 0 0 60px rgba(0,0,0,.45);
  content: "";
}
.gate-crown {
  position: absolute;
  top: 18px;
  left: 50%;
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 14px 30px 18px;
  color: var(--gold);
  background: linear-gradient(180deg, #2e0809, #160304);
  border: 1px solid rgba(216,181,106,.46);
  border-top: 0;
  border-radius: 0 0 70% 70%;
  transform: translateX(-50%);
  box-shadow: 0 10px 30px rgba(0,0,0,.5);
}
.gate-crown b { font-size: 1.15rem; font-weight: 400; letter-spacing: .1em; }
.gate-crown span { font-size: .6rem; }

.frame-pillar {
  position: absolute;
  top: 0;
  bottom: 0;
  width: clamp(22px, 4vw, 68px);
  background:
    linear-gradient(90deg, #130203, #5e1915 25%, #1d0405 50%, #6d2b1e 72%, #160203),
    repeating-linear-gradient(0deg, transparent 0 23px, rgba(216,181,106,.2) 24px 25px);
  box-shadow: inset 0 0 0 1px rgba(216,181,106,.3), 0 0 30px rgba(0,0,0,.7);
}
.frame-pillar-left { left: 0; }
.frame-pillar-right { right: 0; transform: scaleX(-1); }

.door-stage { z-index: 3; display: flex; perspective: 1800px; }
.gate-door {
  position: relative;
  width: 50.08%;
  height: 100%;
  will-change: transform;
  transform-style: preserve-3d;
  transition: transform 2.35s var(--ease-royal), filter 1.7s ease;
}
.gate-door-left { transform-origin: left center; }
.gate-door-right { transform-origin: right center; }

.door-surface {
  position: absolute;
  inset: 0;
  overflow: hidden;
  background:
    radial-gradient(circle at 50% 49%, transparent 0 90px, rgba(216,181,106,.28) 91px 92px, transparent 93px),
    linear-gradient(120deg, transparent 43%, rgba(255,224,153,.08) 48%, transparent 53%),
    repeating-linear-gradient(90deg, rgba(255,255,255,.025) 0 2px, transparent 2px 76px),
    linear-gradient(145deg, #240304, var(--oxblood) 45%, #1c0204 100%);
  border: 2px solid #7e4c24;
  box-shadow: inset 0 0 0 8px #25080a, inset 0 0 0 10px rgba(216,181,106,.48), inset 0 0 80px #0a0102, 0 0 42px rgba(0,0,0,.8);
}
.gate-door-left .door-surface { border-radius: 62% 0 0 0 / 23% 0 0 0; }
.gate-door-right .door-surface { border-radius: 0 62% 0 0 / 0 23% 0 0; }
.door-surface::before, .door-surface::after {
  position: absolute;
  content: "";
  border: 1px solid rgba(216,181,106,.36);
  background: radial-gradient(circle, rgba(216,181,106,.14), transparent 67%);
  transform: rotate(45deg);
}
.door-surface::before { width: 180px; height: 180px; top: 19%; left: calc(50% - 90px); }
.door-surface::after { width: 130px; height: 130px; bottom: 9%; left: calc(50% - 65px); }
.door-star { position: absolute; top: 29%; left: 50%; color: var(--gold); font-size: clamp(2rem, 4vw, 4rem); transform: translateX(-50%); text-shadow: 0 0 18px rgba(216,181,106,.5); }
.door-medallion {
  position: absolute;
  z-index: 2;
  top: 45%;
  left: 50%;
  display: grid;
  width: clamp(84px, 11vw, 142px);
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid var(--gold);
  border-radius: 50%;
  color: var(--champagne);
  font-size: clamp(2rem, 4vw, 4.2rem);
  transform: translate(-50%,-50%);
  box-shadow: inset 0 0 0 7px #310708, inset 0 0 0 8px rgba(216,181,106,.3), 0 0 30px rgba(0,0,0,.65);
}
.door-panel { position: absolute; left: 9%; right: 9%; border: 1px solid rgba(216,181,106,.25); }
.door-panel-top { top: 7%; height: 34%; border-radius: 50% 50% 4px 4px / 38% 38% 4px 4px; }
.door-panel-bottom { bottom: 5%; height: 34%; }
.door-knocker { position: absolute; z-index: 3; top: 57%; width: 23px; height: 30px; border: 3px solid var(--gold); border-radius: 50%; }
.gate-door-left .door-knocker { right: 11px; }
.gate-door-right .door-knocker { left: 11px; }

.gate-control {
  position: absolute;
  z-index: 10;
  top: 50%;
  left: 50%;
  display: grid;
  justify-items: center;
  transform: translate(-50%,-50%);
  transition: opacity .45s ease, transform .8s var(--ease-royal), visibility 0s linear .8s;
}
.gate-control > p { margin: 0 0 18px; color: var(--gold-bright); font-size: clamp(.72rem, 1vw, .84rem); font-weight: 600; text-shadow: 0 2px 14px #000; }
.wax-seal {
  position: relative;
  display: grid;
  width: clamp(142px, 15vw, 178px);
  aspect-ratio: 1;
  place-items: center;
  align-content: center;
  border: 1px solid #e5c27a;
  border-radius: 50%;
  background: radial-gradient(circle at 38% 30%, #8b1c20, var(--oxblood) 45%, #190204 100%);
  box-shadow: 0 0 0 8px rgba(25,2,4,.8), 0 0 0 10px rgba(216,181,106,.8), 0 20px 55px rgba(0,0,0,.66), inset 0 0 30px rgba(255,202,118,.12);
  cursor: pointer;
  transition: transform .35s ease, box-shadow .35s ease;
}
.wax-seal:hover { transform: scale(1.045); box-shadow: 0 0 0 8px rgba(25,2,4,.8), 0 0 0 10px var(--champagne), 0 25px 65px rgba(0,0,0,.75), 0 0 45px rgba(216,181,106,.24); }
.seal-ring { position: absolute; inset: 11px; border: 1px dashed rgba(231,206,160,.5); border-radius: 50%; }
.seal-monogram { color: var(--gold); font-size: clamp(2rem, 4vw, 3rem); line-height: 1; }
.wax-seal strong { margin-top: 6px; color: var(--ivory); font-size: .82rem; font-weight: 400; letter-spacing: .24em; text-transform: uppercase; }
.wax-seal small { margin-top: 3px; color: var(--champagne); font-size: .65rem; letter-spacing: .16em; text-transform: uppercase; }
.gate-prompt { margin-top: 21px; color: rgba(247,240,228,.9); font-size: .7rem; font-weight: 600; line-height: 1.5; text-shadow: 0 2px 12px #000; }

.enter-button {
  position: absolute;
  z-index: 6;
  bottom: max(28px, env(safe-area-inset-bottom));
  left: 50%;
  display: grid;
  gap: 10px;
  border: 0;
  background: transparent;
  color: var(--ivory);
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .25em;
  text-transform: uppercase;
  opacity: 0;
  transform: translate(-50%, 18px);
  cursor: pointer;
  transition: opacity .8s ease 2.1s, transform 1s var(--ease-royal) 2.1s;
}
.enter-button i { justify-self: center; width: 1px; height: 34px; background: linear-gradient(var(--gold), transparent); animation: breathe 1.8s ease-in-out infinite; }

.gate-scene.is-open .gate-door-left { transform: rotateY(-112deg); filter: brightness(.55); }
.gate-scene.is-open .gate-door-right { transform: rotateY(112deg); filter: brightness(.55); }
.gate-scene.is-open .gate-control { opacity: 0; visibility: hidden; transform: translate(-50%,-50%) scale(.82); }
.gate-scene.is-open .name-plaque { opacity: 0; transform: translateY(-16px); }
.gate-scene.is-open .palace-view { filter: brightness(.95) saturate(1); transform: scale(1); }
.gate-scene.is-open .palace-vignette { opacity: .65; }
.gate-scene.is-open .reveal-copy { opacity: 1; transform: translate(-50%,-50%); }
.gate-scene.is-open .enter-button { opacity: 1; transform: translate(-50%,0); }

#invitation {
  position: relative;
  min-height: 100vh;
  overflow: clip;
  background: var(--black-cherry);
}

.gold-dust {
  position: fixed;
  inset: 0;
  z-index: 25;
  overflow: hidden;
  pointer-events: none;
}

.gold-dust .dust {
  position: absolute;
  top: var(--y);
  left: var(--x);
  width: var(--size);
  aspect-ratio: 1;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 8px rgba(216,181,106,.72);
  opacity: 0;
  animation: dust-float var(--duration) ease-in-out var(--delay) infinite;
}

.journey-nav {
  position: fixed;
  z-index: 40;
  top: 50%;
  right: clamp(12px, 2.2vw, 34px);
  display: grid;
  gap: 13px;
  padding: 20px 13px 14px;
  border: 1px solid rgba(216,181,106,.28);
  border-radius: 50px;
  background: rgba(19,2,3,.78);
  box-shadow: 0 18px 50px rgba(0,0,0,.4), inset 0 0 20px rgba(216,181,106,.035);
  opacity: 0;
  pointer-events: none;
  transform: translate(18px,-50%);
  transition: opacity .6s ease, transform .8s var(--ease-royal);
  backdrop-filter: blur(14px);
}

body.invitation-open .journey-nav { opacity: 1; pointer-events: auto; transform: translate(0,-50%); }

.journey-line {
  position: absolute;
  z-index: -1;
  top: 34px;
  bottom: 88px;
  left: 26px;
  width: 1px;
  overflow: hidden;
  background: rgba(216,181,106,.2);
}

.journey-line span {
  display: block;
  width: 100%;
  height: var(--progress, 0%);
  background: linear-gradient(var(--champagne), var(--gold));
  box-shadow: 0 0 8px var(--gold);
  transition: height .6s var(--ease-royal);
}

.journey-dot {
  position: relative;
  display: grid;
  grid-template-columns: 26px 0fr;
  align-items: center;
  gap: 0;
  width: 26px;
  height: 26px;
  padding: 0;
  border: 1px solid rgba(216,181,106,.48);
  border-radius: 50%;
  background: var(--black-cherry);
  cursor: pointer;
  transition: width .35s ease, grid-template-columns .35s ease, background .35s ease;
}

.journey-dot span {
  color: var(--champagne);
  font-size: .48rem;
  letter-spacing: .05em;
  text-align: center;
}

.journey-dot small {
  overflow: hidden;
  color: var(--ivory);
  font-size: .53rem;
  letter-spacing: .16em;
  opacity: 0;
  text-transform: uppercase;
  white-space: nowrap;
  transition: opacity .25s ease;
}

.journey-dot:hover, .journey-dot:focus-visible { grid-template-columns: 26px 1fr; width: 104px; border-radius: 18px; }
.journey-dot:hover small, .journey-dot:focus-visible small { opacity: 1; }
.journey-dot.is-active { border-color: var(--champagne); background: var(--gold-deep); box-shadow: 0 0 18px rgba(216,181,106,.36); }

.auto-journey {
  display: grid;
  justify-items: center;
  gap: 4px;
  margin-top: 5px;
  padding: 10px 0 0;
  border: 0;
  border-top: 1px solid rgba(216,181,106,.2);
  background: transparent;
  color: var(--champagne);
  cursor: pointer;
}
.auto-journey i { position: relative; width: 25px; height: 12px; border: 1px solid rgba(216,181,106,.55); border-radius: 20px; }
.auto-journey i::after { position: absolute; top: 2px; right: 2px; width: 6px; height: 6px; border-radius: 50%; background: var(--gold); content: ""; transition: right .3s ease, background .3s ease; }
.auto-journey span { display: none; }
.auto-journey b { font-size: .43rem; font-weight: 400; letter-spacing: .1em; text-transform: uppercase; }
.auto-journey[aria-pressed="false"] i::after { right: 15px; background: rgba(247,240,228,.55); }

.chapter {
  position: relative;
  display: grid;
  min-height: 100vh;
  min-height: 100svh;
  place-items: center;
  overflow: hidden;
  scroll-margin-top: 0;
}

.revealable {
  opacity: 0;
  transform: translateY(34px);
  transition: opacity 1.1s ease, transform 1.3s var(--ease-royal);
}

.is-revealed .revealable, .revealable.is-revealed { opacity: 1; transform: translateY(0); }

.welcome-section {
  padding: clamp(70px, 8vw, 118px) max(24px, 8vw);
  background:
    linear-gradient(90deg, rgba(216,181,106,.06) 1px, transparent 1px) 0 0 / 80px 80px,
    linear-gradient(rgba(216,181,106,.06) 1px, transparent 1px) 0 0 / 80px 80px,
    radial-gradient(circle at 50% 48%, #6a0c11 0, #390306 39%, #120203 82%);
}

.welcome-section::before, .welcome-section::after {
  position: absolute;
  width: min(38vw, 520px);
  aspect-ratio: 1;
  border: 1px solid rgba(216,181,106,.12);
  border-radius: 50%;
  content: "";
}
.welcome-section::before { top: -23%; left: -15%; box-shadow: 0 0 0 24px rgba(216,181,106,.02), 0 0 0 55px rgba(216,181,106,.018); }
.welcome-section::after { right: -15%; bottom: -23%; box-shadow: 0 0 0 24px rgba(216,181,106,.02), 0 0 0 55px rgba(216,181,106,.018); }

.welcome-halo {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(82vw, 840px);
  aspect-ratio: 1;
  border: 1px solid rgba(216,181,106,.1);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(216,181,106,.13), transparent 67%);
  transform: translate(-50%,-50%);
  animation: halo-pulse 5s ease-in-out infinite;
}

.welcome-card {
  position: relative;
  z-index: 2;
  width: min(760px, 88vw);
  padding: clamp(52px, 7vw, 88px) clamp(24px, 7vw, 76px) clamp(44px, 6vw, 70px);
  border: 1px solid rgba(216,181,106,.52);
  border-radius: 48% 48% 5px 5px / 15% 15% 5px 5px;
  background: linear-gradient(145deg, rgba(51,4,7,.94), rgba(19,2,3,.93));
  box-shadow: inset 0 0 0 8px rgba(216,181,106,.035), 0 45px 110px rgba(0,0,0,.42);
  text-align: center;
}

.welcome-card::before {
  position: absolute;
  inset: 13px;
  border: 1px solid rgba(216,181,106,.15);
  border-radius: inherit;
  content: "";
  pointer-events: none;
}
.welcome-card::after {
  position: absolute;
  top: 24px;
  left: 50%;
  color: rgba(241,216,148,.78);
  font-size: 1.25rem;
  content: "❦";
  transform: translateX(-50%);
  text-shadow: 0 0 18px rgba(216,181,106,.4);
}

.section-kicker, .welcome-prelude, .welcome-family, .welcome-message {
  text-transform: uppercase;
  letter-spacing: .22em;
}
.section-kicker { margin: 0 0 24px; color: var(--gold-bright); font-size: clamp(.72rem, 1vw, .84rem); font-weight: 600; line-height: 1.55; }
.ja-crest { display: inline-grid; width: clamp(64px, 8vw, 88px); aspect-ratio: 1; place-items: center; border: 1px solid var(--gold); border-radius: 50%; box-shadow: 0 0 0 7px rgba(216,181,106,.05); }
.ja-crest span { color: var(--champagne); font-size: clamp(1.15rem, 2.4vw, 1.7rem); }
.welcome-prelude { margin: 27px 0 10px; color: var(--champagne); font-size: .76rem; font-weight: 600; line-height: 1.5; }
.welcome-card h2 { margin: 0; font-size: clamp(2.7rem, 7vw, 5.7rem); font-weight: 400; line-height: .9; letter-spacing: -.055em; }
.welcome-family { margin: 18px 0 24px; color: rgba(247,240,228,.92); font-size: clamp(.72rem, 1vw, .84rem); font-weight: 600; line-height: 1.55; }
.ornament-divider { display: flex; align-items: center; justify-content: center; gap: 12px; color: var(--gold); }
.ornament-divider i { width: min(100px, 20vw); height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.ornament-divider i:last-child { transform: rotate(180deg); }
.ornament-divider b { font-size: .7rem; }
.welcome-message { max-width: 640px; margin: 42px auto 38px; color: #f3dfba; font-size: clamp(.88rem, 1.25vw, 1.05rem); font-weight: 600; line-height: 1.85; }

.date-triptych { display: flex; align-items: center; justify-content: center; gap: clamp(12px, 3vw, 30px); }
.date-triptych > span { display: grid; gap: 4px; }
.date-triptych b { font-size: clamp(1.8rem, 4.2vw, 3rem); font-weight: 400; line-height: 1; }
.date-triptych small { color: var(--gold-bright); font-size: .68rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.date-triptych > i { width: 1px; height: 40px; background: linear-gradient(transparent, var(--gold), transparent); }

.begin-journey {
  display: inline-grid;
  gap: 10px;
  justify-items: center;
  margin-top: 36px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--champagne);
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .24em;
  text-transform: uppercase;
  cursor: pointer;
}
.begin-journey i { width: 1px; height: 32px; background: linear-gradient(var(--gold), transparent); animation: breathe 1.8s ease-in-out infinite; }

.ambient-lantern { position: absolute; z-index: 1; top: 0; width: 80px; height: 250px; transform-origin: top center; animation: lantern-sway 5s ease-in-out infinite; }
.ambient-lantern i { position: absolute; top: 0; left: 50%; width: 1px; height: 150px; background: linear-gradient(#7d531f, var(--gold)); }
.ambient-lantern span { position: absolute; top: 145px; left: 50%; width: 45px; height: 65px; border: 3px double var(--gold-deep); border-radius: 13px 13px 22px 22px; background: radial-gradient(circle, #ffe9a4, #cc7d2c 35%, rgba(66,3,3,.5) 70%); box-shadow: 0 0 46px rgba(255,190,83,.35); transform: translateX(-50%); }
.lantern-left { left: 7vw; }
.lantern-right { right: 7vw; animation-delay: -2.2s; }

.event-section {
  --event-text: var(--ivory);
  --event-muted: var(--champagne);
  color: var(--event-text);
  background:
    radial-gradient(circle at 50% 48%, rgba(190,120,42,.14), transparent 27%),
    linear-gradient(145deg, #170203, #480608 49%, #150203);
}

.mehndi-section {
  background:
    radial-gradient(circle at 20% 20%, rgba(218,142,31,.2), transparent 29%),
    radial-gradient(circle at 82% 76%, rgba(217,111,16,.13), transparent 34%),
    linear-gradient(145deg, #210701, #551608 50%, #180301);
}

.barat-section {
  background:
    linear-gradient(115deg, transparent 46%, rgba(216,181,106,.05) 46% 54%, transparent 54%),
    radial-gradient(circle at 50% 50%, #690b10 0, #350307 46%, #120203 86%);
}

.walima-section {
  background:
    radial-gradient(circle at 50% 42%, rgba(255,244,216,.78), rgba(222,196,147,.25) 34%, transparent 55%),
    linear-gradient(145deg, #320407, #6c1113 50%, #1b0305);
}

.event-section::before, .event-section::after {
  position: absolute;
  z-index: 0;
  width: min(48vw, 650px);
  aspect-ratio: 1;
  border: 1px solid rgba(216,181,106,.12);
  content: "";
  transform: rotate(45deg);
}
.event-section::before { top: -27%; left: -18%; }
.event-section::after { right: -18%; bottom: -27%; }

.event-number {
  position: absolute;
  z-index: 0;
  right: -2vw;
  bottom: -8vh;
  color: rgba(216,181,106,.055);
  font-size: clamp(17rem, 42vw, 42rem);
  font-weight: 400;
  letter-spacing: -.13em;
  line-height: .68;
  pointer-events: none;
}

.event-curtain {
  position: absolute;
  z-index: 6;
  top: 0;
  bottom: 0;
  width: 50.5%;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(255,223,159,.08), transparent 18%, rgba(0,0,0,.2) 78%, rgba(0,0,0,.56)),
    repeating-linear-gradient(90deg, #160103 0 6%, #4d080d 10%, #74151a 15%, #310408 21%, #641016 27%, #240205 33%);
  box-shadow: inset 0 0 0 1px rgba(216,181,106,.22), inset 0 0 90px rgba(0,0,0,.58), 0 0 42px rgba(0,0,0,.42);
  transition: transform 2.75s var(--ease-royal) .48s, filter 2.6s ease .48s;
  pointer-events: none;
}
.event-curtain::before {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 9px;
  background: linear-gradient(90deg, #704017, var(--gold-bright), #7d4a1b);
  box-shadow: 0 0 18px rgba(216,181,106,.5), inset 0 0 0 2px rgba(37,9,4,.42);
  content: "";
}
.event-curtain::after {
  position: absolute;
  top: 53%;
  width: 44px;
  height: 70px;
  border: 1px solid var(--gold-bright);
  border-radius: 52% 52% 62% 62%;
  background:
    radial-gradient(circle at 50% 22%, var(--gold-bright) 0 5px, #714114 6px 8px, transparent 9px),
    repeating-linear-gradient(100deg, #b48737 0 2px, #f1d894 2px 4px, #72501f 4px 6px);
  box-shadow: 0 8px 22px rgba(0,0,0,.48), 0 0 18px rgba(216,181,106,.3);
  clip-path: polygon(12% 0,88% 0,76% 34%,100% 100%,52% 78%,0 100%,24% 34%);
  content: "";
}
.curtain-left { left: 0; transform-origin: left center; }
.curtain-right { right: 0; transform-origin: right center; }
.curtain-left::before { right: 0; }
.curtain-right::before { left: 0; transform: scaleX(-1); }
.curtain-left::after { right: 15%; }
.curtain-right::after { left: 15%; transform: scaleX(-1); }
.event-section.is-revealed .curtain-left { transform: translateX(-78%) scaleX(.5) skewY(-1.2deg); filter: brightness(.82); }
.event-section.is-revealed .curtain-right { transform: translateX(78%) scaleX(.5) skewY(1.2deg); filter: brightness(.82); }

.curtain-valance {
  position: absolute;
  z-index: 7;
  top: 0;
  right: 0;
  left: 0;
  height: clamp(105px, 18vh, 175px);
  background:
    radial-gradient(ellipse at 12.5% -8%, #75141a 0 52%, transparent 53%),
    radial-gradient(ellipse at 37.5% -8%, #4f080e 0 52%, transparent 53%),
    radial-gradient(ellipse at 62.5% -8%, #75141a 0 52%, transparent 53%),
    radial-gradient(ellipse at 87.5% -8%, #4f080e 0 52%, transparent 53%),
    repeating-linear-gradient(90deg, #210204 0 5%, #6d1117 11%, #2a0306 18%);
  border-bottom: 2px solid rgba(241,216,148,.78);
  box-shadow: inset 0 -28px 50px rgba(0,0,0,.38), 0 15px 40px rgba(0,0,0,.42), 0 2px 0 #6b4318;
  clip-path: polygon(0 0,100% 0,100% 61%,93% 82%,87% 61%,81% 86%,75% 62%,69% 88%,63% 63%,56% 86%,50% 64%,44% 86%,37% 63%,31% 88%,25% 62%,19% 86%,13% 61%,7% 82%,0 61%);
  transition: transform 2.25s var(--ease-royal) .65s, opacity 1.8s ease .65s;
  pointer-events: none;
}
.curtain-valance::before { position: absolute; right: 0; bottom: 17%; left: 0; height: 1px; background: linear-gradient(90deg, transparent 2%, var(--gold) 15% 85%, transparent 98%); content: ""; }
.curtain-valance span {
  position: absolute;
  bottom: 10%;
  left: 50%;
  display: grid;
  width: 42px;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid var(--gold-bright);
  border-radius: 50%;
  background: radial-gradient(circle, #621116, #210204 72%);
  color: var(--gold-bright);
  font-size: .72rem;
  transform: translate(-50%,50%);
  box-shadow: 0 0 0 5px rgba(31,2,4,.78), 0 0 0 6px rgba(216,181,106,.42), 0 8px 26px rgba(0,0,0,.52);
}
.event-section.is-revealed .curtain-valance { opacity: .84; transform: translateY(-63%); }

.event-sparkles { position: absolute; inset: 0; z-index: 3; opacity: 0; transition: opacity 1.2s ease 3s; pointer-events: none; }
.event-section.is-revealed .event-sparkles { opacity: .72; }
.event-sparkles span { position: absolute; color: var(--gold-bright); font-size: .72rem; text-shadow: 0 0 15px rgba(216,181,106,.75); animation: star-glow 3s ease-in-out infinite; }
.event-sparkles span:nth-child(1) { top: 18%; left: 15%; }
.event-sparkles span:nth-child(2) { top: 22%; right: 14%; animation-delay: -.8s; }
.event-sparkles span:nth-child(3) { bottom: 17%; left: 18%; animation-delay: -1.5s; }
.event-sparkles span:nth-child(4) { right: 17%; bottom: 14%; animation-delay: -2.1s; }

.side-inscription {
  position: absolute;
  z-index: 2;
  left: clamp(22px, 4vw, 65px);
  top: 50%;
  display: flex;
  align-items: center;
  gap: 14px;
  color: rgba(231,206,160,.55);
  transform: translate(-50%,-50%) rotate(-90deg);
  transform-origin: center;
}
.side-inscription span { color: var(--gold); font-size: .8rem; }
.side-inscription i { width: 60px; height: 1px; background: rgba(216,181,106,.45); }
.side-inscription b { font-size: .5rem; font-weight: 400; letter-spacing: .27em; white-space: nowrap; }

.event-card {
  position: relative;
  z-index: 4;
  display: grid;
  justify-items: center;
  width: min(720px, 84vw);
  padding: clamp(42px, 6vw, 72px) clamp(26px, 6vw, 76px);
  border: 1px solid rgba(216,181,106,.48);
  background: linear-gradient(145deg, rgba(30,2,4,.86), rgba(72,7,10,.73));
  box-shadow: inset 0 0 0 7px rgba(216,181,106,.035), 0 38px 100px rgba(0,0,0,.4);
  text-align: center;
  backdrop-filter: blur(12px);
}
.event-card::before, .event-card::after { position: absolute; width: 48px; height: 48px; content: ""; }
.event-card::before { top: 9px; left: 9px; border-top: 2px solid var(--gold); border-left: 2px solid var(--gold); }
.event-card::after { right: 9px; bottom: 9px; border-right: 2px solid var(--gold); border-bottom: 2px solid var(--gold); }

.event-motif {
  position: relative;
  display: grid;
  width: clamp(74px, 9vw, 102px);
  aspect-ratio: 1;
  place-items: center;
  margin-bottom: 19px;
  border: 1px solid rgba(216,181,106,.55);
  border-radius: 50%;
  color: var(--gold);
  transform: scale(.7) rotate(-22deg);
  transition: transform 1.2s var(--ease-royal) 1.15s;
}
.event-section.is-revealed .event-motif { transform: scale(1) rotate(0); }
.event-motif::before, .event-motif::after { position: absolute; inset: -8px; border: 1px dotted rgba(216,181,106,.34); border-radius: 50%; content: ""; }
.event-motif::after { inset: 10px; border-style: solid; }
.event-motif span { position: relative; z-index: 1; font-size: 1rem; letter-spacing: .06em; }
.mehndi-motif::before { border-radius: 36% 64% 42% 58%; transform: rotate(20deg); }
.barat-motif { border-radius: 50% 50% 8px 8px / 40% 40% 8px 8px; }
.walima-motif { box-shadow: 0 0 40px rgba(247,240,228,.22); }

.event-chapter, .event-overline, .event-signature, .advance-note { text-transform: uppercase; letter-spacing: .23em; }
.event-chapter { margin: 0 0 14px; color: var(--gold-bright); font-size: .72rem; font-weight: 600; }
.event-overline { margin: 0; color: var(--event-muted); font-size: clamp(.72rem, 1vw, .86rem); font-weight: 600; line-height: 1.55; }
.event-card h2 { margin: 13px 0 6px; font-size: clamp(4.4rem, 12vw, 9rem); font-weight: 400; line-height: .72; letter-spacing: -.07em; }

.event-date { overflow: hidden; margin: 15px 0 23px; }
.event-date time { display: flex; align-items: flex-end; gap: 14px; transform: translateY(110%); transition: transform 1.05s var(--ease-royal) 2.95s; }
.event-section.is-revealed .event-date time { transform: translateY(0); }
.event-date strong { color: var(--gold); font-size: clamp(2.2rem, 5vw, 3.8rem); font-weight: 400; line-height: .78; }
.event-date span { padding-bottom: 3px; border-bottom: 1px solid rgba(216,181,106,.5); color: var(--champagne); font-size: clamp(.72rem, 1.4vw, 1rem); letter-spacing: .2em; text-transform: uppercase; }
.event-copy { margin: 0; color: rgba(247,240,228,.92); font-size: clamp(.92rem, 1.35vw, 1.08rem); line-height: 1.7; }
.event-signature { display: flex; align-items: center; gap: 12px; margin-top: 24px; color: var(--gold-bright); font-size: .68rem; font-weight: 600; }
.event-signature i { width: 35px; height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.event-signature i:last-child { transform: rotate(180deg); }
.advance-note { display: flex; align-items: center; gap: 8px; margin: 27px 0 -10px; color: rgba(247,240,228,.75); font-size: .64rem; font-weight: 600; }
.advance-note span { width: 5px; height: 5px; border-radius: 50%; background: var(--gold); animation: advance-pulse 1.5s ease infinite; }

.venue-section {
  padding: 80px 24px;
  background:
    linear-gradient(90deg, rgba(15,1,2,.9), rgba(36,3,5,.58) 50%, rgba(15,1,2,.9)),
    linear-gradient(180deg, rgba(18,2,3,.36), rgba(18,2,3,.7)),
    url("assets/palace-courtyard.webp") center / cover no-repeat;
}

.venue-glow {
  position: absolute;
  top: 50%;
  left: 50%;
  width: min(760px, 90vw);
  height: min(760px, 90vw);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(216,181,106,.24), transparent 66%);
  transform: translate(-50%,-50%);
  animation: halo-pulse 4.5s ease-in-out infinite;
}

.venue-stars span { position: absolute; color: rgba(231,206,160,.48); animation: star-glow 2.8s ease-in-out infinite; }
.venue-stars span:nth-child(1) { top: 16%; left: 18%; }
.venue-stars span:nth-child(2) { top: 27%; right: 16%; animation-delay: -.8s; }
.venue-stars span:nth-child(3) { bottom: 20%; left: 23%; animation-delay: -1.6s; }
.venue-stars span:nth-child(4) { right: 24%; bottom: 13%; animation-delay: -.3s; }
.venue-stars span:nth-child(5) { top: 12%; left: 51%; animation-delay: -2.1s; }

.venue-card {
  position: relative;
  z-index: 2;
  width: min(720px, 88vw);
  padding: clamp(54px, 7vw, 84px) clamp(27px, 7vw, 80px);
  border: 1px solid rgba(216,181,106,.63);
  border-radius: 48% 48% 4px 4px / 12% 12% 4px 4px;
  background: linear-gradient(145deg, rgba(49,4,7,.94), rgba(14,2,3,.94));
  box-shadow: inset 0 0 0 8px rgba(216,181,106,.04), 0 40px 120px rgba(0,0,0,.58);
  text-align: center;
  backdrop-filter: blur(16px);
}
.venue-card::before { position: absolute; inset: 13px; border: 1px solid rgba(216,181,106,.16); border-radius: inherit; content: ""; pointer-events: none; }
.venue-card::after { position: absolute; top: 25px; left: 50%; color: rgba(241,216,148,.8); font-size: 1.28rem; content: "❦"; transform: translateX(-50%); text-shadow: 0 0 18px rgba(216,181,106,.42); }
.venue-pin { display: inline-grid; width: 56px; aspect-ratio: 1; place-items: center; border: 1px solid var(--gold); border-radius: 50% 50% 50% 4px; color: var(--gold); transform: rotate(-45deg); }
.venue-pin span { transform: rotate(45deg); }
.venue-card h2 { margin: 25px 0 16px; font-size: clamp(3rem, 8vw, 6.3rem); font-weight: 400; line-height: .84; letter-spacing: -.05em; }
.venue-card address { color: var(--gold-bright); font-size: clamp(.78rem, 1.3vw, .96rem); font-style: normal; font-weight: 600; letter-spacing: .18em; text-transform: uppercase; }
.venue-card address i { padding: 0 5px; }
.venue-copy { margin: 26px 0; color: rgba(247,240,228,.9); font-size: clamp(.9rem, 1.3vw, 1.05rem); line-height: 1.7; }
.map-button { display: inline-flex; align-items: center; gap: 18px; padding: 14px 20px 14px 24px; border: 1px solid rgba(216,181,106,.68); background: rgba(216,181,106,.08); color: var(--ivory); font-size: .72rem; font-weight: 600; letter-spacing: .18em; text-decoration: none; text-transform: uppercase; transition: background .3s ease, color .3s ease, transform .3s ease; }
.map-button:hover { background: var(--gold); color: var(--black-cherry); transform: translateY(-3px); }
.map-button i { font-size: .9rem; font-style: normal; }
.venue-placeholder { margin: 19px 0 0; color: rgba(247,240,228,.68); font-size: .68rem; line-height: 1.45; letter-spacing: .06em; }

.closing-section {
  position: relative;
  display: grid;
  min-height: 92vh;
  min-height: 92svh;
  place-items: center;
  overflow: hidden;
  padding: 90px 24px 110px;
  background:
    radial-gradient(circle at 50% 34%, rgba(216,181,106,.16), transparent 31%),
    linear-gradient(180deg, #1b0204, #070102);
}
.closing-section::before { position: absolute; inset: 18px; border: 1px solid rgba(216,181,106,.22); content: ""; }
.closing-arch { position: absolute; top: 6%; left: 50%; width: min(720px, 88vw); height: 75%; border: 1px solid rgba(216,181,106,.15); border-radius: 50% 50% 0 0 / 28% 28% 0 0; transform: translateX(-50%); box-shadow: 0 0 0 14px rgba(216,181,106,.018), 0 0 0 30px rgba(216,181,106,.012); }
.closing-content { position: relative; z-index: 2; text-align: center; }
.closing-content > p:first-child { margin: 0 0 22px; color: var(--gold-bright); font-size: .74rem; font-weight: 600; letter-spacing: .24em; text-transform: uppercase; }
.closing-content h2 { margin: 0; font-size: clamp(3rem, 8vw, 6.6rem); font-weight: 400; line-height: .88; letter-spacing: -.05em; }
.closing-rule { display: flex; align-items: center; justify-content: center; gap: 20px; margin: 32px 0; }
.closing-rule i { width: min(120px, 20vw); height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.closing-rule i:last-child { transform: rotate(180deg); }
.closing-rule span { display: grid; width: 55px; aspect-ratio: 1; place-items: center; border: 1px solid var(--gold); border-radius: 50%; color: var(--champagne); }
.closing-message { color: rgba(247,240,228,.88); font-size: clamp(.9rem, 1.3vw, 1.06rem); line-height: 1.8; }
.closing-dates { display: block; margin-top: 28px; color: var(--gold-bright); font-size: .76rem; font-weight: 600; letter-spacing: .24em; text-transform: uppercase; }
.closing-section footer { position: absolute; z-index: 2; right: 44px; bottom: 40px; left: 44px; display: flex; justify-content: center; gap: 18px; color: rgba(247,240,228,.68); font-size: .66rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; }
.closing-section footer i { color: var(--gold); font-style: normal; }

@keyframes breathe { 50% { opacity: .35; transform: translateY(7px); } }
@keyframes dust-float { 0%, 100% { opacity: 0; transform: translate3d(0,12px,0); } 25% { opacity: .55; } 70% { opacity: .2; } 85% { opacity: 0; transform: translate3d(12px,-72px,0); } }
@keyframes lantern-sway { 0%, 100% { transform: rotate(-1.5deg); } 50% { transform: rotate(1.5deg); } }
@keyframes halo-pulse { 0%, 100% { opacity: .6; transform: translate(-50%,-50%) scale(.96); } 50% { opacity: 1; transform: translate(-50%,-50%) scale(1.04); } }
@keyframes advance-pulse { 50% { opacity: .25; box-shadow: 0 0 0 7px rgba(216,181,106,.08); } }
@keyframes star-glow { 50% { opacity: .2; transform: scale(.7); } }

@media (max-width: 680px) {
  .name-plaque { top: max(16px, env(safe-area-inset-top)); right: 50%; width: min(82vw, 380px); transform: translateX(50%); padding: 12px 16px; }
  .gate-scene.is-open .name-plaque { transform: translate(50%,-14px); }
  .gate-crown { top: 12px; padding: 10px 22px 13px; }
  .gate-frame::before { inset: 10px; }
  .frame-pillar { width: 18px; }
  .gate-door-left .door-surface { border-radius: 42% 0 0 0 / 17% 0 0 0; }
  .gate-door-right .door-surface { border-radius: 0 42% 0 0 / 0 17% 0 0; }
  .gate-scene.is-open .gate-door-left { transform: translateX(-31%) rotateY(-88deg); }
  .gate-scene.is-open .gate-door-right { transform: translateX(31%) rotateY(88deg); }
  .reveal-copy { top: 49%; width: calc(100vw - 54px); }
  .reveal-copy h1 { row-gap: .14em; margin-top: 17px; font-size: clamp(2.82rem, 13vw, 3.5rem); line-height: .86; letter-spacing: -.05em; }
  .reveal-copy h1.couple-heading .title-weds { justify-self: center; }
  .eyebrow { margin-bottom: 15px; font-size: clamp(.78rem, 3.3vw, .88rem); letter-spacing: .16em; }
  .mini-crest { width: 56px; }
  .family-line { margin: 19px 0 17px; padding: 9px 10px; font-size: clamp(.84rem, 3.45vw, .9rem); line-height: 1.55; letter-spacing: .1em; }
  .date-line { margin-top: 15px; font-size: clamp(.92rem, 4vw, 1.05rem); letter-spacing: .16em; }
  .hero-flourish { top: 72%; gap: 7px; }
  .hero-flourish-left { left: 28px; }
  .hero-flourish-right { right: 28px; }
  .hero-flourish i { height: 46px; }
  .hero-flourish b { font-size: 1.05rem; }
  .enter-button { bottom: max(76px, calc(env(safe-area-inset-bottom) + 72px)); font-size: .75rem; }
  .journey-nav {
    top: auto;
    right: max(10px, env(safe-area-inset-right));
    bottom: max(10px, env(safe-area-inset-bottom));
    left: max(10px, env(safe-area-inset-left));
    grid-template-columns: repeat(5, 1fr) 42px;
    gap: 5px;
    padding: 8px;
    border-radius: 18px;
    transform: translateY(20px);
  }
  body.invitation-open .journey-nav { transform: translateY(0); }
  .journey-line { top: 20px; right: 54px; bottom: auto; left: 25px; width: auto; height: 1px; }
  .journey-line span { width: var(--progress, 0%); height: 100%; transition: width .6s var(--ease-royal); }
  .journey-dot { justify-self: center; }
  .journey-dot:hover, .journey-dot:focus-visible { grid-template-columns: 26px; width: 26px; }
  .journey-dot small { display: none; }
  .auto-journey { margin: 0; padding: 0 0 0 6px; border-top: 0; border-left: 1px solid rgba(216,181,106,.2); }
  .ambient-lantern { opacity: .48; transform: scale(.75); }
  .lantern-left { left: -9px; }
  .lantern-right { right: -9px; }
  .welcome-section { padding: 70px 18px 100px; }
  .welcome-card { width: 94vw; padding: 62px 20px 48px; border-radius: 46% 46% 5px 5px / 10% 10% 5px 5px; }
  .section-kicker, .welcome-prelude, .welcome-family, .welcome-message { letter-spacing: .14em; }
  .section-kicker { font-size: .76rem; }
  .welcome-prelude { font-size: .74rem; }
  .welcome-family { font-size: .74rem; }
  .welcome-message { margin: 36px auto 34px; font-size: .9rem; line-height: 1.8; }
  .date-triptych small { font-size: .7rem; letter-spacing: .12em; }
  .begin-journey { font-size: .72rem; letter-spacing: .16em; }
  .welcome-message br, .event-copy br, .venue-copy br, .closing-message br { display: none; }
  .side-inscription { display: none; }
  .event-card { width: 91vw; padding: 38px 22px 40px; }
  .event-card h2 { font-size: clamp(4rem, 24vw, 6.5rem); }
  .event-number { right: -6vw; bottom: 5vh; font-size: 70vw; }
  .curtain-valance { height: 112px; }
  .event-curtain::after { top: 55%; width: 36px; height: 59px; }
  .event-chapter, .event-overline, .event-signature, .advance-note { letter-spacing: .15em; }
  .event-chapter { font-size: .72rem; }
  .event-overline { font-size: .74rem; }
  .event-copy { font-size: .92rem; }
  .event-signature { font-size: .66rem; }
  .advance-note { font-size: .63rem; }
  .advance-note { margin-top: 23px; }
  .venue-section { padding: 65px 18px 95px; }
  .venue-card { width: 93vw; padding: 58px 23px; border-radius: 44% 44% 4px 4px / 8% 8% 4px 4px; }
  .closing-section { min-height: 100svh; padding: 70px 22px 125px; }
  .closing-section footer { right: 28px; bottom: 80px; left: 28px; flex-wrap: wrap; gap: 8px 14px; }
}

@media (max-width: 820px) and (orientation: portrait) {
  .palace-view {
    background-image: url("assets/palace-courtyard-mobile.webp");
    background-position: center 47%;
    background-size: cover;
  }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
  .gold-dust { display: none; }
  .auto-journey { opacity: .45; cursor: not-allowed; }
}

/* Design 3 — illustrated royal journey */
:root { --ease-silk: cubic-bezier(.16, 1, .3, 1); }

.couple-reveal {
  position: absolute;
  z-index: 0;
  right: clamp(42px, 5vw, 92px);
  bottom: -7vh;
  width: min(44vw, 650px);
  height: min(94vh, 900px);
  margin: 0;
  opacity: 0;
  pointer-events: none;
  transform: translate3d(44px, 34px, 0) scale(.95);
  transition: opacity 1.35s ease 1.05s, transform 2.15s var(--ease-silk) .86s;
}

.couple-reveal::before {
  position: absolute;
  inset: 5% 1% 10%;
  border: 1px solid rgba(241, 216, 148, .32);
  border-radius: 50% 50% 13px 13px / 25% 25% 13px 13px;
  background: radial-gradient(ellipse at 50% 48%, rgba(216, 181, 106, .2), transparent 68%);
  box-shadow: 0 0 0 9px rgba(216, 181, 106, .025), 0 35px 90px rgba(0, 0, 0, .34);
  content: "";
}

.couple-reveal::after {
  position: absolute;
  inset: 0;
  background: linear-gradient(180deg, transparent 66%, rgba(19, 2, 3, .48) 88%, rgba(19, 2, 3, .92));
  content: "";
}

.couple-reveal img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center bottom;
  filter: drop-shadow(0 30px 34px rgba(0, 0, 0, .52));
}

.gate-scene.is-open .couple-reveal { opacity: 1; transform: translate3d(0, 0, 0) scale(1); }

@media (min-width: 961px) {
  .reveal-copy {
    left: 30%;
    width: min(50vw, 630px);
    justify-items: start;
    text-align: left;
  }
  .reveal-copy .royal-rule { justify-content: flex-start; }
  .reveal-copy h1 { font-size: clamp(3.1rem, 6.4vw, 6.5rem); }
  .hero-flourish-left { left: clamp(38px, 4vw, 82px); }
  .hero-flourish-right { right: clamp(32px, 3.5vw, 72px); }
}

.events-journey {
  --event-progress: 0%;
  position: relative;
  overflow: hidden;
  isolation: isolate;
  background: #120203;
}

.event-spine {
  position: absolute;
  z-index: 3;
  top: 50svh;
  left: 50%;
  width: 2px;
  height: calc(100% - 100svh);
  overflow: visible;
  background: linear-gradient(180deg, rgba(216, 181, 106, .28), rgba(216, 181, 106, .58) 50%, rgba(216, 181, 106, .28));
  box-shadow: 0 0 18px rgba(216, 181, 106, .2);
  pointer-events: none;
  transform: translateX(-50%);
}

.event-spine::before,
.event-spine::after {
  position: absolute;
  left: 50%;
  width: 9px;
  height: 9px;
  border: 1px solid var(--gold-bright);
  background: var(--black-cherry);
  content: "";
  transform: translate(-50%, -50%) rotate(45deg);
}

.event-spine::before { top: 0; }
.event-spine::after { top: 100%; }

.event-spine > span {
  display: block;
  width: 100%;
  height: var(--event-progress);
  background: linear-gradient(180deg, #fff3c9, var(--gold), #fff0bc);
  box-shadow: 0 0 12px rgba(241, 216, 148, .72);
  transition: height .12s linear;
}

.timeline-node {
  position: absolute;
  z-index: 5;
  top: 50%;
  left: 50%;
  display: grid;
  width: 70px;
  aspect-ratio: 1;
  place-items: center;
  border: 1px solid rgba(241, 216, 148, .78);
  border-radius: 50%;
  background: radial-gradient(circle, rgba(77, 8, 13, .98), rgba(19, 2, 3, .98) 70%);
  color: var(--gold-bright);
  opacity: .66;
  box-shadow: 0 0 0 8px rgba(216, 181, 106, .045), 0 14px 40px rgba(0, 0, 0, .5);
  pointer-events: none;
  transform: translate(-50%, -50%) scale(.82);
  transition: opacity .8s ease .65s, transform 1.15s var(--ease-silk) .58s, background .55s ease, color .55s ease, box-shadow .55s ease;
}

.timeline-node::before,
.timeline-node::after {
  position: absolute;
  border: 1px solid rgba(216, 181, 106, .35);
  border-radius: 50%;
  content: "";
}

.timeline-node::before { inset: 8px; }
.timeline-node::after { inset: -14px; border-style: dotted; }
.timeline-node span { font-size: .8rem; letter-spacing: .08em; }
.event-section.is-revealed .timeline-node { opacity: 1; transform: translate(-50%, -50%) scale(1); }
.timeline-node.is-passed { background: radial-gradient(circle, #f3dca7, var(--gold) 74%); color: #3c0608; box-shadow: 0 0 0 8px rgba(216, 181, 106, .08), 0 0 34px rgba(241, 216, 148, .45); }

.edge-garland {
  position: absolute;
  z-index: 2;
  top: 1.5%;
  bottom: 1.5%;
  left: clamp(24px, 3.4vw, 58px);
  display: flex;
  width: 38px;
  flex-direction: column;
  align-items: center;
  justify-content: space-around;
  color: rgba(216, 181, 106, .56);
  opacity: .62;
  pointer-events: none;
}

.edge-garland-right { right: clamp(24px, 3.4vw, 58px); left: auto; transform: scaleX(-1); }

.edge-garland::before {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 1px;
  background: linear-gradient(transparent, rgba(216, 181, 106, .48) 4% 96%, transparent);
  box-shadow: 0 0 10px rgba(216, 181, 106, .16);
  content: "";
}

.edge-garland span,
.edge-garland b,
.edge-garland i {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  background: #210305;
}

.edge-garland span { width: 34px; height: 34px; border: 1px solid rgba(216, 181, 106, .42); border-radius: 50%; font-size: 1.02rem; font-weight: 400; }
.edge-garland b { width: 24px; height: 24px; border: 1px solid rgba(216, 181, 106, .3); border-radius: 50%; font-size: .58rem; font-weight: 400; }
.edge-garland i { width: 14px; height: 28px; border: 1px solid rgba(216, 181, 106, .48); border-radius: 100% 0 100% 0; transform: rotate(45deg); box-shadow: inset 0 0 12px rgba(216, 181, 106, .12); }

.event-section {
  min-height: 100vh;
  min-height: 100svh;
  padding: clamp(84px, 10vh, 120px) clamp(80px, 7vw, 126px);
}

.event-layout {
  position: relative;
  z-index: 4;
  display: grid;
  width: min(1240px, 86vw);
  grid-template-columns: minmax(0, 1fr) 132px minmax(0, 1fr);
  align-items: center;
}

.event-layout-image-left .event-visual { grid-column: 1; }
.event-layout-image-left .event-card { grid-column: 3; }
.event-layout-image-right .event-card { grid-column: 1; }
.event-layout-image-right .event-visual { grid-column: 3; }

.event-visual {
  position: relative;
  width: 100%;
  max-width: 535px;
  margin: 0;
  opacity: 0;
  will-change: opacity, transform, clip-path;
  transition: opacity 1.05s ease .78s, transform 1.5s var(--ease-silk) .72s, clip-path 1.55s var(--ease-silk) .68s;
}

.event-layout-image-left .event-visual { clip-path: inset(12% 18% 12% 0 round 180px 180px 18px 18px); transform: translate3d(-42px, 22px, 0) scale(.94); }
.event-layout-image-right .event-visual { clip-path: inset(12% 0 12% 18% round 180px 180px 18px 18px); transform: translate3d(42px, 22px, 0) scale(.94); }

.event-section.is-revealed .event-visual { clip-path: inset(0 round 180px 180px 18px 18px); opacity: 1; transform: translate3d(0, 0, 0) scale(1); }

.event-art-frame {
  position: relative;
  aspect-ratio: 4 / 3;
  overflow: hidden;
  border: 1px solid rgba(241, 216, 148, .6);
  border-radius: 46% 46% 18px 18px / 30% 30% 18px 18px;
  background: #210305;
  box-shadow: inset 0 0 0 7px rgba(216, 181, 106, .04), 0 35px 90px rgba(0, 0, 0, .48);
}

.event-art-frame::before {
  position: absolute;
  z-index: 2;
  inset: 11px;
  border: 1px solid rgba(241, 216, 148, .22);
  border-radius: inherit;
  content: "";
  pointer-events: none;
}

.event-art-frame::after {
  position: absolute;
  z-index: 1;
  inset: 0;
  background: linear-gradient(180deg, transparent 55%, rgba(18, 2, 3, .36));
  content: "";
  pointer-events: none;
}

.event-art-frame img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transform: scale(1.075);
  transition: transform 6s var(--ease-silk) .65s;
}

.event-section.is-revealed .event-art-frame img { transform: scale(1.01); }

.event-visual figcaption {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  margin-top: 16px;
  color: rgba(231, 206, 160, .76);
  font-size: .58rem;
  font-weight: 600;
  letter-spacing: .2em;
  text-transform: uppercase;
}

.event-visual figcaption i { width: 18px; height: 1px; background: rgba(216, 181, 106, .52); }

.event-card {
  width: 100%;
  max-width: 535px;
  min-height: 0;
  padding: clamp(38px, 4.2vw, 58px) clamp(28px, 4vw, 52px);
  border-radius: 42% 42% 5px 5px / 9% 9% 5px 5px;
  background: linear-gradient(145deg, rgba(30, 2, 4, .9), rgba(72, 7, 10, .78));
  opacity: 0;
  will-change: opacity, transform;
  transition: opacity 1.05s ease .92s, transform 1.45s var(--ease-silk) .86s;
}

.event-layout-image-left .event-card { transform: translate3d(42px, 22px, 0); }
.event-layout-image-right .event-card { transform: translate3d(-42px, 22px, 0); }
.event-section.is-revealed .event-card { opacity: 1; transform: translate3d(0, 0, 0); }
.event-card h2 { font-size: clamp(4rem, 7vw, 6.8rem); }
.event-motif { width: clamp(66px, 6vw, 82px); margin-bottom: 15px; }
.event-chapter { margin-bottom: 10px; }
.event-date { margin: 12px 0 19px; }
.event-date time { transition-delay: 1.18s; }
.event-motif { transition-delay: .82s; }

.event-curtain {
  z-index: 8;
  will-change: transform;
  transition: transform 2.57s var(--ease-silk) .24s, filter 2.25s ease .24s;
}

.curtain-valance { z-index: 9; transition: transform 2s var(--ease-silk) .34s, opacity 1.6s ease .34s; }
.event-section.is-revealed .curtain-left { transform: translate3d(-83%, 0, 0) scaleX(.42) skewY(-1deg); }
.event-section.is-revealed .curtain-right { transform: translate3d(83%, 0, 0) scaleX(.42) skewY(1deg); }
.event-section.is-revealed .curtain-valance { opacity: .78; transform: translate3d(0, -67%, 0); }
.event-sparkles { z-index: 6; transition-delay: 1.55s; }

.barat-section .side-inscription { right: clamp(22px, 4vw, 65px); left: auto; transform: translate(50%, -50%) rotate(90deg); }

@media (max-width: 960px) {
  .couple-reveal {
    right: -9vw;
    bottom: -12vh;
    width: min(92vw, 590px);
    height: 73vh;
  }
  .couple-reveal::before { inset: 7% 3% 15%; }
  .couple-reveal::after { background: linear-gradient(180deg, rgba(19, 2, 3, .03), rgba(19, 2, 3, .25) 56%, rgba(19, 2, 3, .94)); }
  .gate-scene.is-open .couple-reveal { opacity: .62; }
  .reveal-copy { z-index: 2; }

  .event-spine { left: 31px; }
  .timeline-node { top: clamp(92px, 12vh, 116px); left: 31px; width: 52px; }
  .timeline-node::before { inset: 6px; }
  .timeline-node::after { inset: -8px; }
  .timeline-node span { font-size: .68rem; }

  .edge-garland-left { display: none; }
  .edge-garland-right { right: 5px; width: 25px; opacity: .25; }
  .edge-garland-right span { width: 26px; height: 26px; font-size: .76rem; }
  .edge-garland-right i { width: 10px; height: 22px; }

  .event-section { min-height: 100svh; padding: 0 17px; overflow: hidden; }
  .event-layout {
    display: flex;
    width: calc(100% - 55px);
    min-height: 100svh;
    margin-left: 48px;
    padding: 118px 0 max(120px, calc(env(safe-area-inset-bottom) + 98px));
    flex-direction: column;
    justify-content: center;
    gap: 23px;
  }
  .event-layout .event-visual { order: 1; }
  .event-layout .event-card { order: 2; }
  .event-visual,
  .event-card { width: min(100%, 590px); max-width: 590px; }
  .event-layout-image-left .event-visual,
  .event-layout-image-right .event-visual { clip-path: inset(10% 8% round 140px 140px 14px 14px); transform: translate3d(0, 28px, 0) scale(.96); }
  .event-section.is-revealed .event-visual { clip-path: inset(0 round 140px 140px 14px 14px); transform: translate3d(0, 0, 0) scale(1); }
  .event-layout-image-left .event-card,
  .event-layout-image-right .event-card { transform: translate3d(0, 28px, 0); }
  .event-section.is-revealed .event-card { transform: translate3d(0, 0, 0); }
  .event-card { padding: 40px clamp(22px, 7vw, 46px) 42px; border-radius: 38% 38% 5px 5px / 8% 8% 5px 5px; }
  .event-card h2 { font-size: clamp(4.15rem, 15vw, 6rem); }
  .event-number { right: -8vw; bottom: 7vh; font-size: clamp(17rem, 68vw, 28rem); }
  .side-inscription { display: none; }
}

@media (max-width: 560px) {
  .couple-reveal { right: -17vw; bottom: -12vh; width: 108vw; height: 72vh; }
  .gate-scene.is-open .couple-reveal { opacity: .56; }
  .event-spine { left: 27px; }
  .timeline-node { left: 27px; width: 46px; }
  .event-layout { width: calc(100% - 48px); margin-left: 42px; padding-top: 104px; gap: 18px; }
  .event-art-frame { border-radius: 41% 41% 13px 13px / 24% 24% 13px 13px; }
  .event-visual figcaption { gap: 6px; margin-top: 12px; font-size: .5rem; letter-spacing: .13em; }
  .event-visual figcaption i { width: 10px; }
  .event-card { padding: 36px 19px 38px; }
  .event-card h2 { font-size: clamp(3.8rem, 19vw, 5.2rem); }
  .event-copy { font-size: .9rem; }
  .event-signature { font-size: .61rem; }
  .advance-note { font-size: .59rem; }
  .edge-garland-right { right: 1px; }
}

@media (max-height: 620px) and (orientation: landscape) {
  .couple-reveal { right: 2vw; bottom: -18vh; width: 43vw; height: 98vh; }
  .gate-scene.is-open .couple-reveal { opacity: .62; }
  .reveal-copy { left: 29%; width: 54vw; justify-items: start; text-align: left; }
  .reveal-copy .royal-rule { justify-content: flex-start; }
}
