:root {
    --primary: #ff4d94;
    --primary-light: #ff80b3;
    --primary-dark: #cc0052;
    --secondary: #fce4ec;
    --text-dark: #2d3436;
    --text-light: #636e72;
    --white: #ffffff;
    --glass: rgba(255, 255, 255, 0.8);
    --glass-border: rgba(255, 255, 255, 0.3);
    --gradient: linear-gradient(135deg, #ff4d94 0%, #ff9a9e 100%);
    --shadow: 0 10px 30px rgba(255, 77, 148, 0.2);
}

/* Global Overlay Effects */
body::before {
    content: "";
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('https://grainy-gradients.vercel.app/noise.svg');
    opacity: 0.05;
    z-index: 9999;
    pointer-events: none;
}

body {
    margin: 0;
    font-family: 'Outfit', sans-serif;
    background-color: #050505;
    color: var(--text-light);
    overflow-x: hidden;
    line-height: 1.6;
}

/* Hero Section - Premium Cinematic */
.hero {
    height: 100vh;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    position: relative;
    overflow: hidden;
    background: #050505;
    transform-style: preserve-3d;
    perspective: 1000px;
}

/* Sophisticated Lighting & Vignette */
.hero::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, transparent 10%, rgba(0,0,0,0.6) 60%, rgba(0,0,0,0.95) 100%);
    z-index: 5;
    pointer-events: none;
}

/* Slideshow Progress */
.slideshow-progress {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: rgba(255,255,255,0.05);
    z-index: 1000;
}

.progress-bar {
    width: 0%;
    height: 100%;
    background: var(--gradient);
    box-shadow: 0 0 10px var(--primary);
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 3.5s cubic-bezier(0.45, 0.05, 0.55, 0.95);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    transform: scale(1.05);
    filter: brightness(0.85) contrast(1.1);
    image-rendering: high-quality;
    -webkit-backface-visibility: hidden;
    backface-visibility: hidden;
    will-change: transform, opacity;
}

.slide.active {
    opacity: 1;
    filter: brightness(1) contrast(1);
    animation: cinematicZoom 20s cubic-bezier(0.2, 0.4, 0.2, 1) forwards;
}

@keyframes cinematicZoom {
    0% { transform: scale(1.05) translate3d(0,0,0); }
    100% { transform: scale(1.3) translate3d(0,0,0); }
}

.hero-content {
    position: relative;
    z-index: 20;
    padding: 0 10%;
    max-width: 1000px;
    animation: movieTextReveal 5s cubic-bezier(0.2, 0.8, 0.2, 1) forwards;
    transition: transform 0.2s ease-out; /* For parallax */
}

@keyframes movieTextReveal {
    0% { opacity: 0; transform: translateY(50px) scale(0.98); }
    100% { opacity: 1; transform: translateY(0) scale(1); }
}

.hero h1 {
    font-size: clamp(2.2rem, 8vw, 4.5rem);
    color: #fff;
    text-shadow: 0 0 30px rgba(255,255,255,0.2);
    margin-bottom: 1rem;
    font-weight: 700;
    line-height: 1.1;
}

