/* reset 与排版：元素选择器一律包 :where()，权重为 0（05 §4.2） */
*{box-sizing:border-box}
:where(html, body){margin:0;padding:0}
:where(body){
  font-family:var(--font);font-size:15px;line-height:1.78;color:var(--ink-soft);
  background:var(--bg);-webkit-font-smoothing:antialiased;
  transition:background-color var(--theme-dur) ease,color var(--theme-dur) ease;
}
:where(a){color:var(--pri);text-decoration:none}
:where(a:hover){color:var(--pri-dk)}
:where(h1,h2,h3){margin:0;color:var(--ink);line-height:1.3}
:where(p){margin:0}
:where(img){max-width:100%}
:where(button){font:inherit;cursor:pointer;border:0;background:none;color:inherit}
:where(:focus-visible){outline:2px solid var(--pri);outline-offset:2px}

/* 容器：1240 / 22（外壳职责） */
.c-container{max-width:var(--container);margin:0 auto;padding:0 var(--gutter)}

/* 工具类 */
.u-sr-only{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
.u-nowrap{white-space:nowrap}
.u-hidden{display:none}

/* 跳转链接：仅键盘聚焦时出现 */
.c-skip{position:absolute;left:12px;top:-60px;z-index:var(--z-toast);padding:8px 14px;border-radius:var(--r5);background:var(--pri);color:#fff;font-size:13px}
.c-skip:focus{top:12px}

@media (prefers-reduced-motion: reduce){:root{--theme-dur:0s}}
/* 打印：外壳不进纸面（05 §8 打印） */
@media print{.c-topbar,.c-footer,.c-totop,.c-toast{display:none}body{background:#fff}}
/* 页面入场：从详情页/新窗口进来时轻微上浮淡入（04 外壳职责） */
/* 不加 fill-mode：动画结束后不能残留 transform，否则 main 会成为 fixed 后代的包含块（抽屉/遮罩会被裁到内容区） */
.c-main{animation:c-page-in .24s ease-out}
@keyframes c-page-in{from{opacity:0;transform:translateY(6px)}to{opacity:1;transform:none}}
@media (prefers-reduced-motion: reduce){.c-main{animation:none}}
