/* ==========================================================================
   TheoCraft — 宣传站样式
   --------------------------------------------------------------------------
   配色思路：
     · TheoTown 蓝绿  → --teal-*
     · Minecraft 草绿 → --grass-*
     · 石头灰         → --stone-*
   视觉手法：方块感靠「硬边框 + 无模糊的偏移阴影 + 像素化装饰」建立，
             而不是靠渐变和光晕，保持工具类站点的干净。

   主题：变量分两层——
     第一层是品牌色（--teal-* / --grass-* / --stone-*），两个主题共用；
     第二层是语义色（--page / --surface / --ink …），随 data-theme 切换。
     写组件时只用语义色，切主题就自动跟着走。
   ========================================================================== */

/* --------------------------------------------------------------------------
   1. 设计变量
   -------------------------------------------------------------------------- */
:root {
  /* ---- 品牌色 ---- */
  --teal-950: #04211f;
  --teal-900: #07302d;
  --teal-800: #0b4741;
  --teal-700: #0f6259;
  --teal-500: #14a794;
  --teal-400: #2fc0ac;
  --teal-300: #63d4c2;
  --teal-200: #9be3d9;
  --teal-100: #e9f7f4;

  --grass-600: #4c9a2a;
  --grass-500: #6cbb3c;
  --grass-400: #8fd45f;
  --grass-200: #c8e8a8;

  --stone-900: #131a1c;
  --stone-700: #33403f;
  --stone-500: #6e7c7b;
  --stone-400: #98a5a4;
  --stone-300: #c3cdcc;
  --stone-200: #dfe6e5;
  --stone-100: #eff3f2;
  --stone-050: #f6f9f8;

  --amber: #f0b429;
  --warn: #b45309;

  /* ---- 尺寸 / 字体 ---- */
  --r-xs: 3px;
  --r-sm: 6px;
  --r-md: 10px;
  --r-lg: 16px;
  --nav-h: 68px;
  --container: 1180px;
  --gap: 20px;

  /* 字体全部走系统字体，不请求任何外部资源 */
  --font: "Inter", system-ui, -apple-system, "Segoe UI", "PingFang SC",
          "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-mono: ui-monospace, "SFMono-Regular", "Cascadia Mono", Consolas,
               "Liberation Mono", monospace;

  /* ---- 动效曲线 ---- */
  --ease: cubic-bezier(.22, .61, .36, 1);

  /* ======================================================================
     语义色：白天（默认值。脚本没跑起来时也能正常显示）
     ====================================================================== */
  color-scheme: light;

  --page: #ffffff;                 /* 页面底色 */
  --surface: #ffffff;              /* 卡片 / 面板底色 */
  --surface-alt: var(--stone-050); /* 交替区块底色 */
  --sunken: var(--stone-100);      /* 凹陷区（图片容器、输入框底） */

  --ink: #0d1b1a;                  /* 正文主色 */
  --ink-2: var(--stone-700);       /* 次级正文 */
  --muted: #5b6b69;                /* 说明文字 */
  --faint: var(--stone-400);       /* 最弱的注释文字 */

  --line: #dde5e3;                 /* 分隔线 / 描边 */
  --line-strong: var(--stone-300);
  --chip-bg: var(--stone-050);
  --track: var(--stone-200);       /* 进度条 / 星星底槽 */

  --accent-soft-bg: var(--teal-100);
  --accent-soft-brd: var(--teal-200);
  --accent-soft-fg: var(--teal-700);
  --accent-text: var(--teal-700);

  --grass-soft-bg: #f2fbe8;
  --grass-soft-brd: var(--grass-200);
  --grass-soft-fg: var(--grass-600);

  --nav-bg: rgba(255, 255, 255, .82);
  --nav-brd: rgba(221, 229, 227, .9);
  --menu-bg: rgba(255, 255, 255, .98);

  --sh-hard: 0 3px 0 rgba(13, 27, 26, .10);
  --sh-sm: 0 1px 2px rgba(13, 27, 26, .06), 0 3px 10px rgba(13, 27, 26, .05);
  --sh-md: 0 8px 22px rgba(13, 27, 26, .09), 0 2px 4px rgba(13, 27, 26, .04);
}

/* ---- 语义色：黑夜 ---- */
html[data-theme="dark"] {
  color-scheme: dark;

  --page: #0a1312;
  --surface: #101c1b;
  --surface-alt: #0c1716;
  --sunken: #16221f;

  --ink: #e9f2f1;
  --ink-2: #c6d5d3;
  --muted: #93a8a5;
  --faint: #6f8482;

  --line: #21302e;
  --line-strong: #33443f;
  --chip-bg: #14201e;
  --track: #223230;

  --accent-soft-bg: #0f2b28;
  --accent-soft-brd: #1c4a44;
  --accent-soft-fg: var(--teal-300);
  --accent-text: var(--teal-300);

  --grass-soft-bg: #17260f;
  --grass-soft-brd: #2f4d1e;
  --grass-soft-fg: var(--grass-400);

  --nav-bg: rgba(10, 19, 18, .84);
  --nav-brd: rgba(33, 48, 46, .9);
  --menu-bg: rgba(12, 23, 22, .98);

  --sh-hard: 0 3px 0 rgba(0, 0, 0, .5);
  --sh-sm: 0 1px 2px rgba(0, 0, 0, .4), 0 3px 10px rgba(0, 0, 0, .3);
  --sh-md: 0 8px 22px rgba(0, 0, 0, .45), 0 2px 4px rgba(0, 0, 0, .3);
}

