/* Jz52_paper · Z-Blog 适配补充样式
   1) 系统内置侧栏模块通用样式  2) 评论列表与表单  3) 页面小部件补齐
   复用为主：所有内置模块共用同一套列表 / 链接 / 表单规则，只在少数模块上做定点修正。 */

/* ========== 1. 侧栏模块通用（divCalendar / divTags / divArchives / divCatalog /
   divComments / divAuthors / divStatistics / divSearchPanel / divLinkage /
   divFavorites / divMisc / divContorPanel / divSiteInfo …） ========== */

.paper-sidebar .widget .widget-body {
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.7;
}

.paper-sidebar .widget .widget-title {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  font-size: 16px;
  font-weight: 700;
  color: var(--ink);
}

.paper-sidebar .widget .widget-title::before {
  content: "";
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-accent);
  box-shadow: 0 0 0 3px var(--color-accent-soft);
}

/* 列表型模块（分类 / 归档 / 评论 / 作者 / 收藏 / 友链 / 杂项 / 控制面板） */
.paper-sidebar .widget .widget-body ul,
.paper-sidebar .widget .widget-body ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

.paper-sidebar .widget .widget-body li {
  display: flex;
  align-items: baseline;
  gap: 6px;
  padding: 7px 0;
  border-bottom: 1px dashed var(--dash);
}

.paper-sidebar .widget .widget-body li:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.paper-sidebar .widget .widget-body li a {
  flex: 1;
  min-width: 0;
  color: var(--ink-soft);
  text-decoration: none;
  transition: color 0.2s ease, transform 0.2s ease;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.paper-sidebar .widget .widget-body li a:hover {
  color: var(--color-accent-strong);
  transform: translateX(2px);
}

.paper-sidebar .widget .widget-body li span,
.paper-sidebar .widget .widget-body li small,
.paper-sidebar .widget .widget-body li em {
  color: var(--muted);
  font-size: 12px;
  font-style: normal;
  flex: 0 0 auto;
}

/* 归档 / 分类模块的分组子项 */
.paper-sidebar .widget .widget-body li ul {
  padding-left: 14px;
}

.paper-sidebar .widget .widget-body li ul li {
  border-bottom: 0;
  padding: 4px 0;
  font-size: 13px;
}

/* 标签云（divTags / 标签模块） */
.paper-sidebar .widget .widget-body .tags,
.paper-sidebar .widget .widget-body .tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.paper-sidebar .widget .widget-body .tags a,
.paper-sidebar .widget .widget-body .tag-cloud a {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border: 1px dashed var(--dash);
  border-radius: 999px;
  color: var(--ink-soft);
  background: var(--paper-warm);
  font-size: 13px;
  text-decoration: none;
  transition: color 0.2s ease, background-color 0.2s ease, transform 0.2s ease;
}

.paper-sidebar .widget .widget-body .tags a:hover,
.paper-sidebar .widget .widget-body .tag-cloud a:hover {
  color: var(--color-accent-strong);
  background: var(--color-accent-soft);
  transform: translateY(-1px);
}

.paper-sidebar .widget .widget-body .tag-cloud a em {
  color: var(--muted);
  font-size: 11px;
  font-style: normal;
}

/* 日历模块 */
.paper-sidebar .widget .widget-body table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
}

.paper-sidebar .widget .widget-body table th,
.paper-sidebar .widget .widget-body table td {
  padding: 4px 2px;
  text-align: center;
  border-bottom: 1px dashed var(--dash);
}

.paper-sidebar .widget .widget-body table th {
  color: var(--muted);
  font-weight: 600;
}

.paper-sidebar .widget .widget-body table td a {
  color: var(--ink-soft);
  text-decoration: none;
}

.paper-sidebar .widget .widget-body table td a:hover {
  color: var(--color-accent-strong);
}

/* 统计模块 */
.paper-sidebar .widget .widget-body .statistics,
.paper-sidebar .widget .widget-body ul.statistics li {
  display: flex;
  justify-content: space-between;
}

/* 搜索模块 / 控制面板里的输入框 */
.paper-sidebar .widget .widget-body form {
  display: flex;
  gap: 8px;
  align-items: center;
}

.paper-sidebar .widget .widget-body input[type="text"],
.paper-sidebar .widget .widget-body input[type="search"],
.paper-sidebar .widget .widget-body input[type="email"],
.paper-sidebar .widget .widget-body input[type="url"] {
  flex: 1;
  min-width: 0;
  padding: 8px 12px;
  border: 1px dashed var(--dash);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: 13px;
  outline: none;
}

