/* BASE & RESET & RESPONSIVE VARIABLES */
:root {
    --bg-main: #d3c7bb;
    --bg-light: #f5efe6;
    --bg-darker: #ccbfb3;
    
    --text-dark: #3a3a3a;
    --text-primary: #5c5c5c;
    --text-accent: #6d5b4b;
    
    --font-serif: 'Mrs Saint Delafield', cursive;
    --font-mrs: 'Mrs Saint Delafield', cursive;
    --font-script: 'Pinyon Script', cursive;
    --font-sans: 'Tenor Sans', sans-serif;
    --font-body: 'Lora', serif;
    --font-playfair: 'Playfair Display', serif;
    --font-dynalight: 'Dynalight', cursive;
    
    --img-filter: none;
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; font-size: 16px; }
body.locked { overflow: hidden; }
body {
    background-color: var(--bg-main);
    color: var(--text-primary);
    font-family: var(--font-body);
    font-size: 0.85rem;
    line-height: 1.5;
    overflow-x: hidden;
    -webkit-font-smoothing: antialiased;
}

/* COVER SCREEN */
.cover-screen {
    position: fixed; top: 0; left: 0; width: 100vw; height: 100vh;
    z-index: 99999; display: flex; flex-direction: column; justify-content: center; align-items: center; text-align: center;
    padding: 30px 20px 40px; transition: transform 0.8s cubic-bezier(0.77, 0, 0.175, 1), opacity 0.8s ease;
    overflow: hidden;
    background-color: #0b0b0b;
}

.cover-bg-slider-frame {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; z-index: 1; overflow: hidden;
}
.cover-bg-slide {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%; object-fit: cover;
    opacity: 0; transform: translateX(20px) scale(1.05);
    transition: opacity 2s ease-in-out, transform 2.5s cubic-bezier(0.25, 1, 0.5, 1);
    filter: var(--img-filter);
}
.cover-bg-slide.active {
    opacity: 1; transform: translateX(0) scale(1);
}

.cover-overlay {
    position: absolute; top: 0; left: 0; width: 100%; height: 100%;
    background: linear-gradient(180deg, rgba(0,0,0,0.25) 0%, rgba(0,0,0,0.55) 50%, rgba(0,0,0,0.95) 100%);
    z-index: 2;
}

