/* 速工具 文章板块样式 —— 教程/介绍长文，SEO + GEO 优化排版 */

.article-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 24px 64px;
}

/* 面包屑 */
.breadcrumb {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 20px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 6px;
}
.breadcrumb a { color: var(--text-secondary); text-decoration: none; }
.breadcrumb a:hover { color: var(--text); text-decoration: underline; }
.breadcrumb .sep { color: var(--border); }

/* 文章头部 */
.article-header { margin-bottom: 24px; }
.article-header h1 {
  font-size: 30px;
  font-weight: 700;
  line-height: 1.3;
  color: var(--text);
  margin-bottom: 12px;
}
.article-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  font-size: 13px;
  color: var(--text-muted);
}
.article-meta span { display: inline-flex; align-items: center; gap: 5px; }

/* TL;DR 摘要框 —— GEO 重点抽取区 */
.tldr {
  background: var(--primary-light);
  border: 1px solid var(--border);
  border-left: 4px solid var(--primary);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 24px 0;
}
.tldr-label {
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .5px;
  color: var(--primary);
  margin-bottom: 6px;
}
.tldr p { font-size: 15px; line-height: 1.7; color: var(--text); margin: 0; }

/* 正文排版 */
.article-body { font-size: 16px; line-height: 1.8; color: var(--text); }
.article-body h2 {
  font-size: 22px;
  font-weight: 700;
  color: var(--text);
  margin: 36px 0 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-light);
  scroll-margin-top: 76px;
}
.article-body h3 {
  font-size: 18px;
  font-weight: 600;
  color: var(--text);
  margin: 24px 0 10px;
  scroll-margin-top: 76px;
}
.article-body p { margin: 0 0 14px; color: var(--text-secondary); }
.article-body strong { color: var(--text); font-weight: 600; }
.article-body a { color: var(--primary-dark); text-decoration: underline; text-underline-offset: 2px; }
.article-body ul, .article-body ol { margin: 0 0 16px; padding-left: 24px; color: var(--text-secondary); }
.article-body li { margin-bottom: 8px; line-height: 1.7; }
.article-body code {
  background: var(--bg);
  border: 1px solid var(--border-light);
  border-radius: 4px;
  padding: 2px 6px;
  font-family: "SFMono-Regular", Consolas, monospace;
  font-size: 14px;
  color: var(--danger);
}
.article-body pre {
  background: var(--primary-dark);
  color: #e6e6e6;
  border-radius: var(--radius);
  padding: 16px;
  overflow-x: auto;
  margin: 0 0 16px;
  font-size: 13px;
  line-height: 1.6;
}
.article-body pre code { background: none; border: none; color: inherit; padding: 0; }

/* 有序步骤 */
.steps { counter-reset: step; list-style: none; padding-left: 0; }
.steps > li {
  position: relative;
  padding: 4px 0 4px 44px;
  margin-bottom: 14px;
  min-height: 32px;
}
.steps > li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 0; top: 2px;
  width: 30px; height: 30px;
  border-radius: 50%;
  background: var(--primary);
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* 功能/场景网格 */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 14px;
  margin: 16px 0;
}
.feature-card {
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px;
}
.feature-card h4 { font-size: 15px; font-weight: 600; color: var(--text); margin-bottom: 6px; }
.feature-card p { font-size: 14px; color: var(--text-muted); margin: 0; line-height: 1.6; }

/* 对比表格 */
.article-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 14px;
}
.article-body th, .article-body td {
  border: 1px solid var(--border);
  padding: 10px 12px;
  text-align: left;
}
.article-body th { background: var(--bg); font-weight: 600; color: var(--text); }
.article-body td { color: var(--text-secondary); }

/* FAQ */
.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 18px;
  margin-bottom: 12px;
  background: var(--bg-white);
}
.faq-item h3 {
  font-size: 16px;
  font-weight: 600;
  color: var(--text);
  margin: 0 0 8px;
}
.faq-item p { margin: 0; font-size: 15px; line-height: 1.7; color: var(--text-secondary); }

