We recommend not eating anything 2-3 hours before bed to allow digestion and to prevent any reflux. Ideally, you should be fasting 12 hours between dinner and breakfast.
However, if that is not possible with your schedule, then don't stress about it! Some foods are better than others to help you sleep. The foods that do not act as a diuretic (so you don't have to get up to use the toilet in the night) and also the ones with melatonin and tryptophan which helps trigger sleep inducing chemicals!
Also, calcium and magnesium-rich ingredients help to relax the muscles. Also avoid the energy boosting foods like caffeine and cacao and potential stimulating adaptogens like maca.