@font-face {
  font-family: 'Great Vibes';
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url('../fonts/great-vibes-regular.ttf') format('truetype');
}

/* ===== 1. TOKEN WARNA & FONT ===== */
:root {
  --cream: #f5e9dc;
  --cream-2: #efdfce;
  --brown: #3b2a25;
  --brown-2: #5b463c;
  --ink: #5a463d;
  --gold: #c4a26a;
  --gold-d: #a98147;
  --button-gold: linear-gradient(135deg, #916a2e, #7e581f 55%, #624117);
  --copper: #d08c5b;
  /* aksen baru: biru muda, putih, pink, merah rose */
  --sky: #bcdcf0;
  --sky-2: #e8f3fb;
  --sky-d: #7fb3d5;
  --white: #ffffff;
  --pink: #f4c6d0;
  --pink-2: #fdeef1;
  --rose: #c2445a;
  --rose-l: #d9687c;
  --rose-d: #a3304a;
  --f-head: 'Playfair Display', serif;
  --f-body: 'DM Sans', sans-serif;
  --f-it: 'Lora', serif;
  --f-script: 'Great Vibes', cursive;
  box-sizing: border-box;
  padding-top: env(safe-area-inset-top, 0px);
  padding-bottom: env(safe-area-inset-bottom, 0px);
}

html {
  scroll-padding-top: env(safe-area-inset-top, 0px);
  scroll-behavior: smooth;
}

html.auto-scrolling {
  scroll-behavior: auto;
}

html.locked,
html.locked body {
  overflow: hidden;
  height: 100%;
}

* {
  box-sizing: border-box;
  margin: 0;
}

::selection {
  background: var(--pink);
  color: var(--brown);
}

body {
  background: var(--cream);
  color: var(--ink);
  font: 300 15px/1.8 var(--f-body);
}

.wrap {
  max-width: 480px;
  margin: 0 auto;
  background: var(--cream);
  position: relative;
  overflow: hidden;
  box-shadow: 0 0 40px rgba(90, 60, 40, 0.12);
}

/* ===== 2. SLOT GAMBAR (isi nama file di ASSETS; jika belum ada, tampil latar bawaan) ===== */
.slot {
  position: absolute;
  pointer-events: none;
}

.slot img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}

.slot.bg {
  inset: 0;
}

.deco {
  mix-blend-mode: multiply;
  width: 52%;
  z-index: 1;
  height: auto;
}

.deco img {
  height: auto;
  object-fit: initial;
}

.d-tr {
  top: 0;
  right: 0;
}

.d-tl {
  top: 0;
  left: 0;
  transform: scaleX(-1);
}

/* ===== 3. COVER (ukuran font memakai cqw supaya selalu proporsional dengan gambar) ===== */
.cover {
  position: relative;
  container-type: inline-size;
  aspect-ratio: 857 / 1536;
  background: var(--cream);
  overflow: hidden;
}

.cover::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  background:
    radial-gradient(60% 34% at 0% 60%, rgba(188, 220, 240, 0.55), transparent 70%),
    radial-gradient(55% 28% at 100% 90%, rgba(244, 198, 208, 0.55), transparent 70%),
    radial-gradient(45% 22% at 8% 6%, rgba(255, 255, 255, 0.75), transparent 70%);
}

.hero {
  position: absolute;
  left: 8.5%;
  right: 5%;
  top: 19.4%;
  z-index: 3;
}

.lab {
  font: 400 clamp(0.65rem, 2.3cqw, 0.8rem)/1.4 var(--f-body);
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--rose-d);
}

.names {
  width: fit-content;
  max-width: 100%;
  font: 400 clamp(2rem, 10.2cqw, 3.1rem)/1.25 var(--f-script);
  text-align: left;
  color: var(--rose);
  text-shadow: 0 2px 0 rgba(244, 198, 208, 0.7), 0 4px 10px rgba(188, 220, 240, 0.8);
  margin-top: 2.5cqw;
}

.names span {
  display: block;
  overflow-wrap: anywhere;
}

.names-amp {
  display: block;
  width: clamp(18px, 6cqw, 29px);
  height: clamp(22px, 7.5cqw, 36px);
  margin: 2cqw auto;
  overflow: visible;
}

