/* 模板默认占位符在深色联系区表单上对比度不足，仅提高该区占位符亮度 */
.wrapper.style4 form ::-webkit-input-placeholder { color: #aaa !important; }
.wrapper.style4 form :-moz-placeholder { color: #aaa !important; }
.wrapper.style4 form ::-moz-placeholder { color: #aaa !important; }
.wrapper.style4 form :-ms-input-placeholder { color: #aaa !important; }

/* （2026-10-10 清理：原「为微信/邮箱补社交背景色」的旧补丁已删除——
   品牌色现统一由下方社交图标段处理，旧规则 #555 会盖掉邮件红） */

/* ============================================================
   中文（CJK）字体补齐 —— 自托管细体中文 webfont（琢器 / Miniport）
   ------------------------------------------------------------
   问题：模板 main.css 的字体栈只有 'Open Sans'（仅含拉丁字形）。
   页面里的中文会回退到访客操作系统的默认中文字体 —— 各设备不一致，
   且通常比模板的 300 细体更粗，整体观感与原模板差别较大。

   处理：自托管一份子集化的开源中文字体，插在西文字体「之后」：
     · 西文 / 数字 / 符号 仍走模板原字体 'Open Sans' —— 视觉零变化；
     · 只有中文字符才走补充字体。
   之所以把西文放在首位，是保证「西文渲染与原模板完全一致」的关键。

   字重对应（与模板一致）：
     · 正文与 h1 .......... 300（模板 body / h1 即为 300 细体）
     · h2-h6 与 strong .... 700（模板 h2-h6 / strong 为 600-700）

   字体来源（完全开源，可自由商用与自托管分发）：
     Noto Sans SC（思源黑体）· SIL Open Font License 1.1
     已子集化至 GB2312 常用字库（6763 汉字）+ ASCII + 中文标点以控制体积；
     许可证全文见 ../fonts/OFL-NotoSansSC.txt
   ============================================================ */

@font-face {
  font-family: 'Noto Sans SC Web';
  font-style: normal;
  font-weight: 300;
  font-display: swap;
  src: url('../fonts/noto-sans-sc-300.woff2') format('woff2');
}

@font-face {
  font-family: 'Noto Sans SC Web';
  font-style: normal;
  font-weight: 700;
  font-display: swap;
  src: url('../fonts/noto-sans-sc-700.woff2') format('woff2');
}

/* 与模板完全相同的选择器，靠「后加载」覆盖其 font-family；不改动其它任何属性 */
body, input, textarea, select {
  font-family: 'Open Sans', 'Noto Sans SC Web',
               'PingFang SC', 'Hiragino Sans GB', 'Microsoft YaHei',
               'Source Han Sans SC', 'Noto Sans CJK SC', 'WenQuanYi Micro Hei',
               sans-serif;
}

/* ============================================================
   管理页（/Dovis，隐藏入口）专用微调 —— 不触碰前台任何样式
   ------------------------------------------------------------
   模板 main.css 里 `input, select, textarea { appearance: none }`
   会把「复选框」和「文件选择框」的原生外观一并移除，
   导致管理页的批量选择、选图上传控件显示异常，这里只恢复这两类。
   ============================================================ */
input[type="checkbox"].adm {
  -webkit-appearance: checkbox;
  -moz-appearance: checkbox;
  appearance: checkbox;
  width: auto;
  display: inline-block;
  padding: 0;
  border: 0;
  background: none;
  box-shadow: none;
  vertical-align: middle;
}

input[type="file"].adm {
  width: 100%;
  padding: 0.75em;
  font-size: 1em;
  border-radius: 8px;
  border: solid 1px #ddd;
  background: #fff;
  color: #555;
  box-shadow: inset 0px 2px 3px 1px rgba(0, 0, 0, 0.05), 0px 1px 0px 0px rgba(255, 255, 255, 0.025);
}

/* 管理页表单输入文字改黑（刘先生 2026-09-16 反馈）
   模板 input 的 color 是 #bbb 浅灰（作者默认框里只放灰色占位符），
   正式输入/回显的文字也太淡。仅管理页（body.adm）改黑；
   占位符单独压回灰色以示区分。 */
body.adm input,
body.adm textarea,
body.adm select {
  color: #000;
}
body.adm input::-webkit-input-placeholder,
body.adm textarea::-webkit-input-placeholder { color: #999; opacity: 1; }
body.adm input:-moz-placeholder,
body.adm textarea:-moz-placeholder { color: #999; opacity: 1; }
body.adm input::-moz-placeholder,
body.adm textarea::-moz-placeholder { color: #999; opacity: 1; }
body.adm input:-ms-input-placeholder,
body.adm textarea:-ms-input-placeholder { color: #999; opacity: 1; }

/* ============================================================
   首页卡片文字截断（刘先生 2026-09-15 要求：强制排版一致）
   ------------------------------------------------------------
   「我在做的事」(#work) 与「最近的作品」(#portfolio) 的分块，
   因每块文字长短不同而高低不齐。处理（不改动模板其它样式）：
     1. 作品卡标题：超过一行省略号截断；
     2. 简介段落：最多 3 行（作品卡 2 行）后省略号截断；
     3. 同一排的 box 拉伸到等高，保证卡片底边对齐。
   -webkit-line-clamp 全主流浏览器已支持（含 Firefox 68+/Safari 5+）。
   ============================================================ */

/* 作品卡标题：单行省略（截在 <a> 上，h3 本身不裁） */
#portfolio .box.style2 h3 a {
  display: block;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* 「我在做的事」简介：最多 3 行省略 */
#work .box.style1 p {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  overflow: hidden;
}

/* 作品卡简介：最多 2 行省略 */
#portfolio .box.style2 p {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
}

/* 同排卡片拉伸等高（列默认 stretch，box 本身高度跟内容走，补 height:100% 才会跟随列高） */
#work .row > div > section.box.style1,
#portfolio .row > div > article.box.style2 {
  height: 100%;
}

/* ============================================================
   页面整体收紧（刘先生 2026-09-15 反馈）
   ------------------------------------------------------------
   只在桌面/平板横屏（>980px）生效，手机断点保持模板原值。
   模板桌面端三处偏松：区块留白 8em、块标题与内容间 4em、
   区块页脚说明文字与按钮间 2em。分别收到 4.5em / 2em / 1em。
   （#work 已单独收到 3em，ID 优先级更高，不受此影响）
   ============================================================ */
@media screen and (min-width: 981px) {
  article.wrapper {
    padding-top: 4.5em;
    padding-bottom: 4.5em;
  }
  article.wrapper > .container > header {
    margin-bottom: 2em;
  }
  article.wrapper > .container > footer p {
    margin-bottom: 1em;
  }
}

/* ============================================================
   作品卡封面统一 1:1（刘先生 2026-09-16 要求）
   ------------------------------------------------------------
   上传图片宽高不一 → 卡片排版参差；且封面多按 3:2 裁剪时
   应用图标类素材上下被裁得只剩一条。统一改为 1:1（应用图标
   大多是方的），object-fit: cover 居中裁剪、不拉伸变形。
   布局参考「我在做什么」的分块：图片收进卡片内部（不再用
   模板「出血」式探出卡片的定位 —— 那套 top:2em 位移不占文档
   流，图的实际底边会比布局位置低 2em，正好压住下面的标题）。
   尺寸参考 #work 图标（3.5em 字号 ≈ 56px），封面取 7em 方形
   居中，比图标适当大一号。所有断点统一生效。
   ============================================================ */
#portfolio .box.style2 > .image.featured {
  position: static;
  left: auto;
  top: auto;
  width: 7em;
  height: 7em;
  margin: 0 auto 1.2em auto;
  overflow: hidden;
}
#portfolio .box.style2 > .image.featured img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* ============================================================
   作品详情页图集 + 灯箱（刘先生 2026-09-16 要求）
   ------------------------------------------------------------
   预览图限制尺寸：原图小于限制按原大小显示，大于则等比缩到
   max-width/max-height 内（width/height 均 auto + 双 max）。
   点预览图开灯箱看原图（原图最大占 94% 视口，Esc/点击关闭）。
   ============================================================ */
.gallery { margin: 0 0 2em; }
.gallery .gmain { position: relative; text-align: center; }
.gallery .gmain img {
  max-width: 100%;
  max-height: 22em;
  width: auto;
  height: auto;
  border-radius: 8px;
  box-shadow: inset 0px 0px 0px 1px rgba(0, 0, 0, 0.15), 0px 2px 3px 0px rgba(0, 0, 0, 0.1);
  background: #fff;
  cursor: zoom-in;
}
.gallery .gnav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 2.2em;
  height: 2.2em;
  border: 0;
  border-radius: 50%;
  background: rgba(20, 20, 20, 0.5);
  color: #fff;
  font-size: 1.2em;
  line-height: 1em;
  cursor: pointer;
}
.gallery .gnav:hover { background: rgba(20, 20, 20, 0.75); }
.gallery .gprev { left: 0.5em; }
.gallery .gnext { right: 0.5em; }
.gallery .gthumbs {
  margin-top: 1em;
  display: flex;
  flex-wrap: wrap;
  gap: 0.6em;
  justify-content: center;
}
.gallery .gthumbs img {
  width: 4.5em;
  height: 4.5em;
  object-fit: cover;
  border-radius: 6px;
  border: 2px solid transparent;
  opacity: 0.6;
  cursor: pointer;
}
.gallery .gthumbs img.on { opacity: 1; border-color: #43B3E0; }
.gallery .ghint { font-size: 0.85em; color: #999; margin-top: 0.8em; }

/* 灯箱（点击预览图后全屏看原图） */
.lightbox {
  position: fixed;
  top: 0; right: 0; bottom: 0; left: 0;
  background: rgba(10, 10, 10, 0.9);
  display: none;
  z-index: 99999;
}
.lightbox.open { display: block; }
.lightbox img {
  position: absolute;
  top: 0; right: 0; bottom: 0; left: 0;
  margin: auto;
  max-width: 94vw;
  max-height: 94vh;
  width: auto;
  height: auto;
  border-radius: 6px;
  background: #fff;
  cursor: zoom-out;
}
.lightbox .lb-close {
  position: absolute;
  top: 0.4em; right: 0.8em;
  color: #fff;
  font-size: 2.2em;
  line-height: 1;
  cursor: pointer;
}
.lightbox .lb-prev, .lightbox .lb-next {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  color: #fff;
  font-size: 3em;
  line-height: 1;
  cursor: pointer;
  user-select: none;
}
.lightbox .lb-prev { left: 0.6em; }
.lightbox .lb-next { right: 0.6em; }

/* ============================================================
   管理页图集组件（新增/编辑作品页）
   ============================================================ */
#imgList { display: flex; flex-wrap: wrap; gap: 0.9em; margin: 0.9em 0 0.4em; }
#imgList .gempty { color: #999; font-size: 0.9em; }
#imgList .gthumb {
  position: relative;
  width: 8em;
  padding: 0.5em;
  background: #fff;
  border: 1px solid #ddd;
  border-radius: 8px;
  text-align: center;
}
#imgList .gthumb.iscover { border-color: #43B3E0; box-shadow: 0 0 0 1px #43B3E0; }
#imgList .gthumb img {
  display: block;
  width: 100%;
  height: 5.5em;
  object-fit: cover;
  border-radius: 4px;
}
#imgList .gthumb label { display: block; font-size: 0.8em; margin-top: 0.4em; color: #333; }
#imgList .gthumb .gdel {
  position: absolute;
  top: -0.7em; right: -0.7em;
  width: 1.7em; height: 1.7em;
  border: 0;
  border-radius: 50%;
  background: #d9534f;
  color: #fff;
  font-size: 0.9em;
  line-height: 1.5em;
  cursor: pointer;
  padding: 0;
}
#imgMsg { display: block; min-height: 1.2em; font-size: 0.9em; color: #43B3E0; }

/* ============================================================
   首页头图收起（参考拾光 Massively intro 机制，刘先生 2026-09-16 要求）
   ------------------------------------------------------------
   1) 打开页面介绍展开；向下滚动（>60px）或点双箭头 → 介绍收起：
      淡出 + 下移 2rem（Massively 同款过渡）+ 高度塌缩（max-height
      由脚本锁定当前高度后过渡到 0），下方内容随之升起；
   2) 滚回顶部【不】自动展开 —— 只有点顶栏 LOGO 才重新展开
      （脚本 heroScript 控制 has-hero / intro-closed / show 三个状态类）。
   ============================================================ */
body.has-hero #top {
  overflow: hidden; /* 高度塌缩时裁切内容；首页头图无溢出元素，无副作用 */
  transition:
    max-height 0.6s cubic-bezier(0.4, 0, 0.2, 1),
    opacity 0.45s ease,
    transform 0.55s ease,
    padding 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}
#top.intro-closed {
  opacity: 0;
  transform: translateY(2rem);      /* Massively 同款：淡出时微微下沉 */
  padding-top: 0;
  padding-bottom: 0;
  pointer-events: none;
}

