I am speculating!
What is a good night's sleep?
Is it how long you are asleep? Is it how you perceive your night's sleep as it just seemed to be?
It is possible that your sleep patterns are erratic and the quality is lacking in some element resulting in the following bad day,
The attachments are of my personal sleep pattern from last night that show the various aspects of sleep that are important for the overall effects of a good night's sleep.
I have been using the Huawei Health app (that you can download for free) for a few years and measures my sleep automatically while wearing my smart watch that syncs with my tablet to show the previous nights sleep details. Before I was using the App, I had no idea about the importance of quality of sleep, believing naively that total sleep time was the main factor.
I can recommend the APP as it also monitors all my exercise and other important aspects of my health, every hour of the day and night.
Hope you can find some benefit from this post!!