:root {
  --bg-primary: #0B1B3D;
  --bg-secondary: #11264F;
  --bg-light: #F5F7FA;
  --accent-orange: #FF6B00;
  --accent-orange-light: #FF9A4D;
  --accent-cyan: #00C2D1;
  --text-light: #F5F7FA;
  --text-dark: #10182B;
  --text-gray: #6B7280;
  --border-light: rgba(141, 155, 181, 0.35);
  --border-blue: #8D9BB5;
  --warning: #F8C150;
  --font-display: 'Bebas Neue', 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-body: 'Noto Sans SC', 'PingFang SC', 'Microsoft YaHei', sans-serif;
  --font-mono: 'JetBrains Mono', 'Roboto Mono', 'SF Mono', Consolas, monospace;
  --container-width: 1240px;
  --header-height: 72px;
  --size-display-xl: clamp(48px, 6vw, 72px);
  --size-section-title: clamp(30px, 4vw, 44px);
  --size-subheading: clamp(20px, 2.4vw, 28px);
  --size-body: 16px;
  --size-footnote: 13px;
  --size-data: 20px;
  --radius-card: 12px;
  --radius-pill: 999px;
  --transition-base: 0.2s ease;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-body);
  font-size: var(--size-body);
  line-height: 1.75;
  color: var(--text-dark);
  background: var(--text-light);
  -webkit-font-smoothing: antialiased;
}

a {
  color: inherit;
  text-decoration: none;
  transition: color 0.2s ease;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

ul {
  list-style: none;
}

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

:focus-visible {
  outline: 3px solid var(--accent-orange);
  outline-offset: 3px;
  border-radius: 4px;
}

.container {
  width: 100%;
  max-width: var(--container-width);
  margin: 0 auto;
  padding: 0 24px;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 9999;
  padding: 10px 18px;
  background: var(--accent-orange);
  color: #fff;
  font-weight: 600;
  border-radius: 6px;
  transform: translateY(-200%);
  transition: transform 0.2s ease;
}

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

.site-header {
  position: fixed;
  top: 14px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 1000;
  width: min(calc(100% - 32px), 1240px);
  background: rgba(11, 27, 61, 0.88);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid var(--border-light);
  border-radius: var(--radius-pill);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.35);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 12px 20px 12px 28px;
  border-radius: var(--radius-pill);
  position: relative;
}

.brand {
  display: inline-flex;
  flex-direction: column;
  line-height: 1.25;
  white-space: nowrap;
  flex-shrink: 0;
}

.brand__main {
  font-family: var(--font-display);
  font-size: 24px;
  letter-spacing: 0.04em;
  color: var(--text-light);
  text-transform: uppercase;
}

.brand__sub {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.12em;
  color: var(--accent-cyan);
  text-transform: uppercase;
}

.site-nav {
  display: flex;
  align-items: center;
  flex: 1;
  justify-content: center;
}

.site-nav__list {
  display: flex;
  align-items: center;
  gap: 4px;
}

.site-nav__link {
  display: block;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  color: rgba(245, 247, 250, 0.75);
  font-size: 14px;
  font-weight: 500;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, background-color 0.2s ease, border-color 0.2s ease;
}

.site-nav__link:hover,
.site-nav__link:focus {
  color: var(--text-light);
  background: rgba(255, 107, 0, 0.14);
}

.site-nav__link[aria-current="page"] {
  color: var(--accent-orange-light);
  border-bottom-color: var(--accent-orange);
}

.site-header__meta {
  display: flex;
  align-items: center;
  gap: 14px;
  flex-shrink: 0;
}

.site-header__fav {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.08);
  color: rgba(245, 247, 250, 0.85);
  font-family: var(--font-mono);
  font-size: 13px;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.site-header__fav:hover {
  background: rgba(255, 107, 0, 0.22);
  color: #fff;
  transform: translateY(-2px);
}

.site-header__badge {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  background: var(--accent-orange);
  color: #fff;
  font-family: var(--font-mono);
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.08em;
  border-radius: 6px;
  clip-path: polygon(8px 0, 100% 0, calc(100% - 8px) 100%, 0 100%);
}

.site-nav__toggle {
  display: none;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  color: var(--text-light);
  border-radius: var(--radius-pill);
  background: rgba(255, 255, 255, 0.08);
  font-family: var(--font-mono);
  font-size: 14px;
}

.site-nav__toggle-icon {
  position: relative;
  width: 16px;
  height: 14px;
}

.site-nav__toggle-icon::before,
.site-nav__toggle-icon::after {
  content: '';
  position: absolute;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--text-light);
  transition: transform 0.2s ease, top 0.2s ease;
}

