/* =====================================================================
   wedding-v4.css   (dimuat PALING AKHIR, jadi menimpa CSS lama)
   ---------------------------------------------------------------------
   CARA MEMBACA FILE INI
   - Dibagi per bagian, ditandai garis "=====". Gunakan Ctrl+F lalu cari
     nomor bagian, misalnya "[5]".
   - Warna dan ukuran yang sering diubah ada di bagian [1] (variabel).
   - Satuan yang dipakai:
       px   = ukuran tetap
       rem  = relatif terhadap ukuran huruf dasar (1rem = 16px)
       vw   = 1% lebar layar    cqw = 1% lebar wadah (container)
       clamp(min, ideal, max) = ukuran fleksibel, tidak lebih kecil dari
                                min dan tidak lebih besar dari max
   DAFTAR BAGIAN
   [1] Variabel warna     [6] Our Story         [11] Hiasan kiri-kanan
   [2] Sampul             [7] Galeri            [12] Kupu-kupu
   [3] Hero + lentera     [8] Hadiah + kartu    [13] Animasi masuk
   [4] Pengantar + daun   [9] Kontras teks      [14] Responsif
   [5] Mempelai           [10] Badan halaman
   ===================================================================== */


/* =====================================================================
   [1] VARIABEL
   Ganti nilai di sini, seluruh situs ikut berubah.
   ===================================================================== */
:root {
    --v4-navy: #173b67;        /* biru tua: judul, tombol */
    --v4-blue: #5c86b2;        /* biru sedang: kata miring pada judul */
    --v4-ivory: #fbfaf7;       /* putih gading: latar halaman */
    --v4-gold: #b99a6a;        /* emas: garis tipis */
    --v4-gold-ink: #7d5f2f;    /* emas gelap: teks kecil (kontras AA) */
    --v4-soft-ink: #4a6178;    /* abu kebiruan: paragraf */
    --v4-arch: 999px 999px 6px 6px;   /* bentuk lengkung: atas bulat, bawah hampir siku */
    --v4-ease: cubic-bezier(0.2, 0.7, 0.2, 1);  /* kurva gerak lembut */
}

/* Garis fokus untuk pengguna keyboard (tombol Tab). Jangan dihapus. */
:focus-visible {
    outline: 3px solid #2f6db3;
    outline-offset: 3px;
}

/* Memotong apa pun yang melebar ke samping agar tidak muncul scroll horizontal */
main {
    overflow-x: clip;
}


/* =====================================================================
   [2] SAMPUL (layar "Buka Undangan")
   ===================================================================== */
.cover-art {
    position: absolute;
    inset: 0;               /* inset: 0 = menempel ke keempat sisi */
    width: 100%;
    height: 100%;
    object-fit: cover;      /* cover = penuhi area, kelebihan dipotong */
    opacity: 0.3;
    filter: saturate(0.6);
    pointer-events: none;   /* klik menembus gambar ini */
}


/* =====================================================================
   [3] HERO (halaman pertama)
   ===================================================================== */

/* Ornamen lengkung + lentera: membentang SELEBAR HERO, di belakang konten.
   - width: 100%        -> selebar hero
   - height: auto       -> tinggi mengikuti proporsi gambar (persegi)
   - z-index: -1        -> di belakang teks dan foto (hero memakai isolation)
   Bagian bawah gambar yang melewati hero dipotong oleh overflow: hidden. */
