:root {
  --color-bg: #FBF8EE;
  --color-panel: #F1F8F4;
  --color-panel-strong: #DDF1EE;
  --color-border: #3998A6;
  --color-accent: #087F83;
  --color-accent-dark: #07585F;
  --color-text: #17383B;
  --color-muted: #5D7475;
  --color-success: #36875E;
  --color-warn: #EE7623;
  --color-error: #C7473D;
  --color-white: #FFFFFF;
  --color-clear: transparent;
  --color-grid: rgba(57, 152, 166, 0.11);
  --color-grid-strong: rgba(57, 152, 166, 0.22);
  --color-paper: rgba(251, 248, 238, 0.92);
  --color-paper-soft: rgba(251, 248, 238, 0.78);
  --color-panel-soft: rgba(241, 248, 244, 0.88);
  --color-warn-soft: rgba(238, 118, 35, 0.12);
  --color-error-soft: rgba(199, 71, 61, 0.11);
  --color-success-soft: rgba(54, 135, 94, 0.12);
  --color-veil: rgba(7, 88, 95, 0.28);
  --font-display: "Noto Sans SC", "Microsoft YaHei", "PingFang SC", sans-serif;
  --font-body: Inter, "Noto Sans SC", "Microsoft YaHei", "PingFang SC", sans-serif;
  --font-mono: "JetBrains Mono", Consolas, "SFMono-Regular", monospace;
  --radius-xs: 8px;
  --radius-sm: 12px;
  --radius-md: 18px;
  --radius-lg: 28px;
  --radius-xl: 40px;
  --radius-pill: 999px;
  --line-thin: 2px;
  --line-regular: 3px;
  --line-heavy: 6px;
  --page-width: 1440px;
  --content-width: 1180px;
  --reading-width: 820px;
  --gutter: clamp(18px, 4vw, 58px);
  --header-height: 78px;
  --space-1: 8px;
  --space-2: 12px;
  --space-3: 18px;
  --space-4: 26px;
  --space-5: 40px;
  --space-6: 64px;
  --space-7: 96px;
  --motion-fast: 180ms;
  --motion-base: 420ms;
  --motion-vane: 4.8s;
  --motion-water: 6.4s;
}

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

html {
  min-width: 0;
  min-height: 100%;
  scroll-behavior: smooth;
  background: var(--color-bg);
}

html.nav-open {
  overflow: hidden;
}

