/* ==========================================================================
   THEME: DESAIN 32 - LANGIT LENTERA
   KitoNgundang Wedding Invitation
   Konsep: langit biru embun berpola arabesque, tali emas dengan awan dan
   lentera, dua menara masjid cat air. Satu momen gerak: saat sampul dibuka,
   kedua menara bergeser ke sisi seperti gerbang yang terbuka.
   ========================================================================== */

:root {
    --embun: #cdd6dc;
    --embun-2: #dce3e8;
    --kabut: #8ea9ba;
    --laut: #1f4a66;
    --laut-2: #2d6385;
    --laut-deep: #153448;
    --pirus: #3f8f8b;
    --bata: #d6824a;
    --bata-deep: #8f4623;
    --lentera: #f1d58a;
    --emas: #c4953c;
    --emas-deep: #8f6a22;
    --ink: #1b3345;
    --muted: #3e566a;
    --bg-body: #16313f;

    --font-display: 'Berkshire Swash', Georgia, serif;
    --font-text: 'Golos Text', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-arab: 'Amiri', serif;

    --ease: cubic-bezier(0.22, 1, 0.36, 1);
    --ease-io: cubic-bezier(0.65, 0, 0.35, 1);
    --spring: cubic-bezier(0.34, 1.5, 0.5, 1);

    /* tinggi foto sampul menyesuaikan tinggi layar: tali lentera (31% lebar kolom) dan isi bawah ~400px */
    --photo-h: clamp(190px, calc(100dvh - min(100vw, 480px) * 0.3125 - 400px), 430px);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-text);
    font-size: 1rem;
    font-weight: 400;
    background-color: var(--bg-body);
    color: var(--ink);
    line-height: 1.7;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

body.locked {
    overflow: hidden;
    height: 100vh;
}

img {
    display: block;
    max-width: 100%;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
    outline: 2px solid var(--laut-2);
    outline-offset: 3px;
}

.night a:focus-visible,
.night button:focus-visible {
    outline-color: var(--lentera);
}

/* ---------- Latar ---------- */
.deco {
    pointer-events: none;
    user-select: none;
}

/* langit sampul dan hero: warna rata agar sampul dan hero tersambung tanpa sambungan */
.sky {
    background:
        radial-gradient(ellipse 80% 240px at 50% 0, rgba(255, 232, 170, 0.6), rgba(255, 232, 170, 0)),
        url('../images/arabesque.svg') 0 0 / 120px 120px repeat,
        var(--embun);
}

/* pola arabesque digambar sekali di .app-container supaya sambungan antar-bagian tidak terputus;
   bagian terang cukup transparan, bagian .paper-light hanya menambah lapisan putih tipis */
.paper-light {
    background-color: rgba(255, 255, 255, 0.3);
}

/* bagian malam: biru laut dalam, pola arabesque dibuat samar */
.night {
    color: #e6eff5;
    background:
        linear-gradient(180deg, rgba(21, 52, 72, 0.5) 0%, rgba(21, 52, 72, 0.88) 100%),
        url('../images/arabesque.svg') 0 0 / 120px 120px repeat,
        linear-gradient(180deg, #2d6385 0%, #1f4a66 45%, #153448 100%);
}

/* tirai ogee: warna bagian sebelumnya turun menjadi lengkung runcing */
.cap {
    position: absolute;
    left: 0;
    right: 0;
    top: -1px;
    z-index: 2;
    width: 100%;
    aspect-ratio: 480 / 48;
    background-size: 100% 100%;
    background-repeat: no-repeat;
}

.cap-light { background-image: url('../images/valance-light.svg'); }
.cap-dark { background-image: url('../images/valance-dark.svg'); }

/* ---------- Tombol ---------- */
.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    background: linear-gradient(180deg, var(--laut-2) 0%, var(--laut) 100%);
    color: #ffffff;
    font-family: var(--font-text);
    font-weight: 600;
    font-size: 1rem;
    line-height: 1.3;
    padding: 0.85rem 2rem;
    border: 0;
    border-radius: 14px;
    text-decoration: none;
    cursor: pointer;
    box-shadow:
        0 10px 20px rgba(21, 52, 72, 0.3),
        inset 0 0 0 1px rgba(241, 213, 138, 0.55);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow:
        0 14px 24px rgba(21, 52, 72, 0.36),
        inset 0 0 0 1px rgba(241, 213, 138, 0.8);
}

.btn:active {
    transform: scale(0.97);
    transition-duration: 0.1s;
}

.btn-small {
    font-size: 0.92rem;
    padding: 0.55rem 1.3rem;
    border-radius: 12px;
}

.btn-block {
    width: 100%;
}