/* 切换主题的一瞬间：给所有元素加一层颜色过渡，避免硬切 */
html.is-theme-switching,
html.is-theme-switching *,
html.is-theme-switching *::before,
html.is-theme-switching *::after {
  transition: background-color .35s ease, border-color .35s ease,
              color .35s ease, fill .35s ease !important;
}

/* --------------------------------------------------------------------------
   2. 基础重置
   -------------------------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }

html {
  scroll-behavior: smooth;
  /* 锚点跳转时避开固定导航栏 */
  scroll-padding-top: calc(var(--nav-h) + 20px);
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--page);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; }
b, strong { font-weight: 700; }

:focus-visible {
  outline: 3px solid var(--teal-400);
  outline-offset: 2px;
  border-radius: var(--r-xs);
}

/* 只给读屏软件看的文字：视觉上不占位 */
.visually-hidden {
  position: absolute;
  width: 1px; height: 1px;
  margin: -1px; padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 200;
  padding: 10px 16px; border-radius: var(--r-sm);
  background: var(--teal-700); color: #fff; font-size: 14px;
  transition: top .18s ease;
}
.skip-link:focus { top: 12px; }

/* --------------------------------------------------------------------------
   3. 通用布局与组件
   -------------------------------------------------------------------------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 24px;
}

/* 首屏是全屏大图，所以下面每一屏都自带上下留白 */
.section { padding: 92px 0; }
.section--alt { background: var(--surface-alt); border-block: 1px solid var(--line); }

.section__head { max-width: 720px; margin-bottom: 40px; }
.section__head--row {
  display: flex; align-items: flex-end; justify-content: space-between;
  gap: 24px; max-width: none;
}
.section__head--row > div { max-width: 640px; }

/* 小标题：等宽 + 大写字距，做出「像素标签」的味道 */
.section__eyebrow {
  display: inline-block;
  margin-bottom: 12px;
  padding: 4px 9px;
  border: 1px solid var(--accent-soft-brd);
  border-radius: var(--r-xs);
  background: var(--accent-soft-bg);
  color: var(--accent-soft-fg);
  font-family: var(--font-mono);
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .14em;
}

.section__title {
  font-size: clamp(24px, 3vw, 34px);
  line-height: 1.3;
  font-weight: 800;
  letter-spacing: -.015em;
}

.section__desc { margin-top: 12px; color: var(--muted); font-size: 16px; }



/* --- 按钮 --- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 12px 22px;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  font-size: 15px; font-weight: 600; line-height: 1.2;
  cursor: pointer; white-space: nowrap;
  transition: transform .12s ease, box-shadow .12s ease,
              background-color .18s ease, border-color .18s ease, color .18s ease;
}
.btn--lg { padding: 15px 28px; font-size: 16px; }
.btn--sm { padding: 9px 14px; font-size: 14px; }
.btn--block { display: flex; width: 100%; }

/* 主按钮：实心 + 硬阴影，按下去会「压扁」一格 */
.btn--primary {
  background: var(--teal-500); color: #fff;
  box-shadow: 0 4px 0 var(--teal-700);
}
.btn--primary:hover { background: var(--teal-400); }
.btn--primary:active { transform: translateY(3px); box-shadow: 0 1px 0 var(--teal-700); }

/* 幽灵按钮：跟随所在区域的文字颜色（首屏深色底上用） */
.btn--ghost {
  background: transparent;
  color: var(--btn-ghost-fg, var(--ink));
  border-color: var(--btn-ghost-bd, var(--line-strong));
}
.btn--ghost:hover { background: var(--btn-ghost-bg, rgba(13, 27, 26, .04)); }

/* 描边按钮：浅色底上的次级操作 */
.btn--outline {
  background: var(--surface); color: var(--ink-2);
  border-color: var(--line);
  box-shadow: var(--sh-hard);
}
.btn--outline:hover { border-color: var(--teal-400); color: var(--accent-text); }

/* --- 头像 --- */
.avatar {
  flex: 0 0 auto;
  display: grid; place-items: center;
  border-radius: var(--r-sm);
  background: var(--teal-500); color: #fff;
  font-weight: 800; letter-spacing: .02em;
  overflow: hidden;
}
.avatar--lg { width: 52px; height: 52px; font-size: 20px; }

