Surface-induced enhancement of internal structure in polymers and proteins