/* ==========================================================================
   South Indian Hindu Wedding Invitation — stylesheet
   Vanilla CSS. No frameworks.
   Palette is driven by CSS custom properties that are re-bound at runtime
   from `weddingConfig.theme.colors` (see js/main.js → applyTheme).
   ========================================================================== */

/* ------------------------------------------------------------------ tokens */
:root {
  /* Primary palette (defaults — overridden from config) */
  --stormy-teal: #006466;
  --dark-teal: #065a60;
  --deep-teal: #0b525b;
  --deep-blue-teal: #144552;
  --charcoal-blue: #1b3a4b;
  --deep-space-blue: #212f45;
  --space-indigo: #272640;
  --midnight-violet: #312244;
  --midnight-plum: #3e1f47;
  --deep-purple: #4d194d;

  /* Supporting neutrals */
  --ivory: #fdf9f2;
  --cream: #f6ecdd;
  --cream-deep: #eadbc4;
  --gold: #c9a227;
  --gold-soft: #e6c979;
  /* Deep antique gold. Used for text and icons that sit on light surfaces —
     --gold / --gold-soft are too light to meet WCAG AA there. */
  --gold-ink: #7a5a10;
  --gold-dim: rgba(201, 162, 39, 0.34);
  --ink: #22303a;
  --ink-soft: #56636d;

  /* Semantic surfaces */
  --surface: var(--ivory);
  --surface-alt: var(--cream);
  --text-on-dark: #f4efe6;
  --text-on-dark-soft: rgba(244, 239, 230, 0.78);
  --text-on-light: var(--ink);
  --text-on-light-soft: var(--ink-soft);

  --line-gold: rgba(201, 162, 39, 0.42);
  --line-soft: rgba(34, 48, 58, 0.1);

  /* Type */
  --font-display: "Cormorant Garamond", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --font-script: "Great Vibes", "Snell Roundhand", "Brush Script MT", cursive;
  --font-body: "Jost", "Segoe UI", system-ui, -apple-system, "Helvetica Neue", Arial, sans-serif;

  /* Space */
  --sp-1: 0.35rem;
  --sp-2: 0.75rem;
  --sp-3: 1.1rem;
  --sp-4: 1.6rem;
  --sp-5: 2.4rem;
  --sp-6: 3.4rem;
  --sp-7: 5rem;
  --sp-8: 7rem;

  --shell: 1180px;
  --shell-narrow: 860px;

  /* Shape */
  --r-sm: 6px;
  --r-md: 14px;
  --r-lg: 24px;
  --r-pill: 999px;

  /* Elevation */
  --sh-soft: 0 12px 34px rgba(20, 26, 42, 0.1);
  --sh-card: 0 22px 60px rgba(17, 20, 40, 0.16);
  --sh-gold: 0 18px 44px rgba(201, 162, 39, 0.24);

  /* Motion */
  --ease-out: cubic-bezier(0.22, 1, 0.36, 1);
  --ease-in-out: cubic-bezier(0.65, 0.05, 0.36, 1);
  --ease-curtain: cubic-bezier(0.76, 0, 0.24, 1);
  --dur-fast: 0.28s;
  --dur: 0.55s;
  --dur-slow: 0.95s;

  --entrance-image: url("../assets/images/entrance-curtain.jpg");
  --hero-image: url("../assets/images/wedding-hero.jpg");
  --scratch-image: url("../assets/images/scratch-background.jpg");
}

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: 88px;
}

body {
  margin: 0;
  background: var(--surface);
  color: var(--text-on-light);
  font-family: var(--font-body);
  font-size: 16px;
  font-weight: 300;
  line-height: 1.72;
  letter-spacing: 0.012em;
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

body.is-locked { overflow: hidden; }

img { max-width: 100%; height: auto; display: block; }
svg { display: block; }
button { font: inherit; color: inherit; }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 400;
  line-height: 1.18;
  margin: 0 0 0.5em;
  letter-spacing: 0.01em;
}

p { margin: 0 0 1em; }
ul, ol { margin: 0; padding: 0; list-style: none; }

a { color: inherit; text-decoration: none; }

:focus-visible {
  outline: 2px solid var(--gold-soft);
  outline-offset: 3px;
  border-radius: 3px;
}

::selection { background: var(--deep-teal); color: var(--ivory); }

/* --------------------------------------------------------------- utilities */
.svg-sprite { position: absolute; width: 0; height: 0; overflow: hidden; }

.visually-hidden {
  position: absolute !important;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: -100px; left: 12px;
  z-index: 400;
  padding: 0.7rem 1.1rem;
  background: var(--ivory);
  color: var(--deep-blue-teal);
  border-radius: 0 0 var(--r-sm) var(--r-sm);
  font-size: 0.85rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  transition: top var(--dur-fast) var(--ease-out);
}
.skip-link:focus { top: 0; }

.shell {
  width: min(100% - 2.4rem, var(--shell));
  margin-inline: auto;
}
.shell--narrow { width: min(100% - 2.4rem, var(--shell-narrow)); }

.ico { width: 1.15em; height: 1.15em; flex: none; }

/* A <picture> wrapper must not create a box of its own, otherwise it would
   break the layout of the images it wraps. */
picture.is-responsive { display: contents; }

/* Ornamental divider */
.ornament {
  display: block;
  width: min(220px, 60%);
  margin: var(--sp-4) auto 0;
  color: var(--gold);
}
.ornament svg { width: 100%; height: auto; }
.ornament--light { color: var(--gold-soft); }

/* ---------------------------------------------------------------- buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.55em;
  min-height: 52px;
  padding: 0.85rem 1.9rem;
  border: 1px solid transparent;
  border-radius: var(--r-pill);
  font-family: var(--font-body);
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  cursor: pointer;
  transition: transform var(--dur-fast) var(--ease-out),
              box-shadow var(--dur-fast) var(--ease-out),
              background-color var(--dur-fast) var(--ease-out),
              color var(--dur-fast) var(--ease-out),
              border-color var(--dur-fast) var(--ease-out);
}
.btn:hover { transform: translateY(-2px); }
.btn:active { transform: translateY(0); }
.btn[disabled] { opacity: 0.55; cursor: not-allowed; transform: none; }

.btn--gold {
  background: linear-gradient(135deg, var(--gold-soft), var(--gold) 55%, #a9831c);
  color: #2a2208;
  box-shadow: var(--sh-gold);
}
.btn--gold:hover { box-shadow: 0 22px 52px rgba(201, 162, 39, 0.36); }

.btn--ghost {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-on-dark);
  border-color: var(--line-gold);
  backdrop-filter: blur(4px);
}
.btn--ghost:hover {
  background: rgba(230, 201, 121, 0.14);
  border-color: var(--gold-soft);
}

.btn--light {
  background: transparent;
  color: var(--ivory);
  border-color: rgba(230, 201, 121, 0.55);
}
.btn--light:hover { background: rgba(230, 201, 121, 0.12); }

.btn--sm { min-height: 44px; padding: 0.6rem 1.4rem; font-size: 0.72rem; }
.btn--sm .ico { width: 1.35em; height: 1.35em; }

.link-btn {
  background: none;
  border: 0;
  padding: 0.3rem 0;
  color: var(--deep-teal);
  font-family: var(--font-body);
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  cursor: pointer;
  border-bottom: 1px solid var(--line-gold);
  transition: color var(--dur-fast) var(--ease-out), border-color var(--dur-fast) var(--ease-out);
}
.link-btn:hover { color: var(--midnight-plum); border-color: var(--midnight-plum); }

/* --------------------------------------------------------------- headings */
.section {
  position: relative;
  padding: var(--sp-7) 0;
}
.section__head {
  text-align: center;
  max-width: 44rem;
  margin: 0 auto var(--sp-6);
}
.section__kicker {
  margin: 0 0 0.6rem;
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: var(--gold-ink);
}
.section__title {
  font-size: clamp(2rem, 5.2vw, 3.4rem);
  color: var(--deep-blue-teal);
  margin-bottom: 0.4rem;
}
.section__lead {
  margin: 0 auto;
  max-width: 36rem;
  color: var(--text-on-light-soft);
  font-size: 1.02rem;
}
.section__head--light .section__title { color: var(--ivory); }
.section__head--light .section__lead { color: var(--text-on-dark-soft); }
.section__head--light .section__kicker { color: var(--gold-soft); }

