4 inch minimum for regularly sleeping on, can get away with 3 inch for saloon seats that are used occasionally for pilot berths or guests. Get the best quality foam you can afford.
There are still some supplies of non-compliant foam around, so if you are having some bunk mattresses made up, or buying foam to DIY, it's a good idea to check that the foam meets the Furniture and Furnishings (Fire Safety) Regulations 1988 (as amended in 1989 and 1993).
Non-compliant foam will burn rather than smoulder, and will also produce toxic black smoke.
Comfort is a very personal choice: I wouldn't have less than 4", and have just had soggy old cushions refilled with new, firm foam as the covers still had plenty of life.
But don't stint on crew comfort if you want them to return!
Got 4" cushions on current berth and find them too thin. Often sleep in cockpit on 6" cushions that are perfect. Mind you I am over 15 stone so weight might be a factor? On last boat the berths were 5" which was not uncomfortable. Mind you I have piled on a stone since then /forums/images/graemlins/wink.gif