Ight, I have a theory.
Mazaki murdered Kazuya because he's the reason his High School crush aka his first love died. Even if she wasn't going to be with Mazaki: the fact Kazuya used her, and she decided to end it all via train pushed him over the edge.