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

:root {
  --base: #c8e0f4;
  --pink: #f5e0e8;
  --ink: #171f26;
  --mute: #3d4d5a;
  --dim: #6f8291;
  --face: #d8e7f5;
  --face-hi: #e8f2fb;
  --shadow: rgba(23, 31, 38, 0.16);
  --lift-d: -6px -6px 16px rgba(255, 255, 255, 0.85);
  --drop-d: 8px 8px 20px var(--shadow);
  --radio: 14px;
  --side: 238px;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  min-height: 100vh;
  color: var(--ink);
  font-family: 'Space Grotesk', "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.75;
  background: linear-gradient(155deg, #e6f0fa 0%, var(--base) 42%, #d4e6f6 100%);
  background-attachment: fixed;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  background-image: radial-gradient(rgba(23, 31, 38, 0.24) 1px, transparent 1px);
  background-size: 22px 22px;
  opacity: 0.28;
}

img { max-width: 100%; }

a { color: #1d4a70; }

h1, h2, h3, h4 {
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.16;
}

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

/* ---------- 左侧固定栏 ---------- */
.side {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--side);
  z-index: 30;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 26px 18px 30px;
  overflow-y: auto;
  background: linear-gradient(145deg, #e4effa 0%, #c5ddf3 100%);
  box-shadow: 10px 0 26px rgba(23, 31, 38, 0.13);
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 4px;
  min-height: 48px;
  color: var(--ink);
  text-decoration: none;
}

.brand-logo {
  display: block;
  border-radius: 10px;
  box-shadow: var(--lift-d);
}

.brand-name {
  font-size: 27px;
  font-weight: 700;
  letter-spacing: -0.05em;
}

.side nav { min-width: 0; }

.side nav p {
  display: flex;
  flex-direction: column;
  gap: 3px;
  margin: 0;
}

.side nav a {
  display: block;
  padding: 10px 12px;
  border-radius: 11px;
  color: var(--ink);
  font-size: 16.5px;
  font-weight: 500;
  text-decoration: none;
  transition: background 160ms ease, box-shadow 160ms ease, transform 160ms ease;
}

.side nav a:hover,
.side nav a:focus-visible {
  background: linear-gradient(145deg, #fbeef3, var(--pink));
  box-shadow: -4px -4px 10px rgba(255, 255, 255, 0.9), 4px 4px 12px var(--shadow);
  transform: translateX(2px);
}

.search {
  margin-top: auto;
  display: flex;
  gap: 7px;
}

.search input {
  flex: 1 1 auto;
  min-width: 0;
  min-height: 44px;
  padding: 10px 12px;
  border: 0;
  border-radius: 11px;
  font: inherit;
  font-size: 16px;
  color: var(--ink);
  background: var(--base);
  box-shadow: inset -4px -4px 10px rgba(255, 255, 255, 0.9), inset 5px 5px 12px rgba(23, 31, 38, 0.18);
}

.search input:focus-visible {
  outline: 2px solid rgba(23, 31, 38, 0.4);
  outline-offset: 2px;
}

.search button {
  flex: 0 0 auto;
  min-height: 44px;
  padding: 0 13px;
  border: 0;
  border-radius: 11px;
  font: inherit;
  font-size: 15px;
  font-weight: 600;
  color: var(--ink);
  cursor: pointer;
  background: linear-gradient(145deg, #fbeef3, #eccfdb);
  box-shadow: var(--lift-d), 5px 5px 12px var(--shadow);
  transition: transform 150ms ease, box-shadow 150ms ease;
}

.search button:active {
  transform: scale(0.96);
  box-shadow: inset -2px -2px 6px rgba(255, 255, 255, 0.85), inset 3px 3px 8px var(--shadow);
}

/* ---------- 主体 ---------- */
main {
  position: relative;
  z-index: 1;
  margin-left: var(--side);
  max-width: 1160px;
  padding: 0 clamp(16px, 3vw, 46px);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.02fr) minmax(0, 1fr);
  gap: clamp(20px, 4vw, 56px);
  align-items: center;
  min-height: 70vh;
  padding: clamp(28px, 6vh, 64px) 0 clamp(26px, 5vh, 52px);
}

.hero-figure {
  position: relative;
  margin: 0;
  aspect-ratio: 4 / 3;
  border-radius: 18px;
  overflow: hidden;
  background: linear-gradient(145deg, var(--face-hi), #bcd9f0);
  box-shadow: -10px -10px 26px rgba(255, 255, 255, 0.9), 12px 12px 30px var(--shadow);
}

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

.hero-plate {
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(23, 31, 38, 0.3) 1.5px, transparent 1.5px);
  background-size: 17px 17px;
  box-shadow: inset 9px 9px 22px rgba(23, 31, 38, 0.14), inset -9px -9px 22px rgba(255, 255, 255, 0.9);
}

.hero-copy { text-align: right; }

.hero-copy h1 {
  margin: 0 0 16px;
  font-size: clamp(38px, 6.4vw, 84px);
  line-height: 0.95;
  letter-spacing: -0.05em;
  text-shadow: 2px 2px 0 rgba(255, 255, 255, 0.7);
}

.lede {
  margin: 0 0 0 auto;
  max-width: 34ch;
  font-size: clamp(16px, 1.35vw, 19px);
  line-height: 1.7;
  color: var(--mute);
}

/* ---------- 正文区 ---------- */
.stage {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 266px;
  gap: clamp(20px, 3vw, 48px);
  align-items: start;
  padding-bottom: 54px;
}

.stream { min-width: 0; }

.stream section {
  margin: 0 0 clamp(30px, 4vw, 58px);
  padding: clamp(18px, 2.6vw, 34px);
  border-radius: 16px;
  background: linear-gradient(145deg, #e1eef9, #cfe3f4);
  box-shadow: -8px -8px 22px rgba(255, 255, 255, 0.85), 9px 9px 24px var(--shadow);
  scroll-margin-top: 26px;
}

.stream section:nth-child(even) {
  background: linear-gradient(145deg, #fbeef3, #ecd7e1);
}

.stream h2 {
  margin: 0 0 14px;
  font-size: clamp(24px, 3vw, 34px);
  letter-spacing: -0.035em;
}

.stream h3 {
  margin: 26px 0 10px;
  font-size: clamp(19px, 2vw, 22px);
}

.stream h4 {
  margin: 20px 0 8px;
  font-size: 18px;
}

.stream p {
  margin: 0 0 14px;
  color: var(--mute);
}

.stream p:last-child,
.stream ul:last-child,
.stream ol:last-child { margin-bottom: 0; }

.stream ul,
.stream ol {
  margin: 0 0 16px;
  padding-left: 22px;
  color: var(--mute);
}

.stream li { margin-bottom: 7px; }

.stream img {
  display: block;
  width: auto;
  max-width: 100%;
  height: auto;
  margin: 16px 0;
  border-radius: 12px;
  box-shadow: -5px -5px 14px rgba(255, 255, 255, 0.9), 6px 6px 16px var(--shadow);
}

.stream figure {
  margin: 18px 0;
  border-radius: 12px;
  overflow: hidden;
}

.stream figure img { margin: 0; }

.stream blockquote {
  margin: 18px 0;
  padding: 14px 18px;
  border-radius: 12px;
  color: var(--mute);
  background: rgba(255, 255, 255, 0.5);
  box-shadow: inset -3px -3px 9px rgba(255, 255, 255, 0.9), inset 4px 4px 10px rgba(23, 31, 38, 0.1);
}

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

.stream table {
  width: 100%;
  margin: 16px 0;
  border-collapse: collapse;
  font-size: 16px;
}

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

.stream a {
  color: #14496f;
  text-underline-offset: 3px;
}

.stream strong { color: var(--ink); }

/* ---------- 右侧栏 ---------- */
.rail {
  position: sticky;
  top: 26px;
  padding: 20px 18px;
  border-radius: 16px;
  background: linear-gradient(145deg, #fbeef3, #eacfd9);
  box-shadow: -7px -7px 20px rgba(255, 255, 255, 0.9), 8px 8px 22px var(--shadow);
}

.rail small {
  display: block;
  margin-bottom: 5px;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.22em;
  color: var(--dim);
}

.rail h2 {
  margin: 0 0 12px;
  font-size: 19px;
  letter-spacing: -0.02em;
}

.rail-list {
  display: flex;
  flex-direction: column;
  margin: 0;
  counter-reset: rail;
}

.rail-list a {
  display: flex;
  gap: 9px;
  align-items: baseline;
  padding: 9px 0;
  min-height: 42px;
  font-size: 16px;
  color: var(--ink);
  text-decoration: none;
  border-bottom: 1px solid rgba(23, 31, 38, 0.1);
}

.rail-list a:last-child { border-bottom: 0; }

.rail-list a::before {
  counter-increment: rail;
  content: counter(rail, decimal-leading-zero);
  flex: 0 0 auto;
  font-size: 12px;
  font-weight: 600;
  color: var(--dim);
  letter-spacing: 0.06em;
}

.rail-list a:hover { color: #14496f; }

/* ---------- 页脚 ---------- */
.foot {
  position: relative;
  z-index: 1;
  margin-left: var(--side);
  padding: 42px clamp(16px, 3vw, 46px) 34px;
  background: linear-gradient(145deg, #d3e6f6, #bfd9f0);
  box-shadow: inset 0 10px 22px rgba(255, 255, 255, 0.7), 0 -8px 22px var(--shadow);
}

.foot-cols {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 24px;
  max-width: 1080px;
  margin: 0 auto;
}

.foot-col { margin: 0; }

.foot-col dt {
  margin-bottom: 8px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.2em;
  color: var(--dim);
}

.foot-col dd {
  margin: 0;
  font-size: 16px;
}

.foot-col dd a {
  display: inline-block;
  padding: 8px 0;
  min-height: 40px;
  color: var(--ink);
  text-decoration: none;
}

.foot-col dd a:hover { color: #14496f; }

.foot-mark { display: flex; align-items: center; gap: 12px; }

.foot-logo { display: block; min-height: 44px; }

.foot-logo img {
  display: block;
  border-radius: 12px;
  box-shadow: var(--lift-d), 5px 5px 12px var(--shadow);
}

.foot-brand {
  margin: 0;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.copy,
.note {
  max-width: 1080px;
  margin: 26px auto 0;
  text-align: center;
  font-size: 15px;
  color: var(--mute);
}

.note { margin-top: 4px; font-size: 14px; color: var(--dim); }

/* ---------- 滚动出现 ---------- */
html.js :is(.stream section, .hero-figure, .hero-copy, .rail, .foot-cols > *) {
  opacity: 0;
  transform: translateY(18px);
  transition: opacity 520ms ease, transform 520ms cubic-bezier(0.2, 0.7, 0.3, 1);
}

html.js :is(.stream section, .hero-figure, .hero-copy, .rail, .foot-cols > *).in {
  opacity: 1;
  transform: none;
}

html.js .rail-list a:nth-child(n + 2) { transition-delay: 0ms; }

/* ---------- 窄屏 ---------- */
@media (max-width: 900px) {
  .side {
    inset: 0 0 auto 0;
    width: auto;
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 6px 10px;
    padding: 9px 13px;
    box-shadow: 0 8px 20px rgba(23, 31, 38, 0.15);
  }

  .brand {
    grid-column: 1;
    grid-row: 1;
    padding: 4px 0;
  }

  .brand-name { font-size: 23px; }

  .search {
    grid-column: 2;
    grid-row: 1;
    margin: 0;
    align-self: center;
  }

  .side nav {
    grid-column: 1 / -1;
    grid-row: 2;
    min-width: 0;
  }

  .side nav p {
    flex-direction: row;
    gap: 6px;
    overflow-x: auto;
    padding-bottom: 3px;
    scrollbar-width: thin;
  }

  .side nav a {
    white-space: nowrap;
    padding: 9px 12px;
    min-height: 40px;
  }

  .side nav a:hover { transform: none; }

  main {
    margin-left: 0;
    padding-top: 126px;
    padding-left: 14px;
    padding-right: 14px;
  }

  .hero {
    grid-template-columns: minmax(0, 1fr);
    min-height: 0;
    gap: 18px;
    padding: 6px 0 24px;
  }

  .hero-copy { text-align: left; }

  .lede { margin-left: 0; max-width: 46ch; }

  .stage {
    grid-template-columns: minmax(0, 1fr);
    padding-bottom: 36px;
  }

  .rail {
    position: static;
    order: 2;
  }

  .stream section { scroll-margin-top: 128px; padding: 18px 16px; }

  .foot { margin-left: 0; padding: 32px 14px 28px; }

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

@media (max-width: 520px) {
  body { font-size: 16.5px; }

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

  .copy, .note { margin-top: 20px; }
}

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

  html.js :is(.stream section, .hero-figure, .hero-copy, .rail, .foot-cols > *) {
    opacity: 1;
    transform: none;
    transition: none;
  }

  .side nav a,
  .search button { transition: none; }
}

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