Motivation is such a weird thing. It comes and goes like waves and leaves you looking for reasons why it happend.
My advice from a recent bout of lack in motivation is don't beat yourself up during this phase.
Just let it pass. Catch up on your sleep. Relax. You'll be fine.