/* detail.css — 文章详情页专属样式（公共部分继承自 index.css） */

/* ===========================
   面包屑导航
=========================== */
.breadcrumb {
  background: transparent;
  padding: 14px 0;
  border-bottom: 1px solid #e4ddd3;
  margin-bottom: 0;
}

.breadcrumb__inner {
  width: 1200px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
  color: #888;
}

.breadcrumb__inner a {
  color: #888;
  transition: color 0.2s;
}

.breadcrumb__inner a:hover {
  color: #bb2027;
}

.breadcrumb__sep {
  color: #ccc;
  font-size: 12px;
}

.breadcrumb__cur {
  color: #555;
}

/* ===========================
   详情页主体布局（左侧栏 + 右侧内容）
=========================== */
.detail-page {
  background: #f5f0e8;
  min-height: 600px;
  padding: 32px 0 60px;
}

.detail-layout {
  width: 1200px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 28px;
  align-items: start;
}

/* ===========================
   左侧边栏
=========================== */
.detail-sidebar {
  position: sticky;
  top: 20px;
  display: flex;
  flex-direction: column;
  align-self: start;
}

.sidebar-category {
  background: #bb2027;
  padding: 14px 20px;
  border-radius: 3px 3px 0 0;
}

.sidebar-category__title {
  color: #fff;
  font-size: 17px;
  font-weight: 700;
  margin: 0;
  text-align: center;
}

/* 子导航外层：浅底 + 主题色描边（设计稿参考 padding/gap/flex） */
.sidebar-subnav-box {
  position: static;
  box-sizing: border-box;
  width: 100%;
  max-width: 240px;
  display: flex;
  flex-direction: column;
  align-self: stretch;
  flex-grow: 1;
  padding: 12px;
  gap: 1px;
  background: #ffefe0;
  
  border-top: none;
  border-radius: 0 0 3px 3px;
}

.sidebar-subnav {
  display: flex;
  flex-direction: column;
  gap: 1px;
  margin: 0;
  padding: 0;
  background: transparent;
  border: none;
  border-radius: 0;
  overflow: visible;
}

.sidebar-subnav a {
  display: block;
  padding: 11px 14px;
  color: #555;
  font-size: 14px;
  background: #fff;
  border-radius: 2px;
  border-bottom: none;
  text-align: center;
  transition: background 0.15s, color 0.15s;
}

.sidebar-subnav a:last-child {
  border-bottom: none;
}

.sidebar-subnav a:hover {
  background: #fdf6f0;
  color: #bb2027;
}

.sidebar-subnav a.is-active {
  color: #bb2027;
  font-weight: 700;
  background: rgba(187, 32, 39, 0.28);
}

/* 开班动态推荐（左侧下方卡片列表） */
.sidebar-news {
  margin-top: 24px;
}

.sidebar-news__heading {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
  font-size: 15px;
  font-weight: 700;
  color: #1a1a1a;
}

.sidebar-news__heading::before {
  content: '';
  display: inline-block;
  width: 4px;
  height: 16px;
  background: #bb2027;
  border-radius: 2px;
  flex-shrink: 0;
}

.sidebar-news-item {
  display: block;
  margin-bottom: 16px;
  cursor: pointer;
  text-decoration: none;
  color: inherit;
}

.sidebar-news-item:focus-visible {
  outline: 2px solid #bb2027;
  outline-offset: 2px;
}

.sidebar-news-item:visited {
  color: inherit;
}

.sidebar-news-item__thumb {
  width: 100%;
  height: 110px;
  overflow: hidden;
  border-radius: 2px;
  margin-bottom: 8px;
}

.sidebar-news-item__thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  transition: transform 0.4s;
}

.sidebar-news-item:hover .sidebar-news-item__thumb img {
  transform: scale(1.05);
}

.sidebar-news-item__title {
  font-size: 13px;
  color: #444;
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 4px;
}

.sidebar-news-item:hover .sidebar-news-item__title {
  color: #bb2027;
}

.sidebar-news-item__date {
  font-size: 12px;
  color: #aaa;
}

/* ===========================
   右侧详情主体
=========================== */
.detail-main {
  background: #fff;
  border-radius: 3px;
  padding: 36px 40px 40px;
}

.detail-main__title {
  font-size: 24px;
  font-weight: 700;
  color: #1a1a1a;
  text-align: center;
  line-height: 1.5;
  margin: 0 0 16px;
}

.detail-main__meta {
  text-align: center;
  color: #aaa;
  font-size: 13px;
  margin-bottom: 28px;
  padding-bottom: 20px;
  border-bottom: 1px solid #f0ece6;
}

.detail-content {
  color: #444;
  font-size: 15px;
  line-height: 2;
}

.detail-content p {
  margin: 0 0 18px;
  text-indent: 2em;
}

.detail-content p:last-child {
  margin-bottom: 0;
}

.detail-content img {
  max-width: 100%;
  display: block;
  margin: 20px auto;
  border-radius: 2px;
}

.detail-content h3 {
  font-size: 16px;
  font-weight: 700;
  color: #1a1a1a;
  margin: 28px 0 12px;
}

/* ===========================
   上一篇 / 下一篇导航
=========================== */
.detail-pagination {
  display: flex;
  justify-content: space-between;
  margin-top: 36px;
  padding-top: 20px;
  border-top: 1px solid #f0ece6;
  font-size: 14px;
  color: #666;
  gap: 16px;
}

.detail-pagination a {
  color: #666;
  transition: color 0.2s;
  max-width: 48%;
  line-height: 1.6;
}

.detail-pagination a:hover {
  color: #bb2027;
}

.detail-pagination span {
  color: #aaa;
  white-space: nowrap;
}
