I think you are describing about gastric problems that occur at mid night + after awakening.THyroid
problems also lead to gastric problems of having high acid production at night .
Annxiety can also cause more acid production in your stomach
I would recommend to have a review of gastroenterologist for omeprazole
wtc and if possible an endoscopy
Hope this helps