/* =============================================================
   登录页样式（黑金主题）
   ============================================================= */

.login-page {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--grad-bg-radial);
  overflow: hidden;
}

/* —— 背景装饰：金色光晕 + 网格 —— */
.login-page::before {
  content: '';
  position: absolute;
  width: 800px; height: 800px;
  background: radial-gradient(circle, rgba(212,175,55,0.15) 0%, transparent 70%);
  top: -200px; right: -200px;
  pointer-events: none;
  animation: float 8s ease-in-out infinite;
}
.login-page::after {
  content: '';
  position: absolute;
  width: 600px; height: 600px;
  background: radial-gradient(circle, rgba(240,210,124,0.10) 0%, transparent 70%);
  bottom: -150px; left: -150px;
  pointer-events: none;
  animation: float 10s ease-in-out infinite reverse;
}
@keyframes float {
  0%, 100% { transform: translate(0, 0); }
  50%      { transform: translate(30px, -20px); }
}

/* —— 登录卡片 —— */
.login-card {
  position: relative;
  width: 420px;
  background: linear-gradient(180deg, #ffffff 0%, #f7f9fc 100%);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
  padding: var(--space-7) var(--space-6) var(--space-6);
  box-shadow: var(--shadow-lg), var(--shadow-gold);
  backdrop-filter: blur(20px);
  z-index: 2;
}

/* —— 卡片顶部金色描边 —— */
.login-card::before {
  content: '';
  position: absolute;
  top: 0; left: 50%; transform: translateX(-50%);
  width: 60%; height: 1px;
  background: linear-gradient(90deg, transparent, var(--gold-4), transparent);
}

/* —— Logo 区 —— */
.login-logo {
  text-align: center;
  margin-bottom: var(--space-6);
}
.login-logo .brand {
  display: inline-block;
  font-family: var(--font-display);
  font-size: var(--fs-4xl);
  font-weight: 700;
  letter-spacing: 4px;
  background: var(--grad-gold);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  text-shadow: 0 2px 16px rgba(212,175,55,0.4);
}
.login-logo .sub {
  margin-top: var(--space-2);
  color: var(--text-tertiary);
  font-size: var(--fs-sm);
  letter-spacing: 6px;
  text-transform: uppercase;
}

/* —— 标题 —— */
.login-title {
  font-size: var(--fs-xl);
  font-weight: 500;
  color: var(--text-primary);
  text-align: center;
  margin-bottom: var(--space-6);
}
.login-title .divider {
  display: block;
  width: 40px; height: 2px;
  background: var(--gold-4);
  margin: var(--space-3) auto 0;
}

/* —— 表单 —— */
.login-form { display: flex; flex-direction: column; gap: var(--space-4); }

.field {
  position: relative;
  display: flex;
  align-items: center;
  background: var(--bg-2);
  border: 1px solid var(--border-1);
  border-radius: var(--radius-md);
  transition: all var(--dur-base) var(--ease);
}
.field:focus-within {
  border-color: var(--gold-3);
  box-shadow: 0 0 0 3px rgba(212,175,55,0.12);
}

.field .icon {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gold-3);
  font-size: 16px;
  flex-shrink: 0;
}
.field input {
  flex: 1;
  padding: 12px 14px 12px 0;
  background: transparent;
  color: var(--text-primary);
  font-size: var(--fs-md);
}
.field input::placeholder {
  color: var(--text-tertiary);
}

/* —— 错误提示 —— */
.error-msg {
  min-height: 20px;
  color: var(--error);
  font-size: var(--fs-sm);
  text-align: center;
  margin-top: -var(--space-2);
  transition: opacity var(--dur-fast);
}

/* —— 主按钮（金色 CTA）—— */
.btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 48px;
  border: none;
  border-radius: var(--radius-md);
  background: var(--grad-gold);
  color: var(--text-on-gold);
  font-size: var(--fs-md);
  font-weight: 600;
  letter-spacing: 4px;
  cursor: pointer;
  transition: all var(--dur-base) var(--ease);
  box-shadow: 0 4px 12px rgba(212,175,55,0.3);
  position: relative;
  overflow: hidden;
}
.btn-primary::before {
  content: '';
  position: absolute;
  inset: 0;
  background: var(--grad-gold-hover);
  opacity: 0;
  transition: opacity var(--dur-base);
}
.btn-primary > * { position: relative; z-index: 1; }
.btn-primary:hover::before { opacity: 1; }
.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(212,175,55,0.5);
}
.btn-primary:active { transform: translateY(0); }
.btn-primary:disabled {
  background: var(--bg-3);
  color: var(--text-tertiary);
  cursor: not-allowed;
  box-shadow: none;
}
.btn-primary:disabled::before { opacity: 0; }

.btn-primary .spinner {
  display: none;
  width: 18px; height: 18px;
  border: 2px solid var(--text-on-gold);
  border-right-color: transparent;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin-right: var(--space-2);
}
.btn-primary.loading .spinner { display: inline-block; }
.btn-primary.loading .label { opacity: 0.5; }

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* —— 底部 —— */
.login-footer {
  text-align: center;
  margin-top: var(--space-5);
  color: var(--text-tertiary);
  font-size: var(--fs-xs);
  letter-spacing: 2px;
}

/* —— 提示 / 默认账号说明 —— */
.dev-hint {
  margin-top: var(--space-4);
  padding: var(--space-3);
  background: rgba(212,175,55,0.05);
  border: 1px dashed var(--border-2);
  border-radius: var(--radius-sm);
  font-size: var(--fs-xs);
  color: var(--text-secondary);
  text-align: center;
  line-height: 1.7;
}
.dev-hint .label { color: var(--gold-3); font-weight: 500; }
.dev-hint code {
  font-family: var(--font-mono);
  color: var(--gold-5);
  background: rgba(17,24,39,0.04);
  padding: 1px 6px;
  border-radius: var(--radius-sm);
  margin: 0 4px;
}
