/* 邻乐集政务风格主题 */
:root {
  --llj-primary: #c5161d;
  --llj-primary-dark: #a01218;
  --llj-primary-light: #fff1f0;
  --llj-bg: #f3f6fa;
  --llj-white: #ffffff;
  --llj-text: #1f2937;
  --llj-text-dark: #4b5563;
  --llj-text-gray: #6b7280;
  --llj-border: #d8dee8;
  --llj-border-light: #e6ebf2;
}

body {
  background: var(--llj-bg);
  font-family: -apple-system, BlinkMacSystemFont, 'PingFang SC', 'Microsoft YaHei', 'Helvetica Neue', sans-serif;
  color: var(--llj-text);
}

/* 导航栏 */
.cm-navbar {
  background: var(--llj-primary) !important;
  padding: 0;
  border-bottom: none !important;
}
.cm-navbar .navbar-nav .nav-link {
  color: rgba(255,255,255,.9) !important;
  font-weight: 500;
  padding: 14px 20px;
}
.cm-navbar .navbar-nav .nav-link:hover,
.cm-navbar .navbar-nav .nav-link.active {
  color: #fff !important;
  background: rgba(0,0,0,.15);
}
.navbar-brand img {
  height: 45px;
}

/* 首页焦点：后台裁剪尺寸为 1200x600，前台保持 2:1 视觉盒并居中裁剪 */
.hero-carousel {
  position: relative;
  overflow: hidden;
  background: #111827;
}
.hero-carousel,
.hero-carousel .carousel-inner,
.hero-carousel .carousel-item {
  height: clamp(240px, 50vw, 600px);
}
.hero-carousel-image {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
}
.hero-carousel-caption {
  left: 0;
  right: 0;
  bottom: 0;
  padding: 16px 24px 42px;
  background: linear-gradient(180deg, rgba(17,24,39,0) 0%, rgba(17,24,39,.72) 28%, rgba(17,24,39,.82) 100%);
}
.hero-carousel-caption h5 {
  font-size: 18px;
  font-weight: 700;
  text-shadow: 0 1px 2px rgba(0,0,0,.35);
}
.hero-carousel-indicators {
  bottom: 12px;
  margin-bottom: 0;
  z-index: 3;
}
.hero-carousel-indicators [data-bs-target] {
  width: 12px;
  height: 12px;
  border-radius: 50%;
}

/* 板块标题 */
.section-title {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 2px solid var(--llj-primary);
  padding-bottom: 12px;
  margin-bottom: 20px;
}
.section-title h2,
.section-title h3 {
  font-size: 20px;
  font-weight: 700;
  color: var(--llj-text);
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 0;
}
.section-title .bar {
  width: 4px;
  height: 20px;
  background: var(--llj-primary);
  display: inline-block;
  border-radius: 2px;
}
.section-title .more {
  font-size: 13px;
  color: var(--llj-text-gray);
}
.section-title .more:hover {
  color: var(--llj-primary);
}

/* 卡片模块 */
.card-module {
  background: var(--llj-white);
  border: 1px solid var(--llj-border-light);
  border-radius: 8px;
  padding: 24px;
  margin-bottom: 20px;
}

