/* ============================================================
   IJerrt 统一登录 / 未登录落地页样式 (login.css)
   适用：drive / notes / roll / vmusic / novel
   依赖：design.css 提供的 token（--accent-rgb / --glass-bg / --tint-* 等）
   设计：品牌光晕 + 玻璃拟态卡片 + 特性网格，PC/移动双端自适应
   ============================================================ */

/* ---------- 整页容器 ---------- */
.login-page{
  position:fixed;inset:0;z-index:180;
  display:flex;align-items:center;justify-content:center;
  padding:clamp(16px,4vw,40px);
  padding-top:max(clamp(16px,4vw,40px),env(safe-area-inset-top));
  padding-bottom:max(clamp(16px,4vw,40px),env(safe-area-inset-bottom));
  background:var(--bg);
  overflow-y:auto;
  overscroll-behavior:contain;
  animation:lpFade .4s ease;
}
@keyframes lpFade{from{opacity:0}to{opacity:1}}

/* 页面专属的强化光斑层（比全局 .bg-orbs 更亮，突出落地页） */
.login-page .bg-orbs{position:absolute;}
.login-page .bg-orbs span{opacity:calc(var(--orbs-opacity) * 1.9);}
.login-page::before{
  content:'';position:absolute;inset:0;pointer-events:none;
  background:
    radial-gradient(1200px 600px at 50% -10%, rgba(var(--accent-rgb),.16), transparent 60%),
    radial-gradient(800px 500px at 100% 100%, rgba(139,108,240,.12), transparent 55%);
}

/* ---------- 页面骨架 ---------- */
.lp-shell{
  position:relative;z-index:2;
  width:100%;max-width:440px;
  display:flex;flex-direction:column;gap:18px;
  margin:auto;
}

/* 顶部品牌行 */
.lp-topbar{
  display:flex;align-items:center;justify-content:space-between;
  gap:12px;padding:2px 4px;
}
.lp-brand{display:flex;align-items:center;gap:10px;min-width:0;}
.lp-brand-icon{
  width:38px;height:38px;flex:0 0 38px;border-radius:11px;
  background:var(--grad);color:#fff;
  display:flex;align-items:center;justify-content:center;
  box-shadow:0 6px 18px rgba(var(--accent-rgb),.38);
}
.lp-brand-icon svg{width:20px;height:20px;}
.lp-brand-text{min-width:0;}
.lp-brand-name{font-weight:700;font-size:15px;letter-spacing:.3px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}
.lp-brand-sub{font-size:11px;color:var(--text2);margin-top:1px;white-space:nowrap;overflow:hidden;text-overflow:ellipsis;}

/* ---------- 主卡片 ---------- */
.lp-card{
  position:relative;overflow:hidden;
  background:var(--card);
  border:1px solid var(--border);
  border-radius:var(--radius-xl);
  box-shadow:var(--shadow-card);
  backdrop-filter:blur(22px);-webkit-backdrop-filter:blur(22px);
  padding:clamp(24px,5vw,38px) clamp(20px,5vw,36px);
  animation:lpUp .5s var(--ease);
}
@keyframes lpUp{from{transform:translateY(18px);opacity:0}to{transform:none;opacity:1}}
.lp-card::before{
  content:'';position:absolute;top:-60%;left:-60%;width:220%;height:220%;
  background:radial-gradient(circle at 32% 28%, rgba(255,255,255,.10) 0%, transparent 55%);
  pointer-events:none;
}
.lp-card > *{position:relative;z-index:1;}

/* 应用图标（带光晕与描边） */
.lp-app-icon{
  width:72px;height:72px;margin:0 auto 18px;border-radius:20px;
  background:var(--grad);color:#fff;
  display:flex;align-items:center;justify-content:center;
  box-shadow:0 14px 40px rgba(var(--accent-rgb),.42), inset 0 1px 0 rgba(255,255,255,.28);
  position:relative;
}
.lp-app-icon::after{
  content:'';position:absolute;inset:-10px;border-radius:28px;
  background:radial-gradient(circle, rgba(var(--accent-rgb),.32), transparent 70%);
  z-index:-1;filter:blur(6px);
}
.lp-app-icon svg{width:34px;height:34px;}

.lp-title{
  text-align:center;font-size:clamp(20px,4.6vw,24px);
  font-weight:700;letter-spacing:.2px;line-height:1.3;
  margin-bottom:6px;
}
.lp-desc{
  text-align:center;font-size:13px;color:var(--text2);
  line-height:1.65;margin-bottom:22px;
  max-width:340px;margin-left:auto;margin-right:auto;
}

/* 登录按钮区 */
.lp-actions{display:flex;flex-direction:column;gap:10px;}
.lp-btn-login{
  width:100%;padding:14px 18px;border-radius:14px;border:none;cursor:pointer;
  background:var(--blue);color:#fff;font-family:inherit;
  font-size:15px;font-weight:600;letter-spacing:.2px;
  display:flex;align-items:center;justify-content:center;gap:9px;
  position:relative;overflow:hidden;
  transition:transform .12s,background .15s,box-shadow .2s;
  box-shadow:0 8px 24px rgba(var(--accent-rgb),.34);
  touch-action:manipulation;-webkit-tap-highlight-color:transparent;
}
.lp-btn-login:hover{filter:brightness(1.08);box-shadow:0 10px 30px rgba(var(--accent-rgb),.44);}
.lp-btn-login:active{transform:scale(.975);background:var(--blue-press);}
.lp-btn-login::after{
  content:'';position:absolute;top:-50%;left:-50%;width:200%;height:200%;
  background:radial-gradient(circle, rgba(255,255,255,.25) 0%, transparent 55%);
  pointer-events:none;
}
.lp-btn-login svg{width:17px;height:17px;flex:0 0 17px;}
.lp-btn-login[disabled]{opacity:.6;cursor:progress;}