.paper-sidebar .widget .widget-body input:focus {
  border-color: var(--color-accent);
}

.paper-sidebar .widget .widget-body button,
.paper-sidebar .widget .widget-body input[type="submit"] {
  padding: 8px 16px;
  border: 0;
  border-radius: 999px;
  background: var(--color-accent);
  color: #fff;
  font: inherit;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease;
}

.paper-sidebar .widget .widget-body button:hover,
.paper-sidebar .widget .widget-body input[type="submit"]:hover {
  background: var(--color-accent-strong);
  transform: translateY(-1px);
}

/* 主题自带「最新评论」模块的列表 */
.paper-comment-list {
  margin: 0;
  padding: 0;
  list-style: none;
  display: grid;
  gap: 10px;
}

.paper-comment-list li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.paper-comment-list .cmt-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  flex: 0 0 auto;
}

.paper-comment-list .cmt-body {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 8px;
  min-width: 0;
  font-size: 13px;
}

.paper-comment-list .cmt-name {
  color: var(--ink);
  font-weight: 600;
}

.paper-comment-list .cmt-date {
  color: var(--muted);
  font-size: 12px;
}

.paper-comment-list .cmt-text {
  flex: 1 0 100%;
  color: var(--ink-soft);
  text-decoration: none;
  line-height: 1.6;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.paper-comment-list .cmt-text:hover {
  color: var(--color-accent-strong);
}

/* ========== 2. 评论列表与表单 ========== */
.comment-list {
  display: grid;
  gap: 14px;
  margin-bottom: 22px;
}

.comment-item {
  display: flex;
  gap: 12px;
  padding: 12px 14px;
  border: 1px dashed var(--dash);
  border-radius: 14px;
  background: var(--paper);
}

.comment-item--child,
.comment-level-2 .comment-item {
  background: var(--paper-warm);
}

.comment-avatar {
  flex: 0 0 auto;
  align-self: flex-start;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  overflow: hidden;
  background: var(--paper-warm);
}

.comment-avatar img {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: block;
  object-fit: cover;
}

.comment-body {
  flex: 1;
  min-width: 0;
}

.comment-meta {
  display: flex;
  align-items: baseline;
  gap: 10px;
  margin-bottom: 4px;
}

.comment-author {
  color: var(--ink);
  font-weight: 700;
  font-size: 14px;
}

.comment-author a {
  color: inherit;
  text-decoration: none;
}

.comment-date {
  color: var(--muted);
  font-size: 12px;
}

.comment-text {
  color: var(--ink-soft);
  font-size: 14px;
  line-height: 1.75;
  word-break: break-word;
}

.comment-text p {
  margin: 0 0 6px;
}

.comment-actions {
  margin-top: 4px;
}

.comment-reply-link {
  color: var(--color-accent-strong);
  font-size: 12px;
  text-decoration: none;
}

.comment-reply-link:hover {
  text-decoration: underline;
}

.child-comments {
  margin-top: 10px;
  display: grid;
  gap: 10px;
  padding-left: 6px;
  border-left: 2px dashed var(--dash);
}

.comment-empty {
  color: var(--muted);
  font-size: 14px;
}

.comment-pager {
  margin-top: 10px;
}

.comment-respond {
  padding-top: 8px;
  border-top: 1px dashed var(--dash);
}

.comment-respond__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 12px;
}

.comment-respond__head h3 {
  margin: 0;
  font-size: 16px;
}

#cancel-reply {
  color: var(--muted);
  font-size: 12px;
  text-decoration: none;
}

#cancel-reply:hover {
  color: var(--color-accent-strong);
}

.comment-fields {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-bottom: 10px;
}

.comment-fields .comment-field {
  flex: 1 1 190px;
  min-width: 0;
}

.comment-field {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 12px;
  border: 1px dashed var(--dash);
  border-radius: 999px;
  background: var(--paper);
}

.comment-field .paper-ico {
  color: var(--muted);
  flex: 0 0 auto;
}

.comment-field input {
  flex: 1;
  width: 100%;
  font-size: 13px;
  min-width: 0;
  border: 0;
  outline: none;
  background: transparent;
  color: var(--ink);
  font: inherit;
  font-size: 14px;
}

