#jt-gate[hidden] { display: none !important; }
html:not([data-app]) #root { display: none !important; }
html[data-app] .jt-hall,
html[data-app] .jt-veil { display: none !important; }

.jt-hall {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: #8c1224 url("/hero/pillars.jpg") center 18% / cover no-repeat;
  transform-origin: 50% 30%;
  animation: pillar-sway 5.5s ease-in-out infinite alternate;
  pointer-events: none;
}

.jt-veil {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    radial-gradient(ellipse at 50% 18%, rgba(255, 210, 120, 0.22), transparent 42%),
    linear-gradient(180deg, rgba(80, 8, 14, 0.08) 0%, rgba(251, 246, 238, 0) 24%, rgba(251, 246, 238, 0.45) 58%, #fbf6ee 82%);
}

#jt-gate {
  position: fixed;
  inset: 0;
  z-index: 8;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  font-family: "PingFang SC", "Microsoft YaHei", "Noto Sans SC", sans-serif;
  padding: 108px 16px calc(56px + env(safe-area-inset-bottom, 0px));
  overflow: auto;
  background: transparent;
}

#jt-gate.is-page {
  padding-top: 36px;
  padding-bottom: calc(20px + env(safe-area-inset-bottom, 0px));
}
#jt-gate.is-page .jt-card { max-height: calc(100dvh - 40px); }
#jt-gate.is-page h1 { font-size: 22px; letter-spacing: 0.12em; margin: 0; }
#jt-gate.is-page .jt-field { margin-top: 8px; padding-top: 5px; padding-bottom: 5px; }
#jt-gate.is-page .jt-sub { margin: 4px 0 8px; }

.jt-nav {
  display: grid;
  grid-template-columns: 76px 1fr 76px;
  align-items: center;
  margin: 0 0 6px;
}

.jt-back {
  justify-self: start;
  padding: 6px 0;
  color: #8c1224;
  font-size: 18px;
}

.jt-nav h1 { text-align: center; }

.jt-links {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 12px 2px 0;
}

.jt-links button {
  padding: 4px 0;
  border: 0;
  background: none;
  color: #8c1224;
  font-size: 16px;
  font-weight: 600;
}

