/* babianai.com — Docs / Posts / Category extra styles
   保持紫黑风格，沿用 wqpnkmfbtz.css 的 --purple-*、--bg-*、--text 变量
   仅扩充教程列表、文章页、分类页、面包屑、TOC、FAQ 视觉
*/

/* ====== Breadcrumb ====== */
.crumb {
  display: flex; flex-wrap: wrap; align-items: center; gap: 6px;
  font-size: 0.85rem; color: var(--white-60);
  padding: 24px 0 8px;
}
.crumb a { color: var(--purple-3); transition: color var(--transition); }
.crumb a:hover { color: var(--white); }
.crumb__sep { color: var(--white-40); }
.crumb__current { color: var(--white-80); }

/* ====== Docs Section（首页插入「最新教程」与「教程分类」） ====== */
.docs-section {
  padding: 80px 0;
  position: relative;
}
.docs-section .section-header { margin-bottom: 48px; }

.docs-cardgrid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 22px;
}

.docs-card {
  display: block;
  padding: 22px 22px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
  transition: all var(--transition);
  text-decoration: none;
  color: inherit;
  position: relative;
  overflow: hidden;
}
.docs-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at top right, rgba(108,71,255,0.10), transparent 60%);
  opacity: 0;
  transition: opacity var(--transition);
  pointer-events: none;
}
.docs-card:hover {
  border-color: var(--purple-border);
  background: var(--bg-card-hover);
  transform: translateY(-2px);
  box-shadow: 0 12px 32px rgba(108,71,255,0.12);
}
.docs-card:hover::before { opacity: 1; }

.docs-card__title {
  font-size: 1.08rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 10px;
  letter-spacing: -0.01em;
  line-height: 1.35;
}
.docs-card__desc {
  font-size: 0.88rem;
  color: var(--white-60);
  line-height: 1.6;
  margin-bottom: 14px;
}
.docs-card__list {
  list-style: none;
  padding: 0;
  margin: 12px 0 0;
}
.docs-card__list li {
  font-size: 0.84rem;
  color: var(--white-60);
  padding: 4px 0;
  display: flex;
  gap: 6px;
  line-height: 1.45;
}
.docs-card__bullet { color: var(--purple-3); flex-shrink: 0; }
.docs-card__count {
  font-size: 0.78rem;
  color: var(--purple-3);
  margin-top: 12px;
  font-weight: 600;
}

/* ====== Post List（首页「最新教程」 / /docs/ 列表 / 分类页列表） ====== */
.postlist { list-style: none; padding: 0; margin: 0; }
.postlist__item {
  padding: 22px 0;
  border-bottom: 1px solid var(--border);
}
.postlist__item:last-child { border-bottom: none; }

.postlist__title {
  display: inline-block;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: -0.01em;
  line-height: 1.4;
  margin-bottom: 8px;
  transition: color var(--transition);
}
.postlist__title:hover { color: var(--purple-3); }

.postlist__meta {
  display: flex;
  gap: 12px;
  align-items: center;
  font-size: 0.82rem;
  color: var(--white-40);
  margin-bottom: 8px;
}
.postlist__date::before { content: '· '; color: var(--white-40); }
.postlist__date:first-child::before { content: ''; }
.postlist__chip {
  background: rgba(108,71,255,0.12);
  border: 1px solid var(--purple-border);
  color: var(--purple-3);
  padding: 2px 10px;
  border-radius: 100px;
  font-size: 0.74rem;
  font-weight: 600;
}
.postlist__desc {
  color: var(--white-60);
  line-height: 1.65;
  font-size: 0.92rem;
}

.viewall {
  margin-top: 28px;
  text-align: center;
}
.viewall a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--purple-3);
  font-weight: 600;
  font-size: 0.95rem;
  transition: color var(--transition);
}
.viewall a:hover { color: var(--white); }

