:root {
  --ink: #111827;
  --muted: #5f6879;
  --paper: #ffffff;
  --canvas: #ffffff;
  --soft: #f6f8fb;
  --line: #e2e7f0;
  --brand: #2463eb;
  --brand-dark: #1d4ed8;
  --brand-soft: #eef3ff;
  --blue-soft: #edf6ff;
  --amber-soft: #fff6e8;
  --radius: 14px;
  --content: 1120px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 86px;
}

body {
  margin: 0;
  color: var(--ink);
  background: var(--canvas);
  font-family: Inter, "SF Pro Text", "PingFang SC", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
  font-size: 16px;
  line-height: 1.75;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body.menu-open {
  overflow: hidden;
}

a {
  color: var(--brand-dark);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

a:hover {
  color: var(--brand);
}

img {
  display: block;
  max-width: 100%;
}

button,
input {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

:focus-visible {
  outline: 3px solid rgba(36, 99, 235, 0.24);
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  padding: 0;
  border: 0;
  clip: rect(0 0 0 0);
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip-link {
  position: fixed;
  z-index: 1000;
  top: 10px;
  left: 12px;
  padding: 8px 13px;
  color: #fff;
  background: var(--brand-dark);
  border-radius: 8px;
  transform: translateY(-160%);
}

.skip-link:focus {
  transform: translateY(0);
}

.container {
  width: min(calc(100% - 40px), var(--content));
  margin-inline: auto;
}

.site-header {
  position: sticky;
  z-index: 100;
  top: 0;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid var(--line);
  backdrop-filter: blur(12px);
}

.header-inner {
  min-height: 64px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  font-size: 17px;
  font-weight: 800;
  letter-spacing: -0.02em;
  text-decoration: none;
  white-space: nowrap;
}

.brand:hover {
  color: var(--ink);
}

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--brand);
  border-radius: 9px;
}

.brand-mark > span {
  font-size: 16px;
  font-weight: 850;
  line-height: 1;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 2px;
}

.site-nav > a,
.nav-group > a {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 8px 13px;
  color: #3d4656;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 650;
  text-decoration: none;
}

.site-nav > a:hover,
.site-nav > a[aria-current="page"],
.nav-group > a:hover,
.nav-group > a[aria-current="page"] {
  color: var(--brand-dark);
  background: var(--brand-soft);
}

.nav-group {
  position: relative;
}

.nav-dropdown {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  width: 168px;
  display: grid;
  gap: 2px;
  padding: 8px;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 11px;
  box-shadow: 0 12px 30px rgba(28, 39, 61, 0.1);
  opacity: 0;
  pointer-events: none;
  transform: translateY(-5px);
  transition: opacity 140ms ease, transform 140ms ease;
}

.nav-group:hover .nav-dropdown,
.nav-group:focus-within .nav-dropdown {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.nav-dropdown a {
  padding: 8px 10px;
  color: #485164;
  border-radius: 7px;
  font-size: 13px;
  text-decoration: none;
}

.nav-dropdown a:hover {
  color: var(--brand-dark);
  background: var(--brand-soft);
}

.menu-button {
  width: 42px;
  height: 42px;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 10px;
  cursor: pointer;
}

.ui-menu {
  font-size: 21px;
  line-height: 1;
}

.reading-progress {
  position: fixed;
  z-index: 120;
  top: 63px;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--brand);
}

.hero {
  padding: 78px 0 72px;
}

.hero-shell {
  max-width: 870px;
  text-align: center;
}

.hero h1 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(42px, 6vw, 64px);
  line-height: 1.12;
  letter-spacing: -0.05em;
}

.hero-lead {
  max-width: 760px;
  margin: 22px auto 0;
  color: var(--muted);
  font-size: clamp(17px, 2vw, 20px);
  line-height: 1.8;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 11px;
  margin-top: 30px;
}

.button {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 17px;
  color: #fff;
  background: var(--brand);
  border: 1px solid var(--brand);
  border-radius: 9px;
  font-size: 14px;
  font-weight: 750;
  line-height: 1.3;
  text-decoration: none;
  transition: background 140ms ease, border-color 140ms ease, transform 140ms ease;
}

.button:hover {
  color: #fff;
  background: var(--brand-dark);
  border-color: var(--brand-dark);
  transform: translateY(-1px);
}

.button-secondary {
  color: var(--brand-dark);
  background: #fff;
  border-color: #cfd8ea;
}

.button-secondary:hover {
  color: var(--brand-dark);
  background: var(--brand-soft);
  border-color: #b9c9ed;
}

.ui-arrow {
  display: inline-block;
  margin-left: 3px;
  font-size: 15px;
  line-height: 1;
}

.quick-path {
  padding: 50px 0;
  background: var(--soft);
  border-block: 1px solid #edf0f5;
}

.path-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}