.hero-ornament {
    position: absolute;
    z-index: -1;
    /* Dinaikkan sedikit supaya puncak lengkung berada tepat di bawah
       bilah menu dan seluruh isi hero (tulisan + foto) berada DI DALAM
       lengkungan. Ubah angka top untuk menggeser naik/turun. */
    top: calc(-1 * clamp(24px, 4.8vw, 72px));
    left: 50%;
    width: min(100%, 1440px);
    max-width: none;
    height: auto;
    transform: translateX(-50%);
    pointer-events: none;
    /* Tepi kiri-kanan memudar halus agar menyatu dengan motif tepi halaman */
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 9%, #000 91%, transparent 100%);
    mask-image: linear-gradient(to right, transparent 0, #000 9%, #000 91%, transparent 100%);
}

/* Motif tepi kiri-kanan di halaman pertama: memakai class .swirl yang sama
   dengan halaman-halaman berikutnya (dipasang oleh motion.js), hanya
   diletakkan satu lapis di belakang ornamen lengkung. */
.hero-section > .swirl { z-index: -2; opacity: 0.6; }

/* Hero, sampul, dan footer dijadikan "tumpukan sendiri" (isolation)
   supaya elemen ber-z-index negatif tetap berada DI ATAS latar hero. */
.hero-section,
.site-footer,
.cover-screen {
    isolation: isolate;
}

/* Sedikit "kabut" putih di belakang teks kiri agar tulisan tetap terbaca
   di atas pola ornamen. radial-gradient = lingkaran yang memudar. */
.hero-copy {
    position: relative;
}

.hero-copy::before {
    position: absolute;
    z-index: -1;
    inset: -6% -16% -6% -20%;
    background: radial-gradient(ellipse at center, rgba(251, 250, 247, 0.93) 42%, rgba(251, 250, 247, 0) 74%);
    content: "";
    pointer-events: none;
}

/* Label kecil di hero digelapkan agar tetap terbaca di atas ornamen */
.hero-copy .eyebrow,
.hero-kicker {
    color: #33506d;
}

.hero-visual {
    display: grid;
    justify-items: center;
    max-width: 560px;
    margin-inline: auto;
    padding: 0 0 54px;
}

/* Foto pengantin: bingkai putih berbentuk lengkung (arch) */
.hero-photo-frame {
    position: relative;
    z-index: 1;
    width: min(100%, 460px);
    aspect-ratio: 0.72 / 1;         /* lebar : tinggi */
    border: 9px solid rgba(255, 255, 255, 0.9);
    border-radius: var(--v4-arch);
    overflow: hidden;
}

.hero-section .hero-photo-frame::before { display: none; }  /* garis dalam bawaan lama dimatikan */
.hero-photo-frame::after { border-radius: var(--v4-arch); }

.hero-photo-frame img {
    object-position: center 32%;    /* titik fokus foto saat dipotong */
    filter: none;
}

.hero-photo-frame:hover img {
    transform: none;
    filter: none;
}

.photo-caption {
    right: 50%;
    transform: translateX(50%);
    color: #3f5870;
    white-space: nowrap;
}


/* =====================================================================
   [4] PENGANTAR DIBINGKAI DAUN BIRU
   ===================================================================== */
.intro-section { text-align: center; }

.leaf {
    display: block;
    width: min(100%, 440px);
    height: auto;
    margin-inline: auto;
    pointer-events: none;
}

.leaf-top    { margin-bottom: 0.6rem; }
.leaf-bottom { margin-top: 0.6rem; }

.intro-body {
    max-width: 720px;
    margin-inline: auto;
}

.intro-body .section-heading { margin-bottom: 2rem; }


/* =====================================================================
   [5] MEMPELAI (dua kartu berfoto + Instagram)
   ===================================================================== */
.duo {
    display: grid;
    grid-template-columns: 1fr auto 1fr;   /* kartu - tanda "&" - kartu */
    gap: clamp(1rem, 3vw, 3rem);
    align-items: start;
    justify-items: center;
}

.duo-card {
    display: flex;
    width: 100%;
    max-width: 380px;
    flex-direction: column;
    align-items: center;
    text-align: center;
}

.duo-photo {
    position: relative;
    width: 100%;
    aspect-ratio: 3 / 4;
    margin: 0 0 1.8rem;
    overflow: hidden;
    border-radius: var(--v4-arch);
    background: #0a2a93;
    /* dua lapis garis: putih gading lalu emas tipis, seperti bingkai foto */
    box-shadow: 0 0 0 6px var(--v4-ivory), 0 0 0 7px rgba(185, 154, 106, 0.75);
}

.duo-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: center 20%;
}

.duo-and {
    align-self: center;
    margin-top: -4rem;
    color: var(--v4-blue);
    font-family: var(--font-script);
    font-size: clamp(3rem, 6vw, 5rem);
    line-height: 1;
}

.duo-card .person-label {
    margin-bottom: 0.5rem;
    color: var(--v4-soft-ink);
    font-size: 0.95rem;
    letter-spacing: 0.02em;
    text-transform: none;
}

.duo-card h3 {
    margin-bottom: 0.8rem;
    color: var(--v4-navy);
    font-family: var(--font-display);
    font-size: clamp(1.7rem, 3vw, 2.3rem);
    font-weight: 600;
    line-height: 1.12;
}

.duo-card .person-family {
    color: var(--v4-soft-ink);
    font-size: 0.92rem;
    line-height: 1.8;
}

.duo-card .person-family strong { color: #243e58; }

/* Tombol Instagram: tinggi minimal 44px agar nyaman disentuh di ponsel */
.ig-link {
    display: inline-flex;
    min-height: 44px;
    margin-top: 1.1rem;
    padding: 0 1.15rem;
    align-items: center;
    gap: 0.55rem;
    border: 1px solid rgba(23, 59, 103, 0.4);
    border-radius: 3px;
    color: var(--v4-navy);
    font-size: 0.95rem;
    font-weight: 500;
    text-decoration: none;
    transition: background-color 0.25s ease, color 0.25s ease;
}

.ig-link svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;    /* warna garis ikon mengikuti warna teks */
    stroke-width: 1.7;
}

