@import url('https://fonts.googleapis.com/css2?family=Nunito+Sans:wght@300;400;500;600;700&family=Rubik:wght@300;400;500;600;700&display=swap');

:root {
  --ink: #1f1f1f;
  --paper: #ffffff;
  --mist: #f5f5f5;
  --line: #e8e8e8;
  --muted: #5d5d5d;
  --r: 28px;
  --shadow-sm: 0 4px 6px rgba(0, 0, 0, .05);
  --shadow-lg: 0 4px 6px rgba(0, 0, 0, .05), 0 20px 44px -26px rgba(0, 0, 0, .3);
  --font-body: 'Nunito Sans', system-ui, -apple-system, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --font-head: 'Rubik', 'Nunito Sans', system-ui, -apple-system, 'Segoe UI', 'PingFang SC', 'Microsoft YaHei', sans-serif;
}

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

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

body {
  margin: 0;
  overflow-x: clip;
  background: var(--mist);
  color: var(--ink);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.75;
  font-weight: 400;
  padding-bottom: 104px;
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--ink);
  text-decoration-color: #c9c9c9;
  text-underline-offset: 3px;
}

a:hover {
  text-decoration-color: var(--ink);
}

:focus-visible {
  outline: 3px solid #1f1f1f;
  outline-offset: 3px;
  border-radius: 6px;
}

h1,
h2,
h3,
h4 {
  font-family: var(--font-head);
  font-weight: 600;
  letter-spacing: -.02em;
  line-height: 1.18;
  margin: 0 0 .5em;
}

p {
  margin: 0 0 1.05em;
}

ul,
ol {
  margin: 0 0 1.05em;
  padding-left: 1.35em;
}

li {
  margin-bottom: .4em;
}

/* ---------- 底部固定胶囊导航 ---------- */
.dock {
  position: fixed;
  left: 12px;
  right: 12px;
  bottom: 12px;
  z-index: 60;
  max-width: 1120px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px;
  border-radius: 999px;
  background: rgba(255, 255, 255, .92);
  box-shadow: 0 6px 12px rgba(0, 0, 0, .06), 0 24px 48px -28px rgba(0, 0, 0, .45);
  backdrop-filter: saturate(160%) blur(14px);
  border: 1px solid rgba(0, 0, 0, .05);
}

.dock-brand {
  flex: 0 0 auto;
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--mist);
  font-family: var(--font-head);
  font-weight: 600;
  font-size: 1.1rem;
  text-decoration: none;
  overflow: hidden;
}

.dock-brand img {
  width: 26px;
  height: 26px;
  object-fit: contain;
}

.dock-nav {
  flex: 1 1 auto;
  min-width: 0;
  overflow-x: auto;
  scrollbar-width: none;
}

.dock-nav::-webkit-scrollbar {
  display: none;
}

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

.dock-list li {
  margin: 0;
}

.dock-list a {
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  padding: 0 15px;
  border-radius: 999px;
  font-size: .95rem;
  font-weight: 500;
  white-space: nowrap;
  text-decoration: none;
  color: #3a3a3a;
  transition: background-color .25s ease, color .25s ease;
}

.dock-list a:hover,
.dock-list a.is-active {
  background: var(--mist);
  color: var(--ink);
}

.dock-cta {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  min-height: 46px;
  padding: 0 22px;
  border-radius: 999px;
  background: var(--ink);
  color: #fff;
  font-weight: 600;
  font-size: .95rem;
  text-decoration: none;
  transition: transform .25s ease, background-color .25s ease;
}

.dock-cta:hover {
  transform: scale(1.03);
  background: #000;
}

/* ---------- 首屏 ---------- */
.hero {
  position: relative;
  overflow: hidden;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: clamp(24px, 5vh, 56px);
  padding: clamp(56px, 10vh, 104px) clamp(18px, 5vw, 60px) clamp(24px, 5vh, 44px);
  background: var(--paper);
  border-bottom-left-radius: 40px;
  border-bottom-right-radius: 40px;
  box-shadow: var(--shadow-sm);
}

