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

html,
body {
    width: 100%;
    overflow: hidden;
    /* Elimina cualquier posibilidad de scroll */
    background-color: #f8f8f8;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

/* Fondo con la imagen completa */
.background {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: url('assets/FondoIdioma.png') no-repeat center center;
    background-size: cover;
}

/* Contenedor principal */
.container {
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    height: 100vh;
    width: 100vw;
    text-align: center;
    position: relative;
    z-index: 1;
    /* Asegura que el contenido esté sobre el fondo */
}

/* Texto superior */
h2 {
    font-size: 20px;
    color: #34b233;
    /* Cambiado a blanco para mejor visibilidad */
    margin-top: 20px;
}

/* Contenedor de las banderas */
.flags-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
    flex-grow: 1;
    justify-content: center;
}

/* Estilo de las banderas */
.flag {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
}

.flag:hover {
    transform: scale(1.1);
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.2);
}

/* Ajuste en pantallas pequeñas */
@media (max-height: 600px) {
    .flag {
        width: 70px;
        height: 70px;
    }
}

/* Para pantallas más anchas (tablets y landscape mode) */
@media (min-width: 768px) {
    .flags-container {
        flex-direction: row;
        gap: 30px;
    }

    .flag {
        width: 100px;
        height: 100px;
    }
}

/* Solo en pantallas grandes (ordenadores) */
@media screen and (min-width: 768px) {
    body {
        background-size: contain;
        /* Mantiene el tamaño móvil */
        /* Fija la altura del fondo */
        width: 100vw;
        /* Evita que el fondo se expanda demasiado */
        overflow: hidden;
        /* Evita scroll innecesario */
    }
    .background {
        background-size: contain;
    }
}