/*
===============================================================================
style.css

Description: contains all the styles for the pages on the game.

    Project: Synonyms Game
     Author: Augusto A. Peres Goncalez
 Created on: 01-16-18
 Updated on: 02-16-18
===============================================================================
*/

/* DEFINE HERE THE HEIGHT OF ELEMENTS ON THE GAME */
:root {
  --input-height: 5em;
  --input-info-height: 3em;
  --font-size-info: 1.5em;
}

* {
  box-sizing: border-box;
}

html {
  font-size: 12px;
  font-weight: 300;
  -webkit-font-smoothing: antialiased;
}

html, input {
  font-family:
    "HelveticaNeue-Light",
    "Helvetica Neue Light",
    "Helvetica Neue",
    Helvetica,
    Arial,
    "Lucida Grande",
    sans-serif;
}

html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}

button {
  outline: none;
}

.userlog {
  display: none;
  background-color: green;
  width: 5em;
  height: 2em;
  font-size: 0.7em;
  position: fixed;
  bottom: 10px;
  right: 10px;
  z-index: 10;
}

.sound-on, .sound-off {
  position: fixed;
  bottom: 10px;
  right: 10px;
  z-index: 10;
}

#soundOption {
  font-size: 1.5em;
  cursor: pointer;
  float:right;
}

.messages { white-space:pre-wrap; }

ul {
  list-style: none;
  word-wrap: break-word;
}

/* Pages */
.pages {
  height: 100%;
  margin: 0;
  padding: 0;
  width: 100%;
}

/* -------------------- FOR LOGIN PAGE --------------------- */

.login.page, .chatArea, .gameAreaAsync {
  background-image: url("./../images/bkg_small.png");
  background-color: #4789D8;
  background-size: auto 100%;
  background-repeat: repeat-x;
  margin: auto;
  height:100%;
  width: 100%;
  max-width: 800px;
  overflow: hidden;
  z-index:2;
}

.login.page .title, .headerSection {
  color: white;
  margin: auto;
  margin-top: 0.2em;
  margin-bottom: 0.3em;
  height: 9%;
  width: 100%;
  max-width: 700px;
}

.headerSection {
  height: 11%;
}

.title div {
  height: 100%;
  text-align: center;
}

.title div img {
  max-height: 100%;
}

.imgSettings {
  margin-top: 1em;
  width: 40%;
}

.imgTitle {
  margin-top: 0.7em;
  width: 90%;
}

.imgCharacters {
  /*margin-top: -0.2em;*/
  margin-left: -1em;
  height: 90%;
  /*height: 180% !important;*/
}

.login.page .form, .syncGameContent, .asyncGameContent, .endGameContainer{
  background: white;
  border-radius: 20px;
  position: relative;
  text-align: center;
  margin: auto;
  height: 90%;
  width: 92%;
}

.syncGameContent, .asyncGameContent, .endGameContainer{
  text-align: left;
  padding-top: 5%;
  height: 89%;
}

.topShadow {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 100;
}

.bottomShadow {
  position: absolute;
  bottom: 0;
  left: 0;
  width: 100%;
  z-index: 100;
}

.login.page .usernameInputSection {
  position: absolute;
  left: 0;
  bottom: 50%;
  transform: translateY(50%);
  display: inline-block;
  width: 100%;
  z-index: 2;
  -webkit-transition: left 0.8s linear, visibility 0s;
  -moz-transition: left 0.8s linear, visibility 0s;
  -o-transition: left 0.8s linear, visibility 0s;
  transition: left 0.8s linear, visibility 0s;
}

.login.page .usernameInputSectionHidden {
  position: absolute;
  left: -100%; /* to slide on transitions */
  visibility: hidden;
  -webkit-transition: left 0.8s linear, visibility 0s;
  -moz-transition: left 0.8s linear, visibility 0s;
  -o-transition: left 0.8s linear, visibility 0s;
  transition: left 0.8s linear, visibility 0s;
}



.login.page .form .usernameInput {
  background-color: transparent;
  border: none;
  border-bottom: 3px solid #fff;
  font-size: 2em;
  letter-spacing: 3px;
  outline: none;
  padding-bottom: 0.3em;
  text-align: center;
  width: 70%;
}

