/* ==========================
   BUSCAMINAS
========================== */

*{
    margin:0;
    padding:0;
    box-sizing:border-box;
    font-family:Arial, Helvetica, sans-serif;
}

body{
    background:#1f2937;
    display:flex;
    justify-content:center;
    align-items:center;
    min-height:100vh;
    color:white;
}

/* ==========================
   CONTENEDOR
========================== */

.contenedor{
    width:90%;
    max-width:900px;
    background:#2c3e50;
    border-radius:15px;
    padding:25px;
    box-shadow:0 0 20px rgba(0,0,0,.5);
}

h1{
    text-align:center;
    margin-bottom:25px;
    color:#ffd54f;
}

/* ==========================
   CONFIGURACIÓN
========================== */

.configuracion{
    display:flex;
    justify-content:center;
    gap:20px;
    flex-wrap:wrap;
    margin-bottom:20px;
}

.campo{
    display:flex;
    flex-direction:column;
}

.campo label{
    margin-bottom:5px;
    font-weight:bold;
}

.campo input{
    width:90px;
    padding:8px;
    border:none;
    border-radius:8px;
    text-align:center;
    font-size:16px;
}

/* ==========================
   BOTONES
========================== */

.botones{
    display:flex;
    justify-content:center;
    gap:15px;
    margin-bottom:25px;
}

button{
    padding:12px 25px;
    border:none;
    border-radius:10px;
    cursor:pointer;
    font-size:16px;
    font-weight:bold;
    transition:.3s;
}

#btnIniciar{
    background:#2ecc71;
    color:white;
}

#btnIniciar:hover{
    background:#27ae60;
}

#btnReiniciar{
    background:#3498db;
    color:white;
}

#btnReiniciar:hover{
    background:#2980b9;
}

/* ==========================
   INFORMACIÓN
========================== */

.informacion{
    display:flex;
    justify-content:space-around;
    flex-wrap:wrap;
    gap:15px;
    margin-bottom:20px;
}

.dato{
    background:#34495e;
    padding:12px 18px;
    border-radius:10px;
    min-width:180px;
    text-align:center;
}

/* ==========================
   MENSAJES
========================== */

.mensaje{
    text-align:center;
    font-size:24px;
    font-weight:bold;
    min-height:40px;
    margin-bottom:20px;
}

/* ==========================
   TABLERO
========================== */

.tablero{
    display:grid;
    justify-content:center;
    gap:2px;
    background:#555;
    padding:5px;
    border-radius:10px;
    width:max-content;
    margin:auto;
}

/* ==========================
   CASILLAS
========================== */

.casilla{
    width:40px;
    height:40px;
    background:#bdbdbd;
    border:2px solid #eeeeee;
    display:flex;
    justify-content:center;
    align-items:center;
    cursor:pointer;
    font-size:20px;
    font-weight:bold;
    user-select:none;
    transition:.15s;
}

.casilla:hover{
    background:#d6d6d6;
}

.abierta{
    background:#ececec;
    border:1px solid #999;
}

.bomba{
    background:#e53935;
    color:white;
}

.bandera{
    background:#ffeb3b;
}

.numero1{
    color:#1565c0;
}

.numero2{
    color:#2e7d32;
}

.numero3{
    color:#d32f2f;
}

.numero4{
    color:#6a1b9a;
}

.numero5{
    color:#795548;
}

.numero6{
    color:#00838f;
}

.numero7{
    color:#212121;
}

.numero8{
    color:#616161;
}

/* ==========================
   EFECTOS
========================== */

.casilla:active{
    transform:scale(.95);
}

button:active{
    transform:scale(.96);
}

/* ==========================
   RESPONSIVE
========================== */

@media (max-width:700px){

    .casilla{
        width:32px;
        height:32px;
        font-size:16px;
    }

    .configuracion{
        flex-direction:column;
        align-items:center;
    }

    .botones{
        flex-direction:column;
    }

    .dato{
        width:100%;
    }

}