@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+SC:wght@400;500;600;700&family=Source+Serif+4:opsz,wght@8..60,600;8..60,700&display=swap');

:root {
  --gate-ink: #e8eef4;
  --gate-muted: #8fa3b8;
  --gate-accent: #34d399;
  --gate-accent-deep: #0f6e56;
  --gate-accent-2: #1a5f7a;
  --gate-danger: #f97066;
  --gate-font: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  --gate-display: "Source Serif 4", "Noto Serif SC", serif;
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; }
body {
  font-family: var(--gate-font);
  color: var(--gate-ink);
  background: #0b1622;
  -webkit-font-smoothing: antialiased;
}

.ai-gate {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 20px 56px;
  position: relative;
  overflow: hidden;
}

.ai-gate-bg {
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(720px 420px at 18% 8%, rgba(15, 110, 86, 0.38), transparent 58%),
    radial-gradient(640px 380px at 88% 92%, rgba(26, 95, 122, 0.36), transparent 55%),
    radial-gradient(480px 240px at 50% 46%, rgba(52, 211, 153, 0.08), transparent 62%),
    linear-gradient(165deg, #102033 0%, #0c1826 52%, #08131e 100%);
}
.ai-gate-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,0.035) 1px, transparent 1px);
  background-size: 52px 52px;
  mask-image: radial-gradient(ellipse at 50% 42%, #000 18%, transparent 78%);
}

.ai-gate-brand {
  position: relative;
  z-index: 1;
  text-align: center;
  margin-bottom: 28px;
}
.ai-gate-kicker {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.16em;
  color: #9fb5c8;
  margin-bottom: 14px;
}
.ai-gate-kicker span {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--gate-accent);
  box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.18), 0 0 18px rgba(52, 211, 153, 0.55);
}
.ai-gate-brand h1 {
  margin: 0;
  font-family: var(--gate-display);
  font-size: 40px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: #fff;
  text-shadow: 0 10px 40px rgba(0, 0, 0, 0.35);
}

.ai-gate-card {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 420px;
  padding: 32px 32px 28px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255,255,255,0.09), rgba(255,255,255,0.045));
  border: 1px solid rgba(255, 255, 255, 0.14);
  box-shadow:
    0 30px 80px rgba(0, 0, 0, 0.38),
    inset 0 1px 0 rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(18px);
}
.ai-gate-card h2 {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: #fff;
}
.ai-gate-card .sub {
  margin: 8px 0 22px;
  font-size: 13px;
  color: var(--gate-muted);
}

.ai-gate-field { margin-bottom: 14px; }
.ai-gate-label {
  font-size: 12px;
  font-weight: 600;
  color: #c5d4e3;
  margin-bottom: 7px;
}
.ai-gate-field input {
  width: 100%;
  height: 46px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(8, 19, 30, 0.55);
  color: #fff;
  padding: 0 14px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: border-color .15s, box-shadow .15s, background .15s;
}
.ai-gate-field input::placeholder { color: #6e8498; }
.ai-gate-field input:focus {
  border-color: rgba(52, 211, 153, 0.55);
  box-shadow: 0 0 0 4px rgba(52, 211, 153, 0.12);
  background: rgba(8, 19, 30, 0.72);
}

.ai-gate-captcha {
  display: grid;
  grid-template-columns: 1fr 148px;
  gap: 10px;
  align-items: end;
}
.ai-gate-captcha-btn {
  height: 46px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 12px;
  overflow: hidden;
  cursor: pointer;
  background: #0e2430;
  line-height: 0;
}
.ai-gate-captcha-btn img {
  display: block;
  width: 148px;
  height: 46px;
  object-fit: cover;
}
.ai-gate-captcha-btn:hover {
  border-color: rgba(52, 211, 153, 0.4);
}
.ai-gate-hint {
  margin: 6px 0 0;
  font-size: 11px;
  color: #7f93a8;
}

.ai-gate-submit {
  width: 100%;
  height: 46px;
  margin-top: 8px;
  border: 0;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, var(--gate-accent-2), var(--gate-accent-deep));
  box-shadow: 0 12px 28px rgba(15, 110, 86, 0.32);
  transition: transform .15s, filter .15s;
}
.ai-gate-submit:hover { filter: brightness(1.08); transform: translateY(-1px); }
.ai-gate-submit:active { transform: translateY(0); }

.ai-gate-foot {
  margin-top: 18px;
  text-align: center;
  font-size: 13px;
  color: #8a9aab;
}
.ai-gate-foot a {
  color: var(--gate-accent);
  text-decoration: none;
  font-weight: 600;
}
.ai-gate-foot a:hover { text-decoration: underline; }

.ai-gate-err {
  background: rgba(249, 112, 102, 0.12);
  color: #fecaca;
  border: 1px solid rgba(249, 112, 102, 0.28);
  padding: 10px 12px;
  border-radius: 10px;
  margin-bottom: 16px;
  font-size: 13px;
}

@media (max-width: 520px) {
  .ai-gate { padding: 32px 16px 40px; }
  .ai-gate-brand h1 { font-size: 28px; }
  .ai-gate-card { padding: 26px 20px 22px; }
  .ai-gate-captcha { grid-template-columns: 1fr; }
  .ai-gate-captcha-btn,
  .ai-gate-captcha-btn img { width: 100%; }
}