.path-card {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 19px;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-decoration: none;
  transition: border-color 140ms ease, transform 140ms ease;
}

.path-card:hover {
  color: var(--ink);
  border-color: #aec2ee;
  transform: translateY(-2px);
}

.path-icon {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  color: var(--brand-dark);
  background: var(--brand-soft);
  border-radius: 10px;
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.05em;
}

.path-card strong {
  display: block;
  font-size: 16px;
}

.path-card small {
  display: block;
  margin-top: 1px;
  color: var(--muted);
  font-size: 12px;
}

.path-arrow {
  color: #8b95a5;
  font-size: 19px;
}

.section {
  padding: 66px 0;
}

.section + .section {
  border-top: 1px solid #edf0f5;
}

.section-tight {
  padding: 46px 0 4px;
}

.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 26px;
}

.section-head h2,
.section-title {
  margin: 0;
  font-size: clamp(27px, 3vw, 36px);
  line-height: 1.25;
  letter-spacing: -0.035em;
}

.section-head p {
  max-width: 650px;
  margin: 7px 0 0;
  color: var(--muted);
}

.section-more {
  flex: 0 0 auto;
  color: var(--brand-dark);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.search-box,
.toolbar-search {
  position: relative;
  display: block;
}

.search-box {
  max-width: 700px;
  margin: 0 auto 22px;
}

.search-box .ui-search,
.toolbar-search .ui-search {
  position: absolute;
  top: 50%;
  left: 14px;
  color: #7d8797;
  font-size: 22px;
  line-height: 1;
  pointer-events: none;
  transform: translateY(-50%);
}

.search-box input,
.toolbar-search input {
  width: 100%;
  min-height: 48px;
  padding: 10px 15px 10px 42px;
  color: var(--ink);
  background: #fff;
  border: 1px solid #d5dce8;
  border-radius: 10px;
}

.search-box input:focus,
.toolbar-search input:focus {
  border-color: var(--brand);
  outline: 3px solid rgba(36, 99, 235, 0.12);
}

.search-box input::placeholder,
.toolbar-search input::placeholder {
  color: #8c96a6;
}

.search-count {
  min-height: 24px;
  margin: -10px 0 18px;
  color: var(--muted);
  font-size: 13px;
  text-align: center;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
}

.content-card {
  overflow: hidden;
  display: flex;
  min-width: 0;
  flex-direction: column;
  color: var(--ink);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-decoration: none;
  transition: border-color 150ms ease, transform 150ms ease, box-shadow 150ms ease;
}

.content-card:hover {
  color: var(--ink);
  border-color: #afc2ed;
  box-shadow: 0 10px 26px rgba(32, 56, 107, 0.07);
  transform: translateY(-2px);
}

.content-card[hidden] {
  display: none;
}

.card-image {
  aspect-ratio: 16 / 9;
  overflow: hidden;
  background: var(--soft);
  border-bottom: 1px solid var(--line);
}

.card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.card-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 18px;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 10px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 23px;
  padding: 3px 8px;
  color: #3157a7;
  background: var(--brand-soft);
  border-radius: 999px;
  font-size: 11px;
  font-weight: 750;
  line-height: 1.35;
}

.tag-blue {
  color: #1e5a86;
  background: var(--blue-soft);
}

.tag-amber {
  color: #8a560c;
  background: var(--amber-soft);
}

.card-body h3 {
  margin: 0;
  font-size: 19px;
  line-height: 1.4;
  letter-spacing: -0.015em;
}

.card-body p {
  margin: 9px 0 17px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.7;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: auto;
  color: #7a8494;
  font-size: 12px;
}

.text-link {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  color: var(--brand-dark);
  font-weight: 750;
}

.empty-state {
  display: none;
  padding: 34px;
  color: var(--muted);
  background: var(--soft);
  border: 1px dashed #bfc8d6;
  border-radius: var(--radius);
  text-align: center;
}

.empty-state.visible {
  display: block;
}