.login.page .form .inputSection p {
  font-weight: bold;
}

.login.page .title, .login.page .usernameInput, .login.page p {
  color: black;
  font-weight: 100;
}

.login.page .loginImages {
  display: block;
  width: 80%;
  margin: auto;
  margin-top: 5em;
}

.login.page .loginImages img {
  display: block;
  margin: auto;
}

.login.page .loginImages p {
  font-size: 1.5em;
  font-weight: bold;
  margin-bottom: 0;
  margin-top: 1em;
  text-align: center;
}

.logoImage {
  height: 11em;
}

.oxfordLogoImage {
  height: 3em;
}

#usernameSend {
  position: relative;
  left: -2.5em;
  cursor: pointer;
  width: 2.5em;
}

/* -------------------- FOR CHOOSING ROOMS -------------------- */
.login.page .roomsContent {
  display: block;
  height: 12em;
  margin: auto;
  width: 100%;

  position: absolute;
  left: 50%;
  transform: translate(-50%, 0);
  -webkit-transition: 0.8s;
  -moz-transition: 0.8s;
  -o-transition: 0.8s;
  transition: 0.8s;
}

.login.page .roomsContentHidden {
  position: absolute;
  left: 100%;
  visibility: hidden;
  -webkit-transition: left 0.8s linear, visibility 0s;
  -moz-transition: left 0.8s linear, visibility 0s;
  -o-transition: left 0.8s linear, visibility 0s;
  transition: left 0.8s linear, visibility 0s;
}

.roomNameInput {
  background-color: transparent;
  border: none;
  border-bottom: 3px solid #fff;
  color: white;
  font-size: 1.8em;
  letter-spacing: 3px;
  outline: none;
  padding-bottom: 0.3em;
  text-align: center;
  width: 60%;
  transition: 0s;
}

.roomSelectMessage {
  font-weight: bold;
}

.invitedBy {
  color: #ffb949;
  text-decoration: underline;
}

.changeUsernameMessage {
  color: #ffb949;
  cursor: pointer;
  text-decoration: underline;
}

.switchLoginPages {
  display: block;
  margin: 1em auto;
  width: 40%;
}

.pagesIndex {
  display: block;
  margin: 0 auto;
  width: 5em;
}

#usernameIndex, #roomIndex {
  display: inline-block;
  background-color: #204F63;
  border: 0.08em solid white;
  border-radius: 50%;
  padding: 0.5em;
  text-align: center;
}

#usernameIndex {
  margin-left: 0.5em;
  margin-right: 1.2em;
}

/* to start with username selected */
#roomIndex {
  background-color: white;
}

.loginButtonInactive, .loginButtonActive {
  background-color: #2A657E;
  border: 2px solid black;
  border-radius: 0.6em;
  color: white;
  display: block;
  font-size: 1.5em;
  font-weight: bold;
  margin: 1em auto;
  height: 2em;
  width: 7em;
}

.roomButtons {
  margin-top: 2em;
}

.btnGameType {
  color: white;
  position: relative;
  border: 0.3em solid;
  border-radius: 60px;
  font-size: 1em;
  font-weight: bold;
  height: 6em;
  width: 82%;
  margin: auto;
  margin-bottom: 1.3em;
  z-index: 5;
}

.btnGameType * {
  font-size: 2em;
  vertical-align: middle;
}

.lblGameType {
  float: left;
  width: 40%;
  margin: 0.4em;
  vertical-align: top;
}

.imgGameType {
  float: right;
  margin: 0.3em;
  height: 0.7em;
}

.btnFriends {
  background-color: #FECB2F;
  border-color: #FDA438;
}

.btnRandoms {
  background-color: #FC178C;
  border-color: #B21265;
}

.btnSolo {
  background-color: #41ADEB;
  border-color: #2883B8;
}

.btnPrivateRoom {
  display:  none;
  background-color: #42f45c;
  border-color: #2fb827;
}

.loginButtonActive {
  background-color: #5dad0d;
  cursor: pointer;
}

/* ------------------------------------------------ */
/* ------------------------------------------------ */


/* Chat page */
#gameAreaAsync, #gameAreaSync {
  display: none;
  position: fixed;
  width: 100%;
  height:100%;
}

