@import url('https://fonts.googleapis.com/css2?family=Krona+One&family=Montserrat:ital,wght@0,100..900;1,100..900&display=swap');

:root {
    --color-primario: #000000;
    --corlor-secundario: #f6f6f6;
    --color-terciario: #22D4FD;
    --color-hover: #272727;

    --fuente-monserat: "Montserrat", sans-serif;
    --fuente-krona: "Krona One", sans-serif;
}


.ventana-flotante {
    position: fixed;
    top: 10px;
    right: 10px;
    background-color: var(--corlor-secundario);
    border: 1px solid #ccc;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    border-radius: 5px;
    z-index: 1000;
    width: 80px;
    height: 60px;
    overflow: hidden;
    transition: width 0.3s ease-in-out, height 0.3s ease-in-out, opacity 0.3s ease-in-out;
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    flex-direction: column;
}

.ventana-flotante.expandir {
    width: 300px;
    height: 200px;
}

.ventana-flotante .cabecera {
    background-color: #ddd;
    padding: 8px;
    border-bottom: 1px solid #ccc;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-top-left-radius: 5px;
    border-top-right-radius: 5px;
    cursor: grab;
    opacity: 0;
    transition: opacity 0.3s ease-in-out 0.3s;
    width: 100%;
    box-sizing: border-box;
}

.ventana-flotante.expandir .cabecera {
    opacity: 1;
}

.ventana-flotante .cabecera #tituloVentana {
    font-weight: bold;
    font-size: 16px;
}

.ventana-flotante .cabecera button#cerrarVentana {
    background: none;
    border: none;
    font-size: 18px;
    cursor: pointer;
    padding: 0;
    margin-left: 5px;
}

.ventana-flotante .contenido {
    padding: 10px;
    text-align: center;
    opacity: 0;
    transition: opacity 0.3s ease-in-out 0.3s;
    width: 100%;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    height: calc(100% - 30px); /* Ajustar altura */
}

.ventana-flotante.expandir .contenido {
    opacity: 1;
    display: block; /* Cambiar a block para el juego */
}


/* Estilo inicial del icono */
/* Icono de joystick */
.ventana-flotante::before {
    content: "🕹️"; 
    font-size: 28px;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    opacity: 1;
    transition: opacity 0.3s ease-in-out;
}

.ventana-flotante.expandir::before {
    opacity: 0;
}

/* Estilos del juego */
#gameCanvas {
    width: 100%;
    height: 100%;
    border: 1px solid var(--color-primario);
    background-color: #8f8f8f; /* Fondo gris del stage */
}

.game-message {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: rgba(0, 0, 0, 0.7);
    color: var(--corlor-secundario);
    padding: 20px;
    border-radius: 5px;
    font-size: 18px;
}