/* --- 像素分隔带：一排小方块由蓝绿渐变到草绿 --- */
.pixel-band {
  height: 14px;
  background-image: linear-gradient(90deg, var(--teal-500), var(--grass-500));
  -webkit-mask-image: repeating-linear-gradient(90deg, #000 0 9px, transparent 9px 16px);
  mask-image: repeating-linear-gradient(90deg, #000 0 9px, transparent 9px 16px);
  opacity: .9;
}

/* --------------------------------------------------------------------------
   4. 导航栏
        默认状态：透明地覆盖在首屏大图上，文字用白色
        滚过首屏后（.is-solid）：换成有底色的毛玻璃
   -------------------------------------------------------------------------- */
.nav {
  position: fixed; inset: 0 0 auto 0; z-index: 100;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background-color .3s ease, border-color .3s ease, box-shadow .3s ease;
}
.nav.is-solid {
  background: var(--nav-bg);
  -webkit-backdrop-filter: blur(14px) saturate(1.4);
  backdrop-filter: blur(14px) saturate(1.4);
  border-bottom-color: var(--nav-brd);
}
.nav.is-solid.is-scrolled { box-shadow: 0 6px 20px rgba(13, 27, 26, .08); }

.nav__inner {
  position: relative;
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px;
  height: var(--nav-h);
  width: 100%; max-width: var(--container);
  margin: 0 auto; padding: 0 24px;
}

/* --- LOGO --- */
.logo { display: inline-flex; align-items: center; gap: 10px; }
.logo__mark {
  width: 30px; height: 30px; flex: 0 0 auto;
  /* 源文件是纯白图形：默认（深色底）保持白色，浅色底上反相成深色 */
  filter: drop-shadow(0 1px 3px rgba(0, 0, 0, .35));
  transition: filter .3s ease;
}
.logo__text { font-size: 18px; font-weight: 800; letter-spacing: -.01em; }
.logo__text em { font-style: normal; color: var(--teal-400); }

/* --- 链接 --- */
.nav__links { display: flex; align-items: center; gap: 6px; margin-left: auto; }
.nav__link {
  padding: 9px 14px;
  border-radius: var(--r-sm);
  font-size: 15px; font-weight: 600;
  transition: background-color .16s ease, color .16s ease;
}

/* --- 右侧工具区：主题开关 + 汉堡按钮 --- */
.nav__tools { display: flex; align-items: center; gap: 8px; flex: 0 0 auto; }

.theme-toggle {
  position: relative;
  display: grid; place-items: center;
  width: 40px; height: 40px;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  background: transparent;
  cursor: pointer;
  transition: background-color .18s ease, border-color .18s ease, color .18s ease;
}
.theme-toggle__icons { position: relative; display: block; width: 20px; height: 20px; }
.theme-toggle__icon {
  position: absolute; inset: 0;
  transition: opacity .28s ease, transform .45s var(--ease);
}
/* 白天模式显示「月亮」（点它去黑夜），黑夜模式显示「太阳」 */
.theme-toggle__icon--sun { opacity: 0; transform: rotate(-75deg) scale(.55); }
.theme-toggle__icon--moon { opacity: 1; transform: none; }
html[data-theme="dark"] .theme-toggle__icon--sun { opacity: 1; transform: none; }
html[data-theme="dark"] .theme-toggle__icon--moon { opacity: 0; transform: rotate(75deg) scale(.55); }

/* --- 汉堡按钮（默认隐藏，窄屏出现） --- */
.hamburger {
  display: none;
  flex-direction: column; justify-content: center; gap: 5px;
  width: 44px; height: 44px; padding: 0 10px;
  border: 1px solid transparent;
  border-radius: var(--r-sm);
  background: transparent;
  cursor: pointer;
  transition: background-color .18s ease, border-color .18s ease;
}
.hamburger__bar {
  display: block; height: 2px; width: 100%;
  border-radius: 2px;
  transition: transform .22s ease, opacity .16s ease, background-color .3s ease;
}
/* 展开时：上中下三条变叉 */
.hamburger.is-open .hamburger__bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.hamburger.is-open .hamburger__bar:nth-child(2) { opacity: 0; }
.hamburger.is-open .hamburger__bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* --- 覆盖在首屏大图上时（未变实底）的配色：全部转白 --- */
.nav:not(.is-solid) .logo__text { color: #fff; }
.nav:not(.is-solid) .logo__mark { filter: none; }
.nav:not(.is-solid) .theme-toggle { color: #fff; border-color: rgba(255, 255, 255, .34); background: rgba(255, 255, 255, .10); }
.nav:not(.is-solid) .theme-toggle:hover { background: rgba(255, 255, 255, .2); }
.nav:not(.is-solid) .hamburger { border-color: rgba(255, 255, 255, .34); background: rgba(255, 255, 255, .10); }
.nav:not(.is-solid) .hamburger__bar { background: #fff; }

/* --- 变实底后的配色（跟随主题） --- */
.nav.is-solid .logo__text { color: var(--ink); }
.nav.is-solid .logo__text em { color: var(--teal-500); }
.nav.is-solid .theme-toggle { color: var(--ink-2); border-color: var(--line); background: var(--surface); }
.nav.is-solid .theme-toggle:hover { border-color: var(--teal-400); color: var(--accent-text); }
.nav.is-solid .hamburger { border-color: var(--line); background: var(--surface); }
.nav.is-solid .hamburger__bar { background: var(--ink-2); }
.nav.is-solid .nav__link { color: var(--ink-2); }
.nav.is-solid .nav__link:hover { background: var(--accent-soft-bg); color: var(--accent-text); }

/* 白天主题 + 实底导航（白底）时，把白色 logo 反相成深色 */
html[data-theme="light"] .nav.is-solid .logo__mark { filter: brightness(0) opacity(.88); }

/* 桌面端：是否变实底，只看图案颜色需求，链接文字跟随白色 / 主题色 */
@media (min-width: 861px) {
  .nav:not(.is-solid) .nav__link { color: rgba(255, 255, 255, .88); }
  .nav:not(.is-solid) .nav__link:hover { background: rgba(255, 255, 255, .16); color: #fff; }
}

/* --------------------------------------------------------------------------
   5. Hero 首屏：对比大图铺满整个屏幕
   -------------------------------------------------------------------------- */
.hero {
  position: relative;
  height: 100vh;
  height: 100svh;          /* 移动端浏览器地址栏收起时不跳动 */
  min-height: 520px;
  overflow: hidden;
  background: var(--teal-950);
  /* 首屏永远是深色底：幽灵按钮按深色底配色 */
  --btn-ghost-fg: #d9ece9;
  --btn-ghost-bd: rgba(255, 255, 255, .3);
  --btn-ghost-bg: rgba(255, 255, 255, .1);
}

/* 舞台层：所有「贴边铺满」的东西都放在这里 */
.hero__stage {
  position: absolute; inset: 0; z-index: 1;
  overflow: hidden;
  animation: heroFade 1s var(--ease) backwards;
}

/* --- 拖动对比组件：没有边框、没有圆角、没有阴影，直接铺满 --- */
.compare {
  --pos: 50%;
  position: absolute; inset: 0;
  overflow: hidden;
  cursor: ew-resize;
  /* 横向手势交给 JS 处理，纵向仍然可以正常滚动页面（移动端关键） */
  touch-action: pan-y;
  -webkit-user-select: none; user-select: none;
  -webkit-tap-highlight-color: transparent;
  /* 鼠标悬停在文案框上时，整张对比图糊掉，把注意力让给文字 */
  transition: filter .38s var(--ease), transform .5s var(--ease);
}
.hero.is-focus .compare { filter: blur(11px) saturate(.92); transform: scale(1.03); }

.compare__layer {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover;
  pointer-events: none;
  animation: heroZoom 2s var(--ease) backwards;
  transition: clip-path .18s ease;
}
/* 右侧（Minecraft）图：从左侧按 --pos 裁掉，露出右边的部分 */
.compare__layer--after { clip-path: inset(0 0 0 var(--pos)); }

/* 拖动过程中关掉过渡，保证跟手 */
.compare.is-dragging .compare__layer,
.compare.is-dragging .compare__divider { transition: none; }

.compare__divider {
  position: absolute; top: 0; bottom: 0; left: var(--pos);
  width: 2px; margin-left: -1px;
  background: rgba(255, 255, 255, .94);
  box-shadow: 0 0 0 1px rgba(4, 33, 31, .35), 0 0 26px rgba(0, 0, 0, .5);
  pointer-events: none;
  transition: left .18s ease;
}
.compare__handle {
  position: absolute; top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  display: grid; place-items: center;
  width: 52px; height: 52px;
  border-radius: 50%;
  background: #fff;
  color: var(--teal-700);
  box-shadow: 0 6px 18px rgba(4, 33, 31, .5), 0 0 0 6px rgba(255, 255, 255, .24);
  transition: transform .16s ease;
}
.compare:hover .compare__handle,
.compare.is-dragging .compare__handle { transform: translate(-50%, -50%) scale(1.06); }

/* 首次进入时的「可以拖」暗示：手柄轻轻来回晃 */
.compare:not(.has-touched):not(:hover) .compare__handle {
  animation: handleNudge 2.8s ease-in-out 1.4s infinite;
}

/* 手柄下方的提示药丸 */
.compare__hint {
  position: absolute; left: 0; top: calc(50% + 46px);
  transform: translateX(-50%);
  padding: 5px 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .94);
  color: var(--teal-800);
  font-family: var(--font-mono);
  font-size: 11px; font-weight: 700; letter-spacing: .1em;
  white-space: nowrap;
  box-shadow: 0 8px 22px rgba(2, 12, 11, .38);
  transition: opacity .3s ease, transform .3s ease;
}
.compare.has-touched .compare__hint { opacity: 0; transform: translateX(-50%) translateY(-8px); }

/* --- 压暗层：保证导航栏和文案在任何截图上都看得清 ---
   默认只上 62% 的浓度，背景大图能透出来；
   鼠标悬停 / 键盘聚焦到文案框时补满至 100%，配合图片高斯模糊把注意力让给文字。 */
.hero__scrim {
  position: absolute; inset: 0; z-index: 2; pointer-events: none;
  background:
    /* 顶部：给导航栏压出一块足够暗的底，白色文字才稳 */
    linear-gradient(180deg, rgba(3, 17, 16, .82) 0%, rgba(3, 17, 16, .58) 7%,
                    rgba(3, 17, 16, .24) 19%, transparent 38%),
    /* 底部：托住文案框 */
    linear-gradient(0deg, rgba(3, 17, 16, .86) 0%, rgba(3, 17, 16, .5) 20%, transparent 54%);
  opacity: .62;
  transition: opacity .42s var(--ease);
}
.hero.is-focus .hero__scrim { opacity: 1; }

/* --- 左上 / 右上标签 --- */
.tag {
  position: absolute; top: calc(var(--nav-h) + 18px); z-index: 3;
  padding: 6px 10px;
  border-radius: var(--r-xs);
  font-family: var(--font-mono);
  font-size: 11px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase;
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  pointer-events: none;
  animation: heroIn .9s var(--ease) .5s backwards;
}
.tag--before {
  left: max(24px, calc((100% - var(--container)) / 2));
  background: rgba(4, 33, 31, .68); color: var(--teal-200);
  border: 1px solid rgba(155, 227, 217, .38);
}
.tag--after {
  right: max(24px, calc((100% - var(--container)) / 2));
  background: rgba(60, 122, 32, .78); color: #eaf7dc;
  border: 1px solid rgba(200, 232, 168, .45);
}

/* --- 文案层 --- */
.hero__content {
  position: absolute; inset: 0; z-index: 4;
  display: flex; align-items: flex-end; justify-content: flex-start;
  padding-block: calc(var(--nav-h) + 20px) clamp(30px, 7vh, 78px);
  padding-inline: max(24px, calc((100% - var(--container)) / 2));
  pointer-events: none;    /* 让空白区域仍然可以拖动对比图 */
}

/* 文案框：默认浅浅一层玻璃，保证文字始终清晰；鼠标移上来时加强并模糊底图 */
.hero__panel {
  pointer-events: auto;
  width: 100%;
  max-width: 620px;
  padding: 26px 30px 24px;
  border: 1px solid rgba(255, 255, 255, .16);
  border-radius: 20px;
  background: rgba(3, 18, 17, .46);
  -webkit-backdrop-filter: blur(9px) saturate(1.1);
  backdrop-filter: blur(9px) saturate(1.1);
  box-shadow: 0 24px 64px rgba(2, 12, 11, .46);
  transition: background-color .38s var(--ease), border-color .38s var(--ease),
              transform .38s var(--ease);
}
.hero.is-focus .hero__panel {
  background: rgba(3, 18, 17, .66);
  border-color: rgba(255, 255, 255, .26);
  transform: translateY(-3px);
}

.hero__eyebrow {
  display: inline-block;
  margin-bottom: 14px;
  padding: 4px 10px;
  border: 1px solid rgba(155, 227, 217, .34);
  border-radius: var(--r-xs);
  background: rgba(255, 255, 255, .08);
  color: var(--teal-200);
  font-family: var(--font-mono);
  font-size: 11px; font-weight: 700; letter-spacing: .16em; text-transform: uppercase;
}

.hero__title {
  font-size: clamp(30px, 4.6vw, 58px);
  line-height: 1.14;
  font-weight: 800;
  letter-spacing: -.03em;
  color: #f4fbfa;
  text-shadow: 0 2px 20px rgba(2, 12, 11, .4);
}
.hero__comma { color: var(--teal-300); margin: 0 .12em; }

.hero__en {
  margin-top: 10px;
  color: var(--teal-200);
  font-family: var(--font-mono);
  font-size: clamp(11px, 1.05vw, 14px);
  font-weight: 700;
  letter-spacing: .34em;
  text-transform: uppercase;
}

.hero__sub {
  margin-top: 18px;
  max-width: 30em;
  font-size: clamp(14.5px, 1.2vw, 16.5px);
  line-height: 1.75;
  color: #b6d2ce;
}

.hero__actions {
  margin-top: 24px;
  display: flex; flex-wrap: wrap; gap: 12px;
}

/* 文案逐行入场 */
.hero__panel > * { animation: heroIn .85s var(--ease) backwards; }
.hero__panel > *:nth-child(1) { animation-delay: .14s; }
.hero__panel > *:nth-child(2) { animation-delay: .22s; }
.hero__panel > *:nth-child(3) { animation-delay: .30s; }
.hero__panel > *:nth-child(4) { animation-delay: .38s; }
.hero__panel > *:nth-child(5) { animation-delay: .46s; }
.hero__panel > *:nth-child(6) { animation-delay: .54s; }

/* --------------------------------------------------------------------------
   6. 转化实例：横向滚动列表
   -------------------------------------------------------------------------- */
.gallery__nav { display: flex; gap: 10px; flex: 0 0 auto; }

.arrow {
  display: grid; place-items: center;
  width: 44px; height: 44px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--surface); color: var(--ink-2);
  box-shadow: var(--sh-hard);
  cursor: pointer;
  transition: border-color .16s ease, color .16s ease, transform .1s ease;
}
.arrow:hover:not(:disabled) { border-color: var(--teal-400); color: var(--accent-text); }
.arrow:active:not(:disabled) { transform: translateY(2px); }
.arrow:disabled { opacity: .35; cursor: default; box-shadow: none; }

.gallery__viewport {
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x proximity;   /* 用 proximity，避免和按钮平滑滚动打架 */
  scroll-behavior: smooth;
  scrollbar-width: thin;
  scrollbar-color: var(--line-strong) transparent;
  padding: 6px 4px 16px;
}
.gallery__viewport::-webkit-scrollbar { height: 6px; }
.gallery__viewport::-webkit-scrollbar-thumb {
  background: var(--line-strong); border-radius: 999px;
}
.gallery__viewport::-webkit-scrollbar-track { background: transparent; }

/* 卡片数量少时按内容左对齐排列，不会出现被撑开的大片空白 */
.gallery__list {
  display: flex;
  align-items: stretch;
  justify-content: flex-start;
  gap: var(--gap);
  width: max-content;
  min-width: 100%;
}

.card-shot {
  flex: 0 0 clamp(272px, 31vw, 366px);
  display: flex; flex-direction: column;
  scroll-snap-align: start;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  overflow: hidden;
  box-shadow: var(--sh-sm);
  transition: transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.card-shot:hover {
  transform: translateY(-4px);
  box-shadow: var(--sh-md);
  border-color: var(--line-strong);
}

/* 卡片内的前 / 后对比：左原图，右效果图 */
.card-shot__media {
  display: grid;
  grid-template-columns: 1fr 1fr;
  height: 186px;
  background: var(--sunken);
}
.card-shot__half { position: relative; overflow: hidden; }
.card-shot__half img {
  width: 100%; height: 100%; object-fit: cover;
  transition: transform .55s var(--ease);
}
.card-shot:hover .card-shot__half img { transform: scale(1.06); }
/* 中间那条分界线 */
.card-shot__half--after { border-left: 2px solid var(--surface); }

.card-shot__tag {
  position: absolute; left: 8px; bottom: 8px;
  padding: 3px 7px;
  border-radius: var(--r-xs);
  background: rgba(4, 33, 31, .72);
  color: var(--teal-200);
  font-family: var(--font-mono);
  font-size: 9.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase;
}
.card-shot__tag--after { background: rgba(60, 122, 32, .8); color: #eaf7dc; }

.card-shot__body { padding: 15px 17px 18px; }

.card-shot__city { font-size: 17px; font-weight: 750; letter-spacing: -.01em; }

.card-shot__meta { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.meta-chip {
  padding: 4px 9px;
  border: 1px solid var(--line);
  border-radius: var(--r-xs);
  background: var(--chip-bg);
  color: var(--ink-2);
  font-family: var(--font-mono);
  font-size: 11px; letter-spacing: .03em;
}
.meta-chip--mode {
  border-color: var(--accent-soft-brd); background: var(--accent-soft-bg); color: var(--accent-soft-fg);
}
.meta-chip--block {
  border-color: var(--grass-soft-brd); background: var(--grass-soft-bg); color: var(--grass-soft-fg);
}

.card-shot__note { margin-top: 12px; font-size: 13.5px; color: var(--muted); }

/* --------------------------------------------------------------------------
   7. 使用步骤 + 下载
   -------------------------------------------------------------------------- */
.steps {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--gap);
}
.step {
  position: relative;
  padding: 24px 22px 26px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  box-shadow: var(--sh-sm);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
}
.step:hover { transform: translateY(-3px); border-color: var(--line-strong); box-shadow: var(--sh-md); }
.step__num {
  display: inline-block;
  margin-bottom: 14px;
  padding: 3px 8px;
  border-radius: var(--r-xs);
  background: var(--accent-soft-bg);
  border: 1px solid var(--accent-soft-brd);
  color: var(--accent-soft-fg);
  font-family: var(--font-mono);
  font-size: 12px; font-weight: 700; letter-spacing: .08em;
}
.step__title { font-size: 17px; font-weight: 750; }
.step__text { margin-top: 8px; font-size: 14px; line-height: 1.75; color: var(--muted); }

/* --- 下载面板（深色块，两个主题下都是深底） --- */
.cta {
  display: grid;
  grid-template-columns: 1.35fr 1fr;
  gap: 40px;
  align-items: center;
  margin-top: 44px;
  padding: 38px 40px;
  border-radius: var(--r-lg);
  background: var(--teal-900);
  color: #dfeeeb;
  /* 角落的方块装饰 */
  background-image:
    linear-gradient(135deg, rgba(108, 187, 60, .16) 0 22px, transparent 22px),
    linear-gradient(315deg, rgba(20, 167, 148, .18) 0 26px, transparent 26px);
  background-repeat: no-repeat;
  background-position: left top, right bottom;
}
.cta .section__eyebrow {
  border-color: rgba(155, 227, 217, .3);
  background: rgba(255, 255, 255, .08);
  color: var(--teal-200);
}
.cta__title { margin-top: 6px; font-size: clamp(21px, 2.3vw, 27px); font-weight: 800; color: #f3fbfa; }
.cta__desc { margin-top: 10px; font-size: 15px; color: #9dc0bb; }

.cta__label {
  margin-top: 22px; margin-bottom: 10px;
  font-family: var(--font-mono);
  font-size: 11px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase;
  color: #7fa8a3;
}
.chip-list { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
  padding: 6px 11px;
  border: 1px solid rgba(255, 255, 255, .18);
  border-radius: var(--r-xs);
  background: rgba(255, 255, 255, .06);
  font-family: var(--font-mono);
  font-size: 12px; color: #cfe6e2;
  transition: background-color .18s ease, border-color .18s ease, transform .18s ease;
}
.chip:hover { background: rgba(255, 255, 255, .13); border-color: rgba(255, 255, 255, .34); transform: translateY(-2px); }

.cta__actions { display: flex; flex-direction: column; gap: 12px; }
.cta .btn--outline {
  background: transparent; color: #cfe6e2; border-color: rgba(255, 255, 255, .24);
  box-shadow: none;
}
.cta .btn--outline:hover { border-color: var(--teal-400); color: #fff; }
.cta__meta {
  margin-top: 4px; text-align: center;
  font-family: var(--font-mono);
  font-size: 11.5px; letter-spacing: .04em; color: #7fa8a3;
}

/* --------------------------------------------------------------------------
   8. 用户评价
   -------------------------------------------------------------------------- */
.review { max-width: 800px; margin: 0 auto; }

.review__card {
  position: relative;
  padding: 30px 30px 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-md);
  /* 轮播时的淡入淡出过渡（和 .reveal 不冲突：入场用的是 animation，不是 transition） */
  transition: opacity .28s ease, transform .28s ease;
}
.review__card.is-fading { opacity: 0; transform: translateY(8px); }

/* 卡片左侧的像素装饰条 */
.review__card::before {
  content: "";
  position: absolute; left: 0; top: 26px;
  width: 4px; height: 46px;
  background: linear-gradient(var(--teal-500) 0 50%, var(--grass-500) 50% 100%);
  border-radius: 0 3px 3px 0;
}

.review__top { display: flex; align-items: center; gap: 14px; }
.review__who { flex: 1 1 auto; min-width: 0; }
.review__name { font-size: 16px; font-weight: 750; }
.review__role { font-size: 13px; color: var(--muted); }

.stars { display: flex; gap: 3px; font-size: 15px; letter-spacing: 1px; }
.star { color: var(--track); animation: starPop .4s var(--ease) backwards; }
.star:nth-child(2) { animation-delay: .05s; }
.star:nth-child(3) { animation-delay: .1s; }
.star:nth-child(4) { animation-delay: .15s; }
.star:nth-child(5) { animation-delay: .2s; }
.star--on { color: var(--amber); }

.review__text {
  margin-top: 18px;
  font-size: 16.5px; line-height: 1.85;
  color: var(--ink-2);
  text-wrap: pretty;
}

.review__bar {
  margin-top: 22px;
  height: 3px; border-radius: 999px;
  background: var(--track);
  overflow: hidden;
}
.review__bar > span {
  display: block; height: 100%; width: 100%;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--teal-500), var(--grass-500));
  transition: width .25s linear;
}

.review__controls {
  display: flex; align-items: center; justify-content: space-between;
  gap: 12px; margin-top: 16px;
}
.review__timer {
  font-family: var(--font-mono);
  font-size: 12px; letter-spacing: .04em; color: var(--muted);
}

/* --- 提交表单 --- */
.review-form {
  margin-top: 22px;
  padding: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-lg);
  box-shadow: var(--sh-sm);
}
.review-form__title { font-size: 15px; font-weight: 750; margin-bottom: 14px; }
.review-form__grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 12px;
  margin-bottom: 12px;
}

/* --- 打分：5 颗星，默认点亮第 5 颗 --- */
.rating {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 12px;
}
.rating__label { font-size: 14px; font-weight: 600; color: var(--ink-2); }
/* DOM 里星星是 5→1 排的，靠 row-reverse 反成视觉上的 1→5；
   这样 :checked ~ 才能「一次点亮这颗以及它左侧的所有星星」 */
.rating__stars {
  position: relative;   /* 给下面隐藏的单选框当定位参照，键盘聚焦时页面不会被滚走 */
  display: flex; flex-direction: row-reverse; justify-content: flex-end; gap: 2px;
}
/* 真正的单选框：视觉上藏起来，但键盘和读屏照常工作 */
.rating__input {
  position: absolute;
  width: 1px; height: 1px;
  opacity: 0; pointer-events: none;
}
.rating__star {
  padding: 0 2px;
  color: var(--track);
  font-size: 25px; line-height: 1;
  cursor: pointer;
  transition: color .16s ease, transform .12s ease;
}
/* 选中：这颗和它左侧的一起点亮 */
.rating__input:checked ~ .rating__star { color: var(--amber); }
/* 键盘选中时，把描边画在被隐藏的单选框对应的星星上 */
.rating__input:focus-visible + .rating__star {
  outline: 3px solid var(--teal-400); outline-offset: 2px; border-radius: var(--r-xs);
}
/* 悬停预览：先整组回灰，再点亮悬停的这颗及其左侧 */
.rating__stars:hover .rating__star { color: var(--track); }
.rating__stars:hover .rating__star:hover,
.rating__stars:hover .rating__star:hover ~ .rating__star { color: var(--amber); }
.rating__stars .rating__star:hover { transform: scale(1.14); }

.field {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: var(--r-sm);
  background: var(--chip-bg);
  font-family: inherit; font-size: 15px; color: var(--ink);
  transition: border-color .16s ease, background-color .16s ease;
}
.field::placeholder { color: var(--faint); }
.field:focus {
  outline: none;
  border-color: var(--teal-400);
  background: var(--surface);
  box-shadow: 0 0 0 3px rgba(20, 167, 148, .15);
}
.field--area { resize: vertical; min-height: 88px; line-height: 1.7; }

.review-form__foot {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; margin-top: 14px;
}
.review-form__note { flex: 1 1 auto; font-size: 13.5px; color: var(--muted); }
.review-form__note.is-ok { color: var(--accent-text); font-weight: 600; }
.review-form__note.is-warn { color: var(--warn); font-weight: 600; }
html[data-theme="dark"] .review-form__note.is-warn { color: #f0a05a; }

/* --------------------------------------------------------------------------
   9. 开发人员名单
   -------------------------------------------------------------------------- */
.team {
  display: flex; flex-wrap: wrap; justify-content: center;
  gap: 34px 30px;
}
.team__item { width: 152px; text-align: center; }

.team__avatar {
  display: grid; place-items: center;
  width: 96px; height: 96px;
  margin: 0 auto 14px;
  border-radius: var(--r-md);
  background: var(--teal-500); color: #fff;
  font-size: 34px; font-weight: 800;
  object-fit: cover;
  overflow: hidden;
  box-shadow: var(--sh-hard), inset 0 0 0 1px rgba(255, 255, 255, .22);
  transition: transform .35s var(--ease), box-shadow .35s var(--ease);
}
.team__item:hover .team__avatar {
  transform: translateY(-5px) rotate(-3deg);
  box-shadow: var(--sh-md);
}
.team__name { font-size: 16px; font-weight: 750; }
.team__role {
  margin-top: 3px;
  font-family: var(--font-mono);
  font-size: 12px; letter-spacing: .03em; color: var(--muted);
}

.about__note {
  max-width: 660px; margin: 46px auto 0;
  text-align: center;
  font-size: 12.5px; line-height: 1.8; color: var(--faint);
}

/* --------------------------------------------------------------------------
   10. 页脚
   -------------------------------------------------------------------------- */
.footer {
  padding: 44px 0 40px;
  background: var(--teal-950);
  color: #8fb3ae;
}
.footer__inner {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between;
  gap: 18px 28px;
}
.logo--footer .logo__text { color: #eaf6f4; }
.footer__links { display: flex; flex-wrap: wrap; gap: 6px 20px; font-size: 14px; }
.footer__links a { transition: color .16s ease; }
.footer__links a:hover { color: var(--teal-200); }
.footer__copy { width: 100%; font-size: 12.5px; color: #5f8580; }

/* --------------------------------------------------------------------------
   11. 动效
   -------------------------------------------------------------------------- */

/* 滚动入场：只在 JS 可用时启用（html.js），脚本失效也不会藏内容 */
html.js .reveal { opacity: 0; }
html.js .reveal.is-in {
  opacity: 1;
  animation: revealIn .72s var(--ease) backwards;
  animation-delay: var(--d, 0ms);
}

@keyframes revealIn {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: none; }
}
@keyframes heroIn {
  from { opacity: 0; transform: translateY(20px); }
  to   { opacity: 1; transform: none; }
}
@keyframes heroFade {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes heroZoom {
  from { transform: scale(1.06); }
  to   { transform: none; }
}
@keyframes handleNudge {
  0%, 100% { transform: translate(-50%, -50%) translateX(0); }
  50%      { transform: translate(-50%, -50%) translateX(10px); }
}
@keyframes starPop {
  from { opacity: 0; transform: scale(.5) rotate(-25deg); }
  to   { opacity: 1; transform: none; }
}

/* --------------------------------------------------------------------------
   12. 响应式
   -------------------------------------------------------------------------- */

/* 平板：步骤改成两列 */
@media (max-width: 1024px) {
  .steps { grid-template-columns: repeat(2, 1fr); }
  .cta { grid-template-columns: 1fr; gap: 28px; padding: 32px; }
  .cta__actions { max-width: 340px; }
}

/* 窄屏：导航收进汉堡菜单 */
@media (max-width: 860px) {
  .hamburger { display: flex; }

  /* 折叠面板：绝对定位挂在导航栏下方 */
  .nav__links {
    position: absolute;
    left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    margin-left: 0;
    padding: 6px 16px 14px;
    background: var(--menu-bg);
    -webkit-backdrop-filter: blur(16px);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 16px 30px rgba(13, 27, 26, .16);
    /* 收起状态 */
    opacity: 0; visibility: hidden; transform: translateY(-10px);
    transition: opacity .2s ease, transform .2s ease, visibility .2s;
  }
  .nav__links.is-open { opacity: 1; visibility: visible; transform: none; }

  .nav__link,
  .nav.is-solid .nav__link {
    padding: 15px 6px;
    border-bottom: 1px solid var(--line);
    border-radius: 0;
    font-size: 16px;
    color: var(--ink-2);
  }
  .nav__link:last-child { border-bottom: 0; }
  .nav__link:hover,
  .nav.is-solid .nav__link:hover { background: transparent; color: var(--accent-text); }

  .hero__content { padding-inline: 20px; }
  .hero__panel { max-width: none; }

  .section { padding: 72px 0; }
  .section__head { margin-bottom: 32px; }
  .section__head--row {
    flex-direction: column; align-items: flex-start; gap: 20px;
  }
  .gallery__nav { align-self: flex-end; }

  .review-form__grid { grid-template-columns: 1fr; }
}

/* 手机 */
@media (max-width: 620px) {
  :root { --nav-h: 60px; }

  .container { padding: 0 18px; }

  .hero { min-height: 480px; }
  .hero__content {
    padding-inline: 18px;
    padding-block: calc(var(--nav-h) + 16px) 22px;
  }
  .hero__panel { padding: 20px 20px 18px; border-radius: 16px; }
  .hero__eyebrow { margin-bottom: 10px; font-size: 10px; }
  .hero__title { font-size: clamp(28px, 9vw, 40px); }
  .hero__en { letter-spacing: .22em; }
  .hero__sub { margin-top: 12px; font-size: 14px; }
  .hero__actions { margin-top: 18px; flex-direction: column; align-items: stretch; }
  .hero__actions .btn { width: 100%; }
  .hero__facts { margin-top: 16px; gap: 6px 14px; font-size: 11px; }

  .tag { top: calc(var(--nav-h) + 12px); left: 18px; }
  .tag--after { left: auto; right: 18px; }
  /* 手机上文案框占了下半屏，手柄和提示一起上移，落在露出来的画面上 */
  .compare__handle { top: 40%; width: 44px; height: 44px; }
  .compare__handle svg { width: 18px; height: 18px; }
  .compare__hint { top: calc(40% + 36px); font-size: 10px; padding: 4px 10px; }

  .section { padding: 60px 0; }

  .steps { grid-template-columns: 1fr; }

  .cta { padding: 26px 22px; }

  .gallery__viewport { padding: 4px 2px 14px; }
  .card-shot { flex: 0 0 84%; }
  .card-shot__media { height: 158px; }

  .review__card { padding: 24px 20px 20px; }
  .review__text { font-size: 15.5px; }
  .review-form { padding: 18px; }
  .review-form__foot { flex-direction: column-reverse; align-items: stretch; }
  .review-form__foot .btn { width: 100%; }

  .team { gap: 26px 20px; }
  .team__item { width: 128px; }
  .team__avatar { width: 80px; height: 80px; font-size: 28px; }

  .footer__inner { flex-direction: column; align-items: flex-start; }
}

/* 矮屏笔记本 / 横屏手机：压缩文案区，保证按钮不被挤出首屏 */
@media (max-height: 700px) and (min-width: 861px) {
  .hero__panel { padding: 20px 26px 18px; }
  .hero__title { font-size: clamp(28px, 3.6vw, 44px); }
  .hero__sub { margin-top: 12px; font-size: 14.5px; }
  .hero__actions { margin-top: 18px; }
  .hero__facts { margin-top: 16px; }
}

@media (max-height: 560px) {
  .hero { min-height: 420px; }
  .hero__eyebrow, .hero__facts { display: none; }
  .hero__sub { display: none; }
}

/* 尊重系统的「减少动态效果」设置 */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  html.js .reveal { opacity: 1; }
  html.js .reveal.is-in { animation: none; }
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
  }
  .hero.is-focus .compare { transform: none; }
}