.ig-link:hover {
    background: var(--v4-navy);
    color: #fff;
}


/* =====================================================================
   [6] OUR STORY  (tiga bab, semua foto berukuran sama 4:5)
   ===================================================================== */
.chapters {
    display: grid;
    gap: clamp(4.5rem, 9vw, 7.5rem);   /* jarak antar bab */
}

/* Satu bab = foto di satu sisi, teks di sisi lain */
.chapter {
    display: grid;
    grid-template-columns: minmax(0, 420px) minmax(0, 1fr);
    gap: clamp(2rem, 6vw, 5.5rem);
    align-items: center;
    justify-content: center;
}

/* Bab genap (ke-2) dibalik: teks di kiri, foto di kanan */
.chapter:nth-child(even) {
    grid-template-columns: minmax(0, 1fr) minmax(0, 420px);
}

.chapter:nth-child(even) .chapter-photo { order: 2; }

/* FORMAT FOTO SERAGAM: ubah angka 4 / 5 untuk mengganti rasio semua foto story */
.chapter-photo {
    position: relative;
    width: 100%;
    aspect-ratio: 4 / 5;
    margin: 0;
    background: #0a2a93;
    border-radius: 3px;
}

/* Garis emas yang bergeser di belakang foto (kesan berlapis) */
.chapter-photo::before {
    position: absolute;
    z-index: -1;
    inset: 14px -14px -14px 14px;
    border: 1px solid rgba(185, 154, 106, 0.8);
    border-radius: 3px;
    content: "";
}

.chapter:nth-child(even) .chapter-photo::before { inset: 14px 14px -14px -14px; }

.chapter-photo > img {
    width: 100%;
    height: 100%;
    border-radius: 3px;
    object-fit: cover;               /* foto dipotong mengisi bingkai */
    object-position: center 28%;     /* atur 28% bila wajah terpotong */
}

.chapter-text { max-width: 520px; }

.chapter-year {
    margin: 0 0 0.2rem;
    color: var(--v4-blue);
    font-family: var(--font-display);
    font-size: clamp(3.2rem, 7vw, 5.5rem);
    font-weight: 500;
    line-height: 1;
}

.chapter-text time {
    display: block;
    margin-bottom: 0.6rem;
    color: var(--v4-gold-ink);
    font-size: 0.95rem;
    font-weight: 600;
}

.chapter-text h3 {
    margin-bottom: 1rem;
    color: var(--v4-navy);
    font-family: var(--font-display);
    font-size: clamp(1.9rem, 3.4vw, 2.6rem);
    font-weight: 600;
    line-height: 1.1;
}

.chapter-text p:not(.chapter-year) {
    margin-bottom: 0.9rem;
    color: #324a62;
    font-size: 1.02rem;
    line-height: 1.8;
}


/* =====================================================================
   [7] GALERI GABUNGAN (susunan kolom / masonry)
   columns: 3 230px  -> maksimal 3 kolom, tiap kolom minimal 230px.
   Foto baru otomatis mengisi kolom; tidak perlu mengatur ukuran manual.
   ===================================================================== */
.gallery-grid {
    display: block;
    columns: 3 230px;
    column-gap: 14px;
}

.gallery-item {
    display: block;
    width: 100%;
    height: auto;
    margin: 0 0 14px;
    break-inside: avoid;       /* satu foto tidak boleh terbelah antar kolom */
    aspect-ratio: auto;
    grid-area: auto;
    cursor: zoom-in;
}

.gallery-item img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: cover;
}

.gallery-number { display: none; }


/* =====================================================================
   [8] HADIAH: kartu Mandiri di panggung lengkung + QR
   ===================================================================== */
.gift-stage {
    position: relative;
    display: grid;
    width: min(100%, 760px);
    aspect-ratio: 365 / 261;
    margin: 0 auto;
    padding-bottom: 6%;
    place-items: end center;
    border-radius: 6px;
    background: #cfe3f3 url("assets/img/ornament-arch.jpg") center / cover no-repeat;
}

/* Kartu. container-type membuat satuan "cqw" = 1% lebar KARTU,
   jadi nomor dan nama ikut mengecil saat kartu mengecil. */
.mcard {
    position: relative;
    width: min(62%, 430px);
    margin: 0;
    container-type: inline-size;
    overflow: hidden;
    border-radius: 4.5% / 7%;
    box-shadow: 0 22px 40px -14px rgba(10, 28, 50, 0.6);
}

