﻿/* ========== GLOBAL RESPONSIVE SIZING (400px - 1920px) ========== */

/* Loading Screen Styling - Desktop Version */
#loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #ffc6c6;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    opacity: 1;
    transition: opacity 0.3s ease-out;
    backdrop-filter: blur(2px);
}

#loading-screen.fade-out {
    opacity: 0;
    pointer-events: none;
}

/* Loading Screen - Mobile Version (Hidden on desktop) */
#loading-screen-mobile {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    display: none;
    z-index: 9999;
    overflow: hidden;
    
}

#loading-screen-mobile.fade-out {
    opacity: 0;
    pointer-events: none;
}

.door-container {
    display: flex;
    width: 100%;
    height: 100%;
    position: relative;
}

.door {
    position: relative;
    height: 100%;
    width: 60%;
}

.left-door {
    animation: openLeftDoor 2.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards 1s;
    z-index: 1;
}

.right-door {
    animation: openRightDoor 2.5s cubic-bezier(0.34, 1.56, 0.64, 1) forwards 1s;
    z-index: 2;
    margin-left: -5px;
}

@keyframes openLeftDoor {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(-100%);
    }
}

@keyframes openRightDoor {
    from {
        transform: translateX(0);
    }
    to {
        transform: translateX(100%);
    }
}

/* Rotating Circle Logo Animation */
@keyframes rotateLogoSpin {
    from {
        transform: rotate(0deg);
        opacity: 1;
    }
    to {
        transform: rotate(360deg);
        opacity: 1;
    }
}

@keyframes fadeOutLogo {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

.rotating-logo {
    position: fixed;
    margin: center;
    margin-left: 16%;
    margin-top: 90px;
    transform: translate(-30%, -50%);
    width: 355px;
    height: 590px;
    z-index: 10;
    animation: rotateLogoSpin 0s linear forwards, fadeOutLogo 1s ease-in forwards 0.07s;
    pointer-events: none;
}

/* Desktop - Show text loading screen */
@media screen and (min-width: 451px) {
    #loading-screen {
        display: flex;
    }
    
    #loading-screen-mobile {
        display: none !important;
    }
}

/* Mobile - Show door animation */
@media screen and (max-width: 450px) {
    #loading-screen {
        display: none !important;
    }
    
    #loading-screen-mobile {
        display: flex;
    }
}

.loading-text {
    font-family: 'EnglishSpecial1', sans-serif;
    font-size: 4em;
    color: #e6c96b;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    margin: 0 0 10px 0;
    letter-spacing: 2px;
    order: -1;
}
.loading-text1 {
    font-family: 'EnglishSpecial1', sans-serif;
    font-size: 3.9em;
    color: #e6c96b;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    margin: 10px 0 0 0;
    letter-spacing: 2px;
}
html {
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    /* Lock zoom - prevent user from zooming in/out */
    touch-action: manipulation;
    -webkit-touch-callout: none;
}

body {
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    padding: 0;
}

/* ========== UNIVERSAL RESPONSIVE SIZING (400px - 1920px) ========== */
@media screen and (max-width: 1920px) {
    /* Ensure all major containers scale properly */
    html, body {
        width: 100%;
        max-width: 1920px;
        margin: 0 auto;
    }

    .container,
    .invitation-container,
    #page-2-main,
    #entrance-page {
        width: 100%;
        max-width: 1920px;
        margin: 0 auto;
    }

    /* 1. Set border2.png for Page 2 Main Invitation */
    .main-invitation-box {
        background-image: url('images/border2.webp') !important;
        width: 95% !important;
        max-width: 350px !important;
        height: 1200px !important;
        padding: 50px 15px !important; /* Adjust padding for the new border */
        background-size: 100% 100% !important;
    }

    /* 2. Scale down fonts for small screens */
    .សិរីមង្គលអាពាហ៍ពិពាហ៍, .សិរីមង្គលអាពាហ៍ពិពាហ៍2 {
        font-size: 1em !important;
        margin-top: 50px !important;
    }
    .couple-logo-image {
    /* Adjust these values to control the size of the monogram */
        width: 70px !important; /* Slightly smaller for mobile */
        height: 70px !important;
        margin-top: 30px !important; /* Reset the negative margin for better vertical flow */
        margin-left: 100px !important;
    }

    .Guest-name{
        font-size: 1.1em !important;
        text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
        font-weight: 200;
        color: #ffc919;
    }

    /* 3. Adjust the entrance button size for mobile */
    .decorative-button-mobile {
        width: 85% !important;
        height: auto !important;
        aspect-ratio: 350 / 100 !important;
        margin: 80px auto 0 !important;
        display: flex !important;
        justify-content: center !important;
        align-items: center !important;
        margin-top: -50px !important;
    }

    /* Hide desktop version on mobile */
    .decorative-button-desktop {
        display: none !important;
        margin-top: -30px !important;
        margin-top: -50px !important;
    }

    /* 4. Ensure the timeline and grids stack properly */
    .couple-row {
        display: flex !important;
        flex-direction: row !important; /* Forces side-by-side layout */
        justify-content: space-between !important;
        align-items: center !important;
        width: 100% !important;
        margin: 20px 0 !important;
    }

    /* 3. Adjust name containers for mobile width */
    .couple-info {
        width: 40% !important; /* Allocate space for names */
    }

    /* 4. Reset desktop margins to center names within their left/right blocks */
    .កូនប្រុសនាម, .កូនស្រីនាម {
        margin-left: 0 !important;
        margin-right: 0 !important;
        width: 100% !important;
        letter-spacing: 0.05em !important;
        font-size: 0.75em !important; /* Slightly smaller font to prevent overlap */
        text-align: center;
    }
    .Bride-Name {
        font-size: 0.85em !important; /* Slightly smaller font to prevent overlap */
        display: inline !important;
        margin: 0 3px !important;
        
    }
    .Groom-Name {
        font-size: 0.85em !important; /* Slightly smaller font to prevent overlap */
        display: inline !important;
        margin: 0 3px !important;
    }

    .couple-line {
        margin: 0 !important;
        padding: 0 !important;
        text-align: center !important;
        line-height: 1.5 !important;
    }

    .couple-line .កូនប្រុសនាម,
    .couple-line .កូនស្រីនាម {
        display: block !important;
        margin: 0 0 5px 0 !important;
    }

    .couple-line .Groom-Name,
    .couple-line .Bride-Name {
        display: inline !important;
        
        margin: 0 3px !important;
    }
   
    /* 5. Center the Monogram Logo in the middle of the names */
    .logo-center {
        width: 30% !important;
        display: flex;
        justify-content: center;
        margin-top: 40px !important;
        align-items: center;
    }

    .couple-logo-image {
        width: 95px !important; /* Scale logo down to fit between names */
        height: auto !important;
        margin-left: -8px !important;
    }

    /* 6. Ensure Parents also align nicely if you want them side-by-side */
    .parents-row {
        display: flex !important;
        flex-direction: row !important;
        justify-content: space-between !important;
    }
    
    .parent-info {
        width: 48% !important;
        font-size: 1em !important;
        margin-top: 15px !important;
    }

    .parent-line {
        margin: 0 !important;
        padding: 0 !important;
        text-align: center !important;
        line-height: 1.6 !important;
        margin-top: 7px !important;
    }

    .parent-line .title {
        display: inline !important;
        margin-right: 3px !important;
    }

    .parent-line .parent-name {
        display: inline !important;
        margin-left: 3px !important;
       
        
    }

    .title {
        font-size: 0.8em !important;

    }
    
}
    .long-text {
        width: 100% !important;
        font-size: 0.78em !important   ;
        max-width: 320px;
        margin: 10px auto !important;
        line-height: 2 !important;
    }

    /* 5. Center QR Code and Map Button */
    .qr-code-image {
        margin: 10px auto !important;
    }

    .map-link-button {
        width: 100% !important;
        max-width: 280px;
        margin-right: -90px !important;
        margin: 20px auto !important;
    }



/* ###################################################### */
/* COUNTDOWN SECTION STYLING */
/* ###################################################### */

/* --- Countdown Section Styling --- */
#countdown-section {
    padding: 40px 0;
    background-color: transparent;
    width: 100%;
    display: flex;
    justify-content: center;
}

.countdown-container {
    width: 100%;
    height: 100%;
    max-width: 10px;
    margin-top: 0; 
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 20px;
}

.countdown-box {
    position: relative;
    width: 100%;
    max-width: 380px; 
    margin: 0 auto;
    z-index: 1;
    margin-top: -80px !important;
}

.countdown-bg-image {
    width: 100%;
    height: 90%;
    border: 1px solid #c0b695;
    border-radius: 25px;
    opacity: 0.7;
    display: block;
    position: absolute;
    top: 0;
    left: 0;
    pointer-events: none;
}

.countdown-content {
    position: relative;
    width: 100%; 
    display: flex;
    flex-direction: column;
    justify-content: center; 
    align-items: center;
    padding: 40px 15px 30px 15px;
    box-sizing: border-box;
    text-align: center;
    margin-top: 30px;
}

.countdown-title {
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 0.9em;
    margin-top: -55px !important;
    color: #f1d577;
    margin: 5px 0 0 0;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}

/* Timer Layout */
.timer-grid {
    display: flex;
    justify-content: space-evenly;
    width: 100%;
    margin: 12px 0;
    gap: 3px;
}

.time-unit {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    margin: 0; 
}

