Heat the oven to 375°F. Grease a 9×13-inch baking dish.
Cook the ziti in well-salted boiling water for 2 minutes LESS than the package directions. Drain (don't rinse — the starch helps the sauce cling).
While the pasta cooks, brown the sausage in a large skillet over medium-high heat, breaking it into crumbles, 6 to 8 minutes. Add the onion and cook 3 minutes, then the garlic for 30 seconds. Drain excess fat.
Stir the marinara and Italian seasoning into the sausage. Simmer 5 minutes so the flavors marry.
In a bowl, mix the ricotta, egg, half the Parmesan, 1 cup of the mozzarella, 1/2 tsp salt, and 1/4 tsp pepper.
Combine the drained pasta with the sausage sauce. Spread half in the baking dish, dollop over the ricotta mixture and spread gently, then add the remaining pasta mixture.
Top with the remaining mozzarella and Parmesan. Cover with sprayed foil and bake 20 minutes, then uncover and bake 12 to 15 minutes more until bubbly and golden.
Rest 10 minutes before serving. Top with basil.