.filters-container {
  padding: 20px 30px;
  background: #f8f9fa;
  border-bottom: 1px solid #e9ecef;
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  align-items: center;
  transition: all 0.3s ease;
}

.filters-wrapper {
  display: flex;
  gap: 20px;
  flex-wrap: wrap;
  align-items: center;
  flex: 1;
}

.filter-group {
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-width: 200px;
}

.filter-label {
  font-weight: 600;
  color: #495057;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.filter-select {
  padding: 10px 14px;
  border: 1px solid #dee2e6;
  border-radius: 8px;
  background: white;
  font-size: 14px;
  color: #495057;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.filter-select:hover {
  border-color: #667eea;
  box-shadow: 0 2px 8px rgba(102, 126, 234, 0.15);
}

.filter-select:focus {
  outline: none;
  border-color: #667eea;
  box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

.filter-select option {
  padding: 8px;
  color: #495057;
}

.filters-actions {
  display: flex;
  gap: 10px;
  align-items: flex-end;
  margin-top: 22px;
}

.clear-filters-btn {
  background: linear-gradient(135deg, #dc3545 0%, #c82333 100%);
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(220, 53, 69, 0.3);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.clear-filters-btn:hover {
  background: linear-gradient(135deg, #c82333 0%, #a71e2a 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(220, 53, 69, 0.4);
}

.clear-filters-btn:active {
  transform: translateY(0);
  box-shadow: 0 2px 4px rgba(220, 53, 69, 0.3);
}

.toggle-filters-btn {
  background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
  color: white;
  border: none;
  padding: 10px 18px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.3s ease;
  box-shadow: 0 2px 4px rgba(102, 126, 234, 0.3);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.toggle-filters-btn:hover {
  background: linear-gradient(135deg, #5a67d8 0%, #6b46c1 100%);
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(102, 126, 234, 0.4);
}

.filters-summary {
  background: #e3f2fd;
  border: 1px solid #bbdefb;
  border-radius: 6px;
  padding: 8px 12px;
  font-size: 13px;
  color: #1565c0;
  font-weight: 500;
  margin-left: auto;
}

.filters-summary.active {
  background: #e8f5e8;
  border-color: #c8e6c9;
  color: #2e7d32;
}

/* ------------------------------------------------------ анимация для счетчика результатов */
.results-counter {
  background: linear-gradient(135deg, #28a745 0%, #20c997 100%);
  color: white;
  padding: 8px 16px;
  border-radius: 20px;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  box-shadow: 0 2px 4px rgba(40, 167, 69, 0.3);
  transition: all 0.3s ease;
}

.results-counter.updating {
  animation: pulse 0.5s ease-in-out;
}

@keyframes pulse {
  0% {
    transform: scale(1);
  }
  50% {
    transform: scale(1.05);
  }
  100% {
    transform: scale(1);
  }
}

/* ------------------------------------------------------------- адаптивность */
@media (max-width: 768px) {
  .filters-container {
    flex-direction: column;
    align-items: stretch;
    padding: 15px 20px;
  }

  .filters-wrapper {
    flex-direction: column;
    gap: 15px;
  }

  .filter-group {
    width: 100%;
    min-width: auto;
  }

  .filter-select {
    width: 100%;
  }

  .filters-actions {
    width: 100%;
    justify-content: space-between;
    margin-top: 15px;
  }

  .clear-filters-btn,
  .toggle-filters-btn {
    flex: 1;
    max-width: calc(50% - 5px);
  }

  .filters-summary {
    margin-left: 0;
    text-align: center;
    margin-top: 10px;
  }
}

@media (max-width: 480px) {
  .filters-container {
    padding: 12px 15px;
  }

  .filter-group {
    gap: 6px;
  }

  .filter-label {
    font-size: 13px;
  }

  .filter-select {
    padding: 8px 12px;
    font-size: 13px;
  }

  .clear-filters-btn,
  .toggle-filters-btn {
    padding: 8px 14px;
    font-size: 13px;
  }
}

.filters-container.loading {
  opacity: 0.7;
  pointer-events: none;
}

.filters-container.loading::after {
  content: '';
  position: absolute;
  top: 50%;
  left: 50%;
  width: 20px;
  height: 20px;
  border: 2px solid #667eea;
  border-top: 2px solid transparent;
  border-radius: 50%;
  animation: spin 1s linear infinite;
  transform: translate(-50%, -50%);
}

@keyframes spin {
  0% {
    transform: translate(-50%, -50%) rotate(0deg);
  }
  100% {
    transform: translate(-50%, -50%) rotate(360deg);
  }
}