.number-gold {
    font-family: var(--font-body-text) !important;
    font-size: 1.3rem;
    font-weight: 300;
    color: #f1d577;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}

.label-khmer {
    font-family: var(--font-body-text);
    font-size: 0.65em;
    color: #ffffff;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}

/* Footer (Date and Button) */
.countdown-footer {
    width: 100%;
    display: flex;
    flex-direction: column; 
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.wedding-date-text {
    font-family: var(--font-body-text);
    font-size: 0.6em;
    color: #f1d577;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin: 0;
    align-self: flex-start;
    padding-left: 30px;
}

/* Calendar Button Styling */
.calendar-button-link {
    text-decoration: none;
    /* Removed fixed width/height/margins that break centering */
    display: inline-block;
    width: 310px;
    margin-left: -10px !important;
    margin: 0; 
}

.calendar-button-inner {
    display: flex;
    justify-content: center;
    margin-left: 200px   !important;
    margin-top: -45px;
    align-items: center;
    border: 1.5px solid var(--gold-color);
    border-radius: 15px;
    padding: 6px 6px;
    background-color: rgba(0, 0, 0, 0.212); 
    transition: background-color 0.3s;
}

.calendar-button-text {
    font-family: var(--font-body-text);
    font-size: 0.55em;
    margin-right: -6px;
    color: var(--gold-color);
}

.calendar-icon {
    width: 18px;
    height: auto;
    margin-left: 15px;
}

/* --- Mobile Specific Adjustments (450px and below) --- */
@media screen and (max-width: 450px) {
    .countdown-content {
        /* Extra padding for border2.png decorations */
        margin-top: 53px !important   ;
        padding: 20px 20px 30px 20px !important; 
        justify-content: center !important;
    }

    .timer-grid {
        gap: 5px !important;
    }

    .number-gold {
        font-size: 1.6rem !important;
    }
}

/* ========== RSVP SECTION STYLING ========== */

#rsvp-section {
    padding: 40px 0;
    background-color: transparent;
    width: 100%;
    display: flex;
    justify-content: center;
}

.rsvp-container {
    width: 100%;
    height: 100%;
    max-width: 10px;
    margin-top: -35px !important;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 0 20px;
}

.rsvp-box {
    position: relative;
    width: 100%;
    max-width: 380px;
    margin: 0 auto;
    z-index: 1;
}

.rsvp-content {
    position: relative;
    width: 100%;
    height: 120px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    padding: 20px 20px;
    box-sizing: border-box;
    text-align: center;
     background: rgba(255, 144, 144, 0.129);
    border: 1px solid #c0b695;
    border-radius: 25px;
    gap: 10px;
}

.rsvp-title {
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 1em;
    color: #f1d577;
    margin: 0 0 25px 0;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}

.rsvp-options {
    display: flex;
    flex-direction: row;
    gap: 15px;
    width: 100%;
    justify-content: center;
    align-items: center;
}

.rsvp-btn {
    width: 140px;
    padding: 12px 20px;
    height: 45px;
    border: 1px solid #c0b695;
    border-radius: 15px;
    margin: 0;
    background-color: rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: all 0.3s ease;
    color: #f1d577;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: var(--font-heading);
    font-size: 0.9em;
    font-weight: 200;
    margin-top: -30px;
}

.rsvp-btn:hover {
    background-color: rgba(241, 213, 119, 0.1);
    border-color: #f1d577;
    color: #f1d577;
}

.rsvp-btn-accept {
    color: #f1d577;
    border-color: #f1d577;
}
.rsvp-btn-text {
    font-family: var(--font-body-text);
    font-size: 0.9em;
    margin-top: 0px;
    color: #f1d577;
}

.rsvp-btn-accept:hover {
    background-color: rgba(241, 213, 119, 0.1);
    color: #f1d577;
    border-color: #f1d577;
}

.rsvp-btn-decline {
    color: #f1d577;
    border-color: #f1d577;
}

.rsvp-btn-decline:hover {
    background-color: rgba(241, 213, 119, 0.2);
    color: #f1d577;
    border-color: #f1d577;
}

.rsvp-btn.selected {
    background-color: rgba(241, 213, 119, 0.2);
    color: #000000;
    border-color: #020202;
}

.rsvp-btn-accept.selected {
    background-color: #f1d5773b;
    color: #f1d577;
    border-color: #f1d577;
}

.rsvp-btn-decline.selected {
    background-color: #f1d5773b;
    color: #f1d577;
    border-color: #f1d577;
}

/* Mobile Adjustments */
@media screen and (max-width: 450px) {
    .rsvp-content {
        padding: 20px 15px;
        margin-top: -20px !important;
    }

    .rsvp-title {
        font-size: 0.9em;
        margin-top: 0px;
    }

    .rsvp-btn {
        padding: 5px 10px;
        font-size: 0.85em;
    }
    .rsvp-btn-text {
    font-family: var(--font-body-text);
    font-size: 0.8em;
    color: #f1d577;
}
}

:root {
    --gold-color: #f1d577; /* A classic gold */
    --font-body: 'Arial', sans-serif;
    /* ================================================== */
    /* ✅ FONT VARIABLES - CHANGE THESE TO CHANGE THE LOOK */
    /* ================================================== */
    --font-heading: 'HeadingKhmer', serif;
    --font-display: 'DisplayKhmer', serif;
    --font-body-text: 'BodyKhmer', serif;
    --font-name: 'English', serif; /* For Parent/Guest/Couple names */
    --font-button: 'ButtonKhmer', serif; 
    --font-eng: 'EnglishStandard', serif; /* Standard English Font */
    --font-engspecial: 'EnglishSpecial', serif; /* Special English Font */
    /* ================================================== */
}

/* Base Reset and Global Styles */
body {
    font-family: var(--font-body);
    line-height: 1.6;
    margin: 0;
    padding: 0;
    background-color: #f8f8f8;
    overflow-x: hidden;
    /* ✅ CRITICAL: Hide global scrollbar until Page 2 is active */
    overflow-y: hidden;
}


/* Background Video Styling */
/* Background Video Base Styles */
.bg-video-desktop,
.bg-video-mobile {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    z-index: -1;
}

/* PAGE 1 BACKGROUND VIDEOS - Initially visible */
.page1-bg {
    display: block;
    transform: scale(1);
}

/* PAGE 2 BACKGROUND VIDEOS - Initially hidden */
.page2-bg {
    display: none;
    transform: scale(1) !important;
    will-change: auto !important;
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    z-index: -1 !important;
    background-attachment: fixed !important;
    pointer-events: none !important;
}

/* Desktop Video - Display on PC screens (over 450px) */
#page1-bg-video-desktop {
    display: block;
}

#page1-bg-video-mobile {
    display: none;
}

#page2-bg-video-desktop {
    display: none;
}

#page2-bg-video-mobile {
    display: none;
}

/* Mobile Responsive Video Display */
@media screen and (max-width: 450px) {
    #page1-bg-video-desktop {
        display: none;
    }

    #page1-bg-video-mobile {
        display: block;
    }

    #page2-bg-video-desktop {
        display: none;
    }

    #page2-bg-video-mobile {
        display: none;
    }
    
}


/* ###################################################### */
/* PAGE 1: ENTRANCE STYLING */
/* ###################################################### */
#entrance-page {
    /* Styles for full-screen centering */
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    text-align: center;
    position: relative;
    /* ✅ FIX: Ensure the entrance page is on top for clickability */
    z-index: 100;
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    padding-top: 0;
    padding-bottom: 0;
    background-color: rgba(0, 0, 0, 0.3);
}

/* 🌟 Entrance Page FADE-IN ANIMATION 🌟 */



@keyframes entranceFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px); 
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
    
}

@keyframes fadeInBorder {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

#entrance-page.fade-in {
    opacity: 0; 
    /* Delay the start of the whole page fade slightly */
    animation: entranceFadeIn 2s ease-out 0.2s forwards; 
}


/* 🌟 Entrance Page Overrides (No background inside the border, visible) 🌟 */
.entrance-override {
    width: 100% !important; 
    height: 660px !important;
    max-width: 210px !important;
    background-image: url('images/border.webp');
    background-size: 100% 100% !important;
    margin-top: -10px    !important;
    margin-bottom: 5px !important;
    /* 1. CRITICAL CHANGE: Remove background color */
    background-color: transparent !important; 
    /* 2. CRITICAL CHANGE: Make the entrance box visible on load */
    opacity: 0;
    background-color: #814a241e !important;
    animation: fadeInBorder 0.8s ease-out forwards 2.8s;
    /* 3. AUTO ZOOM IN 10% */
    transform: scale(1.1);
    transform-origin: center center;
}
.entrance-photo {
    /* Adjust size as needed for your photo */
    width: 105px; 
    height: 105px; 
    border-radius: auto; /* Makes the photo circular */
    margin-top: 50px; /* Space between photo and the main title */
    display: block; /* Ensure it behaves like a block element */
    margin-left: auto; /* Center the image */
    margin-right: auto; /* Center the image */
}

.top {
    /* Adjust size as needed for your photo */
    width: 140px; 
    height: 50px; 
    border-radius: auto; /* Makes the photo circular */
    margin-top: 5px; /* Space between photo and the main title */
    display: block; /* Ensure it behaves like a block element */
    margin-left: auto; /* Center the image */
    margin-right: auto; /* Center the image */
}
/* Force dark text for readability on the transparent box/light background */
.entrance-override .សិរីមង្គលអាពាហ៍ពិពាហ៍{
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 0.7em;
    margin-top: 20px !important;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    font-weight: 200;
    color: #fdd245;
}
.សូមគោរពអញ្ជើញ{
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 1em;
    margin-top: 10px;
    margin-bottom: 5px !important;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    font-weight: 200;
    color: #fdd245;
}
.entrance-override 
.Guest-name {
    font-family: var(--font-heading);
    font-size: 1.5em;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
    font-weight: 200;
    color: #fdd245;

}
.button-text{
    font-family: var(--font-button);
    font-size: 0em;
    font-weight: bold;
    color: #ffffff;

}
.entrance-override .monogram-placeholder {
    color: #333 !important;
    text-shadow: none !important;
}






.button-container {
    display: flex;
    justify-content: center;
    width: 100%;
    margin-top: 20px; /* Space above the button */
}





/* ========== DECORATIVE BUTTON - BASE SHARED STYLES ========== */
.decorative-button {
    background-color: transparent;
    background-image: url('images/button.png');
    background-size: contain; 
    background-repeat: no-repeat;
    background-position: center; 
    border: none;
    padding: 0;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    /* Animation */
    animation: flyUpDown 2.5s infinite ease-in-out !important;
    will-change: transform;
    transition: transform 0.2s ease-out !important;
    position: relative;
}

/* ========== DECORATIVE BUTTON - MOBILE (450px) ========== */
.decorative-button {
    width: 90%;
    max-width: 280px;
    height: auto;
    aspect-ratio: 310 / 80;
    margin: 25px auto 0;
    margin-top: 40px !important;
    animation: flyUpDown 2.5s infinite ease-in-out !important;
}

