/* Animations */

@keyframes blink {
  0% {
    visibility: visible;
  }
  
  50% {
    visibility: visible;
  }
  
  51% {
    visibility: hidden;
  }
  
  100%
  {
    visibility: hidden;
  }
}

/* Element */
*
{
  box-sizing: border-box;
}

html, body
{
  color: #111;
  font-family: Power Clear, Consolas, monaco, monospace;
  font-size: 1rem;
  margin: 0;
  padding: 0;
}

/* ID */
#frame
{
  position: relative;
  
  overflow: hidden;
}

#frame.hide-labels .room_label
{
  opacity: 0.0;
}

#player
{
  position: fixed;
  
  background-color: blue;
  opacity: 1.0;
  z-index: 9001;
  
  -webkit-transition: all 0.1s linear, opacity 1s linear;
          transition: all 0.1s linear, opacity 1s linear;
  
  /*background: url(../img/mage.png) no-repeat;*/
}

#speechBubble
{
  position: fixed;
  left: 50%;
  top: 20%;
  
  background-color: white;
  border: 1rem solid black;
  color: #333;
  font-family: Power Clear, Consolas, monaco, monospace;
  margin-left: -300px;
  opacity: 0.0;
  padding: 1rem;
  width: 600px;
  z-index: 9004;
  
  -webkit-transition: opacity 0.5s ease-in-out;
          transition: opacity 0.5s ease-in-out;
}

@media (max-width: 600px)
{
  #speechBubble
  {
    margin-left: -150px;
    width: 300px;
  }
}

#speechBubble.visible {
  opacity: 1.0;
}

#speechBubble .speech-bubble-content
{
  margin-bottom: 0.5rem;
}

#speechBubble .speech-bubble-content::after
{
  /* clearfix */
  content: ' ';
  clear: both;
  display: table;
}

#speechBubble .speech-bubble-content img {
  float: left;
  margin-bottom: 1rem;
  margin-right: 1rem;
}

#speechBubble .speech-bubble-content img.right {
  float: right;
}

#speechBubble .speech-bubble-next
{
  color: black;
  display: none;
  text-align: right;
}

#speechBubble.visible .speech-bubble-next
{
  display: block;
}

#speechBubble .speech-bubble-next .caret
{
  animation: blink 1s linear infinite;
}

/* Class */
.door
{
  position: absolute;
  
  background-color: #444;
  opacity: 1.0;
  
  -webkit-transition: opacity 1s linear;
          transition: opacity 1s linear;
}

.door.hidden
{
  background-color: #353535;
  
  /*background: #000 url("../img/wall.png") !important;*/
  /*background-size: 100% 100% !important;*/
}

.door.opened
{
  top: -9999px;
  left: -9999px;
}

.door_top
{
  left: 40%;
  top: 0px;
  
  height: 50px;
  width: 20%;
  
  /*background: #000 url("../img/door_top.png");*/
  /*background-size: 100% 100%;*/
}

.door_bottom
{
  top: 100%;
  left: 40%;
  
  height: 50px;
  width: 20%;
  
  /*background: #000 url("../img/door_bottom.png");*/
  /*background-size: 100% 100%;*/
}

.door_left
{
  top: 40%;
  left: 0px;
  
  height: 20%;
  width: 50px;
  
  /*background: #000 url("../img/door_left.png");*/
  /*background-size: 100% 100%;*/
}

.door_right
{
  top: 40%;
  left: 100%;
  
  height: 20%;
  width: 50px;
  
  /*background: #000 url("../img/door_right.png");*/
  /*background-size: 100% 100%;*/
}

.entity
{
  position: absolute;
}

.entity.entity_npc
{
  background-color: limegreen;
  height: 40px;
  width: 40px;
}

.entity_bottom
{
  left: calc(50% - 20px);
  top: calc(75% - 20px);
  
  transform: rotate(0deg);
}

.entity_bottom_left
{
  left: calc(25% - 20px);
  top: calc(75% - 20px);
  
  transform: rotate(45deg);
}

.entity_bottom_right
{
  left: calc(75% - 20px);
  top: calc(75% - 20px);
  
  transform: rotate(-45deg);
}

.entity_left
{
  left: calc(25% - 20px);
  top: calc(50% - 20px);
  
  transform: rotate(90deg);
}

.entity_middle
{
  left: calc(50% - 20px);
  top: calc(50% - 20px);
  
  transform: rotate(0deg);
}

.entity_right
{
  left: calc(75% - 20px);
  top: calc(50% - 20px);
  
  transform: rotate(-90deg);
}

.entity_top
{
  left: calc(50% - 20px);
  top: calc(25% - 20px);
  
  transform: rotate(180deg);
}

.entity_top_left
{
  left: calc(25% - 20px);
  top: calc(25% - 20px);
  
  transform: rotate(-135deg);
}

.entity_top_right
{
  left: calc(75% - 20px);
  top: calc(25% - 20px);
  
  transform: rotate(135deg);
}

.room
{
  position: absolute;

  background-color: #555;
  overflow: hidden;
  
  -webkit-transition: all 2s ease-in-out;
          transition: all 2s ease-in-out;
}

