/* ==========================================================================
   开全服务 · 共享站点样式 /assets/site.css
   框架式导航 · 海报分层 · 入口—索引—归档
   ========================================================================== */

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

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

body {
  margin: 0;
  padding-left: var(--rail-w);
  padding-top: var(--topbar-h);
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16.5px;
  font-weight: 400;
  line-height: 1.75;
  letter-spacing: 0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  margin: 0 0 0.6em;
  font-family: var(--font-display);
  font-weight: 900;
  line-height: 1.18;
  letter-spacing: -0.005em;
}

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }

ul, ol { margin: 0; padding: 0; }

a { color: inherit; }

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

button { font: inherit; color: inherit; }

::selection { background: var(--cyan); color: #05203a; }

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

/* --------------------------------------------------------------------------
   设计令牌
   -------------------------------------------------------------------------- */
:root {
  /* 色彩 */
  --blue: #1F4FD8;
  --blue-deep: #173EB0;
  --ink-900: #0B1533;
  --ink-800: #101C3D;
  --ink-700: #16244A;
  --cyan: #2BD4C8;
  --cyan-soft: #A8F0EA;
  --orange: #FF7A3D;
  --orange-soft: #FFF1E8;
  --fog-50: #F4F6FB;
  --fog-100: #E3E8F5;
  --slate: #7C8AAE;

  /* 语义主题变量（浅色页面用 body.is-fog 覆盖） */
  --bg: #0B1533;
  --text: #F4F6FB;
  --text-muted: #9DAAC8;
  --panel: #101C3D;
  --line: rgba(31, 79, 216, 0.38);
  --line-soft: rgba(168, 240, 234, 0.16);

  /* 骨架尺寸 */
  --rail-w: 76px;
  --topbar-h: 54px;
  --gutter: clamp(18px, 4vw, 48px);
  --gap: clamp(20px, 2.6vw, 40px);

  /* 字体 */
  --font-display: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-body: "Noto Sans SC", "Source Han Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;

  /* 材质与动效 */
  --ease: cubic-bezier(.2, .7, .3, 1);
  --dur: 220ms;
  --shadow-sm: 0 2px 6px rgba(3, 9, 28, 0.38);
  --shadow-md: 0 6px 18px rgba(3, 9, 28, 0.42);
}

body.is-fog {
  --bg: #F4F6FB;
  --text: #0B1533;
  --text-muted: #5F6E92;
  --panel: #FFFFFF;
  --line: rgba(31, 79, 216, 0.22);
  --line-soft: rgba(31, 79, 216, 0.14);
  --shadow-sm: 0 2px 6px rgba(31, 79, 216, 0.08);
  --shadow-md: 0 6px 18px rgba(31, 79, 216, 0.12);
}

/* --------------------------------------------------------------------------
   工具类
   -------------------------------------------------------------------------- */
.wrap {
  width: min(100%, 1240px);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.section {
  padding-block: clamp(48px, 7vw, 96px);
}

.mono {
  font-family: var(--font-mono);
  font-size: 0.92em;
  letter-spacing: 0.04em;
  font-variant-numeric: tabular-nums;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.7em;
  margin: 0 0 0.9em;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--cyan);
}

.eyebrow::before {
  content: "";
  width: 26px;
  height: 1px;
  background: currentColor;
  flex: none;
}

.section-title {
  font-size: clamp(26px, 3.4vw, 40px);
  font-weight: 900;
  line-height: 1.14;
  margin: 0 0 0.5em;
  max-width: 22ch;
}

.lede {
  font-size: clamp(16px, 1.4vw, 18px);
  line-height: 1.8;
  color: var(--text-muted);
  max-width: 64ch;
}

.grid {
  display: grid;
  gap: var(--gap);
}

.grid--split {
  grid-template-columns: minmax(0, 7fr) minmax(0, 4fr);
  align-items: start;
}

.grid--thirds {
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}

/* 胶囊标签 */
.pill {
  display: inline-flex;
  align-items: center;
  gap: 0.35em;
  padding: 0.3em 0.62em;
  border: 1px solid currentColor;
  border-radius: 999px;
  font-size: 12px;
  line-height: 1.15;
  letter-spacing: 0.06em;
  white-space: nowrap;
}

.pill--cyan {
  color: var(--cyan);
  border-color: rgba(43, 212, 200, 0.5);
  background: rgba(43, 212, 200, 0.1);
}

.pill--orange {
  color: #7A2E08;
  border-color: rgba(255, 122, 61, 0.45);
  background: var(--orange-soft);
}

/* 按钮 */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  padding: 0.72em 1.15em;
  border: 1px solid transparent;
  border-radius: 2px;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 500;
  line-height: 1;
  letter-spacing: 0.05em;
  text-decoration: none;
  cursor: pointer;
  transition: transform var(--dur) var(--ease),
              background-color var(--dur) var(--ease),
              border-color var(--dur) var(--ease),
              color var(--dur) var(--ease),
              box-shadow var(--dur) var(--ease);
}

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

