/* ============ Dawat invitation page ============ */

:root {
  --script: 'Great Vibes', cursive;
  --serif: 'Cormorant Garamond', 'Cormorant', Georgia, serif;
  --col: 480px;
  --noise: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 .09 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
  --tear: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 120 16' preserveAspectRatio='none'><path d='M0 16 L0 9 L6 6 L11 9 L17 4 L24 8 L30 5 L37 10 L44 6 L50 8 L57 3 L64 7 L71 5 L78 9 L85 4 L92 8 L99 5 L106 9 L113 6 L120 9 L120 16Z'/></svg>");
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  background: var(--bg) var(--noise);
  color: var(--ink);
  --body2: color-mix(in srgb, var(--muted) 45%, var(--ink)); /* addresses and notes: softer than the ink, still easy to read */
  font-family: var(--serif);
  font-size: 19px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
body.locked { overflow: hidden; height: 100svh; }
a { color: inherit; }
button { font: inherit; color: inherit; }
img { display: block; max-width: 100%; }
.noscript { padding: 40px; text-align: center; }

.card {
  position: relative;
  max-width: var(--col);
  margin: 0 auto;
  min-height: 100svh;
  background: var(--page);
  box-shadow: 0 0 80px rgba(40, 25, 10, .16);
  overflow: clip;
  container-type: inline-size;
}

.script { font-family: var(--script); font-weight: 400; line-height: 1.12; }
.title { color: var(--accent); font-size: clamp(2.1rem, 9.6cqi, 2.8rem); margin-bottom: 6px; text-wrap: balance; }
.big { font-size: 2.6rem; color: var(--accent); }
.lead { font-size: 1.18rem; color: var(--ink); max-width: 30ch; margin: 0 auto 14px; text-wrap: balance; }
.lead.note { margin-top: 18px; }

.orn { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 12px auto 26px; }
.orn::before, .orn::after { content: ''; width: 70px; height: 1px; background: var(--line); }
.orn span { width: 7px; height: 7px; background: var(--accent); transform: rotate(45deg); }

/* ---------- sections & torn edges ---------- */

.sec { position: relative; padding: 76px 22px 70px; text-align: center; background: var(--page); }
.sec.alt { background: var(--paper) var(--noise); }
.tear {
  position: absolute; left: 0; right: 0; top: -15px; height: 16px;
  background: inherit;
  -webkit-mask: var(--tear) bottom / 140px 16px repeat-x;
  mask: var(--tear) bottom / 140px 16px repeat-x;
}

/* ---------- reveal animations ---------- */

.reveal { opacity: 0; transform: translateY(18px); transition: opacity .55s ease, transform .6s ease; }
.reveal.in { opacity: 1; transform: none; }
/* Inside the card, things surface slowly from below: tipped back in 3D, slightly blurred, then settling flat. */
.sec, .hero-content { perspective: 900px; }
.card .reveal {
  transform: translateY(46px) rotateX(16deg) scale(.97); transform-origin: 50% 100%; filter: blur(5px);
  transition: opacity .7s ease, transform 1s cubic-bezier(.16, .84, .3, 1), filter .6s ease, rotate .5s cubic-bezier(.2, .7, .3, 1);
}
.card .reveal.above { transform: translateY(-46px) rotateX(-16deg) scale(.97); transform-origin: 50% 0; }
.card .reveal.in { opacity: 1; transform: none; filter: none; }
.rise { opacity: 0; transform: translateY(34px) rotateX(18deg); transform-origin: 50% 100%; filter: blur(6px); }
body.play .rise { animation: rise 1.9s cubic-bezier(.16, .84, .3, 1) forwards; }
body.play .rise:nth-child(2) { animation-delay: .3s; }
body.play .hero-names .rise:nth-child(1) { animation-delay: .5s; }
body.play .hero-names .rise:nth-child(2) { animation-delay: .9s; }
body.play .hero-names .rise:nth-child(3) { animation-delay: 1.3s; }
body.play .scroll-down.rise { animation-delay: 2.2s; }
@keyframes rise { 60% { filter: none; } to { opacity: 1; transform: none; filter: none; } }
body.static .reveal, body.static .rise { opacity: 1; transform: none; filter: none; animation: none; transition: none; }

/* 3D lean (set from motion.js through the separate `rotate` property, so it never fights the reveal) */
.cd-item, .ev, .portrait, .rsvp-form, .phone, .sc-card, .hero-content, .blessing {
  transition: rotate .5s cubic-bezier(.2, .7, .3, 1); transform-style: preserve-3d; will-change: rotate;
}
.hero-content, .bouquet-wrap { transition: rotate .5s cubic-bezier(.2, .7, .3, 1), translate .25s linear, opacity .25s linear; }
.sec-garland, .garland-foot, .portrait-wreath, .mandala-foot { transition: translate .4s ease-out, scale .6s cubic-bezier(.2, .7, .3, 1); }
/* garlands and the photo wreath sway softly */
.sec-garland svg, .garland-foot svg { transform-origin: 50% 30%; animation: garland-sway 6s ease-in-out infinite alternate; }
.portrait-wreath svg { animation: wreath-sway 9s ease-in-out infinite alternate; }
@keyframes garland-sway { from { transform: rotate(-1.4deg) translateY(-1px); } to { transform: rotate(1.4deg) translateY(2px) scaleY(1.03); } }
@keyframes wreath-sway { from { transform: rotate(-2.5deg); } to { transform: rotate(2.5deg) scale(1.02); } }
body.static .sec-garland svg, body.static .garland-foot svg, body.static .portrait-wreath svg { animation: none; }
/* a family's name on the outside of the opening, like the name on the back of a printed card */
.guest-tag {
  position: absolute; z-index: 6; left: 8%; right: 8%;
  display: flex; flex-direction: column; align-items: center; text-align: center; line-height: 1.15;
  pointer-events: none; transition: opacity .45s ease;
  animation: fade-up 1.2s ease .9s both;
}
.gt-label { font-size: .62rem; font-weight: 600; letter-spacing: .32em; text-transform: uppercase; color: var(--muted); }
.gt-name { font-size: clamp(1.25rem, 6.4vw, 1.75rem); color: var(--accent); margin: 1px 0 2px; max-width: 100%; overflow-wrap: anywhere; }
.gt-seats { font-size: .7rem; font-weight: 600; letter-spacing: .16em; text-transform: uppercase; color: var(--ink); opacity: .75; }
.gt-seats::before, .gt-seats::after { content: '—'; margin: 0 .5em; opacity: .5; }
.opening .guest-tag, .opening.guest-tag { opacity: 0; }
/* envelope: written on the front pocket, under the seal */
.gt-env { top: 79.5%; }
.gt-env .gt-label { display: none; } /* like a name written on an envelope: just the name */
.gt-env .gt-name { font-size: clamp(1.05rem, 5vw, 1.45rem); margin-top: 0; }
body.lang-ur .gt-env { top: 78%; }
body.lang-ur .gt-env .gt-name { font-size: clamp(.95rem, 4.4vw, 1.25rem); line-height: 1.5; }
.env-screen.opening .guest-tag { opacity: 0; }
/* classic envelope: under "tap to open" */
.gt-classic { top: 75%; }
/* doors: a little plaque hung across the two doors */
.gt-doors {
  top: 74%; left: 50%; right: auto; translate: -50% 0; width: min(64%, 300px); padding: 10px 16px 9px;
  border-radius: 10px; border: 1px solid color-mix(in srgb, var(--accent2) 70%, transparent);
  background: color-mix(in srgb, var(--paper) 88%, transparent); box-shadow: 0 8px 18px rgba(30, 15, 5, .25), inset 0 0 0 3px color-mix(in srgb, var(--paper) 60%, transparent);
}
/* curtains: under the medallion, light on the velvet */
.gt-curtains { position: relative; left: auto; right: auto; max-width: 84vw; }
.gt-curtains .gt-label, .gt-curtains .gt-seats { color: #F6E7C8; opacity: .9; text-shadow: 0 2px 8px rgba(0, 0, 0, .6); }
.gt-curtains .gt-name { color: #FCEFD2; text-shadow: 0 2px 12px rgba(0, 0, 0, .6); }
body.lang-ur .gt-label, body.lang-ur .gt-seats { letter-spacing: 0; text-transform: none; font-size: .85rem; }
.seats-note { display: inline-block; margin: 4px auto 14px; padding: 7px 16px; border-radius: 99px; border: 1px solid color-mix(in srgb, var(--accent) 45%, transparent); color: var(--accent); font-weight: 600; letter-spacing: .02em; }
.seats-note .ur-sub { display: block; font-weight: 400; }
.scroll-petals { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 30; }
/* the home page's demo phone, scrolled out of view: everything holds still (invite.js, showcasePause) */
.sc-paused *, .sc-paused *::before, .sc-paused *::after { animation-play-state: paused !important; }
body.peek { overflow: hidden; }
body.peek .particles, body.peek .scroll-down { display: none; }

/* ============ envelope ============ */
/* A landscape envelope seen from the back: liner, card, pocket, hinged flap and wax seal.
   Opening: .opening (seal breaks) → .flap-open (flap folds up in 3D) → .card-out (card slides up)
   → .reveal (zoom into the card) → .done (fade to the invitation). */

.env-screen {
  position: fixed; inset: 0; z-index: 50;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 34px;
  padding: 24px 16px;
  background:
    radial-gradient(110% 70% at 50% 42%, color-mix(in srgb, var(--page) 70%, transparent), transparent 70%),
    var(--noise),
    var(--bg);
  transition: opacity .9s ease, visibility .9s;
  overflow: hidden;
}
.dark .env-screen { background: radial-gradient(110% 70% at 50% 42%, color-mix(in srgb, var(--paper) 80%, transparent), transparent 70%), var(--noise), var(--bg); }
.es-light {
  position: absolute; inset: -20%; pointer-events: none;
  background: repeating-linear-gradient(118deg, transparent 0 110px, rgba(255, 255, 255, .13) 110px 170px);
  -webkit-mask: radial-gradient(70% 60% at 30% 20%, #000, transparent 75%);
  mask: radial-gradient(70% 60% at 30% 20%, #000, transparent 75%);
  animation: light-drift 14s ease-in-out infinite alternate;
}
.dark .es-light { opacity: .35; }
@keyframes light-drift { to { transform: translateX(40px); } }
.es-kicker {
  position: relative; font-size: .86rem; letter-spacing: .42em; text-transform: uppercase; color: var(--accent);
  font-weight: 600; animation: fade-up 1.2s ease .2s both;
}
@keyframes fade-up { from { opacity: 0; transform: translateY(10px); } }

.env {
  --w: min(92vw, 460px, calc(58svh * 1.43));
  position: relative; width: var(--w); aspect-ratio: 10 / 7;
  perspective: 1400px; cursor: pointer; outline: none;
  -webkit-tap-highlight-color: transparent; user-select: none;
  animation: env-in 1.1s cubic-bezier(.2, .7, .2, 1) both;
  transition: transform .5s ease;
}
@keyframes env-in { from { opacity: 0; transform: translateY(26px) scale(.96); } }
.env:hover .seal, .env:focus-visible .seal { transform: translate(-50%, -50%) scale(1.06); }

/* paper */
.env-back, .env-pocket, .env-flap, .env-card { position: absolute; }
.env-back {
  inset: 0; z-index: 1; border-radius: 6px; overflow: hidden;
  background: color-mix(in srgb, var(--paper) 82%, #000);
  box-shadow: 0 34px 60px -18px rgba(40, 25, 10, .45), 0 10px 22px rgba(40, 25, 10, .16);
}
.env-liner { position: absolute; left: 4%; right: 4%; top: 3%; height: 66%; }
.env-liner svg, .env-flap.inside svg { display: block; width: 100%; height: 100%; }

.env-pocket {
  inset: 0; z-index: 3; border-radius: 6px;
  clip-path: polygon(0 0, 50% 60%, 100% 0, 100% 100%, 0 100%);
  background:
    radial-gradient(60% 40% at 50% 56%, rgba(0, 0, 0, .1), transparent 70%),
    linear-gradient(180deg, color-mix(in srgb, var(--paper) 94%, #fff), color-mix(in srgb, var(--paper) 90%, #000)),
    var(--noise);
  background-blend-mode: normal, normal, multiply;
}
.env-pocket svg, .env-flap.front svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.pk-fold { fill: none; stroke: rgba(60, 40, 20, .14); stroke-width: 1; vector-effect: non-scaling-stroke; }
.pk-fold-hi { fill: none; stroke: rgba(255, 255, 255, .5); stroke-width: 1; vector-effect: non-scaling-stroke; }
.dark .pk-fold { stroke: rgba(0, 0, 0, .4); }
.dark .pk-fold-hi { stroke: rgba(255, 255, 255, .06); }
.pk-gold, .fl-gold { fill: none; stroke: var(--accent); stroke-width: 1.2; vector-effect: non-scaling-stroke; opacity: .85; }
.fl-edge { fill: none; stroke: rgba(60, 40, 20, .16); stroke-width: 1; vector-effect: non-scaling-stroke; }
.fl-deckle { fill: none; stroke: rgba(255, 255, 255, .55); stroke-width: 1; vector-effect: non-scaling-stroke; }

.env-flap-wrap {
  position: absolute; left: 0; right: 0; top: 0; height: 60%; z-index: 4;
  transform-origin: 50% 0; transform-style: preserve-3d;
  transition: transform .95s cubic-bezier(.45, .05, .25, 1), z-index 0s linear .47s;
}
.env-flap { inset: 0; clip-path: polygon(0 0, 100% 0, 50% 100%); backface-visibility: hidden; -webkit-backface-visibility: hidden; }
.env-flap.front {
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--paper) 90%, #fff) 0%, color-mix(in srgb, var(--paper) 96%, #fff) 60%, color-mix(in srgb, var(--paper) 92%, #000) 100%),
    var(--noise);
  background-blend-mode: normal, multiply;
}
/* The inside face is drawn upside-down and pre-flipped, so once the flap swings open its point faces up. */
.env-flap.inside { transform: rotateX(180deg); clip-path: polygon(0 100%, 100% 100%, 50% 0); }
/* soft shadow the closed flap casts on the pocket */
.env-flap-wrap::after {
  content: ''; position: absolute; inset: 0 0 -6% 0; z-index: -1;
  clip-path: polygon(0 0, 100% 0, 50% 100%);
  background: linear-gradient(180deg, transparent 60%, rgba(40, 25, 10, .18));
  transform: translateZ(-1px); filter: blur(3px);
  transition: opacity .3s;
}
.env.flap-open .env-flap-wrap::after { opacity: 0; }

/* liner pattern colours */
.liner { width: 100%; height: 100%; }
.ln-bg { fill: color-mix(in srgb, var(--petal2) 55%, var(--page)); }
.ln-petal { fill: var(--petal); opacity: .75; }
.ln-core { fill: var(--accent2); }
.ln-leaf { fill: var(--leaf); opacity: .6; }
.env-jali .ln-bg, .env-gilded .ln-bg { fill: color-mix(in srgb, var(--seal) 85%, #000); }
.ln-line { fill: none; stroke: var(--accent2); stroke-width: .8; opacity: .55; }
.ln-dot { fill: var(--accent2); opacity: .7; }

/* the card inside */
.env-card {
  left: 6%; right: 6%; top: 5%; height: 90%; z-index: 2;
  border-radius: 4px; padding: 6%;
  background: radial-gradient(120% 80% at 50% 20%, color-mix(in srgb, var(--page) 70%, #fff), var(--page)), var(--noise);
  box-shadow: 0 2px 6px rgba(40, 25, 10, .15);
  transition: transform 1.05s cubic-bezier(.2, .75, .25, 1);
}
.ec-inner {
  position: relative; height: 100%; border: 1px solid var(--line); border-radius: 2px;
  display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 4px;
}
.ec-inner::before { content: ''; position: absolute; inset: 4px; border: 1px solid var(--line); opacity: .6; }
.ec-kicker { font-size: clamp(.55rem, 2.3vw, .72rem); letter-spacing: .32em; text-transform: uppercase; color: var(--muted); }
.ec-names { font-size: clamp(1.7rem, 8.4vw, 2.6rem); color: var(--accent); line-height: 1.05; display: flex; flex-wrap: wrap; justify-content: center; align-items: baseline; gap: 0 .25em; padding: 0 6px; }
.ec-names.long { font-size: clamp(1.4rem, 6.6vw, 2.1rem); }
.ec-amp { font-size: .65em; opacity: .8; }
.ec-date { font-size: clamp(.7rem, 2.8vw, .9rem); letter-spacing: .2em; color: var(--ink); font-weight: 600; }
.ec-orn { display: flex; align-items: center; gap: 8px; margin-top: 4px; }
.ec-orn::before, .ec-orn::after { content: ''; width: 28px; height: 1px; background: var(--line); }
.ec-orn span { width: 5px; height: 5px; background: var(--accent); transform: rotate(45deg); }

/* wax seal on the flap's tip, splits in two when tapped */
.seal {
  position: absolute; left: 50%; top: 60%; z-index: 5; width: 23%; aspect-ratio: 1;
  transform: translate(-50%, -50%);
  filter: drop-shadow(0 5px 6px rgba(40, 10, 10, .38));
  transition: transform .4s ease;
}
.seal-half { position: absolute; inset: 0; transition: transform .75s cubic-bezier(.5, 0, .75, 0), opacity .75s ease; }
.seal-half svg { width: 100%; height: 100%; overflow: visible; }
.seal-half.l { clip-path: polygon(-10% -10%, 53% -10%, 45% 30%, 56% 52%, 47% 75%, 52% 110%, -10% 110%); }
.seal-half.r { clip-path: polygon(53% -10%, 110% -10%, 110% 110%, 52% 110%, 47% 75%, 56% 52%, 45% 30%); }
.seal::after {
  content: ''; position: absolute; inset: -16%; border-radius: 50%;
  border: 1px solid var(--accent2); opacity: 0;
  animation: seal-pulse 2.6s ease-out 1.4s infinite;
}
@keyframes seal-pulse { 0% { opacity: .7; transform: scale(.8); } 100% { opacity: 0; transform: scale(1.35); } }

.env-hint {
  position: relative; display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-size: .78rem; letter-spacing: .26em; text-transform: uppercase; color: var(--muted);
  min-height: 2.6em; transition: opacity .4s;
  animation: fade-up 1.2s ease .6s both;
}
.env-hint .caret { width: 16px; height: 16px; animation: bob 1.6s ease-in-out infinite; }
@keyframes bob { 50% { transform: translateY(-4px); } }

/* ---- opening sequence ---- */
.opening .seal { transform: translate(-50%, -50%) scale(1.04); }
.opening .seal::after { animation: none; opacity: 0; }
.opening .seal-half.l { transform: translate(-28%, 70%) rotate(-28deg); opacity: 0; }
.opening .seal-half.r { transform: translate(28%, 70%) rotate(24deg); opacity: 0; }
.opening .env-hint { opacity: 0; }
.env.flap-open .env-flap-wrap { transform: rotateX(180deg); z-index: 1; }
.env.card-out .env-card { transform: translateY(-58%); }
.reveal .env {
  transform-origin: 50% 0;
  transform: translateY(32%) scale(2.3); opacity: 0;
  transition: transform 1.1s cubic-bezier(.6, 0, .3, 1), opacity .7s ease .35s;
}
.reveal .es-kicker { opacity: 0; transition: opacity .4s; }
.env-screen.done { opacity: 0; visibility: hidden; pointer-events: none; }

/* ============ hero ============ */

.hero {
  position: relative;
  height: 100svh; min-height: 640px; max-height: 980px;
  overflow: hidden;
  text-align: center;
}
.hero-scene { position: absolute; inset: 0; background: linear-gradient(180deg, var(--sky1) 0%, var(--sky2) 55%, var(--sky3) 100%); }
.sc-sun {
  position: absolute; left: 32%; top: 56%; width: 46cqi; aspect-ratio: 1; border-radius: 50%;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(255, 255, 255, .95) 0 8%, rgba(255, 244, 214, .6) 22%, transparent 68%);
}
.dark .sc-sun { background: radial-gradient(circle, rgba(255, 248, 225, .9) 0 6%, rgba(240, 220, 170, .25) 22%, transparent 60%); left: 66%; top: 34%; }
.sc-land { position: absolute; left: 0; right: 0; bottom: 22.5%; width: 100%; height: 13%; }
.sc-hill { fill: var(--hill); opacity: .75; }
.sc-hill.far { opacity: .6; }
.sc-tree { fill: var(--hill); opacity: .9; }
.sc-water {
  position: absolute; left: 0; right: 0; bottom: 0; height: 23%;
  background:
    repeating-linear-gradient(180deg, transparent 0 7px, rgba(255, 255, 255, .14) 7px 8px),
    linear-gradient(180deg, color-mix(in srgb, var(--sky2) 80%, #fff), var(--sky3));
}
.sc-glint {
  position: absolute; left: 32%; top: 0; width: 22%; height: 100%; transform: translateX(-50%);
  background: radial-gradient(50% 60% at 50% 0%, rgba(255, 255, 255, .55), transparent 70%);
  filter: blur(2px);
}
.dark .sc-glint { left: 66%; opacity: .5; }

.hero-photo { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-shade { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0, 0, 0, .35), rgba(0, 0, 0, .15) 45%, rgba(0, 0, 0, .45)); }

.arch { position: absolute; inset: 0; width: 100%; height: 100%; pointer-events: none; }
.arch .frame { fill: var(--page); }
.arch .gold { fill: none; stroke: var(--accent); stroke-width: 1.6; opacity: .75; }
.arch .gold.thin { stroke-width: .8; opacity: .5; }
.arch .gold-fill { fill: var(--accent); opacity: .8; }

.bouquet-wrap { position: absolute; bottom: -3%; width: 68%; pointer-events: none; }
.bouquet-wrap.l { left: -13%; }
.bouquet-wrap.r { right: -13%; transform: scaleX(-1); }
.bouquet-wrap.tl, .bouquet-wrap.tr { top: -2%; bottom: auto; width: 54%; }
.bouquet-wrap.tl { left: -12%; transform: scaleY(-1) rotate(-4deg); }
.bouquet-wrap.tr { right: -12%; transform: scale(-1, -1) rotate(-4deg); }
.bouquet { display: block; width: 100%; height: auto; }
.bouquet .b-leaf { fill: var(--leaf); opacity: .85; }
.bouquet .b-rose { fill: var(--petal); }
.bouquet .b-rose.ring { fill: none; stroke: rgba(255, 255, 255, .55); stroke-width: 1.4; }
.bouquet .b-swirl { fill: none; stroke: color-mix(in srgb, var(--petal) 70%, #6b2a2a); stroke-width: 1.2; opacity: .6; }
.bouquet .b-bloom { fill: var(--petal2); }
.bouquet .b-core { fill: var(--accent2); }
.bouquet .b-bud { fill: var(--petal); }

.particles { position: absolute; inset: 0; pointer-events: none; overflow: hidden; z-index: 1; }
.particles i { position: absolute; top: -6%; animation: fall linear infinite; }
.p-petals i { width: 13px; height: 10px; background: var(--petal); border-radius: 80% 0 80% 0; opacity: .85; }
.p-petals i.alt { background: var(--petal2); }
.p-marigold i {
  width: 14px; height: 14px; border-radius: 50%;
  background: radial-gradient(circle, #C2410C 0 18%, #F59E0B 20% 55%, #FBBF24 58%);
  box-shadow: 0 0 0 2px rgba(251, 191, 36, .35); opacity: .9;
}
.p-marigold i.alt { width: 9px; height: 9px; background: radial-gradient(circle, #B45309 0 20%, #FB923C 24%); }
.p-sparkles i {
  width: 9px; height: 9px; background: var(--accent2);
  clip-path: polygon(50% 0, 62% 38%, 100% 50%, 62% 62%, 50% 100%, 38% 62%, 0 50%, 38% 38%);
  animation-name: fall, twinkle; animation-timing-function: linear, ease-in-out;
  filter: drop-shadow(0 0 3px var(--accent2));
}
.p-sparkles i.alt { width: 5px; height: 5px; border-radius: 50%; clip-path: none; }
@keyframes twinkle { 50% { opacity: .2; } }
@keyframes fall {
  0% { translate: 0 0; rotate: 0deg; }
  50% { translate: 30px 55vh; rotate: 200deg; }
  100% { translate: -10px 110vh; rotate: 420deg; }
}

.hero-content {
  position: absolute; left: 13%; right: 13%; top: 11%; bottom: 20%;
  display: flex; flex-direction: column; align-items: center;
  z-index: 2;
}
.hero-headline { font-size: clamp(1.6rem, 7.5cqi, 2.2rem); color: var(--accent); margin-top: 6%; }
.hero-date { letter-spacing: .14em; font-weight: 600; font-size: 1.05rem; color: var(--ink); margin-top: 4px; }
.hero-names { max-width: 100%; display: flex; flex-direction: column; align-items: center; margin-top: 5%; font-weight: 400; }
.hero-names .script { max-width: 100%; font-size: clamp(3.2rem, 18cqi, 5.4rem); color: color-mix(in srgb, var(--accent) 80%, var(--ink)); line-height: 1.05; text-shadow: 0 1px 2px rgba(60, 35, 10, .3), 0 2px 18px rgba(255, 255, 255, .6); }
.hero-headline { color: color-mix(in srgb, var(--accent) 85%, var(--ink)); text-shadow: 0 1px 2px rgba(60, 35, 10, .22); }
.hero-names.long .script { font-size: clamp(2.6rem, 13cqi, 4.2rem); }
.hero-names .amp { font-size: clamp(1.8rem, 9cqi, 2.6rem) !important; margin: 2px 0; opacity: .85; }
.dark .hero-names .script { color: var(--accent); text-shadow: 0 2px 20px rgba(0, 0, 0, .35); }
.dark .hero-headline { color: var(--accent); text-shadow: none; }
.scroll-down { margin-top: auto; text-decoration: none; display: flex; flex-direction: column; align-items: center; color: var(--accent); }
.scroll-down .script { font-size: 1.7rem; }
.scroll-down .chev { width: 22px; height: 22px; animation: bob 1.8s ease-in-out infinite; }
.has-photo .hero-headline, .has-photo .hero-date, .has-photo .hero-names .script, .has-photo .scroll-down { color: #fff; text-shadow: 0 2px 14px rgba(0, 0, 0, .45); }

/* ============ welcome ============ */

.blessing { font-size: 1.9rem; color: var(--accent); line-height: 1.6; }

/* ============ countdown ============ */

.cd-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; max-width: 380px; margin: 18px auto 0; }
.cd-grid[hidden] { display: none; }
.cd-item { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.cd-ring { position: relative; width: 100%; aspect-ratio: 1; }
.cd-ring svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.cd-ring .trk { fill: color-mix(in srgb, var(--page) 70%, transparent); stroke: var(--line); stroke-width: 2.5; }
.cd-ring .prg { fill: none; stroke: var(--accent2); stroke-width: 3.5; stroke-linecap: round; transition: stroke-dashoffset .6s ease; }
.cd-num { position: absolute; inset: 0; display: grid; place-items: center; font-size: clamp(1.3rem, 6.5cqi, 1.8rem); font-weight: 500; color: var(--ink); font-variant-numeric: lining-nums tabular-nums; }
.cd-lbl { font-size: .95rem; color: var(--body2); letter-spacing: .04em; }
.cd-status { font-size: 2.3rem; color: var(--accent); margin-top: 16px; }
.cd-status:empty { display: none; }

.poppers { display: flex; align-items: center; justify-content: space-between; margin-top: 30px; }
.poppers .hint { font-style: italic; color: var(--body2); }
.popper { width: 64px; height: 64px; background: none; border: 0; cursor: pointer; transform: rotate(-8deg); transition: transform .2s; -webkit-tap-highlight-color: transparent; }
.popper.flip { transform: scaleX(-1) rotate(-8deg); }
.popper:hover { transform: rotate(-14deg) scale(1.06); }
.popper.flip:hover { transform: scaleX(-1) rotate(-14deg) scale(1.06); }
.popper.pop { animation: pop .35s ease; }
.popper.flip.pop { animation: pop-flip .35s ease; }
@keyframes pop { 40% { transform: rotate(-8deg) scale(.82); } }
@keyframes pop-flip { 40% { transform: scaleX(-1) rotate(-8deg) scale(.82); } }
.popper svg { width: 100%; height: 100%; overflow: visible; }
.pp-cone { fill: var(--accent2); }
.pp-stripe { fill: var(--seal); opacity: .9; }
.pp-mouth { fill: color-mix(in srgb, var(--accent) 80%, #000); }
.pp-streamer { fill: none; stroke: var(--petal); stroke-width: 2; stroke-linecap: round; }
.confetti { position: fixed; inset: 0; width: 100vw; height: 100vh; pointer-events: none; z-index: 70; }

/* ============ schedule ============ */

.tl { list-style: none; position: relative; text-align: left; padding: 0 0 0 40px; margin-top: 6px; }
.tl::before { content: ''; position: absolute; left: 13px; top: 10px; bottom: 30px; width: 1px; background: var(--line); }
.ev { position: relative; padding: 2px 0 40px; opacity: .55; transform: translateX(6px); transition: opacity .4s ease, transform .5s ease, rotate .5s cubic-bezier(.2, .7, .3, 1); }
.ev.on { opacity: 1; transform: none; }
.ev:last-child { padding-bottom: 6px; }
.mark { position: absolute; left: -38px; top: 2px; width: 22px; height: 22px; display: grid; place-items: center; }
.mark .diamond { width: 9px; height: 9px; border: 1px solid var(--accent); background: var(--paper); transform: rotate(45deg); transition: opacity .5s; }
.mark .bloom { position: absolute; inset: -6px; opacity: 0; transform: scale(.4) rotate(-40deg); transition: opacity .6s, transform .8s cubic-bezier(.2, .9, .3, 1.3); }
.ev.on .mark .bloom { opacity: 1; transform: none; }
.ev.on .mark .diamond { opacity: 0; }
.bloom .m-petal { fill: var(--accent2); stroke: var(--accent); stroke-width: .4; }
.bloom .m-core { fill: var(--seal); }
.dow { font-style: italic; color: var(--body2); font-size: 1.1rem; }
.date { color: var(--accent); font-weight: 600; letter-spacing: .05em; font-size: 1.2rem; }
.ev h3 { font-size: clamp(2.6rem, 13cqi, 3.3rem); color: var(--accent); margin: 2px 0 4px; }
.time { font-weight: 600; letter-spacing: .08em; font-size: 1.12rem; }
.venue { font-weight: 600; font-size: 1.28rem; margin-top: 8px; }
.addr, .ev-note { color: var(--body2); font-size: 1.12rem; }
.ev-note { font-style: italic; margin-top: 4px; }
/* the event's programme: time, then the moment, like a printed card's running order */
.program { list-style: none; margin: 12px 0 2px; padding: 10px 0 0; border-top: 1px solid color-mix(in srgb, var(--accent) 30%, transparent); display: grid; gap: 5px; max-width: 320px; }
.program li { display: flex; align-items: baseline; gap: 14px; font-size: 1.1rem; }
.p-time { flex: none; min-width: 74px; color: var(--accent); font-weight: 600; font-size: .95rem; letter-spacing: .04em; }
.p-title { min-width: 0; }
.actions { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 16px; }
.actions .btn { padding: 8px 15px; font-size: .95rem; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  padding: 9px 18px; border-radius: 999px;
  border: 1px solid var(--accent); background: transparent; color: var(--accent);
  font-family: var(--serif); font-weight: 600; font-size: .98rem; text-decoration: none; cursor: pointer;
  transition: background .2s, color .2s, transform .15s;
  -webkit-tap-highlight-color: transparent;
}
.btn:hover { background: color-mix(in srgb, var(--accent) 10%, transparent); }
.btn:active { transform: scale(.97); }
.btn.solid { background: var(--accent); color: var(--btnInk); }
.btn.solid:hover { background: color-mix(in srgb, var(--accent) 88%, #000); }
.btn.wide { width: 100%; padding: 13px; font-size: 1.08rem; }
.btn:disabled { opacity: .6; cursor: default; }

.cal { position: relative; }
.cal summary { list-style: none; }
.cal summary::-webkit-details-marker { display: none; }
.cal-menu {
  position: absolute; z-index: 5; top: calc(100% + 6px); left: 0; min-width: 210px;
  background: var(--page); border: 1px solid var(--line); border-radius: 14px; padding: 6px;
  box-shadow: 0 12px 30px rgba(40, 25, 10, .18);
}
.cal-menu a { display: block; padding: 9px 12px; border-radius: 9px; text-decoration: none; font-weight: 600; color: var(--ink); }
.cal-menu a:hover { background: var(--paper); }

/* ============ RSVP ============ */

.deadline { font-style: italic; color: var(--body2); margin-bottom: 4px; }
.rsvp-form, .rsvp-done {
  text-align: left; margin: 20px auto 0; max-width: 400px;
  background: var(--page); border: 1px solid var(--line); border-radius: 20px; padding: 24px 22px;
  box-shadow: 0 10px 30px rgba(40, 25, 10, .06);
}
.rsvp-done { text-align: center; display: grid; gap: 10px; justify-items: center; }
.field { display: block; margin-bottom: 16px; border: 0; }
.field > span, .field legend { display: block; font-size: .85rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin-bottom: 4px; }
.field input, .field textarea {
  width: 100%; font: inherit; font-size: 1.1rem; color: var(--ink);
  background: transparent; border: 0; border-bottom: 1px solid var(--line); padding: 6px 2px; border-radius: 0;
}
.field textarea { resize: vertical; border: 1px solid var(--line); border-radius: 10px; padding: 8px 10px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--accent); }
.field input::placeholder, .field textarea::placeholder { color: color-mix(in srgb, var(--muted) 70%, transparent); }
.choices { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 4px 0 18px; }
.choice {
  border: 1px solid var(--line); background: transparent; border-radius: 12px; padding: 10px 6px; cursor: pointer;
  font-weight: 600; font-size: 1rem; color: var(--muted); transition: all .2s;
}
.choice.on { border-color: var(--accent); background: color-mix(in srgb, var(--accent) 12%, transparent); color: var(--accent); }
.attend-bits[hidden] { display: none; }
.check { display: flex; align-items: center; gap: 10px; padding: 4px 0; font-size: 1.08rem; cursor: pointer; }
.check input { width: 18px; height: 18px; accent-color: var(--accent); }
.form-msg { color: var(--seal); font-size: .98rem; min-height: 1.2em; margin-bottom: 10px; }
.dark .form-msg { color: var(--petal); }

/* ============ help ============ */

.phones { display: grid; gap: 12px; max-width: 340px; margin: 20px auto 0; }
.phone {
  display: flex; align-items: center; justify-content: center; gap: 14px;
  padding: 12px 20px; border: 1px solid var(--accent); border-radius: 999px;
  text-decoration: none; color: var(--ink); background: color-mix(in srgb, var(--page) 60%, transparent);
  box-shadow: 0 4px 14px rgba(40, 25, 10, .06); transition: transform .15s, background .2s;
}
.phone:hover { background: color-mix(in srgb, var(--accent) 8%, var(--page)); }
.phone .ico { width: 22px; height: 22px; color: var(--accent); flex: none; }
.ph-text { display: flex; flex-direction: column; line-height: 1.2; font-size: 1.25rem; font-weight: 500; letter-spacing: .03em; }
.ph-text small { font-size: .8rem; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }

/* ============ closing ============ */

.closing { padding-bottom: 0; }
.portrait {
  width: min(80%, 320px); aspect-ratio: 1; margin: 0 auto 26px; border-radius: 50%;
  padding: 8px; background: conic-gradient(from 40deg, var(--accent2), var(--accent), var(--accent2), var(--accent), var(--accent2));
  box-shadow: 0 14px 34px rgba(40, 25, 10, .2);
}
.portrait img { width: 100%; height: 100%; object-fit: cover; border-radius: 50%; border: 4px solid var(--page); }
.closing-line { font-size: clamp(2.4rem, 12cqi, 3.2rem); color: var(--accent); }
.closing-names { font-size: clamp(2rem, 10cqi, 2.6rem); color: var(--ink); opacity: .85; margin-top: 4px; }
.garland-foot { width: 84%; margin: 26px auto 0; }
.sec-garland { width: 88%; max-width: 380px; margin: -26px auto 14px; }
.portrait-wrap { position: relative; width: min(74%, 300px); margin: 34px auto 38px; }
.portrait-wrap .portrait { width: 100%; margin: 0; }
.portrait-wreath { position: absolute; inset: -19%; z-index: 1; pointer-events: none; }
.made { padding: 16px 0 28px; font-size: .92rem; letter-spacing: .06em; color: var(--body2); }
.made a { color: var(--accent); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; }

/* ============ floating bits ============ */

.music-btn {
  position: fixed; z-index: 40;
  bottom: max(18px, env(safe-area-inset-bottom));
  right: max(16px, calc(50vw - var(--col) / 2 + 16px));
  width: 52px; height: 52px; border-radius: 50%; border: 0; padding: 0; cursor: pointer;
  display: grid; place-items: center; color: var(--sealInk);
  background: radial-gradient(circle at 35% 30%, color-mix(in srgb, var(--seal) 70%, #fff), var(--seal) 62%);
  box-shadow: 0 0 0 1.5px color-mix(in srgb, var(--accent) 65%, #fff), 0 0 0 4px color-mix(in srgb, var(--seal) 18%, transparent), 0 10px 24px -6px rgba(30, 10, 5, .45);
  -webkit-tap-highlight-color: transparent; transition: transform .25s;
}
.music-btn:active { transform: scale(.93); }
.music-btn .mb-icon { position: relative; z-index: 1; display: grid; place-items: center; }
.music-btn svg { width: 21px; height: 21px; }
/* a fine dashed ring that turns while music plays, like a record */
.music-btn .mb-ring {
  position: absolute; inset: 5px; border-radius: 50%;
  border: 1px dashed color-mix(in srgb, var(--sealInk) 55%, transparent); opacity: .7;
}
.music-btn.playing .mb-ring { animation: mb-spin 9s linear infinite; }
@keyframes mb-spin { to { transform: rotate(360deg); } }
.music-btn.playing::after {
  content: ''; position: absolute; inset: -6px; border-radius: 50%; border: 1px solid var(--seal);
  animation: seal-pulse 2.4s ease-out infinite; pointer-events: none;
}
.eq { display: flex; align-items: flex-end; gap: 2.5px; height: 16px; }
.eq i { width: 3px; border-radius: 2px; background: currentColor; transform-origin: bottom; animation: eq 1.1s ease-in-out infinite; }
.eq i:nth-child(1) { height: 45%; animation-delay: -.2s; }
.eq i:nth-child(2) { height: 100%; animation-delay: -.65s; }
.eq i:nth-child(3) { height: 70%; animation-delay: -.4s; }
.eq i:nth-child(4) { height: 55%; animation-delay: -.9s; }
@keyframes eq { 0%, 100% { transform: scaleY(.35); } 50% { transform: scaleY(1); } }
.music-btn .mb-hint {
  position: absolute; right: calc(100% + 10px); top: 50%; white-space: nowrap;
  padding: 7px 12px; border-radius: 99px; font: 500 12.5px/1 system-ui, sans-serif; letter-spacing: .02em;
  background: rgba(25, 18, 14, .82); color: #fff; backdrop-filter: blur(6px);
  opacity: 0; transform: translate(8px, -50%); transition: opacity .35s, transform .35s; pointer-events: none;
}
.music-btn.hint .mb-hint { opacity: 1; transform: translate(0, -50%); }
@media (hover: hover) { .music-btn:hover .mb-hint { opacity: 1; transform: translate(0, -50%); } }
@media (prefers-reduced-motion: reduce) { .music-btn.playing .mb-ring, .eq i { animation: none; } }

.draft-mark {
  position: fixed; inset: 0; z-index: 60; pointer-events: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='190'%3E%3Ctext x='150' y='100' text-anchor='middle' transform='rotate(-28 150 95)' font-family='Georgia,serif' font-size='21' letter-spacing='4' fill='rgba(128,110,95,.26)'%3EDRAFT · dawat.cards%3C/text%3E%3C/svg%3E");
  background-size: 300px 190px;
}
.draft-bar {
  position: fixed; z-index: 45; top: 0; left: 50%; transform: translateX(-50%);
  width: min(100%, var(--col)); padding: 8px 14px; text-align: center;
  font-family: system-ui, sans-serif; font-size: 13px; background: #2b2118; color: #f5e9d5;
}

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

/* soft waterline where the far shore meets the lake */
.sc-water::before {
  content: ''; position: absolute; left: 0; right: 0; top: -7px; height: 14px;
  background: linear-gradient(180deg, transparent, rgba(255, 255, 255, .45), transparent);
}
.dark .sc-water::before { background: linear-gradient(180deg, transparent, rgba(255, 255, 255, .12), transparent); }


/* ============ theme scenes ============ */

/* night palace */
.scene-night { background: linear-gradient(180deg, var(--sky1) 0%, var(--sky2) 62%, var(--sky3) 100%); }
.sc-stars { position: absolute; inset: 0; }
.sc-stars i { position: absolute; border-radius: 50%; background: #FFF6DE; opacity: .85; box-shadow: 0 0 4px rgba(255, 246, 222, .8); }
.sc-stars i.tw { animation: twinkle 3s ease-in-out infinite; }
.sc-moon {
  position: absolute; right: 22%; top: 20%; width: 52px; height: 52px; border-radius: 50%;
  box-shadow: 13px -7px 0 0 #FFF2CF; filter: drop-shadow(0 0 14px rgba(255, 236, 190, .55)); transform: rotate(-12deg);
}
.sc-skyline { position: absolute; left: 0; right: 0; bottom: 22.6%; width: 100%; height: 25%; }
.sc-skyline .pl-body { fill: color-mix(in srgb, var(--sky3) 55%, #000); }
.sc-skyline .pl-lit { fill: #FFD98A; opacity: .85; }
.sc-water.night { background: linear-gradient(180deg, color-mix(in srgb, var(--sky2) 70%, #000), var(--sky3)); }
.sc-water.night::before { background: linear-gradient(180deg, transparent, rgba(255, 230, 180, .18), transparent); }
.sc-skyline.reflect { position: absolute; top: 0; bottom: auto; height: 100%; transform: scaleY(-1); transform-origin: top; opacity: .28; filter: blur(1.5px); }

/* fairy lights */
.scene-lights { background: linear-gradient(180deg, color-mix(in srgb, var(--sky2) 70%, var(--sky1)) 0%, var(--sky1) 55%, var(--sky3) 100%); }
.sc-lights { position: absolute; left: 0; top: 2%; width: 100%; height: 16%; }
.sc-garlands { position: absolute; left: 0; top: 4%; width: 100%; height: 72%; }
.gl-thread { stroke: color-mix(in srgb, var(--ink) 30%, transparent); stroke-width: .8; }
.gl-f0 { fill: #F59E0B; }
.gl-f1 { fill: #FB923C; }
.gl-f2 { fill: #FCD34D; }
.sc-garlands circle[class^="gl-f"] { stroke: rgba(150, 70, 0, .25); stroke-width: .8; }
.gl-leaf { fill: #4D7C0F; opacity: .85; }
.gl-bead { fill: var(--accent); }
.lt-wire { fill: none; stroke: color-mix(in srgb, var(--ink) 45%, transparent); stroke-width: .7; }
.lt-glow { fill: color-mix(in srgb, var(--accent2) 60%, #FFE7A3); opacity: .45; filter: blur(3px); animation: glow 2.6s ease-in-out infinite; }
.lt-bulb { fill: #FFF4CF; }
.lt-bulb.b1 { fill: #FFD27A; }
.lt-bulb.b2 { fill: color-mix(in srgb, var(--accent2) 70%, #fff); }
@keyframes glow { 50% { opacity: .12; } }
.sc-bokeh { position: absolute; inset: 0; }
.sc-bokeh i {
  position: absolute; aspect-ratio: 1; border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 235, 180, .45), transparent 70%);
  animation: glow 5s ease-in-out infinite;
}
.dark .scene-lights { background: linear-gradient(180deg, var(--sky3) 0%, var(--sky1) 50%, var(--sky2) 100%); }

/* mandala */
.scene-mandala { background: radial-gradient(90% 60% at 50% 42%, var(--paper), var(--page)); }
.scene-mandala::after { content: ''; position: absolute; inset: 0; background: var(--noise); opacity: .7; }
.sc-glow { position: absolute; inset: 0; background: radial-gradient(45% 30% at 50% 40%, color-mix(in srgb, var(--accent2) 22%, transparent), transparent 70%); }
.sc-mandala { position: absolute; left: 50%; top: 42%; width: 128%; translate: -50% -50%; opacity: .22; animation: spin 160s linear infinite; }
.dark .sc-mandala { opacity: .3; }
@keyframes spin { to { rotate: 360deg; } }
.mandala circle, .mandala path { fill: none; stroke: var(--accent); stroke-width: .7; }
.mandala .thin { stroke-width: .4; }
.mandala .dot { fill: var(--accent); stroke: none; }

/* frames */
.frame-none .hero-content { top: 9%; }
.frame-border .hero-content { top: 9%; bottom: 13%; }
.frame-round .hero-content { top: 13%; }

/* closing ornament for themes without flowers */
.mandala-foot { width: 140px; margin: 30px auto 6px; opacity: .55; }
.mandala-foot .mandala { display: block; width: 100%; }

/* balloons & bunting */
.scene-balloons { background: linear-gradient(180deg, var(--sky1) 0%, var(--sky2) 55%, var(--sky3) 100%); }
.sc-dots { position: absolute; inset: 0; background-image: radial-gradient(color-mix(in srgb, var(--accent) 22%, transparent) 1.4px, transparent 1.6px); background-size: 24px 24px; opacity: .6; }
.sc-bunting { position: absolute; left: 0; top: 1%; width: 100%; height: 14%; }
.bt-string { fill: none; stroke: color-mix(in srgb, var(--ink) 40%, transparent); stroke-width: .8; }
.bt-flag.f0 { fill: var(--petal); }
.bt-flag.f1 { fill: var(--accent2); }
.bt-flag.f2 { fill: var(--leaf); }
.bt-flag.f3 { fill: var(--sealHi); }
.balloon { position: absolute; width: calc(54px * var(--s)); animation: float 6s ease-in-out infinite; transform-origin: 50% 90%; }
.balloon svg { display: block; width: 100%; height: auto; overflow: visible; }
.balloon.c0 .bl-body { fill: var(--petal); }
.balloon.c1 .bl-body { fill: var(--accent2); }
.balloon.c2 .bl-body { fill: var(--sealHi); }
.balloon.c3 .bl-body { fill: var(--leaf); }
.balloon.c4 .bl-body { fill: var(--accent); }
.bl-shine { fill: rgba(255, 255, 255, .45); }
.bl-string { fill: none; stroke: color-mix(in srgb, var(--ink) 35%, transparent); stroke-width: .9; }
@keyframes float { 50% { translate: 0 -12px; rotate: 3deg; } }

/* confetti */
.p-confetti i { width: 7px; height: 12px; border-radius: 2px; background: var(--petal); opacity: .95; }
.p-confetti i:nth-child(4n + 1) { background: var(--accent2); }
.p-confetti i:nth-child(4n + 2) { background: var(--sealHi); }
.p-confetti i:nth-child(4n + 3) { background: var(--leaf); width: 6px; height: 6px; border-radius: 50%; }

.hero-tagline { font-size: 1.15rem; font-style: italic; letter-spacing: .04em; color: var(--ink); margin-top: 6px; }
.has-photo .hero-tagline { color: #fff; text-shadow: 0 2px 10px rgba(0, 0, 0, .45); }
.dark .hero-tagline { color: var(--ink); }
body.play .hero-tagline.rise { animation-delay: 1.7s; }

/* ============ cover video ============ */

.hero-video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero-tint { position: absolute; inset: 0; }
.video-dark .hero-tint { background: linear-gradient(180deg, rgba(0, 0, 0, .28), rgba(0, 0, 0, .06) 42%, rgba(0, 0, 0, .3)); }
.video-light .hero-tint { background: radial-gradient(70% 40% at 50% 34%, rgba(255, 255, 255, .45), transparent 75%); }
.video-dark .hero-headline, .video-dark .hero-names .script, .video-dark .scroll-down { color: var(--accent2); text-shadow: 0 2px 16px rgba(0, 0, 0, .55); }
.video-dark .hero-date, .video-dark .hero-tagline { color: #fff; text-shadow: 0 2px 12px rgba(0, 0, 0, .55); }

/* ============ botanical art (flora.js) ============ */

.flora { display: block; width: 100%; height: auto; overflow: visible; }
.fp { stroke: rgba(80, 25, 35, .16); stroke-width: .7; }
.fp-a { fill: url(#g-pa); }
.fp-a2 { fill: url(#g-pa2); }
.fp-b { fill: url(#g-pb); }
.fp-b2 { fill: url(#g-pb2); }
.fp-c { fill: url(#g-pc); stroke: rgba(120, 60, 70, .14); }
.fp-core-a { fill: url(#g-core-a); }
.fp-swirl { fill: none; stroke: color-mix(in srgb, var(--petal) 45%, #3e0f1a); stroke-width: 1.3; stroke-linecap: round; opacity: .55; }
.fp-stamen { fill: var(--accent2); }
.fp-fil { stroke: color-mix(in srgb, var(--accent2) 80%, #000); stroke-width: .7; opacity: .7; }
.fl-leaf { fill: url(#g-leaf); stroke: rgba(10, 30, 10, .1); stroke-width: .6; }
.fl-rib { fill: none; stroke: rgba(255, 255, 255, .38); stroke-width: 1; stroke-linecap: round; }
.fl-vein { fill: none; stroke: rgba(255, 255, 255, .22); stroke-width: .7; stroke-linecap: round; }
.fl-sepal { fill: color-mix(in srgb, var(--leaf) 85%, #0d1f10); }
.fl-stem { fill: none; stroke: color-mix(in srgb, var(--leaf) 70%, #1e2e18); stroke-width: 1.6; stroke-linecap: round; }
.fl-euca { fill: url(#g-euca); stroke: rgba(30, 60, 50, .14); stroke-width: .6; }
.fl-twig { stroke: color-mix(in srgb, var(--leaf) 55%, #fff); stroke-width: .8; }
.fl-gyp { fill: #fffdf8; stroke: rgba(80, 70, 60, .16); stroke-width: .5; }
.fl-leaf2 { fill: url(#g-leaf2); }
.fl-vine { stroke-width: 1.1; opacity: .7; }

/* garden light scene: sunlight with soft leaf shadows drifting across */
.scene-botanical {
  background:
    radial-gradient(80% 45% at 88% 6%, rgba(255, 251, 238, .95), transparent 62%),
    linear-gradient(180deg, var(--sky1), var(--sky2) 62%, var(--sky3));
}
.dark .scene-botanical { background: radial-gradient(70% 40% at 85% 8%, rgba(235, 211, 154, .14), transparent 60%), linear-gradient(180deg, var(--sky1), var(--sky2) 60%, var(--sky3)); }
.sc-sunlight {
  position: absolute; inset: -10%;
  background: repeating-linear-gradient(115deg, transparent 0 70px, rgba(255, 255, 255, .2) 70px 110px);
  -webkit-mask: radial-gradient(70% 55% at 80% 10%, #000, transparent 72%);
  mask: radial-gradient(70% 55% at 80% 10%, #000, transparent 72%);
  animation: light-drift 16s ease-in-out infinite alternate;
}
.dark .sc-sunlight { opacity: .25; }
.sc-leafsh { position: absolute; inset: -6%; width: 112%; height: 112%; filter: blur(9px); }
.lsh { transform-box: fill-box; transform-origin: 50% 100%; animation: leaf-sway 9s ease-in-out infinite alternate; }
.lsh path { fill: color-mix(in srgb, var(--leaf) 50%, #3a3020); opacity: .09; }
.dark .lsh path { fill: #d8eadc; opacity: .05; }
@keyframes leaf-sway { to { transform: rotate(5deg) translate(8px, 5px); } }
.sc-motes i {
  position: absolute; width: 4px; height: 4px; border-radius: 50%;
  background: rgba(255, 249, 225, .95); box-shadow: 0 0 8px rgba(255, 240, 200, .9);
  animation: mote 9s ease-in-out infinite;
}
@keyframes mote { 0%, 100% { transform: translate(0, 0); opacity: .15; } 50% { transform: translate(14px, -24px); opacity: .9; } }

/* florals around the envelope */
.es-flora { position: absolute; width: min(76vw, 380px); pointer-events: none; transition: opacity .6s; animation: fade-in 1.4s ease .3s both; }
.es-flora.tl { top: -5%; left: -8%; transform: scaleY(-1) rotate(-4deg); }
.es-flora.br { bottom: -5%; right: -8%; transform: scaleX(-1); }
@keyframes fade-in { from { opacity: 0; } }
.reveal .es-flora { opacity: 0; }

/* the first screen's corners for themes without flowers (envdecor.js) */
.es-deco { position: absolute; pointer-events: none; animation: fade-in 1.4s ease .3s both; }
.es-deco svg { display: block; width: 100%; height: auto; overflow: visible; }
.es-deco.at-tl { top: 0; left: 0; }
.es-deco.at-tr { top: 0; right: 0; transform: scaleX(-1); }
.es-deco.at-bl { bottom: 0; left: 0; }
.es-deco.at-br { bottom: 0; right: 0; }
.reveal .es-deco { opacity: 0; transition: opacity .6s; }

.es-deco.balloons.at-tl { width: min(46vw, 240px); top: 1%; left: 0; }
.es-deco.balloons.at-br { width: min(62vw, 330px); right: -4%; bottom: -3%; }
.eb-b { animation: eb-float 6s ease-in-out infinite; }
@keyframes eb-float { 50% { transform: translateY(-8px) rotate(2deg); } }
.eb-string { fill: none; stroke: color-mix(in srgb, var(--ink) 35%, transparent); stroke-width: 1; }
.eb-shine { fill: rgba(255, 255, 255, .45); }
.eb-b.c0 .eb-body, .eb-bit.c0 { fill: var(--petal); }
.eb-b.c1 .eb-body, .eb-bit.c1 { fill: var(--accent2); }
.eb-b.c2 .eb-body, .eb-bit.c2 { fill: var(--sealHi); }
.eb-b.c3 .eb-body, .eb-bit.c3 { fill: var(--leaf); }
.eb-b.c4 .eb-body { fill: var(--accent); }
.eb-bit { opacity: .8; }

.es-deco.lanterns.at-tl, .es-deco.lanterns.at-tr { width: min(54vw, 270px); }
.es-deco.lanterns.at-bl, .es-deco.lanterns.at-br { width: min(40vw, 200px); bottom: 3%; }
.el-l { animation: el-sway 5s ease-in-out infinite; }
@keyframes el-sway { 0%, 100% { transform: rotate(-2.5deg); } 50% { transform: rotate(2.5deg); } }
.el-chain { stroke: color-mix(in srgb, var(--accent2) 80%, #000); stroke-width: 1.2; fill: none; }
.el-metal { fill: var(--accent2); }
.el-glass { fill: color-mix(in srgb, #FFD27A 55%, var(--accent2)); opacity: .92; }
.el-frame { fill: none; stroke: color-mix(in srgb, var(--accent2) 75%, #3a2a10); stroke-width: 1.3; }
.el-glow { fill: #FFD98A; opacity: .3; filter: blur(8px); animation: glow 3s ease-in-out infinite; }
.el-moon { fill: var(--accent2); opacity: .9; filter: drop-shadow(0 0 8px color-mix(in srgb, var(--accent2) 60%, transparent)); }
.el-star { fill: var(--accent2); animation: el-twinkle 3.2s ease-in-out infinite; }
@keyframes el-twinkle { 50% { opacity: .25; } }

.es-deco.marigold { width: min(34vw, 160px); }
.em-s { animation: el-sway 6s ease-in-out infinite; }
.em-thread { stroke: color-mix(in srgb, var(--ink) 30%, transparent); stroke-width: .9; }
.em-f0 { fill: #F59E0B; }
.em-f1 { fill: #FB923C; }
.em-f2 { fill: #FCD34D; }
.em-core { fill: rgba(150, 70, 0, .28); }
.em-leaf { fill: #4D7C0F; opacity: .85; }
.em-bead { fill: var(--accent); }
.es-deco.marigold.at-bl, .es-deco.marigold.at-br { width: min(38vw, 180px); bottom: 2%; }
.es-deco.marigold.at-br { transform: scaleX(-1); }
.ed-clay { fill: #B4532A; }
.ed-rim { fill: none; stroke: #E9A93A; stroke-width: 1.6; }
.ed-rim.thin { stroke-width: 1; opacity: .7; }
.ed-flame { fill: #FDBA3B; transform-origin: 0 -8px; animation: ed-flicker 1.6s ease-in-out infinite; }
.ed-core { fill: #FFF3C4; }
.ed-glow { fill: #FFC86B; opacity: .35; filter: blur(9px); animation: glow 2.4s ease-in-out infinite; }
@keyframes ed-flicker { 50% { transform: scale(.9, 1.08) rotate(2deg); } }

.es-deco.filigree { width: min(40vw, 190px); margin: 10px; }
.es-deco.filigree.at-bl { transform: scaleY(-1); }
.es-deco.filigree.at-br { transform: scale(-1, -1); }
.ef-line { fill: none; stroke: var(--accent); stroke-width: 1.8; stroke-linecap: round; }
.ef-leaf { fill: var(--accent); opacity: .85; }
.ef-line.thin { stroke-width: .8; opacity: .7; }
.ef-fill { fill: var(--accent); }
@media (prefers-reduced-motion: reduce) { .eb-b, .el-l, .em-s, .el-star, .el-glow { animation: none; } }

/* ============ openings: classic envelope, royal doors, royal curtains ============ */
/* All three share .env-screen with the envelope above. The screen gets .opening on tap,
   then .done to fade away; the doors and curtains also get .open while they move. */

/* embossed sprigs (classic envelope side flaps, carved door panels) */
.sprig .s-stem { fill: none; stroke-width: 1.6; stroke-linecap: round; }
.sprig .s-stem.thin { stroke-width: 1.1; }
.sprig.emboss { filter: drop-shadow(0 1px 0 rgba(255, 255, 255, .75)) drop-shadow(0 -1px .5px rgba(70, 50, 30, .2)); }
.sprig.emboss .s-stem { stroke: color-mix(in srgb, var(--paper) 90%, #fff); }
.sprig.emboss .s-leaf, .sprig.emboss .s-petal, .sprig.emboss .s-core { fill: color-mix(in srgb, var(--paper) 88%, #fff); }
.dark .sprig.emboss { filter: drop-shadow(0 1px 0 rgba(0, 0, 0, .5)) drop-shadow(0 -1px .5px rgba(255, 230, 170, .25)); }
.dark .sprig.emboss .s-stem { stroke: var(--accent); }
.dark .sprig.emboss .s-leaf, .dark .sprig.emboss .s-petal, .dark .sprig.emboss .s-core { fill: color-mix(in srgb, var(--accent) 75%, var(--paper)); }

/* ---- classic envelope: the original portrait envelope, four flaps around the seal ---- */
.cenv {
  position: relative;
  width: min(86vw, 390px, calc(86svh / 1.62));
  aspect-ratio: 1 / 1.62;
  cursor: pointer; outline: none; -webkit-tap-highlight-color: transparent; user-select: none;
  filter: drop-shadow(0 22px 34px rgba(50, 30, 10, .28));
  transition: transform .5s ease;
  animation: env-in 1s cubic-bezier(.2, .7, .2, 1) both;
}
.cenv:hover, .cenv:focus-visible { transform: translateY(-4px); }
.cenv-glow {
  position: absolute; inset: 6%;
  background: radial-gradient(closest-side, #fffaf0, #ffe1a6 35%, color-mix(in srgb, var(--accent2) 70%, transparent) 60%, transparent 80%);
  opacity: 0; transform: scale(.6);
  transition: opacity .8s ease, transform 1.6s ease;
}
.cflap, .cflap-wrap { position: absolute; inset: 0; }
.cflap { background-color: var(--paper); transition: transform 1.2s cubic-bezier(.65, 0, .35, 1), opacity 1.2s; }
.cflap-wrap { transition: transform 1.2s cubic-bezier(.65, 0, .35, 1), opacity 1.2s; }
.cflap-l {
  clip-path: polygon(0 0, 50% 50%, 0 100%);
  background-image: var(--noise), linear-gradient(90deg, color-mix(in srgb, var(--paper) 96%, #fff), color-mix(in srgb, var(--paper) 93%, #000));
}
.cflap-r {
  clip-path: polygon(100% 0, 50% 50%, 100% 100%);
  background-image: var(--noise), linear-gradient(270deg, color-mix(in srgb, var(--paper) 96%, #fff), color-mix(in srgb, var(--paper) 92%, #000));
}
.cflap-wrap.b { filter: drop-shadow(0 -2px 3px rgba(60, 40, 20, .14)); }
.cflap-b {
  clip-path: polygon(0 100%, 50% 50%, 100% 100%);
  background-image: var(--noise), linear-gradient(0deg, color-mix(in srgb, var(--paper) 97%, #fff), color-mix(in srgb, var(--paper) 94%, #000));
}
.cflap-wrap.t { filter: drop-shadow(0 3px 4px rgba(60, 40, 20, .18)); }
.cflap-t {
  clip-path: polygon(0 0, 100% 0, 50% 50%);
  background-image: var(--noise), linear-gradient(180deg, color-mix(in srgb, var(--paper) 90%, #fff), var(--paper));
}
.cenv-gilded .cflap-t { background-image: var(--noise), linear-gradient(180deg, color-mix(in srgb, var(--paper) 86%, #fff), var(--paper)); }
.cflap .sprig { position: absolute; top: 9%; height: 82%; width: 34%; }
.cflap-l .sprig { left: 2%; }
.cflap-r .sprig { right: 2%; transform: scaleX(-1); }
.env-pattern { position: absolute; inset: 0; width: 100%; height: 100%; }
.env-pattern .jl { fill: none; stroke: var(--accent); stroke-width: .7; opacity: .45; }
.env-pattern .jd { fill: var(--accent); opacity: .45; }
.cenv-deco { position: absolute; inset: 0; pointer-events: none; transition: opacity .35s; }
.env-lines { width: 100%; height: 100%; display: block; }
.env-lines .eo-seam, .env-lines .eo-line { fill: none; stroke: var(--accent); stroke-width: 1.2; vector-effect: non-scaling-stroke; opacity: .8; }
.env-lines .eo-line.thin { stroke-width: .6; opacity: .6; }
.cenv-mandala { position: absolute; left: 50%; top: 50%; width: 62%; translate: -50% -50%; opacity: .5; pointer-events: none; transition: opacity .35s; }
.cenv-mandala .mandala { display: block; width: 100%; }
.cseal {
  position: absolute; left: 50%; top: 50%; width: 31%;
  aspect-ratio: 1; transform: translate(-50%, -50%);
  filter: drop-shadow(0 4px 5px rgba(40, 10, 10, .35));
  transition: transform 1s cubic-bezier(.5, 0, .3, 1), opacity .9s;
}
.cseal svg { width: 100%; height: 100%; overflow: visible; }
.cseal::after {
  content: ''; position: absolute; inset: -14%; border-radius: 50%;
  border: 1px solid var(--accent2); opacity: 0;
  animation: seal-pulse 2.6s ease-out 1.2s infinite;
}
.cenv-hint {
  position: absolute; left: 0; right: 0; top: 64%;
  display: flex; flex-direction: column; align-items: center; gap: 2px;
  font-size: .78rem; letter-spacing: .28em; text-transform: uppercase; color: var(--muted);
  transition: opacity .4s;
}
.cenv-hint .caret { width: 16px; height: 16px; animation: bob 1.6s ease-in-out infinite; }
.op-classic.opening .cenv-glow { opacity: 1; transform: scale(1); }
.op-classic.opening .cflap-wrap.t { transform: translateY(-1.6%); }
.op-classic.opening .cflap-wrap.b { transform: translateY(1.6%); }
.op-classic.opening .cflap-l { transform: translateX(-2%); }
.op-classic.opening .cflap-r { transform: translateX(2%); }
.op-classic.opening .cseal { transform: translate(-50%, -50%) scale(1.08); }
.op-classic.opening .cseal::after { animation: none; }
.op-classic.opening .cenv-hint { opacity: .8; }
.op-classic.opening .cenv-deco, .op-classic.opening .cenv-mandala { opacity: 0; }
.cenv.open .cflap-wrap.t { transform: translateY(-115%) rotate(-3deg); opacity: 0; }
.cenv.open .cflap-wrap.b { transform: translateY(115%) rotate(2deg); opacity: 0; }
.cenv.open .cflap-l { transform: translateX(-120%) rotate(-4deg); opacity: 0; }
.cenv.open .cflap-r { transform: translateX(120%) rotate(4deg); opacity: 0; }
.cenv.open .cseal { transform: translate(-50%, -50%) scale(1.7); opacity: 0; }
.cenv.open .cenv-glow { transform: scale(3.2); opacity: 0; transition: opacity 1.2s ease .2s, transform 1.4s ease; }
.cenv.open .cenv-hint { opacity: 0; }

/* ---- the oval medallion (doors and curtains) ---- */
.rd-medal {
  position: absolute; z-index: 2; top: 46%; right: 0;
  width: min(42vw, 172px); aspect-ratio: 150 / 200;
  transform: translate(50%, -50%);
  filter: drop-shadow(0 8px 12px rgba(30, 15, 5, .35));
  transition: opacity .5s ease, filter .5s ease;
}
.rd-door.r .rd-medal { right: auto; left: 0; transform: translate(-50%, -50%); }
.rd-medal.solo { position: relative; top: auto; right: auto; transform: none; animation: medal-breathe 3s ease-in-out infinite; }
@keyframes medal-breathe { 50% { filter: drop-shadow(0 8px 12px rgba(30, 15, 5, .35)) drop-shadow(0 0 14px color-mix(in srgb, var(--accent2) 70%, transparent)); } }
.rd-medal-art, .rd-medal-art svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.rd-medal-txt { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 6px; text-align: center; padding: 0 16%; }
.rd-ini { font-size: clamp(2rem, 11vw, 2.9rem); line-height: 1; color: var(--accent); }
.rd-tap { font-size: .58rem; font-weight: 600; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); }
.cm-out { fill: var(--page); stroke: var(--accent); stroke-width: 1.4; }
.cm-in { fill: none; stroke: var(--accent2); stroke-width: 1.1; }
.cm-rule { fill: none; stroke: var(--accent); stroke-width: .7; stroke-dasharray: 1.2 3; opacity: .8; }
.cm-crest { fill: var(--accent); }

/* ---- royal doors ---- */
.op-doors { --W: min(100vw, 560px); padding: 0; gap: 0; }
/* the doors and curtains open onto the invitation itself, so their screen has no backdrop (dark themes too) */
.env-screen.op-doors, .env-screen.op-curtains, .dark .env-screen.op-doors, .dark .env-screen.op-curtains { background: none; }
.rd-wall {
  position: absolute; z-index: 2; top: 0; bottom: 0; width: calc((100vw - var(--W)) / 2 + 1px);
  background: radial-gradient(90% 60% at 50% 40%, color-mix(in srgb, var(--page) 60%, transparent), transparent 75%), var(--noise), var(--bg);
}
.rd-wall.l { left: 0; box-shadow: inset -18px 0 26px -18px rgba(30, 15, 5, .35); }
.rd-wall.r { right: 0; box-shadow: inset 18px 0 26px -18px rgba(30, 15, 5, .35); }
.rd-way {
  position: absolute; top: 0; bottom: 0; left: 50%; width: var(--W); transform: translateX(-50%);
  perspective: 1150px; cursor: pointer; outline: none; -webkit-tap-highlight-color: transparent; user-select: none;
}
.rd-door {
  --door: color-mix(in srgb, var(--accent) 32%, var(--paper));
  position: absolute; z-index: 1; top: 0; bottom: 0; width: 50%; overflow: hidden;
  background:
    linear-gradient(90deg, rgba(0, 0, 0, .14), transparent 9%, transparent 91%, rgba(0, 0, 0, .2)),
    radial-gradient(120% 55% at 50% 38%, rgba(255, 255, 255, .2), transparent 70%),
    var(--noise),
    var(--door);
  box-shadow: inset 0 0 0 1px rgba(0, 0, 0, .14), inset 0 0 50px rgba(30, 15, 5, .16);
  backface-visibility: hidden; -webkit-backface-visibility: hidden;
  transition: transform 2.2s cubic-bezier(.45, 0, .2, 1);
}
/* a door turning away from the light darkens */
.rd-door::after { content: ''; position: absolute; inset: 0; z-index: 3; background: rgba(20, 10, 4, .45); opacity: 0; pointer-events: none; transition: opacity 1.8s ease; }
.op-doors.open .rd-door::after { opacity: 1; }
.dark .rd-door { --door: color-mix(in srgb, var(--accent) 22%, var(--paper)); }
.rd-door.l { left: 0; transform-origin: 0 50%; }
.rd-door.r { right: 0; transform-origin: 100% 50%; }
.rd-panel {
  position: absolute; left: 16%; right: 16%;
  border: 1.5px solid color-mix(in srgb, var(--accent2) 85%, #fff);
  box-shadow:
    inset 0 0 0 5px color-mix(in srgb, var(--door) 90%, #000),
    inset 0 0 0 6px color-mix(in srgb, var(--accent2) 55%, transparent),
    inset 0 10px 22px rgba(30, 15, 5, .2),
    0 1px 0 rgba(255, 255, 255, .35);
}
.rd-panel.top { top: 14%; height: 48%; border-radius: 999px 999px 4px 4px; }
.rd-panel.bot { top: 68%; height: 21%; border-radius: 4px; }
.rd-sprig { position: absolute; left: 50%; top: 12%; height: 80%; aspect-ratio: 1 / 3; transform: translateX(-50%); }
.rd-sprig svg { display: block; width: 100%; height: 100%; }
.rd-door.r .rd-sprig { transform: translateX(-50%) scaleX(-1); }
.rd-rose { position: absolute; left: 50%; top: 50%; width: min(48%, 64px); aspect-ratio: 1; transform: translate(-50%, -50%); }
.rd-rose svg { display: block; width: 100%; height: 100%; }
.rs-p { fill: color-mix(in srgb, var(--door) 80%, #fff); stroke: color-mix(in srgb, var(--accent2) 70%, transparent); stroke-width: .6; }
.rs-c { fill: var(--accent2); }
.rs-ring { fill: none; stroke: var(--accent2); stroke-width: .8; opacity: .7; }
.rd-knock { position: absolute; top: 63%; width: 24px; filter: drop-shadow(0 3px 3px rgba(30, 15, 5, .35)); }
.rd-door.l .rd-knock { right: 7%; }
.rd-door.r .rd-knock { left: 7%; }
.rd-knock svg { display: block; width: 100%; }
.kn-boss { fill: var(--accent2); }
.kn-ring { fill: none; stroke: var(--accent2); stroke-width: 4; }
.kn-hi { fill: none; stroke: rgba(255, 255, 255, .5); stroke-width: 1; stroke-dasharray: 20 70; }
.rd-arch { position: absolute; z-index: 3; left: -1px; right: -1px; top: -1px; pointer-events: none; filter: drop-shadow(0 6px 8px rgba(30, 15, 5, .3)); }
.rd-arch svg { display: block; width: 100%; height: auto; }
.ar-wall { fill: var(--bg); }
.ar-gold { fill: none; stroke: var(--accent); stroke-width: 1.8; vector-effect: non-scaling-stroke; }
.ar-gold.thin { stroke: var(--accent2); stroke-width: .9; }
.ar-key { fill: var(--accent); }
.rd-light {
  position: absolute; inset: 0; z-index: 0; pointer-events: none; opacity: 0;
  background: radial-gradient(55% 42% at 50% 46%, #fff, color-mix(in srgb, var(--accent2) 55%, #fff) 45%, transparent 78%);
}
.op-doors.opening .rd-medal { filter: drop-shadow(0 0 22px color-mix(in srgb, var(--accent2) 90%, #fff)) brightness(1.06); }
.op-doors.open .rd-door.l { transform: rotateY(-106deg); }
.op-doors.open .rd-door.r { transform: rotateY(106deg); }
.op-doors.open .rd-light { animation: door-light 2.1s ease-out forwards; }
@keyframes door-light { 0% { opacity: 0; } 22% { opacity: .95; } 100% { opacity: 0; } }

/* ---- royal curtains ---- */
.op-curtains { padding: 0; gap: 0; }
.rc-stage { position: absolute; inset: 0; cursor: pointer; outline: none; -webkit-tap-highlight-color: transparent; user-select: none; }
.rc-curtain {
  --velvet: color-mix(in srgb, var(--seal) 90%, #000);
  position: absolute; z-index: 1; top: 0; bottom: 0; width: 52%;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, .12), transparent 28%, rgba(0, 0, 0, .3)),
    repeating-linear-gradient(90deg, rgba(0, 0, 0, .38) 0, rgba(255, 255, 255, .14) 13px, rgba(0, 0, 0, .12) 25px, rgba(0, 0, 0, .38) 34px),
    var(--velvet);
  box-shadow: 0 0 40px rgba(0, 0, 0, .45);
  transition: transform 2.1s cubic-bezier(.6, .02, .25, 1);
}
.rc-curtain.l { left: 0; transform-origin: 0 0; }
.rc-curtain.r { right: 0; transform-origin: 100% 0; }
.rc-fringe {
  position: absolute; left: 0; right: 0; bottom: 0; height: 20px;
  border-top: 3px solid var(--accent2);
  background: repeating-linear-gradient(90deg, var(--accent2) 0 2px, transparent 2px 5px);
  opacity: .9;
}
.op-curtains.open .rc-curtain.l { transform: scaleX(.15) skewY(-3deg); }
.op-curtains.open .rc-curtain.r { transform: scaleX(.15) skewY(3deg); }
.rc-center {
  position: absolute; inset: 0; z-index: 2; pointer-events: none;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 22px;
  transition: opacity .5s ease, transform .5s ease;
}
.rc-kicker { font-size: .86rem; font-weight: 600; letter-spacing: .42em; text-transform: uppercase; color: #F6E7C8; text-shadow: 0 2px 10px rgba(0, 0, 0, .55); animation: fade-up 1.2s ease .2s both; }
.op-curtains.opening .rc-center { opacity: 0; transform: scale(.96); }
.rc-valance { position: absolute; z-index: 3; left: -2%; right: -2%; top: 0; height: clamp(92px, 15svh, 140px); pointer-events: none; filter: drop-shadow(0 8px 10px rgba(0, 0, 0, .4)); }
.rc-swags, .rc-swags svg { position: absolute; inset: 0; width: 100%; height: 100%; display: block; }
.vl-body { fill: color-mix(in srgb, var(--seal) 78%, #000); }
.vl-trim { fill: none; stroke: var(--accent2); stroke-width: 3; vector-effect: non-scaling-stroke; }
.vl-fringe { fill: none; stroke: var(--accent2); stroke-width: 9; stroke-dasharray: 1.4 2.6; vector-effect: non-scaling-stroke; opacity: .85; }
.rc-tassel { position: absolute; top: 33%; width: 16px; transform: translateX(-50%); }
.rc-tassel svg { display: block; width: 100%; }
.tsl-cord { stroke: var(--accent2); stroke-width: 1.5; }
.tsl-gold { fill: var(--accent2); }
.tsl-dark { fill: var(--accent); }
.tsl-line { stroke: rgba(0, 0, 0, .25); stroke-width: .6; fill: none; }

/* ============ scratch to reveal the date ============ */
.scratch { display: grid; justify-items: center; gap: 10px; margin: 6px auto 26px; }
.sc-kicker { font-size: .78rem; font-weight: 600; letter-spacing: .32em; text-transform: uppercase; color: var(--muted); }
.sc-card {
  position: relative; width: min(88%, 320px); aspect-ratio: 16 / 9; border-radius: 16px; overflow: hidden;
  background: radial-gradient(120% 90% at 50% 20%, color-mix(in srgb, var(--page) 70%, #fff), var(--page));
  box-shadow: 0 0 0 1px var(--line), 0 16px 32px -18px rgba(40, 25, 10, .45);
}
.sc-card::before { content: ''; position: absolute; inset: 7px; z-index: 1; border: 1px solid var(--line); border-radius: 11px; pointer-events: none; }
.sc-under { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 2px; text-align: center; padding: 10px; }
.sc-day { font-size: .76rem; letter-spacing: .3em; text-transform: uppercase; color: var(--muted); }
.sc-date { font-size: clamp(1.8rem, 8.4vw, 2.5rem); line-height: 1.1; color: var(--accent); }
.sc-time { font-size: .9rem; font-weight: 600; letter-spacing: .14em; color: var(--ink); }
.sc-foil { position: absolute; inset: 0; z-index: 2; width: 100%; height: 100%; touch-action: none; cursor: grab; transition: opacity .7s ease; }
.sc-card.done .sc-foil { opacity: 0; pointer-events: none; }
.sc-card.done .sc-under { animation: sc-pop .8s cubic-bezier(.2, .8, .3, 1.3); }
@keyframes sc-pop { from { transform: scale(.9); opacity: .4; } }
.sc-help { text-align: center; font-size: .84rem; color: var(--muted); }
.sc-skip { background: none; border: 0; padding: 4px; font: inherit; font-size: .78rem; color: var(--accent); text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.sc-wait { display: none; }

/* ============ living scenes: photo backdrops that drift, glow and move with the guest ============ */
/* Layers: .lv-layer.bg (photo + glows, slow drift) → .lv-tint (theme colour) → .lv-veil (soft light behind
   the names) → .lv-layer.fg (flowers in front, settle into focus). --py (scroll) and --tx (tilt) come from JS. */

.living { position: absolute; inset: 0; overflow: hidden; container-type: size; background: var(--bg); }
.lv-layer { position: absolute; inset: -3%; will-change: transform; }
.lv-layer.bg { transform: translate3d(calc(var(--tx, 0) * -7px), calc(var(--py, 0) * .22px), 0); }
.lv-layer.fg { transform: translate3d(calc(var(--tx, 0) * 14px), calc(var(--py, 0) * -.1px), 0); }
/* the image box is sized like background-size: cover, so glow positions line up with the photo */
.lv-box {
  position: absolute; left: 50%; top: 50%;
  width: max(106cqw, calc(106cqh * var(--ratio))); aspect-ratio: var(--ratio); /* the layer is 6% larger than the cover so it can move */
  translate: -50% -50%;
}
.lv-box img { display: block; width: 100%; height: 100%; }
.lv-layer.bg .lv-box { animation: lv-drift 26s ease-in-out infinite alternate; transform-origin: 50% 22%; }
@keyframes lv-drift { from { transform: scale(1.04); } to { transform: scale(1.13) translateY(-1.2%); } }
.lv-layer.fg .lv-box { animation: lv-sway 11s ease-in-out infinite alternate; transform-origin: 50% 100%; }
@keyframes lv-sway { from { transform: rotate(-.35deg); } to { transform: rotate(.35deg) translateY(-.4%); } }
/* the foreground starts close and soft, then settles into focus as the invitation opens */
.lv-layer.fg img { transform: scale(1.14); filter: blur(5px); opacity: 0; transition: transform 3s cubic-bezier(.2, .7, .2, 1), filter 2.4s ease, opacity 1.4s ease; }
body.play .lv-layer.fg img { transform: scale(1.03); filter: none; opacity: 1; }

.lv-tint { position: absolute; inset: 0; background: var(--accent); mix-blend-mode: color; opacity: .14; pointer-events: none; }
.lv-veil {
  position: absolute; inset: 0; pointer-events: none;
  background:
    radial-gradient(66% 44% at 50% 31%, color-mix(in srgb, var(--page) 72%, transparent), transparent 80%),
    linear-gradient(180deg, color-mix(in srgb, var(--page) 55%, transparent), transparent 30%, transparent 72%, color-mix(in srgb, var(--page) 34%, transparent));
}
.dark .living .lv-layer.bg img { filter: brightness(.48) saturate(.85); }
.dark .living.tone-dark .lv-layer.bg img { filter: brightness(.78) saturate(.9); }
/* dark photos (night, lanterns): a darker veil and light lettering, like the dark video backgrounds */
.living.tone-dark .lv-veil {
  background:
    radial-gradient(66% 42% at 50% 31%, rgba(10, 5, 2, .5), transparent 80%),
    linear-gradient(180deg, rgba(10, 5, 2, .4), transparent 32%, transparent 70%, rgba(10, 5, 2, .35));
}
.living-dark .hero-headline, .living-dark .hero-names .script, .living-dark .scroll-down { color: var(--accent2); text-shadow: 0 2px 16px rgba(0, 0, 0, .6); }
/* names over golden drapes and lights: a paler gold with a crisp dark edge, so they never melt into the scene */
.living-dark .hero-names .script, .video-dark .hero-names .script { color: color-mix(in srgb, var(--accent2) 65%, #fff); text-shadow: 0 1px 3px rgba(0, 0, 0, .7), 0 2px 16px rgba(0, 0, 0, .65); }
.living-dark .hero-date, .living-dark .hero-tagline { color: #fff; text-shadow: 0 2px 12px rgba(0, 0, 0, .6); }
.dark .lv-tint { opacity: .2; }

/* candle flicker and crystal glints, placed on the photo */
.lv-candle, .lv-glint { position: absolute; translate: -50% -50%; pointer-events: none; mix-blend-mode: screen; }
.lv-candle {
  border-radius: 50%;
  background: radial-gradient(circle, rgba(255, 228, 176, .9) 0, rgba(255, 190, 105, .42) 32%, transparent 68%);
  animation: lv-flicker 2.7s ease-in-out infinite;
}
@keyframes lv-flicker {
  0%, 100% { opacity: .7; transform: scale(1); }
  28% { opacity: 1; transform: scale(1.1); }
  52% { opacity: .55; transform: scale(.92); }
  76% { opacity: .95; transform: scale(1.04); }
}
.lv-glint {
  background:
    linear-gradient(90deg, transparent 47%, #fff 50%, transparent 53%),
    linear-gradient(0deg, transparent 47%, #fff 50%, transparent 53%),
    radial-gradient(circle, rgba(255, 255, 255, .95), rgba(255, 245, 220, .4) 18%, transparent 42%);
  opacity: 0;
  animation: lv-glint 3.4s ease-in-out infinite;
}
@keyframes lv-glint {
  0%, 68%, 100% { opacity: 0; transform: scale(.3) rotate(0deg); }
  80% { opacity: 1; transform: scale(1) rotate(25deg); }
}

/* names over a photo: a little more presence */
.living-light .hero-headline, .living-light .hero-names .script { text-shadow: 0 1px 2px rgba(60, 35, 10, .3), 0 1px 18px color-mix(in srgb, var(--page) 85%, transparent); }
.living-light .hero-date, .living-light .hero-tagline { text-shadow: 0 1px 10px color-mix(in srgb, var(--page) 90%, transparent); }

.living.still .lv-box, .living.still .lv-candle, .living.still .lv-glint { animation: none; }
.living.still .lv-layer.fg img { transform: none; filter: none; opacity: 1; transition: none; }
.living.still .lv-glint { opacity: 0; }

/* the editor's phone preview: no desktop scrollbar (phones don't show one either) */
html.in-preview { scrollbar-width: none; }
html.in-preview::-webkit-scrollbar { display: none; }

/* foreground flowers/lanterns/garlands fade away behind the heading and names, keeping the edges and corners */
.lv-layer.fg {
  -webkit-mask: radial-gradient(38% 24% at 50% 27%, transparent 45%, #000 100%);
  mask: radial-gradient(38% 24% at 50% 27%, transparent 45%, #000 100%);
}

/* ============ Urdu ============ */
/* Nastaliq is tall and sits small: more line height, a size boost, right-to-left text. */
body.lang-ur { direction: rtl; line-height: 2.05; }
body.lang-ur .lead, body.lang-ur .venue, body.lang-ur .addr, body.lang-ur .ev-note, body.lang-ur .program, body.lang-ur .field,
body.lang-ur .btn, body.lang-ur .choice, body.lang-ur .hint, body.lang-ur .cd-lbl, body.lang-ur .sc-help,
body.lang-ur .sc-day, body.lang-ur .dow, body.lang-ur .time, body.lang-ur .deadline, body.lang-ur .made { line-height: 2.1; }
body.lang-ur .script { line-height: 1.75; }
body.lang-ur .title { font-size: clamp(1.7rem, 7.4cqi, 2.2rem); }
body.lang-ur .hero-headline, body.lang-ur .ec-kicker, body.lang-ur .es-kicker, body.lang-ur .rc-kicker,
body.lang-ur .sc-kicker, body.lang-ur .rd-tap, body.lang-ur .cd-lbl, body.lang-ur .dow, body.lang-ur .sc-day { letter-spacing: 0; text-transform: none; }
body.lang-ur .cd-lbl { font-size: .95rem; }
body.lang-ur input, body.lang-ur textarea { direction: rtl; font-family: var(--serif); }
/* phone numbers, dates in digits and the like stay left-to-right */
body.lang-ur .phone, body.lang-ur .hero-date, body.lang-ur .ec-date, body.lang-ur input[type=tel], body.lang-ur input[type=number] { direction: ltr; }
/* the timeline keeps its shape; only the words flow right-to-left */
body.lang-ur .tl, body.lang-ur .cd-grid, body.lang-ur .poppers, body.lang-ur .choices { direction: ltr; }
body.lang-ur .tl .ev > *, body.lang-ur .choice { direction: rtl; }

/* both languages: the Urdu line beneath a heading, and Urdu paragraphs after the English ones */
.ur-sub {
  display: block; margin-top: .15em; direction: rtl;
  font-family: 'Noto Nastaliq Urdu', serif; font-size: .52em; line-height: 1.9; opacity: .85; letter-spacing: 0;
}
.ur-para { direction: rtl; font-family: 'Noto Nastaliq Urdu', serif; line-height: 2.1; font-size: .92em; }
body.lang-ur .closing-line { font-size: clamp(1.9rem, 8.6cqi, 2.5rem); }
body.lang-ur .big { font-size: 2.2rem; }

/* ============ illustrated frames: painted arches over the cover ============ */
.hero-plain { position: absolute; inset: 0; background: radial-gradient(60% 45% at 50% 45%, color-mix(in srgb, var(--page) 55%, #fff), var(--page)); }
.illus { position: absolute; inset: 0; z-index: 1; pointer-events: none; overflow: hidden; }
.illus img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%;
  filter: drop-shadow(0 4px 12px rgba(60, 35, 10, .35));
  transform: scale(1.06); transform-origin: 50% 100%; /* no scroll drift: moving it would uncover the background below */
  transition: transform 2.6s cubic-bezier(.2, .7, .2, 1);
}
body.play .illus img { transform: none; }
.illus.still img { transform: none; transition: none; }
.has-illus .particles { z-index: 2; }
/* the words sit inside the arch opening */
.has-illus .hero-content { left: 21%; right: 21%; top: var(--illus-top, 30%); bottom: 17%; z-index: 3; }
.has-illus .hero-headline { margin-top: 0; font-size: clamp(1.4rem, 6.4cqi, 1.9rem); }
.has-illus .hero-names { margin-top: 4%; }
.has-illus .hero-names .script { font-size: clamp(2.6rem, 14cqi, 4.3rem); }
.has-illus .hero-names.long .script { font-size: clamp(2.1rem, 10.5cqi, 3.4rem); }
.has-illus .hero-names .amp { font-size: clamp(1.5rem, 7cqi, 2.1rem) !important; }
/* over a photo, video or scene: a soft glow behind the words keeps them readable */
.has-illus.has-living .hero-content::before, .has-illus.has-video .hero-content::before, .has-illus.has-photo .hero-content::before {
  content: ''; position: absolute; z-index: -1; left: -20%; right: -20%; top: -6%; height: 70%;
  background: radial-gradient(closest-side, color-mix(in srgb, var(--page) 70%, transparent), transparent);
}
.has-illus.living-dark .hero-content::before, .has-illus.video-dark .hero-content::before, .has-illus.has-photo .hero-content::before {
  background: radial-gradient(closest-side, rgba(10, 5, 2, .5), transparent);
}
/* under a painted arch the torn-paper edge reads as a pale band: fade the arch into the next section instead */
.has-illus + .sec > .tear { display: none; }
.has-illus::after {
  content: ''; position: absolute; left: 0; right: 0; bottom: 0; height: 90px; z-index: 2; pointer-events: none;
  background: linear-gradient(180deg, transparent, color-mix(in srgb, var(--paper) 55%, transparent) 55%, var(--paper));
}
.has-illus + .sec:not(.alt) { margin-top: 0; }
.has-illus:has(+ .sec:not(.alt))::after { background: linear-gradient(180deg, transparent, color-mix(in srgb, var(--page) 55%, transparent) 55%, var(--page)); }

/* ============ dress code (under an event) ============ */

.dress { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 10px; margin-top: 10px; }
.dress-lbl { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); font-weight: 600; }
.swatches { display: inline-flex; padding: 2px 0; }
/* each colour like a little satin swatch: a soft highlight up top, the cloth curving into shade below */
.sw {
  width: 26px; height: 26px; border-radius: 50%; flex: none; position: relative;
  background:
    radial-gradient(circle at 32% 26%, rgba(255, 255, 255, .75) 0 7%, rgba(255, 255, 255, .22) 28%, transparent 52%),
    radial-gradient(circle at 70% 88%, rgba(0, 0, 0, .28), transparent 62%),
    linear-gradient(135deg, rgba(255, 255, 255, .12), rgba(0, 0, 0, .1)),
    var(--c);
  box-shadow:
    0 0 0 2px var(--page),
    0 0 0 3px color-mix(in srgb, var(--accent) 50%, transparent),
    0 4px 9px rgba(40, 25, 10, .22),
    inset 0 -2px 4px rgba(0, 0, 0, .12);
  transition: transform .5s cubic-bezier(.34, 1.56, .64, 1), opacity .4s ease;
  transition-delay: calc(.25s + var(--i, 0) * .09s);
}
.sw + .sw { margin-left: -7px; }
/* they pop in, one after another, as the event lights up */
.ev:not(.on) .sw { transform: scale(.4); opacity: 0; }
.dark .sw { box-shadow: 0 0 0 2px var(--page), 0 0 0 3px color-mix(in srgb, var(--accent) 60%, transparent), 0 4px 10px rgba(0, 0, 0, .45), inset 0 -2px 4px rgba(0, 0, 0, .18); }
.dress-text { font-size: 1.1rem; color: var(--ink); }
body.lang-ur .dress-lbl { letter-spacing: 0; text-transform: none; font-size: .95rem; }
body.lang-ur .sw + .sw { margin-left: 0; margin-right: -7px; }

/* ============ WhatsApp beside a contact number ============ */

.ph-row { display: flex; gap: 10px; align-items: stretch; }
.ph-row .phone { flex: 1; min-width: 0; }
.wa {
  flex: none; width: 56px; display: grid; place-items: center; border-radius: 999px;
  border: 1px solid var(--accent); background: color-mix(in srgb, var(--page) 60%, transparent);
  color: #1fa855; box-shadow: 0 4px 14px rgba(40, 25, 10, .06); transition: background .2s;
}
.wa:hover { background: color-mix(in srgb, #25d366 12%, var(--page)); }
.wa svg { width: 26px; height: 26px; }
.dark .wa { color: #4ade80; }
body.lang-ur .ph-row { direction: ltr; }

/* ============ Chashm-e-Baraah ============ */

.fam-names { list-style: none; margin: 18px auto 0; padding: 0; display: grid; gap: 8px; max-width: 360px; }
.fam-names li { font-size: 1.22rem; color: var(--ink); line-height: 1.35; }
body.lang-ur .fam-names li { line-height: 2; }
@media (prefers-reduced-motion: reduce) { .sw { transition: none; } .ev:not(.on) .sw { transform: none; opacity: 1; } }
