@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;700;800&display=swap');

:root {
  --ink: #171f26;
  --ink-2: #4a5763;
  --blue: #c8e0f4;
  --rose: #f5e0e8;
  --bg-a: #eef3f9;
  --bg-b: #f8eff4;
  --lift: -5px -5px 15px rgba(255, 255, 255, 0.9), 5px 5px 15px rgba(23, 31, 38, 0.1);
  --lift-sm: -3px -3px 8px rgba(255, 255, 255, 0.9), 3px 3px 8px rgba(23, 31, 38, 0.12);
  --sink: inset -3px -3px 8px rgba(255, 255, 255, 0.9), inset 3px 3px 8px rgba(23, 31, 38, 0.1);
  --r: 16px;
  --card-r: 10px;
}

* {
  box-sizing: border-box;
}

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

body {
  margin: 0;
  padding-bottom: 20px;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  font-size: 17px;
  line-height: 1.75;
  color: var(--ink);
  background: linear-gradient(165deg, var(--bg-a) 0%, var(--bg-b) 52%, var(--bg-a) 100%);
  overflow-wrap: break-word;
}

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

a {
  color: #1e5b86;
  text-underline-offset: 3px;
}

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

:focus-visible {
  outline: 2px solid #2c6b98;
  outline-offset: 2px;
}

.skip {
  position: absolute;
  left: 14px;
  top: -70px;
  z-index: 70;
  padding: 10px 18px;
  border-radius: 12px;
  background: var(--blue);
  color: var(--ink);
  text-decoration: none;
  font-size: 15px;
  transition: top 0.18s ease;
}

.skip:focus {
  top: 10px;
}

/* 顶栏 */
.bar {
  position: sticky;
  top: 0;
  z-index: 40;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  padding: 9px 16px 10px;
  background: rgba(240, 245, 250, 0.9);
  backdrop-filter: blur(12px);
  border-radius: 0 0 20px 20px;
  box-shadow: 0 8px 22px rgba(23, 31, 38, 0.09);
}

.brand {
  flex: 1 0 100%;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 800;
  letter-spacing: 0.01em;
}

.brand-mark {
  border-radius: 9px;
}

.brand-txt {
  font-size: 17px;
  line-height: 1.2;
}

