@charset "UTF-8";
:root {
  --black-main: #000000;
  --white-main: #f2f6f8;
  /* You can customize the theme color here */
  --primary-color: #3c7fb1;
  --highlight-color: #aaddfa;
  --secondary-color: #d8e1e7;
  --aero-grad: linear-gradient(to bottom,
  color-mix(in srgb, var(--secondary-color), white 60%) 0%,
  var(--secondary-color) 50%,
  color-mix(in srgb, var(--secondary-color), black 10%) 51%,
  var(--secondary-color) 100%);
  /* 以下变量由主题 _config.yml 的 background / font 段生成
     （layout/_partial/theme-vars.ejs），此处给出未配置时的兜底值 */
  --font-family: "Segoe UI", "Microsoft YaHei", "PingFang SC", "Hiragino Sans GB", sans-serif;
  --code-font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, "Courier New", monospace;
  /* You can customize the background here, or via theme _config.yml */
  --bg-image: url(/image/bliss.jpeg);
  --bg-color: #8ea7b8;
  --bg-size: cover;
  --bg-position: center;
  --bg-repeat: no-repeat;
  --bg-attachment: fixed;
  --bg-overlay: transparent;
}

body {
  font-family: var(--font-family);
  color: var(--black-main);
  margin: 0 auto;
  background-color: var(--bg-color);
  background-image: var(--bg-image);
  background-size: var(--bg-size);
  background-position: var(--bg-position);
  background-repeat: var(--bg-repeat);
  background-attachment: var(--bg-attachment);
}

/* 背景遮罩（主题 _config.yml 的 background.overlay，默认为 transparent） */
body::before {
  content: "";
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: var(--bg-overlay);
  pointer-events: none;
  z-index: 0;
}

.container {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  max-width: 960px;
  margin: auto;
  padding: 0 20px;
  position: relative;
  z-index: 1;
}

.card {
  background: rgba(from var(--primary-color) r g b/0.3);
  box-sizing: border-box;
  box-shadow: inset 0 0 20px rgba(from var(--primary-color) r g b/0.8), 0 0 0 1px var(--white-main), 0 0 0 1.5px var(--black-main), 3px 3px 10px rgba(from var(--black-main) r g b/0.6);
  backdrop-filter: blur(2px);
}

.button-bar {
  background: var(--aero-grad);
  box-shadow: inset 0 0 0 1px var(--white-main), 0 0 0 0.5px var(--black-main), 3px 3px 10px rgba(from var(--black-main) r g b/0.6);
  box-sizing: border-box;
  /* 标签数量/名称由主题 _config.yml 决定，超出宽度时可横向滑动而不是被裁掉 */
  overflow-x: auto;
  overflow-y: hidden;
  scrollbar-width: none;
}

.button-bar::-webkit-scrollbar {
  display: none;
}

.button,
.page-number::before,
.extend::before {
  display: block;
  position: relative;
  border: none;
  outline: none;
  cursor: pointer;
  background: var(--aero-grad);
  box-shadow: inset 0 0 0 1px var(--white-main), 0 0 0 0.5px var(--black-main), 3px 3px 10px rgba(from var(--black-main) r g b/0.6);
  box-sizing: border-box;
}

.button::after,
.page-number::after,
.extend::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to top, var(--highlight-color) 0%, var(--highlight-color) 50%, color-mix(in srgb, var(--highlight-color), black 10%) 51%, var(--highlight-color) 80%);
  box-shadow: inset 0 0 0 2px var(--highlight-color), 0 0 3px var(--highlight-color);
  transition: all 0.2s;
  opacity: 0;
}

.button:hover::after,
.page-number:not(.current):hover::after,
.extend:hover::after {
  opacity: 1;
}

.button:active::after,
.button.active,
.page-number:not(.current):active:after,
.extend:active::after {
  opacity: 1;
  box-shadow: inset 0 5px 5px rgba(0, 0, 0, 0.4);
}

.main-layout {
  display: grid;
  flex: 1;
  grid-template-columns: minmax(0, 1fr) minmax(0, 2.5fr);
  gap: 20px;
}

