:root {
  --color-page: #F4F5F6;
  --color-surface: #FFFFFF;
  --color-surface-muted: #ECEEF0;
  --color-line: #D8DBDF;
  --color-accent: #C42B1F;
  --color-accent-deep: #9A1F16;
  --color-text: #17191C;
  --color-text-muted: #5B6169;
  --color-link: #0F6B8C;
  --color-success: #1E7F4F;
  --color-warning: #B9790F;
  --color-error: #AD1F13;
  --color-glow-warm: #FFE8D6;
  --color-glow-cool: #D9F0F0;
  --color-accent-soft: #FBE9E7;
  --color-link-soft: #E5F2F6;
  --color-success-soft: #E5F3EB;
  --color-warning-soft: #FFF2DC;
  --color-dark-surface: #17191C;
  --color-dark-muted: #25292E;
  --color-on-dark: #FFFFFF;
  --color-shadow: rgba(23, 25, 28, .12);
  --color-shadow-soft: rgba(23, 25, 28, .06);
  --color-accent-shadow: rgba(196, 43, 31, .22);
  --color-accent-shadow-soft: rgba(196, 43, 31, .16);
  --color-spine: rgba(23, 25, 28, .12);
  --font-display: 'Inter', 'Noto Sans SC', 'Noto Sans JP', 'Noto Sans KR', -apple-system, 'Segoe UI', 'PingFang SC', 'Hiragino Sans', 'Malgun Gothic', sans-serif;
  --font-body: 'Inter', 'Noto Sans SC', 'Noto Sans JP', 'Noto Sans KR', -apple-system, 'Segoe UI', 'PingFang SC', 'Hiragino Sans', 'Malgun Gothic', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', 'Cascadia Mono', Consolas, monospace;
  --radius-xs: 6px;
  --radius-sm: 8px;
  --radius-md: 12px;
  --radius-lg: 18px;
  --radius-pill: 999px;
  --shadow-panel: 0 1px 2px var(--color-shadow-soft);
  --shadow-raised: 0 18px 36px var(--color-shadow), 0 3px 8px var(--color-shadow-soft);
  --shadow-action: 0 10px 24px var(--color-accent-shadow), 0 2px 6px var(--color-accent-shadow-soft);
  --content-width: 1180px;
  --header-width: 1280px;
  --reading-width: 56rem;
  --header-height: 64px;
  --gutter: clamp(16px, 3vw, 32px);
  --section-space: clamp(68px, 8vw, 112px);
  --toc-top: 76px;
  --transition-fast: 150ms ease;
  --transition-reveal: 560ms cubic-bezier(.2, .7, .2, 1);
}

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

html {
  margin: 0;
  padding: 0;
  scroll-behavior: smooth;
  background: var(--color-page);
}

html.nav-open {
  overflow: hidden;
}

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

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

img {
  height: auto;
}

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

button {
  cursor: pointer;
}

a {
  color: var(--color-link);
  text-decoration: none;
}

a:hover {
  text-decoration: none;
}

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

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

ul,
ol {
  padding-left: 1.35rem;
}

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

:not(pre) > code {
  padding: .1em .35em;
  overflow-wrap: anywhere;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-xs);
  background: var(--color-surface-muted);
  font-size: .9em;
}

pre {
  max-width: 100%;
  padding: 20px;
  overflow-x: auto;
  border-radius: var(--radius-sm);
  background: var(--color-dark-surface);
  color: var(--color-on-dark);
  font-family: var(--font-mono);
  line-height: 1.65;
  -webkit-overflow-scrolling: touch;
}

pre code {
  padding: 0;
  border: 0;
  background: transparent;
  color: inherit;
  overflow-wrap: normal;
  white-space: pre;
}

table {
  border-collapse: collapse;
}

th,
td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--color-line);
  text-align: left;
  vertical-align: top;
}

th {
  color: var(--color-text);
  font-weight: 800;
}

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

h1 {
  max-width: 100%;
  font-size: clamp(52px, 6vw, 72px);
  font-weight: 900;
  letter-spacing: -.015em;
  line-height: 1.1;
}

