:root {
  --c-primary: #0a1930;
  --c-panel: #10223f;
  --c-light: #f5f7fa;
  --c-accent: #ff6b35;
  --c-accent-soft: #ff8c5a;
  --c-muted: #a8b8d0;
  --c-line: #2a3d5c;
  --c-success: #22c55e;
  --c-warning: #f59e0b;
  --c-soft: #5d6f88;
  --font-head: 'Noto Sans SC', Impact, 'Arial Narrow', sans-serif;
  --font-body: Roboto, 'Noto Sans SC', 'PingFang SC', sans-serif;
  --font-num: 'DIN Alternate', 'Roboto Mono', 'SFMono-Regular', Consolas, monospace;
  --shell-width: 1320px;
  --shell-pad: 24px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.8;
  background: var(--c-light);
  color: #182337;
}

img,
svg,
video {
  max-width: 100%;
  height: auto;
  display: block;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  margin: 0 0 0.5em;
  font-family: var(--font-head);
  font-weight: 900;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--c-primary);
}

h1 {
  font-size: clamp(2.6rem, 6vw, 4.4rem);
}

h2 {
  font-size: clamp(1.8rem, 3.2vw, 2.75rem);
}

h3 {
  font-size: 1.35rem;
}

p {
  margin: 0 0 1em;
}

a {
  color: var(--c-accent);
  text-decoration-thickness: 2px;
  text-underline-offset: 2px;
}

ul,
ol {
  padding-left: 1.1rem;
}

button {
  font: inherit;
  cursor: pointer;
}

:focus-visible {
  outline: 3px solid var(--c-accent);
  outline-offset: 3px;
}

.shell {
  width: min(calc(100% - 2 * var(--shell-pad)), var(--shell-width));
  margin-inline: auto;
}

.main-content {
  min-height: 62vh;
  scroll-margin-top: 140px;
}

.skip-link {
  position: fixed;
  top: 0;
  left: 16px;
  z-index: 2000;
  padding: 12px 20px;
  background: var(--c-accent);
  color: var(--c-primary);
  font-weight: 800;
  text-decoration: none;
  transform: translateY(-160%);
  transition: transform 0.18s ease;
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--c-primary);
  color: var(--c-light);
  border-bottom: 1px solid var(--c-line);
}

.site-header::before {
  content: "";
  display: block;
  height: 4px;
  background: linear-gradient(90deg, var(--c-accent) 0%, var(--c-accent-soft) 60%, transparent 100%);
}

.site-progress {
  position: absolute;
  top: 0;
  left: 0;
  z-index: 2;
  width: 100%;
  height: 3px;
  pointer-events: none;
}

.site-progress span {
  display: block;
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, var(--c-accent), var(--c-accent-soft));
}

.header-meta {
  background: var(--c-panel);
  border-bottom: 1px solid var(--c-line);
}

.header-meta__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding-block: 12px;
}

.header-meta__inner::after {
  content: "";
  flex: 0 0 auto;
  width: 64px;
  height: 6px;
  background: linear-gradient(90deg, var(--c-accent), var(--c-accent-soft));
  transform: skewX(-24deg);
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
  min-width: 0;
  color: var(--c-light);
  text-decoration: none;
}

.brand__mark {
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 46px;
  height: 46px;
  background: var(--c-accent);
  color: var(--c-primary);
  font-family: var(--font-head);
  font-size: 24px;
  font-weight: 900;
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
}