/* Messages */

/* Padding bottom depends on size of input section and padding from info section */
.chatArea {
  /*padding-left: 10px;*/
  height: 100%;
  width: 100%;
}

#chatAreaSync {
  height: 100%;
}

.usersAndPoints {
  height: 1em;
  font-size: 1.5em;
  font-weight: bold;
  padding: 0 1em;
  width: 100%;
}

.usersAndPoints img, .usersAndPoints span {
  height: 100%;
}

.playerIcon {
  margin-right: 0.5em;
}

.pointsIcon {
  margin-left: 0.5em;
}

.floatLeft {
  float: left;
}

.floatRight {
  float: right;
}

.wordAsync {
  font-size: 3.8em;
  font-weight: bold;
  height: 14%;
  text-align: center;
  width: 100%;
}

.titleSection {
  color: #fff;
  display: block;
  width: 100%;
  font-family: "Sorts Mill Goudy", Serif;
  text-shadow: 2px 2px #204F63;
  font-weight: 100;
  font-size: 2em;
  text-align: center;
}

.btnSkip {
  border-radius: 10px;
  display: block;
  margin: auto;
  height: 3em;
  width: 8em;
}

.titleSync, .titleAsync {
  font-size: 1.8em;
  width: 100%;
  text-align: center;
  margin-bottom: 0.5em;
}

.wordSync {
  font-size: 3.8em;
  font-weight: bold;
  height: 14%;
  text-align: center;
  width: 100%;
}

.possibleAnswersContainer {
  display: none;
  height: 14%;
  width: 100%;
  padding: 0 0.3em;
}

.possibleAnswersSync {
  width: 100%;
  overflow-x: scroll;
  overflow-y: hidden;
  white-space: nowrap;
  font-size: 2em;
}

.possibleAnswersSync::-webkit-scrollbar {
  width: 1px;
}

.possibleAnswersSync::-webkit-scrollbar-thumb {
  background-color: #653564;
  border-radius: 10px;
  width: 1px;
}

.players {
  height: 72%;
  max-height: 90%;
  width: 100%;
  overflow-y: auto;
}

.player {
  color: white;
  position: relative;
  background-color: #eeecea;
  border-radius: 2.5em;
  font-size: 1.5em;
  font-weight: bold;
  /*opacity: 0.8;*/
  height: 55px;
  width: 300px;
  margin: auto;
  margin-bottom: 1em;
  z-index: 5;
}

.player span {
  line-height: 55px;
}

.playerName {
  position: absolute;
  margin-left:0;
  bottom: 0;
  font-weight: bold;
  font-size: 0.5em;
  z-index: 10;
  text-align: center;
  text-shadow: 1px 1px 1px #516077;
}

.playerPoints, .playerRoundPoints {
  color: white;
  text-align: center;
}

.playerRoundPoints {
  font-size: 1em;
}

.player * {
  height: 100%;
}

.thisPlayer {
  position: relative;
  margin-bottom: 2em;
}

.thisPlayerElem {
  border: 0.2em solid #87316E;
  box-shadow: 0.3em 0.3em 0.3em #E8E8E8;
}

.correctAnimation {
  display: none;
  background-image: url(./../images/correct-spritesheet-mobile.png);
  position: absolute;
  left: calc(50% - 175px);
  top: -30px;
  height: 112px;
  width: 352px;
  z-index: 100;
}

.wrongAnimation {
  display: none;
  background-image: url(./../images/wrong-spritesheet-mobile.png);
  position: absolute;
  left: calc(50% - 161px);
  top: 0;
  /*opacity: 0.8;*/
  height: 60px;
  width: 322px;
}

.readyAnimation {
  display: none;
  background-image: url(./../images/ready-spritesheet-mobile.png);
  position: absolute;
  left: calc(50% - 150px);
  top: 0;
  height: 55px;
  width: 300px;
}

.profilePic {
  position: absolute;
  top: calc(50% - 1.1em);
  margin-left: 0.5em;
  border-radius: 50%;
  height: 2.2em;
}

.playerInitialReady img {
  display: block;
  height: 2em;
  width: 2em;
  position: absolute;
  top: calc(50% - 1em);
  left: calc(50% - 1em);
  margin: auto;
}

