:root {
  --ink: #1b2430;
  --muted: #5c6776;
  --blue: #1a5fb4;
  --blue-deep: #123e78;
  --paper: #f3efe6;
  --card: #fffcf7;
  --line: #e4dccb;
  --coral: #c4512c;
  --head: 68px;
  --max: 1120px;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  color: var(--ink);
  background:
    radial-gradient(1200px 420px at 10% -10%, #d9e8ff 0%, transparent 55%),
    var(--paper);
  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); }
a:hover { color: var(--coral); }

.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  background: #fff;
  padding: 6px 10px;
  z-index: 80;
}
.skip:focus { top: 8px; }

.sticky-stack {
  position: sticky;
  top: 0;
  z-index: 40;
  background: rgba(255, 252, 247, 0.96);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--line);
}

.site-header {
  height: var(--head);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: var(--max);
  margin: 0 auto;
  padding: 0 18px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--ink);
  min-width: 180px;
}
.brand img {
  width: 42px;
  height: 42px;
  border-radius: 10px;
}
.brand strong { display: block; font-size: 16px; letter-spacing: 0.02em; }
.brand span { display: block; color: var(--muted); font-size: 12px; line-height: 1.2; }

.nav-toggle {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: 0;
  opacity: 0;
  pointer-events: none;
}
.nav-btn {
  display: none;
  width: 44px;
  height: 44px;
  margin-left: auto;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  cursor: pointer;
  flex: 0 0 auto;
}
.nav-btn span,
.nav-btn span::before,
.nav-btn span::after {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
}
.nav-btn span { position: relative; }
.nav-btn span::before,
.nav-btn span::after {
  content: "";
  position: absolute;
  left: 0;
}
.nav-btn span::before { top: -6px; }
.nav-btn span::after { top: 6px; }
.nav-toggle:checked + .nav-btn span { background: transparent; }
.nav-toggle:checked + .nav-btn span::before { top: 0; transform: rotate(45deg); }
.nav-toggle:checked + .nav-btn span::after { top: 0; transform: rotate(-45deg); }
.nav-toggle:focus-visible + .nav-btn {
  outline: 2px solid var(--blue);
  outline-offset: 2px;
}

.nav {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 6px 14px;
}
.nav a {
  text-decoration: none;
  color: var(--ink);
  font-size: 15px;
  padding: 4px 0;
  border-bottom: 2px solid transparent;
}
.nav a[aria-current="page"] {
  color: var(--blue);
  border-bottom-color: var(--blue);
}

.wrap {
  max-width: var(--max);
  margin: 0 auto;
  padding: 28px 18px 64px;
}

.age {
  display: inline-block;
  background: var(--coral);
  color: #fff;
  border-radius: 999px;
  font-size: 12px;
  letter-spacing: 0.08em;
  padding: 2px 8px;
  vertical-align: middle;
}

h1 {
  font-size: 34px;
  line-height: 1.35;
  margin: 8px 0 12px;
}
h2 {
  font-size: 26px;
  line-height: 1.4;
  margin: 42px 0 12px;
  padding-top: 8px;
}
h3 { font-size: 20px; margin: 22px 0 8px; }
p { margin: 0 0 14px; }
.lead { font-size: 18px; color: #243041; }

.card, .note, .toc, .faq, .panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 16px;
  padding: 16px 18px;
}
.toc ol { margin: 8px 0 0; padding-left: 20px; }
.toc a { text-decoration: none; }
.note { border-left: 4px solid var(--blue); margin: 16px 0; }

.grid-2, .grid-3 {
  display: grid;
  gap: 14px;
}
.grid-2 { grid-template-columns: 1fr 1fr; }
.grid-3 { grid-template-columns: repeat(3, 1fr); }

.shots {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin: 16px 0 8px;
}
main figure {
  margin: 0;
  background: #101820;
  border-radius: 22px;
  padding: 10px 10px 12px;
  color: #f4efe6;
}
main figure img {
  display: block;
  width: 100%;
  border-radius: 16px;
  background: #1b2430;
}
main figcaption {
  font-size: 13px;
  line-height: 1.55;
  padding: 8px 4px 0;
  color: #efe7da;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border-radius: 12px;
  overflow: hidden;
  margin: 12px 0 18px;
}
th, td {
  border: 1px solid var(--line);
  text-align: left;
  padding: 10px 12px;
  vertical-align: top;
}
th { background: #e7f0fb; }

ol.steps { padding-left: 22px; }
ol.steps li { margin: 0 0 8px; }

details {
  border-top: 1px solid var(--line);
  padding: 8px 0;
}
details:first-of-type { border-top: 0; }
summary { cursor: pointer; font-weight: 700; }
.faq details p { margin: 8px 0 4px; }

.site-footer {
  border-top: 1px solid var(--line);
  background: #fffaf3;
  padding: 28px 18px 40px;
}
.site-footer .inner { max-width: var(--max); margin: 0 auto; }
.foot-links { display: flex; flex-wrap: wrap; gap: 10px 16px; margin-bottom: 8px; }
.foot-links a { text-decoration: none; }
.muted { color: var(--muted); font-size: 14px; }

.error-box {
  min-height: 42vh;
  display: grid;
  align-content: start;
  gap: 8px;
}
.error-code {
  font-size: 64px;
  line-height: 1;
  margin: 0;
  color: var(--blue-deep);
}

.brand-hero {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 16px;
  align-items: center;
}
.brand-hero img {
  width: 120px;
  height: 120px;
  border-radius: 24px;
}

@media (max-width: 900px) {
  h1 { font-size: 28px; }
  .grid-2, .grid-3, .shots { grid-template-columns: 1fr 1fr; }
  .site-header {
    position: relative;
    z-index: 2;
    height: 64px;
    flex-direction: row;
    align-items: center;
    padding: 0 14px;
  }
  .brand { min-width: 0; flex: 1; }
  .brand strong { font-size: 15px; white-space: nowrap; }
  .nav-btn { display: inline-flex; }
  .nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    margin: 0;
    padding: 6px 16px 12px;
    background: #fffcf7;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 14px 28px rgba(24, 24, 24, 0.08);
  }
  .nav-toggle:checked ~ .nav { display: flex; }
  .nav a {
    padding: 12px 0;
    font-size: 16px;
    border-bottom: 1px solid var(--line);
  }
  .nav a:last-child { border-bottom: 0; }
  .nav a[aria-current="page"] { border-bottom-color: var(--line); }
}
@media (max-width: 640px) {
  .grid-3, .brand-hero { grid-template-columns: 1fr; }
  .shots { grid-template-columns: 1fr 1fr; gap: 10px; }
  body { font-size: 16px; }
}
