/* Page styles */

html
{
	width:100%;
	height:100%;
	overflow:hidden;
  touch-action: manipulation;
}

/* Firefox */
body *
{
  scrollbar-color: #bbb #ddd0;
	scrollbar-width: thin;
}

/* Chrome */
body *::-webkit-scrollbar
{
  width: 5px;
}

body *::-webkit-scrollbar-track
{
  background: #ddd0;
}

body *::-webkit-scrollbar-thumb
{
  background-color: #bbb;
  border: 3px solid #bbb;
}

body
{
	font-family:'Nunito', sans-serif;
	font-size:13pt;
	padding: 0px;
	border: 0px;
	margin: 0px;
}

h2 {
	display: block;
	text-align: center;
	margin-top: 0px;
	color: #ffdd79;
	margin-bottom: 0px;
}

.noselect {
  -webkit-touch-callout: none; /* iOS Safari */
    -webkit-user-select: none; /* Safari */
     -khtml-user-select: none; /* Konqueror HTML */
       -moz-user-select: none; /* Old versions of Firefox */
        -ms-user-select: none; /* Internet Explorer/Edge */
            user-select: none; /* Non-prefixed version, currently
                                  supported by Chrome, Edge, Opera and Firefox */
}

.anagramicle
{
	font-weight:700;
}

#header {
	position: absolute;
	width: 100%;
	top: 0px;
	left: 0px;
	height: 60px;
	text-align: center;
	font-weight: 600;
}

/* Dialog boxes */

#dialog_background {
	position: fixed;
	width: 100%;
	height: 100%;
	top: 0px;
	left: 0px;
	background-color: #000;
	opacity: 0.3;
	display:none;
}

.dialog_container
{
	display:flex;
	justify-content:center;
	z-index: 999990;
}

.dialog {
	position: absolute;
	border-radius: 8px;
	max-width: 500px;
	height: 550px;
	top: calc(50% - 300px);
	box-sizing: border-box;
	padding: 18px;
	line-height: 1.5;
	overflow: clip;
	transition: all 0.25s;
	opacity: 0;
	display: none;
	margin: 18px;
	z-index: 999999;
	overflow: clip;
}

.dialog_animate {
	top: calc(50% - 275px) !important;
	opacity:1;
	display:block;
}

.close_dialog, #close_menu {
	cursor: pointer;
	position: absolute;
	right: 8px;
	top: 8px;
}

.close_dialog i,#close_menu i {
	font-size: 34px;
}

/* Header styles */

#logo {
	font-family: 'Fascinate', sans-serif;
	font-size: 26pt;
	text-shadow: 0px 0px 14px hsl(324, 100%, 50%);
	animation: wheelHueColor 30s infinite;
	margin-top: 6px;
}

@keyframes wheelHueColor
{
  from, to { text-shadow: 0px 0px 14px hsl(324, 100%, 50%); }
  10%      { text-shadow: 0px 0px 14px hsl(360, 100%, 50%); }
  20%      { text-shadow: 0px 0px 14px hsl(36, 100%, 50%); }
  30%      { text-shadow: 0px 0px 14px hsl(72, 100%, 50%); }
  40%      { text-shadow: 0px 0px 14px hsl(108, 100%, 50%); }
  50%      { text-shadow: 0px 0px 14px hsl(144, 100%, 50%); }
  60%      { text-shadow: 0px 0px 14px hsl(180, 100%, 50%); }
  70%      { text-shadow: 0px 0px 14px hsl(216, 100%, 50%); }
  80%      { text-shadow: 0px 0px 14px hsl(252, 100%, 50%); }
  90%      { text-shadow: 0px 0px 14px hsl(288, 100%, 40%); }
}

.icon,#menu_icon
{
	cursor:pointer;
}

#settings_icon
{
	position: absolute;
	right: 18px;
	top: 18px;
}

#help_icon {
	position: absolute;
	left: 18px;
	top: 18px;
}

#stats_icon
{
	position: absolute;
	right: 52px;
	top: 18px;
}

#menu_icon
{
	position: absolute;
	left: 18px;
	top: 18px;
	display: none;
}

