* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --gold: #c9a96e;
    --gold-light: #e8d5b0;
    --gold-dark: #a07840;
    --cream: #f5efe6;
    --cream-dark: #ede3d4;
    --dark-brown: #2c1a0e;
    --mid-brown: #5c3d20;
    --text-dark: #1a0f06;
    --text-mid: #4a3020;
    --text-light: #8a6a4a;
    --white: #ffffff;
    --overlay-dark: rgba(20, 10, 0, 0.55);
    --overlay-mid: rgba(30, 15, 5, 0.4);
}

html {
    scroll-behavior: smooth;
}

body {
    background: var(--cream);
    font-family: 'Open Sans', sans-serif;
    color: var(--text-dark);
    overflow-x: hidden;
}

/* ===== COVER SECTION ===== */


#cover {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    transition: opacity 0.6s ease, visibility 0.6s ease;
}

#cover.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

.cover-bg {
    position: absolute;
    inset: 0;
    background-image: url('assets/sampul-undangan-vintage-bali-Copy.jpg');
    background-size: cover;
    background-position: center top;
    background-repeat: no-repeat;
}


.cover-content {
    position: absolute;
    top: 45%;
    left: 50%;
    transform: translate(-50%, -50%);
    z-index: 2;
    text-align: center;
    padding: 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 80%;
    width: 100%;
}

.cover-label {
    font-family: 'Cinzel', serif;
    font-size: 15px;
    letter-spacing: 5px;
    color:#937042;
    text-transform: uppercase;
    margin-bottom: 10px;
    opacity: 0;
    animation: fadeInDown 1s ease 0.3s forwards;
}

.cover-title {
    font-family: 'Pinyon Script', cursive;
    font-size: clamp(22px, 15vw, 80px);
    color: #937042;
    line-height: 1.05;
    margin-bottom: 100px;
    opacity: 0;
    font-weight: 400;
    animation: fadeInUp 1.2s ease 0.6s forwards;
}

.cover-divider {
    width: 70px;
    height: 1px;
    background: linear-gradient(to right, transparent, var(--gold), transparent);
    margin: 12px auto;
    opacity: 0;
    animation: fadeIn 1s ease 1s forwards;
}

.cover-to {
    font-family: 'Vidaloka', serif;
    font-size: 13px;
    letter-spacing: 2px;
    color: #937042;
    text-transform: uppercase;
    margin-bottom: 4px;
    opacity: 0;
    animation: fadeInUp 1s ease 1.2s forwards;
}

.cover-guest {
    font-family: 'Vidaloka', serif;
    font-size: clamp(18px, 4.5vw, 22px);
    color:#937042; 
    margin-bottom: 40px;
    font-weight: 400;
    opacity: 0;
    animation: fadeInUp 1s ease 1.4s forwards;
}

.cover-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: linear-gradient(
    90deg,
    #B89668 0%,
    #C8AA7C 50%,
    #dbc7a4 100%
    );
    border: 1.5px solid var(--gold);
    border-radius: 30px;
    color: #ffffff;
    font-family: 'Cinzel', serif;
    font-size: 11px;
    letter-spacing: 3px;
    text-transform: uppercase;
    padding: 14px 32px;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0;
    animation: fadeInUp 1s ease 1.7s forwards;
}

.cover-btn i {
    font-size: 12px;
}

/* ===== MAIN CONTENT ===== */
#main-content {
    opacity: 0;
    transition: opacity 2s ease;
}

#main-content.visible {
    opacity: 1;
}

/* ===== VIDEO SECTION =====
   Video tampil penuh sesuai resolusi asli, tanpa crop.
   Teks overlay tersembunyi, muncul di detik ke-14 lewat JS.
*/
#video-section {
    position: relative;
    width: 100%;
    background: #0a0500;
}

#bg-video {
    display: block;
    width: 100%;
    height: auto;
    position: relative;
    z-index: 0;
}

/* ===== PARTICLES CANVAS ===== */
#particles-canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2;
    pointer-events: none;
}

/* Video teks: tersembunyi sampai detik 14 */
.video-content {
    position: absolute;
    inset: 0;
    z-index: 3;
    text-align: center;
    padding: 40px 20px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: translateY(12px);
    transition: opacity 1.2s ease, transform 1.2s ease;
    pointer-events: none;
}

/* Class ditambahkan lewat JS saat currentTime >= 14 */
.video-content.text-visible {
    opacity: 1;
    transform: translateY(0);
}

.video-content {
    position: absolute;
    z-index: 2;
    text-align: center;
    padding: 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 80%;
    width: 100%;
}
.video-label {
    font-family: 'Cinzel', serif;
    font-size: clamp(2px, 7vw, 10px);
    letter-spacing: 2px;
    color: #937042;
    text-transform: uppercase;
    margin-bottom: 16px;
}

