:root {
  --bg: #f4f0e6;
  --paper: #fffdf8;
  --ink: #1c2430;
  --muted: #5c6772;
  --blue: #1560b8;
  --line: #e5ddd0;
  --chip: #e7f0fb;
  --warn-bg: #fff6e6;
  --warn: #7a5410;
  --shadow: 0 10px 30px rgba(28, 36, 48, 0.06);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background:
    radial-gradient(1200px 400px at 10% -10%, rgba(21, 96, 184, 0.08), transparent 50%),
    var(--bg);
  color: var(--ink);
  font-family: "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  font-size: 17px;
  line-height: 1.8;
}

img { max-width: 100%; }

a { color: var(--blue); }

a:hover { text-decoration: none; }

.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  background: #fff;
  padding: 6px 10px;
  z-index: 80;
}

.skip:focus { top: 8px; }

.sticky-top {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(244, 240, 230, 0.94);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.header {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1120px;
  margin: 0 auto;
  padding: 10px 20px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  min-width: 0;
}

.brand img {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  flex: none;
}

.brand strong {
  display: block;
  font-size: 16px;
  line-height: 1.3;
}

.brand em {
  display: block;
  margin-top: 1px;
  font-style: normal;
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.04em;
}

.nav-toggle {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.nav-btn {
  display: none;
  border: 1px solid var(--line);
  background: var(--paper);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 14px;
  cursor: pointer;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 16px;
  align-items: center;
}

.nav a {
  text-decoration: none;
  color: var(--ink);
  font-size: 14px;
}

.nav a[aria-current="page"] {
  color: var(--blue);
  font-weight: 700;
}

.ad-wrap { min-height: 8px; }

.wrap {
  max-width: 1120px;
  margin: 0 auto;
  padding: 28px 20px 72px;
}

.layout {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
}

.toc {
  position: sticky;
  top: 196px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 14px 14px 8px;
  box-shadow: var(--shadow);
}

.toc p {
  margin: 0 0 6px;
  padding-left: 16px;
  font-size: 12px;
  letter-spacing: 0.08em;
  color: var(--muted);
}

.toc ol {
  margin: 0;
  padding-left: 28px;
}

.toc a {
  text-decoration: none;
  color: var(--ink);
  font-size: 14px;
  line-height: 1.55;
}

.kicker {
  margin: 0 0 8px;
  color: var(--blue);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
}

h1 {
  margin: 0 0 12px;
  font-size: 36px;
  line-height: 1.25;
  letter-spacing: -0.03em;
}

.lede {
  font-size: 18px;
  color: #2c3846;
}

.meta {
  color: var(--muted);
  font-size: 13px;
}

.note {
  background: var(--warn-bg);
  border: 1px solid #f0e0c2;
  color: var(--warn);
  border-radius: 14px;
  padding: 12px 14px;
  font-size: 14px;
}

section,
h2,
h3 {
  scroll-margin-top: 210px;
}

h2 {
  margin: 2.1em 0 0.55em;
  font-size: 26px;
  line-height: 1.35;
}

h3 {
  margin: 1.35em 0 0.35em;
  font-size: 18px;
}

p { margin: 0 0 0.95em; }

.prose { max-width: 76ch; }

.crumbs {
  margin: 0 0 14px;
  color: var(--muted);
  font-size: 13px;
}

.crumbs a { text-decoration: none; }

.shots {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 280px));
  gap: 16px;
  margin: 8px 0 18px;
}

.shot {
  margin: 0;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 10px 10px 12px;
  box-shadow: var(--shadow);
}

.shot img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 12px;
  background: #141820;
}

.shot figcaption {
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.55;
}

.steps {
  list-style: none;
  margin: 0 0 1em;
  padding: 0;
}

.steps li {
  position: relative;
  margin: 0 0 12px;
  padding: 2px 0 2px 46px;
}

.steps li::before {
  content: counter(step);
  counter-increment: step;
  position: absolute;
  left: 0;
  top: 4px;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  background: var(--blue);
  color: #fff;
  font-size: 14px;
  display: grid;
  place-items: center;
}

.steps { counter-reset: step; }

.card-list {
  display: grid;
  gap: 12px;
  margin: 0 0 1em;
}

.card-list article {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 14px 16px;
}

.card-list h3 { margin-top: 0; }

.faq details {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 10px 14px;
  margin: 0 0 10px;
}

.faq summary {
  cursor: pointer;
  font-weight: 700;
}

.page-card {
  max-width: 760px;
  margin: 0 auto;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px 22px;
  box-shadow: var(--shadow);
}

.footer {
  border-top: 1px solid var(--line);
  padding: 26px 20px 40px;
  color: var(--muted);
  font-size: 14px;
}

.footer .inner { max-width: 1120px; margin: 0 auto; }

.footer nav {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 18px;
  margin-bottom: 8px;
}

.footer a { text-decoration: none; }

@media (max-width: 1080px) {
  .brand em { display: none; }
  .nav { gap: 4px 10px; }
}

@media (max-width: 900px) {
  h1 { font-size: 28px; }
  .layout { display: block; }
  .toc { position: static; margin: 18px 0; }
  .shots { grid-template-columns: 1fr; justify-items: center; }
  .shot { width: min(100%, 330px); }
  .nav-btn { display: inline-flex; }
  .nav { display: none; }
  .nav-toggle:checked ~ .nav {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    position: absolute;
    right: 16px;
    top: 62px;
    width: min(240px, calc(100vw - 32px));
    padding: 10px 14px;
    background: var(--paper);
    border: 1px solid var(--line);
    border-radius: 14px;
    box-shadow: var(--shadow);
  }
}
