/* home.gptstore.vip 样式。数值取自仓库上一级的 DESIGN.md。 */

/* 字体栈第一项 IBM Plex Sans：自托管，只放拉丁子集的 400/500/600/700 四个字重，WOFF2（DESIGN.md「Typography」）。
   文件来自 @fontsource/ibm-plex-sans 5.3.0（出处、大小和 sha256 见 src/assets/fonts/README.md），SIL OFL 1.1 许可，
   许可证和字体一起发布在 /assets/fonts/OFL.txt。unicode-range 照抄 fontsource 的 latin 子集：英文、数字、¥ 这些字符用它，
   中文不在范围里，一律落到后面的系统字体。font-display: swap：字体到之前先用系统字体显示，不会有一段时间看不到字。
   地址写成 /assets/ 下的根路径、不带 ?v=：构建时自动加上文件的内容哈希（tools/build_site.py 的 hash_css_urls），
   换了字体文件地址就跟着变，一年的长期缓存拿不到旧文件。 */
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 400;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-sans-latin-400-normal.woff2?v=3b646991d3) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 500;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-sans-latin-500-normal.woff2?v=0717336fb3) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 600;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-sans-latin-600-normal.woff2?v=8960851d69) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: "IBM Plex Sans";
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url(/assets/fonts/ibm-plex-sans-latin-700-normal.woff2?v=42e7b0c143) format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: only light;   /* 只有浅色版：别让浏览器自动调暗 */
  --primary: #3369ff;
  --primary-pressed: #2454e0;
  --on-primary: #ffffff;
  --ink: #141821;
  --ink-2: #4a5263;
  --ink-3: #636b7c;
  --surface: #ffffff;
  --ground: #f6f7f9;
  --line: #e6e9ef;
  --line-strong: #cfd5df;
  --line-input: #858d9e;
  --disabled: #eef0f4;
  --danger: #d92d20;
  --font: "IBM Plex Sans", "PingFang SC", "HarmonyOS Sans SC", "MiSans", "Microsoft YaHei", "Noto Sans CJK SC", sans-serif;
  --pad: 20px;
  --header-h: 60px;
  --bar-h: 64px;
}

@media (min-width: 768px) {
  :root { --pad: 32px; }
}

@media (min-width: 1024px) {
  :root { --pad: 48px; --header-h: 68px; }
}

@media (min-width: 1200px) {
  :root { --pad: 64px; }
}

*, *::before, *::after { box-sizing: border-box; }
[hidden] { display: none !important; }

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
  /* 触屏点按时不出浏览器自带的半透明高亮块（不用半透明色块叠加），按下的反馈由各元素的 :active 给 */
  -webkit-tap-highlight-color: transparent;
}

/* 跳到锚点或焦点移过去时，正文元素停在吸顶的顶栏下面，多出的 12px 留给焦点框。只给正文（main、footer）：
   不用 html 的 scroll-padding-top，那样焦点移到顶栏里的按钮上时，浏览器以为按钮被挡住了，会把页面往上卷几百像素。
   往下 Tab 时，只露出一截的元素会被卷到刚好露全、贴着屏幕底边：底下也留 12px，焦点框不被底边切掉（底部栏出现时
   留得更多，见 .has-buy-bar） */
main, main *, footer, footer * { scroll-margin-top: calc(var(--header-h) + 12px); scroll-margin-bottom: 12px; }

/* 手机系统或微信把字调大时，文字的行和装文字的盒子都要跟着长高，不然上下两行会叠在一起：行高一律写倍数，不写 px
   （要对齐某个像素值时，取正常字号下正好是那个值的倍数）；装文字的盒子不写 px 定高，写 min-height 或 em（见 .price-slot）。
   顶栏是例外：高度定死（正文的滚动留白按它算），店名放不下时显示省略号 */
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.75;
  color: var(--ink);
  background: var(--surface);
  line-break: strict;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 { margin: 0; text-wrap: balance; }
