:root {
    /* Cream, Black & Crimson Theme */
    --c-ivory: #fdf6dc;
    --c-champagne: #d22329;
    /* Red Accents */
    --c-gold-gradient: #d22329;
    /* Replaced gradient with solid red */
    --c-warm-white: #fdf6dc;
    --c-olive: #090909;
    /* Black for contrasting shapes */
    --c-beige: #090909;
    /* Black for secondary shapes */
    --c-rose: #d22329;
    --c-black: #090909;
    --c-gold-light: #d22329;

    /* Typography */
    --f-serif: 'Gveret Levin', serif;
    --f-display: 'Updock', cursive;
    --f-elegant: 'Updock', serif;
    --f-sans: 'Gveret Levin', sans-serif;
    --f-sans-alt: 'Gveret Levin', sans-serif;
    --f-script: 'Updock', cursive;
}



.pulsing-heart {
    font-size: 5rem;
    color: var(--c-rose);
    animation: heartPulse 0.8s infinite alternate ease-in-out;
}

@keyframes heartPulse {
    0% {
        transform: scale(1);
    }

    100% {
        transform: scale(1.3);
    }
}

/* Lenis Smooth Scroll Recommended Styles */
html.lenis,
html.lenis body {
    height: auto;
}

.lenis.lenis-smooth {
    scroll-behavior: auto !important;
}

.lenis.lenis-smooth [data-lenis-prevent] {
    overscroll-behavior: contain;
}

.lenis.lenis-stopped {
    overflow: hidden;
}

.lenis.lenis-scrolling iframe {
    pointer-events: none;
}

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

html {
    overflow-x: hidden;
    width: 100%;
}

body {
    background-color: var(--c-ivory);
    color: var(--c-black);
    font-family: var(--f-sans);
    overflow-x: hidden;
    width: 100%;
    -webkit-font-smoothing: antialiased;
    position: relative;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--c-ivory);
}

::-webkit-scrollbar-thumb {
    background: var(--c-champagne);
    border-radius: 4px;
}

/* Reusables */
.glassmorphism {
    background: rgba(255, 255, 255, 0.4);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.5);
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.05);
    border-radius: 16px;
}

.section-title {
    font-family: var(--f-elegant);
    font-size: 5rem;
    text-align: center;
    color: var(--c-black);
    margin-bottom: 2rem;
    font-weight: 500;
}

@media screen and (max-width: 768px) {
    .section-title {
        font-size: 2.5rem;
    }
}

.elegant-divider {
    width: 60px;
    height: 2px;
    background: var(--c-champagne);
    margin: 0 auto 3rem auto;
}

/* Envelope Intro Loader */
.loader {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    background-color: var(--c-ivory);
    z-index: 9999;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 50px;
    perspective: 1000px;
    overflow: hidden;
}

.loader-intro-text {
    text-align: center;
    font-family: var(--f-serif);
    font-size: 1.5rem;
    color: var(--c-black);
    z-index: 10;
    opacity: 0.9;
    line-height: 1.8;
}

/* Background Hearts */
/* Floating Controls */
.floating-controls {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 100;
    display: flex;
    gap: 15px;
    align-items: center;
}

.calendar-btn,
.music-toggle {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(10px);
    padding: 12px 20px;
    border-radius: 30px;
    cursor: pointer;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    text-decoration: none;
    color: var(--c-black);
}

.calendar-btn:hover,
.music-toggle:hover {
    transform: translateY(-3px);
    background: #fff;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
}

.music-text {
    font-family: var(--f-sans);
    font-size: 0.85rem;
    color: var(--c-olive);
    text-transform: uppercase;
    letter-spacing: 1.5px;
    font-weight: 500;
}

.bars {
    display: flex;
    gap: 3px;
    height: 15px;
    align-items: flex-end;
}

.bar {
    width: 3px;
    height: 3px;
    background: var(--c-champagne);
    border-radius: 3px;
    transition: height 0.2s ease;
}

/* Playing state animations */
.music-toggle.playing .bar:nth-child(1) {
    animation: bounce 1s infinite alternate;
}

.music-toggle.playing .bar:nth-child(2) {
    animation: bounce 1.2s infinite alternate 0.2s;
}

.music-toggle.playing .bar:nth-child(3) {
    animation: bounce 0.8s infinite alternate 0.4s;
}

@keyframes bounce {
    from {
        height: 3px;
    }

    to {
        height: 15px;
    }
}

