:root {
    --gold: #c29d5f;
    --soft-dark: #121212;
    --accent: #f8f3eb;
    --vignette-start: rgba(0,0,0,0.1);
    --vignette-end: rgba(18,18,18,1);
}

html {
    scroll-behavior: smooth;
}

html, body {
    overflow-x: hidden; /* Kills the horizontal scroll perfectly */
    width: 100%;
    max-width: 100vw;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--soft-dark);
    color: var(--accent);
    font-family: 'Montserrat', sans-serif;
    padding-bottom: 80px;
}

/* 1. Personalized Vignette Hero */
.vignette-hero {
    height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    background: radial-gradient(circle, var(--vignette-start) 0%, var(--vignette-end) 80%),
                url('../images/formal-portrait.jpeg') center 23% / cover; /* Tweaked this line */
    text-align: center;
    position: relative;
    z-index: 1;
}

.hero-content {
    animation: fadeIn 2s ease-out;
    margin-top: 45vh;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.pre-title {
    font-family: 'Cormorant Garamond', serif;
    font-size: 1.8rem;
    font-style: italic;
    color: #f8f3eb;
    letter-spacing: 4px;
    opacity: 0.9;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.8);
}

.main-name {
    font-family: 'Cinzel Decorative', serif;
    font-size: clamp(3.5rem, 10vw, 7.5rem);
    font-weight: 700;
    margin: 10px 0;
    
    /* Richer, multi-stop metallic gold gradient */
    background: linear-gradient(to right, #BF953F, #FCF6BA, #B38728, #FBF5B7, #AA771C);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    
    /* Animation and Shadow to make it pop off the photo */
    animation: shine 4s linear infinite;
    filter: drop-shadow(0px 5px 15px rgba(0,0,0,0.7));
}

.heart {
    display: inline-block;
    font-family: Arial, sans-serif;
    
    font-size: 1.2em;
    margin: 0 10px;
    
    color: #d45d5d;
    -webkit-text-fill-color: #d45d5d;

    filter: drop-shadow(0px 8px 18px rgba(0,0,0,0.6));
    
    animation: heartbeat 2s infinite; 
}

/* The double-beat keyframes */
@keyframes heartbeat {
    0%, 100% { transform: scale(1); }
    10% { transform: scale(1.15); }
    20% { transform: scale(1); }
    30% { transform: scale(1.15); }
    40% { transform: scale(1); }
}

.date-hero {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    letter-spacing: 6px;
    text-transform: uppercase;
    font-size: 1.1rem;
    color: #f8f3eb;
    margin-top: 15px;
    text-shadow: 2px 2px 8px rgba(0,0,0,0.8);
}

@keyframes shine {
    0% { background-position: 0% 50%; }
    100% { background-position: 200% 50%; }
}

.scroll-indicator {
    position: absolute;
    bottom: 40px;
    font-size: 0.8rem;
    letter-spacing: 2px;
    opacity: 0.6;
    animation: nudge 2s infinite ease-in-out;
}

@keyframes nudge {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(10px); }
}

.interactive-invitation {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    padding: 40px 20px;
}

.content-box {
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(194, 157, 95, 0.2);
    padding: clamp(30px, 8vw, 100px) clamp(20px, 4vw, 50px);
    
    border-radius: 30px; 
    
    backdrop-filter: blur(20px);
    max-width: 800px;
    width: 100%;
    text-align: center;
    position: relative;
    z-index: 2;
}

.arch-image {
    height: clamp(350px, 50vw, 450px); 
    border-radius: 300px 300px 0 0; 
    
    background-size: cover;
    background-position: center top; 
    margin-bottom: 40px;
    border: 2px solid var(--gold);
    padding: 15px; 
    background-color: var(--soft-dark); 
    background-clip: content-box; 
    box-shadow: 0 20px 50px rgba(0,0,0,0.8); 
    opacity: 0.95;
}

.script-heading {
    font-family: 'Ephesis', cursive;
    font-size: clamp(3rem, 8vw, 5rem);
    color: var(--gold);
    margin-bottom: clamp(10px, 3vw, 30px);
}

.event-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-top: clamp(20px, 4vw, 50px);
    text-align: center;
}

.detail-block {
    padding: 20px;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 15px;
    border: 1px solid rgba(194, 157, 95, 0.1);
    transition: 0.3s ease;
}

.detail-block:hover {
    border-color: rgba(194, 157, 95, 0.5);
    transform: translateY(-5px);
}

