:root {
  --wip-c1: #1a1a1a;
  --wip-c2: #d4af37;
  --wip-c3: #ffffff;
  --wip-font: 'Vazirmatn', Tahoma, sans-serif;
}

* { box-sizing: border-box; }

html, body.wip-body {
  margin: 0; padding: 0; font-family: var(--wip-font);
  background: #ececec;
}

.wip-card {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  position: relative;
  background: var(--wip-c1);
  background-image: var(--wip-bg-image, none);
  background-size: cover;
  background-position: center;
  overflow: hidden;
}

.wip-card::before {
  content: "";
  position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0,0,0,.35), rgba(0,0,0,.55));
  z-index: 0;
}

.wip-card-inner {
  position: relative;
  z-index: 1;
  padding: 40px 24px 30px;
  text-align: center;
  color: var(--wip-c3);
  display: flex;
  flex-direction: column;
  align-items: center;
  min-height: 100vh;
  justify-content: center;
}

.wip-eyebrow { font-size: 14px; opacity: .85; letter-spacing: 1px; margin-bottom: 18px; }

.wip-photo-wrap { margin-bottom: 20px; }
.wip-photo {
  width: 140px; height: 140px; border-radius: 50%;
  object-fit: cover; border: 4px solid var(--wip-c2);
  box-shadow: 0 6px 24px rgba(0,0,0,.35);
}

.wip-names { font-size: 30px; line-height: 1.5; margin: 10px 0 20px; font-weight: 900; }
.wip-name { display: block; color: var(--wip-c2); }
.wip-amp { display: block; font-size: 22px; opacity: .8; margin: 4px 0; font-weight: 400; }

.wip-poem { font-size: 16px; line-height: 2.1; margin-bottom: 20px; opacity: .95; font-style: normal; }
.wip-description { font-size: 15px; line-height: 1.9; margin-bottom: 20px; opacity: .9; }

.wip-date-box { margin: 10px 0 20px; }
.wip-date-text { font-size: clamp(10px,2.8vw,14px); font-weight: 700; margin-bottom: 6px; white-space: nowrap; line-height: 1.8; letter-spacing:-.15px; }
.wip-venue { font-size: 14px; opacity: .85; }

.wip-ornament { width: 60px; height: 3px; background: var(--wip-c2); margin: 20px auto; border-radius: 3px; opacity: .8; }



