* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Quicksand', sans-serif;
    background: linear-gradient(135deg, #ffd1dc 0%, #ffb6c1 25%, #ff69b4 50%, #ff1493 75%, #c71585 100%);
    background-size: 200% 200%;
    animation: gradientShift 20s ease infinite;
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden;
    position: relative;
    -webkit-tap-highlight-color: transparent;
    touch-action: manipulation;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 50%, rgba(255, 182, 193, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 105, 180, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(255, 192, 203, 0.2) 0%, transparent 50%);
    pointer-events: none;
    z-index: 1;
}

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

.floating-hearts {
    position: fixed;
    width: 100%;
    height: 100%;
    top: 0;
    left: 0;
    pointer-events: none;
    z-index: 2;
}

.floating-hearts span {
    position: absolute;
    font-size: 2em;
    opacity: 0.4;
    animation: floatUp 15s infinite ease-in;
}

.floating-hearts span:nth-child(1) {
    left: 10%;
    animation-delay: 0s;
}

.floating-hearts span:nth-child(2) {
    left: 30%;
    animation-delay: 3s;
}

.floating-hearts span:nth-child(3) {
    left: 50%;
    animation-delay: 6s;
}

.floating-hearts span:nth-child(4) {
    left: 70%;
    animation-delay: 9s;
}

.floating-hearts span:nth-child(5) {
    left: 90%;
    animation-delay: 12s;
}

@keyframes floatUp {
    0% {
        bottom: -10%;
        transform: translateX(0) rotate(0deg);
        opacity: 0;
    }
    10% {
        opacity: 0.4;
    }
    90% {
        opacity: 0.4;
    }
    100% {
        bottom: 110%;
        transform: translateX(50px) rotate(360deg);
        opacity: 0;
    }
}

.container {
    text-align: center;
    padding: 50px 40px;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 25px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.15);
    backdrop-filter: blur(10px);
    max-width: 550px;
    width: 90%;
    animation: fadeIn 1.2s ease-in;
    position: relative;
    z-index: 10;
    border: 1px solid rgba(255, 255, 255, 0.8);
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.letter-header {
    margin-bottom: 20px;
}

.to-text {
    font-family: 'Dancing Script', cursive;
    font-size: 1.8em;
    color: #d63384;
    font-weight: 400;
    margin-bottom: 10px;
}

.title {
    font-family: 'Dancing Script', cursive;
    font-size: 2.8em;
    color: #d63384;
    margin-bottom: 15px;
    font-weight: 700;
    line-height: 1.3;
}

.subtitle {
    font-size: 1.1em;
    color: #666;
    margin-bottom: 35px;
    font-weight: 300;
    font-style: italic;
}

.buttons-container {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
    margin-top: 30px;
    margin-bottom: 20px;
}

.btn {
    padding: 18px 45px;
    font-size: 1.3em;
    border: none;
    border-radius: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    font-family: 'Quicksand', sans-serif;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
    position: relative;
    overflow: hidden;
    -webkit-tap-highlight-color: transparent;
    user-select: none;
    -webkit-user-select: none;
}

.btn-yes {
    background: linear-gradient(135deg, #ff6b9d 0%, #c06c84 100%);
    color: white;
    position: relative;
    display: flex;
    align-items: center;
    gap: 10px;
}

.btn-yes:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 30px rgba(255, 107, 157, 0.4);
}

.btn-yes .heart-icon {
    display: inline-block;
    animation: heartPulse 1.5s ease infinite;
}

@keyframes heartPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

.btn-no {
    background: #e0e0e0;
    color: #666;
    position: relative;
    transition: all 0.1s ease;
}

.hint {
    font-size: 0.9em;
    color: #999;
    font-style: italic;
    margin-top: 15px;
}

.celebration {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #ffd1dc 0%, #ffb6c1 25%, #ff69b4 50%, #ff1493 75%, #c71585 100%);
    background-size: 200% 200%;
    animation: gradientShift 20s ease infinite;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1000;
}

.celebration::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 50%, rgba(255, 182, 193, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(255, 105, 180, 0.3) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(255, 192, 203, 0.2) 0%, transparent 50%);
    pointer-events: none;
}

.celebration-content {
    text-align: center;
    padding: 60px 50px;
    background: rgba(255, 255, 255, 0.98);
    border-radius: 25px;
    box-shadow: 0 15px 50px rgba(0, 0, 0, 0.15);
    max-width: 650px;
    width: 90%;
    position: relative;
    overflow: hidden;
    border: 1px solid rgba(255, 255, 255, 0.8);
    animation: celebrationAppear 0.8s ease-out;
}

@keyframes celebrationAppear {
    0% {
        opacity: 0;
        transform: scale(0.8);
    }
    100% {
        opacity: 1;
        transform: scale(1);
    }
}

.celebration-title {
    font-family: 'Dancing Script', cursive;
    font-size: 3em;
    color: #d63384;
    margin-bottom: 30px;
    font-weight: 700;
    line-height: 1.3;
}

.tenor-gif-embed {
    max-width: 400px;
    width: 100%;
    margin: 30px auto;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    animation: float 3s ease-in-out infinite;
}

.tenor-gif-embed iframe {
    border-radius: 15px;
}

@keyframes float {
    0%, 100% { transform: translateY(0px); }
    50% { transform: translateY(-15px); }
}

.celebration-text {
    font-size: 1.5em;
    color: #d63384;
    margin: 20px 0;
    font-weight: 600;
}

.celebration-message {
    font-size: 1.2em;
    color: #666;
    margin: 15px 0;
    font-weight: 300;
    line-height: 1.6;
}

.love-text {
    font-family: 'Dancing Script', cursive;
    font-size: 2.2em;
    color: #d63384;
    margin-top: 30px;
    font-weight: 700;
}

/* Animazione per i cuori che cadono */
@keyframes heartFall {
    0% {
        transform: translateY(-100px) translateX(0) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(calc(100vh + 100px)) translateX(calc(var(--random-x, 100px))) rotate(360deg);
        opacity: 0;
    }
}

@keyframes confettiFall {
    0% {
        transform: translateY(-100px) translateX(0) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(calc(100vh + 100px)) translateX(calc(var(--random-x, -100px))) rotate(360deg);
        opacity: 0;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .to-text {
        font-size: 1.5em;
    }
    
    .title {
        font-size: 2em;
    }
    
    .subtitle {
        font-size: 1em;
    }
    
    .btn {
        padding: 15px 35px;
        font-size: 1.1em;
    }
    
    .celebration-title {
        font-size: 1.8em;
        line-height: 1.2;
    }
    
    .celebration-content {
        padding: 40px 30px;
    }
    
    .tenor-gif-embed {
        max-width: 100%;
        margin: 20px auto;
    }
    
    .celebration-text {
        font-size: 1.2em;
    }
    
    .celebration-message {
        font-size: 0.95em;
    }
    
    .love-text {
        font-size: 1.6em;
    }
    
    .floating-hearts span {
        font-size: 1.5em;
    }
}