/* -------------------------------------------------------- scroll reveals */
.js [data-reveal] {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity var(--dur-slow) var(--ease-out) var(--reveal-delay, 0ms),
              transform var(--dur-slow) var(--ease-out) var(--reveal-delay, 0ms);
  will-change: opacity, transform;
}
.js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

/* ==========================================================================
   ENTRANCE CURTAIN
   ========================================================================== */
.entrance {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  background: #120e18;
  overflow: hidden;
}
.entrance[hidden] { display: none; }

/* Soft centre vignette — keeps the gold lettering legible over the silk. */
.entrance::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(64% 48% at 50% 46%, rgba(10, 8, 18, 0.6), rgba(10, 8, 18, 0.32) 58%, transparent 76%),
    radial-gradient(130% 34% at 50% 100%, rgba(10, 8, 18, 0.55), transparent 72%);
}

.entrance__stage {
  position: absolute;
  inset: 0;
  perspective: 1400px;
  /* The stage fills the viewport, so it — not the curtain — centres the bow. */
  display: grid;
  place-items: center;
}

/* Curtain panels — the same silk artwork, mirrored for the right panel */
.entrance__panel {
  position: absolute;
  top: 0;
  bottom: 0;
  width: 50.6%;
  background-image: var(--entrance-image);
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  will-change: transform;
  transition: transform 1.45s var(--ease-curtain);
  filter: saturate(1.04) contrast(1.02);
}
.entrance__panel--left {
  left: 0;
  transform-origin: left center;
  box-shadow: inset -26px 0 60px rgba(10, 6, 18, 0.55);
}
.entrance__panel--right {
  right: 0;
  transform-origin: right center;
  transform: scaleX(-1);
  box-shadow: inset 26px 0 60px rgba(10, 6, 18, 0.55);
}

/* Hanging valance across the top */
.entrance__valance {
  position: absolute;
  inset: 0 0 auto 0;
  height: 22vh;
  min-height: 90px;
  background:
    radial-gradient(120% 140% at 50% 0%, rgba(201, 162, 39, 0.22), transparent 62%),
    linear-gradient(180deg, rgba(20, 12, 34, 0.85), transparent);
  pointer-events: none;
  transition: opacity 0.8s var(--ease-out);
}

.entrance__trigger {
  position: relative;
  z-index: 3;
  display: grid;
  place-items: center;
  gap: 0.4rem;
  padding: 1.2rem;
  background: none;
  border: 0;
  cursor: pointer;
  transition: transform 0.7s var(--ease-out), opacity 0.7s var(--ease-out);
}
.entrance__trigger:hover { transform: translateY(-4px); }

.entrance__bow {
  width: clamp(120px, 24vw, 180px);
  color: var(--gold-soft);
  filter: drop-shadow(0 8px 26px rgba(0, 0, 0, 0.55));
  animation: bowSway 5.5s var(--ease-in-out) infinite;
}
.entrance__bow svg { width: 100%; height: auto; }

.entrance__tag {
  display: block;
  position: relative;
  padding-top: 2.6rem;
}
.entrance__tag::before {
  content: "";
  position: absolute;
  top: 0; left: 50%;
  width: 1px; height: 2.2rem;
  background: linear-gradient(180deg, transparent, var(--gold-soft));
}
.entrance__tag-inner {
  display: inline-block;
  padding: 0.55rem 1.5rem;
  background: rgba(18, 12, 28, 0.62);
  border: 1px solid var(--line-gold);
  border-radius: var(--r-pill);
  backdrop-filter: blur(6px);
}
.entrance__tag-text {
  font-size: 0.76rem;
  letter-spacing: 0.32em;
  text-transform: uppercase;
  color: var(--gold-soft);
  animation: tagPulse 2.8s var(--ease-in-out) infinite;
}

.entrance__names {
  position: absolute;
  left: 50%;
  bottom: clamp(1.6rem, 6vh, 3.4rem);
  transform: translateX(-50%);
  z-index: 3;
  margin: 0;
  display: flex;
  align-items: center;
  gap: 0.8rem;
  font-family: var(--font-display);
  font-size: clamp(1.3rem, 4.4vw, 2rem);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: rgba(244, 239, 230, 0.9);
  text-shadow: 0 4px 22px rgba(0, 0, 0, 0.7);
  transition: opacity 0.6s var(--ease-out);
}
.entrance__names[hidden],
.entrance__date[hidden] { display: none; }
.entrance__names em {
  font-style: italic;
  color: var(--gold-soft);
  font-size: 0.9em;
}
.entrance__date {
  position: absolute;
  left: 50%;
  bottom: clamp(0.5rem, 2.4vh, 1.4rem);
  transform: translateX(-50%);
  z-index: 3;
  margin: 0;
  font-size: 0.72rem;
  letter-spacing: 0.34em;
  text-transform: uppercase;
  color: rgba(230, 201, 121, 0.85);
  transition: opacity 0.6s var(--ease-out);
}

/* Opening state */
.entrance.is-opening .entrance__panel--left { transform: translateX(-103%); }
.entrance.is-opening .entrance__panel--right { transform: translateX(103%) scaleX(-1); }
.entrance.is-opening .entrance__trigger { opacity: 0; transform: scale(0.86); pointer-events: none; }
.entrance.is-opening .entrance__names,
.entrance.is-opening .entrance__date,
.entrance.is-opening .entrance__valance { opacity: 0; }
.entrance.is-closing { opacity: 0; transition: opacity 0.5s var(--ease-out); }

@keyframes bowSway {
  0%, 100% { transform: rotate(-1.4deg); }
  50% { transform: rotate(1.4deg); }
}
@keyframes tagPulse {
  0%, 100% { opacity: 0.72; }
  50% { opacity: 1; }
}

/* ==========================================================================
   SITE HEADER
   ========================================================================== */
.site-header {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 90;
  /* Opaque enough that the gold monogram and nav stay legible over the hero
     photograph before the page has been scrolled. */
  background: linear-gradient(180deg, rgba(33, 47, 69, 0.94), rgba(33, 47, 69, 0.8));
  border-bottom: 1px solid rgba(230, 201, 121, 0.16);
  backdrop-filter: blur(12px);
  transform: translateY(-102%);
  opacity: 0;
  transition: transform 0.7s var(--ease-out), opacity 0.7s var(--ease-out), background-color 0.4s;
}
.site-header.is-visible { transform: none; opacity: 1; }
.site-header.is-scrolled {
  background: linear-gradient(180deg, rgba(20, 28, 46, 0.96), rgba(20, 28, 46, 0.88));
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-height: 66px;
}