body {
  min-width: 0;
  min-height: 100vh;
  margin: 0;
  overflow-x: clip;
  color: var(--color-text);
  background-color: var(--color-bg);
  font-family: var(--font-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

main,
section,
article,
aside,
header,
footer,
nav,
div {
  min-width: 0;
}

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

img {
  display: block;
}

a {
  color: var(--color-accent-dark);
  text-decoration-thickness: var(--line-thin);
  text-underline-offset: 0.18em;
}

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

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

button,
a {
  -webkit-tap-highlight-color: var(--color-clear);
}

button {
  cursor: pointer;
}

p,
ul,
ol,
dl,
blockquote,
pre,
table {
  margin-top: 0;
}

p:last-child,
ul:last-child,
ol:last-child,
dl:last-child,
blockquote:last-child,
pre:last-child {
  margin-bottom: 0;
}

code,
kbd,
samp,
pre {
  font-family: var(--font-mono);
}

:not(pre) > code {
  padding: 0.12em 0.38em;
  border-radius: var(--radius-xs);
  color: var(--color-accent-dark);
  background: var(--color-panel-strong);
  overflow-wrap: anywhere;
  word-break: break-word;
}

pre {
  max-width: 100%;
  padding: var(--space-4);
  overflow-x: auto;
  border: var(--line-thin) solid var(--color-border);
  border-radius: var(--radius-md);
  color: var(--color-text);
  background: var(--color-panel);
  white-space: pre;
  -webkit-overflow-scrolling: touch;
}

pre code {
  padding: 0;
  background: var(--color-clear);
  overflow-wrap: normal;
}

::selection {
  color: var(--color-white);
  background: var(--color-accent);
}

:focus-visible {
  outline: var(--line-regular) solid var(--color-warn);
  outline-offset: 3px;
}

h1,
h2,
h3,
h4 {
  margin-top: 0;
  color: var(--color-text);
  font-family: var(--font-display);
  font-weight: 900;
  line-height: 1.16;
  text-wrap: balance;
}

h1 {
  margin-bottom: var(--space-4);
  font-size: clamp(48px, 6vw, 78px);
  letter-spacing: -0.055em;
}

h2 {
  margin-bottom: var(--space-3);
  font-size: clamp(32px, 4vw, 48px);
  letter-spacing: -0.035em;
}

h3 {
  margin-bottom: var(--space-2);
  font-size: clamp(22px, 2.5vw, 29px);
  letter-spacing: -0.02em;
}

h4 {
  margin-bottom: var(--space-2);
  font-size: 18px;
}

.wrap,
.wrap-narrow,
.wrap-reading {
  width: 100%;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.wrap {
  max-width: var(--page-width);
}

.wrap-narrow {
  max-width: var(--content-width);
}

.wrap-reading {
  max-width: calc(var(--reading-width) + var(--gutter) + var(--gutter));
}

.section {
  position: relative;
  overflow-x: clip;
  padding-top: var(--space-7);
  padding-bottom: var(--space-7);
}

.section-compact {
  position: relative;
  overflow-x: clip;
  padding-top: var(--space-6);
  padding-bottom: var(--space-6);
}

.section-heading {
  max-width: 780px;
  margin-bottom: var(--space-5);
}

.section-heading > p:not(.kicker) {
  color: var(--color-muted);
  font-size: 17px;
}

.kicker,
.eyebrow {
  margin-bottom: var(--space-2);
  color: var(--color-accent-dark);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
}

.eyebrow::before {
  width: 32px;
  height: var(--line-heavy);
  flex-shrink: 0;
  border-radius: var(--radius-pill);
  background: var(--color-warn);
  content: "";
}

.muted {
  color: var(--color-muted);
}

.mono {
  font-family: var(--font-mono);
}

.title-brand {
  position: relative;
  z-index: 0;
  display: inline-block;
  color: var(--color-accent);
  white-space: nowrap;
}

.title-brand::after {
  position: absolute;
  z-index: -1;
  right: -5px;
  bottom: 0.11em;
  left: -7px;
  height: 0.23em;
  border-radius: var(--radius-pill);
  background: var(--color-panel-strong);
  content: "";
  transform: rotate(-1deg);
}

.title-action {
  color: var(--color-warn);
}

.panel,
.panel-strong,
.paper-panel,
.card {
  min-width: 0;
  border: var(--line-regular) solid var(--color-border);
  border-radius: var(--radius-lg);
  box-shadow: none;
}

.panel,
.card {
  background: var(--color-panel);
}

.panel-strong {
  background: var(--color-panel-strong);
}

.paper-panel {
  background: var(--color-bg);
}

.panel,
.panel-strong,
.paper-panel,
.card {
  padding: clamp(22px, 3vw, 36px);
}

.card {
  transition:
    border-color var(--motion-fast) ease,
    transform var(--motion-fast) ease;
}

.card:hover {
  border-color: var(--color-accent-dark);
  transform: translateY(-3px);
}

.tilt {
  transform: rotate(-0.45deg);
}

.button-row,
.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2);
}

.button {
  min-height: 54px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  max-width: 100%;
  padding: 0 22px;
  border: var(--line-regular) solid var(--color-accent-dark);
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 850;
  line-height: 1.2;
  text-align: center;
  text-decoration: none;
  transition:
    color var(--motion-fast) ease,
    background-color var(--motion-fast) ease,
    transform var(--motion-fast) ease;
}

.button:hover {
  transform: translateY(-2px);
}

.button-primary {
  color: var(--color-white);
  background: var(--color-accent-dark);
}

.button-primary:hover {
  color: var(--color-white);
  background: var(--color-accent);
}

.button-secondary {
  color: var(--color-accent-dark);
  background: var(--color-panel);
}

.button-secondary:hover {
  color: var(--color-accent-dark);
  background: var(--color-panel-strong);
}

.button-warning {
  color: var(--color-white);
  border-color: var(--color-warn);
  background: var(--color-warn);
}

.button-warning:hover {
  color: var(--color-white);
  border-color: var(--color-accent-dark);
  background: var(--color-accent-dark);
}

.button-small {
  min-height: 44px;
  padding-inline: 17px;
  border-radius: var(--radius-sm);
  font-size: 14px;
}

.button[aria-disabled="true"],
.button:disabled {
  cursor: not-allowed;
  opacity: 0.55;
  transform: none;
}

.button svg,
.inline-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  fill: none;
  stroke: currentColor;
  stroke-width: 2.4;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.badge,
.tag,
.status-badge,
.recommend-badge,
.archived-badge {
  min-height: 30px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  max-width: 100%;
  padding: 3px 11px;
  overflow: hidden;
  border-radius: var(--radius-pill);
  font-size: 12px;
  font-weight: 800;
  line-height: 1.25;
  white-space: nowrap;
}

.badge,
.tag {
  color: var(--color-accent-dark);
  border: var(--line-thin) solid var(--color-border);
  background: var(--color-panel);
}

.status-badge {
  color: var(--color-success);
  border: var(--line-thin) solid var(--color-success);
  background: var(--color-success-soft);
}

.recommend-badge {
  color: var(--color-white);
  border: var(--line-thin) solid var(--color-warn);
  background: var(--color-warn);
}

.archived-badge {
  color: var(--color-error);
  border: var(--line-thin) solid var(--color-error);
  background: var(--color-error-soft);
}

.status-dot,
.chip-dot {
  width: 8px;
  height: 8px;
  flex: 0 0 auto;
  border-radius: var(--radius-pill);
  background: var(--color-warn);
}

.site-header {
  position: relative;
  z-index: 50;
  height: var(--header-height);
  border-bottom: var(--line-thin) solid var(--color-grid-strong);
  background: var(--color-bg);
}

.header-inner {
  position: relative;
  width: min(100%, var(--page-width));
  height: 100%;
  margin-inline: auto;
  padding-inline: var(--gutter);
  display: flex;
  align-items: center;
  gap: clamp(20px, 3vw, 42px);
}

.brand {
  display: inline-flex;
  flex: 0 0 auto;
  align-items: center;
  gap: 11px;
  color: var(--color-accent-dark);
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 900;
  letter-spacing: -0.025em;
  text-decoration: none;
}

.brand img {
  width: 38px;
  height: 43px;
  flex: 0 0 auto;
}

.desktop-nav {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: clamp(17px, 1.75vw, 27px);
  white-space: nowrap;
}

.desktop-nav a {
  position: relative;
  padding: 28px 0 24px;
  color: var(--color-muted);
  font-size: 14px;
  font-weight: 750;
  text-decoration: none;
}

.desktop-nav a::after {
  position: absolute;
  right: 0;
  bottom: 16px;
  left: 0;
  height: var(--line-regular);
  border-radius: var(--radius-pill);
  background: var(--color-warn);
  content: "";
  opacity: 0;
  transform: scaleX(0.35);
  transition:
    opacity var(--motion-fast) ease,
    transform var(--motion-fast) ease;
}

.desktop-nav a:hover,
.desktop-nav a[aria-current="page"] {
  color: var(--color-accent-dark);
}

.desktop-nav a[aria-current="page"]::after {
  opacity: 1;
  transform: scaleX(1);
}

.header-tools {
  position: relative;
  display: flex;
  flex: 0 0 auto;
  align-items: center;
  gap: var(--space-2);
}

.language-picker {
  position: relative;
}

.language-toggle {
  min-height: 40px;
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 0 14px;
  border: var(--line-thin) solid var(--color-border);
  border-radius: var(--radius-pill);
  color: var(--color-accent-dark);
  background: var(--color-panel);
  font-size: 13px;
  font-weight: 750;
  white-space: nowrap;
}

.language-arrow {
  color: var(--color-warn);
  font-size: 11px;
}

.language-menu {
  position: absolute;
  z-index: 70;
  top: calc(100% + 10px);
  right: 0;
  width: 180px;
  padding: 8px;
  border: var(--line-thin) solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-bg);
}

