.black {
	background: lightgray;
}

.white {
	background: white;
}

.gold {
	background: gold;
}

.lemon {
	background: lemonchiffon;
}

:root {
	--chess-cell: clamp(34px, calc((100dvh - 260px) / 8), 90px);
}

@supports not (height: 100dvh) {
	:root {
		--chess-cell: clamp(34px, calc((100vh - 260px) / 8), 90px);
	}
}

.scacchiera {
	width: calc(var(--chess-cell) * 9);
	max-width: 100%;
	margin: 0;
	padding: 0;
	border-collapse: collapse;
	border-spacing: 0;
	border: none;
}

.scacchiera td {
	vertical-align: middle;
	font-size: calc(var(--chess-cell) * 0.3);
	padding: 0.2em;
	border: 1px solid #000;
	text-align: center;
	width: var(--chess-cell);
	height: var(--chess-cell);
	min-height: var(--chess-cell);
	min-width: var(--chess-cell);
}

.scacchiera td.none {
	border: none;
	color: white;
	text-align: center;
	font-size: calc(var(--chess-cell) * 0.23);
	font-weight: bold;
}

.scacchiera th {
	border: none;
	color: white;
	vertical-align: middle;
	text-align: center;
	font-weight: bold;
	width: var(--chess-cell);
	height: var(--chess-cell);
	min-height: var(--chess-cell);
	padding-right: 2em;
}

.scacchiera td img {
	width: calc(var(--chess-cell) * 0.72);
	height: calc(var(--chess-cell) * 0.72);
	object-fit: contain;
}

.draggable {
	text-align: center;
	cursor: pointer;
}

.draggable.dragging {
	cursor: move;
}

.scacchiera td.highlight {
	box-shadow: inset 0 0 3px 3px yellow;
}

.chessbutton {
	cursor: pointer;
	text-shadow: 0 -1px rgb(46, 53, 58);
	width: 130px;
	height: 75px;
	font-size: 40px;
	font-family: 'Saira Extra Condensed';
	border-radius: 10px;
	transition: 0.2s;
}

.chessbutton:hover {
	box-shadow: 0px 0px 20px 1px #40c781;
}

[data-color="black"].chessbutton {
	border-color: white;
	background-color: black;
	color: white;
}

[data-color="white"].chessbutton {
	border-color: black;
	background-color: white;
	color: black;
}
