Saying something racist or homophobic is a bit like taking your eyes off the road for a second when you are driving and clipping a pedestrian.
When you are driving there are no free passes. If you hurt someone, it doesn’t matter how careful you have always been or how slowly you usually drive. Nothing in the past changes the fact that right now, here, you have made a mistake. You didn’t mean to do it, but the damage is done. You can’t claim that you are in a relationship with a pedestrian so you know what hurts them and what doesn’t or that the pedestrian that you ran over last week didn’t mind.
Lots of drivers get angry at the pedestrians they hurt. They get angry that the pedestrian is in their way, or blame pedestrians for being so squishy. Some pedestrians pretend they haven’t been hurt just to avoid this kind of response. It’s even been known for drivers to run over a pedestrian they have clipped because they are so angry. Sometimes I think it is because anger is a much more comfortable emotion than shame. It is easier to blame the pedestrian for getting hurt than to admit that you did something wrong and you are horrified at yourself.
Fortunately, metaphorical car accidents are much more easily solved than real ones. If you can get over the shame and not let it move into anger, you can apologise. You can resolve to do better. You can think about the underlying attitudes that prompted the mistake and start laying down new thought processes.
Having to watch out for pedestrians and cyclists and motorbike riders is annoying when you are driving a nice sports car, but remember you are having a much more comfortable ride. Cars are great, you just have to be careful with them.