.video-title {
    font-family: 'Pinyon Script', cursive;
    font-size: clamp(10px, 14vw, 55px);
    color:#937042;
    line-height: 1;
    margin-bottom: 12px;
}

.video-date {
    font-family: 'Cinzel', serif;
    font-size: clamp(13px, 3vw, 16px);
    letter-spacing: 1px;
    color: #937042;
    text-transform: uppercase;
}

/* ===== GREETING SECTION (slide coklat) =====*/
.greeting-section {
    background: linear-gradient(135deg, #1a0d05 0%, #2c1a0e 50%, #1a0d05 100%);
    padding: 80px 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.greeting-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('assets/halaman-awal-vintage-bali-1.jpg');
    background-size: cover;
    background-position: center;
    opacity: 0.12;
}

.greeting-section .inner {
    position: relative;
    z-index: 1;
    max-width: 500px;
    margin: 0 auto;
}

.greeting-salam {
    font-family: 'Cinzel', serif;
    font-size: clamp(20px, 5.5vw, 26px);
    font-weight: 600;
    letter-spacing: 2px;
    color: var(--gold);
    margin-bottom: 20px;
}

.ornament {
    font-family: 'Cinzel', serif;
    font-size: 20px;
    color: var(--gold);
    margin-bottom: 24px;
    display: block;
    letter-spacing: 8px;
}

.greeting-text {
    font-family: 'Poppins', 'Open Sans', sans-serif;
    font-size: clamp(13px, 3.5vw, 15px);
    font-weight: 300;
    color: var(--cream);
    line-height: 2;
    margin-bottom: 36px;
}

.names-list {
    list-style: none;
    max-width: 420px;
    margin: 0 auto 40px;
    padding: 0;
    text-align: center;
}

.name-item {
    display: flex;
    align-items: center;
    flex-direction: column;
    gap: 4px;
    padding: 14px 4px;
    border-bottom: 1px solid rgba(201, 169, 110, 0.18);
}

.name-item:last-child {
    border-bottom: none;
}


.name-info {
    display: flex;
    flex-direction: column;
    gap: 3px;
}

.name-text {
    font-family: 'Vidaloka', serif;
    font-size: clamp(13px, 3.5vw, 15px);
    color: var(--cream);
    line-height: 1.4;
    text-align:center;
}

.name-parent {
    font-family: 'Open Sans', sans-serif;
    font-size: 11px;
    font-weight: 300;
    letter-spacing: 0.3px;
    color: var(--cream-dark);
    opacity: 0.75;
}

/* Countdown */
.countdown-wrapper {
    display: flex;
    justify-content: center;
    gap: 15px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.countdown-item {
    text-align: center;
    min-width: 10px;
}

.countdown-digits {
    display: block;
    font-family: 'Cinzel', serif;
    font-size: 30px;
    font-weight: 700;
    color: var(--gold);
    line-height: 1;
}

.countdown-label {
    display: block;
    font-family: 'Open Sans', sans-serif;
    font-size: 9px;
    letter-spacing: 3px;
    color: var(--cream-dark);
    text-transform: uppercase;
    margin-top: 6px;
}

.countdown-sep {
    font-family: 'Cinzel', serif;
    font-size: 30px;
    color: var(--gold);
    line-height: 1;
    padding-top: 4px;
}

/* ===== ACARA SECTION ===== */
.acara-section {
    position: relative;
    padding: 80px 30px;
    text-align: center;
    overflow: hidden;
}

.acara-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('assets/background-acara-bali.jpg');
    background-size: cover;
    background-position: center;
}

.acara-section::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(15,8,2,0.72) 0%, rgba(15,8,2,0.80) 100%);
}

.acara-section .inner {
    position: relative;
    z-index: 1;
    max-width: 460px;
    margin: 0 auto;
}

.section-tag {
    font-family: 'Cinzel', serif;
    font-size: 9px;
    letter-spacing: 5px;
    color: var(--gold-light);
    text-transform: uppercase;
    margin-bottom: 10px;
    display: block;
}

.section-heading {
    font-family: 'Vidaloka', serif;
    font-size: clamp(13px, 3.5vw, 15px);
    color: var(--cream);
    line-height: 1.8;
    margin-bottom: 36px;
}

.acara-day {
    font-family: 'Cinzel', serif;
    font-size: clamp(28px, 8vw, 40px);
    font-weight: 700;
    color: var(--gold);
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 4px;
}

.acara-date {
    font-family: 'Cinzel', serif;
    font-size: clamp(16px, 4vw, 22px);
    color: var(--gold-light);
    letter-spacing: 6px;
    margin-bottom: 30px;
}

