/* ============ 美研社 - 专业整形科普平台 ============ */
:root {
  --primary: #D7000F;
  --primary-dark: #B60005;
  --primary-darkest: #910000;
  --white: #FFFFFF;
  --text: #333333;
  --text-light: #777777;
  --border: #ececec;
  --bg-gray: #f6f6f6;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--text);
  background: var(--white);
  font-size: 15px;
  line-height: 1.7;
}

a { text-decoration: none; color: var(--text); transition: color .2s; }
a:hover { color: var(--primary); }
ul, ol { list-style: none; }
img { max-width: 100%; display: block; }

.container { width: 1200px; max-width: 94%; margin: 0 auto; }

/* ---------- 顶部信息条 ---------- */
.topbar {
  background: var(--bg-gray);
  border-bottom: 1px solid var(--border);
  font-size: 13px;
  color: var(--text-light);
}
.topbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 36px;
}
.topbar .hotline { color: var(--primary); font-weight: bold; }

/* ---------- Logo 区 ---------- */
.header { padding: 22px 0; background: var(--white); }
.header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 24px;
}
.logo { display: flex; align-items: center; gap: 14px; }
.logo-img { height: 64px; width: auto; display: block; }

.search-box { display: flex; flex-shrink: 0; }
.search-box input {
  width: 240px; height: 40px;
  border: 2px solid var(--primary);
  border-right: none;
  border-radius: 20px 0 0 20px;
  padding: 0 18px;
  font-size: 14px;
  outline: none;
}
.search-box button {
  height: 40px; padding: 0 24px;
  background: var(--primary);
  color: var(--white);
  border: none; border-radius: 0 20px 20px 0;
  font-size: 14px; cursor: pointer;
  transition: background .2s;
}
.search-box button:hover { background: var(--primary-dark); }

/* ---------- 主导航 ---------- */
.nav {
  background: linear-gradient(180deg, var(--primary), var(--primary-dark));
  box-shadow: 0 2px 8px rgba(145, 0, 0, .25);
  position: sticky; top: 0; z-index: 999;
}
.nav .container { display: flex; align-items: center; }
.nav-list { display: flex; flex: 1; }
.nav-list > li { flex: 1; }
.nav-list > li > a {
  display: block;
  padding: 0 8px;
  line-height: 48px;
  text-align: center;
  white-space: nowrap;
  color: var(--white);
  font-size: 16px;
  transition: background .2s;
}
.nav-list > li > a:hover,
.nav-list > li > a.active { background: var(--primary-darkest); color: var(--white); }
.nav-toggle {
  display: none;
  background: none; border: none;
  color: var(--white); font-size: 24px;
  line-height: 48px; cursor: pointer;
}

/* ---------- 主体布局 ---------- */
.main { padding: 40px 0 40px; }
.layout {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 28px;
  align-items: start;
}