/* Game grid */

#fadetop {
	position: fixed;
	display: block;
	top: 61px;
	bottom: calc(50%);
	left: 0px;
	right: 0px;
	pointer-events: none;
}

#fadebottom {
	position: fixed;
	display: none;
	bottom: calc(50% - 166px);
	top: calc(50% + 40px);
	left: 0px;
	right: 0px;
	pointer-events: none;
}

#game_board {
	position: absolute;
	top: 61px;
	width: 100%;
	text-align: center;
	display: block;
	overflow: scroll;
	bottom: 153px;
	touch-action: pan-y;
	overflow-y: scroll;
}

#tiles {
	width: 100%;
	height: 100%;
}

.game_row {
	padding: 0px;
	margin: 0px;
	border: 0px;
	line-height: 0;
	position: relative;
}

.game_tile {
	width: 56px;
	height: 56px;
	margin: 2px;
	display: inline-block;
	position: relative;
	border: 2px solid #aaa;
}

.letter {
	position: absolute;
	width: 60px;
	height: 60px;
	display: flex;
	left: 0px;
	top: 0px;
	margin: -2px 0px 0px -2px;
	line-height: 0;
	text-align: center;
	flex-direction: column;
	justify-content: center;
	font-size: 34px;
	font-weight: 700;
	transform:rotateX(-90deg)
}

.show_tile {
	transition:transform 0.25s;
	transform: rotateX(0deg)
}

.hide_tile {
	transition:transform 0.25s;
	transform:rotateX(-90deg)
}

.guess {
	transform: rotateX(0deg);
}

/* Keyboard */

#keyboard {
	position: absolute;
	width: 100%;
	bottom: 75px;
	left: 0px;
	text-align: center;
	padding: 0px 0px 12px 0px;
	box-sizing: border-box;
	display: none;
	background-color: #121212;
}

#row1
{
	display:block;
}

#row2
{
	display:block;
}

.key {
	display: inline-flex;
	width: 60px;
	height: 60px;
	border-radius: 1px;
	margin: 0px 2px 4px 2px;
	justify-content: center;
	align-content: center;
	flex-direction: column;
	font-size: 22pt;
	font-weight: 700;
	cursor: pointer;
}

.keypressed {
	/* opacity: 0.3; */
}

.keypress_valid
{
	background-color: #538d4e !important;
}

.keypress_invalid
{
	background-color: #944f3b !important;
}

.key i
{
	font-size:1em;
}

/* Menu */

#menu {
	position: fixed;
	display: block;
	width: 350px;
	left:-350px;
	height: 100%;
	top: 0px;
	padding: 18px;
	box-sizing: border-box;
}

#menu div.item {
	padding: 18px;
	border-radius: 8px;
	margin-bottom: 18px;
	cursor:pointer;
	transition: background-color 0.25s;
}

#menu div.item:hover {
	padding: 18px;
	border-radius: 8px;
	margin-bottom: 18px;
	cursor:pointer;
	transition: background-color 0.25s;
}

#menu div.item h3 {
	margin-top: 0px;
}

 /* SLIDER CSS */
 
.switch {
	position: relative;
	display: inline-block;
	width: 52px;
	height: 30px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #bbb;
  -webkit-transition: .4s;
  transition: .4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 22px;
  width: 22px;
  left: 4px;
  bottom: 4px;
  background-color: white;
  -webkit-transition: .4s;
  transition: .4s;
}

input:checked + .slider {
	background-color: #4a7d46;
}

input:checked + .slider:before {
  -webkit-transform: translateX(22px);
  -ms-transform: translateX(22px);
  transform: translateX(22px);
}

.slider.round {
  border-radius: 34px;
}

.slider.round:before {
  border-radius: 50%;
}

/* Countdown */

#countdown {
	position: absolute;
	display: block;
	left: 0px;
	top: 140px;
	width: 100%;
	height: 100px;
}

.under {
	position: absolute;
	display: block;
}

.over
{
	position: absolute;
	display: block;
}

.under_circle {
	fill: none;
	stroke-width: 5;
	stroke-linecap: round;
}

