/* ==========================================================================
   Catalogue page (product list, category, search results)
   Only the parts home.css does not already provide: breadcrumb, filter
   sidebar, results header, sorting, pagination and the empty state.
   Card/grid styling is reused from home.css (.products-grid/.product-card).
   ========================================================================== */

.catalog-page {
  max-width: 1280px;
  margin: 0 auto;
  padding: 24px 5% 60px;
}

/* --- breadcrumb ----------------------------------------------------------- */

.catalog-page .breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 18px;
  font-size: 13px;
  color: #8a8a8a;
}

.catalog-page .breadcrumb a {
  color: #6d6870;
  text-decoration: none;
}

.catalog-page .breadcrumb a:hover {
  color: #2d9092;
}

.catalog-page .breadcrumb .current {
  color: #222;
  font-weight: 600;
}

/* --- layout --------------------------------------------------------------- */

.catalog-layout {
  display: grid;
  grid-template-columns: 260px 1fr;
  gap: 28px;
  align-items: start;
}

.filter-card {
  padding: 18px;
  margin-bottom: 18px;
  border: 1px solid #f0e6ec;
  border-radius: 14px;
  background: #fff;
}

.filter-title {
  margin-bottom: 14px;
  font-size: 15px;
  font-weight: 700;
  color: #222;
}

.filter-search input[type="search"] {
  width: 100%;
  height: 40px;
  padding: 0 12px;
  border: 1px solid #e6e6e6;
  border-radius: 9px;
  font-family: inherit;
  font-size: 13px;
  outline: none;
}

.filter-search input[type="search"]:focus {
  border-color: #2d9092;
}

.filter-search button {
  width: 100%;
  height: 40px;
  margin-top: 10px;
  border: none;
  border-radius: 9px;
  background: #2d9092;
  color: #fff;
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
}

.filter-search button:hover {
  background: #26807f;
}

.category-filter {
  list-style: none;
  margin: 0;
  padding: 0;
}

.category-filter a {
  display: block;
  padding: 9px 12px;
  border-radius: 8px;
  color: #5c5c5c;
  font-size: 14px;
  text-decoration: none;
  transition: background 0.2s ease, color 0.2s ease;
}

.category-filter a:hover {
  background: #f7f2f5;
  color: #2d9092;
}

.category-filter a.active {
  background: #eef8f8;
  color: #2d9092;
  font-weight: 700;
}

/* --- results header ------------------------------------------------------- */

.catalog-header {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.catalog-title {
  font-size: 20px;
  font-weight: 800;
  color: #222;
}

.catalog-count {
  margin-top: 4px;
  font-size: 13px;
  color: #8a8a8a;
}

.sort-form select {
  height: 40px;
  padding: 0 12px;
  border: 1px solid #e6e6e6;
  border-radius: 9px;
  background: #fff;
  font-family: inherit;
  font-size: 13px;
  color: #444;
  cursor: pointer;
}

/* --- pagination ----------------------------------------------------------- */

.catalog-page .pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 14px;
  margin-top: 34px;
}

.catalog-page .pagination a,
.catalog-page .pagination span {
  padding: 9px 16px;
  border: 1px solid #eee;
  border-radius: 9px;
  font-size: 13px;
  text-decoration: none;
  color: #444;
  background: #fff;
}

.catalog-page .pagination a:hover {
  border-color: #2d9092;
  color: #2d9092;
}

.catalog-page .pagination .page-info {
  border: none;
  background: transparent;
  color: #8a8a8a;
}

/* --- empty state ---------------------------------------------------------- */

.catalog-empty {
  padding: 60px 20px;
  border: 1px dashed #e6dbe2;
  border-radius: 14px;
  background: #fdfafc;
  text-align: center;
}

.catalog-empty p {
  margin-bottom: 18px;
  color: #777;
  font-size: 15px;
}

.catalog-empty a {
  display: inline-block;
  padding: 11px 26px;
  border-radius: 9px;
  background: #e874a5;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  text-decoration: none;
}

.catalog-empty a:hover {
  background: #d95e91;
}

/* --- responsive ----------------------------------------------------------- */

@media (max-width: 900px) {
  .catalog-layout {
    grid-template-columns: 1fr;
  }

  .catalog-sidebar {
    order: 2;
  }

  .catalog-main {
    order: 1;
  }
}

@media (max-width: 480px) {
  .catalog-page {
    padding: 16px 4% 40px;
  }

  .catalog-title {
    font-size: 17px;
  }
}
