As vesperus so aptly pointed out, submarines are often actually better for covert arms dealing than surface ships.
Additionally, the russians literally build missile submarines of a type that doesn't exist in any other country, a dedicated anti ship missile submarine, starting with the oscar class (yasen is a significant engineering improvement of the same concept).
View attachment 5795588
This type of missile submarine is arguably superior to pretty much all of their surface combatants as far as missile salvos go (pretty big salvo, and much more able to achieve surprise), and is far more survivable and maneuverable in high threat environments.
I agree with you on anti piracy, but IMO that is patrol boat up to corvette territory only, even 3000 tons would be rather heavy. I think at best you could argue light air defense is valuable, but that requires the ability to maintain sea superiority which is both I think impossible in the modern environment anyways, and also extremely difficult to do with an already overstretched naval engineering capacity.