:root {
  --primary: #4f46e5;
  --primary-dark: #4338ca;
  --accent: #6366f1;
  --ink: #0f172a;
  --success: #10b981;
  --danger: #ef4444;
  --text: #1e293b;
  --text-muted: #64748b;
  --bg: #f8fafc;
  --white: #ffffff;
  --border: #e7e9ee;
  --shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 8px 24px rgba(15, 23, 42, .05);
  --shadow-lg: 0 18px 48px rgba(15, 23, 42, .10);
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--primary); text-decoration: none; }

.container { width: 100%; max-width: 1200px; margin: 0 auto; padding: 0 20px; }

/* ---------- Header ---------- */
.site-header {
  background: rgba(255, 255, 255, .86);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
}
.header-inner { display: flex; align-items: center; height: 68px; gap: 32px; }

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 18px;
  font-weight: 700;
  letter-spacing: -.2px;
  color: var(--ink);
  white-space: nowrap;
}
.logo .mark {
  width: 30px; height: 30px;
  display: grid; place-items: center;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  font-size: 14px;
  font-weight: 700;
}

.main-nav { display: flex; gap: 2px; flex: 1; justify-content: center; }
.main-nav a {
  padding: 8px 14px;
  color: var(--text-muted);
  font-size: 14px;
  font-weight: 500;
  border-radius: 8px;
  transition: color .18s, background .18s;
}
.main-nav a:hover { color: var(--ink); background: #f5f6f8; }
.main-nav a.active { color: var(--ink); font-weight: 600; }

.user-nav { display: flex; gap: 8px; align-items: center; margin-left: auto; flex-shrink: 0; }

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 22px;
  border: 1px solid transparent;
  border-radius: 10px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  white-space: nowrap;
  cursor: pointer;
  transition: background .18s, color .18s, border-color .18s, box-shadow .18s;
}
.btn-primary { background: var(--primary); color: #fff; }
.btn-primary:hover { background: var(--primary-dark); box-shadow: 0 8px 20px rgba(79, 70, 229, .22); }
.btn-outline { background: #fff; color: var(--ink); border-color: #d9dce3; }
.btn-outline:hover { border-color: var(--ink); }
.btn-ghost { background: transparent; color: var(--text-muted); }
.btn-ghost:hover { color: var(--ink); }
.btn-light { background: #fff; color: var(--ink); }
.btn-light:hover { background: #eef0f4; }
.btn-sm { padding: 8px 16px; font-size: 13px; }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 92px 0 100px;
  background: #fff;
  border-bottom: 1px solid var(--border);
}
.hero::before {
  content: "";
  position: absolute;
  top: -280px;
  right: -160px;
  width: 660px;
  height: 660px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(79, 70, 229, .10), rgba(79, 70, 229, 0) 65%);
  pointer-events: none;
}
.hero-inner {
  position: relative;
  display: grid;
  grid-template-columns: 1.05fr .95fr;
  align-items: center;
  gap: 64px;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: #fff;
  color: var(--text-muted);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: .3px;
}
.eyebrow::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--primary); }
.hero h1 {
  margin: 22px 0 20px;
  font-size: 52px;
  line-height: 1.14;
  font-weight: 700;
  letter-spacing: -1.6px;
  color: var(--ink);
}
.hero h1 em { font-style: normal; color: var(--primary); }
.hero p.lead { max-width: 520px; color: var(--text-muted); font-size: 16.5px; line-height: 1.75; }
.hero .actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 32px; }
.hero-points {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  margin-top: 30px;
  list-style: none;
  color: var(--text-muted);
  font-size: 13px;
}
.hero-points li { display: flex; align-items: center; gap: 7px; }
.hero-points svg { flex: 0 0 auto; color: var(--success); }

