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

:root {
  --paper: #fdfbf7;
  --slate: #f5f5f5;
  --ink: #1a1a1a;
  --line: #e0e0e0;
  --soft: #4a4a4a;
  --rail: 190px;
}

* { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: 'Manrope', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.75;
  letter-spacing: 0.01em;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0.22;
  mix-blend-mode: multiply;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='140' height='140'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/></filter><rect width='140' height='140' filter='url(%23n)' opacity='0.5'/></svg>");
}

h1, h2, h3, h4, .mark, .plate-ink span {
  font-family: 'Syne', 'Manrope', 'PingFang SC', 'Microsoft YaHei', system-ui, sans-serif;
  font-weight: 700;
  letter-spacing: 0.01em;
}

a { color: var(--ink); }

:focus-visible {
  outline: 2px solid var(--ink);
  outline-offset: 2px;
}

/* 左侧竖排导航 */
.rail {
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  width: var(--rail);
  z-index: 8;
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 20px 14px;
  border-right: 1px solid var(--line);
  background: var(--paper);
  overflow-y: auto;
}

.mark {
  width: 44px;
  height: 44px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--ink);
  background: var(--slate);
  text-decoration: none;
  font-size: 18px;
  line-height: 1;
}

.mark img { display: block; width: 26px; height: 26px; }

.navbox summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 16px;
  cursor: pointer;
  list-style: none;
  user-select: none;
}

.navbox summary::-webkit-details-marker { display: none; }

.navbox summary::after {
  content: "";
  margin-left: auto;
  width: 12px;
  height: 2px;
  background: var(--ink);
  box-shadow: 0 -4px 0 var(--ink), 0 4px 0 var(--ink);
}

.navbox summary:hover { border-color: var(--ink); }

.navbox menu {
  list-style: none;
  margin: 12px 0 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.pill {
  display: flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 16px;
  text-decoration: none;
  background: var(--paper);
  color: var(--ink);
}

.pill:hover {
  background: var(--ink);
  border-color: var(--ink);
  color: var(--paper);
}

.find { margin-top: auto; }

.find-input {
  width: 100%;
  min-height: 44px;
  padding: 8px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--slate);
  color: var(--ink);
  font: inherit;
  font-size: 16px;
}

.find-input::placeholder { color: #7d7d7d; }

/* 主体 */
.page {
  margin-left: var(--rail);
  max-width: 1080px;
  padding: 0 clamp(16px, 4vw, 56px) 64px;
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(0, 0.85fr);
  align-items: center;
  gap: clamp(20px, 4vw, 52px);
  min-height: 70vh;
  padding: clamp(28px, 6vw, 72px) 0;
  border-bottom: 1px solid var(--line);
}

.hero-copy h1 {
  margin: 0 0 18px;
  font-size: clamp(30px, 4.6vw, 54px);
  line-height: 1.18;
  letter-spacing: -0.01em;
}

.lede {
  margin: 0;
  max-width: 34em;
  font-size: 17px;
  line-height: 1.8;
  color: var(--soft);
}

.plate {
  margin: 0;
  border: 1px solid var(--line);
  background: var(--slate);
  aspect-ratio: 4 / 3;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  box-shadow: 0 22px 34px -30px rgba(0, 0, 0, 0.65), 0 1px 0 #ececec;
}

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

.plate-ink span {
  font-size: 64px;
  line-height: 1;
  color: #d8d4cb;
}

/* 正文区：aside 在左 */
.workspace {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr);
  gap: clamp(20px, 4vw, 48px);
  align-items: start;
  padding-top: clamp(26px, 4vw, 48px);
}

.ws-title {
  grid-column: 1 / -1;
  margin: 0;
  padding-top: 10px;
  border-top: 1px solid var(--line);
  font-size: 16px;
  letter-spacing: 0.3em;
}

.ws-title span { font-weight: 700; }

.margin {
  position: sticky;
  top: 24px;
  padding: 14px 16px 16px;
  border: 1px solid var(--line);
  background: var(--paper);
  box-shadow: 0 18px 28px -30px rgba(0, 0, 0, 0.8);
}

