It can't be as simple as an expired cookie. I occasionally go weeks without using this computer or my iPad. I have only had login issues the few weeks when the forum was experiencing technical difficulties. I don't think that was a cookie problem.
Also "expired cookie" doesn't fit the symptom very well. The cookie would have to expire between using the first tab and opening the second tab. Something like that may happen once or twice in lifetime.
I do have 'Accept 3rd-party cookies' turned off and 'Delete all cookies on firefox close' selected.
I'm using Firefox as it comes from Mozilla (I don't even know where those settings can be changed). Maybe it's a problem with Firefox.