.cover-content {
    position: relative; z-index: 3; max-width: 380px; width: 100%; margin-top: 10vh;
}
.cover-subtitle { font-family: var(--font-sans); font-size: 0.65rem; letter-spacing: 3px; color: #d8cebe; margin-bottom: 4px; text-transform: uppercase; text-shadow: 0 1px 3px rgba(0,0,0,0.8); }
.cover-title { font-size: clamp(3.2rem, 12vw, 4.2rem); color: #ffffff; margin-bottom: 12px; line-height: 1.1; font-weight: normal; text-shadow: 0 2px 6px rgba(0,0,0,0.8); }

/* TAMU UNDANGAN */
.guest-box {
    background: transparent;
    border: none;
    padding: 0;
    margin-bottom: 20px;
    box-shadow: none;
    backdrop-filter: none;
}
.guest-label-text { font-size: 0.65rem; letter-spacing: 1.5px; color: #d8cebe; margin-bottom: 4px; text-shadow: 0 1px 3px rgba(0,0,0,0.8); }
.guest-name-text { font-family: var(--font-sans); font-size: 0.95rem; color: #ffffff; font-weight: 600; text-shadow: 0 1px 4px rgba(0,0,0,0.8); }

.cover-btn {
    font-size: 0.75rem; padding: 6px 16px; border-radius: 18px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.4);
}

/* ORNAMENTS */
.section-ornament {
    height: auto; margin: 10px auto; display: block; opacity: 0.9;
    filter: drop-shadow(0 3px 6px rgba(0,0,0,0.12));
}
.hero-ornament-large { width: 90px; }
.gallery-ornament-large { width: 90px; }
.rsvp-ornament-large { width: 90px; }

/* TYPOGRAPHY HELPERS */
.mrs-font { font-family: var(--font-mrs); font-weight: normal; }
.pinyon-font { font-family: var(--font-script); }
.playfair-font { font-family: var(--font-playfair); font-weight: normal; font-style: normal; }
.dynalight-font { font-family: var(--font-dynalight); font-weight: normal; font-style: normal; }
.text-center { text-align: center; }
.text-right { text-align: right; }
.hidden { display: none !important; }
img { filter: var(--img-filter); object-fit: cover; }

/* MAIN WRAPPER */
.main-wrapper {
    background: linear-gradient(180deg, rgba(211,199,187,0.7) 0%, rgba(245,239,230,1) 40%, rgba(245,239,230,1) 70%, rgba(204,191,179,1) 100%);
    min-height: 100vh;
    width: 100%;
    max-width: 500px;
    margin: 0 auto;
    position: relative;
    box-shadow: 0 0 20px rgba(0,0,0,0.05);
}

.bg-light { background-color: var(--bg-light); }
.bg-darker { background-color: var(--bg-darker); }
.section { padding: 40px 20px; position: relative; overflow: hidden; }

@media (min-width: 501px) {
    .section { padding: 50px 30px; }
}

/* HERO SECTION */
.hero-section { padding-top: 80px; padding-bottom: 60px; text-align: center; position: relative; }
.hero-slider-container {
    width: 170px; height: 240px; margin: 0 auto 20px; border-radius: 100px 100px 0 0; overflow: hidden; position: relative; border: 1px solid rgba(255,255,255,0.6);
}
.hero-slide { position: absolute; top: 0; left: 0; width: 100%; height: 100%; opacity: 0; transition: opacity 1.5s ease-in-out, transform 4s ease; transform: scale(1.05); }
.hero-slide.active { opacity: 1; transform: scale(1); }

.hero-content { margin-bottom: 15px; }
.hero-title { font-family: var(--font-mrs); font-size: clamp(4.5rem, 18vw, 5.5rem); font-weight: normal; color: #736557; line-height: 0.85; letter-spacing: -1px; text-shadow: 1px 1px 3px rgba(255,255,255,0.4); }
.hero-and { font-family: var(--font-script); font-size: 2.2rem; color: var(--text-accent); margin: -4px 0; position: relative; z-index: 2; }

/* VERSE & DOVE */
.verse-content { max-width: 92%; margin: 0 auto; color: #555; }
.verse-text { font-family: var(--font-sans); font-size: 0.8rem; margin-bottom: 4px; color: #6d5b4b; line-height: 1.6; }
.verse-meaning { font-size: 0.75rem; text-align: center; line-height: 1.6; font-style: italic; }
.verse-source { font-size: 0.7rem; margin-top: 8px; font-weight: bold; }
.dove-icon { width: 45px; height: auto; margin: 15px auto 8px; display: block; opacity: 0.65; filter: drop-shadow(0 4px 6px rgba(0,0,0,0.1)); }

/* ARCH PHOTOS */
.photo-container { width: 85%; background-color: #ddd; position: relative; }
.bride-arch { height: 320px; border-radius: 0 0 160px 0; border: 1px solid rgba(255,255,255,0.4); margin-left: -20px; }
.groom-arch { height: 320px; border-radius: 0 0 0 160px; border: 1px solid rgba(255,255,255,0.4); margin-right: -20px; margin-left: auto; }
.photo-container img { width: 100%; height: 100%; border-radius: inherit; }

/* COUPLE INFO */
.couple-info { margin-top: 25px; padding-left: 30px; }
.couple-name { font-size: clamp(3.2rem, 14vw, 4rem); color: #4a4138; margin-bottom: 8px; letter-spacing: 0.5px; font-weight: normal; }
.couple-parents, .couple-address { font-size: 0.85rem; line-height: 1.5; color: #555; white-space: pre-line; }
.ig-container { display: flex; align-items: center; gap: 6px; margin-top: 10px; }
.justify-end { justify-content: flex-end; padding-right: 30px; }
.ig-icon { width: 14px; height: 14px; color: #000000; }
.ig-link { font-size: 1.1rem; color: #6d5b4b; text-decoration: none; }
.divider { height: 1px; background: linear-gradient(90deg, transparent, rgba(109, 91, 75, 0.4), transparent); width: 90%; margin: 35px auto; }

/* OUR STORY SECTION ("OUR" HITAM KAPITAL & "Love Story" PERKECIL) */
.story-header { margin-bottom: 25px; padding-left: 10px; position: relative; }
.story-title { font-family: var(--font-playfair); font-size: clamp(2.8rem, 11vw, 3.8rem); font-weight: 400; color: #000000; text-transform: uppercase; line-height: 1; }
.story-subtitle { font-family: var(--font-dynalight); font-size: clamp(2.8rem, 12vw, 3.8rem); font-weight: 400; color: #6d5b4b; margin-left: 25px; margin-top: -24px; line-height: 0.9; position: relative; z-index: 2; }

.story-slider {
    display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px; padding-bottom: 15px;
    -ms-overflow-style: none; scrollbar-width: none;  
}
.story-slider::-webkit-scrollbar { display: none; }
.story-item { flex: 0 0 78%; scroll-snap-align: center; display: flex; flex-direction: column; }
.story-item:first-child { margin-left: 10px; }
.story-item:last-child { margin-right: 10px; }
.story-img-wrapper { height: 280px; border-radius: 130px 130px 0 0; overflow: hidden; border: 1px solid rgba(200,180,160,0.5); margin-bottom: 12px; box-shadow: 0 8px 15px rgba(0,0,0,0.04); }
.story-img-wrapper img { width: 100%; height: 100%; }
.story-text-content { text-align: center; padding: 0 8px; }
.story-item-title { font-family: var(--font-playfair); font-size: clamp(1.4rem, 6vw, 1.8rem); font-weight: normal; color: #555; margin-bottom: 6px; }
.story-desc { font-size: 0.75rem; color: #555; line-height: 1.5; }

/* GALLERY SECTION ("Precious" HITAM PERKECIL & "MOMENT" KAPITAL) */
.gallery-header { margin-bottom: 25px; text-align: center; position: relative; }
.gallery-title { font-family: var(--font-dynalight); font-size: clamp(3.2rem, 13vw, 4.3rem); font-weight: normal; color: #000000; line-height: 1; margin-bottom: 0; }
.gallery-subtitle { font-family: var(--font-playfair); font-size: clamp(1.8rem, 8vw, 2.5rem); font-weight: 400; color: #7a6e62; text-transform: uppercase; margin-top: -24px; position: relative; z-index: 2; }
.gallery-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; padding: 0 5px; }
.gallery-grid img { width: 100%; height: 140px; border-radius: 8px; cursor: pointer; border: 1px solid rgba(0,0,0,0.1); }
.gallery-grid img:nth-child(3n+1) { grid-column: span 2; height: 220px; border-radius: 100px 100px 0 0; }

/* EVENT SECTION & COUNTDOWN */
.save-date-container { margin-bottom: 25px; }
.save-date-btn {
    background: var(--text-accent); color: white; border: none; padding: 10px 25px; font-family: var(--font-sans); font-size: 0.95rem;
    border-radius: 25px; letter-spacing: 2px; text-decoration: none; display: inline-block; box-shadow: 0 6px 15px rgba(109, 91, 75, 0.25);
}

.countdown-grid {
    display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 20px; padding: 0 5px;
}
.countdown-box {
    background: rgba(255, 255, 255, 0.75); border: 1px solid rgba(255, 255, 255, 0.9);
    padding: 10px 4px; border-radius: 12px; text-align: center; box-shadow: 0 4px 10px rgba(0,0,0,0.03); backdrop-filter: blur(5px);
}
.cd-number {
    display: block; font-family: var(--font-sans); font-size: 1.3rem; font-weight: 600; color: var(--text-accent); line-height: 1;
}
.cd-label {
    display: block; font-family: var(--font-sans); font-size: 0.55rem; letter-spacing: 1px; color: #776c61; margin-top: 4px; text-transform: uppercase;
}

.event-details { margin-top: 25px; }
.event-type { font-family: var(--font-sans); font-size: 0.85rem; color: #888; letter-spacing: 2px; margin-bottom: 6px; }
.event-date { font-family: var(--font-playfair); font-size: clamp(1.8rem, 7vw, 2.4rem); color: #444; font-weight: 400; margin-bottom: 6px; }
.event-time { font-size: 0.8rem; color: #444; margin-bottom: 8px; font-weight: bold; }
.event-location { font-size: 0.8rem; color: #555; line-height: 1.5; padding: 0 15px; margin-bottom: 12px; }
.btn-map {
    display: inline-flex; align-items: center; justify-content: center; gap: 6px; background: transparent; border: 1px solid var(--text-accent);
    color: var(--text-accent); padding: 8px 20px; border-radius: 25px; text-decoration: none; font-size: 0.7rem; font-family: var(--font-sans);
    transition: background 0.3s, color 0.3s;
}
.btn-map svg { width: 12px; height: 12px; }
.btn-map:hover { background: var(--text-accent); color: white; }

/* DRESSCODE ICONS */
.dresscode-icons { display: flex; justify-content: center; gap: 15px; margin: 10px 0; color: #6d5b4b; }
.dresscode-icons svg { width: 28px; height: 28px; opacity: 0.85; stroke-width: 1.3; }

/* RSVP SECTION */
.rsvp-section { padding-top: 30px; }
.rsvp-header { text-align: center; margin-bottom: 20px; }
.rsvp-title { font-family: var(--font-playfair); font-size: clamp(2.2rem, 9vw, 3.2rem); font-weight: 400; color: #7a6e62; display: inline-block; }
.rsvp-subtitle { font-family: var(--font-playfair); font-size: clamp(1.2rem, 5vw, 1.6rem); font-weight: 400; color: #888; display: inline-block; margin-left: 6px; }

form { display: flex; flex-direction: column; gap: 12px; }
input[type="text"], textarea {
    width: 100%; padding: 12px 16px; background: rgba(255,255,255,0.7); border: 1px solid transparent; border-radius: 10px; font-family: var(--font-body); font-size: 0.8rem; color: #444; box-shadow: inset 0 2px 5px rgba(0,0,0,0.03); backdrop-filter: blur(5px);
}
input:focus, textarea:focus { outline: none; border-color: #c2b4a5; background: #fff; }
.radio-group { display: flex; flex-direction: column; gap: 10px; margin: 5px 0 5px 3px; }
.radio-label { display: flex; align-items: center; cursor: pointer; font-size: 0.8rem; color: #333; }
.radio-label input[type="radio"] { display: none; }
.radio-custom {
    width: 16px; height: 16px; border: 1px solid var(--text-accent); border-radius: 50%; margin-right: 12px; position: relative;
}
.radio-label input[type="radio"]:checked + .radio-custom::after {
    content: ''; width: 8px; height: 8px; background: var(--text-accent); border-radius: 50%; position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%);
}

/* Tombol submit selalu tampil */
.submit-btn { 
    display: block !important;
    background: var(--text-accent); color: white; border: none; padding: 12px; font-family: var(--font-body); font-size: 0.85rem; border-radius: 10px; cursor: pointer; margin-top: 5px; box-shadow: 0 4px 12px rgba(109, 91, 75, 0.2); transition: opacity 0.3s;
}
.submit-btn:disabled { opacity: 0.6; cursor: not-allowed; }

.wishes-list { max-height: 280px; overflow-y: auto; margin-top: 20px; display: flex; flex-direction: column; gap: 10px; padding-right:4px; }
.wishes-list::-webkit-scrollbar { width: 3px; }
.wishes-list::-webkit-scrollbar-thumb { background: rgba(109, 91, 75, 0.3); border-radius: 10px; }
.wish-item { background: rgba(255,255,255,0.65); padding: 12px; border-radius: 10px; font-size: 0.75rem; border-left: 3px solid var(--text-accent); box-shadow: 0 2px 8px rgba(0,0,0,0.02); }
.wish-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 4px; }
.wish-name { font-weight: bold; color: #333; font-family: var(--font-sans); }
.wish-address { font-size: 0.68rem; color: #666; font-weight: normal; margin-top: 1px; }
.wish-time { font-size: 0.65rem; color: #888; white-space: nowrap; margin-left: 8px; }
.wish-item p { font-style: italic; color: #555; }

/* GIFT BLOCKS */
.gift-toggle-btn { background: transparent; border: 1px solid #999; color: #666; padding: 10px 28px; font-family: var(--font-sans); letter-spacing: 2px; font-size: 0.7rem; border-radius: 25px; }
.gift-container { margin-top: 20px; display: flex; flex-direction: column; gap: 12px; padding: 0 5px; }
.gift-card { background: linear-gradient(135deg, rgba(255,255,255,0.9), rgba(245,239,230,0.9)); padding: 20px 15px; border-radius: 20px; box-shadow: 0 8px 15px rgba(0,0,0,0.04); border: 1px solid rgba(255,255,255,0.8); text-align: center; }
.gift-card h4 { font-family: var(--font-sans); font-size: 1rem; margin-bottom: 6px; color: var(--text-accent); }
.gift-card p { font-family: monospace; font-size: 0.95rem; margin-bottom: 4px; font-weight: bold; color: #444; }
.btn-copy { margin-top: 10px; font-size: 0.7rem; padding: 6px 14px; border-radius: 12px; background: rgba(109, 91, 75, 0.05); border: 1px solid var(--text-accent); color: var(--text-accent); cursor:pointer; }

/* WATERMARK LOGO */
.watermark-logo {
    max-height: 45px;
    width: auto;
    object-fit: contain;
    display: block;
    margin: 0 auto;
}

/* NAVBAR BAWAH */
.bottom-navbar {
    position: fixed; bottom: 15px; left: 50%; transform: translateX(-50%);
    background: rgba(255, 255, 255, 0.75); backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
    display: flex; justify-content: space-between; align-items: center; padding: 10px 25px; border-radius: 35px;
    box-shadow: 0 8px 25px rgba(0,0,0,0.08); width: 92%; max-width: 380px; z-index: 1000; border: 1px solid rgba(255,255,255,0.6);
}
.nav-item { display: flex; flex-direction: column; align-items: center; text-decoration: none; color: #999; gap: 3px; transition: color 0.3s; }
.nav-item:hover, .nav-item.active { color: var(--text-accent); }
.nav-item svg { width: 20px; height: 20px; stroke: currentColor; fill: none; stroke-width: 1.5; }
.nav-item span { font-size: 0.55rem; font-family: var(--font-sans); }

/* FLOATING MUSIC BUTTON */
.btn-music {
    position: fixed; top: 15px; right: 15px; padding: 5px 12px 5px 6px; border-radius: 25px;
    background: rgba(255,255,255,0.8); border: 1px solid rgba(255,255,255,0.8); display: flex; align-items: center; gap: 6px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1); cursor: pointer; z-index: 999; backdrop-filter: blur(10px);
    font-family: var(--font-sans); font-size: 0.6rem; color: #5c5c5c; letter-spacing: 1px;
}
.premium-disc svg { transition: transform 0.3s; filter: drop-shadow(0 2px 3px rgba(0,0,0,0.2)); }
.spin svg { animation: spinRecord 4s linear infinite; }
@keyframes spinRecord { 100% { transform: rotate(360deg); } }

/* LIGHTBOX */
.lightbox { display: none; position: fixed; z-index: 10000; left: 0; top: 0; width: 100%; height: 100%; background-color: rgba(0,0,0,0.9); backdrop-filter: blur(5px); }
.lightbox-content { margin: auto; display: block; width: 90%; max-width: 500px; max-height: 90vh; position: relative; top: 50%; transform: translateY(-50%); object-fit: contain; border-radius: 10px; }
.close-lightbox { position: absolute; top: 15px; right: 20px; color: #f1f1f1; font-size: 30px; font-weight: 300; cursor: pointer; }

/* ELEGAN SCROLL ANIMATIONS (FUNGSIONAL SAAT SCROLL UP & DOWN) */
.animate-fade-up, .animate-fade-left, .animate-fade-right, .animate-blur, .animate-zoom {
    opacity: 0; 
    transition: opacity 1.1s cubic-bezier(0.25, 1, 0.5, 1), transform 1.1s cubic-bezier(0.25, 1, 0.5, 1), filter 1.1s ease;
    will-change: opacity, transform, filter;
}

.animate-fade-up { transform: translateY(35px); }
.animate-fade-left { transform: translateX(30px); }
.animate-fade-right { transform: translateX(-30px); }
.animate-blur { filter: blur(10px); transform: translateY(20px); }
.animate-zoom { transform: scale(0.9); }

/* Class saat elemen terlihat di layar */
.is-visible { opacity: 1; transform: translate(0) scale(1); filter: blur(0); }