What is HOA?

I am not from the USA , but I use Reddit and read stories from the USA

And as my questions suggest what is an HOA? Like I have some vague understanding of it form all the stories that I read about them.

And why the fuck do they hold so much power?

Like they can sell your house ? You can’t buy a house in neighborhood within HOA without signing with them? They can give you fines?

Like I can’t guess enforcing some rules like “ don’t plant toxic plants” or “ all home improvements should be from credible companies” but controlling with the shade of paint that I use for my house?