.wip-share-box { margin-top: 20px; display: flex; flex-direction: column; align-items: center; gap: 14px; }
.wip-share-btn {
  background: var(--wip-c2); color: #111; border: none; border-radius: 30px;
  padding: 12px 26px; font-family: var(--wip-font); font-weight: 700; font-size: 14px;
  cursor: pointer; box-shadow: 0 4px 14px rgba(0,0,0,.25);
}
.wip-qr { display: flex; flex-direction: column; align-items: center; gap: 6px; }
.wip-qr img { width: 110px; height: 110px; border-radius: 8px; background: #fff; padding: 6px; }
.wip-qr span { font-size: 12px; opacity: .8; }

.wip-music-toggle {
  position: fixed; top: 16px; left: 16px; z-index: 5;
  width: 46px; height: 46px; border-radius: 50%;
  background: rgba(0,0,0,.4); border: 1px solid rgba(255,255,255,.4);
  color: #fff; font-size: 18px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
}
.wip-music-toggle.is-playing .wip-music-icon { animation: wip-spin 3s linear infinite; }
@keyframes wip-spin { to { transform: rotate(360deg); } }

@media (max-width: 380px) {
  .wip-names { font-size: 24px; }
  .wip-photo { width: 110px; height: 110px; }
}

/* ===================== قالب‌های رنگی ===================== */
[data-template="classic-gold"]     { --wip-c1:#11100f; --wip-c2:#d8b865; --wip-c3:#fbf6ea; --wip-c4:#8e6d2f; }
[data-template="romantic-rose"]    { --wip-c1:#421426; --wip-c2:#f3a6b7; --wip-c3:#fff5f7; --wip-c4:#b65f79; }
[data-template="minimal-elegant"]  { --wip-c1:#202226; --wip-c2:#f2eee8; --wip-c3:#fcfbf8; --wip-c4:#a8a098; }
[data-template="royal-navy"]       { --wip-c1:#0b1b35; --wip-c2:#d1b06c; --wip-c3:#f8f1df; --wip-c4:#6d87a8; }
[data-template="pastel-boho"]      { --wip-c1:#5a4032; --wip-c2:#e1b994; --wip-c3:#fff3e7; --wip-c4:#9b715b; }
[data-template="emerald-luxury"]   { --wip-c1:#0b3b32; --wip-c2:#d8bd78; --wip-c3:#f1f8f3; --wip-c4:#4e8a76; }
[data-template="blush-pink"]       { --wip-c1:#6b233b; --wip-c2:#f4b5c3; --wip-c3:#fff5f8; --wip-c4:#c4778d; }
[data-template="floral-garden"]    { --wip-c1:#244536; --wip-c2:#b7cfb2; --wip-c3:#f4f8ef; --wip-c4:#6d967b; }
[data-template="modern-type"]      { --wip-c1:#101114; --wip-c2:#f4f2ee; --wip-c3:#f7f7f5; --wip-c4:#8e9299; }
[data-template="rustic-kraft"]     { --wip-c1:#4a3325; --wip-c2:#d0a96c; --wip-c3:#f8eee2; --wip-c4:#936a43; }
[data-template="geometric-persian"]{ --wip-c1:#17223f; --wip-c2:#e1b95e; --wip-c3:#faf4e4; --wip-c4:#5372a7; }
[data-template="dreamy-lilac"]     { --wip-c1:#3b2855; --wip-c2:#ceb5ea; --wip-c3:#fbf5ff; --wip-c4:#8464a9; }

/* ===================== Wedding Invite Pro 2.0 visual system ===================== */
html,body.wip-body{background:radial-gradient(circle at 50% 0,#f7f1f4 0,#ece9ea 44%,#e4e1e2 100%);min-height:100%;scroll-behavior:smooth}
body.wip-body{min-height:100vh}
.wip-card{max-width:540px;box-shadow:0 0 70px rgba(30,20,25,.13)}
.wip-card:after{content:"";position:absolute;inset:12px;border:1px solid rgba(255,255,255,.11);border-radius:24px;z-index:0;pointer-events:none}
.wip-card-inner{padding:54px 30px 36px}
.wip-eyebrow{text-transform:none;letter-spacing:.2px;padding:7px 13px;border:1px solid rgba(255,255,255,.14);border-radius:999px;background:rgba(255,255,255,.06);backdrop-filter:blur(6px)}
.wip-photo-wrap{position:relative}.wip-photo-wrap:after{content:"♥";position:absolute;right:-8px;bottom:7px;width:31px;height:31px;border-radius:50%;background:var(--wip-c2);color:#201a1d;display:flex;align-items:center;justify-content:center;font-size:12px;box-shadow:0 5px 15px rgba(0,0,0,.22)}
.wip-photo{width:154px;height:154px;border-width:3px;padding:4px;background:rgba(255,255,255,.08)}
.wip-names{letter-spacing:-.3px;text-shadow:0 4px 20px rgba(0,0,0,.16)}
.wip-poem,.wip-description{max-width:440px}.wip-poem p,.wip-description p{margin:.45em 0}
.wip-date-box{width:min(100%,410px);padding:17px 18px;border:1px solid rgba(255,255,255,.14);border-radius:18px;background:rgba(255,255,255,.07);backdrop-filter:blur(8px);box-shadow:0 12px 35px rgba(0,0,0,.09)}
.wip-date-text{margin:0 0 6px}.wip-venue{margin:0}


.wip-ornament{position:relative;width:74px;height:1px;overflow:visible}.wip-ornament:before{content:"✦";position:absolute;left:50%;top:50%;transform:translate(-50%,-50%);background:var(--wip-c1);padding:0 9px;color:var(--wip-c2);font-size:11px}
.wip-share-box{width:min(100%,430px);margin-top:18px;padding-top:5px}.wip-actions-title{font-size:12px;opacity:.78;margin:0 0 11px}.wip-action-grid{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;width:100%}.wip-action-btn{min-height:42px;border:1px solid rgba(255,255,255,.18);border-radius:14px;background:rgba(255,255,255,.08);color:var(--wip-c3);font-family:var(--wip-font);font-size:11px;font-weight:700;cursor:pointer;backdrop-filter:blur(8px);transition:transform .2s ease,background .2s ease,border-color .2s ease;box-shadow:0 8px 22px rgba(0,0,0,.08)}.wip-action-btn:hover{transform:translateY(-2px);background:rgba(255,255,255,.14);border-color:rgba(255,255,255,.28)}.wip-action-btn span{font-size:14px;margin-left:3px}.wip-action-primary{background:var(--wip-c2);color:#171317;border-color:transparent}.wip-action-primary:hover{background:var(--wip-c2);filter:brightness(1.06)}
.wip-qr{margin-top:7px}.wip-qr-frame{padding:8px;border-radius:17px;background:rgba(255,255,255,.9);box-shadow:0 12px 30px rgba(0,0,0,.16)}.wip-qr img{width:105px;height:105px;padding:0;border-radius:9px}.wip-qr span{margin-top:2px}
.wip-signature{font-size:11px;margin-top:18px;opacity:.66}.wip-signature span{color:var(--wip-c2)}
.wip-music-toggle{top:18px;left:max(18px,calc(50vw - 252px));position:fixed;width:48px;height:48px;background:rgba(12,10,11,.28);backdrop-filter:blur(10px);box-shadow:0 8px 24px rgba(0,0,0,.15);transition:.2s}.wip-music-toggle:hover{transform:scale(1.05)}
.wip-toast{position:fixed;left:50%;bottom:22px;transform:translate(-50%,20px);z-index:99;background:rgba(25,20,23,.92);color:#fff;border:1px solid rgba(255,255,255,.12);padding:10px 16px;border-radius:999px;font-family:var(--wip-font);font-size:12px;opacity:0;visibility:hidden;transition:.25s;box-shadow:0 10px 35px rgba(0,0,0,.25);backdrop-filter:blur(10px);white-space:nowrap}.wip-toast.is-visible{opacity:1;visibility:visible;transform:translate(-50%,0)}
.wip-reveal{opacity:0;transform:translateY(10px);animation:wipReveal .6s cubic-bezier(.2,.7,.3,1) forwards;animation-delay:var(--wip-delay,0ms)}
@keyframes wipReveal{to{opacity:1;transform:none}}

/* Distinct theme personalities */
body[data-template="classic-gold"] .wip-card{background-image:radial-gradient(circle at 50% -5%,rgba(212,175,55,.18),transparent 35%),var(--wip-bg-image,none);background-color:#151515}
body[data-template="classic-gold"] .wip-card:after{border-color:rgba(212,175,55,.22);inset:16px}
body[data-template="classic-gold"] .wip-photo{border-radius:8px;transform:rotate(-1deg)}
body[data-template="classic-gold"] .wip-date-box{border-color:rgba(212,175,55,.22)}

body[data-template="romantic-rose"] .wip-card:before{background:linear-gradient(180deg,rgba(68,10,29,.48),rgba(59,13,26,.78))}
body[data-template="romantic-rose"] .wip-card:after{border-radius:48% 48% 24px 24px / 11% 11% 24px 24px;border-color:rgba(255,143,163,.22)}
body[data-template="romantic-rose"] .wip-photo{border-radius:45% 45% 50% 50% / 42% 42% 58% 58%}
body[data-template="romantic-rose"] .wip-names{font-weight:700}

body[data-template="minimal-elegant"] .wip-card:before{background:linear-gradient(180deg,rgba(0,0,0,.24),rgba(0,0,0,.62))}
body[data-template="minimal-elegant"] .wip-card:after{inset:24px;border-radius:2px}.wip-body[data-template="minimal-elegant"] .wip-photo{border-radius:2px;border-width:1px}.wip-body[data-template="minimal-elegant"] .wip-eyebrow{border-radius:2px;background:transparent}.wip-body[data-template="minimal-elegant"] .wip-action-btn,.wip-body[data-template="minimal-elegant"] .wip-date-box,.wip-body[data-template="minimal-elegant"] 

body[data-template="royal-navy"] .wip-card{background-color:#07172f}.wip-body[data-template="royal-navy"] .wip-card:after{border-color:rgba(201,161,90,.3);box-shadow:inset 0 0 0 5px rgba(201,161,90,.035)}.wip-body[data-template="royal-navy"] .wip-photo{border-radius:50% 50% 12% 12%}.wip-body[data-template="royal-navy"] .wip-date-box{background:rgba(4,18,39,.45);border-color:rgba(201,161,90,.25)}

body[data-template="pastel-boho"] .wip-card:before{background:linear-gradient(180deg,rgba(71,52,40,.34),rgba(69,50,37,.74))}.wip-body[data-template="pastel-boho"] .wip-card:after{border-style:dashed}.wip-body[data-template="pastel-boho"] .wip-photo{border-radius:45% 55% 48% 52% / 55% 42% 58% 45%;transform:rotate(1.5deg)}.wip-body[data-template="pastel-boho"] .wip-date-box,.wip-body[data-template="pastel-boho"] 

body[data-template="emerald-luxury"] .wip-card:before{background:linear-gradient(155deg,rgba(1,50,32,.45),rgba(0,24,15,.82))}.wip-body[data-template="emerald-luxury"] .wip-card:after{border-color:rgba(212,175,55,.3)}.wip-body[data-template="emerald-luxury"] .wip-photo{border-radius:22px}.wip-body[data-template="emerald-luxury"] .wip-ornament{width:105px}

body[data-template="blush-pink"] .wip-card:before{background:linear-gradient(180deg,rgba(122,16,48,.35),rgba(85,7,31,.72))}.wip-body[data-template="blush-pink"] .wip-card:after{border-color:rgba(255,179,198,.24);border-radius:34px}.wip-body[data-template="blush-pink"] .wip-photo{border-radius:50%;box-shadow:0 0 0 8px rgba(255,179,198,.08),0 8px 24px rgba(0,0,0,.22)}

body[data-template="floral-garden"] .wip-card:before{background:linear-gradient(180deg,rgba(22,57,39,.31),rgba(18,49,33,.76))}.wip-body[data-template="floral-garden"] .wip-card:after{border-radius:60px 20px 60px 20px;border-color:rgba(163,201,168,.22)}.wip-body[data-template="floral-garden"] .wip-photo{border-radius:50% 16% 50% 16%}.wip-body[data-template="floral-garden"] .wip-date-box{border-radius:28px 10px 28px 10px}

body[data-template="modern-type"] .wip-card:before{background:linear-gradient(135deg,rgba(0,0,0,.4),rgba(0,0,0,.72))}.wip-body[data-template="modern-type"] .wip-card:after{inset:0;border:0;border-left:8px solid rgba(255,255,255,.08)}.wip-body[data-template="modern-type"] .wip-photo{border-radius:0;width:170px;height:120px}.wip-body[data-template="modern-type"] .wip-names{text-transform:uppercase;line-height:1.1;font-size:34px}.wip-body[data-template="modern-type"] .wip-action-btn,.wip-body[data-template="modern-type"] .wip-date-box{border-radius:0}

body[data-template="rustic-kraft"] .wip-card:before{background:linear-gradient(180deg,rgba(54,38,28,.28),rgba(53,36,25,.72))}.wip-body[data-template="rustic-kraft"] .wip-card:after{border-style:dashed;border-color:rgba(200,161,101,.32);inset:18px}.wip-body[data-template="rustic-kraft"] .wip-photo{border-radius:6px;transform:rotate(-2deg)}.wip-body[data-template="rustic-kraft"] .wip-date-box{border-radius:8px}

body[data-template="geometric-persian"] .wip-card:before{background:linear-gradient(150deg,rgba(27,27,58,.42),rgba(16,16,38,.82))}.wip-body[data-template="geometric-persian"] .wip-card:after{border-radius:0;inset:20px;transform:rotate(.6deg);border-color:rgba(227,178,60,.28)}.wip-body[data-template="geometric-persian"] .wip-photo{border-radius:4px;transform:rotate(45deg);width:120px;height:120px;margin:18px}.wip-body[data-template="geometric-persian"] .wip-photo-wrap:after{bottom:-5px;right:-2px}.wip-body[data-template="geometric-persian"] .wip-date-box{border-radius:4px}

body[data-template="dreamy-lilac"] .wip-card:before{background:linear-gradient(180deg,rgba(51,28,77,.3),rgba(42,20,66,.72))}.wip-body[data-template="dreamy-lilac"] .wip-card:after{border-color:rgba(201,166,240,.25);box-shadow:inset 0 0 50px rgba(201,166,240,.06)}.wip-body[data-template="dreamy-lilac"] .wip-photo{box-shadow:0 0 0 9px rgba(201,166,240,.07),0 8px 30px rgba(0,0,0,.22)}.wip-body[data-template="dreamy-lilac"] .wip-date-box{background:rgba(255,255,255,.08)}

@media(max-width:580px){.wip-card{box-shadow:none}.wip-card-inner{padding:48px 20px 30px}.wip-action-grid{grid-template-columns:1fr 1fr}.wip-action-grid .wip-action-primary{grid-column:span 2}.wip-music-toggle{left:16px}.wip-photo{width:136px;height:136px}.wip-date-box{width:100%}}
@media(prefers-reduced-motion:reduce){*{scroll-behavior:auto!important}.wip-reveal{opacity:1;transform:none;animation:none!important}.wip-music-toggle.is-playing .wip-music-icon{animation:none}}

/* ===================== v2.1 envelope experience + split couple names ===================== */
.wip-couple-names{width:min(100%,430px);display:flex;direction:ltr;align-items:center;justify-content:center;gap:13px;margin:10px 0 22px;text-shadow:0 4px 20px rgba(0,0,0,.16)}
.wip-person{direction:rtl;flex:1;min-width:0;display:flex;flex-direction:column;align-items:center;gap:2px}
.wip-person-groom{order:1}.wip-couple-names>.wip-amp{order:2;flex:0 0 auto}.wip-person-bride{order:3}
.wip-first-name{display:block;width:100%;font-size:31px;line-height:1.35;font-weight:900;color:var(--wip-c2);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.wip-family-name{display:block;width:100%;font-size:14px;line-height:1.6;font-weight:500;color:var(--wip-c3);opacity:.86;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
.wip-couple-names>.wip-amp{font-size:20px;color:var(--wip-c3);opacity:.62;margin:0 2px;font-weight:400}
body[data-template="modern-type"] .wip-first-name{font-size:34px;text-transform:uppercase;letter-spacing:-1px}
body[data-template="minimal-elegant"] .wip-family-name{letter-spacing:.4px}

.wip-has-envelope:not(.wip-envelope-opened){overflow:hidden}
.wip-envelope-screen{--env-paper:#efe6d6;--env-paper-2:#e2d3bd;--env-ink:#553f42;--env-seal:#8f3d62;--wip-envelope-duration:1180ms;position:fixed;inset:0;z-index:1000;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:24px;padding:28px 18px;background:radial-gradient(circle at 50% 22%,rgba(255,255,255,.96),rgba(244,238,239,.96) 42%,rgba(226,218,221,.98) 100%);perspective:1200px;transition:opacity .42s ease,visibility .42s ease}
.wip-envelope-screen[data-style="rose"]{--env-paper:#eab8c7;--env-paper-2:#d69bad;--env-ink:#6d2443;--env-seal:#8e2f57;background:radial-gradient(circle at 50% 20%,#fff4f7,#f1dfe5 48%,#dfc7d0)}
.wip-envelope-screen[data-style="navy"]{--env-paper:#132b4e;--env-paper-2:#0b1e3d;--env-ink:#f3dfb0;--env-seal:#c9a15a;background:radial-gradient(circle at 50% 18%,#243e64,#101d34 52%,#091323)}
.wip-envelope-screen[data-style="kraft"]{--env-paper:#c69b68;--env-paper-2:#ac7d4a;--env-ink:#4b3525;--env-seal:#7c352d;background:radial-gradient(circle at 50% 20%,#ead2ae,#cfaa7c 52%,#b58b5c)}
.wip-envelope-heading{text-align:center;color:var(--env-ink);display:flex;flex-direction:column;align-items:center;gap:7px;transition:opacity calc(var(--wip-envelope-duration)*.28) ease,transform calc(var(--wip-envelope-duration)*.28) ease}
.wip-envelope-heading>span{font-size:12px;font-weight:700;opacity:.72;letter-spacing:.2px}.wip-envelope-heading>strong{font-size:22px;font-weight:900;line-height:1.5}.wip-envelope-heading>strong i{font-style:normal;color:var(--env-seal);font-size:14px;margin:0 5px}.wip-envelope-heading>small{font-size:11px;opacity:.62}
.wip-envelope{position:relative;width:min(86vw,390px);height:252px;border:0;padding:0;background:transparent;cursor:pointer;filter:drop-shadow(0 24px 34px rgba(45,30,35,.24));transform-style:preserve-3d;-webkit-tap-highlight-color:transparent}
.wip-envelope:focus-visible{outline:3px solid var(--env-seal);outline-offset:9px;border-radius:12px}
.wip-envelope-back{position:absolute;inset:0;z-index:1;border-radius:12px;background:linear-gradient(145deg,var(--env-paper),var(--env-paper-2));box-shadow:inset 0 1px rgba(255,255,255,.35)}
.wip-envelope-letter{position:absolute;z-index:2;left:8%;right:8%;top:10%;height:80%;border-radius:9px;background:linear-gradient(180deg,#fffefa,#f9f2e8);color:#4b3d42;padding:24px 18px 18px;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:10px;box-shadow:0 5px 18px rgba(48,35,39,.18);transform:translateY(27px) scale(.94);transition:transform var(--wip-envelope-duration) cubic-bezier(.19,.75,.22,1),box-shadow var(--wip-envelope-duration) ease,filter var(--wip-envelope-duration) ease}
.wip-envelope-letter-kicker{font-family:Georgia,serif;font-size:10px;letter-spacing:2px;text-transform:uppercase;color:#9a7c68}.wip-envelope-mini-couple{width:100%;display:flex;direction:ltr;align-items:center;justify-content:center;gap:9px}.wip-envelope-mini-person{direction:rtl;flex:1;display:flex;flex-direction:column;min-width:0}.wip-envelope-mini-person b{font-size:21px;line-height:1.3;color:#7f3e59;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.wip-envelope-mini-person small{font-size:11px;opacity:.7;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.wip-envelope-mini-couple i{font-family:Georgia,serif;font-style:italic;color:#b4977e}.wip-envelope-letter em{font-size:10px;font-style:normal;opacity:.64}
.wip-envelope-front{position:absolute;inset:0;z-index:3;border-radius:12px;background:linear-gradient(155deg,var(--env-paper),var(--env-paper-2));clip-path:polygon(0 26%,50% 63%,100% 26%,100% 100%,0 100%)}
.wip-envelope-front:after{content:"";position:absolute;inset:0;background:linear-gradient(36deg,rgba(255,255,255,.14),transparent 45%,rgba(0,0,0,.04));clip-path:inherit}
.wip-envelope-flap{position:absolute;left:0;right:0;top:0;height:58%;z-index:4;border-radius:12px 12px 0 0;background:linear-gradient(165deg,var(--env-paper),var(--env-paper-2));clip-path:polygon(0 0,100% 0,50% 100%);transform-origin:50% 0%;transform:rotateX(0deg);backface-visibility:hidden;transition:transform calc(var(--wip-envelope-duration)*.48) cubic-bezier(.45,0,.2,1)}
.wip-envelope-seal{position:absolute;z-index:5;left:50%;top:48%;width:54px;height:54px;margin:-27px 0 0 -27px;border-radius:50%;display:flex;align-items:center;justify-content:center;background:radial-gradient(circle at 34% 30%,color-mix(in srgb,var(--env-seal) 78%,#fff),var(--env-seal));color:#fff;font-size:17px;border:2px solid rgba(255,255,255,.24);box-shadow:0 5px 12px rgba(55,24,36,.28),inset 0 0 0 3px rgba(255,255,255,.08);transition:transform calc(var(--wip-envelope-duration)*.28) ease,opacity calc(var(--wip-envelope-duration)*.22) ease}
.wip-envelope-screen.is-opening .wip-envelope-heading{opacity:0;transform:translateY(-12px)}
.wip-envelope-screen.is-opening .wip-envelope-flap{transform:rotateX(180deg);z-index:1}
.wip-envelope-screen.is-opening .wip-envelope-seal{opacity:0;transform:scale(.55) rotate(-16deg)}
.wip-envelope-screen.is-opening[data-effect="lift"] .wip-envelope-letter{transform:translateY(-130px) scale(1.04);box-shadow:0 25px 48px rgba(48,35,39,.28)}
.wip-envelope-screen.is-opening[data-effect="slide"] .wip-envelope-letter{transform:translate(34px,-112px) rotate(3deg) scale(1.02);box-shadow:0 25px 48px rgba(48,35,39,.28)}
.wip-envelope-screen.is-opening[data-effect="glow"] .wip-envelope-letter{transform:translateY(-122px) scale(1.04);box-shadow:0 0 55px rgba(217,156,182,.72),0 25px 48px rgba(48,35,39,.22);filter:brightness(1.05)}
.wip-envelope-screen.is-open{background-color:rgba(239,232,234,.75)}
.wip-envelope-screen.is-complete{opacity:0;visibility:hidden;pointer-events:none}
.wip-envelope-sparkles{position:absolute;inset:0;pointer-events:none;overflow:hidden}.wip-envelope-sparkles i{position:absolute;left:50%;top:50%;width:7px;height:7px;border-radius:50%;background:var(--env-seal);opacity:0;transform:translate(-50%,-50%) scale(.2)}
.wip-envelope-screen.is-opening[data-effect="glow"] .wip-envelope-sparkles i{animation:wipSparkle calc(var(--wip-envelope-duration)*.85) ease-out forwards}.wip-envelope-sparkles i:nth-child(1){--sx:-145px;--sy:-105px}.wip-envelope-sparkles i:nth-child(2){--sx:145px;--sy:-80px;animation-delay:.08s!important}.wip-envelope-sparkles i:nth-child(3){--sx:-170px;--sy:50px;animation-delay:.14s!important}.wip-envelope-sparkles i:nth-child(4){--sx:170px;--sy:65px;animation-delay:.2s!important}.wip-envelope-sparkles i:nth-child(5){--sx:-85px;--sy:-165px;animation-delay:.1s!important}.wip-envelope-sparkles i:nth-child(6){--sx:85px;--sy:-170px;animation-delay:.18s!important}
@keyframes wipSparkle{0%{opacity:0;transform:translate(-50%,-50%) scale(.2)}25%{opacity:.9}100%{opacity:0;transform:translate(calc(-50% + var(--sx)),calc(-50% + var(--sy))) scale(1.3)}}
.wip-has-envelope .wip-reveal{animation-play-state:paused}.wip-envelope-opened .wip-reveal{animation-play-state:running}

@media(max-width:580px){.wip-first-name{font-size:26px}.wip-family-name{font-size:12px}.wip-couple-names{gap:8px}.wip-envelope{height:225px}.wip-envelope-heading>strong{font-size:20px}.wip-envelope-letter{padding:19px 14px 14px}.wip-envelope-mini-person b{font-size:18px}}
@media(max-width:360px){.wip-first-name{font-size:22px}.wip-family-name{font-size:11px}.wip-couple-names>.wip-amp{font-size:16px}.wip-envelope{height:205px}.wip-envelope-seal{width:48px;height:48px;margin:-24px 0 0 -24px}}
@media(prefers-reduced-motion:reduce){.wip-envelope-screen,.wip-envelope-heading,.wip-envelope-letter,.wip-envelope-flap,.wip-envelope-seal{transition-duration:.01ms!important}.wip-envelope-sparkles{display:none}}


/* v2.2 responsive envelope + single share action */
.wip-share-box-only .wip-actions-title{text-align:center}
.wip-action-grid--single{grid-template-columns:minmax(0,320px);justify-content:center}
.wip-action-grid--single .wip-action-primary{grid-column:auto}

.wip-envelope-screen{padding:max(20px,env(safe-area-inset-top)) max(16px,env(safe-area-inset-right)) max(20px,env(safe-area-inset-bottom)) max(16px,env(safe-area-inset-left));gap:clamp(16px,3vh,24px);overflow:auto}
.wip-envelope{width:min(94vw,440px);aspect-ratio:1.56/1;height:auto;min-height:190px;max-height:282px}
.wip-envelope-heading>strong{font-size:clamp(18px,4.5vw,24px)}
.wip-envelope-heading>span{font-size:clamp(11px,2.8vw,12px)}
.wip-envelope-heading>small{font-size:clamp(10px,2.6vw,11px)}
.wip-envelope-letter{padding:clamp(16px,4vw,24px) clamp(14px,4vw,18px) 16px}
.wip-envelope-letter-kicker{font-size:clamp(9px,2.6vw,10px)}
.wip-envelope-mini-couple{gap:clamp(6px,2vw,9px)}
.wip-envelope-mini-person b{font-size:clamp(16px,4.6vw,21px)}
.wip-envelope-mini-person small{font-size:clamp(10px,2.8vw,11px)}
.wip-envelope-letter em{font-size:clamp(9px,2.5vw,10px)}
.wip-envelope-seal{width:clamp(44px,12vw,54px);height:clamp(44px,12vw,54px);margin-top:calc(clamp(44px,12vw,54px)/-2);margin-left:calc(clamp(44px,12vw,54px)/-2)}
.wip-envelope-screen[data-style="pearl"]{--env-paper:#f6efe9;--env-paper-2:#ddd1c5;--env-ink:#6f5a52;--env-seal:#b49a82;background:radial-gradient(circle at 50% 20%,#fff,#f3ece5 48%,#e2d5ca)}
.wip-envelope-screen[data-style="emerald"]{--env-paper:#1f6155;--env-paper-2:#12473d;--env-ink:#f0e2ae;--env-seal:#d0ba74;background:radial-gradient(circle at 50% 18%,#2d8678,#185147 52%,#0f312d)}
.wip-envelope-screen[data-style="blush"]{--env-paper:#f2cfd7;--env-paper-2:#dcaeb8;--env-ink:#7d4156;--env-seal:#bc7085;background:radial-gradient(circle at 50% 20%,#fff5f8,#f1dde3 48%,#e0c1ca)}
.wip-envelope-screen[data-style="lavender"]{--env-paper:#d9d1ec;--env-paper-2:#bcaedc;--env-ink:#5f4b81;--env-seal:#7d69b5;background:radial-gradient(circle at 50% 20%,#f7f3ff,#e3dcf5 48%,#ccc1e7)}
.wip-envelope-screen[data-style="charcoal"]{--env-paper:#444751;--env-paper-2:#272a31;--env-ink:#f0dfbd;--env-seal:#c9aa70;background:radial-gradient(circle at 50% 18%,#5c606b,#31343d 52%,#1f2127)}
.wip-envelope-screen[data-style="sky"]{--env-paper:#b9dbef;--env-paper-2:#92c3dd;--env-ink:#35596f;--env-seal:#4a7f9f;background:radial-gradient(circle at 50% 20%,#eef8fe,#d3e9f6 48%,#bddced)}
@media(max-width:580px){.wip-envelope{min-height:180px}.wip-envelope-screen.is-opening[data-effect="lift"] .wip-envelope-letter{transform:translateY(-32vw) scale(1.04)}.wip-envelope-screen.is-opening[data-effect="slide"] .wip-envelope-letter{transform:translate(8vw,-28vw) rotate(3deg) scale(1.02)}.wip-envelope-screen.is-opening[data-effect="glow"] .wip-envelope-letter{transform:translateY(-30vw) scale(1.04)}.wip-action-grid--single{grid-template-columns:1fr}}
@media(max-width:380px){.wip-envelope{min-height:165px}.wip-envelope-front{clip-path:polygon(0 30%,50% 66%,100% 30%,100% 100%,0 100%)}.wip-envelope-screen{gap:14px}}
@media (max-height:520px) and (orientation:landscape){.wip-envelope-screen{justify-content:flex-start;padding-top:max(14px,env(safe-area-inset-top));padding-bottom:max(14px,env(safe-area-inset-bottom))}.wip-envelope-heading{gap:4px}.wip-envelope{width:min(72vw,360px);min-height:150px}.wip-envelope-screen.is-opening[data-effect="lift"] .wip-envelope-letter{transform:translateY(-100px) scale(1.03)}.wip-envelope-screen.is-opening[data-effect="slide"] .wip-envelope-letter{transform:translate(28px,-92px) rotate(3deg) scale(1.02)}.wip-envelope-screen.is-opening[data-effect="glow"] .wip-envelope-letter{transform:translateY(-96px) scale(1.03)}}


.wip-envelope-art{position:absolute;inset:0;width:100%;height:100%;z-index:0;pointer-events:none;opacity:.48;color:var(--env-seal)}
.wip-envelope-art .wip-svg-stroke{fill:none;stroke:currentColor;stroke-width:1.35;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:9 11;animation:wipArtDraw 14s linear infinite}
.wip-envelope-art .wip-svg-stroke-b{animation-direction:reverse;animation-duration:18s;opacity:.62}
.wip-envelope-art .wip-svg-dots{fill:currentColor}.wip-envelope-art .wip-svg-dots circle{transform-box:fill-box;transform-origin:center;animation:wipArtPulse 3.8s ease-in-out infinite}.wip-envelope-art .wip-svg-dots circle:nth-child(2){animation-delay:.8s}.wip-envelope-art .wip-svg-dots circle:nth-child(3){animation-delay:1.6s}.wip-envelope-art .wip-svg-dots circle:nth-child(4){animation-delay:2.2s}
.wip-card-art{position:absolute;inset:0;width:100%;height:100%;z-index:1;pointer-events:none;color:var(--wip-c2);opacity:.5}
.wip-card-art-line{fill:none;stroke:currentColor;stroke-width:1.1;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:7 10;animation:wipArtDraw 18s linear infinite}.wip-card-art-right{animation-direction:reverse;animation-duration:22s}.wip-card-art-stars{fill:currentColor}.wip-card-art-stars>*{transform-box:fill-box;transform-origin:center;animation:wipArtPulse 3.1s ease-in-out infinite}.wip-card-art-stars>*:nth-child(2){animation-delay:1s}.wip-card-art-stars>*:nth-child(3){animation-delay:1.8s}
@keyframes wipArtDraw{to{stroke-dashoffset:-240}}@keyframes wipArtPulse{0%,100%{opacity:.3;transform:scale(.72)}50%{opacity:1;transform:scale(1.38)}}


@media(prefers-reduced-motion:reduce){.wip-envelope-art .wip-svg-stroke,.wip-envelope-art .wip-svg-dots circle,.wip-card-art-line,.wip-card-art-stars>*{animation:none!important}}


/* v2.8 — 20 celebratory styles + 10 truly distinct responsive envelope models */
[data-template="sunset-coral"]{--wip-c1:#642038;--wip-c2:#ff8b77;--wip-c3:#fff2df;--wip-c4:#f0b45d}
[data-template="turquoise-party"]{--wip-c1:#064d55;--wip-c2:#39d2c7;--wip-c3:#effffb;--wip-c4:#f1ca6a}
[data-template="purple-neon"]{--wip-c1:#24103f;--wip-c2:#a16bff;--wip-c3:#fff0fb;--wip-c4:#ff76ce}
[data-template="champagne-sage"]{--wip-c1:#344b40;--wip-c2:#b7c9b5;--wip-c3:#fff8e9;--wip-c4:#d7b475}
[data-template="ruby-festival"]{--wip-c1:#510e21;--wip-c2:#dc4e6c;--wip-c3:#fff2df;--wip-c4:#edbd58}
[data-template="midnight-violet"]{--wip-c1:#15112b;--wip-c2:#7d65c8;--wip-c3:#f5efff;--wip-c4:#bb9df4}
[data-template="peach-confetti"]{--wip-c1:#71333a;--wip-c2:#ffac93;--wip-c3:#fff6e8;--wip-c4:#f4cd7b}
[data-template="azure-silver"]{--wip-c1:#10365d;--wip-c2:#58a8dc;--wip-c3:#f2f9ff;--wip-c4:#b8cfdf}
body[data-template="sunset-coral"] .wip-card:before{background:linear-gradient(165deg,rgba(125,37,69,.34),rgba(78,19,46,.82))}body[data-template="sunset-coral"] .wip-card:after{border-radius:70px 20px;border-color:rgba(255,176,106,.3)}body[data-template="sunset-coral"] .wip-photo{border-radius:50% 20% 50% 20%}
body[data-template="turquoise-party"] .wip-card:before{background:linear-gradient(160deg,rgba(1,94,101,.28),rgba(1,55,64,.82))}body[data-template="turquoise-party"] .wip-card:after{border-radius:28px;border-style:dashed;border-color:rgba(75,222,210,.32)}body[data-template="turquoise-party"] .wip-photo{border-radius:36% 64% 42% 58%}
body[data-template="purple-neon"] .wip-card:before{background:radial-gradient(circle at 20% 10%,rgba(255,90,210,.18),transparent 35%),linear-gradient(160deg,rgba(50,18,88,.55),rgba(20,8,45,.88))}body[data-template="purple-neon"] .wip-card:after{border-color:rgba(173,108,255,.35);box-shadow:inset 0 0 55px rgba(255,90,210,.08)}body[data-template="purple-neon"] .wip-photo{box-shadow:0 0 0 7px rgba(168,103,255,.08),0 0 32px rgba(255,90,210,.2)}
body[data-template="champagne-sage"] .wip-card:before{background:linear-gradient(180deg,rgba(58,83,70,.3),rgba(45,66,56,.78))}body[data-template="champagne-sage"] .wip-card:after{border-radius:90px 90px 24px 24px / 55px 55px 24px 24px;border-color:rgba(231,202,145,.3)}body[data-template="champagne-sage"] .wip-photo{border-radius:50% 50% 18px 18px}
body[data-template="ruby-festival"] .wip-card:before{background:linear-gradient(145deg,rgba(118,13,42,.38),rgba(58,4,21,.84))}body[data-template="ruby-festival"] .wip-card:after{border-color:rgba(241,190,82,.34);box-shadow:inset 0 0 0 4px rgba(241,190,82,.04)}body[data-template="ruby-festival"] .wip-date-box{background:rgba(111,16,42,.28)}
body[data-template="midnight-violet"] .wip-card:before{background:radial-gradient(circle at 70% 15%,rgba(124,92,196,.2),transparent 34%),linear-gradient(180deg,rgba(26,20,53,.42),rgba(15,12,35,.88))}body[data-template="midnight-violet"] .wip-card:after{border-color:rgba(190,162,245,.28);border-radius:36px}body[data-template="midnight-violet"] .wip-photo{border-radius:50%;box-shadow:0 0 0 9px rgba(190,162,245,.07)}
body[data-template="peach-confetti"] .wip-card:before{background:linear-gradient(160deg,rgba(138,63,69,.28),rgba(98,43,46,.78))}body[data-template="peach-confetti"] .wip-card:after{border-radius:22px 65px 22px 65px;border-color:rgba(255,211,134,.3)}body[data-template="peach-confetti"] .wip-photo{border-radius:20px 50% 20px 50%;transform:rotate(-1deg)}
body[data-template="azure-silver"] .wip-card:before{background:linear-gradient(155deg,rgba(25,78,125,.34),rgba(10,43,77,.84))}body[data-template="azure-silver"] .wip-card:after{border-color:rgba(191,216,233,.3);inset:18px}body[data-template="azure-silver"] .wip-photo{border-radius:10px;box-shadow:0 0 0 5px rgba(216,235,247,.07)}

/* Envelope model geometry: independent from card style */
.wip-envelope-screen[data-style="ivory"] .wip-envelope{transform:rotate(-.5deg)}
.wip-envelope-screen[data-style="rose"] .wip-envelope-back,.wip-envelope-screen[data-style="rose"] .wip-envelope-front{border-radius:26px}.wip-envelope-screen[data-style="rose"] .wip-envelope-flap{border-radius:26px 26px 0 0;clip-path:polygon(0 0,100% 0,50% 92%)}.wip-envelope-screen[data-style="rose"] .wip-envelope-seal{border-radius:48% 48% 52% 52%;transform:rotate(45deg)}.wip-envelope-screen[data-style="rose"] .wip-envelope-seal{font-size:0}.wip-envelope-screen[data-style="rose"] .wip-envelope-seal:after{content:"♥";font-size:17px;transform:rotate(-45deg)}
.wip-envelope-screen[data-style="navy"] .wip-envelope-back,.wip-envelope-screen[data-style="navy"] .wip-envelope-front{border-radius:4px}.wip-envelope-screen[data-style="navy"] .wip-envelope-flap{border-radius:4px 4px 0 0;clip-path:polygon(0 0,100% 0,50% 84%)}.wip-envelope-screen[data-style="navy"] .wip-envelope:after{content:"";position:absolute;inset:9px;z-index:6;border:1px solid rgba(240,213,146,.35);pointer-events:none}
.wip-envelope-screen[data-style="kraft"] .wip-envelope{transform:rotate(1deg)}.wip-envelope-screen[data-style="kraft"] .wip-envelope-back,.wip-envelope-screen[data-style="kraft"] .wip-envelope-front{border-radius:7px}.wip-envelope-screen[data-style="kraft"] .wip-envelope-front{background-image:repeating-linear-gradient(135deg,rgba(83,54,31,.035) 0 2px,transparent 2px 6px),linear-gradient(155deg,var(--env-paper),var(--env-paper-2))}.wip-envelope-screen[data-style="kraft"] .wip-envelope-seal{border-radius:9px;transform:rotate(45deg)}
.wip-envelope-screen[data-style="pearl"] .wip-envelope-back,.wip-envelope-screen[data-style="pearl"] .wip-envelope-front{border-radius:34px 34px 16px 16px}.wip-envelope-screen[data-style="pearl"] .wip-envelope-flap{border-radius:34px 34px 0 0;clip-path:ellipse(72% 100% at 50% 0%)}.wip-envelope-screen[data-style="pearl"] .wip-envelope-seal{width:46px;height:46px;margin:-23px 0 0 -23px;border:1px solid rgba(255,255,255,.7)}
.wip-envelope-screen[data-style="emerald"] .wip-envelope-back,.wip-envelope-screen[data-style="emerald"] .wip-envelope-front{border-radius:18px}.wip-envelope-screen[data-style="emerald"] .wip-envelope-flap{clip-path:polygon(0 0,100% 0,72% 52%,50% 100%,28% 52%)}.wip-envelope-screen[data-style="emerald"] .wip-envelope-seal{border-radius:14px 14px 50% 50%}
.wip-envelope-screen[data-style="blush"] .wip-envelope-back,.wip-envelope-screen[data-style="blush"] .wip-envelope-front{border-radius:40px 10px 40px 10px}.wip-envelope-screen[data-style="blush"] .wip-envelope-flap{border-radius:40px 10px 0 0;clip-path:polygon(0 0,100% 0,50% 88%)}.wip-envelope-screen[data-style="blush"] .wip-envelope-letter{border-radius:22px 6px 22px 6px}
.wip-envelope-screen[data-style="lavender"] .wip-envelope-back,.wip-envelope-screen[data-style="lavender"] .wip-envelope-front{border-radius:50% 50% 14px 14px / 18% 18% 14px 14px}.wip-envelope-screen[data-style="lavender"] .wip-envelope-flap{border-radius:50% 50% 0 0 / 35% 35% 0 0;clip-path:polygon(0 0,100% 0,50% 94%)}.wip-envelope-screen[data-style="lavender"] .wip-envelope-seal{box-shadow:0 0 0 7px rgba(255,255,255,.12),0 5px 12px rgba(55,24,36,.25)}
.wip-envelope-screen[data-style="charcoal"] .wip-envelope-back,.wip-envelope-screen[data-style="charcoal"] .wip-envelope-front{border-radius:0}.wip-envelope-screen[data-style="charcoal"] .wip-envelope-flap{border-radius:0;clip-path:polygon(0 0,100% 0,58% 100%,42% 100%)}.wip-envelope-screen[data-style="charcoal"] .wip-envelope-seal{border-radius:3px;transform:rotate(45deg)}.wip-envelope-screen[data-style="charcoal"] .wip-envelope-seal{font-size:0}.wip-envelope-screen[data-style="charcoal"] .wip-envelope-seal:after{content:"◆";font-size:14px;transform:rotate(-45deg)}
.wip-envelope-screen[data-style="sky"] .wip-envelope-back,.wip-envelope-screen[data-style="sky"] .wip-envelope-front{border-radius:36px}.wip-envelope-screen[data-style="sky"] .wip-envelope-front{clip-path:polygon(0 22%,18% 36%,35% 49%,50% 61%,65% 49%,82% 36%,100% 22%,100% 100%,0 100%)}.wip-envelope-screen[data-style="sky"] .wip-envelope-flap{border-radius:36px 36px 0 0;clip-path:polygon(0 0,100% 0,82% 22%,65% 43%,50% 72%,35% 43%,18% 22%)}
@media(max-width:420px){.wip-envelope{width:min(92vw,390px);min-height:160px}.wip-envelope-letter{left:7%;right:7%;padding-inline:11px}.wip-envelope-heading{padding-inline:10px}.wip-envelope-screen[data-style="rose"] .wip-envelope-back,.wip-envelope-screen[data-style="rose"] .wip-envelope-front,.wip-envelope-screen[data-style="sky"] .wip-envelope-back,.wip-envelope-screen[data-style="sky"] .wip-envelope-front{border-radius:22px}}


/* Venue navigation */
.wip-venue-actions{display:flex;align-items:center;justify-content:center;gap:8px;flex-wrap:wrap;margin-top:12px}.wip-location-button,.wip-location-google{border-radius:11px;min-height:38px;padding:8px 12px;font:700 11px/1.4 var(--wip-font);text-decoration:none;display:inline-flex;align-items:center;justify-content:center;gap:6px;cursor:pointer}.wip-location-button{border:1px solid rgba(255,255,255,.2);background:rgba(255,255,255,.14);color:inherit}.wip-location-google{border:1px solid rgba(255,255,255,.14);background:transparent;color:inherit;opacity:.88}.wip-location-button span{font-size:18px;line-height:1}
@media(max-width:580px){.wip-date-text{font-size:clamp(9px,3vw,12px);white-space:nowrap}.wip-venue-actions{display:grid;grid-template-columns:1fr;width:100%}.wip-location-button,.wip-location-google{width:100%}}
