:root {
  --color-space: #0A0E27;
  --color-space-deep: #0B0B1A;
  --color-violet: #6C2BF4;
  --color-violet-soft: #9B6BFF;
  --color-green: #39FF14;
  --color-gold: #FFD700;
  --color-white: #F5F7FA;
  --color-silver: #A0AEC0;
  --color-red: #FF4D4D;
  --header-width: 120px;
  --header-height-mobile: 64px;
  --content-max: 1240px;
  --font-body: "Noto Sans SC", "Source Han Sans CN", "PingFang SC", "Microsoft YaHei", sans-serif;
  --font-mono: "JetBrains Mono", "SFMono-Regular", "Roboto Mono", Consolas, "Liberation Mono", monospace;
}

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

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

body {
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.7;
  color: var(--color-white);
  background:
    radial-gradient(1200px 800px at 85% -10%, rgba(108, 43, 244, 0.14) 0%, transparent 60%),
    var(--color-space);
  padding-left: var(--header-width);
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

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

a {
  color: var(--color-violet-soft);
  text-decoration: none;
  transition: color 0.2s ease;
}

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

h1,
h2,
h3,
h4 {
  font-weight: 700;
  line-height: 1.2;
  color: var(--color-white);
  letter-spacing: -0.01em;
}

h1 {
  font-size: clamp(40px, 8vw, 88px);
  font-weight: 800;
  letter-spacing: -0.02em;
}

h2 {
  font-size: clamp(26px, 4vw, 44px);
}

h3 {
  font-size: 22px;
}

p {
  margin-bottom: 1em;
}

ul,
ol {
  padding-left: 1.4em;
}

:focus-visible {
  outline: 2px solid var(--color-green);
  outline-offset: 3px;
  border-radius: 4px;
}

::selection {
  background: rgba(108, 43, 244, 0.45);
  color: var(--color-white);
}

.container {
  width: min(100% - 48px, var(--content-max));
  margin-inline: auto;
}

#main-content {
  min-height: 60vh;
  scroll-margin-top: var(--header-height-mobile);
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 50%;
  z-index: 1000;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--color-violet), var(--color-violet-soft));
  color: #fff;
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.05em;
  box-shadow: 0 8px 24px rgba(108, 43, 244, 0.45);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.skip-link:focus-visible {
  opacity: 1;
  pointer-events: auto;
  color: #fff;
}

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

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--header-width);
  z-index: 100;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  background:
    repeating-linear-gradient(180deg, rgba(155, 107, 255, 0.05) 0px, rgba(155, 107, 255, 0.05) 1px, transparent 1px, transparent 5px),
    linear-gradient(180deg, var(--color-space-deep) 0%, var(--color-space) 55%, var(--color-space-deep) 100%);
  border-right: 1px solid rgba(155, 107, 255, 0.18);
  padding: 24px 12px 20px;
}

.header__brand {
  text-align: center;
  padding-bottom: 24px;
  border-bottom: 1px solid rgba(155, 107, 255, 0.18);
  margin-bottom: 18px;
}

.brand__link {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  color: var(--color-white);
}

.brand__link:hover {
  color: var(--color-white);
}

.brand__mark {
  font-family: var(--font-mono);
  font-size: 32px;
  font-weight: 700;
  line-height: 1;
  color: var(--color-gold);
  text-shadow: 0 0 20px rgba(255, 215, 0, 0.25);
}

.brand__text {
  font-size: 12px;
  letter-spacing: 0.22em;
  color: var(--color-silver);
}

.site-header__nav {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 18px;
  min-height: 0;
}

.nav__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.nav__item {
  margin: 0;
}

.nav__link {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 11px 6px;
  border-radius: 8px;
  color: var(--color-silver);
  text-align: center;
  transition: background 0.25s ease, color 0.25s ease, box-shadow 0.25s ease;
}

.nav__link:hover {
  color: var(--color-white);
  background: rgba(108, 43, 244, 0.14);
}

.nav__index {
  font-family: var(--font-mono);
  font-size: 10px;
  line-height: 1;
  color: var(--color-green);
  opacity: 0.65;
  letter-spacing: 0.08em;
}

.nav__label {
  font-size: 13px;
  font-weight: 500;
  letter-spacing: 0.12em;
  white-space: nowrap;
}

.nav__link[aria-current="page"] {
  color: var(--color-white);
  background: linear-gradient(135deg, rgba(108, 43, 244, 0.32), rgba(155, 107, 255, 0.12));
  box-shadow: inset 0 0 0 1px rgba(155, 107, 255, 0.3);
}

