Finite elements for thin shells and curved members