/* LangLFT 官网样式 —— iOS / Apple 风格：大留白、细字重、单一强调色、克制的动效 */
:root {
  --bg: #fbfbfd;
  --bg-elevated: #ffffff;
  --text: #1d1d1f;
  --text-secondary: #6e6e73;
  --line: rgba(0, 0, 0, .08);
  --accent: #0071e3;
  --accent-hover: #0077ed;
  --chip: rgba(0, 113, 227, .08);
  --nav-bg: rgba(251, 251, 253, .72);
  --shadow: 0 12px 40px rgba(0, 0, 0, .08);
  --shadow-hover: 0 18px 50px rgba(0, 0, 0, .14);
  --radius: 18px;
  --ease: cubic-bezier(.22, .61, .36, 1);
  /* 玻璃拟态 */
  --glass: rgba(255, 255, 255, .58);
  --glass-border: rgba(255, 255, 255, .72);
  --glass-inner: rgba(255, 255, 255, .55);
  /* 背景数字雨 / 鼠标粒子 */
  --fx-color: rgba(20, 24, 32, .075);
  --fx-glow: rgba(0, 113, 227, .11);
  --fx-particle: rgba(0, 113, 227, .85);
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000;
    --bg-elevated: #1c1c1e;
    --text: #f5f5f7;
    --text-secondary: #a1a1a6;
    --line: rgba(255, 255, 255, .12);
    --accent: #0a84ff;
    --accent-hover: #3d9bff;
    --chip: rgba(10, 132, 255, .16);
    --nav-bg: rgba(0, 0, 0, .72);
    --shadow: 0 12px 40px rgba(0, 0, 0, .5);
    --shadow-hover: 0 18px 50px rgba(0, 0, 0, .6);
    --glass: rgba(28, 28, 30, .55);
    --glass-border: rgba(255, 255, 255, .10);
    --glass-inner: rgba(255, 255, 255, .04);
    --fx-color: rgba(190, 220, 255, .09);
    --fx-glow: rgba(10, 132, 255, .16);
    --fx-particle: rgba(120, 190, 255, .85);
  }
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(1000px 620px at 50% -12%, var(--chip), transparent 72%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text",
               "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", "Segoe UI",
               Roboto, sans-serif;
  font-size: 17px;
  line-height: 1.6;
  letter-spacing: -.01em;
  -webkit-font-smoothing: antialiased;
}

/* 背景数字雨画布：固定在底层，不吃事件 */
.bg-fx {
  position: fixed; inset: 0; width: 100%; height: 100%;
  z-index: 0; pointer-events: none;
}
.hero, main, footer { position: relative; z-index: 1; }

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

/* ---------------------------------------------------------------- 导航 */
.nav {
  position: sticky; top: 0; z-index: 20;
  backdrop-filter: saturate(200%) blur(22px);
  -webkit-backdrop-filter: saturate(200%) blur(22px);
  background: var(--nav-bg);
  border-bottom: 1px solid transparent;
  transition: border-color .3s var(--ease);
}
.nav.scrolled { border-bottom-color: var(--line); }
.nav-inner {
  max-width: 980px; margin: 0 auto; padding: 0 22px;
  height: 52px; display: flex; align-items: center; justify-content: space-between;
}
.brand {
  display: flex; align-items: center; gap: 9px;
  color: var(--text); font-size: 15px; font-weight: 600; letter-spacing: -.02em;
  text-decoration: none;
}
.brand:hover { text-decoration: none; }
.brand svg { display: block; }
.brand-ico {
  width: 20px; height: 20px; border-radius: 6px; display: block;
  box-shadow: 0 1px 3px rgba(0, 0, 0, .12);
}
.nav-links { display: flex; gap: 26px; font-size: 13px; }
.nav-links a { color: var(--text-secondary); transition: color .2s var(--ease); }
.nav-links a:hover { color: var(--text); text-decoration: none; }

