Real Madrid forward Vinicius Jr scored a hat-trick to help the LaLiga champions snap a two-game winless run in all competitions.