:root {
  --color-bg: #E7EDF6;
  --color-panel: #F6F9FD;
  --color-panel-alt: #DCE5F1;
  --color-border: #C5D1E2;
  --color-accent: #D9EE3E;
  --color-accent-dark: #6C7C10;
  --color-text: #121A26;
  --color-muted: #4E5D72;
  --color-success: #1E9E63;
  --color-warning: #C9880F;
  --color-error: #C93B3B;
  --color-white: #FFFFFF;
  --color-overlay: rgba(18, 26, 38, .42);
  --color-header: rgba(246, 249, 253, .88);
  --color-glass: rgba(246, 249, 253, .94);
  --color-glass-soft: rgba(231, 237, 246, .86);
  --color-success-soft: rgba(30, 158, 99, .1);
  --color-success-border: rgba(30, 158, 99, .3);
  --color-accent-border: rgba(108, 124, 16, .35);
  --color-dot: rgba(18, 26, 38, .055);
  --color-shadow-soft: rgba(18, 26, 38, .05);
  --color-shadow: rgba(18, 26, 38, .14);
  --color-shadow-deep: rgba(30, 46, 72, .22);
  --flag-red: #D22F3C;
  --flag-red-alt: #C7373F;
  --flag-blue: #2B3F77;
  --font-display: 'Inter', 'Noto Sans SC', -apple-system, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --font-body: 'Inter', 'Noto Sans SC', -apple-system, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --font-mono: 'JetBrains Mono', 'SFMono-Regular', 'Menlo', 'Consolas', monospace;
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-pill: 999px;
  --shadow-1: 0 1px 2px rgba(18, 26, 38, .06);
  --shadow-2: 0 1px 2px var(--color-shadow-soft), 0 14px 34px -10px var(--color-shadow);
  --shadow-3: 0 2px 4px var(--color-shadow-soft), 0 18px 44px -14px rgba(18, 26, 38, .16), 0 40px 90px -40px var(--color-shadow-deep);
  --header-height: 64px;
  --content-width: 1360px;
  --reading-width: 820px;
  --gutter: clamp(16px, 3vw, 32px);
  --section-space: clamp(64px, 9vw, 120px);
  --focus-ring: 2px solid var(--color-accent-dark);
  --transition-fast: 150ms ease;
  --transition-base: 280ms ease;
}

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

html {
  min-width: 320px;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 16px);
}

html.nav-open {
  overflow: hidden;
}

body {
  min-width: 320px;
  margin: 0;
  color: var(--color-text);
  background-color: var(--color-bg);
  background-image: radial-gradient(circle, var(--color-dot) 1px, transparent 1.2px);
  background-size: 22px 22px;
  font-family: var(--font-body);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}

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

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

img {
  height: auto;
}

svg {
  flex-shrink: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

button {
  color: inherit;
}

button,
summary,
[role="tab"],
.site-nav a,
.lang-button,
.mobile-menu-button {
  min-height: 24px;
}

a:focus-visible,
button:focus-visible,
summary:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
[role="tab"]:focus-visible {
  outline: var(--focus-ring);
  outline-offset: 3px;
}

ul,
ol {
  margin-top: 0;
}

h1,
h2,
h3,
h4,
p,
figure,
blockquote {
  margin-top: 0;
}

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

h1 {
  font-size: clamp(52px, 5.1vw, 72px);
  letter-spacing: -.02em;
}

h2 {
  font-size: clamp(34px, 4vw, 54px);
  letter-spacing: -.018em;
}

h3 {
  font-size: clamp(22px, 2.3vw, 30px);
  letter-spacing: -.012em;
}

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

strong {
  color: var(--color-text);
}

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

code {
  overflow-wrap: anywhere;
}

pre {
  max-width: 100%;
  padding: 18px;
  overflow-x: auto;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-panel-alt);
}

pre code {
  overflow-wrap: normal;
  white-space: pre;
}

.no-break {
  white-space: nowrap;
}

@media (max-width: 640px) {
  .no-break {
    white-space: normal;
  }
}

.wrap {
  width: 100%;
  max-width: var(--content-width);
  margin-inline: auto;
  padding-inline: var(--gutter);
  min-width: 0;
}

.reading-wrap {
  width: 100%;
  max-width: calc(var(--reading-width) + var(--gutter) * 2);
  margin-inline: auto;
  padding-inline: var(--gutter);
  min-width: 0;
}

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

.section-compact {
  padding-top: clamp(40px, 6vw, 72px);
  padding-bottom: clamp(40px, 6vw, 72px);
  overflow-x: clip;
}

