Fixed dynamic sorting based on category