.detail-block h3 {
    font-family: 'Playfair Display', serif;
    color: var(--gold);
    font-size: 1.8rem;
    margin-bottom: 10px;
    letter-spacing: 1px;
}

.event-date {
    font-weight: 400;
    font-size: 0.9rem;
    margin-bottom: 5px;
    color: #fff;
}

.time {
    font-size: 0.85rem;
    opacity: 0.7;
    margin-bottom: 20px;
}

.venue-name {
    font-weight: 600;
    color: var(--gold);
    margin-bottom: 15px;
    font-size: 0.95rem;
}

.dress-code {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    color: var(--accent);
    font-style: italic;
    opacity: 0.9;
    margin-bottom: 15px;
    padding: 6px 12px;
    background: rgba(194, 157, 95, 0.1);
    border-radius: 4px;
    display: inline-block;
}

.location-link {
    display: inline-block;
    color: var(--soft-dark);
    background-color: var(--gold);
    text-decoration: none;
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: 0.3s ease;
}

.location-link:hover {
    background-color: #fff;
    color: var(--soft-dark);
    box-shadow: 0 0 15px rgba(194, 157, 95, 0.4);
}

.divider {
    width: 1px;
    height: 60px;
    background: var(--gold);
    opacity: 0.5;
}

.cinematic-gallery {
    padding: 100px 0;
    overflow: hidden;
    position: relative;
}

.gallery-track {
    display: flex;
    gap: 20px;
    width: max-content; 
    animation: scrollGallery 25s infinite linear;
}

.img-frame {
    min-width: 300px;
    height: 450px;
    background: #222;
    border-radius: 150px;
    transition: 0.8s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    background-size: cover;
    background-position: center;
    border: 1px solid transparent;
    cursor: pointer;
}

.img-frame:hover {
    transform: scale(1.1) translateY(-30px);
    border-color: var(--gold);
    box-shadow: 0 20px 50px rgba(194, 157, 95, 0.3);
}

.gallery-track:hover {
    animation-play-state: paused;
}

@keyframes scrollGallery {
    0% { 
        transform: translateX(0); 
    }
    100% {
        transform: translateX(calc(-50% - 10px)); 
    }
}

.bg-particles {
    position: fixed;
    top: 0; left: 0; width: 100%; height: 100%;
    background-image: radial-gradient(circle, var(--gold) 1px, transparent 1px);
    background-size: 100px 100px;
    opacity: 0.1;
    z-index: -1;
    animation: drift 60s infinite linear;
}

@keyframes drift {
    from { background-position: 0 0; }
    to { background-position: 1000px 1000px; }
}