.btn-light {
    background: linear-gradient(180deg, #fbe9b0 0%, #e9c46f 100%);
    color: var(--laut-deep);
    box-shadow: 0 8px 16px rgba(8, 24, 36, 0.35);
}

.btn-light:hover {
    box-shadow: 0 12px 20px rgba(8, 24, 36, 0.42);
}

/* ---------- Tali emas, awan, dan lentera ---------- */
.garland {
    position: relative;
    z-index: 3;
    width: 100%;
    aspect-ratio: 480 / 150;
    background: url('../images/garland.svg') center top / 100% 100% no-repeat;
}

/* lentera: kiri/atas/lebar dalam persen lebar bingkai, tali dihitung dari lebar lentera */
.hang {
    position: absolute;
    top: var(--y);
    left: var(--x);
    z-index: 4;
    isolation: isolate;
    display: block;
    width: var(--w);
    margin-left: calc(var(--w) / -2);
    transform-origin: 50% 0;
    pointer-events: none;
    animation: swing var(--dur, 6s) ease-in-out var(--d, 0s) infinite;
}

.hang .cord {
    display: block;
    width: 1.5px;
    margin: 0 auto;
    padding-top: calc(var(--len, 20) * 1%);
    background: linear-gradient(#f4dc9a, #c4953c);
}

.lamp {
    position: relative;
    display: block;
}

.lamp img {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 5px 6px rgba(15, 40, 58, 0.32));
}

.glow {
    position: absolute;
    z-index: -1;
    left: 50%;
    top: 54%;
    width: 340%;
    aspect-ratio: 1;
    translate: -50% -50%;
    background: radial-gradient(circle, rgba(255, 212, 112, 0.6) 0%, rgba(255, 212, 112, 0) 62%);
    animation: flicker 3.2s ease-in-out infinite alternate;
}

/* bintang dan bulan yang tergantung di bagian penutup */
.star-hang {
    position: absolute;
    top: 40px;
    z-index: 3;
    width: 34px;
    transform-origin: 50% 0;
    animation: swing 7s ease-in-out infinite;
}

.star-hang::before {
    content: '';
    display: block;
    width: 1.5px;
    height: var(--cord, 44px);
    margin: 0 auto;
    background: linear-gradient(#f4dc9a, #c4953c);
}

.star-hang img {
    width: 100%;
    height: auto;
    filter: drop-shadow(0 0 8px rgba(255, 226, 150, 0.6));
}

.star-hang-l { left: 14%; }
.star-hang-r { right: 14%; animation-delay: -3s; }

/* menara masjid cat air */
.minaret {
    position: absolute;
    bottom: 0;
    z-index: 6;
    width: 27%;
    pointer-events: none;
}

.minaret img {
    width: 100%;
    height: auto;
}

.minaret-l { left: -5%; }
.minaret-r { right: -5%; }
.minaret-r img { transform: scaleX(-1); }

/* ---------- Kepala undangan (dipakai sampul dan hero agar identik) ---------- */
.head-art {
    position: relative;
    z-index: 6;
    text-align: center;
}

.arch-photo {
    position: relative;
    z-index: 2;
    width: calc(var(--photo-h) * 0.62);
    height: var(--photo-h);
    margin: -0.2rem auto 0;
    padding: 6px;
    border: 3px solid var(--laut);
    border-radius: 999px;
    background: linear-gradient(180deg, #f6f9fb, #d6e1e8);
    box-shadow:
        0 14px 30px rgba(21, 52, 72, 0.28),
        0 0 0 6px rgba(255, 255, 255, 0.28);
}

.arch-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 999px;
    background: var(--kabut);
}

.kicker {
    margin-top: 1.1rem;
    font-family: var(--font-display);
    font-size: 1.05rem;
    line-height: 1.4;
    color: var(--laut-2);
}

.names {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(2rem, 9.3vw, 2.6rem);
    line-height: 1.3;
    color: var(--laut);
    white-space: nowrap;
    padding: 0.02em 0.2em;
}

/* ==========================================================================
   COVER
   ========================================================================== */
#cover {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 50%;
    width: 100%;
    max-width: 480px;
    transform: translateX(-50%);
    z-index: 9999;
    overflow: hidden;
}

.cover-stage {
    position: absolute;
    inset: 0;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.cover-dome {
    position: relative;
    z-index: 5;
    isolation: isolate;
    margin-top: auto;
    padding: 4.4rem 1.4rem 2.2rem;
    text-align: center;
}

/* wash kubah bawang di belakang nama tamu; ujungnya naik ke bawah nama mempelai */
.cover-dome::before {
    content: '';
    position: absolute;
    z-index: -1;
    left: 7%;
    right: 7%;
    top: -2.4rem;
    bottom: 0;
    background: url('../images/dome-wash.svg') center / 100% 100% no-repeat;
    transition: opacity 1s ease, transform 1.4s var(--ease);
}

.cover-to {
    font-size: 0.98rem;
    font-weight: 500;
    color: var(--laut-deep);
}

.cover-guest-name {
    font-family: var(--font-display);
    font-size: 1.6rem;
    line-height: 1.35;
    color: var(--laut-deep);
    max-width: 15ch;
    margin: 0 auto;
    overflow-wrap: anywhere;
}

.cover-note {
    max-width: 26ch;
    margin: 0.35rem auto 1rem;
    font-size: 0.9rem;
    line-height: 1.5;
    color: #1d3d52;
}

#btn-open {
    position: relative;
    z-index: 6;
}

/* ==========================================================================
   LAYOUT UMUM
   ========================================================================== */
.app-container {
    max-width: 480px;
    margin: 0 auto;
    min-height: 100vh;
    position: relative;
    overflow: hidden;
    background:
        url('../images/arabesque.svg') 0 0 / 120px 120px repeat,
        var(--embun);
    box-shadow: 0 0 50px rgba(0, 0, 0, 0.4);
}

section,
.closing {
    position: relative;
    padding: 4.4rem 1.75rem;
    text-align: center;
    overflow: hidden;
}

section > *:not(.deco):not(.cap):not(.abs),
.closing > *:not(.deco):not(.cap):not(.abs) {
    position: relative;
    z-index: 3;
}

/* judul bagian */
.sec-title {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: clamp(1.9rem, 8.4vw, 2.3rem);
    line-height: 1.35;
    color: var(--laut);
    padding: 0.02em 0.2em;
}

.sec-title::after {
    content: '';
    display: block;
    width: 160px;
    height: 20px;
    margin: 0.5rem auto 2rem;
    background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='20' viewBox='0 0 160 20'%3E%3Cpath d='M0 10H62M98 10H160' stroke='%23c4953c' stroke-width='1.5'/%3E%3Cg fill='%23c4953c'%3E%3Crect x='71' y='1' width='18' height='18' rx='1'/%3E%3Crect x='71' y='1' width='18' height='18' rx='1' transform='rotate(45 80 10)'/%3E%3C/g%3E%3Ccircle cx='80' cy='10' r='4' fill='%23cdd6dc'/%3E%3Ccircle cx='64' cy='10' r='1.8' fill='%23c4953c'/%3E%3Ccircle cx='96' cy='10' r='1.8' fill='%23c4953c'/%3E%3C/svg%3E") center / contain no-repeat;
}

.sec-title-light {
    color: var(--lentera);
}

.sec-title-light::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='20' viewBox='0 0 160 20'%3E%3Cpath d='M0 10H62M98 10H160' stroke='%23f1d58a' stroke-width='1.5'/%3E%3Cg fill='%23f1d58a'%3E%3Crect x='71' y='1' width='18' height='18' rx='1'/%3E%3Crect x='71' y='1' width='18' height='18' rx='1' transform='rotate(45 80 10)'/%3E%3C/g%3E%3Ccircle cx='80' cy='10' r='4' fill='%231f4a66'/%3E%3Ccircle cx='64' cy='10' r='1.8' fill='%23f1d58a'/%3E%3Ccircle cx='96' cy='10' r='1.8' fill='%23f1d58a'/%3E%3C/svg%3E");
}