/* 侧栏比正文栏高时（友链、归档等正文较短的页面），栅格高度由侧栏决定，
   侧栏最后一张卡片会紧贴页脚，这里补出与卡片之间一致的 20px 空隙。
   移动端抽屉自带 padding，不受影响 */
aside {
  padding-bottom: 20px;
}

/* 桌面端：播放器及其下方的信息 / 分类 / 标签挂件作为一整体吸顶悬浮
   （layout.ejs 里的 .sidebar-float 包裹层）。
   组内按 DOM 顺序排列，下面的卡片不再从播放器背后绕过、也就不会被盖住。
   组比视口高时在组内滚动，保证最下面的卡片依然够得着；
   顶栏（约 95px）与吸顶头像（-5px 起、120px 高）都在 140px 之上，不会重叠。
   移动端侧栏是抽屉（fixed + 内部滚动），这里不做处理 */
@media screen and (min-width: 769px) {
  .sidebar-float {
    position: sticky;
    top: 140px;
    z-index: 3;
    max-height: calc(100vh - 160px);
    overflow-y: auto;
    /* 必须留出内边距：overflow-y: auto 会把 overflow-x 也变成 auto，
       而卡片带 3px 3px 10px 的外投影，若卡片边缘与容器边界重合，
       投影就会被裁掉一道硬边（组内卡片与组外卡片观感不一致）。
       负外边距抵消内边距，侧栏占位宽度与卡片宽度都不变 */
    padding: 0 16px 16px;
    margin: 0 -16px -16px;
    /* 内滚动条会破坏 Aero 观感，与顶栏一致隐藏（滚轮 / 触摸仍可滚动） */
    scrollbar-width: none;
  }
  .sidebar-float::-webkit-scrollbar {
    display: none;
  }
}
.mobile-menu-btn, .sidebar-mask {
  display: none;
}

.widget {
  width: 100%;
  margin-top: 20px;
  border-radius: 3px;
}

.page-nav {
  margin-top: 30px;
  justify-content: right;
}

.page-number,
.extend {
  position: relative;
  z-index: 1;
  height: 30px;
  width: 30px;
  border-radius: 50%;
  text-decoration: none;
  color: var(--black-main);
  margin: 0 5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.page-number::before,
.extend::before {
  content: "";
  position: absolute;
  z-index: -2;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  border-radius: inherit;
}

.page-number::after,
.extend::after {
  position: absolute;
  z-index: -1;
  border-radius: inherit;
}

.current {
  top: 1px;
}

.current::before {
  box-shadow: inset 0 5px 5px rgba(0, 0, 0, 0.4), 0 0 0 0.5px var(--black-main);
  /* 3px 3px 10px rgba(from var(--black-main) r g b / 0.6); */
}

.page-nav .space {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  margin: 0 5px;
  color: var(--black-main);
}

.tag-none-link {
  color: var(--primary-color);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: all 0.2s ease;
}

.tag-none-link:hover {
  border-bottom-color: var(--primary-color);
}

.header {
  position: sticky;
  top: 0;
  z-index: 3;
}

header {
  width: 100%;
  height: 80px;
  padding-right: 60px;
  border-radius: 0 0 0 15px;
  overflow: hidden;
  position: relative;
  top: 0;
}

.blog-title {
  position: relative;
  text-align: right;
  /* font-style: italic; */
  font-size: 20px;
  text-shadow: 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main);
}

nav {
  position: relative;
  border-top: none;
  border-radius: 15px;
  padding: 0 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  height: 30px;
  margin-left: 360px;
  top: -15px;
  left: 12px;
}

.nav-links {
  list-style: none;
  padding: 0;
  display: flex;
  box-sizing: border-box;
  height: 100%;
}

.nav-links li {
  display: flex;
  box-sizing: border-box;
  height: 100%;
}

.nav-links li a {
  position: relative;
  box-sizing: border-box;
  height: 100%;
  gap: 8px;
  font-size: 14px;
  line-height: 12px;
  text-decoration: none;
  padding: 0 20px;
  color: var(--black-main);
  box-shadow: inset 0 0 0 1px var(--white-main);
  border-right: 1px solid var(--black-main);
  text-shadow: 0 1px 0 var(--white-main);
}

.nav-text {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  align-items: center;
  gap: 5px;
}

.icon {
  width: 24px;
}

