/* ══════════════════════════════════════════════════════════════
   Bosco & Stefina — /stephens (the Palliyil-family invitation)
   Blue azulejo · marigold · lace · typewriter + script.
   A separate world from the main site's cream watercolour.
   ══════════════════════════════════════════════════════════════ */

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

:root {
  --ink:      #22409b;   /* royal-blue text */
  --ink-deep: #1a2a6c;   /* navy */
  --ink-soft: #4a63b4;   /* dimmed blue */
  --gold:     #ecae28;   /* marigold panel — matches lace-frame.jpg's bg exactly */
  --gold-deep:#e6a20c;
  --gold-line:#d99b12;
  --cream:    #fbf6e2;   /* card paper */
  --cream-2:  #fdfbf1;
  --white:    #ffffff;

  --maxw: 560px;         /* portrait content column (PDF is 600×800) */
  --pad: clamp(18px, 5vw, 34px);

  --ff-type:   "Courier Prime", "Courier New", monospace;
  --ff-script: "Great Vibes", "Segoe Script", cursive;
  --ff-hand:   "Sacramento", "Segoe Script", cursive;
}

html, body { margin: 0; padding: 0; }
/* hard-stop any horizontal overflow on BOTH roots — iOS expands the
   layout viewport if only body hides it, shifting the whole page */
html, body { overflow-x: hidden; overflow-x: clip; }

body {
  font-family: var(--ff-type);
  color: var(--ink);
  background-color: #eef2fb;
  /* azulejo tile softened to the PDF's pale wash by a cream veil,
     woven paper warmth underneath */
  background-image:
    linear-gradient(rgba(251,246,230,.5), rgba(251,246,230,.5)),
    url("../images/stephens/tile.webp"),
    url("../images/stephens/paper.webp");
  background-repeat: repeat, repeat, repeat;
  background-size: auto, 220px 220px, 700px auto;
  background-attachment: fixed, fixed, fixed;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }

/* scroll lock while the envelope is sealed */
html.is-sealed, html.is-sealed body { overflow: hidden; height: 100%; touch-action: none; }

#s-main { position: relative; z-index: 1; }

/* every section is a centred portrait column floating on the tile */
.hero, .invite, .std, .finale {
  position: relative;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--pad);
}

/* ── shared: reveal primitives (hidden only when JS + motion) ── */
@media (prefers-reduced-motion: no-preference) {
  html.js [data-reveal],
  html.js [data-words] .w { opacity: 0; }
}

/* ════════════════ STAGE — sealed envelope / opened ════════════════ */

.stage {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 8svh var(--pad);
  overflow: hidden;
}
/* during the animated intro the stage is a full-screen overlay so it can
   dissolve away and reveal the wedding-name slide (P3) beneath it */
html.js .stage.is-overlay {
  position: fixed;
  inset: 0;
  min-height: 0;
  height: 100svh;
  z-index: 60;
  background-color: #eef2fb;
  background-image:
    linear-gradient(rgba(251,246,230,.5), rgba(251,246,230,.5)),
    url("../images/stephens/tile.webp"),
    url("../images/stephens/paper.webp");
  background-repeat: repeat, repeat, repeat;
  background-size: auto, 220px 220px, 700px auto;
}
/* the sealed envelope and the opened tableau share one centred cell so the
   card appears to rise out of the very same envelope */
.stage > .sealed, .stage > .opened { grid-area: 1 / 1; }

.stage-bloom {
  position: absolute;
  width: clamp(120px, 34vw, 210px);
  opacity: .9;
  pointer-events: none;
  filter: drop-shadow(0 8px 14px rgba(26, 42, 108, .12));
  z-index: 0;
}
.stage-bloom--tl { top: -3%;  left: -6%;  transform: rotate(-12deg); }
.stage-bloom--br { bottom: -4%; right: -8%; width: clamp(150px, 40vw, 260px); transform: rotate(8deg); }