.bar-side {
  flex: 1 0 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.touch,
.burger,
.dock-close {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 9px;
  min-height: 44px;
  padding: 0 18px;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(145deg, #ffffff, #e6eef6);
  box-shadow: var(--lift-sm);
  color: var(--ink);
  font: inherit;
  font-size: 15.5px;
  font-weight: 600;
  text-decoration: none;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
}

.touch:active,
.burger:active,
.dock-close:active {
  transform: scale(0.97);
  box-shadow: var(--sink);
}

.burger-lines {
  position: relative;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
}

.burger-lines::before,
.burger-lines::after {
  content: '';
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  border-radius: 2px;
  background: var(--ink);
}

.burger-lines::before {
  top: -6px;
}

.burger-lines::after {
  top: 6px;
}

/* 全屏菜单 */
.dock {
  position: fixed;
  inset: 0;
  z-index: 60;
  margin: 0;
  padding: 18px 18px 34px;
  display: flex;
  flex-direction: column;
  gap: 16px;
  overflow-y: auto;
  background: linear-gradient(160deg, #e7eff8 0%, #f6ecf2 100%);
  opacity: 0;
  visibility: hidden;
  transform: translateY(-14px);
  transition: opacity 0.28s ease, transform 0.28s ease, visibility 0.28s;
}

.dock.open {
  opacity: 1;
  visibility: visible;
  transform: none;
}

.dock-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.dock-brand {
  font-weight: 800;
  font-size: 17px;
}

.dock-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.dock-nav a {
  display: flex;
  align-items: center;
  min-height: 52px;
  padding: 4px 20px;
  border-radius: 14px;
  background: linear-gradient(145deg, #fdfefe, #e8f0f7);
  box-shadow: var(--lift);
  color: var(--ink);
  text-decoration: none;
  font-size: 17px;
  font-weight: 600;
}

.dock-nav a:active {
  box-shadow: var(--sink);
  transform: scale(0.99);
}

/* 首屏 */
.hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(0, 1.15fr);
  align-items: stretch;
  gap: 18px;
  min-height: 45vh;
  margin: 14px 16px 0;
  padding: 24px 20px 38px;
  border-radius: 22px 22px 96px 96px;
  background: linear-gradient(150deg, var(--blue) 0%, #dbe6f5 48%, var(--rose) 100%);
  box-shadow: var(--lift);
  overflow: hidden;
}

.hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(23, 31, 38, 0.14) 1px, transparent 1px);
  background-size: 15px 15px;
  opacity: 0.65;
  pointer-events: none;
}

.hero-art {
  position: relative;
  z-index: 1;
  margin: 0;
  min-height: 150px;
  max-height: 260px;
  border-radius: var(--card-r);
  overflow: hidden;
  background: rgba(255, 255, 255, 0.42);
  box-shadow: var(--sink);
}

.hero-art img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hero-copy {
  position: relative;
  z-index: 1;
  align-self: end;
  text-align: right;
}

.hero h1 {
  margin: 0 0 10px;
  font-size: clamp(24px, 4.6vw, 40px);
  line-height: 1.24;
  font-weight: 800;
  letter-spacing: -0.01em;
}

.hero-desc {
  margin: 0;
  font-size: 15.5px;
  line-height: 1.7;
  color: var(--ink-2);
}

/* 主体：左栏 + 正文 */
.stage {
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  align-items: start;
  gap: 22px;
  max-width: 1180px;
  margin: 22px auto 0;
  padding: 0 16px 40px;
}

.rail {
  position: sticky;
  top: 124px;
  padding: 18px 15px;
  border-radius: var(--r);
  background: linear-gradient(145deg, #f4f8fc, #e5edf5);
  box-shadow: var(--lift);
}

.rail-kicker {
  display: block;
  font-size: 12.5px;
  font-weight: 700;
  letter-spacing: 0.14em;
  color: var(--ink-2);
}

.rail-title {
  margin: 2px 0 12px;
  font-size: 17px;
  line-height: 1.35;
  font-weight: 800;
}

.rail-nav ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 7px;
}

.rail-nav a {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 12px;
  border-radius: var(--card-r);
  color: var(--ink-2);
  text-decoration: none;
  font-size: 15.5px;
  line-height: 1.4;
  transition: box-shadow 0.15s ease, color 0.15s ease;
}

.rail-nav a:hover,
.rail-nav a:focus-visible {
  color: var(--ink);
  box-shadow: var(--sink);
}

.flow {
  min-width: 0;
  display: grid;
  gap: 18px;
}

.flow > div {
  scroll-margin-top: 132px;
  padding: 24px 22px;
  border-radius: var(--card-r);
  border: 1px solid rgba(255, 255, 255, 0.72);
  background: linear-gradient(145deg, rgba(255, 255, 255, 0.84), rgba(232, 239, 246, 0.7));
  backdrop-filter: blur(6px);
  box-shadow: var(--lift);
}

.flow > div > :first-child {
  margin-top: 0;
}

.flow > div > :last-child {
  margin-bottom: 0;
}

.flow h2 {
  margin: 0 0 12px;
  font-size: 22px;
  line-height: 1.35;
  font-weight: 800;
  letter-spacing: -0.005em;
}

.flow h3 {
  margin: 22px 0 10px;
  font-size: 18px;
  line-height: 1.4;
  font-weight: 700;
}

.flow p {
  margin: 0 0 13px;
}

.flow ul,
.flow ol {
  margin: 0 0 14px;
  padding-left: 22px;
}

.flow li {
  margin: 0 0 7px;
}

.flow figure {
  margin: 16px 0;
  padding: 10px;
  border-radius: var(--card-r);
  background: linear-gradient(145deg, #ffffff, #e9f0f7);
  box-shadow: var(--sink);
}

.flow figure img {
  border-radius: 8px;
}

.flow figcaption {
  margin-top: 8px;
  font-size: 14px;
  color: var(--ink-2);
}

.flow blockquote {
  margin: 16px 0;
  padding: 12px 16px;
  border-radius: var(--card-r);
  background: rgba(200, 224, 244, 0.34);
  box-shadow: var(--sink);
}

.flow table {
  width: 100%;
  border-collapse: collapse;
  margin: 14px 0;
  font-size: 15.5px;
}

.flow th,
.flow td {
  padding: 9px 11px;
  text-align: left;
  border-bottom: 1px solid rgba(23, 31, 38, 0.08);
}

.flow code {
  padding: 1px 5px;
  border-radius: 6px;
  background: rgba(23, 31, 38, 0.06);
  font-size: 15px;
}

.to-top {
  margin: 0;
  text-align: right;
}

.to-top a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 20px;
  border-radius: 12px;
  background: linear-gradient(145deg, #fdfefe, #e7eff6);
  box-shadow: var(--lift-sm);
  color: var(--ink);
  text-decoration: none;
  font-size: 15.5px;
  font-weight: 600;
}

.to-top a:active {
  box-shadow: var(--sink);
}

/* 页脚 */
.foot {
  max-width: 1180px;
  margin: 44px auto 0;
  padding: 30px 18px 38px;
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
  text-align: center;
  border-radius: 24px 24px 0 0;
  background: linear-gradient(160deg, #e8f0f8, #f6ecf2);
  box-shadow: var(--lift);
}

.foot p,
.foot small {
  margin: 0;
}

.foot-a {
  font-weight: 800;
  font-size: 16.5px;
}

.foot-b {
  font-size: 15px;
  color: var(--ink-2);
}

.foot-c,
.foot-d {
  font-size: 13.5px;
  color: var(--ink-2);
}

/* 入场动效 */
.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.js .reveal.in {
  opacity: 1;
  transform: none;
}

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

  .js .reveal {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .touch,
  .burger,
  .dock-close,
  .rail-nav a,
  .dock,
  .skip {
    transition: none;
  }
}

@media (max-width: 960px) {
  .stage {
    grid-template-columns: minmax(0, 1fr);
    gap: 16px;
  }

  .rail {
    position: static;
  }

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

  .hero {
    grid-template-columns: minmax(0, 1fr);
    border-radius: 20px 20px 64px 64px;
    min-height: 0;
  }

  .hero-art {
    min-height: 128px;
    max-height: 190px;
  }

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

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

  .bar {
    padding: 8px 12px 9px;
  }

  .brand-txt {
    font-size: 15.5px;
  }

  .touch,
  .burger {
    padding: 0 15px;
    font-size: 15px;
  }

  .hero {
    margin: 12px 12px 0;
    padding: 18px 15px 30px;
    gap: 14px;
  }

  .hero-art {
    min-height: 112px;
  }

  .stage {
    padding: 0 12px 32px;
    margin-top: 16px;
  }

  .rail-nav ul {
    grid-template-columns: minmax(0, 1fr);
  }

  .flow > div {
    padding: 18px 15px;
    scroll-margin-top: 148px;
  }

  .flow h2 {
    font-size: 20px;
  }

  .foot {
    margin-top: 32px;
    padding: 24px 14px 30px;
    gap: 12px;
  }
}

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