/* 第一个标签补上左边框（其余标签只有右边框） */
.nav-links li:first-child a {
  border-left: 1px solid var(--black-main);
}

/* 导航
   桌面端：.button-bar 顶栏标签（nav.ejs 的 mode='top'）
   移动端：.mobile-nav-widget 侧边展开栏中的列表（mode='side'），
          排列在音乐播放器下方；顶栏标签在移动端隐藏。
   两者共用主题 _config.yml 的 menu.items，标签名与图标均可自定义 */
.mobile-nav-widget {
  display: none;
}

.mobile-nav-title {
  padding: 6px 2px 10px;
  font-size: 15px;
  font-weight: 700;
  text-shadow: 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main);
}

.mobile-nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.mobile-nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  font-size: 15px;
  line-height: 1.2;
  color: var(--black-main);
  text-decoration: none;
  text-shadow: 0 1px 0 var(--white-main);
}

/* .button 的 ::after 高亮层是覆盖整块的，内容需要抬到其上 */
.mobile-nav-item > * {
  position: relative;
  z-index: 2;
}

.mobile-nav-item .icon {
  flex: 0 0 auto;
  width: 22px;
}

.mobile-nav-label {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.post-list {
  margin-top: 20px;
}

.post-item {
  display: flex;
  align-items: stretch;
  gap: 10px;
  padding: 10px;
  border-radius: 3px;
  position: relative;
  margin-bottom: 20px;
}

.post-cover {
  width: 40%;
  flex-shrink: 0;
  padding: 10px 0;
}

.post-cover img {
  width: 100%;
  box-shadow: 0 0 0 0.5px var(--black-main), 0 0 0 1.5px var(--white-main);
}

.post-info {
  display: flex;
  flex: 1;
  flex-direction: column;
}

.post-full {
  margin-top: 20px;
  padding: 10px;
  border-radius: 3px;
  position: relative;
  margin-bottom: 20px;
}

.post-title {
  position: relative;
  font-size: 24px;
  text-shadow: 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main);
}

.post-meta {
  position: relative;
  text-shadow: 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main);
  padding: 5px 0;
}

.post-excerpt {
  position: relative;
  padding: 10px;
  background-color: var(--white-main);
  box-shadow: 0 0 0 0.5px var(--black-main), 0 0 0 1.5px var(--white-main);
}

.post-content {
  position: relative;
  padding: 10px;
  background-color: var(--white-main);
  box-shadow: 0 0 0 0.5px var(--black-main), 0 0 0 1.5px var(--white-main);
}

.rm-link {
  position: relative;
  width: 120px;
  height: 30px;
  display: flex;
  align-self: flex-end;
  margin-top: auto;
  align-items: center;
  justify-content: center;
  border-radius: 15px;
  margin-bottom: -15px;
  text-decoration: none;
  color: var(--black-main);
  text-shadow: 0 1px 0 var(--white-main);
  transition: all 0.2s;
  overflow: hidden;
}

.rm-link::after {
  border-radius: inherit;
}

.rm-link:active {
  top: 1px;
}

.read-more {
  position: relative;
  z-index: 2;
}

.article-title {
  display: block;
  padding: 20px 0;
  font-size: 30px;
}

/* 文章页脚：作者 / 完整发布日期 / 版权声明
   内容与开关见主题 _config.yml 的 post 段。
   它位于 .post-content 内部，是正文白色底上的一张卡片：
   自身不带外框和白色描边，只靠淡蓝底 + 一圈细描边与正文区分，不与文章割裂 */
.post-footer {
  position: relative;
  margin-top: 26px;
  padding: 12px 14px;
  border-radius: 4px;
  font-size: 13px;
  line-height: 1.7;
  color: #1b1b1b;
  background-color: rgba(from var(--primary-color) r g b/0.07);
  box-shadow: inset 0 0 0 1px rgba(from var(--primary-color) r g b/0.3), inset 0 0 0 2px rgba(from var(--white-main) r g b/0.6);
}

.post-footer-row {
  display: flex;
  align-items: baseline;
  gap: 10px;
}