.haldi-card {
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.cartoon-container {
    position: relative;
    width: 100%;
    height: 120px;
    margin-bottom: 20px;
    display: flex;
    justify-content: center;
    align-items: center;
}

.event-cartoon {
    max-height: 100%;
    max-width: 100%;
    object-fit: contain;
    z-index: 5;
    position: relative;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.haldi-card:hover .event-cartoon {
    transform: scale(1.15) rotate(-3deg);
}

.splash {
    position: absolute;
    border-radius: 40% 60% 70% 30% / 40% 50% 60% 50%;
    opacity: 0;
    z-index: 1;
    transform: scale(0);
}

.splash-1 {
    background-color: #FFD700;
    top: 20%;
    left: 20%;
    width: 40px;
    height: 45px;
    box-shadow: 0 0 15px #FFD700;
}

.splash-2 {
    background-color: #FFA500;
    bottom: 10%;
    right: 25%;
    width: 50px;
    height: 40px;
    border-radius: 60% 40% 30% 70% / 50% 60% 40% 50%;
    box-shadow: 0 0 15px #FFA500;
}

.splash-3 {
    background-color: #FDB813;
    top: 10%;
    right: 30%;
    width: 35px;
    height: 35px;
    box-shadow: 0 0 10px #FDB813;
}

.haldi-card:hover .splash-1 {
    animation: haldiBurst 0.6s ease-out forwards;
}

.haldi-card:hover .splash-2 {
    animation: haldiBurst 0.6s ease-out 0.1s forwards;
}

.haldi-card:hover .splash-3 {
    animation: haldiBurst 0.6s ease-out 0.2s forwards;
}

@keyframes haldiBurst {
    0% {
        transform: scale(0) translate(0, 0);
        opacity: 1;
    }
    50% {
        opacity: 0.8;
    }
    100% {
        transform: scale(3.5) translate(calc(10px - 20px), calc(10px - 30px));
        opacity: 0;
    }
}

.countdown-section {
    padding: 80px 20px 20px;
    text-align: center;
    position: relative;
    z-index: 2;
}

.countdown-title {
    font-family: 'Ephesis', cursive;
    font-size: clamp(2.5rem, 6vw, 4rem);
    color: var(--gold);
    margin-bottom: 30px;
}

.countdown-timer {
    display: flex;
    justify-content: center;
    gap: 15px;
    flex-wrap: wrap;
}

.time-box {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(194, 157, 95, 0.3);
    border-radius: 15px;
    padding: 20px 25px;
    min-width: 110px;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.4);
    transition: transform 0.3s ease;
}

.time-box:hover {
    transform: translateY(-5px);
    border-color: rgba(194, 157, 95, 0.7);
}

.time-box span {
    font-family: 'Playfair Display', serif;
    font-size: clamp(2rem, 5vw, 3rem);
    font-weight: 700;
    color: var(--accent); /* White/Cream color */
    display: block;
    line-height: 1;
    margin-bottom: 8px;
}

.time-box p {
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    text-transform: uppercase;
    letter-spacing: 2px;
    color: var(--gold);
    font-weight: 400;
}

.creative-timeline {
    padding: 100px 20px;
    position: relative;
    z-index: 2;
    overflow-x: hidden;
}

.creative-timeline .script-heading {
    text-align: center;
    margin-bottom: 80px;
}

.cards-container {
    max-width: 1000px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    position: relative;
}

.memory-card {
    width: 320px;
    height: auto;
    position: relative;
    transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    z-index: 1;
}

.memory-card:hover {
    transform: rotate(0deg) scale(1.08) !important;
    z-index: 10;
}

.card-inner {
    padding: 15px;
    perspective: 1000px;
}

.card-paper {
    background-color: var(--accent); /* Light cream/white paper color */
    color: var(--soft-dark); /* Dark text on light paper */
    border: 1px solid rgba(194, 157, 95, 0.3); /* Subtle gold border */
    border-radius: 5px; /* Slight rounded corner for paper look */
    padding: 30px;
    position: relative;
    box-shadow: 0 15px 35px rgba(0,0,0,0.4);
    transition: box-shadow 0.3s ease;
}

.memory-card:hover .card-paper {
    box-shadow: 0 20px 60px rgba(194, 157, 95, 0.4); /* Gold glow on hover */
}

/* Decorative Gold Corner Flourishes */
.decorative-corner {
    position: absolute;
    width: 25px;
    height: 25px;
    border: 2px solid var(--gold);
    opacity: 0.5;
}

.corner-flourish.top-left { top: 15px; left: 15px; border-right: none; border-bottom: none; }
.corner-flourish.top-right { top: 15px; right: 15px; border-left: none; border-bottom: none; }
.corner-flourish.bottom-right { bottom: 15px; right: 15px; border-left: none; border-top: none; }

/* 4. Text Styling inside the Cards */
.event-title {
    font-family: 'Playfair Display', serif;
    font-size: 2.2rem;
    font-weight: 700;
    color: var(--soft-dark);
    margin-bottom: 5px;
    letter-spacing: 1px;
}

.event-day {
    font-family: 'Montserrat', sans-serif;
    font-weight: 300;
    text-transform: uppercase;
    letter-spacing: 2px;
    font-size: 0.9rem;
    opacity: 0.7;
    margin-bottom: 20px;
}

.event-date, .event-time, .venue-name {
    font-family: 'Montserrat', sans-serif;
    font-weight: 400;
    margin-bottom: 5px;
    font-size: 1rem;
}

.venue-name {
    margin-top: 15px;
    margin-bottom: 25px;
    font-weight: 600;
}

/* 5. Modern Map Button */
.map-btn {
    display: inline-block;
    color: #fff;
    background-color: var(--soft-dark);
    text-decoration: none;
    padding: 10px 25px;
    border-radius: 30px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
}

.map-btn:hover {
    background-color: var(--gold);
    color: var(--soft-dark);
    box-shadow: 0 5px 15px rgba(194, 157, 95, 0.3);
}

/* --- THE NON-LINEAR POSITIONING --- */

/* Card 1: Mehendi (Stagger Left and Rotate) */
.card-left {
    transform: rotate(-3deg) translateX(-150px);
    margin-bottom: -50px; /* Slight overlap */
}

/* Card 2: Marriage (Stagger Right, Rotate Opposite, Shift Down) */
.card-right {
    transform: rotate(4deg) translateX(150px) translateY(50px);
    margin-bottom: 20px;
}

/* Card 3: Reception (Center but slightly off-kilter) */
.card-center {
    transform: rotate(-2deg);
    margin-top: 30px;
}

/* --- Responsive Layout for Mobile --- */
@media (max-width: 768px) {
    .cards-container {
        gap: 20px;
    }
    
    /* Reduce staggering on smaller screens but keep slight rotations */
    .card-left { transform: rotate(-2deg) translateX(0px); margin-bottom: 0px; }
    .card-right { transform: rotate(3deg) translateX(0px) translateY(0px); margin-bottom: 0px; }
    .card-center { transform: rotate(-1deg); margin-top: 0px; }
}

/* --- Scattered Polaroid Gallery --- */

.photo-gallery {
    padding: 20px 20px;
    position: relative;
    z-index: 2;
    overflow: hidden; /* Prevents tilted images from causing a horizontal scrollbar */
}

.scattered-collage {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 30px; /* Space between photos */
    max-width: 1200px;
    margin: 0 auto;
    padding: 10px 0 30px 0;
}

/* The Polaroid Frame Look */
.polaroid {
    background-color: #f8f3eb; /* Off-white paper color */
    padding: 12px 12px 15px 12px; /* Extra padding at bottom for polaroid style */
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6);
    border-radius: 4px;
    width: clamp(200px, 25vw, 300px); /* Keeps images reasonably sized */
    position: relative;
    z-index: 1;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), z-index 0.4s;
    
    /* ADD THIS LINE: It uses variables that our JavaScript will fill in */
    transform: rotate(var(--rot, 0deg)) translateY(var(--y, 0px));
}