/* the sealed envelope */
.sealed {
  position: relative;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: clamp(18px, 4vh, 34px);
  will-change: transform, opacity;
}

.env {
  position: relative;
  width: min(84vw, 440px);
  filter: drop-shadow(0 26px 40px rgba(26, 42, 108, .30));
}
.env-art { width: 100%; }

.env-seal {
  position: absolute;
  left: 50%;
  top: 53%;
  width: 27%;
  transform: translate(-50%, -50%);
  transform-origin: center;
  will-change: transform, opacity;
}
.env-seal img { width: 100%; filter: drop-shadow(0 3px 5px rgba(26,42,108,.28)); }
.env-seal-mono {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .12em;
  white-space: nowrap;
  font-family: var(--ff-hand);
  font-size: clamp(18px, 5.2vw, 27px);
  color: var(--ink);
  letter-spacing: .01em;
  transform: translateY(-6%);
}
.env-seal-mono i { font-style: normal; opacity: .75; font-size: .8em; }

.tap-hint {
  appearance: none;
  border: 0;
  background: transparent;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: .5em;
  font-family: var(--ff-type);
  font-weight: 700;
  letter-spacing: .28em;
  text-transform: uppercase;
  font-size: clamp(11px, 3vw, 13px);
  color: var(--ink);
  padding: 4px 6px;
}
.tap-hint svg { width: 18px; animation: nudge 1.8s ease-in-out infinite; }
@keyframes nudge { 0%,100% { transform: translateY(0); } 50% { transform: translateY(4px); } }

/* the opened tableau (assembled by JS): the envelope open, the card
   popped up out of its mouth so the church art + caption read clearly,
   its foot tucked behind the navy pocket */
.opened {
  position: relative;
  z-index: 3;
  width: min(84vw, 430px);
  aspect-ratio: 1 / 1.24;
  pointer-events: none;
}
html.js .opened { opacity: 0; }               /* JS reveals; assembled on tap */
.op-flap {
  position: absolute;
  bottom: 0;
  left: 2%;
  width: 96%;
  transform-origin: 50% 100%;
  z-index: 1;
  filter: drop-shadow(0 -4px 12px rgba(26,42,108,.16));
}
.op-card {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 66%;
  margin: 0;
  background: var(--cream-2);
  padding: 6%;
  border-radius: 3px;
  box-shadow: 0 16px 26px rgba(26,42,108,.26);
  z-index: 2;
}
.op-card img { border-radius: 2px; }
/* greenery spilling out of the envelope mouth (PDF p.2, right side) */
.op-sprig {
  position: absolute;
  top: 3%;
  right: -14%;
  width: 62%;
  z-index: 2;
  transform: rotate(14deg);
  filter: drop-shadow(0 6px 10px rgba(26,42,108,.18));
}
.op-pocket {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  z-index: 3;
  filter: drop-shadow(0 16px 24px rgba(26,42,108,.28));
}
/* the lace-doily calling card dropped across the envelope's foot (PDF p.2) */
.op-invited {
  position: absolute;
  right: -2%;
  bottom: -9%;
  width: 68%;
  margin: 0;
  z-index: 4;
  background: var(--cream-2);
  border-radius: 6px;
  padding: clamp(16px, 5vw, 26px) 10px;
  text-align: center;
  font-family: var(--ff-hand);
  font-size: clamp(28px, 8.4vw, 42px);
  line-height: 1.04;
  color: var(--ink);
  transform: rotate(-4deg);
  box-shadow: 0 18px 30px rgba(26,42,108,.30);
}
.op-invited::before {
  /* white scalloped doily ring, outside the paper */
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 12px;
  background:
    radial-gradient(circle at 8px 8px, var(--white) 7px, transparent 7.5px) 0 0 / 16px 16px;
  padding: 11px;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
}
.op-invited::after {
  /* thin gold keyline just inside the paper */
  content: "";
  position: absolute;
  inset: 6px;
  border: 1.5px solid var(--gold-line);
  border-radius: 3px;
  pointer-events: none;
}

