Motion Sensors for bathroom music

Hi, I’m trying to figure out the best way to automatically start music playback while in the bathroom. While I usually have a iOS device with me, I don’t usually carry it in when showering, etc.

I was thinking the best possible solution would be to have a motion sensor in the bathroom that connected with roomie, and some kind of way to set it so that if in there for more than 3 minutes, music (via spotify, pandora, radio or itunes - ideally a pre-determined bathroom playlist) would start up. Ideally, the motion sensor would also be able to turn off playback when room has been empty for x minutes. Is there a motion sensor that connects with roomie and commands that can support this use case? I have been reading about the iBeacons, but don’t think that will work because as I mentioned above, I usually don’t carry a phone into the bathroom.