#pantallaCarga {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #051025 0%, #072037 100%);
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-family: sans-serif;
    font-size: 2rem;
}

#pantallaCarga button {
    padding: 1rem 2rem;
    margin: 1rem;
    font-size: 1.2rem;
    cursor: pointer;
    border-radius: 8px;
    border: none;
    background-color: #1e90ff;
    color: white;
}

#pantallaCarga button:hover {
    background-color: #63b3ed;
}
#FindelJuego {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #051025 0%, #072037 100%);
    color: white;
    display: none; /* solo visible al perder */
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-family: sans-serif;
    font-size: 2rem;
    z-index: 2000;
}

#FindelJuego h1 {
    margin-bottom: 20px;
}

#FindelJuego button {
    padding: 1rem 2rem;
    margin: 0.5rem;
    font-size: 1.2rem;
    cursor: pointer;
    border-radius: 8px;
    border: none;
    background-color: #1e90ff;
    color: white;
    transition: all 0.3s;
}

#FindelJuego button:hover {
    background-color: #63b3ed;
    transform: scale(1.05);
}
:root {
    --bg-init: #051025;
    --bg-end: #072037;
}
body {
    height: 100vh;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--bg-init) 0%, var(--bg-end) 100%);
}
  
  canvas {
    border: 4px solid white;
    background-color: black;
    width: 100%;
    height: 100%;
    display: block;
  }
  
.area {
    width: var(--size);
    height: var(--size);
    box-shadow: 0 8px 30px rgba(2, 6, 23, 0.7);
    border-radius: 12px;
    box-sizing: border-box;
    background: radial-gradient(circle at 30% 10%, rgba(255, 255, 255, 0.05), transparent 20%),
        linear-gradient(0deg, rgba(255, 255, 255, 0.05), transparent 60%);

}
.pantallas{
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}
.control{
    color: white;
    padding: 20px;
    font-size: 1.8rem;
    text-align: center;
    min-width: 300px;
}
.lienzo {
    box-shadow: 0 8px 30px rgba(2, 6, 23, 0.7);
    border-radius: 12px;
    box-sizing: border-box;
    background: radial-gradient(circle at 30% 10%, rgba(255, 255, 255, 0.05), transparent 20%),
        linear-gradient(0deg, rgba(255, 255, 255, 0.05), transparent 60%);
}

@media (max-width: 599px) {
    :root {
        --size: 90vw;
    }

    .pantallas {
        flex-direction: column;
    }

    .lienzo {
        width: var(--size);
        height: var(--size);
    }

    .control {
        font-size: 1.2rem;
        padding: 10px;
        width: 90%;
        min-width: auto;
    }
}

@media (min-width: 600px) and (max-width: 999px) {
    :root {
        --size: 80vw;
    }

    .pantallas {
        flex-direction: row;
    }

    .lienzo {
        width: var(--size);
        height: var(--size);
    }

    .control {
        font-size: 1.4rem;
        min-width: 250px;
    }
}

@media (min-width: 1000px) {
    :root {
        --size: 1000px;
    }

    .lienzo {
        width: var(--size);
        height: var(--size);
    }

    .pantallas {
        flex-direction: row;
    }

    .control {
        font-size: 1.6rem;
    }
}


