:root {
  --ink-900: #081713;
  --ink-800: #0B1F1A;
  --moss-700: #14332B;
  --moss-600: #1D4438;
  --fog-400: #7E948B;
  --fog-200: #C3D2CA;
  --paper-050: #F1F5F1;
  --cyan-400: #35F0C8;
  --cyan-600: #12A98C;
  --amber-500: #E9A73B;
  --clay-500: #A85B3E;
  --stone-300: #8C9490;
  --font-display: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-body: "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-mono: "Roboto Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  --max: 1240px;
  --header-h: 60px;
  --gutter: clamp(16px, 4vw, 32px);
  --ease-out: cubic-bezier(0.2, 0.7, 0.3, 1);
}

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

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

body {
  margin: 0;
  color: var(--fog-200);
  background-color: var(--ink-800);
  background-image:
    repeating-linear-gradient(0deg, rgba(195, 210, 202, 0.045) 0, rgba(195, 210, 202, 0.045) 1px, transparent 1px, transparent 64px),
    repeating-linear-gradient(90deg, rgba(195, 210, 202, 0.045) 0, rgba(195, 210, 202, 0.045) 1px, transparent 1px, transparent 64px);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.75;
  font-weight: 400;
}

body.nav-open {
  overflow: hidden;
}

body,
button,
input,
textarea,
select {
  font-family: var(--font-body);
}

button {
  border-radius: 0;
}

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

button,
input,
textarea,
select {
  font: inherit;
}

button {
  cursor: pointer;
}

a {
  color: var(--cyan-400);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.2em;
}

a:hover {
  color: var(--paper-050);
}

::selection {
  background: var(--cyan-400);
  color: var(--ink-900);
}

:where(a, button, summary, [tabindex]):focus-visible {
  outline: 2px solid var(--cyan-400);
  outline-offset: 3px;
}

h1,
h2,
h3,
h4,
p,
figure,
blockquote,
dl,
dd {
  margin: 0;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-display);
  color: var(--paper-050);
  line-height: 1.15;
  letter-spacing: -0.01em;
  font-weight: 800;
}

h1 {
  font-size: clamp(28px, 5vw, 72px);
}

h2 {
  font-size: clamp(24px, 3vw, 40px);
}

h3 {
  font-size: clamp(20px, 2vw, 28px);
}

h4 {
  font-size: 20px;
}

p + p {
  margin-top: 1.25em;
}

.mono,
.score {
  font-family: var(--font-mono);
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.01em;
}

.eyebrow,
.section-kicker,
.label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0;
  color: var(--cyan-400);
  font-size: 12px;
  line-height: 1.5;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.label {
  color: var(--fog-400);
}

.lead {
  max-width: 36em;
  color: var(--fog-200);
  font-size: clamp(17px, 2vw, 20px);
  line-height: 1.72;
}

.prose {
  max-width: 34em;
  color: var(--fog-200);
  font-size: 16px;
  line-height: 1.75;
}

.prose p + p {
  margin-top: 1.5em;
}

.prose h2,
.prose h3 {
  margin-top: 1.5em;
  margin-bottom: 0.5em;
}

.prose a {
  font-weight: 700;
}

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

.section {
  padding-block: clamp(48px, 7vw, 88px);
}

.section--tight {
  padding-block: clamp(28px, 4vw, 48px);
}

.section--paper {
  background: var(--paper-050);
  color: var(--ink-800);
  background-image:
    repeating-linear-gradient(0deg, rgba(8, 23, 19, 0.035) 0, rgba(8, 23, 19, 0.035) 1px, transparent 1px, transparent 64px),
    repeating-linear-gradient(90deg, rgba(8, 23, 19, 0.035) 0, rgba(8, 23, 19, 0.035) 1px, transparent 1px, transparent 64px);
}

.section--paper h1,
.section--paper h2,
.section--paper h3,
.section--paper h4 {
  color: var(--ink-900);
}

.section--paper .lead,
.section--paper .prose {
  color: var(--ink-800);
}

.section--paper .section-kicker,
.section--paper .eyebrow {
  color: var(--cyan-600);
}

.section--paper a {
  color: var(--cyan-600);
}

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

.section-title {
  display: flex;
  align-items: center;
  gap: 14px;
  font-family: var(--font-display);
  font-size: clamp(28px, 3vw, 40px);
  font-weight: 800;
  line-height: 1.15;
}

