/*
* Zahya Store - Simplified Sidebar Styles (No Animations)
* Version: 1.2
*/

/*--------------------------------------------------------------
# Sidebar Containers
--------------------------------------------------------------*/
.store-sidebar {
  margin-bottom: 30px;
}

.sidebar-widget {
  background-color: var(--card-bg);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 30px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(0, 0, 0, 0.05);
  overflow: hidden;
  position: relative;
}

.sidebar-title {
  font-size: 18px;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid rgba(0, 0, 0, 0.06);
  position: relative;
  font-weight: 600;
  color: var(--text-color);
  display: flex;
  align-items: center;
}

/* Add icons to each sidebar title */
.sidebar-widget:nth-child(1) .sidebar-title::before {
  content: '\f0c9'; /* fa-bars */
  font-family: "Font Awesome 6 Free";
  margin-right: 12px;
  font-weight: 900;
  color: var(--primary-color);
  font-size: 0.9em;
  opacity: 0.9;
}

.sidebar-widget:nth-child(2) .sidebar-title::before {
  content: '\f0b0'; /* fa-filter */
  font-family: "Font Awesome 6 Free";
  margin-right: 12px;
  font-weight: 900;
  color: var(--primary-color);
  font-size: 0.9em;
  opacity: 0.9;
}

.sidebar-widget:nth-child(3) .sidebar-title::before {
  content: '\f0dc'; /* fa-sort */
  font-family: "Font Awesome 6 Free";
  margin-right: 12px;
  font-weight: 900;
  color: var(--primary-color);
  font-size: 0.9em;
  opacity: 0.9;
}

.sidebar-title::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 60px;
  height: 2px;
  background-color: var(--primary-color);
}

/*--------------------------------------------------------------
# Categories Sidebar
--------------------------------------------------------------*/
.category-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.category-item {
  margin-bottom: 12px;
  position: relative;
  border-radius: 8px;
  overflow: hidden;
}

.category-item:last-child {
  margin-bottom: 0;
}

.category-link {
  display: block;
  padding: 10px 15px;
  color: var(--text-color);
  font-weight: 500;
  position: relative;
  border-radius: 8px;
  background-color: rgba(0, 0, 0, 0.01);
  border: 1px solid transparent;
}

/* Hover and active states */
.category-link:hover, 
.category-link.active {
  color: var(--primary-color);
  text-decoration: none;
  background-color: rgba(99, 102, 241, 0.05);
  border-color: rgba(99, 102, 241, 0.1);
}

.category-link.active {
  font-weight: 600;
  border-left: 3px solid var(--primary-color);
}

/* Category icon styling */
.category-icon {
  position: absolute;
  right: 15px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 10px;
}

.category-link.active .category-icon {
  color: var(--primary-color);
}

/* Subcategories styling */
.subcategory-list {
  padding-left: 20px;
  margin-top: 5px;
  display: none;
  overflow: hidden;
}

.subcategory-list.show {
  display: block;
}

.subcategory-item {
  margin-bottom: 8px;
}

.subcategory-item:last-child {
  margin-bottom: 0;
}

.subcategory-link {
  color: var(--text-color);
  font-size: 14px;
  padding: 6px 12px;
  display: block;
  border-radius: 6px;
  border-left: 2px solid transparent;
}

.subcategory-link:hover,
.subcategory-link.active {
  color: var(--primary-color);
  text-decoration: none;
  background-color: rgba(99, 102, 241, 0.05);
  border-left-color: var(--primary-color);
}

.subcategory-link.active {
  font-weight: 600;
}

/*--------------------------------------------------------------
# Filter Sidebar - Special Styling for Filter Widget
--------------------------------------------------------------*/
/* Make sure filter widget inherits sidebar styles correctly */
.sidebar-widget.filter-widget {
  background-color: var(--card-bg);
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 30px;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.03);
  border: 1px solid rgba(0, 0, 0, 0.05);
  overflow: hidden;
  position: relative;
}

.sidebar-widget.filter-widget .sidebar-title {
  font-size: 18px;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 2px solid rgba(0, 0, 0, 0.06);
  position: relative;
  font-weight: 600;
  color: var(--text-color);
}

/* Custom Radio Button Styling */
.filter-options {
  padding: 5px 0;
}

.filter-option {
  position: relative;
  margin-bottom: 12px;
  cursor: pointer;
}

.filter-option:last-child {
  margin-bottom: 15px;
}

