:root {
  --bg: #f7f5ff;
  --surface: #ffffff;
  --text: #1f173a;
  --muted: #6d6490;
  --line: #e3dcfa;
  --primary: #6f42ff;
  --primary-deep: #5527ea;
  --header-bg: #1a1233;
  --radius: 14px;
  --container: 1160px;
}

*,
*::before,
*::after { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--text);
  background: linear-gradient(180deg, #fbfaff, #f3f0ff);
  line-height: 1.75;
}

a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; display: block; }

.container { width: min(calc(100% - 32px), var(--container)); margin: 0 auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  background: rgba(26, 18, 51, 0.94);
  border-bottom: 1px solid #35285f;
  backdrop-filter: blur(10px);
}

.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 12px 0; }
.brand { display: flex; align-items: center; gap: 10px; color: #fff; font-weight: 700; }
.brand img { border-radius: 8px; }

.nav-main { list-style: none; display: flex; margin: 0; padding: 0; gap: 6px; }
.nav-main a { display: block; color: #c5b9ef; border-radius: 8px; padding: 8px 12px; }
.nav-main a.active, .nav-main a:hover { color: #fff; background: #3c2f68; text-decoration: none; }

.nav-toggle {
  display: none;
  border: 1px solid #58488f;
  background: #2a1f4e;
  color: #e9e2ff;
  border-radius: 8px;
  padding: 8px 10px;
}

.breadcrumb-wrap {
  background: #fff;
  border-bottom: 1px solid var(--line);
  padding: 10px 0;
  font-size: 14px;
}
.breadcrumb-wrap ol {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  color: var(--muted);
}
.breadcrumb-wrap li + li::before { content: "/"; margin-right: 8px; color: #a79ccc; }

.hero {
  color: #fff;
  background:
    linear-gradient(120deg, rgba(34, 21, 68, 0.86), rgba(75, 44, 153, 0.72)),
    url("../images/7.webp") center/cover no-repeat;
}

.hero-shell {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 24px;
  align-items: center;
  padding: 70px 0 36px;
}

.hero-main h1 {
  margin: 0 0 12px;
  line-height: 1.35;
  font-size: clamp(1.65rem, 3.2vw, 2.45rem);
}
.hero-main p { margin: 0 0 18px; color: #e7ddff; }

.hero-actions { display: flex; gap: 10px; flex-wrap: wrap; }

.btn-download {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 22px;
  border-radius: 10px;
  background: linear-gradient(135deg, #8f63ff, #6f42ff);
  color: #fff !important;
  text-decoration: none !important;
  font-weight: 700;
  border: 1px solid rgba(255, 255, 255, 0.18);
}
.btn-download.secondary {
  background: transparent;
  border: 1px solid rgba(232, 221, 255, 0.64);
  color: #f3edff !important;
}

.hero-meta { margin-top: 12px; font-size: 14px; color: #d9ccff; }
.hero-side img { border-radius: 12px; box-shadow: 0 12px 28px rgba(20, 10, 44, 0.28); }

.hero-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  padding-bottom: 30px;
}
.hero-strip .item {
  padding: 12px;
  color: #efe8ff;
  border-bottom: 1px solid rgba(226, 213, 255, 0.35);
}

.section { padding: 56px 0; }
.section-alt { background: #f1edff; }
.section-title { text-align: center; margin-bottom: 24px; }
.section-title h2 { margin: 0 0 8px; }
.section-title p { margin: 0; color: var(--muted); }

.grid-4, .grid-3, .gallery-grid, .step-grid { display: grid; gap: 16px; }
.grid-4 { grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); }
.grid-3 { grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); }
.step-grid { grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); }
.gallery-grid { grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); }

.card, .review-card, .step-card, .panel, .page-content {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 20px;
}
.step-card { border-left: 4px solid var(--primary); }
.card h3, .review-card h3, .step-card h3, .panel h3 { margin-top: 0; }
.card p, .review-card p, .step-card p, .panel p { margin: 0; color: #5f5682; }

.gallery-grid img {
  border-radius: 10px;
  border: 1px solid var(--line);
  aspect-ratio: 16/10;
  object-fit: cover;
}

.faq-list { max-width: 900px; margin: 0 auto; }
.faq-item { background: #fff; border: 1px solid var(--line); border-radius: 10px; margin-bottom: 10px; }
.faq-item summary { cursor: pointer; padding: 14px 16px; font-weight: 600; }
.faq-body { padding: 0 16px 16px; color: #5f5682; }

.page-content { margin: 26px 0 34px; }

.article-grid {
  display: grid;
  grid-template-columns: 270px minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}
.toc {
  position: sticky;
  top: 90px;
  background: #fbf8ff;
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 14px;
}
.toc h3 { margin: 0 0 8px; font-size: 16px; }
.toc ol { margin: 0; padding-left: 18px; }
.toc li { margin-bottom: 6px; font-size: 14px; }
.article-body h1 { margin-top: 0; }
.article-meta { color: var(--muted); margin-bottom: 14px; font-size: 14px; }

.pager { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-top: 20px; }
.pager a {
  display: block;
  background: #f8f5ff;
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 12px;
  color: var(--text);
}

.site-footer { background: #1a1233; color: #d3c8f5; }
.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
  padding: 34px 0 22px;
}
.site-footer h4 { margin: 0 0 12px; color: #fff; }
.footer-links { list-style: none; margin: 0; padding: 0; }
.footer-links li { margin-bottom: 8px; }
.footer-links a { color: #c1adff; }
.footer-dates time { display: block; font-size: 13px; margin-bottom: 4px; opacity: 0.9; }
.footer-bottom { text-align: center; border-top: 1px solid #3a2c69; padding: 14px 0; }
.footer-bottom a { color: #c9b4ff; }

@media (max-width: 980px) {
  .hero-shell { grid-template-columns: 1fr; }
  .hero-strip { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .article-grid { grid-template-columns: 1fr; }
  .toc { position: static; }
}

@media (max-width: 860px) {
  .nav-toggle { display: block; }
  .nav-main {
    display: none;
    position: absolute;
    top: 64px;
    right: 16px;
    background: #1a1233;
    border: 1px solid #4b3a82;
    border-radius: 10px;
    width: 230px;
    padding: 8px;
    flex-direction: column;
  }
  .nav-main.open { display: flex; }
}
