/* =====================================================================
   比高创意 · 智库问答样式（deploy/qa/assets/qa.css）
   文件定位：仅服务 deploy/templates/qa-hub.html · qa-detail.html
   原则：只写 .qa-* 新类，不覆盖、不改写 dist/output.css 与 dist/style.css
   设计依据：
   1) 原站视觉 = 黑/白/灰 + 1px 细线分隔 + 满宽分区 + 大留白，
      故不引入圆角、阴影、渐变与任何新彩色。
   2) 唯一强调色 #fff500 只用于两处单点：结论块 3px 左线、检索进度线；
      其余层级靠字号、字重、灰阶和细线区分。
   3) 数字与拉丁字母沿用 style.css 已声明的 Barlow 字族（同首页 .year），
      中文交给系统字体。
   4) 动效统一 300–500ms ease，与 .nav-a / .backtop 的 .5s 节奏同频。
   5) 版式断点 1024px（style.css 的移动端断点），与 Tailwind md=768 的字号断点分开。
   ===================================================================== */

/* ---------- 1. 字体：Barlow 数字（依据：原站年份/编号数字用法） ---------- */
.qa-num { font-family: 'Barlow-SemiBold', Arial, Helvetica, sans-serif; letter-spacing: .04em; }

/* ---------- 2. 面包屑：12/13px 灰字 + 斜杠（依据：原站内页层级提示极克制） ---------- */
.qa-crumb { margin: 0 0 4px; font-size: 12px; line-height: 1.7; color: #777; }
.qa-crumb a { color: #777; transition: color .3s ease; }
.qa-crumb a:hover { color: #000; }
.qa-crumb .qa-sep { margin: 0 .5em; color: #ccc; }
.qa-crumb .qa-current { color: #777; }
@media (min-width: 768px) { .qa-crumb { font-size: 13px; } }

/* ---------- 3. 首页标题区 ---------- */
.qa-section-tt { font-size: 16px; line-height: 1.6; font-weight: 400; color: #000; }
@media (min-width: 768px) { .qa-section-tt { font-size: 20px; } }

/* ---------- 4. 搜索 / 提问输入：只留 1px 下划线，无外框无圆角（依据：原站以细线承载内容） ---------- */
.qa-ask { display: flex; align-items: center; gap: 12px; border-bottom: 1px solid #000; padding-bottom: 10px; }
.qa-ask-input { flex: 1 1 auto; min-width: 0; padding: 6px 0; border: 0; border-radius: 0; outline: 0;
    background: transparent; font-size: 16px; line-height: 1.6; color: #000; }
.qa-ask-input::placeholder { color: #777; opacity: 1; }
.qa-ask-btn { flex: 0 0 auto; padding: 6px 0 6px 8px; border: 0; background: transparent;
    font-size: 14px; line-height: 1.6; color: #000; cursor: pointer; white-space: nowrap; }
.qa-ask-btn:hover { text-decoration: underline; text-underline-offset: 4px; }
.qa-ask-arrow { display: inline-block; transition: transform .3s ease; }
.qa-ask-btn:hover .qa-ask-arrow, .qa-ask-btn:focus-visible .qa-ask-arrow { transform: translateX(4px); }
.qa-hint { padding-top: 12px; font-size: 12px; line-height: 1.7; color: #777; }
@media (min-width: 768px) {
    .qa-ask { gap: 24px; padding-bottom: 14px; }
    .qa-ask-input { font-size: 18px; }
    .qa-ask-btn { font-size: 16px; }
    .qa-hint { padding-top: 14px; font-size: 13px; }
}

/* ---------- 5. 检索进度线：2px 细线替代转圈 loading（依据：细线体系 + 黄色单点强调） ---------- */
.qa-answer { padding-top: 18px; }
.qa-answer[hidden] { display: none; }
.qa-search-status { font-size: 13px; line-height: 1.7; color: #777; letter-spacing: .04em; }
.qa-progress { height: 2px; margin-top: 10px; background: #ddd; overflow: hidden; }
.qa-progress i { display: block; width: 0; height: 100%; background: #fff500; transition: width .4s ease; }
.qa-progress.is-run i { width: 100%; }
.qa-reveal { animation: qa-reveal .4s ease both; }
@keyframes qa-reveal { from { opacity: 0; } to { opacity: 1; } }

/* ---------- 6. 检索结果卡：细线分隔而非色块卡片（依据：原站资讯列表的图+字结构） ---------- */
.qa-hits { margin-top: 14px; border-top: 1px solid #ddd; }
.qa-hit { display: block; padding: 16px 0; border-bottom: 1px solid #ddd; }
.qa-hit-cat { font-size: 12px; line-height: 1.7; color: #777; }
.qa-hit-q { padding-top: 2px; font-size: 16px; line-height: 1.6; color: #000; transition: color .3s ease; }
.qa-hit-a { padding-top: 4px; font-size: 14px; line-height: 1.8; color: #777; }
.qa-hit-more { display: inline-block; margin-top: 8px; font-size: 13px; color: #777; transition: color .3s ease; }
.qa-hit-arrow { display: inline-block; transition: transform .3s ease; }
.qa-hit:hover .qa-hit-q { font-weight: 700; }
.qa-hit:hover .qa-hit-more { color: #000; }
.qa-hit:hover .qa-hit-arrow { transform: translateX(4px); }
.qa-answer-fallback { padding-top: 16px; font-size: 14px; line-height: 1.8; color: #777; }
.qa-answer-fallback a { color: #000; border-bottom: 1px solid #ccc; transition: border-color .3s ease; }
.qa-answer-fallback a:hover { border-color: #000; }

/* 实时提问命中人工答案（/api/qa/ask 返回）：细线分隔，不用气泡 */
.qa-api-answer { padding-top: 12px; }
.qa-api-answer p { font-size: 17px; line-height: 1.8; color: #333; }
.qa-citations { margin-top: 20px; padding-top: 12px; border-top: 1px solid #ddd; }
.qa-cite-label { padding-bottom: 6px; font-size: 12px; line-height: 1.7; color: #777; }
.qa-cite-link { display: flex; align-items: baseline; justify-content: space-between; gap: 16px;
    padding: 10px 0; border-bottom: 1px solid #ddd; font-size: 14px; line-height: 1.7; color: #333;
    transition: color .3s ease; }
.qa-cite-link:hover { color: #000; font-weight: 700; }
.qa-nomatch { padding-top: 2px; font-size: 16px; line-height: 1.8; color: #000; }
.qa-suggest { margin-top: 20px; padding-top: 12px; border-top: 1px solid #ddd; }
@media (min-width: 768px) {
    .qa-api-answer p { font-size: 18px; }
    .qa-nomatch { font-size: 18px; }
}
@media (min-width: 768px) {
    .qa-hit-q { font-size: 18px; }
    .qa-hit-a { font-size: 15px; }
}

/* ---------- 7. 分类 chip：复用原站描边标签（依据：news.html 的筛选 chip） ---------- */
.qa-chips { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.qa-chip { display: block; width: 100%; padding: 8px 12px; border: 1px solid #ccc; background: transparent;
    font: inherit; font-size: 14px; line-height: 1.5; color: #777; text-align: center; cursor: pointer;
    transition: background-color .3s ease, color .3s ease, border-color .3s ease; }
.qa-chip:hover { background: #000; border-color: #000; color: #fff; }
.qa-chip.is-active { background: #000; border-color: #000; color: #fff; }
.qa-chips .qa-chip:last-child { grid-column: 1 / -1; }
.qa-chips-wrap { padding-top: 32px; }
@media (min-width: 768px) {
    .qa-chips-wrap { padding-top: 48px; }
    .qa-chips { grid-template-columns: repeat(3, 1fr); gap: 10px; }
    .qa-chips .qa-chip:last-child { grid-column: auto; }
    .qa-chip { padding: 9px 14px; font-size: 14px; }
}
/* 桌面端：9 个 chip 保持一行（依据：原站筛选行不折行；1440 实测总宽 < 容器） */
@media (min-width: 1025px) {
    .qa-chips { display: flex; flex-wrap: wrap; gap: 8px; }
    .qa-chips .qa-chip:last-child { grid-column: auto; }
    .qa-chip { display: inline-block; width: auto; padding: 8px 16px; font-size: 14px; white-space: nowrap; }
}
.qa-filter-status { padding-top: 12px; font-size: 12px; line-height: 1.7; color: #777; }
.qa-filter-status[hidden] { display: none; }

/* ---------- 8. 区块标题：细线上方一行标题 + 右侧小字说明（依据：原站列表页分区） ---------- */
.qa-section { border-top: 1px solid #ddd; margin-top: 40px; padding-top: 32px; }
.qa-section-hd { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding-bottom: 6px; }
.qa-section-sub { flex: 0 0 auto; font-size: 12px; line-height: 1.8; color: #777; }
@media (min-width: 768px) {
    .qa-section { margin-top: 64px; padding-top: 56px; }
    .qa-section-hd { padding-bottom: 12px; }
    .qa-section-sub { font-size: 13px; }
}

/* ---------- 9. 热门问题：编号 + 问题 + 细箭头，行间 #ddd 细线 ---------- */
.qa-hot-item { display: flex; align-items: baseline; gap: 14px; padding: 18px 0; border-bottom: 1px solid #ddd; }
.qa-hot-idx { flex: 0 0 auto; width: 2.2em; font-family: 'Barlow-SemiBold', Arial, sans-serif; font-size: 13px; color: #777; letter-spacing: .04em; }
.qa-hot-q { flex: 1 1 auto; min-width: 0; font-size: 16px; line-height: 1.6; color: #333; transition: color .3s ease; }
.qa-hot-arrow { flex: 0 0 auto; font-size: 15px; color: #777; transition: transform .3s ease, color .3s ease; }
.qa-hot-item:hover .qa-hot-q { color: #000; font-weight: 700; }
.qa-hot-item:hover .qa-hot-arrow { color: #000; transform: translateX(4px); }
.qa-hot-item:last-child { border-bottom: 0; }
@media (min-width: 768px) { .qa-hot-q { font-size: 20px; } }

/* ---------- 10. 全部问题：1024px 以上两列（依据：原站桌面多列排布；columns 保持自然阅读顺序） ---------- */
.qa-all { columns: 1; column-gap: 48px; }
.qa-all-item { display: flex; align-items: baseline; justify-content: space-between; gap: 20px;
    padding: 12px 0; border-bottom: 1px solid #ddd; break-inside: avoid; -webkit-column-break-inside: avoid; }
.qa-all-q { font-size: 15px; line-height: 1.6; color: #333; transition: color .3s ease; }
.qa-all-cat { flex: 0 0 auto; font-size: 12px; line-height: 1.8; color: #777; white-space: nowrap; }
.qa-all-item:hover .qa-all-q { color: #000; font-weight: 700; }
@media (min-width: 768px) { .qa-all-q { font-size: 16px; } }
@media (min-width: 1025px) { .qa-all { columns: 2; column-gap: 64px; } }

/* ---------- 11. 空态 / 文字按钮：灰字提示，不用插画色块（依据：原站几乎无空态组件） ---------- */
.qa-empty { padding: 24px 0; font-size: 15px; line-height: 1.8; color: #777; }
.qa-empty[hidden] { display: none !important; }
.qa-link-btn { padding: 0; border: 0; background: none; font: inherit; color: #000;
    border-bottom: 1px solid #ccc; cursor: pointer; }
.qa-link-btn:hover { border-color: #000; }

/* ---------- 12. 分类入口：8 个方向，桌面两列、细线分隔（依据：原站文字列表） ---------- */
.qa-cat-links { display: grid; grid-template-columns: 1fr; }
.qa-cat-link { display: flex; align-items: baseline; justify-content: space-between; gap: 20px;
    padding: 14px 0; border-bottom: 1px solid #ddd; font-size: 15px; line-height: 1.6; color: #333;
    transition: color .3s ease; }
.qa-cat-link:hover { color: #000; font-weight: 700; }
.qa-cat-count { flex: 0 0 auto; font-family: 'Barlow-SemiBold', Arial, sans-serif; font-size: 12px; color: #777; letter-spacing: .04em; }
@media (min-width: 768px) {
    .qa-cat-link { font-size: 16px; }
}
@media (min-width: 1025px) {
    .qa-cat-links { grid-template-columns: 1fr 1fr; column-gap: 64px; }
}

/* =====================================================================
   单题详情页
   ===================================================================== */

/* ---------- 13. 正文容器：最大 900px，左侧对齐 + 右侧留白（依据：原站资讯详情页约 960px 的阅读宽度，取 900px 折中，避免行长过长） ---------- */
.qa-article { max-width: 900px; margin-left: auto; margin-right: auto; }
.qa-article-hd { padding-top: 20px; }
.qa-h1 { font-size: 20px; line-height: 1.4; font-weight: 400; color: #000; }
.qa-meta { display: flex; flex-wrap: wrap; align-items: baseline; gap: 0;
    padding-top: 12px; font-size: 13px; line-height: 1.8; color: #777; }
.qa-meta .qa-sep { margin: 0 .6em; color: #ccc; }
.qa-meta-cat { color: #000; }
@media (min-width: 768px) {
    .qa-article-hd { padding-top: 28px; }
    .qa-h1 { font-size: 24px; }
}
@media (min-width: 1024px) { .qa-h1 { font-size: 30px; } }
@media (min-width: 1280px) { .qa-h1 { font-size: 36px; } }

/* ---------- 14. 结论块：全站唯一使用品牌黄左线的位置（依据：结论先行，单点强调） ---------- */
.qa-block-label { padding-bottom: 10px; font-size: 12px; line-height: 1.7; color: #777; letter-spacing: .04em; }
.qa-conclusion-block { padding-top: 28px; }
.qa-conclusion { border-left: 3px solid #fff500; padding-left: 16px;
    font-size: 20px; line-height: 1.7; color: #000; }
.qa-conclusion-actions { display: flex; align-items: center; gap: 12px; padding: 14px 0 0 19px; }
.qa-copy { padding: 0; border: 0; background: none; font: inherit; font-size: 13px; line-height: 1.7;
    color: #777; border-bottom: 1px solid #ccc; cursor: pointer; transition: color .3s ease, border-color .3s ease; }
.qa-copy:hover { color: #000; border-color: #000; }
.qa-copy-tip { font-size: 12px; line-height: 1.7; color: #777; }
@media (min-width: 768px) {
    .qa-conclusion-block { padding-top: 36px; }
    .qa-conclusion { padding-left: 20px; font-size: 22px; }
    .qa-conclusion-actions { padding-left: 23px; }
}

/* ---------- 15. 正文：小节标题 18–20px normal、正文 17–18px 行高 1.8（依据：原站 lh-1-8 长文节奏） ---------- */
.qa-body { padding-top: 8px; }
.qa-body h2 { margin: 36px 0 0; font-size: 18px; line-height: 1.7; font-weight: 400; color: #000; }
.qa-body p { margin: 12px 0 0; font-size: 17px; line-height: 1.8; color: #333; }
.qa-body strong { font-weight: 700; color: #000; }
@media (min-width: 768px) {
    .qa-body h2 { font-size: 20px; }
    .qa-body p { font-size: 18px; }
}

/* 长答案展开/收起（仅移动端、超过一屏时由 qa.js 启用；静态 HTML 内容始终完整） */
.qa-body-toggle { padding-top: 4px; }
.qa-body-toggle[hidden] { display: none; }
.qa-body.is-clamped { max-height: 760px; overflow: hidden; }
.qa-expand { padding: 8px 0; border: 0; background: none; font: inherit; font-size: 14px;
    color: #777; border-bottom: 1px solid #ccc; cursor: pointer; transition: color .3s ease, border-color .3s ease; }
.qa-expand:hover { color: #000; border-color: #000; }

/* ---------- 16. 要点：编号 + 细线列表，不用色块卡片（依据：原站以线分层） ---------- */
.qa-points { border-top: 1px solid #ddd; margin-top: 40px; padding-top: 24px; }
.qa-points[hidden] { display: none; }
.qa-points-tt { font-size: 18px; line-height: 1.7; font-weight: 400; color: #000; }
.qa-points-list { margin: 10px 0 0; padding: 0; list-style: none; counter-reset: qa-point; }
.qa-points-list li { position: relative; counter-increment: qa-point; padding: 14px 0 14px 2.6em;
    border-bottom: 1px solid #ddd; font-size: 16px; line-height: 1.75; color: #333; }
.qa-points-list li::before { content: counter(qa-point, decimal-leading-zero); position: absolute; left: 0; top: 15px;
    font-family: 'Barlow-SemiBold', Arial, sans-serif; font-size: 13px; color: #777; }
@media (min-width: 768px) {
    .qa-points { margin-top: 48px; }
    .qa-points-tt { font-size: 20px; }
    .qa-points-list li { font-size: 17px; }
}

/* ---------- 17. 相关服务：内链到服务页 ---------- */
.qa-service { border-top: 1px solid #ddd; margin-top: 40px; padding-top: 24px; }
.qa-service .qa-block-label { display: block; }
.qa-service-link { display: inline-flex; align-items: baseline; gap: 6px; margin-top: 2px; padding-bottom: 4px;
    font-size: 16px; line-height: 1.7; color: #333; white-space: nowrap;
    border-bottom: 1px solid #ccc; transition: color .3s ease, border-color .3s ease; }
.qa-service-link:hover { color: #000; border-color: #000; }

/* ---------- 18. 相关案例：图 + 标题 + 细箭头，hover 图片 1.05（依据：案例卡 hover scale-110 的克制版） ---------- */
.qa-case-wrap { margin-top: 40px; padding-top: 24px; border-top: 1px solid #ddd; }
.qa-case { display: block; }
.qa-case-img { height: 200px; overflow: hidden; }
.qa-case-img img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform .5s ease; }
.qa-case:hover .qa-case-img img { transform: scale(1.05); }
.qa-case-row { display: flex; align-items: baseline; justify-content: space-between; gap: 20px; padding-top: 16px; }
.qa-case-title { font-size: 16px; line-height: 1.7; color: #333; transition: color .3s ease; }
.qa-case-more { flex: 0 0 auto; font-size: 13px; color: #777; transition: color .3s ease; }
.qa-case-arrow { display: inline-block; transition: transform .3s ease; }
.qa-case:hover .qa-case-title { color: #000; font-weight: 700; }
.qa-case:hover .qa-case-more { color: #000; }
.qa-case:hover .qa-case-arrow { transform: translateX(4px); }
@media (min-width: 768px) {
    .qa-case-wrap { margin-top: 48px; }
    .qa-case-img { height: 300px; }
    .qa-case-title { font-size: 18px; }
}

/* ---------- 19. 相关问题：3 条文字链接 + 细线（依据：原站以文字列表收尾） ---------- */
.qa-related { border-top: 1px solid #ddd; margin-top: 40px; padding-top: 24px; }
.qa-related[hidden] { display: none; }
.qa-related-list { margin-top: 8px; }
.qa-related-link { display: flex; align-items: baseline; justify-content: space-between; gap: 20px;
    padding: 14px 0; border-bottom: 1px solid #ddd; font-size: 15px; line-height: 1.6; color: #333;
    transition: color .3s ease; }
.qa-related-link:hover { color: #000; font-weight: 700; }
@media (min-width: 768px) {
    .qa-related { margin-top: 48px; }
    .qa-related-link { font-size: 16px; }
}

/* ---------- 20. 底部 CTA：大字 + 电话（依据：原站转化位的一行大字结构） ---------- */
.qa-cta { border-top: 1px solid #ddd; margin-top: 48px; padding-top: 32px; }
.qa-cta-title { font-size: 20px; line-height: 1.5; color: #000; }
.qa-cta-tel { display: inline-block; margin-top: 14px; font-size: 28px; line-height: 1.2; color: #000;
    transition: opacity .3s ease; }
.qa-cta-tel:hover { opacity: .7; }
.qa-cta-sub { padding-top: 8px; font-size: 13px; line-height: 1.8; color: #777; }
.qa-cta-back { display: inline-block; margin-top: 22px; padding-bottom: 4px; font-size: 14px; color: #777;
    border-bottom: 1px solid #ccc; transition: color .3s ease, border-color .3s ease; }
.qa-cta-back:hover { color: #000; border-color: #000; }
@media (min-width: 768px) {
    .qa-cta { margin-top: 72px; padding-top: 48px; }
    .qa-cta-title { font-size: 26px; }
    .qa-cta-tel { margin-top: 18px; font-size: 44px; }
}

/* ---------- 21. 1024px 以下：紧凑留白与单列（依据：原站移动断点 1024px） ---------- */
@media (max-width: 1024px) {
    .qa-section { margin-top: 32px; padding-top: 26px; }
    .qa-conclusion-block { padding-top: 24px; }
    .qa-points, .qa-service, .qa-case-wrap, .qa-related { margin-top: 32px; padding-top: 20px; }
    .qa-cta { margin-top: 40px; padding-top: 28px; }
    .qa-crumb-now { max-width: 16em; }
}

/* 面包屑当前项：单行截断（问题可能很长，不撑破版心） */
.qa-crumb-now { display: inline-block; max-width: 22em; overflow: hidden; white-space: nowrap;
    text-overflow: ellipsis; vertical-align: bottom; }

/* ---------- 22. 无障碍：键盘聚焦给细线轮廓，不加圆角阴影 ---------- */
.qa-ask-input:focus-visible, .qa-ask-btn:focus-visible, .qa-chip:focus-visible,
.qa-copy:focus-visible, .qa-expand:focus-visible, .qa-link-btn:focus-visible,
.qa-cat-link:focus-visible, .qa-related-link:focus-visible, .qa-cta-tel:focus-visible {
    outline: 1px solid #000; outline-offset: 3px;
}

/* ---------- 23. 第二轮补丁：E-E-A-T 作者行、追问闭环、移动端折叠、锚点偏移 ---------- */
/* 作者/审校行：继续沿用 .qa-meta 灰字体系，只降一级字号 */
.qa-meta-sub { padding-top: 4px; font-size: 12px; color: #777; }
.qa-meta-sub .qa-sep { margin: 0 .45em; }
/* 提问锚点：固定 header 90/55px，滚动定位留出偏移 */
.qa-ask { scroll-margin-top: 100px; }
/* 移动端「全部问题」折叠入口：居中文字按钮，不加卡片 */
.qa-all-more { display: flex; justify-content: center; padding-top: 24px; }
.qa-all-more[hidden] { display: none; }
@media (min-width: 1025px) { .qa-all-more { display: none !important; } }
/* 追问闭环：置于相关问题之后、CTA 之前，用细线收口 */
.qa-followup { margin-top: 28px; padding-top: 20px; border-top: 1px solid #ddd;
    font-size: 14px; line-height: 1.8; color: #777; }
.qa-followup-link { display: inline-flex; align-items: baseline; gap: 6px; margin-left: 6px;
    color: #000; border-bottom: 1px solid #ccc; white-space: nowrap;
    transition: border-color .3s ease; }
.qa-followup-link:hover { border-color: #000; }
@media (min-width: 768px) {
    .qa-followup { margin-top: 36px; padding-top: 24px; font-size: 15px; }
}