/* ========== DECORATIVE BUTTON - DESKTOP (1920px) ========== */
@media screen and (min-width: 769px) {
    .decorative-button {
        width: 120%;
        max-width: 400px;
        height: 70px;
        aspect-ratio: 310 / 80;
        margin: 10px auto 0;
        margin-left: -20px !important;
        margin-top: 48px !important;
        animation: flyUpDown 2.5s infinite ease-in-out !important;
    }
}

/* Style for the button background image */
.button-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    position: absolute;
    top: 0;
    left: 0;
}

/* Style for the text placed over the image */
.button-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-family: var(--font-body-text);
    font-size: 0.8em; 
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
    font-weight: 500;
    color: #ffffff;
    line-height: 1;
    z-index: 21;
    margin-top: 5px !important;
}

@keyframes flyUpDown {
    0% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-16px);
    }
    100% {
        transform: translateY(0);
    }
}

/* ###################################################### */
/* SHARED & PAGE 2 STYLING */
/* ###################################################### */

/* Ensure text in the invitation box has better contrast on Page 2 (dark background) */
#invitation-box-section 
.សិរីមង្គលអាពាហ៍ពិពាហ៍2 {
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 1.5em;
    margin-top: 40px;
    margin-bottom: -20px;
    color: rgb(255, 222, 88);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}

/* --- Transition Overlay (UNCHANGED) --- */
#transition-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    /* ✅ FIX: Z-index lower than entrance page */
    z-index: 90; 
    display: none;
    justify-content: center;
    align-items: center;
}

#transition-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* White fade overlay after transition video ends */
#transition-overlay::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: white;
    opacity: 0;
    transition: opacity 0.5s ease-in;
    pointer-events: none;
}

#transition-overlay.fade-to-white::after {
    opacity: 1;
}

/* Fade in transition from white */
#transition-overlay {
    opacity: 1;
    transition: opacity 0.5s ease-out;
}

#transition-overlay.fade-from-white {
    opacity: 0;
}

/* Display English translation below Khmer text on Page 2 */
#page-2-main [data-i18n-en]::after {
    content: attr(data-i18n-en);
    display: block;
    font-family: 'EnglishStandard', sans-serif;
    font-size: inherit;
    color: inherit;
    margin-top: 3px;
    line-height: 1.2;
}

/* Adjust letter spacing for English bride name */
#page-2-main .Bride-Name[data-i18n-en]::after {
    letter-spacing: 0.05em;
}

/* --- PAGE 2: MAIN CONTENT STYLING --- */
#page-2-main {
    display: none;
    position: relative;
    /* ✅ FIX: Z-index lowest for content */
    z-index: 10; 
    min-height: 100vh;
    padding: 0;
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    box-sizing: border-box;
    background-color: transparent;
    /* ✅ Lock horizontal scroll on page 2 */
    overflow-x: none;
    /* ✅ Prevent horizontal scrolling */
    touch-action: pan-y;
}

/* Page 2 Background Overlay - Separate from page-2-main */
#page-2-bg {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0);
    z-index: 9;
    display: none;
    transition: background-color 1s ease-in;
}

#page-2-bg.fade-in-bg {
    background-color: rgba(0, 0, 0, 0.35);
}


.section {
    padding: 50px 0;
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
}

.container {
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    padding: 0 15px;
    box-sizing: border-box;
}

/* ========== RESPONSIVE CONSTRAINT: 400px - 1920px ========== */
/* All major sections inherit proper width scaling */
section,
#countdown-section,
#photo-section,
#wishes-section {
    width: 100%;
    max-width: 1920px;
    margin: 0 auto;
    box-sizing: border-box;
}

/* Ensure proper minimum width for small screens */
@media screen and (min-width: 400px) and (max-width: 1920px) {
    body, html {
        width: 100%;
        max-width: 1920px;
    }
}

@keyframes mainFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

@keyframes fadeToBlack {
    from {
        background-color: rgba(0, 0, 0, 0);
    }
    to {
        background-color: rgba(0, 0, 0, 0.5);
    }
}

@keyframes fadeInFromLeft {
    from {
        opacity: 0;
        transform: translateX(-60px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

@keyframes fadeInFromRight {
    from {
        opacity: 0;
        transform: translateX(60px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

    


/* --- INVITATION BOX STYLES (BASE FOR BOTH PAGES: Border, Size, Padding) --- */
.invitation-container {
    display: flex;
    justify-content: center;
    align-items: flex-start; /* Aligns to top */
    min-height: auto; /* Allow height to expand */
    margin-top: -40px;
    width: 100%;
    max-width: 1920px;
    margin-left: auto;
    margin-right: auto;
}
.invitation-box {
    /* 1. Dimensions (SHARED BASE) */
    width: 33%;
    max-width: 160px; 
    height: 850px;
    text-align: center;
    position: center; 
    background-size: 100% 100%; 
    margin-top: auto; 
    background-repeat: no-repeat;
    padding: 10px 70px; 
    opacity: 0;
    transition: opacity 1.5s ease-out, transform 1.5s ease-out;
}

/* Class applied by JS to make the border and box appear on Page 2 */
.invitation-box.border-fade-in {
    opacity: 1;
    animation: mainFadeIn 1.5s ease-out forwards;
}


/* Class to hide text elements initially (REQUIRED for sequential fade) */
.fade-in-item {
    opacity: 0;
    /* Define the starting position: slightly down and slightly smaller */
    transform: translateY(18px) scale(0.98); 
    /* Set transition properties for when the JS adds the 'is-visible' class */
    transition: opacity 0.2s ease-out, transform 0.5s ease-out;
}

/* Entrance page fade-in items with staggered animation after doors open */
#entrance-page .fade-in-item {
    opacity: 0;
    animation: fadeInEntranceItem 0.8s ease-out forwards;
}

#entrance-page .fade-in-item:nth-child(1) {
    animation-delay: 2.8s; /* Border */
}

#entrance-page .fade-in-item:nth-child(2) {
    animation-delay: 3.1s; /* Monogram/photo */
}

#entrance-page .fade-in-item:nth-child(3) {
    animation-delay: 4s; /* Top photo */
}

#entrance-page .fade-in-item:nth-child(4) {
    animation-delay: 4.3s; /* Guest name */
}

#entrance-page .fade-in-item:nth-child(5) {
    animation-delay: 4.6s; /* Bottom image */
}

#entrance-page .fade-in-item:nth-child(6) {
    animation-delay: 4.9s; /* Button - appears last */
}

@keyframes fadeInEntranceItem {
    from {
        opacity: 0;
        transform: translateY(10px) scale(0.98);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

/* Ensure decorative button fades in and then flies up/down continuously */
#enter-button.fade-in-item {
    opacity: 0;
    animation: fadeInEntranceItem 0.8s ease-out forwards 5.3s,
               flyUpDown 2.5s infinite ease-in-out 5.3s !important;
    animation-fill-mode: forwards;
    will-change: transform;
}

/* Add fade-in animations to text elements */
.entrance-override .សូមគោរពអញ្ជើញ {
    opacity: 0;
    animation: fadeInEntranceItem 0.8s ease-out forwards 3.4s;
}

.entrance-override .សិរីមង្គលអាពាហ៍ពិពាហ៍ {
    opacity: 0;
    animation: fadeInEntranceItem 0.8s ease-out forwards 3.7s;
}


/* Final state class applied by JS when the element IS in view */
.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    /* Set the actual animation duration for a smooth transition */
    transition: opacity 1.0s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
                transform 1.0s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}


.title {
    font-family: var(--font-body);
    font-size: 0.8em;
    color: #ffffff;
    margin-bottom: 20px;
    font-weight: 600;
}

/* Parent/Couple Name Layouts (Splitting Left/Right) */
.parents-row, .couple-row {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin: 20px 0;
}

.parent-info, .couple-info {
    width: 45%;
    text-align: center;
}

.title {
    font-family: var(--font-body-text);
    font-size: 0.8em;
    font-weight: 400;
    
    margin-bottom: 5px;
    color: #ffffff;
}

.parent-name {
    font-family: var(--font-body-text);
    font-size: 0.85em;
     margin-top: 30% !important;
    color: #ffde59;
    font-weight: 00;
}

.parent-name-full {
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 0.8em;
    color: #ffde59;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    display: flex;
    flex-direction: column;
    align-items: center;
    margin: 0;
    letter-spacing: -0.05em;
}

.មានកិត្តិយសសូមគោរពអញ្ជើញ {
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 0.96em;
    margin-top: -5px   !important;
    color: rgb(255, 222, 88);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin: 30px 0 20px;
    font-weight: 200;
}

/* Long text formatting */
.long-text {
    font-family: var(--font-body-text);
    font-size: 0.83em;
    /* ✅ FIX: Reduced line-height for text density */
    line-height: 2.12; 
    letter-spacing: 0.03em;
    color: #ffffff;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin: 0 auto 40px;
    margin-top: 2px !important;
    margin-bottom: 30px !important;
    max-width: 600px;
}

/* Couple Names & Logo */
.title-row {
    display: flex;
    justify-content: space-between; /* Spreads the two blocks apart */
    align-items: flex-start;
    width: 90%; /* Defines the width inside the invitation box */
    max-width: 500px;
    
    margin: 60px auto; /* Centers the row and adds vertical space */
}

/* Individual Block for the Title/Name combo */
.title-block {
    width: 48%; /* Each block takes nearly half the width */
    padding: 10px 0;
}


.title-block.left-center, 
.title-block.right-center {
    text-align: center; /* Centers the text within the 48% block */
}

/* --- EXISTING NAME STYLES (Adjusted for consistency) --- */

.Bride-Name{
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 0.9em; /* Increase size slightly for impact */
    letter-spacing: -0.08em !important;
    margin-right: -45px;
    color: rgb(255, 222, 88);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin-top: 20px; 
    margin-bottom: 0;
    /* text-align: center is inherited from .title-block, so no need to add here */
}

.Groom-Name {
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 0.9em; /* Increase size slightly for impact */
    letter-spacing: 0.01em !important;
    margin-left: 30px;
    color: rgb(255, 222, 88);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin-top: 20px; 
    margin-bottom: 0;
    /* text-align: center is inherited from .title-block, so no need to add here */
}