/* 段落最后一行不留孤字（比如「联系 / 你。」）；不支持的浏览器照常折行 */
p { margin: 0; text-wrap: pretty; }
img, svg { display: block; }
a { color: inherit; }
button, input, textarea { font: inherit; color: inherit; }
/* 触屏上连点按钮、链接、问答、选项时不触发双击缩放；双指缩放照常 */
a, button, summary, label { touch-action: manipulation; }
:focus-visible { outline: 2px solid var(--primary); outline-offset: 2px; }

.wrap {
  width: 100%;
  max-width: calc(1248px + 2 * var(--pad));
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}
/* 手机横屏时避开刘海（viewport-fit=cover）。max()、env() 和 dvh 这些新写法一律放在 @supports 里、外面留旧写法：
   值里有 var() 的声明，不认识它们的旧浏览器（旧版微信内核等）要到计算时才作废，这时不会退回前一条写法，而是按没写处理
   （左右边距会变成 0）。认识 max() 的浏览器都认识 env()，所以 env() 也用这个条件 */
@supports (padding: max(1px, 2px)) {
  .wrap {
    padding-left: max(var(--pad), env(safe-area-inset-left, 0px));
    padding-right: max(var(--pad), env(safe-area-inset-right, 0px));
  }
}

/* 只给读屏软件读的文字 */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 12px;
  top: -80px;
  z-index: 100;
  padding: 8px 14px;
  border-radius: 8px;
  background: var(--ink);
  color: var(--surface);
  text-decoration: none;
}
.skip-link:focus { top: 12px; }

/* 链接与按钮 */
.text-link {
  color: var(--ink);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--line-strong);
  text-underline-offset: 6px;
}
/* 悬停样式都放在 (hover: hover) 里，只给有鼠标的设备：触屏手机点一下之后 :hover 会一直留着，
   按钮看上去像一直按着没松开。按下（:active）和焦点框照常：有悬停样式的元素，按下时也给同样的反馈（触屏上没有悬停） */
.text-link:active { text-decoration-color: var(--ink); }
@media (hover: hover) {
  .text-link:hover { text-decoration-color: var(--ink); }
}
/* 客服联系方式：标签和账号各自不折行（不然「doudou-test」会在连字符处断开，「微信」也可能拆到两行），两者之间的空格
   可以换行：一行放不下时（比如手机把字调大），账号整个挪到下一行，后面的括号跟着它走，不撑出横向滚动 */
.contact-label, .contact-value { white-space: nowrap; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 52px;
  padding: 0 32px;
  border: 0;
  border-radius: 8px;
  font-size: 17px;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
}
.btn-compact { min-height: 44px; padding: 0 16px; font-size: 15px; }
.btn-primary { background: var(--primary); color: var(--on-primary); }
.btn-primary:active { background: var(--primary-pressed); }
@media (hover: hover) {
  .btn-primary:hover { background: var(--primary-pressed); }
}
/* 写在悬停规则后面：提交中不可点的「提交需求」鼠标移上去也保持灰色 */
.btn-disabled, .btn[disabled] { background: var(--disabled); color: var(--ink-3); cursor: not-allowed; }
.btn-secondary {
  min-height: 44px;
  padding: 0 14px;
  font-size: 15px;
  background: var(--surface);
  color: var(--ink);
  border: 1px solid var(--line-input);
}
.btn-secondary:active { background: var(--ground); }
@media (hover: hover) {
  .btn-secondary:hover { background: var(--ground); }
}
.icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--ink);
  cursor: pointer;
}
.buy-slot { display: inline-flex; }

/* 顶栏 */
.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  background: var(--surface);
  border-bottom: 1px solid transparent;
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; height: var(--header-h); }
/* 店名不折行：手机系统或微信把字调大、一行放不下时，末尾显示省略号，不伸出顶栏、不压到「去下单」。
   min-width: 0 让店名和外面的 logo 链接都能缩到比文字窄 */
