A very layered question and am also not sure if it's even the correct thing to ask, but it comes from a place where I have conversations with people regarding let's say China and how they are approaching handling the economy, exports, relations to other countries etc.
People will usually say things like "I understand that they are doing good things regarding solar energy, but they absolutely hate gay people or treat them poorly. Not to mention all the surveillance they do, how much plastic they produce, how poor the working conditions are for the people working in sweat shops. I try and never buy anything made in China if I can help it. They also eat dogs.".
Same with Iran. I would have discussions with people regarding the recent memorandum and how this is a win, people will turn around and go "Yeah, but muslims are religious freaks, they treat women badly, patriarchy is rampant, they hate gay people etc.". There was a similar instance where a gay friend of mine said that people were waving the Palestinian flag at a pride parade and commented "Ironic because they would literally kill us".
Don't even get me started on the whole "their culture is just different" argument or how people hate migrants here.
How can I combat this? Where do I even start with my education and how do you approach people like this? It's almost a daily occurence because I'm surrounded by liberals and reactionaries.