/* VOICE   tender, formal, hushed — a hand-finished invitation, not a template
   IDEA    the burgundy envelope opens and the camera dives inside; the invitation is what lives in it
   PICTURE the envelope video, the rose corridor film as header, embossed damask, the pearl sprig
   COLOUR  burgundy & wine fields, pearl-blush accents (no gold), ivory rose paper, crimson roses
   TYPE    Pinyon Script for names, Cormorant Garamond for headings and text, tracked small caps for labels
   LAYOUT  mobile-first single column; editorial two-column splits from 900px */

:root {
  --burgundy: #3B1013; --wine: #24090C; --oxblood: #4A1719; --gold: #D8BFB6;
  --champagne: #F3E6DF; --ivory: #F2E8D7; --shadow: #160708;
  --paper: #FBF7F2; --crimson: #8C2F39;
  --script: "Pinyon Script", "Great Vibes", cursive;
  --serif: "Cormorant Garamond", "Cormorant", Garamond, "Times New Roman", serif;
  --display: "Cormorant Garamond", Garamond, serif;
  --ease: cubic-bezier(.22, .7, .15, 1);
  --pad: clamp(64px, 11vw, 150px);
  color-scheme: dark;
}
* { box-sizing: border-box; min-width: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--wine); color: var(--ivory);
  font: 500 18.5px/1.6 var(--serif); overflow-x: clip;
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
}
body.locked { overflow: hidden; height: 100svh; }
img { display: block; max-width: 100%; }
button, input, textarea, select { font: inherit; color: inherit; }
a { color: inherit; }
:focus-visible { outline: 1.5px solid var(--champagne); outline-offset: 3px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- shared type ---------- */
.label { font: 700 13px/1.4 var(--serif); letter-spacing: .32em; text-transform: uppercase; color: var(--gold); }
.title { font: 600 clamp(40px, 7vw, 68px)/1.05 var(--display); margin: 14px 0 0; letter-spacing: .01em; text-wrap: balance; }
.title em { font-style: italic; font-weight: 400; }
.lede { font-size: clamp(18.5px, 2.2vw, 21px); line-height: 1.6; max-width: 34em; margin: 18px auto 0; font-style: italic; font-weight: 600; opacity: .95; text-wrap: pretty; }
.script { font-family: var(--script); font-weight: 400; }
.center { text-align: center; }
.wrap { width: min(1180px, 100%); margin-inline: auto; position: relative; z-index: 2; }

/* ---------- sections ---------- */
.sec { position: relative; padding: var(--pad) max(6vw, 20px); isolation: isolate; overflow: hidden; }
.sec::before { content: ""; position: absolute; left: 0; right: 0; top: 0; height: clamp(90px, 16vw, 220px); background: linear-gradient(var(--prev, transparent), transparent); z-index: -1; pointer-events: none; }
.sec::after { content: ""; position: absolute; left: 50%; top: 0; width: min(320px, 60%); height: 1px; transform: translateX(-50%) scaleX(0); background: linear-gradient(90deg, transparent, var(--gold), transparent); transition: transform 1.8s var(--ease); z-index: 3; }
.sec.in-view::after { transform: translateX(-50%) scaleX(1); }
#couple::after, #couple::before { display: none; }
.sec .wrap { transition: opacity 1.2s var(--ease), transform 1.2s var(--ease); }
.sec .bg { position: absolute; inset: -12% 0; z-index: -2; background-size: cover; background-position: center; }
@media (pointer: fine) { .sec .bg { will-change: transform; } }
.sec .bg.tile { background-size: 512px; background-repeat: repeat; }
.sec .shade { position: absolute; inset: 0; z-index: -1; pointer-events: none; }
.sec.dark { background: var(--burgundy); color: var(--ivory); }
.sec.light { background: var(--ivory); color: var(--burgundy); }
.sec.light .label { color: #8C2F39; }
.sec.light .lede { opacity: .82; }
.decor { position: absolute; inset: 0; z-index: 1; pointer-events: none; }
.decor .orn { position: absolute; transform: translate(-50%, -50%); pointer-events: none; }
.decor .orn svg, .decor .orn img { width: 100%; height: auto; display: block; }
body.editing .decor { pointer-events: none; }
body.editing .decor .orn { pointer-events: auto; cursor: grab; outline: 1px dashed rgba(243, 230, 223, .5); outline-offset: 4px; }
body.editing .decor .orn.sel { outline: 1.5px solid var(--champagne); }

/* gold rule drawn on reveal */
.rule { width: min(360px, 76%); margin: 26px auto 0; display: block; }
.rule svg { width: 100%; height: auto; overflow: visible; }

/* ---------- reveal system ---------- */
.rv { opacity: 0; transform: translateY(26px); transition: opacity 1.1s var(--ease), transform 1.1s var(--ease); transition-delay: calc(var(--i, 0) * 110ms); }
.rv.in { opacity: 1; transform: none; }
.rv-mask { clip-path: inset(0 0 100% 0); transition: clip-path 1.5s var(--ease); transition-delay: calc(var(--i, 0) * 140ms); }
.rv-mask.in { clip-path: inset(0 0 0 0); }
.rv-mask img, .rv-mask .ph { transform: scale(1.18); transition: transform 2.2s var(--ease); transition-delay: calc(var(--i, 0) * 140ms); }
.rv-mask.in img, .rv-mask.in .ph { transform: scale(var(--z, 1)); }
.draw path, .draw ellipse, .draw circle:not([fill]) { stroke-dasharray: 1; stroke-dashoffset: 1; transition: stroke-dashoffset 2.4s var(--ease); }
.draw.in path, .draw.in ellipse, .draw.in circle:not([fill]) { stroke-dashoffset: 0; }
.draw [fill="url(#g-gold)"] { opacity: 0; transition: opacity 1s .6s; }
.draw.in [fill="url(#g-gold)"] { opacity: 1; }
.letters span { display: inline-block; opacity: 0; transform: translateY(.35em) rotate(4deg); filter: blur(6px);
  transition: opacity 1s var(--ease), transform 1.2s var(--ease), filter 1.2s var(--ease); transition-delay: calc(var(--d, 0ms) + var(--i) * 70ms); }
.in .letters span, .letters.in span { opacity: 1; transform: none; filter: none; }

/* ---------- fixed controls ---------- */
.hud { position: fixed; top: max(14px, env(safe-area-inset-top)); right: 14px; z-index: 60; display: flex; gap: 10px; opacity: 0; pointer-events: none; transition: opacity .8s; }
.hud.on { opacity: 1; pointer-events: auto; }
.hud button, .fab { width: 46px; height: 46px; border-radius: 50%; border: 1px solid rgba(216, 191, 182, .55);
  background: rgba(22, 7, 8, .55); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); color: var(--champagne); cursor: pointer; display: grid; place-items: center; transition: background .3s, transform .3s; }
.hud button:hover, .fab:hover { background: rgba(74, 23, 25, .85); transform: translateY(-1px); }
.hud svg, .fab svg { width: 20px; height: 20px; }
.hud .eq { display: flex; gap: 2px; align-items: flex-end; height: 14px; }
.hud .eq i { width: 2px; background: currentColor; height: 4px; }
.hud .playing .eq i { animation: eq 1s infinite ease-in-out alternate; }
.hud .eq i:nth-child(2) { animation-delay: .3s !important; } .hud .eq i:nth-child(3) { animation-delay: .6s !important; }
@keyframes eq { to { height: 14px; } }
.hud .muted .eq { display: none; }
.hud .playing .spk { display: none; }
.dots { position: fixed; right: 22px; top: 50%; transform: translateY(-50%); z-index: 55; display: none; flex-direction: column; gap: 14px; opacity: 0; transition: opacity .8s; }
.dots.on { opacity: 1; }
.dots a { width: 9px; height: 9px; border: 1px solid var(--gold); transform: rotate(45deg); display: block; position: relative; transition: background .3s; }
.dots a.cur { background: var(--gold); }
.dots a span { position: absolute; right: 22px; top: 50%; transform: rotate(-45deg) translate(0, -50%); transform-origin: right; white-space: nowrap; font: 600 11px var(--serif); letter-spacing: .22em; text-transform: uppercase; color: var(--champagne); opacity: 0; transition: opacity .3s; pointer-events: none; }
.dots a:hover span { opacity: 1; }
@media (min-width: 1000px) { .dots { display: flex; } }

/* =========================================================================
   INTRO — the envelope
   ========================================================================= */
#intro { position: fixed; inset: 0; z-index: 100; background: radial-gradient(120% 80% at 50% 45%, #3a1014 0%, var(--wine) 45%, var(--shadow) 100%); display: grid; place-items: center; overflow: hidden; transition: opacity 1.4s var(--ease), visibility 1.4s; }
#intro.gone { opacity: 0; visibility: hidden; }
.stage { position: relative; height: min(88svh, 1100px); aspect-ratio: 9 / 16; max-width: 92vw; cursor: pointer; border-radius: 6px; transform: scale(.96); opacity: 0;
  animation: stageIn 2s var(--ease) .2s forwards; }
@keyframes stageIn { to { transform: none; opacity: 1; } }
.stage .glow { position: absolute; inset: -6%; border-radius: 30px; background: radial-gradient(closest-side, rgba(243, 230, 223, .28), rgba(216, 191, 182, .08) 60%, transparent); filter: blur(24px); animation: breathe 4.5s ease-in-out infinite; z-index: -1; }
@keyframes breathe { 50% { opacity: .55; transform: scale(.98); } }
.stage .frame { position: absolute; inset: 0; overflow: hidden; border-radius: 6px; box-shadow: 0 40px 90px -30px #000, 0 0 0 1px rgba(216, 191, 182, .35); }
.stage video, .stage .poster { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transform-origin: 50% 48%; backface-visibility: hidden; }
.stage.playing video { transform: scale(1.06); transition: transform 3.6s cubic-bezier(.33, 0, .2, 1); }
.stage .poster { z-index: 2; transition: opacity .25s; }
.stage.playing .poster { opacity: 0; }
.stage.playing { cursor: default; }
.stage .frame { transform-origin: 50% 30%; will-change: transform; }
.stage.dive .frame { transform: scale(var(--k, 6)); box-shadow: none; transition: transform 1.7s cubic-bezier(.65, 0, .25, 1), box-shadow .4s; }
.stage.dive .glow { opacity: 0; transition: opacity .4s; }
#intro.diving { opacity: 0; visibility: hidden; transition: opacity 1.1s ease .75s, visibility 0s 1.9s; }
/* the single quiet cue: a pearl ring breathing over the ornament */
.tap-ring { position: absolute; left: 50%; top: 49.5%; width: 30%; aspect-ratio: 1; transform: translate(-50%, -50%); z-index: 5; pointer-events: none; transition: opacity .5s; }
.tap-ring i { position: absolute; inset: 0; border-radius: 50%; border: 1.5px solid rgba(251, 241, 236, .85); box-shadow: 0 0 18px rgba(251, 241, 236, .35); opacity: 0; animation: ring 3s cubic-bezier(.2, .6, .3, 1) infinite; }
.tap-ring i:nth-child(2) { animation-delay: 1s; } .tap-ring i:nth-child(3) { animation-delay: 2s; }
.tap-ring b { position: absolute; left: 50%; top: 50%; width: 10px; height: 10px; margin: -5px 0 0 -5px; border-radius: 50%; background: #fbf1ec; box-shadow: 0 0 14px 4px rgba(251, 241, 236, .55); animation: dot 3s ease-in-out infinite; }
@keyframes ring { 0% { transform: scale(.35); opacity: 0; } 20% { opacity: .9; } 100% { transform: scale(1.25); opacity: 0; } }
@keyframes dot { 50% { transform: scale(.6); opacity: .6; } }
.stage.playing .tap-ring { opacity: 0; }
.stage .sheen { position: absolute; inset: 0; z-index: 3; pointer-events: none; background: linear-gradient(115deg, transparent 35%, rgba(255, 246, 242, .16) 48%, transparent 60%); background-size: 260% 100%; animation: sheen 5s ease-in-out infinite 2s; mix-blend-mode: screen; }
@keyframes sheen { 0% { background-position: 120% 0; } 60%, 100% { background-position: -60% 0; } }
.stage.playing .sheen { display: none; }
/* phones: the envelope fills the screen */
@media (max-aspect-ratio: 3/4) {
  .stage { height: 100svh; width: 100vw; max-width: none; aspect-ratio: auto; border-radius: 0; }
  .stage .frame { border-radius: 0; box-shadow: none; }
  .stage .glow { display: none; }
  #intro::after { content: ""; position: absolute; inset: 0; pointer-events: none; box-shadow: inset 0 0 110px 20px rgba(22, 7, 8, .55); z-index: 4; transition: opacity .6s; }
  #intro.opening::after { opacity: 0; }
}

/* =========================================================================
   01 — COUPLE
   ========================================================================= */
#couple { min-height: 100svh; padding: 0; background: var(--wine); }
.hero-media { position: absolute; inset: 0; overflow: hidden; z-index: -2; transition: transform 2.6s cubic-bezier(.2, .7, .2, 1); }
.hero-media .bl { position: absolute; inset: -60px; background: center / cover var(--wine); filter: blur(30px) brightness(.5) saturate(1.15); }
.hero-media .hv { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 62%; }
@media (min-aspect-ratio: 3/4) {
  .hero-media .hv { left: 50%; width: auto; aspect-ratio: 9 / 16; transform: translateX(-50%); -webkit-mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent); mask-image: linear-gradient(90deg, transparent, #000 7%, #000 93%, transparent); }
}
.veil { position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: linear-gradient(180deg, rgba(36, 9, 12, .72) 0%, rgba(36, 9, 12, .3) 18%, rgba(36, 9, 12, 0) 34%, rgba(36, 9, 12, 0) 86%, rgba(36, 9, 12, .9) 100%); }
.veil::after { content: ""; position: absolute; inset: 0; background: radial-gradient(80% 70% at 50% 30%, var(--oxblood), var(--wine)); opacity: 0; transition: opacity 2.4s cubic-bezier(.4, 0, .2, 1) .2s; }
/* while the envelope is still closed the header waits behind a burgundy veil, slightly enlarged,
   so the dive into the envelope lands on the same colour and the film appears to rise from it */
body.locked .veil::after { opacity: 1; transition: none; }
body.locked .hero-media { transform: scale(1.18); transition: none; }
.hero-copy { position: relative; z-index: 2; min-height: 100svh; display: flex; flex-direction: column; align-items: center; text-align: center; padding: max(12svh, 84px) 22px 0; }
.hero-copy .label { color: var(--champagne); text-shadow: 0 2px 14px rgba(0, 0, 0, .6); }
.names { font: 400 clamp(64px, min(16vw, 11vh), 128px)/.92 var(--script); color: var(--champagne); margin: 14px 0 4px; }
.names .nm { display: block;
  background: linear-gradient(100deg, #cdb3ab 0%, #fffaf6 30%, #e5d2ca 50%, #fdf3ee 70%, #b9968d 100%); background-size: 220% 100%; -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
  padding: 0 .12em; }
.names .amp { font-size: .5em; line-height: 1.2; }
@keyframes goldShift { 50% { background-position: 100% 0; } }
.rv.blur { filter: blur(10px); transition: opacity 1.4s var(--ease), transform 1.4s var(--ease), filter 1.6s var(--ease); transition-delay: calc(var(--i, 0) * 110ms); }
.rv.blur.in { filter: none; }
.names .nm, #closing .sig { text-shadow: none; }
#couple .invite { font: italic 600 clamp(19px, 2.6vw, 24px)/1.5 var(--serif); margin: 6px auto 0; max-width: 22em; text-shadow: 0 2px 14px rgba(0, 0, 0, .7); }
#couple .when { margin-top: 18px; display: flex; align-items: center; justify-content: center; gap: 14px; font: 700 14px var(--serif); letter-spacing: .3em; text-transform: uppercase; color: var(--champagne); flex-wrap: wrap; text-shadow: 0 2px 12px rgba(0, 0, 0, .7); }
#couple .when i { width: 5px; height: 5px; transform: rotate(45deg); background: var(--champagne); display: inline-block; }
#couple canvas, #closing canvas { position: absolute; inset: 0; width: 100%; height: 100%; z-index: 0; pointer-events: none; }
.scroll-cue { position: absolute; bottom: 26px; left: 50%; transform: translateX(-50%); z-index: 3; width: 1px; height: 56px; background: linear-gradient(var(--gold), transparent); overflow: hidden; }
.scroll-cue::after { content: ""; position: absolute; left: 0; top: -20px; width: 1px; height: 20px; background: var(--champagne); animation: cue 2.2s ease-in-out infinite; }
@keyframes cue { to { top: 60px; } }

/* =========================================================================
   02 — STORY
   ========================================================================= */
#story .shade, #gallery .shade { background: rgba(250, 246, 242, .35); }
.collage { position: relative; width: min(540px, 100%); aspect-ratio: 1.12; margin: clamp(34px, 5vw, 54px) auto 0; }
.collage.n1 { aspect-ratio: 1.4; } .collage.n2 { aspect-ratio: 1.3; }
.fr { position: absolute; margin: 0; filter: drop-shadow(0 18px 24px rgba(74, 23, 25, .28)); transition: transform .8s var(--ease); }
.fr:hover { transform: translateY(-4px) rotate(var(--r, 0deg)) !important; z-index: 9; }
.fr-out, .fr-mid, .fr-in { position: absolute; }
.fr-out { inset: 0; background: linear-gradient(140deg, #b5636b, #8c2f39 45%, #e6cfc8 70%, #8c2f39); }
.fr-mid { inset: 2px; background: var(--paper); }
.fr-in { inset: 8px; overflow: hidden; background: var(--burgundy); }
.fr-in img { width: 100%; height: 100%; object-fit: cover; }
.fr-arch .fr-out, .fr-arch .fr-mid, .fr-arch .fr-in { border-radius: 50% 50% 8px 8px / 36% 36% 8px 8px; }
.fr-oval .fr-out, .fr-oval .fr-mid, .fr-oval .fr-in { border-radius: 50%; }
.fr-heart .fr-out, .fr-heart .fr-mid, .fr-heart .fr-in { -webkit-clip-path: url(#cp-heart); clip-path: url(#cp-heart); }
.fr-heart .fr-mid { inset: 3px; } .fr-heart .fr-in { inset: 10px 11px 14px; }
.fr-scallop .fr-out, .fr-scallop .fr-mid, .fr-scallop .fr-in { -webkit-clip-path: url(#cp-scallop); clip-path: url(#cp-scallop); }
/* positions: an arch in the middle, a heart and an oval leaning into it */
.collage .p0 { left: 31%; top: 0; width: 38%; height: 74%; z-index: 2; --r: 0deg; }
.collage .p1 { left: 1%; top: 36%; width: 37%; height: 42%; z-index: 3; transform: rotate(-7deg); --r: -7deg; }
.collage .p2 { right: 1%; top: 28%; width: 33%; height: 54%; z-index: 3; transform: rotate(6deg); --r: 6deg; }
.collage .p3 { left: 38%; top: 66%; width: 24%; height: 33%; z-index: 4; --r: 0deg; }
.collage.n1 .p0 { left: 32%; width: 36%; height: 100%; }
.collage.n2 .p0 { left: 18%; width: 36%; height: 92%; } .collage.n2 .p1 { left: 48%; top: 20%; width: 38%; height: 58%; }
.collage .fr.rv { opacity: 0; transform: translateY(26px) rotate(var(--r, 0deg)) scale(.94); }
.collage .fr.rv.in { opacity: 1; transform: rotate(var(--r, 0deg)); }
.moments { list-style: none; padding: 0; margin: clamp(28px, 4vw, 40px) auto 0; max-width: 32em; display: grid; gap: 4px; justify-items: center; text-align: center; }
.moments .when { font: 400 clamp(28px, 3.6vw, 34px)/1 var(--script); color: var(--crimson); }
.moments h3 { font: 600 clamp(24px, 3.2vw, 30px)/1.15 var(--display); margin: 6px 0 6px; }
.moments p { margin: 0; font-size: 18.5px; opacity: .92; }
.moments .sep { padding: 14px 0; }
.moments .sep i { display: block; width: 7px; height: 7px; transform: rotate(45deg); background: var(--crimson); opacity: .55; box-shadow: -18px 18px 0 -2px transparent; }
.sec.dark .moments .when { color: var(--champagne); } .sec.dark .moments .sep i { background: var(--gold); }

/* =========================================================================
   03 — DETAILS
   ========================================================================= */
#details { text-align: center; }
#details .bg { opacity: 1; }
#details .shade { background: radial-gradient(80% 60% at 50% 30%, rgba(74, 23, 25, .5), rgba(22, 7, 8, .6)); }
.cards { display: grid; gap: 0; margin: clamp(44px, 6vw, 70px) auto 0; grid-template-columns: minmax(0, 1fr); max-width: 560px; position: relative; }
.cards .card + .card { margin-top: 26px; }
.cards .card + .card::after { content: ""; position: absolute; left: 50%; top: -27px; width: 1px; height: 26px; background: linear-gradient(transparent, var(--gold), transparent); }
.card { position: relative; padding: 42px 24px 36px; background: linear-gradient(160deg, rgba(74, 23, 25, .75), rgba(36, 9, 12, .85)); border: 1px solid rgba(216, 191, 182, .45); border-radius: 3px; box-shadow: 0 30px 60px -30px #000; }
.card::before { content: ""; position: absolute; inset: 7px; border: 1px solid rgba(216, 191, 182, .2); pointer-events: none; }
.card .ic { width: 58px; height: 58px; margin: 0 auto 18px; border-radius: 50%; border: 1px solid var(--gold); display: grid; place-items: center; color: var(--champagne); }
.card .ic svg { width: 26px; height: 26px; }
.card .big { font: 600 clamp(26px, 3.2vw, 32px)/1.15 var(--display); color: var(--ivory); margin-top: 8px; }
.card .sub { font-style: italic; font-weight: 600; opacity: .85; margin-top: 6px; font-size: 17px; }
@keyframes spin { to { transform: rotate(360deg); } }
@keyframes bob { 50% { transform: translateY(-3px); } }
.count { margin-top: clamp(56px, 7vw, 80px); }
.count .label { color: var(--champagne); }
.clock { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(8px, 2vw, 24px); max-width: 680px; margin: 22px auto 0; }
.clock div { padding: 18px 4px 14px; border-top: 1px solid rgba(216, 191, 182, .5); border-bottom: 1px solid rgba(216, 191, 182, .5); }
.clock b { display: block; font: 600 clamp(40px, 8vw, 74px)/1 var(--display); color: var(--champagne); font-variant-numeric: lining-nums tabular-nums; }
.clock span { display: block; margin-top: 8px; font: 700 11.5px var(--serif); letter-spacing: .26em; text-transform: uppercase; opacity: .75; }
.clock b.tick { animation: tickIn .6s var(--ease); }
@keyframes tickIn { from { opacity: .3; transform: translateY(-6px); } }
.count .done { font: 400 clamp(40px, 7vw, 64px) var(--script); color: var(--champagne); }
.cal-links { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin-top: 30px; }

/* buttons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 50px; padding: 0 28px; border-radius: 999px; border: 1.2px solid var(--gold); background: transparent; color: var(--champagne); font: 700 13px var(--serif); letter-spacing: .24em; text-transform: uppercase; text-decoration: none; cursor: pointer; position: relative; overflow: hidden; transition: color .4s, background .4s, transform .3s; }
.btn::before { content: ""; position: absolute; inset: 0; background: linear-gradient(100deg, #e3d0c8, #fffaf6, #e5d2ca); transform: translateY(101%); transition: transform .5s var(--ease); z-index: -1; }
.btn { isolation: isolate; }
.btn:hover { color: var(--wine); }
.btn:hover::before { transform: none; }
.btn.solid { background: linear-gradient(100deg, #e3d0c8, #fffaf6 50%, #e5d2ca); color: var(--wine); border-color: transparent; }
.btn.solid::before { background: var(--ivory); }
.btn svg { width: 18px; height: 18px; }
.sec.light .btn { color: var(--burgundy); border-color: #8C2F39; }
.sec.light .btn:hover { color: var(--wine); }

/* =========================================================================
   04 — VENUE
   ========================================================================= */
#venue { background: var(--wine); }
#venue .bg { mix-blend-mode: soft-light; }
.venue-grid { display: grid; gap: clamp(36px, 5vw, 70px); align-items: center; margin-top: clamp(44px, 6vw, 70px); }
.venue-grid { justify-items: center; text-align: center; }
.venue-pic { width: min(760px, 100%); }
.venue-pic { position: relative; aspect-ratio: 4 / 3; }
@media (max-width: 600px) { .venue-pic { aspect-ratio: 4 / 5; } }
.venue-pic .pic { position: absolute; inset: 0; overflow: hidden; border-radius: 2px; }
.venue-pic .pic img, .venue-pic .pic .ph { width: 100%; height: 100%; object-fit: cover; }
.venue-pic .pic .ph svg { width: 100%; height: 100%; display: block; }
.venue-pic .gold-in { position: absolute; inset: 14px; border: 1px solid rgba(243, 230, 223, .7); pointer-events: none; z-index: 2; }
.venue-pic .gold-out { position: absolute; inset: -12px; border: 1px solid rgba(216, 191, 182, .4); pointer-events: none; }
.venue-pic .pic2 { position: absolute; right: -5%; bottom: -9%; width: 36%; aspect-ratio: 3 / 4; z-index: 4; padding: 6px; background: var(--paper); box-shadow: 0 24px 50px -18px rgba(22, 7, 8, .7); }
.venue-pic .pic2 .rv-mask { width: 100%; height: 100%; overflow: hidden; }
.venue-pic .pic2 img { width: 100%; height: 100%; object-fit: cover; }
@media (max-width: 600px) { .venue-pic .pic2 { right: -2%; width: 40%; } }
.venue-pic .tag { position: absolute; left: 30px; bottom: 0; transform: translate(0, 50%); z-index: 3; background: var(--wine); padding: 8px 18px; border: 1px solid var(--gold); white-space: nowrap; }
.venue-info h3 { font: 600 clamp(32px, 4.6vw, 46px)/1.08 var(--display); margin: 12px 0 16px; text-wrap: balance; }
.venue-info .addr { display: flex; gap: 12px; align-items: flex-start; font-size: 19.5px; font-weight: 600; }
.venue-info .addr svg { width: 22px; height: 22px; color: var(--gold); flex: none; margin-top: 4px; }
.venue-info .note { font-style: italic; opacity: .72; margin-top: 14px; }
.venue-info .acts { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 30px; }
.venue-info { text-align: center; max-width: 34em; } .venue-info .addr, .venue-info .acts { justify-content: center; }
.venue-info .addr { display: inline-flex; }

/* =========================================================================
   05 — GALLERY
   ========================================================================= */
#gallery { text-align: center; }
.masonry { columns: 2 160px; column-gap: 14px; margin-top: clamp(44px, 6vw, 70px); text-align: left; }
@media (min-width: 760px) { .masonry { columns: var(--c3, 3); column-gap: 18px; max-width: calc(var(--c3, 3) * 340px); margin-inline: auto; } }
@media (min-width: 1100px) { .masonry { columns: var(--c4, 4); max-width: calc(var(--c4, 4) * 320px); } }
.shot { break-inside: avoid; margin: 0 0 14px; position: relative; cursor: zoom-in; border: 0; padding: 0; width: 100%; display: block; background: var(--burgundy); overflow: hidden; border-radius: 2px; }
@media (min-width: 760px) { .shot { margin-bottom: 18px; } }
.shot img { width: 100%; height: auto; transition: transform 1.4s var(--ease), filter .8s; }
.shot::after { content: ""; position: absolute; inset: 10px; border: 1px solid rgba(243, 230, 223, 0); transition: border-color .6s, inset .6s; pointer-events: none; }
.shot figcaption { position: absolute; left: 0; right: 0; bottom: 0; padding: 40px 16px 14px; color: var(--ivory); font: italic 600 16.5px var(--serif); background: linear-gradient(transparent, rgba(22, 7, 8, .8)); opacity: 0; transform: translateY(8px); transition: .6s var(--ease); }
.shot:hover img, .shot:focus-visible img { transform: scale(1.06); filter: saturate(1.08); }
.shot:hover::after, .shot:focus-visible::after { border-color: rgba(243, 230, 223, .8); inset: 14px; }
.shot:hover figcaption, .shot:focus-visible figcaption { opacity: 1; transform: none; }
@media (hover: none) { .shot figcaption { opacity: 1; transform: none; font-size: 14px; padding: 30px 12px 10px; } }
.empty { padding: 50px 20px; border: 1px dashed #8C2F39; font-style: italic; opacity: .7; }

/* lightbox */
.lb { position: fixed; inset: 0; z-index: 90; background: rgba(16, 4, 6, .96); display: grid; grid-template-rows: auto 1fr auto; opacity: 0; visibility: hidden; transition: opacity .5s, visibility .5s; }
.lb.on { opacity: 1; visibility: visible; }
.lb header { display: flex; justify-content: space-between; align-items: center; padding: max(12px, env(safe-area-inset-top)) 14px 6px 20px; color: var(--champagne); }
.lb .track { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; scrollbar-width: none; min-height: 0; }
.lb .track::-webkit-scrollbar { display: none; }
.lb .slide { flex: 0 0 100%; scroll-snap-align: center; display: grid; place-items: center; padding: 10px clamp(10px, 6vw, 90px); min-height: 0; }
.lb .slide img { max-width: 100%; max-height: calc(100svh - 170px); object-fit: contain; box-shadow: 0 30px 80px -20px #000; outline: 1px solid rgba(216, 191, 182, .35); outline-offset: 8px; opacity: .35; transform: scale(.96); transition: opacity .6s, transform .8s var(--ease); }
.lb .slide.cur img { opacity: 1; transform: none; }
.lb footer { display: flex; align-items: center; justify-content: center; gap: 18px; padding: 10px 14px max(16px, env(safe-area-inset-bottom)); color: var(--ivory); }
.lb footer .cap { font: italic 18px var(--serif); min-width: 0; flex: 1; text-align: center; max-width: 520px; }
.lb .navb { width: 48px; height: 48px; border-radius: 50%; border: 1px solid rgba(216, 191, 182, .6); background: none; color: var(--champagne); cursor: pointer; display: grid; place-items: center; flex: none; }
.lb .navb:hover { background: rgba(216, 191, 182, .15); }
.lb .navb svg { width: 20px; height: 20px; }

/* =========================================================================
   06 — TIMELINE
   ========================================================================= */
#timeline { text-align: center; }
#timeline .shade { background: linear-gradient(rgba(22, 7, 8, .55), rgba(36, 9, 12, .35)); }
.tl { position: relative; max-width: 620px; margin: clamp(50px, 7vw, 80px) auto 0; text-align: center; }
.tl .spine { position: absolute; top: 0; bottom: 0; left: 50%; width: 1px; transform: translateX(-50%); background: rgba(216, 191, 182, .25); }
.tl .spine i { position: absolute; inset: 0; background: linear-gradient(var(--champagne), var(--gold)); transform-origin: top; transform: scaleY(var(--p, 0)); }
.ev { position: relative; display: grid; justify-items: center; gap: 14px; padding-bottom: 56px; }
.ev:last-child { padding-bottom: 0; }
.ev .medal { width: 66px; height: 66px; border-radius: 50%; background: var(--wine); border: 1px solid var(--gold); display: grid; place-items: center; color: var(--champagne); position: relative; z-index: 1; box-shadow: 0 0 0 8px rgba(36, 9, 12, .95); transition: box-shadow .8s; }
.ev.in .medal { box-shadow: 0 0 0 8px rgba(36, 9, 12, .95), 0 0 28px rgba(243, 230, 223, .35); }
.ev .medal svg { width: 30px; height: 30px; }
.ev .body { position: relative; z-index: 1; padding: 10px 18px 12px; background: var(--wine); }
.ev .time { font: 600 clamp(32px, 4.4vw, 42px)/1 var(--display); color: var(--champagne); font-variant-numeric: lining-nums; white-space: nowrap; }
.ev h3 { font: 600 clamp(24px, 3vw, 30px)/1.15 var(--display); margin: 8px 0 6px; }
.ev p { margin: 0 auto; opacity: .92; max-width: 26em; }
.theme-light .ev .body { background: var(--paper); background: url(../img/paper-ivory.jpg) var(--paper); background-size: 512px; }

/* =========================================================================
   07 — RSVP
   ========================================================================= */
#rsvp { background: radial-gradient(100% 80% at 50% 0%, var(--oxblood), var(--wine)); }
#rsvp .bg { mix-blend-mode: soft-light; }
.rsvp-card { position: relative; max-width: 640px; margin: clamp(44px, 6vw, 64px) auto 0; background: url(../img/paper-roses.jpg) center / cover var(--ivory); color: var(--burgundy); padding: clamp(36px, 6vw, 64px) clamp(22px, 6vw, 60px); border-radius: 3px; box-shadow: 0 50px 90px -40px #000; }
.rsvp-card::before { content: ""; position: absolute; inset: 10px; border: 1px solid rgba(122, 38, 48, .55); pointer-events: none; }
.rsvp-card::after { content: ""; position: absolute; inset: 15px; border: 1px solid rgba(122, 38, 48, .25); pointer-events: none; }
.rsvp-card .deadline { text-align: center; font-style: italic; opacity: .75; margin: 0 0 26px; }
.field { margin-bottom: 22px; position: relative; z-index: 1; }
.field > label, .field > .lab { display: block; font: 700 12.5px var(--serif); letter-spacing: .26em; text-transform: uppercase; color: #8C2F39; margin-bottom: 8px; }
.field input[type=text], .field textarea { width: 100%; font-size: 18px; padding: 12px 2px; background: transparent; border: 0; border-bottom: 1px solid rgba(74, 23, 25, .35); color: var(--burgundy); border-radius: 0; transition: border-color .3s; }
.field textarea { resize: vertical; min-height: 92px; font-family: var(--serif); }
.field input:focus, .field textarea:focus { outline: none; border-bottom-color: var(--gold); box-shadow: 0 1px 0 var(--gold); }
.field .err { color: #8e1d23; font-size: 14.5px; font-style: italic; margin-top: 6px; display: none; }
.field.bad .err { display: block; }
.choice { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.choice label { position: relative; cursor: pointer; }
.choice input { position: absolute; opacity: 0; }
.choice span { display: grid; place-items: center; min-height: 54px; border: 1px solid rgba(74, 23, 25, .35); font-size: 17px; text-align: center; padding: 6px 10px; transition: .35s var(--ease); line-height: 1.2; }
.choice input:checked + span { background: var(--burgundy); color: var(--champagne); border-color: var(--burgundy); }
.choice input:focus-visible + span { outline: 1.5px solid var(--gold); outline-offset: 3px; }
.stepper { display: inline-flex; align-items: center; border: 1px solid rgba(74, 23, 25, .35); }
.stepper button { width: 50px; height: 50px; background: none; border: 0; cursor: pointer; font-size: 22px; color: var(--burgundy); }
.stepper button:disabled { opacity: .3; }
.stepper output { min-width: 50px; text-align: center; font: 500 24px var(--display); }
.rsvp-card .btn { width: 100%; margin-top: 8px; position: relative; z-index: 1; }
.rsvp-card .btn.solid { color: var(--wine); }
.rsvp-card .fine { text-align: center; font-size: 14px; opacity: .6; font-style: italic; margin: 14px 0 0; position: relative; z-index: 1; }
.thanks { text-align: center; position: relative; z-index: 1; display: none; }
.rsvp-card.sent form { display: none; }
.rsvp-card.sent .thanks { display: block; animation: fadeUp 1.2s var(--ease); }
.seal { width: 120px; height: 120px; margin: 0 auto 18px; position: relative; }
.seal svg { width: 100%; height: 100%; overflow: visible; }
.seal .wax { transform-origin: center; transform: scale(0); }
.sent .seal .wax { animation: seal 1s cubic-bezier(.3, 1.6, .5, 1) .2s forwards; }
.seal .chk { stroke-dasharray: 40; stroke-dashoffset: 40; }
.sent .seal .chk { animation: chk .8s var(--ease) 1s forwards; }
@keyframes seal { to { transform: scale(1); } }
@keyframes chk { to { stroke-dashoffset: 0; } }
.thanks h3 { font: 400 clamp(52px, 9vw, 72px)/1 var(--script); color: var(--burgundy); margin: 0; }
.thanks p { font-size: 19px; font-style: italic; max-width: 26em; margin: 12px auto 24px; }
.thanks .sprig { width: 130px; margin: 0 auto 20px; filter: drop-shadow(0 2px 2px rgba(74, 23, 25, .35)) brightness(.85) contrast(1.1); }
.burst { position: absolute; left: 50%; top: 60px; width: 0; height: 0; pointer-events: none; }
.burst i { position: absolute; width: 6px; height: 6px; background: var(--gold); transform: rotate(45deg); opacity: 0; }
.sent .burst i { animation: burst 1.4s var(--ease) .5s forwards; }
@keyframes burst { 0% { opacity: 1; transform: translate(0, 0) rotate(45deg) scale(1); } 100% { opacity: 0; transform: translate(var(--x), var(--y)) rotate(225deg) scale(.4); } }

/* =========================================================================
   08 — CLOSING
   ========================================================================= */
#closing { min-height: 100svh; display: grid; place-items: center; text-align: center; background: radial-gradient(80% 60% at 50% 40%, var(--oxblood), var(--burgundy) 50%, var(--shadow)); }
#closing .bg { filter: saturate(.9); }
.cl-media { position: absolute; inset: 0; z-index: -2; overflow: hidden; background: #0b0506; }
.cl-media video { width: 100%; height: 100%; object-fit: cover; object-position: 50% 40%; }
#closing .shade { background: radial-gradient(70% 55% at 50% 48%, rgba(22, 7, 8, .62), rgba(22, 7, 8, .25) 70%), linear-gradient(rgba(22, 7, 8, .55), rgba(22, 7, 8, 0) 30%, rgba(22, 7, 8, 0) 70%, rgba(22, 7, 8, .9)); }
#closing .quote { font: italic 600 clamp(30px, 5.4vw, 56px)/1.18 var(--display); max-width: 15em; margin: 26px auto 0; text-wrap: balance; color: var(--ivory); }
#closing .with { margin-top: clamp(40px, 6vw, 60px); font: 700 13px var(--serif); letter-spacing: .32em; text-transform: uppercase; color: var(--gold); }
#closing .sig { font: 400 clamp(64px, 13vw, 120px)/1 var(--script); margin-top: 12px; color: var(--champagne);
  background: linear-gradient(100deg, #cdb3ab, #fffaf6 35%, #e5d2ca 55%, #fdf3ee 80%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent; padding: .05em .15em; }
#closing .sprig { width: clamp(110px, 20vw, 160px); margin: 28px auto 0; }
#closing .light { position: absolute; inset: 0; z-index: -1; pointer-events: none; background: conic-gradient(from 200deg at 50% -10%, transparent, rgba(243, 230, 223, .12) 8%, transparent 16%, rgba(243, 230, 223, .07) 24%, transparent 32%); opacity: 0; transition: opacity 3s; }
#closing.in-view .light { opacity: 1; animation: rays 14s ease-in-out infinite alternate; }
@keyframes rays { to { transform: rotate(4deg) scale(1.05); } }
.endbar { margin-top: clamp(50px, 7vw, 80px); display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; }
footer.foot { background: var(--shadow); color: rgba(242, 232, 215, .6); text-align: center; padding: 26px 20px calc(26px + env(safe-area-inset-bottom)); font: 600 11.5px var(--serif); letter-spacing: .3em; text-transform: uppercase; }

/* =========================================================================
   placeholder notice (sample content)
   ========================================================================= */
.sample-note { display: inline-block; margin-top: 14px; font: italic 14px var(--serif); opacity: .6; }
body.no-sample-note .sample-note { display: none; }
.ph { position: relative; width: 100%; height: 100%; }



/* =========================================================================
   ANIMATED ICONS — gentle looping motion, starts when revealed (.in)
   ========================================================================= */
.ai * { transform-box: fill-box; transform-origin: center; animation-play-state: paused; }
.in .ai *, .ai.run * { animation-play-state: running; }
.ai-calendar .pg { transform-origin: top; animation: pageFlip 4.5s cubic-bezier(.6, 0, .3, 1) infinite; }
.ai-calendar .rg { animation: ringBob 4.5s ease-in-out infinite; }
.ai-calendar .hrt { animation: beat 1.6s ease-in-out infinite; }
@keyframes pageFlip { 0%, 62% { transform: scaleY(1); opacity: 1; } 72% { transform: scaleY(0); opacity: .2; } 74% { transform: scaleY(0); opacity: 0; } 86%, 100% { transform: scaleY(1); opacity: 1; } }
@keyframes ringBob { 0%, 60%, 100% { transform: none; } 66% { transform: translateY(-1px); } }
.ai-clock .hand-m { transform-box: view-box; transform-origin: 12px 12px; animation: spin 6s linear infinite; }
.ai-clock .hand-h { transform-box: view-box; transform-origin: 12px 12px; animation: spin 72s linear infinite; }
.ai-pin .drop { animation: drop 2.6s cubic-bezier(.3, .7, .4, 1) infinite; }
.ai-pin .shd { animation: shd 2.6s cubic-bezier(.3, .7, .4, 1) infinite; }
@keyframes drop { 0%, 100% { transform: translateY(0); } 40% { transform: translateY(-3px); } 55% { transform: translateY(0) scaleY(.94); } 65% { transform: none; } }
@keyframes shd { 0%, 100% { transform: scaleX(1); opacity: 1; } 40% { transform: scaleX(.6); opacity: .5; } }
.ai-rings .r1 { animation: ringL 3.6s cubic-bezier(.5, 0, .2, 1) infinite; }
.ai-rings .r2 { animation: ringR 3.6s cubic-bezier(.5, 0, .2, 1) infinite; }
.ai-rings .gem { animation: ringR 3.6s cubic-bezier(.5, 0, .2, 1) infinite; }
.ai-rings .tw { animation: twinkle 3.6s ease-in-out infinite; }
@keyframes ringL { 0%, 100% { transform: translateX(-2.2px); } 35%, 75% { transform: none; } }
@keyframes ringR { 0%, 100% { transform: translateX(2.2px); } 35%, 75% { transform: none; } }
@keyframes twinkle { 0%, 35% { opacity: 0; transform: scale(.3) rotate(0); } 45% { opacity: 1; transform: scale(1.1) rotate(45deg); } 60%, 100% { opacity: 0; transform: scale(.3) rotate(90deg); } }
.ai-glass .gl { transform-origin: 50% 100%; animation: clinkL 3s cubic-bezier(.5, 0, .3, 1) infinite; }
.ai-glass .gr { transform-origin: 50% 100%; animation: clinkR 3s cubic-bezier(.5, 0, .3, 1) infinite; }
.ai-glass .clk { animation: twinkle2 3s ease-out infinite; }
.ai-glass .bb { animation: bubble 1.8s ease-in infinite; } .ai-glass .b2 { animation-delay: .9s; }
@keyframes clinkL { 0%, 30%, 100% { transform: none; } 45%, 55% { transform: rotate(12deg); } }
@keyframes clinkR { 0%, 30%, 100% { transform: none; } 45%, 55% { transform: rotate(-12deg); } }
@keyframes twinkle2 { 0%, 44% { opacity: 0; transform: scale(.4); } 50% { opacity: 1; transform: scale(1.1); } 70%, 100% { opacity: 0; transform: scale(1.3); } }
@keyframes bubble { 0% { transform: translateY(1.5px); opacity: 0; } 30% { opacity: 1; } 100% { transform: translateY(-3.5px); opacity: 0; } }
.ai-dinner .cl { transform-origin: 85% 100%; animation: cloche 3.4s cubic-bezier(.5, 0, .3, 1) infinite; }
.ai-dinner .st { animation: steam 3.4s ease-in-out infinite; } .ai-dinner .s2 { animation-delay: .25s; }
@keyframes cloche { 0%, 25%, 85%, 100% { transform: none; } 45%, 65% { transform: translateY(-2.5px) rotate(-14deg); } }
@keyframes steam { 0%, 35% { opacity: 0; transform: translateY(3px); } 55% { opacity: 1; } 80%, 100% { opacity: 0; transform: translateY(-2px); } }
.ai-music .n0 { animation: sway 2.4s ease-in-out infinite; }
.ai-music .fl { animation: floatUp 2.8s ease-out infinite; } .ai-music .f2 { animation-delay: 1.4s; }
@keyframes sway { 50% { transform: rotate(-6deg); } }
@keyframes floatUp { 0% { transform: translateY(3px); opacity: 0; } 25% { opacity: 1; } 100% { transform: translateY(-4px) rotate(10deg); opacity: 0; } }
.ai-cake .flm { transform-origin: 50% 100%; animation: flicker 1.1s ease-in-out infinite alternate; }
@keyframes flicker { 0% { transform: scale(1, 1) skewX(0); } 40% { transform: scale(.9, 1.15) skewX(4deg); } 100% { transform: scale(1.05, .92) skewX(-3deg); } }
.ai-camera .lens { animation: spin 8s linear infinite; }
.ai-camera .fls { animation: flash 3s ease-out infinite; }
@keyframes flash { 0%, 80%, 100% { opacity: .3; transform: scale(1); } 84% { opacity: 1; transform: scale(2.4); } }
.ai-heart .bt { animation: beat 1.4s ease-in-out infinite; }
.ai-heart .ech { animation: echo 1.4s ease-out infinite; }
@keyframes beat { 0%, 40%, 100% { transform: scale(1); } 15% { transform: scale(1.14); } 28% { transform: scale(1.04); } }
@keyframes echo { 0% { transform: scale(1); opacity: .7; } 100% { transform: scale(1.5); opacity: 0; } }
.ai-car .bd { animation: carBob .5s ease-in-out infinite alternate; }
@keyframes carBob { to { transform: translateY(-.6px); } }
.ai-car .wh { animation: spin 1s linear infinite; }
.ai-sparkle .sp { animation: spark 2.4s ease-in-out infinite; }
@keyframes spark { 0%, 100% { transform: scale(.75) rotate(0); opacity: .6; } 50% { transform: scale(1.08) rotate(22deg); opacity: 1; } }
.ai-dove .wg { transform-origin: 90% 100%; animation: flap .9s ease-in-out infinite alternate; }
@keyframes flap { to { transform: rotate(-18deg) scaleY(.85); } }
.card .ai, .ev .medal .ai { overflow: visible; }

/* =========================================================================
   LIGHT IDENTITY (theme.mode = "light") — ivory/white leads, burgundy accents.
   The header film and the closing stay cinematic; everything else is paper.
   ========================================================================= */
/* ornaments drawn in burgundy wherever the ground is light */
.sec.light [stroke="url(#g-gold)"], .theme-light .sec:not(#closing):not(#couple) [stroke="url(#g-gold)"] { stroke: url(#g-wine); }
.sec.light [fill="url(#g-gold)"], .theme-light .sec:not(#closing):not(#couple) [fill="url(#g-gold)"] { fill: url(#g-wine); }

body.theme-light { background: var(--paper); color: var(--burgundy); }
/* intro: the burgundy envelope rests on ivory; the dive lands on an ivory card */
.theme-light #intro { background: radial-gradient(110% 80% at 50% 45%, #fffdfa 0%, var(--paper) 50%, #efe4da 100%); }
.theme-light .stage .glow { background: radial-gradient(closest-side, rgba(74, 23, 25, .22), rgba(74, 23, 25, .06) 60%, transparent); }
.theme-light .stage .frame { box-shadow: 0 50px 90px -35px rgba(36, 9, 12, .65), 0 0 0 1px rgba(74, 23, 25, .2); }
.theme-light .stage .frame::after { content: ""; position: absolute; inset: 0; z-index: 6; background: var(--paper); opacity: 0; pointer-events: none; transition: opacity .9s ease .55s; }
.theme-light .stage.dive .frame::after { opacity: 1; }
@media (max-aspect-ratio: 3/4) { .theme-light #intro::after { box-shadow: inset 0 0 90px 10px rgba(22, 7, 8, .35); } }

/* header: ivory veil, burgundy lettering */
.theme-light .veil { background: linear-gradient(180deg, rgba(251, 247, 242, .7) 0%, rgba(251, 247, 242, .32) 15%, rgba(251, 247, 242, 0) 30%, rgba(251, 247, 242, 0) 88%, rgba(251, 247, 242, .92) 100%); }
.theme-light .names { filter: drop-shadow(0 0 2px rgba(255, 255, 255, .95)) drop-shadow(0 0 14px rgba(255, 255, 255, .9)); }
.theme-light .veil::after { background: var(--paper); }
.theme-light .hero-media .bl { filter: blur(26px) brightness(.97) saturate(1.2); }
.theme-light .hero-copy .label, .theme-light #couple .when { color: var(--crimson); text-shadow: 0 0 2px #fff, 0 0 8px #fff, 0 0 16px rgba(255, 255, 255, .9); }
.theme-light #couple .when i { background: var(--crimson); }
.theme-light #couple .invite { color: var(--burgundy); text-shadow: 0 0 2px #fff, 0 0 10px #fff, 0 0 18px rgba(255, 255, 255, .9); }
.theme-light .names .nm { background-image: linear-gradient(100deg, #5e1a22 0%, #8c2f39 30%, #4a1719 55%, #a3505a 75%, #5e1a22 100%); }
.theme-light .rv.blur.in { filter: none; }
.theme-light #couple .scroll-cue { background: linear-gradient(var(--crimson), transparent); }

/* the formerly dark sections become ivory paper */
.theme-light .sec.dark:not(#closing):not(#couple) { background: url(../img/paper-ivory.jpg) var(--paper); background-size: 512px; color: var(--burgundy); }
.theme-light .sec.dark:not(#closing):not(#couple) .bg { display: none; }
.theme-light .sec.dark:not(#closing):not(#couple) .shade { background: none; }
.theme-light #venue.sec.dark { background: url(../img/paper-roses.jpg) center / cover var(--paper); }
.theme-light .sec:not(#closing):not(#couple) .label { color: var(--crimson); }
.theme-light .sec.light { background-color: var(--paper); }
.theme-light .sec::after { background: linear-gradient(90deg, transparent, var(--crimson), transparent); opacity: .5; }
.theme-light #closing::after { background: linear-gradient(90deg, transparent, var(--gold), transparent); opacity: 1; }

/* celebration cards & countdown */
.theme-light .card { background: rgba(255, 255, 255, .7); border-color: rgba(140, 47, 57, .3); box-shadow: 0 30px 60px -36px rgba(74, 23, 25, .45); }
.theme-light .card::before { border-color: rgba(140, 47, 57, .14); }
.theme-light .card .ic { border-color: var(--crimson); color: var(--crimson); }
.theme-light .card .big { color: var(--burgundy); }
.theme-light .cards .card + .card::after { background: linear-gradient(transparent, var(--crimson), transparent); }
.theme-light .count .label { color: var(--crimson); }
.theme-light .clock div { border-color: rgba(140, 47, 57, .35); }
.theme-light .clock b { color: var(--burgundy); }
.theme-light .count .done { color: var(--crimson); }

/* buttons on paper */
.theme-light .sec:not(#closing) .btn { color: var(--burgundy); border-color: var(--crimson); }
.theme-light .sec:not(#closing) .btn::before { background: var(--burgundy); }
.theme-light .sec:not(#closing) .btn:hover { color: var(--paper); }
.theme-light .sec:not(#closing) .btn.solid { background: var(--burgundy); color: var(--paper); border-color: var(--burgundy); }
.theme-light .sec:not(#closing) .btn.solid::before { background: var(--crimson); }

/* venue */
.theme-light .venue-pic .gold-out { border-color: rgba(140, 47, 57, .35); }
.theme-light .venue-pic .tag { background: var(--paper); border-color: var(--crimson); color: var(--crimson); }
.theme-light .venue-info .addr svg { color: var(--crimson); }
.theme-light .venue-info h3 { color: var(--burgundy); }

/* timeline */
.theme-light .tl .spine { background: rgba(140, 47, 57, .18); }
.theme-light .tl .spine i { background: linear-gradient(var(--crimson), var(--burgundy)); }
.theme-light .ev .medal { background: var(--paper); border-color: var(--crimson); color: var(--crimson); box-shadow: 0 0 0 8px var(--paper); }
.theme-light .ev.in .medal { box-shadow: 0 0 0 8px var(--paper), 0 10px 30px -8px rgba(140, 47, 57, .45); }
.theme-light .ev .time { color: var(--crimson); }

/* RSVP card sits on plain paper so the roses belong to the card */
.theme-light #rsvp { background: url(../img/paper-ivory.jpg) var(--paper); background-size: 512px; }
.theme-light .rsvp-card { box-shadow: 0 40px 80px -40px rgba(74, 23, 25, .55), 0 0 0 1px rgba(140, 47, 57, .12); }

/* controls on light grounds */
.theme-light .dots a { border-color: var(--crimson); }
.theme-light .dots a.cur { background: var(--crimson); }
.theme-light .dots a span { color: var(--crimson); }


/* =========================================================================
   BOLDER SCRIPT + MOTION EVERYWHERE
   ========================================================================= */
/* the script face has one weight; a hairline stroke in the same colour thickens it */
.names .nm { -webkit-text-stroke: 1.1px rgba(243, 230, 223, .55); }
.theme-light .names .nm { -webkit-text-stroke: 1.2px rgba(110, 32, 41, .75); }
#closing .sig { -webkit-text-stroke: 1px rgba(243, 230, 223, .5); }
.moments .when, .thanks h3, .count .done { -webkit-text-stroke: .6px currentColor; }

/* headings rise word by word */
.title .w, .quote .w { display: inline-block; opacity: 0; transform: translateY(.5em) rotate(2deg); filter: blur(4px);
  transition: opacity .9s var(--ease), transform 1.1s var(--ease), filter 1s var(--ease); transition-delay: calc(150ms + var(--w) * 90ms); }
.title.in .w, .quote.in .w { opacity: 1; transform: none; filter: none; }
.title.rv, .quote.rv { opacity: 1; transform: none; }
/* labels open their tracking as they appear */
.label.rv { letter-spacing: .7em; transition: opacity 1.1s var(--ease), transform 1.1s var(--ease), letter-spacing 1.6s var(--ease); }
.label.rv.in { letter-spacing: .32em; }
/* ledes come into focus */
.lede.rv { filter: blur(5px); transition: opacity 1.2s var(--ease), transform 1.2s var(--ease), filter 1.4s var(--ease); }
.lede.rv.in { filter: none; }

/* photographs breathe slowly (independent "scale" so it never fights the reveal) */
@keyframes breatheImg { from { scale: 1; } to { scale: 1.07; } }
.venue-pic .pic.in img, .venue-pic .pic2 .in img, .fr.in .fr-in img { animation: breatheImg 14s ease-in-out infinite alternate; }
.shot.in img { animation: breatheImg 18s ease-in-out infinite alternate; }
.shot:nth-child(even).in img { animation-delay: -6s; }

/* the story frames float, each on its own rhythm */
@keyframes floaty { 0%, 100% { translate: 0 0; } 50% { translate: 0 -7px; } }
.fr.in { animation: floaty 6s ease-in-out infinite; }
.fr.p1.in { animation-duration: 7s; animation-delay: -2s; } .fr.p2.in { animation-duration: 6.5s; animation-delay: -4s; } .fr.p3.in { animation-duration: 8s; animation-delay: -1s; }
.moments li.rv:not(.sep) .when { display: inline-block; transition: transform 1.2s var(--ease) .15s, opacity 1.2s .15s; transform: translateX(-24px); opacity: 0; }
.moments li.rv.in .when { transform: none; opacity: 1; }
.moments .sep.rv i { transform: rotate(45deg) scale(0); transition: transform .8s var(--ease) .2s; }
.moments .sep.rv.in i { transform: rotate(225deg) scale(1); }

/* gallery tiles settle in with a slight turn */
.shot.rv { transform: translateY(34px) scale(.95) rotate(-1.5deg); }
.shot.rv:nth-child(even) { transform: translateY(34px) scale(.95) rotate(1.5deg); }
.shot.rv.in { transform: none; }

/* cards: lift on hover, a soft light passes across once revealed */
.card { transition: transform .6s var(--ease), box-shadow .6s var(--ease); overflow: hidden; }
.card:hover { transform: translateY(-4px); }
.card::after { content: ""; position: absolute; inset: 0; background: linear-gradient(110deg, transparent 35%, rgba(255, 255, 255, .35) 50%, transparent 65%); transform: translateX(-110%); pointer-events: none; }
.card.in::after { animation: sweep 1.6s var(--ease) .6s; }
@keyframes sweep { to { transform: translateX(110%); } }
.card .ic { transition: transform .8s cubic-bezier(.3, 1.6, .5, 1) .3s; transform: scale(.4); }
.card.in .ic { transform: none; }

/* buttons: a glint every few seconds */
.btn::after { content: ""; position: absolute; top: 0; bottom: 0; width: 40%; left: -60%; background: linear-gradient(100deg, transparent, rgba(255, 255, 255, .45), transparent); transform: skewX(-20deg); animation: glint 5.5s ease-in-out infinite 2s; pointer-events: none; }
@keyframes glint { 0%, 70% { left: -60%; } 100% { left: 130%; } }

/* timeline: medals pop, text follows */
.ev .medal { transform: scale(.5); transition: transform .9s cubic-bezier(.3, 1.6, .5, 1), box-shadow .8s; }
.ev.in .medal { transform: none; }
.ev .body > * { opacity: 0; transform: translateY(14px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
.ev.in .body > * { opacity: 1; transform: none; }
.ev.in .body > :nth-child(2) { transition-delay: .12s; } .ev.in .body > :nth-child(3) { transition-delay: .24s; }

/* venue tag and second photo slide into place */
.venue-pic .tag { transition: transform 1s var(--ease) .6s, opacity 1s .6s; opacity: 0; }
.venue-pic.in .tag { opacity: 1; }
.venue-pic .pic2.rv { transform: translate(30px, 30px) rotate(6deg); }
.venue-pic .pic2.rv.in { transform: rotate(3deg); }

/* RSVP fields draw their underline on focus */
.field input[type=text], .field textarea { background-image: linear-gradient(var(--crimson), var(--crimson)); background-size: 0 1.5px; background-repeat: no-repeat; background-position: 50% 100%; transition: background-size .5s var(--ease), border-color .3s; }
.field input[type=text]:focus, .field textarea:focus { background-size: 100% 1.5px; box-shadow: none; }

/* header: names glow gently in, scroll cue pulses */
.hero-copy .when i { animation: spin 8s linear infinite; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .rv, .rv-mask, .letters span, .draw [fill], .title .w, .quote .w, .ev .body > *, .card .ic, .venue-pic .tag { opacity: 1 !important; transform: none !important; clip-path: none !important; filter: none !important; }
  .shot img, .fr, .fr-in img, .venue-pic img { animation: none !important; scale: 1 !important; translate: 0 0 !important; }
  .draw path, .draw ellipse, .draw circle { stroke-dashoffset: 0 !important; }
  .sec .bg { transform: none !important; }
  html { scroll-behavior: auto; }
}

/* header details sit on a soft pearl ribbon so they stay legible over the film */
.theme-light #couple .when, .theme-light .hero-copy > .label { background: rgba(251, 247, 242, .82); padding: 7px 18px; border-radius: 999px; box-shadow: 0 6px 20px -10px rgba(74, 23, 25, .35); }
#couple .when, .hero-copy > .label { background: rgba(36, 9, 12, .55); padding: 7px 18px; border-radius: 999px; }

/* ---------- RSVP: bold, and the optional message opens after "Will you attend?" ---------- */
.rsvp-card { font-weight: 600; }
.rsvp-card .deadline { font-weight: 600; opacity: .9; }
.field input[type=text], .field textarea { font-weight: 600; }
.field input::placeholder, .field textarea::placeholder { font-weight: 500; color: rgba(59, 16, 19, .5); }
.choice span { font-weight: 700; }
.field .opt { text-transform: none; letter-spacing: 0; font-style: italic; font-weight: 500; }
.msg-field { display: grid; grid-template-rows: 0fr; opacity: 0; margin-bottom: 0; transition: grid-template-rows .7s var(--ease), opacity .6s var(--ease), margin-bottom .7s var(--ease); }
.msg-field > * { overflow: hidden; }
.msg-field > label { min-height: 0; }
.msg-field.open { grid-template-rows: auto 1fr; opacity: 1; margin-bottom: 22px; }
.msg-field:not(.open) > label, .msg-field:not(.open) > textarea { max-height: 0; margin: 0; padding: 0; border: 0; }

/* ---------- header: no white at all — the film shows in full colour ---------- */
.theme-light .veil { background: none; }
.veil { background: none; }
.theme-light .names { filter: drop-shadow(0 2px 6px rgba(36, 9, 12, .35)); }
.theme-light .names .nm { -webkit-text-stroke: 1.2px rgba(94, 26, 34, .9); }
.theme-light #couple .when, .theme-light .hero-copy > .label, #couple .when, .hero-copy > .label,
.theme-light #couple .invite, #couple .invite {
  background: rgba(59, 16, 19, .72); color: #FBF1EC; text-shadow: none; padding: 7px 18px; border-radius: 999px; box-shadow: 0 8px 22px -10px rgba(22, 7, 8, .6);
}
#couple .invite { display: inline-block; border-radius: 18px; padding: 8px 20px; max-width: min(26em, 92%); }
.theme-light #couple .when i, #couple .when i { background: #FBF1EC; }
.theme-light .hero-media .bl { filter: blur(26px) brightness(.85) saturate(1.25); }

/* ---------- header copy sits in one burgundy arch panel (no white over the film) ---------- */
.hero-copy { padding-top: max(9svh, 70px); }
.hero-panel { position: relative; width: min(520px, 92%); padding: clamp(30px, 5vh, 46px) clamp(18px, 5vw, 40px) clamp(22px, 3.4vh, 32px); text-align: center;
  background: linear-gradient(180deg, rgba(59, 16, 19, .82), rgba(74, 23, 25, .74)); border-radius: 260px 260px 18px 18px / 150px 150px 18px 18px;
  box-shadow: 0 30px 60px -24px rgba(22, 7, 8, .7), inset 0 0 0 1px rgba(243, 230, 223, .35), inset 0 0 0 7px rgba(59, 16, 19, 0), inset 0 0 0 8px rgba(243, 230, 223, .18);
  opacity: 0; transform: translateY(18px) scale(.97); transition: opacity 1.4s var(--ease) .2s, transform 1.6s var(--ease) .2s; }
body:not(.locked) .hero-panel { opacity: 1; transform: none; }
.hero-panel .label, .theme-light .hero-panel .label { background: none; box-shadow: none; padding: 0; color: #E6D3CB; text-shadow: none; }
.theme-light .hero-panel .names, .hero-panel .names { filter: none; }
.theme-light .hero-panel .names .nm, .hero-panel .names .nm { background-image: linear-gradient(100deg, #e6d3cb 0%, #fffaf6 30%, #ead8d0 55%, #fdf3ee 75%, #d9c2ba 100%); -webkit-text-stroke: 1px rgba(253, 243, 238, .55); }
.theme-light .hero-panel .invite, .hero-panel .invite, .theme-light #couple .hero-panel .invite { background: none; box-shadow: none; padding: 0; color: #FBF1EC; display: block; max-width: none; }
.theme-light #couple .hero-panel .when, #couple .hero-panel .when { background: none; box-shadow: none; padding: 0; color: #E6D3CB; margin-top: 14px; }
.hero-panel .rule { margin-top: 14px; width: min(220px, 70%); }

/* ---------- header copy straight on the film: no panel, no white — a soft burgundy halo carries it ---------- */
.hero-panel { background: none !important; box-shadow: none !important; padding: 0 !important; width: min(680px, 94%); border-radius: 0; }
.hero-panel .names, .theme-light .hero-panel .names { filter: drop-shadow(0 0 1px rgba(36, 9, 12, .95)) drop-shadow(0 3px 10px rgba(36, 9, 12, .8)) drop-shadow(0 0 28px rgba(36, 9, 12, .55)) !important; }
.hero-panel .names .nm, .theme-light .hero-panel .names .nm { -webkit-text-stroke: .8px rgba(253, 243, 238, .6); }
.hero-panel .label, .theme-light .hero-panel .label,
.hero-panel .invite, .theme-light .hero-panel .invite, .theme-light #couple .hero-panel .invite,
.hero-panel .when, #couple .hero-panel .when, .theme-light #couple .hero-panel .when {
  color: #FBF1EC !important; text-shadow: 0 0 2px rgba(36, 9, 12, .95), 0 2px 8px rgba(36, 9, 12, .85), 0 0 22px rgba(36, 9, 12, .65) !important;
}
.hero-panel .when i, .theme-light #couple .hero-panel .when i { background: #FBF1EC; box-shadow: 0 0 6px rgba(36, 9, 12, .9); }


/* ---------- Beautiful Moments: interlocking romantic frames, a different composition from Our Story ---------- */
.moments-collage { width: min(600px, 100%); aspect-ratio: 1.05; }
.moments-collage .fr { cursor: zoom-in; }
.moments-collage .p0 { left: 2%; top: 4%; width: 40%; height: 62%; z-index: 2; transform: rotate(-5deg); --r: -5deg; }
.moments-collage .p1 { left: 30%; top: 16%; width: 40%; height: 74%; z-index: 3; transform: none; --r: 0deg; }
.moments-collage .p2 { right: 1%; top: 2%; width: 38%; height: 44%; z-index: 4; transform: rotate(7deg); --r: 7deg; }
.moments-collage .p3 { right: 4%; top: 52%; width: 32%; height: 42%; z-index: 2; transform: rotate(4deg); --r: 4deg; }
.moments-collage.n3 .p2 { top: 8%; height: 46%; }
.moments-collage .fr figcaption { position: absolute; left: 50%; bottom: -14px; transform: translateX(-50%); white-space: nowrap; z-index: 5;
  font: italic 600 14.5px var(--serif); color: var(--paper); background: var(--burgundy); padding: 4px 12px; border-radius: 999px;
  opacity: 0; transition: opacity .5s var(--ease), bottom .5s var(--ease); pointer-events: none; }
.moments-collage .fr:hover figcaption, .moments-collage .fr:focus-visible figcaption { opacity: 1; bottom: -6px; }
@media (hover: none) { .moments-collage .fr figcaption { opacity: 1; } }
.moments-collage .fr-heart figcaption { bottom: -4px; }


/* ---------- closing: white petals film, burgundy lettering in its own faces ---------- */
.theme-light #closing { background: #f3f1ef; color: var(--burgundy); }
.theme-light #closing .shade { background: radial-gradient(55% 40% at 50% 46%, rgba(255, 255, 255, .55), rgba(255, 255, 255, 0) 70%), linear-gradient(rgba(251, 247, 242, .9), rgba(251, 247, 242, 0) 16%, rgba(251, 247, 242, 0) 86%, rgba(22, 7, 8, .35)); }
.theme-light #closing .light { display: none; }
.theme-light #closing .cl-media { background: #f3f1ef; }
.theme-light #closing .quote { font: italic 500 clamp(28px, 5.2vw, 50px)/1.28 "Playfair Display", Georgia, serif; color: var(--burgundy); text-shadow: 0 0 2px #fff, 0 0 14px rgba(255, 255, 255, .95); }
.theme-light #closing .with { font: 600 13px/1.4 "Cinzel", serif; letter-spacing: .34em; color: var(--crimson); text-shadow: 0 0 10px #fff; }
.theme-light #closing .sig { font: 400 clamp(62px, 13vw, 116px)/1.05 "Great Vibes", var(--script); background-image: linear-gradient(100deg, #5e1a22, #8c2f39 40%, #4a1719 70%, #a3505a); -webkit-text-stroke: .6px rgba(94, 26, 34, .8); filter: drop-shadow(0 0 10px rgba(255, 255, 255, .95)); }
.theme-light #closing .sprig { filter: brightness(.45) sepia(.6) hue-rotate(-30deg) saturate(3); }
.theme-light #closing .btn { color: var(--burgundy); border-color: var(--crimson); background: rgba(251, 247, 242, .75); }
.theme-light #closing .btn::before { background: var(--burgundy); }
.theme-light #closing .btn:hover { color: var(--paper); }
.theme-light #closing::after { background: linear-gradient(90deg, transparent, var(--crimson), transparent); opacity: .5; }

/* ---------- RSVP form: larger, centred, easy to read ---------- */
.rsvp-card .deadline { font-size: 20px; }
.field > label, .field > .lab { font-size: 14px; letter-spacing: .22em; text-align: center; }
.field input[type=text] { text-align: center; font-size: 22px; padding: 14px 4px; }
.field textarea { text-align: center; font-size: 20px; min-height: 110px; }
.field input::placeholder, .field textarea::placeholder { font-size: inherit; text-align: center; color: rgba(59, 16, 19, .58); }
.field .err { text-align: center; font-size: 16px; }
.choice span { font-size: 20px; min-height: 60px; }
.rsvp-card .btn { font-size: 14.5px; min-height: 56px; }
.thanks p { font-size: 21px; }