.polaroid img {
    width: 100%;
    height: auto;
    display: block;
    border-radius: 2px;
}

/* --- The Interactive Hover Effect --- */
.polaroid:hover {
    /* Straightens the image, brings it forward, and scales it up slightly */
    transform: rotate(0deg) scale(1.15) translateY(0) !important;
    z-index: 50; /* Forces the hovered image to sit on top of the others */
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.8);
    cursor: pointer;
}

/* Import the handwritten font */
@import url('https://fonts.googleapis.com/css2?family=Caveat:wght@600&display=swap');

/* Style the text to look like ink on paper */
.polaroid-caption {
    font-family: 'Caveat', cursive;
    font-size: 1.8rem;
    color: #1a1a1a; /* Very dark grey, looks more natural than pure black ink */
    text-align: center;
    margin-top: 15px; /* Adds a little space between the photo and the writing */
    margin-bottom: 5px;
    line-height: 1;
    transform: rotate(-1deg); /* A tiny tilt makes it look authentically handwritten! */
}

/* --- Perfect Mobile Title Stacking --- */
@media (max-width: 768px) {
    /* 1. Force the heading to stack vertically */
    .main-name {
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        line-height: 1.1; /* Keeps the names from feeling too far apart */
    }

    /* 2. Give the heart perfect spacing in the middle */
    .heart {
        margin: 15px 0; /* Adds 15px of space above and below the heart */
        display: block; 
    }
}

/* --- Premium Cinematic Scroll Animations --- */

/* Base settings for all reveals */
.reveal-up, .reveal-left, .reveal-right, .reveal-zoom, .reveal-focus {
    opacity: 0;
    /* This cubic-bezier makes it start fast and smoothly glide into place */
    transition: all 1.2s cubic-bezier(0.165, 0.84, 0.44, 1); 
    will-change: transform, opacity, filter;
}

/* 1. The Fade Up (Great for headers and text) */
.reveal-up { transform: translateY(60px); }
.reveal-up.active { opacity: 1; transform: translateY(0); }

/* 2. Slide from Left (Great for alternating cards) */
.reveal-left { transform: translateX(-80px); }
.reveal-left.active { opacity: 1; transform: translateX(0); }

/* 3. Slide from Right (Great for alternating cards) */
.reveal-right { transform: translateX(80px); }
.reveal-right.active { opacity: 1; transform: translateX(0); }

/* 4. The Soft Zoom (Great for the countdown) */
.reveal-zoom { transform: scale(0.85); }
.reveal-zoom.active { opacity: 1; transform: scale(1); }

/* 5. Dreamy Focus (Perfect for the polaroids! Doesn't break your rotation math) */
.reveal-focus { 
    opacity: 0; 
    filter: blur(20px); 
    /* Removed transform so it relies entirely on the JavaScript angles */
}

.reveal-focus.active { 
    opacity: 1; 
    filter: blur(0); 
}