.gem-divider {
    margin: 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    max-width: 200px;
}

.gem-divider::before, .gem-divider::after {
    content: '';
    flex: 1;
    height: 1px;
    background: var(--gold);
    opacity: 0.5;
}

.gem-icon {
    color: var(--gold);
    font-size: 14px;
}

.acara-time {
    font-family: 'Open Sans', sans-serif;
    font-size: clamp(13px, 3.5vw, 15px);
    color: var(--cream-dark);
    margin-bottom: 24px;
}

.acara-loc-icon {
    color: var(--gold);
    font-size: 18px;
    margin-bottom: 10px;
}

.acara-loc-text {
    font-family: 'Open Sans', sans-serif;
    font-size: clamp(12px, 3vw, 13px);
    color: var(--cream-dark);
    line-height: 1.8;
    margin-bottom: 24px;
}

.btn-maps {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: transparent;
    border: 1px solid var(--gold);
    color: var(--gold-light);
    font-family: 'Cinzel', serif;
    font-size: 10px;
    letter-spacing: 3px;
    text-transform: uppercase;
    padding: 12px 28px;
    text-decoration: none;
    transition: all 0.3s ease;
    cursor: pointer;
    margin-top: 8px;
}

.btn-maps:hover {
    background: var(--gold);
    color: var(--dark-brown);
}

/* ===== RSVP SECTION ===== */
.rsvp-section {
    background: linear-gradient(135deg, var(--cream-dark), var(--cream));
    padding: 80px 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.rsvp-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('assets/halaman-awal-vintage-bali-1.jpg');
    background-size: cover;
    background-position: center;
    opacity: 0.05;
}

.rsvp-section .inner {
    position: relative;
    z-index: 1;
    max-width: 460px;
    margin: 0 auto;
}

.rsvp-title {
    font-family: 'Cinzel', serif;
    font-size: clamp(18px, 5vw, 22px);
    color: var(--gold-dark);
    letter-spacing: 3px;
    text-transform: uppercase;
    margin-bottom: 8px;
}

.rsvp-sub {
    font-family: 'Open Sans', sans-serif;
    font-size: clamp(12px, 3vw, 13px);
    color: var(--text-mid);
    margin-bottom: 36px;
}

.rsvp-form input,
.rsvp-form select,
.rsvp-form textarea {
    width: 100%;
    padding: 14px 16px;
    background: white;
    border: 1px solid var(--gold-light);
    font-family: 'Poppins', 'Open Sans', sans-serif;
    font-size: 13px;
    color: var(--text-dark);
    margin-bottom: 14px;
    outline: none;
    transition: border-color 0.3s;
    appearance: none;
    -webkit-appearance: none;
    border-radius: 0;
}

.rsvp-form input:focus,
.rsvp-form select:focus,
.rsvp-form textarea:focus {
    border-color: var(--gold);
}

.rsvp-form textarea {
    resize: vertical;
    min-height: 80px;
}

/* Dropdown generik (Hadir/Tidak Hadir) */
.select-wrap {
    position: relative;
    margin-bottom: 14px;
}

.select-wrap select {
    width: 100%;
    padding: 14px 40px 14px 16px;
    background: white;
    border: 1px solid var(--gold-light);
    font-family: 'Poppins', 'Open Sans', sans-serif;
    font-size: 13px;
    color: var(--text-dark);
    outline: none;
    transition: border-color 0.3s;
    appearance: none;
    -webkit-appearance: none;
    border-radius: 0;
    margin-bottom: 0;
}

.select-wrap select:focus {
    border-color: var(--gold);
}

.select-arrow {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--gold);
    font-size: 11px;
    pointer-events: none;
}

.btn-rsvp {
    width: 100%;
    padding: 16px;
    background: var(--gold-dark);
    border: none;
    color: white;
    font-family: 'Cinzel', serif;
    font-size: 11px;
    letter-spacing: 3px;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.3s;
}

.btn-rsvp:hover {
    background: var(--gold);
}

/* ===== CLOSING SECTION ===== */
.closing-section {
    position: relative;
    min-height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    overflow: hidden;
    padding: 80px 30px;
}

.closing-section::before {
    content: '';
    position: absolute;
    inset: 0;
    background-image: url('assets/background-closing-bali.jpg');
    background-size: cover;
    background-position: center;
}

.closing-section::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(to bottom, rgba(10,5,0,0.6), rgba(10,5,0,0.75));
}

.closing-section .inner {
    position: relative;
    z-index: 1;
}

.closing-text {
    font-family: 'Open Sans', sans-serif;
    font-size: clamp(12px, 3.5vw, 14px);
    color: var(--cream-dark);
    line-height: 2;
    margin-bottom: 28px;
    max-width: 400px;
}

