/* 存文档官网 — 青绿文档风格，与 CWD_MINIPRO 一致 */
:root {
  --cwd-primary: #0d9488;
  --cwd-primary-dark: #0f766e;
  --cwd-primary-light: #ccfbf1;
  --cwd-bg: #ecfdf5;
  --cwd-bg-alt: #f0fdfa;
  --cwd-card: #ffffff;
  --cwd-text: #134e4a;
  --cwd-muted: #64748b;
  --cwd-border: #99f6e4;
  --cwd-accent: #f59e0b;
  --cwd-shadow: 0 4px 24px rgba(13, 148, 136, 0.08);
  --cwd-shadow-lg: 0 12px 48px rgba(13, 148, 136, 0.12);
  --radius: 12px;
  --radius-lg: 20px;
  --header-h: 64px;
  --font: "Noto Sans SC", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  --max-w: 1080px;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-h) + 16px);
}

body {
  font-family: var(--font);
  background: var(--cwd-bg);
  color: var(--cwd-text);
  line-height: 1.75;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--cwd-primary-dark); text-decoration: none; }
a:hover { text-decoration: underline; }

img { max-width: 100%; display: block; }

.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 20px;
}

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  height: var(--header-h);
  background: rgba(236, 253, 245, 0.92);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--cwd-border);
  transition: box-shadow 0.2s;
}

.site-header.scrolled { box-shadow: var(--cwd-shadow); }

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--cwd-text);
  text-decoration: none;
  font-weight: 600;
  font-size: 1.05rem;
}

.logo:hover { text-decoration: none; }

.logo svg { width: 32px; height: 32px; flex-shrink: 0; }

.nav { display: flex; align-items: center; gap: 4px; }

.nav a {
  padding: 8px 14px;
  border-radius: 8px;
  color: var(--cwd-muted);
  font-size: 0.925rem;
  text-decoration: none;
  transition: color 0.2s, background 0.2s;
}

.nav a:hover,
.nav a.active {
  color: var(--cwd-primary-dark);
  background: var(--cwd-primary-light);
  text-decoration: none;
}

.menu-btn {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.menu-btn span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--cwd-text);
  border-radius: 1px;
}

/* Hero */
.hero {
  padding: calc(var(--header-h) + 48px) 0 64px;
}

.hero-inner {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 40px;
  align-items: center;
}

.hero-content { text-align: center; }

.hero-qr { display: flex; justify-content: center; }

/* QR code */
.qr-card {
  margin: 0;
  padding: 16px;
  background: var(--cwd-card);
  border: 1px solid var(--cwd-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--cwd-shadow-lg);
  text-align: center;
}

.qr-card img {
  width: 200px;
  height: 200px;
  margin: 0 auto;
  border-radius: 8px;
}

.qr-card--hero img { width: 220px; height: 220px; }

.qr-card--lg img { width: 260px; height: 260px; }

.qr-card figcaption {
  margin-top: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--cwd-primary-dark);
  line-height: 1.5;
}

.qr-or {
  display: block;
  margin-top: 4px;
  font-size: 0.8rem;
  font-weight: 400;
  color: var(--cwd-muted);
}

.scan-block {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 32px;
  margin-top: 40px;
  padding: 28px;
  background: var(--cwd-card);
  border: 1px solid var(--cwd-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--cwd-shadow);
}

.scan-block-text {
  text-align: left;
  max-width: 360px;
}

.scan-block-text h3 {
  font-size: 1.1rem;
  margin-bottom: 8px;
}

.scan-block-text p {
  font-size: 0.9rem;
  color: var(--cwd-muted);
  margin-bottom: 0;
}

.scan-block-text ul {
  margin: 10px 0 0;
  padding-left: 1.2rem;
  font-size: 0.875rem;
  color: var(--cwd-muted);
}

.scan-block-text li { margin-bottom: 4px; }

/* CTA banner */
.cta-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 36px;
  padding: 28px 32px;
  background: linear-gradient(135deg, var(--cwd-primary) 0%, var(--cwd-primary-dark) 100%);
  border-radius: var(--radius-lg);
  color: #fff;
  box-shadow: var(--cwd-shadow-lg);
}

.cta-banner-text h3 {
  font-size: 1.2rem;
  margin-bottom: 6px;
  color: #fff;
}

.cta-banner-text p {
  font-size: 0.925rem;
  opacity: 0.9;
  margin: 0;
  color: #fff;
}

.cta-banner .btn-primary {
  background: #fff;
  color: var(--cwd-primary-dark);
  box-shadow: none;
  flex-shrink: 0;
}