#top a.hero-arrow {
  display: table;          /* 收缩包裹 + margin auto → 整页水平居中（箭头已移出左右分栏） */
  margin: 1.4em auto 0;
  border-bottom: 0;
}
#top a.hero-arrow .icon:before {
  font-size: 2.6em;
  color: #43B3E0;
  transition: color 0.2s ease;
}
#top a.hero-arrow:hover .icon:before { color: #2a86b5; }

/* 双箭头流动动效（刘先生 2026-09-17 要求：引导向下）：
   箭头自上而下轻移并渐隐、循环往复，呈「往下流」的指引感；
   系统开启「减少动态效果」时自动停用 */
#top a.hero-arrow .icon {
  display: inline-block;
  animation: heroArrowFlow 1.9s ease-in-out infinite;
}
@keyframes heroArrowFlow {
  0%   { transform: translateY(-0.3em); opacity: 0; }
  25%  { opacity: 1; }
  70%  { transform: translateY(0.3em); opacity: 1; }
  100% { transform: translateY(0.55em); opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  #top a.hero-arrow .icon { animation: none; }
}

#nav ul { position: relative; }
#navLogo {
  position: absolute;
  left: 1.25em;
  top: 0;
  height: 100%;
  display: flex;
  align-items: center;
  opacity: 0;
  transform: translateY(0.5rem);
  pointer-events: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
}
#navLogo.show { opacity: 1; transform: translateY(0); pointer-events: auto; }
#navLogo a {
  color: #fff;
  font-weight: 700;
  font-size: 0.95em;
  white-space: nowrap;
}
#navLogo a:hover { color: #43B3E0; }
/* 手机端（刘先生 2026-09-17 要求）：收起后 LOGO 再左移一点，菜单【完全不位移】。
   做法：「我在做什么」在手机断点换两字短标签「动态」（双 span 切换，两种状态菜单
   位置一致），菜单整体不再让位/压缩；LOGO 常驻最左，与居中菜单自然留出空隙。
   （≤340px 极窄屏由 heroScript 把 LOGO 缩短为「琢器」兜底） */