.កូនប្រុសនាម {
    font-family: var(--font-body-text);
    font-size: 0.85em; /* Adjusted size */
    /* ✅ FIX: Reduced line-height significantly */
    line-height: 1.5;
    margin-right: 30px !important;
    color: #ffffff;
    margin: 0; /* Remove excess margins */
    margin-top: -5px;
    /* text-align: center is inherited from .title-block, so no need to add here */
}
.កូនស្រីនាម{
    font-family: var(--font-body-text);
    font-size: 0.85em; /* Adjusted size */
    /* ✅ FIX: Reduced line-height significantly */
    line-height: 1.5;
    margin-left: 0px !important;
    color: #ffffff;
    margin: 0; /* Remove excess margins */
    margin-top: -5px;
    /* text-align: center is inherited from .title-block, so no need to add here */
}


.couple-info {
    width: 45%; /* Allocates space for the name columns */
    /* REMOVE text-align: center; from here if present */
}

/* Explicitly align the left column text */
.couple-info.left-aligned {
    text-align: left;
}

/* Explicitly align the right column text */
.couple-info.right-aligned {
    text-align: right;
}

/* Ensure the central container is tiny and centered */
.logo-center {
    width: 10%; /* Small container for the logo */
    display: flex;
    justify-content: center;
    align-items: center;
}

/* New CSS class for the Monogram Image */
.couple-logo-image {
    /* Adjust these values to control the size of the monogram */
    width: 70px; 
    height: 70px; 
    margin-top: -50px  !important;
    object-fit: contain; /* Ensures the image scales down without being cropped */
    
}


.ដែលប្រព្រឹត្តទៅនៅ {
    font-family: var(--font-heading);
    font-size: 0.85em;
    margin-top: 10px;
    color: rgb(255, 255, 255);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    font-weight: 400;
}

.date {
    font-family: var(--font-body-text);
    font-size: 1.15em;
    /* ✅ FIX: Reduced line-height for date density */
    line-height: 1.3;
    color: rgb(255, 222, 88);
    margin-top: -8px !important;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin: 0 auto 15px;
    max-width: 600px;
    word-break: break-word;
    overflow-wrap: break-word;
    font-feature-settings: 'loca' on;
}
.location {
    font-family: var(--font-body-text);
    font-size: 0.85em;
    color: #ffffff;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin: 0 auto 10px;
    max-width: 600px;
    word-break: break-word;
    overflow-wrap: break-word;
    font-feature-settings: 'loca' on;
}
    

.time {
    font-family: var(--font-body-text);
    font-size: 0.85em;
    /* ✅ FIX: Reduced line-height for time density */
    margin-top: 15px    !important;
    color: rgb(255, 222, 88);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin: 0 auto 10px;
    margin-top: -3px   !important;
    max-width: 600px;
}


/* Footer Styling */
.footer {
    text-align: center;
    padding: 20px 0;
    margin-top: -50px;
    background-color: #DDD;
    color: #555;
}

/* --- LOCATION MAP SECTION STYLES --- */
.location-map-section {
    margin-top: 50px;
    padding-top: 30px;
}

.location-title {
    font-family: var(--font-heading);
    font-size: 1em;
    letter-spacing: 1px; ;
    color: rgb(255, 222, 88); /* Gold color */
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin: 10px 0 5px;
    margin-top: -85px   !important;
    font-weight: 400;
}

.scan-text {
    font-family: var(--font-body-text);
    font-size: 0.85em;
    color: #ffffff;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin-top: 1px   !important;
    margin-bottom: 15px;
}

.qr-code-image {
    width: 110px; /* Adjust size as needed */
    height: 110px;
    object-fit: contain;
    margin: 0 auto 25px; /* Centers the image and adds space below */
    margin-top: -3px   !important;
    display: block;
    border-radius: 5px;
    background-color: transparent;
    box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
}

/* 🌟 NEW MAP LINK BUTTON STYLES 🌟 */
.map-link-button {
    display: flex !important;
    justify-content: center !important;
    align-items: center !important;
    margin: 20px auto !important;
    width: 100% !important;
    max-width: 280px !important;
    position: relative !important;
    margin-top: -10px !important;
    text-decoration: none;
    height: 70px;
}

/* Ensure the background image within the button is centered */
.map-button-image-inner {
    width: 75% !important;
    height: 75% !important;
    position: absolute !important;
    top: 46% !important;
    left: 50% !important;
    transform: translate(-50%, -50%) !important; /* Perfectly centers background image */
    object-fit: contain;
    z-index: 1;
}

/* Center the text and the small logo over the button */
.map-button-text {
    font-family: var(--font-body-text)  !important;
    font-size: 0.6rem !important;
    position: relative !important;
    z-index: 2;
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    justify-content: center !important;
    left: 0 !important;
    top: 0 !important;
    transform: none !important;
    color: #ffffff;
    font-weight: bold;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
}

/* Align the Google Maps icon inside the text flexbox */
.google-maps-logo {
    width: 12px !important;
    height: 16px !important;
    margin-left: 8px !important;
    margin-top: -6px !important;     /* Reset negative desktop margins */
    z-index: 2;
    position: static !important;  /* Allow it to sit naturally next to text */
}

/* Desktop Agenda Symbol Styling */
.agenda-symbol {
    width: 32px;
    height: auto;
    margin-left: -10px;
    margin-top: -10px;
    margin-bottom: 10px;
    display: block;
}

.agenda-symbol1 {
    width: 32px;
    height: auto;
    margin-left: -10px;
    margin-top: -60px;
    margin-bottom: 10px;
    display: block;
}

/* Agenda Period Label (Desktop & Mobile) */
.agenda-period-label {
    font-size: 0.65em;
    margin-top: -45px;
    margin-bottom: 10px;
    margin-left: -80px;
    color: #f1d577;
    font-family: var(--font-body-text);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    display: block;
    width: 100%;
    text-align: center;
}
@media screen and (max-width: 768px) {
    .entrance-override {
        width: 100% !important;
        height: 610px !important;
        max-width: 300px !important;
        padding: 6% 5% !important;
        margin-top: -35px !important;
        margin-bottom: 5px !important;
    }
}
/* Specific adjustment for mobile 450px */
@media screen and (max-width: 450px) {
    #entrance-page {
        height: 100vh;
        padding-top: 10px;
        padding-bottom: 10px;
    }

    .entrance-override {
        width: 100% !important;
        height: 610px !important;
        max-width: 295px !important;
        padding: 6% 5% !important;
        margin-top: -37px !important;
        margin-bottom: 5px !important;
    }

    .album-wrapper {
        width: 92%;
        max-width: 400px;
        margin: 0 auto;
        padding: 0 8px;
    }

    .album-photo {
        border-radius: 16px;
        margin-bottom: 18px;
    }

    .album-row {
        gap: 15px;
        margin-bottom: 18px;
    }

    .album-photo.medium {
        width: 48%;
        height: 200px;
    }

    .album-photo.big {
        height: 220px;
        width: 100%;
    }

    .map-link-button {
        max-width: 280px !important; /* Scale down slightly for smaller screens */
    }

    /* Agenda section mobile responsive */
    .agenda-container {
        flex-direction: column;
        gap: 20px;
        
    }

    .agenda-timeline-box {
        width: 92%;
        max-width: 380px;
        padding: 15px 10px;
    }

    .agenda-logo-container {
        display: flex;
        justify-content: center;
        align-items: center;
        margin-bottom: -10px;
        margin-top: -50px;
    }

    .agenda-logo-image {
        width: 270px;
        height: 90px;
        object-fit: contain;
        opacity: 0.85;
    }

    .agenda-title {
        font-size: 1.1em;
        margin-top: -50px !important;
        margin-bottom: 5px;
    }

    .agenda-date {
        font-size: 0.8em;
        margin-bottom: 50px;
    }

    .agenda-symbol {
        width: 30px;
        height: auto;
        margin-left: -10px;
        margin-top: -20px;
        margin-bottom: 15px;
        display: flex;
    }

    .agenda-symbol1 {
        width: 30px;
        height: auto;
        margin-left: -10px;
        margin-top: -55px;
        margin-bottom: 15px;
        display: flex;
    }

    .timeline-item {
        margin-bottom: 20px;
        padding-left: 30px;
        
    }

    .agenda-content-box {
        padding: 8px 18px;
        background: rgba(52, 35, 35, 0.195);
        margin-left: 15px;
        color: #ffeb36;
    }

    .time-label {
        font-size: 0.7em;
    }

    .ceremony-title {
        font-size: 0.8em;
    }

    /* Mobile styling for location and date text */
    .location {
        font-size: 0.75em;
        line-height: 1.5;
        word-break: break-word;
        overflow-wrap: break-word;
        padding: 0 10px;
    }

    .date {
        font-size: 0.95em;
        line-height: 1.4;
        word-break: break-word;
        overflow-wrap: break-word;
        padding: 0 10px;
    }

    .time {
        font-size: 0.75em;
        line-height: 1.5;
        word-break: break-word;
        overflow-wrap: break-word;
        padding: 0 10px;
    }
}
/* END OF NEW MAP LINK BUTTON STYLES */


/* ###################################################### */
/* MEDIA QUERY: DESKTOP & LARGE SCREEN OPTIMIZATION */
/* ###################################################### *

/* ###################################################### */
/* AGENDA TIMELINE STYLING (Left-Aligned, Boxed Content) */
/* ###################################################### */

:root {
    /* Ensure the bright gold is defined, or use the color provided: */
    --bright-gold-border: #f1d577; 
}

#agenda-section {
    padding-top: 50px;
    margin-top: -5% !important;
    padding-bottom: 80px;
    background-color: transparent;
}

.agenda-container {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
}

.agenda-timeline-box {
    width: 98%;
    max-width: 395px;
    text-align: center;
    padding: 40px 10px;
}

.agenda-logo-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 15px;
}

.agenda-logo-image {
    width: 270px;
    height: 90px;
    object-fit: contain;
    opacity: 0.85;
    margin-top: -50px;
}

.agenda-title {
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 1.1em;
    color: var(--gold-color);
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    margin-top: -10px   !important;
    margin-bottom: 5px;
   
}

.agenda-date {
    font-family: var(--font-body-text);
    font-size: 0.8em;
    color: #ffffff;
    margin-bottom: 50px;
}

/* Timeline Structure */
.timeline-wrapper {
    position: relative;
    padding: 0;
    margin: 0 auto;
}

/* Vertical Line (Fixed to the Left) */
.timeline-wrapper::before {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: 5px; /* <<< CRITICAL CHANGE: Align line to the left edge */
    width: 2px;
    background-color: var(--bright-gold-border);
    z-index: 0;
}

