How memory and motivation modulate the responses to trail pheromones in three ant species