.room_label
{
  position: absolute;
  
  color: #666;
  cursor: default;
  display: inline-block;
  font-family: 'Rock Salt', cursive;
  margin-top: -50px;
  min-height: 100px;
  opacity: 1.0;
  text-align: center;
  
  -webkit-touch-callout: none;
    -webkit-user-select: none;
     -khtml-user-select: none;
       -moz-user-select: none;
        -ms-user-select: none;
            user-select: none;
  
  -webkit-transition: opacity 0.5s linear;
          transition: opacity 0.5s linear;
}

.room_label_bottom
{
  left: 10%;
  right: 10%;
  top: 80%;
}

.room_label_bottom_left
{
  left: 5%;
  right: 60%;
  top: 80%;
}

.room_label_bottom_right
{
  left: 60%;
  right: 5%;
  top: 80%;
}

.room_label_left
{
  left: 10%;
  right: 60%;
  top: 50%;
}

.room_label_middle
{
  left: 10%;
  right: 10%;
  top: 50%;
}

.room_label_right
{
  left: 60%;
  right: 10%;
  top: 50%;
}

.room_label_top
{
  left: 10%;
  right: 10%;
  top: 20%;
}

.room_label_top_left
{
  left: 5%;
  right: 60%;
  top: 20%;
}

.room_label_top_right
{
  left: 60%;
  right: 5%;
  top: 20%;
}

.sign
{
  position: absolute;
  
  background-color: #876451;
  border: 3px solid #513c31;
  display: inline-block;
  height: 100px;
  margin-top: -50px;
  margin-left: -75px;
  width: 150px;
  
  /*background: url("../img/sign.png");
  background-size: 100% 100%;*/
}

.sign > div
{
  position: fixed;
  bottom: 25%;
  left: -75%;
  right: 125%;
  top: 25%;
  
  background-color: #876451;
  border: 1rem solid #513c31;
  padding: 1rem;
  text-align: center;
  z-index: 9002;
  
  -webkit-transition: all .5s ease-in-out;
          transition: all .5s ease-in-out;
  
  /*background: url("../img/sign.png");
  background-size: 100% 100%;*/
}

.sign > div .container
{
  height: 100%;
  overflow-y: auto;
  width: 100%;
}

.sign_bottom
{
  left: 50%;
  top: 75%;
}

.sign_bottom_left
{
  left: 25%;
  top: 75%;
}

.sign_bottom_right
{
  left: 75%;
  top: 75%;
}

.sign_left
{
  left: 25%;
  top: 50%;
}

.sign_middle
{
  left: 50%;
  top: 50%;
}

.sign_right
{
  left: 75%;
  top: 50%;
}

.sign_top
{
  left: 50%;
  top: 25%;
}

.sign_top_left
{
  left: 25%;
  top: 25%;
}

.sign_top_right
{
  left: 75%;
  top: 25%;
}

.teleporter
{
  position: absolute;
  
  background-color: #FFF;
  border: 1px solid #000;
  border-radius: 100%;
  height: 50px;
  margin-left: -25px;
  margin-top: -25px;
  width: 50px;
}

.teleporter_bottom
{
  bottom: 10%;
  left: 50%;
}

.teleporter_left
{
  left: 10%;
  top: 50%;
}

.teleporter_middle
{
  left: 50%;
  top: 50%;
}

.teleporter_right
{
  right: 10%;
  top: 50%;
}

.teleporter_top
{
  left: 50%;
  top: 10%;
}

.wall
{
  position: absolute;
  
  background-color: #333;
  
  /*background: url("../img/wall.png");*/
}

.wall_top_full
{
  left: 0px;
  top: 0px;
  
  height: 50px;
  width: 100%;
}

.wall_bottom_full
{
  left: 0px;
  top: 100%;
  
  height: 50px;
  width: 100%;
}

.wall_left_full
{
  left: 0px;
  top: 0px;
  
  height: 100%;
  width: 50px;
}

.wall_right_full
{
  left: 100%;
  top: 0px;
  
  height: 100%;
  width: 50px;
}

.wall_top_left
{
  left: 0px;
  top: 0px;
  
  height: 50px;
  width: 40%;
}

.wall_top_right
{
  left: 60%;
  top: 0px;
  
  height: 50px;
  width: 40%;
}

.wall_bottom_left
{
  left: 0px;
  top: 100%;
  
  height: 50px;
  width: 40%;
}

.wall_bottom_right
{
  left: 60%;
  top: 100%;
  
  height: 50px;
  width: 40%;
}

.wall_left_top
{
  left: 0px;
  top: 0px;
  
  height: 40%;
  width: 50px;
}

.wall_left_bottom
{
  left: 0px;
  top: 60%;
  
  height: 40%;
  width: 50px;
}

.wall_right_top
{
  left: 100%;
  top: 0px;
  
  height: 40%;
  width: 50px;
}

.wall_right_bottom
{
  left: 100%;
  top: 60%;
  
  height: 40%;
  width: 50px;
}
