:root {
  --gold: #e9c77a; --gold-hi: #fff1cc; --gold-lo: #c99a44;
  --ink: #fffaf0; --ink-soft: rgba(255, 248, 232, .82);
  --serif: "Cormorant Garamond", Georgia, "Times New Roman", serif;
  --sans: "Jost", system-ui, -apple-system, "Segoe UI", sans-serif;
  --col: min(100vw, calc(100svh * 9 / 16));
}
* { box-sizing: border-box; }
html { scroll-snap-type: y mandatory; scroll-behavior: auto; background: #0c1430; }
body { margin: 0; color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
button, input, select, textarea { font: inherit; color: inherit; }

/* desktop: the invite is a phone-shaped column over a soft night backdrop */
.backdrop { position: fixed; inset: 0; z-index: -1;
  background: radial-gradient(1200px 800px at 50% 30%, #23305e, #0b1029 70%); }
.book { width: var(--col); margin: 0 auto; box-shadow: 0 0 120px rgba(0, 0, 0, .55); }

.page { position: relative; height: 100svh; overflow: hidden; scroll-snap-align: start; scroll-snap-stop: always;
  display: flex; flex-direction: column; isolation: isolate; background: #111; }
.clip { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; z-index: -2; }
.clip.intro { transition: opacity 1s ease; }
.page.looping .clip.intro { opacity: 0; }

/* copy blocks and the scrims that keep them readable over the paintings */
.copy { position: relative; padding: 9svh 8% 10svh; text-align: center; width: 100%; }
.copy.top { margin-bottom: auto; } .copy.bottom { margin-top: auto; } .copy.center { margin: auto 0; }
.copy::before { content: ""; position: absolute; inset: -12svh 0; z-index: -1; pointer-events: none; }
.copy.bottom::before { background: linear-gradient(to top, rgba(28, 18, 6, .86), rgba(28, 18, 6, .55) 55%, transparent); }
.scrim-night-up::before { background: linear-gradient(to top, rgba(6, 9, 28, .9), rgba(6, 9, 28, .6) 65%, transparent) !important; }
.scrim-light.top::before, .copy.top.scrim-light::before { background: linear-gradient(to bottom, rgba(20, 34, 26, .55), rgba(20, 34, 26, .2) 60%, transparent); }
.scrim-light.bottom::before { background: linear-gradient(to top, rgba(30, 26, 14, .88), rgba(30, 26, 14, .55) 60%, transparent); }
.scrim-dark::before { background: linear-gradient(to bottom, rgba(40, 18, 4, .66), rgba(40, 18, 4, .25) 60%, transparent); }
.scrim-night::before { background: linear-gradient(to bottom, rgba(6, 9, 28, .82), rgba(6, 9, 28, .55) 70%, transparent); }
.panel { width: auto; margin: auto 6% !important; padding: 1.6rem 1.3rem !important; border-radius: 18px; border: 1px solid rgba(233, 199, 122, .35);
  background: rgba(8, 11, 32, .72); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); }


.kicker, .label { font: 500 .72rem/1.4 var(--sans); letter-spacing: .32em; text-transform: uppercase; color: var(--gold); margin: 0 0 1rem; }
.names { font: italic 500 clamp(3rem, 15vw, 4.6rem)/1 var(--serif); margin: 0;
  background: linear-gradient(180deg, var(--gold-hi), var(--gold) 70%, var(--gold-lo)); -webkit-background-clip: text; background-clip: text; color: transparent;
  filter: drop-shadow(0 3px 14px rgba(0, 0, 0, .55)); }
.names.small { font-size: clamp(2.4rem, 11vw, 3.4rem); }
.amp { font-size: .62em; vertical-align: .12em; padding: 0 .06em; }
.title { font: italic 500 clamp(2.4rem, 11vw, 3.2rem)/1 var(--serif); margin: 0 0 1.4rem; color: var(--ink); text-shadow: 0 2px 16px rgba(0, 0, 0, .5); }
.line, .quote { font: italic 500 1.3rem/1.35 var(--serif); color: var(--ink-soft); margin: 1.4rem 0 0; text-shadow: 0 2px 10px rgba(0, 0, 0, .55); }
.quote { font-size: clamp(1.7rem, 8vw, 2.2rem); color: var(--ink); margin: 0; }

.open { margin-top: 2rem; padding: .85rem 1.8rem; border: 1px solid rgba(233, 199, 122, .7); border-radius: 999px;
  background: rgba(20, 12, 4, .35); letter-spacing: .2em; text-transform: uppercase; font-size: .72rem; cursor: pointer; backdrop-filter: blur(4px); }
.open:hover, .open:focus-visible { background: rgba(233, 199, 122, .2); outline: none; }

.families { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin: .4rem 0 0; }
.families .label { display: block; font-size: .62rem; margin-bottom: .45rem; }
.families .who { font: 500 1.15rem/1.3 var(--serif); }

.date { font: italic 500 clamp(2rem, 9.5vw, 2.7rem)/1.1 var(--serif); margin: 0; text-shadow: 0 2px 14px rgba(0, 0, 0, .5); }
.countdown { display: flex; justify-content: center; gap: 1.1rem; margin-top: 1.6rem; }
.countdown div { display: flex; flex-direction: column; min-width: 3.4rem; }
.countdown b { font: 500 2.1rem/1 var(--serif); font-variant-numeric: tabular-nums; color: var(--gold-hi); }
.countdown span { font-size: .6rem; letter-spacing: .26em; text-transform: uppercase; color: var(--ink-soft); margin-top: .35rem; }

.days { display: grid; gap: .7rem; text-align: left; }
.day { background: rgba(14, 16, 40, .6); border: 1px solid rgba(233, 199, 122, .35); border-radius: 14px; padding: .85rem 1rem; backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); }
#pre .day { background: rgba(16, 34, 20, .55); }
.day h3 { font: 600 1.2rem/1.15 var(--serif); margin: 0 0 .5rem; color: var(--gold-hi); }
.day ul { list-style: none; margin: 0; padding: 0; display: grid; gap: .45rem; }
.day li { display: flex; justify-content: space-between; align-items: baseline; gap: .8rem; }
.fn { display: flex; flex-direction: column; }
.fn .en { font-size: .9rem; color: var(--ink); }
.fn .hi { font: .78rem/1.3 "Tiro Devanagari Hindi", "Noto Sans Devanagari", serif; color: var(--ink-soft); }
.time { font: italic 500 1rem/1.2 var(--serif); color: var(--gold-hi); white-space: nowrap; text-align: right; }
.venue { margin-top: .7rem; padding-top: .6rem; border-top: 1px solid rgba(233, 199, 122, .25); display: flex; flex-direction: column; gap: .1rem; }
.vname { font: 600 1.1rem/1.2 var(--serif); }
.addr { font-size: .78rem; color: var(--ink-soft); }
.route { align-self: flex-start; margin-top: .45rem; font-size: .66rem; letter-spacing: .24em; text-transform: uppercase; color: var(--gold); text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.blessing { font: italic 500 1.05rem/1.35 var(--serif); color: var(--ink-soft); margin: 1.3rem 0 0; }
.kids { font: .82rem/1.55 "Tiro Devanagari Hindi", "Noto Sans Devanagari", serif; color: var(--ink-soft); margin: 1rem 0 0; }
.kids b { color: var(--gold); font-weight: 400; }

.monogram { width: 7.4rem; height: 7.4rem; margin: 0 auto 1.4rem; border-radius: 50%; border: 1.5px solid var(--gold); position: relative;
  display: flex; align-items: center; justify-content: center; gap: .1rem; font: italic 500 3rem/1 var(--serif); color: var(--gold-hi);
  box-shadow: 0 0 24px rgba(255, 200, 110, .35), inset 0 0 18px rgba(255, 200, 110, .18); }
.monogram::after { content: ""; position: absolute; inset: 6px; border-radius: 50%; border: 1px solid rgba(233, 199, 122, .5); }
.monogram i { font-size: 1.2rem; align-self: center; }
.monogram span:last-child { transform: translateY(.3rem); }
.rule { width: 11rem; height: 1px; margin: 1.2rem auto; background: linear-gradient(90deg, transparent, var(--gold), transparent); }
.pair { margin: .7rem 0 0; display: flex; flex-direction: column; gap: .2rem; }
.pair .label { margin: 0; font-size: .66rem; }
.pair span:last-child { font: italic 500 1.45rem/1.2 var(--serif); }

.dots { position: fixed; right: max(10px, calc((100vw - var(--col))/2 + 10px)); top: 50%; transform: translateY(-50%); display: grid; gap: 10px; z-index: 5; }
.dots button { width: 7px; height: 7px; padding: 0; border-radius: 50%; border: 0; background: rgba(40, 30, 10, .35); cursor: pointer; transition: transform .3s, background .3s; }
.dots.night button { background: rgba(255, 245, 220, .35); }
.dots button.on { background: var(--gold); transform: scale(1.5); }

/* entrance: copy rises in after its scene starts gathering */
.reveal { opacity: 0; transform: translateY(18px); transition: opacity 1.1s cubic-bezier(.2, .7, .2, 1), transform 1.1s cubic-bezier(.2, .7, .2, 1); }
.page.in .reveal { opacity: 1; transform: none; }
.page.in .reveal:nth-child(1) { transition-delay: .5s; } .page.in .reveal:nth-child(2) { transition-delay: .75s; }
.page.in .reveal:nth-child(3) { transition-delay: 1s; } .page.in .reveal:nth-child(4) { transition-delay: 1.2s; }
.page.in .reveal:nth-child(n+5) { transition-delay: 1.35s; }
#cover.in .reveal:nth-child(1) { transition-delay: 3.4s; } #cover.in .reveal:nth-child(2) { transition-delay: 3.8s; } #cover.in .reveal:nth-child(3) { transition-delay: 4.6s; }
.events .reveal { transition-delay: 1.1s; } .events .reveal + .reveal { transition-delay: 1.35s; }

@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; transition: none; }
}

#wedding .copy, #reception .copy { padding-bottom: 5svh; }
#finale .copy { padding-top: 6svh; }
#finale .monogram { width: 6rem; height: 6rem; font-size: 2.5rem; margin-bottom: 1rem; }
#finale .copy { padding-top: 4.5svh; }
#finale .rule { margin: .8rem auto; }
#finale .pair { margin-top: .45rem; }
#finale .blessing { margin-top: .9rem; font-size: .98rem; }
#finale .kids { margin-top: .7rem; font-size: .76rem; }
