/* ============================================================
   创想工作台 · 登录 / 注册页（大厂级设计）
   科技蓝 · 浅色 · 左右分栏 · 玻璃拟态 · 光效动效
   ============================================================ */

/* ---------- 页面容器 ---------- */
.auth-body {
  position: relative;
  min-height: 100vh;
  overflow: hidden;
  display: flex;
}

.auth-bg {
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(1400px 700px at 80% -10%, rgba(0, 120, 255, 0.18), transparent 60%),
    radial-gradient(1000px 600px at -10% 110%, rgba(0, 170, 230, 0.16), transparent 55%),
    radial-gradient(800px 500px at 110% 90%, rgba(99, 102, 241, 0.16), transparent 55%),
    var(--bg-deep);
}
/* 粒子色块层（深蓝系，漂浮动画，正片叠底保证浅底上清晰） */
.auth-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  mix-blend-mode: multiply;
  background-image:
    radial-gradient(3px 3px at 12% 22%, rgba(37, 99, 235, 0.5), transparent 100%),
    radial-gradient(4px 4px at 25% 68%, rgba(8, 145, 178, 0.45), transparent 100%),
    radial-gradient(2px 2px at 38% 35%, rgba(79, 70, 229, 0.55), transparent 100%),
    radial-gradient(3px 3px at 52% 15%, rgba(2, 132, 199, 0.5), transparent 100%),
    radial-gradient(5px 5px at 62% 55%, rgba(37, 99, 235, 0.4), transparent 100%),
    radial-gradient(2px 2px at 75% 30%, rgba(79, 70, 229, 0.5), transparent 100%),
    radial-gradient(3px 3px at 84% 72%, rgba(37, 99, 235, 0.45), transparent 100%),
    radial-gradient(4px 4px at 92% 18%, rgba(8, 145, 178, 0.5), transparent 100%),
    radial-gradient(5px 5px at 8% 82%, rgba(79, 70, 229, 0.4), transparent 100%),
    radial-gradient(2px 2px at 18% 48%, rgba(2, 132, 199, 0.55), transparent 100%),
    radial-gradient(3px 3px at 30% 88%, rgba(37, 99, 235, 0.5), transparent 100%),
    radial-gradient(2px 2px at 45% 75%, rgba(79, 70, 229, 0.5), transparent 100%),
    radial-gradient(4px 4px at 55% 42%, rgba(37, 99, 235, 0.4), transparent 100%),
    radial-gradient(3px 3px at 68% 82%, rgba(8, 145, 178, 0.5), transparent 100%),
    radial-gradient(5px 5px at 78% 48%, rgba(79, 70, 229, 0.4), transparent 100%),
    radial-gradient(2px 2px at 88% 90%, rgba(2, 132, 199, 0.55), transparent 100%),
    radial-gradient(3px 3px at 4% 55%, rgba(37, 99, 235, 0.45), transparent 100%),
    radial-gradient(4px 4px at 96% 40%, rgba(79, 70, 229, 0.5), transparent 100%),
    radial-gradient(2px 2px at 42% 5%, rgba(8, 145, 178, 0.55), transparent 100%),
    radial-gradient(3px 3px at 70% 95%, rgba(37, 99, 235, 0.45), transparent 100%);
  animation: particleDrift 11s ease-in-out infinite alternate;
}
@keyframes particleDrift {
  0% { transform: translateY(0); opacity: 0.8; }
  100% { transform: translateY(-22px); opacity: 1; }
}
.auth-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(90, 140, 240, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(90, 140, 240, 0.06) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 78%);
  mask-image: radial-gradient(ellipse at center, #000 30%, transparent 78%);
}
.auth-veil {
  position: fixed;
  inset: 0;
  z-index: -1;
  background: linear-gradient(180deg, rgba(233, 238, 247, 0.4), rgba(233, 238, 247, 0.62));
}

