I am having the exact same problem with a fresh install of 3.1.1. I'm on an IIS 10 / Windows 10 machine. My normal websites run fine, so this is definitely related to Moodle or PHP. I've tried editing everything related to fastcgi that I can find, I've tried editing the web.config file. I've tried clearing the Moodledata cache. And, I've used multiple machines and multiple browsers.
The closest I came to a smile was when I cleared the history in Chrome and the login screen came up... but hope faded when I entered in my credentials and it said that my session had timed out and the address included a session=2. I haven't been able to reproduce that since. ;-(