/**
 * 官网样式 · 北京布鼠科技有限公司
 *
 * 配色取自 logo（用 canvas 读像素取的）：
 *   藏青 #375571 系    logo 上的字和虚线边
 *   棕   #8B5E3A 系    logo 上的 CMT
 *   亚麻 #F2EEE6       logo 的背景布纹
 *   奶油 #FBF8F2       徽章底色
 *
 * 结构上把首屏做成**深藏青**，下面才是浅色内容区。
 * 这是 B 端官网常见的层次做法：首屏压深显专业，正文回到浅底好读。
 * 徽章是奶油底的圆，压在深色上正好是一块"缝上去的布贴"，对比也够。
 *
 * 动态效果的原则：**只在"进入视口"和"悬停"两处动**，
 * 不做常驻的、抢注意力的循环动画。滚动渐显最多位移 22px、260ms，
 * 到了一眼看不出"在动"，只觉得页面是"长出来"的。
 */

:root {
  --navy:      #375571;
  --navy-deep: #22364E;
  --navy-ink:  #1A2A3D;
  --navy-soft: #5C7A96;
  --brown:     #8B5E3A;
  --tan:       #B48557;
  --linen:     #F2EEE6;
  --cream:     #FBF8F2;
  --ink:       #2E3337;
  --ink-soft:  #5A6068;
  --stitch:    #C9BBA6;
  --line:      #E7DFD1;
  --radius:    16px;
  --wrap:      1140px;
  --ease:      cubic-bezier(.22,.61,.36,1);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 88px; }

body {
  margin: 0;
  background: var(--linen);
  color: var(--ink);
  font: 16px/1.78 system-ui, -apple-system, "PingFang SC", "Hiragino Sans GB",
        "Microsoft YaHei", "Source Han Sans SC", sans-serif;
  -webkit-font-smoothing: antialiased;
  /* 亚麻布纹。透明度压到 .05——超过 .08 就变成格子布了 */
  background-image:
    repeating-linear-gradient(0deg,  rgba(58,90,120,.05) 0 1px, transparent 1px 4px),
    repeating-linear-gradient(90deg, rgba(58,90,120,.05) 0 1px, transparent 1px 4px);
  overflow-x: hidden;
}

img { max-width: 100%; display: block; }
a { color: inherit; text-decoration: none; }

/* <picture> 只是为了给 webp 兜底，不该在布局里多出一层盒子 */
picture { display: contents; }

/* ============================================================ 滚动渐显 */

/**
 * ⚠️ 初始隐藏态挂在 html.js 下，不是无条件挂的。
 *
 * 写成 `.reveal{opacity:0}` 的话，只要 JS 没跑起来（断网、脚本报错、
 * 被扩展拦了），这些元素就**永久不可见**——用户看到半页空白，
 * 搜索引擎抓到的也是空页面。默认可见、由 JS 去关灯，才是安全的顺序。
 */
html.js .reveal {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .6s var(--ease), transform .6s var(--ease);
  will-change: opacity, transform;
}
html.js .reveal.in { opacity: 1; transform: none; }
/* 同组元素错开出场，比一起冒出来自然 */
html.js .reveal[data-delay="1"] { transition-delay: .09s; }
html.js .reveal[data-delay="2"] { transition-delay: .18s; }
html.js .reveal[data-delay="3"] { transition-delay: .27s; }
html.js .reveal[data-delay="4"] { transition-delay: .36s; }

/* ============================================================ 按钮 */

.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 13px 28px; border-radius: 999px;
  font-size: 15px; font-weight: 600; letter-spacing: .02em;
  border: 1.5px solid transparent;
  transition: transform .2s var(--ease), background .2s, box-shadow .2s, border-color .2s;
}
.btn-light { background: var(--cream); color: var(--navy-deep); }
.btn-light:hover { transform: translateY(-2px); box-shadow: 0 10px 26px rgba(0,0,0,.24); }
.btn-line { border-color: rgba(251,248,242,.42); color: var(--cream); }
.btn-line:hover { border-color: var(--cream); background: rgba(251,248,242,.10); transform: translateY(-2px); }

/* ============================================================ 页头 */

.hd {
  position: fixed; inset: 0 0 auto 0; z-index: 60;
  transition: background .3s var(--ease), box-shadow .3s var(--ease), backdrop-filter .3s;
}
.hd-in {
  max-width: var(--wrap); margin: 0 auto;
  padding: 16px 24px;
  display: flex; align-items: center; gap: 24px;
}
.hd-brand { display: flex; align-items: center; gap: 11px; }
/* 形状由图片自己带（webp/png 有 alpha）：不用 border-radius 硬切，
   硬切会把徽章最外圈那圈虚线缝线削掉 */
