The iPhone 15 Pro Max I bought last year suffered from this very same problem and I did a lot of research to finally, without a shadow of a doubt, conclude that this is a 100% hardware problem. It’s not clear how many iPhones are affected.
Of course the problem was ignored by my reseller, they didn’t even want to hear about it, although I had prepared 100% reproducible use cases in very particular parts of the screen, most notably in a lower right corner.
As the problem was completely ignored, I returned to my iPhone 13 Pro Max that, by pure chance, never had this issue.
[Edited by Moderator]