I'd make the lid removable so you can get it off again at some point. Bedding it down with 5200 is not a good idea as you found. I'd go with automotive gasket
goop. Run a bead around the flange, put the lid on and screw it down. The bead will form a gasket
that matches the lid and flange and will be airtight but easy enough to remove.
5200 eh? My holding tank is sealed off behind a half inch plywood
lid that was epoxyed in place and screwed down.
I plan on using my skilsaw set to 1/2 depth
and just open up the panel then put in flanges so the old lid can be reused.