.loader-hearts {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

.heart-shape {
    position: absolute;
    bottom: -10%;
    color: var(--c-rose);
    font-size: 2.5rem;
    opacity: 0.5;
    animation: floatHearts 6s infinite ease-in;
}

@keyframes floatHearts {
    0% {
        transform: translateY(0) scale(0.8) rotate(0deg);
        opacity: 0;
    }

    20% {
        opacity: 0.6;
    }

    80% {
        opacity: 0.4;
    }

    100% {
        transform: translateY(-120vh) scale(1.2) rotate(45deg);
        opacity: 0;
    }
}

.envelope-wrapper {
    position: relative;
    width: 350px;
    height: 220px;
    z-index: 10;
    animation: floatEnvelope 4s infinite ease-in-out;
}

@keyframes floatEnvelope {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-15px);
    }
}

.envelope {
    position: relative;
    width: 100%;
    height: 100%;
    background: var(--c-beige);
    border-radius: 12px;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.15);
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
}

/* Side flaps removed because we're using a curved overlapping design now */
.envelope::before,
.envelope::after {
    display: none;
}

/* Bottom flap (Curved) */
.envelope-body {
    position: absolute;
    bottom: 0;
    left: -10%;
    width: 120%;
    height: 70%;
    background: var(--c-olive);
    /* Royal Blue */
    border-radius: 50% 50% 0 0;
    z-index: 3;
    box-shadow: 0 -5px 15px rgba(0, 0, 0, 0.2);
}

/* Top flap (Curved) */
.envelope-flap {
    position: absolute;
    top: 0;
    left: -10%;
    width: 120%;
    height: 60%;
    background: #ccba78;
    /* Gold gradient flap */
    border-radius: 0 0 50% 50%;
    z-index: 4;
    transform-origin: top;
    transition: transform 0.8s ease-in-out, z-index 0s 0.3s;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

/* Wax Seal (3D Embossed) */
.wax-seal {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -10%);
    width: 70px;
    height: 70px;
    background: radial-gradient(circle at 30% 30%, #d22329, #8f171b);
    border-radius: 50%;
    border: none;
    z-index: 5;
    cursor: pointer;
    box-shadow:
        inset 0 0 10px rgba(0, 0, 0, 0.8),
        inset 2px 2px 5px rgba(255, 255, 255, 0.2),
        0 5px 15px rgba(0, 0, 0, 0.6);
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 0.3s ease;
}

.wax-seal::before {
    content: '';
    position: absolute;
    width: 55px;
    height: 55px;
    border: 2px solid #8f171b;
    border-radius: 50%;
    box-shadow: inset 1px 1px 3px rgba(0, 0, 0, 0.7), 1px 1px 2px rgba(255, 255, 255, 0.1);
}

.seal-text {
    font-family: var(--f-display);
    color: #fdf6dc;
    font-size: 1.3rem;
    text-shadow: 1px 1px 1px rgba(255, 255, 255, 0.3), -1px -1px 2px rgba(0, 0, 0, 0.8);
    z-index: 2;
    letter-spacing: 0;
}

.wax-seal:hover {
    box-shadow:
        inset 0 0 10px rgba(0, 0, 0, 0.8),
        inset 2px 2px 5px rgba(255, 255, 255, 0.3),
        0 8px 20px rgba(0, 0, 0, 0.7);
    filter: brightness(1.1);
}

.wax-seal.opened {
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.envelope-flap.opened {
    transform: rotateX(180deg);
    z-index: 1;
    box-shadow: 0 -5px 15px rgba(0, 0, 0, 0.2);
}

.envelope-instructions {
    position: absolute;
    bottom: -40px;
    left: 0;
    width: 100%;
    text-align: center;
    font-family: var(--f-sans-alt);
    font-size: 0.9rem;
    color: var(--c-champagne);
    text-transform: uppercase;
    letter-spacing: 2px;
    opacity: 0;
    animation: pulseText 2s infinite ease-in-out;
}

@keyframes pulseText {

    0%,
    100% {
        opacity: 0.6;
    }

    50% {
        opacity: 1;
    }
}


.music-toggle {
    display: flex;
    align-items: center;
    gap: 10px;
}

.bars {
    display: flex;
    gap: 3px;
    height: 15px;
    align-items: flex-end;
}

.bar {
    width: 3px;
    background-color: var(--c-champagne);
    border-radius: 2px;
    transition: height 0.2s;
}

.music-text {
    font-family: var(--f-sans-alt);
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.playing .bar {
    animation: sound 1.5s infinite ease-in-out alternate;
}

.playing .bar:nth-child(1) {
    animation-delay: -0.2s;
    height: 10px;
}

.playing .bar:nth-child(2) {
    animation-delay: -0.4s;
    height: 15px;
}

.playing .bar:nth-child(3) {
    animation-delay: -0.6s;
    height: 8px;
}

@keyframes sound {
    0% {
        height: 4px;
    }

    100% {
        height: 15px;
    }
}

.hero {
    position: relative;
    height: 100vh;
    width: 100%;
    overflow: visible;
    /* Changed to visible to allow hearts to overflow */
    display: flex;
    justify-content: center;
    align-items: center;
}

.petals-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 5;
}

.scroll-heart {
    position: absolute;
    pointer-events: none;
    will-change: transform;
}

.hero-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.1);
    /* for parallax */
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(253, 246, 220, 0.4), var(--c-ivory));
}

