Turns out the culprit was the Brave browser. Reinstalling VS set Chrome as default browser, and it started working again. When I chose Brave (my actual default browser) for debugging, the same problem came back.