too many repetitions of next.classList