.empty-state p {
  margin: 5px 0 0;
}

.guide-strip {
  padding: 62px 0;
  background: var(--soft);
  border-top: 1px solid #edf0f5;
}

.guide-strip-inner {
  display: grid;
  grid-template-columns: 0.8fr 2.2fr;
  gap: 54px;
  align-items: start;
}

.guide-strip h2 {
  margin: 0;
  font-size: 29px;
  line-height: 1.25;
}

.guide-strip p {
  margin: 11px 0 0;
  color: var(--muted);
}

.decision-list {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 22px;
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: decision;
}

.decision-list li {
  position: relative;
  padding-top: 39px;
  counter-increment: decision;
}

.decision-list li::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--brand);
  border-radius: 7px;
  content: counter(decision);
  font-size: 12px;
  font-weight: 800;
}

.decision-list strong {
  display: block;
  font-size: 15px;
}

.decision-list span {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  font-size: 13px;
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  padding: 20px 0 0;
  color: #7a8494;
  font-size: 12px;
}

.breadcrumb a {
  color: #667083;
  text-decoration: none;
}

.breadcrumb .separator {
  color: #a9b1bd;
}

.page-hero {
  padding: 28px 0 34px;
}

.page-hero-box {
  padding: clamp(30px, 5vw, 52px);
  background: var(--soft);
  border: 1px solid #edf0f5;
  border-radius: 18px;
}

.page-hero h1 {
  max-width: 900px;
  margin: 0;
  font-size: clamp(34px, 5vw, 50px);
  line-height: 1.16;
  letter-spacing: -0.045em;
}

.page-hero p {
  max-width: 780px;
  margin: 15px 0 0;
  color: var(--muted);
  font-size: 16px;
}

.page-hero-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 17px;
  margin-top: 19px;
  color: #6e7889;
  font-size: 12px;
}

.page-hero-meta span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.ui-meta {
  font-size: 13px;
  line-height: 1;
}

.article-hero .page-hero-box {
  background: #fff;
  border-color: var(--line);
}

.hero-tags {
  margin-bottom: 15px;
}

.filter-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  margin-bottom: 12px;
  padding: 16px 0 20px;
  border-bottom: 1px solid var(--line);
}

.filter-tab-wrap {
  min-width: 0;
  display: flex;
  align-items: center;
  gap: 13px;
}

.filter-label {
  flex: 0 0 auto;
  color: #495366;
  font-size: 13px;
  font-weight: 750;
}

.filter-tabs {
  display: flex;
  gap: 7px;
}

.filter-tabs button {
  flex: 0 0 auto;
  min-height: 34px;
  padding: 6px 12px;
  color: #566074;
  background: #fff;
  border: 1px solid #d7deea;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 650;
  cursor: pointer;
}

.filter-tabs button:hover,
.filter-tabs button[aria-pressed="true"] {
  color: #fff;
  background: var(--brand);
  border-color: var(--brand);
}

.toolbar-search {
  width: 260px;
  flex: 0 0 260px;
}

.toolbar-search input {
  min-height: 38px;
  font-size: 13px;
}

.group-section {
  padding: 42px 0 56px;
}

.group-section + .group-section {
  border-top: 1px solid var(--line);
}

.group-section[hidden] {
  display: none;
}

.group-head {
  display: grid;
  grid-template-columns: minmax(190px, 0.55fr) minmax(0, 1.45fr);
  gap: 36px;
  margin-bottom: 22px;
}

.group-head h2 {
  margin: 0;
  font-size: 26px;
  letter-spacing: -0.025em;
}

.group-head p {
  margin: 0;
  color: var(--muted);
}

.article-shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 250px;
  gap: 30px;
  align-items: start;
  padding: 12px 0 72px;
}

.article-content {
  min-width: 0;
  padding: clamp(28px, 5vw, 48px);
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
}

.article-content > :first-child {
  margin-top: 0;
}

.article-content h2 {
  margin: 48px 0 16px;
  padding-left: 14px;
  border-left: 4px solid var(--brand);
  font-size: clamp(24px, 3vw, 29px);
  line-height: 1.35;
  letter-spacing: -0.025em;
}

.article-content h3 {
  margin: 30px 0 10px;
  font-size: 19px;
  line-height: 1.45;
}

.article-content p {
  margin: 14px 0;
  color: #344054;
}

.article-content a {
  overflow-wrap: anywhere;
}