/* ====== Page Hero（教程列表 / 分类 / 文章 顶部） ====== */
.page-hero {
  padding: 64px 0 36px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.page-hero h1 {
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  margin-bottom: 14px;
  color: var(--white);
}
.page-hero__lede {
  font-size: 1.05rem;
  color: var(--white-60);
  max-width: 720px;
  line-height: 1.7;
}
.page-hero__meta {
  display: flex; gap: 14px; flex-wrap: wrap; align-items: center;
  margin-top: 18px; font-size: 0.85rem; color: var(--white-40);
}

/* ====== Article Body ====== */
.article {
  padding: 36px 0 72px;
}
.article__layout {
  display: grid;
  grid-template-columns: 1fr 240px;
  gap: 48px;
  max-width: 1140px;
  margin: 0 auto;
}
@media (max-width: 900px) {
  .article__layout { grid-template-columns: 1fr; gap: 24px; }
}

.prose {
  color: var(--text);
  font-size: 1rem;
  line-height: 1.85;
}
.prose h2 {
  font-size: 1.55rem;
  margin: 44px 0 18px;
  font-weight: 700;
  color: var(--white);
  letter-spacing: -0.02em;
  padding-top: 8px;
  scroll-margin-top: 80px;
}
.prose h3 {
  font-size: 1.2rem;
  margin: 28px 0 12px;
  font-weight: 600;
  color: var(--white);
  scroll-margin-top: 80px;
}
.prose p { margin: 14px 0; color: var(--white-80); }
.prose strong { color: var(--white); font-weight: 700; }
.prose a {
  color: var(--purple-3);
  text-decoration: underline;
  text-decoration-color: var(--purple-border);
  text-underline-offset: 3px;
  transition: color var(--transition);
}
.prose a:hover { color: var(--white); }
.prose ul, .prose ol { margin: 14px 0; padding-left: 28px; color: var(--white-80); }
.prose li { margin: 6px 0; line-height: 1.75; }
.prose table {
  width: 100%;
  border-collapse: collapse;
  margin: 22px 0;
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  overflow: hidden;
  font-size: 0.92rem;
}
.prose th, .prose td {
  padding: 11px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
  color: var(--white-80);
}
.prose th {
  background: var(--bg-3);
  color: var(--white);
  font-weight: 600;
  font-size: 0.88rem;
  letter-spacing: 0.01em;
}
.prose tr:last-child td { border-bottom: none; }
.prose blockquote {
  border-left: 3px solid var(--purple-1);
  padding: 6px 18px;
  margin: 18px 0;
  background: rgba(108,71,255,0.06);
  color: var(--white-80);
  border-radius: 0 var(--radius) var(--radius) 0;
}
.prose code {
  background: var(--bg-3);
  border: 1px solid var(--border);
  padding: 2px 6px;
  border-radius: 4px;
  font-family: var(--mono);
  font-size: 0.88em;
  color: var(--purple-3);
}

/* ====== TOC ====== */
.toc {
  position: sticky;
  top: 88px;
  align-self: start;
  max-height: calc(100vh - 120px);
  overflow-y: auto;
  padding: 18px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
}
.toc__title {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--white);
  letter-spacing: 0.05em;
  text-transform: uppercase;
  margin-bottom: 12px;
}
.toc__list { list-style: none; padding: 0; margin: 0; }
.toc__item { padding: 4px 0; }
.toc__item a {
  display: block;
  font-size: 0.85rem;
  color: var(--white-60);
  line-height: 1.5;
  transition: color var(--transition);
}
.toc__item--lv3 a { padding-left: 12px; font-size: 0.82rem; color: var(--white-40); }
.toc__item a:hover { color: var(--purple-3); }
.toc__more {
  margin-top: 18px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
}
@media (max-width: 900px) {
  .toc { position: static; max-height: none; }
}

/* ====== Prev / Next ====== */
.prevnext {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin: 48px 0 0;
  padding-top: 32px;
  border-top: 1px solid var(--border);
}
@media (max-width: 640px) {
  .prevnext { grid-template-columns: 1fr; }
}
.prevnext__item {
  display: block;
  padding: 16px 18px;
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  transition: all var(--transition);
}
.prevnext__item:hover {
  border-color: var(--purple-border);
  background: var(--bg-card-hover);
}
.prevnext__lab {
  font-size: 0.78rem;
  color: var(--purple-3);
  font-weight: 600;
  margin-bottom: 4px;
  display: block;
}
.prevnext__t {
  font-size: 0.95rem;
  color: var(--white);
  font-weight: 600;
  line-height: 1.4;
  display: block;
}
.prevnext__next { text-align: right; }

