Preheat oven to 375°F. Grease a 9×13-inch baking dish.
Bring a large pot of salted water to a boil. Cook pasta until about 2 minutes shy of al dente. Reserve 1/3 cup pasta water, drain, and set aside.
In a large skillet over medium heat, add pepperoni and cook 3–4 minutes to lightly crisp and render some fat. Scoop out half the pepperoni and reserve for topping; leave the rest and drippings in the pan.
Add olive oil if needed, then the ground beef. Season with a pinch of salt and pepper and cook, breaking it up, until browned and no longer pink, 5–6 minutes. Drain excess fat, leaving about 1–2 tablespoons in the pan.
Push beef to the edges. Add onion and bell pepper to the center and sauté until softened, 4–5 minutes. Stir in garlic for 30 seconds. Sprinkle in Italian seasoning and optional crushed fennel; cook 30 seconds to bloom the spices.
Deglaze with red wine (if using), scraping up any browned bits, and let it reduce by about half, 1–2 minutes.
Stir in diced tomatoes, tomato sauce, beef broth, sugar, Worcestershire, red pepper flakes, olives, and the pepperoni remaining in the skillet. Bring to a gentle simmer, cover and cook 8 minutes, then uncover and simmer 4–5 minutes more to thicken. Adjust salt and pepper to taste.
Off the heat, add the drained pasta to the sauce. Splash in a few tablespoons of the reserved pasta water as needed to loosen. Fold in 1/2 cup of the mozzarella so some cheese melts through the pasta.
Transfer to the prepared baking dish. Top evenly with the remaining 1 3/4 cups mozzarella and scatter the reserved crisped pepperoni over the top.
Bake 20–25 minutes, until the edges are bubbling. Broil 1–2 minutes to lightly brown the cheese, watching closely.
Let the casserole rest 5–10 minutes. Finish with Parmesan and parsley or basil before serving hot.