.article-content ul,
.article-content ol {
  padding-left: 1.45em;
}

.article-content li + li {
  margin-top: 7px;
}

.article-lead {
  margin-bottom: 27px !important;
  color: #263247 !important;
  font-size: 17px;
  line-height: 1.85;
}

.article-figure {
  margin: 0 0 30px;
}

.article-figure img {
  width: 100%;
  max-height: 560px;
  object-fit: contain;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 13px;
}

.article-figure figcaption {
  margin-top: 7px;
  color: #7b8494;
  font-size: 11px;
  text-align: center;
}

.article-figure figcaption a {
  color: inherit;
}

.fact-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  overflow: hidden;
  margin: 20px 0 29px;
  padding: 1px;
  background: var(--line);
  border-radius: 11px;
}

.fact {
  padding: 14px 16px;
  background: #fafbfd;
}

.fact dt {
  color: #7a8494;
  font-size: 11px;
  font-weight: 700;
}

.fact dd {
  margin: 2px 0 0;
  color: var(--ink);
  font-size: 13px;
  font-weight: 750;
}

.steps {
  margin: 22px 0 34px !important;
  padding: 0 !important;
  list-style: none;
  counter-reset: steps;
}

.steps > li {
  position: relative;
  min-height: 50px;
  padding: 0 0 25px 52px;
  counter-increment: steps;
}

.steps > li::before {
  position: absolute;
  top: 0;
  left: 0;
  width: 33px;
  height: 33px;
  display: grid;
  place-items: center;
  color: #fff;
  background: var(--brand);
  border-radius: 8px;
  content: counter(steps);
  font-size: 13px;
  font-weight: 800;
}

.steps > li:not(:last-child)::after {
  position: absolute;
  top: 39px;
  bottom: 4px;
  left: 16px;
  width: 1px;
  content: "";
  background: var(--line);
}

.steps strong {
  display: block;
  margin-bottom: 3px;
  color: var(--ink);
  font-size: 16px;
}

.steps p {
  margin: 0;
  color: var(--muted);
  font-size: 14px;
}

.callout {
  margin: 23px 0;
  padding: 16px 18px;
  background: var(--brand-soft);
  border-left: 4px solid var(--brand);
  border-radius: 8px;
}

.callout.warning {
  background: var(--amber-soft);
  border-left-color: #d58a16;
}

.callout strong {
  display: block;
  margin-bottom: 2px;
  color: var(--ink);
}

.callout p {
  margin: 0;
  color: #4c5769;
  font-size: 13px;
}

.official-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin: 27px 0;
  padding: 17px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 11px;
}

.official-card strong,
.official-card span {
  display: block;
}

.official-card span {
  margin-top: 2px;
  color: var(--muted);
  font-size: 12px;
  word-break: break-all;
}

.official-card .button {
  flex: 0 0 auto;
}

.check-list {
  margin: 22px 0 !important;
  padding: 0 !important;
  list-style: none;
}

.check-list li {
  position: relative;
  padding-left: 29px;
}

.check-list li::before {
  position: absolute;
  top: 0.36em;
  left: 0;
  width: 18px;
  height: 18px;
  display: grid;
  place-items: center;
  color: var(--brand-dark);
  background: var(--brand-soft);
  border: 1px solid #c6d4f3;
  border-radius: 5px;
  content: "✓";
  font-size: 11px;
  font-weight: 900;
}

.faq {
  margin-top: 20px;
  border-top: 1px solid var(--line);
}

.faq details {
  border-bottom: 1px solid var(--line);
}

.faq summary {
  position: relative;
  padding: 16px 30px 16px 0;
  cursor: pointer;
  font-weight: 750;
  list-style: none;
}

.faq summary::-webkit-details-marker {
  display: none;
}

.faq summary::after {
  position: absolute;
  top: 15px;
  right: 4px;
  content: "+";
  color: var(--brand);
  font-size: 21px;
  line-height: 1;
}

.faq details[open] summary::after {
  content: "−";
}

.faq details p {
  margin: -3px 0 16px;
  color: var(--muted);
  font-size: 13px;
}

.article-aside {
  position: sticky;
  top: 86px;
}

.toc,
.aside-card {
  padding: 17px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 11px;
}

.toc strong,
.aside-card > strong {
  display: block;
  margin-bottom: 9px;
  font-size: 13px;
}

.toc ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

.toc li + li {
  margin-top: 6px;
}