.site-header__brand {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
}
.site-header__monogram {
  display: grid;
  place-items: center;
  width: 42px; height: 42px;
  border: 1px solid var(--line-gold);
  border-radius: 50%;
  font-family: var(--font-display);
  font-size: 0.92rem;
  letter-spacing: 0.06em;
  color: var(--gold-soft);
  flex: none;
}
.site-header__brand-text {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-family: var(--font-display);
  font-size: 1rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-on-dark);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.site-header__brand-sep { color: var(--gold-soft); font-style: italic; }

.site-nav {
  display: flex;
  align-items: center;
  gap: clamp(0.6rem, 2vw, 1.6rem);
}
.site-nav a {
  position: relative;
  font-size: 0.72rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: rgba(244, 239, 230, 0.76);
  padding: 0.4rem 0;
  transition: color var(--dur-fast) var(--ease-out);
}
.site-nav a::after {
  content: "";
  position: absolute;
  left: 0; bottom: 0;
  width: 100%; height: 1px;
  background: var(--gold-soft);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform var(--dur) var(--ease-out);
}
.site-nav a:hover,
.site-nav a.is-active { color: var(--gold-soft); }
.site-nav a:hover::after,
.site-nav a.is-active::after { transform: scaleX(1); }

/* ==========================================================================
   HERO
   ========================================================================== */
.hero {
  position: relative;
  min-height: 100svh;
  display: grid;
  place-items: center;
  padding: calc(var(--sp-7) + 2rem) 0 var(--sp-6);
  overflow: hidden;
  isolation: isolate;
  text-align: center;
}

.hero__media { position: absolute; inset: 0; z-index: -2; }
.hero__image {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 28%;
  transform: scale(1.08);
  animation: heroDrift 22s var(--ease-in-out) infinite alternate;
}
.hero__image.is-missing { display: none; }
@keyframes heroDrift {
  from { transform: scale(1.08) translate3d(0, 0, 0); }
  to { transform: scale(1.16) translate3d(0, -1.6%, 0); }
}

.hero__veil {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(78% 62% at 50% 42%, rgba(10, 14, 28, 0.24), rgba(10, 14, 28, 0.72) 72%, rgba(8, 10, 20, 0.9)),
    linear-gradient(180deg, rgba(39, 38, 64, 0.6), rgba(33, 47, 69, 0.42) 40%, rgba(62, 31, 71, 0.72));
  mix-blend-mode: multiply;
}
.hero__glow {
  position: absolute;
  inset: 0;
  background: radial-gradient(46% 34% at 50% 30%, rgba(230, 201, 121, 0.2), transparent 70%);
}

.hero__frame {
  position: absolute;
  inset: clamp(0.7rem, 2.4vw, 1.6rem);
  z-index: 1;
  pointer-events: none;
}
.hero__corner {
  position: absolute;
  width: clamp(42px, 8vw, 74px);
  height: clamp(42px, 8vw, 74px);
  border: 1px solid rgba(230, 201, 121, 0.42);
}
.hero__corner--tl { top: 0; left: 0; border-right: 0; border-bottom: 0; }
.hero__corner--tr { top: 0; right: 0; border-left: 0; border-bottom: 0; }
.hero__corner--bl { bottom: 0; left: 0; border-right: 0; border-top: 0; }
.hero__corner--br { bottom: 0; right: 0; border-left: 0; border-top: 0; }

.hero__content { position: relative; z-index: 2; }

/* A soft scrim sits between the photograph and the hero copy. The veil alone
   only reaches 24% opacity in the middle of the frame, so this keeps the
   wording legible no matter which photograph a family drops in. */
.hero__content::before {
  content: "";
  position: absolute;
  inset: -14% -8%;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(64% 60% at 50% 50%,
    rgba(7, 10, 20, 0.68) 0%,
    rgba(7, 10, 20, 0.5) 46%,
    rgba(7, 10, 20, 0.24) 72%,
    rgba(7, 10, 20, 0) 92%);
}

.hero__blessing {
  display: inline-block;
  margin: 0 0 var(--sp-4);
  padding: 0.34rem 1.3rem;
  border-radius: var(--r-pill);
  background: rgba(10, 14, 28, 0.44);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  font-size: clamp(0.82rem, 2.4vw, 1rem);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: rgba(230, 201, 121, 0.95);
  text-shadow: 0 2px 16px rgba(0, 0, 0, 0.6);
}

.hero__eyebrow {
  margin: 0 0 var(--sp-3);
  font-family: var(--font-script);
  font-size: clamp(2.2rem, 8vw, 3.8rem);
  line-height: 1.1;
  color: var(--ivory);
  text-shadow: 0 6px 26px rgba(0, 0, 0, 0.55);
}

.hero__title {
  margin: 0 0 var(--sp-4);
  display: grid;
  justify-items: center;
  gap: 0.15rem;
}
.hero__name {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 11vw, 5.6rem);
  line-height: 1.02;
  letter-spacing: 0.04em;
  color: #fff;
  text-shadow: 0 10px 40px rgba(0, 0, 0, 0.55);
  word-break: break-word;
  overflow-wrap: anywhere;
}
.hero__name--bride { color: #f7e7c4; }
.hero__amp {
  width: clamp(74px, 16vw, 118px);
  color: var(--gold-soft);
  margin: 0.15rem 0 0.35rem;
}
.hero__amp svg { width: 100%; height: auto; }

.hero__meta {
  display: inline-flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.8rem 1.8rem;
  margin: 0 auto var(--sp-5);
  padding: 0.42rem 1.15rem;
  border-radius: var(--r-pill);
  background: rgba(8, 12, 24, 0.42);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  box-shadow: inset 0 0 0 1px rgba(230, 201, 121, 0.26);
  font-size: 0.84rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-on-dark);
}
.hero__meta-item { display: inline-flex; align-items: center; gap: 0.55rem; }
.hero__meta-item .ico { color: var(--gold-soft); width: 1.15em; height: 1.15em; }

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.9rem;
}

.hero__scroll {
  position: absolute;
  left: 50%;
  bottom: clamp(1rem, 4vh, 2.2rem);
  transform: translateX(-50%);
  z-index: 3;
  display: grid;
  justify-items: center;
  gap: 0.5rem;
  font-size: 0.62rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: rgba(244, 239, 230, 0.65);
}
.hero__scroll-line {
  width: 1px;
  height: 46px;
  background: linear-gradient(180deg, var(--gold-soft), transparent);
  animation: scrollHint 2.6s var(--ease-in-out) infinite;
}
@keyframes scrollHint {
  0%, 100% { transform: scaleY(0.45); opacity: 0.4; transform-origin: top; }
  50% { transform: scaleY(1); opacity: 1; transform-origin: top; }
}

/* Petals */
/* Petals drift behind the hero veil so they can never wash out the copy. */
.hero__petals,
.closing__petals {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}
/* Inside .hero__media the petals are painted before the veil, so the veil's
   multiply blend settles them into the photograph. */
.hero__petals { z-index: 0; }
.closing__petals { z-index: 1; }
.petal {
  position: absolute;
  top: -8vh;
  width: 14px;
  height: 14px;
  border-radius: 60% 0 60% 0;
  background: linear-gradient(140deg, rgba(240, 205, 205, 0.72), rgba(190, 120, 140, 0.5));
  opacity: 0;
  filter: blur(0.2px);
  animation: petalFall linear infinite;
}
.petal--gold { background: linear-gradient(140deg, rgba(230, 201, 121, 0.6), rgba(160, 120, 40, 0.38)); }
@keyframes petalFall {
  0% { opacity: 0; transform: translate3d(0, -10vh, 0) rotate(0deg); }
  10% { opacity: 0.6; }
  90% { opacity: 0.38; }
  100% { opacity: 0; transform: translate3d(var(--drift, 40px), 108vh, 0) rotate(420deg); }
}

