Somehow missed this when it was posted
The grey is the cockpit floor/outer skin of the hull. One and the same in a 470. The red keelson with flange sits on top of it, and was originally fastened to the floor with polyester resin.
It may look bad but in reality it's not that serious. No strong forces act on that part of the boat, so you actually don't have to do any
thing to it for the time being. You could mark the end(s) of the crack to see if it develops further with normal use of the boat. It's actually easier to fix the more it's detached
If you consider it psychologically annoying (I would!), then clean the surfaces as well as possible, and re-attach with polyester resin. If you can fit a single layer of fibreglass in between there, fine.
_