:root {
  --color-bg: #F5F6FA;
  --color-panel: #FFFFFF;
  --color-panel-soft: #ECEEF6;
  --color-border: #DADDE9;
  --color-accent: #3D2DB5;
  --color-accent-dark: #2A1E85;
  --color-ice: #5F8BFF;
  --color-gold: #E8A93A;
  --color-text: #14152B;
  --color-muted: #5B5E78;
  --color-success: #1E9C6B;
  --color-warn: #D9931E;
  --color-error: #D2383F;
  --color-footer: #14152B;
  --color-footer-muted: #B9BBD0;
  --color-transparent: transparent;

  --atmosphere-top: rgba(95, 139, 255, .04);
  --atmosphere-bottom: rgba(61, 45, 181, .07);
  --ice-spot: rgba(95, 139, 255, .07);
  --accent-shadow: rgba(61, 45, 181, .12);
  --accent-shadow-strong: rgba(61, 45, 181, .18);
  --accent-tint: rgba(61, 45, 181, .18);
  --accent-tint-soft: rgba(61, 45, 181, .08);
  --accent-line: rgba(61, 45, 181, .55);
  --ice-ring: rgba(95, 139, 255, .42);
  --glass: rgba(255, 255, 255, .82);
  --glass-edge: rgba(255, 255, 255, .92);
  --ink-shadow: rgba(20, 21, 43, .18);
  --veil: rgba(20, 21, 43, .38);

  --cube-top-a: #EEF2FF;
  --cube-top-b: #C4D3FF;
  --cube-top-c: #8DA5FF;
  --cube-front-a: #5B57EA;
  --cube-front-b: #3D2DB5;
  --cube-right-a: #3527A8;
  --cube-right-b: #21176A;

  --flag-red: #D8232A;
  --flag-blue: #2F4C9E;
  --flag-green: #2E9A4B;
  --flag-white: #FFFFFF;

  --font-display: 'Inter', 'Noto Sans SC', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Noto Sans JP', 'Noto Sans KR', system-ui, sans-serif;
  --font-body: 'Inter', 'Noto Sans SC', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', 'Noto Sans JP', 'Noto Sans KR', system-ui, sans-serif;
  --font-mono: 'JetBrains Mono', 'SF Mono', Menlo, Consolas, 'Liberation Mono', monospace;

  --radius-small: 6px;
  --radius-medium: 8px;
  --radius-pill: 999px;
  --wrap: 1240px;
  --reading: 780px;
  --header-height: 72px;
  --gutter: 32px;
  --section-space: 104px;
  --focus-size: 2px;
  --shadow-panel: 0 18px 48px var(--accent-shadow);
  --shadow-button: 0 8px 20px var(--ink-shadow);
  --transition-fast: 180ms ease;
}

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

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

html.nav-open {
  overflow: hidden;
}

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

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

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

img {
  height: auto;
}

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

button,
summary,
select {
  cursor: pointer;
}

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

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

p {
  margin-bottom: 1.25rem;
}

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

h1,
.hero-title {
  font-size: clamp(52px, 5.2vw, 68px);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -.02em;
}

h2 {
  font-size: clamp(34px, 3.4vw, 48px);
  font-weight: 800;
  line-height: 1.16;
  letter-spacing: -.02em;
}

h3 {
  font-size: clamp(22px, 2vw, 28px);
  font-weight: 750;
  line-height: 1.3;
}

h4 {
  font-size: 18px;
  font-weight: 700;
}

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

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

code {
  overflow-wrap: anywhere;
}

pre {
  max-width: 100%;
  overflow-x: auto;
  padding: 20px;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-medium);
  background: var(--color-panel-soft);
  color: var(--color-text);
  -webkit-overflow-scrolling: touch;
}

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

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

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

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

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

.section-rule {
  border-top: 1px solid var(--color-border);
}

.section-head {
  max-width: 760px;
  margin-bottom: 48px;
}

.section-head p {
  color: var(--color-muted);
  font-size: 18px;
}

.kicker,
.eyebrow-mono {
  display: inline-block;
  margin-bottom: 12px;
  color: var(--color-muted);
  font-family: var(--font-mono);
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
}

