I'm trying to understand the route taken by the drain colored red in the images below. This drain starts nearby in the my garage where it is attached to a sink using this drain pump. What is strange is it seems to intentionally connect to the sewer after the U-trap / cleanout which all other drains in the house flow through. I say "intentionally" because the pipe could have taken the route in blue where it would use less pipe. Maybe it is related to sink drain pump?
I'm putting shelves in this closet and would like to move this drain to take either the blue route or the orange route to make it less in the way.
I'm leaning toward the orange since that keeps it most similar to what exists, but I dont understand why the blue route was not taken all along.