#nav .nl-short { display: none; } /* 桌面端只显示全称 */
@media screen and (max-width: 736px) {
  #nav .nl-full { display: none; }
  #nav .nl-short { display: inline; }
  /* left 用负值抵消 container 的 1em 内边距，LOGO 更贴屏幕左缘（实测起点约 8px） */
  #navLogo { left: -0.5em; }
  /* LOGO 链接去掉模板 a 的 0.75em 左右内边距并微收字号：
     六字 LOGO 实测 78px 宽会与居中菜单左缘贴上，去掉 padding 后约 56px，
     375px 视口实测留出 27px 空隙（360/320px 也全部无重叠） */
  #navLogo a { font-size: 0.7em; padding: 0; }
}

/* ============================================================
   行距修正（刘先生 2026-09-15 反馈）
   ------------------------------------------------------------
   1) 大标题「刘先生：信息系统项目管理师…」换行后两行叠在一起：
      模板 h1（桌面端）没有声明 line-height，从 body 继承的是
      「固定像素」计算值（1.85em × 16px ≈ 30px），而 h1 字号 3.25em
      （约 52px）—— 52px 的字挤 30px 行距必然重叠。
      模板默认英文短标题永远单行所以从未暴露。
      修法：改用无单位行高（相对自身字号缩放），所有断点生效。
   2) 普通段落行距偏大：body 行高 1.85em（约 1.9 倍字号）偏松，
      段落统一收到 1.65em；#top 的导语段模板自带 1.75em 不变，
      按钮行高走 .adm 专用规则不受影响。
   ============================================================ */
