/* Sudoku Trainer: Practice and Assistant pages. */
body {
	font-family: Verdana, sans-serif;
	margin: 0.5rem;
	color: #222;
}
header {
	text-align: center;
	max-width: 42rem;
	margin: 0 auto 0.5rem auto;
}
header h1 {
	font-size: clamp(1.6rem, 6vw, 2.5rem);
	margin: 0.25rem 0;
}
nav a {
	display: inline-block;
	margin: 0.25rem;
	padding: 0.25rem 0.75rem;
	border: 1px solid black;
	border-radius: 0.5rem;
	background: #FFC;
	color: #222;
	text-decoration: none;
}
nav a:hover {
	background: #FF9;
	text-decoration: underline;
}
nav a[aria-current] {
	background: #AFA;
}
main {
	max-width: 42rem;
	margin: auto;
}
.controls {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	align-items: center;
	justify-content: center;
	margin: 0.5rem 0;
}
.controls select, .controls input {
	font-family: inherit;
	font-size: 1rem;
	max-width: 100%;
}
.controls input {
	width: 100%;
	font-family: monospace, monospace;
	font-size: 0.8rem;
}
button {
	font-family: inherit;
	font-size: 1rem;
	cursor: pointer;
}
.about {
	text-align: center;
	min-height: 2.5rem;
	margin: 0.25rem 0;
}
.board {
	display: grid;
	grid-template-columns: repeat(9, minmax(0, 1fr));
	width: min(100%, 30rem, 70vh);
	margin: 0.5rem auto;
	border: 3px solid black;
	box-sizing: border-box;
	touch-action: manipulation;
}
.board .cell {
	aspect-ratio: 1;
	border: none;
	border-right: 1px solid #999;
	border-bottom: 1px solid #999;
	background: white;
	font-family: inherit;
	font-size: clamp(1rem, 5vw, 1.6rem);
	color: #1a4fb5;
	padding: 0;
	cursor: pointer;
	-webkit-tap-highlight-color: transparent;
}
.board .cell:nth-child(9n) {
	border-right: none;
}
.board .cell:nth-last-child(-n+9) {
	border-bottom: none;
}
.board .cell.blockRight {
	border-right: 2px solid black;
}
.board .cell.blockBottom {
	border-bottom: 2px solid black;
}
.board .cell.given {
	color: black;
	font-weight: bold;
	cursor: default;
}
.board .cell.selected {
	background: #CFC;
}
.board .cell.wrong {
	background: #FCC;
}
.board .cell.right {
	background: #9E9;
}
.board .cell.known {
	background: #FFE9A8;
}
.board .cell.hint {
	background: #FFE9A8;
}
.pad {
	display: grid;
	grid-template-columns: repeat(9, minmax(0, 1fr));
	gap: 0.25rem;
	width: min(100%, 30rem, 70vh);
	margin: 0.5rem auto;
}
.pad button {
	padding: 0.5rem 0;
	font-size: 1.25rem;
	border: 1px solid black;
	border-radius: 0.4rem;
	background: #FFC;
	touch-action: manipulation;
}
.pad button:hover {
	background: #FF9;
}
#feedback {
	text-align: center;
	min-height: 1.5rem;
	font-weight: bold;
}
#feedback.good {
	color: #0A0;
}
#feedback.bad {
	color: #B00;
}
.center {
	text-align: center;
}
details {
	border: 1px solid black;
	margin: 0.25rem 0;
}
details details {
	margin: 0.25rem 0.5rem;
}
details > div {
	padding: 0.25rem 0.5rem;
}
summary {
	background: #FDE;
	padding: 0.25rem 0.5rem;
	cursor: pointer;
}
details details summary {
	background: #EEE;
}
#stats, #summary {
	text-align: center;
	font-size: 0.9rem;
	color: #444;
}
