Two and three-layer models of stratified flows in hydrostatic balance are studied. For the former, nonlinear transformations are found that map [baroclinic] two-layer flows with either rigid top and bottom lids or vertical periodicity, into [barotropic] single-layer, shallow water free-surface flows. We have previously shown that two-layer flows with Richardson number greater than one are nonlinearly stable, in the following sense: when the system is well-posed at a given time, it remains well-posed through the nonlinear evolution. Here, we give a general necessary condition for the nonlinear stability of systems of mixed type. For three-layer flows with vertical periodicity, the domains of local stability are determined and the system is shown not to satisfy the necessary condition for nonlinear stability. This means that there are wave-motions that evolve into shear unstable flows.