:root {
  --blue: #0c6bff;
  --blue-dark: #084db8;
  --ink: #172033;
  --muted: #5c6b82;
  --line: #e4ebf5;
  --bg: #f3f6fb;
  --card: #ffffff;
  --warn: #8a4b12;
  --warn-bg: #fff6ea;
  --header: 64px;
}

* { box-sizing: border-box; }
html {
  scroll-behavior: smooth;
  scroll-padding-top: 210px;
}
body {
  margin: 0;
  color: var(--ink);
  background: var(--bg);
  font-family: "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
  font-size: 17px;
  line-height: 1.85;
}
img { max-width: 100%; height: auto; }
a { color: var(--blue-dark); }
a:hover { color: var(--blue); }

.site-header {
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--header);
  background: #fff;
  border-bottom: 1px solid var(--line);
}
.header-inner {
  width: min(1120px, calc(100% - 80px));
  height: 100%;
  margin: 0 auto;
  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.02em;
  flex: 0 0 auto;
  margin-right: auto;
}
.brand img {
  width: 40px;
  height: 40px;
  border-radius: 10px;
}
.nav-toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}
.menu-toggle {
  display: none;
  width: 42px;
  height: 42px;
  margin-left: 12px;
  border-radius: 10px;
  align-items: center;
  justify-content: center;
  cursor: pointer;
}
.menu-bars,
.menu-bars::before,
.menu-bars::after {
  display: block;
  width: 18px;
  height: 2px;
  background: var(--ink);
  border-radius: 2px;
  position: relative;
}
.menu-bars::before,
.menu-bars::after {
  content: "";
  position: absolute;
  left: 0;
}
.menu-bars::before { top: -6px; }
.menu-bars::after { top: 6px; }
.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}
.nav {
  display: flex;
  gap: 6px;
  min-width: 0;
}
.nav a {
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 15px;
}
.nav a[aria-current="page"],
.nav a:hover {
  background: #e8f1ff;
  color: var(--blue-dark);
}

.ad-slot {
  position: sticky;
  top: var(--header);
  z-index: 30;
  background: #fff;
  border-bottom: 1px solid var(--line);
  min-height: 0;
}
.ad-slot[hidden] { display: none; }
#ads img {
  width: 65px;
  height: 65px;
  max-width: 65px;
  max-height: 65px;
  object-fit: contain;
  flex: 0 0 auto;
}

.wrap {
  width: min(1120px, calc(100% - 80px));
  margin: 0 auto;
}
.hero {
  padding: 36px 0 10px;
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  color: var(--blue-dark);
  font-size: 14px;
  font-weight: 700;
}
.badge {
  display: inline-block;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--blue);
  color: #fff;
  font-size: 12px;
  letter-spacing: 0.04em;
}
h1, h2, h3 { line-height: 1.35; margin: 0 0 12px; }
h1 { font-size: 36px; letter-spacing: -0.02em; }
h2 { font-size: 28px; margin-top: 8px; }
h3 { font-size: 20px; }
.lead { font-size: 18px; color: #24344d; margin-top: 0; }

.notice {
  background: var(--warn-bg);
  color: var(--warn);
  border: 1px solid #f3ddc4;
  border-radius: 14px;
  padding: 12px 16px;
  margin: 18px 0;
}

.toc, .card, .faq, .shot, .table-wrap {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 18px;
}
.toc { padding: 18px 20px; margin: 18px 0 28px; }
.toc ol { margin: 8px 0 0; padding-left: 20px; }
.toc a { text-decoration: none; }
.toc a:hover { text-decoration: underline; }

.section { padding: 8px 0 28px; }
.media {
  display: grid;
  grid-template-columns: 280px 1fr;
  gap: 22px;
  align-items: start;
  margin: 16px 0 8px;
}
.media.pair { grid-template-columns: 1fr 1fr; }
.shot { padding: 12px; margin: 0; }
.shot img {
  display: block;
  width: 100%;
  max-height: 560px;
  object-fit: contain;
  background: #101828;
  border-radius: 14px;
}
.shot figcaption {
  color: var(--muted);
  font-size: 14px;
  line-height: 1.6;
  margin-top: 10px;
}
.points { margin: 0; padding-left: 18px; }
.points li { margin: 6px 0; }

.table-wrap { overflow-x: auto; margin: 14px 0; }
table { width: 100%; border-collapse: collapse; min-width: 560px; }
th, td { text-align: left; padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: top; }
th { background: #f7faff; font-size: 15px; }
tr:last-child td { border-bottom: 0; }

.faq details {
  border-bottom: 1px solid var(--line);
  padding: 4px 0;
}
.faq details:last-child { border-bottom: 0; }
.faq { padding: 8px 18px; }
.faq summary { cursor: pointer; font-weight: 700; padding: 12px 0; }
.faq p { margin-top: 0; }

.page-intro { padding: 34px 0 8px; }
.prose-page { padding-bottom: 40px; }
.prose-page h2 { margin-top: 28px; }

.error-panel {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  padding: 28px 22px 10px;
  margin: 28px 0 40px;
}
.error-code {
  margin: 0;
  color: var(--blue);
  font-size: 56px;
  font-weight: 800;
  letter-spacing: -0.04em;
  line-height: 1;
}

.site-footer {
  border-top: 1px solid var(--line);
  background: #fff;
  padding: 28px 0 36px;
  color: var(--muted);
  font-size: 14px;
}
.site-footer nav { display: flex; flex-wrap: wrap; gap: 8px 16px; margin-bottom: 10px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--blue-dark); }

@media (max-width: 800px) {
  h1 { font-size: 30px; }
  h2 { font-size: 24px; }
  .media, .media.pair { grid-template-columns: 1fr; }
  .header-inner,
  .wrap { width: min(1120px, calc(100% - 32px)); }
  .brand span { font-size: 15px; }
  .menu-toggle { display: flex; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 4px;
    padding: 10px 16px 14px;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 12px 24px rgba(23, 32, 51, 0.08);
  }
  .nav a { padding: 10px 12px; border-radius: 12px; }
  .nav-toggle:checked ~ .nav { display: flex; }
}