.mcard img { display: block; width: 100%; height: auto; }

/* Posisi nomor: top = jarak dari atas kartu, left = dari kiri.
   Geser angkanya bila nomor terlihat kurang pas di kartu. */
.mcard-number {
    position: absolute;
    top: 56.5%;
    left: 7%;
    color: #f4f4f4;
    font-family: var(--font-body);
    font-size: 5.3cqw;
    font-variant-numeric: tabular-nums;   /* semua angka sama lebar */
    font-weight: 600;
    letter-spacing: 0.12em;
    line-height: 1;
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.7);
    white-space: nowrap;
}

.mcard-name {
    position: absolute;
    bottom: 8%;
    left: 7%;
    color: #ececec;
    font-family: var(--font-body);
    font-size: 3.2cqw;
    font-weight: 500;
    letter-spacing: 0.13em;
    line-height: 1.5;
    text-shadow: 0 1px 1px rgba(0, 0, 0, 0.7);
    white-space: nowrap;
}

.gift-actions {
    display: grid;
    max-width: 760px;
    margin: 2.6rem auto 0;
    grid-template-columns: 1fr 1fr;
    gap: 2.2rem;
    align-items: center;
}

.gift-account p { margin-bottom: 0.3rem; color: var(--v4-soft-ink); font-size: 0.95rem; }

.gift-account strong {
    display: block;
    margin-bottom: 1.2rem;
    color: var(--v4-navy);
    font-family: var(--font-display);
    font-size: 1.55rem;
    line-height: 1.2;
}

.gift-account .copy-button {
    min-height: 44px;
    padding: 0 1.4rem;
    border: 0;
    border-radius: 3px;
    background: var(--v4-navy);
    color: #fff;
    cursor: pointer;
    font: 600 0.95rem var(--font-body);
}