.cta-banner .btn-primary:hover {
  background: var(--cwd-primary-light);
  color: var(--cwd-primary-dark);
}

.hero-badge {
  display: inline-block;
  padding: 6px 14px;
  background: var(--cwd-primary-light);
  color: var(--cwd-primary-dark);
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 500;
  margin-bottom: 20px;
}

.hero h1 {
  font-size: clamp(1.75rem, 5vw, 2.75rem);
  font-weight: 700;
  line-height: 1.25;
  margin-bottom: 16px;
  letter-spacing: -0.02em;
}

.hero-sub {
  font-size: clamp(1rem, 2.5vw, 1.2rem);
  color: var(--cwd-muted);
  max-width: 640px;
  margin: 0 auto 28px;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
  margin-bottom: 36px;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 24px;
  border-radius: 10px;
  font-size: 0.95rem;
  font-weight: 500;
  text-decoration: none;
  transition: transform 0.15s, box-shadow 0.15s;
  border: none;
  cursor: pointer;
}

.btn:hover { text-decoration: none; transform: translateY(-1px); }

.btn-primary {
  background: var(--cwd-primary);
  color: #fff;
  box-shadow: 0 4px 14px rgba(13, 148, 136, 0.35);
}

.btn-primary:hover { background: var(--cwd-primary-dark); color: #fff; }

.btn-outline {
  background: var(--cwd-card);
  color: var(--cwd-primary-dark);
  border: 1.5px solid var(--cwd-border);
}

.search-hint {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 14px 22px;
  background: var(--cwd-card);
  border: 1px dashed var(--cwd-primary);
  border-radius: var(--radius);
  font-size: 1rem;
}

.search-hint strong { color: var(--cwd-primary-dark); font-size: 1.15rem; }

.hero-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  justify-content: center;
  margin-top: 28px;
}

.tag {
  padding: 4px 12px;
  background: rgba(255,255,255,0.8);
  border: 1px solid var(--cwd-border);
  border-radius: 999px;
  font-size: 0.8rem;
  color: var(--cwd-muted);
}

/* Sections */
.section {
  padding: 56px 0;
}

.section-alt { background: var(--cwd-bg-alt); }

.section-head {
  text-align: center;
  margin-bottom: 40px;
}

.section-head h2 {
  font-size: clamp(1.4rem, 3vw, 1.85rem);
  margin-bottom: 10px;
}

.section-head p {
  color: var(--cwd-muted);
  max-width: 560px;
  margin: 0 auto;
}

/* Feature grid */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 20px;
}

.feature-card {
  background: var(--cwd-card);
  border: 1px solid var(--cwd-border);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--cwd-shadow);
  transition: transform 0.2s, box-shadow 0.2s;
}

.feature-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--cwd-shadow-lg);
}

.feature-icon {
  font-size: 1.75rem;
  margin-bottom: 12px;
}

.feature-card h3 {
  font-size: 1.05rem;
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 0.9rem;
  color: var(--cwd-muted);
  line-height: 1.6;
}

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 24px;
  counter-reset: step;
}

.step {
  text-align: center;
  position: relative;
}

.step-num {
  width: 40px;
  height: 40px;
  margin: 0 auto 14px;
  background: var(--cwd-primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
}

.step h3 { font-size: 1rem; margin-bottom: 6px; }
.step p { font-size: 0.875rem; color: var(--cwd-muted); }

/* Compare table */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  border: 1px solid var(--cwd-border);
  background: var(--cwd-card);
  box-shadow: var(--cwd-shadow);
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.925rem;
}

th, td {
  padding: 14px 18px;
  text-align: left;
  border-bottom: 1px solid var(--cwd-border);
}

th {
  background: var(--cwd-primary-light);
  font-weight: 600;
  color: var(--cwd-primary-dark);
}

tr:last-child td { border-bottom: none; }

tr.highlight td { background: rgba(204, 251, 241, 0.35); }

/* FAQ */
.faq-list { max-width: 760px; margin: 0 auto; }

.faq-item {
  background: var(--cwd-card);
  border: 1px solid var(--cwd-border);
  border-radius: var(--radius);
  margin-bottom: 12px;
  overflow: hidden;
}

.faq-q {
  width: 100%;
  padding: 18px 20px;
  background: none;
  border: none;
  text-align: left;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 600;
  color: var(--cwd-text);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}

.faq-q::after {
  content: "+";
  font-size: 1.25rem;
  color: var(--cwd-primary);
  flex-shrink: 0;
}

.faq-item.open .faq-q::after { content: "−"; }

