Pedals and shoes must be discussed separately, because with shoes fit is soooo important. Depending on your foot shape and the way some brands are cut, some shoes that are amazing for some athletes are the worst nightmare for others. So you need to try them on if at all possible. I have wide feet, so I don’t have that luxury. Recommending a brand over another is kinda had.
But let me add something about shoe types. So on the MTB side, you have much more variety. You have marathon XC pedal which are every bit as stiff as the best road shoes you can get. Awesome for power transfer (which IMHO is on par with road shoes), but precisely because they are so unforgivingly stiff, walking gets much more awkward and uncomfortable. At the other end of the spectrum, you have relatively soft shoes which are like sneakers with a very stiff sole. But because they often feature a high-profile rubber sole, they are extremely comfortable. I still have a pair of 10±year-old ratty Northwave shoes I use for commuting. And they are as comfortable to walk in as regular shoes. Thanks to their high profile, walking in slippery conditions was always super easy.
And then basically, you can have anything in between. Cost effective shoes will tend to have a “softer” (relatively speaking!) sole, because only the top-end shoes have a super stiff carbon sole.
With pedals, yeah, Shimano pedals are virtually indestructible. I have Crankbrothers pedals right now, because they offer more float, which works better for my knees. But compared to Shimano pedals, they need maintenance. When I had Shimano pedals, I never thought about maintenance ever. And they worked until the end. I recommend to go for one of the XT-level pedals, not the M520s, though. They have two models, one with a cage and one without. The one with the cage weigh more, but offer some protection of the mechanism against rock strikes.