.over_circle
{
  fill: none;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-dasharray: 0 100;
}

.uc_timer_fine
{
	stroke: #538d4e40;
}

.uc_timer_critical
{
	stroke: #cd534e40;
}

.oc_timer_fine
{
	stroke: #538d4e;
}

.oc_timer_critical
{
	stroke: #cd534e;
}

#timer {
	display: none;
	width: 120px;
	height: 120px;
	position: absolute;
	top: 0px;
	left: calc(50% - 60px);
	box-sizing: border-box;
	text-shadow: 10px 10px 10px #f00;
}

.time {
	position: absolute;
	top: 32px;
	font-size: 2em;
	width: 120px;
	text-align: center;
	left: calc(50% - 60px);
	font-weight: 700;
	font-family: 'Fascinate', sans-serif;
}

#start {
	position: absolute;
	display: inline-flex;
	left: calc(50% - 60px);
	width: 120px;
	height: 120px;
	padding: 16px;
	/* background-color: #538d4e; */
	border-radius: 100%;
	font-weight: 700;
	font-size: 1.5em;
	text-shadow: 0 0 3px #000;
	border: 4px solid #ddd;
	box-sizing: border-box;
	justify-content: center;
	align-content: center;
	cursor: pointer;
	flex-direction: column;
	text-align: center;
	color: #fff;
	bottom: 19px;
	font-family: 'Fascinate', sans-serif;
}

/* Counters */

#counters {
	position: absolute;
	bottom: 15px;
	text-align: center;
	width: 100%;
	display: none;
}

.letter_icon {
	width: 5px;
	height: 5px;
	background-color: #538d4e;
	margin: 1px;
	display: inline-block;
}

.counter {
	display: inline-block;
	width: 60px;
	margin: 0px 20px 0px 20px;
}

.count {
	font-size: 1.5em;
	font-weight: 600;
	display: block;
	line-height: 0.6;
}

.score {
	font-weight: 700;
	font-size: 2em;
}

.score_intro {
	text-align: center;
	margin-bottom: 10px;
}

.you_found, .you_missed {
	display: inline-block;
	width: 45%;
	text-align: center;
	vertical-align: top;
	overflow-y: auto;
	font-size: 0.8em;
	background-color: #777;
	border-radius: 8px;
	padding: 5px;
	margin: 5px;
	box-sizing: border-box;
	height: 200px;
	touch-action: manipulation;
}

.results {
	text-align: center;
}

#results_dialog {
	text-align: center;
}

.emoji {
	font-size: 1.4em;
}

.share_button {
	padding: 8px 10px;
	text-align: center;
	background-color: #347834;
	border-radius: 8px;
	margin-top: 20px;
	font-size: 0.9em;
	margin: 20px 60px;
	display: inline-block;
	font-weight: bold;
	width: 163px;
	cursor: pointer;
}

.share_button span {
	display: inline-block;
	margin-right: 4px;
}

.share_button .material-icons {
	font-size: 1.2em;
	position: absolute;
	margin-top: 3px;
}

/* Extra seconds and particles */

.canvas_coords {
	position: absolute;
	top: 98px;
	width: 200px;
	height: 200px;
	z-index: 9999;
	pointer-events: none;
	left: calc(50% - 100px);
}

.bonus {
	position: absolute;
	top: 177px;
	font-size: 2.2em;
	width: 76px;
	text-align: center;
	left: calc(50% - 38px);
	font-weight: 700;
	font-family: 'Fascinate', sans-serif;
	text-shadow: 0px 0px 5px #000,0px 0px 15px #000,0px 0px 10px #000,0px 0px 5px #000,0px 0px 10px #000,0px 0px 5px #000,0px 0px 10px #000,0px 0px 5px #000,0px 0px 10px #000,0px 0px 5px #000aliceblue;
	z-index: 1000;
	background-color: #121212;
	height: 40px;
	line-height: 0.9;
	margin: 0px;
	/* padding: 10px; */
	display: inline;
	box-sizing: border-box;
}

a.guess:visited
{
	opacity:0.3;
}