.language-menu[hidden] {
  display: none;
}

.language-menu a {
  min-height: 42px;
  display: flex;
  align-items: center;
  width: 100%;
  padding-inline: 12px;
  border-radius: var(--radius-sm);
  color: var(--color-text);
  font-size: 13px;
  font-weight: 700;
  text-decoration: none;
}

.language-menu a:hover,
.language-menu a[aria-current="true"] {
  color: var(--color-accent-dark);
  background: var(--color-panel-strong);
}

.nav-toggle {
  min-width: 44px;
  min-height: 44px;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: var(--line-thin) solid var(--color-border);
  border-radius: var(--radius-sm);
  color: var(--color-accent-dark);
  background: var(--color-panel);
}

.nav-toggle-lines,
.nav-toggle-lines::before,
.nav-toggle-lines::after {
  width: 20px;
  height: var(--line-thin);
  display: block;
  border-radius: var(--radius-pill);
  background: currentColor;
}

.nav-toggle-lines {
  position: relative;
}

.nav-toggle-lines::before,
.nav-toggle-lines::after {
  position: absolute;
  left: 0;
  content: "";
}

.nav-toggle-lines::before {
  top: -6px;
}

.nav-toggle-lines::after {
  top: 6px;
}

.mobile-nav {
  display: none;
}

.nav-veil {
  display: none;
}

.site-footer {
  position: relative;
  overflow-x: clip;
  border-top: var(--line-heavy) solid var(--color-accent-dark);
  background: var(--color-panel-strong);
}

.footer-main {
  display: grid;
  grid-template-columns: minmax(260px, 1.2fr) repeat(3, minmax(150px, 0.8fr));
  gap: var(--space-5);
  padding-top: var(--space-6);
  padding-bottom: var(--space-5);
}

.footer-brand p {
  max-width: 390px;
  margin-top: var(--space-3);
  color: var(--color-muted);
}