#txaArticle {
  width: 100%;
  padding: 12px 14px;
  border: 1px dashed var(--dash);
  border-radius: 14px;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  line-height: 1.7;
  resize: vertical;
  outline: none;
}

#txaArticle:focus,
.comment-field:focus-within {
  border-color: var(--color-accent);
}

.comment-logged {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 10px;
  color: var(--ink-soft);
  font-size: 13px;
}

.comment-logged-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
}

.comment-verify {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-top: 10px;
}

.comment-verify input {
  width: 120px;
  padding: 8px 12px;
  border: 1px dashed var(--dash);
  border-radius: 999px;
  background: var(--paper);
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  outline: none;
}

.comment-verify img {
  height: 34px;
  border-radius: 8px;
}

.comment-submit {
  margin-top: 12px;
}

.comment-submit button {
  padding: 10px 24px;
  border: 0;
  border-radius: 999px;
  background: var(--color-accent);
  color: #fff;
  font: inherit;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  transition: background-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.comment-submit button:hover {
  background: var(--color-accent-strong);
  transform: translateY(-2px);
  box-shadow: 0 8px 18px rgba(var(--paper-shadow-rgb), 0.16);
}

.comment-message {
  font-size: 13px;
  color: var(--color-accent-strong);
}

.comment-message:empty {
  display: none;
}

/* 帖子内的评论列表 / 侧栏最新评论共用行距 */
.paper-comment-list li,
.comment-item {
  animation: none;
}

/* ========== 3. 页面小部件补齐 ========== */
.code-copy {
  position: absolute;
  top: 8px;
  right: 8px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
  padding: 4px 10px;
  border: 1px dashed var(--dash);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  color: var(--ink-soft);
  font: inherit;
  font-size: 12px;
  cursor: pointer;
  opacity: 0;
  transition: opacity 0.2s ease, background-color 0.2s ease;
}

.article-content pre {
  position: relative;
}

.article-content pre:hover .code-copy,
.code-copy:focus-visible {
  opacity: 1;
}

/* 移动端：评论输入框单列，抽屉里的模块更紧凑 */
@media (max-width: 768px) {
  .comment-fields {
    grid-template-columns: 1fr;
  }

  .comment-avatar img {
    width: 34px;
    height: 34px;
  }

  .paper-sidebar .widget .widget-title {
    font-size: 15px;
  }
}

/* 导航文字不折行，保持原版单行胶囊条目 */
.site-nav-link,
.site-nav a,
.site-nav-menu a,
.site-nav-menu {
  white-space: nowrap;
}

/* 归档条目：第三列是原主题的空心小箭头 */
.archive-item em {
  justify-self: end;
}

/* 移动端抽屉里的导航：模块输出直接铺成竖排，子菜单常显（触屏无 hover） */
@media (max-width: 960px) {
  .site-nav-drawer .site-nav-item {
    display: block;
    width: 100%;
  }

  .site-nav-drawer .site-nav-link {
    display: flex;
    width: 100%;
    justify-content: flex-start;
    padding: 9px 12px;
    border-radius: 10px;
    font-size: 15px;
  }

  .site-nav-drawer .site-nav-menu {
    position: static;
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin: 2px 0 6px 12px;
    padding: 0 0 0 10px;
    border: 0;
    border-left: 2px dashed var(--dash);
    border-radius: 0;
    background: transparent;
    box-shadow: none;
    opacity: 1;
    visibility: visible;
    transform: none;
    pointer-events: auto;
  }

  .site-nav-drawer .site-nav-menu::before {
    display: none;
  }

  .site-nav-drawer .site-nav-menu a {
    padding: 7px 10px;
    font-size: 14px;
  }
}


/* ===== 开屏打字机（原版 typed 效果的最小样式补充） ===== */
.home-hero__typed-text {
  white-space: pre-wrap;
}

.home-hero__typed-cursor {
  display: inline-block;
  margin-left: 1px;
  color: var(--ink-soft);
  font-weight: 400;
  animation: jz-typed-caret 1s steps(1) infinite;
}

@keyframes jz-typed-caret {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .home-hero__typed-cursor {
    animation: none;
  }
}

/* ===== 打赏气泡：未配置收款码时的占位文案 ===== */
.reaction-bubble-empty {
  margin: 6px 0 2px;
  color: var(--muted);
  font-size: 12px;
  line-height: 1.6;
  text-align: center;
}