/* Apply this class to the CMS article body, below the template's page title. */
.rcicn-article-body {
  max-inline-size: 48rem;
  margin-inline: auto;
  font-size: clamp(1rem, 0.97rem + 0.15vw, 1.0625rem);
  line-height: 1.85;
  text-align: start;
  overflow-wrap: anywhere;
}

.rcicn-article-body :where(p, ul, ol, dl, blockquote, figure, table) {
  margin-block: 0 1.15em;
}

.rcicn-article-body :where(p) {
  text-indent: 0;
}

/* Keep article prose compact while retaining space around headings and media. */
.rcicn-article-body[itemprop="articleBody"] :where(p) {
  margin-block: 0 .8em;
}

.rcicn-article-body[itemprop="articleBody"] :where(p:last-child) {
  margin-block-end: 0;
}

.rcicn-article-body :where(h2, h3) {
  margin-block: 1.65em 0.6em;
  font-weight: 700;
  line-height: 1.45;
  text-align: start;
}

.rcicn-article-body :where(h2) {
  font-size: clamp(1.25rem, 1.1rem + 0.5vw, 1.5rem);
}

.rcicn-article-body :where(h3) {
  font-size: clamp(1.1rem, 1.02rem + 0.3vw, 1.25rem);
}

.rcicn-article-body :where(ul, ol) {
  padding-inline-start: 1.6em;
}

.rcicn-article-body :where(blockquote) {
  margin-inline: 0;
  border-inline-start: 0.2em solid currentColor;
  padding-inline-start: 1em;
}

.rcicn-article-body :where(figure) {
  margin-inline: 0;
}

.rcicn-article-body :where(img, video) {
  display: block;
  max-inline-size: 100%;
  block-size: auto;
  margin: 0.85em auto;
}

.rcicn-article-body :where(figcaption) {
  font-size: 0.9em;
  line-height: 1.55;
  text-align: center;
}

.rcicn-article-body .rcicn-article-table {
  max-inline-size: 100%;
  overflow-x: auto;
}

.rcicn-article-body :where(table) {
  border-collapse: collapse;
}

.rcicn-article-body :where(th, td) {
  border: 1px solid #d8dddc;
  padding: 0.4em 0.65em;
  text-align: start;
  vertical-align: top;
}

.rcicn-article-body a[href] {
  color: #0f6e56;
  text-decoration: none;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
  border-radius: 3px;
  transition: color .2s ease, background-color .2s ease;
}

.rcicn-article-body a[href]:hover,
.rcicn-article-body a[href]:focus-visible {
  color: #c2610f;
  background-color: #eef6f1;
  text-decoration-line: underline;
  text-decoration-thickness: 2px;
}

/* 资讯详情页不输出顶部缩略图时，标题栏唯一的一列占满整行，避免右侧留白。 */
.page-heading-grid > div:only-child {
  grid-column: 1 / -1;
}

/* 详情页底部：上一篇 / 下一篇 */
.article-prenext {
  max-width: 950px;
  margin: 26px auto 0;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}
.article-prenext-cell {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 0;
  padding: 18px 20px;
  color: #5c6b74;
  background: #fff;
  border: 1px solid #e3e8e6;
  border-radius: 12px;
  box-shadow: 0 5px 22px #112e5a0d;
}
.article-prenext-cell.is-next { text-align: right; }
.article-prenext-label {
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .04em;
  color: #0f6e56;
}
.article-prenext-link {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.5;
  color: #17324d;
  text-decoration: none;
}
.article-prenext-link:hover,
.article-prenext-link:focus-visible {
  color: #c2610f;
  text-decoration: underline;
  text-underline-offset: 3px;
}
@media (max-width: 700px) {
  .article-prenext { grid-template-columns: 1fr; }
  .article-prenext-cell.is-next { text-align: left; }
}

/* 资讯详情页：正文 + 侧栏两栏。只有资讯栏目会输出 .article-aside，
   案例 / 服务详情页仍是原来的单栏，不受影响。 */
.article-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 300px;
  gap: 24px;
  align-items: start;
}
.article-main { min-width: 0; }
.article-layout .reading { max-width: none; margin-inline: 0; }
.article-layout .article-prenext { max-width: none; margin-inline: 0; }