/* fallback when JS/CDN never arrive: no lock, envelope stays sealed but
   the sections below are reachable by normal scroll */
html:not(.js) .opened { display: none; }
html:not(.js) .tap-hint { pointer-events: none; }
html:not(.js) .tap-hint span::after { content: " ↓ scroll"; }

/* ════════════════ PAGE 3 · HERO ════════════════ */

.hero {
  /* the marigold band is full-bleed; only the head + panel contents
     keep the portrait column */
  max-width: none;
  padding-inline: 0;
  text-align: center;
  padding-top: clamp(40px, 10vh, 88px);
  padding-bottom: clamp(34px, 8vh, 70px);
}

/* the title sits on the tile; a soft cream halo keeps the script legible
   over the busy azulejo (mirrors the PDF's clear top band) */
.hero-head {
  position: relative;
  max-width: var(--maxw);
  margin-inline: auto;
  padding: clamp(20px, 6vw, 40px) var(--pad) clamp(30px, 9vw, 56px);
}
.hero-head::before {
  content: "";
  position: absolute;
  inset: -6% -12%;
  background: radial-gradient(ellipse 62% 58% at 50% 52%,
    rgba(253,251,243,.96) 0%, rgba(253,251,243,.9) 42%, rgba(253,251,243,0) 74%);
  z-index: -1;
}
.hero-eyebrow {
  font-family: var(--ff-type);
  font-weight: 700;
  letter-spacing: .32em;
  text-transform: uppercase;
  font-size: clamp(12px, 3.4vw, 15px);
  margin: 0 0 -.05em;
}
.hero-eyebrow span { text-transform: lowercase; letter-spacing: normal; font-weight: 400; }
.hero-title {
  font-family: var(--ff-script);
  font-weight: 400;
  color: var(--ink);
  font-size: clamp(52px, 16vw, 70px);
  line-height: .96;
  margin: .05em 0 0;
  text-shadow: 0 2px 0 rgba(255,255,255,.6);
}
.hero-title .amp { font-size: .8em; opacity: .82; }

/* the full-bleed marigold band (PDF p.3 lower two-thirds): a flat gold
   field with big wavy scallops where it meets the tile, top and bottom */
.hero-panel {
  position: relative;
  background: var(--gold);
  padding: clamp(16px, 4.5vw, 30px) 0 clamp(30px, 8vw, 54px);
  margin-top: clamp(28px, 8vw, 50px);
}
.hero-panel::before {
  /* broad, gentle wave rising into the tile above */
  content: "";
  position: absolute;
  bottom: 100%;
  left: 0;
  right: 0;
  height: 22px;
  background:
    radial-gradient(circle at 48px 98px, var(--gold) 90px, transparent 91px) center bottom / 96px 22px repeat-x;
  pointer-events: none;
}
.hero-panel::after {
  /* broad, gentle wave dipping into the tile below */
  content: "";
  position: absolute;
  top: 100%;
  left: 0;
  right: 0;
  height: 22px;
  background:
    radial-gradient(circle at 48px -76px, var(--gold) 90px, transparent 91px) center top / 96px 22px repeat-x;
  pointer-events: none;
}
.hero-panel-in {
  position: relative;
  max-width: var(--maxw);
  margin-inline: auto;
  padding-inline: var(--pad);
}

/* the big lace doily frame — a single painted asset (lace-frame.png,
   flat gold bg matching var(--gold)); it stays static, only the church
   scene inside its window animates */
.frame--doily {
  position: relative;
  z-index: 1;
  width: min(76%, 340px);
  margin: clamp(6px, 2vw, 16px) auto clamp(22px, 6vw, 38px);
}
.frame--doily .doily { width: 100%; display: block; }
/* the church scene sits ON TOP of the doily, larger than its painted
   window — only the outer scallop ring of lace stays visible around it.
   Multiply-blend + a feathered mask melt the art's cream paper into the
   doily's cream, so the watercolour reads as painted on the lace,
   never as a pasted rectangle */
