/* ---------- GENERALES ---------- */
body{
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    padding: 40px;
    background: #f0f2f5;
    margin: 0;
}
.hidden{display:none;}
button:disabled{background:#ccc!important;cursor:not-allowed;}

/* ---------- SCREENS ---------- */
.screen{
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0,0,0,.1);
    max-width: 500px;
    margin: auto;
}
#screen-game{max-width:none;width:auto;}

/* ---------- INPUTS / BOTONES ---------- */
input,button{
    width:100%;
    padding:12px;
    margin:10px 0;
    border-radius:4px;
    border:1px solid #ccc;
    box-sizing:border-box;
}
button{
    background:#007bff;
    color:white;
    border:none;
    cursor:pointer;
    font-weight:bold;
}
button:hover:not(:disabled){opacity:.9;}

.btn-success{background:#28a745;}
.btn-secondary{background:#6c757d;}

/* ---------- DADOS ---------- */
#dice-container{margin-top:20px;text-align:center;}
#dice-display{font-size:2rem;margin-bottom:10px;}
.die{
    display:inline-block;
    width:60px;height:60px;line-height:60px;
    font-size:3rem;border:3px solid #444;
    border-radius:12px;background:#fff;
    cursor:pointer;text-align:center;margin:10px;
    transition:all .2s ease;
}
.die.kept{
    background:#FFD700!important;
    border-color:#B8860B;
    transform:translateY(-10px);
    box-shadow:0 5px 15px rgba(0,0,0,.3);
}
.die:hover:not(.kept){background:#f0f0f0;}

/* ---------- LISTA JUGADORES ---------- */
#players-list-container{
    background:#f8f9fa;
    padding:10px;border-radius:5px;
    margin:15px 0;border-left:5px solid #007bff;
}
.player-entry{margin:5px 0;padding:5px;border-bottom:1px solid #eee;}

/* ---------- TABLA PUNTUACIONES ---------- */
.game-layout{display:flex;gap:20px;align-items:flex-start;}
.game-left{flex:1 1 600px;}
.game-right{flex:0 0 380px;}
.score-wrapper{overflow-x:auto;}
.table{width:100%;border-collapse:collapse;}
.table th,.table td{padding:2px 3px;font-size:.8rem;}
.table th{background:#e9ecef;}
.table td:last-child{width:25px;}
.table-info th{background:#d1ecf1;}

.table tbody tr{line-height:1;}   /* default ~1.5 */
.table tbody td{height:20px;}     /* o 18-22 px, tú prueba */
.table button{                    /* botón de anotar */
    padding:0 2px;                /* ya casi sin relleno */
    font-size:11px;               /* icono más pequeño */
    line-height:1;
    min-height:25px;              /* evita que el botón empuje la fila */
}

/* ---------- MODAL FIN ---------- */
.game-over-modal{
    position:fixed;top:0;left:0;width:100%;height:100%;
    background:rgba(0,0,0,.8);display:flex;
    align-items:center;justify-content:center;z-index:1000;
}
.game-over-modal .modal-content{
    background:white;padding:30px;border-radius:10px;text-align:center;
}