.nav__link[aria-current="page"]::before {
  content: "";
  position: absolute;
  left: 0;
  top: 14px;
  bottom: 14px;
  width: 3px;
  border-radius: 3px;
  background: linear-gradient(180deg, var(--color-green), rgba(57, 255, 20, 0.2));
}

.nav__link[aria-current="page"]::after {
  content: "";
  position: absolute;
  right: 8px;
  bottom: 8px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--color-green);
  box-shadow: 0 0 8px var(--color-green);
}

.header__status {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 11px 6px;
  border: 1px solid rgba(57, 255, 20, 0.22);
  border-radius: 8px;
  background: rgba(57, 255, 20, 0.05);
}

.status__dot {
  flex-shrink: 0;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--color-green);
  box-shadow: 0 0 8px rgba(57, 255, 20, 0.9);
  animation: status-pulse 2s ease-in-out infinite;
}

@keyframes status-pulse {
  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 6px rgba(57, 255, 20, 0.8);
  }
  50% {
    opacity: 0.55;
    box-shadow: 0 0 2px rgba(57, 255, 20, 0.4);
  }
}

.status__text {
  font-size: 12px;
  color: var(--color-silver);
  letter-spacing: 0.1em;
  white-space: nowrap;
}

.nav-toggle {
  display: none;
  position: relative;
  width: 42px;
  height: 42px;
  border: 1px solid rgba(155, 107, 255, 0.4);
  border-radius: 8px;
  background: rgba(11, 11, 26, 0.6);
  cursor: pointer;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  transition: border-color 0.2s ease, background 0.2s ease;
}

.nav-toggle:hover {
  border-color: var(--color-green);
  background: rgba(108, 43, 244, 0.18);
}

.nav-toggle__line {
  display: block;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--color-white);
  transition: transform 0.3s ease, opacity 0.3s ease;
}

.nav-toggle.is-open .nav-toggle__line:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}

.nav-toggle.is-open .nav-toggle__line:nth-child(2) {
  opacity: 0;
}

.nav-toggle.is-open .nav-toggle__line:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

.scroll-progress {
  position: fixed;
  top: 0;
  right: 0;
  bottom: 0;
  width: 3px;
  z-index: 200;
  pointer-events: none;
  background: rgba(155, 107, 255, 0.16);
}

.scroll-progress::before {
  content: "";
  position: absolute;
  inset: 0;
  transform-origin: top;
  transform: scaleY(var(--scroll-progress, 0));
  background: linear-gradient(180deg, var(--color-violet) 0%, var(--color-green) 100%);
  box-shadow: 0 0 8px rgba(57, 255, 20, 0.35);
  transition: transform 0.06s linear;
}

.back-top {
  position: fixed;
  right: 24px;
  bottom: 24px;
  width: 44px;
  height: 44px;
  z-index: 150;
  border: 1px solid rgba(155, 107, 255, 0.5);
  border-radius: 50%;
  background: rgba(11, 11, 26, 0.85);
  color: var(--color-white);
  font-size: 20px;
  line-height: 1;
  cursor: pointer;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.3s ease, background 0.3s ease, border-color 0.3s ease, transform 0.3s ease;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.4);
}

.back-top.is-visible {
  opacity: 1;
  pointer-events: auto;
}

.back-top:hover {
  background: var(--color-violet);
  border-color: var(--color-violet);
  transform: translateY(-3px);
}

