/* ============================================================
 * 南京市雨花台区人民政府 · 一级栏目概览（单栏列表）
 * 内容区最大宽度 1300px；稿件列表铺满容器，响应式自适应
 * 手写原生 CSS，无任何框架
 * 配色：
 *   主蓝 #2a5caa  深蓝 #1d3f77  高亮蓝 #3b82d6
 *   侧栏选中底 #e9f1fb  列表钻石 #6fb4ea
 *   正文 #333 / 次要 #666 / 日期 #999 / 分割线 #e5e5e5
 * ============================================================ */

:root {
  --primary: rgba(50, 93, 146, 1);
  --deep: #1d3f77;
  --accent: #3b82d6;
  --bullet: #6fb4ea;
  --text: #333333;
  --sub: #666666;
  --date: #999999;
  --line: #e5e5e5;
  --container: 1300px;
}

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

html {
  -webkit-text-size-adjust: 100%;
}

/* 防横向溢出保险（真正的溢出源在页头，下面已修） */
html,
body {
  overflow-x: hidden;
}

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

a {
  color: inherit;
  text-decoration: none;
}

ul,
ol {
  list-style: none;
}

img {
  border: 0;
  display: block;
}

button,
input {
  font-family: inherit;
}

.container {
  max-width: var(--container);
  margin: 0 auto;
  /* padding: 0 20px; */
}

/* ===== 图片占位盒：后期补图时直接给内部 img 填 src 即可 ===== */
.img-slot {}

.img-slot>img {
  width: 100%;
  height: 100%;
}

.img-slot.skin-transparent {
  background: transparent;
  border: 0;
  border-radius: 0;
}

/* ===== 面包屑 ===== */
.crumb {
  padding: 14px 0;
  font-size: 16px;
  color: #8a8f99;
  display: flex;
  align-items: center;
}

.crumb a {
  color: var(--primary);
  margin: 0 8px;
}

.crumb a:hover {
  text-decoration: underline;
}

.crumb .sep {
  margin: 0 8px;
  color: #b8bdc6;
}

.crumb svg {
  vertical-align: -2px;
  margin-right: 4px;
}

/* ===== 主体单栏 ===== */
.page-main {
  padding-bottom: 40px;
}

.layout {
  display: flex;
  align-items: flex-start;
}

/* 稿件列表：铺满容器 */
.main-col {
  flex: 1 1 auto;
  max-width: none;
  min-width: 0;
}

.news-item {
  display: flex;
  align-items: center;
  gap: 14px;
  min-height: 52px;
  padding: 12px 8px;
  border-radius: 2px;
  cursor: pointer;
  transition: background .2s ease;
}

.news-item:hover {
  background: #f6f9fd;
}

.news-item:hover .news-title {
  color: var(--primary);
}

.diamond {
  flex: none;
  width: 7px;
  height: 7px;
  background: var(--bullet);
  border-radius: 1.5px;
  transform: rotate(45deg);
}

.news-title {
  flex: 1;
  min-width: 0;
  font-size: 18px;
  color: #333;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  transition: color .2s ease;
}

.news-date {
  flex: none;
  font-size: 18px;
  color: var(--date);
  font-variant-numeric: tabular-nums;
}

.news-divider {
  height: 1px;
  background: var(--line);
  margin: 8px 0;
}

.empty-tip {
  padding: 60px 0;
  text-align: center;
  color: #999;
  font-size: 14px;
}

/* ===== 分页 ===== */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin-top: 24px;
  flex-wrap: wrap;
}

/* 置标 trs_pagenav 输出：当前页为 .pagenav_span，其余为 .pagenav_a */
.pagination .pagenav_span,
.pagination .pagenav_a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 28px;
  padding: 0 10px;
  border: 1px solid #dcdfe5;
  background: #f5f6f8;
  color: #555;
  font-size: 13px;
  line-height: 1;
  border-radius: 3px;
  text-decoration: none;
  cursor: pointer;
  transition: border-color .2s ease, color .2s ease, background .2s ease;
}

.pagination .pagenav_a:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.pagination .pagenav_span {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  cursor: default;
}

.pg-jump {
  height: 28px;
  width: 44px;
  border: 1px solid #dcdfe5;
  border-radius: 3px;
  text-align: center;
  font-size: 13px;
  outline: 0;
  color: #333;
}

.pg-jump:focus {
  border-color: var(--accent);
}

/* ===== 响应式：窄屏堆叠，不写死宽度 ===== */
/* 与首页保持一致：1360 以下留 16px 边距，640 以下收紧到 12px */
@media (max-width:1360px) {
  .container {
    padding-left: 16px;
    padding-right: 16px;
  }
}

@media (max-width:980px) {

  .layout {
    align-items: stretch;
  }

  .main-col {
    flex: 0 0 auto;
    max-width: none;
    width: 100%;
  }
}

@media (max-width:640px) {

  /* 手机边距与首页保持一致 */
  .container {
    padding-left: 12px;
    padding-right: 12px;
  }

  .crumb {
    padding: 10px 0;
    font-size: 13px;
    flex-wrap: wrap;
    row-gap: 4px;
  }

  .crumb a,
  .crumb .sep {
    margin: 0 4px;
  }

  .news-item {
    gap: 8px;
    min-height: 0;
    padding: 10px 0;
    align-items: flex-start;
  }

  .diamond {
    width: 6px;
    height: 6px;
    margin-top: 7px;
  }

  /* 手机标题最多两行，比单行省略能看到更多内容 */
  .news-title {
    font-size: 15px;
    line-height: 1.5;
    white-space: normal;
    display: -webkit-box;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
    overflow: hidden;
  }

  .news-date {
    font-size: 12px;
    line-height: 1.5;
    margin-top: 2px;
  }

  .news-divider {
    margin: 4px 0;
  }

  .empty-tip {
    padding: 40px 0;
  }

  .pagination {
    gap: 6px;
    margin-top: 18px;
  }

  .pagination .pagenav_span,
  .pagination .pagenav_a {
    min-width: 32px;
    height: 30px;
    padding: 0 8px;
  }

  .pg-jump {
    height: 30px;
    width: 40px;
  }
}
