Headcannon: James Potter was an excellent dancer. He was a pureblood who would have learnt all the traditional wizarding dancers etc.
…Therefore, Harry’s terrible dancing genes came from his mother.