:root { color-scheme: light; --ink: #131212; --muted: #5f6673; --blue: #134cff; --line: rgba(24, 38, 63, .1); --paper: #f7f8fa; }
* { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 90px; }
body { margin: 0; color: var(--ink); background: #fff; font: 15px/1.85 "MiSans", "PingFang SC", "PingFang HK", "Helvetica Neue", Helvetica, "Microsoft YaHei", "Noto Sans CJK SC", Arial, sans-serif; -webkit-font-smoothing: antialiased; }
a { color: var(--blue); text-underline-offset: 4px; }
button { font: inherit; cursor: pointer; }
a:focus-visible, button:focus-visible, summary:focus-visible { outline: 3px solid #86b3ff; outline-offset: 4px; }
.skip-link { position: fixed; top: -100px; left: 20px; z-index: 30; padding: 8px 16px; background: white; }
.skip-link:focus { top: 12px; }
.topbar { height: 64px; position: sticky; top: 0; z-index: 10; display: flex; align-items: center; justify-content: space-between; gap: 16px; padding: 0 max(24px, calc((100vw - 1280px)/2)); background: rgba(247, 248, 250, .94); backdrop-filter: blur(18px); border-bottom: 1px solid var(--line); }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; color: var(--ink); font-size: 17px; font-weight: 600; }
.brand img { flex: none; width: 30px; height: 30px; border-radius: 7px; }
.brand-sub { margin-left: 15px; padding-left: 15px; border-left: 1px solid var(--line); font-size: 14px; font-weight: 400; color: var(--muted); }
.top-actions { display: flex; align-items: center; gap: 24px; font-size: 13px; }
.top-actions a { color: var(--muted); text-decoration: none; }
.top-actions button { background: #f5f8ff; color: var(--blue); border: 1px solid #dbe6ff; border-radius: 6px; padding: 6px 12px; }
.layout { display: grid; grid-template-columns: 230px minmax(0, 890px); gap: 70px; max-width: 1280px; padding: 0 24px; margin: auto; }
.sidebar { position: sticky; top: 64px; height: calc(100vh - 64px); overflow-y: auto; padding: 36px 16px 28px 0; border-right: 1px solid var(--line); }
.sidebar details { border: none; padding: 0; margin: 0; }
.sidebar summary { padding: 0 12px; font-size: 12px; font-weight: 700; letter-spacing: 2px; color: var(--muted); list-style: none; cursor: default; }
.sidebar summary::-webkit-details-marker { display: none; }
.sidebar ol { list-style: none; margin: 14px 0 0; padding: 0; counter-reset: chapter; }
.sidebar li { counter-increment: chapter; }
.sidebar li a { display: flex; gap: 10px; text-decoration: none; color: #526177; font-size: 13px; border-radius: 6px; padding: 7px 10px; line-height: 1.7; }
.sidebar li a::before { content: counter(chapter, decimal-leading-zero); font-size: 11px; opacity: .65; padding-top: 2px; }
.sidebar li a:hover, .sidebar li a[aria-current="location"] { color: var(--blue); background: #edf3ff; }
.sidebar-note { margin: 28px 10px 0; font-size: 12px; color: #607086; line-height: 2.1; border-top: 1px solid var(--line); padding-top: 20px; }
.sidebar-note span { display: block; margin-top: 8px; font-size: 11px; line-height: 1.7; }
main { min-width: 0; padding-bottom: 60px; }
.intro { padding: 54px 0 36px; }
.eyebrow, .section-number { font-size: 12px; font-weight: 700; letter-spacing: 1px; color: var(--blue); }
h1 { font-size: clamp(32px, 3.5vw, 46px); line-height: 1.35; letter-spacing: normal; margin: 16px 0 24px; font-weight: 500; text-wrap: balance; }
h2 { font-size: 27px; line-height: 1.45; margin: 9px 0 22px; font-weight: 500; text-wrap: balance; }
h3 { font-size: 18px; line-height: 1.6; margin: 30px 0 10px; font-weight: 600; }
p { margin: 12px 0; }
.lead { font-size: 17px; line-height: 1.9; color: #526177; max-width: 700px; }
.meta, .small, figcaption { font-size: 12px; color: var(--muted); line-height: 1.8; }
.meta { margin-top: 20px; }
.intro-links { display: flex; gap: 24px; margin: 26px 0; align-items: center; font-size: 14px; }
.intro-links a:first-child { padding: 8px 18px; background: var(--blue); color: white; border-radius: 6px; text-decoration: none; }
.guide-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin-top: 24px; }
.guide-grid a { padding: 15px 18px; border: 1px solid var(--line); border-radius: 10px; background: var(--paper); text-decoration: none; color: var(--ink); }
.guide-grid a:hover { border-color: #c2d2ff; background: #f1f5ff; }
.guide-grid strong { display: block; font-weight: 600; font-size: 14px; }
.guide-grid span { display: block; font-size: 12px; color: var(--muted); margin-top: 3px; }
section { padding: 32px 0 36px; border-top: 1px solid var(--line); scroll-margin-top: 12px; }
.section-number { margin-top: 0; }
.path { font-size: 13px; color: #3e648d; padding: 9px 12px; border-left: 3px solid #b6cef7; background: #f6f9ff; }
ul, ol { padding-left: 24px; }
li { padding-left: 3px; margin: 6px 0; }
.steps li { margin: 12px 0; padding-left: 5px; }
.steps li::marker { color: var(--blue); font-weight: 700; }
.callout { padding: 18px 20px; margin: 22px 0; border: 1px solid #d8e6ff; border-left: 4px solid var(--blue); border-radius: 6px; background: #f4f8ff; font-size: 14px; }
.callout strong { color: #244f93; }
.callout > strong { display: block; }
.callout p { margin: 7px 0 0; }
.callout.important { background: #fffbef; border-color: #f0dfb4; border-left-color: #dc992a; }
.callout.important strong { color: #835514; }
.callout.checklist { background: #f1f9f6; border-color: #cfe6dc; border-left-color: #268b68; }
.callout.checklist strong { color: #246b53; }
figure { margin: 22px 0; padding: 12px; border: 1px solid var(--line); border-radius: 8px; background: #fafbfd; }
.image-link { display: flex; justify-content: center; background: white; border-radius: 4px; overflow: hidden; cursor: zoom-in; }
figure img { display: block; width: 100%; height: auto; max-height: 410px; object-fit: contain; }
figcaption { padding: 10px 3px 0; }
.image-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; margin-top: 16px; }
.image-grid figure { margin: 0; }
.image-grid img { max-height: 330px; }
.portraits img { max-height: 490px; }
.table-wrap { width: 100%; overflow-x: auto; margin: 22px 0; border: 1px solid var(--line); border-radius: 7px; }
table { border-collapse: collapse; width: 100%; font-size: 13px; text-align: left; }
caption { padding: 10px 14px; text-align: left; color: #4d627c; background: #f8fafc; font-size: 12px; }
th { background: #f1f5fb; color: #405674; font-weight: 600; }
th, td { padding: 12px 14px; vertical-align: top; border-bottom: 1px solid var(--line); }
td:first-child { min-width: 110px; }
tr:last-child td { border-bottom: 0; }
tbody tr:nth-child(even) { background: #fafbfd; }
code, kbd { font-family: Consolas, "Microsoft YaHei", monospace; font-size: .88em; background: #edf1f6; border-radius: 4px; padding: 2px 5px; overflow-wrap: anywhere; }
kbd { white-space: nowrap; border: 1px solid #d5dce6; border-bottom-width: 2px; }
details { border: 1px solid var(--line); border-radius: 7px; padding: 0 18px; margin: 18px 0; }
summary { padding: 13px 0; cursor: pointer; font-size: 14px; font-weight: 600; color: #3d5575; }
details[open] { padding-bottom: 16px; }
details > :last-child { margin-bottom: 0; }
details > figure { margin-top: 10px; }
blockquote { margin: 6px 0 18px; padding: 14px 18px; border-left: 3px solid #bad0f8; background: #f7faff; font-size: 14px; }
.flow { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; list-style: none; counter-reset: flow; padding: 0; margin: 22px 0; }
.flow li { counter-increment: flow; padding: 15px 18px; margin: 0; background: #f7f9fd; border: 1px solid var(--line); border-radius: 7px; }
.flow strong { font-size: 14px; }
.flow strong::before { content: counter(flow) " · "; color: var(--blue); }
.flow span { display: block; font-size: 12px; color: var(--muted); margin-top: 6px; }
.doc-footer { border-top: 1px solid var(--line); padding-top: 25px; color: var(--muted); font-size: 12px; }
.doc-footer a { display: inline-block; margin-top: 10px; }
dialog { width: min(1280px, 95vw); max-height: 94vh; border: 0; padding: 18px; border-radius: 10px; box-shadow: 0 15px 80px #0f1a3544; }
dialog::backdrop { background: #16243bc9; }
dialog .preview-toolbar { display: flex; justify-content: space-between; align-items: flex-start; gap: 20px; margin-bottom: 12px; }
.preview-toolbar p { font-size: 13px; margin: 3px 0; }
.preview-toolbar button, .preview-navigation button { flex: none; border: 1px solid var(--line); border-radius: 6px; padding: 5px 12px; color: var(--ink); background: #f5f7fa; }
#preview-image { display: block; max-width: 100%; width: auto; max-height: 74vh; object-fit: contain; margin: auto; }
.preview-navigation { display: flex; justify-content: center; gap: 12px; padding-top: 12px; }
.preview-navigation button:disabled { opacity: .45; cursor: default; }
body:has(dialog[open]) { overflow: hidden; }
@media (max-width: 1050px) { .layout { gap: 32px; grid-template-columns: 205px minmax(0, 1fr); } .sidebar { padding-right: 10px; } }
@media (max-width: 760px) {
  html { scroll-padding-top: 80px; }
  .topbar { padding: 0 16px; height: 64px; gap: 10px; }
  .brand { font-size: 17px; gap: 7px; }
  .brand-sub { margin-left: 8px; padding-left: 8px; font-size: 12px; }
  .top-actions { gap: 8px; }
  .top-actions a { display: none; }
  .top-actions button { font-size: 11px; padding: 5px 8px; }
  .layout { display: block; padding: 0 20px; }
  .sidebar { position: static; height: auto; border-right: 0; border-bottom: 1px solid var(--line); padding: 18px 0; overflow: visible; }
  .sidebar summary { padding: 0; cursor: pointer; list-style: disclosure-closed; letter-spacing: 0; font-size: 13px; }
  .sidebar ol { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px; }
  .sidebar li { margin: 0; }
  .sidebar li a { font-size: 12px; padding: 6px 3px; gap: 7px; }
  .sidebar-note { display: none; }
  .intro { padding-top: 32px; }
  h1 { font-size: 34px; }
  h2 { font-size: 23px; }
  .lead { font-size: 15px; }
  section { padding-top: 28px; }
  .image-grid { grid-template-columns: 1fr; }
  .portraits { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; }
  .portraits figure { padding: 7px; }
  .portraits img { max-height: 330px; }
  .callout { padding: 15px; }
  th, td { padding: 10px; }
  .flow { grid-template-columns: 1fr; }
  .intro-links { gap: 18px; }
}
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }
@media print {
  @page { margin: 15mm; }
  body { font-size: 10pt; line-height: 1.7; color: black; }
  .topbar, .sidebar, .intro-links, .guide-grid, dialog, .skip-link, .doc-footer a { display: none; }
  .layout { display: block; max-width: none; padding: 0; }
  .intro { padding-top: 0; }
  h1 { font-size: 27pt; }
  h2 { font-size: 18pt; }
  h3 { font-size: 13pt; }
  h2, h3, summary { break-after: avoid; }
  section { padding: 20px 0; }
  .callout, figure, tr { break-inside: avoid; }
  figure img { max-height: 85mm; }
  a { color: inherit; text-decoration: none; }
  details { border: 0; padding: 0; }
  .image-grid { gap: 10px; }
  .table-wrap { overflow: visible; }
  table { font-size: 9pt; }
  main { padding-bottom: 0; }
}
