gomoku/public/style.css

80 lines
1.6 KiB
CSS

body {
font-family: Arial, sans-serif;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
min-height: 100vh;
margin: 0;
background-color: #f0f0f0;
}
#game-container {
background-color: white;
padding: 20px;
border-radius: 8px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
text-align: center;
}
.game-board-grid {
position: relative;
width: calc(14 * 30px); /* 14 gaps of 30px between 15 lines */
height: calc(14 * 30px); /* 14 gaps of 30px between 15 lines */
margin-top: 20px;
background-color: #deb887; /* Wood color */
border: 1px solid black; /* Border for the whole board area */
}
/* Grid lines */
.game-board-grid::before {
content: '';
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
background-image:
linear-gradient(to right, black 1px, transparent 1px),
linear-gradient(to bottom, black 1px, transparent 1px);
background-size: 30px 30px;
background-position: -1px -1px; /* Align grid lines to the top-left */
pointer-events: none;
}
.intersection {
position: absolute;
width: 30px;
height: 30px;
display: flex;
justify-content: center;
align-items: center;
cursor: pointer;
z-index: 1;
}
.intersection > div {
width: 24px;
height: 24px;
border-radius: 50%;
border: 1px solid #333;
z-index: 2;
}
.intersection:hover {
background-color: rgba(0, 0, 0, 0.1); /* Subtle hover effect */
}
.last-move {
box-shadow: 0 0 5px 3px rgba(255, 255, 0, 0.7); /* Yellow glow */
}
#messages {
margin-top: 10px;
font-size: 0.9em;
color: #555;
}
#player-info {
margin-top: 10px;
font-weight: bold;
}