/* ============================================================================
 * hdd.ldfix.com — 前台样式
 *
 * 设计约束：
 *   1. 零依赖：不引入任何 CSS 框架 / CDN（站点部署在国内，外链 CDN 既慢又不可控）
 *   2. 单文件：整站只此一个样式表，避免多次请求
 *   3. 渠道颜色来自数据库（--ch-color），因此渠道卡片必须用 CSS 变量着色，
 *      不允许在样式里出现任何具体渠道的品牌色
 * ========================================================================== */

/* ---------- 设计令牌 ---------- */
:root {
  --brand: #2468F2;
  --brand-dark: #1b52c9;
  --brand-soft: #eaf0fe;

  --ink: #1a1d24;
  --ink-2: #5a6273;
  --ink-3: #8b93a5;

  --line: #e6e9f0;
  --line-strong: #d3d8e4;

  --surface: #ffffff;
  --surface-2: #f7f8fb;
  --surface-3: #f1f3f8;

  --radius-sm: 8px;
  --radius: 14px;
  --radius-lg: 18px;

  --shadow-sm: 0 1px 2px rgba(22, 30, 50, .06);
  --shadow: 0 2px 8px rgba(22, 30, 50, .07);
  --shadow-lg: 0 10px 30px rgba(22, 30, 50, .09);

  --wrap: 1080px;

  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
          "Hiragino Sans GB", "Microsoft YaHei", "Source Han Sans SC",
          "Noto Sans CJK SC", Roboto, Helvetica, Arial, sans-serif;
  --mono: ui-monospace, SFMono-Regular, Menlo, Consolas,
          "Liberation Mono", "Courier New", monospace;
}

/* ---------- 基础 ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.65;
  color: var(--ink);
  background: var(--surface-2);
  display: flex;
  min-height: 100vh;
  flex-direction: column;
}

h1, h2, h3, h4 { margin: 0; line-height: 1.3; font-weight: 650; }
p { margin: 0; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }
ul { margin: 0; padding: 0; list-style: none; }

code, .mono {
  font-family: var(--mono);
  font-size: .875em;
  word-break: break-all;
}

.muted { color: var(--ink-2); }

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding: 0 20px;
}

.site-main { flex: 1 0 auto; }

/* ---------- 顶栏 ---------- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(255, 255, 255, .88);
  backdrop-filter: saturate(180%) blur(10px);
  border-bottom: 1px solid var(--line);
}

.header-inner {
  display: flex;
  align-items: center;
  gap: 20px;
  /* ⭐ 跟 .brand-mark（64px）联动：页头现在只剩一张 logo（文字已删），
     logo 撑到 64px 后 76px 的页头会显得挤。改 logo 尺寸时同步核这里的高度。 */
  height: 88px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  flex: 0 1 auto;
  min-width: 0;
}
.brand:hover { text-decoration: none; }

/* ⭐ 品牌位现在是**图片**（原来是渐变底 + "BD" 两个字母的占位方块）。
   渐变背景与文字样式必须去掉 —— 留着的话图片下面透出一层蓝底，
   在图片带白底时会看到一圈蓝色描边，小尺寸下很难一眼看出是 CSS 残留。
   object-fit: cover 保证换一张非正方形的图也不会被拉变形。
   ⭐ 改尺寸要同时动两处：本文件的 CSS + 模板 <img> 的 width/height 属性
   （后者只用于告诉浏览器比例、早点预留空位，写错会导致图片加载时布局跳动）。 */
.brand-mark {
  display: block;
  width: 64px;
  height: 64px;
  flex: 0 0 64px;
  border-radius: 18px;
  object-fit: cover;
  background: transparent;
}

/* 关于页顶部的品牌图：比页头大一号，用同一张 256px 资源。 */
.about-logo {
  width: 76px;
  height: 76px;
  flex: 0 0 76px;
  border-radius: 18px;
  object-fit: cover;
  background: #fff;
}

/* 只剩站点名一行（第二行标语已于 2026-09-21 移除），所以不再是 column 布局；
   min-width:0 仍要留 —— 让长站点名能正常收缩而不是撑破页头。 */
.brand-text { min-width: 0; }
/* 站点名跟着 logo 一起放大（logo 64px / 站点名 24px），保持视觉配平。
   ⭐ 与 logo 的 alt 互斥：旁边有这行文字时 alt 必须留空，见 base.html 的注释。 */
.brand-text strong { font-size: 24px; line-height: 1.2; }

