/* Mayur Vatika v3 — royal maroon & gold, 3D/painted look, full-width responsive */
:root {
  --maroon: #4c110c;
  --maroon-2: #651812;
  --maroon-3: #310a07;
  --maroon-4: #210604;
  --gold: #c9973f;
  --gold-hi: #f6d58b;
  --gold-text: #f7c46c;
  --cream: #fbeedb;
  --cream-2: #f4dfc0;
  --ink: #361e1c;
  --ink-soft: #6c504e;
  --display: 'Fraunces', 'Cormorant Garamond', Georgia, serif;
  --serif: 'Cormorant Garamond', Georgia, serif;
  --script: 'Great Vibes', cursive;
  --deva: 'Tiro Devanagari Hindi', serif;
  --sans: 'Mulish', system-ui, sans-serif;
  --vw: 100vw;
  --gold-grad: linear-gradient(180deg, #fff0b8 0%, #e2b04c 30%, #a86f1c 62%, #f0c86a 100%);
  --cusp: polygon(16px 0, calc(100% - 16px) 0, 100% 50%, calc(100% - 16px) 100%, 16px 100%, 0 50%);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  background: var(--cream);
  color: var(--ink);
  font-family: var(--serif);
  font-variant-numeric: lining-nums;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
button { font: inherit; cursor: pointer; }
.slot { display: block; width: 100%; height: 100%; }
/* low specificity so positioned slots (.door-top, .door-bottom…) keep their own size */
.slot svg, img:where(.slot) { display: block; width: 100%; height: 100%; object-fit: contain; }
.only-wide { display: none !important; }
.wrap { max-width: 760px; margin: 0 auto; }

/* ---------- surfaces ---------- */
.maroon {
  background-color: var(--maroon-3);
  background-image: var(--damask-maroon), radial-gradient(ellipse at 50% 0%, var(--maroon-2), var(--maroon-3) 70%);
  background-size: 120px 140px, 100% 100%;
}
.cream {
  background-color: var(--cream);
  background-image: var(--paper), var(--damask-cream), linear-gradient(180deg, #fdf3e3, var(--cream) 50%, var(--cream-2));
  background-size: 300px 300px, 120px 140px, 100% 100%;
}

/* ---------- plaque button (cusped ends, gold rim) ---------- */
.btn-plaque {
  position: relative;
  border: 0;
  padding: 0;
  background: transparent;
  -webkit-appearance: none;
  appearance: none;
  isolation: isolate;
  -webkit-tap-highlight-color: transparent;
  transition: transform .2s ease;
}
/* gold rim */
.btn-plaque::before { content: ''; position: absolute; inset: 0; background: var(--gold-grad); clip-path: var(--cusp); }
/* shadow/glow: a same-shaped layer behind (no CSS filter, so Safari draws no box) */
.btn-plaque::after {
  content: '';
  position: absolute;
  inset: 3px -2px -5px;
  z-index: -1;
  clip-path: var(--cusp);
  background: rgba(41, 6, 3, .35);
  transition: background .3s ease, inset .3s ease;
}
.btn-plaque:hover::after { background: rgba(41, 6, 3, .45); inset: 5px -3px -7px; }
.btn-plaque:focus { outline: none; }
.btn-plaque:focus-visible span { box-shadow: inset 0 0 0 2px var(--gold-hi); }
.btn-plaque span {
  position: relative;
  display: block;
  margin: 2.5px;
  padding: 12px 40px;
  clip-path: var(--cusp);
  background: linear-gradient(180deg, #7c1f19 0%, var(--maroon) 55%, var(--maroon-3) 100%);
  color: var(--gold-hi);
  font-family: var(--display);
  font-weight: 600;
  font-size: 18px;
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, .25);
}
.btn-plaque:hover { transform: translateY(-1px); }
.btn-plaque:active { transform: translateY(1px); }
.btn-plaque.wide { justify-self: center; }
.btn-plaque:disabled { opacity: .6; }

/* ---------- stage: sticky hero + doors, opened by scrolling ---------- */
.runway { position: relative; height: 100vh; height: 100svh; }
/* page is locked on the invitation card until the guest taps to open */
body.locked { overflow: hidden; height: 100vh; height: 100dvh; touch-action: none; }
.stage { position: sticky; top: 0; height: 100vh; height: 100svh; overflow: hidden; background: var(--maroon-3); }
.hero { position: absolute; inset: 0; overflow: hidden; }
.hero-art { position: absolute; inset: -3% 0 0; will-change: transform; transform: scale(1.04); }
.hero-art .slot svg, .hero-art img.slot { object-fit: cover; }
.hero-art::after { content: ''; position: absolute; inset: 0; background: #2a0b1c; opacity: .35; pointer-events: none; }
body.opened .hero-art::after { animation: dusk 3s cubic-bezier(.2, .7, .2, 1) forwards; }
@keyframes dusk { to { opacity: 0; } }
.hero-names {
  position: absolute;
  top: 7%;
  left: 0;
  right: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  font-family: var(--display);
  font-style: italic;
  font-weight: 600;
  font-size: clamp(46px, 13vw, 62px);
  line-height: 1.02;
  color: var(--maroon);
  text-shadow: 0 2px 14px rgba(255, 240, 225, .7);
  z-index: 2;
}
.hero-names .amp { font-family: var(--script); font-style: normal; font-size: .5em; color: var(--maroon-2); margin: 2px 0; }
.hero-names span { opacity: 0; }
body.opened .hero-names span { animation: rise 1.4s cubic-bezier(.2, .8, .2, 1) both; }
body.opened .hero-names span:nth-child(2) { animation-delay: .3s; }
body.opened .hero-names span:nth-child(3) { animation-delay: .6s; }
@keyframes rise { from { opacity: 0; transform: translateY(24px); filter: blur(5px); } to { opacity: 1; } }

.gate { position: absolute; inset: 0; z-index: 5; perspective: 1400px; --p: 0; }
.gate.gone { visibility: hidden; }
.door {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50.5%;
  transform-style: preserve-3d;
  will-change: transform;
}
.door-l { left: 0; transform-origin: left center; transform: rotateY(calc(var(--p) * -108deg)); }
.door-r { right: 0; transform-origin: right center; transform: rotateY(calc(var(--p) * 108deg)); }
.door-face {
  position: absolute;
  inset: 0;
  background-color: var(--maroon);
  background-image:
    linear-gradient(90deg, rgba(0, 0, 0, .35), transparent 12%, transparent 88%, rgba(0, 0, 0, .35)),
    var(--paper), var(--damask-maroon),
    radial-gradient(ellipse at 50% 40%, #601712, var(--maroon) 55%, var(--maroon-3));
  background-size: 100% 100%, 300px 300px, 120px 140px, 100% 100%;
  box-shadow: inset 0 0 0 3px #210604, inset 0 0 0 6px rgba(201, 151, 63, .55), inset 0 0 0 8px #210604, inset 0 0 70px rgba(0, 0, 0, .55);
  backface-visibility: hidden;
}
.door-l .door-face { border-right: 2px solid #160403; }
.door-r .door-face { border-left: 2px solid #160403; }
.door-edge { position: absolute; top: 0; bottom: 0; width: 18px; background: linear-gradient(90deg, #210604, #57120d, #210604); }
.door-l .door-edge { right: 0; transform-origin: right center; transform: rotateY(-90deg); }
.door-r .door-edge { left: 0; transform-origin: left center; transform: rotateY(90deg); }
.door-top { position: absolute; top: 4%; width: 84%; height: 20%; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, .35)); }
.door-l .door-top { left: 8%; }
.door-r .door-top { right: 8%; transform: scaleX(-1); }
.door-bottom { position: absolute; bottom: 4%; width: 84%; height: 24%; left: 8%; filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .45)); }
.door-r .door-bottom { transform: scaleX(-1); } /* elephants face the centre */
.hero-art img.slot { object-position: 50% 40%; }
.door-ring {
  position: absolute;
  top: 50%;
  width: 26px;
  height: 26px;
  margin-top: 90px;
  border-radius: 50%;
  border: 4px solid #d9a548;
  box-shadow: 0 2px 4px rgba(0, 0, 0, .6), inset 0 1px 2px rgba(255, 255, 255, .5);
}
.door-l .door-ring { right: 14px; }
.door-r .door-ring { left: 14px; }

/* the invitation sash across both doors (vertical panel on desktop) */
.gate-card {
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  z-index: 3;
  padding: 34px 28px 26px;
  text-align: center;
  background-color: var(--cream);
  background-image: var(--paper), var(--damask-cream), radial-gradient(ellipse at center, #fff8ea 0%, var(--cream) 60%, var(--cream-2) 100%);
  background-size: 300px 300px, 120px 140px, 100% 100%;
  box-shadow: 0 30px 50px rgba(0, 0, 0, .6), 0 -20px 40px rgba(0, 0, 0, .35);
  opacity: clamp(0, calc(1 - var(--p) * 2.4), 1);
  transform: translateY(-50%) scale(calc(1 + var(--p) * .12));
}
.gate-card::before, .gate-card::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  height: 14px;
  background: linear-gradient(180deg, #7c1f19, var(--maroon) 60%, var(--maroon-3));
  box-shadow: 0 0 0 1px #210604;
}
.gate-card::before { top: -14px; }
.gate-card::after { bottom: -14px; transform: scaleY(-1); }
.om { font-family: var(--deva); font-size: 56px; line-height: 1; color: #a8742a; text-shadow: 0 1px 0 #fff, 0 2px 6px rgba(168, 116, 42, .4); }
.gate-kalash { width: 80px; height: 90px; margin: 0 auto; }
.mantra { font-family: var(--deva); color: #8a5a22; font-size: 22px; margin: 10px 0 12px; }
.intro { font-family: var(--display); font-size: 18px; line-height: 1.45; color: #8a5a22; margin: 0 auto 22px; font-weight: 600; max-width: 290px; }
#openBtn::after { animation: glow 2.4s ease-in-out infinite; }
@keyframes glow { 50% { background: rgba(246, 213, 139, .75); inset: -4px -8px -8px; } }

/* ---------- music ---------- */
.music-btn {
  position: fixed;
  top: max(12px, env(safe-area-inset-top));
  right: 12px;
  z-index: 60;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 0;
  background: rgba(255, 252, 245, .92);
  color: var(--maroon);
  display: grid;
  place-items: center;
  box-shadow: 0 4px 14px rgba(0, 0, 0, .25);
}
.music-btn svg { width: 20px; height: 20px; fill: currentColor; }
.music-btn .wave { opacity: .25; }
.music-btn.on .wave { opacity: 1; animation: wave 1.4s ease-in-out infinite; }
@keyframes wave { 50% { opacity: .35; } }

/* ---------- content ---------- */
.content { position: relative; overflow: clip; }
section { position: relative; text-align: center; }
[data-reveal] { opacity: 0; transform: translateY(44px); transition: opacity .9s cubic-bezier(.215, .61, .355, 1), transform .9s cubic-bezier(.215, .61, .355, 1); }
[data-reveal].is-in { opacity: 1; transform: none; }

.h2 { font-family: var(--display); font-weight: 600; font-size: 34px; margin: 0 0 26px; }
.h2.light { color: var(--gold-text); text-shadow: 0 2px 8px rgba(0, 0, 0, .4); }
.h2.dark { color: var(--maroon); }

/* scrolls */
.families { padding: 50px 0 30px; }
.scroll { width: calc(100% - 64px); max-width: 760px; margin: 0 auto 34px; position: relative; }
.rod {
  position: relative;
  height: 28px;
  margin: 0 -4px;
  border-radius: 14px;
  background: linear-gradient(180deg, #310a07 0%, #721e18 30%, #aa3f37 45%, #651812 65%, #310a07 100%);
  z-index: 2;
}
.rod::before, .rod::after, .rod i::before, .rod i::after { content: ''; position: absolute; top: 50%; }
.rod::before, .rod::after { width: 18px; height: 34px; margin-top: -17px; border-radius: 4px; background: linear-gradient(180deg, #7a4a10, #f6d58b 35%, #c08a2c 60%, #6b3f0c); }
.rod::before { left: -6px; }
.rod::after { right: -6px; }
.rod i::before, .rod i::after { width: 16px; height: 24px; margin-top: -12px; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #fff2c0, #e0aa48 40%, #8a5512 85%); }
.rod i::before { left: -20px; }
.rod i::after { right: -20px; }
.sheet {
  position: relative;
  margin: -8px 12px;
  padding: 50px 22px 30px;
  background-color: var(--maroon);
  background-image:
    linear-gradient(180deg, rgba(0, 0, 0, .45), transparent 9%, transparent 91%, rgba(0, 0, 0, .45)),
    var(--paper),
    radial-gradient(ellipse at 50% 45%, #6d1913 0%, var(--maroon) 50%, var(--maroon-3) 100%);
  background-size: 100% 100%, 300px 300px, 100% 100%;
  color: var(--gold-text);
}
.sheet::before { content: ''; position: absolute; inset: 8px; border-left: 3px dotted rgba(246, 196, 108, .55); border-right: 3px dotted rgba(246, 196, 108, .55); pointer-events: none; }
.sheet h3 { font-family: var(--display); font-weight: 600; font-size: 27px; margin: 0 0 16px; color: #ffcf7a; }
.sheet .rel { font-family: var(--display); font-size: 17px; margin: 18px 0 4px; color: #f0b866; font-weight: 500; }
.sheet .who { font-family: var(--display); font-size: 19px; font-weight: 600; line-height: 1.3; margin: 0; color: #ffd185; }
.sheet .and { font-weight: 500; }
.sheet ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; font-family: var(--display); font-weight: 600; font-size: 17px; color: #ffd185; }
.sheet-orn { width: 230px; margin: 28px auto 0; }

/* unrolling: --u 0 = rolled shut, 1 = fully open (set from JS) */
.scroll { --u: 0; --sh: 400px; }
.scroll .sheet { clip-path: inset(0 0 calc((1 - var(--u)) * 100%) 0); }
.scroll .sheet-body { opacity: clamp(0, calc(var(--u) * 1.6 - .5), 1); transform: translateY(calc((1 - var(--u)) * -24px)); }
.scroll .rod-bottom { transform: translateY(calc((var(--u) - 1) * (var(--sh) - 16px))); }

/* scroll shadows without filters: rods cast their own soft shadow, and a
   separate shadow plate grows with the unrolled sheet (no flicker, no cut) */
.scroll .rod { box-shadow: 0 6px 10px -2px rgba(39, 6, 3, .35), 0 14px 24px -8px rgba(39, 6, 3, .25); }
.scroll::before {
  content: '';
  position: absolute;
  left: 18px;
  right: 18px;
  top: 14px;
  height: calc(var(--u) * (var(--sh) - 16px));
  border-radius: 6px;
  box-shadow: 0 22px 40px -10px rgba(39, 6, 3, .45), 0 6px 14px rgba(39, 6, 3, .18);
  pointer-events: none;
}
.scroll .rod-bottom { will-change: transform; }

/* floral ornament hanging from the bottom rod; travels down with it and
   blooms in as the scroll opens */
.scroll.has-orn { margin-bottom: 150px; }
.scroll-orn {
  position: absolute;
  left: 50%;
  top: 100%;
  width: 104px;
  margin: -4px 0 0 -52px;
  opacity: clamp(0, calc(var(--u) * 2 - 1), 1);
  transform: scale(calc(.6 + var(--u) * .4));
  transform-origin: 50% 0;
  filter: drop-shadow(0 6px 8px rgba(39, 6, 3, .25));
  pointer-events: none;
}
/* the bottom rod's surface turns as it rolls */
.scroll .rod-bottom {
  background:
    repeating-linear-gradient(180deg, rgba(255, 255, 255, 0) 0 5px, rgba(255, 255, 255, .10) 5px 7px) 0 calc(var(--u) * 140px) / 100% 14px,
    linear-gradient(180deg, #310a07 0%, #721e18 30%, #aa3f37 45%, #651812 65%, #310a07 100%);
}

/* date */
.date { padding: 0 0 4px; overflow: hidden; }
.strip { height: 22px; background-image: var(--strip); background-size: 34px 22px; border-top: 1px solid rgba(201, 151, 63, .4); border-bottom: 1px solid rgba(201, 151, 63, .4); background-color: rgba(246, 222, 190, .6); }
.date-top { width: 150px; margin: 30px auto 6px; filter: drop-shadow(0 8px 10px rgba(61, 22, 19, .25)); }
.date-row { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; margin: 0 auto 40px; max-width: 1000px; }
.date-side { height: 120px; margin: 0 -24px; filter: drop-shadow(0 8px 8px rgba(0, 0, 0, .25)); }
.date-side { position: relative; z-index: 2; }
.date-side.flip { transform: scaleX(-1); }
.plaques { position: relative; z-index: 1; }
.plaques { display: flex; gap: 8px; justify-content: center; margin-bottom: 18px; perspective: 600px; }
.plaque {
  position: relative;
  width: 82px;
  height: 66px;
  display: grid;
  place-items: center;
  background: linear-gradient(180deg, #7c1f19, var(--maroon) 60%, var(--maroon-3));
  --m: radial-gradient(circle 10px at 0 0, #0000 98%, #000) top left / 51% 51% no-repeat,
    radial-gradient(circle 10px at 100% 0, #0000 98%, #000) top right / 51% 51% no-repeat,
    radial-gradient(circle 10px at 0 100%, #0000 98%, #000) bottom left / 51% 51% no-repeat,
    radial-gradient(circle 10px at 100% 100%, #0000 98%, #000) bottom right / 51% 51% no-repeat;
  -webkit-mask: var(--m);
  mask: var(--m);
  box-shadow: inset 0 0 0 2px rgba(246, 196, 108, .5), inset 0 2px 0 rgba(255, 255, 255, .2);
  margin-top: 10px;
}
.plaque .tab { position: absolute; top: 4px; font-family: var(--sans); font-size: 9px; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--maroon); background: var(--cream); padding: 2px 8px; border-radius: 8px; }
.plaque .v { font-family: var(--display); font-weight: 700; font-size: 26px; color: var(--gold-hi); margin-top: 12px; }
/* reveal: the plaque glows, then the number rises out of it, blurred to sharp */
.plaque { overflow: hidden; }
.plaque .v { display: inline-block; opacity: 0; transform: translateY(70%) scale(.7); filter: blur(6px); }
.plaque.lit { animation: plaqueGlow 1.4s ease-out both; }
.plaque.lit .v { animation: numRise 1.1s cubic-bezier(.2, 1.3, .35, 1) .25s both; }
@keyframes plaqueGlow {
  0% { box-shadow: inset 0 0 0 2px rgba(246, 196, 108, .5); }
  35% { box-shadow: inset 0 0 0 2px var(--gold-hi), inset 0 0 40px rgba(255, 214, 120, .65); }
  100% { box-shadow: inset 0 0 0 2px rgba(246, 196, 108, .5), inset 0 0 14px rgba(255, 214, 120, .15); }
}
@keyframes numRise {
  0% { opacity: 0; transform: translateY(70%) scale(.7); filter: blur(6px); }
  60% { opacity: 1; filter: blur(0); }
  100% { opacity: 1; transform: none; filter: none; text-shadow: 0 0 14px rgba(255, 214, 120, .6); }
}
.plaque .shine { position: absolute; inset: 0; pointer-events: none; background: linear-gradient(105deg, transparent 35%, rgba(255, 240, 200, .55) 50%, transparent 65%); transform: translateX(-120%); }
.plaque.lit .shine { animation: shine 1.2s ease-in-out .7s both; }
@keyframes shine { to { transform: translateX(120%); } }
.sparks { position: absolute; left: 0; top: 0; width: 0; height: 0; pointer-events: none; z-index: 3; }
.sparks i { position: absolute; width: 6px; height: 6px; margin: -3px; border-radius: 50%; background: radial-gradient(circle, #fff6d0, #f2c45a 60%, transparent 70%); animation: spark .9s ease-out forwards; }
@keyframes spark { from { transform: translate(0, 0) scale(1); opacity: 1; } to { transform: translate(var(--dx), var(--dy)) scale(.2); opacity: 0; } }
/* button and "Save the Date" share one slot and cross-fade: no layout jump */
.reveal-slot { display: grid; place-items: center; min-height: 64px; }
.reveal-slot > * { grid-area: 1 / 1; }
#revealBtn { transition: opacity .7s ease, transform .7s ease, visibility 0s linear .7s; }
#revealBtn.used { opacity: 0; transform: scale(.94); pointer-events: none; visibility: hidden; }
.after { margin: 0; opacity: 0; transform: translateY(8px); filter: blur(4px); transition: opacity 1.1s ease, transform 1.1s ease, filter 1.1s ease; pointer-events: none; }
.after.show { opacity: 1; transform: none; filter: none; }
.after { font-family: var(--script); font-size: 30px; color: var(--maroon); margin: 12px 0 0; }

/* gallery: a wall with a long rail and many hanging frames */
.gallery {
  padding: 0;
  background-color: #f6e6cf;
  background-image: var(--paper), radial-gradient(ellipse at 50% 30%, #fbf0dd, #f1dcbd 80%);
  background-size: 300px 300px, 100% 100%;
}
.divider-wide { width: min(92%, 640px); margin: 0 auto 18px; }
.wall { position: relative; }
.gal-runway { position: relative; }
.gal-stage {
  position: sticky;
  top: 0;
  height: 100vh;
  height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
}
.gal-stage .h2 { margin-bottom: 2vh; }
.gal-stage .divider-wide { margin-bottom: 1vh; }
.track { overflow: hidden; overflow-x: clip; overflow-y: visible; padding-bottom: 60px; margin-bottom: -60px; }
.track-inner {
  position: relative;
  will-change: transform;
  display: flex;
  align-items: flex-start;
  gap: 40px;
  width: max-content;
  padding: 0 max(4vw, calc((100vw - 1280px) / 2)) 50px;
}
.track-inner::before {
  /* the rail runs the full length of the wall */
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 8px;
  background: linear-gradient(180deg, #82231d, var(--maroon) 60%, var(--maroon-3));
  box-shadow: 0 3px 6px rgba(0, 0, 0, .3);
}
.frame3d {
  flex: none;
  width: min(68vw, 330px, 40vh);
  margin: 0;
  position: relative;
  /* lean from the hanging ring, driven by the rail's motion */
  transform-origin: 50% 0;
  transform: perspective(900px) rotate(var(--lean, 0deg)) rotateY(var(--yaw, 0deg));
}
.frame3d { --cordh: calc(70px + var(--drop)); }
.cords { position: relative; height: var(--cordh); }
.cords .ring { position: absolute; top: -4px; left: 50%; width: 14px; height: 14px; margin-left: -7px; border-radius: 50%; border: 3px solid #ecd6c4; z-index: 2; }
.cords svg { position: absolute; left: 0; top: 4px; width: 100%; height: calc(100% - 2px); overflow: visible; }
.cords .cord { fill: none; stroke: #651812; stroke-width: 2.2; vector-effect: non-scaling-stroke; }
.cords .cord-twist { fill: none; stroke: #d7718f; stroke-width: 1; stroke-dasharray: 3 3; vector-effect: non-scaling-stroke; }
.swing { transform-origin: 50% calc(-1 * var(--cordh)); transform: rotate(var(--tilt)); animation: sway 6s ease-in-out infinite; animation-delay: calc(var(--d) * -.8s); }
@keyframes sway { 0%, 100% { transform: rotate(var(--tilt)); } 50% { transform: rotate(calc(var(--tilt) * -1)); } }
.moulding {
  padding: 20px;
  background: linear-gradient(135deg, rgba(255, 255, 255, .22), transparent 40%), linear-gradient(180deg, #781f19, #651812 50%, #4c110c);
  box-shadow: inset 0 0 0 2px #3c0805, inset 4px 4px 0 rgba(255, 160, 190, .35), inset -4px -4px 0 rgba(0, 0, 0, .35),
    18px 26px 30px rgba(51, 12, 9, .35), 4px 6px 6px rgba(0, 0, 0, .3);
  position: relative;
}
.moulding::after { content: ''; position: absolute; inset: 16px; box-shadow: inset 2px 2px 0 #310a07, inset -2px -2px 0 #aa3f37; pointer-events: none; }
.mat { background: #f9ead6; padding: 14px 14px 10px; box-shadow: inset 2px 2px 6px rgba(0, 0, 0, .25); }
.mat img, .mat .ph { display: block; width: 100%; aspect-ratio: 4 / 5; object-fit: cover; box-shadow: 0 0 0 1px rgba(0, 0, 0, .15); }
.landscape { width: min(80vw, 440px, 52vh); }
@media (max-width: 899px) { .frame3d { --cordh: calc(46px + var(--drop) * .5); } }
@media (max-height: 720px) and (max-width: 899px) {
  .gal-stage .divider-wide { display: none; }
  .gal-stage .h2 { font-size: 28px; margin-bottom: 1vh; }
  .frame3d { width: min(62vw, 36vh); --cordh: calc(34px + var(--drop) * .35); }
  .landscape { width: min(76vw, 46vh); }
  .track-inner { padding-bottom: 24px; }
}
.landscape .mat img, .landscape .mat .ph { aspect-ratio: 4 / 3; }
.mat .ph { position: relative; overflow: hidden; background: radial-gradient(ellipse at 50% 40%, #fff5e6, #ecd2ae); }
.mat .ph svg, .mat .ph img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; box-shadow: none; aspect-ratio: auto; }
.mat .ph img.contain { object-fit: contain; padding: 8%; }
.mat .ph span { position: absolute; left: 50%; bottom: 10px; transform: translateX(-50%); white-space: nowrap; padding: 4px 10px; border-radius: 999px; background: rgba(255, 255, 255, .8); font: 600 10px var(--sans); letter-spacing: .1em; text-transform: uppercase; color: var(--ink-soft); }
.mat figcaption { font-family: var(--display); font-style: italic; font-weight: 600; font-size: 22px; color: var(--maroon); padding-top: 8px; }
.story .mat blockquote { margin: 0; padding: 30px 20px; font-family: var(--display); font-style: italic; font-size: 20px; line-height: 1.45; color: var(--maroon); aspect-ratio: 4 / 5; display: grid; place-items: center; }
.frame-nav { display: flex; justify-content: center; align-items: center; gap: 22px; }
.gal-progress { width: 120px; height: 3px; border-radius: 2px; background: rgba(61, 10, 7, .15); overflow: hidden; }
.gal-progress i { display: block; height: 100%; width: 0; background: var(--maroon); }
.frame-nav button { border: 0; background: none; color: var(--maroon); font-size: 28px; letter-spacing: -2px; padding: 4px 10px; }

/* ceremonies */
.ceremonies { padding: 110px 22px 60px; }
.jh { position: absolute; top: 0; width: 140px; z-index: 1; filter: drop-shadow(0 6px 6px rgba(0, 0, 0, .35)); }
.jh-l { left: 0; }
.jh-r { right: 0; transform: scaleX(-1); }
.cere-grid { max-width: 420px; margin: 0 auto; }
.arch-card {
  --arch: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 100 40' preserveAspectRatio='none'%3E%3Cpath d='M0 40 V30 C0 24 6 22 12 21 C20 20 24 14 28 10 C34 5 42 4 46 2 L50 0 L54 2 C58 4 66 5 72 10 C76 14 80 20 88 21 C94 22 100 24 100 30 V40Z'/%3E%3C/svg%3E");
  position: relative;
  padding: 7px;
  background: linear-gradient(180deg, #b47a3c, #6b3a14 40%, #a8703a 70%, #5a2c0c);
  -webkit-mask: var(--arch) top / 100% 120px no-repeat, linear-gradient(#000, #000) 0 119px / 100% calc(100% - 119px) no-repeat;
  mask: var(--arch) top / 100% 120px no-repeat, linear-gradient(#000, #000) 0 119px / 100% calc(100% - 119px) no-repeat;
  filter: drop-shadow(0 20px 24px rgba(0, 0, 0, .5));
}
.arch-card::before {
  content: '';
  position: absolute;
  inset: 7px;
  background-color: #fbe7c8;
  background-image: var(--paper), radial-gradient(ellipse at 50% 30%, #fff6e6, #f8dfb8 60%, #ecc895);
  background-size: 300px 300px, 100% 100%;
  -webkit-mask: var(--arch) top / 100% 113px no-repeat, linear-gradient(#000, #000) 0 112px / 100% calc(100% - 112px) no-repeat;
  mask: var(--arch) top / 100% 113px no-repeat, linear-gradient(#000, #000) 0 112px / 100% calc(100% - 112px) no-repeat;
}
.arch-card > * { position: relative; }
.arch-art { height: 200px; margin: 50px 18px 4px; }
.arch-card h3 { font-family: var(--display); font-weight: 700; font-size: 34px; color: var(--maroon-3); margin: 4px 0 14px; }
.arch-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin: 0 22px; text-align: left; }
.venue { font-family: var(--sans); font-size: 19px; font-weight: 600; color: var(--ink); margin: 0; line-height: 1.25; }
.pin { flex: none; width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center; color: var(--maroon-3); border: 1.5px solid var(--maroon-3); box-shadow: 0 3px 0 rgba(49, 8, 5, .3); }
.pin svg { width: 22px; height: 22px; }
.arch-foot { display: flex; justify-content: space-between; align-items: baseline; margin: 14px 22px 0; padding: 12px 0 22px; border-top: 1px solid rgba(90, 44, 12, .3); font-family: var(--sans); font-weight: 700; font-size: 18px; color: var(--ink); }
.arch-foot .t { font-size: 13px; }
.cere-div { width: 80%; max-width: 520px; margin: 30px auto; }

/* after ceremonies */
.after-cere { padding: 50px 0 20px; }
.torn {
  position: absolute;
  left: 0;
  right: 0;
  top: -14px;
  height: 16px;
  background: #fdf3e3;
  clip-path: polygon(0 60%, 4% 30%, 8% 70%, 12% 20%, 17% 60%, 21% 35%, 26% 75%, 30% 25%, 35% 55%, 40% 15%, 44% 65%, 49% 30%, 54% 70%, 58% 20%, 63% 60%, 67% 35%, 72% 75%, 76% 25%, 81% 55%, 86% 20%, 90% 65%, 95% 30%, 100% 60%, 100% 100%, 0 100%);
  z-index: 2;
}
.badges { display: flex; justify-content: center; gap: 26px; padding: 14px 16px 40px; flex-wrap: wrap; }
.badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  border: 0;
  padding: 0;
  background: none;
  color: var(--maroon);
  text-decoration: none;
  cursor: pointer;
  -webkit-appearance: none;
  appearance: none;
}
/* brass medallion: gold rim, maroon enamel centre, embossed gold icon */
.medal {
  position: relative;
  width: 74px;
  height: 74px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: var(--gold-hi);
  background:
    radial-gradient(circle at 35% 30%, #8d241c, var(--maroon) 55%, var(--maroon-3) 100%) padding-box,
    conic-gradient(from 200deg, #f8e2a0, #b7822c, #fff0b8, #a86f1c, #f0c86a, #8a5512, #f8e2a0) border-box;
  border: 4px solid transparent;
  box-shadow: 0 10px 18px rgba(51, 8, 5, .3), inset 0 0 0 2px rgba(246, 213, 139, .45), inset 0 -6px 10px rgba(0, 0, 0, .35);
  transition: transform .25s ease, box-shadow .25s ease;
}
.medal::after { content: ''; position: absolute; inset: 7px; border-radius: 50%; border: 1px dashed rgba(246, 213, 139, .45); }
.medal svg { width: 30px; height: 30px; filter: drop-shadow(0 1px 0 rgba(0, 0, 0, .4)); }
.medal-label { font: 700 11px var(--sans); letter-spacing: .14em; text-transform: uppercase; color: var(--maroon); }
.badge:hover .medal, .badge:focus-visible .medal { transform: translateY(-3px); box-shadow: 0 16px 24px rgba(51, 8, 5, .35), inset 0 0 0 2px rgba(246, 213, 139, .6), inset 0 -6px 10px rgba(0, 0, 0, .35); }
.badge:focus { outline: none; }
.orn-img { display: block; width: 100%; height: auto; }

/* RSVP */
.rsvp { padding: 30px 18px 60px; }
.rsvp-card { max-width: 680px; margin: 0 auto; background: rgba(255, 253, 249, .96); border-radius: 22px; padding: 34px 20px 28px; box-shadow: 0 24px 50px rgba(61, 22, 19, .18), 0 0 0 1px rgba(201, 151, 63, .25); }
.rsvp .sub { margin: -14px 0 24px; color: var(--ink-soft); font-size: 18px; }
.rsvp form { text-align: left; display: grid; gap: 16px; }
.two { display: grid; gap: 16px; }
.field { display: grid; gap: 6px; }
.field > span, .field-title { font-family: var(--sans); font-size: 13px; font-weight: 700; color: var(--maroon); margin: 0; }
input, textarea { font: 500 16px var(--sans); color: var(--ink); padding: 13px 14px; border-radius: 12px; border: 1.5px solid #e7d6c6; background: #fff; width: 100%; }
input:focus, textarea:focus { outline: 2px solid var(--gold); border-color: var(--gold); }
.count-box { background: #f1ece9; border-radius: 16px; padding: 18px; text-align: center; display: grid; gap: 10px; }
.count-q { font-family: var(--sans); font-weight: 700; color: var(--maroon-3); }
.count-box small, .hint { font-family: var(--sans); font-size: 12px; color: var(--ink-soft); }
.stepper { display: flex; justify-content: center; align-items: center; gap: 10px; }
.stepper button { width: 44px; height: 44px; border-radius: 12px; border: 1.5px solid #d9c9c2; background: #fff; color: var(--maroon); font-size: 22px; font-weight: 700; }
.stepper output { width: 66px; height: 44px; border-radius: 12px; border: 1.5px solid #d9c9c2; background: #fff; display: grid; place-items: center; font: 700 18px var(--sans); }
.ev-list { border: 1.5px solid #ece0d8; border-radius: 16px; overflow: hidden; }
.rsvp-ev { border: 0; border-bottom: 1px solid #ece0d8; margin: 0; padding: 14px 16px; }
.rsvp-ev:last-child { border-bottom: 0; }
.rsvp-ev legend { float: left; width: 100%; font: 700 17px var(--sans); color: var(--maroon-3); padding: 0; margin-bottom: 10px; }
.rsvp-ev legend small { display: block; font-weight: 500; font-size: 12px; color: var(--gold); margin-top: 2px; }
.opts { clear: both; display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.opts input { position: absolute; opacity: 0; width: 1px; }
.opts span { display: flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 0; border-radius: 12px; border: 1.5px solid #e2d4cc; background: #fff; font: 600 14px var(--sans); color: var(--ink); }
.opts span::before { content: ''; width: 14px; height: 14px; border-radius: 50%; border: 1.5px solid #8a7470; }
.opts input:checked + span { border-color: var(--maroon); background: #e9f5f2; color: var(--maroon); }
.opts input:checked + span::before { border: 4.5px solid var(--maroon); }
.opts input:focus-visible + span { outline: 2px solid var(--gold); }
.hint { text-align: center; margin: 0; }
.status { text-align: center; font: 600 15px var(--sans); margin: 0; min-height: 1.2em; }
.status.ok { color: #7c322d; }
.status.err { color: #b3261e; }

/* outro */
.outro { height: 820px; overflow: hidden; background: #f3d9bf; }
.outro .torn.top { top: 0; z-index: 3; transform: scaleY(-1); background: #fdf3e3; height: 18px; }
.outro-art { position: absolute; inset: 0; will-change: transform; }
.outro-art .slot svg, .outro-art img.slot { object-fit: cover; }
.easel { position: absolute; left: 50%; top: 70px; width: 250px; margin-left: -125px; }
.easel-board { position: relative; height: 420px; padding: 10px; background: var(--gold-grad); border-radius: 125px 125px 6px 6px; box-shadow: 0 30px 40px rgba(51, 12, 9, .4); }
.finial { position: absolute; top: -40px; left: 50%; width: 16px; height: 46px; margin-left: -8px; background: var(--gold-grad); clip-path: polygon(50% 0, 70% 30%, 60% 40%, 75% 60%, 60% 100%, 40% 100%, 25% 60%, 40% 40%, 30% 30%); }
.board-inner {
  height: 100%;
  border-radius: 116px 116px 2px 2px;
  background-color: #fbf3e6;
  background-image: var(--paper);
  box-shadow: inset 0 0 0 8px #fbf3e6, inset 0 0 0 9px #c9973f, inset 0 0 0 18px #fbeedb, inset 0 0 0 19px rgba(201, 151, 63, .6), inset 0 0 40px rgba(150, 100, 50, .25);
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  padding: 40px 30px;
}
.farewell { font-family: var(--display); font-style: italic; font-size: 26px; line-height: 1.35; color: var(--maroon); margin: 0 0 16px; }
.couple-sm { font-family: var(--script); font-size: 34px; color: var(--maroon-2); margin: 0; }
.tag { font-family: var(--sans); font-size: 12px; font-weight: 700; letter-spacing: .1em; color: var(--gold); margin: 8px 0 0; }
.legs { position: relative; height: 250px; }
.legs i { position: absolute; top: -10px; width: 16px; height: 260px; background: linear-gradient(90deg, #a8703a, #f0d29a 40%, #b8803e); box-shadow: 0 8px 10px rgba(0, 0, 0, .25); }
.legs i:nth-child(1) { left: 18%; transform: rotate(8deg); transform-origin: top; }
.legs i:nth-child(2) { left: calc(50% - 8px); height: 200px; filter: brightness(.85); }
.legs i:nth-child(3) { right: 18%; transform: rotate(-8deg); transform-origin: top; }
.credit { position: absolute; bottom: 70px; left: 0; right: 0; font-family: var(--sans); font-size: 12px; color: var(--maroon-3); margin: 0; }


/* Realistic grounding for the farewell stand: a soft contact shadow where it
   meets the floor plus a faint, longer cast shadow from the warm side light. */
.easel-shadow {
  position: absolute;
  left: 50%;
  top: 700px;            /* floor line under the easel feet (phones) */
  width: 300px;
  height: 80px;
  margin-left: -150px;
  pointer-events: none;
  z-index: 1;
  background:
    radial-gradient(ellipse 12% 14% at 12% 55%, rgba(30, 8, 4, .85), transparent 72%),
    radial-gradient(ellipse 12% 14% at 88% 55%, rgba(30, 8, 4, .85), transparent 72%),
    radial-gradient(ellipse 10% 12% at 50% 6%, rgba(30, 8, 4, .7), transparent 72%),
    radial-gradient(ellipse 52% 40% at 50% 50%, rgba(50, 15, 8, .45), transparent 78%);
  filter: blur(3px);
}
.easel-shadow::after {
  /* cast shadow stretched across the floor, away from the lantern light */
  content: '';
  position: absolute;
  left: 20%;
  top: 30%;
  width: 90%;
  height: 120%;
  background: radial-gradient(ellipse at 30% 40%, rgba(50, 15, 10, .38), transparent 70%);
  transform: skewX(-38deg);
  filter: blur(10px);
}
.easel { z-index: 2; }
.easel-board::after {
  /* ambient occlusion: the board darkens slightly toward its lower edge */
  content: '';
  position: absolute;
  left: 6%;
  right: 6%;
  bottom: -18px;
  height: 28px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(40, 12, 8, .35), transparent 70%);
  filter: blur(6px);
  z-index: -1;
}
.credit a { color: inherit; font-weight: 700; text-decoration: none; }
.credit-logo { width: 22px; height: 22px; object-fit: contain; vertical-align: -6px; margin-right: 8px; }
.credit a:hover, .credit a:focus-visible { text-decoration: underline; }



/* per-leg contact shadows: a dark soft oval under each foot plus a faint
   shadow stretched across the floor (counter-rotated so it lies flat) */
.legs i::after, .legs i::before {
  content: '';
  position: absolute;
  left: 50%;
  bottom: -7px;
  pointer-events: none;
}
.legs i::after {
  width: 40px;
  height: 12px;
  margin-left: -20px;
  border-radius: 50%;
  background: radial-gradient(ellipse at center, rgba(30, 8, 4, .7), rgba(30, 8, 4, 0) 70%);
  filter: blur(2px);
}
.legs i::before {
  width: 90px;
  height: 18px;
  margin-left: -10px;
  border-radius: 50%;
  background: radial-gradient(ellipse at 20% 50%, rgba(40, 12, 6, .32), rgba(40, 12, 6, 0) 70%);
  filter: blur(5px);
  transform-origin: 10px 50%;
  transform: rotate(14deg);
}
.legs i:nth-child(1)::after, .legs i:nth-child(1)::before { rotate: -8deg; }
.legs i:nth-child(3)::after, .legs i:nth-child(3)::before { rotate: 8deg; }
@media (max-width: 899px) {
  .easel-shadow { top: 690px; height: 60px; background: radial-gradient(ellipse 50% 40% at 50% 50%, rgba(50, 15, 8, .3), transparent 78%); }
  .easel-shadow::after { display: none; }
  .credit { bottom: 46px; }
}

.credit {
  left: 50%;
  right: auto;
  transform: translateX(-50%);
  width: max-content;
  max-width: calc(100% - 32px);
  padding: 7px 16px;
  border-radius: 18px;
  background: rgba(255, 249, 238, .9);
  color: var(--maroon-3);
  box-shadow: 0 4px 14px rgba(51, 12, 9, .18);
  font-size: 12px;
  line-height: 1.35;
  text-align: center;
  z-index: 3;
}

/* ---------- living scenes ---------- */
.fx-defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.scene { position: absolute; inset: 0; overflow: hidden; }
.scene-box { position: absolute; left: 0; top: 0; width: 100%; height: 100%; }
.scene-img { display: block; width: 100%; height: 100%; }
.fx { position: absolute; background-repeat: no-repeat; pointer-events: none; }
/* water: light glinting and drifting across the surface. The pool itself is
   NOT distorted, so floating diyas and lotuses stay still and crisp. */
.fx-water { background: none !important; overflow: hidden; }
.fx-water::before, .fx-water::after {
  content: '';
  position: absolute;
  inset: 0 -240px;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 22%, #000 100%);
  mask-image: linear-gradient(to bottom, transparent, #000 22%, #000 100%);
}
.fx-water::before { background: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20width%3D%27240%27%20height%3D%2770%27%3E%3Crect%20x%3D%2732%27%20y%3D%2759%27%20width%3D%2718%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.50%27/%3E%3Crect%20x%3D%27119%27%20y%3D%2731%27%20width%3D%2716%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.82%27/%3E%3Crect%20x%3D%2723%27%20y%3D%272%27%20width%3D%2719%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.61%27/%3E%3Crect%20x%3D%27183%27%20y%3D%270%27%20width%3D%2713%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.78%27/%3E%3Crect%20x%3D%2755%27%20y%3D%2766%27%20width%3D%2720%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.37%27/%3E%3Crect%20x%3D%276%27%20y%3D%2738%27%20width%3D%2721%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.58%27/%3E%3Crect%20x%3D%2752%27%20y%3D%2730%27%20width%3D%276%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.48%27/%3E%3Crect%20x%3D%27105%27%20y%3D%2735%27%20width%3D%2710%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.49%27/%3E%3Crect%20x%3D%2753%27%20y%3D%2732%27%20width%3D%2711%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.36%27/%3E%3Crect%20x%3D%27201%27%20y%3D%2739%27%20width%3D%2716%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.46%27/%3E%3Crect%20x%3D%27238%27%20y%3D%2760%27%20width%3D%278%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.55%27/%3E%3Crect%20x%3D%27173%27%20y%3D%2750%27%20width%3D%2721%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.60%27/%3E%3Crect%20x%3D%27199%27%20y%3D%2747%27%20width%3D%2711%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.70%27/%3E%3Crect%20x%3D%27212%27%20y%3D%2759%27%20width%3D%2714%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.70%27/%3E%3Crect%20x%3D%278%27%20y%3D%2717%27%20width%3D%2719%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.60%27/%3E%3Crect%20x%3D%2742%27%20y%3D%2738%27%20width%3D%2717%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.75%27/%3E%3C/svg%3E") 0 0 / 240px 70px repeat; animation: glide 14s linear infinite, glint 3.2s ease-in-out infinite alternate; }
.fx-water::after { background: url("data:image/svg+xml,%3Csvg%20xmlns%3D%27http%3A//www.w3.org/2000/svg%27%20width%3D%27180%27%20height%3D%2750%27%3E%3Crect%20x%3D%2758%27%20y%3D%278%27%20width%3D%2716%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.39%27/%3E%3Crect%20x%3D%2796%27%20y%3D%2718%27%20width%3D%277%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.65%27/%3E%3Crect%20x%3D%277%27%20y%3D%2722%27%20width%3D%277%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.40%27/%3E%3Crect%20x%3D%2776%27%20y%3D%2741%27%20width%3D%278%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.48%27/%3E%3Crect%20x%3D%27113%27%20y%3D%2747%27%20width%3D%2715%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.59%27/%3E%3Crect%20x%3D%27176%27%20y%3D%272%27%20width%3D%2720%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.52%27/%3E%3Crect%20x%3D%2726%27%20y%3D%276%27%20width%3D%2711%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.84%27/%3E%3Crect%20x%3D%2733%27%20y%3D%2729%27%20width%3D%2716%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.57%27/%3E%3Crect%20x%3D%2799%27%20y%3D%273%27%20width%3D%277%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.47%27/%3E%3Crect%20x%3D%27122%27%20y%3D%2721%27%20width%3D%2711%27%20height%3D%271.6%27%20rx%3D%270.8%27%20fill%3D%27white%27%20opacity%3D%270.70%27/%3E%3C/svg%3E") 0 0 / 180px 50px repeat; animation: glideBack 19s linear infinite, glint 2.4s ease-in-out -1.2s infinite alternate; }
@keyframes glide { to { transform: translateX(240px); } }
@keyframes glideBack { to { transform: translateX(-180px); } }
@keyframes glint { from { opacity: .16; } to { opacity: .36; } }
/* foliage stirring in a breeze: a gentle sway of the feathered foliage crop
   (transform only — runs on the GPU, no per-frame repainting) */
.fx-breeze {
  transform-origin: 50% 100%;
  animation: leafSway 5.5s ease-in-out var(--d) infinite alternate;
  -webkit-mask-image: radial-gradient(closest-side, #000 62%, transparent 100%);
  mask-image: radial-gradient(closest-side, #000 62%, transparent 100%);
}
@keyframes leafSway {
  0% { transform: rotate(-.5deg) skewX(.6deg); }
  100% { transform: rotate(.5deg) skewX(-.6deg); }
}
/* hanging lanterns swaying from their hooks */
.fx-swing {
  transform-origin: 50% 0;
  animation: lanternSwing 3.6s ease-in-out var(--d) infinite alternate;
  -webkit-mask-image: radial-gradient(closest-side, #000 75%, transparent 100%);
  mask-image: radial-gradient(closest-side, #000 75%, transparent 100%);
}
@keyframes lanternSwing { from { transform: rotate(-2.2deg); } to { transform: rotate(2.2deg); } }
/* flame glows: warm, soft, each flickering on its own rhythm */
.lights { position: absolute; inset: 0; pointer-events: none; }
.lights i {
  position: absolute;
  aspect-ratio: 1;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(255, 246, 200, .75) 0%, rgba(255, 200, 110, .38) 24%, rgba(255, 160, 60, .12) 50%, transparent 70%);
  animation: flick var(--t) ease-in-out var(--d) infinite alternate;
}
@keyframes flick {
  0% { opacity: .4; transform: translate(-50%, -50%) scale(.88); }
  22% { opacity: .85; transform: translate(-50%, -53%) scale(1.04); }
  48% { opacity: .55; transform: translate(-51%, -50%) scale(.96); }
  74% { opacity: 1; transform: translate(-50%, -52%) scale(1.1); }
  100% { opacity: .68; transform: translate(-49%, -50%) scale(.94); }
}

/* door art comes alive: the branch sways, the elephants breathe */
.door-top { animation: branchSway 5.5s ease-in-out infinite alternate; transform-origin: 50% 85%; }
@keyframes branchSway { from { rotate: -1.6deg; } to { rotate: 1.8deg; } }
.door-bottom { animation: breathe 4.2s ease-in-out infinite; transform-origin: 50% 100%; }
@keyframes breathe { 0%, 100% { scale: 1; translate: 0 0; } 50% { scale: 1.012; translate: 0 -1px; } }
/* a few petals drift over the closed doors */
.gate-petals { position: absolute; inset: 0; pointer-events: none; z-index: 2; overflow: hidden; }
.gate-petals i {
  position: absolute;
  top: -24px;
  width: 11px;
  height: 15px;
  border-radius: 80% 0 80% 0;
  background: linear-gradient(135deg, #ffc2cc, #d9476b);
  opacity: .85;
  animation: gateFall 11s linear infinite;
}
.gate-petals i:nth-child(odd) { background: linear-gradient(135deg, #ffd56a, #e8861a); }
.gate-petals i:nth-child(1) { left: 6%; animation-delay: -1s; }
.gate-petals i:nth-child(2) { left: 18%; animation-delay: -6s; animation-duration: 13s; }
.gate-petals i:nth-child(3) { left: 30%; animation-delay: -3s; }
.gate-petals i:nth-child(4) { left: 44%; animation-delay: -9s; animation-duration: 14s; }
.gate-petals i:nth-child(5) { left: 57%; animation-delay: -4.5s; }
.gate-petals i:nth-child(6) { left: 68%; animation-delay: -11s; animation-duration: 12s; }
.gate-petals i:nth-child(7) { left: 79%; animation-delay: -7s; }
.gate-petals i:nth-child(8) { left: 90%; animation-delay: -2s; animation-duration: 15s; }
.gate-petals i:nth-child(9) { left: 12%; animation-delay: -12.5s; animation-duration: 16s; }
.gate-petals i:nth-child(10) { left: 84%; animation-delay: -5.5s; animation-duration: 13.5s; }
@keyframes gateFall {
  0% { transform: translate(0, 0) rotate(0); }
  50% { transform: translate(30px, 52vh) rotate(260deg); }
  100% { transform: translate(-10px, 106vh) rotate(520deg); }
}
.gate.opening .gate-petals { opacity: 0; transition: opacity .8s; }

/* phones: no drawn birds over the painted opening scene */
@media (max-width: 899px) { .hero .birds { display: none; } }

/* ---------- accessibility (WCAG 2.2 AA) ---------- */
:where(a, button, input, textarea, [tabindex]):focus-visible {
  outline: 3px solid #b8862f;
  outline-offset: 3px;
  border-radius: 6px;
}
.btn-plaque:focus-visible { outline: 3px solid #b8862f; outline-offset: 4px; }
.frame-nav button { min-width: 44px; min-height: 44px; }
.medal { --pin-hole: var(--maroon); }
.pin { --pin-hole: #fbe7c8; width: 44px; height: 44px; }
.music-btn { width: 44px; height: 44px; }
.medal-label { font-size: 12px; }



/* phones: more visible life in the opening scene */
@media (max-width: 899px) {
  .fx-breeze { animation-duration: 4.2s; }
  .only-narrow .lights i { animation-name: flickStrong; }
}
@keyframes flickStrong {
  0% { opacity: .3; transform: translate(-50%, -50%) scale(.8); }
  18% { opacity: 1; transform: translate(-50%, -54%) scale(1.25); }
  40% { opacity: .5; transform: translate(-51%, -50%) scale(.95); }
  62% { opacity: .95; transform: translate(-50%, -53%) scale(1.3); }
  80% { opacity: .45; transform: translate(-49%, -51%) scale(.9); }
  100% { opacity: .85; transform: translate(-50%, -52%) scale(1.15); }
}

/* ---------- performance ---------- */
/* sections far from the screen pause every animation inside them */
.is-off, .is-off *, .is-off *::before, .is-off *::after { animation-play-state: paused !important; }

/* ---------- moving sky ---------- */
/* thin painted wisps drifting across the top of the scene, two depths */
.sky-drift {
  position: absolute;
  left: 0;
  right: 0;
  top: 0;
  height: 40%;
  overflow: hidden;
  pointer-events: none;
  -webkit-mask-image: linear-gradient(to bottom, #000 50%, transparent);
  mask-image: linear-gradient(to bottom, #000 50%, transparent);
}
.sky-drift i { position: absolute; top: 0; bottom: 0; left: 0; will-change: transform; }
.sky-drift i:nth-child(1) {
  width: calc(100% + 1200px);
  background: var(--wisps-a) 0 0 / 1200px 360px repeat;
  opacity: .5;
  animation: skyDriftA 150s linear infinite;
}
.sky-drift i:nth-child(2) {
  width: calc(100% + 900px);
  background: var(--wisps-b) 0 70px / 900px 300px repeat;
  opacity: .32;
  animation: skyDriftB 90s linear infinite;
}
@keyframes skyDriftA { to { transform: translateX(-1200px); } }
@keyframes skyDriftB { to { transform: translateX(-900px); } }

/* clouds that part like curtains as the doors open, then drift softly */
.cloud-veil { position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.cv {
  position: absolute;
  top: -10%;
  width: 90%;
  height: 78%;
  opacity: .95;
  transition: transform 5.5s cubic-bezier(.32, .08, .2, 1), opacity 6s ease;
  will-change: transform, opacity;
}
.cv b {
  position: absolute;
  inset: 0 -450px 0 0;
  background: var(--bank) 0 0 / 900px 520px repeat;
  -webkit-mask-image: radial-gradient(ellipse 46% 48% at 40% 45%, #000 35%, transparent 75%);
  mask-image: radial-gradient(ellipse 46% 48% at 40% 45%, #000 35%, transparent 75%);
  animation: bankDrift 70s ease-in-out infinite alternate;
}
.cv-l { left: -22%; }
.cv-r { right: -22%; }
.cv-r b { background-position: 380px 120px; -webkit-mask-position: 0 0; animation-duration: 84s; }
@keyframes bankDrift { to { transform: translateX(-450px); } }
body.opened .cv-l { transform: translateX(-58%); opacity: .55; }
body.opened .cv-r { transform: translateX(58%); opacity: .55; }
.hero-names { z-index: 3; }
@media (min-width: 900px) {
  .sky-drift { height: 46%; }
  .cv { width: 70%; height: 82%; }
  .cv-l { left: -10%; }
  .cv-r { right: -10%; }
  body.opened .cv-l { transform: translateX(-62%); opacity: .5; }
  body.opened .cv-r { transform: translateX(62%); opacity: .5; }
}

/* ---------- ambient motion ---------- */
.birds, .clouds { position: absolute; inset: 0; pointer-events: none; overflow: hidden; }
.bird { position: absolute; left: 0; top: var(--y); width: var(--s); opacity: 0; animation: fly var(--dur) linear var(--delay) infinite; }
.bird svg { display: block; width: 100%; fill: #4a2a38; }
.wing { transform-box: view-box; transform-origin: 20px 11px; animation: flap var(--flap) ease-in-out infinite alternate; }
@keyframes flap { from { transform: scaleY(1); } to { transform: scaleY(-.35); } }
@keyframes fly {
  0% { transform: translate(-40px, 0); opacity: 0; }
  10% { opacity: .85; }
  50% { transform: translate(calc(var(--vw) * .5), var(--rise)); }
  85% { opacity: .85; }
  100% { transform: translate(calc(var(--vw) + 40px), calc(var(--rise) * .4)); opacity: 0; }
}
.clouds i { position: absolute; height: 40px; border-radius: 50%; background: radial-gradient(ellipse, rgba(255, 255, 255, .55), rgba(255, 255, 255, 0) 70%); filter: blur(6px); animation: drift 70s linear infinite; }
.clouds i:nth-child(1) { top: 9%; width: 260px; left: -30%; }
.clouds i:nth-child(2) { top: 20%; width: 200px; left: 20%; animation-duration: 95s; animation-delay: -40s; }
.clouds i:nth-child(3) { top: 30%; width: 300px; left: 60%; animation-duration: 120s; animation-delay: -80s; opacity: .7; }
@keyframes drift { from { transform: translateX(-60%); } to { transform: translateX(calc(var(--vw) + 60%)); } }
.flame { transform-box: fill-box; transform-origin: 50% 100%; animation: flicker 1.3s ease-in-out infinite alternate; }
.flame:nth-of-type(2n) { animation-duration: .9s; animation-delay: -.4s; }
@keyframes flicker { 0% { transform: scale(1, 1); } 40% { transform: scale(.92, 1.08) skewX(2deg); } 100% { transform: scale(1.04, .94) skewX(-2deg); } }
.halo { animation: halo 2.6s ease-in-out infinite alternate; }
@keyframes halo { from { opacity: .65; } to { opacity: 1; } }
.ripples path { animation: ripple 4s ease-in-out infinite; stroke-dasharray: 20 14; }
@keyframes ripple { 50% { stroke-dashoffset: 34; stroke-opacity: .5; } }

/* Reveals: each block rises into place the FIRST time it is reached and
   then stays (no fading out on the way past — calmer, like real paper). */
html.lenis, html.lenis body { height: auto; }
.lenis.lenis-smooth { scroll-behavior: auto !important; }
.lenis.lenis-stopped { overflow: hidden; }

/* petal shower */
.petals { position: fixed; inset: 0; pointer-events: none; z-index: 45; overflow: hidden; }
.petals i { position: absolute; top: -20px; width: 12px; height: 16px; border-radius: 80% 0 80% 0; background: linear-gradient(135deg, #ffcf4a, #e8761a); animation: fall linear forwards; }
.petals i:nth-child(3n) { background: linear-gradient(135deg, #ffc2cc, #d9476b); }
.petals i:nth-child(5n) { background: linear-gradient(135deg, #fff, #f1d6dc); }
@keyframes fall { to { transform: translate(var(--x), 105vh) rotate(calc(var(--r) + 540deg)); opacity: .7; } }

/* =================== Desktop / large screens =================== */
@media (min-width: 900px) {
  .only-narrow { display: none !important; }
  .only-wide { display: block !important; }

  /* gate: central cream panel between two tall doors */
  .gate-card {
    top: 0;
    bottom: 0;
    left: 50%;
    right: auto;
    width: 500px;
    padding: 0 40px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    transform: translateX(-50%) scale(calc(1 + var(--p) * .08));
    box-shadow: 0 0 60px rgba(0, 0, 0, .55);
  }
  .gate-card::before, .gate-card::after { top: 0; bottom: 0; left: auto; right: auto; width: 14px; height: auto; background: linear-gradient(90deg, #7c1f19, var(--maroon) 60%, var(--maroon-3)); }
  .gate-card::before { left: -14px; }
  .gate-card::after { right: -14px; transform: scaleX(-1); }
  .om { font-size: 72px; }
  .mantra { font-size: 28px; }
  .intro { font-size: 22px; max-width: 340px; }
  .door-top { width: 44%; height: 30%; top: 6%; }
  .door-l .door-top { left: 6%; }
  .door-r .door-top { right: 6%; }
  .door-bottom { width: 42%; height: 42%; left: 6%; bottom: 6%; }
  .door-r .door-bottom { left: auto; right: 6%; }
  .hero-art img.slot { object-position: 50% 40%; }
  .hero-names { text-shadow: 0 0 18px rgba(255, 240, 225, .95), 0 0 40px rgba(255, 230, 210, .8), 0 2px 4px rgba(255, 255, 255, .6); }
  .outro-art img.slot { object-position: 50% 62%; }
  .door-ring { margin-top: 0; }
  .door-l .door-ring { right: 270px; }
  .door-r .door-ring { left: 270px; }

  .hero-names { flex-direction: row; justify-content: center; align-items: baseline; gap: 22px; top: 11%; font-size: clamp(60px, 5.4vw, 84px); }
  .hero-names .amp { font-size: .45em; }

  .h2 { font-size: 44px; margin-bottom: 40px; }
  .families { padding: 80px 0 40px; }
  .scroll { margin-bottom: 60px; }
  .scroll.has-orn { margin-bottom: 190px; }
  .scroll-orn { width: 140px; margin-left: -70px; }
  .sheet { padding: 70px 40px 40px; }
  .sheet h3 { font-size: 40px; }
  .sheet .rel { font-size: 22px; }
  .sheet .who { font-size: 26px; }
  .sheet ul { font-size: 22px; }
  .sheet-orn { width: 300px; }

  .date-top { width: 220px; margin-top: 60px; }
  .date-row { margin-bottom: 70px; }
  .date-side { height: 230px; margin: 0; }
  .plaques { gap: 24px; margin-bottom: 30px; }
  .plaque { width: 200px; height: 130px; }
  .plaque .tab { font-size: 13px; padding: 4px 16px; top: 8px; }
  .plaque .v { font-size: 52px; margin-top: 20px; }
  .btn-plaque span { font-size: 22px; padding: 14px 56px; }
  .after { font-size: 42px; }

  .gallery { padding: 0; }
  .frame3d { width: min(320px, 36vh); }
  .landscape { width: min(440px, 50vh); }
  .track-inner { gap: 70px; padding-bottom: 50px; }

  .ceremonies { padding: 200px 40px 100px; }
  .jh { width: 300px; }
  .cere-grid { max-width: 1320px; display: flex; flex-wrap: wrap; justify-content: center; gap: 60px 50px; align-items: flex-start; }
  .cere-grid .arch-card { flex: 0 1 calc((100% - 100px) / 3); min-width: 300px; }
  .cere-div { display: none; }
  .arch-art { height: 230px; }

  .after-cere { padding: 80px 0 30px; }
  .badges { gap: 70px; padding: 20px 0 60px; }
  .medal { width: 92px; height: 92px; }
  .medal svg { width: 38px; height: 38px; }
  .medal-label { font-size: 12px; }

  .rsvp { padding: 60px 24px 100px; }
  .rsvp-card { padding: 50px 50px 40px; }
  .two { grid-template-columns: 1fr 1fr; }

  /* desktop: no easel — an arched, gold-framed board set against the courtyard */
  .outro { height: 100vh; min-height: 760px; }
  .easel { width: 480px; margin-left: -240px; top: calc(50% - 290px); }
  .easel-board {
    height: 600px;
    padding: 12px;
    border-radius: 240px 240px 14px 14px;
    box-shadow: 0 40px 70px rgba(51, 12, 9, .45), 0 0 0 1px rgba(120, 70, 20, .4), 0 0 60px rgba(255, 210, 150, .35);
  }
  .board-inner { border-radius: 228px 228px 6px 6px; padding: 80px 50px 50px; }
  .finial { top: -46px; }
  .legs { display: none; }
  .easel-shadow { top: calc(50% + 300px); width: 560px; margin-left: -280px; height: 80px;
    background: radial-gradient(ellipse 46% 34% at 50% 30%, rgba(30, 8, 4, .75), transparent 72%), radial-gradient(ellipse 62% 60% at 50% 50%, rgba(50, 15, 8, .38), transparent 78%); filter: blur(4px); }
  .easel-shadow::after { left: 30%; width: 80%; }
  .sheet-orn { width: 360px; }
  .date-top { width: 230px; }
  .farewell { font-size: 34px; max-width: 360px; }
  .couple-sm { font-size: 46px; }
  .credit { bottom: 96px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; }
  [data-reveal] { opacity: 1; transform: none; }
  .hero-names span { opacity: 1; }
  .fx-breeze { animation: none; }
  .sky-drift i, .cv b { animation: none; }
  .cv { transition-duration: .01ms; }
  .fx-water::before, .fx-water::after { animation: none; }
  .gate-petals { display: none; }
}


/* ================= Mayur Vatika theme ================= */
:root {
  --display: 'Cinzel', 'Cormorant Garamond', Georgia, serif;
  --script: 'Pinyon Script', cursive;
  --gold: #c9a45c;
  --gold-hi: #f4dca0;
  --gold-text: #f1d397;
  --cream: #faf4ea;
  --cream-2: #efe4d2;
}
.h2 { font-weight: 600; letter-spacing: .04em; }
.hero-names { font-family: var(--script); font-style: normal; font-weight: 400; color: #400d0a;
  font-size: clamp(56px, 16vw, 78px); text-shadow: 0 2px 16px rgba(255, 245, 235, .9), 0 0 34px rgba(255, 240, 230, .8); }
.hero-names .amp { font-family: var(--display); font-size: .32em; letter-spacing: .3em; color: #b88c3e; margin: 6px 0; }
.sheet h3, .arch-card h3 { font-family: var(--display); letter-spacing: .03em; }
.after, .couple-sm { font-family: var(--script); }
.farewell { font-family: var(--serif); font-weight: 600; }

/* opening: velvet screen with the peacock; the fan spreads to reveal */
.gate-fan { position: absolute; inset: 0; overflow: hidden; }
.gate-velvet {
  position: absolute; inset: 0;
  background: radial-gradient(ellipse at 50% 38%, #731b15 0%, #450e0a 52%, #270604 100%);
  opacity: clamp(0, calc(1 - var(--p) * 1.8), 1);
}
.gate-velvet::after { content: ''; position: absolute; inset: 0; background-image: var(--damask-maroon); background-size: 120px 140px; opacity: .55; }
.fan-img {
  position: absolute; left: 50%; top: 4%; width: min(150vw, 980px); max-width: none;
  transform-origin: 50% 92%;
  transform: translateX(-50%) scale(calc(.62 + var(--p) * 2.6));
  opacity: clamp(0, calc(1 - var(--p) * 1.25), 1);
  filter: drop-shadow(0 18px 30px rgba(0, 0, 0, .35));
  animation: fanBreathe 4.5s ease-in-out infinite alternate;
}
@keyframes fanBreathe { from { scale: 1; } to { scale: 1.025; } }
.gate.opening .fan-img { animation: none; }
.gate-card { top: auto; bottom: 7%; transform: none; border-radius: 26px; left: 6%; right: 6%; padding: 26px 22px;
  background-color: rgba(250, 244, 234, .96); box-shadow: 0 18px 40px rgba(0, 0, 0, .35), 0 0 0 1.5px #c9a45c, 0 0 0 7px rgba(250, 244, 234, .25);
  opacity: clamp(0, calc(1 - var(--p) * 2.4), 1); }
.gate-card::before, .gate-card::after { display: none; }
.om, .mantra, .intro { color: #8a6a2e; }
.om { color: #b88c3e; }

/* ornaments */
.date-top { width: 210px; }
.date-side { height: 150px; }
.date-side img { object-fit: contain; }
.scroll-orn { width: 54px; margin-left: -27px; }
.jh { display: none; }
.ceremonies { padding-top: 70px; }
.petals i { background: linear-gradient(135deg, #b63128, #6c120c); }
.petals i:nth-child(3n) { background: linear-gradient(135deg, #f6c9d4, #d97a95); }
.petals i:nth-child(5n) { background: linear-gradient(135deg, #fff1c8, #d4a64e); }

/* closing: the card stands inside the fanned peacock tail */
.outro { background: #2b0805; }
.outro-velvet { position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 40%, #651812, #300a07 60%, #1b0503); }
.outro-fan { position: absolute; left: 50%; top: 2%; width: min(160vw, 1100px); max-width: none; transform: translateX(-50%); opacity: .95; }
.outro .legs { display: none; }
.outro .easel { top: 120px; }
.outro .easel-shadow { display: none; }
.credit { color: #310a07; }
@media (min-width: 900px) {
  .hero-names { font-size: clamp(76px, 6.5vw, 104px); top: 9%; }
  .hero-names .amp { font-size: .3em; margin: 0 10px; }
  .gate-card { left: 50%; right: auto; width: 520px; bottom: 6%; top: auto; transform: translateX(-50%) scale(calc(1 + var(--p) * .06)); display: block; padding: 30px 40px; }
  .fan-img { top: 2%; width: min(90vw, 1150px); }
  .date-top { width: 300px; }
  .date-side { height: 250px; }
  .outro-fan { top: 4%; width: min(92vw, 1300px); }
  .outro .easel { top: 50%; margin-top: -300px; }
}

/* type: Cinzel capitals only for headings; names/body in Cormorant, captions in script */
.sheet .who, .sheet .rel, .sheet ul { font-family: var(--serif); letter-spacing: 0; }
.sheet .who { font-size: 22px; font-weight: 700; }
.sheet .rel { font-size: 18px; font-style: italic; }
.intro { font-family: var(--serif); font-style: italic; font-weight: 600; font-size: 20px; }
.mat figcaption { font-family: var(--script); font-size: 28px; font-style: normal; }
.story .mat blockquote { font-family: var(--serif); font-size: 22px; }
.plaque .v { font-family: var(--serif); font-weight: 700; }
#date .bf-host { z-index: 3; }
@media (min-width: 900px) {
  .sheet .who { font-size: 28px; }
  .fan-img { top: 1%; width: min(96vw, 1250px); transform: translateX(-50%) scale(calc(.78 + var(--p) * 2.2)); }
  .gate-card { bottom: 4%; width: 480px; padding: 22px 36px; }
  .gate-card .om { font-size: 52px; }
  .gate-card .mantra { font-size: 22px; margin: 6px 0; }
  .gate-card .intro { font-size: 21px; margin-bottom: 14px; }
}


/* ================= Mayur Vatika v2: its own components ================= */

/* ---- Mayur Dwar: arched lacquer doors with a peacock on each ---- */
.gate { perspective: 1600px; }
.gate-fan, .door { display: none; }
.mdoor {
  position: absolute; top: 0; bottom: 0; width: 50.2%; z-index: 1;
  transform-style: preserve-3d; will-change: transform;
}
.mdoor-l { left: 0; transform-origin: left center; transform: translateX(calc(var(--p) * -100%)) rotateY(calc(var(--p) * 22deg)); }
.mdoor-r { right: 0; transform-origin: right center; transform: translateX(calc(var(--p) * 100%)) rotateY(calc(var(--p) * -22deg)); }
.mdoor-face {
  position: absolute; inset: 0; overflow: hidden;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .28), transparent 14%, transparent 86%, rgba(0, 0, 0, .28)),
    radial-gradient(ellipse at 50% 30%, #81211b 0%, #4c110c 55%, #2b0805 100%);
  box-shadow: inset 0 0 0 3px #210503, inset 0 0 0 6px #c9a45c, inset 0 0 0 9px #210503, inset 0 0 0 11px rgba(201, 164, 92, .5), inset 0 0 80px rgba(0, 0, 0, .5);
}
.mdoor-face::before { content: ''; position: absolute; inset: 0; background-image: var(--damask-maroon); background-size: 120px 140px; opacity: .5; }
/* gold arched panel outline on each door */
.mdoor-arch {
  position: absolute; left: 12%; right: 12%; top: 6%; bottom: 5%;
  border: 2px solid rgba(232, 200, 128, .85); border-radius: 999px 999px 14px 14px;
  box-shadow: 0 0 0 6px rgba(201, 164, 92, .18), inset 0 0 0 6px rgba(33, 5, 3, .35), inset 0 0 0 7px rgba(232, 200, 128, .45);
}
.mdoor-peacock {
  position: absolute; top: 9%; width: 118%; max-width: none;
  transform-origin: 70% 20%; filter: drop-shadow(0 10px 14px rgba(0, 0, 0, .45));
  animation: peacockSway 5s ease-in-out infinite alternate;
}
.mdoor-l .mdoor-peacock { left: -22%; }
.mdoor-r .mdoor-peacock { right: -22%; transform: scaleX(-1); transform-origin: 50% 20%; }  /* mirror about the centre */
@keyframes peacockSway { from { rotate: -1.6deg; } to { rotate: 1.4deg; } }
.mdoor-handle { position: absolute; top: 52%; width: 22px; height: 46px; border-radius: 12px; border: 3px solid #e8c880; box-shadow: 0 2px 4px rgba(0, 0, 0, .5); }
.mdoor-l .mdoor-handle { right: 18px; }
.mdoor-r .mdoor-handle { left: 18px; }
/* round gold seal on the seam: splits in two as the doors part */
.seal { position: absolute; left: 50%; top: 30%; width: 104px; height: 104px; margin-left: -52px; z-index: 2; pointer-events: none; }
.seal i { position: absolute; top: 0; width: 50%; height: 100%; background: radial-gradient(circle at 100% 50%, #fff2c6, #d9ac55 45%, #8a5f1c 80%); box-shadow: 0 6px 14px rgba(0, 0, 0, .45); }
.seal-l { left: 0; border-radius: 52px 0 0 52px; transform: translateX(calc(var(--p) * -50vw)); }
.seal-r { right: 0; border-radius: 0 52px 52px 0; transform: translateX(calc(var(--p) * 50vw)) scaleX(-1); }
.seal span { position: absolute; inset: 0; display: grid; place-items: center; font-family: 'Tiro Devanagari Hindi', serif; font-size: 50px; color: #5c3b0c; opacity: calc(1 - var(--p) * 3); }
.gate-card { z-index: 3; }
.gate-card .om { display: none; }

/* ---- names written in letter by letter ---- */
.hero-names .nm { opacity: 1 !important; animation: none !important; }
.hero-names .nm i { display: inline-block; font-style: normal; opacity: 0; transform: translateY(16px) scale(.9); }
body.opened .hero-names .nm i { animation: letterIn .8s cubic-bezier(.2, .8, .2, 1) forwards; animation-delay: calc(var(--k) * 75ms + .4s); }
@keyframes letterIn { 60% { opacity: 1; text-shadow: 0 0 22px rgba(255, 220, 140, .95); } to { opacity: 1; transform: none; } }

/* ---- feather-fan cards ---- */
.families .wrap { display: grid; gap: 40px; }
.fan-card { position: relative; width: calc(100% - 40px); max-width: 560px; margin: 130px auto 30px; }
.fan { position: absolute; left: 50%; top: 22px; width: 0; height: 0; z-index: 0; }
.fan img {
  position: absolute; left: -26px; bottom: 0; width: 52px; max-width: none;
  transform-origin: 50% 100%;
  transform: rotate(0deg) scale(.55); opacity: 0;
  transition: transform 1.3s cubic-bezier(.2, .9, .25, 1.15), opacity .6s ease;
  transition-delay: calc(var(--o) * 110ms);  /* centre feather first, outer ones after */
}
.fan-card.open .fan img { transform: rotate(calc(var(--i) * 21deg)) scale(1); opacity: 1; animation: featherSway 4.5s ease-in-out 1.6s infinite alternate; }
@keyframes featherSway { from { rotate: -1.8deg; } to { rotate: 1.8deg; } }
.fc-body {
  position: relative; z-index: 1; text-align: center;
  padding: 64px 26px 30px; color: #4c110c;
  border-radius: 240px 240px 18px 18px;
  background-color: #fbf6ec; background-image: var(--paper), radial-gradient(ellipse at 50% 20%, #fffdf7, #f5ead6);
  background-size: 300px 300px, 100% 100%;
  box-shadow: inset 0 0 0 2px #c9a45c, inset 0 0 0 9px #fbf6ec, inset 0 0 0 10px rgba(201, 164, 92, .55), 0 26px 40px -14px rgba(41, 6, 3, .35), 0 8px 16px rgba(41, 6, 3, .12);
}
.fc-body h3 { font-family: var(--display); font-weight: 600; font-size: 25px; color: #4c110c; margin: 0 0 14px; letter-spacing: .03em; }
.fc-body .rel { font-family: var(--serif); font-style: italic; font-size: 18px; color: #9a7434; margin: 14px 0 2px; }
.fc-body .who { font-family: var(--serif); font-weight: 700; font-size: 21px; line-height: 1.3; margin: 0; color: #3b0f0c; }
.fc-body .and { color: #b88c3e; font-weight: 600; }
.fc-body ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; font-family: var(--serif); font-weight: 700; font-size: 19px; color: #3b0f0c; }
.fc-orn { width: 220px; margin: 22px auto 0; }
/* lines appear one by one once the fan opens */
.fc-body > * { opacity: 0; transform: translateY(12px); transition: opacity .7s ease, transform .7s ease; }
.fan-card.open .fc-body > * { opacity: 1; transform: none; }
.fan-card.open .fc-body > :nth-child(1) { transition-delay: .55s; }
.fan-card.open .fc-body > :nth-child(2) { transition-delay: .75s; }
.fan-card.open .fc-body > :nth-child(3) { transition-delay: .95s; }
.fan-card.open .fc-body > :nth-child(4) { transition-delay: 1.15s; }
.fan-card.open .fc-body > :nth-child(5) { transition-delay: 1.35s; }
.fan-card.open .fc-body > :nth-child(6) { transition-delay: 1.55s; }

/* ---- date: peacock-eye medallions; the peacock above sways its tail ---- */
.eyes { gap: 14px; }
.eyes .plaque {
  width: 92px; height: 92px; border-radius: 50%; margin-top: 0;
  -webkit-mask: none; mask: none;
  background: radial-gradient(circle, #3f0e0b 0 50%, #d6b26a 51% 54%, #8d231b 55% 64%, #2a5fa8 65% 70%, #d6b26a 71% 74%, #340c09 75%);
  box-shadow: 0 10px 18px rgba(41, 6, 3, .35), inset 0 2px 0 rgba(255, 255, 255, .2);
}
.eyes .plaque .tab { top: auto; bottom: -12px; background: #fbf6ec; color: #4c110c; box-shadow: 0 0 0 1px #c9a45c; }
.eyes .plaque .v { margin-top: 0; font-size: 26px; color: #f6e2ae; }
.date-top img { transform-origin: 46% 26%; animation: tailSway 4.8s ease-in-out infinite alternate; }
@keyframes tailSway { from { rotate: -2deg; } to { rotate: 2deg; } }
.date-side img { transform-origin: 50% 100%; animation: featherSway 3.8s ease-in-out infinite alternate; }

/* ---- gallery: arched frames standing on a marble ledge ---- */
.arched .cords { visibility: hidden; height: 18px; }
.track-inner::before { display: none; }
.arched .moulding { border-radius: 260px 260px 8px 8px; padding: 10px; background: linear-gradient(160deg, #f6e2ae, #c9a45c 40%, #8a6a2e 75%, #e8c880); box-shadow: 0 22px 30px -10px rgba(41, 6, 3, .4); }
.arched .moulding::after { display: none; }
.arched .mat { border-radius: 250px 250px 4px 4px; overflow: hidden; background: #fbf6ec; padding: 10px 10px 8px; }
.arched .mat img, .arched .mat .ph { border-radius: 240px 240px 2px 2px; }
.arched .swing { -webkit-box-reflect: below 6px linear-gradient(transparent 72%, rgba(255, 255, 255, .22)); }
.ledge-wall { position: relative; }
.ledge-wall::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 34px; height: 26px; z-index: -1;
  background: linear-gradient(180deg, #f7f1e6, #ddd0bb 60%, #b9a68a); box-shadow: 0 10px 18px rgba(41, 6, 3, .25);
}
.gallery { background-color: #eef3ee; background-image: var(--paper), radial-gradient(ellipse at 50% 30%, #f6f8f3, #dfe9e3 80%); }

/* ---- ceremonies: timeline with a self-drawing gold vine ---- */
.timeline { padding: 70px 18px 80px; }
.tl { position: relative; max-width: 940px; margin: 0 auto; padding: 10px 0; }
.tl-vine { position: absolute; left: 34px; top: 0; width: 40px; height: 100%; margin-left: -20px; overflow: visible; }
.tl-vine path { fill: none; stroke: #e2bf74; stroke-width: 3; stroke-linecap: round; stroke-dasharray: 1; stroke-dashoffset: 1; vector-effect: non-scaling-stroke; filter: drop-shadow(0 0 6px rgba(226, 191, 116, .55)); }
.tl-item { position: relative; display: flex; align-items: center; gap: 16px; margin: 0 0 44px; padding-left: 64px; text-align: left; }
.tl-node { position: absolute; left: 34px; top: 50%; width: 18px; height: 18px; margin: -9px 0 0 -9px; border-radius: 50%;
  background: radial-gradient(circle, #2a5fa8 0 30%, #8d231b 31% 60%, #e2bf74 61%); box-shadow: 0 0 0 3px rgba(226, 191, 116, .3); }
.tl-medal { flex: none; width: 116px; height: 116px; border-radius: 50%; padding: 6px; background: linear-gradient(160deg, #f6e2ae, #c9a45c 45%, #8a6a2e); box-shadow: 0 12px 22px rgba(0, 0, 0, .35); }
.tl-medal .slot { border-radius: 50%; background: #fbf6ec; overflow: hidden; }
.tl-medal img.slot, .tl-medal .slot svg { object-fit: contain; padding: 10%; }
.tl-text h3 { font-family: var(--display); font-weight: 600; font-size: 24px; color: #f6e2ae; margin: 0 0 4px; letter-spacing: .04em; }
.tl-when { font-family: var(--sans); font-weight: 700; font-size: 13px; color: #e8d0ce; margin: 0 0 4px; }
.tl-text .venue { font-family: var(--serif); font-size: 19px; font-weight: 600; color: #fbf6ec; margin: 0 0 6px; }
.tl-map { display: inline-flex; align-items: center; gap: 6px; min-height: 44px; color: #e2bf74; font: 700 12px var(--sans); letter-spacing: .1em; text-transform: uppercase; text-decoration: none; }
.tl-map svg { width: 18px; height: 18px; --pin-hole: #4c110c; }
@media (min-width: 900px) {
  .tl-vine { left: 50%; }
  .tl-node { left: 50%; }
  .tl-item { width: 50%; padding: 0 56px 0 0; flex-direction: row-reverse; text-align: right; }
  .tl-item.right { margin-left: 50%; padding: 0 0 0 56px; flex-direction: row; text-align: left; }
  .tl-item.left .tl-node { left: 100%; }
  .tl-item.right .tl-node { left: 0; }
  .tl-medal { width: 170px; height: 170px; }
  .tl-text h3 { font-size: 30px; }
}

/* ---- ending: round mandala card inside a shimmering fanned tail ---- */
.fan-wrap { position: absolute; left: 50%; top: 2%; width: min(160vw, 1100px); transform: translateX(-50%); animation: fanBreath 6s ease-in-out infinite alternate; }
@keyframes fanBreath { from { scale: 1; } to { scale: 1.025; } }
.fan-wrap .outro-fan { position: relative; left: auto; top: auto; width: 100%; transform: none; display: block; }
.fan-shine { position: absolute; inset: 0; overflow: hidden; -webkit-mask: var(--fan) center / 100% 100% no-repeat; mask: var(--fan) center / 100% 100% no-repeat; pointer-events: none; }
.fan-shine::before { content: ''; position: absolute; top: 0; bottom: 0; left: 0; width: 35%;
  background: linear-gradient(105deg, transparent, rgba(255, 244, 205, .5), transparent); transform: translateX(-120%); animation: shineSweep 5.5s ease-in-out 1s infinite; }
@keyframes shineSweep { 0% { transform: translateX(-120%); } 60%, 100% { transform: translateX(320%); } }
.mandala { width: 300px; margin-left: -150px; top: 140px; }
.mandala .easel-board { height: 300px; border-radius: 50%; padding: 9px; background: conic-gradient(from 0deg, #f6e2ae, #c9a45c, #8a6a2e, #e8c880, #c9a45c, #f6e2ae); }
.mandala .board-inner { border-radius: 50%; padding: 34px 30px;
  box-shadow: inset 0 0 0 6px #fbf6ec, inset 0 0 0 7px #c9a45c, inset 0 0 0 14px #fbf6ec, inset 0 0 0 15px rgba(201, 164, 92, .5), inset 0 0 40px rgba(150, 110, 40, .2); }
.mandala .farewell { font-size: 20px; color: #4c110c; margin-bottom: 8px; }
.mandala .couple-sm { font-size: 30px; color: #4c110c; }
.mandala .easel-board::after { display: none; }
@media (min-width: 900px) {
  .mandala { width: 400px; margin-left: -200px; top: 50%; margin-top: -170px; }
  .mandala .easel-board { height: 400px; }
  .mandala .farewell { font-size: 26px; }
  .mandala .couple-sm { font-size: 40px; }
  .fan-wrap { top: 4%; width: min(92vw, 1300px); }
  .seal { width: 130px; height: 130px; margin-left: -65px; top: 26%; }
  .seal i { border-radius: 65px 0 0 65px; } .seal-r { border-radius: 0 65px 65px 0; }
  .seal span { font-size: 64px; }
  .mdoor-peacock { width: 92%; top: 7%; }
  .mdoor-l .mdoor-peacock { left: 2%; } .mdoor-r .mdoor-peacock { right: 2%; }
}

/* ---- falling peacock feathers ---- */
.petals .feather-fall { position: absolute; top: -140px; width: 30px; animation-name: featherFall; animation-timing-function: ease-in-out; animation-fill-mode: forwards; }
@keyframes featherFall {
  0% { transform: translate(0, 0) rotate(-24deg); }
  25% { transform: translate(calc(var(--x) * .6), 28vh) rotate(22deg); }
  50% { transform: translate(var(--x), 56vh) rotate(-18deg); }
  75% { transform: translate(calc(var(--x) * .3), 84vh) rotate(16deg); }
  100% { transform: translate(0, 112vh) rotate(-8deg); opacity: .6; }
}
@media (prefers-reduced-motion: reduce) {
  .fan img { transform: rotate(calc(var(--i) * 21deg)); opacity: 1; }
  .fc-body > * { opacity: 1; transform: none; }
  .hero-names .nm i { opacity: 1; transform: none; }
  .tl-vine path { stroke-dashoffset: 0; }
}

@media (min-width: 900px) {
  .fan-card { max-width: 660px; margin-top: 170px; }
  .fan img { width: 78px; left: -39px; }
  .fc-body { padding: 84px 50px 40px; }
  .fc-body h3 { font-size: 32px; }
  .fc-body .rel { font-size: 21px; }
  .fc-body .who { font-size: 26px; }
  .fc-body ul { font-size: 23px; }
  .fc-orn { width: 300px; }
}

/* ===== Mayur Dwar v2: richer doors + one round medallion on the seam ===== */
.mdoor-peacock { top: 20%; width: 132%; }
.mdoor-l .mdoor-peacock { left: -34%; }
.mdoor-r .mdoor-peacock { right: -34%; }
.mdoor-feathers { position: absolute; left: 50%; bottom: 5%; width: 0; height: 0; }
.mdoor-feathers img {
  position: absolute; left: -17px; bottom: 0; width: 34px; max-width: none;
  transform-origin: 50% 100%; transform: rotate(calc(var(--k) * 24deg));
  filter: drop-shadow(0 6px 8px rgba(0, 0, 0, .35));
  animation: featherSway 4s ease-in-out infinite alternate; animation-delay: calc(var(--k) * -1.3s);
}
.gate-card {
  left: 50%; right: auto; top: 50%; bottom: auto;
  width: min(80vw, 330px); aspect-ratio: 1; padding: 0 30px; border-radius: 50%;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  transform: translate(-50%, -50%) scale(calc(1 + var(--p) * .25));
  background: radial-gradient(circle at 50% 40%, #fffaf0, #f6ecd9 70%, #ecdcbf);
  box-shadow: 0 0 0 6px #400d0a, 0 0 0 9px #d9b467, 0 0 0 12px rgba(217, 180, 103, .35), 0 0 60px rgba(255, 214, 140, .35), 0 24px 50px rgba(0, 0, 0, .5);
}
.gate-card::before { content: ''; display: block; position: absolute; inset: 10px; border-radius: 50%; border: 1.5px solid rgba(201, 164, 92, .7); background: none; height: auto; }
.gate-card::after { display: none; }
.gate-card .om { display: block; font-size: 40px; margin: 0; }
.gate-card .mantra { font-size: 17px; margin: 4px 0 6px; }
.gate-card .intro { font-size: 15px; line-height: 1.35; margin: 0 0 12px; max-width: 220px; }
.gate-card .btn-plaque span { padding: 9px 26px; font-size: 14px; }
.gate.opening .gate-card { opacity: 0; transform: translate(-50%, -50%) scale(1.25); }
.seal { display: none; }
@media (min-width: 900px) {
  .mdoor-peacock { top: 14%; width: 100%; }
  .mdoor-l .mdoor-peacock { left: -4%; } .mdoor-r .mdoor-peacock { right: -4%; }
  .mdoor-feathers img { width: 56px; left: -28px; }
  .gate-card { width: 400px; padding: 0 44px; bottom: auto; transform: translate(-50%, -50%) scale(calc(1 + var(--p) * .2)); }
  .gate-card .om { font-size: 52px; } .gate-card .mantra { font-size: 21px; } .gate-card .intro { font-size: 18px; max-width: 280px; }
}

@media (min-width: 900px) {
  .gate-card::before { top: 10px; bottom: 10px; left: 10px; right: 10px; width: auto; height: auto; transform: none; background: none; box-shadow: none; }
}

/* date medallions: labels sit fully below the circle (not clipped) */
.eyes { gap: 18px; margin-bottom: 34px; align-items: flex-start; }
.eyes .plaque { overflow: visible; }
.eyes .plaque .shine { display: none; }
.eyes .plaque .tab { bottom: -30px; left: 50%; transform: translateX(-50%); white-space: nowrap; font-size: 10px; padding: 3px 10px; }
.eyes .plaque .v { transform: translateY(26%) scale(.85); }
.eyes .plaque.lit .v { animation-name: numRiseEye; }
@keyframes numRiseEye {
  0% { opacity: 0; transform: translateY(26%) scale(.85); filter: blur(5px); }
  60% { opacity: 1; filter: blur(0); }
  100% { opacity: 1; transform: none; filter: none; text-shadow: 0 0 14px rgba(255, 214, 120, .6); }
}
@media (min-width: 900px) {
  .eyes .plaque { width: 120px; height: 120px; }
  .eyes .plaque .v { font-size: 34px; }
  .eyes .plaque .tab { font-size: 12px; bottom: -34px; }
  .eyes { margin-bottom: 44px; gap: 28px; }
}

/* breathing room: the feather fan (~ feather height above the card) never touches the card above */
.fan-card { margin-top: 175px; margin-bottom: 40px; }
.families .wrap { gap: 20px; }
@media (min-width: 900px) {
  .fan-card { margin-top: 270px; margin-bottom: 60px; }
  .families .wrap { gap: 30px; }
}


/* ===== Mayur Vatika v3: Pinterest-inspired details + separate animated elements ===== */
/* cusped Mughal arch for the family / wishes cards (gold rim + ivory inside) */
.fan-card { --arch: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 200 60' preserveAspectRatio='none'%3E%3Cpath d='M0 60 V38 C0 30 8 28 16 27 C26 26 30 18 36 14 C44 9 54 10 60 8 C70 5 76 2 86 1 L100 0 L114 1 C124 2 130 5 140 8 C146 10 156 9 164 14 C170 18 174 26 184 27 C192 28 200 30 200 38 V60Z'/%3E%3C/svg%3E"); --ah: 92px; }
.fan-card::before { content: ''; position: absolute; left: 8px; right: 8px; top: 40px; bottom: 0; border-radius: 26px; box-shadow: 0 26px 40px -16px rgba(41, 6, 3, .38), 0 8px 16px rgba(41, 6, 3, .1); z-index: 0; }
.fc-body {
  border-radius: 0 0 18px 18px; box-shadow: none;
  background: linear-gradient(160deg, #f6e2ae, #c9a45c 45%, #8a6a2e 80%, #e8c880);
  -webkit-mask: var(--arch) top / 100% var(--ah) no-repeat, linear-gradient(#000, #000) 0 calc(var(--ah) - 1px) / 100% calc(100% - var(--ah) + 1px) no-repeat;
  mask: var(--arch) top / 100% var(--ah) no-repeat, linear-gradient(#000, #000) 0 calc(var(--ah) - 1px) / 100% calc(100% - var(--ah) + 1px) no-repeat;
  padding-top: calc(var(--ah) + 10px);
}
.fc-body::before {
  content: ''; position: absolute; inset: 3px; border-radius: 0 0 15px 15px;
  background-color: #fbf6ec; background-image: var(--paper), radial-gradient(ellipse at 50% 20%, #fffdf7, #f5ead6);
  background-size: 300px 300px, 100% 100%;
  -webkit-mask: var(--arch) top / 100% calc(var(--ah) - 3px) no-repeat, linear-gradient(#000, #000) 0 calc(var(--ah) - 4px) / 100% calc(100% - var(--ah) + 4px) no-repeat;
  mask: var(--arch) top / 100% calc(var(--ah) - 3px) no-repeat, linear-gradient(#000, #000) 0 calc(var(--ah) - 4px) / 100% calc(100% - var(--ah) + 4px) no-repeat;
  box-shadow: inset 0 0 0 7px #fbf6ec, inset 0 0 0 8px rgba(201, 164, 92, .55);
}
.fc-body > * { position: relative; }
.fan { top: 30px; }

/* rose clusters bloom at the card's lower corners */
.fc-rose { position: absolute; bottom: -22px; width: 104px; z-index: 2; pointer-events: none;
  transform-origin: 50% 90%; opacity: 0; scale: .6; transition: opacity .8s ease 1.2s, scale 1.2s cubic-bezier(.2, .9, .3, 1.2) 1.2s; }
.fc-rose.l { left: -16px; rotate: -8deg; }
.fc-rose.r { right: -16px; transform: scaleX(-1); rotate: 8deg; }
.fan-card.open .fc-rose { opacity: 1; scale: 1; animation: roseSway 5s ease-in-out 2.4s infinite alternate; }
@keyframes roseSway { from { translate: 0 0; } to { translate: 0 -3px; } }

/* hanging brass lanterns: swing from the chain, glow flickers */
.lanterns { position: absolute; left: 0; right: 0; top: 0; height: 0; z-index: 2; pointer-events: none; }
.lan { position: absolute; left: var(--x); top: calc(-34px + var(--drop)); translate: -50% 0; transform-origin: 50% 0;
  animation: lanSwing var(--t) ease-in-out var(--dl) infinite alternate; }
.lan img { display: block; width: 44px; filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .3)); }
.lan::after { content: ''; position: absolute; left: 50%; top: 66%; width: 110px; height: 110px; margin: -55px 0 0 -55px; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 214, 120, .55), rgba(255, 180, 70, .18) 45%, transparent 70%);
  animation: lanGlow 2.2s ease-in-out var(--dl) infinite alternate; }
@keyframes lanSwing { from { rotate: -4deg; } to { rotate: 4deg; } }
@keyframes lanGlow { from { opacity: .55; scale: .9; } to { opacity: 1; scale: 1.08; } }
.date { position: relative; }
.date-lan .lan img { width: 40px; }
.timeline { position: relative; padding-top: 190px; }
.tl-lan .lan img { width: 50px; }

/* lotuses bob on the water at the foot of the mandala card */
.lotus-row { position: absolute; left: 50%; bottom: -78px; translate: -50% 0; display: flex; gap: 4px; pointer-events: none; }
.lotus-row img { width: 96px; animation: lotusBob 3.6s ease-in-out infinite alternate; filter: drop-shadow(0 6px 8px rgba(0, 0, 0, .35)); }
.lotus-row img:nth-child(2) { width: 120px; animation-delay: -1.2s; margin-top: 10px; }
.lotus-row img:nth-child(3) { animation-delay: -2.4s; }
@keyframes lotusBob { from { translate: 0 -3px; rotate: -2deg; } to { translate: 0 4px; rotate: 2deg; } }

/* real rose petals falling with the feathers */
.petals .petal-fall { position: absolute; top: -40px; width: 20px; animation-name: petalFall; animation-timing-function: linear; animation-fill-mode: forwards; }
@keyframes petalFall {
  0% { transform: translate(0, 0) rotate(0deg); }
  50% { transform: translate(var(--x), 55vh) rotate(calc(var(--r) + 180deg)); }
  100% { transform: translate(calc(var(--x) * -.4), 110vh) rotate(calc(var(--r) + 380deg)); opacity: .7; }
}

@media (min-width: 900px) {
  .fan-card { --ah: 130px; }
  .fc-rose { width: 150px; bottom: -30px; }
  .fc-rose.l { left: -60px; } .fc-rose.r { right: -60px; }
  .lan img { width: 58px; }
  .date-lan .lan img { width: 54px; }
  .tl-lan .lan img { width: 62px; }
  .timeline { padding-top: 230px; }
  .lotus-row { bottom: -96px; }
  .lotus-row img { width: 130px; } .lotus-row img:nth-child(2) { width: 160px; }
}
@media (prefers-reduced-motion: reduce) { .fc-rose { opacity: 1; scale: 1; } }

/* lotuses float on the water at the foot of the ending (outside the peacock) */
.outro .lotus-row { bottom: 150px; z-index: 2; }
@media (max-width: 899px) { .outro .lotus-row { bottom: 120px; } }
@media (min-width: 900px) {
  .outro .lotus-row { left: 0; right: 0; translate: none; bottom: 110px; justify-content: space-between; padding: 0 6%; }
  .outro .lotus-row img:nth-child(2) { visibility: hidden; }
}


/* ===== v4 fixes ===== */
/* feathers fall smoothly: steady linear drop + gentle independent sway */
.petals .feather-fall { width: 30px; top: -140px; }
@keyframes featherDrop { from { translate: 0 0; opacity: 1; } 90% { opacity: 1; } to { translate: 0 calc(100vh + 160px); opacity: 0; } }
@keyframes featherSway2 { from { transform: translateX(-26px) rotate(-22deg); } to { transform: translateX(26px) rotate(18deg); } }

/* ending: the whole peacock fits the screen on a clear backdrop */
.outro { background: radial-gradient(ellipse at 50% 42%, #7c1e18 0%, #49100c 45%, #290805 80%, #1c0503 100%); }
.outro-velvet { background: radial-gradient(circle at 50% 44%, rgba(255, 226, 160, .22), transparent 42%); }
.outro-velvet::after { content: ''; position: absolute; inset: 0; background-image: var(--damask-maroon); background-size: 120px 140px; opacity: .35; }
.fan-wrap { width: min(150vw, 980px); top: 3%; }
@media (min-width: 900px) {
  .outro { height: max(100vh, 760px); }
  .fan-wrap { width: min(86vw, calc(100vh * 1.35), 1180px); top: 50%; translate: 0 -54%; }
  .mandala { width: min(32vh, 340px); height: auto; margin-left: calc(min(32vh, 340px) / -2); top: calc(50% - min(32vh, 340px) * .82); margin-top: 0; }
  .mandala .easel-board { height: min(32vh, 340px); }
  .mandala .farewell { font-size: clamp(16px, 2.2vh, 24px); }
  .mandala .couple-sm { font-size: clamp(24px, 3.4vh, 38px); }
}

/* gallery: proper photo frames hanging on the wall (gold moulding, mat, wall shadow) */
.photo .cords { visibility: visible; height: var(--cordh); }
.photo .cords .cord { stroke: #b8903e; }
.photo .cords .cord-twist { stroke: #f1d397; }
.photo .cords .ring { border-color: #d9b467; }
.photo .moulding {
  border-radius: 3px; padding: 16px;
  background: linear-gradient(135deg, rgba(255, 255, 255, .35), transparent 38%), linear-gradient(180deg, #f3d995, #c9a45c 35%, #8a6a2e 65%, #e2c27a);
  box-shadow: inset 0 0 0 2px #6b4f1c, inset 4px 4px 0 rgba(255, 246, 210, .55), inset -4px -4px 0 rgba(70, 48, 12, .45),
    18px 26px 30px rgba(51, 21, 19, .35), 4px 6px 6px rgba(0, 0, 0, .28);
}
.photo .moulding::after { display: block; inset: 12px; box-shadow: inset 2px 2px 0 #6b4f1c, inset -2px -2px 0 #f3d995; }
.photo .mat { border-radius: 0; background: #fbf6ec; padding: 14px 14px 10px; box-shadow: inset 2px 2px 6px rgba(0, 0, 0, .22); }
.photo .mat img, .photo .mat .ph { border-radius: 0; }
.photo .swing { -webkit-box-reflect: unset; }
.ledge-wall::after { display: none; }
.gallery .track-inner::before { display: block; background: linear-gradient(180deg, #e2c27a, #b8903e 60%, #7a5a20); }

/* music button: clear ON (sound waves pulsing) vs OFF (speaker with ×) */
.music-btn .ic-on, .music-btn .ic-off { position: absolute; width: 22px; height: 22px; transition: opacity .25s ease, transform .25s ease; }
.music-btn .ic-on { opacity: 0; transform: scale(.7); }
.music-btn .ic-off { opacity: 1; }
.music-btn.on .ic-on { opacity: 1; transform: none; }
.music-btn.on .ic-off { opacity: 0; transform: scale(.7); }
.music-btn.on .w1 { animation: mwave 1.2s ease-in-out infinite; }
.music-btn.on .w2 { animation: mwave 1.2s ease-in-out .3s infinite; }
@keyframes mwave { 0%, 100% { opacity: .35; } 50% { opacity: 1; } }
.music-btn:not(.on) { background: rgba(255, 252, 245, .78); color: #8a7a74; }
.music-btn.on { box-shadow: 0 0 0 3px rgba(201, 164, 92, .55), 0 4px 14px rgba(0, 0, 0, .25); }
@media (prefers-reduced-motion: reduce) { .music-btn.on .w1, .music-btn.on .w2 { animation: none; } }

/* ending: peacock fully visible (face uncovered); message card sits below its feet */
.fan-wrap { width: 150vw; top: 20px; translate: none; }
.outro .easel.mandala { top: calc(20px + 100vw - 30px); width: 280px; margin-left: -140px; margin-top: 0; z-index: 3; }
.mandala .easel-board { height: 280px; }
.outro { height: calc(100vw + 500px); min-height: 860px; }
.outro .lotus-row { bottom: 64px; }
@media (min-width: 900px) {
  .outro { height: max(112vh, 860px); }
  .fan-wrap { width: min(84vw, calc(66vh * 1.49), 1180px); top: 2vh; translate: 0 0; }
  .outro .easel.mandala { margin-top: 0; width: min(30vh, 320px); margin-left: calc(min(30vh, 320px) / -2);
    top: calc(2vh + min(84vw, 66vh * 1.49, 1180px) * .672 - min(30vh, 320px) * .18); }
  .mandala .easel-board { height: min(30vh, 320px); }
  .outro .lotus-row { bottom: 70px; }
}


/* ===== ending v5: painted moonlit garden + words written in the sky ===== */
.sky-mode.outro { height: calc(100vw * 2.086); min-height: 0; background: #340d0a; }
.sky-mode .torn.top { z-index: 3; }
.sky-mode .outro-art { transform: none !important; }
.sky-mode .easel, .sky-mode .easel-shadow, .sky-mode .lotus-row, .sky-mode .fan-wrap { display: none; }
.moon-glow { position: absolute; left: 54%; top: 10%; width: 34%; aspect-ratio: 1; translate: -50% -50%; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 238, 190, .45), rgba(255, 220, 150, .12) 45%, transparent 70%); animation: moonPulse 5s ease-in-out infinite alternate; pointer-events: none; }
@keyframes moonPulse { from { opacity: .55; scale: .92; } to { opacity: 1; scale: 1.06; } }
.sky-text { position: absolute; left: 22%; right: 22%; top: 21%; z-index: 2; text-align: center; color: #fbf1d9; }
.sky-text .st-line { margin: 0; opacity: 0; transform: translateY(14px); filter: blur(4px); transition: opacity 1.1s ease, transform 1.1s ease, filter 1.1s ease; }
.sky-text.show .st-line { opacity: 1; transform: none; filter: none; }
.sky-text.show .st-line:nth-child(2) { transition-delay: .5s; }
.sky-text.show .st-line:nth-child(3) { transition-delay: 1s; }
.sky-text.show .st-line:nth-child(4) { transition-delay: 1.5s; }
.sky-text .farewell { font-family: var(--serif); font-style: italic; font-weight: 600; font-size: 21px; line-height: 1.3; color: #fbf1d9; text-shadow: 0 2px 10px rgba(0, 0, 0, .55); }
.sky-text .st-orn { width: 78%; margin: 10px auto; }
.sky-text .couple-sm { font-family: var(--script); font-size: 38px; line-height: 1.1; color: #f6dfa3; text-shadow: 0 0 18px rgba(255, 214, 130, .55), 0 2px 8px rgba(0, 0, 0, .5); }
.sky-text .couple-sm span { font-family: var(--display); font-size: .45em; color: #e2bf74; }
.sky-text .tag { font-family: var(--sans); font-weight: 700; font-size: 12px; letter-spacing: .14em; color: #e2bf74; margin-top: 8px; }
.sky-mode .credit { bottom: 18px; }
@media (min-width: 900px) {
  .sky-mode.outro { height: calc(100vw * .563); }
  .moon-glow { left: 53.5%; top: 9%; width: 13%; }
  .sky-text { left: 31%; right: 31%; top: 18%; }
  .sky-text .farewell { font-size: clamp(22px, 2vw, 32px); }
  .sky-text .couple-sm { font-size: clamp(42px, 4vw, 64px); }
  .sky-text .st-orn { width: 60%; }
}
@media (prefers-reduced-motion: reduce) { .sky-text .st-line { opacity: 1; transform: none; filter: none; } }

/* ending motion: night clouds drifting across the moonlit sky, stronger flower sway */
.sky-drift.night { height: 46%; z-index: 1; -webkit-mask-image: linear-gradient(to bottom, #000 55%, transparent); mask-image: linear-gradient(to bottom, #000 55%, transparent); }
.sky-drift.night i:nth-child(1) { opacity: .28; filter: brightness(.75) sepia(.2) hue-rotate(160deg); animation-duration: 120s; }
.sky-drift.night i:nth-child(2) { opacity: .2; filter: brightness(.7); animation-duration: 75s; }
.sky-mode .fx-breeze { animation-duration: 3.6s; }
.sky-mode .fx-water::before { opacity: .3; }
.sky-text { z-index: 3; }
@media (max-width: 899px) {
  .sky-text { left: 27%; right: 27%; top: 22%; }
  .sky-text .farewell { font-size: 17px; }
  .sky-text .couple-sm { font-size: 32px; }
}
@media (min-width: 900px) { .sky-mode .credit { bottom: 76px; } }

/* WCAG AA: guaranteed contrast for text on painted scenes */
.sky-text::before { content: ''; position: absolute; inset: -18% -14%; z-index: -1; pointer-events: none;
  background: radial-gradient(ellipse at center, rgba(31, 6, 4, .55) 0%, rgba(31, 6, 4, .3) 45%, transparent 72%); }
.sky-text .tag { color: #f6dc9c; font-size: 13px; }
.hero-names { color: #2b0805; text-shadow: 0 0 2px rgba(255, 250, 240, .9), 0 0 14px rgba(255, 246, 232, .95), 0 0 30px rgba(255, 240, 225, .85); }

/* ===== surprise: monogram crest that draws itself ===== */
.monogram { position: relative; padding: 150px 20px 60px; display: grid; place-items: center; }
.mono-arch { position: absolute; left: 50%; top: 110px; width: 280px; translate: -50% 0; overflow: visible; }
.mono-arch path { fill: none; stroke: #c9a45c; stroke-width: 2.4; stroke-dasharray: 1; stroke-dashoffset: 1; stroke-linejoin: round; }
.mono-arch path.in { stroke-width: 1; stroke: #d9b467; opacity: .8; }
.monogram.draw .mono-arch path { transition: stroke-dashoffset 2.6s cubic-bezier(.6, 0, .3, 1); stroke-dashoffset: 0; }
.monogram.draw .mono-arch path.in { transition-delay: .5s; }
.mono-arch { filter: drop-shadow(0 6px 10px rgba(150, 110, 40, .2)); }
.mono-letters { position: relative; margin-top: 150px; display: flex; align-items: center; gap: 4px; font-family: var(--script); color: #400d0a; line-height: 1; }
.mono-letters .ml { font-size: 110px; clip-path: inset(0 100% 0 0); transition: clip-path 1.4s cubic-bezier(.5, 0, .3, 1); }
.mono-letters .mamp { font-family: var(--display); font-size: 26px; color: #b88c3e; opacity: 0; transition: opacity .8s ease 2.4s; margin: 30px 4px 0; }
.monogram.draw .ml { clip-path: inset(0 -20% 0 -20%); }
.monogram.draw .ml:first-child { transition-delay: 1.2s; }
.monogram.draw .ml:last-child { transition-delay: 2.2s; }
.monogram.draw .mamp { opacity: 1; }
.mono-date { position: relative; margin: 26px 0 0; font-family: var(--display); letter-spacing: .3em; font-size: 13px; color: #6b5527; opacity: 0; transition: opacity 1s ease 3s; }
.monogram.draw .mono-date { opacity: 1; }
.mono-peacock { position: absolute; left: 50%; top: 18px; width: 210px; translate: -50% 0; opacity: 0; transform: translateY(-40px) scale(.9);
  transition: opacity 1s ease 2.6s, transform 1.4s cubic-bezier(.2, .9, .3, 1.15) 2.6s; filter: drop-shadow(0 10px 12px rgba(41, 6, 3, .25)); z-index: 1; }
.monogram.draw .mono-peacock { opacity: 1; transform: none; }
@media (min-width: 900px) {
  .monogram { padding-top: 190px; }
  .mono-arch { width: 340px; top: 140px; }
  .mono-letters { margin-top: 190px; }
  .mono-letters .ml { font-size: 140px; }
  .mono-peacock { width: 260px; top: 30px; }
}
@media (prefers-reduced-motion: reduce) {
  .mono-arch path { stroke-dashoffset: 0; } .mono-letters .ml { clip-path: none; }
  .mamp, .mono-date, .mono-peacock { opacity: 1; transform: none; }
}

.mono-letters { margin-top: 130px; }
.mono-date { margin-top: 18px; }
@media (min-width: 900px) { .mono-letters { margin-top: 165px; } }

.sky-text .farewell, .sky-text .couple-sm, .sky-text .tag { max-width: none; margin-left: auto; margin-right: auto; }

/* ===== feather door (Mayur Dwar v3) ===== */
.fdoor { position: absolute; top: 0; bottom: 0; width: 50.2%; overflow: hidden; z-index: 1; will-change: transform; box-shadow: 0 0 40px rgba(0, 0, 0, .45); }
.fdoor-l { left: 0; transform-origin: left center; transform: perspective(1600px) rotateY(calc(var(--p) * -100deg)); }
.fdoor-r { right: 0; transform-origin: right center; transform: perspective(1600px) rotateY(calc(var(--p) * 100deg)); }
.fd-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: right center; }
.fdoor-r .fd-img { transform: scaleX(-1); }
/* a slow light sheen sweeps across the feathers */
.fd-sheen { position: absolute; inset: 0; background: linear-gradient(110deg, transparent 30%, rgba(255, 240, 200, .28) 45%, transparent 60%); background-size: 260% 100%; animation: doorSheen 6s ease-in-out infinite; mix-blend-mode: normal; }
.fdoor-r .fd-sheen { animation-delay: -3s; }
@keyframes doorSheen { from { background-position: 120% 0; } to { background-position: -120% 0; } }
/* gold lotus knob on the seam: split in two halves that travel with the doors */
.knob { position: absolute; left: 50%; top: 40%; width: 130px; aspect-ratio: 1; translate: -50% -50%; z-index: 2; pointer-events: none;
  filter: drop-shadow(0 10px 16px rgba(0, 0, 0, .55)); animation: knobBreath 3.6s ease-in-out infinite alternate; }
@keyframes knobBreath { from { scale: 1; } to { scale: 1.04; } }
.knob img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.knob-l { clip-path: inset(0 50% 0 0); transform: translateX(calc(var(--p) * -55vw)) rotate(calc(var(--p) * -120deg)); }
.knob-r { clip-path: inset(0 0 0 50%); transform: translateX(calc(var(--p) * 55vw)) rotate(calc(var(--p) * 120deg)); }
.gate.opening .knob { animation: none; }
/* invitation plaque sits below the knob, not over the door art */
.gate:has(.fdoor) .gate-card {
  top: auto; bottom: 5%; left: 50%; right: auto; width: min(86vw, 360px); aspect-ratio: auto; border-radius: 22px; padding: 20px 22px 18px;
  transform: translateX(-50%) scale(calc(1 + var(--p) * .08));
  background: rgba(251, 246, 236, .97);
  box-shadow: 0 0 0 1.5px #c9a45c, 0 0 0 6px rgba(251, 246, 236, .35), 0 20px 40px rgba(0, 0, 0, .45);
}
.gate:has(.fdoor) .gate-card::before { display: none; }
.gate:has(.fdoor) .gate-card .om { display: none; }
.gate.opening:has(.fdoor) .gate-card { opacity: 0; }
@media (min-width: 900px) {
  .knob { width: 190px; top: 38%; }
  .gate:has(.fdoor) .gate-card { width: 460px; bottom: 6%; padding: 24px 34px 22px; }
}
@media (prefers-reduced-motion: reduce) { .fd-sheen, .knob { animation: none; } }

/* doors swing AND glide fully off-screen, fading only at the very end: no slivers, no pop */
.fdoor-l { transform: perspective(1600px) translateX(calc(var(--p) * -102%)) rotateY(calc(var(--p) * -62deg)); opacity: clamp(0, calc((1 - var(--p)) * 6), 1); }
.fdoor-r { transform: perspective(1600px) translateX(calc(var(--p) * 102%)) rotateY(calc(var(--p) * 62deg)); opacity: clamp(0, calc((1 - var(--p)) * 6), 1); }
.knob { opacity: clamp(0, calc((1 - var(--p)) * 3), 1); }

/* knob stays whole: turns like a key (first part of the opening), glows, then fades */
.knob-l, .knob-r { clip-path: none; transform: none; }
.knob-r { display: none; }
.knob { opacity: clamp(0, calc((.45 - var(--p)) * 4), 1);
  transform: rotate(calc(min(var(--p) * 3, 1) * 180deg)) scale(calc(1 + var(--p) * .5)); }
.knob::after { content: ''; position: absolute; inset: -30%; border-radius: 50%; pointer-events: none;
  background: radial-gradient(circle, rgba(255, 226, 150, .65), transparent 62%); opacity: calc(min(var(--p) * 5, 1)); }

/* one gold lotus knob on each door at its inner edge: travels with its door */
.knob { display: none; }
.fd-knob { position: absolute; top: 40%; width: 74px; translate: 0 -50%; z-index: 2; pointer-events: none;
  filter: drop-shadow(0 8px 12px rgba(0, 0, 0, .55)); animation: knobBreath 3.6s ease-in-out infinite alternate; }
.fdoor-l .fd-knob { right: 6px; }
.fdoor-r .fd-knob { left: 6px; animation-delay: -1.8s; }
.gate.opening .fd-knob { animation: none; }
/* Vakratunda shloka on the plaque */
.gate-card .shloka { font-family: 'Tiro Devanagari Hindi', serif; font-size: 14px; line-height: 1.6; color: #6b4f1c; margin: 2px 0 10px; }
.gate-card .mantra { margin-bottom: 6px; }
@media (min-width: 900px) {
  .fd-knob { width: 120px; }
  .fdoor-l .fd-knob { right: 12px; } .fdoor-r .fd-knob { left: 12px; }
  .gate-card .shloka { font-size: 17px; }
}

/* ending v6: lantern-free paintings + real hanging lanterns */
.sky-mode.outro { height: calc(100vw * 1.777); }
.moon-glow { left: 50%; top: 13%; width: 30%; }
.sky-text { left: 16%; right: 16%; top: 24%; }
.end-lanterns { position: absolute; left: 0; right: 0; top: 18px; height: 0; z-index: 2; pointer-events: none; }
.end-lanterns.only-wide { display: none !important; }
.end-lanterns .lan::before { content: ''; position: absolute; left: 50%; bottom: 100%; width: 2px; height: calc(40px + var(--drop)); margin-left: -1px;
  background: repeating-linear-gradient(180deg, #c9a45c 0 5px, #8a6a2e 5px 7px); }
.end-lanterns .lan { top: calc(40px + var(--drop)); }
.end-lanterns .lan img { width: 46px; }
@media (min-width: 900px) {
  .sky-mode.outro { height: calc(100vw * .563); }
  .moon-glow { left: 50%; top: 7%; width: 12%; }
  .sky-text { left: 31%; right: 31%; top: 16%; }
  .end-lanterns.only-narrow { display: none !important; }
  .end-lanterns.only-wide { display: block !important; }
  .end-lanterns .lan img { width: 60px; }
}

/* ===== door choreography: light through the seam, thickness, key-turn, camera push ===== */
/* 1. golden light spills through the gap: a bright seam that blooms, then fades */
.gate:has(.fdoor)::after {
  content: ''; position: absolute; left: 50%; top: 0; bottom: 0; z-index: 1; pointer-events: none;
  width: calc(4px + var(--p) * 60vw); translate: -50% 0;
  background: radial-gradient(ellipse 50% 60% at 50% 45%, rgba(255, 236, 180, .95), rgba(255, 200, 110, .45) 45%, transparent 75%);
  opacity: clamp(0, calc(.35 + var(--p) * 4), 1);
  opacity: clamp(0, calc(min(.35 + var(--p) * 4, (.7 - var(--p)) * 3.2)), 1);
  mix-blend-mode: screen;
}
/* idle: a faint warm line glows between the closed doors */
.gate:has(.fdoor):not(.opening)::after { animation: seamGlow 2.6s ease-in-out infinite alternate; }
@keyframes seamGlow { from { opacity: .25; } to { opacity: .6; } }
/* 2. thickness: gold-lacquered inner edges with depth shading */
.fdoor-l { box-shadow: inset -6px 0 0 #b8903e, inset -9px 0 10px rgba(0, 0, 0, .45), 0 0 40px rgba(0, 0, 0, .45); }
.fdoor-r { box-shadow: inset 6px 0 0 #b8903e, inset 9px 0 10px rgba(0, 0, 0, .45), 0 0 40px rgba(0, 0, 0, .45); }
/* shade deepens on each door as it swings away from the light */
.fdoor::after { content: ''; position: absolute; inset: 0; background: #140302; opacity: calc(var(--p) * .55); pointer-events: none; }
/* 3. knobs turn like keys before the doors start moving */
.fd-knob { rotate: calc(min(var(--p) * 5, 1) * 90deg); }
.fdoor-r .fd-knob { rotate: calc(min(var(--p) * 5, 1) * -90deg); }
/* 4. camera pushes through the doorway into the garden */
.hero-art .scene { scale: calc(1.14 - var(--door, 1) * .14); transform-origin: 50% 45%; }
@media (prefers-reduced-motion: reduce) { .hero-art .scene { scale: 1; } .gate:has(.fdoor)::after { animation: none; } }

/* gold Ganesha line icon above the mantra & shloka */
.gate-card .ganesha { display: block; width: 52px; height: auto; margin: 0 auto 6px; color: #b8893a; filter: drop-shadow(0 1px 0 rgba(255, 255, 255, .8)); }
@media (min-width: 900px) { .gate-card .ganesha { width: 64px; } }
/* knob: no zoom — a slow, steady rotation */
.fd-knob { animation: knobSpin 40s linear infinite; }
.fdoor-r .fd-knob { animation-direction: reverse; animation-delay: 0s; }
@keyframes knobSpin { to { transform: rotate(360deg); } }

/* plaque symbol (ॐ until the Ganesha artwork is supplied) */
.gate-card .om-plaque { display: block; font-size: 40px; line-height: 1; color: #b8893a; margin: 0 0 4px; }
.gate-card .ganesha { display: block; width: 56px; height: auto; margin: 0 auto 6px; }
/* knobs fully inside each door, symmetric about the seam */
.fd-knob { width: 62px; top: 42%; }
.fdoor-l .fd-knob { right: 16px; }
.fdoor-r .fd-knob { left: 16px; }
@media (min-width: 900px) {
  .fd-knob { width: 104px; }
  .fdoor-l .fd-knob { right: 34px; } .fdoor-r .fd-knob { left: 34px; }
  .gate-card .om-plaque { font-size: 50px; }
}
/* idle: very slow turn; on tap: a quick double spin (unlocking) before the doors part */
.fd-knob { animation: knobSpin 60s linear infinite; rotate: calc(min(var(--p) * 3.2, 1) * 720deg); }
.fdoor-r .fd-knob { rotate: calc(min(var(--p) * 3.2, 1) * -720deg); animation-direction: reverse; }

.gate:has(.fdoor) .gate-card .om.om-plaque { display: block; }

.gate:has(.fdoor) .gate-card .ganesha { display: block; width: 50px; height: auto; margin: 0 auto 8px; filter: drop-shadow(0 1px 0 rgba(255,255,255,.8)); }
@media (min-width: 900px) { .gate:has(.fdoor) .gate-card .ganesha { width: 62px; } }

/* ===== a peacock flies in and lands on each family card, then the card opens ===== */
.fan { display: none; }
.fan-card { margin-top: 210px; }
.fc-peacock { position: absolute; left: 50%; top: -168px; width: 270px; z-index: 2; pointer-events: none;
  translate: -50% 0; opacity: 0; transform: translate(-70vw, -40vh) rotate(-18deg) scale(.55);
  filter: drop-shadow(0 12px 14px rgba(41, 6, 3, .3)); }
.fan-card.open .fc-peacock { animation: peacockLand 2s cubic-bezier(.25, .8, .3, 1) forwards, peacockIdle 4.5s ease-in-out 2.1s infinite alternate; }
.fan-card:nth-child(even).open .fc-peacock { animation-name: peacockLandR, peacockIdle; }
@keyframes peacockLand {
  0% { opacity: 0; transform: translate(-70vw, -40vh) rotate(-18deg) scale(.55); }
  15% { opacity: 1; }
  70% { transform: translate(6px, -14px) rotate(4deg) scale(1.02); }
  85% { transform: translate(0, 4px) rotate(-1deg) scale(.99); }
  100% { opacity: 1; transform: none; }
}
@keyframes peacockLandR {
  0% { opacity: 0; transform: translate(70vw, -40vh) rotate(18deg) scale(.55); }
  15% { opacity: 1; }
  70% { transform: translate(-6px, -14px) rotate(-4deg) scale(1.02); }
  85% { transform: translate(0, 4px) rotate(1deg) scale(.99); }
  100% { opacity: 1; transform: none; }
}
@keyframes peacockIdle { from { rotate: -1deg; } to { rotate: 1.2deg; } }
/* the card opens only after the landing */
.fc-body { clip-path: inset(0 0 100% 0); transition: clip-path 1.4s cubic-bezier(.45, 0, .2, 1) 1.5s; }
.fan-card.open .fc-body { clip-path: inset(0 0 0 0); }
.fan-card.open .fc-body > :nth-child(1) { transition-delay: 2s; }
.fan-card.open .fc-body > :nth-child(2) { transition-delay: 2.2s; }
.fan-card.open .fc-body > :nth-child(3) { transition-delay: 2.4s; }
.fan-card.open .fc-body > :nth-child(4) { transition-delay: 2.6s; }
.fan-card.open .fc-body > :nth-child(5) { transition-delay: 2.8s; }
.fan-card.open .fc-body > :nth-child(6) { transition-delay: 3s; }
.fan-card.open .fc-rose { transition-delay: 2.6s; }
.fan-card::before { opacity: 0; transition: opacity .6s ease 1.8s; }
.fan-card.open::before { opacity: 1; }
@media (min-width: 900px) { .fan-card { margin-top: 260px; } .fc-peacock { width: 340px; top: -212px; } }

/* ===== two peacock feathers sweep in and cross above the names ===== */
.name-feathers { position: absolute; left: 50%; top: 2%; width: 0; height: 0; z-index: 2; pointer-events: none; }
.name-feathers img { position: absolute; width: 46px; top: 0; transform-origin: 50% 95%; opacity: 0; filter: drop-shadow(0 6px 8px rgba(0, 0, 0, .25)); }
.nf-l { left: -40px; transform: translateX(-60vw) rotate(-120deg); }
.nf-r { left: -6px; transform: translateX(60vw) rotate(120deg) scaleX(-1); }
body.opened .nf-l { animation: nfL 1.8s cubic-bezier(.2, .8, .25, 1) .3s forwards; }
body.opened .nf-r { animation: nfR 1.8s cubic-bezier(.2, .8, .25, 1) .45s forwards; }
@keyframes nfL { to { opacity: 1; transform: rotate(-32deg); } }
@keyframes nfR { to { opacity: 1; transform: rotate(32deg) scaleX(-1); } }
.hero-names { padding-top: 64px; }
@media (min-width: 900px) { .name-feathers { top: 3%; } .name-feathers img { width: 58px; } .nf-l { left: -52px; } .hero-names { padding-top: 70px; } }
@media (prefers-reduced-motion: reduce) { .fc-peacock, .name-feathers img { opacity: 1; transform: none; animation: none; } .fc-body { clip-path: none; } }


/* ===== family scrolls: parchment unrolling over the moonlit garden ===== */
.families.scenic { position: relative; overflow: hidden; background: #340d0a; padding: 40px 0 70px; }
.fam-bg { position: absolute; inset: 0; z-index: 0; }
.fam-bg img { position: sticky; top: 0; width: 100%; height: 100vh; height: 100svh; object-fit: cover; display: block; }
.fam-bg::after { content: ''; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(251, 246, 236, 1) 0%, rgba(41, 9, 7, .25) 12%, rgba(41, 9, 7, .35) 88%, rgba(251, 246, 236, 1) 100%); }
.families.scenic .wrap { position: relative; z-index: 1; }
/* parchment: no arch, warm paper with soft edges */
.fc-body { -webkit-mask: none; mask: none; border-radius: 4px; padding: 46px 26px 36px; background: #f6ead2;
  background-image: var(--paper), radial-gradient(ellipse at 50% 40%, #fdf6e7, #f1e1c2 75%, #e6d1a8);
  background-size: 300px 300px, 100% 100%;
  box-shadow: inset 0 0 30px rgba(140, 100, 40, .25), 0 20px 34px rgba(0, 0, 0, .35);
  clip-path: inset(0 0 100% 0); transition: clip-path 1.6s cubic-bezier(.45, 0, .2, 1) 1.4s; }
.fc-body::before { display: none; }
.fan-card.open .fc-body { clip-path: inset(0 0 0 0); }
.fan-card::before { display: none; }
.fan-card { margin-top: 190px; width: calc(100% - 56px); }
/* gold-capped rods: the bottom one rolls down as the paper opens */
.fc-rod { position: absolute; left: -14px; right: -14px; height: 22px; z-index: 3; border-radius: 11px; pointer-events: none;
  background: linear-gradient(180deg, #5a3a12 0%, #c99a4a 32%, #f6dfa3 46%, #b07f33 66%, #4a2e0c 100%);
  box-shadow: 0 6px 10px -2px rgba(0, 0, 0, .45); }
.fc-rod::before, .fc-rod::after { content: ''; position: absolute; top: 50%; width: 16px; height: 30px; margin-top: -15px; border-radius: 50%;
  background: radial-gradient(circle at 40% 35%, #fff2c0, #e0aa48 40%, #8a5512 85%); }
.fc-rod::before { left: -10px; } .fc-rod::after { right: -10px; }
.fc-rod.top { top: -11px; }
.fc-rod.bot { top: -11px; transition: top 1.6s cubic-bezier(.45, 0, .2, 1) 1.4s; }
.fan-card.open .fc-rod.bot { top: calc(100% - 11px); }
/* text on parchment (WCAG: dark ink on light paper) */
.fc-body h3 { color: #400d0a; }
.fc-body .rel { color: #7a5420; }
.fc-body .who { color: #2b241c; }
.fan-card.open .fc-body > :nth-child(1) { transition-delay: 2.2s; }
.fan-card.open .fc-body > :nth-child(2) { transition-delay: 2.4s; }
.fan-card.open .fc-body > :nth-child(3) { transition-delay: 2.6s; }
.fan-card.open .fc-body > :nth-child(4) { transition-delay: 2.8s; }
.fan-card.open .fc-body > :nth-child(5) { transition-delay: 3s; }
.fc-rose { display: none; }
/* the peacock lands on the top rod */
.fc-peacock { top: -176px; }
@media (min-width: 900px) {
  .fan-card { max-width: 620px; margin-top: 250px; }
  .fc-peacock { top: -222px; }
}
@media (prefers-reduced-motion: reduce) { .fc-body { clip-path: none; } .fc-rod.bot { top: calc(100% - 11px); } }

/* footer: Govindam credit at the very end, after RSVP */
.site-foot { position: relative; padding: 28px 16px 90px; text-align: center; background: var(--cream, #fbf4ea); }
.site-foot .credit { position: static !important; transform: none !important; translate: none !important; left: auto; right: auto; bottom: auto;
  display: inline-block; width: auto; max-width: 100%; margin: 0 auto; }

/* peacock appears perched on the rod (no unrealistic flight) */
.fan-card.open .fc-peacock, .fan-card:nth-child(even).open .fc-peacock { animation: peacockSettle 1.2s cubic-bezier(.2, .8, .3, 1) .2s forwards, peacockIdle 4.5s ease-in-out 1.5s infinite alternate; }
@keyframes peacockSettle { 0% { opacity: 0; transform: translateY(-16px) scale(.96); } 60% { opacity: 1; transform: translateY(3px) scale(1.01); } 100% { opacity: 1; transform: none; } }
.fc-body { transition-delay: .9s; }
.fc-rod.bot { transition-delay: .9s; }
.fan-card.open .fc-body > :nth-child(1) { transition-delay: 1.6s; }
.fan-card.open .fc-body > :nth-child(2) { transition-delay: 1.8s; }
.fan-card.open .fc-body > :nth-child(3) { transition-delay: 2s; }
.fan-card.open .fc-body > :nth-child(4) { transition-delay: 2.2s; }
.fan-card.open .fc-body > :nth-child(5) { transition-delay: 2.4s; }
@media (max-width: 899px) {
  .fan-card, .fan-card { width: calc(100% - 84px); }
  .fc-body { padding: 40px 18px 30px; }
  .timeline { padding-left: 26px; padding-right: 26px; }
  .rsvp { padding-left: 26px; padding-right: 26px; }
}

/* ===== v8: clean cream family section + real perched peacock ===== */
.families { background: var(--cream, #fbf6ec); padding: 40px 0 70px; }
.fc-peacock { left: 10%; width: 76%; top: 0; translate: 0 -48.1%; z-index: 0; filter: drop-shadow(0 10px 12px rgba(40, 30, 10, .22)); }
.fc-body { position: relative; z-index: 1; }
.fan-card { margin-top: 200px; }
@media (min-width: 900px) { .fan-card { margin-top: 300px; } .fc-peacock { left: 16%; width: 66%; top: 0; } }

/* phones: the two feathers sit beside the names (left of Aarohi, right of Vihaan) */
@media (max-width: 899px) {
  .hero-names { padding-top: 0; }
  .name-feathers { top: 0; }
  .name-feathers img { width: 40px; }
  .nf-l { left: -134px; right: auto; top: 34px; }
  .nf-r { left: 92px; top: 132px; }
  @keyframes nfL { to { opacity: 1; transform: rotate(-14deg); } }
  @keyframes nfR { to { opacity: 1; transform: rotate(24deg) scaleX(-1); } }
}

/* peacock is always perched and still; only the scroll unrolls */
.fc-peacock, .fan-card.open .fc-peacock, .fan-card:nth-child(even).open .fc-peacock { animation: none !important; opacity: 1 !important; transform: none !important; }
.fc-body { transition-delay: .15s; } .fc-rod.bot { transition-delay: .15s; }
.fan-card.open .fc-body > :nth-child(1) { transition-delay: .8s; }
.fan-card.open .fc-body > :nth-child(2) { transition-delay: 1s; }
.fan-card.open .fc-body > :nth-child(3) { transition-delay: 1.2s; }
.fan-card.open .fc-body > :nth-child(4) { transition-delay: 1.4s; }
.fan-card.open .fc-body > :nth-child(5) { transition-delay: 1.6s; }
.fan-card.open .fc-body > :nth-child(6) { transition-delay: 1.8s; }

/* tail tucks behind the rod so it never shows below short scrolls */
.fc-peacock { clip-path: inset(0 0 50.5% 0); }

/* phones: feathers placed by script around the names (see placeFeathers) */
@media (max-width: 899px) {
  .name-feathers.hug .nf-l, .name-feathers.hug .nf-r { right: auto; }
  body.opened .name-feathers.hug .nf-l { animation-name: nfHugL; }
  body.opened .name-feathers.hug .nf-r { animation-name: nfHugR; }
  @keyframes nfHugL { from { opacity: 0; transform: translate(-40vw, -10vh) rotate(-140deg); } to { opacity: 1; transform: rotate(-58deg); } }
  @keyframes nfHugR { from { opacity: 0; transform: translate(40vw, 10vh) rotate(140deg) scaleX(-1); } to { opacity: 1; transform: rotate(62deg) scaleX(-1); } }
}

/* peacock: fixed size so it always fits the gap above its scroll */
.fc-peacock { width: 250px; left: auto; right: 6%; }
.fan-card { margin-top: 230px; }
@media (min-width: 900px) { .fc-peacock { width: 300px; right: 14%; left: auto; } .fan-card { margin-top: 270px; } }

/* hug pose is set directly (not via keyframes) so every phone browser ends in the same place */
@media (max-width: 899px) {
  body.opened .name-feathers.hug .nf-l, body.opened .name-feathers.hug .nf-r {
    animation: none !important; opacity: 1; transition: transform 1.4s cubic-bezier(.2, .8, .25, 1), opacity .8s ease, left 1.4s ease, top 1.4s ease, width 1.4s ease; }
  body.opened .name-feathers.hug .nf-l { transform: rotate(-58deg); }
  body.opened .name-feathers.hug .nf-r { transform: rotate(62deg) scaleX(-1); }
}


/* ===================== Kalinga Parinaya (Odia) ===================== */
:root { --od-red: #9c1c14; --od-maroon: #5e1410; --od-ochre: #c9821f; --od-ink: #2a160e; --od-leaf: #e9c983; }
.cream { background-color: #fbf3e4; }
[lang="or"] { font-family: 'Noto Serif Oriya', 'Noto Sans Oriya', serif; }

/* ---- opening: palm-leaf manuscript ---- */
.gate:has(.palm) { background: radial-gradient(ellipse at 50% 42%, #7a2216, #4a0f0a 62%, #2a0806); }
.gate:has(.palm)::after { display: none; }
.palm { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.palm-glow { position: absolute; left: 50%; top: 34%; width: 120vmin; height: 120vmin; translate: -50% -50%; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 200, 110, .35), transparent 60%); opacity: calc(.6 + var(--p) * .4); }
.palm-bundle { position: absolute; left: 50%; top: 30%; width: min(86vw, 560px); translate: -50% -50%;
  filter: drop-shadow(0 18px 24px rgba(0,0,0,.5)); animation: palmFloat 4s ease-in-out infinite alternate;
  transform: scale(calc(1 + min(var(--p) * 5, 1) * .06)) rotate(calc(min(var(--p) * 5, 1) * -2deg));
  opacity: clamp(0, calc(1 - (var(--p) - .12) * 9), 1); }
@keyframes palmFloat { from { translate: -50% -50%; } to { translate: -50% calc(-50% - 6px); } }
.gate.opening .palm-bundle { animation: none; }
.palm-cover { position: absolute; left: 50%; top: 30%; width: min(88vw, 580px); translate: -50% -50%; opacity: 0; filter: drop-shadow(0 12px 18px rgba(0,0,0,.5)); }
.gate.opening .palm-cover { opacity: clamp(0, calc((var(--p) - .1) * 12), 1); }
.palm-cover.top { transform: translateY(calc(min(max(var(--p) - .12, 0) * 2.4, 1) * -46vh)); }
.palm-cover.bot { transform: translateY(calc(min(max(var(--p) - .12, 0) * 2.4, 1) * 66vh)) scaleY(-1); }
.palm-leaf { position: absolute; left: 50%; top: 30%; width: min(84vw, 540px); translate: -50% -50%; opacity: 0;
  filter: drop-shadow(0 6px 8px rgba(0,0,0,.35));
  transform: translateY(calc(min(max(var(--p) - .14, 0) * 2.6, 1) * var(--i) * 11vh))
             rotate(calc(min(max(var(--p) - .14, 0) * 2.6, 1) * var(--i) * 2deg))
             translateX(calc(max(var(--p) - .6, 0) * 2.5 * (var(--k) - 3) * 60vw)); }
.gate.opening .palm-leaf { opacity: clamp(0, calc(min((var(--p) - .12) * 10, (1 - var(--p)) * 4)), 1); }
.gate:has(.palm) .gate-card { top: auto; bottom: 5%; left: 50%; right: auto; transform: translateX(-50%); width: min(88vw, 380px); aspect-ratio: auto;
  border-radius: 20px; padding: 18px 20px; background: rgba(253, 246, 232, .97); box-shadow: 0 0 0 2px #c9821f, 0 0 0 7px rgba(253,246,232,.25), 0 20px 40px rgba(0,0,0,.45); }
.gate:has(.palm) .gate-card::before, .gate:has(.palm) .gate-card .om { display: none; }
.gate:has(.palm) .gate-card .ganesha { display: block; width: 46px; height: auto; margin: 0 auto 6px; }
.gate:has(.palm) .gate-card .mantra { color: #6e1a12; font-size: 18px; margin: 0 0 2px; }
.gate:has(.palm) .gate-card .shloka { color: #5a3a10; font-size: 15px; margin: 0 0 8px; }
.gate:has(.palm) .gate-card .intro { color: #3a2418; }
.gate.opening:has(.palm) .gate-card { opacity: 0; }
@media (min-width: 900px) {
  .palm-bundle, .palm-cover, .palm-leaf { top: 32%; }
  .gate:has(.palm) .gate-card { width: 440px; bottom: 6%; }
}

/* ---- hero: temple flags flutter, parrots cross the sky ---- */
.od-flags { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.odf { position: absolute; top: 2%; width: min(24vw, 150px); transform-origin: 14% 96%; animation: flagSway 3.4s ease-in-out infinite alternate; }
.odf.l { left: 1%; }
.odf.r { right: 1%; transform: scaleX(-1); animation-name: flagSwayR; animation-delay: -1.7s; }
@keyframes flagSway { from { rotate: -2deg; } to { rotate: 2.5deg; } }
@keyframes flagSwayR { from { rotate: 2deg; } to { rotate: -2.5deg; } }
.od-birds { position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.od-birds .bird { position: absolute; width: min(18vw, 110px); left: -20%; opacity: 0; }
body.opened .od-birds .bird.b1 { top: 26%; animation: birdFly 14s linear 3s infinite; }
body.opened .od-birds .bird.b2 { top: 34%; width: min(13vw, 80px); animation: birdFly 18s linear 9s infinite; }
@keyframes birdFly {
  0% { left: -20%; opacity: 0; transform: translateY(0) rotate(-4deg); } 5% { opacity: 1; }
  25% { transform: translateY(-18px) rotate(2deg); } 50% { transform: translateY(6px) rotate(-3deg); } 75% { transform: translateY(-12px) rotate(2deg); }
  92% { opacity: 1; } 100% { left: 110%; opacity: 0; transform: translateY(0) rotate(-2deg); } }
.hero-names { color: #4a0f0a; text-shadow: 0 0 2px rgba(255,248,236,.95), 0 0 14px rgba(255,244,226,.95), 0 0 30px rgba(255,236,210,.85); }
.hero-names .amp { color: #9c5a10; }

/* ---- family scrolls: palm-leaf sheet between carved Pattachitra covers ---- */
.fc-body { background: #f1d9a4; background-image: linear-gradient(180deg, rgba(255,255,255,.25), rgba(0,0,0,.04)), repeating-linear-gradient(0deg, rgba(120,70,10,.05) 0 2px, transparent 2px 9px); }
.fc-rod { height: 34px; border-radius: 6px; background: url("media/od-cover.webp?v=1") center / 100% 100% no-repeat; box-shadow: 0 6px 10px -2px rgba(0,0,0,.4); }
.fc-rod::before, .fc-rod::after { display: none; }
.fc-rod.top { top: -17px; } .fc-rod.bot { top: -17px; }
.fan-card.open .fc-rod.bot { top: calc(100% - 17px); }
.fan-card { margin-top: 70px; }
.fc-body h3 { color: #6e1a12; }
.fc-body .rel { color: #7a4a10; }
.fc-body .who { color: #2a160e; }
.fc-orn img.orn-img { width: 92%; max-width: 420px; }

/* ---- date: the Konark wheel turns slowly behind the date ---- */
.date-center { position: relative; }
.konark { position: absolute; left: 50%; top: 42%; width: min(90vw, 460px); translate: -50% -50%; z-index: 0; opacity: .22; animation: wheelTurn 90s linear infinite; pointer-events: none; }
@keyframes wheelTurn { to { rotate: 360deg; } }
.date-center > :not(.konark) { position: relative; z-index: 1; }
.date-diya { width: 90px !important; filter: drop-shadow(0 0 14px rgba(255, 180, 60, .6)); animation: diyaGlow 2.4s ease-in-out infinite alternate; }
@keyframes diyaGlow { to { filter: drop-shadow(0 0 22px rgba(255, 190, 70, .85)); } }

/* ---- RSVP: jhoti chita (rice-paste pattern) drawn faintly behind ---- */
.rsvp { position: relative; overflow: hidden; }
.jhoti { position: absolute; left: 50%; top: 50%; width: min(120vw, 820px); translate: -50% -50%; opacity: .5; z-index: 0; pointer-events: none;
  filter: brightness(0) saturate(100%) invert(25%) sepia(60%) saturate(500%) hue-rotate(345deg); mix-blend-mode: normal; opacity: .08;
  clip-path: circle(0% at 50% 50%); transition: clip-path 2.6s ease-out; }
.rsvp.in .jhoti, .rsvp:has(.is-in) .jhoti { clip-path: circle(75% at 50% 50%); }
.rsvp > :not(.jhoti) { position: relative; z-index: 1; }

/* ---- ending: egrets glide over the lake at sunset ---- */
.od-egrets { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 1; }
.eg { position: absolute; left: -25%; width: min(16vw, 120px); opacity: 0; }
.outro.in-view .eg.e1, .outro .eg.e1 { top: 38%; animation: egretGlide 22s linear 1s infinite; }
.outro .eg.e2 { top: 44%; width: min(11vw, 84px); animation: egretGlide 26s linear 7s infinite; }
.outro .eg.e3 { top: 33%; width: min(9vw, 66px); animation: egretGlide 30s linear 14s infinite; }
@keyframes egretGlide {
  0% { left: -25%; opacity: 0; transform: translateY(0); } 6% { opacity: .95; }
  50% { transform: translateY(-16px); } 94% { opacity: .95; } 100% { left: 115%; opacity: 0; transform: translateY(4px); } }
/* sunset sky: dark ink text with a warm glow instead of the night halo */
.sky-text::before { background: radial-gradient(ellipse at center, rgba(255, 240, 215, .7) 0%, rgba(255, 236, 205, .4) 45%, transparent 72%); }
.sky-text .farewell, .sky-text .couple-sm { color: #3a0d08; text-shadow: 0 0 10px rgba(255, 244, 226, .9); }
.sky-text .tag { color: #5e1410; }

/* petals: marigold + rose */
.petals i { background: linear-gradient(135deg, #ffb238, #e0761b); }
.petals i:nth-child(3n) { background: linear-gradient(135deg, #ff6f61, #c2261c); }
@media (prefers-reduced-motion: reduce) { .konark, .bird, .eg, .odf, .palm-bundle, .date-diya { animation: none !important; } }

/* the red backdrop and covers dissolve while the leaves slide away, so the scene shows through with no empty pause */
.gate:has(.palm) { background: none; }
.palm::before { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse at 50% 42%, #7a2216, #4a0f0a 62%, #2a0806);
  opacity: clamp(0, calc(1 - (var(--p) - .45) * 3), 1); }
.palm-glow { opacity: clamp(0, calc(1 - (var(--p) - .45) * 3), 1); }
.gate.opening .palm-cover { opacity: clamp(0, calc(min((var(--p) - .1) * 12, (.62 - var(--p)) * 6)), 1); }
.gate.opening .palm-leaf { opacity: clamp(0, calc(min((var(--p) - .12) * 10, (.9 - var(--p)) * 5)), 1); }

.sky-text .couple-sm span, .sky-text .couple-sm .amp { color: #8a3d06; }

/* carved covers: shadow follows the carved outline (no rectangular plate) */
.fc-rod { box-shadow: none !important; background-color: transparent !important; border-radius: 0; filter: drop-shadow(0 5px 6px rgba(60, 20, 0, .35)); }

/* calendar offer after RSVP */
.cal-offer { margin-top: 14px; text-align: center; }
.cal-offer .cal-note { margin: 10px 0 0; font-size: 14px; line-height: 1.5; }
.cal-offer .cal-note a { font-weight: 700; text-decoration: underline; }


/* ===== Kalinga ceremonies: palm-leaf (talapatra) leaves ===== */
.od-leaves { position: relative; overflow: hidden; padding: 80px 16px 90px; text-align: center;
  background: radial-gradient(ellipse at 50% 0%, #8a2516, #5e1410 55%, #3e0c08); }
.leaves-jhoti { position: absolute; left: 50%; top: 52%; width: min(150vw, 1100px); translate: -50% -50%; opacity: .07; pointer-events: none; }
.leaves-eyebrow { margin: 0; font: 800 12px 'Mulish', sans-serif; letter-spacing: .28em; text-transform: uppercase; color: #f3c873; }
.od-leaves .h2 { color: #fff3dc; margin: 6px 0 10px; }
.leaves-border { display: block; width: min(86vw, 560px); margin: 0 auto 30px; border-radius: 4px; box-shadow: 0 6px 16px rgba(0,0,0,.35); }
.leaves { position: relative; display: flex; flex-direction: column; align-items: center; gap: 26px; max-width: 900px; margin: 0 auto; }
.leaf { position: relative; display: grid; grid-template-columns: 112px 1fr; align-items: center; gap: 14px; width: min(100%, 640px); padding: 18px 22px 18px 18px; text-align: left;
  border-radius: 46px 14px 46px 14px; color: #2a160e;
  background: linear-gradient(180deg, rgba(255,255,255,.28), rgba(0,0,0,.05)), repeating-linear-gradient(0deg, rgba(110,60,10,.07) 0 1px, transparent 1px 8px), linear-gradient(90deg, #e9c47d, #f4dca6 30%, #f1d494 70%, #dcb064);
  box-shadow: inset 0 0 0 2px rgba(120, 70, 10, .35), inset 0 0 22px rgba(120,70,10,.25), 0 16px 30px rgba(0,0,0,.35); }
.leaf.rt { grid-template-columns: 1fr 112px; padding: 18px 18px 18px 22px; border-radius: 14px 46px 14px 46px; text-align: right; }
.leaf.rt .leaf-medal { order: 2; } .leaf.rt .leaf-map { margin-left: auto; }
/* red thread through the leaf's hole */
.leaf-thread { position: absolute; top: 50%; width: 14px; height: 14px; margin-top: -7px; border-radius: 50%; background: #5e1410; box-shadow: inset 0 0 0 3px #f4dca6; }
.leaf.lt .leaf-thread { right: 26px; } .leaf.rt .leaf-thread { left: 26px; }
.leaf-thread::after { content: ''; position: absolute; top: 6px; width: 46px; height: 3px; border-radius: 2px; background: #c0261a; transform-origin: left center; }
.leaf.lt .leaf-thread::after { left: 7px; rotate: 32deg; } .leaf.rt .leaf-thread::after { right: 7px; left: auto; transform-origin: right center; rotate: -32deg; }
.leaf-medal { width: 112px; height: 112px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; background: #fff7e6;
  box-shadow: 0 0 0 4px #c0261a, 0 0 0 7px #f3c873, 0 0 0 9px #5e1410, 0 10px 18px rgba(0,0,0,.35); }
.leaf-medal img { width: 118%; height: 118%; object-fit: contain; }
.leaf-day { margin: 0; font: 800 11.5px 'Mulish', sans-serif; letter-spacing: .2em; text-transform: uppercase; color: #8a2516; }
.leaf h3 { margin: 2px 0 2px; font-family: var(--serif); font-weight: 700; font-size: 30px; line-height: 1.1; color: #5e1410; }
.leaf-when { margin: 0; font-weight: 700; color: #3a2010; }
.leaf-venue { margin: 2px 0 8px; color: #3a2010; }
.leaf-map { display: inline-flex; align-items: center; gap: 6px; min-height: 40px; padding: 0 14px; border-radius: 999px; background: #5e1410; color: #fff3dc !important; font: 800 12px 'Mulish', sans-serif; letter-spacing: .1em; text-transform: uppercase; text-decoration: none; }
.leaf-map svg { width: 14px; height: 14px; fill: currentColor; }
/* laid out one by one: each leaf slides in from its side and settles */
.leaf[data-reveal] { opacity: 0; transform: translateX(-60px) rotate(-3deg); transition: opacity .8s ease, transform 1s cubic-bezier(.2,.8,.25,1); }
.leaf.rt[data-reveal] { transform: translateX(60px) rotate(3deg); }
.leaf.is-in { opacity: 1; transform: none; }
.leaf.lt.is-in { rotate: -.6deg; } .leaf.rt.is-in { rotate: .6deg; }
@media (min-width: 900px) {
  .leaf { width: 660px; grid-template-columns: 132px 1fr; }
  .leaf.rt { grid-template-columns: 1fr 132px; }
  .leaf.lt { align-self: flex-start; margin-left: 60px; } .leaf.rt { align-self: flex-end; margin-right: 60px; }
  .leaf-medal { width: 132px; height: 132px; }
  .leaf h3 { font-size: 34px; }
}
@media (max-width: 420px) { .leaf, .leaf.rt { grid-template-columns: 84px 1fr; padding: 14px 16px 14px 12px; gap: 10px; } .leaf.rt { grid-template-columns: 1fr 84px; padding: 14px 12px 14px 16px; } .leaf-medal { width: 84px; height: 84px; } .leaf h3 { font-size: 25px; } .leaf-thread { display: none; } }
@media (prefers-reduced-motion: reduce) { .leaf[data-reveal] { opacity: 1; transform: none; transition: none; } }

.leaf.is-in[data-reveal], .leaf.rt.is-in[data-reveal] { opacity: 1; transform: none; }

/* never let decorative layers widen the page (no sideways scroll on phones) */
html, body { overflow-x: clip; }
.od-leaves, .rsvp { overflow: hidden !important; }
.leaves-jhoti { width: min(140%, 1100px); }

.gate:has(.palm) .gate-card .om.om-plaque { display: block; font-size: 38px; line-height: 1; color: #9c5a10; margin: 0 0 4px; }

/* ===== opening v3: every palm leaf carries a line of the invitation; the centre leaf zooms in ===== */
.palm-leaf { display: grid; place-items: center; }
.palm-leaf img { width: 100%; display: block; grid-area: 1 / 1; }
.pl-t { grid-area: 1 / 1; padding: 0 12%; text-align: center; font: italic 500 clamp(12px, 3.2vw, 18px)/1.15 'Lora', Georgia, serif; color: #4a2208;
  text-shadow: 0 1px 0 rgba(255, 240, 200, .6); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 100%; }
.pl-t[lang="or"] { font-style: normal; font-family: 'Noto Serif Oriya', serif; }
.palm-leaf.c .pl-t { font: 400 clamp(22px, 6.4vw, 36px)/1 'Alex Brush', cursive; color: #5e1410; }
/* the centre leaf does not slide away: it grows to fill the screen while the page appears behind it */
.palm-leaf.c { z-index: 2;
  transform: translateY(0) scale(calc(1 + max(var(--p) - .58, 0) * 7)); }
.gate.opening .palm-leaf.c { opacity: clamp(0, calc(min((var(--p) - .12) * 10, (.97 - var(--p)) * 4.5)), 1); }
@media (min-width: 900px) { .pl-t { font-size: 18px; } .palm-leaf.c .pl-t { font-size: 34px; } }

/* ===== ceremonies on desktop: compact leaves side by side (no half-empty strips) ===== */
@media (min-width: 900px) {
  .leaves { flex-direction: row; flex-wrap: wrap; justify-content: center; align-items: stretch; gap: 26px; max-width: 1180px; }
  .leaf, .leaf.rt { width: 360px; margin: 0 !important; align-self: auto !important; grid-template-columns: 1fr; justify-items: center; text-align: center;
    padding: 26px 22px 24px; border-radius: 46px 14px 46px 14px; }
  .leaf.rt .leaf-medal { order: 0; } .leaf.rt .leaf-map { margin-left: 0; }
  .leaf-medal { width: 140px; height: 140px; margin-bottom: 6px; }
  .leaf-thread { top: 22px; margin-top: 0; }
  .leaf.lt .leaf-thread { right: 22px; } .leaf.rt .leaf-thread { left: 22px; }
  .leaf.lt.is-in, .leaf.rt.is-in { rotate: 0deg; }
  .leaf[data-reveal], .leaf.rt[data-reveal] { transform: translateY(40px); transition-delay: calc(var(--i) * .12s); }
}

/* Kalinga Parinaya's own typography (distinct from the other templates) */
:root { --display: 'Rozha One', Georgia, serif; --serif: 'Lora', Georgia, serif; --script: 'Alex Brush', cursive; }
.hero-names, .couple-sm { font-family: var(--script); }
.h2, .leaf h3, .fc-body h3 { font-family: var(--display); letter-spacing: .01em; font-weight: 400; }
.leaf h3 { font-size: 28px; }
body, .fc-body .who, .leaf-when, .leaf-venue, .intro { font-family: var(--serif); }

/* blessing symbol drawn in this template's own colour (the picture is only used as a shape) */
:root { --bless-color: #8a2516; }
.gate-card .ganesha.bless { display: block; aspect-ratio: 1; height: auto; margin-left: auto; margin-right: auto; background: var(--bless-color);
  -webkit-mask: var(--ico) center / contain no-repeat; mask: var(--ico) center / contain no-repeat; filter: none; }


/* ===== Kalinga v4: real artwork in motion ===== */
/* opening: the red thread knot loosens, lifts and falls away before the bundle opens */
.palm-bow { position: absolute; left: 50%; top: 30%; width: min(30vw, 190px); translate: -50% -42%; z-index: 3; pointer-events: none;
  filter: drop-shadow(0 6px 8px rgba(0,0,0,.45)); animation: bowSway 3.2s ease-in-out infinite alternate; transform-origin: 50% 20%;
  transform: translateY(calc(min(var(--p) * 7, 1) * 22vh)) rotate(calc(min(var(--p) * 7, 1) * 38deg)) scale(calc(1 + min(var(--p) * 7, 1) * .25));
  opacity: clamp(0, calc(1 - (var(--p) - .06) * 9), 1); }
@keyframes bowSway { from { rotate: -3deg; } to { rotate: 3deg; } }
.gate.opening .palm-bow { animation: none; }
@media (min-width: 900px) { .palm-bow { top: 32%; width: 170px; } }

/* parrots: two wing poses alternate, so the bird really flaps */
.od-birds .bird { display: block; }
.od-birds .bird img { position: absolute; inset: 0; width: 100%; height: auto; }
.od-birds .bird .wu { position: relative; }
.od-birds .bird .wd { animation: flapB .36s steps(1) infinite; }
.od-birds .bird .wu { animation: flapA .36s steps(1) infinite; }
@keyframes flapA { 0% { opacity: 1; } 50% { opacity: 0; } }
@keyframes flapB { 0% { opacity: 0; } 50% { opacity: 1; } }

/* ending: real flying egrets (animated) */
.eg { width: min(20vw, 140px); }
.outro .eg.e2 { width: min(14vw, 100px); } .outro .eg.e3 { width: min(11vw, 80px); }

/* date: Pattachitra frame + twin elephants */
#date { position: relative; }
.od-frame { position: absolute; inset: 10px 8px; width: calc(100% - 16px); height: calc(100% - 20px); object-fit: fill; z-index: 0; pointer-events: none; opacity: .95; }
.od-frame.only-wide { display: none; }
@media (min-width: 900px) { .od-frame.only-narrow { display: none; } .od-frame.only-wide { display: block; } }
#date > :not(.od-frame) { position: relative; z-index: 1; }
#date .strip { display: none; }
#date { padding-top: 70px; padding-bottom: 70px; }
.od-eles { display: block; width: min(76vw, 420px); margin: 0 auto 6px; position: relative; z-index: 1; }

/* RSVP: fish & lotus flourishes in the corners */
.od-corner { position: absolute; width: min(30vw, 190px); z-index: 0; pointer-events: none; opacity: .9; }
.od-corner.tl { left: 6px; top: 6px; }
.od-corner.br { right: 6px; bottom: 6px; transform: rotate(180deg); }

/* ceremony leaves printed on the real palm plank */
.leaf { background-image: linear-gradient(180deg, rgba(255,240,205,.55), rgba(255,236,196,.35)), url("media/od-plank.webp?v=1") !important; background-size: 100% 100%, 100% 100% !important; }
@media (prefers-reduced-motion: reduce) { .palm-bow, .bird img { animation: none !important; } }

/* the diya sits exactly in the centre above the date */
.date-top { display: flex; justify-content: center; width: 100%; text-align: center; }
.date-top .date-diya { display: block; margin: 0 auto; }

/* no temple flags beside the names; birds sized for balance (egrets small, parrots a little larger) */
.od-flags { display: none !important; }
.eg { width: min(11vw, 70px) !important; }
.outro .eg.e2 { width: min(8vw, 52px) !important; } .outro .eg.e3 { width: min(6.5vw, 42px) !important; }
.od-birds .bird { width: min(14vw, 88px) !important; }
body.opened .od-birds .bird.b2 { width: min(11vw, 68px) !important; }

/* carved covers keep their real proportions (no squashing) */
.fc-rod { height: auto !important; aspect-ratio: 1400 / 314; background-size: 100% 100% !important; translate: 0 -50%; }
.fc-rod.top, .fc-rod.bot { top: 0 !important; }
.fan-card.open .fc-rod.bot { top: 100% !important; }
.fan-card { margin-top: 90px; margin-bottom: 70px; }
.fc-body { padding-top: 64px !important; padding-bottom: 60px !important; }
.fc-body { padding-top: calc(min(100%, 560px) * .14 + 26px) !important; padding-bottom: calc(min(100%, 560px) * .14 + 22px) !important; }
@media (min-width: 900px) { .fc-body { padding-top: 104px !important; padding-bottom: 100px !important; } }

/* distant birds: tiny, faint specks far away */
.bird svg { opacity: .55; }
/* soft clouds drifting in every sky */
.sky-drift i:nth-child(1) { opacity: .42 !important; }
.sky-drift i:nth-child(2) { opacity: .3 !important; }

/* gallery: a real wooden beam with frames hanging on jute cords */
.track-inner::before { height: 26px !important; border-radius: 4px !important;
  background: repeating-linear-gradient(90deg, rgba(0,0,0,.06) 0 2px, transparent 2px 38px),
    linear-gradient(180deg, #8a5a2b 0%, #b07a41 22%, #7a4c22 46%, #9a6633 70%, #5e3a18 100%) !important;
  box-shadow: inset 0 2px 0 rgba(255,220,170,.35), inset 0 -3px 4px rgba(0,0,0,.35), 0 8px 14px rgba(40,20,5,.35) !important; }

/* birds kept small and distant, like the first templates */
.od-birds .bird { width: min(7vw, 34px) !important; }
body.opened .od-birds .bird.b2 { width: min(5.5vw, 26px) !important; }
.eg { width: min(6vw, 30px) !important; }
.outro .eg.e2 { width: min(4.5vw, 22px) !important; } .outro .eg.e3 { width: min(3.5vw, 17px) !important; }

/* remove the loose flourishes above the RSVP card */
.od-corner { display: none !important; }
/* every scroll the same comfortable width, and enough space so covers never overlap the next scroll */
.fan-card { width: min(100% - 40px, 560px) !important; max-width: 560px !important; margin-left: auto !important; margin-right: auto !important;
  margin-top: calc(min(100vw - 40px, 560px) * .13 + 56px) !important; margin-bottom: calc(min(100vw - 40px, 560px) * .13 + 30px) !important; }
.fan-card { margin-top: calc(min(100vw - 40px, 560px) * .25 + 44px) !important; margin-bottom: calc(min(100vw - 40px, 560px) * .13 + 30px) !important; }

/* date: calm and clear (frame + diya + date only) */
.od-eles, .konark { display: none !important; }
.date-side { opacity: .9; }
.date-side img, .date-side .orn-img { width: min(16vw, 150px) !important; max-width: 150px; }
#date { padding: clamp(80px, 9vw, 130px) 20px clamp(90px, 10vw, 150px) !important; }
@media (min-width: 900px) { #date .date-row { max-width: 820px; margin: 0 auto; } }
.date-diya { width: 64px !important; }

@media (max-width: 899px) { .date-side { display: none !important; } }

/* sky: a flock of tiny distant black birds, and a few parrots a little larger */
.hero-art .bird svg { opacity: .6; }
.od-birds .bird, body.opened .od-birds .bird.b2 { width: min(4.6vw, 22px) !important; }
body.opened .od-birds .bird.b1 { top: 22%; animation: birdFly 16s linear 2s infinite; }
body.opened .od-birds .bird.b2 { top: 30%; animation: birdFly 19s linear 6s infinite; width: min(4vw, 19px) !important; }
body.opened .od-birds .bird.b3 { top: 17%; animation: birdFly 22s linear 11s infinite; width: min(3.6vw, 17px) !important; }
body.opened .od-birds .bird.b4 { top: 26%; animation: birdFly 18s linear 15s infinite; width: min(4.2vw, 20px) !important; }

.hero-art .birds .bird { width: var(--s) !important; }

.hero-art .birds { display: block !important; }

/* ===== family cards as a Pattachitra box: the painted lid swings open on its hinge,
   the ivory card is revealed inside a gold tray (like the 3D reference) ===== */
.fan-card { perspective: 1400px; }
.fan-card .fc-rod.top { transform-origin: 50% 0%; transform: rotateX(0deg); transition: transform 1.5s cubic-bezier(.6,0,.2,1) .2s, filter 1.5s ease .2s;
  translate: 0 0 !important; top: -2px !important; z-index: 5; backface-visibility: visible; }
.fan-card.open .fc-rod.top { transform: rotateX(78deg) translateY(-6px); filter: drop-shadow(0 10px 10px rgba(60,20,0,.3)) brightness(.9); }
/* the bottom piece becomes the gold tray the card sits in */
.fan-card .fc-rod.bot { background: linear-gradient(180deg, #e6b75a, #c98f2c 45%, #8f5a16) !important; aspect-ratio: auto !important; height: 18px !important;
  border-radius: 0 0 12px 12px; translate: 0 0 !important; top: calc(100% - 9px) !important; left: -10px !important; right: -10px !important;
  box-shadow: inset 0 2px 0 rgba(255,235,180,.6), 0 8px 14px rgba(60,20,0,.3); transition: none !important; }
.fan-card .fc-body { border-radius: 10px; box-shadow: inset 0 0 0 1px rgba(160,110,30,.35), 0 10px 22px rgba(60,20,0,.18) !important;
  clip-path: inset(0 0 0 0) !important; padding-top: 56px !important; padding-bottom: 46px !important; }
.fan-card .fc-body > * { opacity: 0; transform: translateY(10px); transition: opacity .7s ease, transform .7s ease; }
.fan-card.open .fc-body > * { opacity: 1; transform: none; }
.fan-card.open .fc-body > :nth-child(1) { transition-delay: 1.1s; } .fan-card.open .fc-body > :nth-child(2) { transition-delay: 1.25s; }
.fan-card.open .fc-body > :nth-child(3) { transition-delay: 1.4s; } .fan-card.open .fc-body > :nth-child(4) { transition-delay: 1.55s; }
.fan-card.open .fc-body > :nth-child(5) { transition-delay: 1.7s; } .fan-card.open .fc-body > :nth-child(6) { transition-delay: 1.85s; }
/* closed: the lid covers the top of the card like the box lid */
.fan-card:not(.open) .fc-body { min-height: 200px; }
@media (prefers-reduced-motion: reduce) { .fan-card .fc-rod.top { transition: none; } }
/* lid swings up and over its hinge, standing open above the card with its red inner face showing */
.fan-card .fc-rod.top { transform-style: preserve-3d; }
.fan-card .fc-rod.top::after { content: ''; display: block !important; position: absolute; inset: 0; border-radius: 14px / 40%;
  background: radial-gradient(ellipse at 50% 50%, #9c2a1a, #6e1a12 75%); box-shadow: inset 0 0 0 3px #c98f2c, inset 0 0 18px rgba(0,0,0,.4);
  transform: rotateX(180deg) translateZ(1px); backface-visibility: hidden; }
.fan-card.open .fc-rod.top { transform: rotateX(-172deg); filter: drop-shadow(0 -6px 10px rgba(60,20,0,.25)); }
.fan-card .fc-rod.top { background: none !important; }
.fan-card .fc-rod.top::before { content: ''; display: block !important; position: absolute; inset: 0; background: url("media/od-cover.webp?v=1") center / 100% 100% no-repeat; backface-visibility: hidden; }
.fan-card .fc-rod.top::before, .fan-card .fc-rod.top::after { left: 0 !important; right: 0 !important; top: 0 !important; bottom: 0 !important; width: auto !important; height: auto !important; margin: 0 !important; }
.fan-card .fc-rod.top::before { border-radius: 0 !important; }
/* a filter flattens 3D, so keep the lid filter-free to show its red inner face when open */
.fan-card .fc-rod.top, .fan-card.open .fc-rod.top { filter: none !important; }

@media (max-width: 899px) { #date .date-row { display: flex !important; justify-content: center !important; grid-template-columns: none !important; } #date .date-center { margin: 0 auto; } }

/* scroll-driven lid: follows the finger, no sudden flip */
.fan-card .fc-rod.top, .fan-card.open .fc-rod.top { transition: none !important; transform: rotateX(calc(var(--lid, 0) * -172deg)) !important; }
.fan-card .fc-body > *, .fan-card.open .fc-body > * { opacity: 0; transform: translateY(10px); transition: opacity .6s ease, transform .6s ease; transition-delay: 0s !important; }
.fan-card.lid-open .fc-body > * { opacity: 1; transform: none; }
.fan-card.lid-open .fc-body > :nth-child(2) { transition-delay: .1s !important; } .fan-card.lid-open .fc-body > :nth-child(3) { transition-delay: .2s !important; }
.fan-card.lid-open .fc-body > :nth-child(4) { transition-delay: .3s !important; } .fan-card.lid-open .fc-body > :nth-child(5) { transition-delay: .4s !important; }
@media (prefers-reduced-motion: reduce) { .fan-card .fc-rod.top { transform: rotateX(-172deg) !important; } .fan-card .fc-body > * { opacity: 1 !important; transform: none !important; } }

/* gallery rail: a carved Pattachitra plank */
.track-inner::before { background: url("media/od-border.webp?v=1") 0 50% / auto 100% repeat-x !important; height: 34px !important; border-radius: 3px !important; box-shadow: 0 6px 12px rgba(60,20,0,.35) !important; }

/* egrets flap: two painted wing poses */
.eg { display: block; }
.eg img { position: absolute; left: 0; top: 0; width: 100%; height: auto; }
.eg .wu { position: relative; animation: flapA .5s steps(1) infinite; }
.eg .wd { animation: flapB .5s steps(1) infinite; }
.outro .eg.e2 img { animation-duration: .56s; } .outro .eg.e3 img { animation-duration: .6s; }
.eg { width: min(9vw, 46px) !important; } .outro .eg.e2 { width: min(7vw, 36px) !important; } .outro .eg.e3 { width: min(5.5vw, 28px) !important; }

/* ===== birds always in the sky: 5 parrots (hero) and 5 egrets (ending), staggered with
   negative delays so 4 or 5 are visible at any moment; tiny black birds far away ===== */
body.opened .od-birds .bird { animation: birdFly var(--fd, 16s) linear var(--fdl, 0s) infinite !important; width: var(--fw) !important; top: var(--ft) !important; opacity: 1; }
.od-birds .bird.b1 { --fw: min(12vw, 60px); --ft: 20%; --fd: 15s; --fdl: -2s; }
.od-birds .bird.b2 { --fw: min(9vw, 46px);  --ft: 29%; --fd: 18s; --fdl: -8s; }
.od-birds .bird.b3 { --fw: min(8vw, 40px);  --ft: 15%; --fd: 21s; --fdl: -14s; }
.od-birds .bird.b4 { --fw: min(10vw, 52px); --ft: 25%; --fd: 17s; --fdl: -5s; }
.od-birds .bird.b5 { --fw: min(7vw, 34px);  --ft: 34%; --fd: 20s; --fdl: -11s; }
.outro .eg { animation: egretGlide var(--ed, 18s) linear var(--edl, 0s) infinite !important; width: var(--ew) !important; top: var(--et) !important; }
.outro .eg.e1 { --ew: min(16vw, 92px); --et: 34%; --ed: 17s; --edl: -3s; }
.outro .eg.e2 { --ew: min(12vw, 70px); --et: 41%; --ed: 20s; --edl: -9s; }
.outro .eg.e3 { --ew: min(10vw, 58px); --et: 29%; --ed: 23s; --edl: -15s; }
.outro .eg.e4 { --ew: min(13vw, 76px); --et: 45%; --ed: 19s; --edl: -6s; }
.outro .eg.e5 { --ew: min(9vw, 50px);  --et: 37%; --ed: 22s; --edl: -12s; }
/* far away black birds: very small */
.hero-art .birds .bird { width: calc(var(--s) * .6) !important; }
/* keep the birds on screen most of the time, and let the size variables win */
@keyframes egretGlide2 { 0% { left: -12%; opacity: 0; transform: translateY(0); } 4% { opacity: .95; } 50% { transform: translateY(-16px); } 96% { opacity: .95; } 100% { left: 104%; opacity: 0; transform: translateY(4px); } }
@keyframes birdFly2 { 0% { left: -12%; opacity: 0; transform: translateY(0) rotate(-4deg); } 4% { opacity: 1; } 25% { transform: translateY(-18px) rotate(2deg); } 50% { transform: translateY(6px) rotate(-3deg); } 75% { transform: translateY(-12px) rotate(2deg); } 96% { opacity: 1; } 100% { left: 104%; opacity: 0; } }
html body .outro .od-egrets .eg { animation-name: egretGlide2 !important; width: var(--ew) !important; }
html body.opened .od-birds .bird { animation-name: birdFly2 !important; width: var(--fw) !important; }

html body.opened .od-birds .bird.b1, html body.opened .od-birds .bird.b2, html body.opened .od-birds .bird.b3, html body.opened .od-birds .bird.b4, html body.opened .od-birds .bird.b5 { width: var(--fw) !important; top: var(--ft) !important; }


/* ===================== Pattachitra pop-up plaque (family & wishes) =====================
   carved plank on top · red lacquer stand widening to the base · ivory card with cut corners
   and gold dividers · carved base plank. It rises from the base as the guest scrolls. */
.fan-card { perspective: none !important; padding: 0 0 6px; }
.fan-card .fc-rod { display: block !important; position: absolute !important; left: -4% !important; right: -4% !important; height: auto !important;
  aspect-ratio: 1400 / 314; background: url("media/od-cover.webp?v=1") center / 100% 100% no-repeat !important; border-radius: 0 !important;
  box-shadow: none !important; filter: drop-shadow(0 8px 10px rgba(60,20,0,.35)) !important; translate: 0 0 !important; transition: none !important; z-index: 4; }
.fan-card .fc-rod::before, .fan-card .fc-rod::after { display: none !important; content: none !important; }
.fan-card .fc-rod.bot { top: auto !important; bottom: -2% !important; transform: none !important; }
.fan-card .fc-rod.top, .fan-card.open .fc-rod.top { top: -2% !important;
  transform: translateY(calc((1 - var(--lid, 0)) * (var(--h, 500px) - 22%))) !important; }
/* the red lacquer stand (wider at the base) with the ivory card inside */
.fan-card .fc-body, .fan-card.open .fc-body {
  position: relative; z-index: 2; border-radius: 0 !important; margin: 0 2%;
  padding: calc(14% + 34px) 13% calc(14% + 40px) !important;
  background: linear-gradient(180deg, #b8321f, #8f2315) !important;
  clip-path: polygon(6% 0, 94% 0, 100% 100%, 0 100%) !important;
  box-shadow: none !important;
  transform-origin: 50% 100%; transform: scaleY(calc(.08 + var(--lid, 0) * .92)) !important; transition: none !important;
}
.fan-card .fc-body::before { content: '' !important; display: block !important; position: absolute; inset: 9% 9% 11% 9%; z-index: -1; border: 0;
  background: radial-gradient(ellipse at 50% 40%, #fbf1dc, #f1dfbb 80%) !important;
  clip-path: polygon(22px 0, calc(100% - 22px) 0, 100% 22px, 100% calc(100% - 22px), calc(100% - 22px) 100%, 22px 100%, 0 calc(100% - 22px), 0 22px);
  box-shadow: inset 0 0 0 2px #c9952e, inset 0 0 0 7px #fbf1dc, inset 0 0 0 8px rgba(201,149,46,.6), inset 0 0 30px rgba(120,70,10,.18); }
.fan-card .fc-body::after { content: '❦'; display: block !important; position: absolute; left: 50%; top: calc(9% + 18px); translate: -50% 0; font-size: 26px; color: #c9952e; z-index: 0; }
.fan-card .fc-body h3 { font-family: var(--display) !important; color: #8f2315 !important; font-size: 30px !important; letter-spacing: 0 !important; text-transform: none !important; margin-top: 10px; }
.fan-card .fc-body h3::after { content: ''; display: block; width: min(70%, 300px); height: 10px; margin: 10px auto 2px;
  background: linear-gradient(#c9952e, #c9952e) center / 100% 1.5px no-repeat, radial-gradient(circle, #c9952e 0 4px, transparent 4.5px) center / 12px 12px no-repeat; }
.fan-card .fc-body .rel { color: #8a5a1a !important; font-family: var(--serif); font-style: normal; font-weight: 600; margin-top: 12px; }
.fan-card .fc-body .who { color: #2a160e !important; font-family: var(--serif); font-weight: 600; font-size: 21px; }
.fan-card .fc-body .who + .rel::before { content: ''; display: block; width: min(60%, 260px); height: 10px; margin: 6px auto 10px;
  background: linear-gradient(#c9952e, #c9952e) center / 100% 1.5px no-repeat, radial-gradient(circle, #c9952e 0 4px, transparent 4.5px) center / 12px 12px no-repeat; }
.fan-card .fc-body ul { list-style: none; padding: 0; margin: 10px 0 0; } .fan-card .fc-body li { color: #2a160e; font-family: var(--serif); font-weight: 600; font-size: 19px; margin: 6px 0; }
.fan-card .fc-orn img.orn-img { width: 78% !important; margin-top: 12px; }
/* the details appear once the plaque has risen */
.fan-card .fc-body > * { opacity: 0 !important; transition: opacity .5s ease !important; }
.fan-card.lid-open .fc-body > * { opacity: 1 !important; }
.fan-card { margin-top: 70px !important; margin-bottom: 70px !important; width: min(100% - 40px, 520px) !important; }
@media (prefers-reduced-motion: reduce) { .fan-card .fc-body { transform: none !important; } .fan-card .fc-rod.top { transform: none !important; } .fan-card .fc-body > * { opacity: 1 !important; } }

/* ===================== sky: birds spread evenly, always moving; tiny black birds; more cloud ===================== */
@keyframes birdFlyR { 0% { left: 104%; opacity: 0; transform: translateY(0); } 4% { opacity: 1; } 30% { transform: translateY(14px); } 60% { transform: translateY(-10px); } 96% { opacity: 1; } 100% { left: -12%; opacity: 0; } }
@keyframes egretGlideR { 0% { left: 104%; opacity: 0; transform: translateY(0); } 4% { opacity: .95; } 50% { transform: translateY(-14px); } 96% { opacity: .95; } 100% { left: -12%; opacity: 0; } }
html body.opened .od-birds .bird { --fd: 20s !important; }
.od-birds .bird.b1 { --fdl: 0s !important; --ft: 18% !important; } .od-birds .bird.b2 { --fdl: -3.3s !important; --ft: 27% !important; }
.od-birds .bird.b3 { --fdl: -6.6s !important; --ft: 14% !important; } .od-birds .bird.b4 { --fdl: -10s !important; --ft: 31% !important; }
.od-birds .bird.b5 { --fdl: -13.3s !important; --ft: 22% !important; } .od-birds .bird.b6 { --fw: min(9vw, 44px); --fdl: -16.6s !important; --ft: 36% !important; }
html body.opened .od-birds .bird.rtl { animation-name: birdFlyR !important; }
.od-birds .bird.rtl img { transform: scaleX(-1); }
.outro .eg { --ed: 21s !important; }
.outro .eg.e1 { --edl: 0s !important; } .outro .eg.e2 { --edl: -4.2s !important; } .outro .eg.e3 { --edl: -8.4s !important; } .outro .eg.e4 { --edl: -12.6s !important; } .outro .eg.e5 { --edl: -16.8s !important; }
html body .outro .od-egrets .eg.rtl { animation-name: egretGlideR !important; }
.outro .eg.rtl img { transform: scaleX(-1); }
.hero-art .birds .bird { width: calc(var(--s) * 1.4) !important; }
.hero-art .bird svg { opacity: .8 !important; fill: #2a1a1a; }
.sky-drift { height: 48% !important; }
.sky-drift i:nth-child(1) { opacity: .55 !important; } .sky-drift i:nth-child(2) { opacity: .4 !important; }

/* gallery: Odisha carved teak beam with brass rings, and carved wooden frames */
.track-inner::before { background: url("media/od-beam.webp?v=1") 0 0 / auto 100% repeat-x !important; height: 64px !important; border-radius: 0 !important; box-shadow: none !important; filter: drop-shadow(0 10px 12px rgba(40,20,5,.35)); }
.frame3d .moulding { background: none !important; box-shadow: none !important; border-style: solid; border-width: 52px 30px 34px 30px;
  border-image: url("media/od-wood-frame.webp?v=1") 175 104 105 92 fill / 52px 30px 34px 30px stretch; filter: drop-shadow(0 14px 16px rgba(40,20,5,.35)); }
.frame3d .moulding .mat { margin: 0 !important; }
.frame3d .cords .ring { display: none; }
/* carved planks on top and at the base (override the older box/lid rules) */
html .fan-card .fc-rod.top, html .fan-card .fc-rod.bot {
  display: block !important; position: absolute !important; left: -4% !important; right: -4% !important; width: auto !important; height: auto !important;
  aspect-ratio: 1400 / 314 !important; background: url("media/od-cover.webp?v=1") center / 100% 100% no-repeat !important;
  border-radius: 0 !important; box-shadow: none !important; filter: drop-shadow(0 8px 10px rgba(60,20,0,.35)) !important; z-index: 4 !important; }
html .fan-card .fc-rod.bot { top: auto !important; bottom: -2% !important; transform: none !important; }
html .fan-card .fc-rod.top { top: -2% !important; transform: translateY(calc((1 - var(--lid, 0)) * (var(--h, 500px) * .78))) !important; }
html .fan-card .fc-rod.top::before, html .fan-card .fc-rod.top::after, html .fan-card .fc-rod.bot::before, html .fan-card .fc-rod.bot::after { content: none !important; display: none !important; }

html .fan-card .fc-rod.bot { bottom: 0 !important; translate: 0 45% !important; }
html .fan-card { margin-bottom: 110px !important; }

html .fan-card .fc-rod.bot { translate: 0 -12% !important; }

/* ---------- folded Pattachitra booklet (families, wishes, note) ---------- */
.kp-book { position: relative; width: min(100%, 500px); margin: 24px auto 40px; perspective: 1500px; perspective-origin: 50% 35%; }
.kp-tilt { position: absolute; inset: 0; transform-style: preserve-3d; transform-origin: 50% 50%; will-change: transform; }
.kp-board { position: absolute; left: 0; top: 0; width: 100%; height: auto; display: block; pointer-events: none; will-change: transform;
  filter: drop-shadow(0 8px 10px rgba(70, 25, 5, .32)); }
.kp-page { position: absolute; left: 6.5%; right: 6.5%; top: 0; transform-origin: 50% 0; display: grid; align-content: center; will-change: transform;
  background:
    linear-gradient(90deg, #8f2315 0 3px, transparent 3px 6px, #c39a45 6px 7.5px, transparent 7.5px) left top / 12px 100% no-repeat,
    linear-gradient(270deg, #8f2315 0 3px, transparent 3px 6px, #c39a45 6px 7.5px, transparent 7.5px) right top / 12px 100% no-repeat,
    #f7e9c9 url("media/kp-paper.webp?v=1") 0 0 / 400px auto; }
/* fold shading: pages facing down darken, pages facing up catch the light, creases show at each fold */
.kp-page::before, .kp-page::after { content: ''; position: absolute; inset: 0; pointer-events: none; opacity: var(--f, 0); }
.kp-page::before { background: linear-gradient(180deg, rgba(110, 50, 10, .38), rgba(110, 50, 10, 0) 22%, rgba(110, 50, 10, 0) 80%, rgba(110, 50, 10, .22)); }
.kp-page.dn::after { background: rgba(60, 22, 4, .5); }
.kp-page.up::after { background: linear-gradient(180deg, rgba(255, 226, 160, .3), rgba(255, 226, 160, 0)); }
.kp-book.is-open .kp-page::before { opacity: .22; }
.kp-in { position: relative; z-index: 1; padding: 20px 12%; text-align: center; opacity: var(--t, 1); transform: translateY(calc((1 - var(--t, 1)) * 10px)); }
.kp-in h3 { margin: 0; font-family: var(--display); font-weight: 400; font-size: clamp(28px, 8vw, 38px); line-height: 1.15; color: #8f2315; }
.kp-in .rel { margin: 0 0 6px; font-family: var(--serif); font-weight: 600; font-size: 17px; color: #7a4c12; letter-spacing: .02em; }
.kp-in .who { margin: 0; font-family: var(--serif); font-weight: 600; font-size: clamp(18px, 5vw, 21px); line-height: 1.45; color: #2a160e; }
.kp-in ul { list-style: none; margin: 0; padding: 0; }
.kp-in li { font-family: var(--serif); font-weight: 600; font-size: 18px; line-height: 1.4; color: #2a160e; margin: 4px 0; }
.kp-orn { display: block; width: 86%; height: auto; margin: 0 auto; }
span.kp-orn { height: 2px; background: #c39a45; }
.kp-glow { position: absolute; left: 10%; right: 10%; top: 0; height: 0; pointer-events: none; opacity: 0; border-radius: 50%;
  background: radial-gradient(ellipse at 50% 50%, rgba(255, 216, 128, .9), rgba(255, 178, 70, .35) 45%, rgba(255, 178, 70, 0) 72%); filter: blur(4px); }
@media (min-width: 900px) {
  .families .wrap:has(> .kp-book + .kp-book) { grid-template-columns: 1fr 1fr; align-items: start; max-width: 1080px; column-gap: 48px; }
  .kp-in h3 { font-size: 38px; }
}
/* booklet text is printed on the paper: it folds and opens with the pages */
.kp-in { opacity: 1; transform: none; }

/* ---------- birds flying home at dusk: V formations, all heading the same way ---------- */
.kp-sky { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 1; }
.kp-vee { position: absolute; left: 0; top: var(--top); width: 100%; height: 0; will-change: transform;
  --gx: calc(var(--u) * 1.05); --gy: calc(var(--u) * .42);
  animation: veeHome var(--dur) linear var(--dl) infinite; }
.kp-vee .vb { position: absolute; left: calc(var(--x) * var(--gx)); top: calc(var(--y) * var(--gy)); width: calc(var(--w) * var(--u));
  animation: vbBob 2.8s ease-in-out var(--bd) infinite alternate; }
@keyframes veeHome { from { transform: translate3d(calc(var(--u) * -1.3), 0, 0); } to { transform: translate3d(calc(100% + var(--u) * 6), var(--climb, -24px), 0); } }
@keyframes vbBob { from { translate: 0 -3px; } to { translate: 0 3px; } }
.kp-vee.egret .vb img { position: absolute; left: 0; top: 0; width: 100%; height: auto; display: block; }
.kp-vee.egret .vb .wu { position: relative; animation: flapA var(--fl) steps(1) infinite; }
.kp-vee.egret .vb .wd { animation: flapB var(--fl) steps(1) infinite; }
.kp-vee.egret.a { --u: clamp(24px, 4.6vw, 50px); --top: 30%; --dur: 34s; --dl: -9s; }
.kp-vee.egret.b { --u: clamp(15px, 2.8vw, 30px); --top: 17%; --dur: 48s; --dl: -31s; --climb: -14px; opacity: .9; }
.kp-vee.ink { --gx: calc(var(--u) * 1.5); --gy: calc(var(--u) * .75); }
.kp-vee.ink .vb svg { display: block; width: 100%; fill: #2a1a1a; opacity: .82; transform-origin: 50% 60%; animation: inkFlap var(--fl) ease-in-out infinite alternate; }
@keyframes inkFlap { from { transform: scaleY(1); } to { transform: scaleY(.3); } }
.kp-vee.ink.a { --u: clamp(9px, 1.5vw, 15px); --top: 12%; --dur: 30s; --dl: -7s; }
.kp-vee.ink.b { --u: clamp(7px, 1.1vw, 11px); --top: 22%; --dur: 41s; --dl: -25s; --climb: -12px; }
@media (prefers-reduced-motion: reduce) { .kp-vee { animation: none; transform: translateX(46%); } .kp-vee .vb, .kp-vee .vb svg, .kp-vee .vb img { animation: none !important; } .kp-vee .vb .wd { display: none; } }
/* near skein crosses the open sky between the farewell text and the horizon */
.kp-vee.egret.a { --top: 53%; }
@media (min-width: 900px) { .kp-vee.egret.a { --top: 49%; } }
.kp-vee.egret { --gx: calc(var(--u) * 1.0); --gy: calc(var(--u) * .56); }

/* ---------- water: the lake's own reflections waver; nothing outside the water mask moves ---------- */
.fx-ripple { position: absolute; inset: 0; pointer-events: none; z-index: 0;
  -webkit-mask: var(--wm) 0 0 / 100% 100% no-repeat; mask: var(--wm) 0 0 / 100% 100% no-repeat; }
.fx-ripple .rs { position: absolute; inset: 0; overflow: hidden; }
.fx-ripple .rs i { position: absolute; inset: -3px -6px; background: var(--scene-img) center / calc(100% - 12px) calc(100% - 6px) no-repeat; will-change: transform; }
/* fine bands near the horizon, wider ones toward the viewer (static masks, moving picture = compositor only) */
.fx-ripple .rs.a { -webkit-mask: repeating-linear-gradient(180deg, #000 0 1.2px, transparent 1.2px 3.4px); mask: repeating-linear-gradient(180deg, #000 0 1.2px, transparent 1.2px 3.4px); opacity: .85; }
.fx-ripple .rs.b { -webkit-mask: repeating-linear-gradient(180deg, transparent 0 3px, #000 3px 5.5px, transparent 5.5px 8px); mask: repeating-linear-gradient(180deg, transparent 0 3px, #000 3px 5.5px, transparent 5.5px 8px); opacity: .7; }
.fx-ripple .rs.a i { animation: waverA 3.1s ease-in-out infinite alternate; }
.fx-ripple .rs.b i { animation: waverB 4.3s ease-in-out -1.6s infinite alternate; }
@keyframes waverA { 0% { transform: translate3d(-2.4px, -1px, 0); } 50% { transform: translate3d(1.2px, 1.4px, 0); } 100% { transform: translate3d(2.6px, -.6px, 0); } }
@keyframes waverB { 0% { transform: translate3d(3px, 1.6px, 0); } 50% { transform: translate3d(-1.5px, -1.2px, 0); } 100% { transform: translate3d(-3.2px, 1px, 0); } }
/* warm glints drifting on the surface (the sun's light, not white streaks) */
.fx-ripple .glint { position: absolute; inset: 0 -200px; opacity: .5; mix-blend-mode: screen; will-change: transform;
  background: radial-gradient(1.4px 0.9px at 20% 30%, #ffe3a3 98%, transparent), radial-gradient(1.8px 0.9px at 63% 72%, #ffd58a 98%, transparent),
    radial-gradient(1.2px 0.8px at 82% 18%, #fff0c8 98%, transparent), radial-gradient(1.6px 0.9px at 41% 88%, #ffd58a 98%, transparent);
  background-size: 90px 26px, 130px 34px, 70px 22px, 110px 30px;
  animation: glintDrift 11s linear infinite, glintPulse 2.2s ease-in-out infinite alternate; }
@keyframes glintDrift { to { transform: translate3d(-90px, 0, 0); } }
@keyframes glintPulse { from { opacity: .25; } to { opacity: .6; } }
@media (prefers-reduced-motion: reduce) { .fx-ripple .rs i, .fx-ripple .glint { animation: none; } }

/* ceremony leaves (phones, tablets): carving + thread on one end, medallion on the other,
   the writing centred between them so neither half of the leaf is left bare */
@media (max-width: 899px) {
  .leaf, .leaf.rt { text-align: center; }
  .leaf .leaf-text { display: flex; flex-direction: column; align-items: center; }
  .leaf .leaf-map, .leaf.rt .leaf-map { margin-left: 0; margin-right: 0; }
  .leaf.rt { padding-left: clamp(40px, 13%, 92px); }
  .leaf.lt { padding-right: clamp(40px, 13%, 92px); }
}
/* wider strips (560–899px): medallion · details · venue button, mirrored on alternate leaves */
@media (min-width: 560px) and (max-width: 899px) {
  .leaf, .leaf.rt { width: min(100%, 680px); }
  .leaf .leaf-text { display: grid; grid-template-columns: 1fr auto; column-gap: clamp(14px, 3vw, 28px); align-items: center; justify-items: center; }
  .leaf .leaf-text > :not(.leaf-map) { grid-column: 1; }
  .leaf .leaf-map { grid-column: 2; grid-row: 1 / span 4; margin: 0; }
  .leaf.rt .leaf-text { grid-template-columns: auto 1fr; }
  .leaf.rt .leaf-text > :not(.leaf-map) { grid-column: 2; }
  .leaf.rt .leaf-map { grid-column: 1; }
  .leaf-venue { margin-bottom: 0; }
}

/* ===================== gallery: carved beam, lion hooks, carved frames (artwork by the user) =====================
   Beam = seamless middle strip + swan end caps whose plank matches the strip height.
   Each frame hangs by one cord from a hook directly above it; the cord sits inside .swing,
   so it swings with the frame around the hook. */
html .gallery { --hb: 34px; --hook: 48px; }
@media (max-width: 899px) { html .gallery { --hb: 26px; --hook: 38px; } }
html .gallery .track-inner { padding-top: calc(var(--hb) * 1.7); }
html .gallery .track-inner::before { display: block !important; top: calc(var(--hb) * 1.7) !important; height: var(--hb) !important; left: calc(var(--hb) * 1.5) !important; right: calc(var(--hb) * 1.5) !important;
  background: url("media/kp-beam-mid.webp?v=1") 0 0 / auto 100% repeat-x !important; border-radius: 0 !important; box-shadow: none !important;
  filter: drop-shadow(0 8px 10px rgba(40, 20, 5, .3)); }
html .gallery .track-inner::after { content: ''; position: absolute; left: 0; right: 0; pointer-events: none;
  top: calc(var(--hb) * 1.7 - var(--hb) * 1.61); height: calc(var(--hb) * 4.79);
  background: url("media/kp-cap-l.webp?v=1") left top / auto 100% no-repeat, url("media/kp-cap-r.webp?v=1") right top / auto 100% no-repeat;
  filter: drop-shadow(0 8px 10px rgba(40, 20, 5, .3)); }
html .gallery .frame3d { --fw: min(68vw, 330px, 40vh); width: var(--fw) !important; --cordh: calc(var(--hb) + 60px + var(--drop)); }
html .gallery .frame3d.landscape { --fw: min(80vw, 440px, 52vh); }
@media (max-width: 899px) { html .gallery .frame3d { --cordh: calc(var(--hb) + 40px + var(--drop) * .5); } }
html .gallery .cords { position: relative; height: var(--cordh); visibility: visible; }
html .gallery .cords svg, html .gallery .cords .ring { display: none !important; }
html .gallery .kp-hook { position: absolute; left: 50%; top: calc(var(--hb) * .05); width: var(--hook); height: auto; translate: -50% 0; z-index: 3; filter: drop-shadow(0 3px 3px rgba(40, 20, 5, .4)); }
html .gallery .swing { position: relative; }
/* the cord: from the hook's ring down to the ring on top of the frame */
html .gallery .swing::before { content: ''; position: absolute; left: 50%; width: 3px; margin-left: -1.5px; z-index: 2;
  top: calc(-1 * var(--cordh) + var(--hb) * .05 + var(--hook) * .9); height: calc(var(--cordh) - var(--hb) * .05 - var(--hook) * .9 + var(--fw) * .02);
  background: repeating-linear-gradient(160deg, #7a2a12 0 3px, #c9a25a 3px 5px, #8a3a1a 5px 7px); border-radius: 2px; box-shadow: 1px 1px 2px rgba(0, 0, 0, .25); }
/* carved frames, sliced at the measured opening (portrait 1030x1369, landscape 1319x1060) */
html .gallery .frame3d .moulding { background: none !important; box-shadow: none !important; padding: 0 !important; border-style: solid; border-radius: 0 !important;
  border-width: calc(var(--fw) * 350 / 1030) calc(var(--fw) * 151 / 1030) calc(var(--fw) * 151 / 1030) calc(var(--fw) * 150 / 1030);
  border-image: url("media/kp-frame-p.webp?v=1") 350 151 151 150 fill / calc(var(--fw) * 350 / 1030) calc(var(--fw) * 151 / 1030) calc(var(--fw) * 151 / 1030) calc(var(--fw) * 150 / 1030) stretch;
  filter: drop-shadow(0 14px 14px rgba(40, 20, 5, .32)); }
html .gallery .frame3d.landscape .moulding {
  border-width: calc(var(--fw) * 326 / 1319) calc(var(--fw) * 125 / 1319) calc(var(--fw) * 132 / 1319) calc(var(--fw) * 125 / 1319);
  border-image: url("media/kp-frame-l.webp?v=1") 326 125 132 125 fill / calc(var(--fw) * 326 / 1319) calc(var(--fw) * 125 / 1319) calc(var(--fw) * 132 / 1319) calc(var(--fw) * 125 / 1319) stretch; }
html .gallery .frame3d .moulding::after { display: none !important; }
/* one clean cream mat inside the opening (no double border) */
html .gallery .frame3d .mat { margin: 0 !important; padding: 8px 8px 6px !important; background: #fbf6ec !important; border-radius: 0 !important;
  box-shadow: inset 0 0 0 1px rgba(150, 110, 40, .35), inset 0 2px 6px rgba(0, 0, 0, .18) !important; }
html .gallery .frame3d .mat img, html .gallery .frame3d .mat .ph { border-radius: 0 !important; box-shadow: none !important; }
html .gallery .frame3d .mat figcaption { padding-top: 4px; }