.hero-content {
    text-align: center;
    color: var(--c-black);
    z-index: 4;
}

.hero-img-left,
.hero-img-right {
    position: absolute;
    bottom: 0;
    width: 35vw;
    max-width: 400px;
    height: auto;
    max-height: 90vh;
    z-index: 3;
}

.hero-img-wrapper img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
    max-height: 90vh;
}

.hero-img-left {
    left: 0;
}

.hero-img-right {
    right: 0;
}

/* Speech Bubbles */
.speech-bubbles-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
}

.bride-bubble,
.groom-bubble {
    position: absolute;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(210, 35, 41, 0.3);
    /* subtle red border */
    border-radius: 30px;
    /* Fully rounded bubbles */
    padding: 15px 20px;
    font-family: var(--f-sans);
    font-size: 0.80rem;
    color: var(--c-black);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    width: 300px;
    line-height: 1.5;
    opacity: 0;
    /* for animation */
    transform: translateY(15px) scale(0.9);
    pointer-events: auto;
    /* Allow hovering */
}

/* Pause ALL animations in the sequence if ANY bubble is hovered */
#hero:has(.bride-bubble:hover) .bride-bubble,
#hero:has(.bride-bubble:hover) .groom-bubble,
#hero:has(.groom-bubble:hover) .bride-bubble,
#hero:has(.groom-bubble:hover) .groom-bubble {
    animation-play-state: paused !important;
}

.bride-bubble:hover,
.groom-bubble:hover {
    cursor: default;
    /* Show it's interactive */
}



.bride-bubble::after,
.groom-bubble::after {
    content: '';
    position: absolute;
    border-style: solid;
}

/* Bride on right, bubble points to right (towards bride's face) */
.bride-bubble {
    right: 75%;
    /* Relative to the 35vw wrapper width */
    top: 15%;
}

.bride-bubble::after {
    top: 50%;
    right: -15px;
    margin-top: -10px;
    border-width: 10px 0 10px 15px;
    border-color: transparent transparent transparent rgba(255, 255, 255, 0.9);
}

/* Groom on left, bubble points to left (towards groom's face) */
.groom-bubble {
    left: 75%;
    /* Relative to the 35vw wrapper width */
    top: 15%;
    font-size: 2.5rem;
    font-weight: bold;
    padding: 10px 25px;
    max-width: fit-content;
}

.groom-bubble::after {
    top: 50%;
    left: -15px;
    margin-top: -10px;
    border-width: 10px 15px 10px 0;
    border-color: transparent rgba(255, 255, 255, 0.9) transparent transparent;
}

/* Base animation setup */
.speech-bubbles-container.start-animation .bride-bubble,
.speech-bubbles-container.start-animation .groom-bubble {
    animation: bubbleSequence 20s infinite;
}

/* Replace each other sequentially (20s loop, 4s per bubble) */
.bubble-1 {
    animation-delay: 0s !important;
}

.bubble-2 {
    animation-delay: 4s !important;
}

.bubble-3 {
    animation-delay: 8s !important;
}

.bubble-4 {
    animation-delay: 12s !important;
}

.groom-bubble {
    animation-delay: 16s !important;
}

