html.gjsg-auth-locked,
html.gjsg-auth-locked body {
  width: var(--gjsg-auth-width, 100vw);
  height: var(--gjsg-auth-height, 100vh);
  overflow: hidden;
  background: #101321;
}

html.gjsg-auth-locked body {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  inset: 0;
}

html.gjsg-input-dialog-open,
html.gjsg-input-dialog-open body {
  width: var(--gjsg-auth-width, 100vw);
  height: var(--gjsg-auth-height, 100vh);
  overflow: hidden;
}

html.gjsg-auth-locked #pixi-content {
  visibility: hidden;
}

.boot-loading {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  width: 100%;
  height: 100%;
  inset: 0;
  z-index: 7000;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  background: #000000;
  opacity: 1;
  transition: opacity 0.24s ease;
}

.boot-loading[hidden] {
  display: none;
}

.boot-loading.is-hidden {
  opacity: 0;
  pointer-events: none;
}

.boot-loading__inner {
  width: 100%;
  height: 100%;
  max-width: 750px;
  max-height: 1334px;
  width: min(100%, 750px);
  height: min(100%, 1334px);
  position: relative;
}

.boot-loading__logo {
  position: absolute;
  top: 43%;
  left: 50%;
  width: 70%;
  max-width: 430px;
  width: min(70%, 430px);
  height: auto;
  transform: translate(-50%, -60%);
  display: block;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.65));
}

.boot-loading__bar {
  position: absolute;
  left: 8%;
  right: 8%;
  bottom: 9%;
  height: 18px;
  box-sizing: content-box;
  overflow: hidden;
  border: 1px solid rgba(18, 18, 18, 0.95);
  border-radius: 999px;
  background: linear-gradient(180deg, #151515 0%, #242424 46%, #070707 100%);
  box-shadow:
    0 2px 0 rgba(255, 255, 255, 0.18),
    0 9px 18px rgba(0, 0, 0, 0.65),
    inset 0 0 4px rgba(255, 255, 255, 0.12);
}

.boot-loading__fill {
  position: absolute;
  top: 1px;
  left: 1px;
  bottom: 1px;
  width: calc(100% - 2px);
  box-sizing: border-box;
  transform: scaleX(0);
  transform-origin: left center;
  border-radius: 999px;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.95) 0%, rgba(218, 218, 218, 0.98) 36%, rgba(128, 128, 128, 0.98) 100%);
  box-shadow:
    inset 0 0 2px rgba(255, 255, 255, 0.48),
    0 0 8px rgba(255, 255, 255, 0.22);
  transition: transform 0.16s linear;
}

.boot-loading__text {
  position: absolute;
  z-index: 1;
  left: 8%;
  right: 8%;
  bottom: calc(9% + 28px);
  height: 24px;
  line-height: 24px;
  text-align: center;
  color: #ffffff;
  font-size: 16px;
  text-shadow: 0 2px 3px rgba(0, 0, 0, 0.7);
}

.auth-screen {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  inset: 0;
  width: 100%;
  height: 100%;
  width: var(--gjsg-auth-width, 100vw);
  height: var(--gjsg-auth-height, 100vh);
  z-index: 5000;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  color: #fff6d2;
  font-family: "Microsoft YaHei", "SimHei", Arial, sans-serif;
  background: #101321;
  overflow: hidden;
}

.auth-screen[hidden] {
  display: none;
}

.auth-shell {
  position: relative;
  z-index: 2;
  container-type: inline-size;
  width: 100%;
  height: 100%;
  width: min(var(--gjsg-auth-width, 100vw), calc(var(--gjsg-auth-height, 100vh) * 640 / 1120));
  height: min(var(--gjsg-auth-height, 100vh), calc(var(--gjsg-auth-width, 100vw) * 1120 / 640));
  max-width: 750px;
  max-height: 1334px;
  min-width: 320px;
  min-height: 560px;
  box-sizing: border-box;
  overflow: hidden;
  border: 0;
  border-radius: 0;
  padding: 0;

  box-shadow: none;
}

.auth-spine-layer {
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  inset: 0;
  z-index: 0;
  overflow: hidden;
  pointer-events: none;
}

.auth-spine-layer.is-preview {
  pointer-events: auto;
  z-index: 3;
}

.auth-spine-canvas {
  width: 100%;
  height: 100%;
  display: block;
  pointer-events: none;
}

.auth-spine-picker {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 20;
  width: min(72vw, 360px);
  pointer-events: auto;
}

