* {
  box-sizing: border-box;
}

html {
  width: 100%;
  height: 100%;
  padding: 0px;
  margin: 0px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: #333;
  font-family: Arial, Helvetica, sans-serif;
}

body {
  position: relative;
  padding: 0px;
  margin: 0px;
  width: 100vmin;
  width: 133.3333333333svh;
  max-width: 100%;
  max-height: 100%;
  max-height: 100svh;
  display: flex;
  align-items: center;
  justify-content: center;
  aspect-ratio: 4/3;
  background-color: #aaa;
  overflow: hidden;
  flex-direction: column;
  justify-content: space-evenly;
  background-image: url(img/level0/level0.png);
  background-size: cover;
  background-repeat: no-repeat;
}
body.level1 {
  background-image: url(img/level1/level1.png);
}
body.level2 {
  background-image: url(img/level2/level2.png);
}

html.ios-firefox {
  max-height: 100% !important;
}
html.ios-firefox body {
  max-height: 100% !important;
}

.title {
  font-size: 1.5rem;
  line-height: 2.7rem;
  font-weight: bold;
  opacity: 0;
}

#grid {
  display: grid;
  background-color: #038D36;
  width: 61.65%;
  aspect-ratio: 1/1;
  grid-template-columns: repeat(5, auto);
  position: relative;
}

body.level1 #grid {
  grid-template-columns: repeat(6, auto);
}

body.level2 #grid {
  grid-template-columns: repeat(7, auto);
}

.block #grid * {
  pointer-events: none;
}

.car {
  width: calc(var(--size) / 5.8);
  width: 20%;
  height: 20%;
  position: absolute;
  z-index: 10;
  top: 0;
  left: -20%;
  transition: top 0.7s linear, left 0.7s linear, transform 0.7s linear, opacity 0.3s ease-in-out;
  pointer-events: none;
  background-image: url(img/level0/DXP.svg);
  background-size: 90% auto;
  background-position: center center;
  background-repeat: no-repeat;
  opacity: 0;
  contain: layout;
}
.car.out {
  transition: top 1s ease-out, left 1s ease-out, transform 1s ease-out, opacity 0.3s ease-in-out;
}
.car.show {
  opacity: 1;
}

.level0 .car {
  top: -1%;
  left: -22.7%;
}

.level1 .car {
  top: 0%;
  left: -20%;
  background-size: 95% auto;
  width: 16.6666666667%;
  height: 16.6666666667%;
}

.level2 .car {
  background-size: 100% auto;
  left: -15%;
  top: -1%;
  width: 14.2857142857%;
  height: 14.2857142857%;
}
.level2 .car2 {
  left: -15%;
  top: 0%;
}
.level2 .car2.startpos {
  left: -24%;
  top: 1%;
}

.tile {
  width: 100%;
  text-align: center;
  line-height: 15px;
  font-size: 10px;
  line-height: 25px;
  cursor: pointer;
  overflow: hidden;
  position: relative;
  -webkit-tap-highlight-color: transparent;
  transition: filter 0.3s ease-in-out;
}
.tile div {
  text-indent: -200%;
  transform-origin: center center;
  background-position: center center;
  background-repeat: no-repeat;
  background-size: cover;
  transform: rotate(0deg);
  position: absolute;
  z-index: 2;
  overflow: hidden;
  top: -1px;
  right: -1px;
  bottom: -1px;
  left: -1px;
  will-change: transform;
  -webkit-tap-highlight-color: transparent;
}
.tile[data-type="1"] div {
  background-image: url(img/level0/straight.svg);
}
.tile[data-type="2"] div {
  background-image: url(img/level0/junction.svg);
}
.tile[data-type="3"] div {
  background-image: url(img/level0/curve.svg);
}
.tile[data-type="4"] div {
  background-image: url(img/level0/deadend.svg);
}
.tile[data-type="5"] div {
  background-image: url(img/level0/intersection.svg);
}

.level0 .tile.m0,
.level1 .tile.m0,
.level2 .tile.m0 {
  background-color: #71A35E;
}
.level0 .tile.m1,
.level1 .tile.m1,
.level2 .tile.m1 {
  background-color: #4B8723;
}
.level0 .tile.m2,
.level1 .tile.m2,
.level2 .tile.m2 {
  background-color: #1D663F;
}

.level0 .tile.m1[data-type="3"] div {
  background-image: url(img/level0/curve2.svg);
}