/* ==========================================================================
   SCRATCH TO REVEAL
   ========================================================================== */
.section--scratch {
  background: linear-gradient(180deg, var(--ivory), var(--cream) 55%, var(--ivory));
  overflow: hidden;
}

.scratch-scene {
  position: absolute;
  inset: 0;
  z-index: 0;
  overflow: hidden;
}
.scratch-scene__bg {
  width: 100%; height: 100%;
  object-fit: cover;
  object-position: center 40%;
  opacity: 0.4;
  filter: saturate(0.85);
}
.scratch-scene__bg.is-missing { display: none; }
.scratch-scene__veil {
  position: absolute;
  inset: 0;
  background:
    radial-gradient(60% 46% at 50% 52%, rgba(255, 253, 248, 0.9), rgba(246, 236, 221, 0.72) 58%, rgba(240, 228, 210, 0.6)),
    linear-gradient(180deg, rgba(253, 249, 242, 0.8), rgba(246, 236, 221, 0.55));
}
.scratch-scene__toran {
  position: absolute;
  top: 0;
  width: 46%;
  height: 130px;
  background-repeat: no-repeat;
  background-size: contain;
  background-position: top center;
  opacity: 0.55;
  filter: drop-shadow(0 6px 14px rgba(60, 40, 20, 0.16));
}
.scratch-scene__toran--left { left: -6%; transform: rotate(4deg); }
.scratch-scene__toran--right { right: -6%; transform: rotate(-4deg) scaleX(-1); }

.section--scratch .shell { position: relative; z-index: 1; }

.scratch-wrap {
  display: grid;
  justify-items: center;
  gap: var(--sp-4);
}

.scratch-card {
  position: relative;
  width: min(78vw, 330px);
  aspect-ratio: 1;
  display: grid;
  place-items: center;
}

.scratch-card__ring {
  position: absolute;
  inset: -13px;
  border-radius: 50%;
  border: 1px solid var(--line-gold);
  background:
    radial-gradient(circle at 50% 50%, rgba(201, 162, 39, 0.08), transparent 62%);
}
.scratch-card__ring::before,
.scratch-card__ring::after {
  content: "";
  position: absolute;
  border-radius: 50%;
  border: 1px dashed rgba(201, 162, 39, 0.4);
}
.scratch-card__ring::before { inset: 8px; }
.scratch-card__ring::after { inset: -10px; border-style: solid; border-color: rgba(201, 162, 39, 0.18); }

.scratch-card__frame {
  position: relative;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  overflow: hidden;
  background:
    radial-gradient(120% 120% at 30% 18%, #ffffff, var(--cream) 48%, var(--cream-deep));
  box-shadow: var(--sh-card), inset 0 0 0 1px rgba(255, 255, 255, 0.6);
  display: grid;
  place-items: center;
}

.scratch-card__content {
  padding: 12% 12% 10%;
  text-align: center;
  color: var(--deep-blue-teal);
  opacity: 0;
  transform: scale(0.94);
  transition: opacity 0.7s var(--ease-out), transform 0.9s var(--ease-out);
}
.scratch-card.is-revealed .scratch-card__content {
  opacity: 1;
  transform: none;
}
.scratch-card__eyebrow {
  margin: 0 0 0.3rem;
  font-family: var(--font-script);
  font-size: clamp(1.5rem, 5vw, 2.1rem);
  color: var(--midnight-plum);
  line-height: 1.2;
}
.scratch-card__names {
  margin: 0 0 0.5rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  font-family: var(--font-display);
  font-size: clamp(1rem, 3.6vw, 1.3rem);
  letter-spacing: 0.06em;
  color: var(--deep-blue-teal);
}
.scratch-card__names em { font-style: italic; color: var(--gold-ink); }
.scratch-card__date {
  margin: 0 0 0.15rem;
  font-size: clamp(0.92rem, 3.2vw, 1.05rem);
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--charcoal-blue);
}
.scratch-card__day {
  margin: 0 0 0.5rem;
  font-size: 0.82rem;
  letter-spacing: 0.12em;
  color: var(--ink-soft);
}
.scratch-card__day .dot { color: var(--gold-ink); margin: 0 0.35rem; }
.scratch-card__msg {
  margin: 0 0 0.7rem;
  font-family: var(--font-script);
  font-size: 1.5rem;
  color: var(--midnight-plum);
}

.scratch-card__canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  touch-action: none;
  cursor: crosshair;
  transition: opacity 0.75s var(--ease-out), transform 0.9s var(--ease-out);
}
.scratch-card.is-revealed .scratch-card__canvas {
  opacity: 0;
  transform: scale(1.05);
  pointer-events: none;
}

.scratch-card__sparkles { position: absolute; inset: 0; pointer-events: none; }
.sparkle {
  position: absolute;
  width: 12px; height: 12px;
  background: radial-gradient(circle, #fff 0%, var(--gold-soft) 45%, rgba(230, 201, 121, 0) 72%);
  border-radius: 50%;
  opacity: 0;
  transform: scale(0.2);
  animation: sparklePop 1.15s var(--ease-out) forwards;
}
@keyframes sparklePop {
  0% { opacity: 0; transform: translate(-50%, -50%) scale(0.2); }
  35% { opacity: 1; transform: translate(-50%, -50%) scale(1.15); }
  100% { opacity: 0; transform: translate(-50%, -50%) scale(0.35); }
}

.scratch-status {
  margin: 0;
  font-size: 0.9rem;
  color: var(--ink-soft);
  text-align: center;
  max-width: 30rem;
  min-height: 1.4em;
}
.scratch-actions { margin-top: -0.4rem; }

/* ==========================================================================
   COUNTDOWN
   ========================================================================== */
.section--countdown {
  background:
    radial-gradient(120% 90% at 50% 0%, rgba(77, 25, 77, 0.55), transparent 60%),
    linear-gradient(160deg, var(--deep-space-blue) 0%, var(--space-indigo) 42%, var(--midnight-violet) 72%, var(--midnight-plum) 100%);
  color: var(--text-on-dark);
  overflow: hidden;
}
.section--countdown::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    radial-gradient(rgba(230, 201, 121, 0.14) 1px, transparent 1px);
  background-size: 34px 34px;
  opacity: 0.5;
  pointer-events: none;
}
.section--countdown .shell { position: relative; z-index: 1; }
.section--countdown .section__title { color: var(--ivory); }

.countdown {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: clamp(0.6rem, 2.4vw, 1.4rem);
  max-width: 60rem;
  margin-inline: auto;
}
.countdown__unit {
  position: relative;
  padding: clamp(1rem, 3.4vw, 2rem) 0.4rem;
  text-align: center;
  border: 1px solid rgba(230, 201, 121, 0.28);
  border-radius: var(--r-md);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.06), rgba(255, 255, 255, 0.015));
  backdrop-filter: blur(6px);
  box-shadow: 0 18px 44px rgba(8, 8, 20, 0.3);
  overflow: hidden;
}
.countdown__unit::before {
  content: "";
  position: absolute;
  inset: 6px;
  border: 1px solid rgba(230, 201, 121, 0.14);
  border-radius: 8px;
  pointer-events: none;
}
.countdown__value {
  display: block;
  font-family: var(--font-display);
  font-size: clamp(2.1rem, 8vw, 3.9rem);
  font-weight: 500;
  line-height: 1;
  color: var(--gold-soft);
  font-variant-numeric: tabular-nums;
  text-shadow: 0 6px 26px rgba(0, 0, 0, 0.45);
}
.countdown__value.is-ticking { animation: tick 0.45s var(--ease-out); }
@keyframes tick {
  0% { transform: translateY(-7px); opacity: 0.35; }
  100% { transform: none; opacity: 1; }
}
.countdown__label {
  display: block;
  margin-top: 0.55rem;
  font-size: 0.66rem;
  letter-spacing: 0.28em;
  text-transform: uppercase;
  color: var(--text-on-dark-soft);
}
.countdown__note {
  margin: var(--sp-4) auto 0;
  text-align: center;
  color: var(--gold-soft);
  font-family: var(--font-display);
  font-size: clamp(1.2rem, 3.6vw, 1.7rem);
  font-style: italic;
  min-height: 1.5em;
}