@media (max-width: 768px) {
  body {
    padding-left: 0;
  }

  .site-header {
    position: sticky;
    top: 0;
    width: auto;
    height: var(--header-height-mobile);
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 0 16px;
    border-right: none;
    border-bottom: 1px solid rgba(155, 107, 255, 0.2);
  }

  .header__brand {
    display: flex;
    align-items: center;
    margin: 0;
    padding: 0;
    border: none;
    text-align: left;
  }

  .brand__link {
    flex-direction: row;
    gap: 8px;
  }

  .brand__mark {
    font-size: 22px;
  }

  .brand__text {
    font-size: 12px;
    letter-spacing: 0.18em;
  }

  .site-header__nav {
    position: fixed;
    top: var(--header-height-mobile);
    right: 0;
    bottom: 0;
    left: auto;
    width: 280px;
    max-width: 86vw;
    flex: none;
    justify-content: space-between;
    gap: 24px;
    padding: 26px 22px;
    background:
      repeating-linear-gradient(180deg, rgba(155, 107, 255, 0.05) 0px, rgba(155, 107, 255, 0.05) 1px, transparent 1px, transparent 5px),
      var(--color-space-deep);
    border-left: 1px solid rgba(155, 107, 255, 0.28);
    box-shadow: -20px 0 48px rgba(0, 0, 0, 0.45);
    transform: translateX(105%);
    transition: transform 0.35s ease;
    overflow-y: auto;
    z-index: 120;
  }

  .site-header__nav[data-open] {
    transform: translateX(0);
  }

  .nav__list {
    gap: 4px;
  }

  .nav__link {
    flex-direction: row;
    justify-content: flex-start;
    align-items: center;
    gap: 14px;
    padding: 13px 16px;
    text-align: left;
  }

  .nav__index {
    width: 26px;
    flex-shrink: 0;
    font-size: 12px;
  }

  .nav__label {
    font-size: 15px;
    letter-spacing: 0.08em;
  }

  .nav__link[aria-current="page"]::before {
    left: 0;
    top: 10px;
    bottom: 10px;
  }

  .nav__link[aria-current="page"]::after {
    right: 12px;
    bottom: auto;
    top: 50%;
    transform: translateY(-50%);
  }

  .header__status {
    width: 100%;
  }

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

  .back-top {
    right: 16px;
    bottom: 16px;
    width: 40px;
    height: 40px;
    font-size: 18px;
  }

  .scroll-progress {
    width: 2px;
  }
}

.site-footer {
  position: relative;
  margin-top: 96px;
  background:
    radial-gradient(900px 300px at 50% 0%, rgba(108, 43, 244, 0.12) 0%, transparent 60%),
    var(--color-space-deep);
  border-top: 1px solid rgba(155, 107, 255, 0.14);
  color: var(--color-silver);
}

.site-footer::before {
  content: "";
  position: absolute;
  top: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: linear-gradient(90deg, transparent 0%, var(--color-violet) 30%, var(--color-green) 75%, transparent 100%);
  opacity: 0.85;
}

.site-footer__grid {
  display: grid;
  grid-template-columns: 1.3fr 1fr 1.2fr;
  gap: 48px;
  padding: 72px 0 48px;
}

.footer__column {
  display: flex;
  flex-direction: column;
  gap: 12px;
  min-width: 0;
}

.brand__link--footer {
  flex-direction: row;
  gap: 9px;
  margin-bottom: 6px;
}

.brand__link--footer .brand__mark {
  font-size: 28px;
}

.brand__link--footer .brand__text {
  font-size: 12px;
  letter-spacing: 0.2em;
}

.footer__domain {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--color-violet-soft);
  margin-bottom: 4px;
}

.footer__icp {
  font-family: var(--font-mono);
  font-size: 13px;
  color: var(--color-silver);
  margin-bottom: 4px;
}

.footer__address {
  font-size: 13px;
  color: var(--color-silver);
  line-height: 1.6;
  margin: 0;
}

.footer__heading {
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.18em;
  color: var(--color-white);
  text-transform: uppercase;
  margin-bottom: 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(155, 107, 255, 0.16);
}

.footer__list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer__list a {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  color: var(--color-silver);
  transition: color 0.2s ease, transform 0.2s ease;
}

.footer__list a::before {
  content: "";
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: var(--color-violet-soft);
  transition: background 0.2s ease;
}

.footer__list a:hover {
  color: var(--color-green);
  transform: translateX(4px);
}

.footer__list a:hover::before {
  background: var(--color-green);
  box-shadow: 0 0 6px rgba(57, 255, 20, 0.5);
}

.footer__mail,
.footer__phone,
.footer__hours {
  font-size: 14px;
  color: var(--color-silver);
  margin: 0;
}

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

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

.footer__update {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--color-green);
  margin: 8px 0 0;
}

.status__dot--footer {
  width: 6px;
  height: 6px;
}

.footer__decor {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 32px 0 6px;
}

.footer__decor-line {
  height: 1px;
  flex: 1;
  background: linear-gradient(90deg, transparent 0%, rgba(155, 107, 255, 0.45) 50%, transparent 100%);
}

.footer__decor-label {
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.3em;
  color: rgba(155, 107, 255, 0.5);
  white-space: nowrap;
}

.footer__bottom {
  margin-top: 24px;
  border-top: 1px solid rgba(155, 107, 255, 0.12);
  background: rgba(0, 0, 0, 0.25);
  padding: 22px 0;
}