.hero-panel { position: relative; display: flex; justify-content: flex-end; }
.panel-card {
  width: 100%;
  max-width: 400px;
  padding: 26px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 20px;
  box-shadow: var(--shadow-lg);
}
.panel-head { display: flex; align-items: center; justify-content: space-between; font-size: 13px; color: var(--text-muted); }
.panel-live {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  background: #ecfdf5;
  color: #047857;
  font-size: 12px;
  font-weight: 600;
}
.panel-live::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: var(--success); }
.panel-main { display: flex; align-items: baseline; gap: 8px; margin-top: 22px; }
.panel-main strong {
  font-size: 44px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: -1.5px;
  color: var(--ink);
  font-variant-numeric: tabular-nums;
}
.panel-main span { color: var(--text-muted); font-size: 14px; }
.panel-sub { margin-top: 8px; font-size: 13px; font-weight: 500; color: var(--success); }
.panel-bars {
  display: flex;
  align-items: flex-end;
  gap: 8px;
  height: 104px;
  margin: 24px 0 22px;
  padding-bottom: 1px;
  border-bottom: 1px solid var(--border);
}
.panel-bars i { flex: 1; height: 38%; border-radius: 6px 6px 2px 2px; background: #e0e7ff; }
.panel-bars i:nth-child(2) { height: 55%; }
.panel-bars i:nth-child(3) { height: 46%; }
.panel-bars i:nth-child(4) { height: 68%; }
.panel-bars i:nth-child(5) { height: 58%; }
.panel-bars i:nth-child(6) { height: 82%; }
.panel-bars i.on { height: 72%; background: var(--primary); }
.panel-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.panel-stats div { padding: 14px; border-radius: 12px; background: #f8f9fb; }
.panel-stats span { display: block; margin-bottom: 4px; font-size: 12px; color: var(--text-muted); }
.panel-stats strong { font-size: 16px; color: var(--ink); }

/* ---------- Sections ---------- */
.section { padding: 88px 0; }
.section.alt { background: #fafbfc; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.section-head { max-width: 560px; margin: 0 auto 48px; text-align: center; }
.section-head .kicker {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 1.4px;
  text-transform: uppercase;
  color: var(--primary);
}
.section-head h2 { margin: 10px 0 12px; font-size: 32px; letter-spacing: -.8px; color: var(--ink); }
.section-head p { color: var(--text-muted); font-size: 15px; }

.step-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 40px; }
.step-item { padding-top: 24px; border-top: 1px solid var(--border); }
.step-no { display: block; margin-bottom: 14px; font-size: 13px; font-weight: 700; letter-spacing: 1px; color: var(--primary); }
.step-item h3 { margin-bottom: 8px; font-size: 18px; letter-spacing: -.2px; color: var(--ink); }
.step-item p { font-size: 14.5px; color: var(--text-muted); }

.feature-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.feature-item {
  padding: 26px 22px;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 16px;
  transition: border-color .2s, box-shadow .2s, transform .2s;
}
.feature-item:hover { transform: translateY(-3px); border-color: #c9cdf5; box-shadow: var(--shadow); }
.feature-item .icon {
  width: 42px; height: 42px;
  display: grid; place-items: center;
  margin-bottom: 18px;
  border-radius: 11px;
  background: #eef2ff;
  color: var(--primary);
}
.feature-item h3 { margin-bottom: 6px; font-size: 16px; color: var(--ink); }
.feature-item p { font-size: 14px; line-height: 1.7; color: var(--text-muted); }

/* ---------- CTA ---------- */
.cta { padding: 0 0 88px; }
.cta-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
  padding: 48px 52px;
  border-radius: 20px;
  background: var(--ink);
}
.cta-inner h2 { margin-bottom: 8px; font-size: 26px; letter-spacing: -.5px; color: #fff; }
.cta-inner p { font-size: 14.5px; color: #94a3b8; }
.cta-inner .actions { display: flex; flex-shrink: 0; gap: 12px; }

/* ---------- Footer ---------- */
.site-footer { margin-top: auto; padding: 56px 0 26px; background: #fff; border-top: 1px solid var(--border); }
.footer-grid { display: grid; grid-template-columns: 1.6fr 1fr 1fr; gap: 40px; padding-bottom: 36px; }
.footer-brand .logo { margin-bottom: 14px; }
.footer-brand p { max-width: 320px; font-size: 13.5px; line-height: 1.75; color: var(--text-muted); }
.site-footer h4 { margin-bottom: 14px; font-size: 13px; font-weight: 600; letter-spacing: .2px; color: var(--ink); }
.site-footer ul { list-style: none; }
.site-footer li { margin-bottom: 9px; }
.site-footer a { color: var(--text-muted); font-size: 13.5px; transition: color .18s; }
.site-footer a:hover { color: var(--primary); }
.footer-contact { font-size: 13.5px; color: var(--text-muted); }
.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 16px;
  padding-top: 22px;
  border-top: 1px solid var(--border);
  font-size: 12.5px;
  color: #94a3b8;
}

/* ---------- Auth ---------- */
.auth-section {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 48px 20px;
  background: linear-gradient(160deg, #eef2ff 0%, var(--bg) 60%);
}
.auth-box {
  width: 420px;
  max-width: 100%;
  padding: 34px 30px 26px;
  background: #fff;
  border-radius: 16px;
  box-shadow: var(--shadow-lg);
}
.auth-head { text-align: center; margin-bottom: 20px; }
.auth-head .mark {
  width: 46px; height: 46px;
  display: grid; place-items: center;
  margin: 0 auto 12px;
  border-radius: 13px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  font-size: 20px;
  font-weight: 700;
}
.auth-head h1 { font-size: 20px; margin-bottom: 4px; }
.auth-head p { color: var(--text-muted); font-size: 13px; }

.tabs { display: flex; gap: 4px; padding: 4px; margin-bottom: 20px; background: var(--bg); border-radius: 10px; }
.tabs button {
  flex: 1;
  padding: 9px 0;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--text-muted);
  font-size: 14px;
  font-family: inherit;
  cursor: pointer;
  transition: .2s;
}
.tabs button:hover { color: var(--primary); }
.tabs button.active { background: #fff; color: var(--primary); font-weight: 600; box-shadow: 0 1px 4px rgba(0, 0, 0, .08); }

.pane { display: none; }
.pane.active { display: block; animation: paneIn .2s ease; }
@keyframes paneIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }

.field { display: block; margin-bottom: 16px; }
.field > span { display: block; margin-bottom: 6px; font-size: 14px; font-weight: 500; color: var(--text); }

input {
  width: 100%;
  padding: 10px 14px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: .2s;
}
input::placeholder { color: #9ca3af; }
input:focus { border-color: var(--primary); box-shadow: 0 0 0 3px rgba(102, 126, 234, .15); }

.captcha-row { display: flex; gap: 10px; }
.captcha-row input { flex: 1; min-width: 0; }
.captcha-row img {
  width: 112px; height: 42px;
  flex: 0 0 112px;
  border: 1.5px solid var(--border);
  border-radius: 8px;
  background: #eef2f8;
  object-fit: cover;
  cursor: pointer;
}

.submit {
  width: 100%;
  padding: 11px;
  margin-top: 4px;
  border: none;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  color: #fff;
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: .2s;
}
.submit:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(102, 126, 234, .4); }
.submit:disabled { opacity: .55; cursor: not-allowed; transform: none; box-shadow: none; }

.toast {
  position: fixed;
  top: 20px;
  left: 50%;
  z-index: 999;
  display: flex;
  align-items: center;
  gap: 8px;
  max-width: 90vw;
  padding: 11px 18px;
  border: 1px solid var(--border);
  border-radius: 10px;
  background: #fff;
  box-shadow: var(--shadow-lg);
  font-size: 13px;
  font-weight: 500;
  opacity: 0;
  transform: translateX(-50%) translateY(-12px);
  pointer-events: none;
  transition: opacity .22s, transform .22s;
}
.toast.show { opacity: 1; transform: translateX(-50%); }
.toast::before { font-weight: 700; }
.toast.ok::before { content: "✓"; }
.toast.err::before { content: "!"; }
.toast.ok { background: #ecfdf5; border-color: #a7f3d0; color: #065f46; }
.toast.err { background: #fee2e2; border-color: #fecaca; color: #991b1b; }

.forgot-question {
  margin: -4px 0 14px;
  padding: 10px 12px;
  border: 1px dashed var(--border);
  border-radius: 8px;
  background: #fff;
  color: var(--text);
  font-size: 13px;
}
.forgot-question.err { border-color: #fecaca; background: #fee2e2; color: #991b1b; }

.auth-links { margin-top: 12px; text-align: center; font-size: 13px; color: var(--text-muted); }
.auth-links a { color: var(--primary); }
.auth-links span { margin: 0 8px; color: #d1d5db; }

.login-options {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: flex-start;
  gap: 8px;
  margin: 2px 0 14px;
  font-size: 13px;
  color: var(--text-muted);
}
.login-options .check { display: inline-flex; align-items: center; gap: 6px; cursor: pointer; }
.login-options .check input {
  width: 15px;
  height: 15px;
  min-width: 15px;
  padding: 0;
  margin: 0;
  accent-color: var(--primary);
}

.foot { margin-top: 16px; text-align: center; font-size: 13px; color: var(--text-muted); }
.foot a { font-weight: 500; }

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero { padding: 72px 0 80px; }
  .hero-inner { grid-template-columns: 1fr; gap: 48px; }
  .hero h1 { font-size: 44px; }
  .hero-panel { justify-content: flex-start; }
  .step-grid { grid-template-columns: 1fr 1fr; gap: 28px; }
  .feature-grid { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .cta-inner { flex-direction: column; align-items: flex-start; padding: 40px; }
}

@media (max-width: 768px) {
  .header-inner { height: 62px; gap: 12px; }
  .main-nav { display: none; }
  .logo { font-size: 17px; }
  .hero h1 { font-size: 36px; letter-spacing: -1px; }
  .hero p.lead { font-size: 15.5px; }
  .hero-points { gap: 14px 20px; }
  .section { padding: 64px 0; }
  .section-head { margin-bottom: 36px; }
  .section-head h2 { font-size: 26px; }
  .cta { padding-bottom: 64px; }
  .cta-inner { padding: 32px 28px; }
  .cta-inner h2 { font-size: 22px; }
  .auth-section { padding: 28px 16px; }
  .auth-box { padding: 28px 20px 22px; }
}

@media (max-width: 600px) {
  .container { padding: 0 20px; }
  .step-grid, .feature-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }
  .hero { padding: 56px 0 64px; }
  .hero h1 { font-size: 32px; }
  .hero .actions .btn { flex: 1; }
  .hero-points { flex-direction: column; gap: 10px; }
  .panel-card { max-width: none; padding: 22px; }
  .panel-main strong { font-size: 38px; }
  .cta-inner .actions { width: 100%; }
  .cta-inner .actions .btn { width: 100%; }
  .site-footer { padding: 44px 0 22px; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .header-inner { height: 58px; gap: 8px; }
  .logo { font-size: 16px; gap: 7px; }
  .logo .mark { width: 28px; height: 28px; border-radius: 7px; font-size: 13px; }
  .user-nav { gap: 6px; }
  .btn-sm { padding: 7px 12px; font-size: 12px; }
  .hero { padding: 44px 0 56px; }
  .hero h1 { font-size: 29px; }
  .hero p.lead { font-size: 14.5px; }
  .hero .actions { flex-direction: column; gap: 10px; }
  .hero .actions .btn { width: 100%; }
  .section-head h2 { font-size: 22px; }
  .feature-item { padding: 22px 18px; }
  .auth-section { padding: 20px 12px; }
  .auth-box { padding: 24px 16px 18px; border-radius: 14px; }
  .auth-head h1 { font-size: 18px; }
  .field { margin-bottom: 13px; }
  .captcha-row img { width: 96px; flex-basis: 96px; }
}