.hd-name { display: flex; flex-direction: column; line-height: 1.16; }
.hd-name b { font-size: 16px; letter-spacing: .04em; color: var(--cream); transition: color .3s; }
.hd-name i { font-style: normal; font-size: 10px; letter-spacing: .2em; color: rgba(251,248,242,.62); transition: color .3s; }

.hd-nav { margin-left: auto; display: flex; align-items: center; gap: 28px; font-size: 15px; }
.hd-nav > a { color: rgba(251,248,242,.86); transition: color .25s; position: relative; }
.hd-nav > a:not(.hd-cta)::after {
  content: ""; position: absolute; left: 0; right: 100%; bottom: -5px; height: 1.5px;
  background: var(--tan); transition: right .28s var(--ease);
}
.hd-nav > a:not(.hd-cta):hover::after { right: 0; }
.hd-nav > a:hover { color: var(--cream); }

.hd-cta {
  padding: 9px 20px; border-radius: 999px;
  background: var(--cream); color: var(--navy-deep) !important;
  font-weight: 600; font-size: 14px;
  transition: transform .2s var(--ease), box-shadow .2s;
}
.hd-cta:hover { transform: translateY(-1px); box-shadow: 0 8px 20px rgba(0,0,0,.2); }

/* 滚过首屏后页头变实底——深底上的浅字在浅底内容区会看不清 */
.hd.solid {
  background: rgba(242,238,230,.9);
  backdrop-filter: blur(12px);
  box-shadow: 0 1px 0 var(--line), 0 6px 24px rgba(34,54,78,.06);
}
.hd.solid .hd-name b { color: var(--navy); }
.hd.solid .hd-name i { color: var(--brown); }
.hd.solid .hd-nav > a { color: var(--ink-soft); }
.hd.solid .hd-nav > a:hover { color: var(--navy); }
.hd.solid .hd-cta { background: var(--navy); color: var(--cream) !important; }

.hd-burger { display: none; background: none; border: 0; padding: 8px; cursor: pointer; }
.hd-burger span {
  display: block; width: 22px; height: 2px; margin: 5px 0;
  background: var(--cream); border-radius: 2px;
  transition: transform .28s var(--ease), opacity .2s, background .3s;
}
.hd.solid .hd-burger span { background: var(--navy); }

/* ============================================================ 首屏 */