.section-head {
  max-width: 850px;
  margin-bottom: clamp(30px, 5vw, 56px);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  margin-bottom: 18px;
  color: var(--color-muted);
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .14em;
  text-transform: uppercase;
}

.eyebrow-dot,
.status-dot {
  width: 8px;
  height: 8px;
  flex: none;
  border-radius: 50%;
  background: var(--color-success);
}

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

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

.panel,
.card {
  min-width: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-panel);
  box-shadow: var(--shadow-1);
}

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

.card {
  padding: clamp(22px, 3vw, 36px);
  transition: transform var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast);
}

.card:hover {
  transform: translateY(-3px);
  border-color: var(--color-muted);
  box-shadow: var(--shadow-2);
}

.badge,
.fact-pill,
.tag {
  display: inline-flex;
  min-height: 28px;
  max-width: 100%;
  align-items: center;
  gap: 7px;
  padding: 4px 11px;
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-pill);
  background: var(--color-panel);
  color: var(--color-muted);
  font-size: 12px;
  line-height: 1.4;
  text-overflow: ellipsis;
}

.badge-accent {
  border-color: var(--color-accent-border);
  background: var(--color-accent);
  color: var(--color-text);
  font-weight: 700;
}

.badge-success {
  border-color: var(--color-success-border);
  background: var(--color-success-soft);
  color: var(--color-success);
  font-weight: 700;
}

.btn {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 12px 26px;
  border: 1px solid transparent;
  border-radius: 10px;
  cursor: pointer;
  font-weight: 700;
  line-height: 1.2;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), border-color var(--transition-fast), background-color var(--transition-fast);
}

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

.btn-primary {
  border-color: var(--color-accent-border);
  background: var(--color-accent);
  color: var(--color-text);
  box-shadow: var(--shadow-1);
}

.btn-primary:hover {
  box-shadow: var(--shadow-2);
}

.btn-secondary {
  border-color: var(--color-border);
  background: var(--color-panel);
  color: var(--color-text);
}

.btn-secondary:hover {
  border-color: var(--color-muted);
}

.btn-dark {
  border-color: var(--color-text);
  background: var(--color-text);
  color: var(--color-white);
}

.btn-disabled,
.btn:disabled {
  opacity: .52;
  pointer-events: none;
}

.button-row {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.reveal {
  transition: opacity .58s ease, transform .58s ease;
}

.reveal.pending {
  opacity: 0;
  transform: translateY(16px);
}

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

.site-header {
  position: sticky;
  top: 0;
  z-index: 70;
  min-height: var(--header-height);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-header);
  backdrop-filter: blur(10px);
}

.header-inner {
  position: relative;
  display: flex;
  width: 100%;
  max-width: var(--content-width);
  min-height: var(--header-height);
  align-items: center;
  gap: 22px;
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.site-brand {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 10px;
  flex: none;
}

.brand-logo {
  width: 32px;
  height: 32px;
}

.brand-words {
  display: inline-flex;
  align-items: baseline;
  gap: 7px;
  white-space: nowrap;
}

.brand-name {
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 800;
}

.brand-local {
  color: var(--color-muted);
  font-size: 12px;
  font-weight: 600;
}

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

.nav-link {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  gap: 6px;
  padding: 7px 9px;
  border-radius: var(--radius-sm);
  color: var(--color-muted);
  font-size: 13px;
  font-weight: 550;
  white-space: nowrap;
  transition: color var(--transition-fast), background-color var(--transition-fast);
}

.nav-link svg {
  width: 15px;
  height: 15px;
}

.nav-link:hover,
.nav-link.is-active {
  background: var(--color-panel-alt);
  color: var(--color-text);
}

.nav-link.is-active {
  font-weight: 700;
}

.header-tools {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: none;
}

.lang-menu {
  position: relative;
}

.lang-button {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  gap: 5px;
  padding: 6px 9px;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--color-muted);
  cursor: pointer;
  font-size: 13px;
}

.lang-button:hover {
  background: var(--color-panel-alt);
  color: var(--color-text);
}

.lang-options {
  position: absolute;
  top: calc(100% + 9px);
  right: 0;
  display: none;
  width: 160px;
  padding: 7px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-md);
  background: var(--color-panel);
  box-shadow: var(--shadow-2);
}

.lang-menu.is-open .lang-options {
  display: block;
}

.lang-options a {
  display: flex;
  min-height: 42px;
  align-items: center;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  color: var(--color-muted);
  font-size: 13px;
}

.lang-options a:hover,
.lang-options a[aria-current="true"] {
  background: var(--color-panel-alt);
  color: var(--color-text);
}

