/* Shared visual system for the remaining HAF theme collection. */
.theme-brown-romance{--collection-primary:#704633;--collection-accent:#c29a63;--collection-paper:#fbf4e9;--collection-ink:#49352c;--collection-muted:#7c695d}
.theme-soft-blueish{--collection-primary:#315d70;--collection-accent:#9dbfca;--collection-paper:#f3f9fa;--collection-ink:#29434d;--collection-muted:#687e86}
.theme-shades-of-black{--collection-primary:#17191c;--collection-accent:#c5aa78;--collection-paper:#f5f4f1;--collection-ink:#202225;--collection-muted:#707277}
.theme-green-line{--collection-primary:#335b43;--collection-accent:#a5bc86;--collection-paper:#f4f7ef;--collection-ink:#304538;--collection-muted:#6f7e73}
.theme-choco-vintage{--collection-primary:#5c3b2d;--collection-accent:#bd8d57;--collection-paper:#f5eadb;--collection-ink:#49352c;--collection-muted:#806c60}
.theme-pinky-roseville{--collection-primary:#793b58;--collection-accent:#d49ab2;--collection-paper:#fff5f8;--collection-ink:#543340;--collection-muted:#866b76}
.theme-flourish-green{--collection-primary:#315d45;--collection-accent:#c2a35f;--collection-paper:#f7f8f0;--collection-ink:#2e4437;--collection-muted:#718078}
.theme-moderna-look{--collection-primary:#202735;--collection-accent:#d29d62;--collection-paper:#f5f3ef;--collection-ink:#242a34;--collection-muted:#737780}
.theme-coffee-creamy{--collection-primary:#65503e;--collection-accent:#c6a778;--collection-paper:#faf5eb;--collection-ink:#4d4136;--collection-muted:#82766a}
.theme-wedtoon{--collection-primary:#27648a;--collection-accent:#f2b84b;--collection-paper:#f5fbff;--collection-ink:#284554;--collection-muted:#6c7e88}
.theme-islamic-pattern-v1{--collection-primary:#174f48;--collection-accent:#c9a75f;--collection-paper:#f7f5eb;--collection-ink:#28453f;--collection-muted:#70807b}
.theme-islamic-pattern-v2{--collection-primary:#284f70;--collection-accent:#d0ad68;--collection-paper:#f4f7f8;--collection-ink:#2f4657;--collection-muted:#72808a}
.theme-islamic-pattern-v3{--collection-primary:#59436d;--collection-accent:#d1b273;--collection-paper:#f8f4fa;--collection-ink:#493c53;--collection-muted:#7d7184}
.theme-lux-mandala{--collection-primary:#181c25;--collection-accent:#d0ac64;--collection-paper:#f5f2eb;--collection-ink:#252830;--collection-muted:#77777a}
.theme-elegant-mandala{--collection-primary:#694735;--collection-accent:#cda66b;--collection-paper:#faf5ed;--collection-ink:#4f3c31;--collection-muted:#817267}
.theme-pinkyflat{--collection-primary:#924e6b;--collection-accent:#e1a5bd;--collection-paper:#fff7fa;--collection-ink:#5d3b49;--collection-muted:#8c7480}
.theme-vintagold{--collection-primary:#604b30;--collection-accent:#c7a45f;--collection-paper:#f5eedf;--collection-ink:#4c402f;--collection-muted:#807462}
.theme-skyflower{--collection-primary:#315d77;--collection-accent:#8eb9ce;--collection-paper:#f4fafc;--collection-ink:#304b59;--collection-muted:#6e818a}
.theme-flow-vintage{--collection-primary:#6c4a39;--collection-accent:#c69d66;--collection-paper:#f7efe2;--collection-ink:#513d32;--collection-muted:#837166}
.theme-rose-beauty{--collection-primary:#71394d;--collection-accent:#d29aab;--collection-paper:#fff7f8;--collection-ink:#52343f;--collection-muted:#856e76}
.theme-minimalist-black{--collection-primary:#111315;--collection-accent:#bfa574;--collection-paper:#f7f6f3;--collection-ink:#202124;--collection-muted:#747579}
.theme-red-luck{--collection-primary:#831f25;--collection-accent:#d5aa55;--collection-paper:#fff7ef;--collection-ink:#552b2c;--collection-muted:#856d69}
.theme-flow-vintage .couple-section{background:linear-gradient(145deg,#9a522a,#713923)!important}

body:not(.theme-flower-bless):not(.theme-sweet-purple) {
  --collection-primary:var(--theme-primary);
  --collection-accent:var(--theme-button);
}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .section-heading h2,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .invite-section>h2,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-card h3,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .event-card h3,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .story-copy h2,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .gift-panel h2 {
  color:var(--collection-primary,var(--theme-primary));
  text-wrap:balance;
}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .opening-section,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .date-section,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .gallery-section,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .wishes-section {
  background:linear-gradient(145deg,color-mix(in srgb,var(--collection-paper,#fff) 96%,#fff),color-mix(in srgb,var(--collection-paper,#fff) 88%,var(--collection-primary,#555)))!important;
}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .section-heading p,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .lead-copy,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-card p,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .event-card p {
  color:var(--collection-muted,#718078);
}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .section-label,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-card small,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .event-card small {
  color:var(--collection-accent,var(--theme-button));
}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .event-card {
  border-color:color-mix(in srgb,var(--collection-primary,#555) 15%,transparent);
  border-top:3px solid var(--collection-accent,var(--theme-button));
  background:rgba(255,255,255,.88);
  box-shadow:0 20px 50px color-mix(in srgb,var(--collection-primary,#333) 10%,transparent);
}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .event-actions a:last-child,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .rsvp-form button {
  color:#fff;
  background:var(--collection-primary,var(--theme-primary));
}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .story-section h2,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .gift-section h2 {color:#fff!important;text-shadow:0 2px 20px rgba(0,0,0,.16)}
body:not(.theme-flower-bless):not(.theme-sweet-purple) .story-section .section-label,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .gift-section .section-label {color:#f1d39a!important}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .rsvp-form {
  border-top:3px solid var(--collection-accent,var(--theme-button));
  color:var(--collection-ink,#333);
  background:rgba(255,255,255,.92);
  box-shadow:0 20px 50px color-mix(in srgb,var(--collection-primary,#333) 9%,transparent);
}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .rsvp-form label {color:var(--collection-ink,#333)}
body:not(.theme-flower-bless):not(.theme-sweet-purple) .rsvp-form input,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .rsvp-form select,
body:not(.theme-flower-bless):not(.theme-sweet-purple) .rsvp-form textarea {border:1px solid color-mix(in srgb,var(--collection-primary,#555) 16%,#ddd);background:rgba(255,255,255,.92)}

body:not(.theme-flower-bless):not(.theme-sweet-purple) .invite-dock {
  border-color:color-mix(in srgb,var(--collection-primary,#555) 18%,transparent);
  background:color-mix(in srgb,var(--collection-paper,#fff) 94%,transparent);
  box-shadow:0 16px 42px color-mix(in srgb,var(--collection-primary,#333) 18%,transparent);
}
body:not(.theme-flower-bless):not(.theme-sweet-purple) .invite-dock a.active {color:var(--collection-primary,var(--theme-primary))}
body:not(.theme-flower-bless):not(.theme-sweet-purple) .invite-dock a.active i {color:var(--collection-primary,var(--theme-primary));background:color-mix(in srgb,var(--collection-accent,#ddd) 28%,#fff)}

/* Romantic and floral themes use graceful portrait shapes and soft editorial cards. */
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-section {
  color:var(--collection-ink,#333);
  background:radial-gradient(circle at 8% 12%,rgba(194,154,99,.15),transparent 22rem),#fffaf6!important;
}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-section .section-heading h2 {color:var(--collection-primary)!important}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-section .section-label {color:color-mix(in srgb,var(--collection-primary) 72%,#6b4c3a)!important}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-layout {width:min(1080px,100%);grid-template-columns:1fr 86px 1fr;gap:28px}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-card {grid-template-columns:minmax(180px,230px) minmax(0,1fr);gap:27px;align-items:center}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-bride {grid-template-columns:minmax(0,1fr) minmax(180px,230px)}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .portrait-wrap {height:315px;border-radius:120px 120px 8px 8px;border-color:color-mix(in srgb,var(--collection-primary) 20%,#fff);box-shadow:0 24px 58px color-mix(in srgb,var(--collection-primary) 14%,transparent)}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-card h3 {color:var(--collection-primary);font-size:clamp(31px,2.6vw,42px)}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .lineage {color:color-mix(in srgb,var(--collection-primary) 75%,var(--collection-accent));font-size:14px}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .story-section {background:linear-gradient(145deg,color-mix(in srgb,var(--collection-primary) 88%,#111),var(--collection-primary))!important}
body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .gallery-item {border-radius:18px 5px 18px 5px}

/* Natural themes stay airy and tactile. */
body.family-natural .couple-section {background:linear-gradient(145deg,color-mix(in srgb,var(--collection-primary) 92%,#26372d),color-mix(in srgb,var(--collection-primary) 74%,#6f7c67))!important}
body.family-natural .portrait-wrap {border-radius:110px 110px 18px 18px;box-shadow:0 24px 55px rgba(34,58,43,.18)}
body.family-natural .event-card {border-radius:24px 7px 24px 7px}
body.family-natural .gallery-item {border-radius:22px 7px 22px 7px}

/* Vintage themes use warm paper, thin rules and classic proportions. */
body.family-vintage .opening-section,
body.family-vintage .date-section,
body.family-vintage .gallery-section,
body.family-vintage .wishes-section {background:linear-gradient(145deg,var(--collection-paper),color-mix(in srgb,var(--collection-paper) 78%,var(--collection-accent)))!important}
body.family-vintage .event-card {border-radius:2px;box-shadow:0 18px 42px rgba(67,43,30,.1)}
body.family-vintage .event-card:after {content:"";position:absolute;inset:7px;border:1px solid color-mix(in srgb,var(--collection-accent) 24%,transparent);pointer-events:none}
body.family-vintage .portrait-wrap {border-radius:120px 120px 3px 3px}
body.family-vintage .rsvp-form {border-radius:2px}

/* Modern and minimal themes use sharper geometry and stronger contrast. */
body.family-modern .couple-section,
body.family-minimal .couple-section {background:linear-gradient(145deg,#15181d,color-mix(in srgb,var(--collection-primary) 78%,#383b42))!important}
body.family-modern .event-card,
body.family-minimal .event-card {border-radius:0;text-align:left}
body.family-modern .event-actions,
body.family-minimal .event-actions {justify-content:flex-start}
body.family-modern .portrait-wrap,
body.family-minimal .portrait-wrap {border-radius:2px;padding:5px}
body.family-modern .portrait-wrap img,
body.family-minimal .portrait-wrap img {border-radius:0}
body.family-minimal .opening-section,
body.family-minimal .date-section,
body.family-minimal .gallery-section,
body.family-minimal .wishes-section {background:#f5f4f1!important}

/* Islamic themes use balanced arches and restrained gold geometry. */
body.family-islamic .couple-section {background:linear-gradient(145deg,color-mix(in srgb,var(--collection-primary) 94%,#172722),color-mix(in srgb,var(--collection-primary) 74%,#5b6258))!important}
body.family-islamic .portrait-wrap {border-radius:50% 50% 14px 14px}
body.family-islamic .event-card {border-radius:90px 90px 10px 10px;padding-top:58px}
body.family-islamic .countdown>div {border-radius:50% 50% 8px 8px}
body.family-islamic .rsvp-form {border-radius:28px 28px 5px 5px}

/* Character themes are lively, while preserving readable controls. */
body.family-character .couple-section {background:linear-gradient(145deg,color-mix(in srgb,var(--collection-primary) 90%,#243a46),var(--collection-primary))!important}
body.family-character .portrait-wrap {border-radius:36px;padding:8px;transform:rotate(-1.2deg)}
body.family-character .couple-bride .portrait-wrap {transform:rotate(1.2deg)}
body.family-character .event-card {border-radius:22px;box-shadow:7px 8px 0 color-mix(in srgb,var(--collection-accent) 35%,transparent)}
body.theme-red-luck .couple-section {background:linear-gradient(145deg,#6f181d,#9c2930)!important}

body.family-natural .couple-section .section-heading h2,
body.family-vintage .couple-section .section-heading h2,
body.family-modern .couple-section .section-heading h2,
body.family-minimal .couple-section .section-heading h2,
body.family-islamic .couple-section .section-heading h2,
body.family-character .couple-section .section-heading h2 {color:#fff!important;text-shadow:0 2px 18px rgba(0,0,0,.16)}
body.family-natural .couple-section .section-label,
body.family-vintage .couple-section .section-label,
body.family-modern .couple-section .section-label,
body.family-minimal .couple-section .section-label,
body.family-islamic .couple-section .section-label,
body.family-character .couple-section .section-label {color:#f2d59a!important}
body.family-natural .couple-section .couple-card h3,
body.family-vintage .couple-section .couple-card h3,
body.family-modern .couple-section .couple-card h3,
body.family-minimal .couple-section .couple-card h3,
body.family-islamic .couple-section .couple-card h3,
body.family-character .couple-section .couple-card h3 {color:#fff!important}

body.family-natural .couple-section .couple-card p,
body.family-vintage .couple-section .couple-card p,
body.family-modern .couple-section .couple-card p,
body.family-minimal .couple-section .couple-card p,
body.family-islamic .couple-section .couple-card p,
body.family-character .couple-section .couple-card p {color:rgba(255,255,255,.82)!important}
body.family-natural .couple-section .couple-card p>strong,
body.family-vintage .couple-section .couple-card p>strong,
body.family-modern .couple-section .couple-card p>strong,
body.family-minimal .couple-section .couple-card p>strong,
body.family-islamic .couple-section .couple-card p>strong,
body.family-character .couple-section .couple-card p>strong {color:#fff!important}
body.family-natural .couple-section .lineage,
body.family-vintage .couple-section .lineage,
body.family-modern .couple-section .lineage,
body.family-minimal .couple-section .lineage,
body.family-islamic .couple-section .lineage,
body.family-character .couple-section .lineage {color:#f1cf9e!important;opacity:1!important}
body.family-natural .couple-section .parent-join,
body.family-vintage .couple-section .parent-join,
body.family-modern .couple-section .parent-join,
body.family-minimal .couple-section .parent-join,
body.family-islamic .couple-section .parent-join,
body.family-character .couple-section .parent-join,
body.family-natural .couple-section .couple-amp small,
body.family-vintage .couple-section .couple-amp small,
body.family-modern .couple-section .couple-amp small,
body.family-minimal .couple-section .couple-amp small,
body.family-islamic .couple-section .couple-amp small,
body.family-character .couple-section .couple-amp small {color:rgba(255,255,255,.72)!important;opacity:1!important}

/* Motion families: distinct rhythm without heavy layout work. */
body:not(.theme-flower-bless) .reveal {will-change:opacity,transform;transition:opacity .72s ease,transform .88s cubic-bezier(.18,.76,.24,1),filter .55s ease}
body.motion-gentle:not(.theme-flower-bless) .reveal {opacity:0;filter:blur(1.5px);transform:translate3d(0,34px,0) scale(.985)}
body.motion-botanical:not(.theme-flower-bless) .reveal {opacity:0;filter:blur(1px);transform:translate3d(0,40px,0) scale(.975)}
body.motion-cinematic:not(.theme-flower-bless) .reveal {opacity:0;filter:blur(2px);transform:translate3d(0,52px,0) scale(.96);transition-duration:.9s,1.05s,.65s}
body:not(.theme-flower-bless) .reveal.visible {opacity:1;filter:none;transform:none;will-change:auto}
body.motion-botanical:not(.motion-none) .center-ornament {animation:collectionBotanical 7s ease-in-out infinite}
body.motion-gentle:not(.motion-none) .center-ornament {animation:collectionFloat 8s ease-in-out infinite}
body.motion-cinematic:not(.motion-none) .story-photo img {animation:collectionDrift 14s ease-in-out infinite alternate}
@keyframes collectionBotanical{0%,100%{transform:translateY(2px) rotate(-.7deg)}50%{transform:translateY(-7px) rotate(.8deg)}}
@keyframes collectionFloat{0%,100%{transform:translateY(0)}50%{transform:translateY(-6px)}}
@keyframes collectionDrift{from{transform:scale(1)}to{transform:scale(1.055)}}

@media(max-width:900px){
  body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-layout {width:min(430px,100%);grid-template-columns:1fr;gap:30px}
  body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-card,
  body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-bride {grid-template-columns:1fr;text-align:center}
  body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-bride .portrait-wrap,
  body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-bride .couple-copy {grid-column:1;grid-row:auto;text-align:center}
  body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .portrait-wrap {width:min(215px,65vw);height:min(285px,84vw);margin:auto}
  body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-card h3,
  body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .lineage,
  body.family-flower:not(.theme-flower-bless):not(.theme-sweet-purple) .couple-card p {margin-right:auto;margin-left:auto}
}

@media(max-width:799px){
  body:not(.theme-flower-bless):not(.theme-sweet-purple) .event-layout,
  body:not(.theme-flower-bless):not(.theme-sweet-purple) .wishes-layout {grid-template-columns:1fr}
  body:not(.theme-flower-bless):not(.theme-sweet-purple) .event-actions {display:grid;grid-template-columns:1fr 1fr}
  body:not(.theme-flower-bless):not(.theme-sweet-purple) .event-actions a {width:100%;min-height:45px;display:inline-flex;align-items:center;justify-content:center;font-size:10px}
  body:not(.theme-flower-bless):not(.theme-sweet-purple) .rsvp-form input,
  body:not(.theme-flower-bless):not(.theme-sweet-purple) .rsvp-form select,
  body:not(.theme-flower-bless):not(.theme-sweet-purple) .rsvp-form textarea {min-height:48px;font-size:16px}
  body:not(.theme-flower-bless):not(.theme-sweet-purple) .invite-section:not(.opening-section) {padding-bottom:calc(96px + env(safe-area-inset-bottom))}
  body.family-modern .event-card,
  body.family-minimal .event-card {text-align:center}
  body.family-modern .event-actions,
  body.family-minimal .event-actions {justify-content:center}
}

@media(max-width:360px){body:not(.theme-flower-bless):not(.theme-sweet-purple) .event-actions{grid-template-columns:1fr}}
@media(prefers-reduced-motion:reduce){body .reveal{opacity:1!important;filter:none!important;transform:none!important;transition:none!important}body .center-ornament,body .story-photo img{animation:none!important}}