.level1 #grid {
  background-color: #3A9235;
}
.level1 .car {
  background-image: url(img/level1/DXP.svg);
}
.level1 .tile.m0 {
  background-color: #3AAA35;
}
.level1 .tile.m1 {
  background-color: #008133;
}
.level1 .tile.m2 {
  background-color: #006633;
}
.level1 .tile[data-type="1"] div {
  background-image: url(img/level1/straight.svg);
}
.level1 .tile[data-type="2"] div {
  background-image: url(img/level1/junction.svg);
}
.level1 .tile[data-type="3"] div {
  background-image: url(img/level1/curve.svg);
}
.level1 .tile.m2[data-type="3"] div {
  background-image: url(img/level1/curve2.svg);
}
.level1 .tile[data-type="4"] div {
  background-image: url(img/level1/deadend.svg);
}
.level1 .tile[data-type="5"] div {
  background-image: url(img/level1/intersection.svg);
}

.level2 .car.var0 {
  background-image: url(img/level2/DXP.svg);
}
.level2 .car.var1 {
  background-image: url(img/level2/DXP2.svg);
}
.level2 #grid {
  background-color: #C6C6C6;
}
.level2 .tile.m0 {
  background-color: #DADADA;
}
.level2 .tile.m1 {
  background-color: #C6C6C6;
}
.level2 .tile.m2 {
  background-color: #B2B2B2;
}
.level2 .tile[data-type="1"] div {
  background-image: url(img/level2/straight.svg);
}
.level2 .tile.m2[data-type="1"] div {
  background-image: url(img/level2/straight2.svg);
}
.level2 .tile[data-type="2"] div {
  background-image: url(img/level2/junction.svg);
}
.level2 .tile[data-type="3"] div {
  background-image: url(img/level2/curve.svg);
}
.level2 .tile[data-type="4"] div {
  background-image: url(img/level2/deadend.svg);
}
.level2 .tile[data-type="5"] div {
  background-image: url(img/level2/intersection.svg);
}

.show-right .tile.right {
  filter: sepia(0);
  position: relative;
}
.show-right .tile.right div {
  text-indent: 0%;
}
.show-right .tile.right::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 3;
  background-image: url(img/right.svg);
  background-size: 30% 30%;
  background-position: 90% 10%;
  background-repeat: no-repeat;
}

body .tile div {
  transition: all 0s ease-in-out;
  transform: rotate(0deg);
}
body .tile.r90 div {
  transform: rotate(90deg);
  transition: all 0.3s ease-in-out;
}
body .tile.r180 div {
  transform: rotate(180deg);
  transition: all 0.3s ease-in-out;
}
body .tile.r270 div {
  transform: rotate(270deg);
  transition: all 0.3s ease-in-out;
}
body .tile.r360 div {
  transform: rotate(360deg);
  transition: all 0.3s ease-in-out;
}

body > .gameselect {
  position: absolute;
  top: 5px;
  left: 5px;
  right: 5px;
  font-size: 0.5rem;
  opacity: 0.3;
  display: flex;
  justify-content: center;
  list-style: none;
  margin: 0;
  padding: 0;
  display: none;
}
body > .gameselect li {
  margin: 0;
  padding: 0;
}
body > .gameselect li:hover {
  cursor: pointer;
}
body > .gameselect li:after {
  content: ",";
  padding-right: 3px;
}
body > .gameselect li:last-child:after {
  display: none;
}
body > .gameselect li.active {
  text-decoration: underline;
}

body.level0 .level[data-level="0"] {
  text-decoration: underline;
}

body.level1 .level[data-level="1"] {
  text-decoration: underline;
}

body.level2 .level[data-level="2"] {
  text-decoration: underline;
}

.show-dev > .gameselect {
  display: flex;
}

#help-button,
#pause-button,
.close-button,
.restart-button {
  position: absolute;
  display: block;
  top: 2%;
  height: calc(0.0833333333 * var(--size));
  aspect-ratio: 1/1;
  background-position: center center;
  background-repeat: no-repeat;
  background-size: 100% 100%;
  transition: opacity 0.3s ease-in-out;
  opacity: 1;
}
#help-button:hover,
#pause-button:hover,
.close-button:hover,
.restart-button:hover {
  cursor: pointer;
}

#pause-button,
.close-button,
.restart-button {
  right: 1.4%;
  background-image: url(img/btn-close.svg);
}

#help-button {
  right: 7%;
  background-image: url(img/btn-help.svg);
}

body.show-right #help-button {
  background-image: url(img/btn-help-active.svg);
}

