Welfare Effects of Trade Liberalization with Intra-Industry Reallocations: The Importance of Preferences and Market Failures