.filter-option input[type="radio"] {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.filter-option-card {
  display: flex;
  align-items: center;
  padding: 10px 14px;
  border-radius: 8px;
  background-color: var(--card-bg);
  border: 1px solid rgba(0, 0, 0, 0.08);
  position: relative;
  overflow: hidden;
  z-index: 1;
}

.filter-option:hover .filter-option-card {
  background-color: rgba(99, 102, 241, 0.04);
}

.filter-option input[type="radio"]:checked + .filter-option-card {
  background-color: rgba(99, 102, 241, 0.08);
  border-color: var(--primary-color);
}

/* Custom Radio Circle */
.filter-radio {
  position: relative;
  width: 18px;
  height: 18px;
  min-width: 18px;
  border: 2px solid rgba(0, 0, 0, 0.2);
  border-radius: 50%;
  margin-right: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.filter-option input[type="radio"]:checked + .filter-option-card .filter-radio {
  border-color: var(--primary-color);
}

.filter-radio::after {
  content: "";
  position: absolute;
  width: 0;
  height: 0;
  background-color: var(--primary-color);
  border-radius: 50%;
  opacity: 0;
}

.filter-option input[type="radio"]:checked + .filter-option-card .filter-radio::after {
  width: 10px;
  height: 10px;
  opacity: 1;
}

/* Option Text */
.filter-text {
  display: flex;
  align-items: center;
  font-weight: 500;
  font-size: 0.9rem;
  color: var(--text-color);
}

.filter-option input[type="radio"]:checked + .filter-option-card .filter-text {
  color: var(--primary-color);
}

/* Filter Icons */
.filter-icon {
  margin-right: 10px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.filter-option input[type="radio"]:checked + .filter-option-card .filter-icon {
  color: var(--primary-color);
}

/* Filter Action Buttons */
.filter-apply-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  background-color: var(--primary-color);
  color: white;
  font-weight: 500;
  font-size: 0.95rem;
  text-align: center;
  border: none;
  cursor: pointer;
  position: relative;
  overflow: hidden;
  gap: 8px;
  box-shadow: 0 4px 10px rgba(99, 102, 241, 0.2);
}

.filter-apply-btn:hover {
  background-color: var(--primary-hover);
}

.filter-reset-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  background-color: transparent;
  color: var(--text-muted);
  font-weight: 500;
  font-size: 0.9rem;
  text-align: center;
  border: 1px dashed rgba(0, 0, 0, 0.1);
  margin-top: 10px;
  cursor: pointer;
  gap: 8px;
  text-decoration: none;
}

.filter-reset-btn:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
  background-color: rgba(99, 102, 241, 0.03);
}

/* Rating Filter Styling */
.rating-filter {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.rating-option {
  position: relative;
  cursor: pointer;
  margin: 0;
}

.rating-option input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.rating-option-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 15px;
  border-radius: 8px;
  background-color: var(--card-bg);
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.rating-option input:checked + .rating-option-card {
  background-color: rgba(99, 102, 241, 0.08);
  border-color: var(--primary-color);
}

.rating-stars {
  color: #ffc107;
  letter-spacing: 1px;
}

.rating-text {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-color);
}

