/* ============================================================
   亮品牌 · 基础层（base.css）
   只做三件事：盒模型重置、文档基线、可访问性默认。
   不含任何组件样式与业务样式。
   依赖：tokens.css
   ============================================================ */

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

html {
  font-size: 100%;                    /* 16px 基准；rem 随用户/系统字号缩放（HIG §8.2 支持 200%） */
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--depth-base);
  color: var(--ink);
  font-family: var(--sans);
  font-size: var(--fs-body);
  line-height: var(--lh-body);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;                 /* 兜底：任何元素溢出不产生横向滚动 */
}

h1, h2, h3, h4, h5, h6 { margin: 0; font-family: var(--serif); font-weight: 700; line-height: var(--lh-title); }
p { margin: 0; }
ul, ol { margin: 0; padding: 0; }
figure { margin: 0; }
blockquote { margin: 0; }

img, video, svg, canvas { max-width: 100%; height: auto; display: block; }

a { color: inherit; text-decoration: none; }

button, input, select, textarea { font: inherit; color: inherit; }

/* 键盘可达性：所有可交互元素都有可见焦点（HIG §8.3） */
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* 尊重系统「减弱动态效果」（HIG §7.2） */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: .001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .001ms !important;
    scroll-behavior: auto !important;
  }
}

/* 打印：去掉浮层与控制件 */
@media print {
  .nav, .toast, .modal-mask, .ed-bar, .ed-fab, .skip-link { display: none !important; }
}
