No, not analogy fail.
You stated that HOAs have NOTHING to do with government. You were wrong, and you are STILL wrong if you still believe it to be true.
There is a libertarian school of thought that life would be splendid if contracts governed our every interaction, mostly I think it’s the libertarian lawyers who think this. Personally I think it would end quickly in gridlock, tears, and invasion.
They don’t necessarily have anything to do with government. I’ve been in one that didn’t have a damned thing to do with any branch of government. I bought, I moved in, lived there, liked it, moved out, rented it, and we’ve had 4 renters who lived there and liked it.
Different strokes for different folks, but it’s got nothing to do with government per se.....altho some governments have meddled - but that’s the gov problem, not the HOA problem.