Spin it any way you like, but if you hit the car in front of you the fault is 100% your own because you failed to control your vehicle, were following too closely, or travelling too fast for conditions. Unless a car fell from the sky and landed right in front of your bumper, you should have been able to stop your car without hitting the car in front of you, had you been driving properly.

The city is not responsible, though you are free to make a claim and see how that goes.