@keyframes bubbleSequence {
    0% {
        opacity: 0;
        transform: translateY(15px) scale(0.9);
    }

    2.5% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }

    /* 0.5s fade in */
    17.5% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }

    /* stay visible till 3.5s */
    20% {
        opacity: 0;
        transform: translateY(-15px) scale(0.9);
    }

    /* 0.5s fade out */
    100% {
        opacity: 0;
        transform: translateY(-15px) scale(0.9);
    }

    /* hidden until next loop */
}

@media screen and (max-width: 768px) {

    .bride-bubble,
    .groom-bubble {
        max-width: 180px;
        font-size: 0.7rem;
        padding: 8px 12px;
    }

    .bride-bubble {
        right: 80%;
        top: 10%;
    }

    .groom-bubble {
        left: 80%;
        top: 10%;
        font-size: 1.2rem;
        padding: 4px 10px;
        width: auto;
        min-width: 0;
    }
}

.hero-text-wrap {
    padding: 40px;
}

.hero-subtitle {
    font-family: var(--f-sans);
    font-size: 1.2rem;
    text-transform: uppercase;
    letter-spacing: 6px;
    margin-bottom: 10px;
    opacity: 0.9;
}

.hero-title {
    font-family: var(--f-display);
    font-size: 6rem;
    line-height: 1.1;
    margin: 20px 0;
}

.hero-date {
    font-size: 1.5rem;
    font-style: italic;
    letter-spacing: 2px;
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    left: 50%;
    transform: translateX(-50%);
    text-align: center;
    color: white;
    z-index: 2;
}

.mouse {
    width: 24px;
    height: 36px;
    border: 2px solid white;
    border-radius: 12px;
    margin: 0 auto 10px;
    position: relative;
}

.wheel {
    width: 4px;
    height: 8px;
    background: white;
    border-radius: 2px;
    position: absolute;
    top: 6px;
    left: 50%;
    transform: translateX(-50%);
    animation: scrollWheel 2s infinite;
}

@keyframes scrollWheel {
    0% {
        top: 6px;
        opacity: 1;
    }

    100% {
        top: 20px;
        opacity: 0;
    }
}

/* Global Balloon Hearts */
.balloon-heart {
    position: fixed;
    bottom: -150px;
    font-size: 8rem;
    /* Big love shapes */
    color: rgba(210, 35, 41, 0.4);
    /* Translucent red */
    z-index: 100;
    pointer-events: none;
    animation: floatUp 20s linear infinite;
    filter: drop-shadow(0 10px 15px rgba(0, 0, 0, 0.2));
}

.balloon-1 {
    left: 5%;
    animation-duration: 25s;
}

.balloon-2 {
    right: 5%;
    animation-duration: 28s;
    animation-delay: 12s;
    color: rgba(143, 23, 27, 0.4);
    /* Translucent dark red */
}

@keyframes floatUp {
    0% {
        transform: translateY(0) rotate(-10deg);
    }

    50% {
        transform: translateY(-60vh) rotate(10deg);
    }

    100% {
        transform: translateY(-120vh) rotate(-10deg);
    }
}

/* Invitation Section */
.invitation-section {
    position: relative;
    background-color: var(--c-ivory);
    overflow: hidden;
    padding-top: 10vh;
    /* Small padding, removed 100vh gap */
}

.invitation-images-container {
    position: sticky;
    top: 0;
    width: 100%;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1;
}

.invite-img-left,
.invite-img-right {
    height: 90vh;
    object-fit: contain;
    position: absolute;
    bottom: 0;
    z-index: 2;
    /* Ensure images are in front of their backgrounds */
}

.invite-bg-left,
.invite-bg-right {
    position: absolute;
    bottom: 0;
    width: 25vw;
    height: 75vh;
    border-radius: 200px 200px 0 0;
    /* Beautiful arch shape */
    background: var(--c-champagne);
    opacity: 0.15;
    z-index: 1;
    /* Behind the images */
}

.invite-img-left,
.invite-bg-left {
    left: 50%;
    transform: translateX(-100%);
    /* Perfectly touch the center line */
}

.invite-bg-right {
    left: 50%;
    transform: translateX(0);
    /* Background stays perfectly touching the center line */
}

.invite-img-right {
    left: 50%;
    transform: translateX(-20%);
    /* Pull bride towards the center */
}

