body {
    margin: 0;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(-45deg, #ff9a9e, #fad0c4, #fbc2eb, #a18cd1);
    background-size: 400% 400%;
    animation: gradientBG 12s ease infinite;
    font-family: 'Poppins', sans-serif;
}

.welcome-box {
    text-align: center;

    background: rgba(255,255,255,0.2);

    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);

    border: 1px solid rgba(255,255,255,0.3);

    padding: 40px;

    border-radius: 20px;

    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
}

h1 {
    color: #ff4d6d;
}

p {
    font-size: 18px;
}

button {

    background: #ff4d6d;
    color: white;

    border: none;

    padding: 14px 28px;

    border-radius: 50px;

    font-size: 16px;

    cursor: pointer;

    transition: 0.4s;

    box-shadow:
        0 0 10px #ff4d6d,
        0 0 20px #ff4d6d;

}

button:hover {

    transform: scale(1.08);

    box-shadow:
        0 0 20px #ff4d6d,
        0 0 40px #ff4d6d,
        0 0 60px #ff4d6d;

}

button:hover {
    background: #c9184a;
}
.password-box {
    display: none;
    text-align: center;
    background: rgba(255,255,255,0.2);
backdrop-filter: blur(15px);
-webkit-backdrop-filter: blur(15px);
border: 1px solid rgba(255,255,255,0.3);
    padding: 40px;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

input {
    padding: 12px;
    width: 200px;
    border-radius: 10px;
    border: 1px solid #ccc;
    margin: 15px;
}
.loader {
    width: 50px;
    height: 50px;
    border: 6px solid #ffd6e0;
    border-top: 6px solid #ff4d6d;
    border-radius: 50%;
    margin: auto;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}
.letter-box {
    display: none;
    max-width: 500px;
    text-align: center;
    background: rgba(255,255,255,0.2);
backdrop-filter: blur(15px);
-webkit-backdrop-filter: blur(15px);
border: 1px solid rgba(255,255,255,0.3);
    padding: 35px;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    line-height: 1.6;
}

.letter-box h1 {
    color: #ff4d6d;
}

.letter-box p {
    font-size: 17px;
}
.gallery-box {
    display: none;
    text-align: center;
    background: rgba(255,255,255,0.2);
backdrop-filter: blur(15px);
-webkit-backdrop-filter: blur(15px);
border: 1px solid rgba(255,255,255,0.3);
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.gallery {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    justify-content: center;
}

.gallery img {
    width: 180px;
    height: 180px;
    object-fit: cover;
    border-radius: 15px;
    transition: 0.5s;
}

.gallery img:hover {
    transform: scale(1.1);
}
.timeline-box {
    display: none;
    max-width: 600px;
    background: rgba(255,255,255,0.2);
backdrop-filter: blur(15px);
-webkit-backdrop-filter: blur(15px);
border: 1px solid rgba(255,255,255,0.3);
    padding: 15px;
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    text-align: center;
}

.timeline {
    margin-top: 20px;
}

.memory {
    background: #ffe5ec;
    padding: 20px;
    margin: 15px 0;
    border-radius: 15px;
    transition: 0.5s;
}

.memory:hover {
    transform: translateY(-8px);
}

.memory h2 {
    color: #ff4d6d;
}
.reasons-box {
    display: none;
    max-width: 600px;
    background: rgba(255,255,255,0.2);
backdrop-filter: blur(15px);
-webkit-backdrop-filter: blur(15px);
border: 1px solid rgba(255,255,255,0.3);
    padding: 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.reason {
    background: #ffd6e0;
    padding: 15px;
    margin: 15px;
    border-radius: 15px;
    font-size: 18px;
    transition: 0.4s;
}

.reason:hover {
    transform: scale(1.05);
}
.scratch-box {
    display: none;
    text-align: center;
    background: rgba(255,255,255,0.2);
backdrop-filter: blur(15px);
-webkit-backdrop-filter: blur(15px);
border: 1px solid rgba(255,255,255,0.3);
    padding: 30px;
    border-radius: 20px;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.scratch-card {
    width: 300px;
    height: 150px;
    background: linear-gradient(45deg, #ff9a9e, #fad0c4);
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 20px;
    cursor: pointer;
    margin: auto;
    font-size: 22px;
    color: white;
    transition: 0.5s;
}

.scratch-card:hover {
    transform: scale(1.05);
}
.game-box {
    display: none;
    background: rgba(255,255,255,0.2);
backdrop-filter: blur(15px);
-webkit-backdrop-filter: blur(15px);
border: 1px solid rgba(255,255,255,0.3);
    padding: 30px;
    border-radius: 20px;
    text-align: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.game {
    display: grid;
    grid-template-columns: repeat(3, 100px);
    gap: 15px;
    justify-content: center;
}

.card {
    width: 100px;
    height: 100px;
    background: #ffb3c6;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 15px;
    font-size: 35px;
    cursor: pointer;
    transition: 0.4s;
}

.card:hover {
    transform: scale(1.1);
}
.final-box {
    display: none;
    max-width: 600px;
    background: rgba(255,255,255,0.2);
backdrop-filter: blur(15px);
-webkit-backdrop-filter: blur(15px);
border: 1px solid rgba(255,255,255,0.3);
    padding: 40px;
    border-radius: 25px;
    text-align: center;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
}

.final-box h1 {
    color: #ff4d6d;
}

.hearts {
    font-size: 35px;
    animation: float 2s infinite;
}

footer {
    margin-top: 30px;
    font-size: 15px;
}

@keyframes float {
    50% {
        transform: translateY(-15px);
    }
}
.main-footer {
    position: fixed;
    bottom: 10px;
    width: 100%;
    text-align: center;
    font-size: 14px;
    color: #555;
    font-family: Arial, sans-serif;
}

.welcome-box,
.password-box,
.letter-box,
.gallery-box,
.timeline-box,
.reasons-box,
.scratch-box,
.game-box,
.final-box {
    animation: fadeSlide 1s ease forwards;
}

@keyframes fadeSlide {

    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }

}

.welcome-box,
.password-box,
.letter-box,
.gallery-box,
.timeline-box,
.reasons-box,
.scratch-box,
.game-box,
.final-box {
    transition: all 0.8s ease;
}
/* Floating Hearts */

.floating-hearts {
    position: fixed;
    inset: 0;
    pointer-events: none;
    overflow: hidden;
    z-index: -1;
}

.floating-hearts span {
    position: absolute;
    bottom: -60px;
    font-size: 30px;
    animation: floatHeart 12s linear infinite;
    opacity: 0.8;
}

.floating-hearts span:nth-child(1) { left: 5%; animation-delay: 0s; }
.floating-hearts span:nth-child(2) { left: 18%; animation-delay: 2s; }
.floating-hearts span:nth-child(3) { left: 32%; animation-delay: 4s; }
.floating-hearts span:nth-child(4) { left: 46%; animation-delay: 1s; }
.floating-hearts span:nth-child(5) { left: 60%; animation-delay: 5s; }
.floating-hearts span:nth-child(6) { left: 74%; animation-delay: 3s; }
.floating-hearts span:nth-child(7) { left: 88%; animation-delay: 6s; }
.floating-hearts span:nth-child(8) { left: 96%; animation-delay: 2.5s; }

@keyframes floatHeart {
    0% {
        transform: translateY(0) scale(0.7);
        opacity: 0;
    }

    15% {
        opacity: 1;
    }

    100% {
        transform: translateY(-110vh) scale(1.3) rotate(360deg);
        opacity: 0;
    }
}
@keyframes gradientBG {
    0% {
        background-position: 0% 50%;
    }

    50% {
        background-position: 100% 50%;
    }

    100% {
        background-position: 0% 50%;
    }
}
.confetti {
    font-size: 35px;
    margin-top: 20px;
    animation: confettiBounce 2s ease-in-out infinite;
}

@keyframes confettiBounce {

    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-15px) rotate(8deg);
    }

    100% {
        transform: translateY(0px);
    }

}
body {
    background: linear-gradient(135deg, #ff9a9e, #fad0c4, #a18cd1);
    font-family: 'Poppins', sans-serif;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
}


.letter-container {
    text-align: center;
    cursor: pointer;
}


.envelope {
    font-size: 100px;
    animation: bounce 1.5s infinite;
}


.letter {
    width: 320px;
    padding: 30px;
    background: white;
    border-radius: 20px;
    box-shadow: 0 15px 40px rgba(0,0,0,0.2);
    animation: openLetter 1s ease;
}


.letter h1 {
    color: #ff4b7d;
}


.letter p {
    line-height: 1.7;
    color: #555;
}


@keyframes bounce {

    50% {
        transform: translateY(-15px);
    }

}


@keyframes openLetter {

    from {
        transform: rotateX(90deg);
        opacity:0;
    }

    to {
        transform: rotateX(0);
        opacity:1;
    }

}