/* Individual Timeline Item */
.timeline-item {
    display: flex;
    /* Items align dot left, content left */
    justify-content: flex-start; 
    align-items: center;
    margin-bottom: 20px;
    position: relative;
    padding-left: 30px; /* <<< CRITICAL CHANGE: Create space for the image dot on the left */
    padding-right: 0; /* Reset right padding */
    opacity: 0;
    transform: translateX(60px);
}

.timeline-item.animate {
    animation: fadeInFromRight 1s cubic-bezier(0.34, 1.56, 0.64, 1) forwards;
}

.timeline-item:nth-child(1).animate {
    animation: fadeInFromRight 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0s forwards;
}

.timeline-item:nth-child(2).animate {
    animation: fadeInFromRight 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0.15s forwards;
}

.timeline-item:nth-child(3).animate {
    animation: fadeInFromRight 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0.3s forwards;
}

.timeline-item:nth-child(4).animate {
    animation: fadeInFromRight 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0.45s forwards;
}

.timeline-item:nth-child(5).animate {
    animation: fadeInFromRight 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0.6s forwards;
}

.timeline-item:nth-child(6).animate {
    animation: fadeInFromRight 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0.75s forwards;
}

.timeline-item:nth-child(7).animate {
    animation: fadeInFromRight 1s cubic-bezier(0.34, 1.56, 0.64, 1) 0.9s forwards;
}

/* Timeline Dot Image (Positioned on the Left Line) */
.timeline-dot-image {
    width: 25px;
    height: 25px;
    object-fit: contain;
    position: absolute;
    top: 50%;
    left: 5px; /* <<< CRITICAL CHANGE: Position left on the line */
    transform: translate(-50%, -50%); /* Shift it half its width over the line */
    z-index: 1;
}


/* Content Positioning */
.timeline-content {
    width: 100%;
    text-align: left; 
    margin-bottom: 0px;
}

/* Agenda Content Box (The Bordered Box) */
.agenda-content-box {
    border: 1.5px solid var(--bright-gold-border); 
    background: rgba(52, 35, 35, 0.195);
    color: #ffeb36;
    padding: 7px 13px;
    border-radius: 21px;
    margin-left: 15px; /* <<< CRITICAL CHANGE: Space between box and timeline line */
    margin-right: 0; /* Reset right margin */
}

.time-label {
    font-family: var(--font-body-text);
    font-size: 0.7em;
    color: #ffffff;
    font-weight: 500;
    margin: 0 0 5px 0;
    display: flex;
    align-items: center;
    gap: 6px;
}

.time-icon {
    width: 25px;
    height: 25px;
    object-fit: contain;
    margin-top: -3px;
    display: inline-block;
}

.ceremony-title {
    font-family: var(--font-body-text);
    font-size: 0.8em;
    color: var(--gold-color);
    margin: 0;
    line-height: 1.5;
    font-weight: 500;
}

/* ----------------------------------------------------
   LOVE STORY SECTION (FOLLOWING VIDEO STYLE)
------------------------------------------------------*/

#love-story-section {
    text-align: center;
    color: #fff;
    margin-top: 40px;
}

.love-story-title {
    font-family: var(--font-engspecial);
    font-size: 3em;
    margin-bottom: 10px;
    margin-top: -55px;
    margin-bottom: 40px;
    font-weight: 400;
    color: rgb(255, 222, 88);

}

.love-story-title span {
    color: #ffffff;
    margin-bottom: 60px;
    font-family: var(--font-engspecial);
     margin-bottom: 20px;
}

.love-story-wrapper {
    display: flex;
    justify-content: center;
    align-items: flex-start;
    gap: 100px;
    margin-top: 70px;
}

.love-story-photo {
    border-radius: 15px;
    box-shadow: 0 0 25px rgba(255, 215, 0, 0.25);
    object-fit: cover;
}

.love-story-photo.fade-in-item {
    opacity: 0;
    
    transform: translateY(18px) scale(0.98);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.love-story-photo.fade-in-item.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    transition: opacity 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94), 
                transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}

.love-story-quote.fade-in-item {
    opacity: 0;
    transform: translateY(18px) scale(0.98);
    transition: opacity 0.6s ease-out 0.8s, transform 0.6s ease-out 0.8s;
}

.love-story-quote.fade-in-item.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
    transition: opacity 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.8s, 
                transform 0.6s cubic-bezier(0.25, 0.46, 0.45, 0.94) 0.8s;
}

.love-story-photo-groom {
    width: 210px;
    height: 310px;
    margin-top: -30px !important;
    margin-left: 10px !important;
    transform: scaleX(-1) !important;
    
}

.love-story-photo-bride {
    width: 210px;
    height: 310px;
    margin-top: -130px !important;
    margin-left: -20px !important;
    
}

.love-story-quote {
    font-family: var(--font-name);
    font-size: 0.9em;
    margin-top: 20px !important;
    line-height: 1.8;
    margin-left: -80px !important;
    text-align: left;
    letter-spacing: -0.04em;
    font-weight: 300;
    color: #ffffff;
    position: relative;
    z-index: 10;
}
.love-story-quote1 {
    font-family: var(--font-name);
    font-size: 0.9em;
    margin-top: -70px !important;
    line-height: 1.8;
    margin-right: -60px !important;
    text-align: right;
    max-width: 300px;
    font-weight: 300;
    color: #ffffff;
    position: relative;
    z-index: 10;
}

/* Love Story Mobile Alignment (450px and below) */
@media screen and (max-width: 450px) {
    .love-story-wrapper {
        display: grid;
        grid-template-columns: 1fr 1fr;
        grid-template-rows: auto auto;
        gap: 15px;
        margin-top: 10px;
        align-items: center;
        width: 100%;
        max-width: 350px;
        margin-left: auto;
        margin-right: auto;
    }

    .love-story-photo {
        width: 200px;
        height: 280px;
        margin-bottom: 0 !important;
        border-radius: 10px;
        box-shadow: 0 0 20px rgba(255, 215, 0, 0.2);
        object-fit: cover;
    }

    .love-story-photo-groom {
        margin-bottom: 60px !important;
        margin-left: 0px !important;
        transform: scaleX(-1) !important;
    }

    .love-story-photo-bride {
        margin-top: -150px !important;
        margin-left: 5px !important;
        margin-bottom: -10px !important;

    }

    .love-story-photo:nth-child(1) {
        
        grid-column: 1;
        grid-row: 1;
    }

    .love-story-photo:nth-child(3) {
        grid-column: 2;
        grid-row: 2;
    }

    .love-story-quote {
        font-family: var(--font-name);
        font-size: 0.9em;
        margin-top: -100px !important;
        line-height: 1.8;
        text-align: left;
        margin-left: -5px !important;
        max-width: 100%;
        font-weight: 300;
        color: #ffffff;
        letter-spacing: -0.05em;
        position: relative;
        z-index: 10;
    }
    .love-story-quote1 {
    font-family: var(--font-name);
        font-size: 0.9em;
        margin-top: -120px !important;
        line-height: 1.8;
        text-align: right;
        margin-right: -10px !important;
        letter-spacing: -0.01em;
        max-width: 100%;
        font-weight: 300;
        color: #ffffff;
        position: relative;
        z-index: 10;
}
    .love-story-quote:nth-child(2) {
        grid-column: 2;
        grid-row: 1;
        padding: 10px;
    }

    .love-story-quote:nth-child(4) {
        grid-column: 1;
        grid-row: 2;
        padding: 10px;
    }
    .wedding-card {
    position: relative;
    width: 80%;
    height: 460px;
    max-width: 400px;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 0 25px rgba(0,0,0,0.4);
    margin-top: -30px;
}
.wedding-section {
    display: flex;
    justify-content: center;
    margin: 55px 0;
}

.wedding-card {
    position: relative;
    width: 100%;
    height: 460px;
    max-width: 100px;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 0 25px rgba(0,0,0,0.4);
    margin-top: -30px;
}

}

/* ==========================================
   WEDDING PHOTO SECTIONS
========================================== */

.wedding-section {
    display: flex;
    justify-content: center;
    margin: 55px 0;
}

.wedding-card {
    position: relative;
    width: 100%;
    height: 460px;
    max-width: 350px;
    border-radius: 18px;
    overflow: hidden;
    box-shadow: 0 0 25px rgba(0,0,0,0.4);
    margin-top: -30px;
}

.wedding-photo {
    width: 100%;
    height: 110%  !important;
    margin-top: -20px !important;
    height: auto;
    display: block;
    
}

/* Dark overlay */
.wedding-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to bottom,
        rgba(0,0,0,0.05),
        rgba(0,0,0,0.55)
    );
    pointer-events: none;
    z-index: 5;
}

/* Wedding Text */
.wedding-text {
    position: absolute;
    width: 100%;
    color: #fff;
    font-family: var(--font-body-text);
    font-size: 1em;
    padding: 20px;
    line-height: 1.4;
    z-index: 10;
}

/* position variations */
.wedding-text.center {
    bottom: 30%;
    text-align: center;
}

.wedding-text.bottom-left {
    bottom: 10%;
    left: 20px;
    text-align: left;
}

.wedding-text.top-left {
    top: 10%;
    left: 20px;
    text-align: left;
}

.wedding-text.bottom-center {
    bottom: 12%;
    text-align: center;
    width: 100%;
}

.wedding-text.top-center {
    top: 0;
    left: 0;
    right: 0;
    text-align: center;
    width: 100%;
    padding-top: 30px;
    z-index: 10;
}

.credit {
    display: block;
    margin-top: 10px;
    font-size: 0.6em;
    letter-spacing: 3px;
    opacity: 0.9;
}

/* Swipe text */
.swipe {
    position: absolute;
    right: 20px;
    bottom: 15px;
    font-size: 0.7em;
    color: #fff;
    opacity: 0.8;
}
/* ===============================
   WEDDING ALBUM SECTION
================================ */

#wedding-album {
    text-align: center;
    margin-top: 10px;
}

.album-title {
    font-size: 1.2em;
    margin-bottom: -10px;
    margin-top: -40px !important;
    font-weight: 400;
    color: var(--gold-color);
    font-family: var(--font-display); /* gold Khmer style */
    padding: 20px 0;
    opacity: 0;
    transform: translateY(18px) scale(0.98);
    transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.album-title.is-visible {
    opacity: 1;
    transform: translateY(0) scale(1);
}

#wedding-album .album-photo-big1 {
    transition: opacity 0.6s ease-out 0.3s, transform 0.6s ease-out 0.3s;
}

