/* ============================================================
   CASES PAGE — cases.css
   ============================================================ */

/* CTA 内页渐变 */
.cta-overlay-inner {
  background: linear-gradient(90.175deg, rgba(101, 185, 103, 0.19) 1%, rgb(40, 103, 178) 99%) !important;
}

/* ============================================================
   CASES PAGE SECTION
   ============================================================ */
.cases-page {
  padding: 60px 0 80px;
  background: #fff;
}

.cases-page-head {
  text-align: center;
  margin-bottom: 36px;
}

.cases-page-title {
  font-size: 36px;
  font-weight: 700;
  color: #0075c2;
  line-height: 1.2;
  margin-bottom: 10px;
}

.cases-page-en {
  font-size: 30px;
  font-weight: 700;
  color: #d8e3ef;
}

/* ---- Filter Tabs ---- */
.cp-filter {
  display: flex;
  justify-content: center;
  gap: 16px;
  margin-bottom: 48px;
  flex-wrap: wrap;
}

.cp-filter-btn {
  height: 58px;
  padding: 0 40px;
  border-radius: 90px;
  font-size: 16px;
  cursor: pointer;
  border: none;
  background: #f0f0f0;
  color: #333;
  transition: background .25s, color .25s;
  font-family: inherit;
  white-space: nowrap;
}

.cp-filter-btn.active {
  background: #0975b9;
  color: #fff;
}

.cp-filter-btn:hover:not(.active) {
  background: #e0e8f0;
}

/* ---- Card Grid ---- */
.cp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 32px 28px;
  margin-bottom: 48px;
}

.cp-card {
  border-radius: 10px;
  overflow: hidden;
  background: #f8f8f8;
  border: 1px solid #d3e4f2;
  transition: box-shadow .3s, transform .3s;
  cursor: default;
}

.cp-card:hover {
  box-shadow: 0 8px 32px rgba(0, 117, 194, .15);
  transform: translateY(-4px);
}

.cp-card-img {
  height: 240px;
  overflow: hidden;
  border-bottom: 1px solid #d3e4f2;
}

.cp-card-img img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform .5s;
  display: block;
}

.cp-card:hover .cp-card-img img {
  transform: scale(1.06);
}

.cp-card-body {
  padding: 20px 24px;
}

.cp-card-body h3 {
  font-size: 18px;
  font-weight: 700;
  color: #333;
  line-height: 1.4;
}

/* Featured card — blue gradient */
.cp-card:hover  {
  background: linear-gradient(to bottom, #1692d6, #066eb2);
  border-color: transparent;
}

.cp-card:hover  .cp-card-img {
  border-bottom-color: rgba(255, 255, 255, .2);
}

.cp-card:hover  .cp-card-body h3 {
  color: #fff;
}

/* ---- Pagination ---- */
.cp-pagination {
  display: flex;
  justify-content: center;
  margin-top: 12px;
}

.cp-pagination img {
  max-width: 340px;
  height: auto;
}

.cp-grid > .cp-card {
  display: block;
}

a.cp-filter-btn {
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.cp-pagination-nav {
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 12px;
}

.cp-page-link,
.cp-page-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  padding: 6px 12px;
  font-size: 14px;
  color: #056db1;
  text-decoration: none;
  border: 1px solid #d3e4f2;
  border-radius: 4px;
  background: #fff;
  transition: background .2s, color .2s, border-color .2s;
}

.cp-page-link:hover,
.cp-page-num:hover {
  background: #f0f7fc;
  border-color: #056db1;
}

.cp-page-num--current {
  color: #fff;
  background: #0975b9;
  border-color: #0975b9;
  cursor: default;
  font-weight: 600;
}

.cp-page-prev,
.cp-page-next {
  min-width: auto;
  padding: 6px 16px;
}

/* ============================================================
   RESPONSIVE — Tablet
   ============================================================ */
@media (max-width: 1023px) {
  .cp-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }

  .cp-card-featured {
    grid-column: auto;
  }
}

/* ============================================================
   RESPONSIVE — Mobile  (< 768px)
   ============================================================ */
@media (max-width: 767px) {
  .cases-page {
    padding: 36px 0 52px;
  }

  .cases-page-title {
    font-size: 26px;
  }

  .cases-page-en {
    font-size: 18px;
  }

  .cp-filter {
    gap: 10px;
    margin-bottom: 28px;
  }

  .cp-filter-btn {
    height: 44px;
    padding: 0 20px;
    font-size: 14px;
  }

  .cp-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin-bottom: 32px;
  }

  .cp-card-img {
    height: 160px;
  }

  .cp-card-body {
    padding: 12px 14px;
  }

  .cp-card-body h3 {
    font-size: 13px;
    line-height: 1.5;
  }

  .cp-pagination img {
    max-width: 260px;
  }
}

/* ============================================================
   RESPONSIVE — Very small  (< 480px)
   ============================================================ */
@media (max-width: 479px) {
  .cp-grid {
    grid-template-columns: 1fr;
  }

  .cp-card-img {
    height: 200px;
  }

  .cp-filter {
    justify-content: flex-start;
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
  }

  .cp-filter::-webkit-scrollbar {
    display: none;
  }

  .cp-filter-btn {
    flex-shrink: 0;
  }
}
