My model about not getting enough sleep


Sometimes, especially before my period, I wake up during the night and can’t go back to sleep. Sometimes, I am up for 3 to 4 hours in the middle of the night, which can go on for a week.
I understand that not getting enough sleep causes physical tiredness, but my thoughts around it worsen it.

C: I woke up at 1:00 am, up until 4:00 am, went back to sleep, and woke up at 5:30 am.
T: I didn’t get enough sleep
T: I am going to be tired
T: not getting enough sleep sucks
T: I think I have a headache
T: I am not hungry, but eating makes me feel better when I am tired, and I don’t want to mess up my protocol
F: Powerless
A: I eat to feel better, I canceled my plan with my friend, I didn’t do all the things I wanted to do, I looked for sleep aid, I took some sleep aid, I regret

My question is, what is the best way to do it? To not make the experience worse than what it actually is.