.brand { display: inline-flex; align-items: center; gap: 8px; min-width: 0; min-height: 44px; color: var(--ink); text-decoration: none; }
.brand-logo { flex: none; width: 28px; height: 28px; }
.brand-name { min-width: 0; overflow: hidden; font-size: 16px; font-weight: 700; letter-spacing: .01em; white-space: nowrap; text-overflow: ellipsis; }
.primary-nav { display: none; }
.header-actions { display: flex; align-items: center; gap: 8px; }
/* 没有 JS 时的「导航」文字链接（样式同 .text-link）；正常字号时和替换它的菜单按钮一样占 44×44，换的时候「去下单」不挪动 */
.nav-jump { display: inline-flex; align-items: center; justify-content: center; min-width: 44px; min-height: 44px; font-size: 15px; }

.mobile-menu {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  z-index: 45;
  /* 横屏手机上屏幕矮，面板可能比屏幕还高：限高，在面板里滚动 */
  max-height: calc(100vh - var(--header-h));
  overflow-y: auto;
  overscroll-behavior: contain;
  background: var(--surface);
  border-bottom: 1px solid var(--line);
}
/* 按去掉浏览器工具栏后的实际高度限高。不认识 dvh 的浏览器用上面的 100vh（原因见 .wrap） */
@supports (max-height: 100dvh) {
  .mobile-menu { max-height: calc(100dvh - var(--header-h)); }
}
.mobile-nav { display: flex; flex-direction: column; padding-top: 8px; padding-bottom: 12px; }
.mobile-nav a {
  display: flex;
  align-items: center;
  min-height: 52px;
  border-top: 1px solid var(--line);
  font-size: 16px;
  color: var(--ink);
  text-decoration: none;
}
.mobile-nav a:first-child { border-top: 0; }
.menu-scrim { position: fixed; top: 0; right: 0; bottom: 0; left: 0; z-index: 35; background: transparent; }

/* .18s 要和 src/js/00-core.js 的 CONFIG.menuMs（180）一致：20-nav.js 收起菜单时等这么久，过渡播完才把面板藏起来 */
@media (prefers-reduced-motion: no-preference) {
  .mobile-menu { opacity: 0; transform: translateY(-4px); transition: opacity .18s ease-out, transform .18s ease-out; }
  .mobile-menu.is-open { opacity: 1; transform: none; }
}

@media (min-width: 1024px) {
  .brand-name { font-size: 17px; }
  .primary-nav { display: flex; align-items: center; gap: 32px; margin-left: auto; }
  .nav-link {
    position: relative;
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    font-size: 15px;
    color: var(--ink-2);
    text-decoration: none;
  }
  .nav-link.is-active, .nav-link:active { color: var(--ink); }
  .nav-link.is-active::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: 8px;
    height: 2px;
    background: var(--ink);
  }
  .header-actions { margin-left: 32px; }
  .nav-jump, .menu-btn, .mobile-menu, .menu-scrim { display: none !important; }
}

@media (min-width: 1024px) and (hover: hover) {
  .nav-link:hover { color: var(--ink); }
}

/* 首屏。和画布 C 一样，开通单放在 ground 底色的面板上：
   - 窄于 1200px：文字在上，下面一条通栏的浅灰色带，开通单放在带里，左边和文字对齐；
   - 1200px 起：左右两栏。左栏文字和页面内容区左对齐；右栏整栏是浅灰面板，上下铺满首屏、右边一直铺到窗口边上，
     开通单在面板里居中。
   整个首屏是一张通栏的网格：两边的列就是页面的左右边距（算法同 .wrap），full 是通栏，content 是内容区。
   只用 CSS：不用 JS 量尺寸，也不用 100vw（Windows 上 100vw 含滚动条的宽度，会多出横向滚动）。 */
.hero {
  --gutter-l: var(--pad);
  --gutter-r: var(--pad);
  display: grid;
  grid-template-columns: [full-start] var(--gutter-l) [content-start] minmax(0, 1fr) [content-end] var(--gutter-r) [full-end];
}
/* 边距至少 --pad，横屏手机上避开刘海，内容区最宽 1248px（这里的 100% 是首屏的宽度）。
   写在 @supports 里：值里有 var() 的声明，浏览器不认识 max() 时要到计算时才作废，不会退回前一行的写法 */
