*{
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: serif;
}
body{
    width: 100%;
    height: 100vh;
    background-color: bisque;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 20px;
}
.Game-Table{
    width: 300px;
    height: 300px;
    display: grid;
    gap: 4px;
}
.Game-Table div{
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: rgb(20, 20, 20);
    color: white;
    font-size: 28px;
    user-select: none;
    cursor: pointer;
}
body .controls{
    display: flex;
    gap: 10px;
}
body .controls button{
    padding: 10px 20px;
    font-size: 16px;
    border: none;
    cursor: pointer;
    border-radius: 5px;
    background-color: black;
    color: white;
}
button:hover{
    opacity: 0.8;
}
body .Game-Table div input{
     width: 100%;
    height: 100%;
    font-size: 28px;
    text-align: center;
    background: transparent;
    border: none;
    outline: none;
    color: white;
    cursor: pointer;
}
/* Chrome, Edge, Safari */
.Game-Table div input::-webkit-inner-spin-button,
.Game-Table div input::-webkit-outer-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Firefox */
.Game-Table div input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}

body .footer{
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
}

body .footer button{
    padding: 10px 20px;
    margin-top: 20px;
    font-size: 16px;
    border: none;
    cursor: pointer;
    border-radius: 5px;
    background-color: black;
    color: white;
}
body .footer .Explain-Game button:hover{
    opacity: 0.8;
}
.modal {
    display: none;
    position: fixed;
    z-index: 999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: #ffffff;
    padding: 20px;
    border-radius: 12px;
    width: 300px;
    text-align: center;
    font-size: 20px;
    font-weight: bold;
}

#closeModal {
    background-color: #222;
    color: white;
    border: none;
    padding: 8px 15px;
    margin-top: 15px;
    cursor: pointer;
    border-radius: 5px;
}
#closeModal:hover {
    background-color: #444;
}

#resultModal {
    display: none;
    position: fixed;
    z-index: 9999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.8);
    justify-content: center;
    align-items: center;
}

#resultBox {
    background-color: #000;  
    color: #fff;            
    padding: 25px;
    width: 350px;
    border-radius: 10px;
    border: 2px solid #444; 
    font-family: Arial, sans-serif;
    white-space: pre-line;  
}