/* 标签做成和导航按钮同款的小色块，避免浅色背景上读不清 */
.post-footer-label {
  flex: 0 0 auto;
  display: inline-block;
  min-width: 4em;
  padding: 1px 8px;
  border-radius: 3px;
  text-align: center;
  font-weight: 700;
  color: var(--black-main);
  background: var(--aero-grad);
  box-shadow: inset 0 0 0 1px var(--white-main), 0 0 0 0.5px var(--black-main);
  text-shadow: 0 1px 0 var(--white-main);
}

.post-footer-value {
  flex: 1 1 auto;
  min-width: 0;
  color: #1b1b1b;
  overflow-wrap: break-word;
}

/* 选择器要盖过 _markdown.scss 里作用于 .post-content a 的通用链接样式 */
.post-footer .post-footer-license-link {
  color: color-mix(in srgb, var(--primary-color), black 15%);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-bottom-color 0.2s ease;
}

.post-footer .post-footer-license-link:hover {
  border-bottom-color: currentColor;
}

.post-footer-license-text {
  display: inline-block;
  margin-left: 4px;
  color: #333;
}

.avatar-widget {
  position: sticky;
  z-index: 4;
  top: -5px;
  background: none;
  border: none;
  box-shadow: none;
  width: 20%;
}

.avatar-bg {
  background: var(--aero-grad);
  backdrop-filter: blur(3px);
  margin-top: -30px;
  margin-left: -10px;
  box-sizing: border-box;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  box-shadow: 0 0 0 1px var(--white-main), 0 0 0 1.5px var(--black-main), 3px 3px 10px rgba(from var(--black-main) r g b/0.6);
}

.profile-img {
  width: 110px;
  box-sizing: border-box;
  position: relative;
  top: 5px;
  left: 5px;
  border-radius: 50%;
  border: 1px solid var(--white-main);
}

.profile-link {
  position: relative;
  display: inline-flex;
  height: 40px;
  width: 40px;
  padding: 8px;
  margin: 6px;
  border-radius: 20px;
}

.profile-icon {
  position: relative;
  width: 100%;
  z-index: 2;
}

.profile-link::after {
  border-radius: 20px;
}

.profile-link:active {
  top: 1px;
}

.profile {
  padding-top: 10px;
  padding-left: 100px;
  height: 80px;
  display: flex;
  flex-direction: column;
  justify-content: space-evenly;
  font-size: larger;
}

.about {
  margin-top: 10px;
  padding: 10px;
}

/* 与 .music-widget 同理：不给 z-index 时，DOM 靠后的卡片滚动经过会盖住头像卡片。
   头像本身是 z-index:4，仍在它之上 */
.profile-widget {
  position: relative;
  z-index: 3;
  margin-top: -90px;
  text-shadow: 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main);
  text-align: center;
}

/* 播放器不再自己吸顶：它与下方的信息/分类卡片由 .sidebar-float 一起承载并吸顶
   （见 _main.scss），组内按 DOM 顺序排列，不会再被后面的卡片绕过或盖住。
   但必须保持定位：::before 是 absolute 的装饰渐变层，static 会让它的包含块
   落到最近的定位祖先上，这层半透明 blob 就会铺满整列 */
.music-widget {
  position: relative;
  z-index: 3;
  background: var(--white-main);
  box-sizing: border-box;
  box-shadow: inset 0 0 30px color-mix(in srgb, var(--primary-color), white 50%), 0 0 0 0.5px var(--black-main), 3px 3px 10px rgba(from var(--black-main) r g b/0.6);
  border-radius: 20% 80% 20% 80%/50% 30% 50% 40%;
  padding: 15px;
}

.music-widget::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(to bottom, rgba(from var(--white-main) r g b/0.8) 0%, rgba(from var(--black-main) r g b/0.1) 100%);
  border-radius: 20% 80% 20% 80%/50% 30% 50% 30%;
  pointer-events: none;
}

.player-content {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  position: relative;
}

.album-art {
  width: 60px;
  height: 60px;
  flex-shrink: 0;
  margin-left: 20px;
  margin-bottom: 10px;
  position: relative;
  background-size: cover;
  background-position: center;
}

.song-info {
  width: 100%;
  display: flex;
  align-items: center;
  margin-bottom: 10px;
  min-width: 0;
}

