01 - Preheat the oven to 350°F. Lightly grease a 9x13-inch baking dish with butter or nonstick cooking spray.
02 - In a large mixing bowl, combine the ground beef, diced onion, minced garlic, breadcrumbs, egg, milk, ketchup, Worcestershire sauce, kosher salt, and black pepper. Mix gently with your hands until just combined, being careful not to overwork the meat.
03 - Transfer the meat mixture to the prepared baking dish and press it into an even, flat layer across the bottom. Bake for 20 minutes to set the base.
04 - While the meatloaf layer bakes, cook the elbow macaroni according to package directions until just al dente. Drain thoroughly and set aside.
05 - In a medium saucepan over medium heat, melt the butter. Whisk in the flour and cook for 1 minute to form a roux. Slowly pour in the whole milk while whisking constantly. Continue cooking and whisking for 2 to 3 minutes until the sauce thickens enough to coat the back of a spoon.
06 - Remove the saucepan from heat and stir in the shredded cheddar and grated Parmesan cheese, dry mustard powder, smoked paprika, and salt and pepper to taste. Stir until all the cheese has melted and the sauce is smooth. Fold in the drained macaroni until evenly coated.
07 - Remove the par-baked meatloaf layer from the oven. Carefully drain off any excess rendered fat. Spread the macaroni and cheese mixture evenly over the meatloaf base.
08 - In a small bowl, toss together the shredded cheddar cheese, panko breadcrumbs, and melted butter until the crumbs are evenly moistened. Sprinkle the topping uniformly over the macaroni and cheese layer.
09 - Return the assembled casserole to the oven and bake for 30 to 35 minutes until the topping is golden brown and the edges are bubbling. The internal temperature of the meatloaf layer should reach 160°F.
10 - Remove the casserole from the oven and let it rest for 10 minutes before slicing into portions. Serve hot.