/* =========================================================
   博万中心 · 共享样式表 /assets/site.css
   1 Reset · 2 Tokens · 3 Base · 4 Header · 5 Footer
   6 Buttons · 7 Plates · 8 Layout · 9 Media · 10 Motion
   ========================================================= */

/* ---------- 1. Reset ---------- */
*,
*::before,
*::after { box-sizing: border-box; }

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

body { margin: 0; padding: 0; }

h1, h2, h3, h4, h5, h6, p, figure, blockquote, dl, dd { margin: 0; }

ul, ol { margin: 0; padding: 0; list-style: none; }

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

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

button { background: none; border: 0; }

table { border-collapse: collapse; width: 100%; }

/* ---------- 2. Tokens ---------- */
:root {
  --ink: #101519;
  --ink-soft: #1D252B;
  --paper: #F5F7F8;
  --blue: #0E7C9B;
  --blue-deep: #0A5C74;
  --blue-soft: #CBE6EF;
  --orange: #E4572E;
  --orange-deep: #B23A16;
  --shale: #3A4750;
  --line: #D5DCE0;
  --ice: #EDF3F6;
  --amber: #E0A63C;
  --white: #FFFFFF;

  --r-sm: 12px;
  --r-md: 18px;
  --r-lg: 28px;
  --pill: 999px;

  --header-h: 56px;
  --wrap: 1240px;
  --rail: 6px;

  --font-ui: "PingFang SC", "Hiragino Sans GB", "Source Han Sans SC",
             "Noto Sans CJK SC", "Microsoft YaHei", system-ui, -apple-system,
             "Segoe UI", sans-serif;
  --font-mono: ui-monospace, "SFMono-Regular", "JetBrains Mono", Menlo,
               Consolas, "Liberation Mono", "Courier New", monospace;

  --shadow-1: 0 10px 26px rgba(16, 21, 25, .07);
  --shadow-2: 0 20px 48px rgba(16, 21, 25, .13);
  --ease: cubic-bezier(.2, .7, .3, 1);
}

/* ---------- 3. Base ---------- */
html { scroll-behavior: smooth; }

body {
  padding-top: var(--header-h);
  background: var(--paper);
  color: var(--ink);
  font-family: var(--font-ui);
  font-size: 16.5px;
  line-height: 1.75;
  letter-spacing: .01em;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* 框架左脊：导航成为页面视觉边框的一部分 */
body::before {
  content: "";
  position: fixed;
  top: 0;
  bottom: 0;
  left: 0;
  width: var(--rail);
  z-index: 79;
  pointer-events: none;
  background: linear-gradient(180deg, var(--blue) 0%, var(--blue-deep) 52%, var(--orange) 100%);
}

@media (min-width: 1100px) {
  body { padding-left: var(--rail); }
}

@media (max-width: 1099px) {
  body::before { display: none; }
}

main { display: block; }

#main-content { scroll-margin-top: calc(var(--header-h) + 20px); }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-ui);
  font-weight: 800;
  line-height: 1.16;
  letter-spacing: -.02em;
  color: var(--ink);
}

h1 { font-size: clamp(38px, 6.4vw, 84px); }
h2 { font-size: clamp(26px, 3.4vw, 38px); }
h3 { font-size: clamp(20px, 2vw, 24px); }
h4 { font-size: clamp(17px, 1.5vw, 19px); }

p { line-height: 1.75; }
p + p { margin-top: 1.05em; }

a {
  color: var(--blue-deep);
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}
a:hover { color: var(--blue); }

strong, b { font-weight: 700; }

small { font-size: 12.5px; }

::selection {
  background: var(--blue-soft);
  color: var(--ink);
}

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

.site-header :focus-visible,
.site-footer :focus-visible {
  outline-color: var(--blue-soft);
}