.section-title::before {
  content: "";
  flex: 0 0 2px;
  width: 2px;
  height: 1em;
  background: var(--cyan-400);
  transform: scaleY(1);
  transform-origin: top center;
}

.section--paper .section-title::before {
  background: var(--cyan-600);
}

.editorial-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 32px;
}

.index-rail {
  min-width: 0;
}

.content-main {
  min-width: 0;
}

.grid-12 {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
}

.card-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

.page-header {
  display: grid;
  gap: 16px;
  padding-block: clamp(36px, 6vw, 64px) 20px;
}

.page-title {
  max-width: 14em;
  font-size: clamp(28px, 5vw, 56px);
}

.page-deck {
  max-width: 46em;
  color: var(--fog-200);
  font-size: clamp(16px, 1.8vw, 19px);
  line-height: 1.7;
}

.breadcrumb {
  margin-bottom: 24px;
  color: var(--fog-400);
  font-size: 13px;
}

.breadcrumb ol {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

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

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

.breadcrumb a {
  color: var(--fog-200);
  text-decoration: none;
}

.breadcrumb a:hover {
  color: var(--cyan-400);
}

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

.btn,
.header-cta,
.nav-toggle,
.chip {
  border-radius: 0;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0 18px;
  border: 1px solid var(--moss-600);
  background: transparent;
  color: var(--fog-200);
  font-size: 14px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: background-color 0.18s var(--ease-out), border-color 0.18s var(--ease-out), color 0.18s var(--ease-out);
}

.btn:hover {
  border-color: var(--cyan-400);
  color: var(--cyan-400);
}

.btn:active {
  background: var(--moss-600);
}

.btn-primary {
  border-color: var(--cyan-400);
  background: var(--cyan-400);
  color: var(--ink-900);
}

.btn-primary:hover {
  border-color: var(--cyan-600);
  background: var(--cyan-600);
  color: var(--ink-900);
}

.btn-ghost {
  border-color: var(--moss-600);
  color: var(--fog-200);
}

.btn-ghost:hover {
  border-color: var(--cyan-400);
  color: var(--cyan-400);
}

.text-link {
  color: var(--cyan-400);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  border-bottom: 1px solid currentColor;
}

.text-link:hover {
  color: var(--paper-050);
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  min-height: 32px;
  padding: 0 12px;
  border: 1px solid var(--moss-600);
  background: transparent;
  color: var(--fog-200);
  font-size: 12px;
  line-height: 1;
  letter-spacing: 0.04em;
  text-decoration: none;
  transition: border-color 0.18s var(--ease-out), color 0.18s var(--ease-out), background-color 0.18s var(--ease-out);
}

.chip:hover {
  border-color: var(--cyan-400);
  color: var(--cyan-400);
}

.chip[aria-pressed="true"],
.chip.is-active {
  border-color: var(--cyan-400);
  color: var(--cyan-400);
  background: var(--moss-700);
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-left: 2px solid var(--amber-500);
  background: var(--moss-700);
  color: var(--fog-200);
  font-size: 11px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.score {
  color: var(--amber-500);
  font-size: clamp(28px, 4vw, 56px);
  font-weight: 700;
  line-height: 1;
}

.status-dot {
  display: inline-block;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--amber-500);
  vertical-align: middle;
}

.panel {
  border: 1px solid var(--moss-600);
  background: var(--moss-700);
  padding: clamp(20px, 3vw, 32px);
}

.card {
  border: 1px solid var(--moss-600);
  background: var(--moss-700);
  padding: 20px;
}

.card--quiet {
  background: transparent;
  border-color: var(--moss-700);
}

.divider {
  height: 1px;
  margin-block: 24px;
  border: 0;
  background: var(--moss-600);
}

.media {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--moss-600);
  background: var(--moss-700);
  aspect-ratio: 16 / 10;
}

.media--portrait {
  aspect-ratio: 3 / 4;
}

.media--square {
  aspect-ratio: 1 / 1;
}

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

.media img,
.media picture,
.media picture img {
  width: 100%;
  height: 100%;
}

.media img {
  object-fit: cover;
  filter: saturate(0.82) contrast(1.05);
}

.media__overlay {
  position: absolute;
  inset: auto 0 0 0;
  padding: 16px;
  background: linear-gradient(to top, rgba(8, 23, 19, 0.86), rgba(8, 23, 19, 0));
  color: var(--paper-050);
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.5;
}

.figure {
  margin: 0;
}

