/* ==========================================================================
   Design tokens — see CLAUDE.md "Design system"
   ========================================================================== */
:root {
  /* pink-v2: nudged toward the photos — rose a touch deeper/dustier (wine gown),
     greens toward the olive of the bamboo set. pink-v1 is in docs/palette-history.md */
  --c-rose: #9c3558;
  --c-rose-dark: #571a30;
  --c-sage: #bcbf9c;
  --c-sage-dark: #858c62;
  --c-forest: #34402a;
  --c-cream: #f4e7e2;
  --c-ivory: #fff9f6;
  --c-gold: #ddbf7e;
  --c-gold-deep: #a8823f;     /* gold for text and fine lines on light grounds */
  --c-blush: #e6b0bd;
  --c-ink: #212121;
  --c-white: #ffffff;

  --f-serif: "Cormorant Garamond", Georgia, serif;
  --f-script: "Pinyon Script", cursive;
  --f-sans: "Lato", system-ui, sans-serif;

  --col-width: 430px;      /* invitation column width on desktop */
  --radius: 18px;
  --radius-pill: 999px;
  --shadow: 0 10px 30px rgba(33, 33, 33, 0.15);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --intro-offset: 0.5s;    /* hero intro waits for the cover to slide away */

  /* Fine paper grain (tiled SVG noise) */
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.9' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 .35 0 0 0 0 .2 0 0 0 0 .22 0 0 0 .09 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
}

/* ==========================================================================
   Base
   ========================================================================== */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--f-serif);
  font-size: 17px;
  font-weight: 500;
  line-height: 1.55;
  color: var(--c-ink);
  background: var(--c-cream);
  overflow-x: hidden;
}
body.is-locked { overflow: hidden; height: 100vh; }
img { max-width: 100%; display: block; }
button, input, select, textarea { font: inherit; color: inherit; }
a { color: inherit; }
h1, h2, h3, p { margin: 0; }
[hidden] { display: none !important; }

.script { font-family: var(--f-script); font-weight: 400; line-height: 1.2; }
.eyebrow {
  font-family: var(--f-sans);
  font-size: 11px;
  letter-spacing: 0.32em;
  text-transform: uppercase;
}
.title { font-size: 44px; font-weight: 400; text-align: center; margin-bottom: 14px; }
.title:not(.script) {
  font-family: var(--f-serif);
  font-size: 24px;
  font-weight: 500;
  letter-spacing: 0.22em;
  text-transform: uppercase;
}
.title::after {                         /* gold rule with diamond */
  content: "";
  display: block;
  width: 150px;
  height: 12px;
  margin: 10px auto 0;
  background: url("../assets/img/divider.svg") center / contain no-repeat;
}
.section--rose .title::after { filter: brightness(1.45); }
.lead { text-align: center; max-width: 32ch; margin: 0 auto 22px; font-size: 17px; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 11px 26px;
  border: 0;
  border-radius: var(--radius-pill);
  background: var(--c-rose);
  color: var(--c-white);
  font-family: var(--f-sans);
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s;
}
.btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); }
.btn:active { transform: translateY(0); }
.btn svg { width: 18px; height: 18px; }
.btn--light { background: var(--c-ivory); color: var(--c-rose); }
.btn--small { padding: 7px 18px; font-size: 11px; }
.btn[disabled] { opacity: 0.6; cursor: wait; }

/* Ornaments (original SVG artwork in assets/img) */
.ornament { position: absolute; pointer-events: none; user-select: none; }
.ornament--divider { position: static; width: 200px; margin: 0 auto 18px; }
.sway { animation: sway 9s ease-in-out infinite; transform-origin: bottom left; }
.sway--rev { animation-direction: reverse; }
@keyframes sway {
  0%, 100% { transform: rotate(-1.2deg); }
  50% { transform: rotate(1.2deg); }
}

/* ==========================================================================
   Layout: mobile = single column; desktop = fixed photo panel + column
   ========================================================================== */
