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

:root {
  --paper: #fdfbf7;
  --soft: #f5f5f5;
  --ink: #1a1a1a;
  --line: #e0e0e0;
  --mute: #5a5a5a;
  --hand: 'Caveat', 'Quicksand', system-ui, -apple-system, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --round: 'Quicksand', system-ui, -apple-system, 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  --radius: 28px;
}

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

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--round);
  font-size: 17px;
  font-weight: 400;
  line-height: 1.75;
  overflow-wrap: break-word;
  transition: none;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
  opacity: 0.07;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='140' height='140'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='140' height='140' filter='url(%23g)'/%3E%3C/svg%3E");
}

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

a:hover {
  text-decoration-thickness: 2px;
}

img {
  max-width: 100%;
}

/* 顶部：品牌居左 + 细条口号 */
.masthead {
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.bar {
  max-width: 1180px;
  margin: 0 auto;
  padding: 10px 18px;
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 4px 10px 4px 2px;
  text-decoration: none;
  font-family: var(--hand);
  font-size: 26px;
  font-weight: 600;
  line-height: 1.1;
  letter-spacing: 0.01em;
  white-space: nowrap;
}

.brand .mark {
  width: 34px;
  height: 34px;
  object-fit: contain;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: var(--soft);
}

.ticker {
  flex: 1 1 220px;
  min-width: 0;
  margin: 0;
  font-size: 16px;
  line-height: 1.5;
  color: var(--mute);
}

/* 二级粘性锚点条：details > summary + menu > li > a */
.dock {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--paper);
  border-bottom: 1px solid var(--line);
}

.dock > summary {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 10px 18px;
  max-width: 1180px;
  margin: 0 auto;
  cursor: pointer;
  font-size: 16px;
  letter-spacing: 0.18em;
  list-style: none;
}

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

.dock > summary::before {
  content: "";
  width: 12px;
  height: 12px;
  border: 1px solid var(--ink);
  flex: none;
}

.dock[open] > summary::before {
  background: var(--ink);
}

.dock > menu {
  position: absolute;
  left: 0;
  right: 0;
  top: 100%;
  margin: 0;
  padding: 6px 18px 18px;
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0 20px;
  background: var(--paper);
  border-bottom: 1px solid var(--ink);
  max-height: 72vh;
  overflow: auto;
}

.dock > menu > li + li a {
  border-top: 1px solid var(--line);
}

.dock > menu a {
  display: flex;
  align-items: center;
  gap: 10px;
  min-height: 46px;
  padding: 10px 4px;
  text-decoration: none;
  font-size: 16px;
}

.dock > menu a::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  border: 1px solid var(--ink);
  flex: none;
}

.dock > menu a:hover::before {
  background: var(--ink);
}

/* 主区 */
main {
  display: block;
}

.hero {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 40px;
  min-height: 86svh;
  padding: 26px 18px 42px;
  background: var(--ink);
  color: var(--paper);
}

.hero figure {
  position: absolute;
  inset: 0;
  margin: 0;
}

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

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(26, 26, 26, 0.62);
  pointer-events: none;
}

.hero > *:not(figure) {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 1180px;
  margin-left: auto;
  margin-right: auto;
}

.stamp {
  align-self: flex-start;
  display: inline-block;
  width: auto;
  padding: 7px 16px;
  border: 1px solid rgba(253, 251, 247, 0.6);
  border-radius: 999px;
  background: rgba(253, 251, 247, 0.12);
  font-size: 16px;
  line-height: 1.2;
  letter-spacing: 0.12em;
}

.lede h1 {
  margin: 0;
  font-family: var(--hand);
  font-weight: 600;
  font-size: clamp(42px, 9.6vw, 100px);
  line-height: 1.04;
  letter-spacing: 0.01em;
  text-shadow: 0 1px 0 rgba(26, 26, 26, 0.35);
}

/* 正文 + 右侧边栏 */
.paper {
  max-width: 1180px;
  margin: 0 auto;
  padding: 40px 18px 72px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 282px;
  gap: 44px;
  align-items: start;
}