.faq-a {
  display: none;
  padding: 0 20px 18px;
  color: var(--cwd-muted);
  font-size: 0.925rem;
}

.faq-item.open .faq-a { display: block; }

/* AI block — plain readable text for crawlers */
.ai-summary {
  background: var(--cwd-card);
  border: 1px solid var(--cwd-border);
  border-radius: var(--radius-lg);
  padding: 28px 32px;
  box-shadow: var(--cwd-shadow);
}

.ai-summary h2 { font-size: 1.2rem; margin-bottom: 16px; }

.ai-summary p,
.ai-summary li {
  font-size: 0.95rem;
  color: var(--cwd-text);
}

.ai-summary ul { padding-left: 1.25rem; margin: 12px 0; }
.ai-summary li { margin-bottom: 6px; }

/* Scenarios */
.scenario-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}

.scenario-card {
  background: var(--cwd-card);
  border-left: 4px solid var(--cwd-primary);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 20px 22px;
  box-shadow: var(--cwd-shadow);
}

.scenario-card h3 { font-size: 1rem; margin-bottom: 8px; }
.scenario-card .q { font-size: 0.85rem; color: var(--cwd-accent); margin-bottom: 8px; font-weight: 500; }
.scenario-card p { font-size: 0.9rem; color: var(--cwd-muted); }

/* Page content (guide/faq subpages) */
.page-hero {
  padding: calc(var(--header-h) + 40px) 0 32px;
  text-align: center;
  border-bottom: 1px solid var(--cwd-border);
  background: linear-gradient(180deg, var(--cwd-bg) 0%, var(--cwd-bg-alt) 100%);
}

.page-hero h1 { font-size: clamp(1.5rem, 4vw, 2rem); margin-bottom: 10px; }
.page-hero p { color: var(--cwd-muted); }

.prose {
  max-width: 720px;
  margin: 0 auto;
  padding: 40px 20px 64px;
}

.prose h2 {
  font-size: 1.25rem;
  margin: 32px 0 12px;
  padding-bottom: 8px;
  border-bottom: 2px solid var(--cwd-primary-light);
}

.prose h3 { font-size: 1.05rem; margin: 24px 0 8px; }

.prose p, .prose li {
  font-size: 0.95rem;
  color: var(--cwd-text);
  margin-bottom: 12px;
}

.prose ul, .prose ol { padding-left: 1.5rem; margin-bottom: 16px; }

.prose li { margin-bottom: 6px; }

/* Footer */
.site-footer {
  background: var(--cwd-text);
  color: rgba(255,255,255,0.85);
  padding: 40px 0 24px;
  margin-top: 24px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 32px;
  margin-bottom: 28px;
}

.footer-brand p {
  font-size: 0.875rem;
  opacity: 0.75;
  margin-top: 8px;
  max-width: 320px;
}

.footer-links {
  display: flex;
  gap: 32px;
}

.footer-col h4 {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  opacity: 0.6;
  margin-bottom: 12px;
}

.footer-col a {
  display: block;
  color: rgba(255,255,255,0.85);
  font-size: 0.875rem;
  margin-bottom: 8px;
  text-decoration: none;
}

.footer-col a:hover { color: #fff; text-decoration: underline; }

.footer-bottom {
  padding-top: 20px;
  border-top: 1px solid rgba(255,255,255,0.15);
  font-size: 0.8rem;
  opacity: 0.65;
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  justify-content: space-between;
}

.footer-bottom a { color: inherit; }

/* Responsive */
@media (max-width: 900px) {
  .hero-inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .hero-content { order: 1; }
  .hero-qr { order: 2; }

  .scan-block { flex-direction: column; text-align: center; }
  .scan-block-text { text-align: center; max-width: none; }
  .scan-block-text ul { list-style: none; padding-left: 0; }
}

@media (max-width: 768px) {
  .menu-btn { display: flex; }

  .nav {
    position: fixed;
    top: var(--header-h);
    left: 0;
    right: 0;
    background: var(--cwd-bg);
    border-bottom: 1px solid var(--cwd-border);
    flex-direction: column;
    padding: 12px;
    gap: 4px;
    transform: translateY(-120%);
    opacity: 0;
    pointer-events: none;
    transition: transform 0.25s, opacity 0.25s;
  }

  .nav.open {
    transform: translateY(0);
    opacity: 1;
    pointer-events: auto;
  }

  .nav a { width: 100%; text-align: center; }

  .footer-grid { grid-template-columns: 1fr; }
  .footer-links { flex-direction: column; gap: 20px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .btn:hover, .feature-card:hover { transform: none; }
}
