It is not advisable to brush you teeth after drinking alcohol, acidic beverages, soda or aerated drinks. This is because acid in the drink is subjected to abrasive action of tooth brushing, can erode the tooth enamel. So to protect your pearly whites against the caustic soda compounds, you can try sipping water or chewing gum to neutralize the saliva to reduce the acidity. You can then brush your teeth.
You should also not brush your teeth immediately if you have a heart-burn, do the same thing: sipping water or chewing gum because the mouth is in an acidic state when you have a heart-burn