* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: system-ui, -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
}

body {
  min-height: 100vh;
  display: flex;
  justify-content: center;
  align-items: center;
  background: linear-gradient(135deg, #9c27b0 0%, #c2185b 45%, #e91e63 100%);
  background-size: 200% 200%;
  animation: bgShift 12s ease infinite;
  padding: 20px;
  position: relative;
  overflow-x: hidden;
}

@keyframes bgShift {
  0%, 100% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
}

/* 背景浮动光斑 */
.bg-orb {
  position: fixed;
  border-radius: 50%;
  filter: blur(60px);
  opacity: 0.35;
  pointer-events: none;
  z-index: 0;
  animation: orbFloat 10s ease-in-out infinite;
}

.bg-orb-1 {
  width: 280px;
  height: 280px;
  background: #ff80ab;
  top: -60px;
  left: -40px;
}

.bg-orb-2 {
  width: 220px;
  height: 220px;
  background: #ce93d8;
  bottom: 10%;
  right: -50px;
  animation-delay: -3s;
  animation-duration: 14s;
}

.bg-orb-3 {
  width: 160px;
  height: 160px;
  background: #f48fb1;
  top: 40%;
  left: 15%;
  animation-delay: -6s;
  animation-duration: 11s;
}

@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(30px, -24px) scale(1.08); }
}

.wrap {
  width: 100%;
  max-width: 820px;
  position: relative;
  z-index: 1;
}

.card {
  background: #fcf0f7;
  border-radius: 24px;
  padding: 48px 36px;
  text-align: center;
  box-shadow: 0 20px 60px rgba(80, 0, 60, 0.25);
  opacity: 0;
  transform: translateY(28px) scale(0.97);
  transition: opacity 0.55s ease, transform 0.55s cubic-bezier(0.22, 1, 0.36, 1);
}

body.is-ready .card {
  opacity: 1;
  transform: translateY(0) scale(1);
}

/* 入场动画 */
.anim-item {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.45s ease, transform 0.45s cubic-bezier(0.22, 1, 0.36, 1);
  transition-delay: var(--delay, 0s);
}

body.is-ready .anim-item {
  opacity: 1;
  transform: translateY(0);
}

/* 头部 Logo + 标题 */
.header {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 16px;
  margin-bottom: 12px;
}

.logo-icon {
  width: 80px;
  height: 80px;
  border-radius: 20px;
  background: linear-gradient(145deg, #8b5cf6, #7b42f5);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 36px;
  line-height: 1;
  box-shadow: 0 8px 20px rgba(123, 66, 245, 0.35);
  animation: logoFloat 3.2s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes logoFloat {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-6px); }
}

.title {
  font-size: 42px;
  color: #7b42f5;
  font-weight: 600;
}

.sub-desc {
  font-size: 18px;
  color: #555;
  margin-bottom: 22px;
  letter-spacing: 1px;
}

/* 红色提示条 */
.tip-bar {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #fce4e7;
  color: #d32f2f;
  padding: 10px 24px;
  border-radius: 30px;
  font-size: 17px;
  margin-bottom: 30px;
  animation: tipPulse 2.4s ease-in-out infinite;
}

.tip-bar .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: #d32f2f;
  animation: dotBlink 1.2s ease-in-out infinite;
  flex-shrink: 0;
}

@keyframes tipPulse {
  0%, 100% { box-shadow: 0 0 0 0 rgba(211, 47, 47, 0); }
  50% { box-shadow: 0 0 0 6px rgba(211, 47, 47, 0.08); }
}

@keyframes dotBlink {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(0.85); }
}

/* 密码输入框组 */
.input-wrap {
  position: relative;
  z-index: 40;
  width: 100%;
  max-width: 620px;
  margin: 0 auto 12px;
}

.input-wrap.is-suggest-open {
  z-index: 80;
}

.input-group {
  display: flex;
  width: 100%;
  position: relative;
  z-index: 1;
}

.at-tip {
  position: relative;
  z-index: 1;
  color: #7b42f5;
  font-size: 15px;
  margin-bottom: 20px;
  line-height: 1.5;
}

.at-suggest {
  position: absolute;
  left: 0;
  right: 140px;
  top: calc(100% + 6px);
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 16px 40px rgba(80, 0, 60, 0.22);
  border: 1px solid rgba(123, 66, 245, 0.14);
  z-index: 90;
  max-height: 260px;
  overflow-y: auto;
  text-align: left;
  padding: 6px;
  -webkit-overflow-scrolling: touch;
}

.at-suggest[hidden] {
  display: none !important;
}

.at-suggest-title {
  padding: 8px 12px 6px;
  font-size: 12px;
  color: #999;
}

.at-suggest-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  width: 100%;
  border: none;
  background: transparent;
  padding: 10px 12px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 15px;
  color: #333;
  text-align: left;
  transition: background 0.15s;
}

.at-suggest-item:hover,
.at-suggest-item.is-active {
  background: #f3e8ff;
}

.at-suggest-item .at-key {
  color: #7b42f5;
  font-weight: 600;
}

.at-suggest-item .at-name {
  color: #888;
  font-size: 13px;
}

.at-suggest-empty {
  padding: 12px;
  color: #999;
  font-size: 14px;
  text-align: center;
}

.pwd-input {
  flex: 1;
  height: 64px;
  border: 2px solid transparent;
  border-radius: 12px 0 0 12px;
  padding: 0 22px;
  font-size: 20px;
  outline: none;
  background: #fff;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.pwd-input:focus {
  border-color: #7b42f5;
  box-shadow: 0 0 0 3px rgba(123, 66, 245, 0.15);
}

.pwd-input.input-error {
  border-color: #e03e36;
  animation: inputFlash 0.5s ease;
}