.divider {
  display: flex;
  align-items: center;
  gap: 2.5cqw;
  margin: 5cqw 0 6cqw;
}

.divider i {
  flex: 1;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, var(--sky), var(--pink));
}

.divider i:last-child {
  background: linear-gradient(90deg, var(--pink), var(--sky), transparent);
}

.divider svg {
  width: clamp(30px, 11cqw, 52px);
  height: clamp(30px, 11cqw, 52px);
}

.tag {
  font: italic clamp(0.875rem, 4.3cqw, 1.3rem)/1.65 var(--f-it);
  color: #3a2823;
}

.cover-description {
  max-width: none;
  margin: 0;
}

.cover-story {
  font-size: clamp(0.75rem, 3.5cqw, 1.05rem);
}

.invited {
  display: flex;
  align-items: center;
  gap: 2cqw;
  margin: 8cqw 0 5cqw -3cqw;
}

.invited svg {
  width: clamp(26px, 11cqw, 52px);
  height: clamp(14px, 5cqw, 24px);
}

.branch-flipped {
  transform: scaleX(-1);
}

.open {
  display: flex;
  justify-content: center;
  align-items: center;
  width: 80%;
  padding: 5.2cqw 6cqw;
  border-radius: 3cqw;
  border: 0.5cqw solid var(--white);
  background: var(--button-gold);
  color: var(--white);
  font: 400 clamp(0.875rem, 4.7cqw, 1.4rem) var(--f-body);
  letter-spacing: 0.04em;
  text-decoration: none;
  box-shadow: 0 0 0 1cqw rgba(196, 162, 106, 0.45), 0 2cqw 4.5cqw rgba(109, 77, 28, 0.35);
  transition: transform 0.3s;
  animation: ring 3.2s ease-in-out infinite;
}

@keyframes ring {
  0%,
  100% {
    box-shadow: 0 0 0 1cqw rgba(196, 162, 106, 0.45), 0 2cqw 4.5cqw rgba(109, 77, 28, 0.35);
  }

  50% {
    box-shadow: 0 0 0 2cqw rgba(196, 162, 106, 0.3), 0 2cqw 4.5cqw rgba(109, 77, 28, 0.35);
  }
}

.open:active {
  transform: scale(0.98);
}

@media (max-width: 250px) {
  .hero {
    top: 14%;
  }

  .invited svg {
    display: none;
  }

  .invited {
    margin-top: 6cqw;
    margin-bottom: 3cqw;
  }
}

@media (max-width: 320px) {
  .invited svg {
    width: 20px;
    height: 12px;
  }

  .lab {
    letter-spacing: 0.1em;
    white-space: nowrap;
  }
}

@media (max-width: 230px) {
  .hero {
    top: 7%;
  }

  .divider {
    margin: 3cqw 0 4cqw;
  }

  .invited {
    margin-top: 4cqw;
    margin-bottom: 2cqw;
  }

  .open {
    padding-top: 4cqw;
    padding-bottom: 4cqw;
  }
}

.spark {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #d9b46a;
  z-index: 2;
  animation: tw 3s ease-in-out infinite;
}

.spark:nth-of-type(4n + 1) {
  background: var(--sky);
  box-shadow: 0 0 6px 1px rgba(127, 179, 213, 0.8);
}

.spark:nth-of-type(4n + 2) {
  background: var(--white);
  box-shadow: 0 0 6px 1px rgba(255, 255, 255, 0.9);
}

.spark:nth-of-type(4n + 3) {
  background: var(--pink);
  box-shadow: 0 0 6px 1px rgba(194, 68, 90, 0.45);
}

@keyframes tw {
  0%,
  100% {
    opacity: 0.1;
    transform: scale(0.6);
  }

  50% {
    opacity: 1;
    transform: scale(1.4);
  }
}

/* ===== 4. SEKSI ===== */
.sec {
  position: relative;
  padding: 76px 28px;
  text-align: center;
  background: var(--cream);
}

.sec::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 4px;
  z-index: 3;
  background: linear-gradient(90deg, transparent, var(--sky), var(--white), var(--pink), var(--rose), transparent);
}

