From the suggested other questions, I was able to solve it by adding the following line to my code:
System.Net.ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls11 | SecurityProtocolType.Tls12;
This disabled TLS 1.0 from the client, and then the server accepted the connection.
Hope this helps someone else with the same issue. Although the answer is similar to those other questions, it wasn’t obvious from the questions asked that this was the case, so I don’t feel that this is a duplicate.