.sec-date {
    margin: -1.2rem 0 2.4rem;
    font-weight: 500;
    color: #d6e4ed;
}

.lead {
    max-width: 34ch;
    margin: 0 auto;
    font-size: 1.04rem;
    color: var(--ink);
}

/* ==========================================================================
   HERO
   ========================================================================== */
#home {
    padding: 0 0 2.4rem;
    /* hanya cahaya di atas; pola arabesque datang dari .app-container agar menyambung ke bagian berikutnya */
    background: radial-gradient(ellipse 80% 240px at 50% 0, rgba(255, 232, 170, 0.6), rgba(255, 232, 170, 0));
}

.hero-date {
    margin-top: 0.1rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--laut);
}

.ayat {
    width: min(330px, calc(100% - 2.5rem));
    margin: 1.6rem auto 0;
    padding: 1.5rem 0.4rem 1.2rem;
    border-top: 1.5px solid var(--emas);
    border-bottom: 1.5px solid var(--emas);
}

.ayat-ar {
    font-family: var(--font-arab);
    font-size: 1.2rem;
    line-height: 2.1;
    color: var(--laut);
}

.ayat-id {
    margin-top: 0.7rem;
    font-size: 0.98rem;
    line-height: 1.7;
    color: var(--ink);
}

.ayat cite {
    display: block;
    margin-top: 0.7rem;
    font-style: normal;
    font-weight: 600;
    color: var(--emas-deep);
}

.hero-dome {
    position: relative;
    isolation: isolate;
    margin-top: 1.2rem;
    padding: 5.4rem 1.2rem 3.6rem;
    text-align: center;
}

.hero-dome::before {
    content: '';
    position: absolute;
    z-index: -1;
    left: 5%;
    right: 5%;
    top: 0;
    bottom: 0;
    background: url('../images/dome-wash.svg') center / 100% 100% no-repeat;
}

.countdown {
    display: flex;
    justify-content: center;
    gap: 9px;
    margin-bottom: 1.4rem;
}

.cd-item {
    width: 68px;
    padding: 0.6rem 0 0.5rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    border-radius: 14px;
    background: rgba(31, 74, 102, 0.92);
    box-shadow: 0 10px 18px rgba(21, 52, 72, 0.28);
    color: #ffffff;
}

.cd-number {
    font-size: 1.7rem;
    font-weight: 600;
    line-height: 1.15;
    font-variant-numeric: tabular-nums;
}

.cd-label {
    font-size: 0.78rem;
    line-height: 1.4;
    color: #cfe0ea;
}

.scroll-hint {
    display: flex;
    flex-direction: column;
    align-items: center;
    margin-top: 1.6rem;
    font-size: 1.1rem;
    line-height: 0.7;
    color: var(--laut-2);
}

.scroll-hint i:nth-child(2) {
    opacity: 0.55;
}