/* ==========================================================================
   INVITATION CARD
   ========================================================================== */
.section--invitation {
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(90% 60% at 50% 0%, rgba(0, 100, 102, 0.07), transparent 65%),
    var(--ivory);
  /* Clear the hanging toran: the garland is ~17% of its own height deep and the
     artwork is capped at 64rem wide, so the head must start below it. */
  padding-top: calc(min(100vw, 64rem) * 0.18 + 1.4rem);
}

/* Hanging mango-leaf + jasmine toran across the top of the section */
.invite-toran {
  position: absolute;
  top: 0;
  left: 50%;
  z-index: 0;
  width: min(100%, 64rem);
  transform: translateX(-50%);
  line-height: 0;
  pointer-events: none;
}
.invite-toran img {
  display: block;
  width: 100%;
  height: auto;
  /* Reserve the space up-front so the lazy image causes no layout shift. */
  aspect-ratio: 1200 / 293;
  opacity: 0.9;
  filter: drop-shadow(0 6px 16px rgba(48, 32, 12, 0.16));
}
.section--invitation .shell { position: relative; z-index: 1; }

/* Two-column invitation: the couple photograph beside the formal card */
.invite-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-5);
  align-items: center;
  justify-items: center;
}
@media (min-width: 62rem) {
  .invite-layout {
    grid-template-columns: minmax(0, 20rem) minmax(0, 1fr);
    gap: var(--sp-6);
    align-items: center;
    justify-items: stretch;
  }
  .invite-layout .invite-card { margin-inline: 0; }
}

.couple-photo {
  position: relative;
  margin: 0;
  width: min(100%, 20rem);
  padding-bottom: 1.6rem;
}
.couple-photo__arch {
  position: absolute;
  inset: -10px -10px 0;
  border: 1px solid var(--line-gold);
  border-bottom: 0;
  border-radius: 50% 50% 0 0 / 32% 32% 0 0;
  pointer-events: none;
}
.couple-photo__image {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  border-radius: 50% 50% 10px 10px / 30% 30% 10px 10px;
  box-shadow: var(--sh-card);
  filter: saturate(0.94);
}
.couple-photo__image.is-missing { display: none; }
.couple-photo__caption {
  margin-top: 0.85rem;
  font-family: var(--font-display);
  font-size: 1.06rem;
  letter-spacing: 0.05em;
  color: var(--deep-blue-teal);
  text-align: center;
}
.couple-photo__caption em {
  font-family: var(--font-script);
  font-style: normal;
  color: var(--gold-ink);
  padding-inline: 0.35rem;
}

.invite-card {
  position: relative;
  max-width: 46rem;
  margin-inline: auto;
  padding: clamp(2rem, 6vw, 3.6rem) clamp(1.3rem, 5vw, 3.4rem);
  background: linear-gradient(180deg, #fff, var(--cream) 100%);
  border: 1px solid var(--line-gold);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-card);
  text-align: center;
  overflow: hidden;
}
.invite-card::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(201, 162, 39, 0.28);
  border-radius: calc(var(--r-lg) - 8px);
  pointer-events: none;
}
.invite-card__temple {
  display: block;
  width: min(46%, 190px);
  margin: 0 auto 0.6rem;
  /* Reserve the space up-front so the lazy image causes no layout shift. */
  aspect-ratio: 560 / 644;
  object-fit: contain;
  opacity: 0.9;
  filter: drop-shadow(0 8px 20px rgba(80, 50, 20, 0.14));
}
.invite-card__temple.is-missing { display: none; }

.invite-card__intro {
  margin: 0 0 var(--sp-4);
  color: var(--ink-soft);
  font-size: 1.02rem;
  max-width: 34rem;
  margin-inline: auto;
}
.invite-card__intro:lang(ta) { font-family: "Noto Sans Tamil", "Latha", var(--font-body); }

.invite-card__names {
  margin: 0 0 var(--sp-3);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.35rem 1rem;
}
.invite-card__name {
  font-family: var(--font-display);
  font-size: clamp(1.9rem, 6vw, 3rem);
  color: var(--deep-blue-teal);
  letter-spacing: 0.03em;
  overflow-wrap: anywhere;
}
.invite-card__amp {
  font-family: var(--font-script);
  font-size: clamp(1.8rem, 6vw, 2.6rem);
  color: var(--gold-ink);
}
.invite-card__outro {
  margin: 0 auto var(--sp-3);
  max-width: 32rem;
  color: var(--ink-soft);
  font-style: italic;
}

.invite-details {
  margin: var(--sp-4) auto 0;
  max-width: 30rem;
  display: grid;
  gap: 0.15rem;
  text-align: left;
}
.invite-details__row {
  display: grid;
  grid-template-columns: 8.5rem 1fr;
  gap: 0.6rem 1rem;
  align-items: baseline;
  padding: 0.75rem 0;
  border-top: 1px solid var(--line-soft);
}
.invite-details__row:last-child { border-bottom: 1px solid var(--line-soft); }
.invite-details dt {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.68rem;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--gold-ink);
}
.invite-details dt .ico { width: 1.3em; height: 1.3em; }
.invite-details dd {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.08rem;
  color: var(--charcoal-blue);
}
.invite-details__sub { font-size: 0.95rem; color: var(--ink-soft); }

.invite-reception {
  display: flex;
  align-items: center;
  gap: 1.1rem;
  max-width: 40rem;
  margin: var(--sp-5) auto 0;
  padding: 1.2rem 1.6rem;
  background: linear-gradient(120deg, rgba(62, 31, 71, 0.06), rgba(0, 100, 102, 0.06));
  border: 1px solid var(--line-gold);
  border-radius: var(--r-md);
  text-align: left;
}
.invite-reception__icon {
  display: grid;
  place-items: center;
  width: 52px; height: 52px;
  flex: none;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  color: #33280a;
}
.invite-reception__icon .ico { width: 1.5rem; height: 1.5rem; }
.invite-reception__title {
  margin: 0 0 0.15rem;
  font-size: 1.35rem;
  color: var(--midnight-plum);
}
.invite-reception__text { margin: 0; color: var(--ink-soft); font-size: 0.95rem; }

/* ==========================================================================
   TIMELINE
   ========================================================================== */
.section--celebrations {
  background:
    radial-gradient(80% 50% at 50% 0%, rgba(11, 82, 91, 0.08), transparent 62%),
    linear-gradient(180deg, var(--ivory), var(--cream));
}

.timeline {
  position: relative;
  max-width: 54rem;
  margin-inline: auto;
  display: grid;
  gap: clamp(1rem, 3vw, 1.6rem);
}
.timeline::before {
  content: "";
  position: absolute;
  top: 6px; bottom: 6px;
  left: 19px;
  width: 1px;
  background: linear-gradient(180deg, transparent, var(--line-gold) 8%, var(--line-gold) 92%, transparent);
}

