/* ============================================================
   博客文章正文排版（Blog article prose）
   ------------------------------------------------------------
   纯 CSS，独立于 Tailwind 编译产物 —— 文章正文用到的 list-disc /
   pl-6 / border-l-4 等工具类已被 Tailwind purge 掉，若直接用会裸奔。
   故此处用作用域 .article-body 统一定义文章排版，避免依赖重编译。
   颜色复用各页 head 内联的 design tokens（--accent 等）。
   ============================================================ */
.article-body {
  color: #374151;
  font-size: 1.0625rem;
  line-height: 1.8;
}

.article-body>*+* {
  margin-top: 1.25rem;
}

.article-body .lead {
  font-size: 1.25rem;
  line-height: 1.7;
  color: #475569;
  font-weight: 400;
  margin-bottom: 2rem;
}

.article-body h2 {
  font-family: 'Space Grotesk', system-ui, sans-serif;
  color: #1e293b;
  font-size: 1.875rem;
  line-height: 1.2;
  letter-spacing: -0.02em;
  margin-top: 3rem;
  margin-bottom: 1rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid #e2e8f0;
}

.article-body h3 {
  font-family: 'Space Grotesk', system-ui, sans-serif;
  color: #334155;
  font-size: 1.35rem;
  line-height: 1.3;
  margin-top: 2rem;
  margin-bottom: 0.75rem;
}

.article-body p {
  color: #374151;
}

.article-body strong {
  color: #1f2937;
  font-weight: 600;
}

