* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: Arial, sans-serif;
    background-color: #f0f0f0;
    display: flex;
    justify-content: center;
    padding: 20px;
}

.container {
    max-width: 800px;
    width: 100%;
    text-align: center;
}

h1 {
    margin-bottom: 20px;
}

.game-options {
    margin-bottom: 20px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    align-items: center;
}

button {
    padding: 8px 16px;
    background-color: #4CAF50;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

button:hover {
    background-color: #45a049;
}

.opponent-selection {
    display: flex;
    gap: 20px;
    margin: 10px 0;
}

.status-info {
    font-size: 18px;
    margin-top: 10px;
}

#check-status {
    color: red;
    font-weight: bold;
    height: 1.2em;
}

.chessboard {
    width: 560px;
    height: 560px;
    margin: 0 auto;
    border: 10px solid #8B4513;
    display: grid;
    grid-template-columns: repeat(8, 1fr);
    grid-template-rows: repeat(8, 1fr);
}

.square {
    width: 100%;
    height: 100%;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
}

.light {
    background-color: #f0d9b5;
}

.dark {
    background-color: #b58863;
}

.piece {
    width: 90%;
    height: 90%;
    cursor: pointer;
    user-select: none;
    z-index: 10;
    font-size: 48px;  /* Increase font size */
    display: flex;
    justify-content: center;
    align-items: center;
}

/* Style for white pieces */
[data-piece^="white"] {
    color: #ffffff;
    text-shadow: 0 0 2px #000, 0 0 3px #000, 0 0 4px #000;
}

/* Style for black pieces */
[data-piece^="black"] {
    color: #000000;
    text-shadow: 0 0 2px #555, 0 0 3px #555, 0 0 4px #555;
}

.highlight-move {
    position: absolute;
    width: 25px;
    height: 25px;
    background-color: rgba(144, 238, 144, 0.7);
    border-radius: 50%;
    pointer-events: none;
}

.highlight-capture {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 4px solid rgba(255, 0, 0, 0.5);
    border-radius: 50%;
    pointer-events: none;
}

.selected {
    background-color: rgba(173, 216, 230, 0.7);
}

.last-move {
    background-color: rgba(255, 255, 0, 0.3);
}

.promotion-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 100;
}

.promotion-options {
    background-color: white;
    padding: 20px;
    border-radius: 5px;
    display: flex;
    gap: 15px;
}

.promotion-piece {
    width: 60px;
    height: 60px;
    display: flex;
    justify-content: center;
    align-items: center;
    border: 1px solid #ccc;
    cursor: pointer;
    font-size: 12px;
}

.promotion-piece:hover {
    background-color: #f0f0f0;
}