.sec.alt {
  background: var(--cream);
}

.sec.top {
  padding-top: 205px;
}

.in {
  position: relative;
  z-index: 2;
}

h2 {
  font: 500 34px/1.2 var(--f-head);
  color: var(--brown);
  margin: 6px 0 18px;
}

h2::after {
  content: '';
  display: block;
  width: 72px;
  height: 3px;
  margin: 12px auto 0;
  border-radius: 3px;
  background: linear-gradient(90deg, var(--sky), var(--pink), var(--rose));
}

.eb {
  font: 500 11px/1.4 var(--f-body);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--rose-d);
}

p {
  max-width: 320px;
  margin: 0 auto 14px;
}

.orn {
  display: block;
  width: 90px;
  height: 14px;
  margin: 0 auto 22px;
}

.orn-small {
  width: 40px;
  height: 40px;
  margin-bottom: 6px;
}

.orn-quote {
  margin-bottom: 10px;
}

.guest-name {
  font: 500 20px var(--f-head);
  color: var(--brown);
}

.script {
  font: 400 56px/1 var(--f-script);
  color: var(--rose);
  text-shadow: 0 2px 0 rgba(244, 198, 208, 0.7), 0 4px 10px rgba(188, 220, 240, 0.8);
}

.script-spaced {
  margin-top: 26px;
}

.script-ampersand {
  font-size: 44px;
}

.card {
  position: relative;
  background: rgba(255, 255, 255, 0.86);
  border: 1px solid rgba(244, 198, 208, 0.95);
  border-radius: 18px;
  padding: 30px 22px 28px;
  margin: 18px auto;
  max-width: 340px;
  box-shadow: 0 10px 28px rgba(127, 179, 213, 0.28), 0 2px 6px rgba(194, 68, 90, 0.1);
}

.card::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 5px;
  border-radius: 18px 18px 0 0;
  background: linear-gradient(90deg, var(--sky), var(--white), var(--pink), var(--rose));
}

.floral-card {
  isolation: isolate;
  overflow: hidden;
}

.card-floral {
  position: absolute;
  top: 0;
  z-index: -1;
  width: 112px;
  height: 144px;
  object-fit: cover;
  mix-blend-mode: multiply;
  opacity: 0.7;
  pointer-events: none;
}

.card-floral-left {
  left: 0;
  object-position: top left;
  transform: scaleX(-1);
}

.card-floral-right {
  right: 0;
  object-position: top right;
}

.card h3 {
  font: 500 24px var(--f-head);
  color: var(--brown);
}

#mempelai .card h3,
.profile-nickname [data-cfg="groomNickname"] {
  color: var(--rose);
  font-family: var(--f-script);
  font-weight: 400;
  text-shadow: 0 2px 0 rgba(244, 198, 208, 0.7), 0 4px 10px rgba(188, 220, 240, 0.8);
}

#mempelai .card h3 {
  font-size: 36px;
  line-height: 1.15;
}

.profile-nickname [data-cfg="groomNickname"] {
  display: inline-block;
  font-size: 24px;
  line-height: 1;
}

.event-time {
  margin: 6px 0 4px;
}

.event-description {
  margin: 0;
}

.profile-description {
  margin: 8px auto 0;
}

.profile-nickname {
  margin: 4px auto 0;
}

.story-section {
  background:
    radial-gradient(ellipse at 0% 100%, rgba(244, 198, 208, 0.3), transparent 42%),
    var(--cream);
}

.story-intro {
  margin-bottom: 30px;
}

.story-chapter {
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  gap: 18px;
  align-items: center;
  max-width: 380px;
  margin: 0 auto 24px;
  padding: 14px;
  border: 1px solid rgba(196, 162, 106, 0.55);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.72);
  text-align: left;
}

.story-chapter-reverse {
  grid-template-columns: minmax(0, 1fr) 110px;
}

.story-chapter-reverse img {
  order: 2;
}

.story-chapter img {
  width: 110px;
  height: 140px;
  border: 3px solid var(--white);
  border-radius: 9px;
  object-fit: cover;
  box-shadow: 0 4px 14px rgba(90, 60, 40, 0.15);
}