.article-body a {
  color: var(--accent, #f97316);
  text-decoration: underline;
  text-underline-offset: 2px;
  transition: color 0.2s ease;
}

.article-body a:hover {
  color: var(--accent-dark, #ea580c);
}

.article-body ul,
.article-body ol {
  padding-left: 1.5rem;
}

.article-body ul {
  list-style: disc;
}

.article-body ol {
  list-style: decimal;
}

.article-body li {
  margin-top: 0.75rem;
  padding-left: 0.25rem;
}

.article-body li::marker {
  color: var(--accent, #f97316);
}

.article-body ul li::marker {
  font-size: 1.1em;
}

.article-body blockquote {
  border-left: 4px solid var(--accent, #f97316);
  padding: 0.25rem 0 0.25rem 1rem;
  color: #4b5563;
  font-style: italic;
}

/* 文内对比/规格表 —— 暖色表头 + 斑马纹 + hover 高亮（与正文浅色主题统一） */
.article-body table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  font-size: 0.95rem;
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
  border-radius: 0.75rem;
  overflow: hidden;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.article-body thead th {
  background: #fff7ed;
  color: #9a3412;
  font-family: 'Space Grotesk', system-ui, sans-serif;
  font-size: 0.875rem;
  font-weight: 700;
  letter-spacing: 0.01em;
  text-transform: uppercase;
  padding: 0.875rem 1rem;
  text-align: left;
  vertical-align: top;
  border-bottom: 2px solid #fed7aa;
}

.article-body tbody tr:nth-child(odd) {
  background: #f8fafc;
}

.article-body tbody tr:nth-child(even) {
  background: #ffffff;
}

.article-body tbody tr:hover {
  background: #fff7ed;
  transition: background 0.2s ease;
}

.article-body td {
  padding: 0.875rem 1rem;
  text-align: left;
  vertical-align: top;
  color: #374151;
  border-bottom: 1px solid #e2e8f0;
}

.article-body tbody tr:last-child td {
  border-bottom: none;
}

.article-body td:first-child {
  font-weight: 600;
  color: #1f2937;
}

/* 文末 CTA callout —— 与 At a glance 卡一致的暖色浅底 + 橙色左边条 */
.article-body .article-callout {
  background: linear-gradient(180deg, #fffaf0 0%, #fff7ed 100%);
  border: 1px solid #fed7aa;
  border-left: 4px solid #f97316;
  border-radius: 1rem;
  padding: 1.5rem 1.75rem;
  margin-top: 2.5rem;
  position: relative;
  box-shadow: 0 2px 8px rgba(249, 115, 22, 0.08);
}

/* 左侧橙色竖线已由左边框呈现，去掉额外竖线 */
.article-body .article-callout::before {
  content: none;
}

.article-body .article-callout p {
  color: #44403c;
  margin: 0;
}

.article-body .article-callout p:first-child {
  color: #9a3412;
  font-weight: 700;
  margin-bottom: 0.5rem;
}

.article-body .article-callout a {
  color: #ea580c;
  font-weight: 600;
}

.article-body .article-callout a:hover {
  color: #c2410c;
}

/* ============================================================
   AI 摘要卡（At a glance）—— 浅色高亮卡片
   与文末 CTA 统一为暖色浅底 + 橙色左边条，保证高可读性
   ============================================================ */
.article-body .article-callout.ai-summary {
  background: linear-gradient(180deg, #fffaf0 0%, #fff7ed 100%);
  border: 1px solid #fed7aa;
  border-left: 4px solid #f97316;
  border-radius: 1rem;
  padding: 1.5rem 1.75rem;
  margin-top: 2.5rem;
  box-shadow: 0 2px 8px rgba(249, 115, 22, 0.08);
}

/* 去掉默认深色卡的左侧橙色竖线（改用左边框呈现） */
.article-body .article-callout.ai-summary::before {
  display: none;
}

/* 标题：小号大写 + 橙色短横线装饰 */
.article-body .article-callout.ai-summary p:first-child {
  color: #9a3412;
  font-weight: 700;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.09em;
  margin: 0 0 0.9rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}

.article-body .article-callout.ai-summary p:first-child::before {
  content: '';
  width: 1.75rem;
  height: 2px;
  background: #f97316;
  border-radius: 9999px;
  flex: none;
}

.article-body .article-callout.ai-summary p:first-child strong {
  color: inherit;
  font-weight: 700;
}

/* 列表项：中性高可读文字 + 橙色强调词 + 橙色项目符号 */
.article-body .article-callout.ai-summary ul {
  margin: 0;
  padding-left: 1.25rem;
}

.article-body .article-callout.ai-summary li {
  margin: 0 0 0.6rem;
  padding-left: 0.25rem;
  color: #44403c;
  font-size: 0.975rem;
  line-height: 1.65;
}

.article-body .article-callout.ai-summary li:last-child {
  margin-bottom: 0;
}

.article-body .article-callout.ai-summary li::marker {
  color: #f97316;
  font-weight: 700;
}

.article-body .article-callout.ai-summary li strong {
  color: #92400e;
  font-weight: 600;
}

/* 技术性内联代码 */
.article-body code {
  background: #f1f5f9;
  padding: 0.125rem 0.375rem;
  border-radius: 0.25rem;
  font-size: 0.9em;
  color: #ea580c;
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
}

/* 章节分隔线 */
.article-body hr {
  border: none;
  height: 1px;
  background: linear-gradient(to right, transparent, #e2e8f0, transparent);
  margin: 2.5rem 0;
}

/* ═══════════════════════════════════════════════════════════
   全站共享组件样式层（swup 跳转 + 整页加载两种场景都必须生效）
   说明：页面 head 内的 <style> 在 swup 跳转时不加载，
   因此跨页共享的组件样式统一收敛到本文件（全站 <link> 引用）。
   各页面 head 中保留的重复样式仅作整页加载兜底，修改以本文件为准。
   ═══════════════════════════════════════════════════════════ */

/* ── Custom Cursor: 工业十字线（与 index.html head 版本一致） ── */
#cursor-dot {
  position: fixed;
  left: 0;
  top: 0;
  width: 24px;
  height: 24px;
  pointer-events: none;
  z-index: 99999;
  will-change: transform;
}

#cursor-dot::before,
#cursor-dot::after {
  content: '';
  position: absolute;
  background: #f97316;
  border-radius: 1px;
  opacity: 0.9;
}

#cursor-dot::before {
  width: 1.5px;
  height: 100%;
  left: 50%;
  top: 0;
  transform: translateX(-50%);
}

#cursor-dot::after {
  width: 100%;
  height: 1.5px;
  top: 50%;
  left: 0;
  transform: translateY(-50%);
}

#cursor-dot .dot-center {
  position: absolute;
  width: 4px;
  height: 4px;
  background: #f97316;
  border: none;
  border-radius: 50%;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  transition: width 0.5s cubic-bezier(0.16, 1, 0.3, 1),
    height 0.5s cubic-bezier(0.16, 1, 0.3, 1),
    background 0.5s cubic-bezier(0.16, 1, 0.3, 1);
}

#cursor-dot.hovering {
  width: 32px;
  height: 32px;
}

#cursor-dot.hovering .dot-center {
  width: 32px;
  height: 32px;
  background: rgba(249, 115, 22, 0.12);
  border: 1px solid #f97316;
  border-radius: 50%;
  box-shadow: 0 0 10px rgba(249, 115, 22, 0.4), 0 0 20px rgba(249, 115, 22, 0.15);
}

