Failure characteristics of composite metallic foam core hat-shaped tubular T-joints under static and impact loading