.main {
  position: relative;
  width: 100%;
  max-width: var(--col-width);
  margin: 0 auto;
  background: var(--c-ivory);
  overflow: hidden;
}
.aside { display: none; }

@media (min-width: 900px) {
  .aside {
    display: block;
    position: fixed;
    inset: 0 var(--col-width) 0 0;
  }
  .aside__bg { position: absolute; inset: 0; background: center/cover no-repeat; }
  .aside__bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, rgba(94, 21, 51, 0.1), rgba(94, 21, 51, 0.75));
  }
  .aside__inner {
    position: absolute;
    left: 56px;
    bottom: 56px;
    color: var(--c-ivory);
  }
  .aside__names { font-size: 64px; margin: 8px 0; }
  .aside__date { font-size: 20px; letter-spacing: 0.3em; }
  .main { margin: 0 0 0 auto; box-shadow: -10px 0 40px rgba(0, 0, 0, 0.25); }
}

.section {
  position: relative;
  padding: 72px 24px;
  text-align: center;
}
.section--rose { background: var(--grain), var(--c-rose); color: var(--c-ivory); }
.section--sage { background: var(--grain), var(--c-sage); color: var(--c-ink); }
.section > * { position: relative; }
.section__photo {
  position: absolute !important;
  inset: 0;
  background: center 30% / cover no-repeat;
  opacity: 0.22;
  filter: grayscale(0.3);
  mix-blend-mode: luminosity;
}
.section--rose .btn:not(.btn--light) { background: var(--c-ivory); color: var(--c-rose); }

/* ==========================================================================
   Preloader
   ========================================================================== */
.loader {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  place-content: center;
  gap: 6px;
  text-align: center;
  background: var(--c-rose);
  color: var(--c-ivory);
  transition: opacity 0.6s, visibility 0.6s;
}
.loader.is-done { opacity: 0; visibility: hidden; }
.loader__eyebrow { font-family: var(--f-sans); letter-spacing: 0.3em; font-size: 12px; text-transform: uppercase; }
.loader__names { font-family: var(--f-script); font-size: 46px; }
.loader__pct { font-size: 14px; opacity: 0.8; }

/* ==========================================================================
   Cover
   ========================================================================== */