/* ---------------------------------------------------------------- 通用 */
.wrap { max-width: 980px; margin: 0 auto; padding: 0 22px; }
section { padding: 96px 0; }
/* .wrap 的左右内边距会盖掉 section 的上下留白，这里显式补回来 */
section.wrap { padding-top: 96px; padding-bottom: 96px; }
section.wrap.section-tight { padding-top: 56px; padding-bottom: 96px; }
h1, h2, h3 { margin: 0; letter-spacing: -.025em; font-weight: 600; }
h2 { font-size: 40px; line-height: 1.12; }
.lead { color: var(--text-secondary); font-size: 19px; margin: 14px 0 0; max-width: 620px; }
.muted { color: var(--text-secondary); }
.note-line {
  max-width: 680px; margin: 0; color: var(--text-secondary);
  font-size: 15px; line-height: 1.7;
}
.note-line strong { color: var(--text); font-weight: 500; }

/* ---------------------------------------------------------------- Hero */
.hero { padding: 96px 0 80px; text-align: center; }
.app-icon {
  width: 104px; height: 104px; margin: 0 auto 28px;
  border-radius: 24px; overflow: hidden;
  box-shadow: var(--shadow);
  display: block;
}
.hero h1 { font-size: 64px; line-height: 1.05; letter-spacing: -.035em; }
.hero .lead { font-size: 22px; margin: 16px auto 0; }
.cta-row {
  margin-top: 34px; display: flex; gap: 14px; justify-content: center; flex-wrap: wrap;
}
.fine { margin-top: 16px; font-size: 13px; color: var(--text-secondary); }

/* 首屏入场：默认可见，仅 JS 可用时先隐藏再淡入 */
.js .hs { opacity: 0; transform: translateY(14px); }
.js .hs.in {
  opacity: 1; transform: none;
  transition: opacity .8s var(--ease) var(--d, 0s),
              transform .8s var(--ease) var(--d, 0s);
}
.hs.d1 { --d: .06s; } .hs.d2 { --d: .12s; }
.hs.d3 { --d: .18s; } .hs.d4 { --d: .24s; }

/* 图标极缓慢浮动（纯装饰，不承载可见性） */
.float { animation: float 7s ease-in-out 1s infinite; }
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-5px); }
}

/* ---------------------------------------------------------------- 按钮 */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  background: var(--accent); color: #fff;
  padding: 13px 26px; border-radius: 980px;
  font-size: 16px; font-weight: 500; letter-spacing: -.01em;
  border: none; cursor: pointer;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .06);
  transition: background .2s var(--ease), transform .2s var(--ease),
              box-shadow .3s var(--ease);
}
.btn:hover {
  background: var(--accent-hover); text-decoration: none;
  transform: translateY(-1px); box-shadow: 0 8px 24px rgba(0, 113, 227, .28);
}
.btn:active { transform: scale(.975); box-shadow: 0 1px 2px rgba(0, 0, 0, .08); }
.btn[aria-disabled="true"] { opacity: .45; pointer-events: none; }

/* ---------------------------------------------------------------- 下载卡 */
.download-card {
  margin-top: 8px;
  background: var(--glass);
  backdrop-filter: blur(26px) saturate(180%);
  -webkit-backdrop-filter: blur(26px) saturate(180%);
  border: 1px solid var(--glass-border);
  border-radius: var(--radius);
  padding: 40px 44px 34px;
  box-shadow: var(--shadow), inset 0 1px 0 var(--glass-inner);
  transition: box-shadow .45s var(--ease), transform .45s var(--ease),
              background .3s var(--ease);
}
.download-card:hover { box-shadow: var(--shadow-hover); transform: translateY(-2px); }
.dl-head {
  display: flex; align-items: center; justify-content: space-between;
  gap: 24px; flex-wrap: wrap;
}
.dl-title { font-size: 26px; letter-spacing: -.02em; }
.chip {
  display: inline-block; background: var(--chip); color: var(--accent);
  font-size: 12px; font-weight: 500; padding: 3px 10px; border-radius: 980px;
  vertical-align: middle; margin-left: 8px;
}
.spec {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 0; margin: 28px 0 0; border-top: 1px solid var(--line);
}
.spec div { padding: 18px 0 0; }
.spec dt { font-size: 12px; color: var(--text-secondary); margin: 0 0 3px; }
.spec dd { margin: 0; font-size: 15px; }

/* ---------------------------------------------------------------- 入场动效 */
.reveal { transition: opacity .7s var(--ease), transform .7s var(--ease); }
/* 仅在 JS 生效时才做「先隐藏后淡入」，禁用 JS 也不会白屏 */
.js .reveal { opacity: 0; transform: translateY(18px); }
.js .reveal.in { opacity: 1; transform: none; }