h2 {
  font-size: clamp(32px, 4vw, 48px);
  font-weight: 900;
  letter-spacing: -.012em;
  line-height: 1.16;
}

h3 {
  font-size: clamp(21px, 2.4vw, 28px);
  font-weight: 850;
  line-height: 1.25;
}

h4 {
  font-size: 18px;
  font-weight: 800;
  line-height: 1.35;
}

.keyword-lock {
  white-space: nowrap;
}

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

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

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

.section-compact {
  padding-top: clamp(44px, 6vw, 76px);
  padding-bottom: clamp(44px, 6vw, 76px);
}

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

.section-head.is-centered {
  margin-inline: auto;
  text-align: center;
}

.eyebrow {
  margin-bottom: 10px;
  color: var(--color-accent);
  font-size: 12px;
  font-weight: 850;
  letter-spacing: .2em;
  text-transform: uppercase;
}

.lead {
  max-width: 760px;
  color: var(--color-text-muted);
  font-size: clamp(17px, 2vw, 21px);
  line-height: 1.7;
}

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

.accent-text {
  color: var(--color-accent);
}

.link-text {
  color: var(--color-link);
  font-weight: 750;
}

.stack {
  display: grid;
  gap: 20px;
}

.cluster {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.cluster > svg,
.cluster > img,
.cluster > .dot,
.cluster > .icon {
  flex-shrink: 0;
}

.grid {
  display: grid;
  gap: 24px;
}

.grid > * {
  min-width: 0;
}

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

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

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

.panel {
  padding: clamp(22px, 3vw, 34px);
}

.card {
  padding: 24px;
}

.badge,
.tag {
  display: inline-flex;
  max-width: 100%;
  min-width: 0;
  align-items: center;
  gap: 8px;
  padding: 6px 13px;
  overflow: hidden;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-pill);
  background: var(--color-surface);
  color: var(--color-text-muted);
  font-size: 13px;
  font-weight: 700;
  line-height: 1.25;
  text-overflow: ellipsis;
}

.badge-dot,
.status-dot {
  width: 8px;
  height: 8px;
  flex-shrink: 0;
  border-radius: 2px;
  background: var(--color-accent);
}

.tag.is-accent {
  border-color: var(--color-accent);
  background: var(--color-accent-soft);
  color: var(--color-accent-deep);
}

.tag.is-success {
  border-color: var(--color-success);
  background: var(--color-success-soft);
  color: var(--color-success);
}

.btn,
.btn-primary,
.btn-secondary,
.btn-neutral {
  display: inline-flex;
  min-height: 46px;
  align-items: center;
  justify-content: center;
  gap: 9px;
  padding: 11px 26px;
  border: 1.5px solid transparent;
  border-radius: 10px;
  font-weight: 800;
  line-height: 1.2;
  text-align: center;
  transition: color var(--transition-fast), background var(--transition-fast), border-color var(--transition-fast), transform var(--transition-fast), box-shadow var(--transition-fast);
}

.btn svg,
.btn-primary svg,
.btn-secondary svg,
.btn-neutral svg {
  flex-shrink: 0;
}

.btn-primary {
  border-color: var(--color-accent);
  background: var(--color-accent);
  color: var(--color-on-dark);
  box-shadow: var(--shadow-action);
}

.btn-primary:hover {
  border-color: var(--color-accent-deep);
  background: var(--color-accent-deep);
  color: var(--color-on-dark);
  transform: translateY(-1px);
}

.btn-secondary {
  border-color: var(--color-link);
  background: var(--color-surface);
  color: var(--color-link);
}

.btn-secondary:hover {
  background: var(--color-link-soft);
  color: var(--color-link);
}

.btn-neutral {
  border-color: var(--color-line);
  background: var(--color-surface);
  color: var(--color-text);
}

.btn-neutral:hover {
  border-color: var(--color-text-muted);
  background: var(--color-surface-muted);
}

