* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins', sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    overflow-x: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

/* Starry background */
.stars {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.stars::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: transparent url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='100' height='100' viewBox='0 0 100 100'%3E%3Cg fill-opacity='0.1'%3E%3Cpolygon fill='%23fff' points='50 0 60 40 100 50 60 60 50 100 40 60 0 50 40 40'/%3E%3C/g%3E%3C/svg%3E") repeat;
    animation: twinkle 3s ease-in-out infinite alternate;
}

@keyframes twinkle {
    0% { opacity: 0.3; }
    100% { opacity: 0.8; }
}

.container {
    text-align: center;
    position: relative;
    z-index: 1;
    padding: 20px;
    max-width: 800px;
    width: 100%;
}

/* Heart animations */
.heart-animation {
    position: relative;
    margin-bottom: 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 20px;
}

.heart {
    width: 50px;
    height: 45px;
    position: relative;
    display: inline-block;
    animation: heartbeat 2s ease-in-out infinite;
}

.heart:before,
.heart:after {
    content: '';
    width: 26px;
    height: 40px;
    position: absolute;
    left: 25px;
    top: 0;
    background: #ff6b9d;
    border-radius: 25px 25px 0 0;
    transform: rotate(-45deg);
    transform-origin: 0 100%;
}

.heart:after {
    left: 0;
    transform: rotate(45deg);
    transform-origin: 100% 100%;
}

.main-heart {
    transform: scale(1.2);
}

.main-heart:before,
.main-heart:after {
    background: #ff1744;
}

.heart-2 {
    animation-delay: 0.5s;
}

.heart-3 {
    animation-delay: 1s;
}

@keyframes heartbeat {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.15);
    }
}

/* Message styling */
.message-container {
    margin: 2rem 0;
}

.main-title {
    font-family: 'Dancing Script', cursive;
    font-size: 4rem;
    font-weight: 700;
    color: #fff;
    text-shadow: 3px 3px 6px rgba(0,0,0,0.3);
    margin-bottom: 0.5rem;
    animation: fadeInUp 1.5s ease-out;
}

.name-title {
    font-family: 'Dancing Script', cursive;
    font-size: 3.5rem;
    font-weight: 600;
    color: #ffc1cc;
    text-shadow: 2px 2px 4px rgba(0,0,0,0.3);
    margin-bottom: 1rem;
    animation: fadeInUp 1.5s ease-out 0.5s both;
}

.sub-message {
    font-size: 1.3rem;
    color: #fff;
    opacity: 0.95;
    animation: fadeInUp 1.5s ease-out 1s both;
    font-weight: 300;
}

/* Interactive section */
.interactive-section {
    margin-top: 3rem;
}

.love-button {
    background: linear-gradient(45deg, #ff6b9d, #ff1744);
    border: none;
    padding: 18px 35px;
    border-radius: 50px;
    color: white;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 8px 25px rgba(255, 107, 157, 0.4);
    font-family: 'Poppins', sans-serif;
}

.love-button:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 35px rgba(255, 107, 157, 0.6);
}

.love-button:active {
    transform: translateY(0);
}

.button-heart {
    position: absolute;
    right: -10px;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.5rem;
    animation: bounce 2s infinite;
}

.message-display {
    margin-top: 2rem;
    font-size: 1.4rem;
    color: #fff;
    min-height: 3rem;
    opacity: 0;
    transition: all 0.6s ease;
    font-weight: 400;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 20px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.message-display.show {
    opacity: 1;
    transform: translateY(-10px);
}

/* Letter section */
.letter-section {
    margin-top: 4rem;
    opacity: 0;
    transform: translateY(30px);
    transition: all 1s ease;
}

.letter-section.show {
    opacity: 1;
    transform: translateY(0);
}

.letter-container {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255, 255, 255, 0.3);
}

.letter-header {
    font-family: 'Dancing Script', cursive;
    font-size: 2rem;
    color: #ff1744;
    margin-bottom: 1.5rem;
    font-weight: 600;
}

.letter-content {
    font-size: 1.1rem;
    line-height: 1.8;
    color: #333;
    text-align: left;
    font-weight: 400;
}

/* Floating hearts */
.floating-hearts {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 0;
}

.floating-heart {
    position: absolute;
    font-size: 2rem;
    animation: float 8s linear infinite;
    opacity: 0.8;
}

@keyframes float {
    0% {
        transform: translateY(100vh) rotate(0deg) scale(0);
        opacity: 0;
    }
    10% {
        opacity: 1;
        transform: translateY(90vh) rotate(36deg) scale(1);
    }
    90% {
        opacity: 1;
        transform: translateY(10vh) rotate(324deg) scale(1);
    }
    100% {
        transform: translateY(-10vh) rotate(360deg) scale(0);
        opacity: 0;
    }
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes bounce {
    0%, 20%, 50%, 80%, 100% {
        transform: translateY(-50%);
    }
    40% {
        transform: translateY(-60%);
    }
    60% {
        transform: translateY(-55%);
    }
}

/* Responsive design */
@media (max-width: 768px) {
    .main-title {
        font-size: 3rem;
    }
    
    .name-title {
        font-size: 2.5rem;
    }
    
    .sub-message {
        font-size: 1.1rem;
    }
    
    .heart {
        width: 35px;
        height: 32px;
    }
    
    .heart:before,
    .heart:after {
        width: 18px;
        height: 28px;
        left: 17px;
    }
    
    .heart:after {
        left: 0;
    }
    
    .letter-container {
        padding: 1.5rem;
        margin: 0 10px;
    }
    
    .letter-header {
        font-size: 1.6rem;
    }
    
    .letter-content {
        font-size: 1rem;
    }
}

@media (max-width: 480px) {
    .main-title {
        font-size: 2.5rem;
    }
    
    .name-title {
        font-size: 2rem;
    }
    
    .love-button {
        padding: 15px 25px;
        font-size: 1rem;
    }
}
