:root {
  --ink: #1b2430;
  --muted: #5d6774;
  --paper: #f4f0e8;
  --card: #fffdf8;
  --sea: #0f6cbd;
  --sea-dark: #0a4d88;
  --line: #e3d8c6;
  --sand: #f8ead4;
  --header-h: 64px;
  --shadow: 0 10px 28px rgba(27, 36, 48, 0.08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(1200px 420px at 90% -10%, #d7ebfb 0%, transparent 55%),
    var(--paper);
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 17px;
  line-height: 1.75;
}
img { max-width: 100%; height: auto; }
a { color: var(--sea-dark); }
a:hover { color: var(--sea); }
.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  background: #fff;
  padding: 6px 10px;
  z-index: 100;
}
.skip:focus { top: 8px; }

.wrap { width: min(1120px, calc(100% - 32px)); margin: 0 auto; }

.site-header {
  position: sticky;
  top: 0;
  z-index: 80;
  background: rgba(255, 253, 248, 0.94);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}
.bar {
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  gap: 18px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.brand img { width: 40px; height: 40px; border-radius: 10px; }
.site-nav { display: flex; gap: 6px; margin-left: auto; }
.site-nav a {
  text-decoration: none;
  color: var(--ink);
  padding: 8px 10px;
  border-radius: 999px;
  font-size: 15px;
}
.site-nav a[aria-current="page"],
.site-nav a:hover { background: #e7f2fb; color: var(--sea-dark); }
.nav-toggle { position: absolute; opacity: 0; pointer-events: none; }
.nav-btn {
  display: none;
  margin-left: auto;
  border: 1px solid var(--line);
  background: #fff;
  border-radius: 999px;
  padding: 6px 12px;
  cursor: pointer;
}

#ad-slot {
  position: sticky;
  top: var(--header-h);
  z-index: 70;
  background: rgba(244, 240, 232, 0.96);
  backdrop-filter: blur(10px);
}
#ad-slot:empty { display: none; }
#ad-slot:not(:empty) { border-bottom: 1px solid var(--line); }

.hero { padding: 36px 0 10px; }
.kicker {
  display: inline-block;
  margin: 0 0 10px;
  padding: 2px 10px;
  border-radius: 999px;
  background: var(--sand);
  color: #8a4b12;
  font-size: 13px;
}
h1, h2, h3 { line-height: 1.35; font-weight: 700; }
h1 { font-size: 36px; margin: 0 0 12px; letter-spacing: -0.02em; }
h2 { font-size: 26px; margin: 36px 0 12px; }
h3 { font-size: 20px; margin: 22px 0 8px; }
.lead { font-size: 18px; color: #2a3442; max-width: 760px; }

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 230px;
  gap: 36px;
  align-items: start;
  padding-bottom: 48px;
}
.toc {
  position: sticky;
  top: 168px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 16px;
  box-shadow: var(--shadow);
}
.toc strong { display: block; margin-bottom: 8px; font-size: 14px; }
.toc a { display: block; text-decoration: none; font-size: 14px; padding: 4px 0; color: var(--muted); }
.toc a:hover { color: var(--sea-dark); }

.card, .note, .faq details {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  box-shadow: var(--shadow);
}
.note { padding: 14px 16px; margin: 18px 0; }
.feature {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  gap: 22px;
  align-items: start;
  margin: 22px 0;
  padding: 16px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
}
.shot { margin: 0; }
.shot img {
  width: 100%;
  border-radius: 16px;
  background: #10131b;
  box-shadow: var(--shadow);
}
.shot figcaption { color: var(--muted); font-size: 13px; margin-top: 8px; }
ul, ol { padding-left: 1.2em; }
li { margin: 4px 0; }

.steps { counter-reset: step; list-style: none; padding: 0; }
.steps li {
  list-style: none;
  margin: 0 0 12px;
  padding: 12px 14px 12px 52px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  position: relative;
}
.steps li::before {
  counter-increment: step;
  content: counter(step);
  position: absolute;
  left: 12px;
  top: 12px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--sea);
  color: #fff;
  display: grid;
  place-items: center;
  font-size: 14px;
}

.faq details { padding: 10px 16px; margin: 10px 0; }
.faq summary { cursor: pointer; font-weight: 700; }
.links { display: flex; flex-wrap: wrap; gap: 8px; padding: 0; list-style: none; }
.links a {
  display: inline-block;
  text-decoration: none;
  background: #e7f2fb;
  border-radius: 999px;
  padding: 6px 12px;
}

.page { padding: 28px 0 56px; }
.page h1 { font-size: 32px; }
.prose { max-width: 820px; }

.site-footer {
  border-top: 1px solid var(--line);
  padding: 22px 0 32px;
  color: var(--muted);
  font-size: 14px;
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: 12px; }
.site-footer a { color: var(--muted); }

.error-box {
  margin-top: 18px;
  padding: 28px 22px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
}
.error-box strong { font-size: 42px; color: var(--sea); display: block; }

@media (max-width: 860px) {
  h1 { font-size: 28px; }
  .layout, .feature { grid-template-columns: 1fr; }
  .toc { position: static; }
  .shot img { max-width: 280px; }
  .nav-btn { display: inline-flex; }
  .site-nav {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: var(--header-h);
    flex-direction: column;
    background: #fffdf8;
    border-bottom: 1px solid var(--line);
    padding: 8px 16px 14px;
    margin: 0;
  }
  .nav-toggle:checked ~ .site-nav { display: flex; }
  .bar { position: relative; }
}