/* ==========================================================================
   PEMBUKAAN
   ========================================================================== */
#opening {
    padding-top: 3rem;
    padding-bottom: 4rem;
}

.salam {
    font-family: var(--font-arab);
    font-size: 1.75rem;
    line-height: 1.9;
    color: var(--laut);
    margin-bottom: 1rem;
}

/* ==========================================================================
   MEMPELAI
   ========================================================================== */
#couple {
    padding-top: 2rem;
}

.person-photo {
    --photo-h: clamp(280px, 40dvh, 340px);
}

.person-name {
    margin-top: 1.5rem;
    font-family: var(--font-display);
    font-weight: 400;
    font-size: 2.6rem;
    line-height: 1.3;
    color: var(--laut);
}

.person-full {
    margin-bottom: 0.6rem;
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--laut-deep);
}

.person-parents {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--muted);
}

.person-parents strong {
    font-weight: 600;
    color: var(--ink);
}

.person-ig {
    margin-top: 1rem;
}

.amp {
    font-family: var(--font-display);
    font-size: 3.6rem;
    line-height: 1;
    color: var(--emas);
    margin: 2.2rem 0 2rem;
}

/* ==========================================================================
   ACARA (malam)
   ========================================================================== */
#event {
    padding-top: 5.6rem;
    padding-bottom: 5rem;
}

.event-list {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 340px;
    margin: 0 auto;
}

.event-card {
    position: relative;
    padding: 5rem 1.5rem 1.8rem;
    border-radius: 170px 170px 24px 24px / 130px 130px 24px 24px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.16) 0%, rgba(255, 255, 255, 0.05) 100%);
    border: 1px solid rgba(241, 213, 138, 0.5);
    box-shadow: 0 18px 32px rgba(6, 20, 30, 0.35);
}

.event-card::before {
    content: '';
    position: absolute;
    inset: 7px;
    border-radius: inherit;
    border: 1px solid rgba(241, 213, 138, 0.28);
    pointer-events: none;
}

.event-icon {
    position: absolute;
    top: 1.6rem;
    left: 50%;
    translate: -50% 0;
    width: 46px;
    height: 46px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--lentera);
    color: var(--laut-deep);
    font-size: 1.1rem;
    box-shadow: 0 0 0 5px rgba(241, 213, 138, 0.2), 0 6px 14px rgba(0, 0, 0, 0.3);
}

.event-title {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: 1.65rem;
    line-height: 1.3;
    color: var(--lentera);
}

.event-day {
    margin-top: 0.3rem;
    font-weight: 600;
    color: #ffffff;
}

.event-time {
    color: #d9e6ee;
}

.event-time i {
    margin-right: 6px;
    color: var(--lentera);
}

.event-place {
    margin-top: 0.6rem;
    font-weight: 600;
    color: #ffffff;
}

.event-addr {
    max-width: 26ch;
    margin: 0 auto 1.1rem;
    font-size: 0.94rem;
    line-height: 1.55;
    color: #c4d6e2;
}

/* ==========================================================================
   SUSUNAN ACARA
   ========================================================================== */
#rundown {
    padding-top: 5.6rem;
}

.rundown {
    list-style: none;
    position: relative;
    max-width: 330px;
    margin: 0 auto;
    padding-left: 1.8rem;
    text-align: left;
}

.rundown::before {
    content: '';
    position: absolute;
    left: 5px;
    top: 8px;
    bottom: 8px;
    width: 2px;
    background: linear-gradient(180deg, var(--emas), rgba(196, 149, 60, 0.2));
    transform-origin: 50% 0;
}

.rundown li {
    position: relative;
    padding-bottom: 1.7rem;
}

.rundown li:last-child {
    padding-bottom: 0;
}

.rundown li::before {
    content: '';
    position: absolute;
    left: calc(-1.8rem + 0px);
    top: 7px;
    width: 12px;
    height: 12px;
    border-radius: 2px;
    background: var(--emas);
    border: 2px solid var(--embun);
    transform: rotate(45deg);
    box-sizing: content-box;
    margin: -2px 0 0 -2px;
}

.rd-time {
    display: block;
    font-weight: 600;
    font-size: 0.95rem;
    font-variant-numeric: tabular-nums;
    color: var(--bata-deep);
}

.rd-body h3 {
    font-family: var(--font-display);
    font-weight: 400;
    font-size: 1.25rem;
    line-height: 1.4;
    color: var(--laut);
}

.rd-body p {
    font-size: 0.97rem;
    line-height: 1.6;
    color: var(--muted);
}

/* ==========================================================================
   KISAH
   ========================================================================== */
.story-card {
    max-width: 330px;
    margin: 0 auto 2.6rem;
}

.story-card:last-child {
    margin-bottom: 0;
}

.story-photo {
    position: relative;
    aspect-ratio: 7 / 5;
    overflow: hidden;
    border-radius: 22px;
    border: 4px solid #ffffff;
    box-shadow: 0 14px 28px rgba(21, 52, 72, 0.22);
}

.story-photo img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: var(--kabut);
}