.btn[aria-disabled="true"],
.btn-primary[aria-disabled="true"],
.btn-secondary[aria-disabled="true"],
.btn-neutral[aria-disabled="true"],
button:disabled {
  cursor: not-allowed;
  opacity: .52;
  transform: none;
  box-shadow: none;
}

.site-head {
  position: relative;
  z-index: 100;
  border-bottom: 1px solid var(--color-line);
  background: var(--color-surface);
}

.head-in {
  width: 100%;
  max-width: var(--header-width);
  height: var(--header-height);
  margin-inline: auto;
  padding-inline: var(--gutter);
  display: flex;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  min-width: max-content;
  align-items: center;
  gap: 10px;
  color: var(--color-text);
  font-family: var(--font-display);
  font-size: 19px;
  font-weight: 900;
  letter-spacing: .01em;
}

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

.brand img {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
}

.brand-local {
  color: var(--color-text-muted);
  font-size: 13px;
  font-weight: 650;
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 4px;
}

.main-nav a {
  padding: 7px 14px;
  border-radius: var(--radius-pill);
  color: var(--color-text-muted);
  font-size: 14px;
  font-weight: 650;
  white-space: nowrap;
  transition: color var(--transition-fast), background var(--transition-fast);
}

.main-nav a:hover {
  color: var(--color-text);
}

.main-nav a.is-active {
  background: var(--color-surface-muted);
  color: var(--color-text);
}

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

.lang-control {
  position: relative;
}

.lang-trigger {
  min-height: 44px;
  padding: 7px 10px;
  border: 0;
  background: transparent;
  color: var(--color-text-muted);
  font-size: 13px;
  font-weight: 700;
}

.lang-trigger:hover {
  color: var(--color-text);
}

.lang-menu {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  z-index: 130;
  display: none;
  width: 170px;
  padding: 7px;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-sm);
  background: var(--color-surface);
  box-shadow: var(--shadow-raised);
}

.lang-control.is-open .lang-menu {
  display: grid;
}

.lang-menu a {
  display: block;
  min-height: 42px;
  padding: 9px 11px;
  border-radius: var(--radius-xs);
  color: var(--color-text-muted);
  font-size: 13px;
  font-weight: 650;
}

.lang-menu a:hover,
.lang-menu a[aria-current="true"] {
  background: var(--color-surface-muted);
  color: var(--color-text);
}

.login-link {
  min-height: 38px;
  padding: 7px 21px;
  border: 1.5px solid var(--color-link);
  border-radius: var(--radius-sm);
  color: var(--color-link);
  font-size: 14px;
  font-weight: 800;
  line-height: 1.45;
}

.login-link:hover {
  background: var(--color-link);
  color: var(--color-on-dark);
}

.menu-toggle {
  display: none;
  min-width: 44px;
  min-height: 44px;
  padding: 10px;
  border: 0;
  border-radius: var(--radius-sm);
  background: transparent;
  color: var(--color-text);
}

.menu-toggle:hover {
  background: var(--color-surface-muted);
}

.menu-toggle-lines,
.menu-toggle-lines::before,
.menu-toggle-lines::after {
  display: block;
  width: 22px;
  height: 2px;
  border-radius: var(--radius-pill);
  background: currentColor;
  content: "";
  transition: transform var(--transition-fast), opacity var(--transition-fast);
}

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

.menu-toggle-lines::before {
  position: absolute;
  top: -7px;
  left: 0;
}