.cover {
  position: fixed;
  inset: 0;
  z-index: 50;
  display: grid;
  place-items: center;
  color: var(--c-ivory);
  text-align: center;
  transition: transform 1.1s var(--ease), opacity 1.1s;
}
.cover.is-open { transform: translateY(-100%); opacity: 0; pointer-events: none; }
.cover__bg {
  position: absolute;
  inset: 0;
  background: var(--photo-cover, none) center 30% / cover no-repeat var(--c-rose-dark);
  animation: ken-burns 24s ease-out both;
}
.cover__bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(48, 10, 26, 0.15) 0%, rgba(48, 10, 26, 0.35) 40%, rgba(48, 10, 26, 0.88) 100%);
}
@keyframes ken-burns { from { transform: scale(1.12); } }
.cover__inner {
  position: relative;
  align-self: end;
  width: min(84vw, 340px);
  margin-bottom: max(6svh, 28px);
  padding: 64px 26px 34px;
  display: grid;
  justify-items: center;
  gap: 12px;
}
.cover__inner::before, .cover__inner::after {   /* double gold arch */
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(233, 211, 160, 0.75);
  border-bottom: 0;
  border-radius: 170px 170px 0 0;
  pointer-events: none;
}
.cover__inner::after { inset: 7px 7px 0; border-color: rgba(233, 211, 160, 0.4); border-radius: 163px 163px 0 0; }
.ornament--cover-top { position: static; width: 190px; margin-bottom: 4px; }
.cover__names { font-size: 54px; font-weight: 400; color: #fff; }
.cover__guest { margin: 6px 0 6px; font-size: 16px; }
.cover__guest-name { font-size: 24px; font-weight: 600; }
.cover .btn--light { background: rgba(255, 249, 246, 0.95); }
@media (min-width: 900px) {
  .cover__bg { background-image: var(--photo-cover-wide, var(--photo-cover, none)); background-position: center; }
  /* desktop: sit the arch over the empty right side of the landscape photo */
  .cover__inner { justify-self: end; align-self: center; margin: 0 9vw 0 0; }
}
.reveal-cover { opacity: 0; transform: translateY(16px); animation: rise 1s var(--ease) forwards; }
.reveal-cover:nth-child(2) { animation-delay: 0.2s; }
.reveal-cover:nth-child(3) { animation-delay: 0.4s; }
.reveal-cover:nth-child(4) { animation-delay: 0.6s; }
.reveal-cover:nth-child(5) { animation-delay: 0.8s; }
.loader:not(.is-done) ~ .cover .reveal-cover { animation-play-state: paused; }
@keyframes rise { to { opacity: 1; transform: none; } }

/* ==========================================================================
   Hero + intro — "fine stationery" scene. See CLAUDE.md "Hero intro".
   Base styles are the FINAL frame (so reduced-motion users see the finished
   art). Every intro animation sits paused on its first frame until main.js
   adds .hero.is-playing when the invitation is opened.
   ========================================================================== */
.hero {
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: 24px 0;
  overflow: hidden;
  color: var(--c-rose-dark);
  background:
    radial-gradient(120% 70% at 50% 38%, #fffaf8 0%, #f9e9ec 45%, #efd0d8 100%);
}
.hero::after {                      /* paper grain */
  content: "";
  position: absolute;
  inset: 0;
  z-index: 3;
  pointer-events: none;
  background-image: var(--grain);
  opacity: 0.5;
}

/* Arch composition: SVG art + text share one aspect-ratio box, so the text
   always sits inside the drawn arch whatever the screen size. */
.hero__stage {
  position: relative;
  z-index: 2;
  width: min(88vw, 380px, calc((100svh - 48px) * 360 / 680));
  aspect-ratio: 360 / 680;
  container-type: inline-size;
}
.hero__art, .hero__shine { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; }
.hero__shine { mix-blend-mode: soft-light; opacity: 0.9; }
.hero__inner {
  position: absolute;
  inset: 23% 18% 22%;
  display: grid;
  align-content: center;
  justify-items: center;
  text-align: center;
}
.hero__eyebrow { font-size: 3cqw; letter-spacing: 0.38em; color: var(--c-gold-deep); margin-bottom: 4cqw; }
.hero__name { font-size: 15.5cqw; line-height: 1.05; color: var(--c-rose); }
.hero__and { font-family: var(--f-serif); font-style: italic; font-size: 7cqw; color: var(--c-gold-deep); margin: -1cqw 0; }
.hero__date {
  margin-top: 6cqw;
  font-size: 4.4cqw;
  letter-spacing: 0.32em;
  color: var(--c-rose-dark);
}

/* Optional MP4 intro (config.introVideo): full-bleed, plays once, holds last frame */
.hero__video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.hero--video { color: var(--c-ivory); background: var(--c-rose-dark); }
.hero--video .hero__art, .hero--video .hero__shine { display: none; }
.hero--video .hero__name, .hero--video .hero__date { color: var(--c-ivory); }
.hero--video .hero__stage::before {
  content: "";
  position: absolute;
  inset: 10% -20%;
  background: radial-gradient(closest-side, rgba(94, 21, 51, 0.55), rgba(94, 21, 51, 0));
}

/* Ambient layers: drifting light leaks + rising gold dust (HTML, GPU-friendly) */
.intro { position: absolute; inset: 0; overflow: hidden; }
.intro__light {
  position: absolute;
  border-radius: 50%;
  filter: blur(50px);
  opacity: 0.55;
  animation: drift 18s ease-in-out infinite alternate paused;
}
.intro__light--a { width: 70%; aspect-ratio: 1; top: -12%; right: -20%; background: #f6dfae; }
.intro__light--b { width: 80%; aspect-ratio: 1; bottom: -18%; left: -28%; background: #f2b8c8; animation-delay: -6s; }
@keyframes drift {
  from { transform: translate(0, 0) scale(1); }
  to { transform: translate(-8%, 6%) scale(1.12); }
}
.intro__dust span {
  position: absolute;
  bottom: -10px;
  width: var(--s);
  height: var(--s);
  border-radius: 50%;
  background: radial-gradient(circle, #fff6dc 0%, #e2c27f 45%, rgba(226, 194, 127, 0) 70%);
  opacity: 0;
  animation: dust var(--dur) linear var(--delay) infinite paused;
}
@keyframes dust {
  0% { opacity: 0; transform: translate(0, 0); }
  15% { opacity: 0.9; }
  50% { opacity: 0.35; }
  70% { opacity: 0.85; }
  100% { opacity: 0; transform: translate(var(--drift), -95svh); }
}
.intro__petals { position: absolute; inset: 0; z-index: 2; pointer-events: none; overflow: hidden; perspective: 600px; }
.intro__petals span {
  position: absolute;
  top: -30px;
  width: var(--s);
  height: calc(var(--s) * 1.25);
  border-radius: 70% 0 70% 30% / 80% 10% 90% 20%;
  background: linear-gradient(135deg, #fdeef2 0%, #f1b3c4 55%, #d8829c 100%);
  box-shadow: inset -1px -1px 2px rgba(138, 44, 78, 0.25);
  opacity: 0;
  animation: petal var(--dur) linear var(--delay) infinite paused;
}
@keyframes petal {
  0% { opacity: 0; transform: translate3d(0, 0, 0) rotateX(0) rotateY(0) rotateZ(0); }
  8% { opacity: 0.85; }
  85% { opacity: 0.85; }
  100% { opacity: 0; transform: translate3d(var(--drift), 108svh, 0) rotateX(720deg) rotateY(360deg) rotateZ(200deg); }
}

/* Ink draws itself (stroke length set by main.js as --len), then washes bloom */
.hero__art .ink {
  stroke-dasharray: var(--len) var(--len);
  animation: draw 1.8s cubic-bezier(0.45, 0, 0.2, 1) calc(var(--d) + var(--intro-offset)) both paused;
}
.hero__art .frame { animation-duration: 2.4s; }
.hero__art .wash {
  transform-box: fill-box;
  transform-origin: center;
  animation: bloom 1.6s cubic-bezier(0.22, 1, 0.36, 1) calc(var(--d) + var(--intro-offset)) both paused;
}
.hero__art .panel { animation-name: panel; animation-duration: 2s; }
.hero__shine { animation: fade-in 1.5s ease calc(3.2s + var(--intro-offset)) both paused; }
@keyframes draw { from { stroke-dashoffset: var(--len); } to { stroke-dashoffset: 0; } }
@keyframes bloom { from { opacity: 0; transform: scale(0.82); } }
@keyframes panel { from { opacity: 0; } }
@keyframes fade-in { from { opacity: 0; } }

/* Text arrives once the arch is drawn */
.hero__inner > * { animation: ink-rise 1.6s cubic-bezier(0.22, 1, 0.36, 1) both paused; }
.hero__eyebrow { animation-name: track-in; animation-delay: calc(1.9s + var(--intro-offset)); }
.hero__name:nth-of-type(1) { animation-delay: calc(2.3s + var(--intro-offset)); }
.hero__and { animation-delay: calc(2.7s + var(--intro-offset)); }
.hero__name:nth-of-type(2) { animation-delay: calc(3s + var(--intro-offset)); }
.hero__date { animation-delay: calc(3.4s + var(--intro-offset)); }
@keyframes ink-rise { from { opacity: 0; transform: translateY(10px); filter: blur(8px); } }
@keyframes track-in { from { opacity: 0; letter-spacing: 0.9em; filter: blur(4px); } }

.hero.is-playing .ink,
.hero.is-playing .wash,
.hero.is-playing .hero__shine,
.hero.is-playing .hero__inner > *,
.hero.is-playing .intro__light,
.hero.is-playing .intro__dust span,
.hero.is-playing .intro__petals span { animation-play-state: running; }

/* ==========================================================================
   Monogram
   ========================================================================== */
.monogram__letters {
  width: 120px;
  height: 120px;
  margin: 0 auto 12px;
  display: grid;
  place-items: center;
  border: 1px solid var(--c-gold);
  border-radius: 50%;
  box-shadow: 0 0 0 5px transparent, 0 0 0 6px rgba(221, 191, 126, 0.45);
  font-family: var(--f-serif);
  font-size: 38px;
  font-weight: 500;
  letter-spacing: 0.12em;
  color: var(--c-gold);
}
.monogram__love { font-size: 40px; margin-bottom: 24px; }
.quote { margin: 0 auto; max-width: 30ch; font-style: italic; font-size: 20px; line-height: 1.5; }
.quote cite { display: block; margin-top: 8px; font-style: normal; font-size: 13px; letter-spacing: 0.15em; }
.quote cite:empty { display: none; }

/* ==========================================================================
   Couple
   ========================================================================== */
.person { display: grid; justify-items: center; gap: 4px; }
.frame { position: relative; width: 220px; margin-bottom: 16px; }
.frame__photo {
  width: 220px;
  height: 300px;
  object-fit: cover;
  border-radius: 110px 110px 12px 12px;  /* arch frame */
  border: 6px solid var(--c-white);
  box-shadow: 0 0 0 5px var(--c-ivory), 0 0 0 6px var(--c-gold), var(--shadow);
  background: var(--c-cream);
}
.frame__flower { width: 110px; left: -40px; bottom: -24px; }
.person:nth-of-type(2) .frame__flower { left: auto; right: -40px; transform: scaleX(-1); }
.person__nick { font-size: 54px; color: var(--c-rose); }
.person__name { font-size: 20px; font-weight: 600; letter-spacing: 0.02em; }
.person__order { font-size: 11px; font-family: var(--f-sans); letter-spacing: 0.2em; text-transform: uppercase; margin-top: 8px; color: var(--c-gold-deep); }
.person__parents { font-size: 17px; font-style: italic; margin-bottom: 12px; }
.couple__amp { font-family: var(--f-serif); font-style: italic; font-size: 56px; color: var(--c-gold-deep); margin: 30px 0; }

/* ==========================================================================
   Save the date
   ========================================================================== */
.countdown { display: flex; justify-content: center; gap: 10px; margin: 8px 0 22px; }
.countdown div {
  width: 70px;
  padding: 12px 0 10px;
  border-radius: 36px 36px 8px 8px;
  background: rgba(255, 249, 246, 0.7);
  border: 1px solid rgba(168, 130, 63, 0.55);
  color: var(--c-rose-dark);
  display: grid;
}
.countdown span { font-size: 30px; font-weight: 500; line-height: 1.1; }
.countdown small { font-family: var(--f-sans); font-size: 9px; letter-spacing: 0.2em; text-transform: uppercase; color: var(--c-gold-deep); }
.events { display: grid; gap: 22px; margin-top: 32px; }
.event-card {
  position: relative;
  padding: 52px 26px 34px;
  background: var(--grain), var(--c-ivory);
  border-radius: 160px 160px var(--radius) var(--radius);   /* arch card */
  box-shadow: var(--shadow);
}
.event-card::before {
  content: "";
  position: absolute;
  inset: 9px;
  border: 1px solid rgba(168, 130, 63, 0.5);
  border-radius: 151px 151px 12px 12px;
  pointer-events: none;
}
.event-card h3 { font-family: var(--f-script); font-weight: 400; font-size: 44px; color: var(--c-rose); margin-bottom: 10px; }
.event-card__date { font-weight: 600; letter-spacing: 0.14em; text-transform: uppercase; font-size: 15px; }
.event-card__time { margin-bottom: 12px; }
.event-card__venue { font-weight: 700; }
.event-card__addr { font-size: 14px; margin-bottom: 16px; }

/* ==========================================================================
   Dresscode
   ========================================================================== */
.dresscode__icon { width: 120px; margin: 0 auto 16px; color: var(--c-rose); }
.swatches { display: flex; justify-content: center; gap: 12px; }
.swatches span {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 3px solid var(--c-white);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
}

/* ==========================================================================
   Video
   ========================================================================== */
.video__frame { aspect-ratio: 16 / 9; border-radius: 12px; overflow: hidden; background: #000; }
.video__frame iframe { width: 100%; height: 100%; border: 0; }

/* ==========================================================================
   Gallery
   ========================================================================== */
.masonry { columns: 2; column-gap: 10px; margin: 8px -8px 0; }
.masonry__item {
  display: block;
  width: 100%;
  margin: 0 0 10px;
  padding: 0;
  border: 0;
  background: var(--c-cream);
  border-radius: 6px;
  overflow: hidden;
  break-inside: avoid;
  cursor: zoom-in;
}
.masonry__item img { width: 100%; height: auto; transition: transform 1.2s var(--ease); }
.masonry__item:hover img { transform: scale(1.04); }
.masonry__item:nth-child(4n + 1) { border-radius: 90px 90px 6px 6px; }   /* occasional arch */

/* ==========================================================================
   Gift modal content
   ========================================================================== */
.bank-cards { display: grid; gap: 16px; margin-bottom: 20px; }
.bank-card {
  position: relative;
  padding: 18px 20px;
  aspect-ratio: 1.586;          /* ID-1 card ratio */
  border-radius: 14px;
  background: linear-gradient(135deg, var(--c-rose) 0%, var(--c-rose-dark) 100%);
  color: var(--c-ivory);
  text-align: left;
  display: grid;
  grid-template-rows: auto 1fr auto auto auto;
  box-shadow: var(--shadow);
}
.bank-card__bank { justify-self: end; font-weight: 700; font-size: 20px; letter-spacing: 0.08em; }
.bank-card__chip {
  width: 44px;
  height: 32px;
  border-radius: 6px;
  align-self: center;
  background: linear-gradient(135deg, #f3dca0, var(--c-gold) 50%, #b8964f);
}
.bank-card__number { font-size: 20px; letter-spacing: 0.12em; }
.bank-card__holder { font-family: var(--f-sans); font-size: 13px; margin-bottom: 8px; }
.bank-card .btn { justify-self: start; }
.ship-card {
  padding: 22px;
  border-radius: var(--radius);
  background: var(--c-cream);
  display: grid;
  gap: 6px;
  justify-items: center;
  margin-bottom: 28px;
}
.ship-card h3 { font-family: var(--f-script); font-weight: 400; font-size: 36px; color: var(--c-rose); }
.ship-card__name { font-weight: 700; }

/* ==========================================================================
   Forms
   ========================================================================== */
.form { display: grid; gap: 14px; text-align: left; max-width: 360px; margin: 0 auto; }
.form label { display: grid; gap: 4px; font-family: var(--f-sans); font-size: 13px; }
.form input:not([type="radio"]), .form select, .form textarea {
  width: 100%;
  padding: 11px 14px;
  border: 1px solid rgba(255, 249, 246, 0.5);
  border-radius: 10px;
  background: rgba(255, 249, 246, 0.12);
  color: inherit;
}
.form select option { color: var(--c-ink); }
.form textarea { resize: vertical; }
.form input:focus, .form select:focus, .form textarea:focus { outline: 2px solid var(--c-gold); outline-offset: 1px; }
.form__choice { border: 0; padding: 0; margin: 0; display: grid; gap: 6px; font-family: var(--f-sans); font-size: 13px; }
.form__choice legend { margin-bottom: 4px; }
.form__choice label { display: flex; align-items: center; gap: 8px; font-size: 14px; }
.form .btn { justify-self: center; margin-top: 6px; }
.form__status { text-align: center; font-family: var(--f-sans); font-size: 13px; min-height: 1em; }
.form--light input:not([type="radio"]), .form--light select, .form--light textarea {
  border-color: rgba(33, 33, 33, 0.2);
  background: var(--c-white);
}

/* ==========================================================================
   Love story timeline
   ========================================================================== */
.timeline { position: relative; display: grid; gap: 34px; margin-top: 24px; }
.timeline::before {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  border-left: 1px dashed var(--c-sage-dark);
}
.story-card {
  position: relative;
  padding: 18px;
  background: var(--c-white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.story-card img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; border-radius: 12px; margin-bottom: 12px; }
.story-card h3 { font-family: var(--f-script); font-weight: 400; font-size: 36px; color: var(--c-rose); margin-bottom: 6px; }
.story-card p { font-size: 14px; }

/* ==========================================================================
   QR
   ========================================================================== */
.qr-card {
  margin: 0 auto 20px;
  max-width: 300px;
  padding: 24px 20px;
  border-radius: var(--radius);
  background: var(--c-rose);
  color: var(--c-ivory);
  display: grid;
  gap: 2px;
}
.qr-card__names { font-size: 32px; margin: 4px 0; }
.qr-card__dear { margin-top: 12px; font-size: 13px; }
.qr-card__guest { font-weight: 700; font-size: 18px; margin-bottom: 14px; }
.qr-card__code { justify-self: center; padding: 10px; background: var(--c-white); border-radius: 10px; }
.qr-card__code img, .qr-card__code canvas { width: 180px; height: 180px; }

/* ==========================================================================
   Wishes
   ========================================================================== */
.wishes__count { margin: 28px 0 12px; font-family: var(--f-sans); font-size: 13px; }
.wishes__list {
  list-style: none;
  margin: 0;
  padding: 0 4px 0 0;
  max-height: 420px;
  overflow-y: auto;
  display: grid;
  gap: 12px;
  text-align: left;
}
.wish {
  padding: 14px 16px;
  border-radius: 14px;
  background: var(--c-ivory);
  color: var(--c-ink);
}
.wish__head { display: flex; justify-content: space-between; gap: 8px; align-items: baseline; }
.wish__name { font-weight: 700; }
.wish__badge {
  font-family: var(--f-sans);
  font-size: 10px;
  padding: 2px 8px;
  border-radius: var(--radius-pill);
  background: var(--c-sage);
  white-space: nowrap;
}
.wish__badge--no { background: var(--c-blush); }
.wish__badge--maybe { background: var(--c-cream); }
.wish__msg { margin: 6px 0 4px; font-size: 14px; white-space: pre-wrap; overflow-wrap: anywhere; }
.wish__time { font-family: var(--f-sans); font-size: 11px; opacity: 0.6; }

/* ==========================================================================
   Closing + footer
   ========================================================================== */
.closing { padding-bottom: 120px; }
.closing__photo {
  width: 240px;
  height: 320px;
  margin: 0 auto 24px;
  border-radius: 120px 120px 12px 12px;
  background: center 25% / cover no-repeat var(--c-sage);
  border: 6px solid var(--c-white);
  box-shadow: 0 0 0 5px var(--c-ivory), 0 0 0 6px var(--c-gold), var(--shadow);
}
.closing__names { font-size: 56px; color: var(--c-rose); margin-top: 8px; }
.ornament--closing { width: 150px; left: 50%; bottom: -10px; margin-left: -75px; }
.footer {
  padding: 18px;
  text-align: center;
  font-family: var(--f-sans);
  font-size: 12px;
  background: var(--c-rose-dark);
  color: var(--c-cream);
}

/* ==========================================================================
   Floating music, modals, lightbox, toast
   ========================================================================== */
.music {
  position: fixed;
  right: 16px;
  bottom: 20px;
  z-index: 40;
  width: 46px;
  height: 46px;
  border: 0;
  border-radius: 50%;
  background: var(--c-rose);
  color: var(--c-ivory);
  display: grid;
  place-items: center;
  box-shadow: var(--shadow);
  cursor: pointer;
  animation: spin 4s linear infinite;
}
.music svg { width: 22px; height: 22px; }
.music.is-paused { animation-play-state: paused; opacity: 0.75; }
@keyframes spin { to { transform: rotate(360deg); } }

.modal, .lightbox {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 16px;
  background: rgba(40, 10, 22, 0.7);
  animation: fade 0.3s;
}
.modal__panel {
  position: relative;
  width: 100%;
  max-width: 400px;
  max-height: calc(100svh - 32px);
  overflow-y: auto;
  padding: 44px 22px 28px;
  border-radius: var(--radius);
  background: var(--c-ivory);
  text-align: center;
  animation: rise-in 0.4s var(--ease);
}
.modal__sub { font-family: var(--f-script); font-weight: 400; font-size: 36px; color: var(--c-rose); }
.modal__close {
  position: absolute;
  top: 8px;
  right: 10px;
  width: 36px;
  height: 36px;
  border: 0;
  background: none;
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
}
.lightbox { background: rgba(30, 8, 18, 0.92); }
.lightbox .modal__close { color: var(--c-white); z-index: 1; }
.lightbox img {
  max-height: 84svh;
  border-radius: 4px;
  opacity: 0;
  transform: scale(0.98);
  transition: opacity 0.5s var(--ease), transform 0.6s var(--ease);
}
.lightbox img.is-in { opacity: 1; transform: none; }
.lightbox__nav {
  position: absolute;
  top: 50%;
  width: 44px;
  height: 44px;
  margin-top: -22px;
  border: 1px solid rgba(255, 255, 255, 0.35);
  border-radius: 50%;
  background: rgba(30, 8, 18, 0.35);
  color: #fff;
  cursor: pointer;
}
.lightbox__nav svg { width: 20px; height: 20px; }
.lightbox__nav--prev { left: 12px; }
.lightbox__nav--next { right: 12px; }
.lightbox__count {
  position: absolute;
  bottom: 18px;
  left: 0;
  right: 0;
  text-align: center;
  font-family: var(--f-sans);
  font-size: 11px;
  letter-spacing: 0.3em;
  color: rgba(255, 255, 255, 0.7);
}
@keyframes fade { from { opacity: 0; } }
@keyframes rise-in { from { opacity: 0; transform: translateY(24px); } }

.toast {
  position: fixed;
  left: 50%;
  bottom: 80px;
  z-index: 70;
  padding: 10px 18px;
  border-radius: var(--radius-pill);
  background: var(--c-ink);
  color: var(--c-white);
  font-family: var(--f-sans);
  font-size: 13px;
  opacity: 0;
  transform: translate(-50%, 10px);
  transition: opacity 0.3s, transform 0.3s;
  pointer-events: none;
}
.toast.is-shown { opacity: 1; transform: translate(-50%, 0); }

/* ==========================================================================
   Scroll-reveal animations (driven by IntersectionObserver in main.js)
   ========================================================================== */
[data-anim] {
  opacity: 0;
  filter: blur(6px);
  transition: opacity 1.4s var(--ease), transform 1.4s var(--ease), filter 1.2s var(--ease);
}
[data-anim="fade-up"] { transform: translateY(22px); }
[data-anim="fade-down"] { transform: translateY(-22px); }
[data-anim="fade-left"] { transform: translateX(26px); }
[data-anim="fade-right"] { transform: translateX(-26px); }
[data-anim="zoom"] { transform: scale(0.94); }
[data-anim].is-visible { opacity: 1; transform: none; filter: none; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  [data-anim], .reveal-cover { opacity: 1; transform: none; filter: none; }
  .hero__shine { display: none; }
  html { scroll-behavior: auto; }
}