.invitation-letter {
    position: relative;
    /* Scrolls naturally up */
    margin: 40vh auto 100px auto;
    /* 40vh gap so images are seen first */
    width: 95%;
    max-width: 800px;
    padding: 60px 50px;
    text-align: center;
    z-index: 2;
    background: linear-gradient(rgba(253, 246, 220, 0.4), rgba(253, 246, 220, 0.4)), url('./assets/floral_texture.png') center/cover;
    background-blend-mode: multiply;
    border: 2px solid var(--c-champagne);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

.letter-quote {
    font-size: 0.9rem;
    color: #555;
    margin-bottom: 30px;
    line-height: 1.6;
}

.quote-ref {
    margin-top: 5px;
    font-weight: 600;
}

.letter-parents {
    margin: 20px 0;
}

.letter-parents h3 {
    font-family: var(--f-sans-alt);
    font-size: 1.5rem;
    color: var(--c-black);
    margin-bottom: 5px;
}

.letter-parents p {
    font-size: 1.2rem;
    color: #555;
}

.letter-invite-text {
    /* font-family: var(--f-serif); */
    font-size: 1.1rem;
    color: var(--c-olive);
    line-height: 1.8;
    margin: 30px 0;
}

.letter-names {
    font-family: var(--f-display);
    font-size: 4.5rem;
    color: var(--c-champagne);
    margin: 20px 0 10px;
    line-height: 1.2;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

.weds {
    font-family: var(--f-sans-alt);
    font-size: 1.5rem;
    color: var(--c-olive);
    text-transform: lowercase;
}

.letter-hearts {
    margin-bottom: 30px;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

.letter-heart {
    font-size: 2.5rem;
    color: var(--c-champagne);
    opacity: 0;
    /* Hidden initially for animation */
    transform: translateY(20px) scale(0.5);
    /* Scaled down initially */
}

.heart-center {
    font-size: 3.5rem;
    /* Make the center one larger */
    color: #8f171b;
    /* Dark red */
}

.bride-parents {
    margin-bottom: 40px;
}

.letter-event-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 40px;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    padding: 30px 0;
}

.event-col {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.event-col strong {
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--c-black);
}

.event-col span {
    font-size: 1rem;
    color: #555;
    line-height: 1.4;
}

.letter-footer {
    margin-top: 30px;
}

.highlight-text {
    color: var(--c-champagne);
    font-size: 1.2rem;
    margin-bottom: 10px;
    font-style: italic;
}

.letter-footer p {
    font-size: 0.9rem;
    color: #555;
}

/* Location Details Section */
.location-details {
    padding: 100px 0;
    background-color: #eae2c4;
    /* White background as requested */
    min-height: 100vh;
    text-align: center;
}

.location-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 40px;
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 20px;
}

@media (max-width: 768px) {
    .location-grid {
        grid-template-columns: repeat(auto-fit, minmax(334px, 1fr));

    }
}

.location-card {
    padding: 40px;
    text-align: center;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.location-card h3 {
    font-family: var(--f-serif);
    font-size: 2rem;
    color: var(--c-champagne);
    margin-bottom: 15px;
}

.location-card p {
    font-size: 1.1rem;
    color: var(--c-olive);
    margin-bottom: 10px;
}

.map-wrapper {
    margin: 30px 0;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    overflow: hidden;
}

.btn-navigate {
    display: inline-block;
    padding: 12px 30px;
    background-color: var(--c-champagne);
    color: #fff;
    text-decoration: none;
    border-radius: 30px;
    font-family: var(--f-sans-alt);
    font-weight: 600;
    letter-spacing: 1px;
    transition: transform 0.3s, box-shadow 0.3s;
}

.btn-navigate:hover {
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(210, 35, 41, 0.4);
}

/* Countdown Section */
.countdown-section {
    padding: 150px 20px;
    background-color: var(--c-olive);
    position: relative;
    overflow: hidden;
    text-align: center;
    color: var(--c-ivory);
}

@media screen and (max-width: 768px) {
    .countdown-section {
        padding: 40px 20px;
    }
}

.countdown-glass {
    max-width: 800px;
    margin: 0 auto;
    padding: 60px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    position: relative;
    z-index: 2;
}

.countdown-glass h2 {
    font-family: var(--f-elegant);
    font-size: 2.5rem;
    margin-bottom: 40px;
}

.countdown-timer {
    display: flex;
    justify-content: center;
    gap: 40px;
}

.time-block {
    display: flex;
    flex-direction: column;
}

.time-block .num {
    /* font-family: var(--f-serif); */
    font-size: 4rem;
    font-weight: 300;
}

.time-block .label {
    font-family: var(--f-sans-alt);
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.8rem;
    opacity: 0.8;
}

/* Events Section */
.events-section {
    padding: 100px 20px;
    background-color: var(--c-warm-white);
}

.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 40px;
    max-width: 1000px;
    margin: 0 auto;
}

.event-card {
    padding: 50px 30px;
    text-align: center;
    transition: transform 0.4s ease, box-shadow 0.4s ease;
}

.event-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.08);
}

