:root {
  --ink: #0f172a;
  --muted: #64748b;
  --blue: #2563eb;
  --indigo: #4f46e5;
  --line: #e2e8f0;
  --line-strong: #cbd5e1;
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: #f8fafc;
  background-image:
    radial-gradient(at 10% 10%, rgba(37, 99, 235, 0.08) 0px, transparent 50%),
    radial-gradient(at 90% 15%, rgba(79, 70, 229, 0.08) 0px, transparent 45%);
  color: var(--ink);
  font: 14px -apple-system, BlinkMacSystemFont, "PingFang SC", "Microsoft YaHei", "Inter", system-ui, sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button, input { font: inherit; }
button { cursor: pointer; }
button:disabled { opacity: 0.65; cursor: wait; }
button:focus-visible, a:focus-visible, input:focus-visible {
  outline: none;
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.22);
}

.header-wrap {
  border-bottom: 1px solid rgba(226, 232, 240, 0.9);
  background: rgba(255, 255, 255, 0.82);
  backdrop-filter: blur(14px);
}
header {
  max-width: 1220px;
  margin: auto;
  padding: 18px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.brand {
  font-size: 21px;
  font-weight: 800;
  letter-spacing: -0.6px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.logo {
  background: linear-gradient(135deg, var(--blue), var(--indigo));
  color: white;
  width: 34px;
  height: 34px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 9px;
  font-size: 19px;
  font-weight: 800;
  box-shadow: 0 4px 12px rgba(37, 99, 235, 0.25);
}
.badge-or {
  font-size: 11px;
  background: #eff6ff;
  color: var(--blue);
  border: 1px solid #bfdbfe;
  padding: 3px 9px;
  border-radius: 99px;
  font-weight: 600;
}
.back-link {
  font-size: 13.5px;
  font-weight: 600;
  color: #475569;
  padding: 8px 14px;
  border-radius: 8px;
  border: 1px solid var(--line);
  background: white;
  transition: all 0.15s;
}
.back-link:hover {
  border-color: #94a3b8;
  color: var(--ink);
}

main {
  max-width: 1220px;
  width: 100%;
  margin: 36px auto 52px;
  padding: 0 32px;
  display: grid;
  grid-template-columns: 1.08fr 0.92fr;
  gap: 64px;
  align-items: start;
  flex: 1;
}
.intro { padding-top: 16px; }
.tag {
  font-size: 12.5px;
  color: var(--blue);
  font-weight: 700;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #eff6ff;
  border: 1px solid #bfdbfe;
  padding: 5px 13px;
  border-radius: 99px;
}
h1 {
  font-size: 44px;
  line-height: 1.2;
  letter-spacing: -1.4px;
  margin: 20px 0 16px;
}
.gradient-text {
  background: linear-gradient(135deg, #2563eb 0%, #4f46e5 65%, #0ea5e9 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}
p { color: var(--muted); line-height: 1.78; }
.intro > p { font-size: 15.5px; max-width: 520px; margin: 0; }
.intro code {
  background: #f1f5f9;
  color: #1e293b;
  padding: 2px 6px;
  border-radius: 5px;
  font-size: 12.5px;
  border: 1px solid #e2e8f0;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
}

.journey {
  margin-top: 28px;
  display: grid;
  gap: 14px;
}
.journey article {
  background: white;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 18px 20px;
  box-shadow: 0 2px 8px rgba(15, 23, 42, 0.03);
}
.journey-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 8px;
}
.pill {
  font-size: 11px;
  font-weight: 600;
  padding: 3px 9px;
  border-radius: 99px;
}
.pill.live { background: #ecfdf5; color: #047857; border: 1px solid #a7f3d0; }
.pill.router { background: #eff6ff; color: #1d4ed8; border: 1px solid #bfdbfe; }
.muted { font-size: 12px; color: var(--muted); }
.journey h2 { font-size: 16.5px; margin: 6px 0; color: var(--ink); }
.journey p { font-size: 13.5px; margin: 0; }

.client-strip {
  margin-top: 22px;
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  font-size: 12.5px;
  color: var(--muted);
}
.client-strip code {
  background: white;
  border: 1px solid var(--line);
  padding: 4px 9px;
  border-radius: 6px;
  color: #334155;
  font-weight: 600;
}

.account {
  border: 1px solid var(--line);
  border-radius: 18px;
  background: white;
  padding: 32px;
  box-shadow: 0 20px 50px -12px rgba(15, 23, 42, 0.1);
}
.tabs {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  background: #f1f5f9;
  padding: 5px;
  border-radius: 10px;
  margin-bottom: 24px;
}
.tabs button {
  padding: 10px 12px;
  border: 0;
  background: transparent;
  color: #475569;
  border-radius: 7px;
  font-size: 13px;
  font-weight: 600;
  transition: all 0.15s;
}
.tabs button[aria-pressed="true"] {
  background: white;
  color: var(--blue);
  box-shadow: 0 1px 3px rgba(15, 23, 42, 0.1);
}
.account h2 { font-size: 22px; margin: 0; letter-spacing: -0.4px; }
.account > p { margin: 6px 0 22px; font-size: 13.5px; }

fieldset {
  border: 0;
  padding: 0;
  margin: 0 0 18px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}
legend {
  margin-bottom: 8px;
  font-size: 13px;
  font-weight: 600;
  color: #334155;
}
.choice {
  border: 1px solid var(--line);
  border-radius: 10px;
  display: flex;
  padding: 12px;
  gap: 9px;
  align-items: flex-start;
  cursor: pointer;
  transition: all 0.15s;
}
.choice:hover { border-color: #94a3b8; }
.choice:has(input:checked) {
  border-color: var(--blue);
  background: #eff6ff;
  box-shadow: 0 0 0 1px var(--blue);
}
.choice input { accent-color: var(--blue); margin-top: 3px; }
.choice strong { font-size: 13px; font-weight: 700; display: block; color: var(--ink); }
.choice small { font-size: 11.5px; color: var(--muted); display: block; margin-top: 3px; }

.field {
  display: block;
  font-size: 13px;
  font-weight: 600;
  color: #334155;
  margin-bottom: 16px;
}
.field > input, .password-wrap { margin-top: 7px; }
.field input:not([type="radio"]) {
  width: 100%;
  border: 1px solid var(--line-strong);
  border-radius: 9px;
  padding: 11px 13px;
  color: var(--ink);
  background: #f8fafc;
  font-weight: 400;
  transition: all 0.15s;
}
.field input:not([type="radio"]):focus {
  background: white;
  border-color: var(--blue);
}
.password-wrap {
  display: flex;
  align-items: center;
  position: relative;
}
.password-wrap input { padding-right: 65px !important; }
.password-wrap button {
  position: absolute;
  right: 8px;
  background: #e2e8f0;
  border: 0;
  color: #334155;
  padding: 5px 10px;
  border-radius: 6px;
  font-size: 12px;
  font-weight: 600;
}
.help { font-size: 12px; color: var(--muted); margin: -6px 0 14px; }
.primary {
  width: 100%;
  border: 0;
  border-radius: 10px;
  background: linear-gradient(135deg, var(--blue), var(--indigo));
  color: white;
  padding: 13px;
  font-size: 14px;
  font-weight: 700;
  margin-top: 6px;
  box-shadow: 0 4px 14px rgba(37, 99, 235, 0.28);
  transition: all 0.15s;
}
.primary:hover {
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.36);
  transform: translateY(-1px);
}
#form-error {
  background: #fef2f2;
  border: 1px solid #fecaca;
  color: #b91c1c;
  border-radius: 8px;
  padding: 11px 13px;
  font-size: 13px;
  margin-bottom: 12px;
}
footer {
  text-align: center;
  color: var(--muted);
  font-size: 12.5px;
  padding: 20px;
  border-top: 1px solid var(--line);
}

@media (max-width: 920px) {
  main { grid-template-columns: 1fr; gap: 32px; margin-top: 20px; }
  h1 { font-size: 34px; }
}