@supports (padding: max(1px, 2px)) {
  .hero {
    --gutter-l: max(var(--pad), env(safe-area-inset-left, 0px), (100% - 1248px) / 2);
    --gutter-r: max(var(--pad), env(safe-area-inset-right, 0px), (100% - 1248px) / 2);
  }
}
.hero-copy { grid-column: content; padding: 40px 0 32px; }
/* 浅灰色带通栏铺满，里面左右留出和页面一样的边距：开通单和上面的文字对齐 */
.hero-panel { grid-column: full; padding: 32px var(--gutter-r) 32px var(--gutter-l); background: var(--ground); }
.hero-title { font-size: 34px; line-height: 1.24; font-weight: 700; }
.hero-title span { display: block; }
.hero-lead { max-width: 34em; margin-top: 20px; font-size: 16px; line-height: 1.75; color: var(--ink-2); }
/* 价格和付款方式各占一行：价格位置预留了宽度，放在同一行时，价格短（比如 ¥29）就会和后面的说明隔开一大段空白 */
.price-line { display: flex; flex-direction: column; align-items: flex-start; gap: 8px; margin-top: 20px; }
/* 价格位置预留高度 36px、宽度放得下「¥199.90 / 月」：从「查看价格」换成价格时版面不动。
   高度写 2.25em（16px 字时正好 36px），字被调大时按比例变高。这里不用 min-height：价格那一行本身比 36px 高一两个像素
   （「/ 月」的行和价格数字的行上下错开一点，一直是伸出这个位置的），用 min-height 会把下面的内容往下推 */
.price-slot { display: inline-flex; align-items: center; min-width: 9em; height: 2.25em; line-height: 2.25; }
/* 可点区域 44px 高，上下各用 -4px 外边距收回来，占的位置还是 36px */
.price-unknown { display: inline-flex; align-items: center; min-height: 44px; margin: -4px 0; font-size: 16px; line-height: 2.25; }
/* 行高 36px：22px 字时 1.6364（电脑版 24px 字时 1.5，见下面）。「/ 月」的行也是 36px（15px 的 2.4 倍）：
   它的行比价格数字的矮，这一行的高度和基线位置就会变 */
.price-known { font-size: 22px; font-weight: 600; line-height: 1.6364; font-variant-numeric: tabular-nums; white-space: nowrap; }
.price-unit { font-size: 15px; font-weight: 400; line-height: 2.4; color: var(--ink-3); }
.price-note { font-size: 15px; color: var(--ink-3); }
.hero-actions { display: flex; flex-direction: column; align-items: stretch; gap: 8px; margin-top: 24px; }
.hero-actions .buy-slot, .hero-actions .btn { width: 100%; }
.hero-more { display: inline-flex; align-items: center; justify-content: center; min-height: 44px; font-size: 15px; }

@media (min-width: 768px) {
  .hero-copy { padding-bottom: 48px; }
  .hero-panel { padding-top: 48px; padding-bottom: 48px; }
  .hero-actions { flex-direction: row; align-items: center; gap: 32px; }
  .hero-actions .buy-slot, .hero-actions .btn { width: auto; }
  .hero-more { justify-content: flex-start; }
  .order-card { max-width: 432px; }
}

@media (min-width: 1024px) {
  .hero-copy { padding-top: 96px; padding-bottom: 64px; }
  .hero-panel { padding-top: 64px; padding-bottom: 64px; }
  .hero-title { font-size: 56px; line-height: 1.22; }
  .hero-lead { margin-top: 24px; font-size: 19px; }
  .price-line { margin-top: 24px; }
  .price-known { font-size: 24px; line-height: 1.5; }
  .hero-actions { margin-top: 32px; }
}

/* 两栏。1200 宽时正好排满：文字栏 544px（56px 的两行标题，最长一行 504px）加间距 64px，面板 528px（开通单 432px，
   两边各 48px）。再宽一些，文字栏和面板各占内容区的一半，面板从窗口正中开始，1440 宽时和画布一样 */
@media (min-width: 1200px) {
  .hero {
    grid-template-columns:
      [full-start] var(--gutter-l)
      [content-start] minmax(608px, 1fr)
      [panel-start] minmax(0, 1fr)
      [content-end] var(--gutter-r)
      [full-end];
  }
  .hero-copy { grid-column: content-start / panel-start; grid-row: 1; align-self: center; padding: 96px 64px 96px 0; }
  .hero-panel {
    grid-column: panel-start / full-end;
    grid-row: 1;
    display: grid;
    grid-template-columns: minmax(0, 432px);
    place-content: center;
    padding: 48px;
  }
}