.inline-link,
.prose a {
  color: var(--color-accent);
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.inline-link:hover,
.prose a:hover {
  color: var(--color-accent-dark);
}

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

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.icon {
  width: 22px;
  height: 22px;
  flex: 0 0 auto;
}

.icon-small {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
}

.btn,
.btn-primary,
.btn-secondary,
.btn-quiet,
.btn-login {
  display: inline-flex;
  min-width: 24px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border-radius: var(--radius-small);
  padding: 10px 22px;
  border: 1px solid var(--color-transparent);
  font-size: 15px;
  font-weight: 650;
  line-height: 1.2;
  transition: color var(--transition-fast), background var(--transition-fast), border-color var(--transition-fast), box-shadow var(--transition-fast), transform var(--transition-fast);
}

.btn-primary {
  background: var(--color-text);
  color: var(--color-panel);
  box-shadow: var(--shadow-button);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 0 0 3px var(--ice-ring), var(--shadow-button);
}

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

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

.btn-quiet {
  min-height: 44px;
  padding-inline: 0;
  background: var(--color-transparent);
  color: var(--color-text);
}

.btn-quiet .arrow,
.link-arrow .arrow {
  transition: transform var(--transition-fast);
}

.btn-quiet:hover .arrow,
.link-arrow:hover .arrow {
  transform: translateX(4px);
}

.panel,
.card {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-medium);
  background: var(--color-panel);
  box-shadow: inset 0 0 0 1px var(--glass-edge), var(--shadow-panel);
}

.glass-panel {
  border: 1px solid var(--color-border);
  border-radius: var(--radius-medium);
  background: var(--glass);
  box-shadow: inset 0 0 0 1px var(--glass-edge), var(--shadow-panel);
  backdrop-filter: blur(10px);
}

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

.status-dot {
  width: 7px;
  height: 7px;
  flex: 0 0 auto;
  border-radius: var(--radius-pill);
  background: var(--color-success);
}

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

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

.reveal.shown {
  opacity: 1;
  transform: translateY(0);
}

.site-head {
  position: relative;
  z-index: 50;
  height: var(--header-height);
  border-bottom: 1px solid var(--color-border);
  background: var(--color-bg);
}

.head-in {
  display: flex;
  height: var(--header-height);
  align-items: center;
  gap: 40px;
}

.brand {
  display: inline-flex;
  min-height: 44px;
  align-items: center;
  gap: 10px;
  color: var(--color-text);
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 800;
  letter-spacing: -.02em;
}

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

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

.desktop-nav {
  display: flex;
  height: var(--header-height);
  align-items: center;
  gap: 30px;
}

.desktop-nav a {
  position: relative;
  display: inline-flex;
  min-height: 44px;
  height: var(--header-height);
  align-items: center;
  color: var(--color-muted);
  font-size: 14px;
  font-weight: 500;
  transition: color var(--transition-fast);
}

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

.desktop-nav a[aria-current="page"] {
  font-weight: 650;
}

.desktop-nav a[aria-current="page"]::after {
  position: absolute;
  right: 0;
  bottom: -1px;
  left: 0;
  height: 2px;
  border-radius: 1px;
  background: var(--color-accent);
  content: "";
}

.head-tools {
  display: flex;
  margin-left: auto;
  align-items: center;
  gap: 12px;
}

.language-switch {
  position: relative;
}

.language-button {
  display: inline-flex;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 0;
  background: var(--color-transparent);
  color: var(--color-muted);
  font-size: 14px;
}

.language-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 60;
  display: none;
  width: 168px;
  overflow: hidden;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-medium);
  background: var(--color-panel);
  box-shadow: var(--shadow-panel);
}

.language-switch.is-open .language-menu {
  display: block;
}

.language-menu a {
  display: flex;
  width: 100%;
  min-height: 44px;
  align-items: center;
  padding: 9px 14px;
  color: var(--color-muted);
  font-size: 14px;
}

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

.btn-login {
  min-height: 38px;
  padding-block: 8px;
  padding-inline: 18px;
  border-color: var(--color-text);
  background: var(--color-panel);
  color: var(--color-text);
  font-size: 14px;
}

.btn-login:hover {
  background: var(--color-text);
  color: var(--color-panel);
}