.story-year {
    position: absolute;
    left: 12px;
    bottom: 12px;
    padding: 0.1rem 0.9rem;
    border-radius: 999px;
    background: var(--laut-deep);
    color: var(--lentera);
    font-family: var(--font-display);
    font-size: 1.05rem;
    line-height: 1.6;
}

.story-card h3 {
    margin-top: 1rem;
    font-family: var(--font-display);
    font-weight: 400;
    font-size: 1.4rem;
    line-height: 1.35;
    color: var(--laut);
}

.story-card p {
    margin-top: 0.4rem;
    font-size: 0.98rem;
    line-height: 1.65;
    color: var(--muted);
}

/* ==========================================================================
   GALERI
   ========================================================================== */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 150px;
    gap: 10px;
    max-width: 360px;
    margin: 0 auto;
}

.g-item {
    padding: 0;
    overflow: hidden;
    cursor: pointer;
    border: 3px solid #ffffff;
    border-radius: 18px;
    background: var(--kabut);
    box-shadow: 0 8px 16px rgba(21, 52, 72, 0.18);
}

.g-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.7s var(--ease);
}

.g-item:hover img {
    transform: scale(1.07);
}

.g-tall {
    grid-row: span 2;
}

.g-wide {
    grid-column: span 2;
}

/* lightbox */
.lightbox {
    position: fixed;
    inset: 0;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(8, 22, 32, 0.92);
}

.lightbox[hidden] {
    display: none;
}

.lb-img {
    max-width: 92vw;
    max-height: 82dvh;
    border-radius: 12px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.5);
}

.lb-img.swap {
    animation: lbImg 0.45s var(--ease);
}

.lightbox button {
    position: absolute;
    width: 46px;
    height: 46px;
    border: 1px solid rgba(241, 213, 138, 0.6);
    border-radius: 50%;
    background: rgba(31, 74, 102, 0.9);
    color: #ffffff;
    font-size: 1.1rem;
    cursor: pointer;
    transition: transform 0.25s ease;
}

.lightbox button:hover {
    transform: scale(1.08);
}

.lb-close { top: 18px; right: 18px; }
.lb-prev { left: 12px; top: 50%; margin-top: -23px; }
.lb-next { right: 12px; top: 50%; margin-top: -23px; }

/* ==========================================================================
   TANDA KASIH
   ========================================================================== */
.bank-list {
    display: grid;
    gap: 1.1rem;
    max-width: 340px;
    margin: 2rem auto 0;
}

.bank-card {
    padding: 1.3rem 1.2rem 1.4rem;
    border-radius: 20px;
    background: #ffffff;
    border: 1px solid rgba(31, 74, 102, 0.18);
    box-shadow: 0 10px 22px rgba(21, 52, 72, 0.12);
}

.bank-name {
    font-weight: 600;
    color: var(--laut);
}

.bank-name i {
    margin-right: 6px;
    color: var(--emas);
}

.bank-number {
    margin-top: 0.3rem;
    font-size: 1.5rem;
    font-weight: 600;
    letter-spacing: 0.05em;
    font-variant-numeric: tabular-nums;
    color: var(--laut-deep);
}

.bank-address {
    margin-top: 0.4rem;
    max-width: 24ch;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.55;
    color: var(--ink);
}

.bank-holder {
    margin-bottom: 0.9rem;
    font-size: 0.95rem;
    color: var(--muted);
}

/* ==========================================================================
   RSVP & UCAPAN
   ========================================================================== */
.rsvp-form {
    max-width: 340px;
    margin: 0 auto;
    text-align: left;
}

.field {
    margin-bottom: 1rem;
}

.field-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.8rem;
}

.field label {
    display: block;
    margin-bottom: 0.25rem;
    font-size: 0.92rem;
    font-weight: 600;
    color: var(--laut-deep);
}

.field input,
.field select,
.field textarea {
    width: 100%;
    padding: 0.7rem 0.9rem;
    border: 1px solid rgba(31, 74, 102, 0.28);
    border-radius: 12px;
    background: #ffffff;
    font-family: var(--font-text);
    font-size: 1rem;
    color: var(--ink);
}

.field textarea {
    resize: vertical;
}

.wishes-feed {
    max-width: 340px;
    max-height: 380px;
    margin: 2rem auto 0;
    overflow-y: auto;
    display: grid;
    gap: 0.8rem;
    text-align: left;
    padding: 0.2rem;
}

.wish-card {
    padding: 0.9rem 1rem;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.82);
    border: 1px solid rgba(31, 74, 102, 0.14);
}

.wish-head {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.6rem;
}

.wish-author {
    font-weight: 600;
    color: var(--laut-deep);
}

.wish-status {
    flex-shrink: 0;
    font-size: 0.82rem;
    font-weight: 500;
    color: #1d6b57;
}

.wish-status-no {
    color: #a03a2a;
}

.wish-text {
    margin-top: 0.25rem;
    font-size: 0.96rem;
    line-height: 1.6;
    color: var(--muted);
}

.wish-new {
    animation: newWish 0.8s var(--ease);
}

/* ==========================================================================
   PENUTUP (malam)
   ========================================================================== */
.closing {
    padding: 9.5rem 1.75rem 16rem;
}

.closing-text {
    max-width: 32ch;
    margin: 0 auto;
    color: #dbe8f0;
}