.playerInput {
  color: white;
  font-weight: bold;
  outline: none;
  border: none;
  background-color: transparent;
  padding-left: 1.2em;
  font-size: 1.4em;
  text-align: center;
}

/* prevents players to select hidden answers and then copying them */
.playerAnswer {
  padding-left: 1.2em;
  text-align: center;
  -moz-user-select: none;
  -webkit-user-select: none; 
  -ms-user-select:none; 
  user-select:none;
  -o-user-select:none;
}

.playerRank {
  display: none;
  color: black;
  text-align: center;
  position: absolute;
  top: -0.4em;
  left: -0.4em;
  height: 1.5em;
  width: 1.5em;
  border-radius: 50%;
  background-color: #6DFECD;
  border: 0.15em solid white;
  z-index: 100; /* TODO: MAKE THIS WORK!!; */
}

.playerSubmit img {
  display: block;
  height: 2em;
  width: 2em;
  position: absolute;
  top: calc(50% - 1em);
  right: 1em;
}

.blurry {
  filter: blur(6px);
}

.hidden {
  display: none;
}

.modMessage {
  background-color: white;
  border-radius: 10px;
  /*display: none;*/
  height: 1.2em;
  width: 50%;
  margin: auto;
  margin-top: 1.5em;
  text-align: center;
}

.possibleAnswersSection {
  display: none;
  width: 100%;
}

.possibleAnswersTitle {
  display: block;
  text-align: center;
  width: 80%;
  margin: auto;
  font-family: "Sorts Mill Goudy", Serif;
  text-shadow: 2px 2px #204F63;
  margin-bottom: 0.3em;
  color: #fff;
  font-weight: 100;
  font-size: 2.5em;
}

.warningScreen {
  display: none;
  height: 100%;
  width: 100%;
  background-color: white;
}

.warningTitle {
  color: white;
  display: none;
  position: fixed;
  top: 0.8em;
  right: 10%;
  width: 80%;
  text-align: center;
  font-size: 4em;
  font-weight: bold;
  z-index: 1001;
}

.timerBar {
  position: relative;
  border-radius: 10px;
  height: 0.15em;
  width: 95%;
  background-color: #BDB9B9;
  margin: 1em auto;
}

.timerBarValue {
  position: absolute;
  top: calc(50% - 0.2em);
  border-radius: 10px;
  height: 0.4em;
  width: 1%;
  background-color: #5C29A6;
}

.timerAnimation {
  display: none;
  background-image: url(./../images/timer-spritesheet.png);
  position: absolute;
  top: calc(50% - 22.5px);
  left: calc(50% - 80px);
  height: 45px;
  width: 160px;
  z-index: 10;
}

.timesUp {
  color: white;
  font-weight: bold;
  display: none;
  position: absolute;
  top: calc(50% - 0.5em);
  left: calc(50% - 5em);
  height: 1em;
  width: 10em;
  font-weight: bold;
  z-index: 11;
  text-align: center;
}

.timerInGame {
  border-radius: 50%;
  margin: 1.5em auto;
  position: relative;
  width: 4em;
  height: 4em;
  overflow: hidden;
}

.timeValue {
  position: absolute;
  top: calc(50% - 8px); left: calc(50% - 7px);
  text-align: center;
  display: flex;
  align-items: center;
}

.userPoints {
  position: absolute;
  top: 1em;
  right: 1em;
  font-size: 2em;
  color: #20f215;
}

/* Input */

.inputAndButton {
  /*border: 0.2em solid #F7F7F7;*/
  /*display: none;*/
  height: 5em;
  margin: auto;
  margin-bottom: 2em;
  margin-top: 2em;
  width: 90%;
  z-index: 1;
}

.inputMessage {
  background-color: #eeecea;
  border-radius: 2.5em;
  height: 100%;
  width: 100%;
  outline: none;
  padding-left: 10px;
  font-size: 2em;
}

.sendButton {
  background-color: transparent;
  border: none;
  position: relative;
  right: 4em;
  height: 100%;
}

.sendButton img {
  height: 80%;
  width: 100%;
}