.margin-title {
  margin: 0 0 10px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--line);
  font-size: 16px;
  letter-spacing: 0.18em;
}

.margin-title span { font-weight: 700; }

.margin-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.margin-list a {
  display: flex;
  align-items: center;
  min-height: 40px;
  padding: 4px 2px;
  font-size: 16px;
  text-decoration: none;
  border-bottom: 1px dotted #e7e3da;
}

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

.margin-list a:hover { text-decoration: underline; text-underline-offset: 3px; }

.sheet {
  max-width: 720px;
  min-width: 0;
}

.sheet article {
  scroll-margin-top: 92px;
  padding-bottom: 8px;
}

.sheet article + article { margin-top: 8px; }

.sheet h2 {
  margin: 34px 0 12px;
  padding-top: 14px;
  border-top: 1px solid var(--line);
  font-size: clamp(21px, 2.4vw, 27px);
  line-height: 1.35;
}

.sheet h3 {
  margin: 24px 0 8px;
  font-size: 19px;
  line-height: 1.4;
}

.sheet p { margin: 0 0 15px; }

.sheet ul,
.sheet ol { margin: 0 0 16px; padding-left: 1.25em; }

.sheet li { margin-bottom: 6px; }

.sheet a { text-decoration: underline; text-underline-offset: 3px; }

.sheet blockquote {
  margin: 0 0 16px;
  padding: 10px 16px;
  border-left: 3px solid var(--ink);
  background: var(--slate);
}

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

.sheet figure { margin: 0 0 16px; }

.sheet img { max-width: 100%; height: auto; }

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

.sheet th,
.sheet td {
  border: 1px solid var(--line);
  padding: 8px 10px;
  text-align: left;
  vertical-align: top;
}

.sheet hr {
  border: 0;
  border-top: 1px solid var(--line);
  margin: 24px 0;
}

/* 页脚 */
.foot {
  margin-left: var(--rail);
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  gap: 12px;
  padding: 20px clamp(16px, 4vw, 56px) 44px;
  border-top: 1px solid var(--line);
  font-size: 16px;
}

.foot address {
  font-style: normal;
  letter-spacing: 0.06em;
}

.copy { margin: 0; text-align: center; color: var(--soft); }

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

.foot-links a {
  display: inline-flex;
  align-items: center;
  min-height: 40px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  font-size: 16px;
  text-decoration: none;
}

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

/* 滚动出现 */
.reveal {
  opacity: 0;
  transform: translateY(10px);
  transition: opacity 0.18s linear, transform 0.18s linear;
}

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

@media (min-width: 900px) {
  .navbox > menu { display: grid !important; }
}

/* 移动端 */
@media (max-width: 899px) {
  .rail {
    position: sticky;
    top: 0;
    left: auto;
    right: auto;
    bottom: auto;
    width: auto;
    height: auto;
    flex-direction: row;
    align-items: center;
    gap: 10px;
    padding: 9px 14px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
    overflow: visible;
  }

  .navbox { position: static; }

  .navbox menu {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    margin: 0;
    padding: 14px;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 20px 30px -30px rgba(0, 0, 0, 0.9);
    z-index: 9;
  }

  .find {
    margin: 0;
    flex: 1 1 auto;
    min-width: 0;
  }

  .page,
  .foot { margin-left: 0; }

  .page { padding: 0 16px 48px; }

  .hero {
    grid-template-columns: 1fr;
    min-height: 0;
    gap: 22px;
    padding: 24px 0 30px;
  }

  .workspace {
    grid-template-columns: 1fr;
    gap: 20px;
    padding-top: 24px;
  }

  .ws-title { grid-column: auto; }

  .sheet { order: 2; }

  .margin {
    order: 3;
    position: static;
  }

  .sheet article { scroll-margin-top: 78px; }

  .foot {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 18px 16px 40px;
  }

  .copy { order: 3; }

  .foot-links { justify-content: center; }
}

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

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

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