.jt-card {
  width: min(420px, 100%);
  max-height: calc(100dvh - 136px);
  overflow: auto;
  margin-top: auto;
  padding: 16px 18px 18px;
  border-radius: 26px;
  color: #3a2218;
  background:
    linear-gradient(180deg, rgba(255, 250, 243, 0.94), rgba(255, 246, 234, 0.92)) padding-box,
    linear-gradient(145deg, #f6e2a8, #b8862f 38%, #8c1224 62%, #f0d48a) border-box;
  border: 1.5px solid transparent;
  box-shadow:
    0 18px 40px rgba(70, 8, 16, 0.28),
    inset 0 0 0 1px rgba(255, 248, 230, 0.65);
  backdrop-filter: blur(16px) saturate(1.15);
}

.jt-seal {
  width: 72px;
  height: 72px;
  position: relative;
  z-index: 2;
  margin: 2px auto 8px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  color: #fff8ea;
  font-size: 30px;
  font-weight: 700;
  background: radial-gradient(circle at 32% 28%, #f05a66, #c8102e 46%, #7d1020 100%);
  box-shadow:
    0 0 0 3px #f4d78a,
    0 0 0 6px rgba(140, 18, 36, 0.35),
    0 10px 20px rgba(80, 10, 16, 0.35);
}

.jt-kicker {
  margin: 4px 0 0;
  text-align: center;
  color: #7a4e12;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.28em;
}

.jt-card h1 {
  margin: 2px 0 0;
  text-align: center;
  color: #8c1224;
  font-size: 34px;
  font-weight: 700;
  letter-spacing: 0.22em;
}

.jt-rule {
  width: 72px;
  height: 2px;
  margin: 10px auto 0;
  border-radius: 2px;
  background: linear-gradient(90deg, transparent, #d4a24a, transparent);
}

.jt-sub {
  margin: 8px 0 14px;
  text-align: center;
  color: #3a2218;
  font-size: 15px;
  font-weight: 600;
}

.jt-field {
  display: block;
  margin: 12px 0 0;
  padding: 8px 14px 9px;
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(255, 252, 246, 0.96), rgba(255, 243, 224, 0.88));
  box-shadow:
    inset 0 1px 2px rgba(120, 48, 20, 0.08),
    inset 0 0 0 1px rgba(198, 154, 74, 0.55);
}

.jt-field span {
  display: block;
  color: #8c1224;
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.04em;
}

.jt-field input {
  width: 100%;
  min-height: 30px;
  margin: 0;
  padding: 1px 0 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  color: #2a160f;
  font: inherit;
  font-size: 18px;
  font-weight: 600;
}

.jt-field input::placeholder { color: #8a6248; }

.jt-field:focus-within {
  box-shadow:
    inset 0 1px 2px rgba(120, 48, 20, 0.06),
    inset 0 0 0 1px #c6a15b,
    0 0 0 3px rgba(198, 161, 91, 0.28);
}

.jt-field input:focus { outline: none; }

.jt-hint {
  margin: 10px 2px 0;
  color: #3a2218;
  font-size: 13px;
  line-height: 1.5;
}

.jt-err {
  min-height: 20px;
  margin: 8px 0 0;
  text-align: center;
  color: #9d1828;
  font-size: 14px;
}

.jt-go {
  position: relative;
  overflow: hidden;
  width: 100%;
  margin-top: 14px;
  min-height: 52px;
  border-radius: 16px;
  border: 1px solid #e8c56b;
  color: #fff8ea;
  font-size: 18px;
  letter-spacing: 0.2em;
  background:
    linear-gradient(180deg, rgba(255, 226, 170, 0.38), rgba(255, 226, 170, 0) 46%),
    linear-gradient(180deg, #e23b4c 0%, #c41e32 52%, #8e1526 100%);
  box-shadow:
    inset 0 1px 0 rgba(255, 236, 196, 0.55),
    0 10px 18px rgba(140, 18, 36, 0.28);
}

.jt-go:disabled { opacity: 0.92; }

.jt-go.is-busy span { visibility: hidden; }

.jt-go.is-busy::before {
  content: "";
  position: absolute;
  top: -20%;
  bottom: -20%;
  left: 0;
  width: 45%;
  background: linear-gradient(90deg, transparent, rgba(255, 236, 180, 0.85), transparent);
  transform: translateX(-180%);
  animation: jt-sheen 0.9s ease-in-out infinite;
}

.jt-go.is-busy::after {
  content: "";
  position: absolute;
  z-index: 1;
  left: 50%;
  top: 50%;
  width: 28px;
  height: 28px;
  margin: -14px 0 0 -14px;
  border-radius: 50%;
  border: 3px solid rgba(255, 248, 234, 0.28);
  border-top-color: #ffe7a3;
  border-right-color: #fff;
  box-shadow: 0 0 12px rgba(255, 214, 120, 0.9);
  animation: jt-spin 0.55s linear infinite;
}

.jt-go.is-busy {
  animation: jt-wait 0.9s ease-in-out infinite;
}

@keyframes jt-spin {
  to { transform: rotate(360deg); }
}

@keyframes jt-sheen {
  to { transform: translateX(420%); }
}

@keyframes jt-wait {
  0%, 100% {
    filter: brightness(1);
    box-shadow:
      inset 0 1px 0 rgba(255, 236, 196, 0.55),
      0 10px 18px rgba(140, 18, 36, 0.28);
  }
  50% {
    filter: brightness(1.22);
    box-shadow:
      inset 0 1px 0 rgba(255, 236, 196, 0.8),
      0 0 0 4px rgba(255, 214, 120, 0.35),
      0 12px 24px rgba(140, 18, 36, 0.4);
  }
}

.jt-pin {
  display: block;
  margin-top: 12px;
  color: #5c4036;
  font-size: 14px;
}

.jt-pin input {
  width: 100%;
  margin-top: 6px;
  min-height: 46px;
  padding: 0 12px;
  border-radius: 12px;
  border: 1px solid rgba(198, 154, 74, 0.55);
  background: #fffaf3;
  font-size: 20px;
  letter-spacing: 0.3em;
}
