“So I want to ride this way but I need a bike that does this and that and the other thing. What can you recommend?”
What I can recommend, very specifically, is this: Ride more.
There are bikes which can be dual purpose – for example, a hybrid style bike with mountain bike gearing and suspension shocks in the front fork that can go on light trails and also be on pavement. There are bikes which are intended purely for pavement. And then there are bikes that are meant to be taken out over gravel and dirt and logs and rocks.
Each of those styles of bikes can be ridden in multiple ways. You want to take a mountain bike on pavement? Sure, no problem – though it’s heavier, and maybe more “grippy”, than you might want. Going on a trail through the woods on a road bike? OK, if you’ve got some handling skills and maybe some knobbier tires. Doing a CX race on a steel frame hybrid bike? (Yeah, I did that.)
It’s not (always) the bike itself: it’s the rider. Handling skills are transferable from bike to bike, and situation to situation. You’ll always need to know how to stop correctly. You’ll always need to know how to change gears (unless you’re on a fixed gear or single speed ride). You’ll always need to know how to balance and to anticipate what’s coming up next.
Be prepared for whatever bike you ride by learning more about riding, itself.