:root {
	/* --theme-blue: #4d91ff; */
	--theme-blue: dodgerblue;
	--google-blue:   #4285F4;
	--google-red:    #EA4335;
	--google-yellow: #ffbf00;
	--google-green:  #34A853;
	--global-padding: 8px;
	--gap: 8px;
	--bg-color: rgb(250, 250, 250);
	--frame-color: rgba(255, 255, 255, 1);
	--cell-thickness: 18cqi;
	--cell-color: rgb(237, 237, 237);
	--cell-edge-color: rgb(213, 213, 213);
	--text-color: white;          /* text overlaid on images / dark surfaces */
	--ui-text-color: #3c4043;     /* text on light UI surfaces */
	--border-color: black;
	--muted-color: #6c757d;
	--card-shadow:
		0 8px 17px 2px rgba(0, 0, 0, .14),
		0 3px 14px 2px rgba(0, 0, 0, .12),
		0 5px 5px -3px rgba(0, 0, 0, .20);
}

[data-theme="dark"] {
	--theme-blue: #0b54cb;
	--bg-color: #2b2b2b;
	--frame-color: #181a1b;
	--cell-color: #363636;
	--cell-edge-color: #1b1d1e;
	--text-color: white;
	--ui-text-color: #e8eaed;
	--border-color: rgba(255, 255, 255, 0.35);
	--muted-color: #9aa0a6;
	--card-shadow:
		0 8px 17px 2px rgba(0, 0, 0, .4),
		0 3px 14px 2px rgba(0, 0, 0, .3),
		0 5px 5px -3px rgba(0, 0, 0, .5);
}

[data-theme="dark"] .cell-card {
	box-shadow:
		0 2.5cqi 5.5cqi 0.5cqi rgba(0, 0, 0, .70),
		0 1cqi 4.5cqi 0.5cqi rgba(0, 0, 0, .60),
		0 1.5cqi 1.5cqi -1cqi rgba(0, 0, 0, .80);
}

[data-theme="dark"] .cell-card:hover {
	box-shadow: none;
}

/* Typography */
body {
	font-family: "Noto Sans", "Roboto", -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

li {
	margin-left: 1em;
}

/* Layout and Structure */

body {
	-webkit-font-smoothing: antialiased;
	-moz-osx-font-smoothing: grayscale;
	text-rendering: optimizeLegibility;
	-webkit-tap-highlight-color: transparent;
	align-content: center;
	color: var(--ui-text-color);

	background-position: center;
	background-size: cover;
	background-color: var(--bg-color);
}
body #background {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: -1;
	overflow: hidden;
	transition: opacity 0.3s linear;
}

body #background video {
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: center;
}
body.in-game #background, [data-theme="dark"] #background {
	opacity: 0;
}

.candy-text {
	color: var(--google-blue);
	text-shadow: 0 2px 4px rgba(0, 0, 0, 0.25);
}

.fade-out {
	opacity: 0 !important;
}

.fade-in {
	opacity: 1 !important;
}

.invisible {
	visibility: hidden !important;
}

.visible {
	visibility: visible !important;
}

img:not([src]) {
	visibility: hidden;
}

.icon-img {
	/* width: 20px; */
	width: 24px;
	display: inline-block;
	vertical-align: middle;
	object-fit: contain;
	flex-shrink: 0;
	user-select: none;
}

.center {
	position: absolute;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%);
	pointer-events: none;
}

.notransition {
	transition: none !important;
}

/* Buttons */
.button {
	display: inline-block;
	color: inherit !important;
	text-align: center;
	text-decoration: none;
	box-sizing: content-box;
	font-size: min(15px, max(4.4vw, 12px));
	padding: 10px 18px 10px 18px;
	margin: 12px 5px 12px 5px;
	width: 10ch;
	background-color: transparent;
	outline: none;
	border-radius: 8px;
	border: 1.5px solid;
	border-color: var(--border-color);
}

.button:hover,
.button:active,
.button.active {
	background-color: var(--theme-blue);
	color: white !important;
	text-decoration: none;
	border-color: transparent;
}

.button:hover,
.button:active {
	cursor: pointer;
}

.button.auto {
	width: auto;
}

input {
	color: inherit !important;
	text-align: center;
	box-sizing: content-box;
	font-size: min(15px, max(4.4vw, 12px));
	padding: 10px 18px 10px 18px;
	margin: 12px 5px 12px 5px;
	background-color: transparent;
	outline: none;
	border-radius: 8px;
	border: 1.5px solid;
	border-color: var(--border-color);
}

.button.active,
input:focus {
	opacity: 0.7;
}

a img {
	display: block;
	text-decoration: none;
}

span.half-line-break {
	width: 100%;
	display: block;
	height: 0.5em;
}