@keyframes inputFlash {
  0%, 100% { background: #fff; }
  50% { background: #ffebee; }
}

.confirm-btn {
  width: 140px;
  height: 64px;
  background: #e03e36;
  color: #fff;
  border: none;
  border-radius: 0 12px 12px 0;
  font-size: 20px;
  font-weight: 500;
  cursor: pointer;
  transition: transform 0.2s, background 0.25s, box-shadow 0.25s;
}

.confirm-btn:hover {
  background: #c62828;
  box-shadow: 0 6px 16px rgba(224, 62, 54, 0.35);
}

.confirm-btn:active {
  transform: scale(0.97);
}

.confirm-btn.btn-success {
  background: #00a86b;
}

.confirm-btn:disabled {
  opacity: 0.75;
  cursor: wait;
}

/* 密码大全按钮 */
.pwd-all-btn {
  background: #f29c1f;
  color: #fff;
  border: none;
  padding: 16px 42px;
  border-radius: 12px;
  font-size: 20px;
  cursor: pointer;
  margin-bottom: 24px;
  transition: transform 0.2s, box-shadow 0.25s, background 0.25s;
  box-shadow: 0 4px 14px rgba(242, 156, 31, 0.35);
  animation: btnGlow 2.8s ease-in-out infinite;
}

.pwd-all-btn:hover {
  background: #e08a10;
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(242, 156, 31, 0.45);
}

.pwd-all-btn:active,
.pwd-all-btn.btn-tap {
  transform: scale(0.96);
}

.pwd-all-btn .lock-icon {
  display: inline-block;
  animation: lockWiggle 2.5s ease-in-out infinite;
}

@keyframes btnGlow {
  0%, 100% { box-shadow: 0 4px 14px rgba(242, 156, 31, 0.35); }
  50% { box-shadow: 0 6px 22px rgba(242, 156, 31, 0.55); }
}

@keyframes lockWiggle {
  0%, 70%, 100% { transform: rotate(0); }
  75% { transform: rotate(-12deg); }
  85% { transform: rotate(10deg); }
  95% { transform: rotate(-4deg); }
}

.link-tip {
  color: #7b42f5;
  font-size: 17px;
  margin-bottom: 12px;
}

.update-tag {
  display: inline-block;
  background: #e9d8f4;
  color: #7b42f5;
  padding: 6px 18px;
  border-radius: 20px;
  font-size: 15px;
  margin-bottom: 28px;
  animation: tagBreath 3s ease-in-out infinite;
}

@keyframes tagBreath {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(1.04); opacity: 0.9; }
}

/* 快捷入口按钮 */
.action-btns {
  display: flex;
  justify-content: center;
  gap: 14px;
  flex-wrap: wrap;
  margin: 0 auto 18px;
  max-width: 620px;
}

.action-btn {
  flex: 1;
  min-width: 140px;
  max-width: 280px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 14px 20px;
  background: #1aad19;
  color: #fff;
  border: none;
  border-radius: 10px;
  font-size: 17px;
  font-weight: 500;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.2s, background 0.25s, box-shadow 0.25s;
  box-shadow: 0 4px 12px rgba(26, 173, 25, 0.3);
}

.action-btn:hover {
  background: #169916;
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(26, 173, 25, 0.4);
}

.action-btn:active {
  transform: scale(0.97);
}

/* 横幅图片入口 */
.banner-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 20px auto 0;
  max-width: 620px;
}

.banner-link {
  display: block;
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.2s, box-shadow 0.25s;
  box-shadow: 0 4px 14px rgba(80, 0, 60, 0.12);
}

.banner-link:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(80, 0, 60, 0.18);
}

.banner-link:active {
  transform: scale(0.99);
}

.banner-img {
  display: block;
  width: 100%;
  height: auto;
}

/* 底部统计数据行 */
.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
}

.stat-item {
  background: #fff;
  border-radius: 10px;
  padding: 14px 6px;
  transition: transform 0.25s, box-shadow 0.25s;
  animation: statPop 0.5s cubic-bezier(0.22, 1, 0.36, 1) both;
  animation-delay: calc(0.58s + var(--stat-delay, 0s));
}

body:not(.is-ready) .stat-item {
  animation: none;
  opacity: 0;
}

.stat-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 18px rgba(123, 66, 245, 0.12);
}

@keyframes statPop {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.92);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

.stat-num {
  font-size: 22px;
  font-weight: 600;
  color: #5528cc;
  margin-bottom: 4px;
}

.stat-label {
  font-size: 13px;
  color: #666;
}

/* 抖动反馈 */
.shake {
  animation: shakeX 0.45s ease;
}

@keyframes shakeX {
  0%, 100% { transform: translateX(0); }
  20% { transform: translateX(-8px); }
  40% { transform: translateX(8px); }
  60% { transform: translateX(-6px); }
  80% { transform: translateX(4px); }
}

/* 响应式适配手机 */
@media (max-width: 600px) {
  .stats-row {
    grid-template-columns: repeat(2, 1fr);
  }

  .title {
    font-size: 30px;
  }

  .header {
    flex-direction: column;
  }

  .logo-icon {
    width: 64px;
    height: 64px;
    font-size: 28px;
  }

  .input-group {
    flex-direction: column;
  }

  .pwd-input,
  .confirm-btn {
    border-radius: 12px;
    width: 100%;
  }

  .confirm-btn {
    margin-top: 8px;
  }

  .at-suggest {
    right: 0;
  }

  .action-btns {
    gap: 10px;
  }

  .action-btn {
    font-size: 15px;
    padding: 12px 14px;
    max-width: none;
  }

  .banner-list {
    gap: 10px;
  }

  .card {
    padding: 36px 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