.info-bg {
  background-color: var(--primary-color);
  box-shadow: inset 0 3px 5px rgba(0, 0, 0, 0.5), 0 0 0 0.5px var(--black-main), 0 0 0 1.5px var(--white-main);
  border-radius: 3px;
}

.title-bar {
  flex: 1;
  width: 0;
  min-width: 0;
  overflow: hidden;
  margin-left: 10px;
  border-radius: 10px;
}

.song-title {
  font-size: 14px;
  color: var(--white-main);
  text-shadow: 0 3px 3px var(--black-main);
  display: inline-block;
  white-space: nowrap;
  animation: marquee 8s linear infinite;
}

@keyframes marquee {
  0% {
    transform: translateX(0%);
  }
  20% {
    transform: translateX(0%);
  }
  80% {
    transform: translateX(-100%);
  }
  100% {
    transform: translateX(-100%);
  }
}
.progress-container {
  width: 90%;
  height: 6px;
  border-radius: 3px;
  margin-bottom: 12px;
  margin-left: 16px;
  box-shadow: inset 0 2px 3px rgba(0, 0, 0, 0.5), 0 0 0 0.5px var(--black-main), 0 0 0 1.5px var(--white-main);
}

.progress-bar {
  width: 0%;
  height: 100%;
  background: linear-gradient(to bottom, var(--secondary-color) 0%, var(--primary-color) 50%, var(--secondary-color) 100%);
  border-radius: 3px;
  transition: width 0.1s linear;
}

.controls {
  position: relative;
  margin-left: -60px;
  margin-bottom: -20px;
  display: flex;
  gap: 15px;
  align-items: center;
}

.ctrl-btn {
  border-radius: 50%;
  width: 35px;
  height: 35px;
  display: flex;
  justify-content: center;
  align-items: center;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.1s;
  overflow: hidden;
}

.ctrl-btn span {
  position: relative;
  z-index: 2;
}

.play-btn {
  width: 50px;
  height: 50px;
  border-radius: 70% 30% 70% 30%/70% 30% 70% 30%;
  font-size: 18px;
  overflow: hidden;
}

.play-btn span {
  position: relative;
  z-index: 2;
}

.ctrl-btn:active {
  top: 1px;
}

.play-btn:active {
  top: 1px;
}

.ctrl-btn::after {
  border-radius: inherit;
}

.play-btn::after {
  border-radius: inherit;
}

/* 侧边栏附加组件（layout/_partial/site-widgets.ejs）
   站点信息（运行时间 / 文章数）、文章分类菜单、文章标签菜单 */
.info-widget,
.taxonomy-widget {
  padding: 12px 14px;
  border-radius: 3px;
}

.widget-title {
  margin-bottom: 8px;
  font-size: 15px;
  font-weight: 700;
  text-shadow: 0 1px 0 var(--white-main);
}

.info-list,
.taxonomy-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

/* 卡片本身是半透明玻璃质感，壁纸会透上来，
   蓝色标签直接压在壁纸上对比度只有 1.75:1（截图实测，几乎看不清）。
   这里垫一层接近正文白底的内嵌面板，让标签和数值都有稳定的底色；
   它与播放器的 .info-bg、分类标签的色块是同一套「玻璃面板」思路 */
.info-list {
  padding: 8px 10px;
  border-radius: 3px;
  background-color: rgba(from var(--white-main) r g b/0.8);
  box-shadow: inset 0 0 0 1px var(--white-main), inset 0 0 0 2px rgba(from var(--primary-color) r g b/0.3);
}

.info-item {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  font-size: 13px;
  line-height: 1.5;
}

/* 保留主题的蓝色点缀，但压深一档：
   配合上面的浅色面板，实测对比度 5.52:1，达到 WCAG AA 对正文的 4.5:1 要求 */
.info-label {
  flex: 0 0 auto;
  color: color-mix(in srgb, var(--primary-color), black 28%);
  font-weight: 700;
  text-shadow: 0 1px 0 var(--white-main);
}

.info-value {
  flex: 1 1 auto;
  min-width: 0;
  text-align: right;
  color: #1b1b1b;
  overflow-wrap: break-word;
}

.taxonomy-item {
  line-height: 1.4;
}

