Contracts, trust and market environment in farmer-buyer relationships