.tl-item {
  position: relative;
  padding-left: 3.1rem;
}
.tl-item__marker {
  position: absolute;
  left: 0; top: 0.35rem;
  width: 40px; height: 40px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  border: 1px solid var(--line-gold);
  background: var(--ivory);
  color: var(--deep-teal);
  box-shadow: 0 6px 18px rgba(20, 40, 50, 0.1);
  transition: background-color var(--dur) var(--ease-out), color var(--dur) var(--ease-out), transform var(--dur) var(--ease-out);
}
.tl-item__marker .ico { width: 1.3rem; height: 1.3rem; }
.tl-item.is-open .tl-item__marker,
.tl-item__btn:hover .tl-item__marker {
  background: linear-gradient(135deg, var(--gold-soft), var(--gold));
  color: #33280a;
  transform: scale(1.06);
}

.tl-item__btn {
  display: block;
  width: 100%;
  text-align: left;
  padding: 1.1rem 1.3rem;
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  cursor: pointer;
  transition: border-color var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out), transform var(--dur) var(--ease-out);
}
.tl-item__btn:hover {
  border-color: var(--line-gold);
  box-shadow: var(--sh-soft);
  transform: translateY(-2px);
}
.tl-item__time {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold-ink);
  margin-bottom: 0.2rem;
}
.tl-item__name {
  margin: 0 0 0.25rem;
  font-size: clamp(1.25rem, 3.4vw, 1.6rem);
  color: var(--deep-blue-teal);
}
.tl-item__desc {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.95rem;
}
.tl-item__more {
  display: grid;
  grid-template-rows: 0fr;
  transition: grid-template-rows var(--dur) var(--ease-out);
}
.tl-item__more > span { overflow: hidden; }
.tl-item.is-open .tl-item__more { grid-template-rows: 1fr; }
.tl-item__more p {
  margin: 0.85rem 0 0;
  padding-top: 0.85rem;
  border-top: 1px dashed var(--line-gold);
  font-size: 0.92rem;
  color: var(--ink-soft);
  font-style: italic;
}
.tl-item__toggle {
  display: inline-block;
  margin-top: 0.5rem;
  font-size: 0.66rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--deep-teal);
}
.tl-item__toggle::after { content: " +"; }
.tl-item.is-open .tl-item__toggle::after { content: " –"; }

/* ==========================================================================
   PRE-WEDDING CARDS
   ========================================================================== */
.section--prewedding {
  background:
    radial-gradient(90% 55% at 50% 100%, rgba(62, 31, 71, 0.1), transparent 65%),
    linear-gradient(180deg, var(--cream), var(--ivory));
}

.cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: clamp(1rem, 2.6vw, 1.6rem);
}

.pw-card {
  position: relative;
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  box-shadow: var(--sh-soft);
  transition: transform var(--dur) var(--ease-out), box-shadow var(--dur) var(--ease-out), border-color var(--dur) var(--ease-out);
}
.pw-card:hover {
  transform: translateY(-5px);
  box-shadow: var(--sh-card);
  border-color: var(--line-gold);
}
.pw-card__image {
  width: 100%;
  height: 150px;
  object-fit: cover;
  display: none;
}
.pw-card__image.is-shown { display: block; }
.pw-card__body { padding: 1.4rem 1.4rem 1.6rem; display: flex; flex-direction: column; flex: 1; }
.pw-card__icon {
  display: grid;
  place-items: center;
  width: 46px; height: 46px;
  margin-bottom: 0.9rem;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(201, 162, 39, 0.2), rgba(0, 100, 102, 0.14));
  color: var(--deep-teal);
  flex: none;
}
.pw-card__icon .ico { width: 1.35rem; height: 1.35rem; }
.pw-card__date {
  margin: 0 0 0.15rem;
  font-size: 0.68rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--gold-ink);
}
.pw-card__name {
  margin: 0 0 0.15rem;
  font-size: 1.45rem;
  color: var(--deep-blue-teal);
}
.pw-card__sub {
  margin: 0 0 0.7rem;
  font-family: var(--font-script);
  font-size: 1.25rem;
  color: var(--midnight-plum);
}
.pw-card__desc {
  margin: 0 0 1rem;
  color: var(--ink-soft);
  font-size: 0.94rem;
  flex: 1;
}
.pw-card__meta {
  display: grid;
  gap: 0.45rem;
  margin: 0;
  padding-top: 0.9rem;
  border-top: 1px solid var(--line-soft);
  font-size: 0.86rem;
  color: var(--ink-soft);
}
.pw-card__meta div { display: flex; align-items: flex-start; gap: 0.5rem; }
.pw-card__meta .ico { color: var(--gold-ink); margin-top: 0.32em; width: 1.15em; height: 1.15em; }

/* ==========================================================================
   VENUE
   ========================================================================== */
.section--venue {
  background: linear-gradient(180deg, var(--ivory), var(--cream));
}

.venue {
  display: grid;
  grid-template-columns: 1.05fr 1fr;
  gap: clamp(1.4rem, 4vw, 3rem);
  align-items: center;
  max-width: 64rem;
  margin-inline: auto;
}
.venue__figure {
  position: relative;
  margin: 0;
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--sh-card);
}
.venue__image {
  width: 100%;
  aspect-ratio: 4 / 3.2;
  object-fit: cover;
}
.venue__image.is-missing { display: none; }
.venue__figure::after {
  content: "";
  position: absolute;
  inset: 0;
  border: 1px solid rgba(230, 201, 121, 0.45);
  border-radius: var(--r-lg);
  pointer-events: none;
}
.venue__caption {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 1.6rem 1.4rem 1rem;
  background: linear-gradient(180deg, transparent, rgba(15, 18, 34, 0.88));
  color: var(--ivory);
  font-family: var(--font-display);
  font-size: 1.25rem;
  letter-spacing: 0.05em;
}
.venue__name {
  margin: 0 0 0.4rem;
  font-size: clamp(1.7rem, 4.6vw, 2.4rem);
  color: var(--deep-blue-teal);
}
.venue__address { margin: 0 0 0.2rem; color: var(--ink); }
.venue__city {
  margin: 0 0 1.2rem;
  color: var(--gold-ink);
  font-size: 0.74rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
}
.venue__facts {
  display: grid;
  gap: 0.5rem;
  margin: 0 0 1.6rem;
  padding: 1rem 0;
  border-top: 1px solid var(--line-soft);
  border-bottom: 1px solid var(--line-soft);
}
.venue__facts li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  font-size: 0.95rem;
  color: var(--ink-soft);
}
.venue__facts .ico { color: var(--gold-ink); }
.venue__actions { display: flex; flex-wrap: wrap; gap: 0.8rem; }
.venue__actions .btn--ghost {
  background: rgba(0, 100, 102, 0.05);
  color: var(--deep-teal);
}

/* ==========================================================================
   DRESS CODE
   ========================================================================== */
.section--attire {
  background:
    radial-gradient(70% 50% at 50% 0%, rgba(201, 162, 39, 0.12), transparent 62%),
    var(--ivory);
}
.attire {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(270px, 1fr));
  gap: clamp(1rem, 2.6vw, 1.8rem);
  max-width: 52rem;
  margin-inline: auto;
}
.attire__card {
  padding: clamp(1.6rem, 4vw, 2.4rem) clamp(1.4rem, 3.4vw, 2rem);
  text-align: center;
  background: linear-gradient(180deg, #fff, var(--cream));
  border: 1px solid var(--line-gold);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-soft);
}
.attire__icon {
  display: grid;
  place-items: center;
  width: 74px; height: 74px;
  margin: 0 auto 1rem;
  border-radius: 50%;
  background: linear-gradient(140deg, rgba(0, 100, 102, 0.12), rgba(62, 31, 71, 0.12));
  color: var(--deep-teal);
}
.attire__icon .ico { width: 2.1rem; height: 2.1rem; }
.attire__title {
  margin: 0 0 0.4rem;
  font-size: 1.5rem;
  color: var(--midnight-plum);
}
.attire__text { margin: 0; color: var(--ink-soft); font-size: 0.96rem; }
.attire__note {
  max-width: 44rem;
  margin: var(--sp-5) auto 0;
  text-align: center;
  font-style: italic;
  color: var(--ink-soft);
}