.figure__caption {
  margin-top: 8px;
  color: var(--fog-400);
  font-size: 12px;
  line-height: 1.6;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 16px;
  z-index: 1000;
  padding: 10px 14px;
  border: 1px solid var(--cyan-400);
  background: var(--cyan-400);
  color: var(--ink-900);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
  transform: translateY(-180%);
  transition: transform 0.18s var(--ease-out);
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  color: var(--paper-050);
  background: rgba(8, 23, 19, 0.97);
  border-bottom: 1px solid var(--moss-600);
}

.header-shell {
  display: flex;
  align-items: center;
  gap: clamp(12px, 2vw, 24px);
  min-height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  color: var(--paper-050);
  text-decoration: none;
  white-space: nowrap;
}

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

.brand-name {
  font-family: var(--font-display);
  font-size: 20px;
  line-height: 1;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.brand:hover .brand-name {
  color: var(--cyan-400);
}

.brand-tag {
  color: var(--cyan-400);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0.08em;
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 8px;
  min-height: 40px;
  padding: 0 10px;
  border: 1px solid var(--moss-600);
  background: transparent;
  color: var(--fog-200);
  font-size: 12px;
  line-height: 1;
  letter-spacing: 0.08em;
}

.nav-toggle:hover {
  border-color: var(--cyan-400);
  color: var(--cyan-400);
}

.nav-toggle-label {
  white-space: nowrap;
}

.nav-toggle-bars {
  display: grid;
  gap: 4px;
  width: 16px;
}

.nav-toggle-bars span {
  display: block;
  width: 16px;
  height: 1px;
  background: currentColor;
  transition: transform 0.18s var(--ease-out), opacity 0.18s var(--ease-out);
}

.nav-toggle[aria-expanded="true"] {
  border-color: var(--cyan-400);
  color: var(--cyan-400);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:first-child {
  transform: translateY(2.5px) rotate(45deg);
}

.nav-toggle[aria-expanded="true"] .nav-toggle-bars span:last-child {
  transform: translateY(-2.5px) rotate(-45deg);
}

.site-nav {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: clamp(12px, 2vw, 24px);
  min-width: 0;
}

.nav-list {
  display: flex;
  align-items: stretch;
  gap: 2px;
  margin: 0;
  padding: 0;
  min-width: 0;
  list-style: none;
}

.nav-list a {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 42px;
  padding: 0 10px;
  color: var(--fog-200);
  font-size: 14px;
  line-height: 1;
  font-weight: 600;
  white-space: nowrap;
  text-decoration: none;
  transition: background-color 0.18s var(--ease-out), color 0.18s var(--ease-out);
}

.nav-list a:hover {
  background: var(--moss-600);
  color: var(--paper-050);
}

.nav-list a[aria-current="page"] {
  color: var(--cyan-400);
  box-shadow: inset 2px 0 0 var(--cyan-400);
}

.nav-meta {
  display: flex;
  align-items: center;
  gap: 12px;
  min-width: 0;
}

.status-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid var(--moss-600);
  color: var(--fog-200);
  font-size: 12px;
  line-height: 1;
  letter-spacing: 0.08em;
  white-space: nowrap;
}

.header-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 34px;
  padding: 0 14px;
  border: 1px solid var(--cyan-400);
  background: transparent;
  color: var(--cyan-400);
  font-size: 13px;
  line-height: 1;
  font-weight: 700;
  letter-spacing: 0.04em;
  white-space: nowrap;
  text-decoration: none;
  transition: background-color 0.18s var(--ease-out), border-color 0.18s var(--ease-out), color 0.18s var(--ease-out);
}

.header-cta:hover {
  background: var(--cyan-400);
  color: var(--ink-900);
}

.header-cta:active {
  border-color: var(--cyan-600);
  background: var(--cyan-600);
  color: var(--ink-900);
}

.reading-progress {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  background: var(--cyan-400);
  transform: scaleX(0);
  transform-origin: left center;
  pointer-events: none;
}

.site-footer {
  padding-block: 48px 24px;
  background: var(--ink-900);
  border-top: 1px solid var(--moss-600);
  color: var(--fog-400);
}

.footer-brand {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 10px 14px;
}

.footer-brand-link {
  color: var(--paper-050);
  font-family: var(--font-display);
  font-size: 22px;
  line-height: 1.1;
  font-weight: 800;
  letter-spacing: -0.01em;
  text-decoration: none;
}