/* 开通单 */
.order-card {
  margin: 0;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface);
  box-shadow: 0 1px 2px rgba(20, 24, 33, .04), 0 8px 20px rgba(20, 24, 33, .035);
}
.order-card-head { display: flex; align-items: center; justify-content: space-between; }
.order-card-title { font-size: 16px; font-weight: 600; }
.badge { padding: 2px 8px; border: 1px solid var(--line); border-radius: 6px; font-size: 13px; line-height: 1.6; color: var(--ink-3); }
/* 手机系统或微信把字调大、一行放不下时：标签名不折行，值在自己的位置里折行（「m***@gmail.com」这种中间没有断行处的
   也从中间断开），不把整行撑出开通单。单栏也写 minmax(0, 1fr)，原因见 .faq-grid；不认识 anywhere 的旧浏览器用 break-word */
.order-facts { display: grid; grid-template-columns: minmax(0, 1fr); gap: 8px; margin: 16px 0 0; padding-bottom: 16px; border-bottom: 1px solid var(--line); }
.order-fact { display: flex; justify-content: space-between; gap: 16px; font-size: 15px; }
.order-fact dt { flex: none; color: var(--ink-3); }
.order-fact dd { min-width: 0; margin: 0; font-weight: 500; text-align: right; font-variant-numeric: tabular-nums; overflow-wrap: break-word; overflow-wrap: anywhere; }
.timeline { margin: 16px 0 0; padding: 0; list-style: none; }
.tl-step { position: relative; display: grid; grid-template-columns: 22px minmax(0, 1fr); column-gap: 14px; }
.tl-step:not(:last-child) { padding-bottom: 16px; }
/* 圆环、圆心点和连线都用边框画：Windows 高对比度（forced colors）模式会去掉阴影和背景色，边框会留下 */
.tl-step:not(:last-child)::before {
  content: "";
  position: absolute;
  left: 10px;
  top: 26px;
  bottom: 4px;
  border-left: 2px solid var(--line);
}
.tl-dot {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border: 2px solid var(--line-strong);
  border-radius: 999px;
  background-color: var(--surface);
  color: var(--surface);
}
.tl-body { display: flex; flex-direction: column; gap: 2px; }
.tl-title { font-size: 15px; line-height: 1.4667; font-weight: 600; color: var(--ink-3); }   /* 15px 时 22px，和状态圆点一样高 */
.tl-desc { font-size: 13px; line-height: 1.6; color: var(--ink-3); overflow-wrap: break-word; }   /* 开通时长是店主写的，见 .faq-a */
.is-done .tl-dot { border-color: var(--ink); background-color: var(--ink); }
.is-done .tl-title { color: var(--ink); }
.is-current .tl-dot { border-color: var(--primary); }
.is-current .tl-dot::after { content: ""; width: 8px; height: 8px; border: 4px solid var(--primary); border-radius: 999px; }
.is-current .tl-title { color: var(--primary); }

@media (min-width: 1024px) {
  .order-card {
    padding: 28px;
    border-radius: 16px;
    box-shadow: 0 1px 2px rgba(20, 24, 33, .04), 0 16px 40px rgba(20, 24, 33, .07);
  }
}

/* 开通单演示：加载后依次点亮一次，最后停在静态状态（前两步完成、第三步进行中、第四步未开始）。
   关键帧只写起点（「未开始」的样子），终点就是上面的静态样式，只有这一个出处；
   backwards 让等待延迟时先显示起点，播完不留填充，回到静态样式。 */