.menu-toggle {
  display: none;
  min-width: 44px;
  min-height: 44px;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--color-border);
  border-radius: var(--radius-small);
  background: var(--color-panel);
  color: var(--color-text);
}

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

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

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

.mobile-nav-inner {
  padding: 12px var(--gutter) 20px;
}

.mobile-nav a {
  display: flex;
  width: 100%;
  min-height: 48px;
  align-items: center;
  border-bottom: 1px solid var(--color-border);
  padding: 11px 4px;
  color: var(--color-text);
}

.mobile-nav-languages {
  padding-top: 10px;
}

.mobile-nav-languages strong {
  display: block;
  padding: 8px 4px;
  color: var(--color-muted);
  font-size: 12px;
}

.mobile-nav-languages a {
  color: var(--color-muted);
}

.site-footer {
  position: relative;
  overflow-x: clip;
  padding-top: 72px;
  padding-bottom: 28px;
  background: var(--color-footer);
  color: var(--color-panel);
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.35fr 1fr 1.2fr;
  gap: 64px;
}

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

.footer-brand .brand {
  color: var(--color-panel);
}

.footer-brand .brand-local {
  color: var(--color-footer-muted);
}

.footer-title {
  margin-bottom: 16px;
  color: var(--color-panel);
  font-size: 14px;
  font-weight: 700;
}

.footer-links {
  display: grid;
  gap: 8px;
}

.footer-links a {
  display: inline-flex;
  width: fit-content;
  min-height: 32px;
  align-items: center;
  color: var(--color-footer-muted);
  font-size: 14px;
}

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

.footer-keywords {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.footer-keywords a {
  display: inline-flex;
  min-height: 32px;
  align-items: center;
  border: 1px solid var(--color-muted);
  border-radius: var(--radius-pill);
  padding: 4px 10px;
  color: var(--color-footer-muted);
  font-size: 12px;
}

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

.footer-language {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.footer-language a {
  min-height: 24px;
}

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

.prose h2,
.prose h3 {
  color: var(--color-text);
}

.prose h2 {
  margin-top: 64px;
  margin-bottom: 20px;
}

.prose h3 {
  margin-top: 36px;
  margin-bottom: 14px;
}

.prose li {
  margin-bottom: 8px;
}

#server-status {
  position: relative;
  display: block;
  width: 100%;
  max-width: 100%;
  overflow: hidden;
  margin-bottom: 48px;
}

#server-status + * {
  margin-top: 0;
}

.ticker {
  max-width: 100%;
  overflow: hidden;
  border-block: 1px solid var(--color-border);
  background: var(--color-panel);
}

.ticker-track {
  display: flex;
  width: max-content;
  align-items: center;
  gap: 36px;
  padding-block: 14px;
  padding-inline: 18px;
  color: var(--color-muted);
  font-family: var(--font-mono);
  font-size: 13px;
  white-space: nowrap;
}

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

.ticker-item::before {
  width: 6px;
  height: 6px;
  flex: 0 0 auto;
  border-radius: var(--radius-pill);
  background: var(--color-accent);
  content: "";
}

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

  .head-in {
    gap: 24px;
  }

  .desktop-nav a {
    font-size: 13px;
  }
}

@media (max-width: 920px) {
  .desktop-nav,
  .language-switch {
    display: none;
  }

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

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

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

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

@media (max-width: 768px) {
  :root {
    --gutter: 20px;
    --section-space: 72px;
  }

  h1,
  .hero-title {
    font-size: clamp(32px, 9.5vw, 40px);
    line-height: 1.12;
  }

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

  .footer-grid {
    gap: 40px;
  }
}

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

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

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

  .section {
    max-width: 100%;
  }

  .head-in {
    gap: 8px;
  }

  .brand {
    font-size: 17px;
  }

  .brand img {
    width: 28px;
    height: 28px;
  }

  .btn-login {
    min-width: 56px;
    padding-inline: 12px;
  }

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

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

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

  .badge,
  .fact-pill,
  .tag {
    white-space: normal;
  }
}

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

  *,
  *::before,
  *::after {
    scroll-behavior: auto;
  }

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

  .btn,
  .btn-primary,
  .btn-secondary,
  .btn-quiet,
  .btn-login,
  .desktop-nav a {
    transition: none;
  }
}