.menu-toggle-lines::after {
  position: absolute;
  top: 7px;
  left: 0;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-lines {
  background: transparent;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-lines::before {
  transform: translateY(7px) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-toggle-lines::after {
  transform: translateY(-7px) rotate(-45deg);
}

.mobile-nav {
  display: none;
}

.nav-veil {
  display: none;
}

.site-footer {
  overflow-x: clip;
  border-top: 1px solid var(--color-line);
  background: var(--color-surface);
}

.footer-main {
  padding-top: 58px;
  padding-bottom: 42px;
  display: grid;
  grid-template-columns: 1.35fr 1fr 1.5fr;
  gap: 48px;
}

.footer-main > * {
  min-width: 0;
}

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

.footer-title {
  margin-bottom: 15px;
  font-size: 13px;
  font-weight: 850;
  letter-spacing: .12em;
}

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

.footer-links a,
.footer-keywords a {
  color: var(--color-text-muted);
  font-size: 14px;
}

.footer-links a:hover,
.footer-keywords a:hover {
  color: var(--color-link);
}

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

.footer-keywords a {
  max-width: 100%;
  padding: 5px 10px;
  overflow: hidden;
  border: 1px solid var(--color-line);
  border-radius: var(--radius-pill);
  background: var(--color-page);
  text-overflow: ellipsis;
}

.footer-bottom {
  padding-top: 22px;
  padding-bottom: 26px;
  border-top: 1px solid var(--color-line);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 16px 24px;
  color: var(--color-text-muted);
  font-size: 13px;
}

.footer-bottom .footer-languages {
  margin-left: auto;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

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

.footer-languages a[aria-current="true"],
.footer-languages a:hover {
  color: var(--color-link);
}

.reveal {
  transition: opacity var(--transition-reveal), transform var(--transition-reveal);
}

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

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

.tilt,
.tilt-card {
  transform: rotate(-.35deg);
}

.decor-host,
.hero,
.promo-section {
  position: relative;
  overflow-x: clip;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: fixed;
  top: 8px;
  left: 8px;
  z-index: 1000;
  padding: 8px 12px;
  transform: translateY(-140%);
  border-radius: var(--radius-sm);
  background: var(--color-text);
  color: var(--color-on-dark);
}

.skip-link:focus {
  transform: none;
}

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

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

  .lang-control {
    display: none;
  }

  .menu-toggle {
    display: inline-flex;
    align-items: center;
    justify-content: center;
  }

  .mobile-nav {
    position: absolute;
    top: var(--header-height);
    right: 0;
    left: 0;
    z-index: 125;
    max-height: calc(100dvh - var(--header-height));
    padding: 12px var(--gutter) 20px;
    overflow-y: auto;
    overscroll-behavior: contain;
    border-bottom: 1px solid var(--color-line);
    background: var(--color-surface);
  }

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

  .mobile-nav ul {
    margin: 0;
    padding: 0;
    list-style: none;
  }

  .mobile-nav a {
    display: flex;
    width: 100%;
    min-height: 46px;
    align-items: center;
    padding: 11px 13px;
    border-radius: var(--radius-sm);
    color: var(--color-text-muted);
    font-weight: 700;
  }

  .mobile-nav a:hover,
  .mobile-nav a.is-active,
  .mobile-nav a[aria-current="true"] {
    background: var(--color-surface-muted);
    color: var(--color-text);
  }

  .mobile-nav .mobile-language-title {
    padding: 18px 13px 6px;
    color: var(--color-text-muted);
    font-size: 12px;
    font-weight: 850;
    letter-spacing: .12em;
  }

  .nav-veil {
    position: fixed;
    inset: var(--header-height) 0 0;
    z-index: 90;
    background: var(--color-shadow);
  }

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

@media (max-width: 768px) {
  h1 {
    font-size: clamp(28px, 9vw, 40px);
    line-height: 1.13;
    letter-spacing: -.01em;
  }

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

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

  .footer-main {
    grid-template-columns: minmax(0, 1fr);
    gap: 34px;
  }

  .footer-bottom .footer-languages {
    width: 100%;
    margin-left: 0;
  }

  .absolute-caption,
  .decorative-label {
    display: none;
  }
}

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

  .head-in {
    gap: 8px;
  }

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

  .brand-local {
    display: none;
  }

  .head-tools {
    margin-left: auto;
    gap: 5px;
  }

  .login-link {
    min-height: 36px;
    padding: 6px 13px;
    font-size: 13px;
  }

  .btn,
  .btn-primary,
  .btn-secondary,
  .btn-neutral {
    width: 100%;
    padding-inline: 18px;
  }

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

  th,
  td {
    padding: 12px;
  }
}

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

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

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