#pause-panel,
#success-panel,
#start-panel {
  position: absolute;
  top: 0px;
  right: 0px;
  bottom: 0px;
  left: 0px;
  padding-left: 50px;
  padding-right: 50px;
  z-index: 11;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease-in-out;
}
#pause-panel #resume-button,
#pause-panel #exit-button,
#pause-panel #restart-button,
#pause-panel #start-button,
#success-panel #resume-button,
#success-panel #exit-button,
#success-panel #restart-button,
#success-panel #start-button,
#start-panel #resume-button,
#start-panel #exit-button,
#start-panel #restart-button,
#start-panel #start-button {
  text-align: center;
}
#pause-panel #resume-button .btn,
#pause-panel #exit-button .btn,
#pause-panel #restart-button .btn,
#pause-panel #start-button .btn,
#success-panel #resume-button .btn,
#success-panel #exit-button .btn,
#success-panel #restart-button .btn,
#success-panel #start-button .btn,
#start-panel #resume-button .btn,
#start-panel #exit-button .btn,
#start-panel #restart-button .btn,
#start-panel #start-button .btn {
  width: calc(0.1846153846 * var(--size));
  aspect-ratio: 1/1;
  margin-left: auto;
  margin-right: auto;
}
#pause-panel #resume-button .desc,
#pause-panel #exit-button .desc,
#pause-panel #restart-button .desc,
#pause-panel #start-button .desc,
#success-panel #resume-button .desc,
#success-panel #exit-button .desc,
#success-panel #restart-button .desc,
#success-panel #start-button .desc,
#start-panel #resume-button .desc,
#start-panel #exit-button .desc,
#start-panel #restart-button .desc,
#start-panel #start-button .desc {
  font-size: calc(0.032 * var(--size));
  line-height: calc(0.04 * var(--size));
  padding-top: calc(var(--size) / 50);
  font-weight: bold;
}
#pause-panel #resume-button:hover,
#pause-panel #exit-button:hover,
#pause-panel #restart-button:hover,
#pause-panel #start-button:hover,
#success-panel #resume-button:hover,
#success-panel #exit-button:hover,
#success-panel #restart-button:hover,
#success-panel #start-button:hover,
#start-panel #resume-button:hover,
#start-panel #exit-button:hover,
#start-panel #restart-button:hover,
#start-panel #start-button:hover {
  cursor: pointer;
}
#pause-panel #resume-button,
#pause-panel #restart-button,
#success-panel #resume-button,
#success-panel #restart-button,
#start-panel #resume-button,
#start-panel #restart-button {
  margin-bottom: 3vh;
}
#pause-panel #resume-button .btn,
#pause-panel #restart-button .btn,
#success-panel #resume-button .btn,
#success-panel #restart-button .btn,
#start-panel #resume-button .btn,
#start-panel #restart-button .btn {
  background-image: url(img/btn-replay.svg);
}
#pause-panel #exit-button .btn,
#success-panel #exit-button .btn,
#start-panel #exit-button .btn {
  background-image: url(img/cancel.svg);
}

.success #success-panel {
  transform: scale(1);
  opacity: 1;
  pointer-events: auto;
}

#start-panel {
  background-image: url(img/start-panel.png);
  background-color: #333;
  background-repeat: no-repeat;
  background-size: cover;
  z-index: 12;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s ease-in-out;
}
#start-panel:hover {
  cursor: pointer;
}

.start-active #start-panel {
  opacity: 1;
  pointer-events: auto;
}

