body {
    margin: 0;
    padding: 0;
    background: #111;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    overflow: hidden;
}

.card {
    width: 360px;
    height: 640px;
    background: #fff;
    border-radius: 30px;
    box-shadow: 0 20px 40px rgba(0,0,0,0.5);
    position: relative;
    overflow: hidden;
    display: flex;
    justify-content: center;
    align-items: center;
}

.animation-container {
    width: 100%;
    height: 100%;
    position: relative;
}

.character {
    position: absolute;
    bottom: 120px;
    left: 40px;
    width: 90px;
    height: 90px;
    z-index: 10;
    animation: moveHand 3s infinite ease-in-out;
}

.character-svg {
    width: 100%;
    height: 100%;
}

.hand {
    transform-origin: 70px 55px;
    animation: drawMotion 0.6s infinite alternate ease-in-out;
}

@keyframes drawMotion {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(-15deg) translateY(-2px); }
}

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

.heart-grid {
    position: absolute;
    top: 60px;
    left: 30px;
    width: 300px;
    height: 300px;
}

.small-heart {
    position: absolute;
    width: 16px;
    height: 16px;
    background-color: #ff4757;
    transform: rotate(45deg);
    opacity: 0;
    animation: popIn 0.4s forwards cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.small-heart::before,
.small-heart::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    background-color: #ff4757;
    border-radius: 50%;
}

.small-heart::before {
    top: -8px;
    left: 0;
}

.small-heart::after {
    top: 0;
    left: -8px;
}

@keyframes popIn {
    0% {
        transform: scale(0) rotate(45deg);
        opacity: 0;
    }
    80% {
        transform: scale(1.2) rotate(45deg);
        opacity: 1;
    }
    100% {
        transform: scale(1) rotate(45deg);
        opacity: 1;
    }
}

.message {
    position: absolute;
    bottom: 80px;
    width: 100%;
    text-align: center;
    font-size: 36px;
    font-weight: bold;
    color: #ff4757;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.8s ease;
    font-family: 'Brush Script MT', cursive, sans-serif;
}

.message.show {
    opacity: 1;
    transform: translateY(0);
}