@media (prefers-reduced-motion: no-preference) {
  .is-done .tl-dot { animation: tl-dot-done .25s ease-out backwards; }
  .is-done .tl-dot svg { animation: tl-show .25s ease-out backwards; }
  .is-done .tl-title { animation: tl-title .25s ease-out backwards; }
  .is-current .tl-dot { animation: tl-dot-current .25s ease-out backwards; }
  .is-current .tl-dot::after { animation: tl-show .25s ease-out backwards; }
  .is-current .tl-title { animation: tl-title .25s ease-out backwards; }
  .tl-step:nth-child(1) .tl-dot, .tl-step:nth-child(1) .tl-dot svg, .tl-step:nth-child(1) .tl-title { animation-delay: .4s; }
  .tl-step:nth-child(2) .tl-dot, .tl-step:nth-child(2) .tl-dot svg, .tl-step:nth-child(2) .tl-title { animation-delay: 1s; }
  .tl-step:nth-child(3) .tl-dot, .tl-step:nth-child(3) .tl-dot::after, .tl-step:nth-child(3) .tl-title { animation-delay: 1.6s; }
}

@keyframes tl-dot-done {
  from { border-color: var(--line-strong); background-color: var(--surface); }
}
@keyframes tl-dot-current {
  from { border-color: var(--line-strong); }
}
@keyframes tl-show {
  from { opacity: 0; }
}
@keyframes tl-title {
  from { color: var(--ink-3); }
}

/* 区块：之间用 1px line 细线分开（三步开通 → 常见问题）；企业采购区换 ground 底色。
   首屏以浅灰色带（1200px 起是右栏的浅灰面板）收尾，它本身就把首屏和三步开通分开了：三步开通顶上不画细线，
   免得细线直接贴在色带的下边上。
   scroll-margin-top：跳到区块（导航、「查看开通流程」）时，区块顶上的细线正好压在顶栏底部的细线下面，不会出现相隔 12px 的
   两条线（区块自己有 48px 以上的内边距，用不着正文元素那多出的 12px） */
.section { padding: 48px 0; border-top: 1px solid var(--line); scroll-margin-top: var(--header-h); }
.hero + .section { border-top: 0; }
.section-band { border-top: 0; background: var(--ground); }
.section-head h2 { font-size: 26px; line-height: 1.3; font-weight: 700; }
.section-head p { margin-top: 8px; font-size: 15px; color: var(--ink-2); }
.sub-title { margin-bottom: 12px; font-size: 17px; line-height: 1.5; font-weight: 600; }

.steps { display: grid; margin: 24px 0 0; padding: 0; list-style: none; }
.step { display: flex; flex-direction: column; gap: 8px; padding: 20px 0; border-top: 1px solid var(--line); }
.step:last-child { padding-bottom: 0; }   /* 最后一步下面没有分隔线，留白交给区块的内边距，免得区块底部多出 20px */
.step-no { font-size: 13px; font-weight: 600; color: var(--ink-3); }
.step h3 { font-size: 17px; line-height: 1.5; font-weight: 600; }
.step p { font-size: 15px; color: var(--ink-2); }
.step .text-link { display: inline-flex; align-items: center; align-self: flex-start; min-height: 44px; font-size: 15px; }

@media (min-width: 1024px) {
  .section { padding: 96px 0; }
  .section-head h2 { font-size: 36px; }
  .section-head p { font-size: 16px; }
  .sub-title { font-size: 18px; }
  .steps { grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 24px; margin-top: 48px; }
  .step { padding: 24px 0 0; }
  .step h3 { font-size: 18px; }
}

/* 常见问题。单栏时也写 minmax(0, 1fr)：默认的列宽会被里面最长的一串断不开的字（比如回答里的网址）撑宽，撑出横向滚动 */
.faq-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 24px; }
.faq-list { border-bottom: 1px solid var(--line); }
.faq-item { border-top: 1px solid var(--line); }
.faq-q {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 52px;
  padding: 12px 0;
  font-size: 17px;
  line-height: 1.5;
  font-weight: 600;
  text-wrap: balance;   /* 问题和标题同一级：折行时两行一样长，不在末行只剩「吗？」 */
  list-style: none;
  cursor: pointer;
}
.faq-q::-webkit-details-marker { display: none; }
.faq-q .chev { flex: none; transition: transform .15s ease-out; }   /* 图标颜色跟随问题文字 */
.faq-item[open] .chev { transform: rotate(180deg); }
/* 回答是店主写的，可能有一长串网址或邮箱：一行放不下时从中间断开（break-word 不改变最小宽度的算法，别的排版不受影响） */
.faq-a { padding: 0 0 20px; font-size: 15px; color: var(--ink-2); overflow-wrap: break-word; }