.auth-spine-trigger {
  width: 100%;
  height: 30px;
  box-sizing: border-box;
  border: 1px solid rgba(255, 255, 255, 0.45);
  border-radius: 3px;
  color: #fff;
  background: rgba(0, 0, 0, 0.68);
  padding: 0 28px 0 10px;
  font-size: 13px;
  line-height: 28px;
  text-align: left;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  cursor: pointer;
}

.auth-spine-trigger::after {
  content: "";
  position: absolute;
  right: 10px;
  top: 12px;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-top: 6px solid #fff;
}

.auth-spine-menu {
  position: absolute;
  left: 0;
  top: 34px;
  width: 100%;
  max-height: min(58vh, 420px);
  overflow-y: auto;
  box-sizing: border-box;
  border: 1px solid rgba(255, 255, 255, 0.4);
  border-radius: 3px;
  background: rgba(0, 0, 0, 0.86);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.45);
}

.auth-spine-option {
  display: block;
  width: 100%;
  min-height: 30px;
  border: 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.12);
  color: #fff;
  background: transparent;
  padding: 6px 10px;
  font-size: 13px;
  line-height: 18px;
  text-align: left;
  cursor: pointer;
}

.auth-spine-option.is-active,
.auth-spine-option:hover {
  background: rgba(31, 151, 205, 0.68);
}

.auth-spine-select {
  display: none;
  pointer-events: auto;
}

.auth-shell::after {
  content: "";
  position: absolute;
  left: 50%;
  top: 50%;
  z-index: 1;
  pointer-events: none;
  transform: translate(-50%, -50%);
  background-repeat: no-repeat;
  background-position: center;
}

.auth-shell::after {
  top: 46.8%;
  width: 76%;
  height: 34.3%;
  background-image: url("./api/assets/home-image.php?path=ui%2Fofficial%2F1b471cab-b8da-4974-8143-2416a35f48b6.png&v=3");
  background-size: 100% 100%;
}

.auth-title {
  position: absolute;
  left: 50%;
  top: 28.2%;
  z-index: 2;
  width: 28%;
  height: 5.3%;
  margin: 0;
  overflow: hidden;
  text-indent: -9999px;
  transform: translateX(-50%);
}

.auth-panel-copy {
  position: absolute;
  left: 46%;
  top: 37.5%;
  z-index: 2;
  width: 46%;
  min-height: 7.5%;
  max-height: 12%;
  box-sizing: border-box;
  overflow: hidden;
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
  color: #fff9da;
  font-size: clamp(12px, 3.1vmin, 22px);
  font-size: clamp(12px, 3cqw, 18px);
  font-weight: 700;
  line-height: 1.2;
  text-align: left;
  white-space: normal;
  overflow-wrap: anywhere;
  word-break: break-word;
  text-shadow:
    1px 0 #101010,
    -1px 0 #101010,
    0 1px #101010,
    0 -1px #101010,
    0 2px 2px rgba(0, 0, 0, 0.8);
  pointer-events: none;
}

.auth-field {
  position: absolute;
  left: 44%;
  z-index: 2;
  display: grid;
  grid-template-columns: 23% 1fr;
  align-items: center;
  width: 62%;
  height: 5.1%;
  margin: 0;
  transform: translateX(-50%);
}

.auth-field:nth-of-type(1) {
  top: 50%;
}

.auth-field:nth-of-type(2) {
  top: 56%;
}

.auth-field span {
  display: block;
  color: #fff9da;
  font-size: clamp(16px, 4.2vmin, 30px);
  font-weight: 700;
  line-height: 1;
  text-align: right;
  text-shadow:
    1px 0 #101010,
    -1px 0 #101010,
    0 1px #101010,
    0 -1px #101010,
    0 2px 2px rgba(0, 0, 0, 0.8);
}

.auth-field input {
  width: 100%;
  height: 100%;
  box-sizing: border-box;
  border: 0;
  border-radius: 0;
  padding: 0 4.5%;
  color: #251100;
  outline: none;
  font-size: clamp(16px, 3.9vmin, 28px);
  font-weight: 700;
  background: url("./api/assets/home-image.php?path=ui%2Fofficial%2Fb4ff975d-26d7-4235-8da2-0b695bf593c0.png&v=3") center / 100% 100% no-repeat;
  box-shadow: none;
}

.auth-field input:focus {
  filter: brightness(1.12);
}

