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

:root {
  --bg: #0f1117;
  --card: #1a1d27;
  --card2: #21252f;
  --border: #2c303c;
  --text: #e6e8ee;
  --text-dim: #8b90a0;
  --accent: #f5b62c;
  --accent-dark: #d99a0f;
  --danger: #e5534b;
}

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.login-wrap { position: relative; width: 100%; min-height: 100vh; display: flex; align-items: center; justify-content: center; }
.glow {
  position: absolute; width: 480px; height: 480px; border-radius: 50%;
  background: radial-gradient(circle, rgba(245,182,44,0.15), transparent 65%);
  top: 10%; right: 8%; filter: blur(30px);
}
.glow::after {
  content: ''; position: absolute; width: 400px; height: 400px; border-radius: 50%;
  background: radial-gradient(circle, rgba(90,120,255,0.12), transparent 65%);
  bottom: -220px; left: -160px; filter: blur(30px);
}

.login-card {
  width: 420px; max-width: 92vw; background: var(--card);
  border: 1px solid var(--border); border-radius: 18px;
  padding: 36px 36px 24px; position: relative; z-index: 2;
  box-shadow: 0 20px 60px rgba(0,0,0,0.5);
}

.brand { text-align: center; margin-bottom: 24px; }
.brand-logo {
  width: 72px; height: 72px; margin: 0 auto 12px; border-radius: 18px;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 8px 24px rgba(245,182,44,0.35); object-fit: cover;
  border: 2px solid var(--card2);
}
.brand-icon {
  width: 64px; height: 64px; margin: 0 auto 12px; border-radius: 16px;
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  display: flex; align-items: center; justify-content: center;
  font-size: 30px; color: #15161a; box-shadow: 0 8px 24px rgba(245,182,44,0.35);
}
.brand h1 { font-size: 22px; font-weight: 600; letter-spacing: 1px; }
.brand-sub { color: var(--text-dim); font-size: 13px; margin-top: 4px; }

/* 激活码授权面板 */
.license-panel { margin-bottom: 4px; }
.license-title { text-align: center; font-size: 17px; font-weight: 600; margin-bottom: 8px; }
.license-desc { text-align: center; color: var(--text-dim); font-size: 12.5px; line-height: 1.7; margin-bottom: 16px; }
.license-hint { text-align: center; color: var(--text-dim); font-size: 12.5px; margin-top: 12px; }
.device-source { text-align: center; font-size: 12px; margin-top: 8px; padding: 6px 10px; border-radius: 6px; }
.device-source.ok { color: #7ce3a0; background: rgba(46,165,90,0.12); border: 1px solid rgba(46,165,90,0.35); }
.device-source.warn { color: #ffc07a; background: rgba(245,150,60,0.12); border: 1px solid rgba(245,150,60,0.4); }
.license-options { display: flex; gap: 20px; justify-content: center; margin-top: 14px; }
.check { display: inline-flex; align-items: center; gap: 6px; color: var(--text-dim); font-size: 13px; cursor: pointer; user-select: none; }
.check input { accent-color: var(--accent); width: 15px; height: 15px; cursor: pointer; }
.check:hover { color: var(--text); }
.foot-auth { display: block; color: var(--text-dim); font-size: 12px; margin-top: 6px; }
.foot-auth::before { content: '● '; }

.tabs { display: flex; background: var(--card2); border-radius: 10px; padding: 4px; margin-bottom: 20px; }
.tab {
  flex: 1; padding: 10px 0; text-align: center; border: none; background: transparent;
  color: var(--text-dim); font-size: 15px; cursor: pointer; border-radius: 8px; transition: all .2s;
}
.tab.active { background: var(--accent); color: #15161a; font-weight: 600; }

.form-panel { display: none; }
.form-panel.active { display: block; }
.form-group { margin-bottom: 16px; }
.form-group label { display: block; font-size: 13px; color: var(--text-dim); margin-bottom: 6px; }
.form-group input {
  width: 100%; padding: 12px 14px; background: var(--card2); border: 1px solid var(--border);
  border-radius: 9px; color: var(--text); font-size: 14px; outline: none; transition: border .2s;
}
.form-group input:focus { border-color: var(--accent); }

.btn-primary {
  width: 100%; padding: 13px; background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  border: none; border-radius: 10px; color: #15161a; font-size: 16px; font-weight: 600;
  cursor: pointer; transition: filter .2s; margin-top: 4px;
}
.btn-primary:hover { filter: brightness(1.08); }
.btn-primary:disabled { opacity: .6; cursor: not-allowed; }

.error-message { color: var(--danger); font-size: 13px; min-height: 18px; margin: 4px 0 8px; }
.hint-text { text-align: center; color: var(--text-dim); font-size: 13px; margin-top: 14px; cursor: pointer; }
.hint-text:hover { color: var(--accent); }

.foot-info { text-align: center; color: #5a5f6e; font-size: 12px; margin-top: 22px; border-top: 1px solid var(--border); padding-top: 14px; }

.toast {
  position: fixed; bottom: 40px; left: 50%; transform: translateX(-50%) translateY(80px);
  background: #2a2e3a; color: var(--text); padding: 12px 26px; border-radius: 10px;
  font-size: 14px; opacity: 0; transition: all .3s; z-index: 99; border: 1px solid var(--border);
}
.toast.show { transform: translateX(-50%) translateY(0); opacity: 1; }
.toast.error { border-color: var(--danger); }
.toast.success { border-color: #2ea55a; }
