It could potentially be any of those or any of the connections between your router and the chess.com servers.
Also, if the wifi is shared, the connection can be adversely impacted by other traffic.