/* ==========================================================================
   Undangan — tema Garden Envelope: amplop bunga, hijau zaitun, magenta & pita pink
   ========================================================================== */
:root {
  --olive: #5b6a3a;
  --olive-2: #4a5830;
  --olive-3: #73844a;
  --olive-ink: #2f3a1c;
  --magenta: #b14a7b;
  --magenta-2: #8d2f5d;
  --pink: #f0a7c4;
  --pink-2: #e98bb5;
  --rasp: #a8466f;
  --cream: #f2e8d2;
  --cream-2: #eadcc0;
  --gold: #e6c36a;
  --script: 'Pinyon Script', cursive;
  --serif: 'Cinzel', Georgia, serif;
  --sans: 'Quicksand', system-ui, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
  --pop: cubic-bezier(0.34, 1.56, 0.64, 1);
  --grain: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix values='0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 0 .55 0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='.35'/%3E%3C/svg%3E");
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
html, body { margin: 0; }
body {
  color: var(--cream);
  font: 400 16px/1.65 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  background:
    var(--grain),
    radial-gradient(ellipse at 50% 0%, rgba(140, 158, 92, 0.45), transparent 60%),
    radial-gradient(ellipse at 50% 100%, rgba(40, 50, 22, 0.5), transparent 60%),
    var(--olive);
  background-attachment: fixed;
}
body.is-locked { overflow: hidden; height: 100svh; }
img { max-width: 100%; display: block; }
svg { fill: currentColor; }
a { color: inherit; }
button { font: inherit; color: inherit; }
.center { text-align: center; }
.muted { opacity: 0.75; }

#petals { position: fixed; inset: 0; width: 100%; height: 100%; pointer-events: none; z-index: 40; }
main { position: relative; z-index: 1; }

@keyframes gdSway { from { transform: rotate(var(--a, -4deg)); } to { transform: rotate(calc(var(--a, -4deg) * -1)); } }
@keyframes gdTwinkle { 0%, 100% { transform: scale(0.5) rotate(0); opacity: 0.35; } 50% { transform: scale(1.1) rotate(45deg); opacity: 1; } }
@keyframes gdFloat { from { transform: translateY(0); } to { transform: translateY(-8px); } }

/* ==========================================================================
   SAMPUL — AMPLOP
   ========================================================================== */
.gd-cover {
  position: fixed; inset: 0; z-index: 50; overflow: hidden;
  display: grid; place-items: center;
  background:
    var(--grain),
    radial-gradient(ellipse at 50% 40%, #c2588a, transparent 70%),
    var(--rasp);
}
.gd-cover-inner { width: 100%; max-width: 440px; padding: 24px 18px; display: flex; flex-direction: column; align-items: center; text-align: center; }
.gd-cover-eyebrow { font: 400 2.2rem var(--script); margin: 0 0 6px; color: var(--cream); animation: gdFadeDown 1.2s var(--ease) both; }
@keyframes gdFadeDown { from { opacity: 0; transform: translateY(-16px); } }

.gd-env {
  position: relative; width: min(88vw, 380px); aspect-ratio: 340 / 260; perspective: 1400px; margin-top: 60px;
  animation: gdEnvIn 1.4s var(--ease) both 0.2s, gdFloat 3s ease-in-out 1.6s infinite alternate;
}
@keyframes gdEnvIn { from { opacity: 0; transform: translateY(60px) rotate(-6deg) scale(0.9); } }
.gd-env > svg, .gd-env-flowers { position: absolute; inset: 0; width: 100%; height: 100%; }
.gd-env-back { z-index: 1; filter: drop-shadow(0 18px 30px rgba(60, 10, 30, 0.35)); }
.gd-env-front { z-index: 3; }
.gd-env-flap { z-index: 4; transform-origin: 50% 23.08%; backface-visibility: visible; filter: drop-shadow(0 4px 6px rgba(60, 10, 30, 0.15)); }
.gd-scallop { fill: none; stroke: #e2568a; stroke-width: 5; stroke-dasharray: 0.1 9; stroke-linecap: round; }
.gd-seal { font: 600 13px var(--serif); fill: var(--cream); letter-spacing: 0.5px; }
.gd-env-flap circle { animation: gdSeal 1.8s ease-in-out infinite; transform-box: fill-box; transform-origin: center; }
@keyframes gdSeal { 50% { transform: scale(1.12); } }

.gd-env-card {
  position: absolute; z-index: 2; left: 8%; width: 84%; top: 27%; height: 64%;
  background: var(--grain), linear-gradient(#475631, #3b4826);
  border-radius: 6px; padding: 8px 12px; color: var(--cream);
  display: flex; flex-direction: column; align-items: center; justify-content: flex-start;
  box-shadow: inset 0 0 0 1px rgba(242, 232, 210, 0.15);
}
.gd-env-bow { width: 100%; height: auto; }
.gd-env-names { font: 500 1.25rem var(--serif); letter-spacing: 0.08em; margin: 4px 0 0; }
.gd-env-names span { font: 400 1.1rem var(--serif); color: var(--pink); }
.gd-env-date { font-size: 0.75rem; letter-spacing: 0.2em; text-transform: uppercase; margin: 2px 0 0; opacity: 0.85; }

.gd-env-flowers { z-index: 0; }
.gd-env-flowers svg { position: absolute; transform-origin: 50% 100%; animation: gdSway 3.4s ease-in-out infinite alternate; }
.gd-env-flowers .f1 { width: 26%; left: 4%; top: -3%; --a: -6deg; }
.gd-env-flowers .f2 { width: 9%; left: 22%; top: -10%; --a: 5deg; animation-duration: 4s; }
.gd-env-flowers .f3 { width: 22%; left: 26%; top: 3%; --a: 4deg; animation-duration: 3.8s; }
.gd-env-flowers .f4 { width: 25%; right: 8%; top: -5%; --a: 6deg; animation-duration: 3.1s; }
.gd-env-flowers .f5 { width: 9%; right: 28%; top: -10%; --a: -5deg; animation-duration: 4.2s; }
.gd-env-flowers .f6 { width: 22%; right: 30%; top: 1%; --a: -4deg; }

.gd-to { display: flex; flex-direction: column; margin: 34px 0 18px; font-size: 0.9rem; opacity: 0.95; animation: gdFadeDown 1s var(--ease) 0.6s both; }
.gd-to strong { font: 500 1.4rem var(--serif); letter-spacing: 0.06em; }

.gd-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px; text-decoration: none; cursor: pointer;
  border: 1.5px solid var(--cream); background: var(--cream); color: var(--magenta-2);
  font: 600 0.9rem var(--sans); letter-spacing: 0.12em; text-transform: uppercase;
  padding: 12px 26px; border-radius: 999px; box-shadow: 0 10px 24px rgba(40, 10, 25, 0.25);
  transition: transform 0.25s var(--ease), background 0.25s, color 0.25s;
}
.gd-btn svg { width: 17px; height: 17px; }
.gd-btn:hover { transform: translateY(-2px); }
#openBtn { animation: gdFadeDown 1s var(--ease) 0.8s both, gdGlow 2.4s ease-in-out 2s infinite; }
@keyframes gdGlow { 50% { box-shadow: 0 0 0 8px rgba(242, 232, 210, 0.18), 0 10px 24px rgba(40, 10, 25, 0.25); } }
.gd-btn.sm { padding: 9px 18px; font-size: 0.75rem; color: var(--olive-ink); }
.gd-btn.ghost { background: transparent; color: var(--cream); }

/* urutan membuka amplop */
.gd-cover.is-opening { animation: gdCoverOut 0.9s ease 2.2s forwards; pointer-events: none; }
.gd-cover.is-opening .gd-env { animation: gdEnvOut 1s var(--ease) 1.8s forwards; }
.gd-cover.is-opening .gd-env-flap { animation: gdFlap 0.9s cubic-bezier(0.6, 0, 0.3, 1) forwards; }
.gd-cover.is-opening .gd-env-flap circle, .gd-cover.is-opening .gd-seal { opacity: 0; transition: opacity 0.25s; }
.gd-cover.is-opening .gd-env-card { animation: gdCard 1s var(--ease) 0.8s forwards; }
.gd-cover.is-opening .gd-to, .gd-cover.is-opening #openBtn, .gd-cover.is-opening .gd-cover-eyebrow { animation: gdFadeAway 0.5s ease forwards; }
@keyframes gdFlap { 0% { transform: rotateX(0); z-index: 4; } 49% { z-index: 4; } 50% { z-index: 1; } 100% { transform: rotateX(180deg); z-index: 1; } }
@keyframes gdCard { to { transform: translateY(-62%); box-shadow: 0 20px 40px rgba(30, 10, 20, 0.35); } }
@keyframes gdEnvOut { to { transform: scale(1.7) translateY(10%); opacity: 0; filter: blur(4px); } }
@keyframes gdCoverOut { to { opacity: 0; visibility: hidden; } }
@keyframes gdFadeAway { to { opacity: 0; transform: translateY(12px); } }

/* ==========================================================================
   BINGKAI PITA & BUNGA (tetap di layar)
   ========================================================================== */
.gd-decor {
  position: fixed; top: 0; bottom: 0; left: 50%; width: min(100%, 520px); transform: translateX(-50%);
  z-index: 30; pointer-events: none; opacity: 0; transition: opacity 1.2s ease 0.3s;
}
body.is-open .gd-decor { opacity: 1; }
.gd-ribbon-top { position: absolute; top: 0; left: 0; width: 100%; height: 70px; }
.gd-ribbon-line, .gd-bow-tail { fill: none; stroke: var(--pink); stroke-width: 4; stroke-linecap: round; }
.gd-bow { fill: var(--pink); transform-box: fill-box; transform-origin: 50% 30%; animation: gdBow 2.6s ease-in-out infinite alternate; }
@keyframes gdBow { from { transform: rotate(-4deg) scale(1); } to { transform: rotate(4deg) scale(1.05); } }
.gd-dots { fill: var(--pink); }
.gd-ribbon-side {
  position: absolute; top: 46px; bottom: 0; width: 26px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='26' height='120'%3E%3Cpath d='M13 0 C25 30 1 30 13 60 C25 90 1 90 13 120' fill='none' stroke='%23f0a7c4' stroke-width='3.5'/%3E%3Ccircle cx='22' cy='32' r='2.3' fill='%23f0a7c4'/%3E%3Ccircle cx='4' cy='92' r='2.3' fill='%23f0a7c4'/%3E%3C/svg%3E") repeat-y;
  animation: gdRibbonFlow 12s linear infinite;
}
.gd-ribbon-side.l { left: 2px; }
.gd-ribbon-side.r { right: 2px; animation-direction: reverse; }
@keyframes gdRibbonFlow { to { background-position: 0 120px; } }

.gd-top-flowers { position: absolute; top: 56px; width: 70px; height: 120px; }
.gd-top-flowers.l { left: 0; }
.gd-top-flowers.r { right: 0; }
.gd-top-flowers svg { position: absolute; width: 38px; height: 38px; transform-origin: 50% 0; animation: gdSway 3s ease-in-out infinite alternate; }
.gd-top-flowers .t1 { top: 0; left: 4px; --a: 8deg; }
.gd-top-flowers .t2 { top: 34px; left: 18px; width: 32px; height: 32px; --a: -6deg; animation-duration: 3.6s; }
.gd-top-flowers .t3 { top: 64px; left: 2px; width: 28px; height: 28px; --a: 5deg; animation-duration: 4.1s; }
.gd-top-flowers.r .t1 { left: auto; right: 4px; }
.gd-top-flowers.r .t2 { left: auto; right: 18px; }
.gd-top-flowers.r .t3 { left: auto; right: 2px; }

.gd-cluster { position: absolute; bottom: -14px; width: 140px; height: 190px; }
.gd-cluster-l { left: -30px; }
.gd-cluster-r { right: -30px; transform: scaleX(-1); }
.gd-stem { position: absolute; bottom: 0; transform-origin: 50% 100%; animation: gdSway 3.2s ease-in-out infinite alternate; }
.gd-stem.s1 { left: 20px; width: 34px; height: 120px; --a: -8deg; animation-duration: 4.2s; }
.gd-stem.s2 { left: 62px; width: 30px; height: 100px; --a: 7deg; animation-duration: 3.7s; }
.gd-stem.s3 { left: 34px; bottom: 30px; width: 76px; height: 92px; --a: -5deg; }
.gd-stem.s4 { left: 6px; bottom: 70px; width: 56px; height: 56px; --a: 6deg; animation-duration: 2.9s; }
.gd-stem.s5 { left: 70px; bottom: 96px; width: 44px; height: 44px; --a: -7deg; animation-duration: 3.4s; }
.gd-stem.s6 { left: 40px; bottom: 130px; width: 36px; height: 36px; --a: 5deg; animation-duration: 4s; }
.gd-stem.s7 { left: 84px; bottom: 20px; width: 50px; height: 50px; --a: 6deg; animation-duration: 3.1s; }

/* ==========================================================================
   SECTION
   ========================================================================== */
.gd-main { max-width: 520px; margin: 0 auto; }
.gd-sec { position: relative; padding: 76px 46px 40px; text-align: center; }
.gd-script { font: 400 2.3rem/1.2 var(--script); color: var(--cream); margin: 0; }
.gd-script.big { font-size: clamp(2.8rem, 12vw, 3.6rem); }
.gd-names { font: 500 clamp(2.4rem, 11vw, 3.4rem)/1.1 var(--serif); letter-spacing: 0.05em; margin: 4px 0 18px; text-transform: uppercase; }
.gd-names span { font: 400 0.8em var(--serif); color: var(--pink); }
.gd-names.sm { font-size: clamp(1.8rem, 8vw, 2.4rem); margin-top: 26px; }
.gd-lead { margin: 0 auto; max-width: 26em; font-size: 0.98rem; }
.gd-sub { margin: 6px 0 24px; opacity: 0.85; }

.gd-hero { padding-top: 96px; min-height: 100svh; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.gd-hero-date { font: 500 0.95rem var(--sans); letter-spacing: 0.24em; text-transform: uppercase; margin: 18px 0 0; }

/* bingkai quatrefoil */
.gd-qf-wrap { width: min(300px, 82%); margin: 0 auto; }
.gd-qf-wrap.sm { width: min(220px, 66%); }
.gd-qf { width: 100%; height: auto; display: block; overflow: visible; }
.gd-qf-wrap.in .gd-qf { animation: gdFloat 3.2s ease-in-out infinite alternate; }
.qf-glow { fill: none; stroke: rgba(36, 46, 18, 0.35); stroke-width: 44; }
.qf-outer { fill: none; stroke: #93a55c; stroke-width: 26; }
.qf-fill { fill: var(--magenta); stroke: var(--magenta); stroke-width: 6; }
.qf-pearls { fill: none; stroke: #fbf3f6; stroke-width: 6; stroke-dasharray: 0 12; stroke-linecap: round; animation: gdPearls 4s linear infinite; }
@keyframes gdPearls { to { stroke-dashoffset: -48; } }
.qf-initial { font: 500 64px var(--serif); fill: var(--cream); letter-spacing: 2px; }

/* kutipan */
.gd-divider { width: 150px; height: 16px; margin: 0 auto 20px; display: block; fill: var(--cream); stroke: var(--cream); stroke-width: 1.4; }
.gd-divider.gold { fill: var(--gold); stroke: var(--gold); margin: 6px auto 18px; }
.gd-quote-text { margin: 0 auto 10px; font-size: 1rem; line-height: 1.75; font-style: italic; max-width: 26em; }
.gd-quote cite { display: block; font: 500 0.85rem var(--serif); letter-spacing: 0.16em; color: var(--gold); font-style: normal; margin-bottom: 34px; }
[data-words] .w { display: inline-block; opacity: 0; transform: translateY(10px); filter: blur(4px); transition: opacity 0.6s, transform 0.8s var(--ease), filter 0.6s; }
[data-words].in .w { opacity: 1; transform: none; filter: none; }
.gd-bismillah { font: 700 1.9rem/1.6 'Amiri', serif; color: var(--pink); margin: 0 0 8px; }
.gd-salam { font-weight: 500; margin: 0 0 14px; }

/* mempelai */
.gd-couple { display: flex; flex-direction: column; align-items: center; gap: 4px; }
.gd-person { display: flex; flex-direction: column; align-items: center; }
.gd-person-name { font: 600 clamp(1.15rem, 5.4vw, 1.5rem)/1.3 var(--serif); letter-spacing: 0.06em; text-transform: uppercase; margin: 16px 0 6px; }
.gd-parents { margin: 0; font-size: 0.9rem; opacity: 0.92; }
.gd-ig { display: inline-flex; align-items: center; gap: 6px; margin-top: 10px; text-decoration: none; font-size: 0.85rem; padding: 5px 14px; border: 1px solid rgba(242, 232, 210, 0.5); border-radius: 999px; }
.gd-ig svg { width: 15px; height: 15px; }
.gd-amp { font: 400 2.8rem/1 var(--serif); color: var(--pink); margin: 14px 0; }

/* save the date */
.gd-sparkle { position: absolute; width: 20px; height: 20px; fill: var(--gold); animation: gdTwinkle 2.6s ease-in-out infinite; }
.gd-sparkle.sp1 { top: 60px; right: 40px; }
.gd-sparkle.sp2 { top: 180px; left: 34px; width: 14px; height: 14px; animation-delay: -0.8s; }
.gd-sparkle.sp3 { top: 330px; right: 56px; width: 12px; height: 12px; animation-delay: -1.4s; }
.gd-sparkle.sp4 { bottom: 140px; left: 50px; animation-delay: -2s; }
.gd-month { font: 500 1.35rem var(--sans); letter-spacing: 0.12em; margin: 18px 0 0; }
.gd-week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 2px; margin: 0 -18px 30px; }
.gd-week-cell { position: relative; display: flex; flex-direction: column; align-items: center; gap: 4px; padding: 6px 0; }
.gd-week-cell span { font-size: 0.78rem; opacity: 0.9; }
.gd-week-cell b { font-weight: 500; font-size: 0.95rem; }
.gd-heart {
  position: absolute; left: 50%; top: 50%; width: 80px; height: 75px; margin: -40px 0 0 -40px; z-index: 2;
  display: flex; flex-direction: column; align-items: center; justify-content: center; padding-bottom: 14px;
  color: var(--magenta-2); animation: gdBeat 1.6s ease-in-out infinite;
}
.gd-heart svg { position: absolute; inset: 0; width: 100%; height: 100%; fill: #fbf3e4; stroke: var(--gold); stroke-width: 5; filter: drop-shadow(0 6px 10px rgba(30, 40, 10, 0.3)); }
.gd-heart small, .gd-heart strong { position: relative; line-height: 1.05; }
.gd-heart small { font: 600 0.62rem var(--serif); letter-spacing: 0.08em; text-transform: uppercase; }
.gd-heart strong { font: 600 1.5rem var(--serif); }
@keyframes gdBeat { 0%, 100% { transform: scale(1); } 15% { transform: scale(1.1); } 30% { transform: scale(0.98); } 45% { transform: scale(1.06); } }

.gd-countdown { display: flex; justify-content: center; gap: 10px; margin: 6px 0 34px; }
.gd-countdown > div { width: 64px; padding: 10px 0 8px; border: 1px solid rgba(242, 232, 210, 0.45); border-radius: 32px 32px 12px 12px; background: rgba(36, 46, 18, 0.25); display: flex; flex-direction: column; align-items: center; }
.gd-countdown b { font: 600 1.5rem/1 var(--serif); color: var(--gold); font-variant-numeric: lining-nums tabular-nums; }
.gd-countdown b.tick { animation: gdTick 0.4s var(--pop); }
@keyframes gdTick { from { transform: scale(1.25); } }
.gd-countdown span { font-size: 0.68rem; letter-spacing: 0.14em; text-transform: uppercase; margin-top: 4px; }

.gd-event { margin: 0 auto 36px; padding: 26px 18px 24px; border: 1px solid rgba(242, 232, 210, 0.35); border-radius: 140px 140px 18px 18px; background: rgba(36, 46, 18, 0.22); }
.gd-event-name { font: 600 1.35rem var(--serif); letter-spacing: 0.12em; text-transform: uppercase; margin: 10px 0 12px; color: var(--cream); }
.gd-label { font: 600 0.95rem var(--sans); color: var(--gold); margin: 12px 0 2px; letter-spacing: 0.06em; }
.gd-value { margin: 0; font-size: 1rem; font-weight: 500; }
.gd-address { margin: 4px 0 0; font-size: 0.88rem; opacity: 0.85; }
.gd-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 18px; }

/* ==========================================================================
   RSVP & UCAPAN
   ========================================================================== */
.rsvp-form {
  text-align: left; color: var(--olive-ink); background: var(--grain), var(--cream);
  border-radius: 20px; padding: 24px 18px; display: flex; flex-direction: column; gap: 16px;
  box-shadow: 0 20px 44px rgba(20, 28, 8, 0.35); border: 3px solid var(--pink);
}
.field { display: flex; flex-direction: column; gap: 8px; }
.field-label { font: 600 0.72rem var(--sans); letter-spacing: 0.18em; text-transform: uppercase; color: var(--magenta-2); }
.field-label small { text-transform: none; letter-spacing: 0; font-weight: 500; }
.field-static { font: 600 1.25rem var(--serif); letter-spacing: 0.04em; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip input { position: absolute; opacity: 0; pointer-events: none; }
.chip span { display: inline-block; padding: 8px 16px; border-radius: 999px; border: 1.5px solid var(--magenta); color: var(--magenta-2); background: #fff8; cursor: pointer; transition: all 0.25s var(--pop); font-weight: 500; font-size: 0.9rem; }
.chip input:checked + span { background: var(--magenta); color: #fff; transform: scale(1.06); }
.chip input:focus-visible + span { outline: 2px solid var(--olive); outline-offset: 2px; }
.stepper { display: inline-flex; align-items: center; align-self: flex-start; border: 1.5px solid var(--magenta); border-radius: 999px; background: #fff8; }
.stepper button { width: 42px; height: 42px; border: 0; background: none; font-size: 1.3rem; cursor: pointer; color: var(--magenta-2); }
.stepper output { min-width: 34px; text-align: center; font: 600 1.3rem var(--serif); }
.rsvp-form textarea { font: inherit; width: 100%; border: 1.5px solid var(--cream-2); border-radius: 14px; padding: 10px 12px; background: #fffaf0; resize: vertical; min-height: 96px; color: var(--olive-ink); }
.rsvp-form textarea:focus { outline: none; border-color: var(--magenta); box-shadow: 0 0 0 3px rgba(177, 74, 123, 0.15); }
.btn-solid { border: 0; cursor: pointer; padding: 13px; border-radius: 999px; background: var(--magenta); color: #fff; font: 600 0.85rem var(--sans); letter-spacing: 0.14em; text-transform: uppercase; transition: transform 0.2s var(--ease), opacity 0.2s; }
.btn-solid:hover { transform: translateY(-2px); }
.btn-solid:disabled { opacity: 0.6; }
.form-note { margin: 0; text-align: center; font-size: 0.85rem; opacity: 0.8; min-height: 1em; }
.is-hidden-field { display: none; }

.wishes { margin-top: 34px; }
.wishes-count { font: 400 1.9rem var(--script); text-align: center; margin: 0 0 10px; }
.wish-scroll { max-height: 440px; overflow-y: auto; padding: 4px; display: flex; flex-direction: column; gap: 10px; scrollbar-width: thin; scrollbar-color: var(--pink) transparent; text-align: left; }
.wish { display: flex; gap: 12px; background: rgba(242, 232, 210, 0.12); border: 1px solid rgba(242, 232, 210, 0.3); border-radius: 16px; padding: 12px 14px; animation: wishIn 0.6s var(--ease) both; }
.wish .avatar { flex: none; width: 36px; height: 36px; border-radius: 50%; display: grid; place-items: center; background: var(--magenta); color: var(--cream); font: 600 1rem var(--serif); box-shadow: 0 0 0 2px var(--pink); }
.wish header { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.wish header strong { font-weight: 600; }
.wish header em { font-style: normal; font-size: 0.7rem; padding: 1px 9px; border-radius: 999px; background: var(--pink); color: var(--magenta-2); font-weight: 600; }
.wish p { margin: 3px 0; font-size: 0.92rem; word-break: break-word; }
.wish time { font-size: 0.74rem; opacity: 0.7; }
@keyframes wishIn { from { opacity: 0; transform: translateY(10px); } }

/* ==========================================================================
   TIKET QR
   ========================================================================== */
.ticket-intro { margin: 8px 0 26px; opacity: 0.9; }
.ticket { position: relative; width: min(320px, 100%); margin: 0 auto; filter: drop-shadow(0 24px 40px rgba(20, 28, 8, 0.45)); }
.ticket-top { position: relative; text-align: center; color: var(--olive-ink); padding: 34px 22px 20px; border-radius: 160px 160px 0 0; background: var(--grain), var(--cream); overflow: hidden; }
.ticket-brand { font: 400 1.7rem var(--script); color: var(--magenta); }
.ticket-label { font-size: 0.66rem; letter-spacing: 0.3em; text-transform: uppercase; margin: 2px 0; opacity: 0.7; }
.ticket-name { font: 600 1.4rem/1.2 var(--serif); margin: 0; letter-spacing: 0.04em; }
.ticket-pax { font-size: 0.85rem; opacity: 0.75; margin: 4px 0 14px; }
.qr-wrap { position: relative; display: inline-block; padding: 12px; border: 0; cursor: zoom-in; background: #fff; border-radius: 18px; overflow: hidden; box-shadow: 0 0 0 4px var(--magenta), 0 0 0 7px var(--pink); }
#qrCanvas img, #qrCanvas canvas { display: block; width: 190px; height: 190px; }
.qr-shine { position: absolute; inset: 0; background: linear-gradient(115deg, transparent 35%, rgba(255, 255, 255, 0.75) 50%, transparent 65%); transform: translateX(-120%); animation: shine 4s ease-in-out infinite 1.5s; pointer-events: none; }
@keyframes shine { 30%, 100% { transform: translateX(120%); } }
.ticket-code { font: 500 1rem ui-monospace, Consolas, monospace; letter-spacing: 0.25em; margin: 14px 0 0; }
.ticket-cut { height: 26px; position: relative; background:
    radial-gradient(circle at 0 50%, transparent 13px, var(--magenta) 14px) left / 51% 100% no-repeat,
    radial-gradient(circle at 100% 50%, transparent 13px, var(--magenta) 14px) right / 51% 100% no-repeat; }
.ticket-cut::after { content: ''; position: absolute; left: 22px; right: 22px; top: 50%; border-top: 3px dotted rgba(251, 243, 246, 0.8); }
.ticket-bottom { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; background: var(--magenta); padding: 6px 22px 22px; border-radius: 0 0 18px 18px; color: var(--cream); text-align: left; }
.ticket-bottom div { display: flex; flex-direction: column; }
.ticket-bottom small { font-size: 0.64rem; letter-spacing: 0.2em; text-transform: uppercase; opacity: 0.75; }
.ticket-bottom strong { font: 600 0.95rem/1.3 var(--serif); }
.ticket-actions { display: flex; justify-content: center; gap: 10px; margin-top: 26px; flex-wrap: wrap; }
.btn-pill { display: inline-flex; align-items: center; gap: 8px; padding: 10px 18px; border-radius: 999px; border: 1.5px solid var(--cream); background: var(--cream); color: var(--olive-ink); cursor: pointer; text-decoration: none; font: 600 0.8rem var(--sans); letter-spacing: 0.08em; text-transform: uppercase; transition: transform 0.2s var(--ease); }
.btn-pill svg { width: 16px; height: 16px; }
.btn-pill:hover { transform: translateY(-2px); }
.btn-pill.ghost { background: transparent; color: var(--cream); }
.ticket-empty .ticket-top { border-radius: 160px 160px 22px 22px; padding: 50px 30px 34px; }
.ticket-empty p { margin: 12px 0 0; opacity: 0.8; }
.stamp {
  position: absolute; top: 48%; left: 50%; transform: translate(-50%, -50%) rotate(-14deg);
  border: 3px double var(--magenta); color: var(--magenta); background: rgba(242, 232, 210, 0.92);
  padding: 8px 18px; border-radius: 10px; font: 600 1rem var(--serif); letter-spacing: 0.12em; text-transform: uppercase;
  display: flex; flex-direction: column; align-items: center;
}
.stamp small { font: 500 0.7rem var(--sans); letter-spacing: 0.08em; }
.ticket.is-used .qr-wrap { opacity: 0.35; filter: grayscale(1); }

/* ==========================================================================
   PENUTUP
   ========================================================================== */
.gd-closing .gd-lead { margin-bottom: 30px; }
.gd-closing .gd-script.big { margin-top: 24px; }
.gd-families { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin: 18px 0 0; font-size: 0.88rem; }
.gd-families strong { font-weight: 600; }
.gd-hashtag { font: 600 0.82rem var(--sans); letter-spacing: 0.18em; color: var(--pink); margin: 8px 0 0; }
.foot { text-align: center; padding: 30px 20px 120px; font-size: 0.72rem; letter-spacing: 0.25em; text-transform: uppercase; opacity: 0.6; }

/* ==========================================================================
   KONTROL MENGAMBANG
   ========================================================================== */
.dock {
  position: fixed; left: 50%; bottom: max(16px, env(safe-area-inset-bottom)); z-index: 45;
  display: flex; gap: 2px; padding: 6px;
  background: rgba(47, 58, 28, 0.82); backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border: 1.5px solid var(--pink); border-radius: 999px;
  transform: translate(-50%, 160%); transition: transform 0.7s var(--ease) 0.4s;
}
body.is-open .dock { transform: translate(-50%, 0); }
.dock a { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 50%; color: rgba(242, 232, 210, 0.75); transition: background 0.25s, color 0.25s; }
.dock a svg { width: 19px; height: 19px; }
.dock a.on { background: var(--pink); color: var(--magenta-2); }

.music {
  position: fixed; top: max(70px, calc(env(safe-area-inset-top) + 56px)); right: 64px; z-index: 45;
  width: 48px; height: 48px; border-radius: 50%; border: 0; cursor: pointer; padding: 0;
  background: transparent; opacity: 0; transform: scale(0.6); transition: opacity 0.5s, transform 0.5s var(--ease);
}
@media (min-width: 560px) { .music { right: calc(50% - 260px + 64px); } }
body.is-open .music { opacity: 1; transform: none; }
.disc {
  position: absolute; inset: 0; border-radius: 50%;
  background: repeating-radial-gradient(circle, #9a3d6a 0 2px, var(--magenta-2) 2px 4px);
  border: 2px solid var(--pink); box-shadow: 0 6px 18px rgba(20, 28, 8, 0.4);
  animation: spin 4s linear infinite; animation-play-state: paused;
}
@keyframes spin { to { transform: rotate(360deg); } }
.disc span { position: absolute; inset: 34%; border-radius: 50%; background: var(--cream); box-shadow: inset 0 0 0 4px var(--pink); }
.music.is-playing .disc { animation-play-state: running; }
.eq { position: absolute; right: -4px; bottom: -4px; display: flex; gap: 2px; align-items: flex-end; height: 16px; padding: 3px 4px; background: var(--cream); border-radius: 8px; }
.eq i { width: 3px; height: 4px; background: var(--magenta); border-radius: 2px; }
.music.is-playing .eq i { animation: eq 0.9s ease-in-out infinite; }
.music.is-playing .eq i:nth-child(2) { animation-delay: -0.3s; }
.music.is-playing .eq i:nth-child(3) { animation-delay: -0.6s; }
@keyframes eq { 50% { height: 12px; } }
.now-playing {
  position: fixed; top: max(82px, calc(env(safe-area-inset-top) + 68px)); right: 122px; z-index: 45;
  background: rgba(47, 58, 28, 0.85); color: var(--cream); border: 1px solid var(--pink);
  padding: 5px 13px; border-radius: 999px; font-size: 0.78rem; white-space: nowrap;
  opacity: 0; transform: translateX(10px); transition: opacity 0.5s, transform 0.5s var(--ease); pointer-events: none;
}
.now-playing.show { opacity: 1; transform: none; }

.qr-zoom { position: fixed; inset: 0; z-index: 80; background: #fff; display: grid; place-items: center; cursor: zoom-out; }
.qr-zoom[hidden] { display: none; }
.qr-zoom-inner { text-align: center; color: var(--olive-ink); }
.qr-zoom-inner canvas, .qr-zoom-inner img { width: min(80vw, 420px) !important; height: auto !important; margin: 0 auto; }
.qr-zoom-inner p { font: 600 1.4rem var(--serif); margin: 18px 0 4px; }
.qr-zoom-inner small { opacity: 0.7; }

.toast {
  position: fixed; left: 50%; bottom: 90px; z-index: 90; transform: translate(-50%, 20px);
  background: var(--olive-ink); color: var(--cream); padding: 10px 20px; border-radius: 999px; font-size: 0.9rem; border: 1px solid var(--pink);
  opacity: 0; pointer-events: none; transition: opacity 0.3s, transform 0.3s var(--ease); max-width: calc(100% - 32px); text-align: center;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.spark { position: fixed; z-index: 70; pointer-events: none; width: 8px; height: 8px; margin: -4px 0 0 -4px; border-radius: 50%; animation: spark 0.9s var(--ease) forwards; }
.spark.star { border-radius: 0; clip-path: polygon(50% 0, 61% 39%, 100% 50%, 61% 61%, 50% 100%, 39% 61%, 0 50%, 39% 39%); width: 12px; height: 12px; margin: -6px 0 0 -6px; }
@keyframes spark { to { transform: translate(var(--dx), var(--dy)) scale(0.2) rotate(180deg); opacity: 0; } }

/* ==========================================================================
   ANIMASI MUNCUL SAAT DIGULIR
   ========================================================================== */
[data-reveal] { opacity: 0; transition: opacity 1.1s var(--ease), transform 1.1s var(--ease), filter 1.1s var(--ease); }
[data-reveal='up'] { transform: translateY(36px); }
[data-reveal='down'] { transform: translateY(-26px); }
[data-reveal='zoom'] { transform: scale(0.7) rotate(-6deg); }
[data-reveal='blur'] { filter: blur(12px); transform: scale(1.08); }
[data-reveal].in { opacity: 1; transform: none; filter: none; }

@media (max-width: 380px) {
  .gd-sec { padding-left: 38px; padding-right: 38px; }
  .gd-week { margin: 0 -14px 30px; }
  .gd-heart { width: 68px; height: 64px; margin: -34px 0 0 -34px; }
  .gd-countdown > div { width: 56px; }
  .gd-cluster { transform: scale(0.8); transform-origin: 0 100%; }
  .gd-cluster-r { transform: scaleX(-0.8) scaleY(0.8); }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.2s !important; }
  [data-reveal], [data-words] .w { transform: none !important; filter: none !important; }
  #petals { display: none; }
}
