html {
  -ms-touch-action: none;
}

body,
canvas,
div {
  display: block;
  outline: none;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
  -moz-user-select: none;
  -webkit-user-select: none;
  -ms-user-select: none;
  -khtml-user-select: none;
  -webkit-tap-highlight-color: rgba(0, 0, 0, 0);
}

/* Remove spin of input type number */

input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  /* display: none; <- Crashes Chrome on hover */
  -webkit-appearance: none;
  margin: 0;
  /* <-- Apparently some margin are still there even though it's hidden */
}

body {
  /* position: absolute; */
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  margin: 0;
  cursor: default;
  color: #888;
  /* background-color: #333; */
  background-color: black;
  text-align: center;
  font-family: Helvetica, Verdana, Arial, sans-serif;
  display: flex;
  flex-direction: column;
  /* fix bug: https://github.com/cocos-creator/2d-tasks/issues/791 */
  /* overflow cannot be applied in Cocos2dGameContainer, 
  otherwise child elements will be hidden when Cocos2dGameContainer rotated 90 deg */
  overflow: hidden;
}

#Cocos2dGameContainer {
  position: absolute;
  margin: 0;
  /* overflow: hidden; */
  /*直版隱藏*/
  left: 0px;
  top: 0px;
  display: -webkit-box;
  -webkit-box-orient: horizontal;
  -webkit-box-align: center;
  -webkit-box-pack: center;
}

canvas {
  background-color: rgba(0, 0, 0, 0);
}

a:link,
a:visited {
  color: #666;
}

a:active,
a:hover {
  color: #666;
}

p.header {
  font-size: small;
}

p.footer {
  font-size: x-small;
}

#splash {
  position: relative;
  top: 0;
  left: 0;
  display: flex;
  justify-content: center;
  align-items: center;
  width: 100vw;
  height: 100vh;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center;
  /* -webkit-background-size: contain; */
}

@media screen and (orientation: landscape) {
  .splash_en {
    background-image: url("./Loading/en/IMG_loadingBG_Landscape.jpg");
  }
  .splash_zhcn {
    background-image: url("./Loading/zhcn/IMG_loadingBG_Landscape.jpg");
  }
  /*馬來文*/
  .splash_msmy {
    background-image: url("./Loading/msmy/IMG_loadingBG_Landscape.jpg");
  }
}

@media screen and (orientation: portrait) {
  .splash_en {
    background-image: url("./Loading/en/IMG_loadingBG_Portrait.jpg");
  }
  .splash_zhcn {
    background-image: url("./Loading/zhcn/IMG_loadingBG_Portrait.jpg");
  }
   /*馬來文*/
  .splash_msmy {
    background-image: url("./Loading/msmy/IMG_loadingBG_Portrait.jpg");
  }
}

.splash_bg {
  display: inline-block;
  position: relative;
  object-fit: contain;
}

.splash_bg img {
  object-fit: contain;
  max-width: 100vw;
  max-height: 100vh;
}

.splash_bg_frame {
  opacity: 0;
}

@media screen and (orientation: landscape) {
  /* 橫版 直橫版提示位置，動.rotation_presentation的right/bottom就好 */
  .rotation_presentation {
    position: absolute;
    right: 0%;
    bottom: 5%;
    width: 10%;
  }
  .rotation_presentation > img {
    width: 100%;
    object-fit: contain;
  }
  /* 橫版 進度條位置  */
  /* 整體進度條位置，調整bottom可使上下移動 */
  .progress-bar-out {
    display: flex;
    width: 35%;
    background-repeat: no-repeat;
    background-position: center;
    /* background-size  進度條UI內框的圖片背景大小調整部位， 寬 高 */
    background-size: 90% 50%; 
    position: absolute;
    left: 50%;
    bottom: 10%;
    transform: translateX(-50%);
    align-items: center;
    justify-content: center;
    background-image: url("./Loading/loading/Back.png");
  }
  /* 進度條的UI，負責利用寬度撐起比例，不動 */
  .progress-bar-out-bone {
    width: 100%;
    object-fit: contain;
  }
  /* 把進度條的比例塞進div，不動 */
  .progress-bar-out > div {
    position: relative;
    width: 100%;
    height: 100%;
  }
  /* .progress-bar 放置進度條實際 跑 進度的範圍 */
  /* 調整方式
  1.把z-index改成1
  2.調整寬度高度，(background:red可以打開，方便調整)
  寬度調整至UI裡面的進度條的內框大小，高度調整至以 z-index:-1的情況下 不露餡為主 
  3.把z-index改成-1，
  */
  .progress-bar {
    display: flex;
    width: 89%;
    height: 50%;
    /* background:red; */
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 2;
    transform: translate(-50%, -50%);
    align-items: center;
    z-index: -1;
  }
  /* 不動 */
  .progress-bar > span {
    display: block;
    height: 100%;
    background-image: url("./Loading/loading/laodingBar_active.png");
    background-size: 100% 100%;
    position: relative;
  }
}

