/* 云端联动附加样式：详情弹层 / 提示条 / 动态列表补充 */

#siteModal { position: fixed; inset: 0; z-index: 9999; display: none; }
#siteModal.show { display: block; }
#siteModal .sm-mask { position: absolute; inset: 0; background: rgba(10, 24, 48, .58); backdrop-filter: blur(2px); }
#siteModal .sm-box {
  position: relative; z-index: 1; max-width: 680px; margin: 6vh auto 0;
  background: #fff; border-radius: 14px; overflow: hidden;
  box-shadow: 0 24px 70px rgba(10, 24, 48, .34);
  max-height: 82vh; overflow-y: auto;
  animation: smIn .22s ease;
}
@keyframes smIn { from { opacity: 0; transform: translateY(16px) scale(.98); } to { opacity: 1; transform: none; } }
#siteModal .sm-x {
  position: absolute; right: 10px; top: 8px; z-index: 2;
  width: 34px; height: 34px; border: 0; border-radius: 50%;
  background: rgba(255, 255, 255, .92); color: #1c2536;
  font-size: 22px; line-height: 1; cursor: pointer; box-shadow: 0 2px 8px rgba(0, 0, 0, .16);
}
/* 弹层配图：按图片原始长宽比完整显示，不再用固定高度 + cover 裁切 */
#siteModal .sm-img { background: #f2f5fa; overflow: hidden; display: flex; align-items: center; justify-content: center; }
#siteModal .sm-img img {
  display: block; width: auto; height: auto;
  max-width: 100%; max-height: 50vh; object-fit: contain;
}
#siteModal .sm-body { padding: 20px 24px 24px; }
#siteModal .sm-cat {
  display: inline-block; font-size: 12px; color: #0A3A78; background: #e8f0fa;
  padding: 3px 10px; border-radius: 999px; margin-bottom: 10px;
}
#siteModal h3 { margin: 0 0 8px; font-size: 21px; color: #12213d; }
#siteModal p { margin: 0 0 10px; font-size: 14px; line-height: 1.75; color: #4a5769; }
#siteModal .sm-spec { font-size: 13px; color: #8a94a6; }
#siteModal .sm-price { font-size: 16px; color: #c0392b; font-weight: 600; }
#siteModal .sm-desc { color: #5a6880; }
/* 富文本正文（后台富文本编辑器保存的 HTML） */
#siteModal .sm-rich { font-size: 14px; line-height: 1.85; color: #334155; word-break: break-word; }
#siteModal .sm-rich p { margin: 0 0 12px; }
#siteModal .sm-rich h2, #siteModal .sm-rich h3, #siteModal .sm-rich h4 { margin: 18px 0 10px; color: #12213d; line-height: 1.5; }
#siteModal .sm-rich h2 { font-size: 19px; }
#siteModal .sm-rich h3 { font-size: 17px; }
#siteModal .sm-rich ul, #siteModal .sm-rich ol { margin: 0 0 14px 22px; }
#siteModal .sm-rich li { margin-bottom: 6px; }
#siteModal .sm-rich blockquote { margin: 14px 0; padding: 8px 14px; border-left: 3px solid #0A3A78; background: #f4f8fd; color: #5a6880; }
#siteModal .sm-rich img { max-width: 100%; height: auto; border-radius: 6px; margin: 8px 0; display: block; }
#siteModal .sm-rich a { color: #0A3A78; text-decoration: underline; }
#siteModal .sm-rich table { width: 100%; border-collapse: collapse; margin: 12px 0; }
#siteModal .sm-rich td, #siteModal .sm-rich th { border: 1px solid #dbe2ec; padding: 6px 8px; }
#siteModal .sm-rich pre { background: #1c2536; color: #e6edf6; padding: 12px; border-radius: 6px; overflow-x: auto; }
#siteModal .sm-cta {
  display: inline-block; margin-top: 6px; padding: 9px 20px; border-radius: 8px;
  background: #0A3A78; color: #fff; text-decoration: none; font-size: 14px;
}

.case-desc {
  margin: 6px 0 0; font-size: 13px; line-height: 1.6; color: #6b7688;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}

/* 通用提示条（页面无 #toast 时兜底） */
#siteToast {
  position: fixed; left: 50%; bottom: 42px; transform: translateX(-50%) translateY(14px);
  background: rgba(24, 38, 66, .94); color: #fff; font-size: 14px;
  padding: 11px 22px; border-radius: 999px; z-index: 10000;
  opacity: 0; pointer-events: none; transition: .24s; max-width: 88vw; text-align: center;
}
#siteToast.show { opacity: 1; transform: translateX(-50%) translateY(0); }

@media (max-width: 640px) {
  #siteModal .sm-box { margin: 3vh 12px 0; max-height: 88vh; }
  #siteModal .sm-img img { max-height: 38vh; }
}

/* 列表卡片图片首屏防闪烁：正确图片预加载完成前保持透明，避免模板示例图/默认图一闪而过。
 * JS 未执行时由 <noscript> 恢复显示，保证无脚本环境仍可见静态内容。 */
.prod-img img.img-pending,
.news-img img.img-pending,
.case-img img.img-pending,
.sol-img img.img-pending,
.scene-img img.img-pending { opacity: 0; }
.prod-img, .news-img, .case-img { background-color: #f7f8fa; }
