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

:root {
  --pink: #eb879c;
  --pink-soft: #ffb6c1;
  --ink: #26171a;
  --muted: #6a5257;
  --bg: #fff8fa;
  --surface: #ffffff;
  --tint: #fdeef2;
  --line: #f2dbe1;
  --radius: 12px;
  --shadow-xs: 0 1px 2px rgba(38, 23, 26, 0.05);
  --shadow-soft: 0 2px 4px rgba(38, 23, 26, 0.05), 0 10px 26px rgba(235, 135, 156, 0.14);
  --shadow-lift: 0 4px 8px rgba(38, 23, 26, 0.06), 0 16px 32px rgba(235, 135, 156, 0.2);
  --ease: 240ms cubic-bezier(0.22, 0.61, 0.36, 1);
}

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

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

body {
  margin: 0;
  background:
    radial-gradient(1100px 520px at 78% -8%, #fdeef2 0%, rgba(253, 238, 242, 0) 62%),
    linear-gradient(180deg, #fff8fa 0%, #fff8fa 62%, #fdefF3 100%);
  background-color: var(--bg);
  color: var(--ink);
  font-family: 'Inter', system-ui, -apple-system, 'Segoe UI', 'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei', sans-serif;
  font-size: 16px;
  line-height: 1.7;
  font-weight: 400;
  overflow-x: hidden;
}

h1,
h2,
h3,
h4 {
  font-weight: 600;
  letter-spacing: -0.012em;
  line-height: 1.32;
}

p {
  margin: 0 0 1em;
}

a {
  color: inherit;
}

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

:focus-visible {
  outline: 3px solid var(--pink);
  outline-offset: 3px;
  border-radius: 6px;
}

/* ---------- 顶部 ---------- */
.top {
  background: rgba(255, 248, 250, 0.94);
  border-bottom: 1px solid var(--line);
}

.ticker {
  background: linear-gradient(90deg, #fdeef2 0%, #ffd8e1 58%, #ffc2cf 100%);
  border-bottom: 1px solid var(--line);
}

.ticker p {
  max-width: 1080px;
  margin: 0 auto;
  padding: 9px 20px;
  color: #a94f63;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.2em;
}

.brandrow {
  max-width: 1080px;
  margin: 0 auto;
  padding: 16px 20px 8px;
  display: flex;
  align-items: center;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 44px;
  padding: 4px 2px;
  font-size: 20px;
  font-weight: 700;
  letter-spacing: -0.015em;
  text-decoration: none;
  color: var(--ink);
  transition: color var(--ease);
}

.brand:hover {
  color: #c0526b;
}

.brand .mark {
  width: 30px;
  height: 30px;
  border-radius: 9px;
  box-shadow: var(--shadow-xs);
}

.menu p {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 6px 20px 14px;
}

.pill {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 18px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--surface);
  color: var(--ink);
  font-size: 16px;
  font-weight: 500;
  text-decoration: none;
  box-shadow: var(--shadow-xs);
  transition: transform var(--ease), box-shadow var(--ease), background var(--ease), border-color var(--ease);
}

.pill:hover {
  transform: translateY(-2px);
  background: var(--tint);
  border-color: var(--pink-soft);
  box-shadow: var(--shadow-soft);
}

.pill:active {
  transform: translateY(0);
}

/* ---------- Hero ---------- */
.hero {
  max-width: 1080px;
  margin: 0 auto;
  padding: 44px 20px 20px;
  display: flex;
  align-items: center;
  gap: 32px;
  min-height: 70vh;
}

.hero-copy {
  flex: 1 1 auto;
  min-width: 0;
  text-align: left;
}

.hero h1 {
  margin: 0;
  font-size: clamp(28px, 4.4vw, 46px);
  font-weight: 600;
  letter-spacing: -0.025em;
  color: var(--ink);
  text-shadow: 0 1px 0 #fff;
}

.hero-art {
  flex: 0 0 auto;
  width: min(300px, 40vw);
  padding: 8px;
  background: var(--surface);
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}

/* ---------- 内容骨架 ---------- */
.wrap {
  display: grid;
  grid-template-columns: 224px minmax(0, 1fr);
  gap: 32px;
  align-items: start;
  max-width: 1080px;
  margin: 0 auto;
  padding: 8px 20px 64px;
}

.side {
  position: sticky;
  top: 132px;
  padding: 18px 16px 16px;
  background: var(--surface);
  border-radius: var(--radius);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-soft);
}

.side small {
  display: block;
  color: #b8576d;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.14em;
}

.side h2 {
  margin: 4px 0 12px;
  font-size: 18px;
  font-weight: 600;
}

.side-links {
  display: grid;
  gap: 4px;
  margin: 0;
}

.side-links a {
  display: block;
  padding: 10px 12px;
  border-radius: 8px;
  font-size: 16px;
  text-decoration: none;
  color: var(--ink);
  transition: background var(--ease), transform var(--ease), color var(--ease);
}

.side-links a:hover {
  background: var(--tint);
  color: #a94f63;
  transform: translateX(3px);
}

.body {
  min-width: 0;
}

.doc {
  min-width: 0;
}

.doc > div {
  margin: 0 0 26px;
  padding: 26px 24px 22px;
  background: var(--surface);
  border-radius: 4px;
  border-bottom: 3px solid var(--pink-soft);
  box-shadow: var(--shadow-soft);
  transition: box-shadow var(--ease), transform var(--ease);
}

.doc > div:hover {
  box-shadow: var(--shadow-lift);
  transform: translateY(-2px);
}

.doc div[id] {
  scroll-margin-top: 148px;
}

.doc small {
  display: block;
  margin-bottom: 6px;
  color: #b8576d;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.14em;
}

.doc h2 {
  margin: 0 0 14px;
  font-size: clamp(21px, 3vw, 27px);
  color: var(--ink);
}

.doc h3 {
  margin: 22px 0 10px;
  font-size: 19px;
  color: #3b2529;
}

.doc p {
  margin: 0 0 14px;
  color: #322024;
}

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

.doc li {
  margin-bottom: 8px;
}

.doc li::marker {
  color: var(--pink);
}

.doc strong {
  font-weight: 600;
  color: var(--ink);
}

.doc a {
  color: #b04a61;
  text-decoration-color: var(--pink-soft);
  text-underline-offset: 3px;
  transition: color var(--ease);
}

.doc a:hover {
  color: #8d3448;
}

.doc blockquote {
  margin: 0 0 16px;
  padding: 14px 18px;
  border-radius: 4px;
  background: var(--tint);
  border-left: 4px solid var(--pink);
  color: #4a3237;
}

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

.doc img {
  border-radius: 8px;
  box-shadow: var(--shadow-xs);
  margin: 6px 0 16px;
}

.doc time {
  font-size: 16px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

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

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

.doc th {
  background: var(--tint);
  font-weight: 600;
}

/* ---------- 页脚 ---------- */
footer {
  margin-top: 12px;
  background: #fdf0f4;
  border-top: 1px solid var(--line);
}

.foot-cols {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 28px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 40px 20px 26px;
}

.foot-cols dl {
  margin: 0;
}

.foot-cols dt {
  margin-bottom: 10px;
  font-size: 16px;
  font-weight: 600;
  letter-spacing: 0.14em;
  color: #a94f63;
}

.foot-cols dd {
  margin: 0;
  font-size: 16px;
  color: #3b2529;
}

.foot-links {
  display: grid;
  gap: 2px;
}

.foot-links a {
  display: inline-block;
  padding: 10px 0;
  min-height: 40px;
  text-decoration: none;
  color: #3b2529;
  transition: color var(--ease), transform var(--ease);
}

.foot-links a:hover {
  color: #a94f63;
  transform: translateX(2px);
}

.foot-base {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  max-width: 1080px;
  margin: 0 auto;
  padding: 16px 20px 32px;
  border-top: 1px solid var(--line);
}

.foot-base p {
  margin: 0;
  font-size: 16px;
  color: var(--muted);
}

.to-top a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 8px 18px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: var(--shadow-xs);
  text-decoration: none;
  color: var(--ink);
  transition: background var(--ease), transform var(--ease), box-shadow var(--ease);
}

.to-top a:hover {
  background: var(--tint);
  transform: translateY(-2px);
  box-shadow: var(--shadow-soft);
}

/* ---------- 动效 ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity 300ms ease, transform 300ms ease;
}

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

/* ---------- 断点 ---------- */
@media (min-width: 900px) {
  .top {
    position: sticky;
    top: 0;
    z-index: 30;
    backdrop-filter: blur(10px);
  }
}

@media (max-width: 899px) {
  .hero {
    min-height: auto;
    padding-top: 30px;
    gap: 20px;
  }

  .wrap {
    grid-template-columns: minmax(0, 1fr);
    gap: 20px;
    padding-bottom: 48px;
  }

  .side {
    position: static;
  }

  .side-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
  }

  .side-links a {
    padding: 10px 14px;
    border: 1px solid var(--line);
    border-radius: 999px;
    min-height: 44px;
    display: inline-flex;
    align-items: center;
  }

  .doc div[id] {
    scroll-margin-top: 24px;
  }
}

@media (max-width: 620px) {
  .hero {
    flex-direction: column;
    align-items: flex-start;
    padding-bottom: 8px;
  }

  .hero-art {
    width: min(240px, 68vw);
    order: 2;
  }

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

  .foot-base {
    flex-direction: column;
    align-items: flex-start;
  }

  .doc > div {
    padding: 20px 16px 18px;
  }
}

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

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }

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

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