:root {
    --primary-color: #ffcdd2;
    --secondary-color: #e91e63;
    --text-color: #333;
    --card-bg: #fff;
    --shadow: 0 4px 8px rgba(0,0,0,0.05);
}

/* 1. Dynamic Background Animation */
body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(-45deg, #fce4ec, #ffebee, #ffcdd2, #f8bbd0);
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
    color: var(--text-color);
    margin: 0;
    line-height: 1.6;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
}

@keyframes gradientShift {
    0% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
    100% { background-position: 0% 50%; }
}

/* 2. Pulsating Heart Animation */
.main-heading {
    font-family: 'Dancing Script', cursive;
    font-size: 3.5rem;
    color: var(--secondary-color);
    margin: 0;
    position: relative;
}

.main-heading::after {
    content: "❤️";
    position: absolute;
    top: 5px;
    right: -40px;
    font-size: 0.8em;
    animation: pulse 1s infinite alternate;
}

@keyframes pulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.2); }
}

/* 3. Smooth Content Transition */
.opener-container {
    text-align: center;
    transition: transform 0.8s ease-in-out, opacity 0.8s ease-in-out;
    padding: 20px;
}

.opener-title {
    font-family: 'Dancing Script', cursive;
    font-size: 2.5rem;
    color: var(--secondary-color);
}

.open-button {
    background-color: var(--secondary-color);
    color: var(--card-bg);
    border: none;
    padding: 15px 30px;
    font-size: 1.2rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
    transition: transform 0.2s, background-color 0.2s;
}

.open-button:hover {
    background-color: #d81b60;
    transform: scale(1.05);
}

.content-container {
    max-width: 900px;
    width: 90%;
    transition: opacity 1s ease-in-out, transform 1s ease-in-out;
}

/* Class to hide content before it's revealed */
.hidden {
    opacity: 0;
    transform: translateY(20px);
    display: none;
}

/* General Section Styles with Hover Effect */
section {
    background-color: var(--card-bg);
    padding: 30px;
    border-radius: 15px;
    box-shadow: var(--shadow);
    margin-bottom: 30px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

section:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 16px rgba(0,0,0,0.1);
}

/* Hero section is an exception to the hover since it's the main header */
.hero-section {
    text-align: center;
    padding: 80px 20px;
    background-color: rgba(255, 255, 255, 0.5);
    border-bottom-left-radius: 50% 20%;
    border-bottom-right-radius: 50% 20%;
    box-shadow: 0 4px 10px rgba(0,0,0,0.1);
}

/* Other existing styles */
.future-list {
    list-style: none;
    padding-left: 0;
}

.future-list li {
    padding: 10px 0;
    border-bottom: 1px dashed #eee;
}

.video-wrapper {
    position: relative;
    padding-bottom: 56.25%;
    height: 0;
    overflow: hidden;
    border-radius: 15px;
}

.video-wrapper iframe {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

audio {
    width: 100%;
    margin-top: 15px;
}

.countdown-section {
    text-align: center;
}

.countdown-timer {
    font-size: 2rem;
    font-weight: 600;
    color: #ad1457;
    margin-top: 10px;
}

.countdown-timer span {
    display: inline-block;
    min-width: 50px;
}

.excited-section {
    text-align: center;
}

.reveal-button {
    background-color: #ff8a80;
    color: white;
    border: none;
    padding: 12px 25px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: transform 0.2s;
    margin-top: 15px;
}

.reveal-button:hover {
    transform: scale(1.05);
}

.hidden-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.8s ease-out, opacity 0.8s ease-out;
    opacity: 0;
}

.show-content {
    /* We'll set the height dynamically with JS */
    opacity: 1;
}

.excited-list {
    list-style: none;
    padding: 0;
    margin-top: 20px;
    text-align: left;
}

.excited-list li {
    background-color: #fce4ec;
    padding: 15px;
    border-radius: 10px;
    margin-bottom: 10px;
    transition: background-color 0.2s;
}

.excited-list li:hover {
    background-color: #f8bbd0;
}

.playlist-embed {
    margin-top: 20px;
}

/* Gallery Section Styles */
.gallery-section {
    text-align: center;
}

.gallery-message {
    font-style: italic;
    color: #555;
    margin-bottom: 30px;
}

.photo-grid {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    flex-wrap: wrap;
    gap: 20px;
}

.photo-item {
    text-align: center;
    transition: transform 0.3s ease-in-out;
}

.photo-item:hover {
    transform: scale(1.05);
}

.photo-item img {
    max-width: 100%;
    height: auto;
    border-radius: 15px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.1);
    border: 3px solid #ffcdd2;
}

.photo-caption {
    display: block;
    margin-top: 10px;
    font-size: 0.9em;
    color: #777;
}

/* Make photos slightly different sizes for a creative layout */
.photo-item:nth-child(1) img { width: 220px; }
.photo-item:nth-child(2) img { width: 250px; }
.photo-item:nth-child(3) img { width: 270px; }

