Whether or not the cockpit door is opened for any length of time appears to be one of sensitivity and nationality. No American carrier will have significant cockpit door opening. If crew needs the lav, the front is usually blocked by a galley cart and FAs. Same when refreshments are bought forward. I was on a recent AeroMexico 757 ATL-MEX where the door was opened for many minutes and captain spent significant time in the front galley. This would never, IMO, happen on a US carrier after 9/11.