/* the blank cream panel inside the fine gold dot band:
   measured off lace-frame.jpg (752×984) */
.doily-win {
  position: absolute;
  inset: 14.4% 16.9% 14.7% 17%;
  overflow: hidden;
}
.doily-win img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  mix-blend-mode: multiply;
  filter: brightness(1.06) contrast(1.04);
  -webkit-mask-image:
    linear-gradient(to right, transparent 0, #000 8%, #000 92%, transparent 100%),
    linear-gradient(to bottom, transparent 0, #000 8%, #000 92%, transparent 100%);
  -webkit-mask-composite: source-in;
  mask-image:
    linear-gradient(to right, transparent 0, #000 8%, #000 92%, transparent 100%),
    linear-gradient(to bottom, transparent 0, #000 8%, #000 92%, transparent 100%);
  mask-composite: intersect;
}

.verse {
  margin: 0 auto;
  max-width: 34ch;
}
/* the verse is blue handwriting on the marigold, as printed (PDF p.3) */
.verse p {
  font-family: var(--ff-hand);
  font-size: clamp(26px, 7.4vw, 38px);
  line-height: 1.22;
  color: var(--ink);
  margin: 0;
  text-shadow: 0 1px 0 rgba(255,255,255,.3);
}
.verse cite {
  font-family: var(--ff-hand);
  font-style: normal;
  font-size: .95em;
  color: inherit;
  white-space: nowrap;
}
.hero-tag {
  font-family: var(--ff-type);
  font-weight: 700;
  letter-spacing: .05em;
  font-size: clamp(13px, 3.6vw, 16px);
  color: var(--ink-deep);
  margin-top: clamp(18px, 5vw, 30px);
}
/* the tall hero sprays read on yellow, not tile */
.bloom--hero-br { z-index: 1; }

/* florals tucked into the doily's corners (positioned off the frame,
   so they can never be cropped by the viewport edge) */
.bloom--hero-fl1 {
  top: -4%;
  left: -9%;
  width: clamp(64px, 18vw, 100px);
  transform: rotate(-14deg);
  z-index: 2;
}
.bloom--hero-fl2 {
  top: 30%;
  right: -11%;
  width: clamp(76px, 21vw, 120px);
  transform: rotate(24deg);
  z-index: 2;
}
.bloom--hero-fl3 {
  bottom: -5%;
  left: -9%;
  width: clamp(70px, 19vw, 108px);
  transform: scaleX(-1) rotate(12deg);
  z-index: 2;
}

/* ════════════════ PAGE 4 · INVITATION ════════════════ */

.invite { padding-block: clamp(30px, 8vh, 70px); }

.card {
  position: relative;
  background: var(--cream);
  padding: clamp(28px, 8vw, 52px) clamp(22px, 6vw, 40px);
  text-align: center;
  border-radius: 4px;
  box-shadow: 0 22px 44px rgba(26,42,108,.18);
}
/* gold beaded "chain" border (PDF p.4) */
.card--chain {
  outline: 2px solid var(--gold);
  outline-offset: -14px;
}
.card--chain::before {
  content: "";
  position: absolute;
  inset: 9px;
  border-radius: 3px;
  background:
    radial-gradient(circle, var(--gold) 3.2px, transparent 3.6px) 0 0 / 15px 15px;
  -webkit-mask:
    linear-gradient(#000 0 0) top / 100% 15px no-repeat,
    linear-gradient(#000 0 0) bottom / 100% 15px no-repeat,
    linear-gradient(#000 0 0) left / 15px 100% no-repeat,
    linear-gradient(#000 0 0) right / 15px 100% no-repeat;
  pointer-events: none;
}

.type {
  font-family: var(--ff-type);
  font-weight: 700;
  color: var(--ink);
  line-height: 1.55;
  font-size: clamp(14px, 3.9vw, 17px);
  margin: 0 0 .55em;
}
.type--dim { color: var(--ink-soft); font-weight: 400; margin: .1em 0; }
.type--with { font-weight: 400; color: var(--ink-soft); margin: -.1em 0 -.15em; }

.script-name {
  font-family: var(--ff-script);
  font-weight: 400;
  color: var(--ink);
  font-size: clamp(46px, 14vw, 74px);
  line-height: 1;
  margin: .06em 0;
}

.event { margin-top: clamp(22px, 5vh, 34px); }
.event-title {
  font-size: clamp(15px, 4.2vw, 18px);
  letter-spacing: .04em;
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-underline-offset: 5px;
  text-decoration-thickness: 2px;
  margin-bottom: .35em;
}
.event-line { margin: .15em 0; line-height: 1.5; }

.map {
  display: inline-flex;
  align-items: center;
  gap: .4em;
  margin-top: .5em;
  color: var(--gold-deep);
  font-family: var(--ff-type);
  font-weight: 700;
  font-size: clamp(13px, 3.4vw, 15px);
  text-decoration: none;
  border-bottom: 1.5px solid transparent;
  transition: border-color .25s ease, transform .25s ease;
}
.map svg { width: 17px; }
.map:hover { border-bottom-color: var(--gold-deep); transform: translateY(-1px); }

/* ════════════════ PAGE 5 · SAVE THE DATE ════════════════ */

.std { padding-block: clamp(30px, 8vh, 70px); }

/* the panel is an ornate bracket silhouette (the .std-shape SVG),
   never a box — the azulejo tile shows through around its curves */
.std-panel {
  position: relative;
  color: var(--ink-deep);
  padding: clamp(38px, 10vw, 64px) clamp(26px, 8vw, 48px) clamp(46px, 11vw, 70px);
  text-align: center;
}
.std-shape {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  filter: drop-shadow(0 20px 34px rgba(26,42,108,.22));
  pointer-events: none;
}
.std-shape-fill { fill: var(--gold); }
.std-shape-line {
  fill: none;
  stroke: rgba(255,255,255,.75);
  stroke-width: 1.5;
  vector-effect: non-scaling-stroke;
}
/* everything else floats above the gold silhouette */
.std-kicker, .std-date, .std-presence, .film { position: relative; z-index: 1; }

.std-kicker {
  color: var(--ink-deep);
  letter-spacing: .34em;
  text-transform: uppercase;
  font-size: clamp(14px, 4vw, 18px);
  margin-bottom: .8em;
}
.std-date {
  color: var(--ink-deep);
  font-size: clamp(17px, 4.8vw, 22px);
  letter-spacing: .08em;
  line-height: 1.5;
  margin-bottom: .4em;
}

.std-presence {
  font-family: var(--ff-hand);
  color: var(--white);
  font-size: clamp(30px, 9vw, 46px);
  line-height: 1.15;
  margin: clamp(14px, 4vw, 24px) 0 clamp(20px, 6vw, 34px);
  text-shadow: 0 1px 2px rgba(26,42,108,.25), 0 4px 12px rgba(26,42,108,.18);
  transform: rotate(-3deg);
}

/* white blossoms tucked around the panel (PDF p.5) */
.std-flower {
  position: absolute;
  width: clamp(54px, 15vw, 84px);
  top: clamp(6px, 2vw, 16px);
  opacity: .95;
  pointer-events: none;
  filter: drop-shadow(0 4px 8px rgba(26,42,108,.14));
}
.std-flower--tl { left: clamp(4px, 2vw, 18px); transform: rotate(-14deg); }
.std-flower--tr { right: clamp(4px, 2vw, 18px); transform: rotate(12deg) scaleX(-1); }
.std-flower--br {
  top: auto;
  left: auto;
  bottom: clamp(24px, 6vw, 60px);
  right: clamp(2px, 1.5vw, 20px);
  width: clamp(96px, 27vw, 160px);
  transform: rotate(6deg);
}

/* hands raising champagne flutes, flanking the reel */
.flute {
  position: absolute;
  width: clamp(74px, 20vw, 108px);
  color: var(--ink-deep);
  opacity: .9;
  z-index: 1;
}
.flute--l { left: clamp(2px, 1.5vw, 16px); top: 55%; transform: rotate(-10deg); }
.flute--r { right: clamp(2px, 1.5vw, 16px); top: 26%; transform: rotate(10deg); }
/* champagne bubbles drift up out of the glasses */
.flute .bub { animation: bub 2.6s ease-in-out infinite; }
.flute .bub:nth-of-type(2) { animation-delay: .9s; }
.flute .bub:nth-of-type(3) { animation-delay: 1.6s; }
@keyframes bub {
  0%   { transform: translateY(0);    opacity: 1; }
  70%  { transform: translateY(-7px); opacity: .25; }
  100% { transform: translateY(-9px); opacity: 0; }
}

/* the photo reel — a blue film strip that drops out of a silver slot */
:root { --reel-blue: #2f4ccf; --reel-perf: #1c2c9c; }

.film {
  position: relative;
  width: min(72vw, 248px);
  margin: 0 auto;
  padding-top: 24px;               /* room for the slot to sit on top */
}
/* a clean silver slot bar the reel feeds through */
.film-slot {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 120%;
  height: 26px;
  z-index: 3;
  border-radius: 7px;
  background: linear-gradient(#fdfdfd 0%, #d9dde4 30%, #c3c9d2 55%, #eceef2 100%);
  box-shadow:
    0 1px 0 rgba(255,255,255,.9) inset,
    0 8px 14px rgba(26,42,108,.26);
  pointer-events: none;
}
.film-slot::after {
  /* the dark slit the strip emerges from */
  content: "";
  position: absolute;
  left: 7%;
  right: 7%;
  bottom: 6px;
  height: 4px;
  border-radius: 2px;
  background: linear-gradient(#5a6070, #2c3040);
}
/* clips the reel's top edge so it reads as fed through the slot */
.film-feed {
  position: relative;
  overflow: hidden;
  padding-top: 22px;
  margin-top: -22px;
}
.film-strip {
  position: relative;
  background: var(--reel-blue);
  padding: 13px 15px 10px;
  box-shadow: 0 16px 28px rgba(26,42,108,.34);
  will-change: transform;
}
/* darker-blue film perforations down both edges */
.film-strip::before, .film-strip::after {
  content: "";
  position: absolute;
  top: 10px; bottom: 10px;
  width: 7px;
  background: repeating-linear-gradient(var(--reel-perf) 0 8px, transparent 8px 16px);
  border-radius: 4px;
}
.film-strip::before { left: 4px; }
.film-strip::after  { right: 4px; }
.film-window {
  position: relative;
  background: var(--white);
  margin: 0 auto 8px;
  padding: 4px;
  box-shadow: 0 1px 2px rgba(26,42,108,.18);
}
.film-window img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  display: block;
}
.film-caption {
  position: relative;
  font-family: var(--ff-script);
  color: var(--white);
  text-align: center;
  font-size: clamp(26px, 8vw, 36px);
  line-height: .96;
  margin: 10px 4px 6px;
  text-shadow: 0 1px 3px rgba(20,30,110,.4);
}
.film-caption span { display: block; font-size: .58em; opacity: .92; margin: -.05em 0; }
.film-caption .spark {
  font-style: normal;
  display: inline-block;
  font-size: .42em;
  vertical-align: middle;
  margin: 0 .5em;
  transform: translateY(-.4em);
  opacity: .95;
}
.film-checker {
  height: 18px;
  margin: 4px -15px -10px;         /* bleed to the strip edges */
  background:
    repeating-conic-gradient(var(--reel-perf) 0 25%, var(--white) 0 50%) 0 0 / 9px 9px;
}

/* ════════════════ PAGE 6 · FINALE ════════════════ */

.finale {
  text-align: center;
  padding-top: clamp(40px, 10vh, 90px);
  padding-bottom: clamp(60px, 14vh, 120px);
}

/* the golden ribbon winding down behind the car (PDF p.6) */
.ribbon {
  position: absolute;
  top: 0;
  left: 50%;
  transform: translateX(-50%);
  width: min(100%, 420px);
  color: var(--gold-deep);
  opacity: .9;
  z-index: 0;
  pointer-events: none;
}

.car-lane { position: relative; z-index: 1; overflow: hidden; padding: 10px 0 clamp(20px, 5vh, 40px); }
.car-wrap {
  position: relative;
  width: min(44vw, 180px);
  margin: 0 auto;
  will-change: transform;
}
.car { width: 100%; filter: drop-shadow(0 14px 18px rgba(26,42,108,.18)); }

/* the compliments card wears a lace doily + gold beading (PDF p.6) */
.card--gold-lace {
  max-width: 420px;
  margin: 0 auto;
  background: var(--cream);
  z-index: 1;
}
.card--gold-lace::before {
  /* fine gold beaded ring just inside the paper */
  content: "";
  position: absolute;
  inset: 8px;
  border-radius: 3px;
  background:
    radial-gradient(circle, var(--gold) 2.4px, transparent 2.8px) 0 0 / 12px 12px;
  -webkit-mask:
    linear-gradient(#000 0 0) top / 100% 12px no-repeat,
    linear-gradient(#000 0 0) bottom / 100% 12px no-repeat,
    linear-gradient(#000 0 0) left / 12px 100% no-repeat,
    linear-gradient(#000 0 0) right / 12px 100% no-repeat;
  pointer-events: none;
}
.card--gold-lace::after {
  /* white scalloped doily ring around the outside */
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 14px;
  background:
    radial-gradient(circle at 8px 8px, var(--cream) 7px, transparent 7.5px) 0 0 / 16px 16px;
  padding: 11px;
  -webkit-mask: linear-gradient(#000 0 0) content-box, linear-gradient(#000 0 0);
  -webkit-mask-composite: xor;
          mask-composite: exclude;
  pointer-events: none;
}
.compliments-lead { color: var(--ink-soft); font-weight: 400; margin-bottom: .8em; }
.compliments {
  font-size: clamp(15px, 4.3vw, 18px);
  text-decoration: underline;
  text-decoration-color: var(--gold);
  text-underline-offset: 4px;
  text-decoration-thickness: 1.5px;
  margin: .3em 0;
}
.finale-sign {
  margin-top: clamp(26px, 7vh, 50px);
}
.finale-sign span {
  display: inline-block;
  font-family: var(--ff-hand);
  color: var(--ink);
  font-size: clamp(30px, 9vw, 44px);
  line-height: 1;
  padding: .12em .6em .2em;
  background: radial-gradient(ellipse 70% 62% at 50% 54%,
    rgba(253,251,243,.96) 0%, rgba(253,251,243,.9) 46%, rgba(253,251,243,0) 78%);
}

/* ── blossoms drifting in the section corners ── */
.bloom {
  position: absolute;
  pointer-events: none;
  z-index: 0;
  width: clamp(90px, 26vw, 160px);
  opacity: .92;
  filter: drop-shadow(0 8px 12px rgba(26,42,108,.12));
}
.bloom--hero-tl { top: 2%;  left: -7%;  width: clamp(70px, 20vw, 120px); transform: rotate(-8deg); }
.bloom--hero-br { bottom: 6%; right: -9%; }
.bloom--std-tr  { top: -4%; right: -6%; }
.bloom--std-bl  { bottom: -3%; left: -7%; width: clamp(110px, 30vw, 180px); }

/* ════════════════ reduced motion / no-JS ════════════════ */
@media (prefers-reduced-motion: reduce) {
  .tap-hint svg { animation: none; }
  .flute .bub { animation: none; }
}
