/*
 * landscape-core.css
 * 知识地图全库公共核心样式。
 *
 * 设计原则：
 *   1. 只放跨分支逐字一致、或差异极小的公共规则。
 *   2. body 的 background / padding / line-height 不在此处定义
 *      （各页/各分支视觉不同，由页面内联 <style> 提供）。
 *      h1 / .subtitle 同理不在此处（部分页面需 text-align:center，是布局差异）。
 *   3. 公共类用一组"主流默认值"。任何需要不同值的页面，
 *      在 <link> 之后保留自己的 <style>，同名规则自动覆盖（同特异性下后者胜）。
 *   4. 不含 .badge.* 子类（每分支语义/配色不同），
 *      不含 .route* 族（AI/entry/tech 各页语义不同），
 *      不含各页特有组件。
 *
 * 引用方式（按页面到 pages/ 的深度调整 ../ 层数）：
 *   深度 3: <link rel="stylesheet" href="../../assets/landscape-core.css">
 *   深度 4: ../../../assets/landscape-core.css
 *   深度 5: ../../../../assets/landscape-core.css
 *   深度 6: ../../../../../assets/landscape-core.css
 */

/* ===== Reset ===== */
* { margin: 0; padding: 0; box-sizing: border-box; }
a { color: inherit; text-decoration: none; }

/* ===== Body 字体族（全库一致；背景/内边距/行高留给页面） ===== */
body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #333;
}

/* ===== 容器（默认 1380，页面可覆盖） ===== */
.container { max-width: 1380px; margin: 0 auto; }

/* ===== 顶部面包屑导航 ===== */
.top-nav {
  display: inline-flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 0.8rem;
  color: #6b7280;
  margin-bottom: 14px;
}
.top-nav a { color: #4b5563; }
.top-nav a:hover { text-decoration: none; }
.top-nav-sep { color: #9ca3af; }

/* ===== 章节标题 ===== */
.section-header {
  font-size: 1.25rem;
  font-weight: 700;
  color: #111827;
  margin: 44px 0 18px;
  padding-bottom: 10px;
  border-bottom: 2px solid #e8e8e8;
}
.section-header:first-of-type { margin-top: 0; }
.section-lead {
  font-size: 0.86rem;
  color: #6b7280;
  margin: -6px 0 18px;
}
.sub-header {
  font-size: 1.05rem;
  font-weight: 600;
  color: #333;
  margin: 24px 0 12px;
}

/* ===== 表格 .t（全库最通用的表格类） ===== */
.t {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 0.8rem;
}
.t th, .t td {
  padding: 9px 12px;
  border: 1px solid #e8e8e8;
  text-align: left;
  vertical-align: top;
}
.t th { background: #f5f5f5; font-weight: 600; color: #333; }
.t tr:hover { background: #fafafa; }

/* ===== 网格容器（默认列宽，页面常覆盖 minmax） ===== */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 12px;
  margin: 16px 0;
}

/* ===== 卡片（主流默认值；圆角/padding 各页可能微调） ===== */
.card {
  background: #fafafa;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  padding: 14px 16px;
  transition: box-shadow 0.2s;
}
a.card:hover { box-shadow: 0 2px 12px rgba(0,0,0,0.06); }
.card-title { font-size: 0.9rem; font-weight: 600; color: #1a1a1a; margin-bottom: 6px; }
.card-body { font-size: 0.8rem; color: #555; }
.card-body ul { padding-left: 16px; margin: 4px 0; }
.card-body li { margin: 2px 0; }

/* ===== 阅读定位提示框 ===== */
.scope-note {
  margin: 0 auto 28px;
  max-width: 1100px;
  background: #f9f9f9;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  padding: 14px 16px;
  font-size: 0.82rem;
  color: #555;
}
.scope-note strong { color: #333; }

/* ===== 提示框 .note ===== */
.note {
  background: #f9fafb;
  border: 1px solid #e5e7eb;
  border-radius: 8px;
  padding: 16px 18px;
  font-size: 0.82rem;
  color: #555;
  margin: 14px 0 20px;
}
.note strong { color: #333; }

/* ===== 标签 ===== */
.tags { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; align-items: center; }
.tag {
  font-size: 0.72rem;
  color: #4b5563;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  padding: 4px 8px;
}

/* ===== 依赖流程图（AI/历史等页通用） ===== */
.dep-diagram {
  background: #f9f9f9;
  border: 1px solid #e8e8e8;
  border-radius: 8px;
  padding: 24px;
  margin: 20px 0;
  overflow-x: auto;
}
.dep-flow {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0;
  flex-wrap: wrap;
  min-width: 900px;
}
.dep-node {
  padding: 10px 16px;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  text-align: center;
  min-width: 120px;
}
.dep-arrow { font-size: 1.2rem; color: #999; padding: 0 8px; }
/* n1-n6 并集配色：AI 用到 n1-n5，部分页用到 n6 */
.dep-node.n1 { background: #e8f8f5; color: #0d7377; border: 1px solid #b2dfdb; }
.dep-node.n2 { background: #f3e8ff; color: #6b21a8; border: 1px solid #d8b4fe; }
.dep-node.n3 { background: #e8f4fd; color: #1d4ed8; border: 1px solid #93c5fd; }
.dep-node.n4 { background: #fef9e7; color: #b45309; border: 1px solid #fcd34d; }
.dep-node.n5 { background: #e8fdf0; color: #047857; border: 1px solid #6ee7b7; }
.dep-node.n6 { background: #fce7f3; color: #9d174d; border: 1px solid #f9a8d4; }

/* ===== 方向卡片（AI/历史入口页通用） ===== */
.direction-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 12px;
  margin: 18px 0 26px;
}
.direction-card {
  background: #fafafa;
  border: 1px solid #e8e8e8;
  border-radius: 10px;
  padding: 14px 16px;
}
a.direction-card:hover { background: #fff; box-shadow: 0 2px 12px rgba(0,0,0,0.06); }
.direction-kicker { font-size: 0.72rem; font-weight: 700; color: #4b5563; margin-bottom: 6px; }
.direction-title { font-size: 0.9rem; font-weight: 700; color: #1a1a1a; margin-bottom: 6px; }
.direction-body { font-size: 0.78rem; color: #555; }
.direction-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.direction-tag {
  font-size: 0.68rem;
  color: #4b5563;
  background: #f3f4f6;
  border: 1px solid #e5e7eb;
  border-radius: 999px;
  padding: 3px 7px;
}

/* ===== 移动端骨架（页面可追加自己的 media 规则） ===== */
@media (max-width: 720px) {
  body { padding: 24px 14px 40px; }
  h1 { font-size: 1.55rem; }
  .grid { grid-template-columns: 1fr; }
  .direction-grid { grid-template-columns: 1fr; }
}
