html {
  box-sizing: border-box;
}
*,
*::before,
*::after {
  box-sizing: inherit;
  /* border-radius: 50%; */
}
body {
  font: 16px Poppins, sans-serif;
  background: #1a202c;
  text-align: center;
  margin: 0;
  height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  user-select: none;
  opacity: 0;
  animation: fadeIn 1s 0.5s forwards;
  overflow: hidden;
}
@keyframes fadeIn {
  100% {
    opacity: 1;
  }
}
#app {
  background: #2d3748;
  display: inline-block;
  position: relative;
  box-shadow: 0 0 0 10px #2d3748;
}
#boxCon {
  width: 720px;
  display: flex;
  flex-wrap: wrap;
}
#boxCon span {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  margin: 2px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  cursor: default;
  color: #a0aec0;
}
#boxCon span.active {
  background: #4a5568;
}
#boxCon span.stop {
  background: url('data:image/svg+xml,\
    <svg fill="rgb(45, 55, 72)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\
      <path d="M0 0h24v24H0z" fill="none"/>\
      <path d="M11.99 2C6.47 2 2 6.48 2 12s4.47 10 9.99 10C17.52 22 22 17.52 22 12S17.52 2 11.99 2zm4.24 16L12 15.45 7.77 18l1.12-4.81-3.73-3.23 4.92-.42L12 5l1.92 4.53 4.92.42-3.73 3.23L16.23 18z"/>\
    </svg>')
    no-repeat center / cover;
}
#boxCon span.otherStop {
  background: url('data:image/svg+xml,\
    <svg fill="rgb(74, 85, 104)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\
      <path d="M0 0h24v24H0z" fill="none"/>\
      <path d="M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2z"/>\
    </svg>')
    no-repeat center / 50%;
}
#bigBoxCon span {
  height: 284px;
  width: 284px;
  margin: 2px;
  position: absolute;
  top: 0;
  left: 0;
}
#coinCon span {
  width: 44px;
  height: 44px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  position: absolute;
  top: 0;
  left: 0;
  transition: 150ms;
  border-radius: 50%;
  margin: 2px;
  outline: none;
  font-size: 12px;
  font-weight: bold;
  line-height: 1;
  color: #fff;
  text-shadow: 0 2px 2px #0002;
  box-shadow: 0 0 8px #000;
  background: url('data:image/svg+xml,\
    <svg fill="white" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\
      <path d="M0 0h24v24H0z" fill="none"/>\
      <path d="M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"/>\
    </svg>')
    no-repeat center / 72%;
  transform-origin: left;
}
#coinCon span.active {
  cursor: pointer;
  animation: shadow 500ms infinite alternate ease-in;
  z-index: 200 !important;
}
@keyframes shadow {
  from {
    box-shadow: 0 0 0 4px #0004;
  }
  to {
    box-shadow: 0 0 0 24px #0004;
  }
}
#chokka {
  width: 48px;
  height: 48px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  position: absolute;
  border-radius: 50%;
  background: #0002;
  top: 0;
  left: 0;
  transition: 150ms;
}
#chokka.disabled {
  pointer-events: none;
}
#cube {
  height: 32px;
  width: 32px;
  background: #fff;
  border-radius: 4px;
  position: relative;
  color: #4a5568;
}
#cube::after {
  content: "";
  position: absolute;
  height: 6px;
  width: 6px;
  background: transparent;
  border-radius: 50%;
  left: -6px;
  top: -6px;
  transition: box-shadow 250ms;
  opacity: 0;
  box-shadow: 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor;
}
#cube[class^="v"]::after {
  opacity: 1;
}
/*

10px  10px 0 currentColor,  TOP    | LEFT 
28px  10px 0 currentColor,  TOP    | RIGHT
10px  28px 0 currentColor,  BOTTOM | LEFT 
28px  28px 0 currentColor,  BOTTOM | RIGHT
10px  19px 0 currentColor,  LEFT          
28px  19px 0 currentColor,  RIGHT         
19px  19px 0 currentColor,  CENTER        

*/
/* ONE */
#cube.v1::after {
  box-shadow: 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor;
}
/* TWO */
#cube.v2::after {
  box-shadow: 10px 19px 0 currentColor, 28px 19px 0 currentColor, 28px 19px 0 currentColor, 28px 19px 0 currentColor, 28px 19px 0 currentColor, 28px 19px 0 currentColor, 28px 19px 0 currentColor;
}
/* THREE */
#cube.v3::after {
  box-shadow: 10px 10px 0 currentColor, 28px 28px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor;
}
/* FOUR */
#cube.v4::after {
  box-shadow: 10px 10px 0 currentColor, 28px 28px 0 currentColor, 28px 10px 0 currentColor, 10px 28px 0 currentColor, 10px 28px 0 currentColor, 10px 28px 0 currentColor, 10px 28px 0 currentColor;
}
/* FIVE */
#cube.v5::after {
  box-shadow: 10px 10px 0 currentColor, 28px 28px 0 currentColor, 28px 10px 0 currentColor, 10px 28px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor, 19px 19px 0 currentColor;
}
/* SIX */
#cube.v6::after {
  box-shadow: 10px 10px 0 currentColor, 28px 28px 0 currentColor, 28px 10px 0 currentColor, 10px 28px 0 currentColor, 10px 19px 0 currentColor, 28px 19px 0 currentColor, 28px 19px 0 currentColor;
}
#cube.spin {
  animation: spin 500ms infinite linear;
}
/* winCon */
#winCon span {
  height: 96px;
  width: 96px;
  position: absolute;
  display: none;
  top: 0;
  left: 0;
}
#winCon span:nth-child(1) {
  background: url('data:image/svg+xml,\
    <svg fill="rgba(255, 255, 255, 0.25)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\
      <path d="M0 0h24v24H0z" fill="none"/>\
      <path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm11 10h2V5h-4v2h2v8zm7-14H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14z"/>\
  </svg>')
    no-repeat center / cover;
}
#winCon span:nth-child(2) {
  background: url('data:image/svg+xml,\
    <svg fill="rgba(255, 255, 255, 0.25)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\
      <path d="M0 0h24v24H0z" fill="none"/>\
      <path d="M3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm18-4H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zm-4-4h-4v-2h2c1.1 0 2-.89 2-2V7c0-1.11-.9-2-2-2h-4v2h4v2h-2c-1.1 0-2 .89-2 2v4h6v-2z"/>\
  </svg>')
    no-repeat center / cover;
}
#winCon span:nth-child(3) {
  background: url('data:image/svg+xml,\
    <svg fill="rgba(255, 255, 255, 0.25)" xmlns="http://www.w3.org/2000/svg" width="24" height="24" viewBox="0 0 24 24">\
      <path d="M0 0h24v24H0z" fill="none"/>\
      <path d="M21 1H7c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2V3c0-1.1-.9-2-2-2zm0 16H7V3h14v14zM3 5H1v16c0 1.1.9 2 2 2h16v-2H3V5zm14 8v-1.5c0-.83-.67-1.5-1.5-1.5.83 0 1.5-.67 1.5-1.5V7c0-1.11-.9-2-2-2h-4v2h4v2h-2v2h2v2h-4v2h4c1.1 0 2-.89 2-2z"/>\
  </svg>')
    no-repeat center / cover;
}
#winCon span.show {
  display: block;
}
#center {
  width: 0;
  border: 70px solid;
  position: absolute;
  top: 0;
  left: 0;
  transform: translate(290px, 290px);
}
@keyframes spin {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}