#pause-panel {
  -webkit-backdrop-filter: blur(5px);
          backdrop-filter: blur(5px);
}
@media (max-width: 550px) {
  #pause-panel {
    padding-left: 0px !important;
    padding-right: 0px !important;
  }
}
#pause-panel .gameselect {
  position: relative;
  margin-bottom: calc(var(--size) / 10);
  list-style-type: none;
  padding: 0px;
  padding-top: calc(var(--size) / 10);
  padding-bottom: calc(var(--size) / 10);
  height: 60%;
  width: 90%;
  background-color: #ffd700;
  border-radius: calc(var(--size) / 25);
  display: flex;
  align-items: center;
  justify-content: space-evenly;
}
#pause-panel .gameselect li {
  padding: calc(var(--size) / 80) calc(var(--size) / 60);
  border-radius: calc(var(--size) / 25);
  background-color: #fff;
  overflow: hidden;
  transform: scale(1);
  transition: transform 0.3s ease-in-out;
  width: 28%;
  aspect-ratio: 1/1;
  margin: 0px !important;
  display: flex;
  align-items: center;
  justify-content: center;
  background-repeat: no-repeat;
  background-position: center center;
  background-size: cover;
}
#pause-panel .gameselect li:hover {
  cursor: pointer;
  transform: scale(1.1);
  text-decoration: none;
}
#pause-panel .gameselect li:before {
  content: "";
  position: absolute;
  background-color: rgba(0, 0, 0, 0.4);
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: -1;
}
#pause-panel .gameselect li .stars {
  border-radius: calc(var(--size) / 25);
  border: calc(var(--size) / 200) solid #FFCC02;
  background-color: #fff;
  padding: calc(var(--size) / 60) calc(var(--size) / 40);
  display: flex;
  align-items: center;
  justify-content: center;
}
#pause-panel .gameselect li .star {
  display: inline-block;
  height: calc(0.05 * var(--size));
  width: calc(0.05 * var(--size));
  margin: calc(0.01 * var(--size));
  background-image: url(img/star.svg);
  background-repeat: no-repeat;
  background-position: center center;
}
#pause-panel .gameselect li.level[data-level="0"] {
  background-image: url(img/level0_prev.png);
}
#pause-panel .gameselect li.level[data-level="1"] {
  background-image: url(img/level1_prev.png);
}
#pause-panel .gameselect li.level[data-level="2"] {
  background-image: url(img/level2_prev.png);
}
#pause-panel .close-button {
  position: absolute;
  top: calc(0.0208333333 * var(--size));
  right: calc(0.0208333333 * var(--size));
  background-image: url(img/btn-close-red.svg);
}

.pause-active #pause-panel {
  transform: scale(1);
  opacity: 1;
  pointer-events: auto;
}

#success-panel {
  background-image: url(img/success-panel.png);
  background-repeat: no-repeat;
  background-size: cover;
  z-index: 12;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s ease-in-out;
}
#success-panel #restart-button {
  flex: 1;
  margin-bottom: 0;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  align-items: center;
}
#success-panel #restart-button .btn {
  margin-bottom: calc(0.15625 * var(--size));
}

.success #success-panel #restart-button {
  opacity: 1;
  pointer-events: auto;
  transition-delay: 1.5s;
}

.hand {
  opacity: 0;
  z-index: 10;
  pointer-events: none;
  display: block;
  position: absolute;
  transition: top 1s ease-in-out, left 1s ease-in-out, opacity 1s ease-in-out;
  top: 50%;
  left: 50%;
  margin-left: calc(0.04 * var(--size));
  margin-top: calc(0.04 * var(--size));
  background-image: url(img/hand2.svg);
  background-repeat: no-repeat;
  background-size: contain;
  width: calc(0.24 * var(--size));
  height: calc(0.24 * var(--size));
}
.hand.click {
  background-image: url(img/hand-click2.svg);
}

body.level1 .hand {
  margin-left: calc(0.02 * var(--size));
  margin-top: calc(0.02 * var(--size));
}

body.level2 .hand {
  margin-left: calc(0.0133333333 * var(--size));
  margin-top: calc(0.0133333333 * var(--size));
}

body {
  transition: all 0.5s ease-in-out;
  transform-origin: bottom center;
}
body #demo-panel {
  -webkit-user-select: none;
     -moz-user-select: none;
          user-select: none;
  pointer-events: none;
  z-index: 20;
  background-color: transparent;
  box-shadow: 0px 0px 0px 100vw #FFD600;
  color: #fff;
  border-radius: calc(var(--size) / 5);
  position: absolute;
  top: 0%;
  right: 0%;
  bottom: 0%;
  left: 0%;
  opacity: 0;
  transition: all 0.5s ease-in-out;
}

body.demo {
  pointer-events: none;
  transform: scale(1.1);
}
body.demo #demo-panel {
  top: 14%;
  right: 5%;
  bottom: 2%;
  left: 5%;
  opacity: 1;
}
body.demo .tile.right:after {
  opacity: 0;
  pointer-events: none;
}

body.show-hand .hand {
  opacity: 1;
}

canvas {
  position: absolute;
  height: 140%;
  width: 100%;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  pointer-events: none;
}

svg.people {
  position: absolute;
  pointer-events: none;
  width: auto;
  overflow: visible;
  display: none;
}

.level0 #people0-1 {
  display: block;
}

.level1 #people1-1 {
  display: block;
}

.level2 #people2-1,
.level2 #people2-2 {
  display: block;
}

