body {
    font-family: Arial, sans-serif;
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    margin: 0;
    background-color: #f0f0f0;
    padding: 10px;
    box-sizing: border-box;
    position: relative;
}

.container {
    text-align: center;
    width: 100%;
    max-width: 500px;
    z-index: 1;
}

.carta {
    background-color: #fff;
    border: 2px solid #000;
    padding: 20px;
    cursor: pointer;
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    position: relative;
    box-sizing: border-box;
    padding-bottom: 50%;
    height: 0;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: transform 0.5s ease, opacity 0.5s ease;
    z-index: 1;
}

.corazon {
    font-size: 48px;
    color: red;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

.acertijoBox {
    display: none;
    margin-top: 20px;
}

.acertijoBox p,
.acertijoBox input,
.acertijoBox button {
    font-size: 18px;
    margin: 10px 0;
}

.acertijoBox input {
    width: 100%;
    padding: 10px;
    margin-top: 10px;
    margin-bottom: 10px;
    box-sizing: border-box;
}

.acertijoBox button {
    padding: 10px 20px;
    font-size: 18px;
    cursor: pointer;
    width: 100%;
    box-sizing: border-box;
}

.contenidoCarta {
    margin-top: 20rem;
    padding: 20px;
    border: 2px solid #000;
    background-color: #fff;
    width: 100%;
    box-sizing: border-box;
    opacity: 0;
    transform: scale(0.9);
    transition: transform 0.5s ease, opacity 0.5s ease;
}

.contenidoCarta.show {
    opacity: 1;
    transform: scale(1);
}

.carta.hide {
    opacity: 0;
    transform: scale(0.9);
    pointer-events: none;
}

/* Media Queries for Mobile */
@media (max-width: 600px) {
    .corazon {
        font-size: 36px;
    }

    .acertijoBox p,
    .acertijoBox input,
    .acertijoBox button {
        font-size: 16px;
    }

    .contenidoCarta {
        padding: 15px;
    }
}

.heart {
    position: absolute;
    color: rgba(255, 0, 0, 0.6);
    font-size: 24px;
    animation: moveHeart 5s infinite;
    top: 100vh;
}

/* Varias posiciones y tamaños para los corazones */
.heart:nth-child(1) {
    left: 10%;
    font-size: 18px;
    animation-duration: 7s;
    animation-delay: 1s;
}

.heart:nth-child(2) {
    left: 20%;
    font-size: 22px;
    animation-duration: 6s;
    animation-delay: 0.5s;
}

.heart:nth-child(3) {
    left: 30%;
    font-size: 26px;
    animation-duration: 8s;
    animation-delay: 2s;
}

.heart:nth-child(4) {
    left: 40%;
    font-size: 16px;
    animation-duration: 9s;
    animation-delay: 1.5s;
}

.heart:nth-child(5) {
    left: 50%;
    font-size: 20px;
    animation-duration: 7.5s;
    animation-delay: 0.7s;
}

.heart:nth-child(6) {
    left: 60%;
    font-size: 24px;
    animation-duration: 7s;
    animation-delay: 1.2s;
}

.heart:nth-child(7) {
    left: 70%;
    font-size: 28px;
    animation-duration: 6.5s;
    animation-delay: 0.8s;
}

.heart:nth-child(8) {
    left: 80%;
    font-size: 18px;
    animation-duration: 8.5s;
    animation-delay: 1.3s;
}

.heart:nth-child(9) {
    left: 90%;
    font-size: 22px;
    animation-duration: 6.2s;
    animation-delay: 0.9s;
}

.heart:nth-child(10) {
    left: 15%;
    font-size: 30px;
    animation-duration: 7.2s;
    animation-delay: 1.1s;
}

.heart:nth-child(11) {
    left: 25%;
    font-size: 16px;
    animation-duration: 7.8s;
    animation-delay: 1.4s;
}

.heart:nth-child(12) {
    left: 35%;
    font-size: 26px;
    animation-duration: 7.4s;
    animation-delay: 0.6s;
}

.heart:nth-child(13) {
    left: 45%;
    font-size: 28px;
    animation-duration: 6.9s;
    animation-delay: 1.2s;
}

.heart:nth-child(14) {
    left: 55%;
    font-size: 20px;
    animation-duration: 7.3s;
    animation-delay: 0.8s;
}

.heart:nth-child(15) {
    left: 65%;
    font-size: 22px;
    animation-duration: 8.1s;
    animation-delay: 0.9s;
}
