If you have a leak in the overhead it's common for water to pool in the empty spaces below the bed (including the nose which can hold a significant amt of water).  Water will try and leave that area via the screw holes of the trim piece - your brown water is likely from rusty screws and maybe disintegrating wood/insulation. 
I would remove the trim piece and let the water drain.  Your going to have to find the source of the leak as well as assess the damage that the water has done.  A pressure test of the rig should identify the source of the leak(s) - accessing the damage will require some dismantling of the cabover.  If your lucky (I was) your damage will be minimal and limited to replacing some luan and insulation - some have to do a major rebuild of the area.
Good luck.