.btn--accent {
  background: var(--orange);
  border-color: var(--orange);
  color: #2A0E02;
  font-weight: 700;
  box-shadow: 0 0 0 0 rgba(255, 122, 61, 0.45);
}

.btn--accent:hover {
  background: #FF8F5B;
  border-color: #FF8F5B;
  box-shadow: 0 4px 14px rgba(255, 122, 61, 0.34);
}

.btn--blue {
  background: var(--blue);
  border-color: var(--blue);
  color: #FFFFFF;
  font-weight: 700;
}

.btn--blue:hover {
  background: var(--blue-deep);
  border-color: var(--blue-deep);
}

.btn--ghost {
  background: transparent;
  border-color: rgba(168, 240, 234, 0.34);
  color: var(--cyan-soft);
}

.btn--ghost:hover {
  border-color: var(--cyan);
  color: var(--cyan);
}

/* 面包屑 */
.breadcrumb {
  padding-block: 18px 0;
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: 0.06em;
  color: var(--text-muted);
}

.breadcrumb__list {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.6em;
  list-style: none;
}

.breadcrumb__item {
  display: inline-flex;
  align-items: center;
  gap: 0.6em;
}

.breadcrumb__item + .breadcrumb__item::before {
  content: "/";
  color: var(--blue);
  opacity: 0.7;
}

.breadcrumb a {
  text-decoration: none;
  color: inherit;
  border-bottom: 1px solid transparent;
  transition: color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}

.breadcrumb a:hover {
  color: var(--cyan);
  border-bottom-color: var(--cyan);
}