.closing-salam {
    margin-top: 1.2rem;
    font-family: var(--font-arab);
    font-size: 1.5rem;
    line-height: 1.9;
    color: var(--lentera);
}

.closing-regards {
    margin-top: 1.2rem;
    color: #c4d6e2;
}

.closing-names {
    font-family: var(--font-display);
    font-size: clamp(1.9rem, 8.4vw, 2.3rem);
    line-height: 1.4;
    color: var(--lentera);
    white-space: nowrap;
}

.footer-credit {
    margin-top: 1.8rem;
    font-size: 0.82rem;
    line-height: 1.5;
    color: #b6cad7;
}

/* bulan sabit di antara dua menara */
.closing-moon {
    position: absolute;
    left: 50%;
    bottom: 6.5rem;
    z-index: 3;
    width: 68px;
    translate: -50% 0;
    filter: drop-shadow(0 0 14px rgba(255, 226, 150, 0.55));
    animation: moonFloat 7s ease-in-out infinite;
}

@keyframes moonFloat {
    0%, 100% { translate: -50% 0; }
    50%      { translate: -50% -9px; }
}

.footer-credit .fa-heart {
    color: #e48a7a;
}

.footer-credit a {
    color: var(--lentera);
    text-decoration: none;
}

.minaret-foot {
    width: clamp(86px, 21%, 100px);
    z-index: 2;
}

.closing > .minaret-l { left: -2%; }
.closing > .minaret-r { right: -2%; }

/* ==========================================================================
   MUSIK & NAVIGASI BAWAH (gaya sama dengan desain 16-31)
   ========================================================================== */
#music-btn {
    position: fixed;
    top: 18px;
    right: max(18px, calc(50% - 240px + 18px));
    width: 42px;
    height: 42px;
    border: 1px solid rgba(241, 213, 138, 0.75);
    border-radius: 50%;
    background: rgba(31, 74, 102, 0.96);
    color: #f6e9c2;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 999;
    box-shadow: 0 4px 14px rgba(15, 40, 58, 0.4);
    animation: rotateMusic 4s linear infinite;
}

#music-btn.paused {
    animation-play-state: paused;
    opacity: 0.92;
}

#music-btn::after {
    content: '';
    position: absolute;
    inset: -1px;
    border-radius: 50%;
    border: 1px solid rgba(241, 213, 138, 0.95);
    opacity: 0;
    pointer-events: none;
}

#music-btn:not(.paused)::after {
    animation: ripple 2.4s var(--ease) infinite;
}

.bottom-nav {
    position: fixed;
    bottom: 15px;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(31, 74, 102, 0.96);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(241, 213, 138, 0.5);
    border-radius: 50px;
    padding: 0.5rem 1.2rem;
    display: flex;
    gap: clamp(0.7rem, 3.6vw, 1.5rem);
    z-index: 998;
    box-shadow: 0 8px 25px rgba(15, 40, 58, 0.45);
}

.nav-item {
    color: #d6e4ec;
    text-decoration: none;
    font-size: 0.78rem;
    line-height: 1.5;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 3px;
    transition: color 0.3s, transform 0.3s;
}

.nav-item i {
    font-size: 1.1rem;
}

.nav-item.active,
.nav-item:hover {
    color: #ffffff;
    transform: translateY(-2px);
}

.nav-item.active i {
    color: var(--lentera);
    animation: navPop 0.55s cubic-bezier(0.34, 1.8, 0.64, 1);
}

.nav-item:focus-visible {
    outline-color: #ffffff;
}

body.opened .bottom-nav {
    animation: navIn 1.2s cubic-bezier(0.34, 1.45, 0.64, 1) 2.2s backwards;
}

/* ==========================================================================
   ANIMASI
   Konsep: lentera yang berayun dan gerbang menara. Easing "keluar cepat,
   berhenti pelan", gerak diam yang pelan, dan tiap jenis elemen punya gaya
   masuk sendiri.
   ========================================================================== */
@keyframes coverIn {
    from { opacity: 0; transform: translateY(18px); filter: blur(5px); }
    to   { opacity: 1; transform: none; filter: blur(0); }
}

@keyframes riseSoft {
    from { opacity: 0; transform: translateY(20px); filter: blur(6px); }
    to   { opacity: 1; transform: none; filter: blur(0); }
}

@keyframes popIn {
    from { opacity: 0; transform: translateY(22px) scale(0.8); }
    to   { opacity: 1; transform: none; }
}

@keyframes lbImg {
    from { opacity: 0; transform: scale(0.94); }
    to   { opacity: 1; transform: none; }
}

@keyframes newWish {
    from { opacity: 0; transform: translateY(-14px); background: rgba(241, 213, 138, 0.7); }
    to   { opacity: 1; transform: none; }
}

@keyframes tick {
    from { opacity: 0; transform: translateY(-10px); }
    to   { opacity: 1; transform: none; }
}