#top h1 {
  line-height: 1.4;
}

p {
  line-height: 1.65em;
}

/* ============================================================
   「看看我在做什么」按钮下留白收短（刘先生 2026-09-16 反馈）
   ------------------------------------------------------------
   #top 区块下留白之前随整体收紧到 4.5em，加上下一块 3em 的
   上留白，按钮到底部空隙仍偏大。#top 单独收到 2.5em
   （ID 选择器优先级更高；#top 同为作品详情/表单页根区块，
   一并变紧凑，风格统一）。
   ============================================================ */
#top {
  padding-bottom: 2.5em;
}

/* ============================================================
   「我在做什么」(#work) 区块收短（刘先生 2026-09-15 要求）
   ------------------------------------------------------------
   反馈：这块太高，翻很久才看到下面的作品。模板数值过大：
     .wrapper 上下 padding 各 8em；图标字号 6em；方块 padding 3em/3.5em。
   处理：仅针对 #work 收紧这三处，其它区块与模板保持一致。
   （ID 选择器优先级高于模板类，所有断点下均生效）
   ============================================================ */
#work {
  padding-top: 3em;
  padding-bottom: 3em;
}
#work .icon.featured:before {
  font-size: 3.5em;
}
#work .icon.featured {
  margin-bottom: 0.8em;
}
#work .box.style1 {
  padding: 1.8em 2em 2.2em 2em;
}