.hero-bg {
  position: absolute;
  top: clamp(6px, 4vh, 44px);
  left: clamp(10px, 3vw, 36px);
  right: 0;
  font-family: var(--font-head);
  font-weight: 700;
  font-size: clamp(3.6rem, 17vw, 15rem);
  line-height: .86;
  letter-spacing: -.055em;
  color: #eeeeee;
  white-space: nowrap;
  pointer-events: none;
  user-select: none;
}

.hero-stack {
  position: relative;
  z-index: 1;
  max-width: 900px;
  margin-top: auto;
}

.hero-title {
  font-size: clamp(2.15rem, 6.6vw, 4.6rem);
  font-weight: 700;
  line-height: 1.04;
  letter-spacing: -.035em;
  max-width: 15em;
  margin-bottom: .38em;
  text-wrap: balance;
}

.hero-lead {
  max-width: 44ch;
  color: var(--muted);
  font-size: clamp(1rem, 1.6vw, 1.1rem);
  margin-bottom: 1.5em;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.btn {
  display: inline-flex;
  align-items: center;
  min-height: 50px;
  padding: 0 26px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 1rem;
  text-decoration: none;
  transition: transform .25s ease, background-color .25s ease, box-shadow .25s ease;
}

.btn-solid {
  background: var(--ink);
  color: #fff;
  box-shadow: var(--shadow-sm);
}

.btn-solid:hover {
  transform: scale(1.03);
  background: #000;
}

.btn-ghost {
  background: #fff;
  color: var(--ink);
  border: 1px solid var(--line);
}

.btn-ghost:hover {
  transform: scale(1.03);
  background: var(--mist);
}

.hero-figure {
  position: relative;
  z-index: 1;
  margin: 0;
}

.hero-img {
  width: 100%;
  height: clamp(170px, 30vh, 360px);
  object-fit: cover;
  border-radius: var(--r);
  box-shadow: var(--shadow-lg);
}

/* ---------- 主体网格 ---------- */
.wrap {
  max-width: 1180px;
  margin: 0 auto;
  padding: clamp(26px, 5vw, 56px) clamp(14px, 4vw, 40px) 0;
}

.shell {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: clamp(14px, 2vw, 22px);
  align-items: start;
}

/* ---------- 右侧目录卡 ---------- */
.rail {
  background: var(--paper);
  border-radius: var(--r);
  padding: 22px;
  box-shadow: var(--shadow-sm);
}

.rail-h {
  font-size: 1.05rem;
  margin-bottom: .2em;
}

.subtitle {
  color: #8a8a8a;
  font-size: .85rem;
  letter-spacing: .04em;
  margin-bottom: 1em;
}

.rail-list {
  list-style: none;
  margin: 0 0 12px;
  padding: 0;
  display: flex;
  gap: 8px;
  overflow-x: auto;
  scrollbar-width: none;
}

.rail-list::-webkit-scrollbar {
  display: none;
}

.rail-list li {
  margin: 0;
}

.rail-list a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 15px;
  border-radius: 999px;
  background: var(--mist);
  font-size: .92rem;
  text-decoration: none;
  white-space: nowrap;
  transition: background-color .25s ease, transform .25s ease;
}

.rail-list a:hover {
  background: #ececec;
  transform: scale(1.03);
}

.to-top {
  width: 100%;
  min-height: 46px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: .95rem;
  cursor: pointer;
  transition: background-color .25s ease;
}

.to-top:hover {
  background: var(--mist);
}

/* ---------- 正文卡 ---------- */
.prose {
  counter-reset: sec;
  min-width: 0;
}

.prose > section {
  background: var(--paper);
  border-radius: var(--r);
  padding: clamp(22px, 4vw, 44px);
  margin-bottom: clamp(14px, 2vw, 22px);
  box-shadow: var(--shadow-sm);
  scroll-margin-top: 28px;
  transition: box-shadow .35s ease;
}

.prose > section:hover {
  box-shadow: var(--shadow-lg);
}

.prose > section::before {
  counter-increment: sec;
  content: counter(sec, decimal-leading-zero);
  display: block;
  font-family: var(--font-head);
  font-size: clamp(1.7rem, 4.5vw, 2.6rem);
  font-weight: 600;
  line-height: 1;
  letter-spacing: -.03em;
  color: #dedede;
  margin-bottom: .5rem;
}

