.category-results-hero {
  position: relative;
  overflow: hidden;
  margin-bottom: 40px;
  padding: 32px;
  border: 1px solid #e4e4e7;
  border-radius: 32px;
  background: #fff;
  box-shadow: 0 8px 30px rgba(0, 0, 0, 0.04);
}

.category-results-hero::after {
  position: absolute;
  content: "";
  pointer-events: none;
}

.category-results-hero::after {
  inset-block-end: -96px;
  inset-inline-start: -96px;
  width: 256px;
  height: 256px;
  border-radius: 50%;
  background: #d1fae5;
  filter: blur(80px);
  opacity: 0.4;
}

.category-results-hero-main,
.category-subcategories {
  position: relative;
  z-index: 1;
}

.category-results-hero-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 32px;
}

.category-results-breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
  color: #71717a;
  font-size: 13px;
  font-weight: 600;
}

.category-results-breadcrumb a:hover {
  color: #047857;
}

.category-results-breadcrumb b {
  color: #18181b;
}

.category-results-hero h1 {
  margin: 0;
  color: #09090b;
  font-size: 40px;
  font-weight: 900;
  letter-spacing: -0.035em;
  line-height: 1.2;
}

.category-directory-hero p {
  max-width: 650px;
  margin: 13px 0 0;
  color: #71717a;
  font-size: 16px;
  font-weight: 600;
  line-height: 1.85;
}

.category-directory-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.category-directory-card {
  min-height: 250px;
  border: 1px solid #e4e4e7;
  border-radius: 22px;
  background: #fff;
  padding: 22px;
  transition: border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}

.category-directory-card:hover {
  border-color: #a7f3d0;
  box-shadow: 0 16px 30px -22px rgba(24, 24, 27, .35);
  transform: translateY(-3px);
}

.category-directory-heading {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid #f4f4f5;
  padding-bottom: 14px;
  color: #18181b;
  font-size: 17px;
  font-weight: 900;
  line-height: 1.5;
}

.category-directory-heading i {
  flex: 0 0 auto;
  color: #059669;
  font-size: 19px;
  transition: transform .2s ease;
}

.category-directory-heading:hover i { transform: translateX(-4px); }

.category-directory-card ul {
  display: grid;
  gap: 10px;
  margin: 16px 0 0;
  padding: 0;
  list-style: none;
}

.category-directory-card li a {
  display: block;
  overflow: hidden;
  color: #71717a;
  font-size: 13px;
  font-weight: 600;
  text-overflow: ellipsis;
  transition: color .2s ease;
  white-space: nowrap;
}