#cursor-dot.hovering::before,
#cursor-dot.hovering::after {
  opacity: 0;
}

/* ── Cursor Glow (Hero only) ── */
#cursor-glow {
  position: fixed;
  left: 0;
  top: 0;
  width: 350px;
  height: 350px;
  border-radius: 50%;
  pointer-events: none;
  background: radial-gradient(circle,
      rgba(249, 115, 22, 0.18) 0%,
      rgba(249, 115, 22, 0.08) 30%,
      transparent 60%);
  opacity: 0;
  transition: opacity 0.6s ease;
  z-index: 5;
  mix-blend-mode: screen;
  will-change: transform;
}

#cursor-glow.visible {
  opacity: 1;
}

/* ── Click Ripple ── */
.click-ripple {
  position: fixed;
  border: 2px solid rgba(249, 115, 22, 0.95);
  border-radius: 50%;
  pointer-events: none;
  z-index: 99997;
  animation: lj-ripple-expand 0.6s cubic-bezier(0.16, 1, 0.3, 1) forwards;
  box-shadow: 0 0 0 4px rgba(249, 115, 22, 0.15);
}

@keyframes lj-ripple-expand {
  0% {
    width: 0;
    height: 0;
    opacity: 1;
    transform: translate(-50%, -50%);
  }

  100% {
    width: 70px;
    height: 70px;
    opacity: 0;
    transform: translate(-50%, -50%);
  }
}

/* ── FAQ 知识库：全展开阅读布局（faq.html，规范见 docs/FAQ知识库规范.md） ── */
.kb-faq h2 {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.kb-faq h2::before {
  content: '';
  width: 6px;
  height: 1.5em;
  border-radius: 3px;
  background: #f97316;
  flex-shrink: 0;
}

.kb-qa {
  padding: 1.25rem 1.5rem;
  border-left: 3px solid #f97316;
  background: #fafaf9;
  border-radius: 0.5rem;
  margin-bottom: 1rem;
  transition: background-color 0.2s ease, border-color 0.2s ease;
}

.kb-qa:hover {
  background: #fff7ed;
  border-left-color: #ea580c;
}

.kb-q {
  font-family: 'Space Grotesk', system-ui, sans-serif;
  font-size: 1.0625rem;
  font-weight: 600;
  color: #2d3436;
  margin-bottom: 0.5rem;
}

.kb-a {
  color: #4b5563;
  line-height: 1.7;
  font-size: 0.9375rem;
}

.kb-a a {
  color: #ea580c;
  text-decoration: underline;
  text-underline-offset: 2px;
}