.taxonomy-link {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  padding: 4px 8px;
  border-radius: 3px;
  font-size: 13px;
  color: var(--black-main);
  text-decoration: none;
  background: var(--aero-grad);
  box-shadow: inset 0 0 0 1px var(--white-main), 0 0 0 0.5px var(--black-main);
  text-shadow: 0 1px 0 var(--white-main);
  transition: filter 0.15s ease;
}

.taxonomy-link:hover,
.taxonomy-link.active {
  filter: brightness(1.06) saturate(1.3);
}

.taxonomy-link.active {
  box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.35), 0 0 0 0.5px var(--black-main);
}

.taxonomy-name {
  flex: 1 1 auto;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.taxonomy-count {
  flex: 0 0 auto;
  min-width: 20px;
  padding: 0 5px;
  border-radius: 10px;
  font-size: 12px;
  text-align: center;
  color: var(--white-main);
  background: var(--primary-color);
  /* text-shadow 会从 .taxonomy-link 继承下来，而那层是给浅色底上的深色文字
     用的白色投影；这里是白字配蓝色底，白影只会让数字重影、发虚，直接去掉 */
  text-shadow: none;
  box-shadow: inset 0 1px 2px rgba(0, 0, 0, 0.35);
}

.taxonomy-empty {
  font-size: 13px;
  color: #666;
}

.year-group {
  padding: 10px;
  border-radius: 3px;
  margin: 20px 0;
}

.year-header {
  font-size: 24px;
  text-shadow: 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main);
  padding: 10px 0;
}

.archive-list {
  padding: 10px;
  background-color: var(--white-main);
  box-shadow: 0 0 0 0.5px var(--black-main), 0 0 0 1.5px var(--white-main);
}

.archive-item {
  padding: 5px 0;
  width: 100%;
}

.archive-title {
  margin-left: 5px;
  color: var(--primary-color);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: all 0.2s;
}

.archive-title:hover {
  border-bottom-color: var(--primary-color);
}

/* 友链页面（layout/links.ejs），列表数据来自 source/_data/link.yml。
   整块嵌在 .post-content 里，所以选择器统一挂在其下，
   以压过 _markdown.scss 中作用于正文 img / ul / li 的通用样式 */
.post-content .flink-desc {
  margin: -0.4em 0 0;
  color: var(--primary-color);
  font-size: 0.9em;
  text-shadow: 0 1px 0 var(--white-main);
}
.post-content .flink-list {
  list-style: none;
  margin-bottom: 0;
  padding-left: 0;
  padding-top: 10px;
}
.post-content .flink-list-item {
  margin-bottom: 0;
  line-height: 1.5;
}
.post-content .flink-list-item a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 6px 2px;
  border-bottom: 1px solid transparent;
}
.post-content .flink-list-item a:hover {
  border-bottom-color: var(--primary-color);
}
.post-content .flink-item-avatar {
  flex: 0 0 28px;
  width: 28px;
  height: 28px;
  margin: 0;
  border-radius: 50%;
  object-fit: cover;
  background: var(--secondary-color);
  box-shadow: 0 0 0 1px var(--white-main), 0 0 0 1.5px var(--black-main);
}
.post-content .flink-item-name {
  flex: 0 0 auto;
  font-weight: 700;
  color: var(--primary-color);
}
.post-content .flink-item-desc {
  flex: 1 1 auto;
  min-width: 0;
  color: #555;
  font-size: 0.9em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

footer {
  border-radius: 15px 15px 0 0;
  margin-bottom: 0;
  height: 80px;
  display: flex;
}

.copyright {
  width: 100%;
  align-items: center;
  text-align: center;
  text-shadow: 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main), 0 0 10px var(--white-main);
}

/* RSS 订阅图标（主题 source/img/rss.png，Frutiger Aero 风格） */
.footer-rss {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-left: 6px;
  vertical-align: middle;
  border-radius: 4px;
  transition: transform 0.15s ease, filter 0.15s ease;
}

.footer-rss:hover {
  transform: translateY(-1px);
  filter: brightness(1.08) saturate(1.2);
}

.footer-rss-icon {
  display: block;
  width: 22px;
  height: 22px;
}

