A low-order theory for stability of non-parallel boundary layer flows