For your stated purposes the .22LR is what you really want, and it in a quality revolver with adjustable sights.
There are .22LR cartridges in a wide spectrum of load levels from subsonic to hyper-velo, light bullet weight to the Aguila SSS 60gr. (which is heavy enough and accurate enough at 35 yds to penetrate deep, even though sub sonic, and the revolver, unlike an auto, will digest them all).
Get one with about a 4-5" barrel, it will be easy to pack and belt carry, and not too heavy or you wont carry it, and shoot cheap 22 ammo enough to get good with it.
When (if) you ever get tired of it you wont have trouble selling/trading if you take care of it properly.
If you had wanted a caliber with more beans I would have recommended the 357Mag for all the very good reasons already stated.