I would go back to storing login details in the session - storing them in cookies is not secure.
Then you have to find out why your Sessions are timing out. The timeout is set to 20 mins by default, but is configurable in
web.config[
^].
Another possibility is that IIS is shutting down the worker process due to inactivity or recycling it, as it does periodically. You can use a
Session State Server[
^]in this case.