/* ==========================================================================
   TRAVEL / STAY
   ========================================================================== */
.section--travel,
.section--stay {
  background: linear-gradient(180deg, var(--cream), var(--ivory));
}
.section--travel[hidden],
.section--stay[hidden] { display: none; }

.info-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: clamp(0.9rem, 2.4vw, 1.4rem);
  max-width: 60rem;
  margin-inline: auto;
}
.info-card {
  display: flex;
  gap: 0.9rem;
  padding: 1.2rem 1.3rem;
  background: #fff;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-md);
  box-shadow: var(--sh-soft);
}
.info-card__icon {
  display: grid;
  place-items: center;
  width: 44px; height: 44px;
  flex: none;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(0, 100, 102, 0.12), rgba(201, 162, 39, 0.16));
  color: var(--deep-teal);
}
.info-card__icon .ico { width: 1.3rem; height: 1.3rem; }
.info-card__title {
  margin: 0 0 0.2rem;
  font-size: 1.1rem;
  color: var(--deep-blue-teal);
}
.info-card__text { margin: 0; font-size: 0.9rem; color: var(--ink-soft); }
.info-card__link {
  display: inline-block;
  margin-top: 0.35rem;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--deep-teal);
  border-bottom: 1px solid var(--line-gold);
}
.info-note {
  max-width: 44rem;
  margin: var(--sp-5) auto 0;
  text-align: center;
  font-style: italic;
  color: var(--ink-soft);
}
.info-note:empty { display: none; }

/* ==========================================================================
   GIFTS
   ========================================================================== */
.section--gifts {
  background:
    radial-gradient(80% 60% at 50% 50%, rgba(0, 100, 102, 0.08), transparent 68%),
    var(--ivory);
}
.gifts {
  max-width: 44rem;
  margin-inline: auto;
  text-align: center;
  padding: clamp(2rem, 6vw, 3.6rem) clamp(1.4rem, 5vw, 3rem);
  background: linear-gradient(180deg, #fff, var(--cream));
  border: 1px solid var(--line-gold);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-soft);
}
.gifts__icon {
  display: grid;
  place-items: center;
  width: 66px; height: 66px;
  margin: 0 auto 1rem;
  border-radius: 50%;
  background: linear-gradient(140deg, rgba(201, 162, 39, 0.2), rgba(0, 100, 102, 0.14));
  color: var(--gold-ink);
}
.gifts__icon .ico { width: 1.9rem; height: 1.9rem; }
.gifts__message {
  margin: 0 auto;
  max-width: 32rem;
  font-family: var(--font-display);
  font-size: clamp(1.15rem, 3.4vw, 1.5rem);
  font-style: italic;
  color: var(--charcoal-blue);
}
.gifts__note { margin: 1rem 0 0; color: var(--ink-soft); font-size: 0.92rem; }
.gifts__note[hidden] { display: none; }

/* ==========================================================================
   RSVP
   ========================================================================== */
.section--rsvp {
  background:
    radial-gradient(110% 70% at 50% 0%, rgba(62, 31, 71, 0.1), transparent 62%),
    linear-gradient(180deg, var(--ivory), var(--cream));
}
.rsvp {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: clamp(1.4rem, 3.6vw, 2.6rem);
  max-width: 62rem;
  margin-inline: auto;
  align-items: start;
}
.rsvp__form {
  padding: clamp(1.5rem, 4vw, 2.4rem);
  background: #fff;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-card);
}
.field { margin-bottom: 1.2rem; border: 0; padding: 0; }
.field label,
.field legend {
  display: block;
  margin-bottom: 0.45rem;
  font-size: 0.7rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--charcoal-blue);
  font-weight: 500;
}
.field__req { color: var(--gold-ink); }
.field__optional {
  text-transform: none;
  letter-spacing: 0.02em;
  color: var(--ink-soft);
  font-weight: 300;
  font-style: italic;
}
.field input[type="text"],
.field input[type="tel"],
.field input[type="number"],
.field textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  font-family: var(--font-body);
  font-size: 1rem;
  color: var(--ink);
  background: var(--ivory);
  border: 1px solid var(--line-soft);
  border-radius: var(--r-sm);
  transition: border-color var(--dur-fast) var(--ease-out), box-shadow var(--dur-fast) var(--ease-out);
}
.field textarea { resize: vertical; min-height: 110px; }
.field input:focus,
.field textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px rgba(201, 162, 39, 0.18);
}
.field input[aria-invalid="true"],
.field textarea[aria-invalid="true"] {
  border-color: #b3261e;
  box-shadow: 0 0 0 3px rgba(179, 38, 30, 0.12);
}
.field__error {
  margin: 0.4rem 0 0;
  font-size: 0.82rem;
  color: #b3261e;
}
.field__error[hidden] { display: none; }

.choices { display: grid; gap: 0.6rem; }
.choice {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  padding: 0.8rem 1rem;
  border: 1px solid var(--line-soft);
  border-radius: var(--r-sm);
  background: var(--ivory);
  cursor: pointer;
  transition: border-color var(--dur-fast) var(--ease-out), background-color var(--dur-fast) var(--ease-out);
}
.choice:hover { border-color: var(--gold); }
.choice input { accent-color: var(--deep-teal); width: 18px; height: 18px; flex: none; }
.choice span {
  margin: 0;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  text-transform: none;
  font-weight: 300;
  color: var(--ink);
}
.choice:has(input:checked) { border-color: var(--gold); background: rgba(201, 162, 39, 0.1); }

.rsvp__actions { display: flex; flex-wrap: wrap; gap: 0.8rem; margin-top: 1.4rem; }
/* The form card is white, so the ghost button needs dark ink rather than the
   light-on-dark treatment used over the hero and the venue panel. */