svg#people0-1 {
  height: 13%;
  opacity: 1;
  right: 4.65%;
  bottom: 6.7%;
}
svg#people0-1 #left-arm {
  transform-origin: 14px 35px;
}
svg#people0-1 #right-arm {
  transform-origin: 26px 35px;
}
svg#people0-1 #left-arm-2 {
  transform-origin: 52px 25px;
}
svg#people0-1 #right-arm-2 {
  transform-origin: 62px 25px;
}

svg#people1-1 {
  height: 11.1%;
  opacity: 1;
  right: 8.25%;
  bottom: 11.4%;
}
svg#people1-1 #left-arm {
  transform-origin: 8px 30px;
}
svg#people1-1 #right-arm {
  transform-origin: 18px 30px;
}
svg#people1-1 #left-arm-2 {
  transform-origin: 35px 25px;
}
svg#people1-1 #right-arm-2 {
  transform-origin: 44px 25px;
}

svg#people2-1 {
  height: 10.2%;
  opacity: 1;
  left: 8.9%;
  bottom: 6.5%;
}
svg#people2-1 #left-arm {
  transform-origin: 9px 20px;
}
svg#people2-1 #right-arm {
  transform-origin: 20px 20px;
}
svg#people2-1 #left-arm-2 {
  transform-origin: 38px 24px;
}
svg#people2-1 #right-arm-2 {
  transform-origin: 49px 24px;
}

svg#people2-2 {
  height: 13.75%;
  opacity: 1;
  right: 6.3%;
  bottom: 7%;
}
svg#people2-2 #left-arm {
  transform-origin: 10px 44px;
}
svg#people2-2 #right-arm {
  transform-origin: 18px 44px;
}
svg#people2-2 #left-arm-2 {
  transform-origin: 42px 27px;
}
svg#people2-2 #right-arm-2 {
  transform-origin: 52px 27px;
}

.show-people #pause-button,
.show-people #help-button,
.show-people .tile.right:after {
  opacity: 0;
  pointer-events: none;
}
.show-people .people {
  animation-name: huepfen;
  animation-duration: 0.15s;
  animation-timing-function: ease-in-out;
  animation-iteration-count: infinite;
  animation-direction: alternate;
}
.show-people #left-arm,
.show-people #left-arm-2 {
  animation-name: leftarm;
  animation-duration: 0.3s;
  animation-timing-function: ease-in-out;
  animation-iteration-count: infinite;
  animation-direction: alternate;
}
.show-people #right-arm,
.show-people #right-arm-2 {
  animation-name: rightarm;
  animation-duration: 0.35s;
  animation-timing-function: ease-in-out;
  animation-iteration-count: infinite;
  animation-direction: alternate;
}

@keyframes leftarm {
  0% {
    transform: rotate(15deg);
  }
  100% {
    transform: rotate(-40deg);
  }
}
@keyframes rightarm {
  0% {
    transform: rotate(-15deg);
  }
  100% {
    transform: rotate(40deg);
  }
}
@keyframes huepfen {
  0% {
    transform: translateY(0%);
  }
  100% {
    transform: translateY(-5%);
  }
}
#cancle-panel {
  position: fixed;
  background-color: rgba(255, 255, 255, 0.5);
  -webkit-backdrop-filter: blur(5px);
          backdrop-filter: blur(5px);
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 11;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s ease-in-out;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}
#cancle-panel img {
  height: 50vw;
  width: 50vh;
  max-height: 70%;
  max-width: 70%;
  -o-object-fit: contain;
     object-fit: contain;
}
#cancle-panel video {
  height: 80%;
  width: 80%;
  -o-object-fit: contain;
     object-fit: contain;
  background-color: #FFD600;
  box-shadow: 0px 0px 0px 100vw #FFD600;
  border-radius: 1.25vw;
}
#cancle-panel .btn {
  background-repeat: no-repeat;
  background-position: center center;
  background-size: contain;
}
#cancle-panel .btn:hover {
  cursor: pointer;
}

body.cancle #cancle-panel {
  opacity: 1;
  pointer-events: auto;
}

#resume-button,
.resume-button {
  background-image: url(img/btn-resume.svg);
  width: 20vw;
  height: 20vh;
  background-position: center center;
  background-repeat: no-repeat;
}

.restart-button {
  right: 1.4vw;
  background-image: url(/spiel1/img/btn-close.svg);
}

#cancle-panel #restart-button {
  background-image: url(img/btn-close.svg);
  width: 20vw;
  height: 20vh;
}/*# sourceMappingURL=styles.css.map */