.footer__bottom-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.footer__bottom p {
  font-size: 13px;
  color: var(--color-silver);
  margin: 0;
}

.section-kicker {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-family: var(--font-mono);
  font-size: 13px;
  letter-spacing: 0.2em;
  color: var(--color-green);
  text-transform: uppercase;
  margin-bottom: 18px;
}

.section-kicker::before {
  content: attr(data-index);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 34px;
  padding: 3px 10px;
  border: 1px solid rgba(155, 107, 255, 0.35);
  border-radius: 5px;
  background: rgba(108, 43, 244, 0.25);
  color: var(--color-gold);
  font-size: 12px;
  font-weight: 700;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 14px 30px;
  border: 1px solid transparent;
  border-radius: 6px;
  background: transparent;
  font-family: var(--font-body);
  font-size: 15px;
  font-weight: 600;
  color: var(--color-white);
  line-height: 1;
  cursor: pointer;
  text-decoration: none;
  transition: all 0.25s ease;
}

.btn--primary {
  background: linear-gradient(135deg, var(--color-violet) 0%, var(--color-violet-soft) 100%);
  color: #fff;
  box-shadow: 0 8px 24px rgba(108, 43, 244, 0.35);
}

.btn--primary:hover {
  filter: brightness(1.12);
  box-shadow: 0 8px 36px rgba(155, 107, 255, 0.5);
  color: #fff;
}

.btn--ghost {
  border-color: rgba(160, 174, 192, 0.4);
  color: var(--color-white);
}

.btn--ghost:hover {
  border-color: var(--color-green);
  color: var(--color-green);
  box-shadow: inset 0 0 20px rgba(57, 255, 20, 0.06);
}

.photo-frame {
  position: relative;
  display: block;
  overflow: hidden;
  border-radius: 12px;
  background: linear-gradient(135deg, rgba(108, 43, 244, 0.2) 0%, rgba(155, 107, 255, 0.06) 100%);
  border: 1px solid rgba(155, 107, 255, 0.16);
}

.photo-frame::before {
  content: "";
  display: block;
  padding-top: 56.25%;
}

.photo-frame > img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo-frame--ratio-4-3::before {
  padding-top: 75%;
}

.photo-frame--ratio-1-1::before {
  padding-top: 100%;
}

.note-aside {
  position: relative;
  font-size: 13px;
  line-height: 1.7;
  color: var(--color-silver);
  border-left: 2px solid var(--color-violet);
  padding-left: 16px;
  margin: 20px 0;
}

.note-aside::before {
  content: "注";
  font-family: var(--font-mono);
  font-size: 11px;
  color: var(--color-green);
  letter-spacing: 0.1em;
  margin-right: 6px;
}

.article-index {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
}

.article-index__item {
  margin: 0;
}

.article-index__item a {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 20px;
  padding: 14px 0;
  font-size: 15px;
  color: var(--color-white);
  border-bottom: 1px solid rgba(155, 107, 255, 0.16);
  transition: color 0.2s ease, padding-left 0.2s ease, border-color 0.2s ease;
}

.article-index__item a:hover {
  color: var(--color-green);
  padding-left: 8px;
  border-bottom-color: rgba(57, 255, 20, 0.4);
}

.article-index__item a::after {
  content: attr(data-meta);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--color-silver);
  white-space: nowrap;
}

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

.data-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 3px 10px;
  border: 1px solid rgba(57, 255, 20, 0.25);
  border-radius: 5px;
  background: rgba(57, 255, 20, 0.07);
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--color-green);
  letter-spacing: 0.06em;
}

[data-reveal].is-pre {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

[data-reveal].is-revealed {
  opacity: 1;
  transform: none;
}

@media (max-width: 960px) {
  .site-footer__grid {
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    padding: 56px 0 40px;
  }

  .footer__contact {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .container {
    width: min(100% - 32px, var(--content-max));
  }

  .site-footer__grid {
    grid-template-columns: 1fr;
    gap: 36px;
    padding: 48px 0 32px;
  }

  .footer__contact {
    grid-column: auto;
  }

  .footer__decor {
    padding-top: 24px;
  }

  .footer__bottom-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .btn {
    width: 100%;
  }
}

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

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

  .scroll-progress::before {
    transition: none;
  }

  .status__dot,
  .status__dot--footer {
    animation: none;
  }

  .back-top:hover {
    transform: none;
  }

  [data-reveal].is-pre {
    opacity: 1;
    transform: none;
    transition: none;
  }
}