/* Stagger delays so things don't appear all at the exact same millisecond */
.delay-1 { transition-delay: 0.1s; }
.delay-2 { transition-delay: 0.3s; }
.delay-3 { transition-delay: 0.5s; }

/* --- Floating Music Player --- */
.music-control {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 1000; /* Ensures it stays on top of everything */
}

.music-btn {
    width: 55px;
    height: 55px;
    border-radius: 50%;
    background-color: var(--soft-dark);
    border: 2px solid var(--gold);
    color: var(--gold);
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    transition: all 0.3s ease;
}

.music-btn:hover {
    transform: scale(1.1);
    box-shadow: 0 15px 35px rgba(194, 157, 95, 0.4);
    background-color: var(--gold);
    color: var(--soft-dark);
}

/* Optional: Add a gentle pulse animation when the music is playing */
@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(194, 157, 95, 0.4); }
    70% { box-shadow: 0 0 0 15px rgba(194, 157, 95, 0); }
    100% { box-shadow: 0 0 0 0 rgba(194, 157, 95, 0); }
}

.music-btn.playing {
    animation: pulse 2s infinite;
}

/* Move it slightly on mobile so it doesn't block the screen edge */
@media (max-width: 768px) {
    /* .music-control {
        bottom: 20px;
        right: 20px;
    } */
    .music-btn {
        width: 45px;
        height: 45px;
    }
}

/* --- Dreamy Flower and Heart Shower --- */

/* 1. Container - Full Screen and non-blocking */
#flower-shower-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    pointer-events: none; /* Crucial: ensures guests can still click buttons underneath */
    z-index: 999; /* Floats above everything except the particle background */
    overflow: hidden;
}

/* 2. Styling for individual Petals (uses soft shapes for flowers) */
.petal {
    position: absolute;
    top: -30px; /* Start just off-screen */
    width: 15px; /* Variations in JS */
    height: 15px; /* Variations in JS */
    opacity: 0.8;
    border-radius: 50% 0 50% 0; /* Petal shape */
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
    
    /* Fall animation is added dynamically in JS for variation */
}

/* 3. Styling for individual Hearts */
.falling-heart {
    position: absolute;
    top: -30px;
    font-size: 20px; /* Variations in JS */
    color: #d45d5d; /* Your exact Ruby Red wedding color */
    opacity: 0.9;
    user-select: none;
    line-height: 1;
}

/* 4. The Falling and Spinning Keyframes */
@keyframes petal-fall {
    0% { transform: translateY(0) rotate(0deg); opacity: 0; }
    10% { opacity: 0.8; }
    90% { opacity: 0.8; }
    100% { transform: translateY(105vh) rotate(540deg); opacity: 0; }
}

/* --- Fun Comic Strip Section --- */

.comic-section {
    padding: 60px 20px;
    position: relative;
    z-index: 2;
    overflow: hidden;
}

.comic-strip {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
    max-width: 1000px;
    margin: 0 auto;
    flex-wrap: wrap; /* Allows panels to stack on mobile */
}

/* Classic Comic Book Panel Look */
.comic-panel {
    background-color: #fff;
    padding: 10px; /* Creates the white comic border */
    border-radius: 4px;
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.6);
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

/* Give the panels a very slight, playful tilt */
.comic-panel:nth-child(1) { transform: rotate(-2deg); }
.comic-panel:nth-child(2) { transform: rotate(1deg); }
.comic-panel:nth-child(3) { transform: rotate(-1deg); }

/* Make them pop out when hovered over */
.comic-panel:hover {
    transform: scale(1.05) rotate(0deg);
    z-index: 10;
    box-shadow: 0 20px 40px rgba(194, 157, 95, 0.3); /* Subtle gold glow */
}

/* .comic-panel img {
    display: block;
    max-width: 100%;
    height: auto;
    width: 280px;
    border: 2px solid #1a1a1a;
} */

.comic-panel img {
    display: block;
    width: 280px;
    height: 180px; /* Forces every image to be the exact same height */
    object-fit: cover; /* Fills the box perfectly without squishing or stretching */
    object-position: top center; /* Ensures the top of the comic isn't cut off in the thumbnail */
    border: 2px solid #1a1a1a;
    cursor: pointer;
}

/* The Disclaimer Text */
.comic-disclaimer {
    text-align: center;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.75rem;
    color: var(--accent); /* Uses your light cream color */
    opacity: 0.5; /* Keeps it subtle so it doesn't distract */
    font-style: italic;
    margin-top: 35px;
    letter-spacing: 0.5px;
}