.site-nav__toggle-icon::before {
  top: 0;
}

.site-nav__toggle-icon::after {
  top: 12px;
}

.progress-bar {
  position: absolute;
  top: auto;
  bottom: 0;
  left: 0;
  height: 3px;
  width: 0%;
  background: linear-gradient(90deg, var(--accent-orange), var(--accent-orange-light));
  border-radius: 0 0 var(--radius-pill) var(--radius-pill);
  transition: width 0.1s linear;
}

.site-footer {
  background: var(--bg-primary);
  color: rgba(245, 247, 250, 0.8);
  padding: 72px 0 28px;
  margin-top: 80px;
  clip-path: polygon(0 0, 100% 0, 100% calc(100% - 24px), 0 100%);
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1.2fr;
  gap: 48px;
  padding-bottom: 48px;
  border-bottom: 1px solid rgba(141, 155, 181, 0.2);
}

.site-footer .brand__main {
  font-size: 22px;
}

.site-footer__desc {
  margin-top: 12px;
  font-size: var(--size-footnote);
  line-height: 1.7;
  color: rgba(245, 247, 250, 0.6);
}

.site-footer__nav h4,
.site-footer__service h4,
.site-footer__contact h4 {
  font-family: var(--font-mono);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-light);
  margin-bottom: 20px;
  position: relative;
  padding-bottom: 8px;
}

.site-footer__nav h4::after,
.site-footer__service h4::after,
.site-footer__contact h4::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: 0;
  width: 32px;
  height: 2px;
  background: var(--accent-orange);
}

.site-footer__nav ul {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.site-footer__nav a,
.site-footer__service a {
  color: rgba(245, 247, 250, 0.65);
  font-size: 14px;
  display: inline-block;
  margin-bottom: 8px;
}

.site-footer__nav a:hover,
.site-footer__service a:hover {
  color: var(--accent-orange-light);
}

.site-footer__service p,
.site-footer__contact ul,
.site-footer__contact li {
  font-size: 14px;
  line-height: 1.7;
  margin-bottom: 6px;
}

.site-footer__contact ul li::before {
  content: '→ ';
  color: var(--accent-cyan);
  font-family: var(--font-mono);
}

.site-footer__icp {
  display: inline-block;
  margin-top: 12px;
  padding: 4px 10px;
  border: 1px solid var(--border-light);
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: rgba(245, 247, 250, 0.7);
}

.site-footer__bottom {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: 24px;
  padding-bottom: 16px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: rgba(245, 247, 250, 0.5);
}

.page-shell {
  padding-top: 120px;
}

.section-title {
  font-family: var(--font-display);
  font-size: var(--size-section-title);
  line-height: 1.15;
  color: var(--bg-primary);
  margin-bottom: 12px;
}

.chapter-index {
  font-family: var(--font-display);
  font-size: var(--size-display-xl);
  line-height: 1;
  color: var(--accent-cyan);
  display: block;
  margin-right: 18px;
  opacity: 0.9;
}

.data-card {
  background: var(--bg-secondary);
  border-radius: var(--radius-card);
  padding: 28px;
  clip-path: polygon(0 0, calc(100% - 16px) 0, 100% 16px, 100% 100%, 0 100%);
  color: var(--text-light);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  border: 1px solid rgba(141, 155, 181, 0.2);
}

.data-card:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.2);
}

.data-card__label {
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.06em;
  color: rgba(245, 247, 250, 0.6);
  text-transform: uppercase;
}

.data-card__value {
  font-family: var(--font-display);
  font-size: 52px;
  line-height: 1;
  color: var(--accent-cyan);
  margin-top: 8px;
}

.data-card__unit {
  font-family: var(--font-mono);
  font-size: 14px;
  color: rgba(245, 247, 250, 0.5);
  margin-left: 6px;
}

.tag {
  display: inline-flex;
  align-items: center;
  padding: 4px 12px;
  background: rgba(255, 107, 0, 0.12);
  border: 1px solid rgba(255, 107, 0, 0.3);
  color: var(--accent-orange);
  border-radius: var(--radius-pill);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.08em;
  margin-right: 10px;
  font-weight: 500;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 12px 28px;
  border-radius: var(--radius-pill);
  font-weight: 600;
  font-size: 15px;
  background: var(--bg-primary);
  color: var(--text-light);
  transition: transform 0.2s ease, background 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 6px 18px rgba(11, 27, 61, 0.2);
}

