.EP-container {
  display: grid;
  grid-template-columns: rEPeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
  padding: 20px 0;
  width: 100%;
  max-width: 100%;
  box-sizing: border-box;

  /* 新增：最多显示 4 列 */
  grid-template-columns: rEPeat(auto-fit, minmax(160px, 1fr));
  max-width: calc(160px * 4 + 20px * 3); /* 4列 + 3个间距 */
  margin: 0 auto;
}

.EP-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  background: white;
  border-radius: 10px;
  padding: 8px; /* 缩小整体内边距 */
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  cursor: pointer;
  box-shadow: 0 0 0 rgba(0, 0, 0, 0); /* hover前无阴影 */
}


.EP-card img {
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 6px;
  margin-bottom: 12px;
}


.acolor img {
  border-bottom: none;
}

.EP-card a {
  outline: none;
}

.EP-card a:focus {
  outline: none;
  box-shadow: none;
}

.EP-card p {
  margin: 2px 0; /* 上下间距更小 */
  font-size: 0.95rem;
  color: #333;
  line-height: 1.2;
}


.pagination {
  display: flex;
  justify-content: center;
  padding: 20px;
  min-height: 60px; /* 保持高度不跳动 */
}


.pagination button {
  padding: 8px 16px;
  font-size: 1rem;
  border: none;
  background-color: #eee;
  cursor: pointer;
  transition: background-color 0.3s ease;
}



.pagination button:disabled {
  background-color: #ddd;
  cursor: not-allowed;
}
.pagination button.active {
  font-weight: bold;
  background-color: #333;
}

.page-btn, .dots {
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  font-size: 14px;
  border: none;
  background-color: #ccc;
  color: black;
  border-radius: 0;
  text-align: center;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
  flex-shrink: 0;
  margin: 0;
}

.page-btn.active {
  background-color: #333;
  color: white;
}

/* 圆角按钮样式 */
.round-left {
  border-top-left-radius: 6px;
  border-bottom-left-radius: 6px;
}

.round-right {
  border-top-right-radius: 6px;
  border-bottom-right-radius: 6px;
}

/* 可选：容器样式，防止换行 */

#pageNumbers {
  display: flex;
  justify-content: center;
  gap: 0;
  flex-wrap: nowrap;
  min-width: 400px;  /* 固定容器宽度，视情况调整 */
  max-width: 100%;
}


