html {
  box-sizing: border-box;
}

:root {
  --white: #fff;
  --black: #000;
  --grey: #eee;
  --darkgrey: #2e2e2e;
  background: var(--black);
  color: var(--grey);
}

body {
  margin: 10px;
  font-family: Haettenschweiler, sans serif;
}

h1,
p {
  margin: 0;
}

.fade-in {
  opacity: 1;
  animation-name: fadeInOpacity;
  animation-iteration-count: 1;
  animation-timing-function: ease-in;
  animation-duration: 1s;
}

@keyframes fadeInOpacity {
  0% {
    opacity: 0;
  }
  100% {
    opacity: 1;
  }
}

.intro-text {
  pointer-events: none;
  color: var(--grey);
  font-style: bold;
  margin: 0px 10px;
  padding-top: 1%;
  text-align: center;
  position: relative;
  z-index: 1;
}

.blurry-text {
  color: transparent;
  text-shadow: 0 0 3px white;
  -webkit-transition: text-shadow 0.5s ease-in-out, color 0.5s ease-in-out;
  -moz-transition: text-shadow 0.5s ease-in-out, color 0.5s ease-in-out;
  -ms-transition: text-shadow 0.5s ease-in-out, color 0.5s ease-in-out;
  -o-transition: text-shadow 0.5s ease-in-out, color 0.5s ease-in-out;
  transition: text-shadow 0.5s ease-in-out, color 0.5s ease-in-out;
}

.user-div {
  color: var(--grey);
  display: inline-block;
  position: absolute;
  right: 2%;
  border-radius: 5px;
  margin-top: 1%;
  padding: 5px;
  background-color: var(--darkgrey);
  opacity: 0;
  -webkit-transition: opacity 0.5s ease-in-out;
  -moz-transition: opacity 0.5s ease-in-out;
  -ms-transition: opacity 0.5s ease-in-out;
  -o-transition: opacity 0.5s ease-in-out;
  transition: opacity 0.5s ease-in-out;
}

@media only screen and (max-width: 662px) {
  .user-div {
    position: relative;
    width: 90%;
    margin-left: 10px;
    margin-bottom: 10px;
  }
  .form {
    width: 100%;
  }
}

.username-text {
  font-weight: bold;
}

.help-tip {
  pointer-events: auto;
  font-weight: bold;
  position: absolute;
  top: -13px;
  right: -18px;
  opacity: 0.9;
  text-align: center;
  color: #bd5757;
  background-color: var(--grey);
  border-radius: 10px;
  width: 40px;
  height: 20px;
  font-size: 18px;
  line-height: 20px;
  cursor: pointer;
}

.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 */
}

.form {
  position: absolute;
  top: 50%;
  left: 50%;
  justify-content: center;
  width: 70%;
  height: 50px;
  transform: translate(-50%, -50%);
  opacity: 0;
  -webkit-transition: opacity 0.5s ease-in-out;
  -moz-transition: opacity 0.5s ease-in-out;
  -ms-transition: opacity 0.5s ease-in-out;
  -o-transition: opacity 0.5s ease-in-out;
  transition: opacity 0.5s ease-in-out;
}

.form input {
  width: 100%;
  height: 100%;
  background-color: black;
  font-size: 30px;
  letter-spacing: 3px;
  padding-top: 15px;
  color: var(--grey);
  border: none;
  outline: none;
}

.form label {
  color: var(--grey);
  position: absolute;
  bottom: 0px;
  left: 0%;
  width: 100%;
  height: 100%;
  pointer-events: none;
}

.form label::after {
  content: "";
  position: absolute;
  left: 0px;
  bottom: -1px;
  height: 100%;
  width: 100%;
  transform: translateX(-100%);
}

.content-username {
  position: absolute;
  bottom: 2px;
  left: 0px;
  transition: all 0.3s ease;
}

input:invalid {
  box-shadow: none;
}

.form input:focus + .label-username .content-username,
.form input:valid + .label-username .content-username {
  transform: translateY(-150%);
  transition: all 0.5s ease;
  opacity: 0.4;
}

#click-count {
  position: relative;
  background-color: var(--darkgrey);
  border: none;
  color: var(--grey);
  display: block;
  text-align: center;
  margin: auto;
  margin: 40px;
  margin-top: 20px;
  padding: 10px;
}

#page-container {
  position: relative;
  min-height: 95vh;
}

#content-wrap {
  padding-bottom: 6.5rem;
  /* Footer height */
}

#leaderboard-div {
  font-size: xx-large;
  margin: 0 200px;
}

/* ---------------NEW SWITCH --------------------*/

*,
*:before,
*:after {
  box-sizing: inherit;
  margin: 0;
  padding: 0;
}

.mid {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding-top: 8em;
}

/* Switch starts here */

.rocker {
  display: inline-block;
  position: relative;
  /*
  SIZE OF SWITCH
  ==============
  All sizes are in em - therefore
  changing the font-size here
  will change the size of the switch.
  See .rocker-small below as example.
  */
  font-size: 2em;
  font-weight: bold;
  text-align: center;
  text-transform: uppercase;
  color: #888;
  width: 7em;
  height: 4em;
  overflow: hidden;
  border-bottom: 0.5em solid #eee;
}

.rocker-small {
  font-size: 0.75em;
  /* Sizes the switch */
  margin: 1em;
}

.rocker::before {
  content: "";
  position: absolute;
  top: 0.5em;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: #999;
  border: 0.5em solid #eee;
  border-bottom: 0;
}

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

.switch-left,
.switch-right {
  cursor: pointer;
  position: absolute;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 2.5em;
  width: 3em;
  transition: 0.2s;
}

.switch-left {
  height: 2.4em;
  width: 2.75em;
  left: 0.85em;
  bottom: 0.4em;
  background-color: #ddd;
  transform: rotate(15deg) skewX(15deg);
}

.switch-right {
  right: 0.5em;
  bottom: 0;
  background-color: #bd5757;
  color: #fff;
}

.switch-left::before,
.switch-right::before {
  content: "";
  position: absolute;
  width: 0.4em;
  height: 2.45em;
  bottom: -0.45em;
  background-color: #ccc;
  transform: skewY(-65deg);
}

.switch-left::before {
  left: -0.4em;
}

.switch-right::before {
  right: -0.375em;
  background-color: transparent;
  transform: skewY(65deg);
}

input:checked + .switch-left {
  background-color: #0084d0;
  color: #fff;
  bottom: 0px;
  left: 0.5em;
  height: 2.5em;
  width: 3em;
  transform: rotate(0deg) skewX(0deg);
}

input:checked + .switch-left::before {
  background-color: transparent;
  width: 3.0833em;
}

input:checked + .switch-left + .switch-right {
  background-color: #ddd;
  color: #888;
  bottom: 0.4em;
  right: 0.8em;
  height: 2.4em;
  width: 2.75em;
  transform: rotate(-15deg) skewX(-15deg);
}

input:checked + .switch-left + .switch-right::before {
  background-color: #ccc;
}

/* Keyboard Users */

input:focus + .switch-left {
  color: #333;
}

input:checked:focus + .switch-left {
  color: #fff;
}

input:focus + .switch-left + .switch-right {
  color: #fff;
}

input:checked:focus + .switch-left + .switch-right {
  color: #333;
}