#wedding-album .album-photo-big1.is-visible {
    transition-delay: 0.3s;
}

.album-wrapper {
    width: 92%;
    max-width: 400px;
    margin: 0 auto;
    padding: 0 8px;
}

/* Shared Photo Style */
.album-photo {
    width: 100%;
    border-radius: 20px;
    object-fit: cover;
    box-shadow: 0 4px 25px rgba(0,0,0,0.35);
    margin-bottom: 25px;
    transition: transform 0.3s ease;
    opacity: 0;
}

.album-photo.animate {
    animation: fadeInFromLeft 0.8s ease-out forwards;
}

.album-photo:nth-child(2) {
    animation: none;
}
.album-photo:nth-child(0).animate {
    animation: fadeInFromRight 0.8s ease-out forwards;
}
.album-photo:nth-child(2).animate {
    animation: fadeInFromRight 0.8s ease-out forwards;
}

.album-photo:nth-child(3) {
    animation: none;
}

.album-photo:nth-child(3).animate {
    animation: fadeInFromLeft 0.8s ease-out 0.1s both;
}

.album-photo:nth-child(4) {
    animation: none;
}

.album-photo:nth-child(4).animate {
    animation: fadeInFromRight 0.8s ease-out 0.1s both;
}
.album-photo:nth-child(5).animate {
    animation: fadeInFromRight 0.8s ease-out forwards;
}

.album-photo:hover {
    transform: scale(1.02);
}

/* Two-photo row */
.album-row {
    display: flex;
    justify-content: center;
    gap: 22px;
    margin-bottom: 25px;
}

.album-photo.medium {
    width: 48%;
    height: 240px;
}

.album-photo.big {
    height: 220px;
    width: 100%;
}
.album-photo-big1 {
    width: 100%;
    border-radius: 20px;
    object-fit: cover;
    box-shadow: 0 4px 25px rgba(0,0,0,0.35);
    margin-bottom: 25px;
    margin-top: 30px;
    opacity: 0;
    height: 460px;
}
.album-photo-big2 {
    width: 100%;
    border-radius: 20px;
    object-fit: cover;
    box-shadow: 0 4px 25px rgba(0,0,0,0.35);
    margin-bottom: 25px;
    opacity: 0;
    height: 460px;
    width: 100%;
}


/* =====================================
   LIGHTBOX STYLE
===================================== */

.lightbox {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.88);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 99999;
    animation: fadeInLightbox 0.3s ease;
}

.lightbox.fade-out {
    animation: fadeOutLightbox 0.3s ease forwards;
}

@keyframes fadeInLightbox {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes fadeOutLightbox {
    from {
        opacity: 1;
    }
    to {
        opacity: 0;
    }
}

.lightbox-image {
    max-width: 90%;
    max-height: 90%;
    border-radius: 12px;
    box-shadow: 0 0 25px rgba(255,255,255,0.2);
    /* Start hidden, fade in */
    opacity: 0;
    transition: opacity 0.4s ease, transform 0.4s ease !important;
}

/* Hover zoom - desktop only */
@media (hover: hover) and (pointer: fine) {
    .lightbox-image {
        transition: transform 0.35s ease, opacity 0.4s ease;
    }

    .lightbox-image:hover {
        transform: scale(1.06);
        cursor: zoom-in;
    }
}
/* When shown */
.lightbox-image.show {
    opacity: 1;
}


.lightbox-close {
    position: absolute;
    top: 25px;
    right: 25px;
    font-size: 2.2em;
    color: white;
    cursor: pointer;
    font-weight: 300;
}

/* Lightbox Arrow Navigation Buttons */
.lightbox-arrow {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
    border: none;
    color: white;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    font-size: 1.5em;
    cursor: pointer;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.3s ease;
    z-index: 100;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
}

.lightbox-arrow:hover {
    background: rgba(255, 255, 255, 0.5);
    backdrop-filter: blur(12px);
    transform: translateY(-50%) scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.4);
}

.lightbox-arrow:active {
    transform: translateY(-50%) scale(0.95);
}

.lightbox-prev {
    left: 20px;
}

.lightbox-next {
    right: 20px;
}

/* Mobile responsive arrow sizing */
@media screen and (max-width: 600px) {
    .lightbox-arrow {
        width: 40px;
        height: 40px;
        font-size: 1.2em;
    }

    .lightbox-prev {
        left: 10px;
    }

    .lightbox-next {
        right: 10px;
    }
}

/* Lightbox Dots/Pagination Indicator */
.lightbox-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 100;
}

.lightbox-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.4);
    cursor: pointer;
    transition: all 0.3s ease;
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.lightbox-dot:hover {
    background: rgba(255, 255, 255, 0.6);
    transform: scale(1.15);
}

.lightbox-dot.active {
    background: rgb(255, 255, 255);
    border-color: rgba(0, 0, 0, 0.8);
    box-shadow: 0 0 8px rgba(241, 213, 119, 0.6);
}

/* Mobile responsive dots */
@media screen and (max-width: 600px) {
    .lightbox-dots {
        bottom: 15px;
        gap: 6px;
    }

    .lightbox-dot {
        width: 6px;
        height: 6px;
    }
}

/* Swipe animation */
.lightbox-image.swipe-left {
    transform: translateX(-120%);
}

.lightbox-image.swipe-right {
    transform: translateX(120%);
}

/* Morph Animation - Smooth transition between photos */
.lightbox-image.morph-out {
    animation: morphOut 0.3s ease-in forwards;
}

.lightbox-image.morph-in {
    animation: morphIn 0.3s ease-out forwards;
}

@keyframes morphOut {
    0% {
        opacity: 1;
        transform: scale(1);
    }
    100% {
        opacity: 0;
        transform: scale(0.95);
    }
}

@keyframes morphIn {
    0% {
        opacity: 0;
        transform: scale(1.05);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}
/*======================================================*/
/* --- Guestbook Section Styling (Dark/Moody Aesthetic) --- */
/*======================================================*/
.wish-section {
    /* Sets the dark background container */
    background-color: rgba(78, 78, 78, 0.205); 
    padding: 0px 35px;
    margin: 50px auto;
    width: 70%;
    max-width: 380px; 
    border-radius: 35px; 
     /* Deep shadow for a sophisticated look */
    color: #fff; /* Light text for dark background */
    height: 440px;
    text-align: center;
    position: center; 
}

.wish-container {
    text-align: center;
}

.wish-title {
    font-family: var(--font-heading);
    font-weight: 200;
    font-size: 1.2rem;
    color: #f1d577; /* Soft gold/khaki color for elegance */
    margin-bottom: 5px;
    letter-spacing: 1px;
    margin-top: -5px;
    margin-bottom: 20px;
}

.wish-subtitle {
    font-family: 'Roboto', sans-serif;
    font-weight: 300;
    font-size: 1.1rem;
    margin-bottom: 30px;
    color: #bbb; /* Off-white subtitle */
}

.wish-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
    border-radius: 12px;
    max-width: 450px;
    margin: 0 auto;
    
}

.input-group {
    text-align: left;
    
}

.input-group{
    font-family: var(--font-body-text);
    font-size: 0.75em;
    font-weight: 400;
    margin-bottom: 10px;
    color: #f1d577;
    
    

}

/* Copy Link Button Styling */
.copy-link-button {
    padding: 8px 12px;
    background: #d38d98;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-size: 0.9em;
    font-weight: 600;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.copy-link-button:hover {
    background: #c07683;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3);
}

.copy-link-button:active {
    transform: translateY(0);
}

.wish-form input[type="text"],
.wish-form textarea {
    width: 100%;
    padding: 15px;
    margin-left: -11px;
    /* Dark, semi-transparent input fields, mimicking the countdown box style */
    background-color: rgba(158, 158, 158, 0.151); 
    border-radius: 15px;
    font-family: var(--font-body-text);
    font-size: 1rem;
    outline: none !important;
    box-shadow: none !important;
    border: none !important;
    color: #ebe4ac;
    cursor: n;

}

/* Style the placeholder text (for "សរសេរសារ") */
.wish-form input::placeholder,
.wish-form textarea::placeholder {
    color: rgba(255, 255, 255, 0.5); 
    font-style: italic;
    
}

.wish-form textarea {
    min-height: 150px;
    resize: none;
    color:#fff
    
}
/* Styling for the Personalized Name on Page 1 and Page 2 */
.personalized-name-locked {
    font-family: var(--font-heading);
    font-weight: 200;
    display: inline-block;
    padding: 10px 20px;
    color: #f1d577 !important;   /* Force gold color */
    font-weight: bold;
    text-transform: capitalize;
    letter-spacing: 1px;
}

/* Ensure the Page 1 Guest Name looks big and clear */
#guest-name-page-1 {
    font-size: 1.5em;
    margin: 15px 0;
}
.wish-form input:focus,
.wish-form textarea:focus {
    /* Disables the default browser outline */
    outline: none !important; 
    /* Ensures no border is added */
    border: none !important; 
    /* Ensures no glow effect is added */
    box-shadow: none !important; 
    
}
/* ###################################################### */
/* NEW: Wish Message and Name Link section */
/* ###################################################### */

