/* Bowling Sudoku game page. */
#header {
	max-width: 42rem;
	margin: 0.25rem auto;
	padding: 0 0.25rem;
	touch-action: manipulation;
	-webkit-user-select: none;
	user-select: none;
}
#tray {
	display: grid;
	grid-template-columns: repeat(8, minmax(0, 1fr));
	gap: 0.25rem;
}
.pick {
	height: 2.4rem;
	border: 2px solid #888;
	border-radius: 0.4rem;
	background: white;
	font-family: inherit;
	font-size: 1.3rem;
	font-weight: bold;
	cursor: pointer;
	padding: 0;
}
.pick.activePick {
	border: 3px solid #0A0;
	background: #DFD;
}
/* Scoresheet for the selected row: a line with the row and its target, then the 10 frames. */
#sheet {
	display: grid;
	grid-template-columns: repeat(10, minmax(0, 1fr));
	margin: 0.4rem 0 0 0;
	font-size: clamp(0.75rem, 3vw, 0.95rem);
}
.sheetHead {
	grid-column: 1 / -1;
	display: flex;
	justify-content: space-between;
	font-weight: bold;
	padding: 0 0.1rem 0.15rem 0.1rem;
}
.sheetTarget.good {
	color: #080;
}
.sheetTarget.off {
	color: #C00;
}
.frame {
	border: 1px solid #555;
	border-left: none;
	text-align: center;
	background: white;
	position: relative;
}
.frame:nth-child(2) {
	border-left: 1px solid #555;
}
.frame .throws span {
	min-height: 1.2em;
}
.frame .throws {
	display: grid;
	grid-template-columns: 1fr 1fr;
	border-bottom: 1px solid #999;
}
.frame .throws span + span {
	border-left: 1px solid #999;
	border-bottom: 1px solid #999;
	margin-bottom: -1px;
}
.frame .ftotal {
	min-height: 1.2em;
	font-weight: bold;
}
.frame .fnum {
	font-size: 0.75em;
	color: #888;
}
#status {
	text-align: center;
	min-height: 1.4rem;
	max-width: 42rem;
	margin: 0.25rem auto;
	font-size: 0.95rem;
}
.cardFull {
	display: grid;
	max-width: 42rem;
	margin: 0.25rem auto;
	padding: 0;
	position: relative;
	grid-template-columns: repeat(17, minmax(0, 1fr));
}
#gameContainer {
	border: 3px solid black;
	border-left: none;
}
#gameContainer .cellLeft {
	height: var(--w);
	line-height: var(--w);
	text-align: center;
	font-size: min(calc(var(--w) * 0.4), 1.1rem);
	font-weight: bold;
	border-right: 3px solid black;
	background: #F4F4F4;
	cursor: pointer;
}
#gameContainer .cellLeft.activeRow {
	background: #FFE9A8;
}
#gameContainer .cellLeft.good {
	color: #080;
}
#gameContainer .cellLeft.off {
	color: #C00;
}
#gameContainer .cell {
	height: var(--w);
	padding: 0;
	border: none;
	border-right: 1px solid #CCC;
	border-bottom: 1px solid #999;
	background: white;
	color: #1a4fb5;
	font-family: inherit;
	font-size: min(calc(var(--w) * 0.6), 1.6rem);
	line-height: 1;
	cursor: pointer;
	box-sizing: border-box;
}
#gameContainer .cell.frameStart {
	box-shadow: inset 2px 0 0 #666;
}
#gameContainer .cell.mark {
	background: #E4E4E4;
	color: #333;
	font-weight: bold;
	cursor: default;
}
#gameContainer .cell.given {
	color: black;
	font-weight: bold;
}
#gameContainer .cell.rowSelected {
	background-color: #FFF6D6;
}
#gameContainer .cell.mark.rowSelected {
	background-color: #E9DFB8;
}
#gameContainer .cell.blockRight {
	border-right: 3px solid black;
}
#gameContainer .cell.blockBottom {
	border-bottom: 3px solid black;
}
#gameContainer .cellLeft.blockBottom {
	border-bottom: 3px solid black;
}
#gameContainer .cell.hint {
	outline: 3px solid #F90;
	outline-offset: -3px;
	position: relative;
	z-index: 1;
}
#gameContainer .cell.wrong {
	outline: 3px solid #E00;
	outline-offset: -3px;
	position: relative;
	z-index: 1;
}
#gameContainer .cell.bad {
	animation: bad 0.4s;
}
@keyframes bad {
	0%, 100% { transform: none; }
	25% { transform: translateX(-3px); }
	75% { transform: translateX(3px); }
}