/* ====== Pagination ====== */
.pager {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 36px;
  flex-wrap: wrap;
}
.pager__btn, .pager__num {
  padding: 8px 14px;
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius);
  color: var(--white-80);
  font-size: 0.9rem;
  font-weight: 600;
  transition: all var(--transition);
}
.pager__btn:hover, .pager__num:hover {
  border-color: var(--purple-border);
  color: var(--white);
}
.pager__num.is-current {
  background: var(--purple-1);
  color: var(--white);
  border-color: var(--purple-1);
}
.pager__btn.is-disabled { opacity: 0.4; pointer-events: none; }

/* ====== FAQ ====== */
.faq { margin: 24px 0; display: flex; flex-direction: column; gap: 12px; }
.faq__item {
  background: var(--bg-card);
  border: 1px solid var(--border-2);
  border-radius: var(--radius-lg);
  overflow: hidden;
}
.faq__q {
  cursor: pointer;
  padding: 16px 22px;
  font-weight: 600;
  color: var(--white);
  list-style: none;
  position: relative;
  font-size: 0.98rem;
  transition: color var(--transition);
}
.faq__q::-webkit-details-marker { display: none; }
.faq__q::after {
  content: '+';
  position: absolute;
  right: 22px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--purple-3);
  font-size: 1.4rem;
  transition: transform var(--transition);
}
details[open] .faq__q::after { content: '−'; }
.faq__a {
  padding: 0 22px 18px;
  color: var(--white-80);
  font-size: 0.92rem;
  line-height: 1.7;
}

/* ====== Chip / Tag list ====== */
.chip {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(108,71,255,0.12);
  border: 1px solid var(--purple-border);
  color: var(--purple-3);
  border-radius: 100px;
  font-size: 0.78rem;
  font-weight: 600;
  transition: all var(--transition);
}
.chip:hover { background: rgba(108,71,255,0.2); color: var(--white); }

/* ====== 404 ====== */
.err-404 {
  text-align: center;
  padding: 120px 24px;
  max-width: 480px;
  margin: 0 auto;
}
.err-404__code {
  font-size: 6rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  background: linear-gradient(135deg, var(--purple-3), var(--purple-1));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
  margin-bottom: 20px;
}
.err-404__title { font-size: 1.8rem; color: var(--white); margin-bottom: 14px; }
.err-404__body { color: var(--white-60); margin-bottom: 30px; }

/* ====== Mini nav extension（旧 nav 加一项「教程」） ====== */
.nav-links a.is-active { color: var(--white); background: var(--white-15); }

