:root {
  --ink: #1a2233;
  --ink-soft: #4a5568;
  --paper: #fdfcfb;
  --panel: #ffffff;
  --line: #e6e2da;
  --brand: #b23b2e;
  --brand-dark: #8f2e24;
  --accent: #c9a15a;
  --radius: 10px;
  --maxw: 1080px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", -apple-system, sans-serif;
  color: var(--ink);
  background: var(--paper);
  line-height: 1.65;
}

a { color: var(--brand-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; }

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 24px;
}

/* ---- Header ---- */
header.site {
  border-bottom: 1px solid var(--line);
  background: var(--panel);
  position: sticky;
  top: 0;
  z-index: 20;
}
header.site .bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  max-width: var(--maxw);
  margin: 0 auto;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.15rem;
  color: var(--ink);
}
.brand .mark {
  width: 34px; height: 34px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--brand), var(--accent));
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 800; font-size: 1rem;
}
nav.main a {
  margin-left: 26px;
  color: var(--ink-soft);
  font-weight: 500;
  font-size: 0.95rem;
}
nav.main a:hover { color: var(--brand-dark); text-decoration: none; }

/* ---- Hero ---- */
.hero {
  padding: 64px 0 48px;
  text-align: center;
  background:
    radial-gradient(600px 300px at 50% -60px, rgba(178,59,46,0.08), transparent);
}
.hero h1 {
  font-size: clamp(1.9rem, 4vw, 2.7rem);
  margin: 0 0 14px;
  letter-spacing: -0.01em;
}
.hero p.lead {
  color: var(--ink-soft);
  font-size: 1.1rem;
  max-width: 640px;
  margin: 0 auto 28px;
}
.cta-row { display: flex; gap: 14px; justify-content: center; flex-wrap: wrap; }
.btn {
  display: inline-block;
  padding: 12px 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.98rem;
}
.btn.primary { background: var(--brand); color: #fff; }
.btn.primary:hover { background: var(--brand-dark); text-decoration: none; }
.btn.ghost { border: 1px solid var(--line); color: var(--ink); background: var(--panel); }
.btn.ghost:hover { border-color: var(--brand); text-decoration: none; }

/* ---- Sections ---- */
section { padding: 56px 0; }
section.alt { background: #f6f2ec; }
h2.section-title {
  font-size: 1.6rem;
  margin: 0 0 8px;
  text-align: center;
}
p.section-sub {
  text-align: center;
  color: var(--ink-soft);
  max-width: 560px;
  margin: 0 auto 36px;
}

/* ---- Card grid ---- */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 22px;
}
.card {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.card .icon {
  width: 42px; height: 42px;
  border-radius: 10px;
  background: #f6ede6;
  display: flex; align-items: center; justify-content: center;
  font-size: 1.3rem;
  margin-bottom: 14px;
}
.card h3 { margin: 0 0 8px; font-size: 1.05rem; }
.card p { margin: 0; color: var(--ink-soft); font-size: 0.94rem; }

/* ---- Article list ---- */
.article-row {
  display: flex;
  gap: 18px;
  padding: 20px 0;
  border-bottom: 1px solid var(--line);
  align-items: flex-start;
}
.article-row .tag {
  flex: none;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--brand-dark);
  background: #f6ede6;
  padding: 4px 10px;
  border-radius: 999px;
  margin-top: 3px;
}
.article-row h3 { margin: 0 0 6px; font-size: 1.08rem; }
.article-row p { margin: 0; color: var(--ink-soft); font-size: 0.93rem; }

/* ---- Article page ---- */
.article-hero {
  padding: 40px 0 20px;
  border-bottom: 1px solid var(--line);
}
.breadcrumb { font-size: 0.85rem; color: var(--ink-soft); margin-bottom: 14px; }
.article-hero h1 { font-size: clamp(1.6rem, 3.4vw, 2.2rem); margin: 0 0 10px; }
.meta { color: var(--ink-soft); font-size: 0.88rem; }

.prose { max-width: 760px; margin: 0 auto; padding: 40px 24px; }
.prose h2 { margin-top: 2.2em; font-size: 1.3rem; border-left: 4px solid var(--brand); padding-left: 12px; }
.prose h3 { margin-top: 1.6em; font-size: 1.08rem; color: var(--brand-dark); }
.prose p { color: #2b3242; }
.prose ol, .prose ul { padding-left: 1.3em; }
.prose li { margin-bottom: 0.5em; }
.callout {
  background: #f6ede6;
  border-left: 4px solid var(--accent);
  border-radius: 6px;
  padding: 14px 18px;
  margin: 1.6em 0;
  font-size: 0.93rem;
}
.callout.warn { background: #fbeceb; border-left-color: var(--brand); }
.step-num {
  display: inline-flex;
  width: 26px; height: 26px;
  border-radius: 50%;
  background: var(--brand);
  color: #fff;
  align-items: center; justify-content: center;
  font-size: 0.85rem; font-weight: 700;
  margin-right: 10px;
}

/* ---- Footer ---- */
footer.site {
  border-top: 1px solid var(--line);
  padding: 32px 0;
  color: var(--ink-soft);
  font-size: 0.88rem;
  text-align: center;
}

@media (max-width: 640px) {
  nav.main a { margin-left: 14px; font-size: 0.85rem; }
  .article-row { flex-direction: column; }
}