.footer-brand-link:hover {
  color: var(--cyan-400);
}

.footer-version {
  color: var(--cyan-400);
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1;
  letter-spacing: 0.08em;
}

.footer-note {
  flex-basis: 100%;
  max-width: 34em;
  margin-top: 2px;
  color: var(--fog-400);
  font-size: 13px;
  line-height: 1.7;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  margin-top: 32px;
  padding-top: 28px;
  border-top: 1px solid var(--moss-700);
}

.footer-col {
  min-width: 0;
}

.footer-heading {
  margin: 0 0 12px;
  color: var(--fog-400);
  font-family: var(--font-body);
  font-size: 12px;
  line-height: 1.5;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.footer-list {
  display: grid;
  gap: 8px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-list a {
  color: var(--fog-200);
  font-size: 14px;
  text-decoration: none;
}

.footer-list a:hover {
  color: var(--cyan-400);
}

.footer-meta {
  color: var(--fog-400);
  font-size: 13px;
  line-height: 1.8;
  overflow-wrap: anywhere;
}

.footer-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 12px 24px;
  margin-top: 32px;
  padding-top: 16px;
  border-top: 1px solid var(--moss-700);
}

.footer-legal,
.footer-copy {
  margin: 0;
  color: var(--fog-400);
  font-size: 12px;
  line-height: 1.7;
}

html.js [data-reveal] {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.28s var(--ease-out), transform 0.28s var(--ease-out);
}

html.js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

html.js .section-title::before {
  transform: scaleY(0);
  transition: transform 0.32s var(--ease-out);
}

html.js .section-title.is-visible::before {
  transform: scaleY(1);
}

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

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

@media (min-width: 900px) {
  .editorial-grid {
    grid-template-columns: 240px minmax(0, 1fr);
    gap: clamp(32px, 5vw, 64px);
  }

  .index-rail {
    position: sticky;
    top: calc(var(--header-h) + 24px);
    align-self: start;
  }
}

@media (min-width: 1000px) {
  .grid-12 {
    grid-template-columns: repeat(12, minmax(0, 1fr));
  }
}

@media (min-width: 900px) and (max-width: 1100px) {
  .status-chip {
    display: none;
  }

  .nav-list a {
    padding-inline: 8px;
    font-size: 13px;
  }

  .header-cta {
    min-height: 32px;
    padding-inline: 10px;
  }
}

@media (max-width: 899.98px) {
  :root {
    --header-h: 58px;
  }

  .header-shell {
    justify-content: space-between;
    gap: 12px;
  }

  .brand-name {
    font-size: 18px;
  }

  .brand-tag {
    font-size: 10px;
  }

  .nav-toggle {
    display: inline-flex;
    order: 2;
    margin-left: auto;
  }

  .site-nav {
    position: fixed;
    top: var(--header-h);
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 95;
    display: flex;
    flex-direction: column;
    align-items: stretch;
    justify-content: flex-start;
    gap: 0;
    padding: 20px clamp(16px, 5vw, 28px) 32px;
    overflow-y: auto;
    background: var(--ink-900);
    border-top: 1px solid var(--moss-600);
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transform: translateY(-8px);
    transition: opacity 0.18s var(--ease-out), transform 0.18s var(--ease-out), visibility 0.18s;
  }

  .site-nav[data-open] {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: none;
  }

  .nav-list {
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    width: 100%;
  }

  .nav-list a {
    min-height: 54px;
    padding: 0 14px;
    border-bottom: 1px solid var(--moss-700);
    font-size: clamp(18px, 5vw, 22px);
  }

  .nav-list a[aria-current="page"] {
    box-shadow: inset 2px 0 0 var(--cyan-400);
  }

  .nav-meta {
    align-items: center;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: auto;
    padding-top: 28px;
  }

  .status-chip {
    display: inline-flex;
  }

  .header-cta {
    min-height: 44px;
    padding-inline: 18px;
    font-size: 14px;
  }

  .section-head {
    display: grid;
    align-items: start;
    gap: 8px;
  }

  .site-footer {
    padding-top: 36px;
  }

  .footer-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 28px 20px;
  }
}

@media (max-width: 520px) {
  .footer-base {
    flex-direction: column;
  }

  .footer-brand-link {
    font-size: 20px;
  }
}

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

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

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

  html.js .section-title::before {
    transform: scaleY(1);
    transition: none;
  }

  .site-nav {
    transition: none;
  }
}