.rv-on .story-chapter:not(.in-v) .story-photo-left {
  opacity: 0;
  transform: translateX(-36px);
  transition: none;
}

.rv-on .story-chapter:not(.in-v) .story-photo-right {
  opacity: 0;
  transform: translateX(36px);
  transition: none;
}

.story-chapter .story-photo-left,
.story-chapter .story-photo-right {
  transition: opacity 0.8s ease var(--reveal-delay, 0ms), transform 0.8s ease var(--reveal-delay, 0ms);
}

.story-number {
  color: var(--gold-d);
  font: italic 15px var(--f-it);
}

.story-chapter h3 {
  margin: 3px 0 8px;
  color: var(--brown);
  font: 500 20px/1.3 var(--f-head);
}

.story-chapter p {
  margin: 0;
  font-size: 13px;
  line-height: 1.65;
}

.story-signoff {
  margin-top: 30px;
  font: italic 15px/1.8 var(--f-it);
}

.story-signoff span {
  color: var(--rose);
  font: 400 42px/1.3 var(--f-script);
}

.date-long {
  font: 500 20px var(--f-head);
  color: var(--brown);
}

.arch {
  position: relative;
  width: 62%;
  aspect-ratio: 3 / 4;
  margin: 0 auto 18px;
  border-radius: 999px 999px 14px 14px;
  overflow: hidden;
  border: 3px solid var(--white);
  background: linear-gradient(160deg, var(--sky-2), var(--pink));
  box-shadow: 0 0 0 1px var(--pink), 0 0 0 6px rgba(188, 220, 240, 0.6), 0 12px 24px rgba(194, 68, 90, 0.18);
}

.arch b {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  font: 500 54px var(--f-head);
  color: rgba(194, 68, 90, 0.4);
}

.small {
  font-size: 13px;
  opacity: 0.85;
}

.cd {
  display: flex;
  gap: 10px;
  justify-content: center;
  margin: 22px 0;
}

.cd div {
  width: 66px;
  padding: 12px 0;
  border-radius: 12px;
  border: 2px solid var(--white);
  background: linear-gradient(160deg, var(--rose-l), var(--rose-d));
  color: var(--white);
  box-shadow: 0 6px 14px rgba(194, 68, 90, 0.3);
}

.cd div:nth-child(even) {
  background: var(--white);
  color: var(--rose-d);
  border-color: var(--sky);
  box-shadow: 0 6px 14px rgba(127, 179, 213, 0.4);
}

.cd b {
  display: block;
  font: 500 24px/1 var(--f-head);
}

.cd small {
  font-size: 10px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.btn {
  display: inline-block;
  padding: 14px 30px;
  border-radius: 12px;
  border: 1px solid var(--white);
  background: var(--button-gold);
  color: var(--white);
  font: 400 13px var(--f-body);
  letter-spacing: 0.08em;
  text-decoration: none;
  cursor: pointer;
  margin: 6px 4px 0;
  box-shadow: 0 6px 16px rgba(109, 77, 28, 0.3);
}

.btn.line {
  background: rgba(255, 255, 255, 0.9);
  color: var(--rose-d);
  border-color: var(--sky-d);
  box-shadow: 0 6px 16px rgba(127, 179, 213, 0.3);
}

.btn.sm {
  padding: 8px 18px;
  font-size: 12px;
}

.rsvp-submit {
  width: 100%;
  margin: 0;
}

.gal {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-top: 20px;
}

.gal div {
  position: relative;
  aspect-ratio: 3 / 4;
  border-radius: 14px;
  border: 4px solid var(--white);
  overflow: hidden;
  background: linear-gradient(160deg, var(--sky-2), var(--pink));
  box-shadow: 0 8px 18px rgba(127, 179, 213, 0.4);
}

.gal div:nth-child(even) {
  box-shadow: 0 8px 18px rgba(217, 104, 124, 0.3);
}

.gal div:nth-child(1),
.gal div:nth-child(4) {
  aspect-ratio: 3 / 4.6;
}

.gal .slot {
  inset: 0;
}

.rek {
  font: 500 20px var(--f-head);
  letter-spacing: 0.06em;
  color: var(--rose-d);
  margin: 6px 0 2px;
}

form {
  display: grid;
  gap: 12px;
  max-width: 330px;
  margin: 0 auto;
  text-align: left;
}

input[type='text'],
select,
textarea {
  width: 100%;
  padding: 13px 14px;
  border-radius: 10px;
  border: 1px solid var(--sky-d);
  background: var(--white);
  color: var(--brown);
  font: 300 14px var(--f-body);
}

input[type='text']:focus,
select:focus,
textarea:focus {
  outline: none;
  border-color: var(--rose);
  box-shadow: 0 0 0 3px rgba(244, 198, 208, 0.8);
}

.opts {
  display: flex;
  gap: 10px;
}

.opts label {
  flex: 1;
}

.opts input {
  position: absolute;
  opacity: 0;
}

.opts span {
  display: block;
  text-align: center;
  padding: 12px;
  border-radius: 10px;
  border: 1px solid var(--sky-d);
  background: var(--white);
  cursor: pointer;
  font-size: 13px;
}

.opts input:checked + span {
  background: var(--button-gold);
  border-color: var(--gold);
  color: var(--white);
}

.opts input:focus-visible + span {
  box-shadow: 0 0 0 3px rgba(188, 220, 240, 0.9);
}

#thanks {
  display: none;
  font: 500 22px var(--f-head);
  color: var(--rose-d);
}