.brand__text {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.brand__name {
  font-size: 1.35rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  line-height: 1;
  color: var(--c-light);
}

.brand__name sub {
  font-size: 0.6em;
  font-weight: 800;
  color: var(--c-accent-soft);
  margin-left: 2px;
}

.brand__tagline {
  margin-top: 5px;
  font-size: 12px;
  line-height: 1.4;
  color: var(--c-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.header-meta__icp {
  flex: 0 0 auto;
  padding-left: 16px;
  border-left: 1px solid var(--c-line);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--c-muted);
}

.header-nav-bar {
  position: relative;
  background: rgba(0, 0, 0, 0.14);
}

.header-nav-bar__inner {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-height: 56px;
}

.site-nav__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-nav__link {
  position: relative;
  display: inline-block;
  padding: 18px 16px;
  color: var(--c-muted);
  font-weight: 700;
  font-size: 0.95rem;
  letter-spacing: 0.02em;
  text-decoration: none;
  transition: color 0.18s ease;
}

.site-nav__link::after {
  content: "";
  position: absolute;
  left: 16px;
  right: 16px;
  bottom: 10px;
  height: 3px;
  background: linear-gradient(90deg, var(--c-accent), var(--c-accent-soft));
  transform: scaleX(0);
  transform-origin: left;
  transition: transform 0.2s ease;
}

.site-nav__link:hover,
.site-nav__link:focus-visible {
  color: var(--c-light);
}

.site-nav__link:hover::after,
.site-nav__link:focus-visible::after,
.site-nav__link[aria-current="page"]::after {
  transform: scaleX(1);
}

.site-nav__link[aria-current="page"] {
  color: #ffffff;
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  background: transparent;
  border: 1px solid var(--c-line);
  color: var(--c-light);
  clip-path: polygon(0 0, calc(100% - 10px) 0, 100% 10px, 100% 100%, 10px 100%, 0 calc(100% - 10px));
  transition: border-color 0.18s ease, color 0.18s ease;
}

.nav-toggle:hover,
.nav-toggle[aria-expanded="true"] {
  border-color: var(--c-accent);
  color: var(--c-accent);
}

.nav-toggle__box {
  position: relative;
  width: 22px;
  height: 14px;
}

.nav-toggle__box span {
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: currentColor;
  transition: transform 0.2s ease, opacity 0.2s ease, top 0.2s ease;
}

.nav-toggle__box span:nth-child(1) { top: 0; }
.nav-toggle__box span:nth-child(2) { top: 6px; }
.nav-toggle__box span:nth-child(3) { top: 12px; }

.nav-toggle[aria-expanded="true"] .nav-toggle__box span:nth-child(1) { top: 6px; transform: rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__box span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__box span:nth-child(3) { top: 6px; transform: rotate(-45deg); }

.nav-toggle__label {
  font-weight: 800;
  font-size: 0.85rem;
}

.site-footer {
  position: relative;
  overflow: hidden;
  padding-top: 72px;
  background: var(--c-primary);
  color: var(--c-light);
}

.site-footer::before {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  width: 45%;
  height: 100%;
  background: linear-gradient(115deg, transparent 46%, rgba(16, 34, 63, 0.6) 46%, rgba(16, 34, 63, 0.4) 85%, transparent 85%);
  pointer-events: none;
}

.footer-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr;
  gap: 48px;
  padding-bottom: 56px;
}

.footer-brand__logo {
  display: inline-block;
  margin-bottom: 18px;
  padding-bottom: 6px;
  border-bottom: 3px solid var(--c-accent);
  font-family: var(--font-head);
  font-size: 1.8rem;
  font-weight: 900;
  letter-spacing: -0.02em;
  color: var(--c-light);
  text-decoration: none;
  transition: border-color 0.18s ease, color 0.18s ease;
}

.footer-brand__logo:hover {
  border-color: var(--c-accent-soft);
  color: var(--c-accent-soft);
}

.footer-brand__desc {
  max-width: 54ch;
  margin-bottom: 18px;
  font-size: 0.95rem;
  line-height: 1.8;
  color: var(--c-muted);
}

.footer-trust {
  margin: 0;
  padding-left: 16px;
  border-left: 3px solid var(--c-accent);
  background: linear-gradient(90deg, rgba(255, 107, 53, 0.12), transparent 70%);
  font-size: 0.9rem;
  line-height: 1.8;
  color: var(--c-muted);
}

.footer-title {
  margin: 0 0 18px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--c-line);
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-light);
}

.footer-contact p {
  margin: 0 0 8px;
  color: var(--c-muted);
}

.footer-contact__note {
  font-size: 0.85rem;
}