/* Responsive adjustment for mobile */
@media (max-width: 768px) {
    .comic-panel:nth-child(1),
    .comic-panel:nth-child(2),
    .comic-panel:nth-child(3) {
        transform: rotate(0deg); /* Keeps them straight on small screens */
    }
}

/* --- Elegant Lightbox/Modal --- */
.lightbox {
    position: fixed;
    z-index: 2000; /* Sits on top of absolutely everything */
    left: 0;
    top: 0;
    width: 100vw;
    height: 100vh;
    background-color: rgba(10, 10, 10, 0.85); /* Dark, cinematic background */
    backdrop-filter: blur(8px); /* Premium frosted glass effect */
    display: flex;
    justify-content: center;
    align-items: center;
    
    /* Hidden by default with smooth transitions */
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: all 0.4s ease;
}

/* When the JavaScript adds the "show" class */
.lightbox.show {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
}

.lightbox-content {
    max-width: 90%;
    max-height: 85vh;
    border-radius: 8px;
    box-shadow: 0 0 40px rgba(194, 157, 95, 0.4); /* Soft gold glow behind the image */
    
    /* Starts slightly small and pops up */
    transform: scale(0.8);
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.lightbox.show .lightbox-content {
    transform: scale(1);
}

/* The Close Button */
.lightbox-close {
    position: absolute;
    top: 25px;
    right: 40px;
    color: #fff;
    font-size: 45px;
    font-weight: 300;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 2001;
}

.lightbox-close:hover {
    color: var(--gold); /* Turns gold when hovered */
    transform: scale(1.1);
}

/* Make sure the mouse turns into a 'pointer' finger when hovering over comic images */
.comic-panel img {
    cursor: pointer; 
}

/* --- Lightbox Navigation Arrows --- */
.lightbox-prev,
.lightbox-next {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: #fff;
    font-size: 50px;
    font-weight: 300;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 2001;
    padding: 20px;
    user-select: none; /* Prevents the arrows from turning blue if clicked too fast */
}

.lightbox-prev { left: 20px; }
.lightbox-next { right: 20px; }

.lightbox-prev:hover,
.lightbox-next:hover {
    color: var(--gold);
    transform: translateY(-50%) scale(1.2);
}

/* Adjust sizes for mobile screens */
@media (max-width: 768px) {
    .lightbox-prev, .lightbox-next {
        font-size: 35px;
        padding: 10px;
    }
    .lightbox-prev { left: 5px; }
    .lightbox-next { right: 5px; }
}

/* --- Slow, Elegant Live Message Pulse --- */
.live-event-message {
    text-align: center;
    padding: 30px;
    background: rgba(10, 10, 10, 0.4);
    border: 1px solid rgba(194, 157, 95, 0.3);
    border-radius: 8px;
    backdrop-filter: blur(5px);
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    
    /* A very slow, 4-second breathing animation that fades gently */
    animation: slowBreathing 4s infinite alternate ease-in-out;
}

@keyframes slowBreathing {
    0% { 
        opacity: 0.75; /* Never goes fully invisible, just dims slightly */
        box-shadow: 0 0 10px rgba(194, 157, 95, 0.1); 
    }
    100% { 
        opacity: 1;    /* Fully bright */
        box-shadow: 0 0 30px rgba(194, 157, 95, 0.4); /* Gold glow expands */
    }
}

@media (max-width: 768px) {
    .live-event-message h3 { font-size: 1.8rem !important; }
    .live-event-message p { font-size: 0.95rem !important; }
}

/* --- Live Blinking Dot Effect --- */
.live-blink-dot {
    display: inline-block;
    width: 14px;
    height: 14px;
    background-color: #d45d5d; /* Matches your ruby red theme */
    border-radius: 50%;
    animation: livePulse 1.5s infinite;
}

@keyframes livePulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(212, 93, 93, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 12px rgba(212, 93, 93, 0);
    }
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(212, 93, 93, 0);
    }
}

.top-live-badge {
    position: absolute;
    top: 40px;
    right: 50px;
    z-index: 100;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 18px;
    border: 1px solid rgba(194, 157, 95, 0.4); /* Soft Gold border */
    border-radius: 30px; /* Pill shape */
    background: rgba(10, 10, 10, 0.3); /* Dark glass effect */
    backdrop-filter: blur(8px);
    color: var(--gold); 
    font-family: 'Montserrat', sans-serif;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    text-decoration: none;
    transition: all 0.3s ease;
}

.top-live-badge:hover {
    background: rgba(194, 157, 95, 0.2);
    border-color: var(--gold);
    transform: scale(1.05);
    box-shadow: 0 5px 15px rgba(194, 157, 95, 0.2);
}

