349 without contract is really cheap. Why do you say is not? Is the same as the LG Nexus 5.
The Galaxy S5 costs Samsung something like $246 to manufacturer. It sells for $649 off-contract. Pretty big margins for somebody in that pipeline.
Yeah if you can sell 40+ million a quarter. OTOH if you're sales are more like HTC's you sell your flagship phones to carriers for $400 and break even.