.content {
  min-width: 0;
  max-width: 72ch;
}

.content > article {
  position: relative;
  margin: 0 0 28px;
  padding: 28px 24px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.62);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
  scroll-margin-top: 118px;
}

.content > article:nth-child(even) {
  background: rgba(245, 245, 245, 0.72);
}

.content > article:last-child {
  margin-bottom: 0;
}

.content small {
  display: block;
  margin-bottom: 4px;
  font-size: 16px;
  line-height: 1.4;
  letter-spacing: 0.16em;
  color: var(--mute);
}

.content h2 {
  margin: 0 0 14px;
  font-family: var(--hand);
  font-weight: 600;
  font-size: clamp(27px, 4.6vw, 40px);
  line-height: 1.16;
}

.content small + h2 {
  margin-top: 0;
}

.content h3 {
  margin: 24px 0 10px;
  font-family: var(--hand);
  font-weight: 600;
  font-size: 26px;
  line-height: 1.25;
}

.content p {
  margin: 0 0 14px;
}

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

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

.content li {
  margin: 0 0 8px;
}

.content blockquote {
  margin: 18px 0;
  padding: 4px 0 4px 16px;
  border-left: 2px solid var(--ink);
  color: var(--mute);
}

.content figure {
  margin: 20px 0;
}

.content img {
  display: block;
  height: auto;
  border-radius: 16px;
}

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

.content th,
.content td {
  padding: 9px 11px;
  border: 1px solid var(--line);
  text-align: left;
}

.content code {
  font-size: 15px;
  padding: 2px 5px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--soft);
}

/* 边栏 */
.side {
  position: sticky;
  top: 66px;
  padding: 22px 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: rgba(255, 255, 255, 0.7);
  -webkit-backdrop-filter: blur(8px);
  backdrop-filter: blur(8px);
}

.side small {
  display: block;
  font-size: 16px;
  line-height: 1.4;
  letter-spacing: 0.16em;
  color: var(--mute);
}

.side h2 {
  margin: 2px 0 12px;
  font-family: var(--hand);
  font-weight: 600;
  font-size: 28px;
  line-height: 1.2;
}

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

.side li + li {
  border-top: 1px solid var(--line);
}

.side a {
  display: flex;
  align-items: center;
  min-height: 46px;
  padding: 10px 2px;
  font-size: 16px;
  text-decoration: none;
}

.side a:hover {
  text-decoration: underline;
}

/* 页脚：只有 p 与 small */
footer {
  border-top: 1px solid var(--line);
  background: var(--soft);
  padding: 36px 18px 40px;
  text-align: center;
}

footer p {
  margin: 0 0 6px;
  font-family: var(--hand);
  font-size: 24px;
  line-height: 1.2;
}

footer small {
  display: block;
  font-size: 16px;
  line-height: 1.5;
  color: var(--mute);
  letter-spacing: 0.12em;
}

/* 滚动出现 */
.reveal {
  opacity: 0;
  transform: translateY(12px);
}

.reveal.in {
  opacity: 1;
  transform: none;
  transition: opacity 0.3s steps(3), transform 0.3s steps(3);
}

@media (max-width: 900px) {
  .paper {
    grid-template-columns: minmax(0, 1fr);
    gap: 26px;
    padding: 28px 16px 56px;
  }

  .content {
    max-width: none;
  }

  .side {
    position: static;
  }

  .dock > menu {
    grid-template-columns: minmax(0, 1fr);
    max-height: 64vh;
  }

  .hero {
    min-height: 78svh;
  }
}

@media (max-width: 600px) {
  .bar {
    gap: 8px;
    padding: 8px 14px;
  }

  .brand {
    font-size: 23px;
  }

  .ticker {
    flex-basis: 100%;
  }

  .hero {
    padding: 20px 14px 30px;
    gap: 28px;
  }

  .content > article {
    padding: 22px 16px;
    border-radius: 22px;
  }

  .content h2 {
    font-size: clamp(24px, 6.6vw, 32px);
  }

  .side {
    border-radius: 22px;
  }
}

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

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

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