.skip-link {
  position: absolute;
  left: 14px;
  top: -120px;
  z-index: 200;
  padding: 10px 20px;
  background: var(--blue);
  color: #fff;
  font-size: 14px;
  text-decoration: none;
  border-radius: 0 0 var(--r-sm) var(--r-sm);
  transition: top .2s var(--ease);
}
.skip-link:focus { top: 0; color: #fff; }

/* ---------- 4. Header ---------- */
.site-header {
  position: fixed;
  top: 0;
  right: 0;
  bottom: auto;
  left: 0;
  z-index: 80;
  background: var(--ink);
  color: var(--ice);
  border-bottom: 1px solid rgba(213, 220, 224, .14);
}

@media (min-width: 1100px) {
  .site-header { left: var(--rail); }
}

.site-header__bar {
  display: flex;
  align-items: center;
  gap: clamp(8px, 1.4vw, 20px);
  max-width: var(--wrap);
  margin-inline: auto;
  min-height: var(--header-h);
  padding-inline: clamp(14px, 2.4vw, 28px);
}

/* brand */
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  flex: 0 0 auto;
  padding: 4px 4px;
  border-radius: var(--r-sm);
  text-decoration: none;
  color: inherit;
}

.brand__mark {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 10px;
  background: linear-gradient(145deg, var(--blue) 0%, var(--blue-deep) 72%);
  color: #fff;
  font-size: 14px;
  font-weight: 800;
  line-height: 1;
  box-shadow: 0 4px 14px rgba(14, 124, 155, .38);
}

.brand__text { display: flex; flex-direction: column; gap: 1px; }

.brand__name {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: .06em;
  line-height: 1.1;
  transition: color .2s var(--ease);
}
.brand:hover .brand__name { color: var(--blue-soft); }

.brand__sub {
  font-size: 10px;
  letter-spacing: .26em;
  line-height: 1.1;
  color: rgba(237, 243, 246, .55);
}

/* version plate */
.version-plate {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  flex: 0 0 auto;
  padding: 5px 12px;
  border-radius: var(--pill);
  border: 1px solid rgba(203, 230, 239, .26);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .08em;
  color: rgba(203, 230, 239, .78);
  white-space: nowrap;
}

.version-plate__key { font-size: 9.5px; letter-spacing: .16em; opacity: .72; }

.version-plate__val { color: #fff; font-weight: 700; }

/* nav */
.site-nav { flex: 1 1 auto; min-width: 0; }

.site-nav__head { display: none; }
.site-nav__foot { display: none; }

.site-nav__list {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-wrap: wrap;
}

.site-nav__list a {
  display: block;
  padding: 8px 12px;
  border-radius: var(--pill);
  border: 1px solid transparent;
  font-size: 14px;
  line-height: 1.3;
  white-space: nowrap;
  text-decoration: none;
  color: rgba(237, 243, 246, .76);
  transition: color .2s var(--ease), background-color .2s var(--ease),
              border-color .2s var(--ease);
}

.site-nav__list a:hover {
  color: #fff;
  background: rgba(203, 230, 239, .1);
  border-color: rgba(203, 230, 239, .26);
}

.site-nav__list a[aria-current="page"] {
  color: #fff;
  font-weight: 600;
  background: var(--blue);
  border-color: var(--blue);
}

/* edge cluster */
.site-header__edge {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: 0 0 auto;
  margin-left: auto;
}

.batch-flag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 5px 12px 5px 10px;
  border-radius: var(--pill);
  border: 1px solid rgba(213, 220, 224, .2);
  font-size: 12px;
  letter-spacing: .06em;
  color: rgba(237, 243, 246, .74);
  white-space: nowrap;
}

.batch-flag__dot {
  flex: 0 0 auto;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--orange);
  box-shadow: 0 0 0 3px rgba(228, 87, 46, .2);
}

/* toggle */
.nav-toggle {
  display: none;
  align-items: center;
  gap: 9px;
  padding: 7px 14px;
  border-radius: var(--pill);
  border: 1px solid rgba(203, 230, 239, .26);
  background: rgba(237, 243, 246, .06);
  color: var(--ice);
  font-size: 13px;
  letter-spacing: .08em;
  cursor: pointer;
  transition: background-color .2s var(--ease), border-color .2s var(--ease);
}

.nav-toggle:hover {
  background: rgba(203, 230, 239, .14);
  border-color: var(--blue-soft);
}

.nav-toggle__icon { display: grid; gap: 4px; width: 16px; }