.toc a {
  display: block;
  color: #687386;
  font-size: 12px;
  line-height: 1.5;
  text-decoration: none;
}

.toc a:hover,
.toc a.active {
  color: var(--brand-dark);
}

.aside-card {
  margin-top: 12px;
  color: var(--muted);
  font-size: 12px;
}

.aside-card p {
  margin: 0 0 10px;
}

.aside-card > a {
  font-weight: 750;
}

.mini-related {
  display: block;
  padding: 9px 0;
  color: #3e485a;
  border-top: 1px solid #edf0f5;
  font-size: 12px;
  line-height: 1.45;
  text-decoration: none;
}

.mini-related span {
  display: block;
  margin-bottom: 2px;
  color: var(--brand-dark);
  font-size: 10px;
  font-weight: 750;
}

.mini-related:hover {
  color: var(--brand-dark);
}

.related-section {
  margin-top: 48px;
  padding-top: 31px;
  border-top: 1px solid var(--line);
}

.related-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 17px;
}

.article-content .related-head h2 {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 23px;
}

.related-head > a {
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 700;
  text-decoration: none;
}

.related-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
}

.related-card {
  min-width: 0;
  display: flex;
  flex-direction: column;
  padding: 15px;
  color: var(--ink);
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 10px;
  text-decoration: none;
}

.related-card:hover {
  color: var(--ink);
  border-color: #afc2ed;
}

.related-card span {
  color: var(--brand-dark);
  font-size: 10px;
  font-weight: 750;
}

.related-card strong {
  margin-top: 4px;
  font-size: 14px;
  line-height: 1.45;
}

.related-card small {
  display: -webkit-box;
  overflow: hidden;
  margin-top: 5px;
  color: var(--muted);
  font-size: 11px;
  line-height: 1.55;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
}

.prev-next {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 11px;
  margin-top: 39px;
  padding-top: 25px;
  border-top: 1px solid var(--line);
}

.prev-next a {
  padding: 13px 14px;
  color: var(--ink);
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 9px;
  text-decoration: none;
}

.prev-next a:hover {
  border-color: #afc2ed;
}

.prev-next a:last-child {
  text-align: right;
}

.prev-next small {
  display: block;
  color: #7c8696;
  font-size: 10px;
}

.prev-next strong {
  display: block;
  margin-top: 2px;
  font-size: 13px;
}

.site-footer {
  padding: 48px 0 25px;
  color: #596476;
  background: var(--soft);
  border-top: 1px solid var(--line);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.3fr repeat(3, 0.7fr);
  gap: 36px;
}

.footer-brand p {
  max-width: 370px;
  margin: 13px 0 0;
  color: #6d7788;
  font-size: 13px;
}

.footer-column strong {
  display: block;
  margin-bottom: 11px;
  color: var(--ink);
  font-size: 13px;
}

.footer-column a {
  display: block;
  width: fit-content;
  color: #626d7e;
  font-size: 12px;
  text-decoration: none;
}

.footer-column a + a {
  margin-top: 6px;
}

.footer-column a:hover {
  color: var(--brand-dark);
}

.resource-notice {
  margin-top: 32px;
  padding: 16px 18px;
  color: #667184;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 10px;
  font-size: 12px;
  line-height: 1.7;
}

.resource-notice a {
  overflow-wrap: anywhere;
}

.footer-bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  margin-top: 34px;
  padding-top: 18px;
  color: #7b8595;
  border-top: 1px solid var(--line);
  font-size: 11px;
}

.footer-bottom p {
  margin: 0;
}

.back-to-top {
  position: fixed;
  z-index: 80;
  right: 20px;
  bottom: 20px;
  width: 42px;
  height: 42px;
  display: grid;
  place-items: center;
  padding: 0;
  color: #fff;
  background: var(--brand);
  border: 0;
  border-radius: 10px;
  box-shadow: 0 8px 20px rgba(36, 99, 235, 0.18);
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transform: translateY(8px);
  transition: opacity 140ms ease, transform 140ms ease;
}

.back-to-top.visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.back-to-top > span {
  font-size: 20px;
  line-height: 1;
}

.not-found {
  min-height: 65vh;
  display: grid;
  place-items: center;
  padding: 70px 0;
  text-align: center;
}

.not-found-card {
  max-width: 600px;
  padding: 46px;
  background: var(--soft);
  border: 1px solid var(--line);
  border-radius: 16px;
}