/* Container for all wishes */
#wishesList {
    /* REMOVED: max-height and overflow-y */
    display: flex;
    flex-direction: column;
    align-items: center;
    width: 100%;
    margin-left: -15px;
}
.wishes-display {
    text-align: center;
    margin-top: 30px;
    width: 100%;
    background-color: rgba(78, 78, 78, 0.205);
    padding: 40px 35px;
    border-radius: 35px;
    display: flex;
    flex-direction: column;
    align-items: center;
}
/* Individual Wish Card */
.wish-card {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease, transform 0.8s ease;
    background: none;
    border: 1.5px solid rgba(241, 213, 119, 0.5);
    border-radius: 28px;
    padding: 15px 25px;
    margin-bottom: 25px;
    width: 95%;
    max-width: 800px;
    text-align: left;
    margin-left: 0;
    margin-right: auto;
    box-shadow: none;
    backdrop-filter: none;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

/* When the 'show' class is added via JavaScript */
.wish-card.show {
    opacity: 1;
    transform: scale(1);
}
.wish-card:nth-child(odd) { transition-delay: 0.1s; }
.wish-card:nth-child(even) { transition-delay: 0.2s; }
/* Guest Name Header */
.wish-guest-name {
    font-family: var(--font-body-text);
    color: #f1d577;
    font-size: 1.5em;
    font-weight: 200;
    letter-spacing: 1px;
    margin-bottom: 12px;
    padding-bottom: 12px;
    display: block;
    text-align: left;
    border-bottom: 1px solid rgba(255, 215, 85, 0.6);
}

/* The Message in the Middle */
.wish-text-content {
    font-family: 'BodyKhmer', sans-serif;
    color: #ffffff;
    font-size: 1.4em;
    line-height: 1.8;
    font-style: normal;
    margin: 0;
    padding: 0;
    position: relative;
    word-wrap: break-word;
    white-space: normal;
}
    

/* Decorative quotes around the message */
.wish-text-content::before { content: "“"; color: #f1d577; font-size: 1.5em; margin-right: 5px; }
.wish-text-content::after { content: "”"; color: #f1d577; font-size: 1.5em; margin-left: 5px; }

/* Date Footer */
.wish-date-time {
    font-size: 0.9em;
    color: rgba(255, 255, 255, 0.7);
    margin-top: 0;
    display: block;
    font-weight: 300;
    text-align: left;
}

.wish-form input#guestName.personalized-name-locked {
    background-color: rgba(255, 255, 255, 0.1); /* Slightly lighter background */
    font-style: italic;
    color: #f0e68c; /* Display name in gold color */
}

/* Remove decorative quotes */
.wish-text-content::before,
.wish-text-content::after {
    content: "" !important;
    display: none !important;
}

.golden-button {
    background: transparent;
    color: #f1d577;
    border: 2px solid #f1d577;
    border-radius: 25px;
    padding: 5px 25px;
    font-family: var(--font-body-text);
    cursor: pointer;
    margin: 30px auto;
    display: none; /* Hidden by default, JS will show it */
    transition: all 0.3s ease;
}

/* --- BUTTON CONTAINER STYLING (The Image Itself) --- */
.submit-button.image-button {
    width: 170px; 
    height: 10px;
    margin-top: -20px;
    background-image: url('images/Button-Page2.png'); 
    background-size: contain; 
    background-repeat: no-repeat;
    background-position: center;
    background-color: transparent !important; 
    border: none;
    cursor: pointer;
    display: flex; 
    justify-content: center; 
    align-items: center; 
    overflow: hidden; 
    font-family: var(--font-body-text);
    margin-top: -10px !important;
    font-size: 0.5rem;
    text-shadow: #181717;
    color: #f1d577;
}

/* --- TEXT LABEL STYLING (The Best Way to Hide Text for Accessibility) --- */
.submit-button .button-label {
    /* 💥 CRITICAL FIX: Use the Visually Hidden Technique 💥 */
    position: absolute; font-size: 0.7rem;
    margin-bottom: -3px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.7);
    /* Remove unnecessary styles that conflict with hiding */
    
}
.submit-button.image-button:hover {
    transform: scale(1.02);
}

.submit-button {
    cursor: pointer;
    transition: transform 0.1s;
}
/* Style for the confirmation message */
.status-message {
    font-family: var(--font-body-text);
    font-size: 0.8rem;
    margin-top: 20px;
    font-style: italic;
    color: #f1d577; /* Ensure success message is gold/white */
}

/* Ensure the fade-in-item styles are still present in your file: */
.fade-in-item {
    opacity: 0;
    transform: translateY(30px);
    transition: opacity 0.8s ease-out, transform 0.8s ease-out;
}
.fade-in-item.is-visible {
    opacity: 1;
    transform: translateY(0);
}
.fade-in-item.appear {
    opacity: 1 !important;
    transform: translateY(0) !important;
    visibility: visible !important;
}
.fade-in-item.show {
    opacity: 1;
    transform: translateY(0);
}

/* Mobile Responsive - Wish Section (450px and below) */
@media screen and (max-width: 1920px) {
    .wish-section {
        width: 90%;
        max-width: 400px;
        margin: 20px auto;
        padding: 25px 10px;
        border-radius: 17px;
        height: 470px;
        text-align: center;
    }

    .wish-container {
        text-align: center;
        width: 100%;
    }

    .wish-title {
        font-size: 1.1em;
        margin-bottom: 15px;
    }

    .wish-form {
        display: flex;
        flex-direction: column;
        gap: 12px;
        width: 100%;
        align-items: center;
    }

    .input-group {
        width: 100%;
        margin-bottom: 8px;
        margin-left: 10px;
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .input-group label {
        width: 100%;
        text-align: left;
        margin-bottom: 5px;
        font-size: 0.9em;
    }

    .input-group > div {
        width: 100%;
        max-width: 350px;
        display: flex;
        gap: 8px;
        align-items: center;
    }

    .copy-link-button {
        padding: 6px 10px;
        font-size: 0.85em;
        flex-shrink: 0;
    }

    .wish-form input[type="text"],
    .wish-form textarea {
        width: 100%;
        max-width: 350px;
        font-size: 1.4em;
        padding: 10px 12px;
        box-sizing: border-box;
    }

    .submit-button.image-button {
        width: 190px;
        height: 60px;
       
        display: flex;
        margin-top: 25px;
        justify-content: center;
        align-items: center;
    }

    .wishes-display {
        width: 90%;
        max-width: 420px;
        margin: 20px auto;
        padding: 20px 15px;
        border-radius: 25px;
        text-align: center;
    }

    .wishes-subtitle {
        font-family: var(--font-heading);
        font-weight: 200;
        font-size: 1.4em;
        margin-bottom: 15px;
         color: #f1d577;
    }

    .wish-card {
        width: 100%;
        max-width: 342px;
        margin-left: 10px !important;
        padding: 12px 15px;
        border-radius: 20px;
        margin: 0 auto 15px;
        gap: 6px;
    }

    .wish-guest-name { 
        font-size: 0.95em;
        margin-bottom: 8px;
        padding-bottom: 8px;
    }

    .wish-text-content {
        font-size: 0.85em;
        line-height: 1.6;
    }

    .wish-date-time {
        font-size: 0.7em;
    }

    #wishesList {
        width: 100%;
        align-items: center;
    }
}

/* ###################################################### */
/* NEW: MUSIC TOGGLE BUTTON STYLES (Page 2) */
/* ###################################################### */
#language-toggle-button {
    position: fixed;
    bottom: 100px;
    right: 40px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid var(--gold-color);
    background-color: #ffffff;
    color: var(--gold-color);
    font-family: var(--font-button);
    font-size: 0.9em;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 55;
    transition: background-color 0.2s, transform 0.1s;
}

#music-toggle-button {
    /* Position the button fixed relative to the viewport so it stays in place */
    position: fixed;
    /* Adjust these values to position it (e.g., top right corner) */
    bottom: 40px;
    right: 40px; 
    
    /* Styling */
    width: 50px;
    height: 50px;
    border-radius: 50%; /* Make it circular */
    border: 2px solid var(--gold-color); /* Use gold border from other elements [cite: 893] */
    background-color: #ffffff; /* White background */
    color: var(--gold-color); /* Gold icon color */
    
    display: flex;
    justify-content: center;
    align-items: center;
 font-size: 1.2em;
    cursor: pointer;
    z-index: 50; /* Ensure it's above all content, but below the entrance page  */
    
    /* Animation and transition for hover/press feedback */
    transition: background-color 0.2s, transform 0.1s;
}

/* Optional: Hide on the entrance page if needed (assuming page 1 is #entrance-page) */
#entrance-page #music-toggle-button {
    display: none;
}

#entrance-page #language-toggle-button {
    display: none;
}

/* PAGE 1 MUSIC TOGGLE BUTTON */
#page1-music-toggle-button {
    /* Position the button fixed relative to the viewport so it stays in place */
    position: fixed;
    /* Adjust these values to position it (e.g., bottom right corner) */
    bottom: 40px;
    right: 40px; 
    
    /* Styling */
    width: 50px;
    height: 50px;
    border-radius: 50%; /* Make it circular */
    border: 2px solid var(--gold-color); /* Use gold border from other elements */
    background-color: #ffffff; /* White background */
    color: var(--gold-color); /* Gold icon color */
    
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2em;
    cursor: pointer;
    z-index: 50; /* Ensure it's above all content */
    
    /* Animation and transition for hover/press feedback */
    transition: background-color 0.2s, transform 0.1s, opacity 0.8s ease;
    opacity: 1;
}

/* Fade-out animation for page 1 music button */
#page1-music-toggle-button.fade-out {
    opacity: 0;
    pointer-events: none;
}

/* Responsive for mobile (450px and below) */
@media screen and (max-width: 450px) {
    #page1-music-toggle-button {
        bottom: 30px;
        right: 30px;
        width: 45px;
        height: 45px;
        font-size: 1em;
        border: 1.5px solid var(--gold-color);
    }
}

/* ===== NAVIGATION MENU BUTTON AND STYLING ===== */
#menu-toggle-button {
    position: fixed;
    top: 40px;
    right: 40px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid var(--gold-color);
    background-color: #ffffff;
    color: var(--gold-color);
    font-size: 1.2em;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    z-index: 100;
    transition: background-color 0.2s, transform 0.1s;
    padding: 0;
}

#menu-toggle-button i {
    transition: opacity 0.3s ease;
}

#menu-toggle-button.active i {
    display: none;
}

#menu-toggle-button::after {
    content: '';
    position: absolute;
    transition: content 0.3s ease, opacity 0.3s ease;
    opacity: 0;
    font-size: 1.5em;
    font-weight: bold;
    color: var(--gold-color);
}

#menu-toggle-button.active::after {
    content: '✕';
    opacity: 1;
}

.menu-icon {
    width: 24px;
    height: 24px;
    object-fit: contain;
    filter: brightness(0) saturate(50%) invert(73%) sepia(81%) saturate(200%) hue-rotate(3deg) brightness(102%) contrast(102%);
}

#menu-toggle-button.active {
    background-color: rgba(212, 175, 55, 0.2);
}