/* 新闻列表项 */
.news-item {
  display: flex;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid var(--llj-border-light);
}
.news-item:last-child {
  border-bottom: none;
}
.news-item .thumb {
  width: 180px;
  height: 120px;
  flex-shrink: 0;
  overflow: hidden;
  border-radius: 6px;
  background: #eee;
}
.news-item .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.news-item .info h4 {
  font-size: 16px;
  margin-bottom: 8px;
}
.news-item .info h4 a {
  color: var(--llj-text);
}
.news-item .info h4 a:hover {
  color: var(--llj-primary);
}
.news-item .info p {
  font-size: 14px;
  color: var(--llj-text-dark);
  line-height: 1.6;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.news-item .info .date {
  font-size: 12px;
  color: var(--llj-text-gray);
}

/* 通知列表 */
.notice-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.notice-list li {
  padding: 10px 0;
  border-bottom: 1px solid var(--llj-border-light);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.notice-list li:last-child {
  border-bottom: none;
}
.notice-list li a {
  color: var(--llj-text-dark);
  font-size: 14px;
  flex: 1;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.notice-list li a:hover {
  color: var(--llj-primary);
}
.notice-list li .date {
  font-size: 12px;
  color: var(--llj-text-gray);
  margin-left: 12px;
  flex-shrink: 0;
}

/* 图标网格 */
.icon-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}
.icon-item {
  text-align: center;
  padding: 24px 16px;
  background: var(--llj-primary-light);
  border-radius: 8px;
  transition: transform .2s, box-shadow .2s;
}
.icon-item:hover {
  transform: translateY(-4px);
  box-shadow: 0 8px 24px rgba(197,22,29,.15);
}
.icon-item .ic {
  width: 56px;
  height: 56px;
  background: var(--llj-primary);
  color: #fff;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 24px;
  font-weight: 700;
  margin: 0 auto 12px;
}
.icon-item h4 {
  font-size: 16px;
  color: var(--llj-text);
  margin-bottom: 4px;
}
.icon-item p {
  font-size: 12px;
  color: var(--llj-text-gray);
  margin: 0;
}

/* 双栏布局 */
.two-col {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
  margin-bottom: 20px;
}

/* 数据表格 */
.data-table {
  width: 100%;
  border-collapse: collapse;
}
.data-table th,
.data-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--llj-border-light);
  font-size: 14px;
}
.data-table th {
  background: var(--llj-primary);
  color: #fff;
  font-weight: 500;
}
.data-table tr:hover {
  background: var(--llj-primary-light);
}
.data-table td a {
  color: var(--llj-text);
  text-decoration: none;
}
.data-table td a:hover {
  color: var(--llj-primary);
}

/* 统计数据 */
.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  background: var(--llj-primary);
  padding: 32px;
  border-radius: 8px;
  margin-bottom: 20px;
}
.stat-item {
  text-align: center;
  color: #fff;
}
.stat-item .num {
  font-size: 36px;
  font-weight: 700;
}
.stat-item .label {
  font-size: 14px;
  margin-top: 8px;
  opacity: .9;
}

/* 文本列表 */
.text-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.text-list li {
  padding: 8px 0;
  border-bottom: 1px solid var(--llj-border-light);
}
.text-list li:last-child {
  border-bottom: none;
}
.text-list li a {
  color: var(--llj-text-dark);
  font-size: 14px;
}
.text-list li a:hover {
  color: var(--llj-primary);
}

/* 图片占位 */
.section-img {
  width: 100%;
  height: 200px;
  object-fit: cover;
  border-radius: 6px;
  background: #eee;
  margin-bottom: 16px;
}

/* 面包屑 */
.breadcrumb-bar {
  background: var(--llj-white);
  border-bottom: 1px solid var(--llj-border-light);
  padding: 12px 0;
  font-size: 13px;
}
.breadcrumb-bar a {
  color: var(--llj-text-gray);
}
.breadcrumb-bar a:hover {
  color: var(--llj-primary);
}

/* 页面标题 */
.page-header {
  background: var(--llj-primary);
  padding: 32px 0;
  color: #fff;
  margin-bottom: 24px;
}
.page-header h1 {
  font-size: 24px;
  font-weight: 700;
  margin: 0;
}
.page-header p {
  font-size: 14px;
  opacity: .8;
  margin-top: 8px;
}

/* 文章详情 */
.article-detail {
  background: var(--llj-white);
  border-radius: 8px;
  padding: 32px;
}
.article-detail h1 {
  font-size: 24px;
  font-weight: 700;
  color: var(--llj-text);
  margin-bottom: 16px;
}
.article-detail .meta {
  font-size: 13px;
  color: var(--llj-text-gray);
  margin-bottom: 24px;
  padding-bottom: 16px;
  border-bottom: 1px solid var(--llj-border-light);
}
.article-detail .content {
  line-height: 1.8;
  font-size: 15px;
}
.article-detail .content img {
  max-width: 100%;
  height: auto;
  border-radius: 4px;
  margin: 16px 0;
}

