Try to deactivate your Windows Firewall, had this problem before, the problem was that Windows didn't show me any warning to let my steam's games have access outside my internet, so sometime, I was able to play, other times I wasn't. It seems Windows had fun to cut my connection sometime, then opened it again, then cut it again, etc, etc.