@font-face {
  font-family: "Fraunces";
  src: url("../typefaces/fraunces-700.woff2") format("woff2");
  font-weight: 700;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("../typefaces/ibm-plex-sans-400.woff2") format("woff2");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "IBM Plex Sans";
  src: url("../typefaces/ibm-plex-sans-600.woff2") format("woff2");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}
html, body {
  margin: 0;
  padding: 0;
  background: #ebe6dc;
  color: #2a2620;
  font-family: "IBM Plex Sans", "Helvetica Neue", Arial, sans-serif;
}
body { margin: 48px 0 80px; }
.container { max-width: 520px; margin: 0 auto; padding: 0 20px; }
h1.title { font-size: 0; margin: 0 0 16px; }
h1.title img { display: block; height: 72px; width: auto; }
.game-intro { margin: 0 0 20px; font-size: 16px; line-height: 1.45; }
.court-wrap {
  position: relative;
  margin: 0 auto 28px;
  padding: 16px 72px 80px;
  box-sizing: border-box;
}
.game {
  width: 280px;
  height: 560px;
  margin: 0 auto;
  box-shadow: 0 18px 40px rgba(42,38,32,0.18);
}
.ashlar-canvas { display:block; width:100%; height:100%; padding:0; margin:0; border:none; }
.game-explanation, .game-credit { font-size: 14px; line-height: 1.5; }
.game-credit a { color: #2a2620; text-decoration: underline; }
hr { border: none; border-top: 1px solid #cfc6b8; margin: 24px 0; }
@media screen and (max-width: 520px) {
  h1.title img { height: 52px; }
  .court-wrap { padding: 8px 56px 72px; }
  .game { width: 220px; height: 440px; }
}

.blockrain-game-holder {
  position: relative;
  padding: 0;
  margin: 0;
  color: #ffffff;
  font-size: 18px;
  line-height: 140%;
}

/* Touch Controls */
.blockrain-touch {
  position: absolute;
  width: 50px;
  height: 50px;
  display: block;
  border-radius: 100%;
  border: 1px solid white;
  background: rgba(255,255,255,0.2);
  z-index: 10;

  -webkit-touch-callout: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
  user-select: none;

  line-height: 50px;
  text-align: center;
}
.blockrain-touch:active {
  background: rgba(255,255,255,0.3);
}

.blockrain-touch-left {
  left: -60px;
  bottom: 10px;
}
.blockrain-touch-left::after {
  content: "<";
}
.blockrain-touch-right {
  right: -60px;
  bottom: 10px;
}
.blockrain-touch-right::after {
  content: ">";
}

.blockrain-touch-rotate-left {
  left: -60px;
  bottom: 80px;
}
.blockrain-touch-rotate-left::after {
  content: "<o";
}

.blockrain-touch-rotate-right {
  right: -60px;
  bottom: 80px;
}
.blockrain-touch-rotate-right::after {
  content: "o>";
}

.blockrain-touch-drop {
  left: 50%;
  margin-left: -25px;
  bottom: -60px;
}
.blockrain-touch-drop::after {
  content: ".";
}

/* Buttons */
.blockrain-btn {
  position: relative;
  display: inline-block;
  background: none;
  color: #ffffff;
  text-decoration: none;
  border: 2px solid #ffffff;
  padding: 15px 30px;
  font-size: 18px;
  text-align: center;
  cursor: default;
}
.blockrain-btn::before {
  position: absolute;
  content: "";
  top: 100%;
  left: 0px;
  bottom: 0px;
  right: 0px;
  border: 2px solid #ffffff;
  border-top: none;
  border-right: none;
  transition: all 0.2s ease;
}
.blockrain-btn::after {
  position: absolute;
  content: "";
  top: 0px;
  left: 100%;
  bottom: 0px;
  right: 0px;
  border: 2px solid #ffffff;
  border-left: none;
  border-bottom: none;
  transition: all 0.2s ease;
}

.blockrain-btn:hover::before {
  left: 5px;
  bottom: -8px;
  right: -8px;
}
.blockrain-btn:hover::after {
  top: 5px;
  bottom: -8px;
  right: -8px;
}


/* Score */
.blockrain-score-holder {
  position: absolute;
  top: 20px;
  right: 20px;
  text-align: right;
}
.blockrain-score-msg {
  font-size: 14px;  
  line-height: 100%;
  margin-bottom: 0.2em;
}
.blockrain-score-num {
  font-size: 20px;
  font-weight: bold;
}

/* Menu */
.blockrain-start-holder, .blockrain-game-over-holder {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;

  background: rgba(0,0,0,0.8);
  text-align: center;
}
.blockrain-start, .blockrain-game-over {
  position: absolute;
  top: 50%;
  width: 100%;
  transform: translateY(-50%);
}

.blockrain-start-msg, .blockrain-game-over-msg {
  font-size: 18px;
  margin-bottom: 30px;
}


.blockrain-game-holder { font-family: "IBM Plex Sans", "Helvetica Neue", Arial, sans-serif; color: #ebe6dc; }
.blockrain-btn {
  color: #ebe6dc;
  border-color: #d9d0c1;
  font-family: "IBM Plex Sans", sans-serif;
  font-weight: 600;
  background: #6b5840;
  border-radius: 8px;
}
.blockrain-btn::before, .blockrain-btn::after { border-color: #6b5840; display: none; }
.blockrain-start-holder, .blockrain-game-over-holder {
  background: rgba(47,43,38,0.82);
  color: #ebe6dc;
}
.blockrain-score-holder { color: #ebe6dc; }
.blockrain-touch { border-color: #6b5840; background: rgba(107,88,64,0.35); color: #2a2620; }
