html {
  -ms-touch-action: none;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: hidden;
  overscroll-behavior: none;
  background-color: #000000;
}

body {
  cursor: default;
  padding: 0;
  border: 0;
  margin: 0;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  max-width: 100%;
  max-height: 100%;
  text-align: center;
  background-color: #000000;
  font-family: Helvetica, Verdana, Arial, sans-serif;
  overflow: hidden;
  overscroll-behavior: none;
  box-sizing: border-box;
}

body, canvas, div {
  outline: none;
  -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);
}

input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

#Cocos2dGameContainer {
  position: absolute;
  margin: 0;
  overflow: hidden;
  left: 0;
  top: 0;
  border: none !important;
  box-shadow: none !important;
}

canvas {
  background-color: rgba(0, 0, 0, 0);
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  vertical-align: top;
}

a:link, a:visited {
  color: #000;
}

a:active, a:hover {
  color: #666;
}

#GameDiv {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  width: 100%;
  height: 100%;
  max-width: 100vw;
  max-height: 100vh;
  margin: 0 !important;
  padding: 0;
  background: #000000;
  border: none !important;
  outline: none !important;
  box-shadow: none !important;
  box-sizing: border-box;
}

#splash {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  background: #000000;
  z-index: 10;
  overflow: hidden;
}

#splash-bg {
  position: absolute;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center center;
  pointer-events: none;
  user-select: none;
}

.progress-bar {
    background-color: rgba(0, 0, 0, 0.45);
    position: absolute;
    left: 50%;
    bottom: 12%;
    top: auto;
    height: 8px;
    width: min(320px, 72vw);
    margin: 0;
    transform: translateX(-50%);
    border-radius: 8px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.5);
    z-index: 2;
}

.progress-bar span {
    display: block;
    height: 100%;
    border-radius: 8px;
    box-shadow: 0 1px 0 rgba(255, 255, 255, .35) inset;
    transition: width .35s ease-out;
    background-color: #b06cff;
}

.stripes span {
    background-size: 30px 30px;
    background-image: linear-gradient(135deg, rgba(255, 255, 255, .15) 25%, transparent 25%,
                        transparent 50%, rgba(255, 255, 255, .15) 50%, rgba(255, 255, 255, .15) 75%,
                        transparent 75%, transparent);
    animation: animate-stripes 1s linear infinite;
}

@keyframes animate-stripes {
    0% {background-position: 0 0;} 100% {background-position: 60px 0;}
}

h1.header, h1, p.footer, .header, .footer {
  display: none !important;
  height: 0 !important;
  margin: 0 !important;
  padding: 0 !important;
  overflow: hidden !important;
}

/* 页面只管理可用视口和安全边距，游戏内容由 Cocos 分层全屏布局。 */
#GameDiv {
  position: fixed;
  left: env(safe-area-inset-left, 0px);
  right: env(safe-area-inset-right, 0px);
  top: env(safe-area-inset-top, 0px);
  bottom: env(safe-area-inset-bottom, 0px);
  width: auto;
  height: auto;
  max-width: none;
  max-height: none;
  overflow: hidden;
  background: #10131d;
}
#rotate-hint {
  display: none;
  position: fixed;
  left: 24px;
  right: 24px;
  bottom: calc(24px + env(safe-area-inset-bottom, 0px));
  z-index: 20;
  color: #d9deec;
  text-align: center;
  font: 14px/1.5 sans-serif;
  pointer-events: none;
}
@media (orientation: portrait) and (pointer: coarse) {
  #rotate-hint { display: block; }
}