/* ---------------------------------------------------------------- 协议页 */
.legal { padding: 72px 0 96px; }
.legal-head h1 { font-size: 44px; letter-spacing: -.03em; }
.legal-head .lead { font-size: 17px; }
.legal-body { max-width: 760px; margin-top: 48px; }
.legal-body h2 {
  font-size: 22px; margin: 52px 0 14px; letter-spacing: -.02em;
  padding-top: 26px; border-top: 1px solid var(--line);
}
.legal-body h2:first-child { border-top: none; padding-top: 0; margin-top: 0; }
.legal-body p { margin: 0 0 12px; color: var(--text); font-size: 15px; line-height: 1.75; }
.legal-body p.clause { padding-left: 46px; text-indent: -46px; }
.legal-body p.clause .num {
  display: inline-block; min-width: 30px; padding-right: 6px;
  color: var(--text-secondary); font-variant-numeric: tabular-nums; font-weight: 500;
}
.legal-body p.sub { padding-left: 46px; color: var(--text-secondary); }
.legal-note {
  background: var(--glass);
  backdrop-filter: blur(20px) saturate(170%);
  -webkit-backdrop-filter: blur(20px) saturate(170%);
  border: 1px solid var(--glass-border);
  border-radius: 14px; padding: 22px 26px; margin: 30px 0 0;
  font-size: 14px; color: var(--text-secondary);
}
.toc { margin: 34px 0 0; padding: 22px 26px;
       border: 1px solid var(--glass-border); border-radius: 14px;
       background: var(--glass);
       backdrop-filter: blur(20px) saturate(170%);
       -webkit-backdrop-filter: blur(20px) saturate(170%); }
.toc ol { margin: 0; padding-left: 0; list-style: none; columns: 2; column-gap: 34px;
          font-size: 14px; }
.toc li { margin-bottom: 5px; }
.toc a { color: var(--text-secondary); }

/* ---------------------------------------------------------------- 页脚 */
footer {
  border-top: 1px solid var(--line); padding: 40px 0 64px;
  font-size: 13px; color: var(--text-secondary);
}
.foot-inner {
  max-width: 980px; margin: 0 auto; padding: 0 22px;
  display: flex; justify-content: space-between; gap: 24px; flex-wrap: wrap;
}
.foot-links { display: flex; gap: 22px; flex-wrap: wrap; }
.foot-links a { color: var(--text-secondary); transition: color .2s var(--ease); }
.foot-links a:hover { color: var(--text); }
.foot-icp { width: 100%; margin-top: 10px; font-size: 12px; line-height: 1.6; }
.foot-icp a { color: var(--text-secondary); }
.foot-icp a:hover { color: var(--text); }
.foot-police { width: 100%; margin-top: 4px; font-size: 12px; line-height: 1.6; }
.foot-police a { color: var(--text-secondary); }
.foot-police a:hover { color: var(--text); }

/* ---------------------------------------------------------------- 响应式 */
@media (max-width: 760px) {
  body { font-size: 16px; }
  section { padding: 64px 0; }
  section.wrap { padding-top: 64px; padding-bottom: 64px; }
  section.wrap.section-tight { padding-top: 40px; padding-bottom: 64px; }
  .hero { padding: 56px 0 52px; }
  .hero h1 { font-size: 42px; }
  .hero .lead { font-size: 18px; }
  h2 { font-size: 29px; }
  .app-icon { width: 88px; height: 88px; border-radius: 21px; }
  .download-card { padding: 26px 22px; }
  .dl-head { gap: 16px; }
  .dl-head .btn { width: 100%; justify-content: center; }
  .spec { grid-template-columns: 1fr; gap: 0; }
  .spec div { padding: 14px 0; border-bottom: 1px solid var(--line); }
  .spec div:last-child { border-bottom: none; }
  .legal-head h1 { font-size: 32px; }
  .legal-body p.clause, .legal-body p.sub { padding-left: 0; text-indent: 0; }
  .legal-body p.clause .num { display: block; min-width: 0; }
  .toc ol { columns: 1; }
  .nav-links { gap: 18px; }
}

/* 系统开启“减少动态效果”时全部关掉 */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .reveal { opacity: 1; transform: none; }
  .bg-fx { display: none; }
}