.article-aside { display: grid; gap: 18px; min-width: 0; }
.aside-card {
  padding: 20px;
  background: #fff;
  border: 1px solid #e3e8e6;
  border-radius: 12px;
  box-shadow: 0 5px 22px #112e5a12;
}
.aside-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  margin: 0 0 14px;
  padding-bottom: 12px;
  border-bottom: 2px solid #eef2f0;
  font-size: 1.05rem;
  font-weight: 700;
  color: #17324d;
}
.aside-title span {
  font-size: .75rem;
  font-weight: 500;
  color: #8a989f;
}
.aside-reading-list { list-style: none; margin: 0; padding: 0; }
.aside-reading-list li + li { border-top: 1px dashed #e8ecea; }
.aside-reading-list a {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 10px 2px;
  text-decoration: none;
}
.aside-reading-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: .92rem;
  font-weight: 600;
  line-height: 1.5;
  color: #2a3b48;
  transition: color .2s ease;
}
.aside-reading-list time { font-size: .75rem; color: #95a2a8; }
.aside-reading-list a:hover .aside-reading-title,
.aside-reading-list a:focus-visible .aside-reading-title { color: #c2610f; }
.aside-more {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-top: 14px;
  font-size: .85rem;
  font-weight: 600;
  color: #0f6e56;
  text-decoration: none;
}
.aside-more:hover,
.aside-more:focus-visible {
  color: #c2610f;
  text-decoration: underline;
  text-underline-offset: 3px;
}

/* 服务案例：无缝缓慢上滚，鼠标悬停 / 键盘聚焦时暂停，方便点击。 */
.case-reel {
  position: relative;
  height: 344px;
  overflow: hidden;
  border-radius: 10px;
}
.case-reel::after {
  content: "";
  position: absolute;
  inset: auto 0 0;
  height: 32px;
  pointer-events: none;
  background: linear-gradient(transparent, #fff);
}
.case-reel-track { display: flex; flex-direction: column; gap: 12px; }
.case-reel[data-ready] .case-reel-track {
  animation: case-reel-scroll var(--reel-duration, 40s) linear infinite;
}
.case-reel:hover .case-reel-track,
.case-reel:focus-within .case-reel-track { animation-play-state: paused; }
@keyframes case-reel-scroll {
  to { transform: translateY(calc(-1 * var(--reel-distance, 1200px))); }
}
.case-reel-group { display: grid; gap: 12px; }
.case-reel-item {
  display: grid;
  grid-template-columns: 104px minmax(0, 1fr);
  gap: 10px;
  align-items: center;
  min-width: 0;
  padding: 6px;
  background: #fbfcfc;
  border: 1px solid #edf0ef;
  border-radius: 9px;
  color: #2a3b48;
  text-decoration: none;
}
.case-reel-item img {
  width: 104px;
  aspect-ratio: 16 / 10;
  object-fit: cover;
  border-radius: 6px;
}
.case-reel-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  overflow: hidden;
  font-size: .82rem;
  font-weight: 600;
  line-height: 1.45;
}
.case-reel-item:hover,
.case-reel-item:focus-visible {
  background: #f2f8f5;
  border-color: #9ecbb9;
  color: #0f6e56;
}

/* 咨询引导 */
.aside-cta {
  background: linear-gradient(140deg, #f3f8f5, #fff7ee);
  border-color: #e3ebe5;
}
.aside-cta .aside-title { margin-bottom: 8px; padding-bottom: 0; border-bottom: 0; }
.aside-cta p { margin: 0 0 16px; font-size: .86rem; line-height: 1.7; color: #5c6b74; }
.aside-cta-link, .aside-cta-alt {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 9px 14px;
  border-radius: 8px;
  font-size: .85rem;
  font-weight: 600;
  text-decoration: none;
}
.aside-cta-link { background: #0f6e56; color: #fff; }
.aside-cta-link:hover { background: #c2610f; }
.aside-cta-alt { margin-left: 8px; border: 1px solid #cddbd4; color: #0f6e56; }
.aside-cta-alt:hover { border-color: #c2610f; color: #c2610f; }

@media (prefers-reduced-motion: reduce) {
  .case-reel { height: auto; max-height: 420px; overflow-y: auto; }
  .case-reel::after { display: none; }
  .case-reel[data-ready] .case-reel-track { animation: none; }
  .case-reel .is-clone { display: none; }
}

/* 平板 / 手机：侧栏移到正文下方，关闭自动滚动，改为静态两列图片网格。 */
@media (max-width: 991px) {
  .article-layout { grid-template-columns: 1fr; gap: 20px; }
  .article-aside { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .aside-cta { grid-column: 1 / -1; }
  .case-reel { height: auto; max-height: none; overflow: visible; }
  .case-reel::after { display: none; }
  .case-reel[data-ready] .case-reel-track { animation: none; transform: none; }
  .case-reel .is-clone { display: none; }
  .case-reel-group { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 700px) {
  .article-aside { grid-template-columns: 1fr; }
  .case-reel-item { grid-template-columns: 1fr; }
  .case-reel-item img { width: 100%; aspect-ratio: 16 / 9; }
  /* 手机上侧栏位于正文下方，展示 4 张即可，避免侧栏比正文还长。 */
  .case-reel-item:nth-child(n+5) { display: none; }
}
@media (max-width: 420px) {
  .case-reel-group { grid-template-columns: 1fr; }
  .case-reel-item { grid-template-columns: 104px minmax(0, 1fr); }
  .case-reel-item img { width: 104px; aspect-ratio: 16 / 10; }
}
/* RCICN-ROSTER-GRID */
/* 应用单位名单改为自适应药丸网格，避免一列竖排把页面拉得过长。 */
.reading .rcicn-roster {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 4px 0 8px;
}
.reading .rcicn-roster > div {
  display: inline-flex;
  align-items: center;
  flex: 0 1 auto;
  padding: 8px 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #ffffffde;
  color: var(--ink);
  font-size: .9rem;
  line-height: 1.35;
  box-shadow: 0 3px 12px #112e5a0d;
}
.reading .rcicn-roster > div::before {
  content: "";
  display: inline-block;
  width: 5px;
  height: 5px;
  margin-right: 8px;
  border-radius: 50%;
  background: var(--green);
  vertical-align: middle;
  flex: 0 0 auto;
}
@media (max-width: 700px) {
  .reading .rcicn-roster { gap: 6px; }
  .reading .rcicn-roster > div { padding: 7px 9px; font-size: .8rem; }
  .reading .rcicn-roster > div::before { width: 4px; margin-right: 6px; }
}