/* 栏目列表 */
.channel-list {
  display: grid;
  gap: 20px;
}
.channel-item {
  background: var(--llj-white);
  border: 1px solid var(--llj-border-light);
  border-radius: 8px;
  padding: 20px;
  display: flex;
  gap: 20px;
}
.channel-item .thumb {
  width: 200px;
  height: 140px;
  flex-shrink: 0;
  overflow: hidden;
  border-radius: 6px;
  background: #eee;
}
.channel-item .thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.channel-item .info h3 {
  font-size: 18px;
  margin-bottom: 8px;
}
.channel-item .info h3 a {
  color: var(--llj-text);
}
.channel-item .info h3 a:hover {
  color: var(--llj-primary);
}
.channel-item .info p {
  font-size: 14px;
  color: var(--llj-text-dark);
  line-height: 1.6;
  margin-bottom: 8px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.channel-item .info .date {
  font-size: 12px;
  color: var(--llj-text-gray);
}

/* 座底 */
.site-footer {
  background: #2d3748;
  color: rgba(255,255,255,.7);
  padding: 32px 0;
  margin-top: 40px;
}
.site-footer a {
  color: rgba(255,255,255,.7);
}
.site-footer a:hover {
  color: #fff;
}

/* 关于我们点位地图 */
.about-map-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.3fr) minmax(280px, .7fr);
  gap: 20px;
}
.about-map {
  min-height: 360px;
  border: 1px solid var(--llj-border-light);
  border-radius: 8px;
  overflow: hidden;
  background: #eef2f7;
}
.about-map-fallback {
  height: 100%;
  min-height: 360px;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
  color: var(--llj-text-gray);
  line-height: 1.8;
}
.about-location-list {
  display: grid;
  gap: 12px;
}
.about-location-card {
  border: 1px solid var(--llj-border-light);
  border-radius: 8px;
  padding: 16px;
  background: #fff;
}
.about-location-card h4 {
  margin: 0 0 8px;
  font-size: 16px;
  font-weight: 700;
  color: var(--llj-text);
}
.about-location-card p {
  margin: 0 0 8px;
  font-size: 13px;
  line-height: 1.7;
  color: var(--llj-text-dark);
}
.about-location-card .coords {
  color: var(--llj-text-gray);
  font-size: 12px;
}
.about-location-card .nav-link {
  display: inline-flex;
  margin-top: 6px;
  font-size: 13px;
  color: var(--llj-primary);
}

/* 分页 */
.pagination {
  margin-top: 24px;
}
.pagination .page-link {
  color: var(--llj-text-dark);
}
.pagination .page-item.active .page-link {
  background: var(--llj-primary);
  border-color: var(--llj-primary);
  color: #fff;
}
.pagination .page-link:hover {
  background: var(--llj-primary-light);
  color: var(--llj-primary);
}
.pagination .page-item.active .page-link:hover {
  background: var(--llj-primary-dark);
  border-color: var(--llj-primary-dark);
  color: #fff;
}

/* 按钮覆盖 */
.btn-primary {
  background: var(--llj-primary) !important;
  border-color: var(--llj-primary) !important;
  color: #fff !important;
}
.btn-primary:hover,
.btn-primary:focus,
.btn-primary:active {
  background: var(--llj-primary-dark) !important;
  border-color: var(--llj-primary-dark) !important;
  color: #fff !important;
}
.btn-outline-primary {
  color: var(--llj-primary) !important;
  border-color: var(--llj-primary) !important;
}
.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active {
  background: var(--llj-primary) !important;
  border-color: var(--llj-primary) !important;
  color: #fff !important;
}

/* 响应式 */
@media (max-width: 768px) {
  .hero-carousel-caption {
    padding: 12px 16px 36px;
  }
  .hero-carousel-caption h5 {
    font-size: 15px;
  }
  .icon-grid {
    grid-template-columns: repeat(2, 1fr);
  }
  .two-col {
    grid-template-columns: 1fr;
  }
  .stats-row {
    grid-template-columns: repeat(2, 1fr);
  }
  .news-item {
    flex-direction: column;
  }
  .news-item .thumb {
    width: 100%;
    height: 180px;
  }
  .channel-item {
    flex-direction: column;
  }
  .channel-item .thumb {
    width: 100%;
    height: 180px;
  }
  .about-map-layout {
    grid-template-columns: 1fr;
  }
  .about-map,
  .about-map-fallback {
    min-height: 280px;
  }
}
