/* ===== RESET & BODY ===== */
body {
    margin: 0;
    padding: 0;
    min-height: 100svh; /* chuẩn mobile */
    background: linear-gradient(to bottom, #ff9a9e, #fad0c4);
    font-family: Arial, sans-serif;
    color: white;
    text-align: center;

    display: flex;
    justify-content: center;
    align-items: center;
}

/* ===== BACKGROUND ===== */
.bg-hearts {
    position: fixed;
    inset: 0;
    pointer-events: none;
}

/* ===== HEART ===== */
.heartbeat-heart {
    width: 100px; /* Có thể điều chỉnh kích thước tổng */
    height: 90px;
    position: relative;
    margin: 40px auto;
    animation: heartbeat 1.5s ease-in-out infinite;
}

.heartbeat-heart::before,
.heartbeat-heart::after {
    content: "";
    width: 50px; /* Nửa rộng của trái tim */
    height: 80px; /* Chiều cao của nửa tròn */
    position: absolute;
    left: 50px; /* Đặt ở giữa */
    top: 0;
    background: #ff4757;
    border-radius: 50px 50px 0 0; /* Tròn ở trên */
    transform: rotate(-45deg); /* Nửa trái */
    transform-origin: 0 100%; /* Quan trọng: origin ở bottom left */
}

.heartbeat-heart::after {
    left: 0; /* Di chuyển nửa phải sang trái để chồng lên */
    transform: rotate(45deg); /* Nửa phải */
    transform-origin: 100% 100%; /* Origin ở bottom right */
}

@keyframes heartbeat {
    0% { transform: scale(1); }
    20% { transform: scale(1.15); }
    40% { transform: scale(1); }
    60% { transform: scale(1.1); }
    80% { transform: scale(1.05); }
    100% { transform: scale(1); }
}
/* ===== TEXT ===== */
.container h1 {
    font-size: 2rem;
    margin: 10px;
}

.container p {
    font-size: 1.1rem;
    margin: 10px;
}

/* ===== BUTTONS ===== */
.buttons {
    display: flex;
    flex-direction: row;     /* Ngang hàng */
    justify-content: center; /* Căn giữa */
    gap: 12px;               /* Khoảng cách giữa 2 nút */
    margin-top: 15px;
}
.buttons button {
    width: 100%;
    max-width: 125px;
    padding: 14px;
    font-size: 1.1rem;
    border: none;
    border-radius: 40px;
    cursor: pointer;
    transition: transform 0.2s;
}

#yes-btn {
    background: #2ed573;
    color: white;
}

#no-btn {
    background: #ff4757;
    color: white;
}

.buttons button:active {
    transform: scale(0.95);
}

.hidden {
    display: none;
}

/* ===== RESPONSE ===== */
#response {
    font-size: 1.6rem;
    margin-top: 25px;
    font-weight: bold;
}

/* ===== FOOD LIST ===== */
#food-list {
    margin-top: 25px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 16px;
    padding: 16px;
    box-shadow: 0 6px 20px rgba(0,0,0,0.25);
}

#food-list:not(.hidden) {
    display: grid;
    grid-template-columns: 1fr; /* mobile: 1 cột */
    gap: 15px;
}

#food-list h2 {
    grid-column: 1 / -1;
    color: #333;
    margin-bottom: 10px;
}

/* ===== FOOD CARD ===== */
.food-card {
    background: #fff;
    color: #333;
    border-radius: 14px;
    padding: 12px;
    text-align: center;
    box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.food-card img {
    width: 100%;
    height: 140px;
    object-fit: cover;
    border-radius: 10px;
    margin-bottom: 8px;
}

.food-card p {
    font-size: 1.1rem;
    font-weight: bold;
    color: #e63946;
}

/* ===== TABLET & PC ===== */
@media (min-width: 768px) {
    .buttons {
        flex-direction: row;
        justify-content: center;
    }

    #food-list:not(.hidden) {
        grid-template-columns: repeat(2, 1fr); /* 2 cột */
    }

    .container h1 {
        font-size: 2.8rem;
    }

    .container p {
        font-size: 1.4rem;
    }
}

#cute-toast {
    position: fixed;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: rgba(255, 255, 255, 0.95);
    color: #ff4d6d;
    padding: 12px 20px;
    border-radius: 30px;
    font-size: 15px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.2);
    opacity: 0;
    transition: all 0.4s ease;
    z-index: 9999;
    pointer-events: none;
    white-space: nowrap;
}

#cute-toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}
