:root {
	--gold: #f0be00;
}

* {
	box-sizing: border-box;
	font-weight: bold;
	user-select: none;
}

body,html{
	width:100%;
	height: 100%;
	margin: auto;
	padding: 0;
	font-family: arial, sans-serif;
	font-size: 1.5em;
	overflow: hidden;
}

body {
	max-width: 700px;
}

#header {
	position: relative;
	height: 2em;
	line-height: 1.7;
	overflow-x:hidden;
}

#playfield 	{
	position: relative;
	height: calc(75% - 2em);
	display: flex;
	align-items: center;
}

.grid-area {
	margin: auto;
	justify-content: center;
	/* width: fit-content; */
}

#keyboard {
	position: relative;
	height: 25%;
}

.letter-row {
	display: flex;
	align-items: center;
	margin: auto;
}

.letter-box {
	height: calc(67vh / 7);
	width: calc(67vh / 7);
	margin: 2px 1px;
	max-height: calc(100vw / 7);
	max-width: calc(100vw / 7);
	border: lightgray 3px solid;
	border-radius: 5px;
	color: black;
	display: inline-flex;
	font-weight: bold;
	justify-content: center;
	align-items: center;
}

.letter-box:before {
	content: " ";
}

.key-row {
	justify-content: center;
	display: flex;
	align-items: center;
	margin: auto;
}

.keyboard-letter {
	height: calc(25vh / 3.5);
	width: calc(25vh / 4);
	max-height: calc(100vw / 10);
	max-width: calc(100vw / 10);
	margin: 3px 1px;
	border: lightgray 2px solid;
	border-radius: 5px;
	color: black;
	background-color: #EEE;
	display: inline-flex;
	font-weight: bold;
	justify-content: center;
	align-items: center;
	font-size: .60em;
	font-weight: normal;
	cursor: pointer;
}


.active-letter {
	border: 5px black solid;
}

.correct-letter {
	background-color: green;
	border: green 3px solid;
	color: white;
}

.misplaced-letter {
	background-color: var(--gold);
	border: var(--gold) 3px solid;
	color: white;
}

.incorrect-letter {
	background-color: gray;
	border: gray 3px solid;
	color: white;
}

.finished {
	opacity: 0.5;
	cursor: default !important;
}

#keyENTER, #keyDELETE {
	padding: 0 10px;
	width: fit-content;
	background-color: #B9B9B9;
	max-width: fit-content;
}

#message-overlay {
	position: fixed;
	top: 3.5em;
	left: 50%;
	transform: translate(-50%, -50%);
	width: fit-content;
	padding: 0.2em 0.5em;
	color: white;
	background-color: gray;
	font-weight: normal;
	font-size: .75em;
	font-variant: all-small-caps;
	text-align: center;
	z-index: 10;
	opacity: 0;
	transition: opacity 0.5s;
}

#message-overlay.show {
	opacity: 1;
}

#share-overlay {
	width: 100%;
	height: 100%;
	overflow: hidden;
	z-index: 10;
	position: fixed;
	top: 0;
	left: 0;
	font-size: 0.5em;
}

#share-boxes {
	line-height: 1.4em;
	font-size: 2em;
	padding-bottom: 0.5em;
}

#how-to-play-overlay {
	width: 100%;
	height: 100%;
	overflow: hidden;
	z-index: 10;
	position: fixed;
	top: 0;
	left: 0;
	font-size: 0.5em;
}

.overlay-gray {
	background: rgba(0,0,0, 0.3);
	height: 100%;
	width: 100%;
	z-index: 14;
	position: fixed;
	top: 0;
	left: 0;
}

.overlay-container {
	position: fixed;
	display: flex;
	flex-direction: column;
	z-index: 15;
	left: 50%;
	top: 50%;
	transform: translate(-50%, -50%);
	max-width: 600px;
	min-width: 350px;
}

.overlay-content {
	display: flex;
	flex-direction: column;
	border-radius: 10px;
	background: white;
	height: fit-content;
	margin: auto;
	padding: 15px;
	text-align: center;
	vertical-align: middle;
}


.button {
	font-size: 1rem;
	background-color: rgb(52, 198, 255);
	color: white;
	padding: 10px 12px;
	margin: 3px;
	border-radius: 5px;
	text-decoration: none;
	border: none;
	cursor: pointer;
}

.info-button {
	background-color: white;
	border: 2px lightgray solid;
	border-radius: 5px;
	color: black;
	font-size: 0.5em;
	float: right;
	cursor: pointer;
}

.info-button:disabled {
	cursor: default;
}

.share-container {
	display: block;
	padding: .45em .1em;
}

.share-icon { /*snagged from https://codepen.io/bertdida/pen/jemgbO */
	position: relative;
	display: block;
	left: -0.25em;
	width: 0.3em;
	height: 0.3em;
	border-radius: 50%;
	background-color: black;
	color: black;
	box-shadow: 0.4em -0.4em, 0.4em 0.4em;
	opacity: 20%;
}
.share-icon::before,
.share-icon::after {
	content: "";
	position: absolute;
	width: .55em;
	height: 0.075em;
	background-color: black;
}

.share-icon::before {
    top: 0.15em;
    left: 0.15em;
    transform-origin: bottom left;
    transform: rotate(45deg);
}

.share-icon::after {
    top: -0.1em;
    left: 0.1em;
    transform-origin: center;
    transform: rotate(-45deg);
}