.prose > section > h2:first-of-type,
.prose > section > h3:first-of-type {
  margin-top: 0;
}

.prose h2 {
  font-size: clamp(1.45rem, 3.2vw, 2.05rem);
  margin-top: 1.4em;
}

.prose h3 {
  font-size: clamp(1.15rem, 2.2vw, 1.4rem);
  margin-top: 1.3em;
}

.prose p,
.prose li {
  color: #2b2b2b;
}

.prose img {
  border-radius: 20px;
  margin: 1em 0;
  box-shadow: var(--shadow-sm);
}

.prose blockquote {
  margin: 1.3em 0;
  padding: 14px 20px;
  border-left: 3px solid var(--ink);
  background: var(--mist);
  border-radius: 0 18px 18px 0;
  color: #3a3a3a;
}

.prose blockquote p:last-child {
  margin-bottom: 0;
}

.prose table {
  width: 100%;
  border-collapse: collapse;
  font-size: .95rem;
  display: block;
  overflow-x: auto;
}

.prose th,
.prose td {
  border: 1px solid var(--line);
  padding: 10px 12px;
  text-align: left;
}

.prose pre {
  background: #1f1f1f;
  color: #f3f3f3;
  padding: 16px;
  border-radius: 18px;
  overflow-x: auto;
  font-size: .9rem;
}

.prose code {
  font-size: .92em;
}

.prose hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 2em 0;
}

/* ---------- 页脚 ---------- */
.foot {
  max-width: 1180px;
  margin: 0 auto;
  padding: clamp(26px, 5vw, 56px) clamp(14px, 4vw, 40px) 8px;
}

.foot-cta a {
  display: block;
  padding: clamp(30px, 7vw, 68px) 24px;
  border-radius: var(--r);
  background: var(--paper);
  box-shadow: var(--shadow-sm);
  text-align: center;
  text-decoration: none;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: clamp(1.5rem, 5vw, 2.6rem);
  letter-spacing: -.03em;
  transition: transform .3s ease, box-shadow .3s ease;
}

.foot-cta a:hover {
  transform: scale(1.02);
  box-shadow: var(--shadow-lg);
}

.foot-line {
  display: grid;
  justify-items: center;
  gap: 10px;
  padding: 26px 0 10px;
  text-align: center;
  font-size: .88rem;
  color: var(--muted);
}

.foot-line address {
  font-style: normal;
  font-weight: 600;
  color: var(--ink);
}

.foot-links {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 16px;
  justify-content: center;
}

.foot-links li {
  margin: 0;
}

.foot-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  text-decoration: none;
  color: var(--muted);
}

.foot-links a:hover {
  color: var(--ink);
}

.copy {
  margin: 0;
  color: #8a8a8a;
}

/* ---------- 滚动显现 ---------- */
.js .prose > section,
.js .rail {
  opacity: 0;
  transform: translateY(22px);
  transition: opacity .7s ease, transform .7s cubic-bezier(.2, .7, .3, 1), box-shadow .35s ease;
}

.js .prose > section.is-in,
.js .rail.is-in {
  opacity: 1;
  transform: none;
}

/* ---------- 断点 ---------- */
@media (min-width: 960px) {
  .shell {
    grid-template-columns: minmax(0, 1fr) 300px;
  }

  .rail {
    grid-column: 2;
    grid-row: 1;
    position: sticky;
    top: 24px;
  }

  .prose {
    grid-column: 1;
    grid-row: 1;
  }

  .rail-list {
    flex-direction: column;
    gap: 4px;
    overflow: visible;
    margin-bottom: 16px;
  }

  .rail-list a {
    width: 100%;
    padding: 0 14px;
  }
}

@media (max-width: 719px) {
  .dock-cta {
    display: none;
  }

  .hero {
    border-bottom-left-radius: 28px;
    border-bottom-right-radius: 28px;
  }
}

@media (max-width: 419px) {
  .dock-list a {
    padding: 0 12px;
    font-size: .9rem;
  }
}

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

  .js .prose > section,
  .js .rail {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .dock-cta:hover,
  .btn:hover,
  .foot-cta a:hover {
    transform: none;
  }
}

button[aria-expanded]{min-width:44px;min-height:44px}
