/* The web entry's own pages: warm paper, one soft card, the admin page's blue for what you press. */
:root {
  --g-font: "HarmonyOS Sans SC", "MiSans", "PingFang SC", "Microsoft YaHei UI", "Microsoft YaHei", system-ui,
            -apple-system, "Segoe UI", sans-serif;
  --g-bg: #f6f2ea;
  --g-panel: #fffdf9;
  --g-line: rgba(64, 46, 24, .10);
  --g-line-strong: rgba(64, 46, 24, .18);
  --g-text: #211b14;
  --g-text-2: #5d5346;
  --g-muted: #998d7d;
  --g-accent: #2a5bd7;
  --g-accent-deep: #1b3e9e;
  --g-warm: #e07a52;
  --g-warm-soft: #fbefe6;
  --g-warm-text: #7a4f36;
  --g-ok: #18915f;
  --g-error: #c0483a;
  --g-error-soft: #fcefec;
  --g-shadow: 0 1px 2px rgba(48, 32, 12, .05), 0 22px 48px -22px rgba(48, 32, 12, .28);
}

* { box-sizing: border-box; }
html, body { margin: 0; }
body {
  min-height: 100vh;
  color: var(--g-text);
  font: 15px/1.65 var(--g-font);
  -webkit-font-smoothing: antialiased;
  background:
    radial-gradient(900px 520px at 8% -12%, #fde3cf 0%, rgba(253, 227, 207, 0) 62%),
    radial-gradient(760px 480px at 104% 4%, #e3eafc 0%, rgba(227, 234, 252, 0) 58%),
    linear-gradient(180deg, #f8f4ec 0%, var(--g-bg) 100%);
  background-attachment: fixed;
}
::selection { background: rgba(42, 91, 215, .16); }

.g-wrap { max-width: 440px; margin: 0 auto; padding: 64px 16px 40px; }
.g-brand { display: flex; align-items: center; justify-content: center; gap: 10px; margin-bottom: 24px; }
.g-logo {
  width: 38px; height: 38px; border-radius: 12px; display: grid; place-items: center; color: #fff;
  background: linear-gradient(145deg, #3b6ff0 0%, var(--g-accent-deep) 100%);
  box-shadow: 0 8px 18px -8px rgba(27, 62, 158, .55);
}
.g-logo svg { width: 22px; height: 22px; }
.g-word { font-size: 17px; font-weight: 700; letter-spacing: .06em; color: var(--g-text); }

.g-card {
  position: relative; padding: 32px 30px 28px; border-radius: 22px; background: var(--g-panel);
  border: 1px solid var(--g-line); box-shadow: var(--g-shadow);
}
.g-card::before {
  content: ""; position: absolute; inset: 0 0 auto; height: 4px; border-radius: 22px 22px 0 0;
  background: linear-gradient(90deg, var(--g-warm) 0%, #f2b48f 45%, #8fb0f7 100%); opacity: .8;
}
.g-title { margin: 0 0 6px; font-size: 22px; line-height: 1.35; font-weight: 700; letter-spacing: .01em; }
.g-lede { margin: 0 0 22px; color: var(--g-text-2); }

.g-label { display: block; margin-bottom: 7px; font-size: 13px; font-weight: 600; color: var(--g-text-2); }
.g-input {
  width: 100%; height: 48px; padding: 0 15px; border-radius: 13px; border: 1px solid var(--g-line-strong);
  background: #fff; color: var(--g-text); font: 15px var(--g-font); letter-spacing: .02em;
  transition: border-color .15s, box-shadow .15s;
}
.g-input::placeholder { color: #bdb3a5; }
.g-input:focus { outline: none; border-color: var(--g-accent); box-shadow: 0 0 0 4px rgba(42, 91, 215, .13); }

.g-button {
  display: flex; align-items: center; justify-content: center; width: 100%; height: 48px; margin-top: 16px;
  border: 0; border-radius: 13px; cursor: pointer; text-decoration: none;
  background: linear-gradient(180deg, #3769ea 0%, var(--g-accent) 100%); color: #fff;
  font: 600 15px var(--g-font); letter-spacing: .08em;
  box-shadow: 0 10px 20px -10px rgba(42, 91, 215, .7), inset 0 1px 0 rgba(255, 255, 255, .18);
  transition: filter .12s, transform .12s, box-shadow .12s;
}
.g-button:hover { filter: brightness(1.05); }
.g-button:active { transform: translateY(1px); }
.g-secondary {
  background: #fff; color: var(--g-accent-deep); border: 1px solid var(--g-line-strong); box-shadow: none;
}
.g-secondary:hover { background: #fbfaf7; filter: none; }
.g-button:focus-visible, .g-text-button:focus-visible, .g-choice:focus-visible {
  outline: 2px solid var(--g-accent); outline-offset: 3px;
}

.g-error {
  margin: 12px 0 0; padding: 10px 13px; border-radius: 11px; background: var(--g-error-soft); color: var(--g-error);
  font-size: 13.5px;
}
.g-or { display: flex; align-items: center; gap: 12px; margin: 24px 0 16px; color: var(--g-muted); font-size: 12.5px; }
.g-or::before, .g-or::after { content: ""; flex: 1; height: 1px; background: var(--g-line); }
.g-tip {
  display: flex; gap: 12px; align-items: flex-start; padding: 14px 15px; border-radius: 15px;
  background: var(--g-warm-soft); color: var(--g-warm-text); font-size: 14px; line-height: 1.6;
}
.g-tip p { margin: 0; }
.g-tip-icon {
  flex: none; width: 32px; height: 32px; border-radius: 10px; display: grid; place-items: center;
  background: #fff; color: var(--g-warm); box-shadow: 0 2px 6px -3px rgba(224, 122, 82, .5);
}
.g-tip-icon svg { width: 19px; height: 19px; }
.g-tip-note { color: #a07a62; font-size: 12.5px; }
.g-note { margin: 14px 0 0; text-align: center; color: var(--g-muted); font-size: 13px; }

.g-bot {
  display: flex; align-items: center; gap: 13px; margin: 2px 0 6px; padding: 13px 15px; border-radius: 16px;
  background: #fff; border: 1px solid var(--g-line);
}
.g-avatar {
  flex: none; width: 44px; height: 44px; border-radius: 13px; display: grid; place-items: center;
  background: linear-gradient(145deg, #eef3ff, #e1e9fd); color: var(--g-accent); font-weight: 700; font-size: 19px;
}
.g-bot-text { display: flex; flex-direction: column; min-width: 0; line-height: 1.45; }
.g-bot-name { font-weight: 700; font-size: 15.5px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.g-bot-meta { font-size: 12.5px; color: var(--g-muted); }
.g-dot {
  display: inline-block; width: 7px; height: 7px; margin-right: 7px; border-radius: 50%; vertical-align: 1px;
  background: #c9bfb1;
}
.g-online .g-dot { background: var(--g-ok); box-shadow: 0 0 0 3px rgba(24, 145, 95, .16); }

.g-choice {
  display: block; width: 100%; margin: 0 0 10px; padding: 0; border: 0; background: none; cursor: pointer;
  text-align: left; font: inherit; color: inherit; border-radius: 16px;
}
.g-choice .g-bot { margin: 0; transition: border-color .15s, box-shadow .15s; }
.g-choice:hover .g-bot { border-color: rgba(42, 91, 215, .35); box-shadow: 0 6px 16px -10px rgba(42, 91, 215, .45); }

.g-logout { margin-top: 18px; text-align: center; }
.g-text-button {
  padding: 4px 8px; border: 0; background: none; cursor: pointer; color: var(--g-muted);
  font: 13px var(--g-font); text-decoration: underline; text-underline-offset: 3px;
}
.g-text-button:hover { color: var(--g-text-2); }
.g-foot { margin: 20px 0 0; text-align: center; color: var(--g-muted); font-size: 12.5px; }

/* 开通 */
.g-link { color: var(--g-accent-deep); text-underline-offset: 3px; }
.g-steps {
  display: flex; gap: 6px; margin: -6px 0 22px; padding: 0; list-style: none; counter-reset: step;
  font-size: 12.5px; color: var(--g-muted);
}
.g-steps li { flex: 1; text-align: center; counter-increment: step; }
.g-steps li::before {
  content: counter(step); display: grid; place-items: center; width: 24px; height: 24px; margin: 0 auto 4px;
  border-radius: 50%; background: #efe9df; color: var(--g-muted); font-weight: 700; font-size: 12px;
}
.g-steps li.is-done::before { content: "✓"; background: #dcefe5; color: var(--g-ok); }
.g-steps li.is-now { color: var(--g-text); font-weight: 600; }
.g-steps li.is-now::before { background: var(--g-accent); color: #fff; }
.g-key {
  padding: 14px 15px; border-radius: 13px; background: #f7f3ec; border: 1px dashed var(--g-line-strong);
  word-break: break-all; font: 13.5px/1.55 ui-monospace, "Cascadia Mono", Consolas, monospace; user-select: all;
}
.g-row { display: flex; gap: 10px; }
.g-row .g-button { margin-top: 12px; }
.g-check { display: flex; align-items: center; gap: 9px; margin-top: 16px; font-size: 14px; color: var(--g-text-2); }
.g-check input { width: 17px; height: 17px; accent-color: var(--g-accent); }
.g-button:disabled { opacity: .45; cursor: default; filter: none; }
.g-gap { margin-top: 14px; }
.g-hint { margin: 6px 0 14px; font-size: 12.5px; color: var(--g-muted); }
.g-muted { color: var(--g-muted); margin: 0; }
.g-progress { margin: 0; padding: 0; list-style: none; }
.g-progress li {
  position: relative; padding: 9px 0 9px 30px; color: var(--g-muted); border-bottom: 1px solid var(--g-line);
}
.g-progress li:last-child { border-bottom: 0; }
.g-progress li::before {
  content: ""; position: absolute; left: 4px; top: 50%; width: 12px; height: 12px; margin-top: -6px;
  border-radius: 50%; border: 2px solid #d5ccbf;
}
.g-progress li.is-done { color: var(--g-text); }
.g-progress li.is-done::before { background: var(--g-ok); border-color: var(--g-ok); }
.g-progress li.is-now { color: var(--g-text); font-weight: 600; }
.g-progress li.is-now::before { border-color: var(--g-accent); border-top-color: transparent; animation: g-spin 1s linear infinite; }
@keyframes g-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .g-progress li.is-now::before { animation: none; } }
.g-qr {
  display: grid; place-items: center; min-height: 236px; padding: 14px; border-radius: 16px; background: #fff;
  border: 1px solid var(--g-line);
}
.g-qr img { width: 208px; height: 208px; image-rendering: pixelated; }

@media (max-width: 480px) {
  .g-wrap { padding-top: 36px; }
  .g-card { padding: 26px 20px 22px; border-radius: 20px; }
  .g-card::before { border-radius: 20px 20px 0 0; }
}