.not-found-code {
  margin: 0;
  color: var(--brand);
  font-size: 68px;
  font-weight: 850;
  line-height: 1;
}

.not-found h1 {
  margin: 13px 0 7px;
}

.not-found p {
  margin: 0 0 22px;
  color: var(--muted);
}

@media (max-width: 980px) {
  .card-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .guide-strip-inner,
  .group-head {
    grid-template-columns: 1fr;
    gap: 22px;
  }

  .article-shell {
    grid-template-columns: minmax(0, 1fr) 220px;
    gap: 22px;
  }

  .filter-toolbar {
    align-items: flex-end;
  }

  .filter-tab-wrap {
    align-items: flex-start;
    flex-direction: column;
    gap: 7px;
  }

  .footer-grid {
    grid-template-columns: 1.3fr repeat(3, 0.7fr);
    gap: 24px;
  }
}

@media (max-width: 760px) {
  .container {
    width: min(calc(100% - 28px), var(--content));
  }

  .menu-button {
    display: inline-flex;
  }

  .site-nav {
    position: fixed;
    z-index: 99;
    inset: 65px 0 auto;
    max-height: calc(100vh - 65px);
    overflow-y: auto;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 3px;
    padding: 14px;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: 0 14px 28px rgba(28, 39, 61, 0.1);
  }

  .site-nav.open {
    display: flex;
  }

  .site-nav > a,
  .nav-group > a {
    padding: 10px 12px;
  }

  .nav-dropdown {
    position: static;
    width: auto;
    display: grid;
    margin: 2px 0 6px 14px;
    padding: 3px 0 3px 12px;
    background: transparent;
    border: 0;
    border-left: 2px solid var(--line);
    border-radius: 0;
    box-shadow: none;
    opacity: 1;
    pointer-events: auto;
    transform: none;
  }

  .reading-progress {
    top: 63px;
  }

  .hero {
    padding: 58px 0 54px;
  }

  .hero h1 {
    font-size: clamp(38px, 11vw, 49px);
  }

  .hero-lead {
    font-size: 16px;
  }

  .hero-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .hero-actions .button {
    width: 100%;
  }

  .quick-path {
    padding: 38px 0;
  }

  .path-grid,
  .card-grid,
  .decision-list,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .path-card {
    padding: 15px;
  }

  .section {
    padding: 50px 0;
  }

  .section-head {
    align-items: start;
    flex-direction: column;
    gap: 8px;
  }

  .guide-strip-inner {
    gap: 30px;
  }

  .page-hero {
    padding-bottom: 24px;
  }

  .page-hero-box {
    padding: 27px 21px;
    border-radius: 14px;
  }

  .page-hero h1 {
    font-size: clamp(30px, 8.8vw, 38px);
  }

  .filter-toolbar {
    align-items: stretch;
    flex-direction: column;
    gap: 13px;
  }

  .filter-tab-wrap {
    min-width: 0;
  }

  .filter-tabs {
    width: 100%;
    overflow-x: auto;
    padding-bottom: 5px;
    scrollbar-width: thin;
  }

  .toolbar-search {
    width: 100%;
    flex-basis: auto;
  }

  .article-shell {
    display: block;
    padding-bottom: 48px;
  }

  .article-content {
    padding: 25px 20px;
    border-radius: 13px;
  }

  .article-content h2 {
    margin-top: 42px;
  }

  .article-aside {
    display: none;
  }

  .fact-grid,
  .related-grid,
  .prev-next {
    grid-template-columns: 1fr;
  }

  .official-card {
    align-items: stretch;
    flex-direction: column;
  }

  .official-card .button {
    width: 100%;
  }

  .prev-next a:last-child {
    text-align: left;
  }

  .footer-grid {
    gap: 27px;
  }

  .footer-bottom {
    align-items: start;
    flex-direction: column;
  }

  .back-to-top {
    right: 13px;
    bottom: 13px;
  }
}

@media (max-width: 420px) {
  .hero h1 {
    font-size: 38px;
  }

  .brand-text {
    font-size: 16px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}

@media print {
  .site-header,
  .site-footer,
  .article-aside,
  .back-to-top,
  .reading-progress,
  .filter-toolbar {
    display: none !important;
  }

  body {
    background: #fff;
  }

  .article-shell {
    display: block;
  }

  .article-content {
    padding: 0;
    border: 0;
  }
}