.auth-submit {
  position: absolute;
  left: 50%;
  top: 66%;
  z-index: 2;
  width: 40%;
  height: 7.1%;
  border: 0;
  border-radius: 0;
  padding: 0 0 0.15em;
  color: #fff7d6;
  background: url("./api/assets/home-image.php?path=ui%2Fofficial%2F8a68d368-2d58-4607-9102-5cec89a27a22.png&v=3") center / 100% 100% no-repeat;
  overflow: hidden;
  text-indent: -9999px;
  font-size: 0;
  font-weight: 700;
  line-height: 1;
  cursor: pointer;
  transform: translateX(-50%);
  text-shadow:
    1px 0 #7d1200,
    -1px 0 #7d1200,
    0 1px #7d1200,
    0 -1px #7d1200,
    0 2px 2px rgba(0, 0, 0, 0.72);
}

.auth-shell.is-registering .auth-submit,
.auth-register {
  background: linear-gradient(#d3a34b, #914919);
  border: 1px solid #f5d58b;
  border-radius: 4px;
  color: #fff7d6;
  text-indent: 0;
  font-size: clamp(16px, 4vmin, 26px);
}

.auth-register {
  position: absolute;
  left: 50%;
  top: 75%;
  z-index: 2;
  width: 40%;
  height: 5.5%;
  transform: translateX(-50%);
  font-weight: 700;
  cursor: pointer;
}

.auth-register:disabled {
  cursor: wait;
  opacity: 0.72;
}

.auth-submit:active {
  transform: translate(-50%, 2px);
  filter: brightness(0.92);
}

.auth-submit:disabled {
  cursor: wait;
  opacity: 0.72;
}

.auth-message {
  position: absolute;
  left: 14%;
  right: 14%;
  top: 82%;
  z-index: 3;
  pointer-events: none;
  min-height: 1.5em;
  margin: 0;
  color: #ffe26e;
  text-align: center;
  font-size: clamp(16px, 4vmin, 28px);
  line-height: 1.35;
  text-shadow:
    1px 0 #321000,
    -1px 0 #321000,
    0 1px #321000,
    0 -1px #321000;
}

.auth-message.is-error {
  color: #ff8a72;
}

.auth-input-dialog {
  position: fixed;
  inset: auto;
  top: var(--gjsg-visual-top, 0px);
  left: var(--gjsg-visual-left, 0px);
  width: var(--gjsg-visual-width, 100vw);
  height: var(--gjsg-visual-height, 100vh);
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
  padding: max(18px, env(safe-area-inset-top)) 18px 18px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.58);
  font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif;
}

.auth-input-dialog__box {
  width: min(72vw, 320px);
  max-width: calc(var(--gjsg-visual-width, 100vw) - 36px);
  max-height: calc(var(--gjsg-visual-height, 100vh) - 36px);
  box-sizing: border-box;
  margin-top: 0;
  padding: 14px 16px 13px;
  border: 1px solid #d8d8d8;
  border-top-width: 3px;
  border-bottom-width: 3px;
  border-radius: 2px;
  background: #7a7a7a;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.55);
}

.auth-input-dialog__title {
  margin: 0 0 6px;
  color: #ffffff;
  font-size: 14px;
  font-weight: 700;
  text-align: left;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.65);
}

.auth-input-dialog__input {
  width: 100%;
  height: 36px;
  box-sizing: border-box;
  border: 1px solid #111111;
  border-radius: 5px;
  outline: none;
  padding: 0 10px;
  color: #ffffff;
  background: #000000;
  font-size: 15px;
  font-weight: 700;
}

.auth-input-dialog__actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
  margin-top: 8px;
}

.auth-input-dialog__button {
  justify-self: end;
  width: 60%;
  height: 32px;
  border: 1px solid #111111;
  border-radius: 5px;
  color: #ffffff;
  background: #a6a6a6;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  text-shadow: 0 1px 1px rgba(0, 0, 0, 0.55);
}

.auth-input-dialog__button--primary {
  justify-self: start;
  background: #b8b8b8;
}

@media (max-aspect-ratio: 9 / 16) {
  .auth-shell {
    width: var(--gjsg-auth-width, 100vw);
    height: calc(var(--gjsg-auth-width, 100vw) * 1120 / 640);
  }
}

@media (min-aspect-ratio: 9 / 16) {
  .auth-shell {
    width: calc(var(--gjsg-auth-height, 100vh) * 640 / 1120);
    height: var(--gjsg-auth-height, 100vh);
  }
}
