/* 登录页：深色舞台 + AI 守护盾主视觉 + 浮动处理卡片 + 白色登录卡。
   颜色与字体来自 design-tokens.css，不依赖业务页面的样式层。 */
*{box-sizing:border-box}
html,body{margin:0;min-height:100%;font-family:var(--ds-font);-webkit-font-smoothing:antialiased}
body{color:#fff;background:#050f24;font-size:14px;line-height:1.6}
a{color:inherit;text-decoration:none}
button,input{font:inherit}
a:focus-visible,button:focus-visible{outline:3px solid #60a5fa;outline-offset:4px}

:root{--cyan:#5fd4e6;--sky:#7dd3fc;--blue:#3b82f6;--stage:#050f24;--glass:rgba(13,32,70,.62);--glass-line:rgba(125,211,252,.22)}

/* ---------- 舞台 ---------- */
.login-stage{
  position:relative;isolation:isolate;overflow:hidden;
  display:grid;grid-template-columns:minmax(0,1fr) 440px;gap:clamp(24px,4vw,72px);
  min-height:100vh;min-height:100svh;
  padding:clamp(24px,3.2vw,48px) clamp(24px,4vw,72px);
  background:
    radial-gradient(ellipse 60% 55% at 32% 58%,rgba(29,78,216,.32),transparent 70%),
    radial-gradient(ellipse 40% 40% at 88% 10%,rgba(95,212,230,.10),transparent 70%),
    var(--stage);
}
/* 细网格，暗示数据与算法 */
.login-stage::before{
  content:"";position:absolute;inset:0;z-index:-1;pointer-events:none;
  background-image:linear-gradient(rgba(125,211,252,.06) 1px,transparent 1px),linear-gradient(90deg,rgba(125,211,252,.06) 1px,transparent 1px);
  background-size:44px 44px;
  -webkit-mask-image:radial-gradient(ellipse 70% 70% at 35% 55%,#000 20%,transparent 75%);
  mask-image:radial-gradient(ellipse 70% 70% at 35% 55%,#000 20%,transparent 75%);
}

/* ---------- 左：品牌与主视觉 ---------- */
.login-hero{display:flex;flex-direction:column;gap:clamp(16px,3vh,32px);min-width:0;min-height:0}
.login-brand{display:inline-flex;align-items:center;gap:12px;align-self:flex-start}
.login-brand img{width:40px;height:40px;object-fit:contain;flex:none}
.login-brand>span{font-size:20px;font-weight:600;letter-spacing:2px;line-height:1.2}
.login-brand small{display:block;margin-top:6px;color:#a9bfdc;font-size:11px;font-weight:400;letter-spacing:1.5px}

.hero-copy{max-width:640px;margin:0 auto;text-align:center}
.hero-eyebrow{display:inline-flex;align-items:center;gap:10px;margin:0 0 16px;padding:5px 14px 5px 10px;border:1px solid var(--glass-line);border-radius:999px;background:rgba(95,212,230,.08);color:#a5f3fc;font-size:12px;letter-spacing:2px}
.hero-eyebrow i{width:8px;height:8px;border-radius:50%;background:var(--cyan);box-shadow:0 0 0 0 rgba(95,212,230,.6);animation:ping 2.4s infinite}
.hero-copy h1{margin:0;font-size:clamp(30px,3.1vw,48px);line-height:1.3;font-weight:600;letter-spacing:1px}
.hero-copy h1 em{font-style:normal;background:linear-gradient(90deg,#7dd3fc,#5fd4e6 40%,#93c5fd);-webkit-background-clip:text;background-clip:text;color:transparent}
.hero-description{margin:14px auto 0;color:#b7c8e0;font-size:15px;max-width:540px}

.hero-visual{position:relative;flex:1 1 0;min-height:240px}
.visual-inner{position:absolute;inset:0;margin:auto;width:min(100%,680px)}
.shield{position:absolute;left:50%;top:50%;height:100%;max-height:440px;width:auto;transform:translate(-50%,-50%);overflow:visible}
.orbit{fill:none;stroke:rgba(125,211,252,.16);stroke-width:1;stroke-dasharray:2 10;transform-origin:200px 236px;animation:spin 60s linear infinite}
.orbit-2{stroke:rgba(59,130,246,.22);stroke-dasharray:60 14 4 14;animation-duration:40s;animation-direction:reverse}
.shield-body{fill:url(#shield-fill)}
.shield-edge{fill:none;stroke:url(#shield-stroke);stroke-width:2.5;filter:drop-shadow(0 0 10px rgba(59,130,246,.65))}
.mesh path{fill:none;stroke:rgba(125,211,252,.32);stroke-width:1}
.nodes circle{fill:#7dd3fc;filter:drop-shadow(0 0 6px #5fd4e6);animation:blink 3.2s ease-in-out infinite}
.nodes circle:nth-child(3n){animation-delay:-1.1s}
.nodes circle:nth-child(3n+1){animation-delay:-2.2s}
.scan{opacity:0;transition:opacity .4s}
.shield.scanning .scan{opacity:1;animation:scan 1.6s cubic-bezier(.45,0,.55,1) infinite}
.core-halo{fill:rgba(95,212,230,.10);stroke:rgba(95,212,230,.35);stroke-width:1;transform-origin:200px 240px;opacity:.6}
.shield.verify .core-halo{animation:halo .9s ease-out}
.core{fill:#0b2a66;stroke:#5fd4e6;stroke-width:2;filter:drop-shadow(0 0 14px rgba(95,212,230,.55))}
.check{fill:none;stroke:#a5f3fc;stroke-width:6;stroke-linecap:round;stroke-linejoin:round;stroke-dasharray:70;stroke-dashoffset:0;transition:opacity .3s}
.shield.scanning .check{opacity:.25}
.shield.verify .check{animation:check .7s ease-out}

/* AI 处理卡片：由 login-visual.js 依次切换 idle → run → done，讲一遍“AI 先处理、人工再复核”的流程 */
.ai-card{
  position:absolute;width:236px;padding:12px 14px;
  border:1px solid var(--glass-line);border-radius:14px;background:var(--glass);
  -webkit-backdrop-filter:blur(10px);backdrop-filter:blur(10px);
  box-shadow:0 18px 40px -16px rgba(0,0,0,.6);
  transition:opacity .45s ease,border-color .45s ease,box-shadow .45s ease,transform .45s var(--ds-ease);
}
.card-uw{left:0;top:4%}
.card-claim{right:0;top:34%}
.card-health{left:5%;bottom:2%}
.ai-card[data-state=idle]{opacity:.5;transform:scale(.97)}
.ai-card[data-state=run]{opacity:1;transform:scale(1.03);border-color:rgba(95,212,230,.65);
  box-shadow:0 0 0 1px rgba(95,212,230,.25),0 0 36px -6px rgba(95,212,230,.5),0 18px 40px -16px rgba(0,0,0,.6)}
.ai-card[data-state=done]{opacity:.92}

.ai-card-head{display:flex;align-items:center;gap:8px}
.ai-card-head b{flex:1;font-size:13px;font-weight:600;letter-spacing:.5px;white-space:nowrap}
.ai-icon{display:grid;place-items:center;flex:none;width:24px;height:24px;border-radius:7px;background:rgba(59,130,246,.28);color:#bfdbfe;font-size:12px;font-weight:600}
.ai-state{display:inline-flex;align-items:center;gap:5px;padding:1px 8px;border-radius:999px;font-size:11px;line-height:18px;white-space:nowrap;color:#8aa3c4;background:rgba(138,163,196,.12);transition:color .3s,background .3s}
.ai-state i{width:6px;height:6px;border-radius:50%;background:currentColor}
[data-state=run] .ai-state{color:#a5f3fc;background:rgba(95,212,230,.16)}
[data-state=run] .ai-state i{animation:blink .9s ease-in-out infinite}
[data-state=done] .ai-state{color:#86efac;background:rgba(52,211,153,.14)}

/* 处理步骤：只在处理中展开 */
.ai-steps-wrap,.ai-result-wrap{display:grid;grid-template-rows:0fr;transition:grid-template-rows .45s var(--ds-ease)}
.ai-steps,.ai-result{overflow:hidden;min-height:0}
[data-state=run] .ai-steps-wrap{grid-template-rows:1fr}
[data-state=done] .ai-result-wrap{grid-template-rows:1fr}
.ai-steps{list-style:none;margin:0;padding:0}
.ai-steps li{display:flex;align-items:center;gap:8px;padding-top:7px;color:#6f88ab;font-size:12px;line-height:18px;transition:color .3s}
.ai-steps li:first-child{padding-top:10px}
.ai-steps li::before{content:"";flex:none;box-sizing:border-box;width:14px;height:14px;border-radius:50%;border:1.5px solid rgba(138,163,196,.45)}
.ai-steps li.on{color:#e2ecf8}
.ai-steps li.on::before{border-color:rgba(95,212,230,.25);border-top-color:var(--cyan);animation:spin .7s linear infinite}
.ai-steps li.ok{color:#b7c8e0}
.ai-steps li.ok::before{border:0;background:var(--cyan) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 14 14'%3E%3Cpath d='m4 7.2 2 2 4-4.4' fill='none' stroke='%23050f24' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/14px no-repeat}

.ai-result{display:flex;align-items:center;justify-content:space-between;gap:8px}
.ai-result>*{margin-top:10px}
.ai-result small{color:#8aa3c4;font-size:11px;white-space:nowrap}
[data-state=done] .chip{animation:pop .5s var(--ds-ease)}
.chip{padding:1px 8px;border-radius:999px;background:rgba(59,130,246,.22);color:#bfdbfe;font-size:11px;line-height:18px;white-space:nowrap}
.chip.ok{background:rgba(52,211,153,.16);color:#86efac}

/* 可信承诺 */
.hero-trust{list-style:none;margin:0;padding:16px 0 0;display:flex;flex-wrap:wrap;justify-content:center;gap:12px 32px;border-top:1px solid rgba(169,191,220,.16)}
.hero-trust li{display:flex;align-items:center;gap:8px;color:#a9bfdc;font-size:13px}
.hero-trust svg{width:18px;height:18px;fill:none;stroke:var(--cyan);stroke-width:1.6;stroke-linecap:round;stroke-linejoin:round}

/* ---------- 右：登录卡 ---------- */
.login-card-wrap{display:flex;flex-direction:column;align-items:stretch;justify-content:center;min-width:0}
.login-card{
  position:relative;padding:36px 36px 28px;border-radius:20px;
  color:var(--ds-ink);background:#fff;
  box-shadow:0 30px 80px -20px rgba(0,0,0,.65),0 0 0 1px rgba(125,211,252,.18);
}
.login-card::before{content:"";position:absolute;inset:0 24px auto;height:3px;border-radius:0 0 3px 3px;background:linear-gradient(90deg,#1d4ed8,#5fd4e6)}
.secure-tag{display:inline-flex;align-items:center;gap:6px;margin:0 0 14px;padding:2px 10px 2px 8px;border-radius:999px;background:#ecfdf5;color:#047857;font-size:12px}
.secure-tag svg{width:14px;height:14px;fill:none;stroke:currentColor;stroke-width:2;stroke-linejoin:round}
.login-heading h2{margin:0;font-size:26px;line-height:1.35;font-weight:600}
.login-heading p{margin:6px 0 28px;color:var(--ds-muted)}

.field{margin-bottom:20px}
.field label{display:block;margin:0 0 8px;color:var(--ds-text);font-size:14px;font-weight:500}
.input-shell{position:relative}
.input-shell>svg{position:absolute;left:16px;top:15px;width:18px;height:18px;fill:none;stroke:#75849a;stroke-width:1.5;stroke-linecap:round;stroke-linejoin:round;pointer-events:none}
.input-shell input{display:block;width:100%;height:48px;padding:0 16px 0 46px;color:var(--ds-ink);background:#f8fafc;border:1px solid #dbe2eb;border-radius:10px;outline:none;transition:border-color 140ms,box-shadow 140ms,background 140ms}
.input-shell input::placeholder{color:var(--ds-muted);opacity:1}
.input-shell input:hover{border-color:#b1bfd0}
.input-shell input:focus{border-color:var(--ds-primary);box-shadow:0 0 0 3px var(--ds-primary-ring);background:#fff}
.input-shell:focus-within>svg{stroke:var(--ds-primary)}

.form-error{min-height:20px;margin:-4px 0 12px;color:var(--ds-danger);font-size:13px;line-height:20px;overflow-wrap:anywhere}
.form-error:empty{min-height:0;margin:0}
.ui-field-error{display:block;margin-top:6px;color:var(--ds-danger);font-size:12px}

.login-submit{width:100%;height:48px;margin-top:8px;border:0;border-radius:10px;background:var(--ds-primary);color:#fff;font-size:15px;font-weight:500;letter-spacing:4px;cursor:pointer;box-shadow:0 10px 24px -10px rgba(29,78,216,.7);transition:filter 140ms,box-shadow 140ms}
.login-submit:hover{background:var(--ds-primary-hover);box-shadow:0 14px 28px -10px rgba(29,78,216,.8)}
.login-submit:disabled{cursor:wait;opacity:.65;letter-spacing:1px}
.login-help{margin:18px 0 0;color:var(--ds-muted);font-size:12px;text-align:center}
.login-legal{margin:20px 0 0;color:#6b84a8;font-size:12px;letter-spacing:1px;text-align:center}

/* ---------- 动效 ---------- */
@keyframes spin{to{transform:rotate(360deg)}}
@keyframes blink{0%,100%{opacity:.45}50%{opacity:1}}
@keyframes scan{0%{transform:translateY(0)}100%{transform:translateY(560px)}}
@keyframes halo{0%{transform:scale(1);opacity:1}100%{transform:scale(1.5);opacity:0}}
@keyframes pop{0%{transform:scale(.8);opacity:0}100%{transform:scale(1);opacity:1}}
@keyframes check{0%{stroke-dashoffset:70}100%{stroke-dashoffset:0}}
@keyframes ping{0%{box-shadow:0 0 0 0 rgba(95,212,230,.6)}80%,100%{box-shadow:0 0 0 8px rgba(95,212,230,0)}}

/* ---------- 适配 ---------- */
@media (max-width:1240px){
  .login-stage{grid-template-columns:minmax(0,1fr) 400px}
  .ai-card{width:216px}
  .card-health{display:none}
}
@media (max-height:760px) and (min-width:961px){
  .hero-copy h1{font-size:clamp(26px,2.6vw,38px)}
  .hero-description{font-size:14px;margin-top:10px}
  .hero-eyebrow{margin-bottom:10px}
  .login-card{padding:28px 32px 22px}
  .login-heading p{margin-bottom:20px}
  .field{margin-bottom:14px}
}
@media (max-width:960px){
  .login-stage{grid-template-columns:1fr;gap:24px;padding:24px 20px 28px;align-content:start}
  .login-hero{gap:18px}
  .hero-visual{display:none}
  .hero-copy{margin:0;text-align:left}
  .hero-description{margin-left:0}
  .hero-trust{justify-content:flex-start}
  .hero-copy h1{font-size:clamp(24px,6.4vw,34px)}
  .hero-description{font-size:13px;margin-top:10px}
  .hero-trust{order:3;gap:8px 16px;padding-top:12px}
  .hero-trust li{font-size:12px}
  .login-card{padding:28px 22px 22px}
  .login-heading h2{font-size:22px}
  .login-heading p{margin-bottom:22px}
  .input-shell input{font-size:16px}
  .login-stage::before{-webkit-mask-image:linear-gradient(#000,transparent 50%);mask-image:linear-gradient(#000,transparent 50%)}
}
@media (max-width:960px) and (min-width:600px){.login-card-wrap{max-width:440px;width:100%;justify-self:center}}
@media (prefers-reduced-motion:reduce){
  *,*::before,*::after{animation:none!important;transition:none!important}
  .check{stroke-dashoffset:0}
  .scan{display:none}
}