/* The tiny blinking red dot */
.small-blink-dot {
    width: 8px;
    height: 8px;
    background-color: #d45d5d;
    border-radius: 50%;
    animation: livePulse 1.5s infinite; /* Reuses the pulse animation we made earlier */
}

/* Adjustments so it looks perfect on mobile phones */
@media (max-width: 768px) {
    .top-live-badge {
        top: 25px;
        right: 20px;
        padding: 6px 14px;
        font-size: 0.75rem;
    }
}
/* --- Live Event Location Button --- */
.live-location-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    padding: 8px 20px;
    background: rgba(194, 157, 95, 0.15); /* Soft gold background */
    border: 1px solid rgba(194, 157, 95, 0.4);
    border-radius: 30px;
    color: var(--gold);
    text-decoration: none;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.9rem;
    transition: all 0.3s ease;
}

.live-location-btn:hover {
    background: rgba(194, 157, 95, 0.3);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(194, 157, 95, 0.2);
    color: #fff;
}

/* --- Hero Section Days Countdown --- */
.hero-days-text {
    font-family: 'Ephesis', cursive; /* Gives it that beautiful handwritten look */
    color: var(--gold);
    font-size: 2.2rem;
    margin-top: -10px;
    margin-bottom: 40px;
    opacity: 0;
    
    /* Adds a slight delay so it fades in gracefully after the hero image loads */
    animation: fadeInText 2s ease forwards 1s; 
    text-shadow: 2px 2px 8px rgba(0,0,0,0.6);
}