.closing-label,
.closing-names {
    font-family: 'Cinzel', serif;
    font-size: clamp(16px, 4.5vw, 20px);
    letter-spacing: 3px;
    text-transform: uppercase;
    color: var(--gold-light);
    line-height: 1.5;
}

.closing-label {
    margin-bottom: 4px;
}

.closing-names {
    margin-bottom: 100px;
}

/* "Om Shanti, Shanti, Shanti, Om" - di bawah Keluarga Besar Nyoman Budarsa */
.closing-salam {
    font-family: 'Cinzel', serif;
    position: relative;
    font-size: clamp(13px, 3.5vw, 15px);
    letter-spacing: 4px;
    color: var(--gold);
}

/* ===== FOOTER SECTION ===== */
.footer-section {
    background: var(--dark-brown);
    padding: 20px 30px;
    text-align: center;
}

.footer-made {
    font-family: 'Cinzel', serif;
    font-size: 11px;
    letter-spacing: 2px;
    color: var(--gold-light);
    margin-bottom: 8px;
}

.footer-visit {
    font-family: 'Open Sans', sans-serif;
    font-size: 11px;
    color: rgba(255,255,255,0.4);
    margin-bottom: 16px;
}

.footer-icons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

.footer-icons a {
    color: var(--gold-light);
    font-size: 18px;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-icons a:hover {
    color: var(--gold);
}

/* ===== MUSIC BUTTON ===== */
#music-btn {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 52px;
    height: 52px;
    background: var(--gold-dark);
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 900;
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
}

#music-btn:hover {
    background: var(--gold);
    transform: scale(1.05);
}

#music-btn i {
    color: white;
    font-size: 18px;
}

#music-btn.playing i {
    animation: spin 3s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to   { transform: rotate(360deg); }
}

/* ===== SCROLL ANIMATIONS ===== */
.reveal {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.7s ease, transform 0.7s ease;
}

.reveal.visible {
    opacity: 1;
    transform: translateY(0);
}

/* ===== KEYFRAMES ===== */
@keyframes fadeInDown {
    from { opacity: 0; transform: translateY(-20px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(20px); }
    to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}

/* ===== RESPONSIVE (mobile default) ===== */
@media (min-width: 768px) {
    #main-content {
        max-width: 500px;
        margin: 0 auto;
    }
}

/* ============================================================
   DESKTOP SIDEBAR — hanya muncul di desktop (≥768px)
   Diambil dari referensi file wigi
============================================================ */

/* Sembunyikan di mobile secara default */
#desk_cov {
    display: none;
}

/* Judul subtitle di sidebar desktop */
.desk-title-sub {
    font-family: 'Poppins', 'Open Sans', sans-serif;
    font-size: 0.85rem;
    font-weight: 400;
    letter-spacing: 0.35em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.85);
    margin-bottom: 0.6rem;
}

/* Judul utama (script font) di sidebar desktop */
.desk-title-main {
    font-family: 'Pinyon Script', cursive;
    font-size: 4rem;
    font-weight: 400;
    color: #ffffff;
    line-height: 1.1;
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}

/* === LAYOUT DESKTOP: sidebar kiri + panel kanan === */
@media (min-width: 768px) {

    /* Tampilkan sidebar desktop */
    #desk_cov {
        display: flex;
        position: fixed;
        left: 0;
        top: 0;
        width: calc(100% - 500px);
        height: 100vh;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        background: linear-gradient(160deg, #2c1a0e 0%, #5a3a1a 60%, #3d2410 100%);
        color: #ffffff;
        text-align: center;
        padding: 2rem;
        z-index: 10;
    }

    /* Geser #cover ke panel kanan saja */
    #cover {
        left: calc(100% - 500px);
        width: 500px;
    }

    /* Geser #main-content ke panel kanan, override margin: 0 auto */
    #main-content {
        margin-left: calc(100% - 500px);
        margin-right: 0;
        max-width: 500px;
    }
}

/* Tablet sedang (768–900px): sidebar proporsional */
@media (min-width: 768px) and (max-width: 900px) {
    #desk_cov {
        width: 45%;
    }
    #cover {
        left: 45%;
        width: 55%;
    }
    #main-content {
        margin-left: 45%;
        max-width: 55%;
    }
}

/* Scrollbar tipis di area panel kanan (desktop) */
@media (min-width: 768px) {
    ::-webkit-scrollbar { width: 6px; }
    ::-webkit-scrollbar-track { background: transparent; }
    ::-webkit-scrollbar-thumb {
        background-color: rgba(201, 169, 110, 0.4);
        border-radius: 20px;
    }
    ::-webkit-scrollbar-thumb:hover {
        background-color: rgba(201, 169, 110, 0.7);
    }
}
