/* ============================================================
   base.css — reset + 排版基础
   ============================================================ */
*,
*::before,
*::after { box-sizing: border-box; }

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

body {
  margin: 0;
  font-family: var(--font);
  font-size: var(--fs-body);
  line-height: 1.75;
  color: var(--text-body);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

/* 坑 5：figure 的 UA margin 必须清掉 */
h1, h2, h3, h4, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }

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

a { color: var(--brand-ink); text-decoration: none; }
a:hover { text-decoration: none; }

button { font: inherit; border: 0; background: none; cursor: pointer; padding: 0; }

strong { color: var(--text); font-weight: 700; }

/* 坑 2：组件的 display 不得盖掉 hidden */
[hidden] { display: none !important; }

/* 焦点可见 */
:focus-visible {
  outline: 2px solid var(--brand-mark);
  outline-offset: 2px;
  border-radius: 4px;
}

/* 无障碍跳转 */
.skip-link {
  position: absolute;
  left: 16px;
  top: -48px;
  z-index: 100;
  padding: 10px 18px;
  border-radius: var(--r-pill);
  background: var(--brand);
  color: var(--text-invert);
  font-weight: 600;
  transition: top 0.15s ease;
}
.skip-link:focus { top: 12px; }

/* 排版 */
.h-display {
  font-family: var(--font-display);
  font-weight: 800;
  letter-spacing: 0.01em;
  line-height: 1.18;
  color: var(--text);
}
h1, h2, h3 { font-weight: 800; color: var(--text); line-height: 1.3; }

.text-gradient {
  background: linear-gradient(100deg, #E85BC0 0%, #A259FF 62%, #7C3AED 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}

.kicker {
  font-size: var(--fs-tiny);
  font-weight: 700;
  letter-spacing: 0.22em;
  color: var(--brand-ink);
  text-transform: uppercase;
}

.muted { color: var(--text-muted); }
.small { font-size: var(--fs-small); }
.center { text-align: center; }

/* 长文阅读宽度（全站唯一） */
.prose { width: 100%; max-width: var(--w-prose); }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
}