/* 图片容器基础规则 */
.media {
  position: relative;
  display: block;
  overflow: hidden;
  min-height: 180px;
  border: 1px solid var(--line);
  border-radius: 2px;
  background:
    repeating-linear-gradient(90deg, rgba(168, 240, 234, 0.07) 0 1px, transparent 1px 18px),
    linear-gradient(150deg, rgba(31, 79, 216, 0.28) 0%, rgba(16, 28, 61, 0.94) 62%, #0B1533 100%);
  box-shadow: var(--shadow-sm);
}

.media__img {
  display: block;
  width: 100%;
  height: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.media__cap {
  position: absolute;
  left: 0;
  bottom: 0;
  padding: 0.45em 0.75em;
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: 0.08em;
  color: var(--cyan-soft);
  background: rgba(9, 17, 40, 0.86);
  border-top: 1px solid rgba(43, 212, 200, 0.34);
  border-right: 1px solid rgba(43, 212, 200, 0.34);
}

/* 滚动渐显协议 */
html.has-js [data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity var(--dur) var(--ease), transform var(--dur) var(--ease);
}

html.has-js [data-reveal].is-visible {
  opacity: 1;
  transform: none;
}

/* --------------------------------------------------------------------------
   跳转链接
   -------------------------------------------------------------------------- */
.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 400;
  padding: 0.78em 1.1em;
  border-radius: 2px;
  background: var(--cyan);
  color: #052A2B;
  font-family: var(--font-body);
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-decoration: none;
  transform: translateY(-180%);
  transition: transform var(--dur) var(--ease);
}

.skip-link:focus-visible { transform: translateY(0); }

/* --------------------------------------------------------------------------
   头部：框架式导航
   -------------------------------------------------------------------------- */
.site-header {
  position: relative;
  z-index: 120;
}

/* 左侧竖向索引栏 —— 导航即页面边框 */
.rail {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 130;
  width: var(--rail-w);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 16px 0 14px;
  background:
    repeating-linear-gradient(180deg, rgba(168, 240, 234, 0.05) 0 1px, transparent 1px 26px),
    linear-gradient(180deg, #0B1533 0%, #0E1A3E 55%, #0B1533 100%);
  border-right: 1px solid rgba(31, 79, 216, 0.62);
  overflow-y: auto;
  scrollbar-width: none;
}

.rail::-webkit-scrollbar { width: 0; }

.rail__brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  width: 100%;
  padding: 6px 0 16px;
  text-decoration: none;
  color: var(--fog-50);
  border-bottom: 1px solid rgba(31, 79, 216, 0.42);
}

.rail__brand-text {
  writing-mode: vertical-rl;
  text-orientation: upright;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 900;
  letter-spacing: 0.18em;
  line-height: 1;
}

.rail__brand-dot {
  width: 6px;
  height: 6px;
  flex: none;
  background: var(--cyan);
  border-radius: 50%;
  box-shadow: 0 0 10px rgba(43, 212, 200, 0.9);
}

.rail__brand:hover .rail__brand-text { color: var(--cyan-soft); }

.rail__nav {
  width: 100%;
  display: flex;
  flex-direction: column;
  flex: 1 1 auto;
}

.rail__list {
  list-style: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  padding: 8px 0 0;
}

.rail__list > li { width: 100%; }

.rail__link {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 7px;
  width: 100%;
  padding: 12px 2px;
  text-decoration: none;
  color: rgba(244, 246, 251, 0.76);
  transition: background-color var(--dur) var(--ease), color var(--dur) var(--ease);
}

.rail__num {
  font-family: var(--font-mono);
  font-size: 9.5px;
  letter-spacing: 0.1em;
  color: var(--cyan);
  opacity: 0.9;
  line-height: 1;
}

.rail__label {
  writing-mode: vertical-rl;
  text-orientation: upright;
  font-family: var(--font-display);
  font-size: 12.5px;
  font-weight: 500;
  letter-spacing: 0.16em;
  line-height: 1;
}

.rail__link:hover {
  background: rgba(31, 79, 216, 0.3);
  color: #FFFFFF;
}

.rail__link[aria-current="page"] {
  background: var(--blue);
  color: #FFFFFF;
  box-shadow: inset -3px 0 0 var(--cyan);
}

.rail__link[aria-current="page"] .rail__num { color: var(--cyan-soft); opacity: 1; }

.rail__foot {
  display: none;
  margin: 0;
  font-size: 11px;
  color: var(--slate);
  letter-spacing: 0.06em;
}

.rail__mark {
  margin: auto 0 0;
  padding-top: 16px;
  writing-mode: vertical-rl;
  font-size: 10px;
  letter-spacing: 0.14em;
  color: var(--slate);
}

/* 顶部窄条 */
.topbar {
  position: fixed;
  top: 0;
  left: var(--rail-w);
  right: 0;
  z-index: 125;
  height: var(--topbar-h);
  display: flex;
  align-items: center;
  gap: clamp(12px, 2vw, 24px);
  padding-inline: clamp(16px, 2.6vw, 34px);
  background: rgba(11, 21, 51, 0.93);
  border-bottom: 1px solid rgba(31, 79, 216, 0.42);
  backdrop-filter: blur(12px) saturate(1.15);
  -webkit-backdrop-filter: blur(12px) saturate(1.15);
}

.topbar__brand {
  display: none;
  font-family: var(--font-display);
  font-size: 17px;
  font-weight: 900;
  letter-spacing: 0.1em;
  color: var(--fog-50);
  text-decoration: none;
  white-space: nowrap;
}

.topbar__meta {
  display: flex;
  align-items: center;
  gap: 0.7em;
  margin: 0;
  font-size: 13px;
  color: rgba(244, 246, 251, 0.82);
  letter-spacing: 0.04em;
  white-space: nowrap;
}

.topbar__meta-text {
  font-weight: 500;
  letter-spacing: 0.06em;
}

.topbar__note {
  margin: 0 0 0 auto;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: 0.05em;
  color: var(--slate);
  white-space: nowrap;
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: none;
}

.topbar__progress {
  position: absolute;
  left: 0;
  bottom: -1px;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, var(--cyan) 0%, var(--blue) 100%);
  transform: scaleX(0);
  transform-origin: 0 50%;
  transition: transform 90ms linear;
  pointer-events: none;
}

