
/* Main Layout */
.main-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 24px;
}
.main-content { min-width: 0; }

/* ===== post detail ===== */
.post { background: #fff; border: 1px solid #ebeef5; border-radius: 12px; padding: 30px 34px; }
.post-title { font-size: 24px; font-weight: 700; color: #111827; line-height: 1.45; letter-spacing: -0.5px; margin-bottom: 14px; }
.post-meta { display: flex; align-items: center; flex-wrap: wrap; gap: 14px; font-size: 13px; color: #9ca3af; padding-bottom: 16px; border-bottom: 1px solid #f3f4f6; }
.post-meta .pm-author { color: #2563eb; }
.post-meta .pm-cat a { color: #2563eb; text-decoration: none; }
.post-meta .pm-cat a:hover { text-decoration: underline; }
.post-meta .iconfont { font-size: 14px; margin-right: 4px; vertical-align: -2px; }
.post-content {
    font-size: 15px;
    color: #374151;
    line-height: 1.9;
    padding: 20px 0;
    white-space: normal;
    /* word-wrap: break-word; */
    overflow-wrap: break-word;
    word-break: break-word;
}
/* a 标签超链接 */
.post-content a {
  color: #2563eb;           /* 默认蓝色，可改 */
  text-decoration: none;    /* 去掉下划线，想保留就删掉这行 */
  transition: color 0.2s;   /* 变色过渡更顺滑 */
}

.post-content a:hover {
  color: #1d4ed8;           /* 悬停变深蓝 */
  text-decoration: underline; /* 悬停加下划线，可选 */
}

.post-content a:visited {
  color: #7c3aed;           /* 访问过变色，可选 */
}
.post-content p { margin: 0 0 18px; }
.post-content h2 { font-size: 19px; color: #1f2937; margin: 26px 0 12px; padding-left: 12px; border-left: 4px solid #2563eb; }
.post-content h3 { font-size: 17px; color: #1f2937; margin: 22px 0 10px; }
.post-content strong { color: #1f2937; }
.post-content img { max-width: 100%; border-radius: 10px; display: block; margin: 6px auto 20px; border: 1px solid #eef1f6; }
.post-content blockquote { margin: 18px 0; padding: 12px 18px; background: #f8faff; border-left: 4px solid #93c5fd; color: #6b7280; border-radius: 0 8px 8px 0; }
.post-tags { display: flex; flex-wrap: wrap; gap: 8px; padding: 16px 0; border-top: 1px solid #f3f4f6; }
.post-tags a { font-size: 12px; color: #6b7280; background: #f3f4f6; padding: 4px 12px; border-radius: 14px; text-decoration: none; transition: all .2s; }
.post-tags a:hover { background: #eff6ff; color: #2563eb; }
.post-actions { display: flex; align-items: center; justify-content: center; gap: 14px; padding-top: 22px; border-top: 1px solid #f3f4f6; }
.like-count { font-weight: 700; }
/*.post-actions .btn.liked { background: #ef4444; border-color: #ef4444; color: #fff; }*/


/* Sidebar */
.sidebar { min-width: 0; }
.side-card {
  padding: 18px 20px;
  margin-bottom: 16px;
}
.side-title {
  font-size: 15px;
  font-weight: 600;
  color: #111827;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid #f3f4f6;
  display: flex;
  align-items: center;
  gap: 6px;
}
.side-title .iconfont { color: #2563eb; font-size: 16px; }
.side-title .na-more {
  margin-left: auto;
  font-size: 12px;
  font-weight: 400;
  color: #9ca3af;
  text-decoration: none;
  transition: color .2s ease;
}
.side-title .na-more:hover { color: #2563eb; }
/* 最新文章列表（复用首页“今日热门”小圆点 + hover 填充特效） */
.latest-list { padding: 4px 0 8px; }
.latest-list li {
  padding: 0;
  list-style: none;
  border-bottom: 1px solid #f5f6f8;
}
.latest-list li a {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 9px 16px;
  font-size: 13px;
  color: #374151;
  text-decoration: none;
}
.latest-list li:last-child { border-bottom: none; }
.latest-list .ll-t {
  flex: 1;
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.latest-list .ll-t::before {
  content: '';
  display: inline-block;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  border: 1.5px solid #c7d2fe;
  margin-right: 7px;
  vertical-align: middle;
  flex-shrink: 0;
  transition: all .25s ease;
}
.latest-list .ll-d { flex-shrink: 0; font-size: 12px; color: #9ca3af; }
.latest-list li:hover { background: #f8faff; }
.latest-list li:hover .ll-t { color: #2563eb; }
.latest-list li:hover .ll-t::before { background: #93c5fd; border-color: #93c5fd; }
/* 广告位（预留）—— 虚线占位，可替换为真实广告图 */
.side-ad {
  position: relative;
  margin-bottom: 16px;
  padding: 18px 20px;
  background: #fff;
  border: 1px solid #ebeef5;
  border-radius: 10px;
  overflow: hidden;
  cursor: pointer;
}
.side-ad .sa-tag {
  position: absolute;
  top: 0;
  left: 0;
  background: rgba(0,0,0,.06);
  color: #6b7280;
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 0 0 6px 0;
}
.side-ad .sa-inner {
  height: 170px;
  border: 1.5px dashed #d1d5db;
  border-radius: 8px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 8px;
  color: #9ca3af;
}
.side-ad .sa-icon { font-size: 30px; }
.side-ad .sa-title { font-size: 14px; color: #6b7280; margin: 0; }
.side-ad .sa-size { font-size: 12px; color: #c0c4cd; }
.side-rank-list li {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px dashed #f0f0f0;
  transition: all 0.2s;
}
.side-rank-list li:last-child { border-bottom: none; }
.side-rank-list li:hover { padding-left: 4px; }
.side-rank-list li:hover .side-rank-name { color: #2563eb; }
.rank-num {
  width: 20px;
  height: 20px;
  border-radius: 4px;
  background: #e5e7eb;
  color: #6b7280;
  font-size: 12px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.rank-num.top1 { background: #fef3c7; color: #b45309; }
.rank-num.top2 { background: #f3f4f6; color: #6b7280; }
.rank-num.top3 { background: #fef3c7; color: #d97706; }
.side-rank-name {
  flex: 1;
  font-size: 13px;
  color: #374151;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color 0.2s;
}
.side-rank-heat { font-size: 12px; color: #9ca3af; flex-shrink: 0; }

/* Ad placeholder */
.ad-box {
  padding: 20px;
  text-align: center;
  margin-bottom: 16px;
}
.ad-box .ad-label {
  display: inline-block;
  padding: 2px 8px;
  background: rgba(0,0,0,0.1);
  border-radius: 4px;
  font-size: 11px;
  color: #78350f;
  margin-bottom: 8px;
}
.ad-box h4 { font-size: 15px; color: #78350f; margin-bottom: 4px; }
.ad-box p { font-size: 12px; color: #92400e; opacity: 0.8; }

/* Quick links */
.quick-links { display: flex; flex-wrap: wrap; gap: 6px; }
.quick-links a {
  padding: 5px 10px;
  background: #f3f4f6;
  color: #4b5563;
  border-radius: 4px;
  font-size: 12px;
  transition: all 0.2s;
}
.quick-links a:hover { background: #2563eb; color: #fff; }

/* 评论模块 */
.comment-section .section-bd { padding: 0; }
.comment-head {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 18px;
  border-bottom: 1px solid #f3f4f6;
}
.comment-head .count {
  font-size: 12px;
  color: #3b82f6;
  background: #eff6ff;
  padding: 1px 10px;
  border-radius: 12px;
}
.comment-head .write-btn {
  margin-left: auto;
  padding: 7px 18px;
  font-size: 13px;
  color: #fff;
  background: linear-gradient(135deg, #3b82f6, #60a5fa);
  border: none;
  border-radius: 18px;
  cursor: pointer;
  transition: opacity .2s;
}
.comment-head .write-btn:hover { opacity: .9; }
.comment-list { padding: 4px 18px; }
.comment-item {
  display: flex;
  gap: 12px;
  padding: 16px 0;
  border-bottom: 1px solid #f5f6f8;
}
.comment-item:last-child { border-bottom: none; }
.comment-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 16px;
  font-weight: 700;
  background: linear-gradient(135deg, #3b82f6, #60a5fa);
}
.comment-avatar.c2 { background: linear-gradient(135deg, #10b981, #34d399); }
.comment-avatar.c3 { background: linear-gradient(135deg, #f59e0b, #fbbf24); }
.comment-main { flex: 1; min-width: 0; }
.comment-meta { display: flex; align-items: center; gap: 10px; margin-bottom: 6px; }
.comment-name { font-size: 13px; font-weight: 600; color: #1f2937; }
.comment-time { font-size: 12px; color: #9ca3af; }
.comment-text { font-size: 13px; color: #4b5563; line-height: 1.7; }
.comment-actions { display: flex; gap: 16px; margin-top: 10px; }
.comment-actions button {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  font-size: 12px;
  color: #9ca3af;
  background: none;
  border: none;
  cursor: pointer;
  transition: color .2s;
}
.comment-actions button:hover { color: #3b82f6; }
.comment-actions .like-btn.active { color: #ef4444; }
.comment-compose {
  display: flex;
  gap: 12px;
  padding: 16px 18px;
  border-top: 1px solid #f3f4f6;
  align-items: flex-start;
}
.comment-compose .compose-avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  flex-shrink: 0;
  background: #f1f5f9;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #94a3b8;
}
.comment-compose textarea {
  flex: 1;
  min-height: 64px;
  resize: none;
  border: 1px solid #e2e8f0;
  border-radius: 10px;
  padding: 10px 12px;
  font-size: 13px;
  outline: none;
  transition: border-color .2s;
}
.comment-compose textarea:focus { border-color: #3b82f6; }
.comment-compose .send {
  align-self: flex-end;
  padding: 8px 22px;
  font-size: 13px;
  color: #fff;
  background: #3b82f6;
  border: none;
  border-radius: 18px;
  cursor: pointer;
}
.comment-compose .send:hover { opacity: .9; }
/* 层级回复 */
.comment-reply {
  margin: 10px 0 0 52px;
  padding: 10px 14px;
  background: #f8fafc;
  border-radius: 8px;
  border-left: 3px solid #dbeafe;
}
.comment-reply .cr-meta { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; }
.comment-reply .cr-name { font-size: 12px; font-weight: 600; color: #3b82f6; }
.comment-reply .cr-time { font-size: 11px; color: #9ca3af; }
.comment-reply .cr-text { font-size: 13px; color: #4b5563; line-height: 1.6; }
.comment-reply .cr-actions { display: flex; gap: 14px; margin-top: 6px; }
.comment-reply .cr-actions button {
  display: inline-flex; align-items: center; gap: 4px; font-size: 12px;
  color: #9ca3af; background: none; border: none; cursor: pointer; transition: color .2s;
}
.comment-reply .cr-actions button:hover { color: #3b82f6; }

/* 侧边 Tab 排行（文章/软件） —— 复刻 qqziyuan umAppTabs */
.widget.umAppTabs {
  background: #fff;
  border: 1px solid #ebeef5;
  border-radius: 10px;
  padding: 20px 22px 18px;
  margin-bottom: 16px;
}
.widget.umAppTabs .umTabe {
  margin-bottom: 6px;
  overflow: hidden;
  font-size: 0;
  border-bottom: 1px solid #f2f3f7;
  text-align: center;
}
.widget.umAppTabs .umTabe li {
  display: inline-block;
  height: 36px;
  line-height: 36px;
  padding: 0 6px 0 2px;
  font-size: 15px;
  font-weight: 600;
  color: #4b5563;
  cursor: pointer;
  position: relative;
  margin-right: 22px;
}
.widget.umAppTabs .umTabe li.active { color: #2563eb; }
.widget.umAppTabs .umTabe li.active::after {
  content: '';
  position: absolute;
  left: 2px;
  right: 6px;
  bottom: -1px;
  height: 2px;
  background: #2563eb;
  border-radius: 2px;
}
.widget.umAppTabs .umTabeCon { padding: 0; background: none; min-height: auto; }
.umAppTabs .umAppTops { counter-reset: sectioncounter; display: none; }
.umAppTabs .umAppTops:first-child { display: block; }
.umAppTabs .umAppTops li {
  position: relative;
  font-size: 14px;
  width: 100%;
  height: 20px;
  line-height: 20px;
  margin: 14px 0 6px;
  padding-left: 32px;
  overflow: hidden;
  white-space: normal;
}
.umAppTabs .umAppTops li .pic {
  width: 68px;
  height: 68px;
  display: none;
  border-radius: 15px;
  overflow: hidden;
  position: relative;
  background: linear-gradient(135deg, #dbeafe, #eff6ff);
  align-items: center;
  justify-content: center;
  font-size: 26px;
}
.umAppTabs .umAppTops li .pic a {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #3b82f6;
}
.umAppTabs .umAppTops li.on { height: 68px; line-height: 20px; }
.umAppTabs .umAppTops li.on .pic { display: flex; float: left; }
.umAppTabs .umAppTops li.on .text {
  overflow: hidden;
  padding-left: 15px;
  margin-top: 8px;
}
.umAppTabs .umAppTops li.on .tit { width: 100%; padding-right: 0; line-height: 20px; margin-bottom: 5px; }
.umAppTabs .umAppTops li.on .divTit { padding-top: 0; width: 100%; text-align: left; }
.umAppTabs .umAppTops .tit {
  display: inline-block;
  width: 72%;
  padding-right: 5px;
  text-overflow: ellipsis;
  white-space: nowrap;
  overflow: hidden;
  vertical-align: middle;
  font-weight: 500;
  color: #374151;
}
.umAppTabs .umAppTops .tit a:hover { color: #2563eb; }
.umAppTabs .umAppTops .divTit {
  font-size: 12px;
  opacity: .4;
  overflow: hidden;
  height: 20px;
  line-height: 20px;
  display: inline-block;
  width: 28%;
  text-align: right;
  vertical-align: middle;
}
.umAppTabs .umAppTops li::before {
  content: counter(sectioncounter);
  counter-increment: sectioncounter;
  width: 20px;
  height: 20px;
  line-height: 20px;
  text-align: center;
  position: absolute;
  background: rgba(233, 234, 240, 1);
  color: #666;
  top: 0;
  left: 0;
  font-size: 12px;
  font-weight: bold;
  border-radius: 50px;
}
.umAppTabs .umAppTops li.on::before { height: 68px; line-height: 68px; }
.umAppTabs .umAppTops li:nth-child(1)::before,
.umAppTabs .umAppTops li:nth-child(2)::before,
.umAppTabs .umAppTops li:nth-child(3)::before { color: #fff; }
.umAppTabs .umAppTops li:nth-child(1)::before { background: #ff3a3a; }
.umAppTabs .umAppTops li:nth-child(2)::before { background: #ff9e20; }
.umAppTabs .umAppTops li:nth-child(3)::before { background: #dbad42; }