@media (min-width: 1024px) {
  .faq-grid { grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); column-gap: 24px; }
  .faq-q { font-size: 18px; }
  .faq-a { font-size: 16px; }
}

@media (prefers-reduced-motion: no-preference) {
  @supports (interpolate-size: allow-keywords) and selector(::details-content) {
    :root { interpolate-size: allow-keywords; }
    .faq-item::details-content {
      height: 0;
      overflow: clip;
      transition: height .18s ease-out, content-visibility .18s ease-out allow-discrete;
    }
    .faq-item[open]::details-content { height: auto; }
  }
}

@media (prefers-reduced-motion: reduce) {
  .faq-q .chev { transition: none; }
}

/* 企业采购 */
.business-grid { display: grid; grid-template-columns: minmax(0, 1fr); gap: 48px; margin-top: 48px; }   /* 原因见 .faq-grid */

@media (min-width: 1024px) {
  .business-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); column-gap: 48px; margin-top: 64px; }
}

/* 表单 */
.inquiry { position: relative; }
.form-fallback { font-size: 15px; color: var(--ink-2); }
.inquiry-form { display: grid; gap: 20px; }
.field { min-width: 0; margin: 0; padding: 0; border: 0; }
.field-label { display: block; margin-bottom: 8px; padding: 0; font-size: 15px; font-weight: 500; line-height: 1.4; color: var(--ink); }
.req { margin-left: 8px; font-size: 13px; font-weight: 400; color: var(--ink-3); }
.input {
  display: block;
  width: 100%;
  min-height: 48px;
  padding: 0 14px;
  border: 1px solid var(--line-input);
  border-radius: 8px;
  background: var(--surface);
  font-size: 16px;
  line-height: 1.5;
  color: var(--ink);
  appearance: none;
}
.textarea { height: auto; min-height: 120px; padding: 12px 14px; line-height: 1.6; resize: vertical; }
.input:focus-visible { outline: 2px solid var(--primary); outline-offset: 0; border-color: var(--primary); }
.has-error .input { border-color: var(--danger); }
.field-error { margin-top: 8px; font-size: 13px; line-height: 1.6; color: var(--danger); }
.options { display: flex; flex-wrap: wrap; gap: 0 20px; }
.option { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; font-size: 15px; cursor: pointer; }
.option input { width: 18px; height: 18px; margin: 0; accent-color: var(--primary); }
.hp { position: absolute; left: -10000px; top: auto; width: 1px; height: 1px; overflow: hidden; }
.form-privacy { font-size: 13px; line-height: 1.6; color: var(--ink-3); }
.form-submit { width: 100%; }
.form-failure { display: grid; gap: 12px; padding-top: 8px; }
.result-title { font-size: 16px; line-height: 1.6; font-weight: 600; color: var(--ink); }
.copy-label { font-size: 13px; color: var(--ink-3); }
.copy-text { min-height: 200px; }   /* 字号沿用 .input 的 16px：iOS 聚焦小于 16px 的输入框会放大页面 */
.result-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 16px; font-size: 15px; }
.form-success { padding: 20px 0; }
/* 复制的后备做法用的临时文本框：放到屏幕外（不能用 style 属性，CSP 不允许） */
.copy-buffer { position: fixed; top: 0; left: -10000px; width: 1px; height: 1px; opacity: 0; }

@media (min-width: 768px) {
  .form-submit { width: auto; justify-self: start; }
}

