If you are running those commands every tick, then the issue is that the title command also plays every tick. And since it does, it does not have enough time for the title to fade in before the next title is played.

You can fix this issue by changing the fade in parameter from:

title @p times 10 30 10

to:

title @p times 1 30 10