/* blog.css —— M5 静态镜像层样式。加载于镜像页与列表页。 */

/* #app 变为定位上下文, 静态层以覆盖层姿态盖在终端之上(不能 display:none 终端,
   否则 FitAddon 量不到尺寸)。inset 与 #app 的 padding 对齐。 */
#app { position: relative; }

#static-view {
  position: absolute;
  inset: 12px;
  z-index: 20;
  background: var(--bg);      /* 不透明: 终端在其下就绪但不被看见 */
  overflow-y: auto;
  padding: 24px 18px;
  transition: opacity 400ms ease-out;
}
#static-view.fade-out { opacity: 0; pointer-events: none; }

/* 落地页等待层: JS 用户首屏只看它(不透明盖住静态正文, 正文不闪现),
   终端就绪后淡出; 无 JS 时由镜像页里的 <noscript> 隐藏本层 */
#mirror-cover {
  position: absolute;
  inset: 12px;
  z-index: 21;
  background: var(--bg);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: opacity 400ms ease-out;
}
#mirror-cover.fade-out { opacity: 0; pointer-events: none; }
#mirror-cover .mirror-status { margin: 0; }

#static-view article {
  max-width: 80ch;
  margin: 0 auto;
  font-size: 15px;
  line-height: 1.7;
}
#static-view article h1 { font-size: 1.6em; margin: 0 0 .6em; }
#static-view article h2 { font-size: 1.3em; margin: 1.4em 0 .5em; }
#static-view article h3 { font-size: 1.1em; margin: 1.2em 0 .4em; }
#static-view article p { margin: .6em 0; }
#static-view article pre {
  background: #f0f2f4;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 12px;
  overflow-x: auto;
}
#static-view article code { font-family: inherit; }
#static-view article pre code { padding: 0; background: none; border: 0; }
#static-view article :not(pre) > code {
  background: #f0f2f4;
  border-radius: 4px;
  padding: 1px 5px;
}
#static-view article blockquote {
  border-left: 3px solid var(--border);
  margin: .8em 0;
  padding: 2px 0 2px 14px;
  color: #6a737d;
}
#static-view article a { color: #0969da; }
/* 镜像页图片: 内容编译期写死了 width/height 属性, height:auto 防拉伸 */
#static-view article img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 1em auto;
}
.post-meta { color: #6a737d; font-size: 13px; margin-top: 2.5em; }

.mirror-status { color: #6a737d; font-size: 13px; margin: 0 0 1.5em; }

@media (max-width: 640px) {
  #static-view { inset: 4px; padding: 14px 8px; }
  #mirror-cover { inset: 4px; }
}

#blog-list { max-width: 80ch; margin: 0 auto; padding: 32px 18px; line-height: 1.7; }
#blog-list .comments { margin-top: 3rem; }
