I'm sixty, and still haven't figured that out.
I grew up in a rural part of Illinois, very (completely) white, and very Republican. Growing up, I used to think that people were bigoted because they didn't know anyone who didn't look and believe the same as they did. I thought that, once people were exposed to people not like themselves, the bigotry would at least diminish, if not disappear altogether.
Then, in my twenties, I spent three years in Boston, and saw firsthand that that was not the case. The racial bigotry was palpable there, in the early eighties. Interracial couples who were bold enough to walk in the Commons together were chased by white mobs.
From there, I came to St. Louis, and in comparison, St. Louis was refreshing, since the bigotry at least didn't manifest itself physically. (Except, of course, by some of the police.)
Where I grew up in Illinois, one can now see an occasional black person, and a few immigrants. However, in the county where I grew up, there are still no Democrats on the ticket for most public offices, and the bigotry is still there. People believe pretty much every thing that is said on right wing radio, and every right wing meme that floats around the internet. It's amazing.