/* ---------- 焦点区：轮播 + 要闻 ---------- */
.focus-area {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  margin-bottom: 60px;
}
.carousel {
  position: relative;
  border-radius: 10px;
  overflow: hidden;
  height: 480px;
  box-shadow: 0 4px 16px rgba(0,0,0,.08);
}
.carousel-track { display: flex; height: 100%; transition: transform .5s ease; }
.slide { min-width: 100%; height: 100%; position: relative; display: block; }
.slide-bg { width: 100%; height: 100%; display: flex; align-items: center; justify-content: center; }
/* 轮播图片:等比自适应,可缩小完整展示,不裁切;图片之外留白填充白色 */
.slide-bg.slide-img { background: var(--white); }
.slide-bg.slide-img img {
  width: 100%; height: 100%;
  object-fit: contain;
  display: block;
}
.slide-bg-1 { background: linear-gradient(135deg, #D7000F, #910000); }
.slide-bg-2 { background: linear-gradient(135deg, #B60005, #6e0000); }
.slide-bg-3 { background: linear-gradient(135deg, #910000, #D7000F); }
.slide-icon { font-size: 90px; opacity: .25; color: var(--white); }
.slide-caption {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 40px 20px 16px;
  background: linear-gradient(transparent, rgba(0,0,0,.75));
  color: var(--white);
}
.slide-caption h3 {
  font-size: 21px; font-weight: 700; line-height: 1.45;
  letter-spacing: .5px; text-shadow: 0 2px 8px rgba(0,0,0,.45);
}
/* 图片帧标题条:白底配深色文字,去掉暗色渐变与文字阴影 */
.slide-caption.on-light {
  background: linear-gradient(transparent, rgba(255, 255, 255, .95) 45%);
  color: var(--primary-darkest);
}
.slide-caption.on-light h3 { text-shadow: none; }
.carousel-dots {
  position: absolute; bottom: 14px; right: 20px;
  display: flex; gap: 8px; z-index: 2;
}
/* 圆点:深灰芯 + 白色内描边,白底与红底帧上均清晰可见 */
.carousel-dots span {
  width: 10px; height: 10px; border-radius: 50%;
  background: rgba(0, 0, 0, .25);
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .85);
  cursor: pointer; transition: all .2s;
}
.carousel-dots span.on { background: var(--primary); width: 24px; border-radius: 5px; }
.carousel-arrow {
  position: absolute; top: 50%; transform: translateY(-50%);
  width: 36px; height: 60px;
  background: rgba(0,0,0,.25); color: var(--white);
  border: none; font-size: 20px; cursor: pointer;
  opacity: 0; transition: opacity .2s; z-index: 2;
}
.carousel:hover .carousel-arrow { opacity: 1; }
.carousel-arrow.prev { left: 0; border-radius: 0 6px 6px 0; }
.carousel-arrow.next { right: 0; border-radius: 6px 0 0 6px; }

/* 要闻面板 */
.headline-panel {
  background: var(--bg-gray);
  border-radius: 10px;
  padding: 22px 24px;
  height: 480px;
  overflow: hidden;
  display: flex; flex-direction: column;
}
.headline-panel .hp-title {
  font-size: 21px; font-weight: 700; color: var(--primary-darkest);
  padding-bottom: 12px;
  border-bottom: 2px solid var(--primary);
  margin-bottom: 14px;
  display: flex; justify-content: space-between; align-items: center;
}
.hp-title .more { font-size: 13px; font-weight: normal; color: var(--text-light); }
.headline-top { margin-bottom: 12px; }
.headline-top a { font-size: 20px; font-weight: 700; line-height: 1.45; display: block; letter-spacing: .3px; }
.headline-top a:hover { color: var(--primary); }
.headline-top p { font-size: 13px; color: var(--text-light); margin-top: 4px; }
.headline-list li {
  padding: 8px 0;
  border-bottom: 1px dashed #ddd;
  display: flex; gap: 10px; align-items: baseline;
}
.headline-list li:last-child { border-bottom: none; }
.headline-list li::before {
  content: "";
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--primary); flex-shrink: 0;
  transform: translateY(-2px);
}
.headline-list a {
  flex: 1; font-size: 14.5px; font-weight: 500;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.headline-list li .date {
  flex-shrink: 0; font-size: 12.5px; color: #aaa;
}

/* ---------- 栏目区块 ---------- */
.section { margin-bottom: 36px; }
.section-head {
  display: flex; justify-content: space-between; align-items: center;
  border-bottom: 2px solid var(--border);
  margin-bottom: 20px;
}
.section-head h2 {
  font-size: 24px; color: var(--primary-darkest);
  font-weight: 700; letter-spacing: .5px;
  padding-bottom: 10px;
  border-bottom: 3px solid var(--primary);
  margin-bottom: -2px;
  display: inline-flex; align-items: center; gap: 8px;
}
/* 栏目标题图标：内联 SVG 继承主题色，与文字基线居中对齐 */
.section-ico { width: 22px; height: 22px; color: var(--primary); flex-shrink: 0; }
.section-head .more { font-size: 13px; color: var(--text-light); }
.section-head .more:hover { color: var(--primary); }

/* 知识卡片 */
.card-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.card {
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: var(--white);
  transition: transform .25s, box-shadow .25s;
}
.card:hover { transform: translateY(-5px); box-shadow: 0 10px 24px rgba(145,0,0,.12); }
.card-thumb {
  height: 150px;
  display: flex; align-items: center; justify-content: center;
  font-size: 52px; color: rgba(255,255,255,.85);
}
.thumb-1 { background: linear-gradient(135deg, #D7000F, #B60005); }
.thumb-2 { background: linear-gradient(135deg, #B60005, #910000); }
.thumb-3 { background: linear-gradient(135deg, #910000, #6e0000); }
.thumb-4 { background: linear-gradient(135deg, #e8474f, #910000); }
.card-body { padding: 14px 16px 18px; }
.card-tag {
  display: inline-block;
  font-size: 12px; color: var(--primary);
  background: rgba(215, 0, 15, .08);
  border-radius: 4px; padding: 1px 8px; margin-bottom: 8px;
}
.card-body h3 { font-size: 16px; line-height: 1.5; margin-bottom: 8px; font-weight: 700; }
.card-body h3 a:hover { color: var(--primary); }
.card-body p {
  font-size: 13px; color: var(--text-light);
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.card-date { font-size: 12px; color: #aaa; margin-top: 10px; }

/* 科普文章列表 */
.article-list li {
  display: flex; align-items: baseline; gap: 14px;
  padding: 13px 2px;
  border-bottom: 1px dashed #e5e5e5;
}
.article-list li a {
  flex: 1; font-size: 15.5px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.article-list li a:hover { color: var(--primary); }
.article-list li .tag {
  flex-shrink: 0; font-size: 12px; color: var(--primary-dark);
  border: 1px solid rgba(215,0,15,.35); border-radius: 3px; padding: 0 6px;
}
/* 来源：字号更小、颜色更淡，图标点缀主题色 */
.article-list li .src {
  flex-shrink: 0; display: inline-flex; align-items: center; gap: 4px;
  font-size: 12px; color: #9a9a9a;
  max-width: 150px;
}
.article-list li .src .src-ico { width: 13px; height: 13px; flex-shrink: 0; color: var(--primary); opacity: .75; }
.article-list li .src .src-txt { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
/* 时间：更浅、等宽数字，并用竖线与来源分隔，避免拥挤 */
.article-list li .date {
  flex-shrink: 0; white-space: nowrap;
  font-size: 12.5px; color: #b3b3b3; font-weight: 500;
  letter-spacing: .3px; font-variant-numeric: tabular-nums;
  padding-left: 14px; margin-left: 2px;
  border-left: 1px solid #e5e5e5;
}

/* ---------- 列表页文章条目(纯文字排版) ---------- */

/* ---------- 列表页文章条目(左图 + 右文) ---------- */
.list-item {
  display: flex; gap: 18px; align-items: stretch;
  padding: 18px 2px;
  border-bottom: 1px dashed #e5e5e5;
}
.list-item:last-child { border-bottom: none; }
.list-item > a { flex-shrink: 0; display: block; }
.list-item .info { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.list-item > .info:only-child { width: 100%; }
.list-item .info h3 { font-size: 17px; font-weight: 700; line-height: 1.5; margin-bottom: 8px; }
.list-item .info h3 a:hover { color: var(--primary); }
.list-item .info .summary {
  font-size: 13.5px; color: var(--text-light); line-height: 1.8;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.list-item .info .meta {
  margin-top: auto; padding-top: 10px;
  font-size: 12.5px; color: #b3b3b3; font-weight: 500;
  letter-spacing: .3px; font-variant-numeric: tabular-nums;
}
.list-item .info .meta .cat {
  display: inline-block; margin-right: 10px;
  font-size: 12px; font-weight: 400; letter-spacing: 0;
  color: var(--primary-dark);
  background: rgba(215,0,15,.06);
  border: 1px solid rgba(215,0,15,.25); border-radius: 3px;
  padding: 0 6px;
}

/* ---------- 面包屑 / 列表页标题 / 分页 ---------- */
.breadcrumb {
  font-size: 14px; color: var(--text-light);
  margin-bottom: 22px;
}
.breadcrumb a { color: var(--text-light); }
.breadcrumb a:hover { color: var(--primary); }
.breadcrumb .sep { margin: 0 8px; color: #ccc; }

.page-title {
  font-size: 24px; color: var(--primary-darkest);
  font-weight: 700; letter-spacing: .5px;
  padding-bottom: 12px; margin-bottom: 8px;
  border-bottom: 2px solid var(--border);
  position: relative;
}
.page-title::after {
  content: "";
  position: absolute; left: 0; bottom: -2px;
  width: 70px; height: 3px;
  background: var(--primary);
}
.page-title > span { display: inline-flex; align-items: center; gap: 8px; }
.page-title-ico { width: 22px; height: 22px; color: var(--primary); flex-shrink: 0; }

.pagination {
  display: flex; justify-content: center; gap: 8px;
  margin-top: 30px;
}
.pagination a {
  min-width: 34px; height: 34px; padding: 0 10px;
  border: 1px solid var(--border); border-radius: 6px;
  background: var(--white);
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; color: var(--text);
  transition: all .2s;
}
.pagination a:hover { border-color: var(--primary); color: var(--primary); }
.pagination a.cur {
  background: var(--primary); border-color: var(--primary);
  color: var(--white); font-weight: bold;
}

/* ---------- 文章详情页 ---------- */
.article-box {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 30px 34px;
}
.article-box h1 {
  font-size: 26px; line-height: 1.5;
  color: var(--primary-darkest); font-weight: 700; letter-spacing: .5px;
  padding-bottom: 16px; margin-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.article-meta {
  display: flex; flex-wrap: wrap; gap: 4px 18px;
  font-size: 13px; color: #9a9a9a;
  margin-bottom: 24px;
}
.article-meta .src { color: var(--primary-dark); font-weight: 500; }

/* 正文富文本排版:内容来自后端富文本,需覆盖全局 reset(如 ul/ol 去符号) */
.article-content { font-size: 16px; line-height: 2; color: var(--text); }
.article-content p { margin-bottom: 18px; text-align: justify; }
.article-content h2,
.article-content h3 {
  font-size: 19px; line-height: 1.4; color: var(--primary-darkest);
  margin: 28px 0 14px;
  padding-left: 12px;
  border-left: 4px solid var(--primary);
}
.article-content h3 { font-size: 17px; }
.article-content img { margin: 18px auto; border-radius: 8px; }
.article-content ul { list-style: disc; margin: 0 0 18px 26px; }
.article-content ol { list-style: decimal; margin: 0 0 18px 26px; }
.article-content li { margin-bottom: 6px; }
.article-content blockquote {
  margin: 0 0 18px; padding: 12px 18px;
  background: var(--bg-gray);
  border-left: 4px solid var(--primary);
  border-radius: 4px;
  color: var(--text-light);
}
.article-content table { width: 100%; border-collapse: collapse; margin-bottom: 18px; }
.article-content th,
.article-content td { border: 1px solid var(--border); padding: 8px 12px; font-size: 14px; }
.article-content a { color: var(--primary); text-decoration: underline; }
.article-content strong { color: var(--primary-darkest); }

.article-tags {
  display: flex; flex-wrap: wrap; gap: 10px;
  margin-top: 28px; padding-top: 18px;
  border-top: 1px dashed var(--border);
}
.article-tags a {
  font-size: 12.5px; color: var(--primary-dark);
  background: rgba(215,0,15,.06);
  border: 1px solid rgba(215,0,15,.25);
  border-radius: 14px; padding: 3px 14px;
  transition: all .2s;
}
.article-tags a:hover { background: var(--primary); border-color: var(--primary); color: var(--white); }

.disclaimer {
  margin-top: 26px; padding: 12px 16px;
  font-size: 13px; color: var(--text-light); line-height: 1.9;
  background: rgba(215, 0, 15, .04);
  border: 1px dashed rgba(215, 0, 15, .25);
  border-radius: 6px;
}

/* ---------- 侧边栏 ---------- */
.sidebar > div { margin-bottom: 24px; }
.side-box {
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
}
.side-box .sb-head {
  background: linear-gradient(180deg, var(--primary), var(--primary-dark));
  color: var(--white);
  font-size: 17px; font-weight: bold;
  padding: 10px 18px;
}
.side-box .sb-body { padding: 8px 18px 14px; }
.rank-list li {
  display: flex; gap: 12px; align-items: baseline;
  padding: 10px 0; border-bottom: 1px dashed #eee;
}
.rank-list li:last-child { border-bottom: none; }
.rank-list .num {
  width: 22px; height: 22px; flex-shrink: 0;
  background: #ccc; color: var(--white);
  border-radius: 4px; font-size: 13px;
  display: flex; align-items: center; justify-content: center;
  transform: translateY(3px);
}
.rank-list li:nth-child(1) .num { background: var(--primary); }
.rank-list li:nth-child(2) .num { background: var(--primary-dark); }
.rank-list li:nth-child(3) .num { background: var(--primary-darkest); }
.rank-list a { font-size: 14px; line-height: 1.5; }

/* 侧边栏盒子标题 */
.sb-head { display: flex; justify-content: space-between; align-items: center; }

/* 侧边栏:品牌横幅与标签云 */
.side-banner {
  background: linear-gradient(135deg, var(--primary), var(--primary-darkest));
  border-radius: 10px;
  padding: 24px 20px;
  text-align: center;
  color: var(--white);
  box-shadow: 0 4px 14px rgba(145, 0, 0, .2);
}
.side-banner h3 { font-size: 20px; letter-spacing: 1px; margin-bottom: 8px; }
.side-banner p { font-size: 13px; color: rgba(255, 255, 255, .85); margin-bottom: 14px; }
.btn-ghost {
  display: inline-block;
  border: 1px solid rgba(255, 255, 255, .8);
  border-radius: 18px;
  padding: 5px 22px;
  font-size: 13px; color: var(--white);
  transition: all .2s;
}
.btn-ghost:hover { background: var(--white); color: var(--primary); }

.tag-cloud {
  display: flex; flex-wrap: wrap; gap: 10px;
  padding: 14px 18px 18px;
}
.tag-cloud a {
  font-size: 12.5px; color: var(--text-light);
  background: var(--bg-gray);
  border: 1px solid var(--border);
  border-radius: 14px; padding: 3px 12px;
  transition: all .2s;
}
.tag-cloud a:hover { background: var(--primary); border-color: var(--primary); color: var(--white); }

/* ---------- 医生介绍页 ---------- */
.doctor-profile {
  display: flex; gap: 28px; align-items: center;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 30px 34px;
  margin-bottom: 24px;
}
.doctor-profile .doc-avatar {
  width: 130px; height: 130px; flex-shrink: 0;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--white); font-size: 52px; font-weight: bold;
  background: linear-gradient(135deg, #D7000F, #910000);
  border: 4px solid rgba(215, 0, 15, .15);
}
.doctor-profile .doc-detail { flex: 1; }
.doctor-profile .doc-name-big { font-size: 26px; font-weight: bold; color: var(--primary-darkest); margin-bottom: 6px; }
.doctor-profile .doc-name-big small { font-size: 14px; color: var(--text-light); font-weight: normal; margin-left: 12px; }
.doctor-profile .doc-tags { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0; }
.doctor-profile .doc-tags span {
  font-size: 12.5px; color: var(--primary-dark);
  background: rgba(215,0,15,.06);
  border: 1px solid rgba(215,0,15,.25);
  border-radius: 14px; padding: 2px 12px;
}
.doctor-profile .doc-meta-line { font-size: 14px; color: var(--text-light); line-height: 2; }
.doctor-profile .btn-book {
  display: inline-block; margin-top: 12px;
  background: var(--primary); color: var(--white);
  border-radius: 22px; padding: 8px 30px;
  font-size: 14px; transition: background .2s;
}
.doctor-profile .btn-book:hover { background: var(--primary-dark); color: var(--white); }

.doctor-section {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 26px 34px;
  margin-bottom: 24px;
}
.doctor-section h2 {
  font-size: 19px; color: var(--primary-darkest);
  padding-bottom: 10px; margin-bottom: 16px;
  border-bottom: 2px solid var(--border);
  position: relative;
}
.doctor-section h2::after {
  content: "";
  position: absolute; left: 0; bottom: -2px;
  width: 70px; height: 3px;
  background: var(--primary);
}
.doctor-section p { font-size: 15px; line-height: 1.95; margin-bottom: 12px; text-align: justify; }
.doctor-section ul.honor-list li {
  padding: 8px 0 8px 20px;
  position: relative;
  font-size: 14.5px; color: var(--text);
  border-bottom: 1px dashed #eee;
}
.doctor-section ul.honor-list li:last-child { border-bottom: none; }
.doctor-section ul.honor-list li::before {
  content: "";
  position: absolute; left: 4px; top: 18px;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--primary);
}
.doctor-works {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
}
.doctor-works .work-item {
  height: 130px; border-radius: 8px;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255,255,255,.9); font-size: 15px;
}
@media (max-width: 768px) {
  .doctor-profile { flex-direction: column; text-align: center; padding: 24px 18px; }
  .doctor-profile .doc-tags { justify-content: center; }
  .doctor-works { grid-template-columns: 1fr; }
}

/* ---------- 专家团队：医生列表 ---------- */
.doctor-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}
.doctor-card {
  display: flex; gap: 16px; align-items: center;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 18px;
  background: var(--white);
  transition: transform .25s, box-shadow .25s;
}
.doctor-card:hover { transform: translateY(-4px); box-shadow: 0 10px 24px rgba(145,0,0,.12); }
.doctor-card .dc-avatar {
  width: 72px; height: 72px; flex-shrink: 0;
  border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  color: var(--white); font-size: 30px; font-weight: bold;
  background: linear-gradient(135deg, #D7000F, #910000);
}
.doctor-card .dc-body { min-width: 0; }
.doctor-card .dc-name { font-size: 18px; font-weight: bold; color: var(--primary-darkest); }
.doctor-card .dc-name small { font-size: 13px; color: var(--text-light); font-weight: normal; margin-left: 8px; }
.doctor-card .dc-tags { display: flex; flex-wrap: wrap; gap: 6px; margin: 8px 0; }
.doctor-card .dc-tags span {
  font-size: 12px; color: var(--primary-dark);
  background: rgba(215,0,15,.06);
  border: 1px solid rgba(215,0,15,.2);
  border-radius: 12px; padding: 1px 10px;
}
.doctor-card .dc-meta { font-size: 13px; color: var(--text-light); }

/* 头像 / 医生照片：图片铺满圆形容器，加载失败时露出姓名首字 */
.doctor-card .dc-avatar,
.doctor-profile .doc-avatar { position: relative; overflow: hidden; }
.doctor-card .dc-avatar img,
.doctor-profile .doc-avatar img {
  position: absolute; top: 0; left: 0;
  width: 100%; height: 100%; object-fit: cover;
  border-radius: 50%; display: block;
}
.doc-photo img { max-width: 320px; width: 100%; border-radius: 8px; display: block; }

.list-tip { padding: 40px 0; text-align: center; color: var(--text-light); font-size: 15px; }
.pagination a.disabled { color: #ccc; pointer-events: none; }
@media (max-width: 900px) {
  .doctor-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .doctor-grid { grid-template-columns: 1fr; }
}

/* ---------- 首页医生排行榜：主视觉 + 侧边缩略图 ---------- */
.doctor-showcase { margin-bottom: 44px; --dsc-height: 520px; }
.dsc-wrap {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 20px;
  align-items: stretch;
}
.dsc-wrap[hidden] { display: none; }
.dsc-stage {
  position: relative;
  display: block;
  height: var(--dsc-height);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 4px 16px rgba(0, 0, 0, .1);
}
.dsc-stage-media,
.dsc-thumb-media {
  position: relative;
  width: 100%; height: 100%;
  display: flex; align-items: center; justify-content: center;
  color: rgba(255, 255, 255, .85);
  background: linear-gradient(135deg, var(--primary), var(--primary-darkest));
  overflow: hidden;
}
.dsc-stage-media { font-size: 96px; font-weight: bold; }
.dsc-thumb-media { font-size: 30px; font-weight: bold; }
.dsc-stage-media img,
.dsc-thumb-media img {
  position: absolute; top: 0; left: 0;
  width: 100%; height: 100%; object-fit: contain; display: block;
}
.dsc-caption {
  position: absolute; left: 0; right: 0; bottom: 0;
  display: flex; align-items: center; gap: 14px;
  padding: 14px 20px;
  background: linear-gradient(90deg, rgba(145, 0, 0, .92), rgba(215, 0, 15, .78));
  color: var(--white);
}
.dsc-play {
  width: 34px; height: 34px; flex-shrink: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .22);
  position: relative;
}
.dsc-play::after {
  content: "";
  position: absolute; left: 0; right: 0; top: 0; height: 6px;
  background: linear-gradient(90deg, var(--primary), var(--primary-darkest));
}
.dsc-caption-text {
  flex: 1; min-width: 0;
  font-size: 15px; line-height: 1.5;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.dsc-side {
  display: flex; flex-direction: column; gap: 10px;
  min-width: 0;
  height: var(--dsc-height);
}
.dsc-arrow {
  height: 30px; flex-shrink: 0;
  border: 1px solid var(--border); border-radius: 8px;
  background: var(--white);
  color: var(--text-light); font-size: 14px; line-height: 1;
  cursor: pointer; transition: all .2s;
}
.dsc-arrow:hover { border-color: var(--primary); color: var(--primary); }
.dsc-thumbs {
  flex: 1; min-height: 0;
  display: flex; flex-direction: column; gap: 14px;
  overflow-y: auto; overflow-x: hidden;
  scrollbar-width: thin;
}
.dsc-thumb {
  position: relative;
  height: 118px; flex-shrink: 0;
  border-radius: 10px; overflow: hidden;
  border: 2px solid transparent;
  cursor: pointer;
  transition: border-color .2s;
}
.dsc-thumb.on { border-color: var(--primary); }
.dsc-thumb-cap {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 12px 12px 8px;
  background: linear-gradient(transparent, rgba(0,0,0,.68));
  color: var(--white); font-size: 14px; font-weight: bold;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.dsc-thumb-cap small {
  display: block; font-weight: normal; font-size: 12px;
  color: rgba(255,255,255,.8);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
/* 排行榜徽章：叠加在图片左上角，前 3 名金/银/铜渐变，其余半透明黑 */
.dsc-rank {
  position: absolute; top: 8px; left: 8px; z-index: 2;
  min-width: 26px; height: 26px; padding: 0 8px;
  border-radius: 13px;
  background: rgba(0,0,0,.45); color: var(--white);
  font-size: 13px; font-weight: bold;
  display: flex; align-items: center; justify-content: center;
}
.dsc-rank[hidden] { display: none; }
.dsc-rank.top1 { background: linear-gradient(135deg, #f7b500, #d98e00); }
.dsc-rank.top2 { background: linear-gradient(135deg, #c0c5cb, #8f959c); }
.dsc-rank.top3 { background: linear-gradient(135deg, #c9762c, #a05a1c); }
.dsc-rank-stage {
  top: 18px; left: 18px;
  min-width: 56px; height: 34px; padding: 0 14px;
  border-radius: 17px;
  font-size: 16px; letter-spacing: 1px;
  box-shadow: 0 2px 10px rgba(0,0,0,.3);
}
.dsc-cap-avatar {
  width: 44px; height: 44px; flex-shrink: 0;
  border-radius: 50%;
  overflow: hidden;
  position: relative;
  display: flex; align-items: center; justify-content: center;
  background: rgba(255, 255, 255, .22);
  color: var(--white);
  font-size: 18px; font-weight: bold;
}
.dsc-cap-avatar img {
  position: absolute; top: 0; left: 0;
  width: 100%; height: 100%; object-fit: cover; display: block;
}

@media (max-width: 1024px) {
  .doctor-showcase { --dsc-height: 420px; }
  .dsc-wrap { grid-template-columns: 1fr; }
  .dsc-side { flex-direction: row; align-items: center; height: auto; }
  .dsc-arrow { width: 34px; height: 44px; }
  .dsc-thumbs { flex-direction: row; overflow-x: auto; overflow-y: hidden; }
  .dsc-thumb { width: 150px; height: 104px; }
}
.doc-avatar-wrap { position: relative; flex-shrink: 0; }
.doc-verify {
  position: absolute; left: 50%; transform: translateX(-50%); bottom: -10px;
  white-space: nowrap;
  font-size: 12px; color: var(--white);
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: 12px; padding: 2px 12px;
  box-shadow: 0 2px 8px rgba(145, 0, 0, .3);
}
.doctor-profile .doc-meta-grid { display: flex; flex-wrap: wrap; gap: 4px 28px; margin-top: 6px; }
.doctor-profile .doc-meta-line { position: relative; padding-left: 16px; }
.doctor-profile .doc-meta-line::before {
  content: "";
  position: absolute; left: 0; top: 12px;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--primary);
}
.doctor-profile .doc-actions { display: flex; gap: 12px; flex-wrap: wrap; margin-top: 14px; }
.doctor-profile .btn-book.ghost {
  background: var(--white); color: var(--primary);
  border: 1px solid var(--primary);
}
.doctor-profile .btn-book.ghost:hover { background: rgba(215, 0, 15, .06); color: var(--primary-dark); }

.doctor-section h2 { display: flex; align-items: center; }
.doctor-section h2 .sec-ico {
  width: 8px; height: 20px; border-radius: 2px; margin-right: 10px; flex-shrink: 0;
  background: linear-gradient(180deg, var(--primary), var(--primary-darkest));
}

/* 侧边栏：预约流程 / 就诊须知 / 安全提示 */
.step-list li {
  position: relative; padding: 8px 0 8px 34px;
  font-size: 14px; color: var(--text);
  border-bottom: 1px dashed #eee;
}
.step-list li:last-child { border-bottom: none; }
.step-list li b {
  position: absolute; left: 0; top: 8px;
  width: 22px; height: 22px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  background: rgba(215, 0, 15, .08); color: var(--primary);
  font-size: 13px; font-weight: bold;
}
.tip-list li {
  position: relative; padding: 6px 0 6px 18px;
  font-size: 13.5px; color: var(--text-light); line-height: 1.7;
}
.tip-list li::before {
  content: "";
  position: absolute; left: 2px; top: 14px;
  width: 6px; height: 6px; border-radius: 50%;
  background: var(--primary);
}
.safe-note {
  font-size: 13px; color: var(--primary-darkest); line-height: 1.8;
  background: rgba(215, 0, 15, .05);
  border-left: 3px solid var(--primary);
  border-radius: 4px; padding: 10px 12px;
}
@media (max-width: 768px) {
  .doctor-profile .doc-meta-grid { justify-content: center; }
  .doctor-profile .doc-actions { justify-content: center; }
  .doc-verify { bottom: -8px; }
}

/* ---------- 页脚 ---------- */
.footer {
  background: linear-gradient(180deg, var(--primary-darkest), #6e0000);
  color: rgba(255,255,255,.85);
  padding: 40px 0 0;
  margin-top: 20px;
}
.footer-cols {
  display: grid;
  grid-template-columns: 2.4fr 1fr 1fr;
  gap: 36px;
  padding-bottom: 30px;
}
.footer-cols > div:first-child { margin-right: 28px; }
.footer h4 {
  color: var(--white); font-size: 17px; margin-bottom: 14px;
  padding-bottom: 8px;
  border-bottom: 1px solid rgba(255,255,255,.2);
}
.footer p { font-size: 13.5px; line-height: 2; }
.footer a { color: rgba(255,255,255,.85); font-size: 13.5px; }
.footer a:hover { color: var(--white); }
.footer ul li { padding: 3px 0; }
.footer .contact p { display: flex; gap: 8px; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,.15);
  padding: 16px 0 20px;
  text-align: center;
  font-size: 12.5px;
  color: rgba(255,255,255,.55);
  line-height: 2;
}

/* ---------- 响应式 ---------- */
@media (max-width: 1024px) {
  .layout { grid-template-columns: 1fr; }
  .focus-area { grid-template-columns: 1fr; }
  .carousel, .headline-panel { height: auto; }
  .carousel { height: 300px; }
  .card-grid { grid-template-columns: repeat(2, 1fr); }
  .project-grid { grid-template-columns: repeat(3, 1fr); }
  .footer-cols { grid-template-columns: 1fr 1fr; }
  .nav-list > li > a { font-size: 14px; padding: 0 4px; }
}

/* ---------- 首页优选医院 ---------- */
.hospital-showcase .section-head h2 .hsp-sub {
  font-size: 14px; font-weight: normal; color: var(--text-light);
  margin-left: 10px; letter-spacing: 1px;
}
.hsp-tabs { display: flex; align-items: center; gap: 6px; overflow-x: auto; }
.hsp-tab {
  background: none; border: none; cursor: pointer;
  font-size: 14px; color: var(--text);
  padding: 5px 14px; border-radius: 16px;
  white-space: nowrap; transition: all .2s;
}
.hsp-tab:hover { color: var(--primary); }
.hsp-tab.on { background: var(--primary); color: var(--white); }

/* 卡片网格：外框 + 1px 细线分隔（表格线效果） */
.hsp-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border: 1px solid var(--border);
  border-radius: 10px;
  overflow: hidden;
  background: var(--white);
}
.hsp-card {
  padding: 26px 22px;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  text-align: center;
  cursor: pointer;
  transition: background .2s, box-shadow .2s;
}
.hsp-card:nth-child(4n) { border-right: none; }
.hsp-card:nth-child(n + 5) { margin-top: -1px; }
.hsp-card:hover { background: #fdf7f7; }
.hsp-card.on { background: #fdf3f3; box-shadow: inset 0 0 0 2px var(--primary); }

.hsp-logo {
  width: 96px; height: 96px; margin: 0 auto 14px;
  border-radius: 50%; overflow: hidden;
  background: var(--bg-gray);
  display: flex; align-items: center; justify-content: center;
  border: 3px solid var(--border);
}
.hsp-logo img { width: 100%; height: 100%; object-fit: cover; }
.hsp-logo .media-fb { font-size: 34px; color: var(--primary); font-weight: 700; }

.hsp-name {
  font-size: 16.5px; font-weight: 700; color: var(--text);
  display: flex; align-items: center; justify-content: center; gap: 6px;
  line-height: 25px; min-height: 50px;
}
.hsp-name-text {
  display: -webkit-box; -webkit-box-orient: vertical;
  -webkit-line-clamp: 2; line-clamp: 2; overflow: hidden;
  word-break: break-all;
}
.hsp-verify {
  flex-shrink: 0;
  font-size: 11px; font-weight: 700; color: #5b4300;
  background: linear-gradient(135deg, #ffe08a, #e8a723);
  border: 1px solid rgba(184, 134, 11, .35);
  border-radius: 9px; padding: 1px 8px;
}
.hsp-meta {
  font-size: 12.5px; color: var(--text-light);
  margin-top: 5px;
  line-height: 19px; min-height: 19px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.hsp-stars { margin-top: 7px; font-size: 13px; color: #ddd; letter-spacing: 2px; line-height: 18px; }
.hsp-stars .hsp-star.on { color: #ff9500; }
.hsp-stars em { font-style: normal; font-size: 12px; color: #ff9500; margin-left: 6px; letter-spacing: 0; }
.hsp-addr {
  font-size: 12px; color: var(--text-light); margin-top: 6px;
  line-height: 18px; min-height: 18px;
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}

/* 患者评论面板 */
.hsp-review { margin-top: 20px; border: 1px solid var(--border); border-radius: 10px; background: var(--bg-gray); }
.hsp-review-head {
  padding: 13px 20px;
  font-size: 15px; color: var(--text);
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; gap: 12px; flex-wrap: wrap;
}
.hsp-review-head strong { color: var(--primary-darkest); font-size: 16px; }
.hsp-review-sign { font-size: 12.5px; color: var(--text-light); }
.hsp-review-body { padding: 6px 20px 14px; }

.hsp-review-list { display: flex; flex-direction: column; }
.hsp-rv-item {
  display: flex; gap: 14px;
  padding: 16px 0;
  border-bottom: 1px dashed #e2e2e2;
}
.hsp-rv-item:last-child { border-bottom: none; }
.hsp-rv-avatar {
  width: 46px; height: 46px; border-radius: 50%;
  overflow: hidden; flex-shrink: 0;
  background: var(--white); border: 1px solid var(--border);
  display: flex; align-items: center; justify-content: center;
}
.hsp-rv-avatar img { width: 100%; height: 100%; object-fit: cover; }
.hsp-rv-avatar .media-fb { font-size: 18px; color: var(--primary); font-weight: 700; }
.hsp-rv-main { flex: 1; min-width: 0; }
.hsp-rv-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.hsp-rv-name { font-size: 14px; font-weight: 700; color: var(--text); }
.hsp-rv-stars { font-size: 12px; color: #ddd; letter-spacing: 1px; }
.hsp-rv-stars .hsp-star.on { color: #ff9500; }
.hsp-rv-stars em { font-style: normal; color: #ff9500; margin-left: 4px; }
.hsp-rv-item-tag {
  font-size: 11.5px; color: var(--primary);
  border: 1px solid rgba(215, 0, 15, .35);
  border-radius: 9px; padding: 0 8px; background: var(--white);
}
.hsp-rv-date { font-size: 12px; color: #aaa; margin-left: auto; }
.hsp-rv-content { font-size: 13.5px; color: var(--text); line-height: 1.8; margin-top: 5px; }
.hsp-rv-imgs { display: flex; gap: 8px; margin-top: 8px; flex-wrap: wrap; }
.hsp-rv-img {
  width: 76px; height: 76px; border-radius: 6px;
  overflow: hidden; border: 1px solid var(--border); background: var(--white);
}
.hsp-rv-img img { width: 100%; height: 100%; object-fit: cover; }
.hsp-rv-reply {
  margin-top: 9px; padding: 9px 12px;
  background: var(--white);
  border-left: 3px solid var(--primary);
  border-radius: 0 6px 6px 0;
  font-size: 12.5px; color: var(--text-light); line-height: 1.75;
}
.hsp-rv-reply b { color: var(--primary-darkest); font-weight: 700; }

/* 响应式：≥1400px 4列；1000–1400px 3列；700–1000px 2列；<700px 1列 */
@media (max-width: 1400px) {
  .hsp-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .hsp-card { border-right: 1px solid var(--border); }
  .hsp-card:nth-child(4n) { border-right: 1px solid var(--border); }
  .hsp-card:nth-child(3n) { border-right: none; }
  .hsp-card:nth-child(n + 4) { margin-top: -1px; }
}
@media (max-width: 1000px) {
  .hsp-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .hsp-card:nth-child(3n) { border-right: 1px solid var(--border); }
  .hsp-card:nth-child(2n) { border-right: none; }
  .hsp-card:nth-child(n + 3) { margin-top: -1px; }
  .hsp-review-head { padding: 12px 16px; }
  .hsp-review-body { padding: 4px 16px 12px; }
}
@media (max-width: 700px) {
  .hsp-grid { grid-template-columns: minmax(0, 1fr); }
  .hsp-card { border-right: none; }
  .hsp-card:nth-child(3n), .hsp-card:nth-child(2n) { border-right: none; }
  .hsp-card:nth-child(n + 2) { margin-top: -1px; }
  /* 横向紧凑卡片：logo 左、信息右 */
  .hsp-card { display: flex; align-items: center; gap: 16px; text-align: left; padding: 18px 16px; }
  .hsp-logo { width: 72px; height: 72px; margin: 0; flex-shrink: 0; }
  .hsp-name { justify-content: flex-start; min-height: 0; }
  .hsp-card > div:not(.hsp-logo) { min-width: 0; }
  .hsp-rv-date { margin-left: 0; width: 100%; }
}

/* 首页医院卡片作为链接时去除下划线并继承文字色 */
a.hsp-card { display: block; text-decoration: none; color: inherit; }

/* 优选医院列表页：筛选工具条 */
.hsp-listbar { display: flex; justify-content: flex-end; margin-bottom: 16px; }

/* ---------- 医院详情页 ---------- */
.hospital-profile {
  display: flex; gap: 28px; align-items: center;
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 30px 34px;
  margin-bottom: 20px;
}
.hospital-profile .hp-logo {
  width: 120px; height: 120px; flex-shrink: 0;
  border-radius: 16px; overflow: hidden;
  display: flex; align-items: center; justify-content: center;
  background: var(--bg-gray);
  border: 1px solid var(--border);
  position: relative;
}
.hospital-profile .hp-logo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hospital-profile .hp-logo .media-fb { font-size: 46px; color: var(--primary); font-weight: 700; }
.hp-detail { flex: 1; min-width: 0; }
.hp-name-big {
  font-size: 26px; font-weight: bold; color: var(--primary-darkest);
  display: flex; align-items: center; gap: 10px; flex-wrap: wrap;
}
.hp-stars { margin-top: 8px; font-size: 15px; color: #ddd; letter-spacing: 2px; }
.hp-stars .hsp-star.on { color: #ff9500; }
.hp-stars em { font-style: normal; font-size: 13px; color: #ff9500; margin-left: 6px; letter-spacing: 0; }
.hp-sign { margin-top: 6px; font-size: 14px; color: var(--text-light); }
.hp-meta-grid { margin-top: 12px; display: flex; flex-direction: column; gap: 4px; }
.hp-meta-grid .hp-meta-line { font-size: 14px; color: var(--text-light); line-height: 1.9; }
.hp-actions { margin-top: 6px; }
.hospital-profile .btn-book {
  display: inline-block; margin-top: 12px; margin-right: 10px;
  background: var(--primary); color: var(--white);
  border-radius: 22px; padding: 8px 30px;
  font-size: 14px; transition: background .2s; text-decoration: none;
}
.hospital-profile .btn-book:hover { background: var(--primary-dark); color: var(--white); }
.hospital-profile .btn-book.ghost { background: var(--white); color: var(--primary); border: 1px solid var(--primary); }
.hospital-profile .btn-book.ghost:hover { background: rgba(215, 0, 15, .06); }

/* 详情页标签导航 */
.hsp-detail-tabs {
  display: flex; gap: 4px; flex-wrap: wrap;
  border-bottom: 2px solid var(--border);
  margin-bottom: 20px;
}
.hsp-dtab {
  background: none; border: none; cursor: pointer;
  font-size: 15.5px; color: var(--text);
  padding: 12px 26px; position: relative;
  border-radius: 8px 8px 0 0;
  transition: color .2s, background .2s;
}
.hsp-dtab:hover { color: var(--primary); background: #fdf3f3; }
.hsp-dtab.on { color: var(--primary); font-weight: 700; }
.hsp-dtab.on::after {
  content: ""; position: absolute; left: 0; right: 0; bottom: -2px;
  height: 3px; background: var(--primary);
}
.hsp-panel { min-height: 120px; }

/* 详情页信息条目 / 服务标签 / 证书 */
.hp-info-list { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px 24px; }
.hp-info-list .hp-info-item { font-size: 14.5px; color: var(--text); line-height: 1.9; }
.hp-info-list .hp-info-item b { color: var(--text-light); font-weight: normal; margin-right: 6px; }
.hp-services { display: flex; flex-wrap: wrap; gap: 8px; }
.hp-services span {
  font-size: 12.5px; color: var(--primary-dark);
  background: rgba(215, 0, 15, .06);
  border: 1px solid rgba(215, 0, 15, .25);
  border-radius: 14px; padding: 2px 12px;
}
.hp-license img {
  max-width: 260px; width: 100%; border-radius: 8px;
  border: 1px solid var(--border); display: block;
}

@media (max-width: 768px) {
  .hospital-profile { flex-direction: column; text-align: center; padding: 24px 18px; }
  .hp-name-big { justify-content: center; }
  .hp-meta-grid { align-items: center; }
  .hp-info-list { grid-template-columns: 1fr; }
  .hsp-dtab { padding: 10px 16px; font-size: 14.5px; }
}