.footer-heading {
  margin-bottom: var(--space-3);
  color: var(--color-accent-dark);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

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

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

.footer-links a {
  color: var(--color-text);
  font-size: 14px;
  font-weight: 700;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--color-warn);
}

.footer-bottom {
  padding-top: var(--space-3);
  padding-bottom: var(--space-4);
  border-top: var(--line-thin) dashed var(--color-border);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  color: var(--color-muted);
  font-size: 13px;
}

.footer-legal {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
}

.footer-legal a {
  color: var(--color-muted);
}

.prose {
  color: var(--color-text);
  font-size: 17px;
  line-height: 1.82;
}

.prose h2 {
  margin-top: var(--space-7);
  scroll-margin-top: calc(var(--header-height) + var(--space-3));
}

.prose h3 {
  margin-top: var(--space-5);
  scroll-margin-top: calc(var(--header-height) + var(--space-3));
}

.prose a {
  font-weight: 750;
}

.prose blockquote {
  margin-inline: 0;
}

.prose img {
  border-radius: var(--radius-md);
}

.table-wrap {
  max-width: 100%;
  overflow-x: auto;
  border: var(--line-thin) solid var(--color-border);
  border-radius: var(--radius-md);
  -webkit-overflow-scrolling: touch;
}

.data-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
  background: var(--color-panel);
}

.data-table th,
.data-table td {
  padding: 15px 17px;
  border-bottom: var(--line-thin) solid var(--color-grid-strong);
  text-align: left;
  vertical-align: top;
}

.data-table th {
  color: var(--color-accent-dark);
  background: var(--color-panel-strong);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.04em;
}

.data-table tr:last-child td {
  border-bottom: 0;
}

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition:
    opacity var(--motion-base) ease,
    transform var(--motion-base) ease;
}

.reveal.shown {
  opacity: 1;
  transform: none;
}

@media (max-width: 1120px) {
  .desktop-nav {
    display: none;
  }

  .header-tools {
    margin-left: auto;
  }

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

  .mobile-nav {
    position: fixed;
    z-index: 65;
    top: var(--header-height);
    right: 0;
    left: 0;
    max-height: calc(100dvh - var(--header-height));
    padding: 12px var(--gutter) 24px;
    overflow-y: auto;
    overscroll-behavior: contain;
    border-bottom: var(--line-heavy) solid var(--color-accent-dark);
    background: var(--color-bg);
  }

  .mobile-nav.open {
    display: block;
  }

  .mobile-nav a {
    min-height: 48px;
    display: flex;
    align-items: center;
    width: 100%;
    padding: 10px 13px;
    border-bottom: var(--line-thin) solid var(--color-grid-strong);
    color: var(--color-text);
    font-weight: 800;
    text-decoration: none;
  }

  .mobile-nav a[aria-current="page"],
  .mobile-nav a:hover {
    color: var(--color-accent-dark);
    background: var(--color-panel);
  }

  .mobile-language-title {
    margin: 18px 13px 5px;
    color: var(--color-muted);
    font-family: var(--font-mono);
    font-size: 11px;
    font-weight: 800;
    letter-spacing: 0.08em;
    text-transform: uppercase;
  }

  .nav-veil.open {
    position: fixed;
    z-index: 40;
    inset: var(--header-height) 0 0;
    display: block;
    border: 0;
    background: var(--color-veil);
  }

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

@media (max-width: 640px) {
  :root {
    --gutter: 18px;
    --header-height: 68px;
    --space-6: 48px;
    --space-7: 68px;
  }

  h1 {
    font-size: clamp(42px, 13vw, 58px);
  }

  h2 {
    font-size: clamp(29px, 9vw, 38px);
  }

  .site-header {
    height: var(--header-height);
  }

  .brand {
    gap: 8px;
    font-size: 16px;
  }

  .brand img {
    width: 32px;
    height: 37px;
  }

  .language-picker {
    display: none;
  }

  .header-tools {
    margin-left: auto;
  }

  .panel,
  .panel-strong,
  .paper-panel,
  .card {
    padding: 21px;
    border-radius: var(--radius-md);
  }

  .button-row,
  .hero-actions {
    align-items: stretch;
  }

  .button-row .button,
  .hero-actions .button {
    flex: 1 1 100%;
  }

  .tilt,
  [class*="tilt"] {
    transform: none;
  }

  .footer-main {
    grid-template-columns: minmax(0, 1fr);
    gap: var(--space-5);
  }

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

  .prose {
    font-size: 16px;
  }

  .prose h2 {
    margin-top: var(--space-6);
  }
}

@media (max-width: 360px) {
  :root {
    --gutter: 16px;
  }

  .brand span {
    max-width: 120px;
    overflow: hidden;
    white-space: nowrap;
  }
}

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

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

  .reveal {
    opacity: 1;
    transform: none;
  }
}