@keyframes rotateMusic {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

@keyframes ripple {
    from { transform: scale(1); opacity: 0.7; }
    to   { transform: scale(1.9); opacity: 0; }
}

@keyframes navIn {
    from { transform: translate(-50%, 160%); opacity: 0; }
    to   { transform: translate(-50%, 0); opacity: 1; }
}

@keyframes navPop {
    0%   { transform: scale(0.7); }
    60%  { transform: scale(1.25); }
    100% { transform: scale(1); }
}

/* gerak diam: dimulai dan berakhir di 0 derajat agar tersambung dengan sampul */
@keyframes swing {
    0%, 100% { rotate: 0deg; }
    25%      { rotate: 3.2deg; }
    75%      { rotate: -3.2deg; }
}

@keyframes swingWide {
    0%   { rotate: -3deg; }
    22%  { rotate: 12deg; }
    50%  { rotate: -9deg; }
    78%  { rotate: 5deg; }
    100% { rotate: 0deg; }
}

@keyframes flicker {
    from { opacity: 0.55; scale: 0.94; }
    to   { opacity: 1; scale: 1.06; }
}

@keyframes hint {
    0%, 100% { transform: translateY(0); }
    50%      { transform: translateY(6px); }
}

/* ---------- sampul: isi muncul berurutan, lalu gerbang menara terbuka ---------- */
.head-art .garland,
.head-art .arch-photo,
.head-art .kicker,
.head-art .names {
    animation: coverIn 1.4s var(--ease) var(--d, 0s) backwards;
}

#cover .garland { --d: 0.1s; }
#cover .arch-photo { --d: 0.35s; }
#cover .kicker { --d: 0.6s; }
#cover .names { --d: 0.8s; }

#home .head-art .garland,
#home .head-art .arch-photo,
#home .head-art .kicker,
#home .head-art .names {
    animation: none;
}

.cover-dome > * {
    animation: coverIn 1.4s var(--ease) var(--d, 0s) backwards;
    transition: opacity 0.7s ease, transform 0.9s var(--ease), box-shadow 0.3s ease, background 0.3s ease;
}

.cover-dome > :nth-child(1) { --d: 1s; }
.cover-dome > :nth-child(2) { --d: 1.15s; }
.cover-dome > :nth-child(3) { --d: 1.3s; }
.cover-dome > :nth-child(4) { --d: 1.5s; }

.cover-dome::before {
    animation: fadeWash 1.6s var(--ease) 0.7s backwards;
}

@keyframes fadeWash {
    from { opacity: 0; transform: translateY(24px) scale(0.96); }
    to   { opacity: 1; transform: none; }
}

#cover .minaret {
    transition: transform 1.9s var(--ease-io) 0.35s;
}

#cover .minaret-l { animation: slideInL 1.6s var(--ease) 0.5s backwards; }
#cover .minaret-r { animation: slideInR 1.6s var(--ease) 0.5s backwards; }

@keyframes slideInL {
    from { transform: translateX(-40%); opacity: 0; }
    to   { transform: none; opacity: 1; }
}

@keyframes slideInR {
    from { transform: translateX(40%); opacity: 0; }
    to   { transform: none; opacity: 1; }
}

#cover.opened .cover-dome > * {
    opacity: 0;
    transform: translateY(-16px);
}

#cover.opened .cover-dome > :nth-child(2) { transition-delay: 0.06s; }
#cover.opened .cover-dome > :nth-child(3) { transition-delay: 0.12s; }
#cover.opened .cover-dome > :nth-child(4) { transition-delay: 0.18s; }

#cover.opened .cover-dome::before {
    opacity: 0;
    transform: translateY(-18px) scale(1.04);
}

#cover.opened .minaret-l { transform: translateX(-125%); }
#cover.opened .minaret-r { transform: translateX(125%); }

#cover.opened .hang {
    animation: swingWide 1.7s ease-in-out forwards;
}

#cover.opened .cover-stage {
    opacity: 0;
    transition: opacity 1s ease 1.7s;
}

#cover.opened {
    visibility: hidden;
    pointer-events: none;
    transition: visibility 0s linear 2.8s;
}

/* ---------- hero: lentera mulai berayun setelah sampul membuka, sisanya tampil berurutan ---------- */
body.locked #home .hang {
    animation: none;
}

body.opened #home .hang {
    animation: swing var(--dur, 6s) ease-in-out 1.8s infinite;
}

body.locked .hero-date,
body.locked .ayat,
body.locked .cd-item,
body.locked #btn-calendar,
body.locked .scroll-hint {
    opacity: 0;
}

body.opened .hero-date { animation: riseSoft 1.3s var(--ease) 1.3s backwards; }
body.opened .ayat { animation: riseSoft 1.5s var(--ease) 1.7s backwards; }

body.opened .cd-item { animation: popIn 1s var(--spring) backwards; }
body.opened .cd-item:nth-child(1) { animation-delay: 2.2s; }
body.opened .cd-item:nth-child(2) { animation-delay: 2.35s; }
body.opened .cd-item:nth-child(3) { animation-delay: 2.5s; }
body.opened .cd-item:nth-child(4) { animation-delay: 2.65s; }

body.opened #btn-calendar { animation: riseSoft 1.2s var(--ease) 3s backwards; }
body.opened .scroll-hint {
    animation:
        riseSoft 1.2s var(--ease) 3.3s backwards,
        hint 2.4s ease-in-out 4.5s infinite;
}

