/* =====================================================================
   KALYANAM: Tamil wedding invitation
   Kumkum maroon, turmeric, temple gold, banana-leaf green, palm-leaf tan.
   Display: Arima · Text: Noto Serif Tamil · Hand: Kavivanar
   ===================================================================== */

:root {
  --maroon: #5A0F17;
  --maroon-d: #3A070D;
  --kumkum: #B3162A;
  --turmeric: #F2B91E;
  --turmeric-l: #FAD872;
  --gold: #D8A845;
  --gold-l: #F4DC94;
  --leaf: #2E6B33;
  --ink: #3D220B;
  --cream: #FBF4E4;
  --text: #3B1A12;
  --muted: #76503F;
  --f-disp: "Arima", "Noto Serif Tamil", serif;
  --f-text: "Noto Serif Tamil", "Latha", "Nirmala UI", serif;
  --f-hand: "Kavivanar", "Arima", "Noto Serif Tamil", cursive;
  --ease: cubic-bezier(.22, .8, .24, 1);
  --wv-accent: #D8A845;
  --wv-ink: #3A070D;
  --wv-paper: #FBF4E4;
  --wv-font: "Noto Serif Tamil", serif;
  --karai: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 22'%3E%3Crect width='24' height='3' fill='%23D8A845'/%3E%3Crect y='19' width='24' height='3' fill='%23D8A845'/%3E%3Cpath d='M0 19L12 6L24 19Z' fill='%23D8A845'/%3E%3Cpath d='M5 19L12 11.5L19 19Z' fill='%232E6B33'/%3E%3Ccircle cx='12' cy='4.4' r='1.6' fill='%23D8A845'/%3E%3C/svg%3E");
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
html.is-locked, html.is-locked body { overflow: hidden; }
body {
  margin: 0;
  background: var(--cream);
  color: var(--text);
  font: 400 16px/1.85 var(--f-text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}
img { max-width: 100%; }
button { font: inherit; }
h1, h2, h3, p { overflow-wrap: break-word; }
:focus-visible { outline: 2px solid var(--turmeric); outline-offset: 3px; }
main:focus { outline: none; }
.defs { position: absolute; width: 0; height: 0; overflow: hidden; }
.vh { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.noscript { padding: 48px 24px; text-align: center; }

.wrap { position: relative; z-index: 1; width: min(1120px, 100% - 40px); margin: 0 auto; }
.wrap.narrow { width: min(760px, 100% - 40px); }
.sec { position: relative; padding: 76px 0; overflow: hidden; }

/* ---------- Reveal ---------- */
[data-reveal] { opacity: 0; transform: translateY(24px); transition: opacity .9s var(--ease), transform .9s var(--ease); }
[data-reveal].is-in { opacity: 1; transform: none; }
.rise { opacity: 0; transform: translateY(18px); }
.is-open .rise { opacity: 1; transform: none; transition: opacity 1s var(--ease), transform 1s var(--ease); }
.is-open .hero .pillaiyar { transition-delay: .05s; }
.is-open .hero .blessing { transition-delay: .12s; }
.is-open .hero .greet { transition-delay: .2s; }
.is-open .hero .hero-kick { transition-delay: .28s; }
.is-open .hero .hero-ring { transition-delay: .18s; }
.is-open .hero .hero-names { transition-delay: .45s; }
.is-open .hero .hero-date { transition-delay: .6s; }
.is-open .hero .hero-city { transition-delay: .7s; }

/* ---------- Kolam (self-drawing) ---------- */
.kolam { display: block; overflow: visible; }
.kolam .kl {
  fill: none; stroke: currentColor; stroke-width: .2; stroke-linecap: round; stroke-linejoin: round;
  stroke-dasharray: 1 1; stroke-dashoffset: 1; opacity: 0;
  transition: stroke-dashoffset 2.6s cubic-bezier(.45, .05, .35, 1) calc(var(--k, 0) * .22s + .35s), opacity .01s linear calc(var(--k, 0) * .22s + .35s);
}
.kolam .kd { fill: currentColor; opacity: 0; transform: scale(0); transform-box: fill-box; transform-origin: center; transition: opacity .3s, transform .45s cubic-bezier(.3, 1.6, .6, 1); }
.is-in .kolam .kl, .is-open .hero .kolam .kl { stroke-dashoffset: 0; opacity: 1; }
.is-in .kolam .kd, .is-open .hero .kolam .kd { opacity: 1; transform: none; }

/* ---------- Brass lamp ---------- */
.lamp { display: block; overflow: visible; }
.lamp .lp-rim { fill: #7A5418; }
.lamp .lp-oil { fill: #3D240A; }
.lp-shade { opacity: .6; transition: opacity 1.8s ease .25s; }
.lp-shade * { fill: #0E0406; }
.lamp.is-lit .lp-shade { opacity: 0; }
.fl-halo { opacity: 0; transition: opacity 1s ease; }
.fl.on .fl-halo { opacity: 1; }
.fl-glow { transform-box: fill-box; transform-origin: center; animation: glow 2.4s ease-in-out infinite alternate; }
.fl-pop { opacity: 0; transform: scale(0, .2); transform-box: fill-box; transform-origin: 50% 100%; }
.fl.on .fl-pop { opacity: 1; transform: none; transition: transform .55s cubic-bezier(.3, 1.7, .5, 1), opacity .15s; }
.fl-flick, .dy-fl { transform-box: fill-box; transform-origin: 50% 100%; animation: flick 1.3s ease-in-out infinite alternate; }
.fl:not(.on) .fl-flick, .fl:not(.on) .fl-glow { animation-play-state: paused; }
@keyframes flick {
  0% { transform: scale(1, 1) rotate(-1.6deg); }
  35% { transform: scale(.93, 1.08) rotate(1.2deg); }
  70% { transform: scale(1.05, .95) rotate(-.6deg); }
  100% { transform: scale(.97, 1.05) rotate(1.8deg); }
}
@keyframes glow { from { opacity: .75; transform: scale(.94); } to { opacity: 1; transform: scale(1.06); } }
.diya { display: block; overflow: visible; }

/* ---------- Intro: light the kuthuvilakku ---------- */
.intro {
  position: fixed; inset: 0; z-index: 100; overflow: hidden; cursor: pointer;
  display: grid; grid-template-rows: auto minmax(0, 1fr) auto; justify-items: center; align-items: center; gap: 10px;
  padding: calc(30px + env(safe-area-inset-top)) 20px calc(28px + env(safe-area-inset-bottom));
  text-align: center; color: var(--gold-l);
  background: radial-gradient(ellipse 75% 60% at 50% 52%, #2B0C11 0%, #15070A 58%, #080304 100%);
  -webkit-tap-highlight-color: transparent;
}
.intro::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(circle, rgba(232, 185, 90, .16) 0 1.2px, transparent 1.8px) 0 0 / 26px 26px;
  -webkit-mask: radial-gradient(ellipse 70% 60% at 50% 50%, #000 15%, transparent 75%);
  mask: radial-gradient(ellipse 70% 60% at 50% 50%, #000 15%, transparent 75%);
}
.in-aura, .in-flood { position: absolute; left: 50%; top: 42%; border-radius: 50%; pointer-events: none; }
.in-aura {
  width: 130vmin; height: 130vmin; margin: -65vmin 0 0 -65vmin;
  background: radial-gradient(circle, rgba(255, 196, 92, .45), rgba(255, 140, 50, .16) 34%, transparent 64%);
  opacity: 0; transform: scale(.35); transition: opacity 1.6s ease, transform 2s var(--ease);
}
.is-lighting .in-aura { opacity: 1; transform: none; }
.in-flood {
  z-index: 3; width: 60vmax; height: 60vmax; margin: -30vmax 0 0 -30vmax;
  background: radial-gradient(circle, #FFF8E4 0%, #FFE9A6 20%, #F8C35C 40%, rgba(214, 112, 40, .7) 56%, rgba(110, 24, 22, 0) 70%);
  opacity: 0; transform: scale(.04); will-change: transform, opacity;
}
.is-flood .in-flood { opacity: 1; transform: scale(4.4); transition: transform 1.3s cubic-bezier(.55, 0, .55, 1), opacity .45s ease; }
.intro.is-gone { opacity: 0; transition: opacity .95s ease; pointer-events: none; }

.in-top, .in-lamp, .in-bot { position: relative; z-index: 1; }
.in-top { transition: opacity .8s ease; }
.in-kick { margin: 0; font: 600 15px/1.6 var(--f-text); color: var(--turmeric); opacity: .9; }
.in-names { margin: 4px 0 0; font: 700 clamp(30px, 8.6vw, 46px)/1.35 var(--f-disp); color: var(--gold-l); text-shadow: 0 0 24px rgba(255, 190, 90, .25); }
.in-names i { font-style: normal; font-size: .55em; color: var(--turmeric); vertical-align: .2em; }
.in-lamp { height: min(52vh, 470px); aspect-ratio: 240 / 420; max-width: 80vw; }
.lamp--intro { width: 100%; height: 100%; filter: drop-shadow(0 18px 30px rgba(0, 0, 0, .55)); }
.in-spark {
  position: absolute; left: 8.75%; top: 29.4%; width: 16px; height: 16px; margin: -8px 0 0 -8px; border-radius: 50%;
  background: radial-gradient(circle, #FFF0B8 0 18%, rgba(255, 186, 72, .65) 40%, transparent 70%);
  animation: spark 1.8s ease-in-out infinite;
}
@keyframes spark { 0%, 100% { opacity: .35; transform: scale(.7); } 50% { opacity: 1; transform: scale(1.25); } }
.in-bot { display: grid; justify-items: center; gap: 12px; transition: opacity .4s ease; }
.in-hint { margin: 0; font: 400 16px/1.5 var(--f-hand); color: rgba(244, 220, 148, .85); animation: hint 2.6s ease-in-out infinite; }
@keyframes hint { 0%, 100% { opacity: .6; } 50% { opacity: 1; } }
.in-btn {
  display: inline-flex; align-items: center; gap: 10px; min-height: 50px; padding: 10px 26px 10px 18px; border: 0; border-radius: 999px; cursor: pointer;
  font: 600 16px/1.2 var(--f-text); color: var(--maroon-d);
  background: linear-gradient(180deg, #FBE7AA, #D8A845 58%, #A9792A);
  box-shadow: 0 10px 30px rgba(255, 170, 60, .18), 0 6px 16px rgba(0, 0, 0, .5), inset 0 1px 0 rgba(255, 255, 255, .6);
}
.in-btn .diya { width: 26px; height: 24px; }
.is-lighting .in-bot, .is-lighting .in-spark { opacity: 0; }
.is-lighting { cursor: default; }
.greet { display: grid; justify-items: center; margin: 0 0 14px; font: 400 15px/1.5 var(--f-hand); color: rgba(244, 220, 148, .85); }
.greet b { font: 400 clamp(22px, 6vw, 28px)/1.4 var(--f-hand); color: #FFF3CF; }

/* ---------- Hero ---------- */
.hero {
  position: relative; overflow: hidden; text-align: center; color: var(--gold-l);
  padding: 108px 24px 74px;
  background:
    radial-gradient(ellipse 85% 55% at 50% 45%, rgba(170, 40, 40, .42), transparent 70%),
    radial-gradient(circle, rgba(232, 185, 90, .17) 0 1.2px, transparent 1.8px) 0 0 / 22px 22px,
    radial-gradient(circle, rgba(232, 185, 90, .1) 0 1px, transparent 1.6px) 11px 11px / 22px 22px,
    linear-gradient(180deg, #3E0910, #5A0F17 45%, #4A0C13);
}
.hero > .karai { position: absolute; left: 0; right: 0; bottom: 0; }
.thoranam { position: absolute; z-index: 3; top: 0; left: 0; right: 0; height: 96px; overflow: hidden; pointer-events: none; }
.th-cord {
  position: absolute; top: 9px; left: 0; right: 0; height: 7px;
  background: repeating-linear-gradient(115deg, #E8BD5A 0 4px, #8C5E1C 4px 7px);
  box-shadow: 0 2px 4px rgba(0, 0, 0, .4);
}
.th-row { position: absolute; top: 11px; left: 50%; display: flex; width: max-content; transform: translateX(-50%); }
.th-l, .th-f { display: block; flex: none; width: 20px; margin: 0 -.5px; transform-origin: 50% 0; animation: sway var(--t, 3s) ease-in-out var(--d, 0s) infinite alternate; }
.th-l svg { display: block; width: 20px; height: 74px; }
.th-f svg { display: block; width: 20px; height: 60px; overflow: visible; }
@keyframes sway { from { transform: rotate(-5deg); } to { transform: rotate(5deg); } }
.strands { position: absolute; z-index: 2; top: 14px; display: flex; gap: 4px; pointer-events: none; }
.strands--l { left: 0; }
.strands--r { right: 0; }
.strands svg { display: block; width: 22px; overflow: visible; transform-origin: 50% 0; animation: sway2 6s ease-in-out infinite alternate; }
.strands svg + svg { animation-duration: 7.4s; animation-delay: -2.6s; }
@keyframes sway2 { from { transform: rotate(2.4deg); } to { transform: rotate(-2.4deg); } }
@media (max-width: 599px) { .strands svg + svg, .strands--r svg:first-child { display: none; } .strands--r svg + svg { display: block; } }

.hero-in { position: relative; z-index: 1; max-width: 1180px; margin: 0 auto; display: grid; justify-items: center; }
.pillaiyar { margin: 0; font: 600 24px/1 var(--f-text); color: var(--turmeric); }
.blessing { margin: 6px 0 16px; font: 600 16px/1.6 var(--f-text); color: #F6D77E; }
.hero-kick { display: flex; align-items: center; justify-content: center; gap: 12px; margin: 0 0 12px; font: 600 15px/1.6 var(--f-text); color: var(--turmeric); }
.hero-kick i { width: 34px; height: 1px; background: linear-gradient(90deg, transparent, var(--gold)); }
.hero-kick i:last-child { transform: scaleX(-1); }
.hero-ring { --rw: min(68vw, 280px); }
.hero-names { margin: 6px 0 0; font: 700 clamp(46px, 14vw, 84px)/1.28 var(--f-disp); }
.hero-names .nm, .close-names .nm {
  display: block; color: #F4D27A;
  background: linear-gradient(180deg, #FFF3CB 12%, #F2C766 55%, #C38A2A 92%); -webkit-background-clip: text; background-clip: text; -webkit-text-fill-color: transparent;
}
.nm-join { display: flex; align-items: center; justify-content: center; gap: 10px; height: .5em; }
.nm-join i { display: block; width: 46px; height: 1px; background: linear-gradient(90deg, transparent, #E2B552); }
.nm-join i:last-child { transform: scaleX(-1); }
.nm-join svg { width: 22px; height: 22px; flex: none; }
.hero-date { display: grid; margin: 16px 0 0; color: #FBEBC4; }
.hero-date span { font: 400 16px/1.5 var(--f-hand); color: var(--turmeric-l); }
.hero-date b { font: 600 20px/1.5 var(--f-text); }
.hero-city { margin: 2px 0 0; font-size: 15px; color: rgba(244, 220, 148, .75); }
.scroll-cue { position: relative; z-index: 2; display: grid; justify-items: center; gap: 4px; margin: 26px auto 0; padding: 6px 12px; border: 0; background: none; cursor: pointer; }
.scroll-cue .diya { width: 32px; height: 29px; }
.scroll-cue i { display: block; width: 1px; height: 30px; background: linear-gradient(var(--gold-l), transparent); transform-origin: top; animation: cue 2.2s ease-in-out infinite; }
@keyframes cue { 0% { transform: scaleY(0); opacity: 1; } 60% { transform: scaleY(1); opacity: 1; } 100% { transform: scaleY(1); opacity: 0; } }

@media (min-width: 960px) {
  .hero { min-height: 100vh; min-height: 100svh; display: grid; align-content: center; padding: 130px 56px 96px; }
  .hero-in {
    width: 100%; grid-template-columns: minmax(0, 1fr) minmax(0, 1.1fr); grid-template-areas: "ring top" "ring bot";
    column-gap: 72px; justify-items: start; text-align: left;
  }
  .hero-ring { grid-area: ring; justify-self: end; align-self: center; --rw: min(34vw, 430px); }
  .hero-top { grid-area: top; align-self: end; }
  .hero-bot { grid-area: bot; align-self: start; }
  .hero-kick { justify-content: flex-start; }
  .hero-kick i:first-child { display: none; }
  .hero .greet { justify-items: start; }
  .hero .nm-join { justify-content: flex-start; }
  .hero .nm-join i:first-child { display: none; }
  .hero .nm-join i:last-child { width: 150px; transform: none; background: linear-gradient(90deg, #E2B552, transparent); }
  .pillaiyar { font-size: 28px; }
  .blessing { font-size: 18px; }
  .hero-kick { font-size: 17px; }
  .hero-date span { font-size: 18px; }
  .hero-date b { font-size: 24px; }
  .scroll-cue { margin-top: 40px; }
}

/* ---------- Garland ring ---------- */
.ring { position: relative; width: var(--rw, 260px); aspect-ratio: 208 / 264; }
.ring .garland { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; filter: drop-shadow(0 6px 10px rgba(0, 0, 0, .3)); }
.ring-photo {
  position: absolute; left: 17.31%; top: 13.64%; width: 65.38%; aspect-ratio: 1; border-radius: 50%; overflow: hidden;
  background: radial-gradient(circle at 50% 38%, #7A1A22, #3A070D 80%);
  box-shadow: 0 0 0 3px #E2B552, 0 0 0 6px #6B1218, 0 14px 30px rgba(0, 0, 0, .45);
}
.ring-photo img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ring-mono { position: absolute; inset: 0; display: grid; place-items: center; }
.ring-mono .kolam { position: absolute; inset: 9%; width: 82%; height: 82%; color: rgba(244, 220, 148, .5); }
.ring-mono b { position: relative; font: 700 clamp(30px, 9vw, 52px)/1 var(--f-disp); color: var(--gold-l); text-shadow: 0 2px 6px rgba(0, 0, 0, .5); }
.gf { transform-box: fill-box; transform-origin: center; transform: scale(0); transition: transform .55s cubic-bezier(.3, 1.6, .6, 1) calc(var(--i, 0) * 28ms + .25s); }
.is-open .hero .gf, .is-in .gf { transform: none; }

/* ---------- Temple border (koyil karai) ---------- */
.karai { height: 22px; background: #4A0C13 var(--karai) repeat-x center / 24px 22px; }
.karai--top { transform: scaleY(-1); }

/* ---------- Section heading ---------- */
.sh { max-width: 640px; margin: 0 auto 40px; text-align: center; }
.sh-kolam { width: 150px; margin: 0 auto 8px; color: var(--kumkum); }
.sh-kolam .kolam { width: 100%; height: auto; }
.sh-kolam .kl { stroke-width: .22; }
.sh-kick { margin: 0; font: 400 17px/1.5 var(--f-hand); color: #A2671A; }
.sh-title { margin: 2px 0 0; font: 700 clamp(30px, 8vw, 46px)/1.4 var(--f-disp); color: var(--maroon); }
.sh--light .sh-kolam { color: var(--turmeric); }
.sh--light .sh-kick { color: var(--turmeric-l); }
.sh--light .sh-title { color: var(--gold-l); }

/* ---------- Buttons ---------- */
.btns { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 22px; }
.btns--c { justify-content: center; }
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 46px; padding: 10px 20px;
  border: 1.5px solid transparent; border-radius: 999px; cursor: pointer; text-decoration: none;
  font: 600 15px/1.25 var(--f-text); transition: transform .2s ease, opacity .2s ease;
}
.btn:active, .chip:active, .fab:active, .gal-btn:active { transform: scale(.96); }
.ico { width: 18px; height: 18px; flex: none; }
.btn--gold { color: var(--maroon-d); background: linear-gradient(180deg, #F9E4A4, #D8A845 60%, #B4832D); box-shadow: 0 6px 18px rgba(0, 0, 0, .25), inset 0 1px 0 rgba(255, 255, 255, .6); }
.btn--maroon { color: #FBEBC4; background: var(--maroon); box-shadow: 0 6px 16px rgba(90, 15, 23, .25); }
.btn--line { color: inherit; background: transparent; border-color: currentColor; }
.btn--wa { color: #fff; background: #1E7A45; box-shadow: 0 6px 16px rgba(20, 90, 50, .22); }
.btn--sm { min-height: 42px; padding: 8px 14px; font-size: 14px; }

/* ---------- Invitation card (pathirigai) ---------- */
.invite { background: radial-gradient(ellipse at 50% 0, #FFFDF6, var(--cream) 60%); padding-bottom: 56px; }
.patra {
  position: relative; max-width: 680px; margin: 0 auto; padding: 46px 26px 44px; text-align: center; border-radius: 6px;
  background:
    radial-gradient(ellipse 74px 58px at 0 0, rgba(242, 178, 24, .9), rgba(242, 178, 24, .4) 52%, transparent 74%),
    radial-gradient(ellipse 36px 62px at 18px 8px, rgba(226, 142, 10, .35), transparent 70%),
    radial-gradient(ellipse 74px 58px at 100% 0, rgba(242, 178, 24, .9), rgba(242, 178, 24, .4) 52%, transparent 74%),
    radial-gradient(ellipse 62px 36px at calc(100% - 8px) 20px, rgba(226, 142, 10, .3), transparent 70%),
    radial-gradient(ellipse 74px 58px at 0 100%, rgba(242, 178, 24, .9), rgba(242, 178, 24, .4) 52%, transparent 74%),
    radial-gradient(ellipse 74px 58px at 100% 100%, rgba(242, 178, 24, .9), rgba(242, 178, 24, .4) 52%, transparent 74%),
    radial-gradient(ellipse 34px 58px at calc(100% - 16px) calc(100% - 8px), rgba(226, 142, 10, .32), transparent 70%),
    #FFFBF0;
  box-shadow: 0 22px 50px rgba(90, 40, 10, .14), 0 2px 6px rgba(90, 40, 10, .08);
}
.patra::before, .patra::after { content: ""; position: absolute; border: 1px solid rgba(176, 124, 36, .5); border-radius: 3px; pointer-events: none; }
.patra::before { inset: 12px; }
.patra::after { inset: 17px; border-color: rgba(176, 124, 36, .3); }
.pottu { display: block; width: 26px; height: 26px; margin: 0 auto 14px; border-radius: 50%; background: radial-gradient(circle, #C21E2A 0 32%, #F0AE18 35% 60%, rgba(240, 174, 24, 0) 64%); }
.patra-kolam { width: min(190px, 52vw); margin: 0 auto 18px; }
.patra-kolam .kl { stroke-width: .17; }
.patra-hello { margin: 0 0 10px; font: 400 22px/1.5 var(--f-hand); color: var(--maroon); }
.patra-msg { margin: 0 auto; max-width: 540px; font-size: 17px; line-height: 2.05; color: var(--text); }
@media (min-width: 700px) { .patra { padding: 56px 48px 50px; } .patra-msg { font-size: 18px; } }
.patra-sign { margin: 22px 0 0; font: 600 20px/1.4 var(--f-disp); color: var(--kumkum); }

/* ---------- Couple ---------- */
.couple { background: linear-gradient(180deg, var(--cream), #F6E9CC); }
.pr-grid { display: grid; justify-items: center; gap: 18px; text-align: center; }
.pr { max-width: 380px; }
.pr-ring .ring { --rw: 220px; margin: 0 auto; }
.ring--sm .ring-mono b { font-size: 54px; }
.pr-role { margin: 6px 0 0; font: 400 18px/1.4 var(--f-hand); color: #A2671A; }
.pr-name { margin: 2px 0 6px; font: 700 clamp(28px, 7.6vw, 38px)/1.35 var(--f-disp); color: var(--maroon); }
.pr-par { margin: 0; font-size: 15px; line-height: 1.85; color: var(--muted); }
.pr-mid .lamp { width: 74px; height: auto; }
@media (min-width: 860px) {
  .pr-grid { grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: start; gap: 48px; }
  .pr-grid.is-one { grid-template-columns: 1fr; }
  .pr-mid { align-self: center; }
  .pr-mid .lamp { width: 120px; }
  .pr-ring .ring { --rw: 250px; }
}

/* ---------- Muhurtham (banana leaf + brass plate) ---------- */
.mu {
  padding: 84px 0 100px; color: #F7EBD0;
  background:
    repeating-linear-gradient(103deg, rgba(255, 255, 255, .05) 0 1.5px, transparent 1.5px 14px),
    linear-gradient(180deg, rgba(0, 0, 0, .28), transparent 26%, transparent 72%, rgba(0, 0, 0, .32)),
    radial-gradient(ellipse 80% 60% at 50% 40%, #3D8443, #215A2C 66%, #173F20);
  box-shadow: inset 0 4px 0 var(--gold);
}
.banana { position: absolute; bottom: -12px; z-index: 0; display: none; height: 280px; width: auto; aspect-ratio: 200 / 480; pointer-events: none; opacity: .92; transform-origin: 50% 100%; }
.banana--l { left: -78px; animation: plantL 7s ease-in-out infinite alternate; }
.banana--r { right: -78px; transform: scaleX(-1); animation: plantR 8s ease-in-out infinite alternate; }
@keyframes plantL { from { transform: rotate(-1.2deg); } to { transform: rotate(1.2deg); } }
@keyframes plantR { from { transform: scaleX(-1) rotate(-1.2deg); } to { transform: scaleX(-1) rotate(1.2deg); } }
.mu-grid { display: grid; justify-items: center; gap: 30px; }
.mu-plate-wrap { position: relative; width: min(290px, 76vw); aspect-ratio: 1; display: grid; place-items: center; }
.betel { position: absolute; inset: -11%; width: 122%; height: 122%; overflow: visible; filter: drop-shadow(0 4px 6px rgba(0, 0, 0, .3)); }
.betel use { transform-box: fill-box; transform-origin: 50% 100%; transform: scale(0); transition: transform .7s cubic-bezier(.3, 1.4, .6, 1) calc(var(--i, 0) * 60ms + .2s); }
.is-in .betel use { transform: none; }
.mu-plate {
  position: relative; width: 78%; aspect-ratio: 1; border-radius: 50%; display: grid; place-content: center; text-align: center; color: var(--maroon-d);
  background: radial-gradient(circle at 36% 30%, #FFF6D2 0%, #F3D482 20%, #D2A341 46%, #A8782A 70%, #E0B652 85%, #7A5418 100%);
  box-shadow: 0 20px 44px rgba(0, 0, 0, .5), inset 0 0 0 3px rgba(255, 240, 190, .45), inset 0 -12px 26px rgba(90, 50, 10, .35);
}
.mu-plate::before, .mu-plate::after { content: ""; position: absolute; border-radius: 50%; pointer-events: none; }
.mu-plate::before { inset: 8%; border: 1.5px solid rgba(110, 70, 20, .45); box-shadow: inset 0 0 0 5px rgba(255, 236, 170, .22); }
.mu-plate::after { inset: 14%; border: 2px dotted rgba(110, 70, 20, .45); }
.mu-wd { position: relative; font: 600 14px/1.3 var(--f-text); }
.mu-day { position: relative; margin: 2px 0; font: 700 clamp(68px, 20vw, 92px)/1 var(--f-disp); color: var(--maroon); text-shadow: 0 1px 0 rgba(255, 245, 210, .6); }
.mu-my { position: relative; font: 600 15px/1.3 var(--f-text); }
.mu-info { max-width: 540px; text-align: center; }
.mu-time { margin: 0; font: 700 clamp(22px, 6.3vw, 36px)/1.4 var(--f-disp); color: var(--turmeric-l); text-wrap: balance; }
.mu-tdate { margin: 14px 0 0; }
.mu-tdate span {
  display: inline-block; padding: 10px 28px; color: var(--maroon); font: 400 17px/1.6 var(--f-hand);
  background: linear-gradient(180deg, #FFF6DC, #F3E2B4);
  clip-path: polygon(0 0, 100% 0, calc(100% - 12px) 50%, 100% 100%, 0 100%, 12px 50%);
}
.mu-note { margin: 14px auto 0; max-width: 440px; font-size: 16px; line-height: 1.85; color: rgba(247, 235, 208, .92); }
.mu-venue { display: flex; align-items: flex-start; justify-content: center; gap: 8px; margin: 16px 0 0; font: 600 17px/1.55 var(--f-text); color: #FFF6DE; }
.mu-venue .ico { margin-top: 4px; color: var(--turmeric-l); }
.mu-venue small { display: block; font-weight: 400; font-size: 14px; opacity: .8; }
.mu .btns { justify-content: center; }
.mu .btn--line { color: var(--gold-l); border-color: rgba(244, 220, 148, .6); }
@media (min-width: 900px) {
  .mu { padding: 110px 0 120px; }
  .banana { display: block; height: 560px; }
  .banana--l { left: -36px; }
  .banana--r { right: -36px; }
  .mu-grid { grid-template-columns: auto minmax(0, 1fr); gap: 72px; align-items: center; max-width: 900px; margin: 0 auto; }
  .mu-grid.is-one { grid-template-columns: 1fr; }
  .mu-grid:not(.is-one) .mu-info { text-align: left; }
  .mu-grid:not(.is-one) .mu-venue, .mu-grid:not(.is-one) .btns { justify-content: flex-start; }
  .mu-plate-wrap { width: 330px; }
}

/* ---------- Countdown ---------- */
.cd { position: relative; text-align: center; color: var(--gold-l); background: radial-gradient(ellipse at 50% 30%, #701621, #4A0C13 60%, #33060C); }
.cd .wrap { padding: 52px 0 56px; }
.cd-kick { margin: 0; font: 400 17px/1.5 var(--f-hand); color: var(--turmeric-l); }
.cd-title { margin: 2px 0 26px; font: 700 clamp(24px, 6.6vw, 34px)/1.45 var(--f-disp); }
.cd-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; max-width: 580px; margin: 0 auto; }
.cd-u { display: grid; justify-items: center; }
.cd-u .diya { width: 30px; height: 27px; margin-bottom: 2px; }
.cd-u b { font: 700 clamp(34px, 10.5vw, 56px)/1.1 var(--f-disp); color: #FFF1C9; font-variant-numeric: tabular-nums; }
.cd-u span { font-size: 13px; line-height: 1.6; color: rgba(244, 220, 148, .85); }
.cd-done { margin: 0; font: 600 20px/1.6 var(--f-disp); }

/* ---------- Olai chuvadi (palm-leaf manuscript) ---------- */
.olai { background: radial-gradient(ellipse at 50% 0, rgba(255, 252, 240, .7), transparent 60%), linear-gradient(180deg, #F4E6C6, #EAD6AA); }
.bundle { --cx: 46px; position: relative; max-width: 780px; margin: 0 auto; }
.cord { position: absolute; left: var(--cx); top: 12px; bottom: 12px; width: 4px; margin-left: -2px; border-radius: 2px; z-index: 0; background: repeating-linear-gradient(165deg, #C8202F 0 5px, #8E0F1C 5px 8px); }
.board {
  position: relative; z-index: 2; height: 26px; margin: 0 8px; border-radius: 9px;
  background: linear-gradient(180deg, #84512A, #4E2C12);
  box-shadow: inset 0 1px 0 rgba(255, 220, 170, .35), 0 6px 14px rgba(60, 30, 10, .3);
}
.board::after { content: ""; position: absolute; inset: 6px 16px; border: 1px solid rgba(255, 210, 150, .22); border-radius: 4px; }
.board::before { content: ""; position: absolute; z-index: 1; top: 0; bottom: 0; left: calc(var(--cx) - 10px); width: 4px; background: linear-gradient(90deg, #8E0F1C, #D02736, #8E0F1C); }
.knot { position: absolute; z-index: 2; left: calc(var(--cx) - 15px); top: -6px; width: 14px; height: 14px; border-radius: 50%; background: radial-gradient(circle at 40% 35%, #E04050, #9E1222); box-shadow: 0 1px 3px rgba(0, 0, 0, .4); }
.knot::before, .knot::after { content: ""; position: absolute; top: -3px; width: 17px; height: 10px; border: 3px solid #B3162A; border-radius: 50%; }
.knot::before { right: 10px; transform: rotate(-24deg); }
.knot::after { left: 10px; transform: rotate(24deg); }
.leaves { position: relative; z-index: 1; display: grid; gap: 14px; margin: 0; padding: 14px 0; list-style: none; }
.leaf {
  position: relative; display: flex; align-items: center; gap: 12px; min-height: 120px; padding: 20px 16px 20px 74px;
  border-radius: 46px / 50%; color: var(--ink);
  background:
    repeating-linear-gradient(180deg, rgba(120, 80, 30, .07) 0 1px, transparent 1px 6px),
    linear-gradient(180deg, #EFDCAD 0%, #E3C88F 45%, #D3AF6C 100%);
  box-shadow: inset 0 0 0 1px rgba(120, 80, 30, .3), inset 0 -9px 14px rgba(140, 90, 30, .18), inset 0 6px 10px rgba(255, 248, 222, .55), 0 6px 14px rgba(90, 55, 20, .2);
}
.leaf[data-reveal] { transform: translateX(-28px) rotate(-1.2deg); }
.leaf--r[data-reveal] { transform: translateX(28px) rotate(1.2deg); }
.leaf[data-reveal].is-in { transform: none; }
.hole {
  position: absolute; left: calc(var(--cx) - 10px); top: 50%; width: 20px; height: 20px; margin-top: -10px; border-radius: 50%;
  background: linear-gradient(90deg, transparent 8px, #B3162A 8px 12px, transparent 12px), #4A2E10;
  box-shadow: inset 0 2px 4px rgba(30, 15, 0, .7), 0 1px 0 rgba(255, 245, 215, .6);
}
.leaf-body { flex: 1; min-width: 0; }
.leaf-when { margin: 0; font: 400 15px/1.55 var(--f-hand); color: #6E4616; text-shadow: 0 1px 0 rgba(255, 246, 220, .7); }
.leaf-when span { display: block; }
.leaf-name { margin: 2px 0 2px; font: 700 clamp(23px, 6.4vw, 30px)/1.3 var(--f-disp); color: #3A1E08; text-shadow: 0 1px 0 rgba(255, 246, 220, .8), 0 -1px 0 rgba(90, 50, 10, .3); }
.leaf-at { margin: 0; font-size: 14.5px; line-height: 1.6; color: #5A3A18; }
.leaf-note { margin: 3px 0 0; font: 400 15px/1.55 var(--f-hand); color: #6E4616; }
.leaf-cal { flex: none; display: grid; place-items: center; width: 42px; height: 42px; border-radius: 50%; color: var(--maroon); border: 1.5px solid rgba(90, 15, 23, .35); background: rgba(255, 249, 228, .55); }
.leaf--main { background: repeating-linear-gradient(180deg, rgba(120, 80, 30, .07) 0 1px, transparent 1px 6px), linear-gradient(180deg, #F6E4B4 0%, #EBCD8A 45%, #D9AE5E 100%); box-shadow: inset 0 0 0 1.5px rgba(179, 22, 42, .45), inset 0 -9px 14px rgba(140, 90, 30, .2), inset 0 6px 10px rgba(255, 248, 222, .6), 0 10px 24px rgba(120, 40, 20, .25); }
.seal {
  position: absolute; right: 8px; top: -16px; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center;
  font: 700 13px/1 var(--f-disp); color: #FCE3A6; transform: rotate(-12deg);
  background: radial-gradient(circle at 40% 35%, #D83B3B, #9E1222 70%);
  box-shadow: 0 3px 8px rgba(90, 10, 10, .4), inset 0 0 0 3px rgba(255, 200, 150, .25);
}
.board--b { margin-top: 0; }
@media (min-width: 760px) {
  .leaf { padding: 22px 28px 22px 92px; min-height: 128px; border-radius: 64px / 50%; }
  .bundle { --cx: 62px; }
}

/* ---------- Dress code (silk border) ---------- */
.dress { position: relative; background: var(--maroon); }
.dress::before, .dress::after { content: ""; position: absolute; left: 0; right: 0; height: 22px; background: var(--karai) repeat-x center / 24px 22px; }
.dress::before { top: 0; transform: scaleY(-1); }
.dress::after { bottom: 0; }
.dress-in {
  padding: 58px 24px; text-align: center; color: var(--gold-l);
  background: radial-gradient(circle, rgba(232, 185, 90, .2) 0 1.2px, transparent 1.8px) 0 0 / 18px 18px, radial-gradient(ellipse at 50% 50%, #761824, var(--maroon) 70%);
}
.dress-k { margin: 0; font: 400 17px/1.5 var(--f-hand); color: var(--turmeric-l); }
.dress-v { margin: 4px 0 0; font: 700 clamp(24px, 6.8vw, 36px)/1.45 var(--f-disp); }

/* ---------- Venue ---------- */
.venue { background: var(--cream); }
.vn-grid { display: grid; gap: 22px; }
.vn-card { padding: 30px 22px; text-align: center; border-radius: 12px; background: #FFFBF1; border: 1px solid rgba(180, 130, 40, .32); box-shadow: 0 14px 40px rgba(90, 40, 10, .1); }
.gopuram { display: block; width: 124px; height: auto; margin: 0 auto; color: var(--kumkum); overflow: visible; }
.gp { fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; stroke-dasharray: 1 1; stroke-dashoffset: 1; transition: stroke-dashoffset 1.5s ease calc(var(--k, 0) * .12s + .2s); }
.is-in .gp { stroke-dashoffset: 0; }
.gp-dots { fill: var(--gold); }
.vn-name { margin: 12px 0 6px; font: 700 clamp(24px, 6.6vw, 32px)/1.4 var(--f-disp); color: var(--maroon); }
.vn-addr { margin: 0; font-size: 16px; line-height: 1.85; }
.vn-city { margin: 2px 0 0; font-weight: 600; }
.vn-note { margin: 16px auto 0; max-width: 460px; padding: 12px 16px; border-radius: 8px; background: #F6EACB; font-size: 14.5px; line-height: 1.85; color: #5A3A18; }
.vn-card .btns { justify-content: center; }
.vn-map { position: relative; padding: 8px; border-radius: 12px; background: linear-gradient(135deg, #F7E3A1, #C99A3B 35%, #8C6420 60%, #E9C46A); box-shadow: 0 14px 40px rgba(90, 40, 10, .2); }
.vn-map iframe { display: block; width: 100%; height: 320px; border: 0; border-radius: 6px; background: #EADBB8; }
@media (min-width: 900px) {
  .vn-grid { grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: 32px; }
  .vn-grid.is-one { grid-template-columns: minmax(0, 640px); justify-content: center; }
  .vn-card { display: flex; flex-direction: column; justify-content: center; padding: 40px 36px; }
  .vn-map iframe { height: 100%; min-height: 440px; }
}

/* ---------- Gallery: brass rail ---------- */
.gal { color: var(--gold-l); background: radial-gradient(ellipse at 50% 0, #6E1520, #3A070D 70%); padding-bottom: 64px; }
.gal-stage { position: relative; }
.rail {
  position: relative; z-index: 2; height: 14px;
  background: radial-gradient(circle, #FFF2C0 0 1.5px, #8C6420 2.1px, transparent 2.7px) 0 50% / 22px 14px repeat-x, linear-gradient(180deg, #F7E09A, #C99A3B 45%, #7A5418);
  box-shadow: 0 3px 8px rgba(0, 0, 0, .45);
}
.gal-track {
  --gw: min(64vw, 290px);
  position: relative; display: flex; gap: 18px; margin: 0; padding: 34px calc(50% - var(--gw) / 2) 30px; list-style: none;
  overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x mandatory; scrollbar-width: none; -webkit-overflow-scrolling: touch;
}
.gal-track::-webkit-scrollbar { display: none; }
.gal-track:focus-visible { outline-offset: -4px; }
.gal-cell { flex: 0 0 var(--gw); scroll-snap-align: center; }
.gal-item {
  position: relative; display: block; width: 100%; padding: 7px; border: 0; border-radius: 10px 10px 6px 6px; cursor: zoom-in;
  background: linear-gradient(135deg, #FBE9B0, #C99A3B 30%, #8C6420 55%, #E9C46A 80%, #9C6E22);
  box-shadow: 0 16px 30px rgba(0, 0, 0, .5), inset 0 0 0 1px rgba(255, 240, 200, .5);
}
.gal-item::before, .gal-item::after { content: ""; position: absolute; top: -34px; width: 2px; height: 34px; background: repeating-linear-gradient(180deg, #F0D07A 0 3px, #8C6420 3px 5px); }
.gal-item::before { left: 22%; }
.gal-item::after { right: 22%; }
.gal-in { display: block; aspect-ratio: 3 / 4; overflow: hidden; border-radius: 4px; border: 2px solid #4A0C13; background: #2A0508; }
.gal-in img { display: block; width: 100%; height: 100%; object-fit: cover; }
.gal-nav { display: flex; align-items: center; justify-content: center; gap: 18px; margin-top: 20px; }
.gal-btn { width: 46px; height: 46px; display: grid; place-items: center; border-radius: 50%; border: 1.5px solid rgba(244, 220, 148, .55); background: rgba(0, 0, 0, .2); color: var(--gold-l); cursor: pointer; }
.gal-count { min-width: 60px; text-align: center; font: 600 16px var(--f-disp); }
@media (min-width: 900px) { .gal-track { --gw: 300px; gap: 30px; } }

/* ---------- Story ---------- */
.story { background: var(--cream); }
.st-list { position: relative; margin: 0; padding: 0 0 0 40px; list-style: none; }
.st-list::before { content: ""; position: absolute; left: 14px; top: 10px; bottom: 16px; border-left: 2px dotted rgba(179, 22, 42, .45); }
.st { position: relative; padding: 0 0 30px; }
.st-dot { position: absolute; left: -41px; top: 2px; padding: 2px; background: var(--cream); }
.st-dot .diya { width: 28px; height: 25px; }
.st-when { margin: 0; font: 400 15px/1.5 var(--f-hand); color: #A2671A; }
.st-title { margin: 2px 0 4px; font: 700 22px/1.4 var(--f-disp); color: var(--maroon); }
.st-text { margin: 0; font-size: 15.5px; line-height: 1.9; }

/* ---------- Families ---------- */
.fam { padding-top: 96px; background: linear-gradient(180deg, #FCF0C8, #F7E2A2); }
.swag { position: absolute; top: 0; left: 50%; display: flex; width: max-content; transform: translateX(-50%); pointer-events: none; }
.swag svg { display: block; flex: none; width: 180px; height: 50px; overflow: visible; }
.fam-list { margin: 0 auto; padding: 0; list-style: none; display: grid; gap: 12px; text-align: center; }
.fam-list li { font: 600 17px/1.75 var(--f-text); color: var(--maroon-d); }
.fam-list li + li::before { content: ""; display: block; width: 46px; height: 8px; margin: 0 auto 12px; background: radial-gradient(circle, var(--kumkum) 0 2px, transparent 2.5px) 0 50% / 16px 8px repeat-x; opacity: .7; }

/* ---------- Contacts ---------- */
.ct { background: var(--cream); }
.ct-grid { display: grid; gap: 16px; max-width: 880px; margin: 0 auto; }
.ct-card { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 4px 14px; padding: 18px; border-radius: 14px; background: #FFFBF1; border: 1px solid rgba(180, 130, 40, .32); box-shadow: 0 10px 26px rgba(90, 40, 10, .08); }
.ct-mono { display: grid; place-items: center; width: 54px; height: 54px; border-radius: 50%; font: 700 24px/1 var(--f-disp); color: var(--gold-l); background: radial-gradient(circle at 40% 35%, #7A1A22, #4A0C13); box-shadow: 0 0 0 2px var(--gold), 0 0 0 4px #FFFBF1, 0 0 0 5px rgba(216, 168, 69, .5); }
.ct-name { margin: 0; font: 700 20px/1.35 var(--f-disp); color: var(--maroon); }
.ct-role { margin: 0; font-size: 14px; line-height: 1.6; color: var(--muted); }
.ct-ph { margin: 0; font-size: 14px; line-height: 1.6; letter-spacing: .02em; color: #6B4A3A; }
.ct-btns { grid-column: 1 / -1; display: flex; gap: 10px; margin-top: 10px; }
.ct-btns .btn { flex: 1; }
@media (min-width: 760px) { .ct-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .ct-grid > :only-child { grid-column: 1 / -1; max-width: 440px; justify-self: center; width: 100%; } }

/* ---------- Closing ---------- */
.close { position: relative; overflow: hidden; text-align: center; color: var(--gold-l); background: radial-gradient(ellipse at 50% 25%, #701621, #3A070D 65%, #22040A); }
.close-in { display: grid; justify-items: center; max-width: 1100px; margin: 0 auto; padding: 50px 24px 72px; }
.lamp--close { width: 84px; height: auto; }
.lamp--r { display: none; }
.close-text { min-width: 0; }
.close-msg { max-width: 540px; margin: 16px auto 0; font: 400 19px/1.85 var(--f-hand); color: #F7E3B0; }
.close-names { margin: 14px 0 6px; font: 700 clamp(38px, 11vw, 64px)/1.3 var(--f-disp); }
.close-date { margin: 0; font-size: 15px; color: rgba(244, 220, 148, .85); }
.chip {
  display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 18px; border-radius: 999px; cursor: pointer;
  border: 1.5px solid rgba(244, 220, 148, .55); background: transparent; color: var(--gold-l); font: 600 14.5px/1.2 var(--f-text);
}
.chip .ico { width: 17px; height: 17px; }
.chip--solid { color: var(--maroon-d); border-color: transparent; background: linear-gradient(180deg, #F9E4A4, #D8A845 60%, #B4832D); }
@media (min-width: 900px) {
  .close-in { grid-template-columns: auto minmax(0, 1fr) auto; align-items: end; gap: 48px; padding: 80px 40px 96px; }
  .lamp--close, .lamp--r { display: block; width: 130px; }
}

/* ---------- Floating buttons ---------- */
.fabs { position: fixed; right: 14px; bottom: calc(14px + env(safe-area-inset-bottom)); z-index: 50; display: grid; gap: 10px; transition: opacity .4s; }
.is-loading .fabs, .is-locked .fabs { opacity: 0; pointer-events: none; }
.fab {
  display: grid; place-items: center; width: 48px; height: 48px; border: 0; border-radius: 50%; cursor: pointer; color: var(--maroon-d);
  background: radial-gradient(circle at 38% 30%, #FFF1C2, #D8A845 55%, #9C6E22);
  box-shadow: 0 8px 20px rgba(30, 5, 8, .4), inset 0 0 0 1.5px rgba(255, 245, 210, .6);
}
.fab[hidden] { display: none; }
.fab svg { width: 21px; height: 21px; fill: none; stroke: currentColor; stroke-width: 1.9; stroke-linecap: round; stroke-linejoin: round; }
.fab-music .eq { display: none; }
.fab-music.is-playing .i-note { display: none; }
.fab-music.is-playing .eq { display: flex; align-items: flex-end; gap: 3px; height: 18px; }
.eq i { display: block; width: 3px; height: 100%; border-radius: 2px; background: currentColor; transform-origin: bottom; animation: eq 1s ease-in-out infinite; }
.eq i:nth-child(2) { animation-delay: -.4s; }
.eq i:nth-child(3) { animation-delay: -.7s; }
@keyframes eq { 0%, 100% { transform: scaleY(.3); } 50% { transform: scaleY(1); } }

/* ---------- Editor preview & reduced motion ---------- */
.wv-instant *, .wv-instant *::before, .wv-instant *::after { transition: none !important; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
}