/* Home cat-block list */
.cat-list { display: grid; gap: 32px; max-width: 1100px; margin: 0 auto; }
.cat-block { background: rgba(255,255,255,0.03); border: 1px solid rgba(255,255,255,0.08); border-radius: 16px; padding: 24px 28px; }
.cat-block__head { margin-bottom: 16px; display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 8px; }
.cat-block__title { font-size: 22px; font-weight: 700; margin: 0; }
.cat-block__title a { color: inherit; text-decoration: none; }
.cat-block__desc { color: rgba(255,255,255,0.65); font-size: 14px; margin: 4px 0 0; flex-basis: 100%; }
.cat-block__more { font-size: 13px; color: var(--accent, #7c5cff); text-decoration: none; }
.cat-block__list { list-style: none; padding: 0; margin: 0; display: grid; gap: 10px; }
.cat-block__item { display: flex; justify-content: space-between; align-items: baseline; gap: 16px; padding: 8px 0; border-bottom: 1px dashed rgba(255,255,255,0.06); }
.cat-block__item:last-child { border-bottom: none; }
.cat-block__link { color: rgba(255,255,255,0.9); text-decoration: none; font-size: 15px; }
.cat-block__date { color: rgba(255,255,255,0.45); font-size: 12px; white-space: nowrap; }

/* === V-C: Cards Grid + Feed === */
.cat-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 20px; max-width: 1200px; margin: 0 auto; }
.cat-card { display: block; padding: 24px; border-radius: 16px; background: rgba(255,255,255,0.025); border: 1px solid rgba(255,255,255,0.06); text-decoration: none; color: inherit; position: relative; transition: transform 0.15s, border-color 0.15s; overflow: hidden; }
.cat-card:hover { transform: translateY(-3px); border-color: var(--accent, #7c5cff); }
.cat-card__num { position: absolute; top: 16px; right: 18px; font-size: 36px; font-weight: 900; opacity: 0.1; line-height: 1; }
.cat-card__title { font-size: 20px; font-weight: 700; margin: 0 0 8px; }
.cat-card__desc { font-size: 13px; opacity: 0.65; margin: 0 0 16px; line-height: 1.5; }
.cat-card__list { list-style: none; padding: 0; margin: 0 0 14px; display: grid; gap: 8px; }
.cat-card__list li { font-size: 13px; opacity: 0.85; padding-left: 14px; position: relative; line-height: 1.4; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.cat-card__list li::before { content: '›'; position: absolute; left: 0; opacity: 0.5; }
.cat-card__count { font-size: 12px; opacity: 0.7; }
.cat-card__count--empty { opacity: 0.4; }
.feed { max-width: 720px; margin: 0 auto; display: flex; flex-direction: column; gap: 4px; }
.feed__item { display: grid; grid-template-columns: 64px 1fr; gap: 16px; padding: 18px 0; border-bottom: 1px solid rgba(255,255,255,0.05); }
.feed__item:last-child { border-bottom: none; }
.feed__date { display: flex; flex-direction: column; align-items: center; padding-top: 4px; line-height: 1; }
.feed__day { font-size: 24px; font-weight: 700; }
.feed__ym { font-size: 11px; opacity: 0.5; margin-top: 4px; }
.feed__body { display: flex; flex-direction: column; gap: 6px; }
.feed__title { font-size: 16px; font-weight: 600; text-decoration: none; color: inherit; }
.feed__title:hover { color: var(--accent, #7c5cff); }
.feed__desc { font-size: 13px; opacity: 0.65; margin: 0; line-height: 1.5; }
.feed__chip { font-size: 11px; padding: 2px 8px; border-radius: 999px; background: rgba(255,255,255,0.06); align-self: flex-start; opacity: 0.7; }

/* ============================================================
   biabatech.com — Style Completion (Group S3 / Variant C)
   独立配色：青蓝科技调（基于主 CSS 的 --cyan / --blue 体系）
   仅追加；映射 docs.css 内部用到的未定义变量到本站主色
   ============================================================ */
:root {
  --purple-1: #06b6d4;
  --purple-2: #00c8ff;
  --purple-3: #00d4e8;
  --purple-border: rgba(0, 200, 255, 0.32);
  --white-15: rgba(255, 255, 255, 0.10);
  --white-40: #6b7592;
  --white-60: #a8b2cc;
  --white-80: #d8dde8;
  --bg-card: #1e2436;
  --bg-card-hover: #242a3d;
  --bg-3: #1a1f2e;
  --border-2: #2a3248;
  --transition: 0.22s cubic-bezier(0.4, 0, 0.2, 1);
  --mono: 'JetBrains Mono', 'Fira Code', 'SF Mono', Consolas, monospace;
}

/* ====== Layout container ====== */
.container {
  max-width: var(--max, 1200px);
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

/* ====== Gradient text accent ====== */
.gradient-text {
  background: linear-gradient(135deg, #00c8ff 0%, #3b82f6 55%, #06b6d4 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
  font-weight: 800;
}

/* ====== Hero — additional / variant elements ====== */
.hero-badge-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--cyan, #00c8ff);
  box-shadow: 0 0 12px rgba(0, 200, 255, 0.65);
  margin-right: 8px;
  vertical-align: middle;
  animation: biaba-pulse 2.2s ease-in-out infinite;
}
@keyframes biaba-pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.55; transform: scale(1.25); }
}

.hero-desc {
  font-size: 1.05rem;
  color: var(--text2, #a8b2cc);
  line-height: 1.75;
  max-width: 720px;
  margin: 14px auto 28px;
  text-align: center;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: center;
  align-items: center;
  margin-top: 8px;
}

/* ====== Hero CTA buttons ====== */
.btn-hero-primary,
.btn-hero-secondary {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 28px;
  font-size: 1rem;
  font-weight: 700;
  border-radius: 10px;
  cursor: pointer;
  letter-spacing: 0.01em;
  text-decoration: none;
  border: 1px solid transparent;
  transition: transform var(--transition), box-shadow var(--transition), opacity var(--transition), background var(--transition), border-color var(--transition);
  white-space: nowrap;
}
.btn-hero-primary {
  background: linear-gradient(135deg, #00c8ff 0%, #2563eb 100%);
  color: #ffffff;
  box-shadow: 0 6px 22px rgba(0, 200, 255, 0.32);
}
.btn-hero-primary:hover {
  opacity: 0.94;
  transform: translateY(-2px);
  box-shadow: 0 10px 30px rgba(0, 200, 255, 0.45);
}
.btn-hero-secondary {
  background: rgba(0, 200, 255, 0.06);
  color: #00d4e8;
  border-color: rgba(0, 200, 255, 0.4);
}
.btn-hero-secondary:hover {
  background: rgba(0, 200, 255, 0.12);
  border-color: #06b6d4;
  color: #ffffff;
  transform: translateY(-2px);
}

/* ====== Generic btn / btn-lg helpers ====== */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 20px;
  font-weight: 600;
  border-radius: 8px;
  text-decoration: none;
  border: 1px solid transparent;
  cursor: pointer;
  transition: all var(--transition);
}
.btn-lg {
  padding: 15px 32px;
  font-size: 1.05rem;
  border-radius: 12px;
  font-weight: 700;
}

/* ====== Strengthen cat-card hover for cyan theme ====== */
.cat-card { background: rgba(0, 200, 255, 0.025); }
.cat-card:hover {
  border-color: rgba(0, 200, 255, 0.4);
  background: rgba(0, 200, 255, 0.05);
  box-shadow: 0 10px 28px rgba(0, 200, 255, 0.10);
}
.cat-card__num { color: #00c8ff; }
.cat-card__list li::before { color: #00d4e8; opacity: 0.8; }

/* ====== Feed polish ====== */
.feed__day { color: #00d4e8; }
.feed__chip {
  background: rgba(0, 200, 255, 0.10);
  color: #00d4e8;
  border: 1px solid rgba(0, 200, 255, 0.22);
  opacity: 1;
}

/* ====== Section header spacing ====== */
.section-header { text-align: center; margin: 0 auto 32px; max-width: 760px; }
.section-header h2 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); margin: 10px 0 8px; color: var(--white, #fff); letter-spacing: -0.02em; }
.section-header p { color: var(--text2, #a8b2cc); font-size: 0.95rem; line-height: 1.6; }
.section-tag {
  display: inline-block;
  padding: 4px 14px;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #00d4e8;
  background: rgba(0, 200, 255, 0.08);
  border: 1px solid rgba(0, 200, 255, 0.22);
  border-radius: 100px;
}

/* ====== TOC levels 1/2/4/5 ====== */
.toc__item--lv1 a { padding-left: 0; font-size: 0.9rem; color: var(--white, #fff); font-weight: 600; }
.toc__item--lv2 a { padding-left: 0; font-size: 0.86rem; }
.toc__item--lv4 a { padding-left: 22px; font-size: 0.8rem; color: #6b7592; }
.toc__item--lv5 a { padding-left: 30px; font-size: 0.78rem; color: #6b7592; }

/* ====== Responsive (≤768px) ====== */
@media (max-width: 768px) {
  .container { padding: 0 16px; }
  .hero-actions { flex-direction: column; align-items: stretch; }
  .btn-hero-primary, .btn-hero-secondary { width: 100%; }
  .hero-desc { font-size: 0.96rem; }
  .cat-cards { grid-template-columns: 1fr; gap: 14px; }
  .cat-card { padding: 18px; }
  .feed__item { grid-template-columns: 52px 1fr; gap: 12px; padding: 14px 0; }
  .feed__day { font-size: 20px; }
  .feed__title { font-size: 15px; }
  .section-header { margin-bottom: 24px; }
  .docs-section { padding: 48px 0; }
  .page-hero { padding: 40px 0 24px; }
}
