/* Invite sections below the hero: date scratch, welcome arch, timeline, countdown, venue, sign-off.
   Theme (shared with hero.css): off-white paper, dark red text, gold ornament. */
:root {
  --paper: #f5efe7;
  --paper-2: #efe6d9;
  --maroon: #7a1424;
  --maroon-deep: #4f0c16;
  --gold: #a87a24;
  --gold-soft: #d9b46a;
  --gold-pale: #ead7a8;
  --script: 'Great Vibes', 'Snell Roundhand', 'Apple Chancery', cursive;
  --serif: 'Cormorant Garamond', Georgia, serif;
  --caps: 'Cinzel', Georgia, serif;
}

/* the invite is a phone-width card; on wide screens a soft shadow on its left and right sets it apart */
html, body { background: var(--paper); }
main {
  width: min(100vw, 440px, 56.25vh); /* same width as the envelope (#introStage in index.html) */
  margin: 0 auto;
  background: var(--paper);
  min-height: 100vh;
  overflow: hidden;
  box-shadow: -18px 0 36px -18px rgba(79, 12, 22, .28), 18px 0 36px -18px rgba(79, 12, 22, .28);
}
main .hero { min-height: 100svh; background: var(--paper); }
/* faint monogram watermark repeated behind the whole invite (the hero and scene images cover their own area) */
main { position: relative; isolation: isolate; }
main::before {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background: url(watermark.png) 0 0 / 240px auto repeat;
  opacity: .12;
}
main .stage { width: 100%; border: 0; box-shadow: none; }

.sec {
  position: relative;
  padding: 64px 20px;
  text-align: center;
  color: var(--maroon);
  font-family: var(--serif);
  overflow: hidden;
}
.sec + .sec { padding-top: 8px; }
.wrap { max-width: 560px; margin: 0 auto; position: relative; }

.kicker { margin: 0 0 6px; font-family: var(--caps); font-size: 12px; letter-spacing: .3em; text-transform: uppercase; color: var(--gold); }
.title { margin: 0; font-family: var(--script); font-weight: 400; font-size: clamp(44px, 11vw, 64px); line-height: 1.1; color: var(--maroon); }
.ornament { display: block; width: 180px; height: 18px; margin: 14px auto 26px; color: var(--gold); }
.lead { margin: 0 auto; max-width: 30em; font-size: clamp(18px, 4.6vw, 21px); line-height: 1.5; color: var(--maroon-deep); }

/* reveal on scroll */
.rv { opacity: 0; transform: translateY(26px); transition: opacity 1.1s ease, transform 1.1s cubic-bezier(.2, .7, .2, 1); }
.rv.in { opacity: 1; transform: none; }
.rv-fade { transform: none; transition: opacity 1.4s ease; }   /* plain fade, no slide */

