/* ==========================================================================
   content.css — 文档 / 博客 / 更新日志 / 中文落地页 共用样式
   与 style.css 共用同一套设计令牌，视觉保持一致；只补充长文排版所需的部分。
   页面按需引入：<link rel="stylesheet" href="/css/content.css">
   ========================================================================== */

/* ---------- 顶部导航（复用官网，去掉语言切换） ---------- */
.c-nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255, 255, 255, .85);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.c-nav-inner {
  max-width: 1120px; margin-inline: auto; padding-inline: 24px;
  display: flex; align-items: center; justify-content: space-between;
  height: 68px; gap: 16px;
}
.c-brand {
  display: flex; align-items: center; gap: 10px;
  color: var(--text); text-decoration: none;
  font-weight: 800; font-size: 19px; letter-spacing: -.02em;
}
.c-brand img { width: 30px; height: 30px; border-radius: 7px; }
.c-nav-links { display: flex; gap: 28px; align-items: center; }
.c-nav-links a {
  color: var(--muted); text-decoration: none;
  font-size: 15px; font-weight: 500; transition: color .18s;
}
.c-nav-links a:hover { color: var(--accent-dark); }
.c-nav-links a.is-current { color: var(--accent-dark); font-weight: 600; }
@media (max-width: 720px) {
  .c-nav-links { gap: 16px; }
  .c-nav-links a { font-size: 13.5px; }
  .c-nav-links .hide-sm { display: none; }
}

