I've been having this weird issue with my Nokia Lumia recently. Every time I lock my phone while watching a YouTube video, it turns the audio off and makes it impossible to keep listening to the audio with the locked screen. It used to be different - I was able to lock the screen off and the keep the audio playing. Surprisingly, it happens only with the audio I lists to in my IE App. When listening to podcasts or music in my Podcast App, locking the screen doesn't stop the audio from being played. I haven't done any system updates recently so I have no clue what might have caused that change.