I had the same problem with my 6+ (not an S). After reading up on similar situations, I think (and I could be wrong) that your phone is having problems with its display controller because the symptoms sound like the same thing I saw. The controller is on the main logic board, so fixing it is possible but new logic boards aren't cheap. There are some repair outfits I've seen that can replace the controller itself and keep the original logic board, but you need some specific skills to do that. I ended up getting a new phone because I didn't want to replace the board only to find out that it wasn't the problem.
Like I said, your problem may be different than mine was. But it does sound similar. Good luck. Also, look up "touch disease" and see if that sounds like your problem. Apple has a repair program for that, but they didn't think my problem qualified.