/* 次按钮（如「先随便看看」） */
.lp-btn-ghost{
  width:100%;padding:12px 18px;border-radius:14px;cursor:pointer;
  background:var(--tint-b);color:var(--text);border:1px solid var(--border);
  font-family:inherit;font-size:14px;font-weight:500;
  display:flex;align-items:center;justify-content:center;gap:8px;
  transition:background .15s,transform .12s;
  touch-action:manipulation;-webkit-tap-highlight-color:transparent;
}
.lp-btn-ghost:hover{background:var(--tint-c);}
.lp-btn-ghost:active{transform:scale(.98);}

/* 安全性说明行 */
.lp-secure{
  display:flex;align-items:center;justify-content:center;gap:6px;
  margin-top:16px;font-size:11.5px;color:var(--text3);text-align:center;
}
.lp-secure svg{width:13px;height:13px;flex:0 0 13px;}

/* ---------- 特性网格 ---------- */
.lp-features{
  display:grid;grid-template-columns:repeat(3,1fr);gap:10px;
  margin-top:22px;padding-top:20px;border-top:1px solid var(--border);
}
.lp-feature{
  display:flex;flex-direction:column;align-items:center;gap:7px;
  text-align:center;padding:12px 8px;border-radius:14px;
  background:var(--tint-a);border:1px solid var(--border);
  transition:background .2s,border-color .2s,transform .2s;
}
.lp-feature:hover{background:var(--tint-b);border-color:var(--border-2);transform:translateY(-2px);}
.lp-feature-ico{
  width:34px;height:34px;border-radius:10px;
  background:rgba(var(--accent-rgb),.14);color:var(--blue);
  display:flex;align-items:center;justify-content:center;
}
.lp-feature-ico svg{width:17px;height:17px;}
.lp-feature-t{font-size:12px;font-weight:600;color:var(--text);line-height:1.3;}
.lp-feature-d{font-size:10.5px;color:var(--text3);line-height:1.35;}

/* ---------- 底部 ---------- */
.lp-foot{
  text-align:center;font-size:11.5px;color:var(--text3);line-height:1.7;
  padding:0 8px;
}
.lp-foot a{color:var(--text2);text-decoration:none;border-bottom:1px solid var(--border-2);padding-bottom:1px;transition:color .15s;}
.lp-foot a:hover{color:var(--blue);}

/* ---------- 加载态 ---------- */
.lp-loading{
  display:flex;flex-direction:column;align-items:center;gap:14px;
  padding:40px 0;
}
.lp-spinner{
  width:34px;height:34px;border-radius:50%;
  border:3px solid var(--tint-c);border-top-color:var(--blue);
  animation:lpSpin .8s linear infinite;
}
@keyframes lpSpin{to{transform:rotate(360deg)}}
.lp-loading-text{font-size:13px;color:var(--text2);}

/* ============================================================
   响应式：移动端
   ============================================================ */
@media (max-width:520px){
  .login-page{align-items:flex-start;padding:20px 16px 28px;}
  .lp-shell{max-width:100%;gap:14px;margin:0 auto;}
  .lp-topbar{display:none;}                      /* 移动端隐藏顶栏，信息合并进卡片 */
  .lp-card{border-radius:20px;padding:26px 20px 24px;}
  .lp-app-icon{width:64px;height:64px;border-radius:18px;margin-bottom:16px;}
  .lp-app-icon svg{width:30px;height:30px;}
  .lp-title{font-size:20px;}
  .lp-desc{font-size:12.5px;margin-bottom:20px;}
  .lp-btn-login{padding:15px 16px;font-size:15px;}  /* 移动端加大点击区域 */
  .lp-features{grid-template-columns:1fr;gap:8px;padding-top:16px;margin-top:18px;}
  .lp-feature{
    flex-direction:row;text-align:left;gap:11px;padding:11px 13px;
  }
  .lp-feature-ico{flex:0 0 34px;}
  .lp-feature-t{font-size:12.5px;}
  .lp-feature-d{font-size:11px;}
}
@media (max-width:360px){
  .lp-title{font-size:18.5px;}
  .lp-app-icon{width:56px;height:56px;}
  .lp-app-icon svg{width:26px;height:26px;}
  .lp-btn-login{font-size:14px;padding:14px;}
}

/* 横屏矮屏：避免卡片被裁 */
@media (max-height:560px) and (orientation:landscape){
  .login-page{align-items:flex-start;}
  .lp-features{display:none;}
  .lp-app-icon{width:52px;height:52px;margin-bottom:12px;}
}

@media (prefers-reduced-motion:reduce){
  .login-page,.lp-card,.lp-spinner{animation-duration:.01s;}
  .lp-spinner{animation:lpSpin .8s linear infinite;}
}
