In a recent game a certain city-state became angry with me, and from that point onward I could not enter the territory of the city-state, it showed it in red, just like trying to enter mountains or deep-ocean tiles in early game. This behavior persisted after the city-state returned to neutral state. It was never friends with me. I could enter the territories of other city-states just fine.
I've found this thread on civfanatics where a user encountered the exact same phenomena, but the participants there could not find any explanation.
Is it a bug? If it isn't, why does this happen, how can I prevent it, and can I restore the ability to move through that territory?