footer {
  padding: 70px 28px 60px;
  text-align: center;
  background: var(--cream);
  position: relative;
}

.footer-content {
  padding-top: 175px;
}

.footer-signoff {
  font-style: italic;
  font-family: var(--f-it);
}

.footer-names {
  font-size: 48px;
}

.music-toggle {
  position: fixed;
  right: max(16px, env(safe-area-inset-right, 0px), calc((100vw - 480px) / 2 + 16px));
  top: 50%;
  transform: translateY(-50%);
  z-index: 45;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  padding: 0;
  border: 1px solid var(--white);
  border-radius: 999px;
  background: var(--button-gold);
  color: var(--white);
  font: 400 12px var(--f-body);
  cursor: pointer;
  box-shadow: 0 4px 14px rgba(109, 77, 28, 0.28);
}

footer::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 6px;
  background: linear-gradient(90deg, var(--sky), var(--white), var(--pink), var(--rose));
}

/* ===== 4b. DEKORASI BUNGA DI SETIAP HALAMAN ===== */
.fl {
  position: absolute;
  width: 38%;
  aspect-ratio: 626 / 830;
  background: url('../floral-transparent.webp') center / contain no-repeat;
  mix-blend-mode: multiply;
  opacity: 0.95;
  pointer-events: none;
  z-index: 1;
}

.fl-tr {
  top: 0;
  right: 0;
}

.fl-tl {
  top: 0;
  left: 0;
  transform: scaleX(-1);
}

.fl-br {
  bottom: 0;
  right: 0;
  transform: scaleY(-1);
}

.fl-bl {
  bottom: 0;
  left: 0;
  transform: rotate(180deg);
}

.pt-fl {
  padding-top: 150px;
}

.pb-fl {
  padding-bottom: 140px;
}

/* bunga kecil warna aksen (dibuat lewat JS) */
.blossom {
  position: absolute;
  z-index: 1;
  pointer-events: none;
  opacity: 0.9;
  filter: drop-shadow(0 2px 3px rgba(163, 48, 74, 0.18));
  animation: sway 6s ease-in-out infinite alternate;
}

@keyframes sway {
  from {
    transform: rotate(-12deg) translateY(0);
  }

  to {
    transform: rotate(14deg) translateY(6px);
  }
}

/* ===== 5. ANIMASI ===== */
.rv {
  transition: opacity 0.9s ease var(--reveal-delay, 0ms), transform 0.9s ease var(--reveal-delay, 0ms);
}

/* disembunyikan HANYA bila skrip sudah siap; kalau skrip gagal, konten tetap tampil */
.rv-on .rv:not(.in-v) {
  opacity: 0;
  transform: translateY(24px);
}

.rv.in-v {
  opacity: 1;
  transform: none;
}