.header-login {
  display: inline-flex;
  min-height: 40px;
  align-items: center;
  justify-content: center;
  padding: 8px 18px;
  border: 1px solid var(--color-text);
  border-radius: var(--radius-sm);
  background: var(--color-text);
  color: var(--color-white);
  font-size: 13px;
  font-weight: 700;
}

.mobile-menu-button {
  display: none;
  width: 44px;
  min-width: 44px;
  height: 44px;
  align-items: center;
  justify-content: center;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  cursor: pointer;
}

.mobile-menu-button svg {
  width: 22px;
  height: 22px;
}

.mobile-nav {
  position: fixed;
  z-index: 74;
  top: var(--header-height);
  right: 0;
  left: 0;
  display: none;
  max-height: calc(100dvh - var(--header-height));
  padding: 12px var(--gutter) 20px;
  overflow-y: auto;
  overscroll-behavior: contain;
  border-top: 1px solid var(--color-border);
  background: var(--color-panel);
  box-shadow: var(--shadow-2);
}

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

.mobile-nav a {
  display: flex;
  width: 100%;
  min-height: 48px;
  align-items: center;
  gap: 10px;
  padding: 11px 12px;
  border-radius: var(--radius-sm);
  color: var(--color-muted);
}

.mobile-nav a:hover,
.mobile-nav a.is-active {
  background: var(--color-panel-alt);
  color: var(--color-text);
}

.mobile-nav svg {
  width: 18px;
  height: 18px;
}

.mobile-language-list {
  margin-top: 10px;
  padding-top: 10px;
  border-top: 1px solid var(--color-border);
}

.nav-veil {
  position: fixed;
  z-index: 68;
  inset: var(--header-height) 0 0;
  display: none;
  border: 0;
  background: var(--color-overlay);
}

.nav-veil.is-open {
  display: block;
}

.site-footer {
  border-top: 1px solid var(--color-border);
  background: var(--color-panel);
}

.footer-main {
  display: grid;
  grid-template-columns: minmax(220px, 1.15fr) repeat(3, minmax(150px, .75fr));
  gap: clamp(28px, 5vw, 70px);
  padding-top: 64px;
  padding-bottom: 52px;
}

.footer-brand p {
  max-width: 340px;
  margin-top: 16px;
  margin-bottom: 0;
  font-size: 14px;
}

.footer-title {
  margin-bottom: 14px;
  font-size: 13px;
  letter-spacing: .05em;
}

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

.footer-links a {
  display: inline-flex;
  min-height: 30px;
  align-items: center;
  color: var(--color-muted);
  font-size: 13px;
}

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

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 20px;
  padding-bottom: 24px;
  border-top: 1px solid var(--color-border);
  color: var(--color-muted);
  font-size: 12px;
}

.footer-legal,
.footer-languages {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
}

.prose {
  min-width: 0;
}

.prose h2,
.prose h3 {
  scroll-margin-top: calc(var(--header-height) + 78px);
}

.prose h2 {
  margin-top: 2.2em;
  margin-bottom: .7em;
}

.prose h3 {
  margin-top: 1.7em;
  margin-bottom: .6em;
}

.prose p,
.prose li {
  color: var(--color-muted);
}

.prose a:not(.btn) {
  color: var(--color-accent-dark);
  text-decoration: underline;
  text-underline-offset: 3px;
}

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

@media (max-width: 1160px) {
  .desktop-nav {
    gap: 0;
  }

  .nav-link {
    padding-inline: 7px;
    font-size: 12px;
  }

  .brand-local {
    display: none;
  }
}

@media (max-width: 960px) {
  .desktop-nav,
  .header-tools .lang-menu {
    display: none;
  }

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

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

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

@media (max-width: 768px) {
  h1 {
    font-size: clamp(28px, 10vw, 40px);
    line-height: 1.12;
  }

  h2 {
    font-size: clamp(28px, 8vw, 38px);
  }

  .section {
    padding-top: 64px;
    padding-bottom: 64px;
  }

  [data-parallax-decor],
  .decor-text {
    display: none;
  }
}

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

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

  .button-row {
    align-items: stretch;
  }

  .button-row .btn {
    flex: 1 1 150px;
  }

  .header-inner {
    gap: 8px;
  }

  .brand-local {
    display: none;
  }

  .header-login {
    padding-inline: 13px;
  }

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

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

@media (max-width: 370px) {
  .brand-name {
    font-size: 15px;
  }

  .brand-logo {
    width: 29px;
    height: 29px;
  }

  .header-login {
    padding-inline: 10px;
  }
}

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

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

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