/* Responsive adjustments */
@media (max-width: 768px) {
    .photo-grid {
        flex-direction: column;
        align-items: center;
    }
    .photo-item img {
        width: 100% !important;
        max-width: 250px;
    }
}

/* Cake Animation Styles */
.cake-container {
    display: flex;
    justify-content: center;
    align-items: flex-end;
    padding-top: 40px;
}

.cake {
    position: relative;
    width: 250px;
    height: 200px;
    margin-bottom: 20px;
    animation: cakePopUp 1s ease-out forwards;
}

@keyframes cakePopUp {
    0% { transform: translateY(100px) scale(0.5); opacity: 0; }
    100% { transform: translateY(0) scale(1); opacity: 1; }
}

.plate {
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 280px;
    height: 25px;
    background: #ccc;
    border-radius: 50%;
    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.15);
}

.layer {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    background: #f8e1eb;
    border-radius: 50% / 100% 100% 0 0;
    box-shadow: 0 -5px 5px rgba(0,0,0,0.05) inset;
}

.layer-bottom {
    bottom: 0;
    width: 250px;
    height: 60px;
}

.layer-middle {
    bottom: 50px;
    width: 220px;
    height: 50px;
}

.layer-top {
    bottom: 90px;
    width: 190px;
    height: 40px;
}

.icing {
    position: absolute;
    bottom: 120px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 30px;
    background: #f8c1d9;
    border-radius: 50%;
}

/* Sprinkles */
.icing::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 100%;
    background-image:
        radial-gradient(circle, #ffeb3b 5px, transparent 0),
        radial-gradient(circle, #8bc34a 5px, transparent 0),
        radial-gradient(circle, #03a9f4 5px, transparent 0),
        radial-gradient(circle, #e91e63 5px, transparent 0);
    background-size: 20px 20px;
    background-position:
        5% 20%, 30% 60%, 55% 30%, 80% 80%;
    animation: sprinkleAnimate 2s infinite linear;
}

@keyframes sprinkleAnimate {
    from { background-position: 0% 0%; }
    to { background-position: 100% 100%; }
}

/* Drips on the side */
.drip {
    position: absolute;
    background: #f8c1d9;
    width: 5px;
    height: 10px;
    border-radius: 0 0 50% 50%;
    z-index: 5;
    animation: dripFall 1s linear infinite;
}

.drip1 { left: 40px; animation-delay: 0.2s; }
.drip2 { left: 80px; animation-delay: 0.5s; }
.drip3 { left: 120px; animation-delay: 0.8s; }
.drip4 { left: 160px; animation-delay: 1.1s; }
.drip5 { left: 200px; animation-delay: 1.4s; }
.drip6 { left: 240px; animation-delay: 1.7s; }

@keyframes dripFall {
    0% { transform: translateY(0); opacity: 1; }
    100% { transform: translateY(10px); opacity: 0; }
}

/* Multiple Candles */
.candle-group {
    position: absolute;
    bottom: 135px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 30px;
    z-index: 6;
}

.candle {
    position: relative;
    width: 10px;
    height: 60px;
    background: #ffcc00;
    border-radius: 5px;
    box-shadow: 0 0 5px #ffcc00;
}

.flame {
    position: absolute;
    top: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 15px;
    height: 25px;
    background: #ff9900;
    border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
    animation: flameFlicker 0.4s infinite alternate;
    transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

@keyframes flameFlicker {
    0% { transform: scale(1) translateX(-50%); opacity: 0.9; }
    50% { transform: scale(1.2) translateX(-50%); opacity: 1; }
    100% { transform: scale(1) translateX(-50%); opacity: 0.9; }
}

.flame-off {
    opacity: 0 !important;
    transform: scale(0.1) !important;
}



/* Balloons Animation */
.balloons-container {
    position: fixed;
    bottom: -100px;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    display: flex;
    justify-content: space-around;
    align-items: flex-end;
}

.balloon {
    width: 80px;
    height: 100px;
    background: #ffcdd2;
    border-radius: 50% 50% 50% 50% / 60% 60% 40% 40%;
    box-shadow: inset -5px -5px 10px rgba(0,0,0,0.1);
    position: relative;
    animation: balloonFloat 10s ease-in infinite;
}

.balloon::after {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 0;
    height: 0;
    border-left: 10px solid transparent;
    border-right: 10px solid transparent;
    border-top: 15px solid #ffcdd2;
}

.balloon:nth-child(2) { background: #ff8a80; animation-duration: 12s; }
.balloon:nth-child(3) { background: #e91e63; animation-duration: 9s; }
.balloon:nth-child(4) { background: #ffeb3b; animation-duration: 11s; }
.balloon:nth-child(5) { background: #ad1457; animation-duration: 13s; }

@keyframes balloonFloat {
    0% { transform: translateY(0) rotate(0deg); opacity: 1; }
    100% { transform: translateY(-1200px) rotate(360deg); opacity: 0; }
}