.petal {
  position: fixed;
  top: -30px;
  width: 12px;
  height: 16px;
  border-radius: 0 100% 0 100%;
  background: linear-gradient(135deg, #fbd3dc, #ee93a8);
  opacity: 0.7;
  pointer-events: none;
  z-index: 50;
  animation: fall linear infinite;
}

.petal.b {
  background: linear-gradient(135deg, #e3f2fb, #8fc1e3);
}

.petal.r {
  background: linear-gradient(135deg, #e0788d, #b23a52);
}

.petal.w {
  background: linear-gradient(135deg, #ffffff, #fbe6ea);
  filter: drop-shadow(0 1px 2px rgba(163, 48, 74, 0.35));
  opacity: 0.9;
}

@keyframes fall {
  0% {
    transform: translate3d(0, -5vh, 0) rotate(0);
  }

  50% {
    transform: translate3d(36px, 55vh, 0) rotate(200deg);
  }

  100% {
    transform: translate3d(-28px, 108vh, 0) rotate(420deg);
  }
}

@media (prefers-reduced-motion: reduce) {
  .rv {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .story-chapter .story-photo-left,
  .story-chapter .story-photo-right {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .petal,
  .spark {
    display: none;
  }

  .open,
  .blossom {
    animation: none;
  }
}

/* ===== 6. LAPISAN MEWAH (gold foil, bingkai ganda, kilau, bokeh) ===== */
:root {
  --foil: linear-gradient(100deg, #6d4d1c 0%, #b8893f 30%, #c99d50 50%, #b8893f 70%, #6d4d1c 100%);
  --wine: #4a1e2c;
}

body {
  background:
    radial-gradient(60% 40% at 12% 8%, #e8f3fb, transparent 70%),
    radial-gradient(50% 40% at 92% 85%, #fdeef1, transparent 70%),
    #eedfcd;
}

.wrap {
  box-shadow: 0 0 0 1px rgba(196, 162, 106, 0.4), 0 24px 70px rgba(90, 40, 50, 0.28);
}

.wrap::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 40;
  pointer-events: none;
  opacity: 0.12;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='200' height='200'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .42 0 0 0 0 .3 0 0 0 0 .2 0 0 0 .7 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

.sec::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background: radial-gradient(70% 30% at 50% 9%, rgba(255, 255, 255, 0.8), transparent 70%);
}

h2 {
  padding-bottom: 0.1em;
  color: #8a6428;
  background: var(--foil);
  background-size: 200% auto;
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: foil 7s linear infinite;
}

@keyframes foil {
  to {
    background-position: 200% center;
  }
}

h2::after {
  width: 180px;
  height: 14px;
  margin: 10px auto 0;
  border-radius: 0;
  background: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 180 14'><defs><linearGradient id='a'><stop offset='0' stop-color='%23c4a26a' stop-opacity='0'/><stop offset='1' stop-color='%23b8893f'/></linearGradient><linearGradient id='b'><stop offset='0' stop-color='%23b8893f'/><stop offset='1' stop-color='%23c4a26a' stop-opacity='0'/></linearGradient></defs><rect x='4' y='6.5' width='70' height='1' fill='url(%23a)'/><rect x='106' y='6.5' width='70' height='1' fill='url(%23b)'/><path d='M90 1L96 7L90 13L84 7Z' fill='%23c2445a'/><circle cx='78' cy='7' r='1.8' fill='%237fb3d5'/><circle cx='102' cy='7' r='1.8' fill='%23f4a6b8'/></svg>") center / contain no-repeat;
}

.eb::before,
.eb::after {
  content: '';
  display: inline-block;
  width: 24px;
  height: 1px;
  margin: 0 10px;
  vertical-align: middle;
  background: linear-gradient(90deg, transparent, #c4a26a);
}

.eb::after {
  transform: scaleX(-1);
}

.card::after {
  content: '';
  position: absolute;
  inset: 7px;
  border: 1px solid rgba(196, 162, 106, 0.55);
  border-radius: 12px;
  pointer-events: none;
}

.open,
.btn {
  position: relative;
  overflow: hidden;
}

.open::after,
.btn::after {
  content: '';
  position: absolute;
  top: 0;
  left: -60%;
  width: 40%;
  height: 100%;
  background: linear-gradient(100deg, transparent, rgba(255, 255, 255, 0.55), transparent);
  transform: skewX(-20deg);
  animation: shine 4.5s ease-in-out infinite;
}

@keyframes shine {
  0%,
  60% {
    left: -60%;
  }

  100% {
    left: 130%;
  }
}

.cd div {
  position: relative;
}

.cd div::after {
  content: '';
  position: absolute;
  inset: 3px;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 9px;
}

.cd div:nth-child(even)::after {
  border-color: rgba(196, 162, 106, 0.6);
}

.gal div {
  cursor: zoom-in;
}

/* seksi kutipan: pita wine + emas */
.ayat {
  padding: 96px 28px;
  background: var(--cream);
}

.qm {
  font: 400 84px/0.7 var(--f-head);
  color: var(--rose);
  text-shadow: 0 2px 0 rgba(244, 198, 208, 0.7);
  margin-bottom: 14px;
}

.quote {
  max-width: 340px;
  margin: 0 auto 22px;
  font: italic 17px/1.95 var(--f-it);
  color: var(--brown-2);
}

/* animasi masuk lebih halus */
/* bokeh emas melayang */
.bokeh {
  position: fixed;
  bottom: -60px;
  border-radius: 50%;
  pointer-events: none;
  z-index: 49;
  opacity: 0;
  filter: blur(1.5px);
  animation: rise linear infinite;
}

@keyframes rise {
  0% {
    transform: translateY(0) scale(0.8);
    opacity: 0;
  }

  15% {
    opacity: 0.6;
  }

  85% {
    opacity: 0.35;
  }

  100% {
    transform: translateY(-115vh) scale(1.2);
    opacity: 0;
  }
}

/* lightbox galeri */
#lb {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: none;
  place-items: center;
  background: rgba(58, 20, 32, 0.88);
  backdrop-filter: blur(6px);
}

#lb.on {
  display: grid;
}

#lb img {
  max-width: 92vw;
  max-height: 84vh;
  border: 6px solid var(--white);
  border-radius: 14px;
  box-shadow: 0 0 0 2px #e2c47e, 0 24px 60px rgba(0, 0, 0, 0.5);
}

#lbx {
  position: absolute;
  top: calc(14px + env(safe-area-inset-top, 0px));
  right: 16px;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid #e2c47e;
  background: rgba(255, 255, 255, 0.12);
  color: var(--white);
  font: 300 26px/1 var(--f-body);
  cursor: pointer;
}

@media (prefers-reduced-motion: reduce) {
  h2,
  .open::after,
  .btn::after {
    animation: none;
  }

  .rv-on .rv:not(.in-v) {
    opacity: 1;
    transform: none;
  }

  .bokeh {
    display: none;
  }
}

/* ===== 7. FORM RSVP (bentuk lembut, kapsul, bingkai emas) ===== */
#form {
  position: relative;
  gap: 14px;
  max-width: 340px;
  padding: 34px 22px 26px;
  border-radius: 28px;
  border: 1px solid rgba(244, 198, 208, 0.95);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 32px rgba(127, 179, 213, 0.3), 0 2px 8px rgba(194, 68, 90, 0.1);
  overflow: hidden;
}

#form::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 6px;
  background: linear-gradient(90deg, var(--sky), var(--white), var(--pink), var(--rose));
}

#form::after {
  content: '';
  position: absolute;
  inset: 8px;
  border: 1px solid rgba(196, 162, 106, 0.5);
  border-radius: 21px;
  pointer-events: none;
}

#form input[type='text'],
#form select,
#form textarea {
  border: 1.5px solid #cfe3f1;
  background-color: var(--white);
  background-repeat: no-repeat;
  color: var(--brown);
  font: 300 14px var(--f-body);
  transition: border-color 0.25s, box-shadow 0.25s;
}

#form input[type='text'],
#form select {
  height: 50px;
  padding: 0 20px 0 48px;
  border-radius: 999px;
  background-position: 18px center;
  background-size: 20px;
}