.hero {
  position: relative;
  background: linear-gradient(168deg, #22364E 0%, #1A2A3D 58%, #16232F 100%);
  color: var(--cream);
  padding: 148px 0 0;
  overflow: hidden;
}

/* 底色上飘三团暖光。纯装饰，aria-hidden */
.hero-bg { position: absolute; inset: 0; pointer-events: none; }
.orb {
  position: absolute; border-radius: 50%;
  filter: blur(70px); opacity: .5;
  animation: drift 22s ease-in-out infinite;
}
.orb-1 { width: 460px; height: 460px; top: -140px; right: -80px; background: #3E6486; }
.orb-2 { width: 380px; height: 380px; bottom: -160px; left: -100px; background: #6B4A2E; animation-delay: -7s; }
.orb-3 { width: 300px; height: 300px; top: 38%; left: 46%; background: #375571; animation-delay: -14s; opacity: .34; }
@keyframes drift {
  0%, 100% { transform: translate3d(0, 0, 0) scale(1); }
  50%      { transform: translate3d(26px, -30px, 0) scale(1.09); }
}

/* 极淡的网格，给深底一点"技术感"的肌理 */
.grid-veil {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(251,248,242,.045) 1px, transparent 1px),
    linear-gradient(90deg, rgba(251,248,242,.045) 1px, transparent 1px);
  background-size: 62px 62px;
  mask-image: radial-gradient(ellipse 78% 68% at 50% 34%, #000 32%, transparent 78%);
  -webkit-mask-image: radial-gradient(ellipse 78% 68% at 50% 34%, #000 32%, transparent 78%);
}

.hero-in {
  position: relative; z-index: 1;
  max-width: var(--wrap); margin: 0 auto;
  padding: 0 24px 84px;
  display: grid; grid-template-columns: 1.12fr .88fr;
  align-items: center; gap: 56px;
}
.eyebrow {
  margin: 0 0 18px; font-size: 13px; font-weight: 600;
  letter-spacing: .16em; color: var(--tan);
}
.hero h1 {
  margin: 0 0 22px;
  font-size: clamp(32px, 4.8vw, 54px);
  line-height: 1.24; letter-spacing: .01em; font-weight: 800;
}
/* 标题里那半句用暖色提一下 */
.hero h1 .hl { color: var(--tan); position: relative; }
.hero h1 .hl::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: .06em; height: .30em;
  background: rgba(180,133,87,.20); border-radius: 3px; z-index: -1;
}
.lede {
  margin: 0 0 34px; font-size: 17px; line-height: 1.9;
  color: rgba(251,248,242,.76); max-width: 30em;
}
.hero-cta { display: flex; gap: 14px; flex-wrap: wrap; }

/* 首屏右侧：会缓慢浮动的公司徽章 */
.hero-art { display: flex; justify-content: center; }
.badge-float { animation: float 7s ease-in-out infinite; }
.badge-float img {
  width: clamp(200px, 24vw, 290px); height: auto;
  /*
   * 这里原来是 border-radius:50% + box-shadow：
   * 图是带奶油底的方图，靠 CSS 切圆、靠 box-shadow 在深色 hero 上压出投影。
   * 现在图自带 alpha，圆由图片说了算；阴影也换成 drop-shadow——
   * box-shadow 是给**盒子**打阴影的，方图换成透明图之后会在深蓝底上留一个方块影子。
   */
  filter: drop-shadow(0 20px 30px rgba(0, 0, 0, .5)) drop-shadow(0 0 1px rgba(251, 248, 242, .3));
}
@keyframes float {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-13px); }
}

/* 首屏底部那条业务带 */
.hero-strip {
  position: relative; z-index: 1;
  max-width: var(--wrap); margin: 0 auto;
  padding: 0 24px;
  display: grid; grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid rgba(251,248,242,.14);
}
.hs-item {
  padding: 26px 4px 30px;
  display: flex; flex-direction: column; gap: 4px;
  border-right: 1px solid rgba(251,248,242,.10);
  transition: background .25s;
}
.hs-item:last-child { border-right: 0; }
.hs-item:hover { background: rgba(251,248,242,.05); }
.hs-item b { font-size: 16px; color: var(--cream); letter-spacing: .02em; }
.hs-item span { font-size: 13.5px; color: rgba(251,248,242,.56); }
.hs-item::before {
  content: "→"; color: var(--tan); font-size: 13px;
  position: absolute; opacity: 0; transition: opacity .25s, transform .25s var(--ease);
}
.hs-item { position: relative; }
.hs-item:hover::before { opacity: 1; transform: translateX(3px); }

/* ============================================================ 通用区块 */

.sec { max-width: var(--wrap); margin: 0 auto; padding: 88px 24px; }
.sec-head { margin-bottom: 46px; }
.sec-h {
  margin: 0 0 10px;
  font-size: clamp(24px, 2.8vw, 34px);
  color: var(--navy); font-weight: 800; letter-spacing: .01em;
}
.sec-sub { margin: 0; color: var(--ink-soft); font-size: 16px; }

.sec-alt {
  background: rgba(251,248,242,.72);
  border-top: 1px dashed var(--stitch);
  border-bottom: 1px dashed var(--stitch);
  max-width: none;
  padding-left: max(24px, calc((100vw - var(--wrap)) / 2 + 24px));
  padding-right: max(24px, calc((100vw - var(--wrap)) / 2 + 24px));
}

/* 深色区块：案例那一段 */
.sec-dark {
  max-width: none;
  background: linear-gradient(160deg, #22364E, #1A2A3D);
  color: var(--cream);
  padding-left: max(24px, calc((100vw - var(--wrap)) / 2 + 24px));
  padding-right: max(24px, calc((100vw - var(--wrap)) / 2 + 24px));
}
.sec-dark .sec-h { color: var(--cream); }
.sec-dark .sec-sub { color: rgba(251,248,242,.66); }

/* ============================================================ 业务范围 */

.svc { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }

.svc-card {
  position: relative;
  background: var(--cream);
  border: 1.5px solid var(--line);
  border-radius: var(--radius);
  padding: 30px 26px 28px;
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
}
/**
 * 缝线：卡片内缩 8px 再画一圈虚线——logo 上那圈藏青虚线边，
 * 放到卡片尺度就是"缝份"。这是整套视觉里最有辨识度的一笔。
 */
.svc-card::after {
  content: ""; position: absolute; inset: 8px;
  border: 1px dashed var(--stitch);
  border-radius: calc(var(--radius) - 8px);
  pointer-events: none; opacity: .7;
  transition: opacity .25s;
}
.svc-card:hover {
  transform: translateY(-4px);
  border-color: var(--navy-soft);
  box-shadow: 0 18px 40px rgba(55,85,113,.13);
}
.svc-card:hover::after { opacity: 1; }

.svc-no {
  display: inline-block; margin-bottom: 14px;
  font-size: 12px; font-weight: 700; letter-spacing: .14em;
  color: var(--brown);
}
.svc-card h3 { margin: 0 0 12px; font-size: 20px; color: var(--navy); font-weight: 800; }
.svc-lead { margin: 0 0 14px; font-size: 15.5px; line-height: 1.8; color: var(--navy-deep); font-weight: 600; }
.svc-card > p { margin: 0 0 18px; font-size: 14.5px; line-height: 1.85; color: var(--ink-soft); }
.svc-card b { color: var(--navy); }
.svc-list { margin: 0; padding: 0; list-style: none; display: grid; gap: 9px; }
.svc-list li { position: relative; padding-left: 20px; font-size: 14px; color: var(--ink-soft); }
.svc-list li::before {
  content: ""; position: absolute; left: 2px; top: .66em;
  width: 6px; height: 6px; border-radius: 50%; background: var(--tan);
}

/* ============================================================ 案例 */

.case {
  display: grid; grid-template-columns: 1fr 220px; gap: 48px;
  background: rgba(251,248,242,.055);
  border: 1px solid rgba(251,248,242,.14);
  border-radius: 22px;
  padding: 42px 44px;
  align-items: center;
}
.case-tags { display: flex; gap: 10px; margin-bottom: 16px; }
.tag {
  font-size: 12px; letter-spacing: .06em; padding: 4px 12px; border-radius: 999px;
  background: rgba(180,133,87,.18); color: var(--tan);
  border: 1px solid rgba(180,133,87,.34);
}
.case h3 { margin: 0 0 22px; font-size: clamp(21px, 2.4vw, 27px); color: var(--cream); font-weight: 800; }

.case-dl { margin: 0 0 26px; display: grid; grid-template-columns: 64px 1fr; gap: 12px 18px; }
.case-dl dt {
  font-size: 13px; font-weight: 700; letter-spacing: .1em;
  color: var(--tan); padding-top: .28em;
}
.case-dl dd { margin: 0; font-size: 15px; line-height: 1.85; color: rgba(251,248,242,.80); }

.case-cta { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.case-note { font-size: 13.5px; color: rgba(251,248,242,.55); }

.case-side { text-align: center; }
.case-qr {
  background: #fff; padding: 12px; border-radius: 16px;
  box-shadow: 0 14px 34px rgba(0,0,0,.3);
  transition: transform .25s var(--ease);
}
.case-qr:hover { transform: scale(1.04); }
.case-qr-cap { display: block; margin-top: 12px; font-size: 13px; letter-spacing: .1em; color: var(--tan); }

/* ============================================================ 关于 */

/*
 * 版式说明：原来是"左边一段说明 + 右边竖着一列卡片"。
 * 卡片从 3 张变成 4 张（把灵活、快、定制、AI 各写一条）之后，
 * 右边那一列比左边高出一大截，留白很难看，所以改成：
 * 说明整段在上（限宽，中文一行别超过 40 字），四条优势在下面排 2×2。
 */
/*
 * 核心 + 三个点的连线。
 *
 * 做法：不用 SVG、不用 JS，纯 CSS 画"组织结构图"那种连线——
 * 核心下面一段竖线、一排横线、每张卡片上面一小段竖线，
 * 三段接在一起就是一张网。
 *
 * 为什么用 repeating-linear-gradient 而不是 `border: dashed`：
 * **border 的虚线不能动**。用背景渐变画虚线，再动 background-position，
 * 虚线就会一段一段往前走，看着像针脚在被缝出来——正好是这品牌的母题。
 */
.about-map { --stem: 26px; }

.about-hub {
  position: relative;
  width: max-content; max-width: 100%; margin: 0 auto;
  padding: 13px 32px; border-radius: 999px;
  border: 1.5px dashed var(--stitch);
  background: var(--cream); color: var(--navy);
  /* 「AI based」是标记不是句子：字距拉开、字号放大，不做任何解释 */
  font-size: clamp(19px, 2vw, 23px); font-weight: 800; letter-spacing: .16em;
  box-shadow: 0 8px 22px rgba(55, 85, 113, .07);
  animation: hub-pulse 2.8s ease-out infinite;
}
@keyframes hub-pulse {
  0%, 100% { box-shadow: 0 8px 22px rgba(55, 85, 113, .07), 0 0 0 0 rgba(92, 122, 150, .22); }
  55%      { box-shadow: 0 8px 22px rgba(55, 85, 113, .07), 0 0 0 12px rgba(92, 122, 150, 0); }
}

/* 核心往下的一竖 */
.about-hub::after {
  content: ''; position: absolute; left: 50%; top: 100%;
  width: 2px; height: var(--stem); margin-left: -1px;
  background-image: repeating-linear-gradient(to bottom, var(--stitch) 0 6px, transparent 6px 12px);
  animation: stitch-down .85s linear infinite;
}

/* 两段缝线的间距：卡片上留一个 --stem，正好让横线落在正中间 */
.about-cards {
  position: relative; margin-top: calc(var(--stem) * 2);
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 16px;
}
/* 横线：从第一张卡的中心连到第三张卡的中心 */
.about-cards::before {
  content: ''; position: absolute; top: calc(var(--stem) * -1); height: 2px;
  left: calc(100% / 6); right: calc(100% / 6);
  background-image: repeating-linear-gradient(to right, var(--stitch) 0 6px, transparent 6px 12px);
  animation: stitch-right .85s linear infinite;
}
/* 每张卡片往上的一小竖 */
.ac::before {
  content: ''; position: absolute; left: 50%; top: calc(var(--stem) * -1);
  width: 2px; height: var(--stem); margin-left: -1px;
  background-image: repeating-linear-gradient(to bottom, var(--stitch) 0 6px, transparent 6px 12px);
  animation: stitch-down .85s linear infinite;
}
/* 12px = 一个「6px 实 + 6px 空」的周期，所以位移一个周期就能无缝循环 */
@keyframes stitch-down  { to { background-position: 0 12px; } }
@keyframes stitch-right { to { background-position: 12px 0; } }

.ac {
  position: relative;
  background: var(--cream); border: 1.5px solid var(--line);
  border-radius: 14px; padding: 20px 22px;
  transition: transform .22s var(--ease), border-color .22s, box-shadow .22s;
}
/* 网格排列下横向位移会显得歪，改成往上抬一点 */
.ac:hover { transform: translateY(-3px); border-color: var(--navy-soft); box-shadow: 0 10px 26px rgba(55,85,113,.10); }
.ac h4 { margin: 0 0 7px; font-size: 16px; color: var(--navy); font-weight: 700; }
.ac p { margin: 0; font-size: 14px; line-height: 1.8; color: var(--ink-soft); }
.ac b { color: var(--navy); }

/*
 * 服务对象那一句。用暖色的缝线虚线起头——和页尾那句"哪些不做"是同一种做法，
 * 让它在版式上被认出来是"一句定位"，而不是又一段正文。
 */
.about-who {
  margin: 0 0 26px; max-width: 34em;
  padding: 12px 0 12px 18px;
  border-left: 3px dashed var(--tan);
  font-size: 16.5px; line-height: 1.85; color: var(--navy-deep); font-weight: 600;
}
.about-who b { color: var(--navy); }

/* 收尾那句"哪些不做"：用缝线感的虚线包一下，和整站的针脚母题一致 */
.about-note {
  margin: 24px 0 0; max-width: 940px;
  padding: 14px 18px; border-left: 3px dashed var(--navy-soft);
  background: rgba(251, 248, 242, .75); border-radius: 0 12px 12px 0;
  font-size: 14px; line-height: 1.85; color: var(--ink-soft);
}

/* ============================================================ 联系 */

.contact { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 22px; }
/*
 * 四张卡里，邮箱和电话是"读"的（地址长，要整行宽），
 * 企业微信和钉钉是"扫"的（方形，并排正好）。
 * 所以网格永远是两列，读的两张自己占满一行 —— 三种屏宽下版式一致，
 * 不必每个断点各写一遍。
 */
.ct:not(.ct-qr) { grid-column: 1 / -1; }
.ct {
  position: relative; display: flex; flex-direction: column; gap: 7px;
  padding: 28px 30px;
  background: var(--cream); border: 1.5px solid var(--line);
  border-radius: var(--radius);
  transition: transform .25s var(--ease), box-shadow .25s, border-color .25s;
}
.ct::after {
  content: ""; position: absolute; inset: 8px;
  border: 1px dashed var(--stitch); border-radius: calc(var(--radius) - 8px);
  pointer-events: none; opacity: .7;
}
.ct:hover { transform: translateY(-4px); border-color: var(--navy-soft); box-shadow: 0 18px 40px rgba(55,85,113,.13); }
.ct-kind { font-size: 12px; font-weight: 700; letter-spacing: .16em; color: var(--brown); }
.ct-value {
  font-size: clamp(18px, 2.1vw, 23px); font-weight: 800;
  color: var(--navy); letter-spacing: .01em;
  overflow-wrap: anywhere;   /* 邮箱很长，窄屏要能断，否则撑破卡片 */
}
.ct[href^="tel"] .ct-value { font-variant-numeric: tabular-nums; }
.ct-hint { font-size: 13.5px; color: var(--ink-soft); }

/*
 * 二维码名片（企业微信 / 钉钉）。
 *
 * 两张卡并排，码是**扫描用**的，不是插图，所以有三条硬约束：
 *   1. 码四周必须留白（二维码规范的静区）。图片本身已经带了一圈，
 *      这里再给 12px 白底 —— 屏幕反光/摩尔纹的情况下这点白很值钱。
 *   2. **不要在码上叠任何东西**：`.ct` 那个虚线内框会压进静区，这里去掉。
 *   3. 不缩放、不变形：写死 188px 并给 width/height 属性，
 *      否则窄屏被压扁之后模块糊成一片，扫不出来。
 * 素材是 `scripts/make-contact-qr.mjs` 裁的，裁完用系统 Vision 解过码（见那个脚本）。
 */
.ct-qr { align-items: center; text-align: center; gap: 12px; cursor: default; padding: 22px 18px; }
.ct-qr::after { content: none; }
.qr-tile {
  display: block; background: #fff; padding: 12px;
  border: 1px solid var(--line); border-radius: 16px;
  box-shadow: 0 8px 22px rgba(55,85,113,.08);
  line-height: 0;            /* 去掉 img 下面的基线空隙 */
}
.qr-tile img { display: block; width: 188px; max-width: 100%; height: auto; aspect-ratio: 1 / 1; }
/* 码本身不参与悬停位移，整个站点在关掉动效时也不动它 */
@media (prefers-reduced-motion: reduce) { .ct-qr { transition: none; } }

/* ============================================================ 页脚 */

.ft { background: var(--navy-ink); color: rgba(251,248,242,.72); padding: 52px 0 40px; }
.ft-in { max-width: var(--wrap); margin: 0 auto; padding: 0 24px; }
.ft-top {
  display: flex; align-items: center; gap: 30px; flex-wrap: wrap;
  padding-bottom: 28px; border-bottom: 1px solid rgba(251,248,242,.10);
}
.ft-brand { display: flex; align-items: center; gap: 13px; }
/* 形状由图片自己带（webp/png 有 alpha）：不用 border-radius 硬切，
   硬切会把徽章最外圈那圈虚线缝线削掉 */
.ft-brand b { display: block; font-size: 16px; color: var(--cream); letter-spacing: .03em; }
.ft-brand span { display: block; font-size: 12.5px; color: rgba(251,248,242,.5); margin-top: 3px; }
.ft-nav { margin-left: auto; display: flex; gap: 24px; font-size: 14.5px; flex-wrap: wrap; }
.ft-nav a { color: rgba(251,248,242,.7); transition: color .2s; }
.ft-nav a:hover { color: var(--tan); }

.ft-bottom { padding-top: 26px; font-size: 13.5px; line-height: 2; }
.ft-info { margin: 0 0 6px; font-size: 14.5px; }
.ft-info a { color: var(--cream); }
.ft-info a:hover { color: var(--tan); }
.ft-info .sep { margin: 0 12px; color: rgba(251,248,242,.26); }
.ft-info .wx { color: rgba(251,248,242,.5); font-size: 13px; }
.ft-copy { margin: 0; color: rgba(251,248,242,.52); }
/* 备案号：法定公示项，字要比正文更小更淡，但不能没有 */
.ft-icp { margin: 6px 0 0; color: rgba(251,248,242,.44); font-size: 13px; }
.ft-icp a { color: inherit; }
.ft-icp a:hover { color: var(--tan); }

/* ============================================================ 回到顶部 */

.to-top {
  position: fixed; right: 26px; bottom: 26px; z-index: 40;
  width: 44px; height: 44px; border-radius: 50%;
  border: 1.5px solid var(--line); background: var(--cream); color: var(--navy);
  font-size: 18px; cursor: pointer;
  opacity: 0; visibility: hidden; transform: translateY(10px);
  transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s, box-shadow .2s;
  box-shadow: 0 8px 22px rgba(34,54,78,.14);
}
.to-top.show { opacity: 1; visibility: visible; transform: none; }
.to-top:hover { box-shadow: 0 12px 28px rgba(34,54,78,.22); }

/* ============================================================ 手机 */

@media (max-width: 980px) {
  .hero-in { grid-template-columns: 1fr; gap: 40px; text-align: center; padding-bottom: 64px; }
  .hero-chat { order: -1; }
  .lede { margin-left: auto; margin-right: auto; }
  .hero-cta { justify-content: center; }
  .svc { grid-template-columns: 1fr; }
  .case { grid-template-columns: 1fr; gap: 32px; padding: 32px 26px; }
  .case-side { display: flex; flex-direction: column; align-items: center; }
  /*
   * 窄屏卡片竖着排，横线+三个分支就没意义了：改成一条往下接的链子——
   * 核心 → 卡片1 → 卡片2 → 卡片3，每段正好是卡片之间的 16px 间距。
   */
  .about-cards { grid-template-columns: 1fr; margin-top: var(--stem); }
  .about-cards::before { display: none; }
  .ac::before { top: -16px; height: 16px; }
  .about-hub::after { height: var(--stem); }
  .contact { grid-template-columns: repeat(2, minmax(0,1fr)); }
  .ft-top { flex-direction: column; align-items: flex-start; gap: 20px; }
  .ft-nav { margin-left: 0; }
}

@media (max-width: 720px) {
  /* 导航收进抽屉 */
  .hd-burger { display: block; margin-left: auto; }
  .hd-nav {
    position: fixed; inset: 0 0 auto 0;
    margin: 0; padding: 84px 24px 30px;
    flex-direction: column; align-items: stretch; gap: 4px;
    background: var(--navy-deep);
    transform: translateY(-102%);
    transition: transform .34s var(--ease);
    box-shadow: 0 20px 40px rgba(0,0,0,.3);
  }
  .hd-nav.open { transform: none; }
  .hd-nav > a { padding: 15px 4px; border-bottom: 1px solid rgba(251,248,242,.10); font-size: 16px; }
  .hd-nav > a:not(.hd-cta)::after { display: none; }
  .hd-cta { margin-top: 16px; text-align: center; border-bottom: 0 !important; }
  /* 汉堡变叉 */
  .hd-burger[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .hd-burger[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .hd-burger[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .hero { padding-top: 118px; }
  .hero-strip { grid-template-columns: 1fr; }
  .hs-item { border-right: 0; border-bottom: 1px solid rgba(251,248,242,.10); padding: 20px 4px; }
  .hs-item:last-child { border-bottom: 0; }
  .hs-item::before { display: none; }

  .sec { padding: 60px 20px; }
  .sec-alt, .sec-dark { padding-left: 20px; padding-right: 20px; }
  .sec-head { margin-bottom: 32px; }
  .svc-card { padding: 26px 22px; }
  .case-dl { grid-template-columns: 1fr; gap: 4px 0; }
  .case-dl dt { padding-top: .6em; }
  .hero-cta { flex-direction: column; }
  .hero-cta .btn { width: 100%; }
  .to-top { right: 16px; bottom: 16px; }
}

/* 尊重"减少动态效果"：所有动画和位移都关掉，内容直接显示 */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  html.js .reveal { opacity: 1; transform: none; transition: none; }
  .orb, .badge-float { animation: none; }
  /* 缝线动画和脉冲都停掉，但线本身要留着（它是版式的一部分，不是纯装饰） */
  .about-hub, .about-hub::after, .about-cards::before, .ac::before { animation: none; }
  .btn, .svc-card, .ac, .ct, .case-qr, .to-top { transition: none; }
  .btn:hover, .svc-card:hover, .ac:hover, .ct:hover, .case-qr:hover { transform: none; }
  .hd-nav { transition: none; }
}

/* ============================================================
   咨询助手（首屏下部）
   ============================================================
   两种形态，靠 .ask.open 切换：

     折叠态   一条普通输入栏 + 一行说明 + 三个例子。
              访客刚进来还不确定要问什么，摆一个完整聊天窗会把首屏压得很重。
     展开态   消息区从 0 高度撑到定高，输入栏留在底部（像聊天那样）。
              展开是**向下发生**的，所以首屏的文字和 logo 不会被顶上去。

   展开用 max-height 过渡而不是 height：内容高度事先不知道，
   写死 height 要么裁掉要么留白。max-height 只要给一个够大的上限即可。
   ============================================================ */

.ask {
  position: relative; z-index: 1;
  max-width: 720px;
  margin: 0 auto 46px;
  padding: 0 24px;
}

.ask-box {
  background: var(--cream);
  border-radius: 18px;
  box-shadow: 0 20px 48px rgba(0,0,0,.30);
  overflow: hidden;
  transition: box-shadow .3s var(--ease);
}
.ask.open .ask-box { box-shadow: 0 28px 64px rgba(0,0,0,.40); }

/* 消息区：折叠时高度为 0，展开时撑开 */
.ask-log {
  max-height: 0;
  overflow: hidden;
  transition: max-height .42s var(--ease), padding .42s var(--ease);
  padding: 0 16px;
  display: flex; flex-direction: column; gap: 9px;
}
.ask.open .ask-log {
  max-height: min(340px, 42vh);
  padding: 16px 16px 6px;
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: #D8CFC0 transparent;
}
.ask-log::-webkit-scrollbar { width: 6px; }
.ask-log::-webkit-scrollbar-thumb { background: #D8CFC0; border-radius: 3px; }

.ask-msg {
  max-width: 86%;
  padding: 9px 13px;
  border-radius: 13px;
  font-size: 13.5px; line-height: 1.72;
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  animation: askIn .28s var(--ease);
}
@keyframes askIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
/**
 * ⚠️ 这里必须显式写 color。
 *    气泡在白底上，但它继承的是 .hero 的 color: var(--cream)——
 *    奶油色字写在白底上基本看不见。这个不是"顺手加上"，是踩过的。
 *    （截图上看出来的：整段回答是一团几乎透明的浅灰。）
 */
.ask-msg.bot {
  align-self: flex-start; background: #fff; color: var(--ink);
  border: 1px solid var(--line); border-bottom-left-radius: 5px;
}
.ask-msg.me  { align-self: flex-end;  background: var(--navy); color: var(--cream); border-bottom-right-radius: 5px; }
.ask-msg.err { align-self: flex-start; background: #FDF3EC; border: 1px solid #E9C9AF; color: #8A4B22; }
/* 业主从邮箱回复过来的，用另一个颜色区分——访客要能看出"这是人回的" */
.ask-msg.owner {
  align-self: flex-start; background: #EEF5EE; border: 1px solid #C9DFC9;
  border-bottom-left-radius: 5px; color: #2F4A2F;
}
.ask-msg.owner::before {
  content: "布鼠科技 · 人工回复";
  display: block; margin-bottom: 4px;
  font-size: 11px; letter-spacing: .1em; color: #4E7A4E;
}

.ask-msg.thinking { display: flex; gap: 4px; align-items: center; padding: 12px 14px; }
.ask-msg.thinking span {
  width: 6px; height: 6px; border-radius: 50%; background: var(--navy-soft);
  animation: askDot 1.3s ease-in-out infinite;
}
.ask-msg.thinking span:nth-child(2) { animation-delay: .18s; }
.ask-msg.thinking span:nth-child(3) { animation-delay: .36s; }
@keyframes askDot { 0%,60%,100% { opacity: .28; transform: translateY(0); } 30% { opacity: 1; transform: translateY(-3px); } }

/* 输入栏：两种形态下都在，位置不变 */
.ask-bar {
  display: flex; align-items: center; gap: 9px;
  padding: 12px 12px 12px 16px;
}
.ask-dot {
  flex: none; width: 8px; height: 8px; border-radius: 50%;
  background: #4E9A6A; box-shadow: 0 0 0 3px rgba(78,154,106,.18);
}
.ask-bar input {
  flex: 1; min-width: 0;
  font: inherit; font-size: 15px;
  padding: 9px 2px; border: 0; background: transparent; color: var(--ink);
}
.ask-bar input:focus { outline: none; }
.ask-bar input::placeholder { color: #9A948A; }
.ask-bar button {
  flex: none;
  font: inherit; font-size: 14.5px; font-weight: 600;
  padding: 10px 22px; border-radius: 999px; cursor: pointer;
  border: 1.5px solid var(--navy); background: var(--navy); color: var(--cream);
  transition: background .18s, opacity .18s;
}
.ask-bar button:hover:not(:disabled) { background: var(--navy-deep); }
.ask-bar button:disabled { opacity: .45; cursor: default; }

/* 说明与例子：只在折叠态出现，展开后收掉，把地方让给对话 */
.ask-foot {
  padding: 10px 4px 0;
  transition: opacity .28s var(--ease), max-height .3s var(--ease);
  max-height: 120px;
  overflow: hidden;
}
.ask.open .ask-foot { opacity: 0; max-height: 0; padding-top: 0; }
.ask-tip {
  display: block; margin-bottom: 9px;
  font-size: 12.5px; color: rgba(251,248,242,.60);
}
.ask-chips { display: flex; flex-wrap: wrap; gap: 7px; }
.ask-chips button {
  font: inherit; font-size: 12.5px; line-height: 1;
  padding: 8px 13px; border-radius: 999px; cursor: pointer;
  background: rgba(251,248,242,.07); color: rgba(251,248,242,.86);
  border: 1px dashed rgba(251,248,242,.30);
  transition: background .18s, border-color .18s, color .18s;
}
.ask-chips button:hover { background: rgba(251,248,242,.15); border-color: rgba(251,248,242,.6); color: var(--cream); }

@media (max-width: 620px) {
  .ask { padding: 0 18px; margin-bottom: 34px; }
  .ask.open .ask-log { max-height: min(300px, 38vh); padding: 13px 12px 4px; }
  .ask-msg { font-size: 13px; max-width: 90%; }
  .ask-bar { padding: 10px 10px 10px 13px; }
  .ask-bar button { padding: 10px 17px; }
  .ask-tip { font-size: 12px; }
  .ask-chips button { font-size: 11.5px; padding: 7px 11px; }
  /*
   * 窄到这个程度，两张二维码并排的话每张只剩不到 200px 宽，
   * 码被压到 140px 以下就扫不出来了（`check-site.mjs` 里有这条判据）。
   * 宁可让它俩各占一行。
   */
  .ct-qr { grid-column: 1 / -1; }
}

@media (prefers-reduced-motion: reduce) {
  .ask-box, .ask-log, .ask-foot, .ask-msg, .ask-msg.thinking span { transition: none; animation: none; }
}