/* ============================================================
   管理页按钮统一（仅 .adm 页面生效，前台不受影响）
   ------------------------------------------------------------
   现象：管理页里同一行的按钮高低不一（「编辑」比「删除」高一截），排不齐。
   根因（全部来自模板 main.css，不是我们写的样式）：
     1. 模板 reset 的 HTML5 元素列表里有 a / ol / li / ul…，但没有 <button>，
        所以 <button class="button"> 不会 font: inherit；
     2. 模板的字体/行高规则只写了 `body, input, textarea, select`，同样没有 button，
        于是 <button> 走浏览器默认字体与 line-height:normal；
     3. 而 <a class="button"> 会从 body 继承 line-height:1.85em。
        两者 padding 相同（1em 2.35em），行高不同 → 高度差约 0.65em，并排时明显错位；
     4. <input type="submit|reset|button"> 是 replaced element，line-height 对它无效，
        高度自成一档，又是一种不一致。
   处理：只补「字体 + 行高 + 高度」这三项对齐相关的属性，
        模板的圆角 / 阴影 / 配色 / 内边距（1em 2.35em）/ 字号（1.1em）一律不动。
   ============================================================ */
.adm a.button,
.adm button,
.adm input[type="submit"],
.adm input[type="reset"],
.adm input[type="button"] {
  font-family: inherit;      /* <button> 不继承，需显式补上（含中文字形一致） */
  line-height: 1.85em;       /* 与 <a class="button"> 继承到的一致 */
  vertical-align: middle;
  box-sizing: border-box;
}