#form input[type='text'] {
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23c2445a' stroke-width='1.6' stroke-linecap='round'><circle cx='12' cy='8' r='4'/><path d='M4 21c0-4 4-6 8-6s8 2 8 6'/></svg>");
}

#form select {
  appearance: none;
  -webkit-appearance: none;
  cursor: pointer;
  background-image:
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237fb3d5' stroke-width='1.6' stroke-linecap='round'><circle cx='9' cy='8' r='3.5'/><circle cx='17' cy='9' r='2.5'/><path d='M2 20c0-3.5 3-5 7-5s7 1.5 7 5M16 15c3 0 6 1 6 4'/></svg>"),
    url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23b8893f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'><path d='M6 9l6 6 6-6'/></svg>");
  background-position: 18px center, right 18px center;
  background-size: 20px, 16px;
}

#form textarea {
  min-height: 104px;
  padding: 14px 20px;
  border-radius: 24px;
  resize: none;
}

#form ::placeholder {
  color: rgba(90, 70, 60, 0.5);
}

#form input[type='text']:focus,
#form select:focus,
#form textarea:focus {
  outline: none;
  border-color: var(--rose);
  box-shadow: 0 0 0 4px rgba(244, 198, 208, 0.7);
}

#form .opts span {
  height: 50px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 12px;
  border-radius: 999px;
  border: 1.5px solid #cfe3f1;
  background: var(--white);
  transition: all 0.25s;
}