.nav-toggle__icon span {
  display: block;
  height: 1.5px;
  border-radius: 2px;
  background: currentColor;
  transition: transform .22s var(--ease), opacity .22s var(--ease);
}

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

/* scroll progress */
.site-header__progress {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: 2px;
  transform: scaleX(0);
  transform-origin: 0 50%;
  background: linear-gradient(90deg, var(--blue) 0%, var(--blue-soft) 58%, var(--orange) 100%);
  pointer-events: none;
  transition: transform .12s linear;
}

/* mobile drawer */
@media (max-width: 1080px) {
  .nav-toggle { display: inline-flex; }

  .site-nav {
    position: fixed;
    top: var(--header-h);
    right: 0;
    z-index: 81;
    width: min(360px, 88vw);
    height: calc(100vh - var(--header-h));
    padding: 22px 20px 40px;
    overflow-y: auto;
    overscroll-behavior: contain;
    background: var(--ink-soft);
    border-left: 1px solid rgba(213, 220, 224, .16);
    box-shadow: -24px 0 60px rgba(16, 21, 25, .45);
    transform: translateX(102%);
    transition: transform .24s var(--ease);
  }

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

  .site-nav__head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 0 0 18px;
    padding: 12px 14px;
    border-radius: var(--r-md);
    background: rgba(14, 124, 155, .18);
    border: 1px solid rgba(203, 230, 239, .2);
  }

  .site-nav__ver {
    font-family: var(--font-mono);
    font-size: 14px;
    font-weight: 700;
    letter-spacing: .06em;
    color: #fff;
  }

  .site-nav__hint { font-size: 12px; color: rgba(203, 230, 239, .72); }

  .site-nav__list {
    flex-direction: column;
    align-items: stretch;
    gap: 6px;
  }

  .site-nav__list a {
    padding: 14px 16px;
    border-radius: var(--r-md);
    font-size: 16px;
    background: rgba(237, 243, 246, .04);
    border-color: rgba(213, 220, 224, .1);
  }

  .site-nav__foot {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 24px;
    padding-top: 20px;
    border-top: 1px solid rgba(213, 220, 224, .14);
  }

  .site-nav__pill {
    padding: 8px 14px;
    border-radius: var(--pill);
    border: 1px solid rgba(203, 230, 239, .22);
    font-size: 13px;
    text-decoration: none;
    color: rgba(237, 243, 246, .8);
  }
  .site-nav__pill:hover { color: #fff; border-color: var(--blue-soft); }

  main {
    transition: transform .24s var(--ease), opacity .24s var(--ease);
  }

  body[data-nav-open] main {
    transform: translateX(-24px);
    opacity: .62;
  }
}

@media (max-width: 560px) {
  .version-plate { display: none; }
  .batch-flag { display: none; }
}

/* ---------- 5. Footer ---------- */
.site-footer {
  position: relative;
  margin-top: clamp(56px, 9vw, 120px);
  background: var(--ink);
  color: var(--ice);
  overflow: hidden;
}

.site-footer::before {
  content: "";
  position: absolute;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(120% 82% at 6% 0%, rgba(14, 124, 155, .3), transparent 62%),
    linear-gradient(180deg, rgba(228, 87, 46, .1), transparent 40%);
}

.site-footer__inner {
  position: relative;
  max-width: var(--wrap);
  margin-inline: auto;
  padding: clamp(44px, 6vw, 80px) clamp(16px, 3vw, 32px) 30px;
}

.site-footer__top {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(30px, 4vw, 56px);
  padding-bottom: clamp(28px, 4vw, 44px);
  border-bottom: 1px solid rgba(213, 220, 224, .16);
}

@media (min-width: 900px) {
  .site-footer__top {
    grid-template-columns: minmax(0, 1.05fr) minmax(0, 1.6fr);
  }
}

.site-footer__logo {
  font-size: clamp(22px, 2.2vw, 26px);
  font-weight: 800;
  letter-spacing: .06em;
  line-height: 1.2;
  color: #fff;
}

.site-footer__tagline {
  margin-top: 14px;
  max-width: 34ch;
  font-size: 15px;
  line-height: 1.85;
  color: rgba(237, 243, 246, .68);
}