.site-nav { margin-left: auto; display: flex; gap: 4px; }
.site-nav a {
  padding: 7px 12px;
  border-radius: var(--radius-sm);
  color: var(--ink-2);
  font-size: 14.5px;
}
.site-nav a:hover { background: var(--surface-3); color: var(--ink); text-decoration: none; }
.site-nav a.is-active { color: var(--brand); background: var(--brand-soft); font-weight: 600; }

.lang-switch {
  flex: 0 0 auto;
  padding: 6px 11px;
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  font-size: 13px;
  color: var(--ink-2);
}
.lang-switch:hover { border-color: var(--brand); color: var(--brand); text-decoration: none; }

/* ---------- 仅读屏可见（视觉隐藏） ---------- */
/*
 * ⭐ 首页用它承载 h1：页面必须有 h1，但用户不想看到原先那块
 *    「蓝点数据工具 / 面向磁盘底层的…」介绍，所以 h1 保留、视觉上不显示。
 *
 * ⚠️ 不要用 display:none 或 visibility:hidden —— 那会把读屏软件也一起屏蔽掉，
 *    等于没写这个 h1。这里靠「缩到 1px + 裁切」让它**物理上仍在文档流里**，
 *    浏览器不显示、读屏照样念。
 */
.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;
}

/* ---------- 分区 ---------- */
.section { padding: 46px 0; }
.section + .section { border-top: 1px solid var(--line); }
.section-download { background: var(--surface); }

.section-head { margin-bottom: 24px; }

.section-title {
  font-size: 21px;
  margin-bottom: 8px;
}
.section-head .section-title { margin-bottom: 6px; }
.section-desc { color: var(--ink-2); font-size: 14.5px; }

.block-title {
  font-size: 15px;
  color: var(--ink-2);
  font-weight: 600;
  margin: 22px 0 10px;
}

/* ---------- 卡片 ---------- */
.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
  gap: 20px;
}

.product-card {
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  transition: box-shadow .18s ease, transform .18s ease;
}
.product-card:hover { box-shadow: var(--shadow-lg); transform: translateY(-2px); }

.product-head { display: flex; gap: 14px; align-items: flex-start; }

.monogram {
  display: grid;
  place-items: center;
  flex: 0 0 46px;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  background: var(--brand-soft);
  color: var(--brand);
  font-size: 20px;
  font-weight: 700;
}
.monogram-lg { flex-basis: 60px; width: 60px; height: 60px; font-size: 26px; border-radius: 16px; }

.product-title { min-width: 0; }
.product-name { font-size: 18px; margin-bottom: 4px; }
.product-name a { color: var(--ink); }
.product-name a:hover { color: var(--brand); text-decoration: none; }
.product-tagline { font-size: 13.5px; color: var(--ink-2); }

.product-latest {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-top: 14px;
  border-top: 1px dashed var(--line);
}

.latest-line { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }

.ver {
  font-family: var(--mono);
  font-size: 14px;
  font-weight: 700;
  color: var(--ink);
}

.badge {
  display: inline-block;
  padding: 1px 8px;
  border-radius: 999px;
  font-size: 11.5px;
  line-height: 1.7;
  font-weight: 600;
}
.badge-current { background: var(--brand-soft); color: var(--brand-dark); }

.pkg-line { display: flex; flex-wrap: wrap; gap: 6px; align-items: baseline; font-size: 13px; }

.card-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-top: auto;
  padding-top: 4px;
}

/* ---------- 按钮 ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 16px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-size: 14.5px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.btn:hover { text-decoration: none; }
.btn-sm { padding: 6px 12px; font-size: 13.5px; }

.btn-primary { background: var(--brand); color: #fff; }
.btn-primary:hover { background: var(--brand-dark); color: #fff; }

.btn-ghost {
  background: var(--surface);
  border-color: var(--line-strong);
  color: var(--ink);
}
.btn-ghost:hover { border-color: var(--brand); color: var(--brand); }

.btn-link {
  background: none;
  padding: 6px 4px;
  color: var(--brand);
  font-weight: 500;
}
.btn-link:hover { text-decoration: underline; }

/* ---------- 变更条目 ---------- */
.changes { display: flex; flex-direction: column; gap: 7px; }

.change {
  display: flex;
  gap: 8px;
  align-items: baseline;
  font-size: 14px;
  color: var(--ink-2);
}
.change-icon { flex: 0 0 auto; font-size: 12.5px; line-height: 1.6; }
.change-type {
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 600;
  color: var(--ct-color, var(--ink-2));
}
.change-text { flex: 1 1 auto; color: var(--ink); }

