we've just encountered this same phenomenon ourselves, after having lived in our motorhome off and on for over 6 years, much of that time as full-time living - I started noticing dark 'moisture' or a wet spot under the upper end of our bed mattress, quite by accident, when I simply moved the mattress to 'turn it'. Our bed is situated at the rear of the coach, on the back wall. It sits right over the engine, the diesel engine. The bed frame is basically a 'box' that sits over the top of the engine, all plywood as the 'base' for the bed.
I realized fairly quickly that while it may seem initially that it 'must' be a leak, or outside water or moisture intrusion from the base of the bed, or from the engine itself, it's probably none of those. I realized that this happens while we are parked, for LONG periods of time, and certainly not the engine itself. Since water doesn't typically move up, either, it wasn't any leak.
I've found also that the bottom of the mattress is VERY MOIST, and yes, starting to show signs of molding. After some cursory searching on the net, it seems that this is actually not that uncommon with solid foam mattresses. They are not well designed to sit on SOLID surfaces, since there's no way for the mattress to 'breath'. It needs to breath since a solid foam mattress easily traps body heat, sweat, etc and has little way get rid of it since little airflow enters the area. A typical spring mattress has a 'cavity', so this very rarely any problem with those, and they also don't typically lay right on a solid surface.
I tried several things to mitigate not having to replace the mattress, which has worked very well over 6 years - using small 1/2" x 1/2" wood strips to provide some air flow below the mattress, and even places wood paneling over those strips for the mattress to also lay on - either way, the moisture continued.
We recently, just this week, decided that the 'full-time' living with a sold foam mattress, like this Denver mattress that came with the coach, might not be a good choice - RV manufacturers, and mattress manufacturers, don't probably contemplate folks sleeping EVERY NIGHT of the year on these mattresses, on a sold platform, with no air flow - so we went to Sams Club and picked up the Queen 'firm' spring mattress on sale for $299.00 to replace it. It seems to work very well, and is basically as comfortable as the original mattress, along with a 3" foam topper that we had added only a year ago.
I just check the bottom of the new mattress, and the top of the platform, and no worries... no more moisture.
'14 Palazzo 33.3 bunkhouse 34' diesel
KingTailgater2 Dish HD, 100w/5a SOLAR, BlueOx
110,000+mi since '14 - US, Alaska, Canada (also, '14 Gulfstream Amerilite and '07 ForestRiver Rockwood) : )b