body, html {
    height: 100%;
    margin: 0;
    font-family: 'Arial', sans-serif;
}

#background-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-image: url('flower-field.jpg');
    background-size: cover;
    background-position: center;
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 1;
}

#game-container {
    background-color: rgba(255, 255, 255, 0.7);
    padding: 2rem;
    border-radius: 10px;
    max-width: 500px;
    width: 100%;
    z-index: 3;
}

h1 {
    color: #343a40;
    font-weight: bold;
}

#game-board {
    display: grid;
    grid-template-rows: repeat(6, 1fr);
    gap: 5px;
    max-width: 330px;
    margin: 0 auto;
}

.row {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 5px;
}

.tile {
    width: 100%;
    aspect-ratio: 1 / 1;
    border: 2px solid #ced4da;
    font-size: 2rem;
    font-weight: bold;
    display: flex;
    justify-content: center;
    align-items: center;
    text-transform: uppercase;
    background-color: #fff;
    transition: all 0.3s ease;
}

.tile {
    width: 100%;
    aspect-ratio: 1 / 1;
    border: 2px solid #ced4da;
    font-size: 2rem;
    font-weight: bold;
    display: flex;
    justify-content: center;
    align-items: center;
    text-transform: uppercase;
    background-color: #fff;
    transition: all 0.3s ease;
}

.tile.correct {
    background-color: #198754;
    border-color: #198754;
    color: white;
}

.tile.present {
    background-color: #ffc107;
    border-color: #ffc107;
    color: white;
}

.tile.absent {
    background-color: #6c757d;
    border-color: #6c757d;
    color: white;
}

.key.correct {
    background-color: #198754;
    color: white;
}

.key.present {
    background-color: #ffc107;
    color: white;
}

.key.absent {
    background-color: #6c757d;
    color: white;
}

#keyboard {
    display: grid;
    grid-template-rows: repeat(3, 1fr);
    gap: 5px;
    max-width: 500px;
    margin: 0 auto;
}

/* ... (mantén los estilos existentes para .keyboard-row, .key, etc.) ... */

#bees-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 4;
    overflow: hidden;
}

.bee {
    position: absolute;
    width: 50px;
    height: 50px;
    background-image: url('./cute-bee.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
    pointer-events: none;
    will-change: transform;
    z-index: 1001; /* Asegúrate de que las abejas estén por encima de otros elementos */
}

@media (max-width: 400px) {
    #game-container {
        padding: 1rem;
    }
    .tile {
        font-size: 1.5rem;
    }
    .key {
        font-size: 0.8rem;
        padding: 8px;
        min-width: 25px;
    }
    .key.wide {
        min-width: 50px;
    }
}
#keyboard {
    display: grid;
    grid-template-rows: repeat(3, 1fr);
    gap: 5px;
    max-width: 100%; /* Cambiado de 500px a 100% */
    margin: 0 auto;
}

.keyboard-row {
    display: flex;
    justify-content: center;
    gap: 5px;
}

.key {
    background-color: #e9ecef;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: bold;
    padding: 10px;
    min-width: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.key:hover {
    background-color: #ced4da;
    transform: scale(1.1);
}

.key.wide {
    min-width: 60px;
}

/* Estilos para las teclas según su estado */
.key.correct {
    background-color: #198754;
    color: white;
}

.key.present {
    background-color: #ffc107;
    color: white;
}

.key.absent {
    background-color: #6c757d;
    color: white;
}

@media (max-width: 400px) {
    .key {
        font-size: 0.8rem;
        padding: 8px;
        min-width: 25px;
    }
    
    .key.wide {
        min-width: 50px;
    }
}
@keyframes moveCloud {
    from { transform: translateX(100%); }
    to { transform: translateX(-100%); }
}

#cloud-container {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 2;
    overflow: hidden;
}

.cloud {
    position: absolute;
    width: 2000px;
    height: 300px;
    background-image: url('clouds.png');
    background-repeat: repeat-x;
    animation: moveCloud 60s linear infinite; /* Cambia 60s al valor que desees */
}

/* Para las otras capas de nubes */
.cloud:nth-child(2) {
    top: 20%;
    animation-duration: 80s; /* Ajusta este valor */
}

.cloud:nth-child(3) {
    top: 40%;
    animation-duration: 100s; /* Ajusta este valor */
}
#image-container {
    text-align: center;
}

#bee-image {
    max-width: 100%;
    height: auto;
    border: 2px solid #ced4da;
    border-radius: 10px;
}

#input-container {
    max-width: 330px;
    margin: 0 auto;
}

#answer-input {
    font-size: 1.5rem;
    text-align: center;
}
/* Estilos para el contador de progreso */
#progress-counter {
    font-size: 1.2rem;
    font-weight: bold;
    color: #343a40;
}

/* Estilos para la ventana modal */
.modal-body {
    position: relative;
}

.modal-body h5 {
    color: #343a40;
}

.confetti {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1050; /* Por encima de la ventana modal */
}
/* Estilos para el contenedor principal del juego */
#game-container {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: 100vh; /* Usa toda la altura de la ventana */
    padding: 20px;
    box-sizing: border-box;
}

/* Estilos para el contenedor de la imagen */
#image-container {
    width: 100%;
    max-width: 500px; /* Máximo ancho en pantallas grandes */
    height: 50vh; /* Usa el 50% de la altura de la ventana */
    max-height: 500px; /* Máxima altura en pantallas grandes */
    margin: 0 auto;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow: hidden; /* Evita desbordamiento */
}

/* Estilos para la imagen */
#bee-image {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain; /* Mantiene la proporción de la imagen */
    border: 2px solid #ced4da;
    border-radius: 10px;
}

/* Media query para dispositivos móviles */
@media (max-width: 767px) {
    #image-container {
        height: 40vh; /* Usa menos altura en móviles */
        max-height: none; /* Elimina la altura máxima en móviles */
    }
}

/* Media query para asegurar que el contenido no desborde en pantallas muy pequeñas */
@media (max-height: 500px) {
    #game-container {
        height: auto; /* Permite scroll si la pantalla es muy pequeña */
    }
    
    #image-container {
        height: 60vh; /* Ajusta según sea necesario */
    }
}
#keyboard {
    display: grid;
    grid-template-rows: repeat(3, 1fr);
    gap: 5px;
    max-width: 100%;
    margin: 20px auto;
}

.keyboard-row {
    display: flex;
    justify-content: center;
    gap: 5px;
}

.key {
    background-color: #e9ecef;
    border: none;
    border-radius: 4px;
    font-size: 1rem;
    font-weight: bold;
    padding: 10px;
    min-width: 30px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.key:hover {
    background-color: #ced4da;
    transform: scale(1.05);
}

.key[data-key="ENTER"], .key[data-key="⌫"] {
    min-width: 60px;
}

@media (max-width: 400px) {
    .key {
        font-size: 0.8rem;
        padding: 8px;
        min-width: 25px;
    }
    
    .key[data-key="ENTER"], .key[data-key="⌫"] {
        min-width: 50px;
    }
}

