This sounds like a very common issue with the iPhone 7 (and 7 Plus) that develops with the Audio chip on the board.
My guess is that wired headphones through an adapter also don't work. And your speakerphone button is greyed out during a call. That and voice memos not working are all text book symptoms.
Your Bluetooth headphones work, because they use different circuitry so it bypasses the problematic spot.
It's been documented pretty thoroughly on iFixit already, so I won't beat a dead horse, but chances are you're going to need a board-level technician to fix your issue. There are some spots on the logic board that lose connection to this Audio chip so it needs to be desoldered, and connections to the relevant spots need to be remade with tiny jumper wires.
UPDATE: This guy. You can just peel up the sticker covering all the board components on the back. The loose connections will be along the edge of the chip closest to the NAND (the big silver one in the middle of the board).
crwdns2934105:0crwdne2934105:0
crwdns2934113:0crwdne2934113:0
crwdns2915270:0crwdne2915270:0
crwdns2889612:0crwdne2889612:0
2
crwdns2942205:01crwdne2942205:0
Nothing obvious in the headphone jack, tried repeatedly inserting headphone cord and that didn't help.
crwdns2934271:0crwdnd2934271:0 Sean Christianson crwdne2934271:0