.btn:hover {
  transform: translateY(-2px);
  background: var(--bg-secondary);
  box-shadow: 0 10px 28px rgba(11, 27, 61, 0.3);
}

.btn--primary {
  background: var(--accent-orange);
  color: #fff;
}

.btn--primary:hover {
  background: var(--accent-orange-light);
}

.image-placeholder {
  background: linear-gradient(135deg, var(--bg-primary) 0%, var(--bg-secondary) 100%);
  min-height: 220px;
  border-radius: var(--radius-card);
  clip-path: polygon(0 0, calc(100% - 24px) 0, 100% 24px, 100% 100%, 0 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(245, 247, 250, 0.5);
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(141, 155, 181, 0.2);
}

.image-placeholder::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    linear-gradient(115deg, transparent 30%, rgba(0, 194, 209, 0.2) 40%, transparent 55%);
  background-size: 200% 100%;
  animation: sheen 4s linear infinite;
}

@keyframes sheen {
  0% { background-position: 130% 0; }
  100% { background-position: -30% 0; }
}

.breadcrumb {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(11, 27, 61, 0.06);
  border-radius: var(--radius-pill);
  padding: 8px 18px;
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--text-gray);
}

.breadcrumb__item:not(:last-child)::after {
  content: '/';
  margin-left: 8px;
  color: var(--border-blue);
}

.breadcrumb a {
  color: var(--bg-primary);
  font-weight: 500;
}

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

[data-reveal] {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}

[data-reveal].is-revealed {
  opacity: 1;
  transform: translateY(0);
}

[data-scroll-spy] [data-spy-item] {
  opacity: 0.5;
  transition: opacity 0.3s ease, transform 0.3s ease;
}

[data-scroll-spy] [data-spy-item].is-active {
  opacity: 1;
  transform: translateX(4px);
  color: var(--accent-orange);
}

@media (max-width: 1024px) {
  .site-header__inner {
    padding: 12px 16px 12px 20px;
    gap: 12px;
  }

  .brand__sub {
    display: none;
  }

  .site-footer__grid {
    grid-template-columns: 1fr 1fr;
    gap: 36px;
  }
}

@media (max-width: 768px) {
  .site-header {
    top: 8px;
    width: calc(100% - 16px);
    border-radius: 20px;
  }

  .site-header__inner {
    flex-wrap: wrap;
    padding: 10px 14px;
  }

  .site-header__meta {
    margin-left: auto;
  }

  .site-header__fav span {
    display: none;
  }

  .site-header__fav {
    padding: 8px 12px;
  }

  .site-header__badge {
    font-size: 12px;
    padding: 3px 10px;
  }

  .site-nav {
    order: 3;
    width: 100%;
    position: relative;
  }

  .site-nav__toggle {
    display: inline-flex;
    width: 100%;
    justify-content: center;
    background: rgba(255, 255, 255, 0.06);
  }

  .site-nav__list {
    display: none;
    flex-direction: column;
    align-items: stretch;
    width: 100%;
    gap: 4px;
    margin-top: 8px;
    padding: 12px;
    background: rgba(11, 27, 61, 0.98);
    border: 1px solid var(--border-light);
    border-radius: 16px;
    clip-path: polygon(0 0, calc(100% - 14px) 0, 100% 14px, 100% 100%, 0 100%);
  }

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

  .site-nav[data-open] .site-nav__toggle-icon::before {
    top: 6px;
    transform: rotate(45deg);
  }

  .site-nav[data-open] .site-nav__toggle-icon::after {
    top: 6px;
    transform: rotate(-45deg);
  }

  .site-nav__link {
    padding: 12px 16px;
    border-bottom: 1px solid rgba(141, 155, 181, 0.12);
    border-radius: 8px;
  }

  .site-nav__link[aria-current="page"] {
    background: rgba(255, 107, 0, 0.15);
    border-bottom-color: var(--accent-orange);
  }

  .site-footer {
    clip-path: none;
    padding-top: 48px;
  }

  .site-footer__grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .site-footer__bottom {
    flex-direction: column;
    gap: 8px;
    text-align: center;
  }

  .page-shell {
    padding-top: 100px;
  }

  .data-card__value {
    font-size: 40px;
  }
}

@media (max-width: 420px) {
  .brand__main {
    font-size: 20px;
  }

  .site-header__meta {
    gap: 8px;
  }

  .site-nav__toggle-label {
    display: none;
  }

  .site-nav__toggle {
    padding: 10px;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

  [data-reveal] {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .image-placeholder::after {
    animation: none;
  }

  .site-header__fav:hover {
    transform: none;
  }

  .data-card:hover {
    transform: none;
  }
}
