Should you thank helpful referees in the acknowledgements section of a paper? I submitted a paper to a [science] journal and received some particularly constructive feedback from the referees. I am inclined to add something to the effect of

We are grateful to the referees for their constructive input.

to the acknowledgements, as I have seen in other papers before. But is this considered appropriate?

On the one hand, it seems polite. But on the other, it's part of the job of a referee to make suggestions. Moreover, since they are anonymous and I am not going to specify their contributions, the only information provided in this remark is that 'someone suggested something' which seems a bit pointless.
I usually try to add a line to the acknowledgements to thank anonymous referees and I try to make it honest and clear. Reviewers' time and effort invariably improves my papers and I think it's only polite to thank anybody who contributed for their time, effort, and engagement to making a manuscript better.

Will anybody care if it's missing? Will anybody even notice if it's missing? Probably not. That said, although it may be the "job" of the reviewers to give suggestions, refereeing is something that academics do as volunteers. Reviewing papers is perhaps the most thankless part of an academic job. Acknowledgement of the positive impact that referees have seems like the least an author can do.