It's all in the topic. So I need to turn down volume of my music gradually over time until the sound is muted
Develop games in your browser. Powerful, performant & highly capable.
This is the easiest way
http://postimg.org/image/g31xs2n23/
Here's an image of how i'd do it without any external plugins or addons