Welcome to Android Forums Jas19kt. If shaking the phone sometimes causes the screen to become responsive leads one to think it's a physical problem. It could be at the connector or anywhere along the power to the screen. It doesn't sound like a firmware problem but I'm only guessing.
If it's a phone new enough to be cost effective to repair or as you suggest you might lose some important documents, I'd suggest seeking a reputable phone repair shop vs attempting the project yourself. Considering the minute circuitry of a cell phone, it's not something I'd care to attempt. But that's me. Good luck in whatever you decide to do.
well if you can get to the screen's cables, you can always try unplugging it and see if that helps. and as @olbriar said it could have gotten loose. but i would look into taking it in to a professional and see what they can do......i am not one for doing DIY on electronics. my fingers are not that nimble....lol
I have a S23 now, so it wouldn't be very cost effective. I was just thinking of any direction to retrieve the data without a third party being involved. Nothing criminal on their but just very sensitive information.