/* CTA */
.cta-box {
  background: var(--primary-dark);
  border-radius: var(--radius);
  padding: 28px 24px;
  text-align: center;
  color: #fff;
  margin: 36px 0;
}
.cta-box h3 { font-size: 20px; font-weight: 700; margin-bottom: 8px; color: #fff; }
.cta-box p { font-size: 14px; opacity: .8; margin-bottom: 18px; }
.cta-box .btn-primary { background: #fff; color: var(--primary-dark); font-size: 15px; padding: 11px 28px; }
.cta-box .btn-primary:hover { background: var(--primary-light); }

/* 相关工具 */
.related-tools { margin: 32px 0; }
.related-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 10px;
}

/* 文章列表页 - Hero 区 */
.article-list-hero {
  padding: 48px 0 24px;
  text-align: center;
  border-bottom: 1px solid var(--border-light);
  margin-bottom: 24px;
}
.article-list-hero h1 { font-size: 32px; font-weight: 700; margin-bottom: 12px; line-height: 1.3; }
.article-list-hero p { color: var(--text-muted); font-size: 15px; max-width: 600px; margin: 0 auto; }

/* 搜索框 */
.search-box {
  max-width: 480px;
  margin: 24px auto 0;
  position: relative;
}
.search-box input {
  width: 100%;
  padding: 12px 16px 12px 44px;
  border: 1px solid var(--border);
  border-radius: 24px;
  font-size: 14px;
  background: var(--bg-white);
  color: var(--text);
  transition: all .2s;
  font-family: inherit;
}
.search-box input:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}
.search-box svg {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
  width: 18px;
  height: 18px;
  color: var(--text-muted);
}

/* 统计行 */
.article-stats {
  text-align: center;
  color: var(--text-muted);
  font-size: 13px;
  margin-bottom: 16px;
}
.article-stats strong { color: var(--primary); font-weight: 600; }

/* 筛选栏 */
.filter-bar {
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  gap: 8px;
  padding: 12px 0;
  margin-bottom: 20px;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}
.filter-bar::-webkit-scrollbar { display: none; }
.filter-pill {
  flex-shrink: 0;
  padding: 6px 16px;
  border: 1px solid var(--border);
  border-radius: 20px;
  background: var(--bg-white);
  color: var(--text-secondary);
  font-size: 13px;
  cursor: pointer;
  transition: all .2s;
  white-space: nowrap;
  font-family: inherit;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.filter-pill:hover { background: var(--bg); }
.filter-pill.active {
  background: var(--primary-dark);
  color: #fff;
  border-color: var(--primary-dark);
}
.filter-pill .count {
  font-size: 11px;
  opacity: .7;
}

/* 统一文章网格 */
.article-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 16px;
}
.article-grid .article-card { height: 100%; }
.article-grid .no-result {
  grid-column: 1 / -1;
  text-align: center;
  padding: 60px 20px;
  color: var(--text-muted);
  font-size: 14px;
}

/* 文章卡片 */
.article-card {
  display: block;
  background: var(--bg-white);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  text-decoration: none;
  color: var(--text);
  transition: all .2s;
  height: 100%;
  position: relative;
}
.article-card:hover {
  border-color: var(--primary);
  box-shadow: 0 4px 12px rgba(99, 102, 241, 0.12);
  transform: translateY(-2px);
}
.article-card .ac-title { font-size: 16px; font-weight: 600; margin-bottom: 8px; line-height: 1.5; }
.article-card .ac-desc { font-size: 13px; color: var(--text-muted); line-height: 1.6; }
.article-card .ac-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border-light);
}
.article-card .ac-tag {
  display: inline-block;
  font-size: 11px;
  color: var(--primary-dark);
  background: var(--primary-light);
  border-radius: 4px;
  padding: 3px 8px;
  font-weight: 500;
}
.article-card .ac-arrow {
  color: var(--text-muted);
  font-size: 12px;
  display: inline-flex;
  align-items: center;
  gap: 2px;
  transition: all .2s;
}
.article-card:hover .ac-arrow {
  color: var(--primary);
  transform: translateX(2px);
}

/* 平板 */
@media (max-width: 1024px) {
  .article-wrap { padding: 20px 20px 56px; }
  .article-list-hero { padding: 36px 0 20px; }
  .article-list-hero h1 { font-size: 28px; }
  .article-grid {
    grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
    gap: 14px;
  }
}

/* 移动端 */
@media (max-width: 768px) {
  .article-header h1 { font-size: 24px; }
  .article-body { font-size: 15px; }
  .article-body h2 { font-size: 20px; }
  .article-wrap { padding: 16px 16px 48px; }

  /* 列表页响应式 */
  .article-list-hero { padding: 24px 0 16px; }
  .article-list-hero h1 { font-size: 22px; }
  .article-list-hero p { font-size: 14px; }
  .filter-bar { padding: 12px 0; }
  .filter-pill { font-size: 12px; padding: 5px 12px; }
  .article-grid {
    grid-template-columns: 1fr;
    gap: 12px;
  }
  .article-card { padding: 16px; }
  .article-card .ac-title { font-size: 15px; }
  .search-box { margin-top: 16px; }
  .search-box input { padding: 10px 16px 10px 40px; font-size: 13px; }
}

@media (max-width: 480px) {
  .article-wrap { padding: 12px 12px 40px; }
  .article-list-hero h1 { font-size: 20px; }
  .article-list-hero p { font-size: 13px; }
  .article-stats { font-size: 12px; }
}