.gift-account .copy-button:hover { background: #244d7c; }

.qris { display: flex; align-items: center; gap: 1.2rem; }

.qris-code {
    display: grid;
    width: 188px;
    height: 188px;
    flex: none;
    place-items: center;
    border: 1px solid rgba(185, 154, 106, 0.7);
    border-radius: 4px;
    background: #fff;
}

.qris-code img,
.qris-svg { width: 168px; height: 168px; }

/* Atribut hidden harus menang atas aturan display lain */
.qris-code img[hidden] { display: none; }

.qris-svg svg { display: block; width: 100%; height: 100%; }

.qris-copy h3 {
    margin-bottom: 0.4rem;
    color: var(--v4-navy);
    font-family: var(--font-display);
    font-size: 1.6rem;
}

.qris-copy p { max-width: 24ch; color: var(--v4-soft-ink); font-size: 0.92rem; line-height: 1.6; }


/* =====================================================================
   [9] KONTRAS TEKS (agar terbaca, standar WCAG AA)
   ===================================================================== */
.section-lead { color: var(--v4-soft-ink); }


/* =====================================================================
   [10] "BADAN HALAMAN" BERBUNGA
   Setiap halaman (.section-shell) punya panel bergaris emas dengan
   kluster bunga di pojok kiri-atas dan kanan-bawah (dipotong dari
   ornamen rangkaian bunga). Panel disisipkan oleh motion.js sebagai
   <span class="page-frame">.
   ===================================================================== */
.section-shell {
    position: relative;
    isolation: isolate;                       /* tumpukan sendiri */
    padding-inline: clamp(1.1rem, 4vw, 3.5rem); /* konten tidak menempel ke garis panel */
}

.page-frame {
    position: absolute;
    z-index: -1;
    inset: 1rem 0;                            /* jarak panel dari atas/bawah halaman */
    border: 1px solid rgba(185, 154, 106, 0.75);
    border-radius: 4px;
    /* urutan lapisan: bunga kiri-atas, bunga kanan-bawah, lalu warna dasar */
    background:
        url("assets/img/flower-tl.png") top left / clamp(110px, 17vw, 200px) auto no-repeat,
        url("assets/img/flower-br.png") bottom right / clamp(110px, 17vw, 200px) auto no-repeat,
        rgba(251, 250, 247, 0.66);
    /* garis tipis kedua di sebelah dalam, meniru garis ganda pada rangkaian bunga */
    box-shadow: inset 0 0 0 8px rgba(251, 250, 247, 0), inset 0 0 0 9px rgba(23, 59, 103, 0.16);
    pointer-events: none;
}


/* =====================================================================
   [11] HIASAN KIRI-KANAN (motif lengkung biru)
   .swirl-l di tepi kiri layar, .swirl-r adalah cerminnya di tepi kanan.
   left: calc(50% - 50vw) = tarik elemen sampai ke tepi layar,
   walaupun halamannya sendiri lebih sempit dari layar.
   Gambar swirl-tile.png sudah disusun bolak-balik (atas-bawah bercermin)
   sehingga bisa diulang ke bawah tanpa sambungan terlihat.
   ===================================================================== */
.swirl {
    position: absolute;
    z-index: -1;
    top: 0;
    bottom: 0;
    width: clamp(72px, 15vw, 230px);
    background: url("assets/img/swirl-tile.png") left top / 100% auto repeat-y;
    opacity: 0.55;              /* turunkan bila terlalu ramai, naikkan bila kurang terlihat */
    pointer-events: none;
}

.swirl-l { left: calc(50% - 50vw); }

.swirl-r {
    right: calc(50% - 50vw);
    transform: scaleX(-1);      /* cermin horizontal */
}


/* =====================================================================
   [12] KUPU-KUPU (hiasan, dipasang oleh motion.js)
   --s = ukuran dasar, --r = kemiringan, --d = durasi, --l = tunda.
   Nilai-nilai itu ditulis per kupu-kupu di tabel pada motion.js.
   ===================================================================== */
.fly {
    position: absolute;
    z-index: -1;
    width: calc(var(--s) * 1.5px);
    transform: rotate(var(--r, 0deg));
    pointer-events: none;
}

.fly img { display: block; width: 100%; height: auto; }

@keyframes fly-drift {          /* melayang pelan sambil sedikit berputar */
    0%, 100% { transform: translate(0, 0) rotate(var(--r, 0deg)); }
    50%      { transform: translate(14px, -18px) rotate(calc(var(--r, 0deg) + 7deg)); }
}

@keyframes fly-flap {           /* kepakan sayap: lebar menyempit lalu melebar */
    0%, 100% { transform: scaleX(1); }
    50%      { transform: scaleX(0.78); }
}


/* =====================================================================
   [13] ANIMASI MASUK
   Semua gerak dibungkus "prefers-reduced-motion: no-preference":
   pengunjung yang mematikan animasi di perangkatnya tidak melihat gerak.
   Kelas .js-motion ditambahkan oleh motion.js; tanpa JavaScript semua
   konten tetap tampil normal.
   ===================================================================== */
@media (prefers-reduced-motion: no-preference) {

    .fly { animation: fly-drift var(--d, 9s) ease-in-out var(--l, 0s) infinite; }
    .fly img { animation: fly-flap 1.8s ease-in-out infinite; }

    /* Hero: lentera memudar masuk, teks naik berurutan, foto terbuka dari bawah */
    .js-motion .hero-ornament { transition: opacity 1.4s ease 0.1s; }
    .js-motion:not(.is-revealed) .hero-ornament { opacity: 0; }

    .js-motion .hero-copy > * { transition: opacity 0.9s ease, transform 0.9s var(--v4-ease); }
    .js-motion:not(.is-revealed) .hero-copy > * { opacity: 0; transform: translateY(18px); }

    .js-motion.is-revealed .hero-copy > *:nth-child(1) { transition-delay: 0.2s; }
    .js-motion.is-revealed .hero-copy > *:nth-child(2) { transition-delay: 0.3s; }
    .js-motion.is-revealed .hero-copy > *:nth-child(3) { transition-delay: 0.4s; }
    .js-motion.is-revealed .hero-copy > *:nth-child(4) { transition-delay: 0.5s; }
    .js-motion.is-revealed .hero-copy > *:nth-child(5) { transition-delay: 0.6s; }
    .js-motion.is-revealed .hero-copy > *:nth-child(6) { transition-delay: 0.7s; }
    .js-motion.is-revealed .hero-copy > *:nth-child(7) { transition-delay: 0.8s; }
    .js-motion.is-revealed .hero-copy > *:nth-child(8) { transition-delay: 0.9s; }

    .js-motion .hero-photo-frame img {
        transition: clip-path 1.5s var(--v4-ease) 0.15s, transform 2s var(--v4-ease) 0.15s;
    }

    .js-motion:not(.is-revealed) .hero-photo-frame img {
        transform: scale(1.12);
        clip-path: inset(100% 0 0 0);     /* terpotong penuh = belum terlihat */
    }

    /* Our Story: foto terbuka dari atas ke bawah, teks menyusul.
       Kelas .is-in ditambahkan motion.js saat bab masuk layar. */
    .js-motion .chapter-photo { transition: clip-path 1.2s var(--v4-ease); }
    .js-motion .chapter:not(.is-in) .chapter-photo { clip-path: inset(0 0 100% 0); }
    .js-motion .chapter.is-in .chapter-photo { clip-path: inset(-20px); }

    .js-motion .chapter-photo > img { transition: transform 1.8s var(--v4-ease); }
    .js-motion .chapter:not(.is-in) .chapter-photo > img { transform: scale(1.14); }

    .js-motion .chapter-text > * { transition: opacity 0.8s ease, transform 0.8s var(--v4-ease); }
    .js-motion .chapter:not(.is-in) .chapter-text > * { opacity: 0; transform: translateX(28px); }
    .js-motion .chapter:nth-child(even):not(.is-in) .chapter-text > * { transform: translateX(-28px); }

    .js-motion .chapter.is-in .chapter-text > *:nth-child(1) { transition-delay: 0.35s; }
    .js-motion .chapter.is-in .chapter-text > *:nth-child(2) { transition-delay: 0.45s; }
    .js-motion .chapter.is-in .chapter-text > *:nth-child(3) { transition-delay: 0.55s; }
    .js-motion .chapter.is-in .chapter-text > *:nth-child(4) { transition-delay: 0.65s; }
    .js-motion .chapter.is-in .chapter-text > *:nth-child(5) { transition-delay: 0.75s; }

    /* Judul, kartu, formulir: naik pelan saat pertama terlihat (kelas .rise) */
    .js-motion .rise { transition: opacity 0.9s ease, transform 0.9s var(--v4-ease); }
    .js-motion .rise:not(.is-in) { opacity: 0; transform: translateY(26px); }
}


/* =====================================================================
   [14] RESPONSIF (layar sempit)
   ===================================================================== */
@media (max-width: 900px) {
    .chapter,
    .chapter:nth-child(even) { grid-template-columns: 1fr; justify-items: center; }
    .chapter:nth-child(even) .chapter-photo { order: 0; }
    .chapter-photo { max-width: 420px; }
    .chapter-text { text-align: left; }
}

@media (max-width: 760px) {
    /* Di ponsel ornamen hero dibuat sedikit lebih lebar dari layar agar
       lengkungnya tetap terlihat dan lentera tidak terlalu kecil. */
    .hero-ornament { top: -26px; width: 128%; -webkit-mask-image: none; mask-image: none; }
    .gift-actions { grid-template-columns: 1fr; justify-items: center; text-align: center; }
    .qris { flex-direction: column; text-align: center; }
}

@media (max-width: 640px) {
    .duo { grid-template-columns: 1fr; gap: 1.4rem; }
    .duo-card { max-width: 320px; }
    .duo-and { margin-top: 0; }
    .photo-caption { font-size: 1rem; }
    .gift-stage { aspect-ratio: 1 / 1; background-position: center top; }
    .mcard { width: 84%; }
    .fly { width: calc(var(--s) * 0.9px); }       /* kupu-kupu lebih kecil di ponsel */
    .gallery-grid { columns: 2 140px; column-gap: 9px; }
    .gallery-item { margin-bottom: 9px; }
}


/* ============================================================
   [17] UKURAN TEKS: dinaikkan sedikit (sekitar 10-15 persen)
   Hanya teks kecil (menu, label, paragraf, tombol, formulir).
   Judul besar tidak diubah supaya komposisi tetap anggun.
   Blok ini sengaja di paling bawah agar menang atas file CSS lain.
   Ingin lebih besar/kecil? Ubah angka rem di sini saja.
   ============================================================ */
body { font-size: 16.5px; }
.main-nav a { font-size: 0.78rem; }
.music-button { font-size: 0.74rem; }
.brand-name { font-size: 1.05rem; }
.eyebrow, .section-heading .eyebrow, .hero-kicker { font-size: 0.76rem; }
.button, .button-primary { font-size: 0.82rem; }
.text-link, .map-action, .copy-button { font-size: 0.78rem; }
.cover-date { font-size: 0.84rem; }
.cover-recipient span { font-size: 0.74rem; }
.cover-note { font-size: 0.76rem; }
.wedding-date-pill { font-size: 0.8rem; }
.countdown-item span { font-size: 0.64rem; }
.scroll-cue { font-size: 0.66rem; }
.section-lead { font-size: 0.94rem; }
.intro-copy { font-size: 1rem; }
.intro-closing { font-size: 0.86rem; }
.quran-quote cite { font-size: 0.76rem; }
.person-label { font-size: 0.7rem; }
.person-family { font-size: 0.88rem; }
.event-card .event-type { font-size: 0.7rem; }
.event-card > p:not(.event-type) { font-size: 0.86rem; }
.event-date-banner div span { font-size: 0.88rem; }
.event-flow-heading p:not(.eyebrow), .event-flow-heading > p:last-child { font-size: 0.86rem; }
.event-flow-time { font-size: 0.78rem; }
.event-flow-list strong { font-size: 1.32rem; }
.event-flow-list small { font-size: 0.8rem; }
.venue-copy p:not(.eyebrow), .venue-grid .venue-copy p:not(.eyebrow) { font-size: 0.9rem; }
.venue-note { font-size: 0.78rem; }
.story-content time { font-size: 0.7rem; }
.story-content p { font-size: 0.9rem; }
.gallery-number { font-size: 0.68rem; }
.bank-label { font-size: 0.66rem; }
.bank-owner { font-size: 0.84rem; }
.gift-account p, .qris-copy p { font-size: 0.98rem; }
.rsvp-form label { font-size: 0.76rem; }
.rsvp-form input, .rsvp-form select, .rsvp-form textarea { font-size: 0.92rem; }
.field-note, .form-feedback, .storage-note { font-size: 0.76rem; }
.wishes-heading span { font-size: 0.76rem; }
.wish-card strong { font-size: 0.92rem; }
.wish-card .wish-status { font-size: 0.72rem; }
.wish-card p, .empty-state { font-size: 0.88rem; }
.site-footer .footer-small { font-size: 0.76rem; }
.ticket-confirmation-heading p:last-child { font-size: 0.86rem; }

@media (max-width: 1100px) {
    .main-nav a { font-size: 0.72rem; }
}
@media (max-width: 760px) {
    .main-nav a { font-size: 0.86rem; }
    .brand-name { font-size: 0.9rem; }
    .story-content p, .intro-copy { font-size: 0.95rem; }
}


/* ============================================================
   [18] ANIMASI PEMBUKA (kamera "masuk" melalui ornamen)
   TUJUAN: tombol "Buka Undangan" terasa seperti melewati gerbang
   lengkung berlentera menuju halaman pernikahan. Hanya terjadi sekali,
   sekitar 5 detik, dan bisa dilewati lewat tombol "Lewati".
   Dibuat dari ornamen milik website sendiri (tanpa file video), jadi
   ringan dan tajam di semua layar. Pengguna yang mengaktifkan
   "kurangi gerakan" tidak melihatnya (dilewati otomatis oleh script.js).
   Waktu total = variabel --fx-total (harus sama dengan FX_TOTAL_MS di script.js).
   ============================================================ */
.opening-fx {
    --fx-total: 5.2s;
    position: fixed;
    z-index: 200;
    inset: 0;
    overflow: hidden;
    background:
        radial-gradient(ellipse at 50% 38%, #f7f9fb 0%, #d7e6f3 45%, #9ec0e0 100%);
    opacity: 0;
    animation: fx-fade-in 0.45s ease forwards;
    pointer-events: auto;
}

.opening-fx.is-leaving { animation: fx-fade-out 0.5s ease forwards; }

.opening-fx > * { position: absolute; pointer-events: none; will-change: transform, opacity; }

/* Motif kiri-kanan bergeser keluar seperti tirai yang dibuka */
.fx-swirl {
    top: 0; bottom: 0;
    width: clamp(110px, 24vw, 340px);
    background: url("assets/img/swirl-tile.png") left top / 100% auto repeat-y;
    opacity: 0.8;
}
.fx-swirl-l { left: 0; animation: fx-curtain-l var(--fx-total) cubic-bezier(.55,.05,.35,1) forwards; }
.fx-swirl-r { right: 0; transform: scaleX(-1); animation: fx-curtain-r var(--fx-total) cubic-bezier(.55,.05,.35,1) forwards; }

/* Bunga pojok mendekat ke kamera lalu melewati layar */
.fx-flower {
    width: clamp(120px, 26vw, 300px);
    height: auto;
}
.fx-flower-tl { top: -2%; left: -2%; transform-origin: 0 0; animation: fx-pass-tl var(--fx-total) ease-in forwards; }
.fx-flower-br { right: -2%; bottom: -2%; transform-origin: 100% 100%; animation: fx-pass-br var(--fx-total) ease-in forwards; }

/* Gerbang lengkung berlentera: kecil di kejauhan, lalu dilewati kamera */
.fx-arch {
    top: 50%; left: 50%;
    width: min(100vw, 900px);
    height: auto;
    transform: translate(-50%, -52%) scale(0.5);
    transform-origin: 50% 62%;
    opacity: 0;
    animation: fx-arch var(--fx-total) cubic-bezier(.45,.02,.3,1) forwards;
}

/* Monogram di tengah: muncul pelan, lalu ikut "tertembus" */
.fx-mark {
    top: 50%; left: 50%;
    display: grid;
    justify-items: center;
    gap: 0.3rem;
    color: #173b67;
    text-align: center;
    transform: translate(-50%, -50%);
    opacity: 0;
    animation: fx-mark var(--fx-total) ease forwards;
}
.fx-mark b {
    font-family: "Cormorant Garamond", Georgia, serif;
    font-size: clamp(3.4rem, 14vw, 6.5rem);
    font-weight: 500;
    line-height: 1;
}
.fx-mark b i { color: #b99a6a; font-style: normal; }
.fx-mark span {
    font-family: "DM Sans", sans-serif;
    font-size: 0.8rem;
    letter-spacing: 0.3em;
    text-transform: uppercase;
}

.fx-fly {
    width: clamp(46px, 9vw, 84px);
    height: auto;
    opacity: 0;
}
.fx-fly-1 { top: 62%; left: 14%; animation: fx-fly-a var(--fx-total) ease-in-out forwards; }
.fx-fly-2 { top: 30%; right: 12%; animation: fx-fly-b var(--fx-total) ease-in-out forwards; }

/* Cahaya putih di akhir: jembatan halus menuju halaman utama */
.fx-glow {
    inset: 0;
    background: radial-gradient(circle at 50% 45%, #fff 0%, rgba(255,255,255,0.85) 40%, rgba(255,255,255,0) 75%);
    opacity: 0;
    animation: fx-glow var(--fx-total) ease forwards;
}

.fx-skip {
    right: clamp(14px, 3vw, 32px);
    bottom: clamp(16px, 4vh, 36px);
    z-index: 5;
    min-height: 44px;
    border: 1px solid rgba(23, 59, 103, 0.35);
    border-radius: 999px;
    padding: 0 1.3rem;
    background: rgba(255, 255, 255, 0.78);
    color: #173b67;
    font: 600 0.8rem/1 "DM Sans", sans-serif;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    cursor: pointer;
    pointer-events: auto !important;
}
.fx-skip:hover { background: #fff; }
.fx-skip:focus-visible { outline: 3px solid #173b67; outline-offset: 3px; }

@keyframes fx-fade-in  { to { opacity: 1; } }
@keyframes fx-fade-out { from { opacity: 1; } to { opacity: 0; } }

@keyframes fx-curtain-l {
    0%, 40% { transform: translateX(0) scale(1); }
    100%    { transform: translateX(-120%) scale(1.5); }
}
@keyframes fx-curtain-r {
    0%, 40% { transform: scaleX(-1) translateX(0) scale(1); }
    100%    { transform: scaleX(-1) translateX(-120%) scale(1.5); }
}
@keyframes fx-pass-tl {
    0%   { transform: scale(0.8); opacity: 0; }
    15%  { opacity: 1; }
    100% { transform: scale(4.2) translate(-18%, -18%); opacity: 0; }
}
@keyframes fx-pass-br {
    0%   { transform: scale(0.8); opacity: 0; }
    15%  { opacity: 1; }
    100% { transform: scale(4.2) translate(18%, 18%); opacity: 0; }
}
@keyframes fx-arch {
    0%   { transform: translate(-50%, -52%) scale(0.5); opacity: 0; }
    18%  { opacity: 1; }
    55%  { transform: translate(-50%, -52%) scale(1.05); opacity: 1; }
    100% { transform: translate(-50%, -52%) scale(3.6); opacity: 0; }
}
@keyframes fx-mark {
    0%, 12% { opacity: 0; transform: translate(-50%, -46%) scale(0.92); }
    32%, 58% { opacity: 1; transform: translate(-50%, -50%) scale(1); }
    90%, 100% { opacity: 0; transform: translate(-50%, -50%) scale(2.4); }
}
@keyframes fx-fly-a {
    0%   { opacity: 0; transform: translate(0, 0) rotate(-14deg) scale(0.7); }
    20%  { opacity: 1; }
    60%  { transform: translate(24vw, -26vh) rotate(8deg) scale(1); opacity: 1; }
    100% { transform: translate(52vw, -60vh) rotate(18deg) scale(1.5); opacity: 0; }
}
@keyframes fx-fly-b {
    0%   { opacity: 0; transform: translate(0, 0) rotate(16deg) scale(0.7); }
    22%  { opacity: 1; }
    60%  { transform: translate(-22vw, 20vh) rotate(-6deg) scale(1); opacity: 1; }
    100% { transform: translate(-48vw, 52vh) rotate(-16deg) scale(1.5); opacity: 0; }
}
@keyframes fx-glow {
    0%, 62% { opacity: 0; }
    88%, 100% { opacity: 1; }
}

@media (max-width: 760px) {
    .fx-arch { width: 150vw; }
}
@media (prefers-reduced-motion: reduce) {
    .opening-fx { display: none; }
}
