3-4 inches from the water to keep splashing to a minimum & you should have more than adequate par for most anything but extremely high light-demanding SPS on the sandbed. might even be able to do some of the lower light clams on the sand
all the stuff i have read says 24" or less t5 is plenty adequate....but the deeper you go, the less par you will have, which might be beneficial depending on what you want to keep. for instance, most mushrooms & zoas don't like to be blasted w/ the same mid to upper 3-figure par readings that alot of SPS corals thrive in