/* ---------- muncul saat digulir: tiap jenis elemen punya gerak sendiri ---------- */
.js [data-reveal] {
    opacity: 0;
    transition:
        opacity 1.2s var(--ease) var(--d, 0s),
        transform 1.4s var(--ease) var(--d, 0s),
        filter 1.2s var(--ease) var(--d, 0s),
        clip-path 1.8s var(--ease) var(--d, 0s);
}

.js [data-reveal="up"] {
    transform: translateY(28px);
    filter: blur(6px);
}

.js [data-reveal="slide"] {
    transform: translateX(-22px);
    filter: blur(4px);
}

.js [data-reveal="card"] {
    transform: translateY(46px) scale(0.95);
    filter: blur(4px);
}

.js [data-reveal="pop"] {
    transform: translateY(22px) scale(0.9);
}

/* lentera dan bintang turun pelan dari tirai */
.js [data-reveal="drop"] {
    transform: translateY(-60px);
    transition-duration: 1.4s, 2s, 1.2s, 1.8s;
}

/* foto lengkung: terbuka dari bawah, lalu menenang */
.js [data-reveal="arch"] {
    clip-path: inset(calc(100% - 1px) 0 0 0 round 999px);
}

.js [data-reveal="arch"] img {
    transform: scale(1.18);
    transition: transform 2.4s var(--ease) var(--d, 0s);
}

.js [data-reveal="frame"] {
    clip-path: inset(calc(100% - 1px) 0 0 0 round 22px);
}

.js [data-reveal="frame"] img {
    transform: scale(1.15);
    transition: transform 2.4s var(--ease) var(--d, 0s);
}

/* judul: tertulis dari kiri */
.js [data-reveal="write"] {
    clip-path: inset(-30% calc(100% - 1px) -30% -6%);
    transition-duration: 1.2s, 1.4s, 1.2s, 2.2s;
    transition-timing-function: var(--ease), var(--ease), var(--ease), cubic-bezier(0.45, 0.05, 0.25, 1);
}

/* garis susunan acara menggambar dari atas */
.js [data-reveal="line"] {
    opacity: 1;
}

.js [data-reveal="line"]::before {
    transform: scaleY(0);
    transition: transform 2.8s var(--ease) var(--d, 0s);
}

.js [data-reveal].in {
    opacity: 1;
}

.js [data-reveal="up"].in,
.js [data-reveal="slide"].in,
.js [data-reveal="card"].in,
.js [data-reveal="pop"].in,
.js [data-reveal="drop"].in {
    transform: none;
    filter: none;
}

.js [data-reveal="arch"].in {
    clip-path: inset(0 0 0 0 round 999px);
}

.js [data-reveal="frame"].in {
    clip-path: inset(0 0 0 0 round 22px);
}

.js [data-reveal="arch"].in img,
.js [data-reveal="frame"].in img {
    transform: none;
}

.js [data-reveal="write"].in {
    clip-path: inset(-30% -6% -30% -6%);
}

.js [data-reveal="line"].in::before {
    transform: none;
}

.cd-number.tick {
    animation: tick 0.55s var(--ease);
}

/* ==========================================================================
   RESPONSIF & AKSESIBILITAS
   ========================================================================== */
@media (max-height: 700px) {
    .cover-note {
        display: none;
    }

    .cover-dome {
        padding-top: 3.6rem;
        padding-bottom: 1.6rem;
    }

    .kicker {
        margin-top: 0.7rem;
    }
}

/* layar sangat pendek: sampul dipadatkan agar tombol tetap terlihat */
@media (max-height: 620px) {
    .cover-dome {
        padding-top: 2.6rem;
        padding-bottom: 1.1rem;
    }

    .cover-dome::before {
        top: -1.6rem;
    }

    .cover-guest-name {
        font-size: 1.35rem;
    }

    .kicker {
        margin-top: 0.5rem;
        font-size: 0.95rem;
    }

    .names {
        font-size: clamp(1.7rem, 8.4vw, 2.2rem);
    }

    #btn-open {
        padding-top: 0.65rem;
        padding-bottom: 0.65rem;
    }
}

@media (max-width: 360px) {
    section,
    .closing {
        padding-left: 1.25rem;
        padding-right: 1.25rem;
    }

    .bottom-nav {
        padding: 0.45rem 0.9rem;
    }

    .nav-item {
        font-size: 0.7rem;
    }

    .cd-item {
        width: 60px;
    }

    .cd-number {
        font-size: 1.45rem;
    }

    .event-card {
        padding-left: 1.1rem;
        padding-right: 1.1rem;
    }

    .bank-number {
        font-size: 1.3rem;
    }
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    *,
    *::before,
    *::after {
        animation: none !important;
        transition: none !important;
    }

    #cover.opened {
        display: none;
    }

    body.locked .hero-date,
    body.locked .ayat,
    body.locked .cd-item,
    body.locked #btn-calendar,
    body.locked .scroll-hint,
    .js [data-reveal] {
        opacity: 1;
        clip-path: none;
        transform: none;
        filter: none;
    }

    .js [data-reveal="arch"] img,
    .js [data-reveal="frame"] img,
    .js [data-reveal="line"]::before {
        transform: none;
    }
}