.footer-links ul {
  margin: 0 0 24px;
  padding: 0;
  list-style: none;
}

.footer-links li + li {
  margin-top: 10px;
}

.footer-links a {
  color: var(--c-muted);
  text-decoration: none;
  transition: color 0.18s ease, padding-left 0.18s ease;
}

.footer-links a:hover {
  color: var(--c-accent);
  padding-left: 4px;
}

.footer-icp {
  display: inline-block;
  padding: 6px 12px;
  border: 1px solid var(--c-line);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--c-muted);
}

.footer-bottom {
  border-top: 1px solid var(--c-line);
  padding: 20px 0;
  text-align: center;
  font-size: 0.85rem;
  color: var(--c-muted);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 24px;
  background: var(--c-accent);
  border: 1px solid var(--c-accent);
  color: var(--c-primary);
  font-weight: 800;
  line-height: 1;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  clip-path: polygon(12px 0, 100% 0, calc(100% - 12px) 100%, 0 100%);
  transition: background 0.18s ease, border-color 0.18s ease, color 0.18s ease, transform 0.18s ease, box-shadow 0.18s ease;
}

.btn:hover {
  background: var(--c-accent-soft);
  border-color: var(--c-accent-soft);
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(255, 107, 53, 0.22);
}

.btn:active {
  transform: translateY(0);
}

.btn--dark {
  background: var(--c-primary);
  border-color: var(--c-primary);
  color: var(--c-light);
}

.btn--dark:hover {
  background: var(--c-panel);
  border-color: var(--c-panel);
  box-shadow: 0 8px 20px rgba(10, 25, 48, 0.25);
}

.btn--outline {
  background: transparent;
  border-color: var(--c-primary);
  color: var(--c-primary);
}

.btn--outline:hover {
  background: var(--c-primary);
  border-color: var(--c-primary);
  color: var(--c-light);
  box-shadow: 0 8px 20px rgba(10, 25, 48, 0.18);
}

.section {
  padding: 80px 0;
}

.section--tight {
  padding: 48px 0;
}

.section--dark {
  background: var(--c-primary);
  color: var(--c-light);
}

.section--dark .section-title,
.section--dark h1,
.section--dark h2,
.section--dark h3 {
  color: var(--c-light);
}

.section-kicker {
  margin-bottom: 8px;
  font-family: var(--font-head);
  font-size: 0.875rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-accent);
}

.section-title {
  margin-bottom: 16px;
}

.section-intro {
  max-width: 68ch;
  margin-bottom: 0;
  font-size: 1.05rem;
  color: var(--c-soft);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 12px;
  margin: 0 0 32px;
  padding: 0;
  list-style: none;
  font-size: 0.9rem;
}

.breadcrumb li {
  display: flex;
  align-items: center;
  gap: 12px;
}

.breadcrumb li + li::before {
  content: "/";
  color: var(--c-muted);
}

.breadcrumb a {
  color: var(--c-primary);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color 0.18s ease, color 0.18s ease;
}

.breadcrumb a:hover {
  border-color: var(--c-accent);
  color: var(--c-accent);
}

.breadcrumb [aria-current="page"] {
  color: var(--c-soft);
}

.panel {
  padding: 32px;
  background: #ffffff;
  border: 1px solid #d8e0eb;
  clip-path: polygon(0 0, calc(100% - 20px) 0, 100% 20px, 100% 100%, 20px 100%, 0 calc(100% - 20px));
}

.panel--dark {
  background: var(--c-panel);
  border-color: var(--c-line);
  color: var(--c-muted);
}

.panel--dark .panel__title {
  color: var(--c-light);
}

.panel--accent {
  background: var(--c-accent);
  border-color: var(--c-accent);
  color: var(--c-primary);
}

.panel__title {
  margin-top: 0;
  font-size: 1.4rem;
}

.grid {
  display: grid;
  gap: 24px;
}