.site-footer__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 22px;
}

.site-footer__cols {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 26px;
}

@media (min-width: 620px) {
  .site-footer__cols { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.site-footer__col-title {
  margin-bottom: 14px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: .2em;
  color: rgba(203, 230, 239, .72);
}

.site-footer__list { display: grid; gap: 10px; }

.site-footer__list a {
  display: inline-block;
  padding-bottom: 1px;
  font-size: 14.5px;
  text-decoration: none;
  color: rgba(237, 243, 246, .84);
  border-bottom: 1px solid transparent;
  transition: color .2s var(--ease), border-color .2s var(--ease);
}

.site-footer__list a:hover {
  color: #fff;
  border-bottom-color: var(--orange);
}

.site-footer__muted { font-size: 14.5px; color: rgba(237, 243, 246, .4); }

.site-footer__bottom {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 24px;
  align-items: baseline;
  justify-content: space-between;
  padding-top: 24px;
  font-size: 12.5px;
  line-height: 1.9;
  color: rgba(237, 243, 246, .5);
}

.site-footer__bottom p { line-height: 1.9; }

.site-footer__bottom a {
  color: rgba(203, 230, 239, .82);
  text-decoration: none;
}
.site-footer__bottom a:hover { color: #fff; text-decoration: underline; }

.site-footer__contact {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .02em;
  font-variant-numeric: tabular-nums;
}

.site-footer__meta {
  font-family: var(--font-mono);
  font-size: 12px;
  letter-spacing: .04em;
}

.site-footer__sep { color: rgba(213, 220, 224, .28); }

/* ---------- 6. Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 11px 20px;
  border-radius: var(--pill);
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  text-decoration: none;
  cursor: pointer;
  transition: transform .2s var(--ease), background-color .2s var(--ease),
              border-color .2s var(--ease), color .2s var(--ease);
}

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

.btn--primary { background: var(--blue); color: #fff; }
.btn--primary:hover { background: var(--blue-deep); color: #fff; }

.btn--ghost {
  background: transparent;
  color: var(--ice);
  border-color: rgba(203, 230, 239, .3);
}
.btn--ghost:hover {
  color: #fff;
  border-color: var(--blue-soft);
  background: rgba(203, 230, 239, .1);
}

.btn--ink { background: var(--ink); color: #fff; }
.btn--ink:hover { background: var(--ink-soft); color: #fff; }

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

.btn[disabled],
.btn[aria-disabled="true"] {
  opacity: .5;
  pointer-events: none;
}

/* ---------- 7. Plates & annotations ---------- */
.plate {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 5px 12px;
  border-radius: var(--pill);
  border: 1px solid var(--line);
  background: var(--ice);
  font-size: 12px;
  letter-spacing: .06em;
  line-height: 1.5;
  color: var(--shale);
}

.plate--blue {
  background: var(--blue-soft);
  border-color: transparent;
  color: var(--blue-deep);
}

.plate--orange {
  background: rgba(228, 87, 46, .12);
  border-color: rgba(228, 87, 46, .34);
  color: var(--orange-deep);
}

.plate--ink {
  background: var(--ink);
  border-color: transparent;
  color: var(--ice);
}

.annotation {
  font-family: var(--font-mono);
  font-size: 11px;
  line-height: 1.6;
  letter-spacing: .3em;
  text-transform: uppercase;
  color: var(--shale);
}

.annotation--side {
  writing-mode: vertical-rl;
  text-orientation: mixed;
}

.annotation--onDark { color: rgba(203, 230, 239, .62); }

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

/* ---------- 8. Layout ---------- */
.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: clamp(16px, 3vw, 32px);
}

.wrap--narrow { max-width: 880px; }

.split {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(24px, 3.5vw, 56px);
}

@media (min-width: 980px) {
  .split { grid-template-columns: minmax(0, 62fr) minmax(0, 38fr); }
  .split--even { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .split--flip > :first-child { order: 2; }
}

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

@media (min-width: 760px) {
  .grid--2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (min-width: 1040px) {
  .grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

.stack > * + * { margin-top: var(--stack-gap, 18px); }

.hairline {
  height: 1px;
  border: 0;
  margin: var(--hairline-gap, 32px) 0;
  background: var(--line);
}

.card {
  display: block;
  padding: clamp(20px, 2.2vw, 26px);
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  background: var(--white);
  color: inherit;
  text-decoration: none;
  transition: transform .22s var(--ease), border-color .22s var(--ease),
              box-shadow .22s var(--ease);
}

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

.card--ink {
  background: var(--ink-soft);
  border-color: rgba(213, 220, 224, .14);
  color: var(--ice);
}
.card--ink:hover { border-color: var(--blue); box-shadow: var(--shadow-2); }

.card--flat { background: var(--ice); }
.card--flat:hover { background: var(--white); }

.card__title {
  font-size: clamp(20px, 1.9vw, 23px);
  font-weight: 800;
  letter-spacing: -.01em;
  line-height: 1.3;
}

.card__meta {
  margin-top: 6px;
  font-family: var(--font-mono);
  font-size: 11.5px;
  letter-spacing: .1em;
  color: var(--shale);
}

.card--ink .card__meta { color: rgba(203, 230, 239, .64); }

.card__body { margin-top: 12px; font-size: 15.5px; color: var(--shale); }
.card--ink .card__body { color: rgba(237, 243, 246, .72); }

.lede {
  font-size: clamp(17px, 1.4vw, 19px);
  line-height: 1.8;
  color: var(--shale);
}

.page-head { padding: clamp(28px, 5vw, 64px) 0 clamp(18px, 3vw, 34px); }

.page-head__kicker { display: block; margin-bottom: 14px; }

.page-head__title { font-size: clamp(32px, 5vw, 60px); }

.page-head__desc {
  margin-top: 16px;
  max-width: 62ch;
  font-size: 17px;
  line-height: 1.8;
  color: var(--shale);
}

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 12.5px;
  letter-spacing: .04em;
  color: var(--shale);
}

.breadcrumb a { color: var(--blue-deep); text-decoration: none; }
.breadcrumb a:hover { text-decoration: underline; }
.breadcrumb__sep { color: var(--line); }

.note-rail {
  position: sticky;
  top: calc(var(--header-h) + 28px);
  align-self: start;
}

.aside-note {
  padding: 20px;
  border-radius: var(--r-md);
  border: 1px solid var(--line);
  border-left: 3px solid var(--blue);
  background: var(--ice);
  font-size: 14.5px;
  line-height: 1.8;
  color: var(--shale);
}

.tag-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

/* ---------- 9. Media ---------- */
.figure { margin: 0; }

.media {
  position: relative;
  display: block;
  width: 100%;
  overflow: hidden;
  border-radius: var(--r-lg);
  border: 1px solid var(--line);
  background: linear-gradient(155deg, var(--blue-soft) 0%, var(--ice) 48%, var(--white) 100%);
  aspect-ratio: 16 / 10;
}

.media > img,
.media > svg,
.media > video {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.media--wide { aspect-ratio: 21 / 9; }
.media--tall { aspect-ratio: 4 / 5; }
.media--square { aspect-ratio: 1 / 1; }
.media--plain { background: var(--ice); }

.media__badge {
  position: absolute;
  left: 14px;
  bottom: 14px;
  padding: 5px 12px;
  border-radius: var(--pill);
  background: rgba(16, 21, 25, .82);
  color: var(--ice);
  font-family: var(--font-mono);
  font-size: 11px;
  letter-spacing: .08em;
}

.figure__caption {
  margin-top: 10px;
  font-size: 12px;
  line-height: 1.7;
  letter-spacing: .04em;
  color: var(--shale);
}

/* ---------- 10. Motion ---------- */
[data-reveal] {
  transition: opacity .55s var(--ease), transform .55s var(--ease);
}

html[data-observe] [data-reveal] {
  opacity: 0;
  transform: translateY(16px);
}

html[data-observe] [data-reveal].is-visible,
html[data-observe] [data-reveal]:focus-within {
  opacity: 1;
  transform: none;
}

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

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

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

  .btn:hover,
  .card:hover { transform: none; }

  body[data-nav-open] main { transform: none; opacity: 1; }
}