.rel-more { font-size: 13px; color: var(--ink-3); margin-top: 6px; }

/* ---------- 产品 / 版本页头 ---------- */
.page-hero {
  background: linear-gradient(180deg, #fff 0%, var(--surface-2) 100%);
  border-bottom: 1px solid var(--line);
  padding: 26px 0 34px;
}

.crumb {
  display: flex;
  gap: 8px;
  align-items: center;
  font-size: 13px;
  color: var(--ink-3);
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.crumb a { color: var(--ink-2); }

.page-hero-inner { display: flex; gap: 18px; align-items: flex-start; }
.page-hero-text h1 { font-size: clamp(24px, 3.4vw, 32px); margin-bottom: 8px; letter-spacing: -.3px; }
.page-tagline { color: var(--ink-2); font-size: 16px; }

.page-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-top: 12px;
  font-size: 14px;
}

/* ---------- 下载区 ---------- */
.download-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: baseline;
  margin-bottom: 14px;
  font-size: 14px;
}

.channel-list { display: flex; flex-direction: column; gap: 10px; }

.channel {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 14px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-left: 4px solid var(--ch-color, var(--line-strong));
  border-radius: var(--radius-sm);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.channel:hover { box-shadow: var(--shadow); }

.channel-mark {
  display: grid;
  place-items: center;
  flex: 0 0 38px;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--ch-color, #8b93a5) 12%, #fff);
  color: var(--ch-color, var(--ink-2));
  font-weight: 700;
  font-size: 16px;
  overflow: hidden;
}
.channel-mark img { width: 22px; height: 22px; object-fit: contain; }

.channel-body { flex: 1 1 auto; min-width: 0; }
.channel-name { font-weight: 650; font-size: 15px; }
.channel-note { font-size: 13px; color: var(--ink-2); margin-top: 2px; }

.channel-code {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 7px;
  font-size: 13px;
  flex-wrap: wrap;
}
.channel-code code {
  padding: 1px 7px;
  background: var(--surface-3);
  border: 1px solid var(--line);
  border-radius: 5px;
  font-weight: 600;
  letter-spacing: .4px;
}

.btn-copy {
  padding: 2px 9px;
  font-size: 12px;
  font-family: inherit;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: 5px;
  color: var(--ink-2);
  cursor: pointer;
}
.btn-copy:hover { border-color: var(--brand); color: var(--brand); }
.btn-copy.is-copied { border-color: #639922; color: #639922; }

.channel-action { flex: 0 0 auto; }

.tips {
  margin-top: 22px;
  padding: 16px 18px;
  background: var(--surface-3);
  border-radius: var(--radius-sm);
}
.tips .block-title { margin: 0 0 8px; }
.tips ul { display: flex; flex-direction: column; gap: 6px; }
.tips li {
  position: relative;
  padding-left: 16px;
  font-size: 13.5px;
  color: var(--ink-2);
}
.tips li::before {
  content: "";
  position: absolute;
  left: 2px;
  top: .68em;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--brand);
  opacity: .55;
}

/* ---------- 时间线 ---------- */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 16px;
  position: relative;
}

.rel { padding: 18px 20px; }
.rel:target { box-shadow: 0 0 0 3px var(--brand-soft); }

.rel-head {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}
.rel-ver { font-family: var(--mono); font-size: 17px; font-weight: 700; }
.rel-date { margin-left: auto; font-size: 13.5px; color: var(--ink-3); }

.rel-actions { display: flex; gap: 10px; margin-top: 14px; flex-wrap: wrap; }

.more-link { margin-top: 18px; font-size: 14.5px; }

/* ---------- 变更分组（版本详情页）---------- */
.change-group { margin-bottom: 22px; }
.change-group-head {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 15px;
  margin-bottom: 10px;
  color: var(--ct-color, var(--ink));
}

/* ---------- 键值表 ---------- */
.kv {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 8px 18px;
  font-size: 14px;
}
.kv dt { color: var(--ink-2); }
.kv dd { margin: 0; }

.kv-block {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 16px 18px;
}

/* ---------- 正文 ---------- */
.prose { max-width: 760px; color: var(--ink-2); font-size: 15.5px; }
.prose p + p { margin-top: 12px; }

/* 2026-11-10：产品介绍支持多段——DB 文案以空行分段，pre-line 按换行渲染，
   about 页的 .prose 不加此类（其文案为单段字符串，行为不变） */