/* input 不受 line-height 影响，用等高补偿：1em(上padding) + 1.85em(行高) + 1em(下padding) */
.adm input[type="submit"],
.adm input[type="reset"],
.adm input[type="button"] {
  height: 3.85em;
  padding-top: 0;
  padding-bottom: 0;
}


/* ============================================================
   留言 / 微信弹窗（2026-09-24）
   - 原生 <dialog>：showModal() 进 top layer（不被祖先 overflow 裁切、自带 Esc 关闭）。
   - 居中必须 top/left 50% + transform —— 拾光同款经验：inset:0 + margin:auto
     对 auto 高度元素分不出余量，会贴在左上角。
   - 模板给 button/.button 的 inset 0 0 0 2px 描边在弹窗里不要，md-close 显式清掉。
   ============================================================ */
dialog.msg-dialog {
  position: fixed;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  margin: 0;   /* ⚠️ 必须清零：UA 给模态 dialog 的默认 margin:auto 会和 50%+translate 叠加，把弹窗顶出视口（2026-10-16 实测 rect.top=-15px 顶部被裁） */
  width: min(34rem, calc(100vw - 2rem));
  max-height: min(82vh, 44rem);
  border: 0;
  padding: 0;
  background: #ffffff;
  color: #212931;
  box-shadow: 0 0 3rem rgba(0, 0, 0, 0.25);
  overflow: auto;
}
dialog.msg-dialog::backdrop {
  background: rgba(20, 22, 26, 0.55);
}
.msg-dialog .md-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.25rem;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}
.msg-dialog .md-title {
  font-weight: 700;
  letter-spacing: 0.05em;
}
.msg-dialog .md-close {
  border: 0;
  background: none;
  box-shadow: none;
  font-family: inherit;
  font-size: 1.4rem;
  line-height: 1;
  color: inherit;
  cursor: pointer;
  padding: 0 0.3rem;
}
.msg-dialog form,
.msg-dialog .md-body {
  padding: 1.25rem;
}
.msg-dialog input[type="text"],
.msg-dialog textarea {
  width: 100%;
  margin-bottom: 1em;
}
.msg-dialog .actions {
  margin-bottom: 0;
}
.msg-dialog input[type="submit"],
.msg-dialog input[type="reset"] {
  height: 3.85em;
  padding-top: 0;
  padding-bottom: 0;
}
.msg-dialog .wx-id {
  font-size: 1.3em;
  margin: 0.4em 0 1em;
}

/* 前台 .actions 里 <button class="button"> 与 <a class="button"> 等高：
   模板 reset 不含 <button>（字体/行高不一致，见上方 .adm 段注释），
   首页联系按钮与作品页「发表评论」混用两种元素，按 .adm 同款思路对齐前台。 */
ul.actions a.button,
ul.actions button.button {
  font-family: inherit;
  line-height: 1.85em;
  vertical-align: middle;
  box-sizing: border-box;
}

/* ============================================================
   ul.social 图标按钮（2026-09-28 起）
   ------------------------------------------------------------
   模板只写了 ul.social li a，「微信 / 留言」是 <button>，这里把
   <button> 镜像成同款样式（数值照抄 main.css），并清掉浏览器默认
   按钮壳。可见的圆角方块 + FontAwesome 字形都画在 :before 伪元素上。

   模板原生机制（关键）：元素 <a>/<button> 本身设品牌色，:before 是一层
   深灰「盖子」(#444 + 深灰字 #2E2E2E)；默认盖子盖住 → 看起来就是灰圆；
   hover 时 :before 变透明、露出元素品牌色，并上浮 5px。
   → 刘先生 2026-10-16 要求：默认灰、hover 才上浮变色。直接复用模板机制，
   只需给四个按钮的元素本身补上品牌色（模板 GitHub 是白色、微信/邮件/留言
   未设），并把 hover 的「盖子透明 + 浮起」补全到 <button> 上即可。
   ============================================================ */