#form .opts label:first-child span::before {
  content: '\2713\00a0\00a0';
}

#form .opts label:last-child span::before {
  content: '\2715\00a0\00a0';
}

#form .opts input:checked + span {
  background: var(--button-gold);
  border-color: var(--white);
  color: var(--white);
  box-shadow: 0 6px 14px rgba(109, 77, 28, 0.3), 0 0 0 3px rgba(196, 162, 106, 0.4);
}

#form .btn {
  height: 52px;
  padding: 0 24px;
  border-radius: 999px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-size: 12px;
}

#thanks {
  max-width: 340px;
  margin: 0 auto;
  padding: 30px 22px;
  border-radius: 28px;
  border: 1px solid rgba(244, 198, 208, 0.95);
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 12px 32px rgba(127, 179, 213, 0.3);
}

/* ===== 9. LAYAR MUAT (agar tidak tampak kosong saat gambar masih diunduh) ===== */
.splash {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 200;
  display: grid;
  place-items: center;
  text-align: center;
  background: var(--cream);
  animation: splashOut 0.6s ease 9s forwards;
}

.splash b {
  display: block;
  font: 400 44px/1.2 var(--f-script);
  color: var(--rose);
  text-shadow: 0 2px 0 rgba(244, 198, 208, 0.7), 0 4px 10px rgba(188, 220, 240, 0.8);
}

.splash span {
  display: block;
  margin-top: 12px;
  font: 300 12px var(--f-body);
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--rose-d);
  animation: blink 1.6s ease-in-out infinite;
}

.splash.off {
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.6s ease, visibility 0s 0.6s;
}

@keyframes splashOut {
  to {
    opacity: 0;
    visibility: hidden;
  }
}

@keyframes blink {
  50% {
    opacity: 0.35;
  }
}

.music-toggle .music-icon {
  width: 14px;
  height: 14px;
}

.music-toggle .music-icon-pause,
.music-toggle[aria-pressed="true"] .music-icon-play {
  display: none;
}

.music-toggle[aria-pressed="true"] .music-icon-pause {
  display: block;
}

.music-toggle:focus-visible {
  outline: 2px solid #7e581f;
  outline-offset: 3px;
}

/* Floral accents match the existing floral.webp decoration dimensions. */
.sec > .corner-flower,
footer > .corner-flower {
  position: absolute;
  width: 52%;
  aspect-ratio: 626 / 829;
  background: url('../bunga-corner.webp') right top / contain no-repeat;
  opacity: 0.72;
  pointer-events: none;
  user-select: none;
  z-index: 1;
}

.corner-flower-tl { top: 0; left: 0; transform: scaleX(-1); }
.corner-flower-tr { top: 0; right: 0; }
.corner-flower-bl { bottom: 0; left: 0; transform: rotate(180deg); }
.corner-flower-br { bottom: 0; right: 0; transform: scaleY(-1); }