.prose-product p { white-space: pre-line; }

/* ---------- 媒体 ---------- */
.media-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 16px;
}
.media-item { margin: 0; }
.media-item img {
  width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  display: block;
  /* 2026-11-10：截图是深色软件界面，直接贴在浅色页面上显得"生硬"，
     补一层浅阴影把图从背景里托出来 */
  box-shadow: var(--shadow-sm);
}
/* 悬停轻微上浮 + 加深阴影，与产品卡片的交互语言保持一致 */
.media-item:hover img { box-shadow: var(--shadow-lg); }
.media-item figcaption { font-size: 13px; color: var(--ink-2); margin-top: 6px; }

.video-embed {
  position: relative;
  aspect-ratio: 16 / 9;
  border-radius: var(--radius-sm);
  overflow: hidden;
  border: 1px solid var(--line);
  background: #000;
}
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }

.doc-list { display: flex; flex-direction: column; gap: 8px; font-size: 15px; }

/* ---------- 空态 ---------- */
.empty-hint {
  padding: 22px;
  text-align: center;
  color: var(--ink-3);
  font-size: 14.5px;
  background: var(--surface-3);
  border-radius: var(--radius-sm);
}

/* ---------- 错误页 ---------- */
.error-page { padding: 80px 0; text-align: center; }
.error-inner { max-width: 560px; }
.error-code {
  font-family: var(--mono);
  font-size: 56px;
  font-weight: 700;
  color: var(--line-strong);
  line-height: 1;
  margin-bottom: 10px;
}
.error-heading { font-size: 24px; margin-bottom: 10px; }
.error-message { color: var(--ink-2); margin-bottom: 24px; }
.error-actions { display: flex; justify-content: center; gap: 10px; }

/* ---------- 页脚 ---------- */
.site-footer {
  flex: 0 0 auto;
  background: var(--surface-3);
  border-top: 1px solid var(--line);
  padding: 30px 0 22px;
  font-size: 13.5px;
}
.footer-main {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  align-items: flex-start;
  justify-content: space-between;
}
.footer-brand { max-width: 560px; }
.footer-brand strong { display: block; color: var(--ink); margin-bottom: 6px; }
.footer-note { color: var(--ink-3); line-height: 1.6; }
.footer-note + .footer-note { margin-top: 4px; }

.footer-filing {
  display: flex;
  flex-direction: column;
  gap: 4px;
  color: var(--ink-3);
}
.footer-filing a { color: var(--ink-2); }

.footer-links { display: flex; flex-direction: column; gap: 4px; }
.footer-links a { color: var(--ink-2); }

.footer-bottom {
  margin-top: 22px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  color: var(--ink-3);
  font-size: 12.5px;
}

/* ---------- 首页产品幻灯片 ---------- */
.section-slides { padding-top: 34px; padding-bottom: 34px; }

.slideshow {
  position: relative;
  border: 1px solid var(--line);
  /* ⭐ 刻意直角（2026-09-21）：轮播图要完整展示产品界面截图。
     这里原本是 `border-radius: var(--radius-lg)`，配合下面的 overflow:hidden
     会把图片**四个角裁成圆弧**，界面上被切掉的正是窗口边角。
     ⚠️ 显式写 0 而不是删掉这行 —— 否则下一个人看到「只有这一块没有圆角」，
     很可能当成漏写又给加回去。同理：不要改成 overflow: visible 来"绕过"裁剪，
     裁剪本身是有用的（挡住切换时相邻幻灯片的溢出）。 */
  border-radius: 0;
  overflow: hidden;
  background: var(--surface);
  box-shadow: var(--shadow);
}

/* ⭐ 固定 16:9 占位：图还没下载完时高度就已经确定了 ——
   否则页面会「先塌成一条、图到了再撑开」，把下面的内容整个顶下去。 */
.slide-viewport {
  position: relative;
  aspect-ratio: 16 / 9;
  background: var(--surface-3);
}

.slide { position: absolute; inset: 0; display: none; }
.slide.is-active { display: block; }

.slide-link { display: block; height: 100%; color: inherit; }
.slide-link:hover { text-decoration: none; }

.slide-img {
  display: block;
  width: 100%;
  height: 100%;
  /* 现有截图是 1.70 / 1.68，统一裁成 16:9；
     取 center top 是因为软件界面的顶部是菜单栏，裁下面比裁上面安全 */
  object-fit: cover;
  object-position: center top;
}

