I still keep trying to figure this out but since macOS 14.5 came out today I wanted to see if that fixed this but it didn't. So I wanted to do a fresh install of 14.5 so I could install one thing and setting at a time and see what helps. This government site I use that I'm having trouble with works in a not so usual way. First you sign into one site, then it has a link on that site that will take you to another government site where you are logged in. So it's logging you in from another site.
One setting in safari that broke this once again but then fixed it was under the Advanced tab of settings. Then under Privacy and a check box for "Use advanced tracking and fingerprinting protection". When I turn that on I get that 'can't find server' message when I go from the first site to the second. When I turn that off the second site loads as expected.
So I guess this setting was blocking that link info between one site and the other. I hope this is the end of it. I would like to keep a lot of these settings on but this site I need to go to relies on links to log into other departments of government. So how it is designed is more what I find is at fault here. I wish I could log into the site I need directly but they removed that a few years ago and force you to log in from this main portal sort of site now. Thank you to everyone who helped and replied.