ul.social li button.soc-btn {
  -moz-transition: top .2s ease-in-out;
  -webkit-transition: top .2s ease-in-out;
  transition: top .2s ease-in-out;
  display: block;
  width: 48px;
  height: 48px;
  border-radius: 6px;
  top: 0;
  position: relative;
  background: none;
  border: 0;
  padding: 0;
  margin: 0;
  cursor: pointer;
  font-family: inherit;
  box-shadow: none;
}
/* 2026-10-16 刘先生反馈：默认灰太深、外圈还有一圈颜色。
   → 灰盖调亮为 #8a8a8a，字形转白；inset 描边环（#282828 那圈）整体去掉。
     模板 main.css 的 ul.social li a:before 自带 inset 描边环，此处必须显式置 none。 */
ul.social li a:before,
ul.social li button.soc-btn:before {
  background-color: #8a8a8a;
  color: #2E2E2E;          /* 灰圆 + 深灰字形（与之前 GitHub/邮件一致）；<a> 图标模板本就 #2E2E2E !important，这里统一让 <button> 也用同色 */
  box-shadow: none;
  border-radius: 6px;
}
ul.social li button.soc-btn:before {
  background-image: url("images/bg.png"), -moz-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.2));
  background-image: url("images/bg.png"), -webkit-linear-gradient(top, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.2));
  -moz-transition: background-color .2s ease-in-out, color .2s ease-in-out, top .2s ease-in-out;
  -webkit-transition: background-color .2s ease-in-out, color .2s ease-in-out, top .2s ease-in-out;
  transition: background-color .2s ease-in-out, color .2s ease-in-out, top .2s ease-in-out;
  display: block;
  font-size: 26px;
  height: 48px;
  line-height: 48px;
  text-align: center;
  outline: 0;
  overflow: hidden;
  width: 48px;
}

/* 元素本身设各品牌色（默认被 :before 灰盖盖住 → 平时看不到；hover 才露出） */
ul.social li a.fa-github               { background-color: #181717; } /* GitHub 黑 */
ul.social li button.soc-btn.fa-weixin  { background-color: #07C160; } /* 微信绿 */
ul.social li a.fa-envelope             { background-color: #EA4335; } /* 邮件红 */
ul.social li button.soc-btn.fa-comment { background-color: #43B3E0; } /* 留言蓝 */

/* hover：上浮 5px + :before 透明露品牌色 + 字形转白（<a>/<button> 同款） */
ul.social li a:hover,
ul.social li button.soc-btn:hover { top: -5px; }
ul.social li a:hover:before,
ul.social li button.soc-btn:hover:before {
  background-color: transparent;
  color: #fff !important;
}

/* 留言 / 微信弹窗主标题（2026-09-28 刘先生要求弹窗带主标题） */
.msg-dialog .md-body { padding-top: 0.5rem; }
.msg-dialog .md-h {
  font-size: 1.5em;
  font-weight: 700;
  letter-spacing: 0.02em;
  margin: 0 0 0.25em;
}
.msg-dialog .md-sub {
  margin: 0 0 0.4em;
  color: rgba(33, 41, 49, 0.6);
}
.msg-dialog .md-src {
  margin: 0 0 0.8em;
  font-size: 0.95em;
  font-weight: 600;
  color: #43B3E0;   /* 琢器 accent，仅在有来源（作品页进入）时显示 */
}
.msg-dialog .md-src:empty { display: none; }