.grid--2 {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.grid--3 {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.grid--4 {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.numeric {
  font-family: var(--font-num);
  font-variant-numeric: tabular-nums;
  letter-spacing: -0.02em;
}

.tag-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  background: var(--c-panel);
  border: 1px solid var(--c-line);
  color: var(--c-light);
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  clip-path: polygon(6px 0, 100% 0, calc(100% - 6px) 100%, 0 100%);
}

.tag-chip--accent {
  background: var(--c-accent);
  border-color: var(--c-accent);
  color: var(--c-primary);
}

.path-node {
  position: relative;
  padding: 32px 24px 24px 32px;
  background: #ffffff;
  border: 1px solid #d8e0eb;
  clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 18px, 100% 100%, 18px 100%, 0 calc(100% - 18px));
}

.path-node--dark {
  background: var(--c-panel);
  border-color: var(--c-line);
  color: var(--c-muted);
}

.path-node--dark .path-node__title {
  color: var(--c-light);
}

.path-node__number {
  display: block;
  margin-bottom: 8px;
  font-family: var(--font-num);
  font-size: 3.25rem;
  line-height: 1;
  color: var(--c-accent);
}

.path-node__title {
  margin-bottom: 0.5rem;
  font-size: 1.15rem;
}

.path-node p {
  margin: 0;
  color: var(--c-soft);
}

.media-frame {
  position: relative;
  display: block;
  overflow: hidden;
  min-height: 220px;
  background: var(--c-panel);
  clip-path: polygon(0 0, calc(100% - 18px) 0, 100% 18px, 100% 100%, 18px 100%, 0 calc(100% - 18px));
}

.media-frame::before {
  content: "IMG";
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #132642 0%, var(--c-primary) 100%);
  font-family: var(--font-head);
  font-size: 1.25rem;
  letter-spacing: 0.2em;
  color: var(--c-line);
}

.media-frame--ratio {
  aspect-ratio: 16 / 9;
}

.media-frame img {
  position: relative;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media-frame__caption {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 1;
  padding: 24px 16px 10px;
  font-size: 0.8rem;
  color: var(--c-light);
  background: linear-gradient(transparent, rgba(10, 25, 48, 0.9));
}

.prose {
  max-width: 76ch;
}

.prose p,
.prose ul,
.prose ol {
  margin-bottom: 1.2em;
}

@media (min-width: 768px) and (max-width: 1023px) {
  .grid--3 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .grid--4 {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .footer-brand {
    grid-column: 1 / -1;
  }
}

@media (max-width: 1023px) {
  .section {
    padding: 64px 0;
  }
}

@media (max-width: 860px) {
  .header-nav-bar__inner {
    min-height: 52px;
  }

  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    z-index: 90;
    background: var(--c-primary);
    border-top: 1px solid var(--c-accent);
    box-shadow: 0 24px 40px rgba(4, 10, 22, 0.45);
  }

  .site-nav[data-open] {
    display: block;
  }

  .site-nav__list {
    flex-direction: column;
  }

  .site-nav__link {
    display: block;
    padding: 14px 24px;
    border-bottom: 1px solid var(--c-line);
  }

  .site-nav__link::after {
    display: none;
  }

  .site-nav__link[aria-current="page"] {
    background: rgba(255, 107, 53, 0.08);
    color: var(--c-accent);
  }
}

@media (max-width: 767px) {
  :root {
    --shell-pad: 16px;
  }

  .header-meta__inner {
    flex-wrap: wrap;
    gap: 10px;
    padding-block: 10px;
  }

  .brand__tagline {
    display: none;
  }

  .header-meta__inner::after {
    display: none;
  }

  .header-meta__icp {
    border-left: none;
    padding-left: 0;
    font-size: 11px;
  }

  .grid--2,
  .grid--3,
  .grid--4 {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    gap: 36px;
    padding-bottom: 40px;
  }

  .footer-brand {
    grid-column: auto;
  }

  .footer-bottom {
    padding: 16px 0;
  }

  .section {
    padding: 48px 0;
  }

  .panel,
  .path-node {
    padding: 24px 20px 20px 24px;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  html {
    scroll-behavior: auto;
  }

  .site-progress {
    opacity: 0;
  }
}
