:root {
  --bg: #ffffff; --side: #f6f7f9; --line: #e3e6ea; --text: #1d2330; --muted: #5d6675;
  --brand: #1f5fd1; --brand-soft: #eaf1fd; --step: #1f5fd1;
}
* { box-sizing: border-box; }
html, body { margin: 0; background: var(--bg); color: var(--text);
  font: 14px/1.55 -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; }
a { color: var(--brand); text-decoration: none; }
a:hover { text-decoration: underline; }

header { display: flex; align-items: center; gap: 16px; height: 52px; padding: 0 20px;
  border-bottom: 1px solid var(--line); position: sticky; top: 0; background: var(--bg); z-index: 2; }
.logo { font-weight: 700; font-size: 15px; color: var(--text); white-space: nowrap; }
.logo:hover { text-decoration: none; }
.logo span { color: var(--muted); font-weight: 500; }
.search { flex: 1; max-width: 420px; margin-left: auto; position: relative; min-width: 0; }
.search input { width: 100%; height: 32px; padding: 0 10px; border: 1px solid var(--line);
  border-radius: 6px; font: inherit; background: var(--side); color: var(--text); }
.faq-link { font-size: 13px; white-space: nowrap; }
.results { position: absolute; top: 38px; left: 0; right: 0; background: var(--bg); border: 1px solid var(--line);
  border-radius: 6px; box-shadow: 0 6px 20px rgba(20,30,50,.12); max-height: 70vh; overflow-y: auto; z-index: 3; }
.results[hidden] { display: none; }
.results a { display: block; padding: 8px 12px; color: var(--text); border-bottom: 1px solid var(--line); }
.results a:last-child { border-bottom: 0; }
.results a:hover, .results a.sel { background: var(--brand-soft); text-decoration: none; }
.results b { display: block; font-weight: 600; color: var(--brand); }
.results small { display: block; color: var(--muted); font-size: 12px; }
.results .none { padding: 10px 12px; color: var(--muted); }
.results .none a { display: inline; padding: 0; border: 0; color: var(--brand); }
.skip { position: absolute; left: -9999px; top: 8px; background: var(--bg); padding: 6px 10px; border: 1px solid var(--line); z-index: 5; }
.skip:focus { left: 8px; }

.wrap { display: grid; grid-template-columns: 260px 1fr; min-height: calc(100vh - 52px); }
nav { background: var(--side); border-right: 1px solid var(--line); padding: 16px 0; font-size: 13px; }
nav details { margin: 2px 0; }
nav summary { list-style: none; cursor: pointer; display: flex; align-items: center; gap: 6px;
  padding: 8px 20px 4px; font-size: 11px; font-weight: 600; letter-spacing: .06em;
  text-transform: uppercase; color: var(--muted); user-select: none; }
nav summary::-webkit-details-marker { display: none; }
nav summary::before { content: ""; width: 0; height: 0; border-left: 4px solid currentColor;
  border-top: 4px solid transparent; border-bottom: 4px solid transparent; transition: transform .15s; }
nav details[open] > summary::before { transform: rotate(90deg); }
nav summary:hover { color: var(--text); }
nav a { display: block; padding: 4px 20px; color: var(--text); }
nav a:hover { background: #eceff3; text-decoration: none; }
nav a.active { background: var(--brand-soft); color: var(--brand); font-weight: 600; border-left: 3px solid var(--brand); padding-left: 17px; }

main { padding: 28px 40px 60px; max-width: 760px; min-width: 0; }
.crumbs { font-size: 12px; color: var(--muted); margin-bottom: 6px; }
.crumbs a { color: var(--muted); }
h1 { font-size: 22px; line-height: 1.3; margin: 0 0 6px; }
.updated { font-size: 12px; color: var(--muted); margin-bottom: 18px; }
h2 { font-size: 15px; margin: 22px 0 8px; }
p { margin: 0 0 10px; }
main ul { margin: 0 0 12px; padding-left: 20px; }
main ul li { margin: 0 0 4px; }
ol.steps { list-style: none; counter-reset: s; padding: 0; margin: 0 0 12px; }
ol.steps li { counter-increment: s; position: relative; padding: 2px 0 8px 32px; }
ol.steps li::before { content: counter(s); position: absolute; left: 0; top: 2px; width: 20px; height: 20px;
  border-radius: 50%; background: var(--step); color: #fff; font-size: 11px; font-weight: 700;
  display: flex; align-items: center; justify-content: center; }
.table-wrap { overflow-x: auto; margin: 6px 0 14px; }
table { border-collapse: collapse; width: 100%; font-size: 13px; }
th, td { border: 1px solid var(--line); padding: 6px 10px; text-align: left; vertical-align: top; }
thead th { background: var(--side); font-weight: 600; }
tbody th { font-weight: 500; }
td.mark { text-align: center; }
.related { margin-top: 28px; padding-top: 14px; border-top: 1px solid var(--line); font-size: 13px; }
.related h2 { font-size: 12px; text-transform: uppercase; letter-spacing: .06em; color: var(--muted); margin: 0 0 6px; }
.related a { display: block; padding: 2px 0; }
.cat-list { list-style: none; padding: 0; margin: 0 0 12px; }
.cat-list li { padding: 3px 0; }
.home-cat h2 a { color: var(--text); }
footer { margin-top: 36px; font-size: 12px; color: var(--muted); }

@media (max-width: 760px) {
  .wrap { grid-template-columns: 1fr; }
  nav { display: none; }
  main { padding: 20px 16px 48px; }
  header { padding: 0 16px; gap: 12px; }
  .faq-link { display: none; }
}
