How can I prevent post-exercise muscle cramps in my legs at night?

Muscle cramps. Always warm up before exercising. Also do tip-toe exercises or massage your calves. Get good hydration during and after exercise ( gatorade or alike). Try tonic water or magnesium supplements.
Many possibiities. It could be from over use. There is also a possibility that it could be related to too little iron, magnesium, potassium, or calcium in your blood. One of the most common symptoms of varicose veins and venous incompetence is leg cramps. As much as 65% of the time, people with varicose veins will have leg cramps and exercise can make it worse. If you can see leg veins, see a vein specialist.
N-Acetyl cysteine. You need more glutathione which gets depleted due to exercise with take glutathione or precursor of the same n-acetyl cysteine will prevent cramps.