/* CP Page Styles */

.page-banner {
  width: 100%;
  height:550px;
  background: linear-gradient(rgba(0, 0, 0, 0.4), rgba(0, 0, 0, 0.4)),
              url('../images/topBanner.jpg') center center / cover no-repeat;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  color: #fff;
}

.banner-content h1 {
  font-size: 42px;
  margin: 0 0 10px;
  font-weight: 700;
}

.banner-content p {
  font-size: 16px;
  opacity: 0.9;
  letter-spacing: 2px;
}

.product-container {
  width: min(1200px, calc(100% - 40px));
  margin: 0 auto;
  padding: 40px 0;
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 30px;
}

.category-sidebar {
  background: #fff;
  border-radius: 8px;
  box-shadow: 0 5px 20px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  height: fit-content;
}

.sidebar-title {
  background: #6cc4b9;
  color: #fff;
  padding: 20px;
  font-size: 20px;
  font-weight: 700;
  text-align: center;
}

.category-list {
  list-style: none;
  padding: 0;
  margin: 0;
}

.category-list li {
  border-bottom: 1px solid #eee;
}

.category-list li:last-child {
  border-bottom: none;
}

.category-list a {
  display: block;
  padding: 15px 20px;
  color: #666;
  text-decoration: none;
  font-size: 15px;
  transition: all 0.3s ease;
  position: relative;
}

.category-list a span {
  float: right;
  color: #ccc;
}

.category-list a:hover,
.category-list a.active {
  background: #f5f5f5;
  color: var(--green);
}

.product-list {
  background: #fff;
}

.product-header {
  background: #6cc4b9;
  color: #fff;
  padding: 15px 20px;
  margin-bottom: 20px;
}

.product-header h2 {
  font-size: 20px;
  margin: 0;
  font-weight: 700;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
  margin-bottom: 40px;
}

.product-item {
  background: #fff;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  padding: 20px;
  text-align: center;
  transition: all 0.3s ease;
}

.product-item:hover {
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.12);
  transform: translateY(-5px);
}

.product-image {
  width: 100%;
  height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
  background: #f9f9f9;
  border-radius: 4px;
  overflow: hidden;
}

.product-image img {
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
}

.product-item h3 {
  font-size: 18px;
  color: #333;
  margin: 0 0 20px;
  font-weight: 600;
}

.btn-more {
  display: inline-block;
  padding: 10px 40px;
  border: 1px solid #ddd;
  border-radius: 25px;
  color: #666;
  text-decoration: none;
  font-size: 14px;
  transition: all 0.3s ease;
}

.btn-more:hover {
  background: var(--green);
  color: #fff;
  border-color: var(--green);
}

.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.pagination a,
.pagination span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 12px;
  border: 1px solid #ddd;
  background: #fff;
  color: #666;
  text-decoration: none;
  font-size: 14px;
  border-radius: 4px;
  transition: all 0.3s ease;
}

.pagination a:hover {
  background: var(--green);
  color: #fff;
  border-color: var(--green);
}

.pagination .current {
  background: #333;
  color: #fff;
  border-color: #333;
}

.pagination .page-info {
  margin-left: 15px;
  font-size: 14px;
  color: #666;
}

.pagination input[type="number"] {
  width: 50px;
  height: 28px;
  margin: 0 5px;
  padding: 0 5px;
  border: 1px solid #ddd;
  border-radius: 4px;
  text-align: center;
  font-size: 14px;
}

@media (max-width: 1024px) {
  .product-container {
    grid-template-columns: 250px 1fr;
    gap: 20px;
  }

  .product-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 760px) {
  .page-main {
    margin-top: 60px;
  }

  .page-banner {
    height: 200px;
  }

  .banner-content h1 {
    font-size: 28px;
  }

  .banner-content p {
    font-size: 14px;
  }

  .product-container {
    grid-template-columns: 1fr;
    padding: 20px 0;
  }

  .category-sidebar {
    margin-bottom: 20px;
  }

  .sidebar-title {
    padding: 15px;
    font-size: 18px;
  }

  .category-list a {
    padding: 12px 15px;
    font-size: 14px;
  }

  .product-grid {
    grid-template-columns: 1fr;
    gap: 20px;
  }

  .product-item {
    padding: 15px;
  }

  .product-image {
    height: 180px;
  }

  .product-item h3 {
    font-size: 16px;
  }

  .btn-more {
    padding: 8px 30px;
  }
}

@media (max-width: 420px) {
  .page-banner {
    height: 160px;
  }

  .banner-content h1 {
    font-size: 24px;
  }

  .pagination {
    flex-wrap: wrap;
    gap: 5px;
  }

  .pagination .page-info {
    margin-left: 0;
    margin-top: 10px;
    width: 100%;
    text-align: center;
  }
}