.post-content h1,
.post-content h2,
.post-content h3,
.post-content h4,
.post-content h5,
.post-content h6 {
  margin-top: 1.5em;
  margin-bottom: 0.8em;
  font-weight: 700;
  line-height: 1.3;
}

.post-content p {
  margin-bottom: 1.5em;
  text-align: justify;
}

.post-content a {
  color: var(--primary-color);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: all 0.2s ease;
}

.post-content a:hover {
  border-bottom-color: var(--primary-color);
}

.post-content strong {
  font-weight: 700;
  color: #000;
}

.post-content em {
  font-style: italic;
}

.post-content del {
  color: #999;
  text-decoration: line-through;
}

.post-content ul,
.post-content ol {
  margin-bottom: 1.5em;
  padding-left: 2em;
}

.post-content li {
  margin-bottom: 0.5em;
  line-height: 1.8;
}

.post-content li ul,
.post-content li ol {
  margin-top: 0.5em;
  margin-bottom: 0;
}

.post-content blockquote {
  margin: 0 0 1.5em 0;
  padding: 10px 20px;
  border-left: 4px solid #dfe2e5;
  background-color: #f8f9fa;
  color: #6a737d;
}

.post-content blockquote p {
  margin: 0;
}

.post-content img {
  max-width: 100%;
  height: auto;
  display: block;
  margin: 1.5em auto;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.post-content table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5em;
  display: block;
  overflow-x: auto;
}

.post-content th,
.post-content td {
  border: 1px solid #dfe2e5;
  padding: 6px 13px;
}

.post-content th {
  background-color: #f6f8fa;
  font-weight: 700;
}

.post-content tr:nth-child(2n) {
  background-color: #f8f9fa;
}

.post-content :not(pre) > code {
  background-color: rgba(27, 31, 35, 0.05);
  color: var(--primary-color);
  padding: 0.2em 0.4em;
  border-radius: 3px;
  font-family: var(--code-font-family);
  font-size: 85%;
}

.post-content pre,
.post-content .highlight {
  background-color: #fafafa;
  padding: 5px;
  margin: 0;
  border-radius: 3px;
  overflow-x: auto;
  line-height: 1.45;
  font-family: var(--code-font-family);
  font-size: 14px;
}

.post-content .highlight table {
  margin: 0;
  border: none;
  display: table;
}

.post-content .highlight td,
.post-content .highlight th {
  border: none;
  padding: 0;
}

.post-content .highlight .gutter {
  color: #999;
  text-align: right;
  border-right: 1px solid #eee;
}

/* MathJax v3 输出 */
.markdown-body .mjx-chtml,
.post-content mjx-container {
  outline: 0;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: hidden;
}

/* PJAX 页面切换过渡（source/js/pjax-transition.js）
   #pjax-container（正文）与 #pjax-header（顶栏）是 pjax 的替换目标：
   切换时先变淡、轻微上移，新内容再淡入并回落，避免整块生硬地闪替。
   侧边栏（头像、播放器、站点信息等）不在替换范围内、内容不会变，
   但同样套用这组过渡，让它与正文、顶栏同向出现 */
#pjax-container,
#pjax-header {
  transition: opacity 0.22s ease, transform 0.22s ease;
}

/* 离开：变淡并轻微上移，作为「已响应点击」的即时反馈。
   它是一个静止状态，整个加载期间保持；
   导航完成（或出错）时由脚本移除，不会残留 */
#pjax-container.pjax-leaving,
#pjax-header.pjax-leaving {
  opacity: 0.35;
  transform: translateY(-3px);
}

/* 进入：用 keyframes，而不是「先置为透明再移除类」的过渡写法。
   过渡写法依赖下一帧的回调，页面被浏览器节流（后台标签、不可见）时
   回调不会执行，类会一直挂着、正文就停在 opacity:0，看起来像整页空白。
   keyframes 里元素自身的样式始终是常态，动画只是叠加在上面的临时效果，
   即使动画没能播放也不会把内容卡住 */
#pjax-container.pjax-entering,
#pjax-header.pjax-entering {
  animation: pjax-enter 0.24s ease;
}