/* ---------- 按钮 ---------- */
.c-btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  padding: 13px 26px; border-radius: 999px; border: 1px solid transparent;
  font: inherit; font-size: 15.5px; font-weight: 600; text-decoration: none;
  cursor: pointer; transition: transform .18s, box-shadow .18s, border-color .18s, color .18s;
}
.c-btn-primary {
  background: linear-gradient(180deg, #22c55e, var(--accent));
  color: #fff;
  box-shadow: 0 6px 18px rgba(22, 163, 74, .30), inset 0 1px 0 rgba(255, 255, 255, .25);
}
.c-btn-primary:hover { transform: translateY(-2px); box-shadow: 0 12px 26px rgba(22, 163, 74, .38); }
.c-btn-ghost {
  border-color: var(--border); color: var(--text);
  background: var(--card); box-shadow: var(--shadow-sm);
}
.c-btn-ghost:hover { border-color: var(--accent); color: var(--accent-dark); }
.c-btn-lg { padding: 15px 34px; font-size: 16.5px; }

/* ---------- 页面骨架 ---------- */
.c-wrap { max-width: 780px; margin-inline: auto; padding-inline: 24px; }
.c-wrap-wide { max-width: 1120px; margin-inline: auto; padding-inline: 24px; }

.c-hero { padding-block: 64px 40px; text-align: center; }
.c-hero h1 {
  font-size: clamp(30px, 5vw, 46px); font-weight: 800;
  letter-spacing: -.03em; line-height: 1.14;
}
.c-hero h1 em { font-style: normal; color: var(--accent-dark); }
.c-hero .c-sub {
  color: var(--muted); font-size: clamp(15.5px, 2vw, 18px);
  max-width: 640px; margin: 18px auto 30px;
}
.c-hero-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

.c-kicker {
  display: inline-block; padding: 6px 14px; border-radius: 999px;
  background: var(--accent-soft); border: 1px solid var(--accent-border);
  color: var(--accent-dark); font-size: 13px; font-weight: 600;
  letter-spacing: .02em; margin-bottom: 16px;
}

.c-section { padding-block: 72px; }
.c-section.alt { background: var(--bg-soft); }
.c-section h2 {
  font-size: clamp(26px, 3.6vw, 34px); font-weight: 800;
  letter-spacing: -.02em; line-height: 1.2;
}
.c-section > .c-wrap > h2, .c-section > .c-wrap-wide > h2 { text-align: center; }
.c-section-sub {
  text-align: center; color: var(--muted);
  max-width: 620px; margin: 14px auto 48px; font-size: 16.5px;
}

/* ---------- 长文正文排版 ---------- */
.c-article { padding-block: 48px 80px; }
.c-article-meta {
  color: var(--muted); font-size: 14px;
  display: flex; gap: 14px; flex-wrap: wrap; align-items: center;
  padding-bottom: 24px; margin-bottom: 32px; border-bottom: 1px solid var(--border);
}
.c-article h2 {
  font-size: 25px; font-weight: 800; letter-spacing: -.02em;
  margin-top: 48px; margin-bottom: 14px; scroll-margin-top: 88px;
}
.c-article h3 {
  font-size: 19px; font-weight: 700;
  margin-top: 32px; margin-bottom: 10px; scroll-margin-top: 88px;
}
.c-article p { margin-bottom: 18px; font-size: 16.5px; }
.c-article ul, .c-article ol { margin: 0 0 22px 1.35em; font-size: 16.5px; }
.c-article li { margin-bottom: 8px; }
.c-article li > strong { color: var(--text); }
.c-article a { color: var(--accent-dark); text-decoration: underline; text-underline-offset: 2px; }
.c-article a:hover { color: var(--accent); }
.c-article strong { font-weight: 700; }

.c-article blockquote {
  border-left: 3px solid var(--accent);
  background: var(--accent-soft);
  padding: 16px 20px; border-radius: 0 12px 12px 0;
  margin: 0 0 24px; color: #14532d; font-size: 16px;
}
.c-article blockquote p:last-child { margin-bottom: 0; }

.c-article pre {
  background: #0f172a; color: #dbe4ee;
  padding: 18px 20px; border-radius: 12px; overflow-x: auto;
  font-size: 13.5px; line-height: 1.7; margin-bottom: 24px;
  font-family: "Cascadia Mono", Consolas, "SF Mono", Menlo, monospace;
}
.c-article code {
  font-family: "Cascadia Mono", Consolas, "SF Mono", Menlo, monospace;
  font-size: .9em;
}
.c-article :not(pre) > code {
  background: var(--bg-soft); border: 1px solid var(--border);
  padding: 2px 6px; border-radius: 6px; color: #b91c1c;
}
/* 代码块里的注释 / 字符串轻微着色，避免整块死板 */
.c-article pre .c { color: #7d8fa6; font-style: italic; }
.c-article pre .s { color: #a5d6ff; }
.c-article pre .k { color: #ff8f7a; }

.c-article table {
  width: 100%; border-collapse: collapse;
  margin-bottom: 26px; font-size: 15px; display: block; overflow-x: auto;
}
.c-article th, .c-article td {
  border: 1px solid var(--border); padding: 11px 14px; text-align: start; vertical-align: top;
}
.c-article th { background: var(--bg-soft); font-weight: 700; white-space: nowrap; }
.c-article tbody tr:nth-child(even) td { background: #fcfdfc; }

.c-article figure { margin-bottom: 26px; }
.c-article figcaption { color: var(--muted); font-size: 13.5px; margin-top: 8px; text-align: center; }

/* ---------------- 提示块 ---------------- */
.c-note {
  border: 1px solid var(--border); border-left: 3px solid var(--accent);
  background: var(--bg-soft); border-radius: 0 12px 12px 0;
  padding: 16px 20px; margin-bottom: 24px; font-size: 15.5px;
}
.c-note p:last-child { margin-bottom: 0; }
.c-note strong { display: block; margin-bottom: 4px; }

/* ---------------- 卡片网格 ---------------- */
.c-grid { display: grid; gap: 22px; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.c-card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: var(--radius); padding: 26px;
  box-shadow: var(--shadow-sm); transition: transform .2s, box-shadow .2s, border-color .2s;
}
.c-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: var(--accent-border); }
.c-card h3 { font-size: 18px; margin-bottom: 8px; }
.c-card p { color: var(--muted); font-size: 14.5px; margin-bottom: 14px; }
.c-card .c-more { color: var(--accent-dark); font-weight: 600; font-size: 14.5px; text-decoration: none; }
.c-card .c-more:hover { text-decoration: underline; }
.c-card-icon { font-size: 28px; margin-bottom: 14px; }

/* ---------------- 文章列表 ---------------- */
.c-postlist { display: grid; gap: 18px; }
.c-post {
  display: block; text-decoration: none; color: inherit;
  background: var(--card); border: 1px solid var(--border);
  border-radius: 14px; padding: 24px 26px;
  box-shadow: var(--shadow-sm); transition: border-color .18s, transform .18s;
}
.c-post:hover { border-color: var(--accent-border); transform: translateY(-2px); }
.c-post h3 { font-size: 19px; margin-bottom: 8px; letter-spacing: -.01em; }
.c-post p { color: var(--muted); font-size: 15px; margin-bottom: 12px; }
.c-post time { color: var(--muted); font-size: 13.5px; }

/* ---------------- 更新时间线 ---------------- */
.c-log { position: relative; padding-left: 28px; }
.c-log::before {
  content: ''; position: absolute; left: 7px; top: 8px; bottom: 8px;
  width: 2px; background: var(--border);
}
.c-entry { position: relative; padding-bottom: 40px; }
.c-entry:last-child { padding-bottom: 0; }
.c-entry::before {
  content: ''; position: absolute; left: -28px; top: 9px;
  width: 12px; height: 12px; border-radius: 50%;
  background: var(--accent); border: 2px solid var(--bg);
  box-shadow: 0 0 0 2px var(--accent-soft);
}
.c-entry h3 { font-size: 20px; margin-bottom: 6px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.c-entry time { color: var(--muted); font-size: 13.5px; font-weight: 500; }
.c-entry ul { margin: 12px 0 0 1.2em; color: var(--muted); font-size: 15.5px; }
.c-entry li { margin-bottom: 7px; }
.c-tag {
  display: inline-block; padding: 3px 10px; border-radius: 999px;
  font-size: 12px; font-weight: 600; letter-spacing: .02em;
  background: var(--accent-soft); color: var(--accent-dark);
  border: 1px solid var(--accent-border);
}
.c-tag.gray { background: var(--bg-soft); color: var(--muted); border-color: var(--border); }

/* ---------------- 文末 CTA ---------------- */
.c-cta {
  background: linear-gradient(135deg, #ecfdf3, #f0fdf4);
  border: 1px solid var(--accent-border);
  border-radius: 20px; padding: 44px 32px; text-align: center;
  margin-top: 56px;
}
.c-cta h2 { font-size: 26px; margin-bottom: 10px; }
.c-cta p { color: var(--muted); margin-bottom: 24px; font-size: 16px; }
.c-cta-actions { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }

/* ---------------- 面包屑 ---------------- */
.c-crumbs { font-size: 14px; color: var(--muted); padding-block: 20px 0; }
.c-crumbs a { color: var(--muted); text-decoration: none; }
.c-crumbs a:hover { color: var(--accent-dark); }
.c-crumbs span { margin-inline: 8px; opacity: .5; }

/* ---------------- 页脚 ---------------- */
.c-footer {
  border-top: 1px solid var(--border);
  padding-block: 36px; color: var(--muted); font-size: 14px;
}
.c-footer-inner {
  max-width: 1120px; margin-inline: auto; padding-inline: 24px;
  display: flex; justify-content: space-between; align-items: center;
  gap: 16px; flex-wrap: wrap;
}
.c-footer a { color: var(--muted); text-decoration: none; margin-inline-start: 18px; }
.c-footer a:hover { color: var(--accent-dark); }
.c-footer-inner nav { display: flex; flex-wrap: wrap; }
/* 支持邮箱：页脚必须肉眼可见，故加深颜色并加下划线 */
.c-foot-contact { margin-top: 10px; font-size: 14px; }
.c-foot-contact a {
  margin-inline-start: 0; color: var(--accent-dark); font-weight: 600;
  text-decoration: underline; text-underline-offset: 2px;
}
.c-foot-contact .c-foot-alt { margin-inline-start: 0; color: var(--muted); font-weight: 400; }