@keyframes fadeInText {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

/* @media (max-width: 768px) {
    .hero-days-text {
        font-size: 1.8rem;
        margin-bottom: 30px;
    }
} */

/* --- Music Player Tooltip --- */
.music-tooltip {
    position: absolute;
    right: 75px; /* Positions it just to the left of the play button */
    top: 50%;
    transform: translateY(-50%);
    background: var(--gold, #BF953F); 
    color: #1a1a1a; /* Dark text for contrast */
    padding: 6px 14px;
    border-radius: 20px;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.8rem;
    font-weight: 600;
    white-space: nowrap;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    pointer-events: none; /* Prevents the tooltip from blocking clicks */
    
    /* Starts hidden, fades in after 1.5 seconds, and bounces */
    opacity: 0; 
    animation: fadeInTooltip 0.5s ease forwards 1.5s, pointToButton 2s ease-in-out infinite 1.5s;
}

/* The tiny arrow pointing right */
.music-tooltip::after {
    content: '';
    position: absolute;
    right: -6px;
    top: 50%;
    transform: translateY(-50%);
    border-width: 6px 0 6px 6px;
    border-style: solid;
    border-color: transparent transparent transparent var(--gold, #BF953F);
}

/* The gentle bouncing animation */
@keyframes pointToButton {
    0%, 100% { transform: translate(0, -50%); }
    50% { transform: translate(-8px, -50%); } /* Moves slightly left */
}

@keyframes fadeInTooltip {
    to { opacity: 1; }
}

/* Class to hide the tooltip smoothly once they click play */
.music-tooltip.hide {
    animation: fadeOutTooltip 0.5s ease forwards;
}

@keyframes fadeOutTooltip {
    to { opacity: 0; visibility: hidden; }
}

/* Hide the tooltip on very small mobile screens if it gets too crowded */
/* @media (max-width: 400px) {
    .music-tooltip {
        display: none;
    }
} */

/* =========================================
   FORMAL INVITATION CARD
========================================= */
.invitation-section {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 85svh; /* Takes up 85% of the screen height for a "big screen" feel */
    padding: 40px 20px;
    background-color: var(--soft-dark);
    position: relative;
    z-index: 10;
}

.invitation-card {
    background: rgba(20, 20, 20, 0.6);
    border: 1px solid var(--gold, #c29d5f);
    padding: 60px 40px;
    border-radius: 15px;
    text-align: center;
    max-width: 700px;
    width: 100%;
    box-shadow: 0 10px 40px rgba(0,0,0,0.4);
}

.invite-pre {
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 3px;
    color: var(--accent, #f8f3eb);
    opacity: 0.8;
    margin-bottom: 25px;
}

.invite-hosts {
    font-family: 'Cinzel Decorative', serif; /* Uses your premium gold font */
    color: var(--gold, #c29d5f);
    font-size: 1.3rem;
    margin: 0;
    line-height: 1.2;
    font-weight: 400;
}

.invite-hosts span {
    display: block; 
    font-family: 'Montserrat', sans-serif; 
    font-style: italic;
    font-size: 0.9rem; /* Keep this delicate */
    color: var(--accent, #f8f3eb);
    opacity: 0.7;
    margin: 2px auto; /* Drastically pulls the names closer together */
}

.invite-and {
    font-style: italic;
    color: var(--accent, #f8f3eb);
    opacity: 0.6;
    margin: 30px 0; /* This big gap tells the brain "Here is the next family" */
    font-size: 1rem;
}

.invite-text {
    font-size: 1.1rem;
    line-height: 1.8;
    margin: 35px 0;
    color: var(--accent, #f8f3eb);
    opacity: 0.9;
}

.invite-names {
    font-family: 'Cinzel Decorative', serif;
    font-size: 3rem;
    color: var(--gold, #c29d5f);
    margin: 20px 0;
    font-weight: 600;
}

.invite-names span {
    display: block; /* CRITICAL: Forces the & onto its own centered line */
    font-size: 2.5rem;
    color: var(--accent, #f8f3eb);
    opacity: 0.7;
    margin: 10px auto; /* Creates spacing above and below the & */
}

.invite-closing {
    font-family: 'Montserrat', sans-serif;
    font-style: italic;
    font-size: 1.2rem;
    color: var(--gold, #c29d5f);
    margin-top: 40px;
}

/* --- MOBILE REFINEMENTS --- */
@media (max-width: 768px) {
    .vignette-hero {
        background: linear-gradient(to bottom, rgba(10, 10, 10, 0.1) 0%, rgba(10, 10, 10, 0.65) 55%, #0a0a0a 100%),
                    url('../images/formal-portrait.jpeg') center 5% / cover !important;
        height: 100svh !important; /* CRITICAL: Forces it to fit the exact visible screen, ignoring browser bars */
    }

    /* Pull the text block up and give it bottom breathing room */
    .hero-content {
        padding-top: 5vh !important; /* Reduced from 15vh so it doesn't push down too far */
        padding-bottom: 80px !important; /* Creates a safe zone so it doesn't hit the scroll text */
    }

    .hero-content .pre-title {
        font-size: 0.85rem;
        margin-bottom: 5px;
    }

    /* Shrink names slightly so they fit cleanly */
    .hero-content h1 {
        font-size: 3rem; 
        line-height: 0.9 !important; /* Squeezes the text lines closer together */
        margin: 0 !important; /* Removes default spacing above and below the names */
    }

    .hero-content img, 
    .hero-content .heart {
        margin: 10px auto !important; 
        display: block !important;
        padding-bottom: 5px !important; /* Gives the bottom tip room to breathe so it isn't cut off */
        overflow: visible !important;
    }

    /* The date text */
    .hero-content p:not(.hero-days-text) {
        font-size: 0.8rem !important;
        margin-bottom: 10px !important;
        letter-spacing: 2px; /* Slightly tighter to fit the screen */
    }

    /* The 14 Days to go text */
    .hero-days-text {
        font-size: 1.4rem !important; /* Scaled down slightly to stay on one line safely */
        margin-top: 5px !important;
        margin-bottom: 0 !important;
    }

    /* Ensure Scroll to Discover sits neatly at the very bottom */
    .scroll-indicator {
        bottom: 65px !important; /* Lifts it much higher safely into view */
    }

    .music-control {
        position: fixed !important; /* Locks it to the screen view */
        bottom: 20px !important;
        right: 20px !important; /* Safely inside the right edge */
        transform: scale(0.85) !important; 
        transform-origin: center right !important; /* Ensures it shrinks inward */
        z-index: 9999 !important;
    }

    .music-tooltip {
        right: 60px !important; /* Keeps it right next to your button */
        font-size: 0.7rem !important; /* Slightly smaller for mobile */
        padding: 5px 10px !important;
    }

    /* .music-tooltip {
        right: 65px !important;
    } */

    /* --- Invitation Card Mobile Fixes --- */
    .invitation-section {
        min-height: 90svh;
        padding: 20px 15px;
    }

    .invitation-card {
        padding: 40px 20px;
    }

    .invite-pre {
        font-size: 0.75rem;
        letter-spacing: 2px;
    }

    .invite-hosts {
        font-size: 1.2rem;
    }

    .invite-text {
        font-size: 0.95rem;
        margin: 25px 0;
    }

    .invite-names {
        font-size: 2.2rem;
    }

    .invite-closing {
        font-size: 1.1rem;
    }
}