/* ===================================================
   ZetaStyle Wear — Category / Shop Page Styles
=================================================== */

/* --- Page Header --- */
.category-page-header {
  padding: 120px 5% 40px;
  background-color: var(--light-bg, #fafafa);
  text-align: center;
  border-bottom: 1px solid var(--border-color, #eee);
}

.breadcrumb {
  font-size: 0.9rem;
  color: var(--text-light, #666);
  margin-bottom: 15px;
  font-weight: 500;
}

.breadcrumb a {
  color: var(--text-dark, #111);
  text-decoration: none;
  transition: color 0.3s;
}

.breadcrumb a:hover {
  color: var(--primary-color, #000);
  text-decoration: underline;
}

.breadcrumb .separator {
  margin: 0 8px;
  color: #ccc;
}

.category-main-title {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 3.5rem;
  letter-spacing: 2px;
  color: var(--text-dark, #111);
  margin-bottom: 10px;
}

.category-main-desc {
  color: var(--text-light, #666);
  font-size: 1.1rem;
  max-width: 600px;
  margin: 0 auto;
}

/* --- Shop Section Layout --- */
.shop-section {
  display: flex;
  padding: 50px 5%;
  gap: 40px;
  align-items: flex-start;
  max-width: 1400px;
  margin: 0 auto;
}

/* --- Sidebar Filters --- */
.sidebar-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0, 0, 0, 0.6);
  z-index: 10000;
  opacity: 0;
  visibility: hidden;
  transition: all 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  backdrop-filter: blur(3px);
}

.sidebar-overlay.active {
  opacity: 1;
  visibility: visible;
}

.shop-sidebar {
  position: fixed;
  top: 0;
  left: -350px;
  width: 320px;
  height: 100vh;
  background: #fff;
  z-index: 10001;
  overflow-y: auto;
  padding: 30px 25px;
  transition: left 0.4s cubic-bezier(0.4, 0, 0.2, 1);
  box-shadow: 4px 0 15px rgba(0, 0, 0, 0.05);
}

.shop-sidebar.active {
  left: 0;
}

.sidebar-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--border-color, #eee);
}

.sidebar-header h2 {
  font-family: 'Bebas Neue', sans-serif;
  font-size: 2.2rem;
  letter-spacing: 1.5px;
  margin: 0;
}

.close-sidebar {
  background: none;
  border: none;
  font-size: 2.5rem;
  line-height: 1;
  cursor: pointer;
  color: var(--text-dark, #111);
  transition: transform 0.3s, color 0.3s;
}

.close-sidebar:hover {
  transform: rotate(90deg);
  color: var(--text-light, #666);
}

.filter-group {
  margin-bottom: 35px;
  padding-bottom: 25px;
  border-bottom: 1px solid var(--border-color, #eee);
}

.filter-group:last-child {
  border-bottom: none;
}

.filter-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 15px;
  text-transform: uppercase;
  letter-spacing: 1px;
}

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

.filter-list li {
  margin-bottom: 10px;
}

.filter-link {
  text-decoration: none;
  color: var(--text-light, #555);
  font-size: 1rem;
  font-weight: 500;
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
}

.filter-link:hover, .filter-link.active {
  color: var(--text-dark, #000);
  font-weight: 700;
}

.filter-link.active::before {
  content: '→';
  margin-right: 8px;
  color: var(--primary-color, #000);
}

/* Price Slider */
.price-filter {
  margin-top: 10px;
}

.price-slider {
  width: 100%;
  -webkit-appearance: none;
  height: 4px;
  background: #ddd;
  border-radius: 2px;
  outline: none;
  margin-bottom: 15px;
}

.price-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--text-dark, #000);
  cursor: pointer;
}

.price-labels {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-light, #555);
}

/* Size & Color Filters */
.size-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.size-btn {
  min-width: 40px;
  height: 40px;
  padding: 0 8px;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-family: inherit;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.size-btn:hover, .size-btn.active {
  background: var(--text-dark, #000);
  color: #fff;
  border-color: var(--text-dark, #000);
}

.color-filter {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.color-btn {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: none;
  cursor: pointer;
  transition: transform 0.2s, box-shadow 0.2s;
  position: relative;
}

.color-btn:hover {
  transform: scale(1.1);
}

.color-btn.active {
  box-shadow: 0 0 0 2px #fff, 0 0 0 4px var(--text-dark, #000);
}

/* --- Main Shop Area --- */
.shop-main {
  flex-grow: 1;
}

.shop-controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 30px;
  padding-bottom: 15px;
  border-bottom: 1px solid var(--border-color, #eee);
  gap: 15px;
  flex-wrap: wrap;
}

.shop-controls-left {
  display: flex;
  align-items: center;
  gap: 20px;
}

.show-sidebar-btn {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid var(--text-dark, #111);
  color: var(--text-dark, #111);
  padding: 10px 20px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  border-radius: 4px;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.show-sidebar-btn:hover {
  background: var(--text-dark, #111);
  color: #fff;
}

.show-sidebar-btn:hover svg {
  stroke: #fff;
}

.results-count {
  font-size: 1rem;
  font-weight: 500;
  color: var(--text-light, #666);
}

.sort-dropdown select {
  padding: 8px 16px;
  border: 1px solid #ccc;
  border-radius: 4px;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  background-color: #fff;
  outline: none;
}

/* Grid Layout overrides (using existing product-card styles from style.css) */
.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 30px;
}

/* Empty State */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 20px;
  text-align: center;
  color: var(--text-light, #666);
  background: #f9f9f9;
  border-radius: 12px;
}

.empty-state svg {
  margin-bottom: 20px;
  color: #ccc;
}

.empty-state h3 {
  font-size: 1.5rem;
  color: var(--text-dark, #111);
  margin-bottom: 10px;
}

.clear-filters-btn {
  margin-top: 20px;
  padding: 10px 24px;
  background: var(--text-dark, #000);
  color: #fff;
  border: none;
  border-radius: 4px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.3s;
}

.clear-filters-btn:hover {
  opacity: 0.8;
}

/* --- Custom Filters styling --- */
.filter-title {
  display: inline-block;
  font-size: 1.05rem;
  font-weight: 700;
  margin-bottom: 15px;
  text-transform: capitalize;
  letter-spacing: 0.5px;
  background-color: yellow;
  color: #000;
  padding: 2px 5px;
}

.color-title {
  background-color: transparent;
  color: red;
  padding: 0;
}

.sub-filter-title {
  font-size: 0.95rem;
  font-weight: 600;
  margin: 15px 0 10px 0;
  color: #333;
}

.custom-checkbox-list {
  padding-left: 0;
}

.custom-checkbox-list li {
  margin-bottom: 8px;
}

.custom-checkbox {
  display: flex;
  align-items: center;
  position: relative;
  cursor: pointer;
  font-size: 0.95rem;
  user-select: none;
  color: #333;
  transition: color 0.2s;
}

.custom-checkbox:hover {
  color: #000;
}

.custom-checkbox input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.checkmark {
  position: relative;
  display: inline-block;
  height: 16px;
  width: 16px;
  background-color: #fff;
  border: 1px solid #999;
  border-radius: 2px;
  margin-right: 10px;
  transition: all 0.2s;
}

.custom-checkbox input:checked ~ .checkmark {
  background-color: #000;
  border-color: #000;
}

.checkmark:after {
  content: "";
  position: absolute;
  display: none;
  left: 4px;
  top: 1px;
  width: 4px;
  height: 8px;
  border: solid white;
  border-width: 0 2px 2px 0;
  transform: rotate(45deg);
}

.custom-checkbox input:checked ~ .checkmark:after {
  display: block;
}

.sub-filter-group {
  padding-left: 20px;
  border-left: 1px dashed #ccc;
  margin-left: 8px;
  margin-bottom: 15px;
  margin-top: 5px;
}

.hidden {
  display: none;
}

.show-more-toggle {
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  margin-top: 10px;
  margin-bottom: 10px;
}

.show-more-toggle .highlight-text {
  background-color: cyan;
  color: #000;
  padding: 2px 5px;
}

.show-more-toggle:hover .highlight-text {
  opacity: 0.8;
}

.size-desc {
  font-size: 0.85rem;
  color: #666;
  margin-bottom: 10px;
}

/* --- Active Filters --- */
.active-filters-container {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin-bottom: 30px;
  padding: 16px 20px;
  background: #f8f9fa;
  border: 1px solid #eaeaea;
  border-radius: 8px;
  transition: all 0.3s ease;
}

.active-filters-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.active-filters-label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-light, #666);
}

.active-filters-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-dark, #111);
  cursor: pointer;
  padding: 4px;
}

.active-filters-content {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  width: 100%;
}

.active-filters-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  flex: 1;
}

.filter-chip {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  background: var(--text-dark, #111);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 500;
  border-radius: 30px;
  transition: all 0.2s ease;
  box-shadow: 0 2px 5px rgba(0,0,0,0.1);
}

.filter-chip:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 10px rgba(0,0,0,0.15);
}

.remove-chip {
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.2);
  border-radius: 50%;
  width: 18px;
  height: 18px;
  transition: 0.2s;
}

.remove-chip:hover {
  background: #ff5252;
  color: #fff;
}

.clear-all-filters-btn {
  background: none;
  border: none;
  font-size: 0.85rem;
  font-weight: 600;
  color: #ff5252;
  cursor: pointer;
  margin-left: auto;
  text-decoration: underline;
  text-underline-offset: 3px;
  transition: 0.2s;
}

.clear-all-filters-btn:hover {
  color: #d32f2f;
}

/* --- Responsive Design --- */
@media (max-width: 992px) {
  .shop-section {
    flex-direction: column;
    padding-top: 30px;
  }
}

@media (max-width: 576px) {
  .shop-section {
    padding-top: 10px;
  }
  .category-page-header {
    padding: 20px 5% 10px;
  }
  .category-main-title {
    font-size: 2.5rem;
  }
  
  .shop-controls {
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    margin-bottom: 15px;
    padding-bottom: 15px;
  }

  .shop-controls-left {
    width: 100%;
    justify-content: space-between;
  }
  
  .show-sidebar-btn {
    padding: 6px 14px;
    font-size: 0.8rem;
  }
  
  .show-sidebar-btn svg {
    width: 14px;
    height: 14px;
  }
  
  .results-count {
    font-size: 0.85rem;
  }
  
  .sort-dropdown {
    width: 100%;
  }

  .sort-dropdown select {
    width: 100%;
    padding: 8px 12px;
    font-size: 0.85rem;
  }
  
  .category-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 15px;
  }

  .shop-sidebar {
    width: 85vw; /* Slightly narrower on very small screens */
    padding: 20px 15px;
  }

  .active-filters-content {
    display: none;
    flex-direction: column;
    align-items: flex-start;
  }
  .active-filters-content.expanded {
    display: flex;
  }
  .active-filters-toggle {
    display: flex;
  }
  .active-filters-toggle svg {
    transition: transform 0.3s ease;
  }
  .active-filters-container.expanded .active-filters-toggle svg {
    transform: rotate(180deg);
  }
  .clear-all-filters-btn {
    margin-left: 0;
    margin-top: 8px;
  }
}

@media (min-width: 577px) {
  .active-filters-container {
    flex-direction: row;
  }
  .active-filters-header {
    width: auto;
  }
}
