Hi,
I have exactly the same problem on my Moto X (2014, 32GB) running Android 6.0.
The phone stops charging as soon as I unlock the screen.
Also, when I plug the phone in, it starts charging around 4-5 seconds later, instead of immediately (as it used to earlier).
Motorola Support's been of...