.event-icon {
    font-size: 3rem;
    margin-bottom: 20px;
}

.event-card h3 {
    font-family: var(--f-elegant);
    font-size: 2rem;
    margin-bottom: 20px;
    color: var(--c-champagne);
}

.event-info p {
    margin-bottom: 10px;
    line-height: 1.6;
}

/* Venue Section */
.venue-section {
    position: relative;
    height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.venue-bg {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
}

.venue-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.venue-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
}

.venue-content {
    text-align: center;
    color: white;
    z-index: 2;
}

.venue-content h2 {
    font-family: var(--f-elegant);
    font-size: 4rem;
    margin-bottom: 20px;
}

.venue-address {
    font-size: 1.2rem;
    margin-bottom: 30px;
}

.btn-navigate {
    display: inline-block;
    padding: 15px 40px;
    background: var(--c-champagne);
    color: white;
    text-decoration: none;
    text-transform: uppercase;
    letter-spacing: 2px;
    border-radius: 30px;
    transition: background 0.3s ease;
}

.btn-navigate:hover {
    background: #b8962c;
}

/* Masonry Gallery */
.gallery-section {
    padding: 100px 20px;
    background: var(--c-ivory);
}

.masonry-gallery {
    column-count: 2;
    column-gap: 20px;
    max-width: 1200px;
    margin: 0 auto;
}

.gallery-item {
    margin-bottom: 20px;
    break-inside: avoid;
    overflow: hidden;
    border-radius: 12px;
    cursor: pointer;
    position: relative;
}

.gallery-item img {
    width: 100%;
    display: block;
    transition: transform 0.8s ease, filter 0.8s ease;
}

.gallery-item:hover img {
    transform: scale(1.05);
    filter: brightness(0.8);
}

/* RSVP Section */
.rsvp-section {
    padding: 100px 20px;
    background: #ec8083;
    display: flex;
    align-items: center;
    justify-content: center;
}

.rsvp-container {
    max-width: 900px;
    width: 100%;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 50px;
}

.rsvp-image-wrapper {
    flex: 0 1 auto;
    /* Do not stretch unnecessarily */
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.rsvp-couple-img {
    width: 330px;
    /* Make the image smaller */
    height: auto;
    object-fit: contain;
    filter: drop-shadow(0 15px 25px rgba(0, 0, 0, 0.15));
    border-radius: 10px;
}

.rsvp-form {
    flex: 1;
    min-width: 350px;
    padding: 50px;
}

.rsvp-form h2 {
    font-family: var(--f-elegant);
    font-size: 2.5rem;
    margin-bottom: 30px;
    text-align: center;
}

.input-group {
    margin-bottom: 20px;
}

.input-group input,
.input-group select,
.input-group textarea {
    width: 100%;
    padding: 15px;
    border: none;
    border-bottom: 2px solid rgba(0, 0, 0, 0.1);
    background: rgba(255, 255, 255, 0.5);
    font-family: inherit;
    font-size: 1rem;
    transition: all 0.3s;
    border-radius: 5px 5px 0 0;
}

.input-group textarea {
    resize: vertical;
    border: 1px solid rgba(0, 0, 0, 0.1);
    /* Full border for textarea looks better */
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.7);
}

.input-group input:focus,
.input-group select:focus,
.input-group textarea:focus {
    outline: none;
    border-color: var(--c-champagne);
    background: rgba(255, 255, 255, 0.8);
}

.btn-submit {
    width: 100%;
    padding: 15px;
    background: var(--c-olive);
    color: white;
    border: none;
    font-family: var(--f-sans-alt);
    text-transform: uppercase;
    letter-spacing: 2px;
    cursor: pointer;
    margin-top: 20px;
    border-radius: 4px;
    transition: background 0.3s ease;
}

.btn-submit:hover {
    background: #364419;
}

