/* ==========================================================================
   新天地 APP 下载落地页 — 公共样式
   纯 HTML+CSS+JS，无框架。紫色系品牌调、圆角按钮，移动优先。
   ========================================================================== */

:root {
  --purple-dark: #4a2d8c;
  --purple: #7c4dff;
  --purple-lt: #b388ff;
  --grad: linear-gradient(135deg, #7c4dff 0%, #9b6cff 55%, #b388ff 100%);
  --grad-btn: linear-gradient(135deg, #8a5cff 0%, #6a3df0 100%);
  --page-bg: #eee9f8;
  --text: #2a2440;
  --radius: 12px;   /* 按钮统一小圆角矩形 */
}

* { box-sizing: border-box; margin: 0; padding: 0; -webkit-tap-highlight-color: transparent; }

html, body {
  font-family: -apple-system, "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: var(--page-bg);
}

/* 页面容器：手机宽度居中，桌面预览时不至于铺满 */
.wrap {
  max-width: 480px;
  margin: 0 auto;
  min-height: 100vh;
  background: linear-gradient(180deg, #efe9fb 0%, #e6ddf7 100%);
  position: relative;
  overflow-x: hidden;
}

img { display: block; max-width: 100%; }

/* 通用小圆角矩形主按钮 */
.btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: none;
  outline: none;
  cursor: pointer;
  font-size: 16px;
  font-weight: 700;
  color: #fff;
  background: var(--grad-btn);
  border-radius: var(--radius);
  padding: 13px 20px;
  box-shadow: 0 4px 12px rgba(124, 77, 255, .3);
  text-decoration: none;
  transition: transform .08s ease, box-shadow .15s ease;
}
.btn:active { transform: translateY(1px) scale(.99); box-shadow: 0 2px 8px rgba(124, 77, 255, .28); }
.btn.ghost { background: rgba(124, 77, 255, .12); color: var(--purple-dark); box-shadow: none; }

/* ============ 首页 index ============ */
.home-hero { width: 100%; }
.home-slogan { text-align: center; padding: 6px 16px 2px; }
.home-cats {
  display: flex; justify-content: space-around; flex-wrap: wrap;
  gap: 6px; padding: 10px 12px 4px; color: var(--purple-dark);
  font-size: 13px;
}
.home-cats span { display: flex; flex-direction: column; align-items: center; gap: 3px; opacity: .85; }
.home-cats i { font-style: normal; font-size: 22px; }
.home-actions { padding: 14px 20px 28px; }
.home-actions .row { display: flex; gap: 12px; margin-bottom: 12px; }
.home-actions .row .btn { flex: 1; }

/* ============ 顶栏（苹果/安卓页共用）============ */
.topbar {
  display: flex; align-items: center; justify-content: space-between;
  padding: 12px 14px; background: var(--purple-dark);
}
.topbar .brand { display: flex; align-items: center; gap: 8px; color: #fff; }
.topbar .brand img { width: 34px; height: 34px; border-radius: 50%; }
.topbar .brand b { font-size: 17px; }
.topbar .brand small { display: block; font-size: 10px; opacity: .7; }
.topbar .anti { font-size: 13px; padding: 8px 14px; }

/* 主视觉 */
.hero-img { width: 100%; }

/* 下载按钮区（苹果页） */
.dl-block { padding: 16px; }
.dl-block .btn { width: 100%; margin-bottom: 12px; font-size: 17px; padding: 14px; }
.dl-block .split { display: flex; gap: 10px; align-items: stretch; margin-bottom: 12px; }
.dl-block .split .btn { flex: 2; margin: 0; }
.dl-block .split .kf {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: var(--grad); color: #fff; border-radius: var(--radius); font-size: 12px;
  text-align: center; line-height: 1.35; text-decoration: none; padding: 6px;
}

/* 教程分节标题 */
.sec-title {
  display: flex; align-items: center; justify-content: center; gap: 10px;
  font-size: 18px; font-weight: 700; color: var(--purple-dark);
  padding: 18px 10px 6px;
}
.sec-title::before, .sec-title::after { content: "🔵"; font-size: 14px; }

/* 教程步骤（竖排） */
.steps { padding: 6px 16px 24px; }
.step { margin-bottom: 18px; }
.step .hd { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.step .num {
  width: 26px; height: 26px; flex: none; border-radius: 50%;
  background: var(--purple); color: #fff; font-weight: 700;
  display: flex; align-items: center; justify-content: center; font-size: 14px;
}
.step .tx { font-size: 15px; font-weight: 600; }
.step img { width: 100%; border-radius: 12px; box-shadow: 0 2px 10px rgba(0,0,0,.08); }

/* ============ 安卓页 ============ */
.phone-tabs {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 10px; padding: 16px;
}
.phone-tabs .tab {
  border: 2px solid transparent; border-radius: 14px; background: #fff;
  padding: 8px 4px 6px; text-align: center; cursor: pointer;
  box-shadow: 0 2px 8px rgba(0,0,0,.06); transition: all .15s;
}
.phone-tabs .tab img { width: 100%; border-radius: 10px; margin-bottom: 4px; }
.phone-tabs .tab span { font-size: 13px; color: #666; display: block; padding: 3px 0; border-radius: 8px; }
.phone-tabs .tab.active { border-color: var(--purple); }
.phone-tabs .tab.active span { background: var(--purple); color: #fff; }

.install-card {
  background: #fff; margin: 0 16px; border-radius: 18px; padding: 18px 16px 22px;
  box-shadow: 0 4px 16px rgba(0,0,0,.08);
}
.install-card h3 { text-align: center; font-size: 18px; margin-bottom: 14px; color: var(--text); }
.install-card .a-step { margin-bottom: 16px; }
.install-card .a-step .lbl { font-size: 14px; color: #555; margin-bottom: 8px; font-weight: 600; }
.install-card .a-step img { width: 100%; border-radius: 12px; }

/* 安卓底部下载横幅 */
.dl-banner {
  display: flex; align-items: center; gap: 10px; margin: 20px 16px 12px;
  background: #4b4560; border-radius: 14px; padding: 12px 14px; color: #fff;
}
.dl-banner img { width: 44px; height: 44px; border-radius: 10px; }
.dl-banner .txt b { font-size: 16px; display: block; }
.dl-banner .txt small { font-size: 11px; opacity: .75; }
.dl-banner .anti { margin-left: auto; font-size: 13px; padding: 9px 14px; white-space: nowrap; }

.dl-lines { display: flex; gap: 10px; padding: 4px 16px 30px; }
.dl-lines .btn { flex: 1; font-size: 15px; padding: 14px 6px; }

/* 浮动客服（苹果页右侧） */
.kf-float {
  position: fixed; right: 10px; top: 42%; z-index: 30;
  background: var(--grad); color: #fff; border-radius: 14px;
  font-size: 12px; text-align: center; line-height: 1.3; padding: 8px 10px;
  text-decoration: none; box-shadow: 0 4px 12px rgba(124,77,255,.4);
  max-width: 92px;
}

/* ============ 下载线路选择弹层 ============ */
.mask {
  display: none; position: fixed; inset: 0; z-index: 50;
  background: rgba(0,0,0,.5); align-items: flex-end;
}
.mask.show { display: flex; }
.sheet {
  width: 100%; max-width: 480px; margin: 0 auto;
  background: #fff; border-radius: 20px 20px 0 0; padding: 10px 0 20px;
  animation: rise .22s ease;
}
@keyframes rise { from { transform: translateY(100%); } to { transform: translateY(0); } }
.sheet .line {
  display: block; text-align: center; padding: 16px; font-size: 17px;
  color: var(--purple-dark); font-weight: 600; text-decoration: none;
  border-bottom: 1px solid #f0edf7;
}
.sheet .line.main { color: var(--purple); font-weight: 700; }
.sheet .tip { text-align: center; font-size: 12px; color: #999; padding: 14px 16px 4px; }
.sheet .cancel { display: block; text-align: center; padding: 14px; color: #999; font-size: 16px; cursor: pointer; }