.readyButton {
  margin: auto;
  width: 10em;
  height: 4em;
  font-size: 2em;
  border-radius: 20px;
  background-color: #69CA6B;
}

.disconnected {
  background-color: #d6d9db;
  margin: auto;
  height:50%;
  width:75%;
  padding: 10%;
}

.disconnected p {
  font-size: 3em;
  text-align: center;
}

.disconnected a {
  display: block;
  background-color: #005893;
  color: white;
  font-weight: bold;
  margin: auto;
  padding: 2%;
  text-align: center;
  text-decoration: none;
}

/* for spans in the chat message */


.points {
  color: #079b39;
  font-weight: bold;
}

.user {
  font-style: italic;
  font-weight: bold;
}

.bonusPoints {
  color: #0359af;
}

.endGamePlayer {
  position: relative;
  background-color: #d8e7ff;
  font-weight: bold;
  /*opacity: 0.8;*/
  height: 7em;
  width: 100%;
  margin-bottom: 1em;
  z-index: 5;
}

/*.picAndName img, .picAndName span {
  display: inline-block;
}*/

.picAndName {
  width: 80%;
  height: 1em;
  margin: 0 auto;
  text-align: center;
}

.endGameProfilePic {
  height: 1em;
}

.playerPointsEndGame, .playerNumOfFirstRight, .playerNumOfRight {
  color: green;
}

.playerNumOfWrong {
  color: red;
}

.endGameStats {
  position: absolute;
  bottom: 0;
  width: 100%;
}

.endGameStats tr td {
  text-align: center;
}

.wipeScreenLeft, .wipeScreenRight {
  position: fixed;
  background-image: url(./../images/random-bkg.png);
  background-color: #8A1293;
  background-size: auto 100%;
  background-repeat: repeat-x;
  height: 100%;
  width: 50%;
  z-index: 999;
}

.wipeScreenLeft {
  left: -50%;
}

.wipeScreenRight {
  right: -50%;
}

.charactersAnimation {
  display: none;
  background-image: url(./../images/characters-spritesheet.png);
  position: fixed;
  left: 0;
  bottom: 0;
  height: 550px;
  width: 284px;
  z-index: 1000;
}

.charactersTest, .wipePurple, .wipeWhite, .wipeYellow {
  position: fixed;
  left: -284px;
  bottom: -550px;
  z-index: 1000;
}

#tests {
  position: fixed;
  bottom: 20px;
}

.btnInviteFriendsSync {
  display:  none;
  background-color: #d3e8d3;
  border-radius: 2.5em;
  font-size: 1.5em;
  font-weight: bold;
  height: 55px;
  width: 110px;
  margin: auto;
  z-index: 5;
}

/* ------- for modal -------- */
#home {
  cursor: pointer;
  font-size: 1.5em;
  position:  fixed;
  bottom: 50px;
  right: 10px;
  z-index: 10;
}

.modal {
    display: none; /* Hidden by default */
    position: fixed; /* Stay in place */
    z-index: 1; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: rgb(0,0,0); /* Fallback color */
    background-color: rgba(0,0,0,0.4); /* Black w/ opacity */
}

/* Modal Content/Box */
.modal-content {
    background-color: #fefefe;
    margin: 15% auto; /* 15% from the top and centered */
    padding: 20px;
    border: 1px solid #888;
    width: 80%; /* Could be more or less, depending on screen size */
}

.modal-content p {
  text-align: center;
}

.modalCenter {
  display: block;
  margin: auto;
  width: 80%;
}

/* The Close Button */
.closeModal {
    color: #aaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
}

.closeModal:hover,
.closeModal:focus {
    color: black;
    text-decoration: none;
    cursor: pointer;
}

.modalButtons {
  display: flex;
  margin: auto;
  width: 100%;
  justify-content: center;
  align-items: center;
}

.btnModal {
  background-color: #39f949;
  border: 2px solid black;
  border-radius: 10px;
  display: inline-block;
  margin: 0.3em 1em;
  height:  2em;
  width: 30%;
}

.btnModal.btnNo {
  background-color: #f96b6b;
}
/* ------------------------ */

