Generalized beam theory for thin-walled beams with curvilinear open cross-sections