#overlay {
  padding-left: 0;
  padding-right: 0;
  margin-left: auto;
  margin-right: auto;
  display: block;
  width: 960px;
  position: relative;
  height: 480px;
  z-index: 1;
  background-color: #000;
}

#canvas {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 0;
}

#prog-bar {
  width: 1%;
}

#loading {
  position: absolute;
  top: 35%;
  width: 100%;
}

#gameover {
  position: absolute;
  padding-top: 15%;
  width: 100%;
  background-color: green;
  z-index: 10;
  height: 100%;
  text-align: center;
  color: #eaeaea;
}

.progress {
  width: 95%;
  margin: 0 auto;
}

#loading h1 {
  color: #fafafa;
  text-align: center;
}

.control-button {
  margin: 1% auto;
}

.guide {
  text-align: center;
}

.center {
  margin: 0 auto;
  width: 80%;
}

.hide {
  display: none !important;
}

/* breaks accessibility but these look ugly */
* {
  outline: none !important;
}

#mainMenu {
  position: absolute;
  width: 100%;
  height: 100%;
  z-index: 2;
  margin: 0;
  background-color: rgba(0, 0, 0, 0.25);
}

#mainMenu div {
  width: 60%;
  margin: 15% 20% 0;
  text-align: center;
}

#mainMenu h1 {
  color: #fafafa;
  text-shadow: -1px -1px 0 #000,
                1px -1px 0 #000,
               -1px  1px 0 #000,
                1px  1px 0 #000;
   margin-bottom: 20px;
}

.player {
  border-radius: 3px;
  border: 1px solid #000;
  display: block;
  position: absolute;
  width: 200px;
  top: 5px;
  text-align: center;
  background-color: rgba(128, 128, 128, 0.75);
  border-color: rgb(128, 128, 128);
}

.player ul {
  display: inline-block;
  list-style-type: none;
  margin: 0;
  padding: 0;
  overflow: hidden;
}

.player ul li {
  float: left;
  padding: 0;
  margin: 0 3px;
  width: 20px;
  height: 20px;
  text-align: center;
  display: block;
  border-radius: 20px;
}

.player ul li.pocketed {
  background-color: #3d3d3d;
}

.player1 {
  left: 5px;
}

.player.active {
  background-color: rgba(152, 251, 152, 0.75);
  border-color: rgb(152, 251, 152);
}

.player2 {
  left: 755px;

}

.player h5 {
  margin: 0;
  padding: 0;
  margin-top: 2px;
  margin-left: 3px;
  margin-bottom: 3px;
  color: #eaeaea;
  text-shadow: -1px -1px 0 #3d3d3d,
                1px -1px 0 #3d3d3d,
               -1px  1px 0 #3d3d3d,
                1px  1px 0 #3d3d3d;
}

#controlsHud {
  z-index: 2;
  position: absolute;
}

.shootControls {
  background-color: rgba(255, 255, 255, 0.75);
  border-radius: 3px;
  border: 1px solid #000;
  display: block;
  position: absolute;
  width: 200px;
  top: 395px;
  left: 380px;
  text-align: center;
}

.power {
  width: 95%;
  margin: 0 auto;
}

.power form, .power input {
  padding: 0;
  margin: 0;
}

#btn_ball {
  width: 95%;
  margin-bottom: 2px;
  margin-top: 2px;
}

.gamelog {
  background-color: rgba(0, 0, 0, 0.25);
  border-radius: 3px;
  border: 1px solid #000;
  display: block;
  position: absolute;
  width: 300px;
  top: 450px;
  left: 5px;
  text-align: center;
  z-index: 2;
  height: 150px;
}

.gamelog {
  text-align: left;
  margin: 0;
  margin-left: 3px;
  color: #dadada;
  height: 14px;
}

.gamelog {
  height: 20px;
  padding: 0 3px;
}

.gamelog:hover {
  height: 130px;
  top: 340px;
}

.gamelog li {
  display: none;
}

.gamelog li:nth-last-child(-n+1) {
  display: block;
}

.gamelog:hover li:nth-last-child(-n+6) {
  display: block;
}

.gamelog li {
  margin: 0;
  padding: 0;
  margin-top: 0px;
}

.timer {
  background-color: rgba(255, 255, 255, 0.75);
  border-radius: 3px;
  border: 1px solid #000;
  display: block;
  position: absolute;
  width: 50px;
  height: 50px;
  top: 420px;
  left: 900px;
  text-align: center;
  font-size: 36px;
  z-index: 1;
}

.player.solid span:before {
  content: 'Solid';
}

.player.striped span:before {
  content: 'Striped';
}
.player.unknown span:before {
  content: '?';
}


#stats {
    position: absolute;
    top: 420px;
    left: 810px;
    z-index: 1;
}

.player ul li {
  font-size: 10px;
  line-height: 19px;
  text-align: center;
}

.player ul li::after {
  display: block;
  background-color: white;
  width: 12px;
  height: 12px;
  border-radius: 12px;
  margin-top: -15px;
  content: '';
  margin-left: 4px;
  z-index: 10;
}

.player.striped ul li::before {
  background-image: linear-gradient(#fff 13%, transparent 13%, transparent 87%, #fff 13%);
}

.player.solid ul li::before {
  background-image: none;
}

.player ul li::before {
  display: block;
  border: 1px solid #000;
  width: 20px;
  height: 20px;
  border-radius: 20px;
  margin-top: 0;
  content: '';
  margin-bottom: -20px;
}


.player ul li:nth-child(1) {
  background-color: #f5c61f;
}

.player ul li:nth-child(2) {
  background-color: #123ecd;
}

.player ul li:nth-child(3) {
  background-color: #cd1b12;
}

.player ul li:nth-child(4) {
  background-color: #8412cd;
}

.player ul li:nth-child(5) {
  background-color: #ff7f00;
}

.player ul li:nth-child(6) {
  background-color: #269c0f;
}

.player ul li:nth-child(7) {
  background-color: #a20000;
}

.player ul li.pocketed {
  opacity: 0.5;
}

.player.unknown ul li {
  background-color: #3d3d3d;
}