/* Navigation Menu Styles */
.navigation-menu {
    position: fixed;
    top: 100px;
    right: 40px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.navigation-menu.active {
    opacity: 1;
    visibility: visible;
}

.menu-item {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    border: 2px solid var(--gold-color);
    background-color: rgba(0, 0, 0, 0.4);
    color: var(--gold-color);
    font-size: 1.2em;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    text-decoration: none;
    transition: background-color 0.2s, transform 0.1s;
    animation: slideIn 0.3s ease forwards;
}

.menu-item:nth-child(1) { animation-delay: 0.05s; }
.menu-item:nth-child(2) { animation-delay: 0.1s; }
.menu-item:nth-child(3) { animation-delay: 0.15s; }
.menu-item:nth-child(4) { animation-delay: 0.2s; }
.menu-item:nth-child(5) { animation-delay: 0.25s; }
.menu-item:nth-child(6) { animation-delay: 0.3s; }

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.menu-item:hover {
    background-color: rgba(212, 175, 55, 0.3);
    transform: scale(1.1);
}

.menu-item:active {
    background-color: rgba(212, 175, 55, 0.5);
}

#entrance-page #menu-toggle-button {
    display: none;
}

#entrance-page .navigation-menu {
    display: none;
}

/* ===== APPRECIATION SECTION ===== */
.appreciation-section {
    padding: 60px 20px;
    background: rgba(0, 0, 0, 0.3);
    backdrop-filter: blur(5px);
}

.appreciation-container {
    max-width: 800px;
    margin: 0 auto;
    margin-left: -10px;
}

/* For large screens (1920px) */
@media screen and (min-width: 1920px) {
    .appreciation-container {
        max-width: 450px;
    }
}

.appreciation-box {
    background-color: rgba(0, 0, 0, 0.3);
    bottom: -30px;
    border-radius: 40px;
    padding: 30px 25px;
    height: 440px;
    min-height: auto;
    text-align: center;
    position: relative;
    overflow: hidden;
    
}

.appreciation-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url('images/apprec.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    filter: blur(3px);
    z-index: 0;
}

.appreciation-box > * {
    position: relative;
    z-index: 1;
}

.appreciation-title {
    font-family: 'DisplayKhmer', sans-serif;
    font-size: 0.9em;
    color: #f1d577;
    margin-bottom: 10px;
    font-weight: 600;
}

.appreciation-icon {
    margin: 20px 0 30px 0;
}

.flower-icon {
    width: 70px;
    height: 70px;
    object-fit: contain;
    margin-top: -20px;
    opacity: 0.8;
}

.appreciation-text {
    font-family: var(--font-body-text);
    font-size: 0.85em;
    line-height: 1.5em;
    color: #ffffff;
    margin-top: -30px;
    font-weight: 300;
}



/* Responsive adjustments */
@media screen and (max-width: 450px) {
    .appreciation-section {
        padding: 40px 15px;
    }

    .appreciation-box {
        padding: 35px 25px;
        bottom: 0px;
    }

    .appreciation-title {
        font-size: 1em;
        margin-bottom: 20px;
    }

    .appreciation-text {
        font-size: 0.95em;
        line-height: 1.7;
    }
}

/* Mobile refinement for appreciation box (450px and below) */
@media screen and (max-width: 450px) {
    .appreciation-section {
        padding: 30px 10px 50px 10px;
    }

    .appreciation-box {
        padding: 25px 15px;
        border-radius: 25px;
        width: 95%;
        max-width: 370px;
        margin: 0 auto;
    }

    .appreciation-title {
        font-size: 0.9em;
        margin-bottom: 17px;
        color: #f1d577;
        margin-top: 1px;
        
    }

    .appreciation-text {
        font-size: 0.85em;
        line-height: 1.5em;
        margin-top: -45px;
        margin-bottom: 30px;
    }

    .flower-icon {
        width: 80px;
        height: 90px;
        margin: -15px 0 15px 0;
        
    }
}

/* ========== FOOTER SECTION ========== */
.footer-section {
    width: 100%;
    padding: 40px 20px;
    text-align: center;
    margin-left: -40px;
}

.footer-text {
    font-family: 'EnglishStandard', sans-serif;
    font-size: 1em;
    color: #e6c96b;
    letter-spacing: 1px;
}

.heart-icon {
    display: inline-block;
    animation: heartbeat 1.5s ease-in-out infinite;
}

@keyframes heartbeat {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.2);
    }
}

.social-icons {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin: 20px 0;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background-color: rgba(230, 201, 107, 0.2);
    border: 2px solid #e6c96b;
    border-radius: 50%;
    color: #e6c96b;
    font-size: 1.3em;
    transition: all 0.3s ease;
    text-decoration: none;
}

.social-link:hover {
    background-color: #e6c96b;
    color: #1a1a1a;
    transform: scale(1.1);
}

.footer-copyright {
    font-family: 'EnglishStandard', sans-serif;
    font-size: 0.85em;
    color: #b8a87f;
    margin: 15px 0 0 0;
    letter-spacing: 0.5px;
}

/* ========== FOOTER RESPONSIVE DESIGN ========== */
/* Desktop (1920px and above) */
@media screen and (min-width: 1200px) {
    .footer-section {
        padding: 50px 40px;
        margin-top: 80px;
        
    }

    .footer-text {
        font-size: 1.3em;
        margin-left: -90px;
        margin: 0 0 20px 0;
    }

    .social-icons {
        gap: 30px;
        margin: 30px 0;
    }

    .social-link {
        width: 55px;
        height: 55px;
        font-size: 1.5em;
    }

    .footer-copyright {
        font-size: 0.95em;
        margin-top: 20px;
    }
}

/* Tablet (768px - 1199px) */
@media screen and (min-width: 768px) and (max-width: 1199px) {
    .footer-section {
        padding: 40px 30px;
        margin-top: 0px;
    }

    .footer-text {
        font-size: 1.15em;
        margin: 0 0 18px 0;
    }

    .social-icons {
        gap: 25px;
        margin: 25px 0;
    }

    .social-link {
        width: 50px;
        height: 50px;
        font-size: 1.4em;
    }

    .footer-copyright {
        font-size: 0.9em;
        margin-top: 18px;
    }
}

/* Mobile (450px and below) */
@media screen and (max-width: 450px) {
    .footer-section {
        padding: 30px 15px;
        margin-top: 0px;
        margin-left: 0px;

    }

    .footer-text {
        font-size: 0.95em;
        margin: 0 0 12px 0;
        letter-spacing: 0.5px;
    }

    .heart-icon {
        font-size: 1.1em;
    }

    .social-icons {
        gap: 15px;
        margin: 15px 0;
    }

    .social-link {
        width: 40px;
        height: 40px;
        font-size: 1.1em;
        border-width: 1.5px;
    }

    .social-link:hover {
        transform: scale(1.15);
    }

    .footer-copyright {
        font-size: 0.75em;
        margin-top: 12px;
        line-height: 1.4;
    }
}

/* ========== BLANK VIEWPOINT AT BOTTOM OF PAGE 2 ========== */
.blank-viewpoint {
    width: 100%;
    height: 5vh;
    background-color: transparent;
}

/* ========== LOGO DIVIDER SECTION (Between Agenda and Countdown) ========== */
#logo-divider-section {
    padding: 30px 20px;
    background-color: transparent;
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
}

.logo-divider-container {
    width: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 20px;
    margin-top: -35px;
    margin-bottom: -35px;
}

.logo-divider-box {
    display: flex;
    justify-content: center;
    align-items: center;
}

.divider-logo-image {
    width: 270px;
    height: 90px;
    object-fit: contain;
    opacity: 0.85;
    margin-top: -150px;
    transition: opacity 0.6s ease-in-out, transform 0.6s ease-in-out;
    will-change: opacity, transform;
    display: block;
    margin-left: auto;
    margin-right: auto;
}

/* Responsive Logo Divider for smaller screens */
@media screen and (max-width: 768px) {
    #logo-divider-section {
        padding: 20px 10px;
        margin-top: -20px;
    }

    .divider-logo-image {
        width: 270px;
        height: 90px;
        transition: opacity 0.6s ease-in-out, transform 0.6s ease-in-out;
        will-change: opacity, transform;
    }
}

@media screen and (max-width: 480px) {
    #logo-divider-section {
        padding: 20px 10px;
        margin-top: -20px;
        
    }

    .divider-logo-image {
        width: 270px;
        height: 90px;
        transition: opacity 0.6s ease-in-out, transform 0.6s ease-in-out;
        will-change: opacity, transform;
    }
}

/* ========== LOGO DIVIDER SECTION (Above Agenda Title) ========== */
.logo-divider-box-top {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.divider-logo-image-top {
    width: 80px;
    height: 80px;
    object-fit: contain;
    opacity: 0.85;
}

/* Responsive Logo Divider Top for smaller screens */
@media screen and (max-width: 768px) {
    .logo-divider-box-top {
        margin-bottom: 15px;
    }

    .divider-logo-image-top {
        width: 70px;
        height: 70px;
    }
}

@media screen and (max-width: 480px) {
    .logo-divider-box-top {
        margin-bottom: 10px;
    }

    .divider-logo-image-top {
        width: 60px;
        height: 60px;
    }
}

/* ========== LOGO DIVIDER SECTION (Above Agenda Title) ========== */
.logo-divider-box-top {
    display: flex;
    justify-content: center;
    align-items: center;
    margin-bottom: 20px;
}

.divider-logo-image-top {
    width: 80px;
    height: 80px;
    object-fit: contain;
    opacity: 0.85;
}

/* Responsive Logo Divider Top for smaller screens */
@media screen and (max-width: 768px) {
    .logo-divider-box-top {
        margin-bottom: 15px;
    }

    .divider-logo-image-top {
        width: 70px;
        height: 70px;
    }
}

@media screen and (max-width: 480px) {
    .logo-divider-box-top {
        margin-bottom: 10px;
    }

    .divider-logo-image-top {
        width: 60px;
        height: 60px;
    }
}

/* ========== DIVIDER LOGO ANIMATIONS ========== */
@keyframes dividerFadeIn {
    from {
        opacity: 0;
        transform: scale(0.95);
    }
    to {
        opacity: 0.85;
        transform: scale(1);
    }
}

.divider-logo-image.is-visible {
    animation: dividerFadeIn 0.8s ease-out forwards;
}

/* ========== ENTRANCE CLASS WITH RESPONSIVE OVERRIDES ========== */
.entrance {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    opacity: 0;
    animation: entranceFadeIn 2s ease-out 0.2s forwards;
}