.category-directory-card li a:hover { color: #047857; }

.category-directory-more {
  display: inline-flex;
  margin-top: 16px;
  color: #047857;
  font-size: 12px;
  font-weight: 800;
}

.category-directory-standalone {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
  margin-top: 26px;
}

.category-directory-standalone-button {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  border: 1px solid #a7f3d0;
  border-radius: 12px;
  background: #fff;
  padding: 11px 14px;
  color: #065f46;
  font-size: 14px;
  font-weight: 800;
  transition: background .2s ease, border-color .2s ease, color .2s ease, transform .2s ease;
}

.category-directory-standalone-button i { font-size: 17px; }

.category-directory-standalone-button:hover {
  border-color: #047857;
  background: #ecfdf5;
  color: #047857;
  transform: translateY(-2px);
}

.category-results-count {
  display: flex;
  min-width: 160px;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  border: 1px solid #f4f4f5;
  border-radius: 16px;
  background: #fafafa;
  padding: 24px;
}

.category-results-count strong {
  color: #18181b;
  direction: ltr;
  font-family: Outfit, sans-serif;
  font-size: 36px;
  font-weight: 900;
}

.category-results-count span {
  margin-top: 4px;
  color: #71717a;
  font-size: 12px;
  font-weight: 700;
}

.category-count-skeleton {
  display: block;
  width: 70px;
  height: 36px;
  border-radius: 9px;
  background: linear-gradient(90deg, #e4e4e7 25%, #f4f4f5 37%, #e4e4e7 63%);
  background-size: 400% 100%;
  animation: price-skeleton-loading 1.4s ease infinite;
}

.category-products-loading {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 25px;
}

.category-product-skeleton {
  display: flex;
  min-height: 418px;
  flex-direction: column;
  gap: 14px;
  overflow: hidden;
  border: 1px solid #e4e4e7;
  border-radius: 30px;
  background: #fff;
  padding: 0 23px 23px;
}

.category-product-skeleton i,
.category-product-skeleton b,
.category-product-skeleton em {
  display: block;
  border-radius: 8px;
  background: linear-gradient(90deg, #e4e4e7 25%, #f4f4f5 37%, #e4e4e7 63%);
  background-size: 400% 100%;
  animation: price-skeleton-loading 1.4s ease infinite;
}

.category-product-skeleton i {
  width: calc(100% + 46px);
  height: 220px;
  margin-inline: -23px;
  border-radius: 0;
}

.category-product-skeleton b:first-of-type { width: 44%; height: 13px; margin-top: 8px; }
.category-product-skeleton b:last-of-type { width: 88%; height: 36px; }
.category-product-skeleton em { width: 54%; height: 24px; margin-top: auto; }

.category-results-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 34px;
}

.category-results-pagination button,
.category-results-pagination a {
  display: inline-flex;
  min-width: 38px;
  height: 38px;
  align-items: center;
  justify-content: center;
  gap: 6px;
  border: 1px solid #d4d4d8;
  border-radius: 10px;
  background: #fff;
  color: #3f3f46;
  font: 800 13px Cairo, sans-serif;
  text-decoration: none;
  cursor: pointer;
  transition: .2s;
}

.category-results-pagination button:hover:not(:disabled),
.category-results-pagination a:hover {
  border-color: #047857;
  color: #047857;
}

.category-results-pagination button.is-current {
  border-color: #18181b;
  background: #18181b;
  color: #fff;
}

.category-results-pagination button:disabled { cursor: default; opacity: .55; }

.category-results-pagination > span {
  margin-inline-start: 8px;
  color: #71717a;
  font: 800 12px Cairo, sans-serif;
}

.category-results-layout {
  display: grid;
  grid-template-columns: 230px minmax(0, 1fr);
  align-items: start;
  gap: 24px;
}

.category-subcategories {
  overflow: hidden;
  border: 1px solid #e4e4e7;
  border-radius: 20px;
  background: #fff;
  box-shadow: 0 8px 22px rgba(24, 24, 27, .04);
}

.category-subcategories-heading {
  display: flex;
  align-items: center;
  gap: 9px;
  border-bottom: 1px solid #f4f4f5;
  padding: 17px;
  color: #18181b;
  font-size: 14px;
  font-weight: 900;
}

.category-subcategories-heading i { color: #047857; font-size: 20px; }

.category-subcategories nav {
  display: grid;
  gap: 3px;
  padding: 9px;
}

.category-subcategories b,
.category-subcategories a {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0;
  border-radius: 11px;
  padding: 10px 11px;
  color: #52525b;
  font-size: 13px;
  font-weight: 800;
  transition: background .2s ease, color .2s ease;
}

.category-subcategories b {
  background: #18181b;
  color: #fff;
}

.category-subcategories a span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.category-subcategories a i { flex: 0 0 auto; color: #a1a1aa; font-size: 13px; }
.category-subcategories a:hover { background: #ecfdf5; color: #047857; }
.category-subcategories a:hover i { color: #047857; }

@media (max-width: 950px) {
  .category-results-layout { grid-template-columns: 1fr; gap: 18px; }
  .category-subcategories nav { padding: 9px; }
}

@media (max-width: 700px) {
  .category-results-hero {
    margin-bottom: 25px;
    padding: 22px;
    border-radius: 23px;
  }

  .category-results-hero-main {
    align-items: flex-start;
  }

  .category-results-hero h1 {
    font-size: 27px;
  }

  .category-directory-hero p { font-size: 13px; }
  .category-directory-grid { grid-template-columns: 1fr; gap: 11px; }
  .category-directory-card { min-height: 220px; border-radius: 18px; padding: 15px; }
  .category-directory-heading { gap: 8px; padding-bottom: 11px; font-size: 13px; }
  .category-directory-card li a { font-size: 13px; }
  .category-directory-standalone { justify-content: stretch; margin-top: 18px; }
  .category-directory-standalone-button { flex: 1 1 100%; justify-content: space-between; font-size: 13px; }

  .category-results-count {
    min-width: 90px;
    padding: 12px 8px;
  }

  .category-results-count strong {
    font-size: 22px;
  }

  .category-count-skeleton { width: 45px; height: 24px; }

  .category-products-loading { grid-template-columns: repeat(2, 1fr); gap: 11px; }

  .category-product-skeleton { min-height: 310px; border-radius: 19px; padding: 0 12px 12px; }

  .category-product-skeleton i { width: calc(100% + 24px); height: 145px; margin-inline: -12px; }

  .category-results-pagination { gap: 6px; margin-top: 26px; }
  .category-results-pagination button,
  .category-results-pagination a { min-width: 34px; height: 34px; padding: 0 9px; font-size: 11px; }
  .category-results-pagination > span { width: 100%; margin: 5px 0 0; text-align: center; }

  .category-results-count span {
    display: block;
    white-space: nowrap;
  }

  .category-subcategories { border-radius: 15px; }
  .category-subcategories-heading { padding: 13px; font-size: 13px; }
  .category-subcategories nav { gap: 5px; }
  .category-subcategories b,
  .category-subcategories a { border-radius: 9px; padding: 8px 11px; font-size: 11px; }
}
