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

body {
    overflow: hidden;
    font-family: 'Quicksand', sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    /* Nền gradient chuyển động siêu mượt */
    background: linear-gradient(-45deg, #ff9a9e, #fad0c4, #ffecd2, #fcb69f);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
}

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

/* Hộp nội dung với hiệu ứng kính (Glassmorphism) cực cao cấp */
.card {
    background: rgba(255, 255, 255, 0.4);
    box-shadow: 0 8px 32px 0 rgba(255, 105, 135, 0.37);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-radius: 25px;
    border: 1px solid rgba(255, 255, 255, 0.6);
    padding: 60px 40px;
    text-align: center;
    max-width: 90%;
    z-index: 10;
    animation: popIn 1s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

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

h1 {
    font-family: 'Dancing Script', cursive;
    color: #f72585;
    font-size: 55px;
    margin-bottom: 40px;
    text-shadow: 2px 2px 4px rgba(255, 255, 255, 0.7);
    line-height: 1.2;
}

.buttons {
    display: flex;
    justify-content: center;
    gap: 20px;
}

button {
    padding: 16px 45px;
    font-size: 22px;
    font-family: 'Quicksand', sans-serif;
    font-weight: 700;
    border: none;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    outline: none;
}

#yes {
    background: linear-gradient(45deg, #f72585 0%, #ff4d6d 100%);
    color: white;
}

#yes:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 12px 25px rgba(247, 37, 133, 0.4);
}

#no {
    background: white;
    color: #f72585;
    border: 2px solid #f72585;
    /* Xóa position: absolute tĩnh ở đây để ko bị lỗi đè lên #yes ban đầu */
}

/* Tim bay */
.heart {
    position: fixed;
    color: #ff3366;
    animation: float ease-in infinite;
    z-index: 1;
    pointer-events: none;
    text-shadow: 0 0 15px rgba(255, 51, 102, 0.6);
}

@keyframes float {
    0% {
        transform: translateY(100vh) scale(0.5);
        opacity: 0;
    }
    20% {
        opacity: 1;
    }
    100% {
        transform: translateY(-20vh) scale(1.2);
        opacity: 0;
    }
}

/* Lớp phủ mở thư */
#overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(-45deg, #ff9a9e, #fad0c4, #ffecd2, #fcb69f);
    background-size: 400% 400%;
    animation: gradientBG 15s ease infinite;
    z-index: 99999;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: opacity 1s ease;
}

#openCard {
    font-size: 30px;
    padding: 20px 45px;
    font-family: 'Quicksand', sans-serif;
    font-weight: 700;
    background: white;
    color: #f72585;
    border-radius: 50px;
    cursor: pointer;
    border: none;
    box-shadow: 0 10px 25px rgba(247, 37, 133, 0.3);
    animation: pulse 1.5s infinite;
    transition: transform 0.3s ease;
}

#openCard:hover {
    transform: scale(1.05);
}

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