.page-container {
  display: flex;
  align-items: flex-start;
  max-width: 1300px;
  margin: 40px auto;
  padding: 0 20px;
  gap: 20px;
  min-height: calc(100vh - 80px);
  font-family: var(--para-font);
}

.sidebar {
  flex: 0 0 260px;
  background: var(--white);
  border-radius: 12px;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.05);
  padding: 20px 18px;
  height: calc(100vh - 100px);
  overflow-y: auto;
  position: sticky;
  top: 20px;
  transition: transform 0.4s ease;
}

.sidebar::-webkit-scrollbar {
  width: 6px;
}

.sidebar::-webkit-scrollbar-thumb {
  background: #ffb703;
  border-radius: 10px;
}

.sidebar::-webkit-scrollbar-track {
  background: #f1f1f1;
}

.sidebar h3 {
  font-size: 18px;
  color: #00386e;
  font-weight: 600;
  border-bottom: 2px solid #ffb703;
  padding-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
}

.filter-group {
  background: #f9fafc;
  border: 1px solid #e6e6e6;
  border-radius: 10px;
  padding: 12px 14px;
  margin-bottom: 18px;
  transition: all 0.3s ease;
}

.filter-group:hover {
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.05);
  transform: translateY(-2px);
}

.filter-header {
  font-weight: 600;
  font-size: 14px;
  color: #00386e;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
}
.filter-header i{
  color: #ffa726;
  background-color: #00386e;
  padding: 10px;
  border-radius: 50%
}
.filter-body select {
  width: 100%;
  padding: 10px 12px;
  border-radius: 6px;
  border: 1px solid #ccc;
  background: #fff;
  font-size: 14px;
  color: #333;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
  appearance: none;
  background-image: url("data:image/svg+xml;utf8,<svg fill='gray' height='14' viewBox='0 0 20 20' width='14' xmlns='http://www.w3.org/2000/svg'><path d='M5.516 7.548L10 12.032l4.484-4.484L16 8.548l-6 6-6-6z'/></svg>");
  background-repeat: no-repeat;
  background-position: right 10px center;
  background-size: 14px;
}

.filter-body select:hover {
  border-color: #ffb703;
  box-shadow: 0 0 0 2px rgba(255, 184, 28, 0.2);
}

.filter-body select:focus {
  outline: none;
  border-color: #ffb703;
  box-shadow: 0 0 0 2px rgba(255, 184, 28, 0.3);
}

.filter-body select option {
  padding: 8px;
}

.filter-body select option:hover {
  background: #ffb703 !important;
  color: #fff;
}

@media (max-width: 992px) {
  .sidebar {
    position: fixed;
    left: 0;
    top: 0;
    height: 100vh;
    transform: translateX(-100%);
    z-index: 9999;
  }

  .sidebar.active {
    transform: translateX(0);
  }
}

.main-content {
  flex: 1;
  background: var(--white);
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  padding: 20px;
}

.top-bar {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 15px;
  gap: 10px;
}

.top-bar .left-info p {
  font-size: 14px;
  color: #555;
}

.top-bar .right-actions {
  display: flex;
  align-items: center;
  gap: 10px;
}

.top-bar select {
  padding: 8px 12px;
  border: 1px solid #e5e5e5;
  border-radius: 5px;
  font-size: 14px;
}

.view-toggle button {
  background: #f4f4f4;
  border: none;
  padding: 8px 14px;
  border-radius: 5px;
  cursor: pointer;
  transition: 0.3s;
}

.view-toggle button.active {
  background: #ffb703;
  color: #fff;
}

.learning-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
  transition: all 0.3s ease-in-out;
}

.product-card {
  background: var(--white);
  border-radius: 10px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.1);
  overflow: hidden;
  transition: transform 0.3s;
  display: flex;
  flex-direction: column;
  position: relative;
}

.product-card:hover {
  transform: translateY(-5px);
}

.product-img {
  position: relative;
  text-align: center;
  background: #f9f9f9;
}

.product-img img {
  width: 100%;
  max-height: 230px;
  object-fit: contain;
  margin-bottom: 5px;
}