/* 页脚 */
.site-footer {
  padding: 32px 0;
  /* 窄屏时底部留出手机底部栏的位置（栏高加安全区），保证页脚不被挡住；1024px 起没有底部栏 */
  padding-bottom: calc(32px + var(--bar-h));
  border-top: 1px solid var(--line);
  background: var(--ground);
  font-size: 13px;
  line-height: 1.6;
  color: var(--ink-3);
}
/* 安全区（原因见 .wrap）。要写在下面 1024px 的规则前面，电脑上那条才盖得过它 */
@supports (padding: max(1px, 2px)) {
  .site-footer { padding-bottom: calc(32px + var(--bar-h) + env(safe-area-inset-bottom, 0px)); }
}
.footer-inner { display: grid; gap: 12px; }
/* 手机上一行放不下五个链接（窄于 400px 时「兑换入口」会一个落到第二行）：排成三列两行，站内的三个一行，
   站外的两个一行。列宽用 auto：字号被调大时列会变窄、链接文字折行，不会撑出横向滚动 */
.footer-nav { display: grid; grid-template-columns: repeat(3, auto); justify-content: start; column-gap: 20px; }
.footer-nav a { display: inline-flex; align-items: center; min-height: 44px; font-size: 14px; color: var(--ink-2); text-decoration: none; }
.footer-nav a:active { color: var(--ink); text-decoration: underline; }
@media (hover: hover) {
  .footer-nav a:hover { color: var(--ink); text-decoration: underline; }
}
.footer-contact { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; font-size: 14px; color: var(--ink-2); }
.footer-brand { font-weight: 600; color: var(--ink-2); }

@media (min-width: 768px) {
  .footer-nav { display: flex; flex-wrap: wrap; }
}

@media (min-width: 1024px) {
  .site-footer { padding-bottom: 32px; }
}

/* 手机底部常驻栏 */
.buy-bar {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 30;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  min-height: var(--bar-h);
  padding: 8px var(--pad);
  border-top: 1px solid var(--line);
  background: var(--surface);
}
/* 底部避开 iPhone 的横条，横屏时左右避开刘海（原因见 .wrap） */
@supports (padding: max(1px, 2px)) {
  .buy-bar {
    padding-bottom: calc(8px + env(safe-area-inset-bottom, 0px));
    padding-left: max(var(--pad), env(safe-area-inset-left, 0px));
    padding-right: max(var(--pad), env(safe-area-inset-right, 0px));
  }
}
/* 底部栏出现时，用键盘移动焦点或跳到锚点，正文里的目标不会停在栏的下面。和顶栏一样只给正文，不给栏自己 */
.has-buy-bar main, .has-buy-bar main *, .has-buy-bar footer, .has-buy-bar footer * {
  scroll-margin-bottom: calc(var(--bar-h) + 12px);
}
@supports (padding: max(1px, 2px)) {
  .has-buy-bar main, .has-buy-bar main *, .has-buy-bar footer, .has-buy-bar footer * {
    scroll-margin-bottom: calc(var(--bar-h) + 12px + env(safe-area-inset-bottom, 0px));
  }
}
.buy-bar-info { display: flex; flex-direction: column; min-width: 0; }
.buy-bar-name { font-size: 13px; line-height: 1.5; color: var(--ink-3); }
.buy-bar .price-slot { min-width: 0; height: auto; line-height: 1.4; }
.buy-bar .price-known { font-size: 17px; line-height: 1.4; }
.buy-bar .price-unit { line-height: 1.4; }

@media (min-width: 1024px) {
  .buy-bar { display: none !important; }
}

/* 提示条：始终在页面里（屏幕阅读器能播报），没有内容时看不见 */
.toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  z-index: 50;
  width: max-content;   /* 不写的话，left: 50% 让它最多只有半屏宽，max-width 形同虚设 */
  max-width: calc(100% - 40px);
  padding: 12px 16px;
  border-radius: 8px;
  background: var(--ink);
  color: var(--surface);
  font-size: 15px;
  font-weight: 500;
  line-height: 1.4;
  transform: translateX(-50%);
  opacity: 0;
  pointer-events: none;
}
.toast.is-visible { opacity: 1; }
.has-buy-bar .toast { bottom: calc(var(--bar-h) + 16px); }
/* 安全区（原因见 .wrap） */
@supports (padding: max(1px, 2px)) {
  .toast { bottom: calc(24px + env(safe-area-inset-bottom, 0px)); }
  .has-buy-bar .toast { bottom: calc(var(--bar-h) + 16px + env(safe-area-inset-bottom, 0px)); }
}