.text-gradient {
    background: linear-gradient(135deg, #ff4f81, #c084fc, #ff4f81);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    filter: drop-shadow(0 0 15px rgba(255, 79, 129, 0.5));
    position: relative;
    animation: shimmer 4s linear infinite, breathingGlow 3s ease-in-out infinite;
}

@keyframes breathingGlow {
    0%, 100% { filter: drop-shadow(0 0 15px rgba(255, 79, 129, 0.5)); }
    50% { filter: drop-shadow(0 0 30px rgba(192, 132, 252, 0.8)); }
}

@keyframes shimmer {
    to { background-position: 200% center; }
}

.hero p {
    font-size: clamp(0.9rem, 3vw, 1.2rem);
    color: rgba(255, 255, 255, 0.6);
    letter-spacing: 5px;
    text-transform: uppercase;
    font-weight: 300;
    margin-top: 10px;
}


/* Animations */
@keyframes float {
    0%, 100% { transform: translateY(0) rotate(0deg); }
    50% { transform: translateY(-10px) rotate(5deg); }
}

/* Advanced Reveal Animations */
.reveal, .reveal-left, .reveal-right, .reveal-zoom {
    opacity: 0;
    transition: all 1s cubic-bezier(0.4, 0, 0.2, 1);
}

.reveal { transform: translateY(40px); }
.reveal-left { transform: translateX(-60px); }
.reveal-right { transform: translateX(60px); }
.reveal-zoom { transform: scale(0.85); }

.reveal.active, .reveal-left.active, .reveal-right.active, .reveal-zoom.active {
    opacity: 1;
    transform: translate(0) scale(1);
}

/* Floating Hearts Styling */
.heart {
    position: fixed;
    color: #ff4d94;
    font-size: 1.5rem;
    pointer-events: none;
    z-index: 999;
    animation: heartFly 4s linear forwards;
    opacity: 0.6;
}

@keyframes heartFly {
    0% { transform: translateY(100vh) scale(0.5); opacity: 0; }
    10% { opacity: 0.6; }
    100% { transform: translateY(-100px) translateX(var(--x-move)) scale(1.2); opacity: 0; }
}


/* Audio Visualizer */
.visualizer-container {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    align-items: flex-end;
    gap: 3px;
    height: 30px;
    z-index: 100;
}

.bar {
    width: 3px;
    background: var(--primary);
    border-radius: 2px;
    animation: visualize 0.5s ease-in-out infinite alternate;
}

@keyframes visualize {
    from { height: 5px; opacity: 0.3; }
    to { height: 25px; opacity: 1; }
}

.bar:nth-child(2) { animation-delay: 0.1s; }
.bar:nth-child(3) { animation-delay: 0.2s; }
.bar:nth-child(4) { animation-delay: 0.3s; }
.bar:nth-child(5) { animation-delay: 0.4s; }

/* Letter Trigger */
.letter-trigger {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 60px;
    height: 60px;
    background: var(--gradient);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    cursor: pointer;
    z-index: 1000;
    box-shadow: 0 10px 25px rgba(255, 77, 148, 0.4);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.letter-trigger:hover {
    transform: scale(1.1) rotate(15deg);
}

.letter-trigger .tooltip {
    position: absolute;
    right: 75px;
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.75rem;
    color: #fff;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: 0.3s;
    border: 1px solid rgba(255,255,255,0.1);
}

.letter-trigger:hover .tooltip {
    opacity: 1;
    transform: translateX(-5px);
}

/* Letter Modal */
.modal {
    display: none;
    position: fixed;
    top: 0; left: 0;
    width: 100%; height: 100%;
    background: rgba(0,0,0,0.85);
    z-index: 2000;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(8px);
}

.modal-content {
    background: rgba(255, 255, 255, 0.05);
    padding: 40px;
    width: 90%;
    max-width: 500px;
    border-radius: 30px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    position: relative;
    text-align: center;
    color: #fff;
    box-shadow: 0 20px 50px rgba(0,0,0,0.5);
}

.letter-body h2 {
    font-weight: 300;
    letter-spacing: 3px;
    margin-bottom: 20px;
    color: var(--primary);
}

.letter-body p {
    font-weight: 300;
    line-height: 1.8;
    margin-bottom: 15px;
    color: rgba(255,255,255,0.8);
}

.letter-footer {
    margin-top: 30px;
    font-style: italic;
    color: var(--primary);
}

.close-modal {
    position: absolute;
    top: 20px; right: 25px;
    font-size: 1.5rem;
    cursor: pointer;
    color: rgba(255,255,255,0.5);
}

/* Ambient Lens Flare */
.lens-flare {
    position: absolute;
    top: -20%; left: -20%;
    width: 60%; height: 60%;
    background: radial-gradient(circle, rgba(255,255,255,0.05) 0%, transparent 70%);
    pointer-events: none;
    z-index: 6;
    animation: flareMove 20s infinite alternate linear;
}

@keyframes flareMove {
    from { transform: translate(0, 0); }
    to { transform: translate(40vw, 40vh); }
}

/* Sparkle Cursor */
.sparkle {
    position: fixed;
    width: 10px; height: 10px;
    background: #fff;
    border-radius: 50%;
    pointer-events: none;
    z-index: 9999;
    box-shadow: 0 0 10px #fff, 0 0 20px var(--primary);
    animation: sparkleOut 1s forwards;
}

@keyframes sparkleOut {
    to { transform: scale(0); opacity: 0; }
}

/* Lightbox Modal */
.lightbox {
    display: none;
    position: fixed;
    z-index: 2000;
    padding-top: 50px;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.9);
    backdrop-filter: blur(5px);
}

.lightbox-content {
    margin: auto;
    display: block;
    width: 80%;
    max-width: 900px;
    border-radius: 20px;
    box-shadow: 0 0 50px rgba(255, 77, 148, 0.3);
    animation: zoom 0.6s;
}

@keyframes zoom {
    from {transform:scale(0.5); opacity: 0;}
    to {transform:scale(1); opacity: 1;}
}

.close {
    position: absolute;
    top: 30px;
    right: 50px;
    color: #f1f1f1;
    font-size: 40px;
    font-weight: bold;
    transition: 0.3s;
    cursor: pointer;
}

.close:hover {
    color: var(--primary);
}

.gallery-item {
    cursor: pointer;
}

/* Mobile Optimization */
@media (max-width: 768px) {
    .hero {
        padding: 0 10%;
    }

    .hero h1 {
        font-size: 2.5rem;
        white-space: normal; /* Wrap text on mobile */
        line-height: 1.2;
    }

    .hero p {
        font-size: 1rem;
        margin-bottom: 1.5rem;
    }

    .music-controller {
        bottom: 20px;
        right: 20px;
        width: 45px;
        height: 45px;
    }

    .heart {
        font-size: 1rem !important; /* Smaller hearts for mobile */
    }
}