/* 汉堡按钮 */
.nav-toggle {
  display: none;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 5px;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid rgba(168, 240, 234, 0.3);
  border-radius: 2px;
  background: rgba(31, 79, 216, 0.2);
  color: var(--fog-50);
  cursor: pointer;
  transition: background-color var(--dur) var(--ease), border-color var(--dur) var(--ease);
}

.nav-toggle:hover { background: rgba(31, 79, 216, 0.42); }

.nav-toggle__bar {
  display: block;
  width: 18px;
  height: 2px;
  background: currentColor;
  transition: transform var(--dur) var(--ease), opacity 160ms var(--ease);
}

.nav-toggle[aria-expanded="true"] {
  background: var(--blue);
  border-color: var(--blue);
}

.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] .nav-toggle__bar:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* --------------------------------------------------------------------------
   页脚：归档库
   -------------------------------------------------------------------------- */
.site-footer {
  position: relative;
  margin-top: clamp(48px, 7vw, 96px);
  padding-block: clamp(44px, 6vw, 76px) 26px;
  background: linear-gradient(180deg, #0A1430 0%, #0B1533 55%, #091026 100%);
  color: var(--fog-50);
  border-top: 1px solid rgba(31, 79, 216, 0.55);
  overflow: hidden;
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 128px;
  background: repeating-linear-gradient(
    90deg,
    rgba(43, 212, 200, 0.16) 0 1px,
    transparent 1px 15px
  );
  -webkit-mask-image: linear-gradient(180deg, #000 0%, transparent 100%);
  mask-image: linear-gradient(180deg, #000 0%, transparent 100%);
  pointer-events: none;
}

.site-footer > * { position: relative; z-index: 1; }

.footer__inner {
  display: grid;
  grid-template-columns: minmax(260px, 1fr) minmax(0, 1.45fr);
  gap: clamp(28px, 4vw, 64px);
  align-items: start;
}

.footer__lead { min-width: 0; }

.footer__logo {
  margin: 0 0 0.35em;
  font-family: var(--font-display);
  font-size: clamp(26px, 3.4vw, 36px);
  font-weight: 900;
  letter-spacing: 0.06em;
  line-height: 1.1;
  color: #FFFFFF;
}

.footer__tagline {
  display: flex;
  align-items: center;
  gap: 0.6em;
  margin: 0 0 1.1em;
  font-size: 13.5px;
  letter-spacing: 0.05em;
  color: rgba(244, 246, 251, 0.78);
}

.footer__contact {
  margin: 0;
  max-width: 34ch;
  font-size: 13px;
  line-height: 1.95;
  color: var(--slate);
}

.footer__cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(18px, 2.4vw, 32px);
}

.footer__col { min-width: 0; }

.footer__col-title {
  margin: 0 0 1em;
  padding-left: 12px;
  position: relative;
  font-family: var(--font-body);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: rgba(244, 246, 251, 0.92);
}

.footer__col-title::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.32em;
  width: 5px;
  height: 5px;
  background: var(--cyan);
}

.footer__links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.7em;
}

