/* ══════════════════════════════════════════════════════════════════════════
 * 灵通 · 启动页样式
 *
 * 跟启动界面（launcher.css）用同一套色板和玻璃质感，
 * 但从 launcher.css 里复制变量而不是 @import —— 两个页面不该互相依赖，
 * 以后改一个不会连带崩另一个。
 * ══════════════════════════════════════════════════════════════════════════ */

:root {
  --accent:    #7d63c4;
  --accent-2:  #9d84da;
  --ink:       #1d2635;
  --ink-2:     #3d4a5c;
  --ink-dim:   #4a5769;
  --ink-mute:  #67758a;
  --edge:      rgba(255, 255, 255, 0.72);
  --line:      rgba(124, 139, 161, 0.18);
}

* { box-sizing: border-box; }

html, body {
  height: 100%;
  margin: 0;
}

body {
  font-family: system-ui, -apple-system, "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: linear-gradient(160deg, #eef2fb 0%, #f7eef6 52%, #eef6fb 100%);
  overflow: hidden;
  -webkit-font-smoothing: antialiased;
}

/* ── 背景印花 ── */
.bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 0;
}
.blob {
  position: absolute;
  border-radius: 50%;
  filter: blur(56px);
  opacity: 0.62;
}
.b1 {
  width: 46vw; height: 46vw; min-width: 340px; min-height: 340px;
  left: -8vw; top: -12vw;
  background: radial-gradient(circle, rgba(125, 99, 196, 0.5), transparent 68%);
  animation: float1 22s ease-in-out infinite;
}
.b2 {
  width: 40vw; height: 40vw; min-width: 300px; min-height: 300px;
  right: -6vw; bottom: -10vw;
  background: radial-gradient(circle, rgba(93, 158, 199, 0.46), transparent 68%);
  animation: float2 27s ease-in-out infinite;
}
.b3 {
  width: 30vw; height: 30vw; min-width: 240px; min-height: 240px;
  left: 46%; top: 30%;
  background: radial-gradient(circle, rgba(209, 120, 160, 0.36), transparent 68%);
  animation: float3 31s ease-in-out infinite;
}
@keyframes float1 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(4vw, 3vw) scale(1.08); }
}
@keyframes float2 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(-3vw, -4vw) scale(1.06); }
}
@keyframes float3 {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50%      { transform: translate(-4vw, 3vw) scale(1.1); }
}
.grain {
  position: absolute;
  inset: 0;
  /* 2026-10-29 视觉自查：0.32 的点阵显得生硬，压到 0.16 */
  opacity: 0.10;
  background-image: radial-gradient(rgba(120, 130, 150, 0.16) 1px, transparent 1px);
  background-size: 4px 4px;
}

/* ── 内容 ── */
.entry {
  position: relative;
  z-index: 1;
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0;
  padding: 32px 24px;
  text-align: center;
}

.brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  animation: riseIn 0.62s cubic-bezier(0.2, 0.8, 0.3, 1) both;
}
.logo {
  width: 92px;
  height: 92px;
  border-radius: 24px;
  box-shadow: 0 16px 40px rgba(125, 99, 196, 0.3),
              0 2px 6px rgba(56, 74, 110, 0.1);
}
.brand h1 {
  margin: 0;
  font-size: 40px;
  font-weight: 900;
  letter-spacing: 6px;
  text-indent: 6px;
  color: var(--ink);
}
.brand .sub {
  margin: 0;
  font-size: 13px;
  letter-spacing: 1.6px;
  color: var(--ink-mute);
}

/* 2026-10-29：首页三句说明。新用户第一眼要能看懂这是干什么的。
   用低对比小字，不抢主按钮。 */
.facts {
  /* 2026-10-29：这里必须显式 text-align: left。
     .entry 是 text-align: center，会被继承下来，
     三行长短不一就各自居中，短的那行看着像多了缩进。
     width: fit-content + margin auto 让整个块在页面中间，但内部左对齐。 */
  text-align: left;
  width: fit-content;
  margin: 30px auto 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 9px;
  animation: riseIn 0.62s cubic-bezier(0.2, 0.8, 0.3, 1) 0.16s both;
}
.facts li {
  position: relative;
  padding-left: 16px;
  font-size: 12.5px;
  line-height: 1.6;
  letter-spacing: 0.3px;
  color: var(--ink-mute);
}
.facts li::before {
  content: '';
  position: absolute;
  left: 2px;
  top: 7px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: linear-gradient(135deg, #b9a6e8, #7d63c4);
  opacity: 0.75;
}

.lead {
  margin: 34px 0 0;
  font-size: 14px;
  color: var(--ink-dim);
  animation: riseIn 0.62s cubic-bezier(0.2, 0.8, 0.3, 1) 0.08s both;
}

/* ── 主按钮 ── */
.enter {
  position: relative;
  margin-top: 34px;
  min-width: 232px;
  height: 56px;
  padding: 0 46px;
  border: none;
  border-radius: 16px;
  background: linear-gradient(180deg, var(--accent-2), var(--accent));
  color: #fff;
  font-family: inherit;
  font-size: 16px;
  font-weight: 800;
  /* 2026-10-29 视觉自查：字距被连续嫌宽。
     真正的病因是 HTML 里写了一个真空格「启 动」，已删；
     字距本身也收到 2px。 */
  letter-spacing: 2px;
  text-indent: 2px;
  cursor: pointer;
  box-shadow: 0 14px 34px rgba(125, 99, 196, 0.42);
  transition: transform 0.16s ease, box-shadow 0.16s ease, filter 0.16s ease;
  animation: riseIn 0.62s cubic-bezier(0.2, 0.8, 0.3, 1) 0.14s both;
}
.enter:hover:not(:disabled) {
  transform: translateY(-2px);
  box-shadow: 0 18px 42px rgba(125, 99, 196, 0.5);
}
.enter:active:not(:disabled) { transform: translateY(0); }
.enter:disabled {
  cursor: default;
  filter: saturate(0.72) brightness(1.02);
}
.enter.busy { letter-spacing: 2px; text-indent: 2px; font-size: 14px; }

.enter-spin {
  position: absolute;
  right: 18px;
  top: 50%;
  transform: translateY(-50%);
}
.enter-spin i {
  display: block;
  width: 16px;
  height: 16px;
  border: 2.2px solid rgba(255, 255, 255, 0.34);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.72s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

.hint {
  margin: 16px 0 0;
  min-height: 18px;
  font-size: 12.5px;
  /* 2026-10-29 视觉自查：浅灰对比度不够，调到 ink-dim */
  color: var(--ink-dim);
  animation: riseIn 0.62s cubic-bezier(0.2, 0.8, 0.3, 1) 0.2s both;
}

.ver {
  position: absolute;
  bottom: 22px;
  margin: 0;
  font-size: 11.5px;
  letter-spacing: 0.4px;
  /* 2026-10-29 视觉自查：0.7 透明 + 浅灰，底下几乎看不清 */
  color: var(--ink-mute);
  opacity: 1;
}

@keyframes riseIn {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}

@media (max-width: 480px) {
  .brand h1 { font-size: 32px; letter-spacing: 4px; text-indent: 4px; }
  .logo { width: 76px; height: 76px; border-radius: 20px; }
  .enter { min-width: 200px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

/* ⚠ 2026-10-29 修的真 bug：
 * .field / .field2 这类自己写了 display:grid 的元素，
 * 会把浏览器默认的 [hidden]{display:none} 盖掉，
 * 结果登录态也显示了「再输一遍」密码框，
 * 表单看起来像注册但页签在登录。
 * 这条必须放在最后，且加 !important。 */
[hidden] { display: none !important; }
