Mostly they're dried, including pod, the rest is genetics.
They are botanically nuts, though: They are indehiscent, meaning they do not open to release their seeds. They're also fruit. It's e.g. pine nuts which aren't nuts because pine cones do indeed open and release the seeds. Of which you should roast a couple and mush up with a wee bit of garlic, a metric pound of basil, some salt, some proper hard cheese, and quantum satis good olive oil. Use a mortar the basil wants to get squeezed, pre-chop everything or you're going to be there forever. Throw your pasta, shape is not that important as long as it's bronze-cut, into a pan at lowish heat, put your pesto on top, add some of that pasta water (incl. the starch in there), the saponids in the garlic will help with emulsifying everything. Reduce very carefully you don't want to denature the cheese.
I guess making a distinction, in the culinary context, between nuts and peanuts makes sense because allergy considerations, legumes are a class of their own there.
I used to be able to name every nut that there was. And it used to drive my mother crazy, because she used to say, "Harlan Pepper, if you don't stop naming nuts," and the joke was that we lived in Pine Nut, and I think that's what put it in my mind at that point. So she would hear me in the other room, and she'd just start yelling. I'd say, "Peanut. Hazelnut. Cashew nut. Macadamia nut." That was the one that would send her into going crazy. She'd say, "Would you stop naming nuts!" And Hubert used to be able to make the sound, he couldn't talk, but he'd go "rrrawr rrawr" and that sounded like Macadamia nut. Pine nut, which is a nut, but it's also the name of a town. Pistachio nut. Red pistachio nut. Natural, all natural white pistachio nut.