.footer__links a {
  display: inline-block;
  font-size: 14px;
  letter-spacing: 0.03em;
  color: rgba(244, 246, 251, 0.72);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: color var(--dur) var(--ease),
              transform var(--dur) var(--ease),
              border-color var(--dur) var(--ease);
}

.footer__links a:hover {
  color: var(--cyan);
  border-bottom-color: rgba(43, 212, 200, 0.6);
  transform: translateX(2px);
}

.footer__base {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px 24px;
  margin-top: clamp(32px, 4vw, 52px);
  padding-top: 18px;
  border-top: 1px solid rgba(31, 79, 216, 0.4);
}

.footer__legal,
.footer__host {
  margin: 0;
  font-size: 12px;
  letter-spacing: 0.05em;
  color: var(--slate);
}

.footer__host { color: rgba(124, 138, 174, 0.85); }

/* --------------------------------------------------------------------------
   响应式
   -------------------------------------------------------------------------- */
@media (max-width: 1023px) {
  :root {
    --rail-w: 0px;
    --topbar-h: 60px;
  }

  body.is-nav-open { overflow: hidden; }

  /* 左侧栏在移动端退化为导航抽屉 */
  .rail { display: contents; }

  .rail__brand,
  .rail__mark { display: none; }

  .rail__nav {
    position: fixed;
    left: 0;
    right: 0;
    top: var(--topbar-h);
    bottom: 0;
    z-index: 126;
    display: flex;
    flex-direction: column;
    padding: 20px var(--gutter) 40px;
    background:
      repeating-linear-gradient(180deg, rgba(168, 240, 234, 0.045) 0 1px, transparent 1px 26px),
      #0A1430;
    border-top: 1px solid rgba(31, 79, 216, 0.5);
    overflow-y: auto;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-12px);
    transition: opacity var(--dur) var(--ease),
                transform var(--dur) var(--ease),
                visibility var(--dur) var(--ease);
  }

  .rail__nav[data-open="true"] {
    opacity: 1;
    visibility: visible;
    transform: none;
  }

  .rail__list {
    flex: none;
    align-items: stretch;
    padding: 0;
  }

  .rail__link {
    flex-direction: row;
    align-items: center;
    justify-content: flex-start;
    gap: 18px;
    width: 100%;
    padding: 17px 4px;
    border-bottom: 1px solid rgba(31, 79, 216, 0.22);
  }

  .rail__num {
    width: 2.4em;
    flex: none;
    font-size: 11px;
  }

  .rail__label {
    writing-mode: horizontal-tb;
    text-orientation: mixed;
    font-size: 20px;
    font-weight: 800;
    letter-spacing: 0.06em;
  }

  .rail__link[aria-current="page"] {
    background: transparent;
    color: var(--cyan);
    box-shadow: inset 3px 0 0 var(--cyan);
    padding-left: 14px;
  }

  .rail__foot {
    display: block;
    margin-top: auto;
    padding-top: 26px;
    font-size: 11px;
    letter-spacing: 0.06em;
  }

  .topbar__brand { display: inline-block; }
  .topbar__meta-text { display: none; }
  .topbar__note { display: none; }
  .topbar__actions { margin-left: auto; }
  .nav-toggle { display: flex; }
}

@media (max-width: 899px) {
  .footer__inner {
    grid-template-columns: minmax(0, 1fr);
  }

  .footer__contact { max-width: none; }
}

@media (max-width: 639px) {
  body { font-size: 16px; }

  .topbar { padding-inline: 14px; gap: 10px; }

  .topbar .btn--accent {
    padding: 0.62em 0.85em;
    font-size: 13px;
  }

  .footer__cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 22px 18px;
  }

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

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

  .section-title { max-width: none; }
}

@media (max-width: 379px) {
  .footer__cols { grid-template-columns: minmax(0, 1fr); }
}

/* --------------------------------------------------------------------------
   可访问性与降级
   -------------------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }

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

  .btn:hover,
  .footer__links a:hover { transform: none; }

  html.has-js [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
  }

  .rail__nav {
    transform: none !important;
  }

  .topbar__progress { transition: none !important; }
}