/* #VIvaaHIT above "Save the date" */
.hashtag {
  margin: 0 0 clamp(18px, 4svh, 32px);
  font-family: 'Cormorant Garamond', Georgia, serif; font-weight: 600;
  font-size: clamp(34px, 9vw, 52px); line-height: 1; letter-spacing: .01em;
  color: var(--maroon);
}
.hashtag .h-hash { color: var(--gold); font-weight: 500; margin-right: .03em; }
.hashtag i { font-weight: 400; color: #b8506b; }

/* ───────── date scratch ───────── */
.scratch-row { display: flex; justify-content: center; gap: clamp(12px, 4vw, 26px); margin-top: 6px; }
.scratch {
  position: relative;
  width: clamp(92px, 25vw, 124px); aspect-ratio: 1;
  border-radius: 50%;
  border: 1.5px solid var(--gold-soft);
  box-shadow: 0 0 0 5px var(--paper), 0 0 0 6px rgba(168, 122, 36, .35), 0 10px 26px rgba(122, 20, 36, .12);
  background: radial-gradient(circle at 50% 40%, #fffdf8, var(--paper-2));
  display: grid; place-items: center;
}
.scratch .v { font-family: var(--caps); font-size: clamp(24px, 7vw, 34px); color: var(--maroon); letter-spacing: .04em; }
.scratch canvas { position: absolute; inset: 0; width: 100%; height: 100%; border-radius: 50%; cursor: grab; touch-action: none; transition: opacity .8s ease; }
.scratch canvas.done { opacity: 0; pointer-events: none; }
.scratch-hint { margin: 22px 0 0; font-family: var(--caps); font-size: 11px; letter-spacing: .28em; text-transform: uppercase; color: var(--gold); }
.date-full { margin: 14px 0 0; line-height: 1; font-family: var(--script); font-size: clamp(30px, 8vw, 40px); color: var(--maroon); opacity: 0; transition: opacity 1s ease .3s; }
.date-full.show { opacity: 1; }

/* ───────── welcome arch (owner's invite artwork, assets/site/arch.png) ───────── */
.arch {
  position: relative; max-width: 520px; margin: -40px auto 0; /* top of the art is a faded edge */
  aspect-ratio: 1012 / 1416;
  background: url(arch.png) center / 100% 100% no-repeat;
  container-type: inline-size;
}
/* text sits inside the arch opening; sizes scale with the artwork */
.arch .inner {
  position: absolute; left: 21%; right: 21%; top: 15.5%; bottom: 8%;
  display: flex; flex-direction: column; align-items: center; justify-content: space-between;
}
.arch .lbl { margin: 0; font-family: var(--caps); font-size: 2.55cqw; letter-spacing: .1em; line-height: 1.6; text-transform: uppercase; color: var(--maroon-deep); }
.arch .name { margin: 0; font-family: var(--script); font-weight: 400; font-size: 10.5cqw; line-height: 1; color: var(--maroon); }
.arch .with { margin: 0; font-family: var(--script); font-size: 6cqw; line-height: 1; color: var(--gold); }
.arch .div { display: block; width: 22cqw; height: 2.2cqw; margin: 0; color: var(--gold); }
.arch .dear { margin: 1.5cqw 0 0; font-family: var(--script); font-size: 5.6cqw; line-height: 1; white-space: nowrap; color: var(--maroon); }
.arch .msg { margin: 0; font-size: 3.4cqw; line-height: 1.35; color: var(--maroon-deep); }
.arch .parivar { margin: 0; font-family: var(--script); font-size: 5.6cqw; line-height: 1; white-space: nowrap; color: var(--maroon); }   /* per-side pages: family sign-off */

/* ───────── timeline ───────── */
.day { margin: 40px 0 0; }
.day h3 { margin: 0 0 22px; font-family: var(--caps); font-weight: 400; font-size: 14px; letter-spacing: .3em; text-transform: uppercase; color: var(--gold); }
.day h3 span { display: inline-block; padding: 7px 18px; border: 1px solid rgba(168, 122, 36, .45); border-radius: 999px; background: linear-gradient(160deg, var(--maroon), var(--maroon-deep)); color: #fff4dd; }   /* same red + cream as the countdown */
.events { position: relative; display: grid; gap: 18px; }
.events::before { content: ''; position: absolute; left: 50%; top: -22px; bottom: 0; width: 1px; background: linear-gradient(var(--gold-soft), rgba(217, 180, 106, .15)); }
.ev {
  position: relative;
  padding: 26px 20px 22px;
  border-radius: 18px;
  background: linear-gradient(180deg, #fffdf8, var(--paper-2));
  border: 1px solid rgba(168, 122, 36, .3);
  box-shadow: 0 12px 30px rgba(122, 20, 36, .08);
  overflow: hidden;
}
.ev::before { content: ''; position: absolute; inset: 7px; border-radius: 13px; border: 1px solid rgba(168, 122, 36, .22); pointer-events: none; }
.ev h4 { margin: 0; font-family: var(--script); font-weight: 400; font-size: clamp(34px, 9vw, 42px); line-height: 1.1; color: var(--maroon); position: relative; }
.ev .when { margin: 10px 0 0; font-family: var(--caps); font-weight: 700; font-size: 13px; letter-spacing: .2em; text-transform: uppercase; color: var(--gold); position: relative; }
.ev .note { margin: 8px 0 0; font-size: 19px; color: var(--maroon-deep); position: relative; }
/* small plain THEME: label, the theme itself larger and bold */
.ev .note span { font-family: var(--caps); font-size: 12px; letter-spacing: .2em; color: var(--gold); }
.ev .note b { font-weight: 600; }
/* hall name under the date + time */
.ev .venue { margin: 10px 0 0; font-family: var(--caps); font-weight: 700; font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--maroon-deep); position: relative; }
.ev.reception { padding-bottom: 0; }
.ev.reception img { display: block; width: min(260px, 70%); height: auto; margin: 14px auto 0; position: relative; filter: drop-shadow(0 10px 18px rgba(79, 12, 22, .18)); }
.then { margin: -6px 0; font-family: var(--script); font-size: 26px; color: var(--gold); position: relative; justify-self: center; padding: 0 12px; }
/* a collapsed event (e.g. "followed by dinner"): cream tab pinned over the bottom edge of the card above,
   overlapping it by 12px so cards keep their usual padding (gap 18px - 30px) */
.then.tab { margin: -30px 0 0; z-index: 2; padding: 4px 22px 6px; line-height: 1.2; color: var(--maroon);
  background: linear-gradient(180deg, #fffaf0, #f6e7c8); border: 1.5px solid var(--gold-soft); border-radius: 999px; box-shadow: 0 6px 14px rgba(120, 80, 20, .16); }

/* a few lines under a card from someone on that side (events.json "wish"), per-side pages only */
.ev-wish { position: relative; padding: 10px 12px 8px; border-radius: 14px; background: var(--paper); text-align: center; }   /* paper hides the timeline line behind the text */
.ev-wish .lines { margin: 0; font-size: clamp(21px, 5.6vw, 25px); font-style: italic; font-weight: 500; line-height: 1.4; color: var(--maroon); }
.ev-wish .note { margin: 10px 0 0; font-size: 18px; color: var(--gold); }
.ev-wish .note::before, .ev-wish .note::after { content: '•'; margin: 0 .5em; }
.ev-wish .rule { display: block; position: relative; width: min(240px, 70%); height: 1px; margin: 14px auto 12px; background: var(--gold-soft); }
.ev-wish .rule::after { content: ''; position: absolute; left: 50%; top: 50%; width: 7px; height: 7px; background: var(--gold); transform: translate(-50%, -50%) rotate(45deg); }
.ev-wish .from { margin: 0; font-size: 18px; font-style: italic; color: var(--maroon-deep); }
.ev-wish .from b { display: block; margin-top: 4px; font-family: var(--caps); font-style: normal; font-weight: 700; font-size: 15px; letter-spacing: .2em; text-transform: uppercase; color: var(--maroon); }

/* interactive scenes (haldi / sangeet / varmala pages) live in iframes so their taps, ids and scripts stay isolated */
.ev .play {
  position: relative; margin: 16px -6px 0;
  border-radius: 14px; overflow: hidden;
  border: 1px solid rgba(168, 122, 36, .45);
  box-shadow: 0 10px 24px rgba(79, 12, 22, .16);
  background: var(--paper-2);
}
.ev .play iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; }

/* ───────── watch live (shared page only) ───────── */
#live .lead { margin-bottom: 26px; }
.live-events { display: grid; gap: 18px; }
.live-ev .ist { margin: 8px 0 0; font-size: 16px; color: var(--maroon-deep); opacity: .8; position: relative; }
.live-ev .cal { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin: 16px 0 0; position: relative; }
.live-ev .cal a, .live-url .copy-link {
  padding: 7px 14px; border-radius: 999px; border: 1px solid rgba(168, 122, 36, .45); background: rgba(255, 255, 255, .7);
  font-family: var(--caps); font-size: 10px; letter-spacing: .16em; text-transform: uppercase; color: var(--maroon); text-decoration: none; cursor: pointer;
}
.live-url { margin: 22px 0 0; font-size: 16px; color: var(--maroon-deep); overflow-wrap: anywhere; }
.live-url .copy-link { margin-left: 6px; }
.live-note { margin: 10px 0 0; font-size: 16px; font-style: italic; color: var(--maroon-deep); }

/* ───────── countdown ───────── */
.count { display: grid; grid-template-columns: repeat(4, 1fr); gap: clamp(8px, 3vw, 16px); margin-top: 6px; }
.unit {
  padding: 18px 4px 14px;
  border-radius: 14px;
  background: linear-gradient(160deg, var(--maroon), var(--maroon-deep));
  color: #fff4dd;
  box-shadow: inset 0 0 0 1px rgba(217, 180, 106, .55), inset 0 0 0 5px var(--maroon-deep), inset 0 0 0 6px rgba(217, 180, 106, .35), 0 12px 24px rgba(79, 12, 22, .2);
}
#countdown .kicker.after-count { margin: 22px 0 0; }   /* sits under the timer */
.unit b { display: block; font-family: var(--caps); font-weight: 500; font-size: clamp(26px, 8vw, 42px); line-height: 1; font-variant-numeric: tabular-nums; }
.unit span { display: block; margin-top: 8px; font-family: var(--caps); font-size: clamp(9px, 2.4vw, 11px); letter-spacing: .2em; text-transform: uppercase; color: var(--gold-soft); }

/* ───────── venue ───────── */
.venue-name { margin: 26px 0 2px; font-family: var(--caps); font-weight: 500; font-size: clamp(20px, 5.4vw, 26px); letter-spacing: .14em; color: var(--maroon); }
.venue-addr { margin: 0; font-size: 18px; color: var(--maroon-deep); }
.map { margin: 26px auto 0; max-width: 520px; border-radius: 18px; overflow: hidden; border: 1px solid rgba(168, 122, 36, .45); box-shadow: 0 12px 30px rgba(122, 20, 36, .1); }
.map iframe { display: block; width: 100%; height: 300px; border: 0; }
.btn {
  display: inline-block; margin-top: 22px; padding: 12px 26px;
  border-radius: 999px;
  background: linear-gradient(90deg, #b88a36, #e0bb6e, #b88a36);
  color: var(--maroon-deep);
  font-family: var(--caps); font-size: 12px; letter-spacing: .22em; text-transform: uppercase; text-decoration: none;
  box-shadow: 0 8px 20px rgba(168, 122, 36, .3);
}
.btn:hover { filter: brightness(1.05); }

/* ───────── sign-off ───────── */
.end { padding-bottom: 60px; }
.end .title { font-size: min(11vw, 50px); white-space: nowrap; }
.end .sign { margin: 34px 0 0; font-size: 20px; color: var(--maroon-deep); }
.end .monogram { display: block; position: relative; width: min(260px, 66%); height: auto; margin: 26px auto 0; }
/* dress-code note just above the monogram */
.end .attire { margin: 26px auto 0; max-width: 24em; font-size: 18px; line-height: 1.55; font-style: italic; color: var(--maroon-deep); }
/* Instagram link between the sign-off and the monogram */
.end .insta { margin: 22px 0 0; font-size: 17px; line-height: 1.5; color: var(--maroon-deep); }
.end .insta a {
  display: inline-flex; align-items: center; gap: 7px; margin-top: 6px;
  padding: 7px 16px; border-radius: 999px; border: 1px solid rgba(168, 122, 36, .45);
  font-size: 17px; letter-spacing: .02em; color: var(--maroon); text-decoration: none;   /* body serif: shows the handle exactly as on Instagram */
  background: rgba(255, 255, 255, .6);
}
.end .insta svg { width: 17px; height: 17px; fill: none; stroke: var(--gold); stroke-width: 1.8; }
.end .insta svg .dot { fill: var(--gold); stroke: none; }
.end .sign i { display: block; margin-top: 4px; font-style: normal; font-family: var(--script); font-size: 34px; color: var(--maroon); }

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

#date { padding-bottom: 24px; }
#welcome { overflow: visible; }   /* the arch's faded top reaches up into the gap above; don't clip it */