.rsvp__form .btn--ghost {
  background: rgba(0, 100, 102, 0.06);
  color: var(--deep-teal);
}
.rsvp__form .btn--ghost:hover {
  background: rgba(201, 162, 39, 0.16);
  border-color: var(--gold-ink);
}
.rsvp__status {
  margin: 1rem 0 0;
  padding: 0 0 0;
  font-size: 0.92rem;
  min-height: 1.4em;
}
.rsvp__status:empty { display: none; }
.rsvp__status.is-ok { color: #1c6b45; }
.rsvp__status.is-warn { color: #9a6a12; }
.rsvp__status.is-err { color: #b3261e; }

.rsvp__aside {
  padding: clamp(1.4rem, 3.6vw, 2rem);
  background: linear-gradient(165deg, var(--deep-space-blue), var(--midnight-violet) 70%, var(--midnight-plum));
  border-radius: var(--r-lg);
  color: var(--text-on-dark);
  box-shadow: var(--sh-card);
}
.rsvp__aside-title {
  margin: 0 0 1rem;
  font-size: 1.4rem;
  color: var(--gold-soft);
}
.rsvp__facts { display: grid; gap: 0.85rem; }
.rsvp__facts li {
  display: flex;
  align-items: flex-start;
  gap: 0.6rem;
  font-size: 0.92rem;
  color: var(--text-on-dark-soft);
}
.rsvp__facts .ico { color: var(--gold-soft); margin-top: 0.28em; }
.rsvp__aside-note {
  margin: 1.2rem 0 0;
  padding-top: 1rem;
  border-top: 1px solid rgba(230, 201, 121, 0.22);
  font-size: 0.88rem;
  color: var(--gold-soft);
}
.rsvp__aside-note[hidden] { display: none; }

/* ==========================================================================
   CLOSING
   ========================================================================== */
.closing {
  position: relative;
  padding: var(--sp-8) 0;
  text-align: center;
  overflow: hidden;
  background:
    radial-gradient(80% 70% at 50% 20%, rgba(201, 162, 39, 0.16), transparent 62%),
    linear-gradient(165deg, var(--deep-teal), var(--deep-blue-teal) 34%, var(--space-indigo) 68%, var(--midnight-plum));
  color: var(--ivory);
}
.closing__inner { position: relative; z-index: 1; }
/* Keeps the gold lettering crisp even when a petal drifts behind it. */
.closing__inner::before {
  content: "";
  position: absolute;
  inset: -3rem -1.5rem;
  z-index: -1;
  pointer-events: none;
  background: radial-gradient(58% 58% at 50% 44%, rgba(9, 11, 24, 0.55), rgba(9, 11, 24, 0.22) 62%, transparent 82%);
}
.closing__seal {
  display: grid;
  place-items: center;
  width: 84px; height: 84px;
  margin: 0 auto 1.4rem;
  border-radius: 50%;
  border: 1px solid rgba(230, 201, 121, 0.5);
  color: var(--gold-soft);
}
.closing__seal .ico { width: 2.6rem; height: 2.6rem; }
.closing__title {
  font-size: clamp(2rem, 6.4vw, 3.6rem);
  color: var(--ivory);
  margin-bottom: 0.4rem;
}
.closing__sub {
  margin: 0 0 0.5rem;
  font-family: var(--font-script);
  font-size: clamp(1.6rem, 5vw, 2.3rem);
  color: var(--gold-soft);
}
.closing__names {
  margin: 0 0 2rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 0.5rem 1.2rem;
  font-family: var(--font-display);
  font-size: clamp(1.6rem, 5.4vw, 2.6rem);
  letter-spacing: 0.06em;
  color: #fff;
}
.closing__names em { font-style: italic; color: var(--gold-soft); }

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
  padding: var(--sp-6) 0 var(--sp-5);
  text-align: center;
  background: linear-gradient(180deg, var(--deep-space-blue), #16192b);
  color: var(--text-on-dark-soft);
  border-top: 1px solid rgba(230, 201, 121, 0.18);
}
.site-footer__names {
  margin: 0 0 0.2rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.6rem;
  font-family: var(--font-display);
  font-size: 1.5rem;
  letter-spacing: 0.1em;
  color: var(--ivory);
}
.site-footer__names em { font-style: italic; color: var(--gold-soft); }
.site-footer__date {
  margin: 0 0 1rem;
  font-size: 0.72rem;
  letter-spacing: 0.3em;
  text-transform: uppercase;
  color: var(--gold-soft);
}
.site-footer__motif {
  display: grid;
  place-items: center;
  width: 54px; height: 54px;
  margin: 0 auto 1rem;
  border: 1px solid rgba(230, 201, 121, 0.35);
  border-radius: 50%;
  color: var(--gold-soft);
}
.site-footer__motif .ico { width: 1.7rem; height: 1.7rem; }
.site-footer__made {
  margin: 0 0 0.4rem;
  font-family: var(--font-script);
  font-size: 1.35rem;
  color: rgba(244, 239, 230, 0.86);
}
.site-footer__credit { margin: 0; font-size: 0.78rem; letter-spacing: 0.08em; }
.site-footer__credit a {
  color: var(--gold-soft);
  border-bottom: 1px solid rgba(230, 201, 121, 0.35);
  transition: color var(--dur-fast) var(--ease-out);
}
.site-footer__credit a:hover { color: #fff; }

/* ==========================================================================
   FLOATING UI
   ========================================================================== */
.floating-ui {
  position: fixed;
  right: clamp(0.7rem, 2.4vw, 1.4rem);
  bottom: clamp(0.7rem, 2.4vw, 1.4rem);
  z-index: 80;
  display: grid;
  gap: 0.6rem;
  justify-items: center;
}
.float-btn {
  display: grid;
  place-items: center;
  width: 48px; height: 48px;
  border-radius: 50%;
  border: 1px solid var(--line-gold);
  background: linear-gradient(150deg, rgba(33, 47, 69, 0.94), rgba(49, 34, 68, 0.94));
  color: var(--gold-soft);
  cursor: pointer;
  box-shadow: 0 12px 30px rgba(8, 8, 20, 0.4);
  backdrop-filter: blur(8px);
  transition: transform var(--dur-fast) var(--ease-out), opacity var(--dur) var(--ease-out), background-color var(--dur-fast) var(--ease-out);
}
.float-btn:hover { transform: translateY(-3px); background: linear-gradient(150deg, rgba(62, 31, 71, 0.96), rgba(33, 47, 69, 0.96)); }
.float-btn[hidden] { display: none; }
.float-btn .ico { width: 1.35rem; height: 1.35rem; }
.float-btn .ico--off { display: none; }
.float-btn[aria-pressed="true"] .ico--on { display: none; }
.float-btn[aria-pressed="true"] .ico--off { display: block; }
.float-btn[aria-pressed="true"] {
  background: linear-gradient(150deg, rgba(201, 162, 39, 0.9), rgba(169, 131, 28, 0.9));
  color: #2a2208;
}

/* ==========================================================================
   RESPONSIVE
   ========================================================================== */
@media (max-width: 960px) {
  .venue { grid-template-columns: 1fr; }
  .rsvp { grid-template-columns: 1fr; }
  .site-nav { display: none; }
}

@media (max-width: 720px) {
  :root { --sp-7: 3.6rem; --sp-8: 4.6rem; }
  html { scroll-padding-top: 74px; }
  .shell { width: min(100% - 1.6rem, var(--shell)); }
  .countdown { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .invite-details__row { grid-template-columns: 1fr; gap: 0.15rem; }
  .invite-card::before { inset: 7px; }
  .hero__meta { font-size: 0.76rem; gap: 0.5rem 1.2rem; }
  .hero__actions .btn { width: 100%; max-width: 20rem; }
  .timeline::before { left: 15px; }
  .tl-item { padding-left: 2.5rem; }
  .tl-item__marker { width: 32px; height: 32px; }
  .tl-item__marker .ico { width: 1.15rem; height: 1.15rem; }
  .tl-item__btn { padding: 0.95rem 1rem; }
  .scratch-card { width: min(84vw, 300px); }
  .site-header__brand-text { font-size: 0.82rem; letter-spacing: 0.1em; }
  .rsvp__actions .btn { width: 100%; }
}

@media (max-width: 420px) {
  .site-header__brand-text { display: none; }
  .countdown { gap: 0.5rem; }
  .countdown__value { font-size: 2.1rem; }
}

/* ==========================================================================
   REDUCED MOTION
   ========================================================================== */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *,
  *::before,
  *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
  .js [data-reveal] { opacity: 1; transform: none; }
  .hero__image { animation: none; }
  .entrance__panel { transition-duration: 0.25s !important; }
  .petal { display: none; }
  .entrance__bow,
  .entrance__tag-text { animation: none; }
}