/* Date Filter Styling */
.date-filter {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.date-option {
  position: relative;
  cursor: pointer;
  margin: 0;
}

.date-option input {
  position: absolute;
  opacity: 0;
  cursor: pointer;
  height: 0;
  width: 0;
}

.date-option-card {
  display: flex;
  align-items: center;
  padding: 8px 15px;
  border-radius: 8px;
  background-color: var(--card-bg);
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.date-option input:checked + .date-option-card {
  background-color: rgba(99, 102, 241, 0.08);
  border-color: var(--primary-color);
}

.date-option input:checked + .date-option-card .date-icon {
  color: var(--primary-color);
}

.date-icon {
  margin-right: 10px;
  color: var(--text-muted);
}

.date-text {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-color);
}

/*--------------------------------------------------------------
# Filter Section Title and Components
--------------------------------------------------------------*/
.filter-section {
  margin-bottom: 20px;
}

.filter-section-title {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 15px;
  color: var(--text-color);
  position: relative;
  padding-left: 15px;
}

.filter-section-title::before {
  content: '';
  position: absolute;
  left: 0;
  top: 50%;
  transform: translateY(-50%);
  width: 6px;
  height: 16px;
  background-color: var(--primary-color);
  border-radius: 3px;
}

/*--------------------------------------------------------------
# Price Range Slider Styling
--------------------------------------------------------------*/
.price-slider-container {
  padding: 0 5px;
}

/* noUiSlider Customization */
.noUi-connect {
  background: var(--primary-color);
}

.noUi-horizontal {
  height: 8px;
}

.noUi-horizontal .noUi-handle {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background-color: #fff;
  box-shadow: 0 1px 5px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  border: 2px solid var(--primary-color);
  top: -7px;
  right: -10px;
}

.noUi-handle:before,
.noUi-handle:after {
  display: none;
}

.noUi-target {
  border-radius: 4px;
  border: none;
  box-shadow: none;
  background-color: rgba(0, 0, 0, 0.1);
}

/* Price inputs */
.price-inputs {
  margin-top: 15px;
}

.price-input {
  position: relative;
  width: 45%;
}

.price-currency {
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
  z-index: 1;
}

.price-input .form-control {
  padding-left: 25px;
  height: 36px;
}

.price-input .form-control:focus {
  border-color: var(--primary-color);
}

.price-separator {
  margin: 0 10px;
  color: var(--text-muted);
  font-weight: 500;
}

/*--------------------------------------------------------------
# Sort By Sidebar
--------------------------------------------------------------*/
.sort-options {
  padding: 10px 0;
  position: relative;
}

.sort-options .form-select {
  border-radius: 10px;
  padding: 12px 16px;
  font-size: 0.95rem;
  font-weight: 500;
  letter-spacing: 0.01rem;
  color: var(--text-color);
  background-color: var(--card-bg);
  border: 1px solid rgba(0, 0, 0, 0.08);
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%236366F1' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 16px;
  padding-right: 42px;
  position: relative;
  z-index: 1;
}

.sort-options .form-select:focus {
  border-color: var(--primary-color);
  outline: none;
}

.sort-options .form-select option {
  padding: 12px;
  font-weight: 500;
}

/*--------------------------------------------------------------
# Dark Theme Adjustments
--------------------------------------------------------------*/
.theme-dark .sidebar-widget {
  background-color: #1f1f2c;
  border-color: #2e2e3e;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.15);
}

.theme-dark .sidebar-widget.filter-widget {
  background-color: #1f1f2c;
  border-color: #2e2e3e;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.25);
}

.theme-dark .sidebar-title {
  color: #e0e0e0;
  border-bottom-color: #2e2e3e;
}

.theme-dark .category-link {
  color: #e0e0e0;
  background-color: rgba(255, 255, 255, 0.02);
}

.theme-dark .category-link:hover, 
.theme-dark .category-link.active {
  background-color: rgba(99, 102, 241, 0.15);
  border-color: rgba(99, 102, 241, 0.3);
}

.theme-dark .subcategory-link {
  color: #c0c0c0;
}

.theme-dark .subcategory-link:hover,
.theme-dark .subcategory-link.active {
  background-color: rgba(99, 102, 241, 0.15);
}

.theme-dark .filter-option-card {
  background-color: #2a2a38;
  border-color: #3a3a48;
}

.theme-dark .filter-option input[type="radio"]:checked + .filter-option-card {
  background-color: rgba(99, 102, 241, 0.15);
  border-color: var(--primary-color);
}

.theme-dark .filter-radio {
  border-color: #4e4e5e;
}

.theme-dark .filter-text {
  color: #e0e0e0;
}

.theme-dark .filter-icon {
  color: #8e8e9e;
}

.theme-dark .filter-reset-btn {
  border-color: rgba(255, 255, 255, 0.1);
  color: #9e9e9e;
}

.theme-dark .filter-reset-btn:hover {
  border-color: var(--primary-color);
  color: var(--primary-color);
  background-color: rgba(99, 102, 241, 0.1);
}

.theme-dark .rating-option-card,
.theme-dark .date-option-card {
  background-color: #2a2a38;
  border-color: #3a3a48;
}

.theme-dark .rating-option input:checked + .rating-option-card,
.theme-dark .date-option input:checked + .date-option-card {
  background-color: rgba(99, 102, 241, 0.15);
  border-color: var(--primary-color);
}

.theme-dark .rating-text,
.theme-dark .date-text {
  color: #e0e0e0;
}

.theme-dark .date-icon {
  color: #8e8e9e;
}

.theme-dark .noUi-target {
  background-color: rgba(255, 255, 255, 0.1);
}

.theme-dark .noUi-handle {
  background-color: #2a2a38;
  border-color: var(--primary-color);
}

.theme-dark .sort-options .form-select {
  background-color: #1f1f2c;
  border-color: #2e2e3e;
  color: #e0e0e0;
}

.theme-dark .sort-options .form-select:focus {
  border-color: var(--primary-color);
}

.theme-dark .sort-options .form-select option {
  background-color: #1f1f2c;
  color: #e0e0e0;
}