:root {
  --cm-red: #e62828;
  --cm-text: #333;
  --cm-muted: #999;
  --cm-border: #eee;
  --cm-bg: #f5f5f5;
  --cm-card: #fff;
}
* { box-sizing: border-box; }
body.community-page {
  margin: 0;
  background: var(--cm-bg);
  color: var(--cm-text);
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  font-size: 14px;
}
/* 页眉沿用首页 .top / .header，社区内容区单独铺灰底 */
body.community-page .cm-tabs-bar,
body.community-page .cm-wrap,
body.community-page .cm-crumb,
body.community-page .cm-detail {
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
}
/* 正文图右下角水印：不透明层盖住「什么值得买」 */
.cm-wm-wrap {
  position: relative !important;
  display: inline-block !important;
  max-width: 100% !important;
  line-height: 0 !important;
  vertical-align: top !important;
}
.cm-wm-wrap > img {
  max-width: 100% !important;
  height: auto !important;
  display: block !important;
}
/* 相关推荐封面：.left-img img{width/height:100%}，包裹后父级必须继承槽位尺寸，否则图塌成 0 只剩徽标 */
.article-contant .left-img .cm-wm-wrap,
.list-related .left-img .cm-wm-wrap,
a.left-img .cm-wm-wrap {
  display: block !important;
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
}
.article-contant .left-img .cm-wm-wrap > img,
.list-related .left-img .cm-wm-wrap > img,
a.left-img .cm-wm-wrap > img {
  width: 100% !important;
  height: 100% !important;
  max-width: none !important;
  object-fit: cover !important;
  object-position: center !important;
}
.cm-wm-layer {
  position: absolute !important;
  right: 1px !important;
  bottom: 1px !important;
  z-index: 6 !important;
  pointer-events: none !important;
  line-height: 0 !important;
  /* 正文大图默认；实际宽度由 JS 按图尺寸写入 */
  width: clamp(200px, 42%, 320px) !important;
  background: #1a1a1a !important;
  border-radius: 999px !important;
  overflow: hidden !important;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.4) !important;
}
.cm-wm-wrap.is-thumb .cm-wm-layer,
.cm-wm-layer.is-thumb {
  /* 推荐封面：外框随水印图收缩，去掉额外黑底放大框 */
  width: auto !important;
  right: 3px !important;
  bottom: 3px !important;
  background: transparent !important;
  border-radius: 0 !important;
  box-shadow: none !important;
  overflow: visible !important;
}
.cm-wm-badge {
  display: block !important;
  width: 100% !important;
  height: auto !important;
  min-height: 0 !important;
  object-fit: contain !important;
  object-position: center !important;
}
.cm-wm-wrap.is-thumb .cm-wm-badge,
.cm-wm-layer.is-thumb .cm-wm-badge {
  width: clamp(48px, 22%, 72px) !important;
  max-width: 72px !important;
  filter: drop-shadow(0 1px 2px rgba(0, 0, 0, 0.35));
}
/* 页眉 LOGO 与协议页同大 */
a.logo,
.logo {
  display: inline-flex !important;
  align-items: center !important;
  line-height: 0 !important;
}
.header .content.screen-width,
.header .content {
  min-height: 88px !important;
  align-items: center !important;
}
a.logo img.logo-img,
a.logo img,
.logo img.logo-img,
.header .logo img {
  height: 80px !important;
  width: auto !important;
  max-width: 320px !important;
  object-fit: contain !important;
  object-position: left center !important;
  display: block !important;
}
.cm-wrap {
  width: 1200px;
  max-width: calc(100% - 24px);
  margin: 0 auto;
  padding: 0 0 48px;
}
.cm-tabs-bar {
  background: #fff;
  border-bottom: 1px solid #e8e8e8;
  position: sticky;
  top: 0;
  z-index: 20;
}
.cm-tabs-inner {
  width: 1200px;
  max-width: calc(100% - 24px);
  margin: 0 auto;
  display: flex;
  align-items: flex-start;
  gap: 8px;
  padding: 10px 0 8px;
}
.cm-tabs {
  flex: 1;
  display: flex;
  flex-wrap: wrap;
  gap: 4px 2px;
  max-height: 36px;
  overflow: hidden;
}
.cm-tabs.expanded { max-height: none; }
.cm-tab {
  appearance: none;
  border: 0;
  background: transparent;
  color: #222;
  cursor: pointer;
  padding: 6px 12px;
  font-size: 15px;
  line-height: 22px;
  border-radius: 2px;
}
.cm-tab:hover { color: var(--cm-red); }
.cm-tab.active {
  color: var(--cm-red);
  font-weight: 600;
}
.cm-tabs-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
  padding-top: 4px;
  color: #666;
  font-size: 13px;
}
.cm-tabs-actions button {
  border: 0;
  background: transparent;
  cursor: pointer;
  color: #666;
  font-size: 13px;
}
.cm-layout {
  display: grid;
  grid-template-columns: 1fr 300px;
  gap: 20px;
  margin-top: 16px;
}
.cm-feed {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.cm-card {
  background: var(--cm-card);
  border-radius: 6px;
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition: box-shadow .2s ease, transform .2s ease;
}
.cm-card:hover {
  box-shadow: 0 8px 24px rgba(0,0,0,.08);
  transform: translateY(-2px);
}
.cm-card-cover {
  position: relative;
  aspect-ratio: 16 / 10;
  background: #eaeaea;
  overflow: hidden;
}
.cm-card-cover img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cm-badge {
  position: absolute;
  left: 8px;
  top: 8px;
  background: var(--cm-red);
  color: #fff;
  font-size: 12px;
  padding: 2px 6px;
  border-radius: 2px;
}
.cm-card-meta {
  position: absolute;
  left: 0; right: 0; bottom: 0;
  padding: 28px 10px 8px;
  background: linear-gradient(transparent, rgba(0,0,0,.55));
  color: #fff;
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
}
.cm-card-meta img {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  object-fit: cover;
}
.cm-card-body { padding: 12px 12px 10px; flex: 1; display: flex; flex-direction: column; }
.cm-card-title {
  font-size: 15px;
  font-weight: 600;
  line-height: 1.45;
  height: 2.9em;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.cm-card-stats {
  margin-top: auto;
  padding-top: 10px;
  display: flex;
  align-items: center;
  gap: 16px;
  color: #999;
  font-size: 12px;
}
.cm-card-stats .cm-stat {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  line-height: 1;
}
.cm-card-stats .cm-ico {
  width: 14px;
  height: 14px;
  color: #bbb;
}
.cm-side > * + * { margin-top: 14px; }
.cm-side-box {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 4px;
  padding: 0 0 8px;
  overflow: hidden;
}
.cm-side-box h3 {
  margin: 0;
  padding: 12px 14px;
  font-size: 16px;
  font-weight: 700;
  color: #333;
  border-bottom: 1px solid #eee;
}
.cm-side-empty {
  color: #999;
  font-size: 13px;
  padding: 12px 14px;
  line-height: 1.6;
}
.cm-ico {
  width: 14px;
  height: 14px;
  display: inline-block;
  vertical-align: -2px;
  color: #bbb;
}
.cm-side-meta {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-top: 8px;
  color: #999;
  font-size: 12px;
}
.cm-side-meta span { margin-right: 10px; }

/* 热门资讯：hover 切换大图（对标站 side-change） */
.cm-news-hover {
  list-style: none;
  margin: 0;
  padding: 10px 14px 12px;
}
.cm-news-hover > li { margin: 0 0 12px; }
.cm-news-hover > li:last-child { margin-bottom: 0; }
.cm-news-hover .side-max { display: none; overflow: hidden; }
.cm-news-hover .side-min {
  display: block;
  line-height: 24px;
  overflow: hidden;
}
.cm-news-hover > li.active .side-max { display: block; }
.cm-news-hover > li.active .side-min { display: none; }
.cm-news-hover .side-max > a {
  float: left;
  width: 80px;
  height: 80px;
  margin-right: 12px;
  overflow: hidden;
  background: #f5f5f5;
}
.cm-news-hover .side-max > a img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cm-news-hover .side-jx-r { overflow: hidden; }
.cm-news-hover .side-line-title {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  color: #333;
  text-decoration: none;
  font-size: 14px;
  line-height: 24px;
  max-height: 48px;
}
.cm-news-hover .side-min .side-line-title {
  display: block;
  white-space: nowrap;
  text-overflow: ellipsis;
  -webkit-line-clamp: unset;
  max-height: none;
  font-size: 13px;
}
.cm-news-hover .side-line-title:hover { color: var(--cm-red); }
.cm-news-hover .cm-side-meta { margin-top: 8px; }
.cm-news-hover .side-max:after {
  content: "";
  display: block;
  clear: both;
}

/* 热门众测：轮播 + 申请条 + 图文列表 */
.cm-zc-carousel {
  position: relative;
  margin: 12px 14px 0;
  border-radius: 4px;
  overflow: hidden;
  background: #111;
}
.cm-zc-slides { position: relative; aspect-ratio: 16 / 10; }
.cm-zc-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  pointer-events: none;
  transition: opacity .35s ease;
  color: #fff;
  text-decoration: none;
}
.cm-zc-slide.is-active { opacity: 1; pointer-events: auto; }
.cm-zc-slide img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cm-zc-slide-mask {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 35%, rgba(0,0,0,.72));
}
.cm-zc-slide-title {
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: 36px;
  font-size: 14px;
  font-weight: 600;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.cm-zc-slide-btn {
  position: absolute;
  left: 12px;
  bottom: 10px;
  height: 22px;
  line-height: 22px;
  padding: 0 10px;
  border-radius: 11px;
  background: rgba(255,255,255,.92);
  color: #333;
  font-size: 12px;
}
.cm-zc-dots {
  position: absolute;
  left: 0; right: 0; bottom: 8px;
  display: flex;
  justify-content: center;
  gap: 5px;
  z-index: 2;
  pointer-events: none;
}
.cm-zc-dot {
  pointer-events: auto;
  width: 6px;
  height: 6px;
  border: 0;
  padding: 0;
  border-radius: 50%;
  background: rgba(255,255,255,.45);
  cursor: pointer;
}
.cm-zc-dot.is-active { background: #fff; }
.cm-zc-cta {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 10px 14px 4px;
}
.cm-zc-cta-title {
  flex: 1;
  min-width: 0;
  color: #333;
  text-decoration: none;
  font-size: 13px;
  font-weight: 600;
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.cm-zc-cta-title:hover { color: var(--cm-red); }
.cm-zc-apply {
  flex-shrink: 0;
  height: 30px;
  line-height: 30px;
  padding: 0 12px;
  background: var(--cm-red);
  color: #fff !important;
  border-radius: 2px;
  text-decoration: none;
  font-size: 13px;
}
.cm-zc-apply:hover { filter: brightness(.95); }
.cm-zc-list { padding: 4px 14px 6px; }
.cm-zc-item {
  display: flex;
  gap: 10px;
  padding: 12px 0;
  text-decoration: none;
  color: inherit;
  border-top: 1px solid #f3f3f3;
}
.cm-zc-item-pic {
  width: 72px;
  height: 72px;
  flex-shrink: 0;
  border-radius: 2px;
  overflow: hidden;
  background: #f2f2f2;
}
.cm-zc-item-pic img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.cm-zc-item-body { min-width: 0; flex: 1; }
.cm-zc-item-title {
  font-size: 13px;
  line-height: 1.45;
  color: #333;
  font-weight: 600;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.cm-zc-item:hover .cm-zc-item-title { color: var(--cm-red); }
.cm-pager {
  grid-column: 1 / -1;
  display: flex;
  justify-content: center;
  gap: 8px;
  padding: 18px 0 8px;
  flex-wrap: wrap;
}
.cm-pager button, .cm-pager span {
  min-width: 34px;
  height: 34px;
  border: 1px solid #ddd;
  background: #fff;
  border-radius: 4px;
  cursor: pointer;
  color: #333;
}
.cm-pager button.active {
  background: var(--cm-red);
  border-color: var(--cm-red);
  color: #fff;
}
.cm-pager button:disabled { opacity: .45; cursor: default; }
.cm-empty {
  grid-column: 1 / -1;
  text-align: center;
  color: #999;
  padding: 60px 20px;
  background: #fff;
  border-radius: 6px;
}
.cm-crumb {
  width: 1200px;
  max-width: calc(100% - 24px);
  margin: 0 auto;
  padding: 14px 0;
  color: #666;
  font-size: 13px;
}
.cm-crumb a { color: #666; text-decoration: none; }
.cm-crumb a:hover { color: var(--cm-red); }
.cm-detail-layout {
  width: 1200px;
  max-width: calc(100% - 24px);
  margin: 0 auto 48px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 20px;
  align-items: start;
}
.cm-detail {
  background: #fff;
  border-radius: 6px;
  padding: 28px 40px 40px;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}
.cm-detail-head {
  border-bottom: 1px solid #f0f0f0;
  margin-bottom: 22px;
  padding-bottom: 18px;
}
.cm-detail h1 {
  margin: 0 0 14px;
  font-size: 28px;
  line-height: 1.35;
  font-weight: 700;
  color: #222;
}
.cm-detail-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #999;
  font-size: 13px;
  flex-wrap: wrap;
}
.cm-detail-avatar {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
}
.cm-detail-author { color: #666; font-weight: 500; }
.cm-detail-dot { color: #ccc; }
.cm-detail-channel {
  margin-left: 4px;
  padding: 1px 8px;
  border: 1px solid #eee;
  border-radius: 999px;
  color: #999;
  font-size: 12px;
}
.cm-detail-summary {
  margin: 14px 0 0;
  padding: 12px 14px;
  background: #fafafa;
  border-left: 3px solid #e62828;
  color: #666;
  font-size: 14px;
  line-height: 1.7;
}
.cm-detail-body {
  font-size: 16px;
  line-height: 1.85;
  color: #333;
  word-break: break-word;
}
.cm-detail-body img {
  max-width: 100% !important;
  height: auto !important;
  display: block;
  margin: 14px auto;
  border-radius: 2px;
}
.cm-detail-body p { margin: 0 0 1em; }
.cm-detail-body strong,
.cm-detail-body b {
  font-weight: 700;
  color: #222;
}
.cm-detail-body .center-img,
.cm-detail-body .img_desc,
.cm-detail-body .img_desc_text {
  display: block;
  text-align: center;
}
.cm-detail-body .seo_link {
  color: #e62828;
  text-decoration: none;
  border-bottom: 1px dashed rgba(230,40,40,.35);
}
.cm-detail-body .seo_link:hover { border-bottom-style: solid; }
.cm-detail-body .interests_ugc {
  margin-top: 24px;
  padding: 14px 16px;
  background: #fff8f8;
  border: 1px solid #ffe1e1;
  border-radius: 6px;
  color: #666;
  font-size: 14px;
  line-height: 1.7;
}
.cm-detail-body .cm-dead-link {
  color: inherit;
  border-bottom: none;
  pointer-events: none;
  cursor: default;
}
.cm-detail-body dir,
.cm-detail-body .insert-card-editor { display: none !important; }
.cm-detail-actions {
  margin-top: 32px;
  padding-top: 18px;
  border-top: 1px solid #f0f0f0;
  display: flex;
  gap: 12px;
  flex-wrap: wrap;
}
.cm-act {
  min-width: 88px;
  height: 36px;
  padding: 0 16px;
  border: 1px solid #eee;
  border-radius: 18px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #666;
  font-size: 13px;
  background: #fafafa;
}
.cm-detail-side { position: sticky; top: 12px; }
.cm-detail-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
}
.cm-tag {
  display: inline-block;
  padding: 2px 10px;
  border: 1px solid #eee;
  border-radius: 999px;
  color: #666;
  font-size: 12px;
  background: #fafafa;
}
.cm-comments {
  margin-top: 16px;
  background: #fff;
  border-radius: 6px;
  padding: 22px 28px 28px;
  box-shadow: 0 1px 2px rgba(0,0,0,.04);
}
.cm-comments-title {
  margin: 0 0 16px;
  font-size: 18px;
  font-weight: 700;
  color: #222;
}
.cm-comments-title em {
  font-style: normal;
  color: var(--cm-red);
  font-weight: 600;
  margin-left: 6px;
  font-size: 15px;
}
.cm-cmt {
  padding: 14px 0;
  border-top: 1px solid #f3f3f3;
}
.cm-cmt:first-child { border-top: 0; padding-top: 0; }
.cm-cmt-main { display: flex; gap: 12px; }
.cm-cmt-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: #eee;
}
.cm-cmt-avatar-ph { display: inline-block; }
.cm-cmt-body { min-width: 0; flex: 1; }
.cm-cmt-head {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
}
.cm-cmt-name { color: #666; font-size: 13px; font-weight: 600; }
.cm-cmt-author-tag {
  font-size: 11px;
  color: var(--cm-red);
  border: 1px solid #ffd0d0;
  border-radius: 2px;
  padding: 0 4px;
  line-height: 16px;
}
.cm-cmt-text {
  color: #333;
  font-size: 14px;
  line-height: 1.7;
  white-space: pre-wrap;
  word-break: break-word;
}
.cm-cmt-foot {
  margin-top: 8px;
  display: flex;
  gap: 16px;
  color: #999;
  font-size: 12px;
}
.cm-cmt-replies {
  margin: 10px 0 0 48px;
  padding: 4px 12px;
  background: #fafafa;
  border-radius: 4px;
}
.cm-cmt.is-child {
  border-top: 0;
  padding: 10px 0;
}
.cm-cmt.is-child .cm-cmt-avatar { width: 28px; height: 28px; }
@media (max-width: 1100px) {
  .cm-layout { grid-template-columns: 1fr; }
  .cm-feed { grid-template-columns: repeat(2, 1fr); }
  .cm-side { display: none; }
  .cm-detail-layout { grid-template-columns: 1fr; }
}
@media (max-width: 640px) {
  .cm-feed { grid-template-columns: 1fr; }
  .cm-detail { padding: 18px 16px 28px; }
  .cm-detail h1 { font-size: 20px; }
}