.badge.sale {
  position: absolute;
  top: 10px;
  left: 10px;
  background: #ff3e00;
  color: #fff;
  font-size: 12px;
  padding: 4px 8px;
  border-radius: 4px;
}

.product-card {
  padding: 15px;
  text-align: center;
}

.product-card h3 {
  font-size: 16px;
  color: #333;
  margin-bottom: 10px;
}

.rating i {
  color: #ffb703;
}

.price {
  font-weight: bold;
  color: #000;
}

.price .old {
  text-decoration: line-through;
  color: #999;
  margin-right: 5px;
}

.desc {
  display: none;
  font-size: 14px;
  color: #666;
  margin-top: 10px;
}

.buttons {
  margin-top: 10px;
}

.buttons1 .cart1 {
  background-color: #fff;
  color: var(--main-color);
  border: 1px solid var(--para-color);
  border-radius: 5px;
  font-size: 13px;
  font-family: var(--para-font);
}
.buttons1 .buy1 {
  background: #ffa726;
  color: #fff;
  border-radius: 5px;
  font-size: 13px;
  font-family: var(--para-font);
}

.buttons1 button:hover {
  opacity: 0.9;
}

.learning-grid.list-view {
  display: flex;
  flex-direction: column;
}

.learning-grid.list-view .product-card {
  flex-direction: row;
  align-items: center;
}

.learning-grid.list-view .product-img {
  flex: 0 0 200px;
  padding: 10px;
}

.learning-grid.list-view .product-card {
  flex: 1;
  text-align: left;
  padding: 15px 25px;
}

.learning-grid.list-view .desc {
  display: block;
}

.filter-toggle {
  display: none;
}

.sidebar-overlay {
  display: none;
}

/* PAGINATION */
.pagination {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  margin: 40px 0 20px;
  flex-wrap: wrap;
}

.page-btn {
  width: 40px;
  height: 40px;
  border-radius: 8px;
  border: 1px solid #00386e;
  background: #fff;
  color: #555;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.3s ease;
  cursor: pointer;
  display: flex;
  justify-content: center;
  align-items: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.05);
}

.page-btn:hover {
  background: #00386e !important;
  color: #fff;
  border-color: #00386e !important;
}

.page-btn.active {
  background: #00386e !important;
  color: #fff;
  border-color:#00386e !important;
}

.page-btn.prev, .page-btn.next {
  width: 30px;
  height: 30px;
}

.page-btn i {
  font-size: 12px;
}

.sidebar-close {
  display: none;
  background: none;
  border: none;
  font-size: 20px;
  color: #555;
  cursor: pointer;
  transition: color 0.3s ease;
}

.sidebar-close:hover {
  color: var(--primary);
  transform: rotate(90deg);
}

@media (max-width: 992px) {
  .sidebar-close {
    display: block;
    position: absolute;
    right: 0;
    top: 0;
    transform: translateY(0);
    padding: 8px;
    font-size: 22px;
  }
  .filter-group{
    width: 70%;
  }
}

@media (max-width: 576px) {
  .pagination {
    gap: 6px;
  }
  .page-btn {
    width: 36px;
    height: 36px;
    font-size: 13px;
  }
}

@media (max-width: 992px) {
  .page-container {
    flex-direction: column;
  }

  .sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 999;
    background: #fff;
    transform: translateX(-100%);
    box-shadow: 2px 0 10px rgba(0, 0, 0, 0.15);
  }

  .sidebar.active {
    transform: translateX(0);
  }

  .sidebar-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: 998;
    display: none;
  }

  .sidebar-overlay.active {
    display: block;
  }

  .filter-toggle {
    display: inline-block;
    background: #219ebc;
    color: #fff;
    padding: 10px 15px;
    border-radius: 6px;
    cursor: pointer;
    margin-bottom: 15px;
  }

  .learning-grid.list-view .product-card {
    flex-direction: column;
    text-align: center;
  }

  .learning-grid.list-view .product-card {
    text-align: center;
  }
}
