Under VFR, can a pilot fly above a layer of clouds?
Yes, it's legal to operate under VFR without any visual reference to the surface. It's called operating VFR over-the-top, not to be confused with VFR-on-top which is an IFR clearance. Over-the-top is defined in 14 CFR 1.1:


  Over-the-top means above the layer of clouds or other obscuring phenomena forming the ceiling.


There are some exceptions and restrictions, though (this list may not be complete):


Recreational pilots must have visual reference to the surface (14 CFR 61.101)
So must sport pilots (14 CFR 61.315)
So must student pilots (14 CFR 61.89)
If the pilot has a foreign-based private license then all restrictions on the foreign license apply, which could prevent VFR over-the-top (14 CFR 61.75)
Large, turbine or fractionally owned aircraft must be equipped as for IFR (14 CFR 91.507)
If flying for an airline or other operator, their OpSpecs must allow it