@keyframes pjax-enter {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}
/* 侧边栏沿用同一组过渡，方向与正文、顶栏一致（先上移变淡，再从下方淡入）。
   仅限桌面端：移动端的侧栏是抽屉，靠 translateX 开合，
   这里的 transform 会盖掉抽屉的位移、让关闭的抽屉也显出来 */
@media screen and (min-width: 769px) {
  #sidebar {
    transition: opacity 0.22s ease, transform 0.22s ease;
  }
  #sidebar.pjax-leaving {
    opacity: 0.35;
    transform: translateY(-3px);
  }
  #sidebar.pjax-entering {
    animation: pjax-enter 0.24s ease;
  }
}
/* 系统开启「减少动态效果」时不做过渡（js 里也会跳过标记类的切换） */
@media (prefers-reduced-motion: reduce) {
  #pjax-container,
  #pjax-header,
  #sidebar {
    transition: none;
  }
  #pjax-container.pjax-leaving,
  #pjax-header.pjax-leaving,
  #sidebar.pjax-leaving {
    opacity: 1;
    transform: none;
  }
  #pjax-container.pjax-entering,
  #pjax-header.pjax-entering,
  #sidebar.pjax-entering {
    animation: none;
  }
}
/* 顶栏标签数量/名称现在由主题 _config.yml 的 menu.items 决定，
   标签变多时容器会先收缩、标签被挤出。提前取消 nav 的 360px 左偏移，
   并允许 .button-bar 横向滑动（见 _main.scss），标签不再被裁掉 */
@media screen and (max-width: 1024px) {
  nav {
    margin-left: 0;
    left: 0;
  }
}
@media screen and (max-width: 768px) {
  * {
    -webkit-tap-highlight-color: transparent;
  }
  /* iOS 上 background-attachment: fixed 会导致背景不显示，改为随页面滚动 */
  body {
    background-attachment: scroll;
  }
  .main-layout {
    display: block;
  }
  header {
    border-radius: 0;
  }
  /* 顶栏标签已整合进侧边展开栏（.mobile-nav-widget），不再显示 */
  .header .button-bar {
    display: none;
  }
  .mobile-nav-widget {
    display: block;
    margin-top: 20px;
  }
  .mobile-menu-btn {
    position: fixed;
    top: 90px;
    left: 0;
    z-index: 10;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 30px;
    height: 30px;
    font-size: 18px;
    cursor: pointer;
    border-radius: 0 15px 15px 0;
    overflow: hidden;
    margin: 10px 0;
  }
  .mobile-menu-btn::after {
    border-radius: inherit;
  }
  .menu-icon {
    z-index: 12;
  }
  aside {
    position: fixed;
    top: 0;
    left: 0;
    width: 260px;
    height: 100vh;
    background-color: var(--bg-color);
    background-image: var(--bg-image);
    background-size: var(--bg-size);
    background-position: var(--bg-position);
    background-repeat: var(--bg-repeat);
    z-index: 100;
    padding: 20px;
    overflow-y: auto;
    overscroll-behavior: contain;
    box-shadow: 2px 0 8px rgba(0, 0, 0, 0.15);
    transform: translateX(-100%);
    transition: transform 0.3s ease-in-out;
  }
  aside.open {
    transform: translateX(0);
  }
  /* 抽屉里是纵向滚动的列表，头像与播放器不再吸附，负外边距也一并取消 */
  .avatar-widget {
    position: static;
    margin-top: 0;
  }
  /* 播放器已不再吸顶（基础规则就是 relative），抽屉里按正常流排列即可。
     注意别改成 static：.music-widget::before 的包含块会落到抽屉上 */
  .avatar-bg {
    margin-top: 0;
    margin-left: 0;
  }
  .profile-widget {
    margin-top: 10px;
  }
  .sidebar-mask {
    display: block;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.5);
    z-index: 99;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s;
  }
  .sidebar-mask.open {
    opacity: 1;
    visibility: visible;
  }
  .post-item {
    flex-direction: column;
    gap: 0;
  }
  .post-cover {
    width: 100%;
  }
}
/* 窄屏下文章页脚的「标签 / 内容」改为上下排列 */
@media screen and (max-width: 560px) {
  .post-footer-row {
    flex-direction: column;
    gap: 0;
  }
  .post-footer-label {
    min-width: 0;
  }
}