Layered polyelectrolyte complexes: physics of formation and molecular properties