refactored activities with fragments to use common layouts