@media screen and (orientation: portrait) {
  /* 直版 直橫版提示位置，動.rotation_presentation的right/bottom就好 */
  .rotation_presentation {
    position: absolute;
    left: 50%;
    transform: translateX(-50%);
    bottom: -3%;
    width: 20%;
  }
  .rotation_presentation > img {
    width: 100%;
    object-fit: contain;
  }
   /* 直版 進度條位置  */
  /* 整體進度條位置，調整bottom可使上下移動 */
  .progress-bar-out {
    display: flex;
    width: 50%;
    background-repeat: no-repeat;
    background-position: center;
    /*  */
    background-size: 90% 50%;
    position: absolute;
    left: 50%;
    bottom: 25%;
    transform: translateX(-50%);
    align-items: center;
    justify-content: center;
    background-image: url("./Loading/loading/Back.png");
  }
  /* 進度條的UI，負責利用寬度撐起比例，不動 */
  .progress-bar-out-bone {
    width: 100%;
    object-fit: contain;
  }
  /* 把進度條的比例塞進div，不動 */
  .progress-bar-out > div {
    position: relative;
    width: 100%;
    height: 100%;
  }
  /* .progress-bar 放置進度條實際 跑 進度的範圍 */
  /* 調整方式
  1.把z-index改成1
  2.調整寬度高度，(background:red可以打開，方便調整)
  寬度調整至UI裡面的進度條的內框大小，高度調整至以 z-index:-1的情況下 不露餡為主 
  3.把z-index改成-1，
  */
  .progress-bar {
    display: flex;
    width: 89%;
    height: 50%;
    /* background:red; */
    position: absolute;
    left: 50%;
    top: 50%;
    z-index: 2;
    transform: translate(-50%, -50%);
    align-items: center;
    z-index: -1;
  }
  /* 不動 */
  .progress-bar > span {
    display: block;
    height: 100%;
    background-image: url("./Loading/loading/laodingBar_active.png");
    background-size: 100% 100%;
    position: relative;
  }
}

.stripes span {
  /* background-size: 30px 30px; */
  /* background-image: linear-gradient(
    135deg,
    rgba(147, 112, 219, 0.15) 25%,
    transparent 25%,
    transparent 50%,
    rgba(147, 112, 219, 0.15) 50%,
    rgba(147, 112, 219, 0.15) 75%,
    transparent 75%,
    transparent
  ); */
  /* animation: animate-stripes 1s linear infinite; */
}

@keyframes animate-stripes {
  0% {
    background-position: 0 0;
  }
  100% {
    background-position: 60px 0;
  }
}

@keyframes jumpLogo {
  0% {
    top: -1.8rem;
  }
  25% {
    top: -1.9rem;
  }
  50% {
    top: -1.8rem;
  }
  75% {
    top: -1.7rem;
  }
  100% {
    top: -1.8rem;
  }
}

#Icon {
  position: absolute;
  top: -1.8rem;
  left: -6rem;
  width: 5rem;
  height: 3rem;
  animation: jumpLogo 1s infinite linear;
}

.orientation,
.swiper {
  width: 100%;
  height: 100%;
  min-height: 100vh;
  z-index: 99;
  background-repeat: no-repeat;
  background-color: #000;
  background-position: center;
  display: none;
}

.orientation {
  background-image: url(dist/img/orientation.gif);
  z-index: 100;
}

.swiper-chrome {
  background-image: url(dist/img/swiper-chrome.gif);
  height: 100%;
  background-position: center;
  position: fixed;
  display: none;
}

.swiper-safari {
  background-image: url(dist/img/swiper-safari.gif);
  height: calc(100vh * 2); 
  background-position: top;
  display: none;
}

/* .swiper {
  height: calc(100vh*2);
}
.chrome {
  height: 100vh;
} */

.show {
  display: none;
}

@media screen and (orientation: portrait) {
  /* .swiper {
    display: none;
  } */
  /* #splash.portrait:lang(zh_CN) {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #171717 url(./Loading/zhcn/IMG_loadingBG_Portrait.jpg) no-repeat
      center;
    background-size: contain;
    -webkit-background-size: contain;
  }

  #splash.portrait:lang(en_US) {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #171717 url(./Loading/en/IMG_loadingBG_Portrait.jpg) no-repeat
      center;
    background-size: contain;
    -webkit-background-size: contain;
  } */
}

@media screen and (orientation: landscape) {
  .orientation {
    display: none;
  }
  .splashChange {
    overflow-x: hidden;
    transform: rotate(90deg) translateY(-100%);
    transform-origin: top left;
    width: 100vh;
    height: 100vw;
    background-position: center;
    background-size: contain;
  }
  /* #splash.landspace:lang(zh_CN) {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #171717 url(./Loading/zhcn/IMG_loadingBG.jpg) no-repeat center;
    background-size: contain;
    -webkit-background-size: contain;
  }

  #splash.landspace:lang(en_US) {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: #171717 url(./Loading/en/IMG_loadingBG.jpg) no-repeat center;
    background-size: contain;
    -webkit-background-size: contain;
  } */
  body.rotation90 {
    -webkit-transform: rotate(180deg);
    -moz-transform: rotate(180deg);
    -ms-transform: rotate(180deg);
    -o-transform: rotate(180deg);
    transform: rotate(180deg);
    -webkit-transform-origin: center;
    -moz-transform-origin: center;
    -ms-transform-origin: center;
    -o-transform-origin: center;
    transform-origin: center;
    width: 100%;
    position: fixed;
    background-position: center;
    background-size: contain;
  }
}

.show {
  z-index: 999999;
  background: pink;
  width: 100%;
  height: 70%;
  position: fixed;
  color: green;
  opacity: 0.7;
}

.fullScreen {
  width: 100% !important;
  height: 100% !important;
  min-width: 100vw !important;
  min-height: 100vh !important;
}

/* #Cocos2dGameContainer {
  z-index: -1;
  margin: 0 !important;
  width: 100% !important;
  height: 100% !important;
} */

@media only screen and (min-width: 786px) {
  .swiper .orientation {
    display: none;
  }
  #Cocos2dGameContainer {
    z-index: unset;
  }
}

#Cocos2dGameContainer iframe {
  background-color: transparent !important;
}

#Cocos2dGameContainer div {
  background-color: transparent !important;
}