/* 漂浮光斑 */
.auth-blob {
  position: fixed;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.26;
  z-index: -1;
  animation: blobFloat 14s ease-in-out infinite alternate;
}
.auth-blob.b1 { width: 420px; height: 420px; left: 6%; top: 8%; background: #2563eb; }
.auth-blob.b2 { width: 360px; height: 360px; right: 8%; bottom: 4%; background: #06b6d4; animation-delay: -5s; }
.auth-blob.b3 { width: 280px; height: 280px; right: 30%; top: 2%; background: #6366f1; animation-delay: -9s; }
@keyframes blobFloat {
  0% { transform: translate(0, 0) scale(1); }
  100% { transform: translate(-40px, 30px) scale(1.15); }
}

/* ---------- 左右分栏 ---------- */
.auth-grid {
  width: 100%;
  min-height: 100vh;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(440px, 0.85fr);
}

/* 左侧品牌区（与页面背景统一，无独立色块） */
.auth-panel {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  padding: 52px 60px;
}

.auth-panel-top { position: relative; z-index: 1; display: flex; align-items: center; gap: 14px; }
.auth-panel-mid { position: relative; z-index: 1; }
.auth-panel-foot { position: relative; z-index: 1; }

.brand-mark {
  width: 44px; height: 44px;
  border-radius: 13px;
  background: var(--grad-gold);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 20px;
  box-shadow: 0 8px 26px rgba(59, 130, 246, 0.45);
  flex: none;
}
.brand-name { font-size: 19px; font-weight: 700; letter-spacing: 3px; color: #101b33; }
.brand-sub { font-size: 10px; color: #5b6b8f; letter-spacing: 4px; margin-top: 4px; }

.panel-title {
  font-size: 40px;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: 2px;
  background: linear-gradient(120deg, #0b1526 20%, #1d4ed8 60%, #0e7490);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.panel-desc { margin-top: 18px; font-size: 15px; color: #33446a; line-height: 2; max-width: 460px; }

/* 特性清单（白色半透明卡片） */
.panel-feats { margin-top: 40px; display: flex; flex-direction: column; gap: 18px; max-width: 480px; }
.panel-feat {
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 16px 18px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(37, 74, 138, 0.16);
  box-shadow: 0 4px 16px rgba(31, 60, 120, 0.06);
  backdrop-filter: blur(8px);
  transition: all 0.25s;
}
.panel-feat:hover { background: rgba(255, 255, 255, 0.85); border-color: rgba(37, 99, 235, 0.4); transform: translateX(4px); }
.panel-feat .feat-icon {
  width: 40px; height: 40px;
  border-radius: 11px;
  background: rgba(37, 99, 235, 0.12);
  color: #2563eb;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  flex: none;
}
.panel-feat b { font-size: 14px; display: block; margin-bottom: 4px; color: #101b33; }
.panel-feat span { font-size: 12px; color: #4b5c80; line-height: 1.7; }

.auth-panel-foot {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  color: #64748b;
  letter-spacing: 0.5px;
}

/* ---------- 右侧表单区 ---------- */
.auth-side {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 40px;
  position: relative;
}

/* 白色登录卡片 */
.auth-card {
  width: 100%;
  max-width: 430px;
  background: #ffffff;
  border-radius: 18px;
  padding: 40px 42px;
  box-shadow: 0 20px 60px rgba(31, 60, 120, 0.2), 0 0 0 1px rgba(100, 116, 139, 0.28);
  position: relative;
  animation: authFloat 0.7s ease;
}
.auth-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 42px;
  right: 42px;
  height: 3px;
  background: linear-gradient(90deg, transparent, #38bdf8, #6366f1, transparent);
  border-radius: 999px;
}
@keyframes authFloat {
  from { opacity: 0; transform: translateY(26px); }
  to { opacity: 1; transform: translateY(0); }
}

.auth-card-head { margin-bottom: 26px; }
.auth-card-head h2 { font-size: 23px; font-weight: 700; letter-spacing: 1px; color: #0f172a; }
.auth-card-head .sub { font-size: 13px; color: #6b7280; margin-top: 8px; }

/* Tab 切换 */
.auth-tabs {
  display: flex;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 11px;
  padding: 4px;
  margin-bottom: 24px;
}
.auth-tabs button {
  flex: 1;
  height: 36px;
  border-radius: 8px;
  font-size: 13px;
  color: #64748b;
  transition: all 0.2s;
}
.auth-tabs button.active {
  background: var(--grad-gold);
  color: #fff;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* 输入字段 */
.field { margin-bottom: 16px; }
.field-label {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12px;
  color: #374151;
  margin-bottom: 7px;
}
.field-label .link { color: #2563eb; cursor: pointer; font-size: 12px; }
.field-box {
  position: relative;
  display: flex;
  align-items: center;
}
.field-box > i.field-icon {
  position: absolute;
  left: 14px;
  color: #94a3b8;
  font-size: 14px;
  z-index: 2;
  transition: color 0.2s;
}
.field-box:focus-within > i.field-icon { color: #2563eb; }
.field-box .input {
  width: 100%;
  height: 48px;
  padding: 0 44px;
  border-radius: 12px;
  background: #f8fafc;
  border: 1px solid #dbe2ec;
  color: #0f172a;
  outline: none;
  transition: all 0.2s;
}
.field-box .input::placeholder { color: #9aa7bd; }
.field-box .input:focus { border-color: #3b82f6; background: #fff; box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.12); }
.field-box .input.invalid { border-color: #dc2626; }
.field-box .eye-btn {
  position: absolute;
  right: 8px;
  width: 34px;
  height: 34px;
  border-radius: 9px;
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
}
.field-box .eye-btn:hover { color: #334155; }

/* 验证码（注册页） */
.captcha-row { display: flex; gap: 10px; }
.captcha-row .input { flex: 1; padding-right: 14px; padding-left: 14px; letter-spacing: 6px; font-weight: 700; }
.captcha-box {
  width: 118px;
  height: 48px;
  flex: none;
  border-radius: 12px;
  border: 1px dashed #93c5fd;
  background: #eff6ff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  user-select: none;
  overflow: hidden;
  position: relative;
  transition: all 0.2s;
}
.captcha-box:hover { border-color: #3b82f6; }
.captcha-box .cap-char {
  font-size: 24px;
  font-weight: 800;
  display: inline-block;
  margin: 0 3px;
  font-family: "Consolas", "Courier New", monospace;
  text-shadow: 0 0 8px currentColor;
}

/* 选项行 */
.auth-options {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin: 4px 0 18px;
  font-size: 12px;
  color: #374151;
}
.auth-options label { display: flex; align-items: center; gap: 7px; cursor: pointer; }
.auth-options input[type="checkbox"] {
  appearance: none;
  width: 16px; height: 16px;
  border-radius: 5px;
  border: 1px solid #cbd5e1;
  background: #fff;
  position: relative;
  cursor: pointer;
  transition: all 0.2s;
}
.auth-options input[type="checkbox"]:checked {
  background: var(--grad-gold);
  border-color: transparent;
}
.auth-options input[type="checkbox"]:checked::after {
  content: "\f00c";
  font-family: "Font Awesome 6 Free";
  font-weight: 900;
  font-size: 10px;
  color: #fff;
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 主按钮 */
.auth-submit {
  width: 100%;
  height: 48px;
  border-radius: 12px;
  font-size: 15px;
  letter-spacing: 5px;
  background: var(--grad-gold);
  color: #fff;
  font-weight: 700;
  box-shadow: 0 10px 30px rgba(59, 130, 246, 0.35);
  position: relative;
  overflow: hidden;
  transition: all 0.25s;
}
.auth-submit::after {
  content: "";
  position: absolute;
  top: 0; left: -60%;
  width: 40%; height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-20deg);
  transition: left 0.5s;
}
.auth-submit:hover::after { left: 120%; }
.auth-submit:hover { filter: brightness(1.1); transform: translateY(-1px); box-shadow: 0 14px 36px rgba(59, 130, 246, 0.45); }
.auth-submit:disabled { opacity: 0.6; cursor: not-allowed; transform: none; }

/* 分隔线 */
.auth-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 22px 0 16px;
  font-size: 11px;
  color: #94a3b8;
}
.auth-divider::before, .auth-divider::after { content: ""; flex: 1; height: 1px; background: linear-gradient(90deg, transparent, #e2e8f0, transparent); }

/* 三方登录 */
.oauth-row { display: flex; justify-content: center; gap: 14px; }
.oauth-btn {
  width: 42px; height: 42px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
  background: #fff;
  color: #64748b;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
}
.oauth-btn:hover { border-color: #3b82f6; color: #2563eb; transform: translateY(-2px); box-shadow: 0 8px 20px rgba(59, 130, 246, 0.18); }

/* 底部切换 */
.auth-switch { text-align: center; margin-top: 22px; font-size: 13px; color: #6b7280; }
.auth-switch a { color: #2563eb; font-weight: 600; }

/* 错误提示 */
.auth-error {
  display: none;
  background: rgba(251, 113, 133, 0.08);
  border: 1px solid rgba(251, 113, 133, 0.28);
  color: #dc2626;
  border-radius: 10px;
  padding: 10px 14px;
  font-size: 13px;
  margin-bottom: 16px;
  animation: shake 0.4s;
}
.auth-error.show { display: flex; align-items: center; gap: 8px; }
@keyframes shake {
  0%, 100% { transform: translateX(0); }
  25% { transform: translateX(-6px); }
  75% { transform: translateX(6px); }
}

/* 密码强度 */
.auth-strength { height: 4px; background: rgba(15, 23, 42, 0.08); border-radius: 999px; margin-top: 8px; overflow: hidden; }
.auth-strength > div { height: 100%; width: 0; border-radius: 999px; transition: all 0.3s; }

/* ---------- 扫码登录 ---------- */
.scan-panel { text-align: center; padding: 8px 0; }
.qr-wrap {
  width: 200px; height: 200px;
  margin: 8px auto 16px;
  border-radius: 18px;
  padding: 14px;
  background: #fff;
  box-shadow: 0 16px 44px rgba(15, 23, 42, 0.18), 0 0 0 1px rgba(148, 163, 184, 0.2);
  position: relative;
  animation: authFloat 0.5s ease;
}
.qr-grid {
  width: 100%; height: 100%;
  display: grid;
  grid-template-columns: repeat(9, 1fr);
  gap: 2px;
  background: #f1f5ff;
  padding: 6px;
  border-radius: 10px;
}
.qr-grid i { display: block; border-radius: 1px; }
.qr-grid i.on { background: #0b1222; }
.qr-grid i.off { background: transparent; }
.scan-tip { font-size: 12px; color: #6b7280; line-height: 1.8; }
.scan-actions { margin-top: 14px; display: flex; justify-content: center; gap: 10px; }

/* ---------- 弹窗（忘记密码） ---------- */
.auth-mask {
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.55);
  backdrop-filter: blur(6px);
  z-index: 999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.auth-mask.show { display: flex; }
.auth-modal {
  width: 100%;
  max-width: 400px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 18px;
  padding: 28px 30px;
  box-shadow: 0 30px 90px rgba(15, 23, 42, 0.35);
  animation: authFloat 0.35s ease;
  position: relative;
}
.auth-modal h3 { font-size: 17px; margin-bottom: 6px; color: #0f172a; }
.auth-modal h3 i { color: #2563eb !important; }
.auth-modal .m-sub { font-size: 12px; color: #6b7280; margin-bottom: 20px; line-height: 1.7; }
.auth-modal .m-close {
  position: absolute;
  top: 14px; right: 14px;
  width: 30px; height: 30px;
  border-radius: 9px;
  color: #94a3b8;
  display: flex;
  align-items: center;
  justify-content: center;
}
.auth-modal .m-close:hover { background: #f1f5f9; color: #0f172a; }

/* 响应式 */
@media (max-width: 980px) {
  .auth-grid { grid-template-columns: 1fr; }
  .auth-panel { display: none; }
  .auth-side { padding: 24px; }
  .auth-card { padding: 30px 26px; }
}