/* 没配图时的兜底：首字渐变块。
   ⚠️ 刻意不用通用占位图 —— 占位图会让「漏配」永远看不出来 */
.slide-img-fallback {
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, var(--brand-soft) 0%, #dde5fb 100%);
  color: var(--brand);
  font-size: clamp(48px, 9vw, 84px);
  font-weight: 700;
}

/* 底部压一层渐变压住图片亮区，保证白字始终看得清 */
.slide-body {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 52px 26px 22px;
  background: linear-gradient(180deg,
    rgba(12, 16, 26, 0) 0%, rgba(12, 16, 26, .70) 60%, rgba(12, 16, 26, .88) 100%);
  color: #fff;
}
.slide-name { font-size: clamp(18px, 2.4vw, 24px); margin: 0 0 4px; }
.slide-tagline { margin: 0 0 10px; font-size: 14px; color: rgba(255, 255, 255, .84); }
.slide-cta {
  display: inline-block;
  font-size: 13.5px;
  font-weight: 600;
  padding-bottom: 2px;
  border-bottom: 1px solid rgba(255, 255, 255, .5);
}
.slide-link:hover .slide-cta { border-bottom-color: #fff; }

/* ⭐ 控件默认隐藏，JS 接管后（.is-ready）才显示 ——
   否则脚本没加载时用户点了箭头毫无反应，比没有箭头更糟 */
.slide-nav, .slide-dots { display: none; }

.slide-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 40px; height: 40px;
  border: none;
  border-radius: 50%;
  background: rgba(255, 255, 255, .92);
  color: var(--ink);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
  box-shadow: var(--shadow);
}
.slide-prev { left: 14px; }
.slide-next { right: 14px; }
.slide-nav:hover { background: #fff; }
.slideshow.is-ready .slide-nav { display: grid; place-items: center; }

.slide-dots {
  position: absolute;
  right: 20px; bottom: 18px;
  gap: 8px;
}
.slideshow.is-ready .slide-dots { display: flex; }

.slide-dot {
  width: 10px; height: 10px;
  padding: 0;
  border: 1px solid rgba(255, 255, 255, .85);
  border-radius: 50%;
  background: rgba(255, 255, 255, .22);
  cursor: pointer;
}
.slide-dot.is-active { background: #fff; }

/* ---------- 首页「适用范围」提示 ---------- */
.section-notice { padding-top: 30px; }

/* 中文站是成品海报图：自带底色与边框，外面只补圆角和阴影，
   不再套一层卡片 —— 否则会出现「卡片里套卡片」的两圈边框 */
.notice-image { line-height: 0; }
.notice-img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
}

/* 英文站走文字版（图里是中文），用告警色卡片靠站点自身的设计令牌呈现 */
.notice-text {
  background: #fffaf0;
  border: 1px solid #f0d9a8;
  border-radius: var(--radius);
  padding: 20px 22px;
}
.notice-title { font-size: 17px; margin: 0 0 8px; }
.notice-body { margin: 0; font-size: 15px; color: var(--ink-2); }
.notice-phone { font-weight: 600; color: var(--brand); white-space: nowrap; }
.notice-phone:hover { color: var(--brand-dark); }

/* ---------- 在线购买页 ----------
 * 只服务 /{lang}/buy 一个页面。
 * 价格、档位名、可用性全部由服务端渲染好，这里只管版式。
 */

.buy-wrap { max-width: 760px; }
.buy-card { padding: 26px; margin-bottom: 18px; }

.buy-field { margin-bottom: 20px; }
.buy-field label { display: block; font-weight: 600; margin-bottom: 6px; color: var(--ink); }
.buy-field input[type="text"],
.buy-field input[type="email"] {
  width: 100%;
  padding: 11px 13px;
  font: inherit;
  color: var(--ink);
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  transition: border-color .15s ease, box-shadow .15s ease;
}
.buy-field input:focus {
  outline: none;
  border-color: var(--brand);
  box-shadow: 0 0 0 3px var(--brand-soft);
}
.buy-hint { margin: 6px 0 0; font-size: 13px; line-height: 1.55; color: var(--ink-3); }

/* 兑换码折叠区：默认收起，避免与主流程（选档 + 扫码）抢注意力 */
.buy-redeem {
  margin-top: 22px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}
.buy-redeem > summary {
  cursor: pointer;
  font-weight: 600;
  color: var(--ink-2);
  list-style-position: outside;
}
.buy-redeem > summary:hover { color: var(--brand); }
.buy-redeem[open] > summary { color: var(--ink); margin-bottom: 4px; }
.buy-redeem .buy-field { margin-top: 14px; }
.buy-redeem .buy-submit { margin-top: 4px; }

.buy-group { margin: 26px 0; }
.buy-tiers {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 12px;
}
.buy-tier {
  display: flex;
  align-items: flex-start;
  gap: 9px;
  padding: 14px;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.buy-tier:hover { border-color: var(--brand); }
.buy-tier input[type="radio"] { margin: 3px 0 0; flex: 0 0 auto; }
/* 选中态用 :checked 的兄弟选择器，不依赖 :has（旧浏览器不支持） */
.buy-tier input[type="radio"]:checked ~ .buy-tier-main .buy-tier-name { color: var(--brand); }
.buy-tier:focus-within { border-color: var(--brand); box-shadow: 0 0 0 3px var(--brand-soft); }
.buy-tier.is-disabled {
  cursor: not-allowed;
  background: var(--surface-2);
  border-style: dashed;
  opacity: .7;
}
.buy-tier.is-disabled:hover { border-color: var(--line-strong); }
.buy-tier-main { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.buy-tier-name { font-weight: 600; color: var(--ink); }
.buy-tier-price { font-size: 20px; font-weight: 700; color: var(--brand); }
.buy-tier-list { font-size: 12px; color: var(--ink-3); text-decoration: line-through; }
.buy-tier-note { flex-basis: 100%; font-size: 12px; color: var(--ink-3); margin-top: 2px; }

.buy-submit { margin-top: 22px; }
.buy-submit .btn { min-width: 220px; }
.buy-error {
  margin: 16px 0 0;
  padding: 11px 13px;
  font-size: 14px;
  color: #b3261e;
  background: #fdecec;
  border-radius: var(--radius-sm);
}

.buy-qr { display: flex; justify-content: center; padding: 10px 0 4px; }
.buy-qr img, .buy-qr canvas { display: block; }
.buy-qr-fallback {
  max-width: 100%;
  padding: 10px;
  font-family: var(--mono);
  font-size: 12px;
  word-break: break-all;
  background: var(--surface-2);
  border-radius: var(--radius-sm);
}
.buy-amount { margin: 6px 0 2px; text-align: center; font-size: 22px; font-weight: 700; color: var(--ink); }
.buy-status { margin: 0 0 4px; text-align: center; font-size: 14px; color: var(--ink-2); }

.buy-code {
  width: 100%;
  padding: 13px;
  font-family: var(--mono);
  font-size: 13px;
  line-height: 1.55;
  color: var(--ink);
  background: var(--surface-2);
  border: 1px solid var(--line-strong);
  border-radius: var(--radius-sm);
  resize: vertical;
  word-break: break-all;
}
.buy-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 14px; }
.buy-warn {
  margin: 14px 0 0;
  padding: 11px 13px;
  font-size: 13px;
  line-height: 1.55;
  color: #8a5a00;
  background: #fff8e6;
  border-radius: var(--radius-sm);
}

/* ---------- 响应式 ---------- */
@media (max-width: 720px) {
  .header-inner { height: auto; padding-top: 10px; padding-bottom: 10px; flex-wrap: wrap; }
  .site-nav { order: 3; margin-left: 0; width: 100%; }
  .section { padding: 34px 0; }
  .product-grid { grid-template-columns: 1fr; }
  .page-hero-inner { flex-direction: column; }
  .channel { flex-wrap: wrap; }
  .channel-action { width: 100%; }
  .channel-action .btn { width: 100%; }
  .rel-date { margin-left: 0; width: 100%; }
  .kv { grid-template-columns: 1fr; gap: 2px 0; }
  .kv dd { margin-bottom: 8px; }

  /* 购买页：小屏单列，提交按钮占满宽度 */
  .buy-card { padding: 18px; }
  .buy-tiers { grid-template-columns: 1fr; }
  .buy-submit .btn { width: 100%; min-width: 0; }

  /* 幻灯片：小屏上箭头压住画面太多，缩一档；文字留白收紧 */
  .slide-nav { width: 34px; height: 34px; font-size: 19px; }
  .slide-prev { left: 8px; }
  .slide-next { right: 8px; }
  .slide-body { padding: 36px 16px 18px; }
  .slide-dots { right: 14px; bottom: 12px; }
}