.success-message {
    text-align: center;
    padding: 20px;
    margin-top: 25px;
    background: rgba(255, 255, 255, 0.95);
    border: 2px solid var(--c-champagne);
    border-radius: 10px;
    color: var(--c-olive);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

/* Wishes Wall */
.wishes-section {
    padding: 100px 0;
    background: var(--c-ivory);
    overflow: hidden;
}

@media screen and (max-width: 768px) {
    .wishes-section {
        padding: 50px 0;

    }
}

.marquee-wrapper {
    width: 100vw;
    position: relative;
    display: flex;
    overflow: hidden;
}

.marquee-track {
    display: flex;
    gap: 30px;
    padding: 20px 0;
}

.wish-card {
    min-width: 400px;
    padding: 40px;
    white-space: normal;
    height: max-content;
}

.wish-text {
    /* font-family: var(--f-serif); */
    font-size: 1rem;
    font-style: italic;
    line-height: 1.6;
    margin-bottom: 20px;
}

.wish-author {
    font-family: var(--f-sans-alt);
    font-weight: 500;
    color: var(--c-champagne);
}

/* Quote Section */
.quote-section {
    height: 60vh;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--c-warm-white);
    text-align: center;
    padding: 40px;
}

.quote-text {
    font-family: var(--f-serif);
    font-size: 3rem;
    font-style: italic;
    font-weight: 300;
    max-width: 800px;
    line-height: 1.4;
    margin-bottom: 40px;
}

.handwriting-signature {
    font-family: var(--f-display);
    font-size: 4rem;
    color: var(--c-champagne);
}

@media (max-width: 768px) {
    .handwriting-signature {
        font-size: 3rem;
    }
}

/* Footer */
.footer {
    background: var(--c-black);
    color: var(--c-ivory);
    padding: 80px 20px;
    text-align: center;
}

.made-with-love {
    font-family: var(--f-sans);
    font-size: 1rem;
    color: var(--c-ivory);
    text-transform: uppercase;
    letter-spacing: 3px;
    margin-bottom: 20px;
}

.footer-love {
    display: block;
    font-family: var(--f-display);
    font-size: 5rem;
    color: #e74c3c;
    /* Red color */
    text-transform: none;
    letter-spacing: 0;
    margin-top: 15px;
    line-height: 1;
}

.developer-credit {
    margin-top: 15px;
    font-size: 0.95rem;
    color: var(--c-ivory);
    opacity: 0.9;
}

.developer-credit a {
    color: #e74c3c;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.developer-credit a:hover {
    color: var(--c-champagne);
}

.copyright {
    margin-top: 40px;
    opacity: 0.5;
    font-size: 0.9rem;
}

/* Responsive */
@media (max-width: 768px) {
    .hero {
        align-items: flex-start;
        padding-top: 4vh;
        /* Pushes text to the top to avoid image overlap */
    }

    .hero-title {
        font-size: 4rem;
    }

    .hero-subtitle {
        font-size: 1rem;
    }

    .timeline-card {
        width: 300px;
    }

    .couple-container {
        flex-direction: column;
        gap: 40px;
    }

    .masonry-gallery {
        column-count: 1;
    }

    .countdown-timer {
        flex-wrap: wrap;
    }

    .time-block .num {
        font-size: 3rem;
    }

    .wish-card {
        min-width: 300px;
    }

    .quote-text {
        font-size: 2rem;
    }

    .balloon-heart {
        font-size: 4rem;
        /* Smaller hydrogen balloon hearts on mobile */
    }

    .rsvp-form {
        min-width: 100%;
        padding: 20px;
    }

    .rsvp-couple-img {
        width: 200px;
    }

    .envelope-wrapper {
        width: 100%;
        max-width: 350px;
    }

    .loader-intro-text {
        font-size: 1rem;
        padding: 0 20px;
    }

    .letter-event-grid {
        grid-template-columns: 1fr;
        /* Stack event details vertically to prevent overflow */
        padding: 20px 10px;
    }

    .invitation-section {
        padding-top: 0;
    }

    .invitation-letter {
        padding: 40px 20px;
        margin-top: 25vh;
        /* Bring letter up sooner on small screens */
        margin-bottom: -200px;
        /* Aggressively pull the next section up to remove the invisible gap caused by GSAP animations */
    }

    .location-details {
        padding: 20px 0;
        /* Minimal padding before location section on mobile */
    }

    .footer {
        padding: 120px 40px 60px 40px;
        /* More gap on top, more padding left/right */
    }

    .calendar-btn .music-text,
    .music-toggle .music-text {
        display: none;
    }

    .calendar-btn,
    .music-toggle {
        padding: 12px;
        gap: 0;
    }
}