.col-s-1 {width: 8.33%;}
.col-s-2 {width: 16.66%;}
.col-s-3 {width: 25%;}
.col-s-4 {width: 33.33%;}
.col-s-5 {width: 41.66%;}
.col-s-6 {width: 50%;}
.col-s-7 {width: 58.33%;}
.col-s-8 {width: 66.66%;}
.col-s-9 {width: 75%;}
.col-s-10 {width: 83.33%;}
.col-s-11 {width: 91.66%;}
.col-s-12 {width: 100%;}

[class*="col-"] {
    float: left;
}

/* increase size of the font if on tablets */
@media only screen and (min-width: 768px) {
  :root {
    --input-height: 3.2em;
    --input-info-height: 2em;
  }

  html {
    font-size: 14px;
  }

  /* -------------------- FOR LOGIN PAGE --------------------- */
  .login.page .form .usernameInput {
    width: 50%;
  }

  .logoImage {
    height: 11em;
  }

  .oxfordLogoImage {
    height: 3.5em;
  }

  .login.page .loginImages p {
    font-size: 1.1em;
    margin-top: 0.5em;
  }

  .login.page .form, .syncGameContent {
    border-radius: 35px;
  }

  .col-1 {width: 8.33%;}
  .col-2 {width: 16.66%;}
  .col-3 {width: 25%;}
  .col-4 {width: 33.33%;}
  .col-5 {width: 41.66%;}
  .col-6 {width: 50%;}
  .col-7 {width: 58.33%;}
  .col-8 {width: 66.66%;}
  .col-9 {width: 75%;}
  .col-10 {width: 83.33%;}
  .col-11 {width: 91.66%;}
  .col-12 {width: 100%;}
}

/* increase size of the font if on desktop */
/*@media only screen and (min-width: 890px) {
  :root {
    --input-height: 3.2em;
    --input-info-height: 2em;
  }

  html {
    font-size: 16px;
  }

  .logoImage {
    height: 9em;
  }

  .oxfordLogoImage {
    height: 3em;
  }

  .login.page .form, .syncGameContent {
    border-radius: 50px;
  }

  .player {
    height: 115px;
    width: 605px;
  }

  .player span {
    line-height: 115px;
  }

  .correctAnimation {
    display: none;
    background-image: url(./../images/correct-spritesheet-desktop.png);
    position: absolute;
    top: -57px;
    left: calc(50% - 350px);
    height: 222px;
    width: 700px;
    z-index: 100;
  }

  .wrongAnimation {
    display: none;
    background-image: url(./../images/wrong-spritesheet-desktop.png);
    position: absolute;
    top: -7px;
    opacity: 0.8;
    left: calc(50% - 324.5px);
    height: 129px;
    width: 649px;
  }

  .readyAnimation {
    display: none;
    background-image: url(./../images/ready-spritesheet-desktop.png);
    position: absolute;
    top: 0;
    left: calc(50% - 302.5px);
    height: 115px;
    width: 605px;
  }
}*/

/* decrease size of font in smaller devices */
@media only screen and (max-width: 400px) {
  :root {
    --input-height: 5em;
    --input-info-height: 3em;
    --font-size-info: 1.7em;
  }

  html {
    font-size: 10px;
  }

  .player {
    height: 48px;
    width: 260px;
  }

  .player span {
    height: 48px;
  }

  .correctAnimation {
    display: none;
    background-image: url(./../images/correct-spritesheet-mobileSml.png);
    position: absolute;
    left: calc(50% - 150px);
    height: 96px;
    width: 300px;
    z-index: 100;
  }

  .wrongAnimation {
    display: none;
    background-image: url(./../images/wrong-spritesheet-small.png);
    position: absolute;
    /*opacity: 0.8;*/
    top: 0;
    left: calc(50% - 140px);
    height: 52px;
    width: 280px;
  }

  .readyAnimation {
    display: none;
    background-image: url(./../images/ready-spritesheet-small.png);
    position: absolute;
    top: 0;
    left: calc(50% - 130px);
    height: 48px;
    width: 260px;
  }

  .btnRoomSelected, .btnRoomNotSelected {
    display: inline-block;
    margin: 0.8em 1.8em 0.2em 1.8em;
  }

  #btnPublicDesc {
    vertical-align: top;
    margin-right: 6.2em;
  }
}
