01 - Preheat oven to 375°F. Lightly grease a 9x13-inch baking dish with cooking spray or a small amount of oil.
02 - In a large skillet over medium heat, sauté diced onion in a little oil for 3–4 minutes until softened and translucent.
03 - Add shredded chicken, black beans, corn, cumin, chili powder, garlic powder, salt, and pepper to the skillet. Stir well and cook for 2–3 minutes to combine flavors. Remove from heat.
04 - Spread 1/2 cup enchilada sauce on the bottom of the prepared baking dish. Layer 4 tortillas over the sauce, tearing as needed to cover the bottom completely.
05 - Spread half the chicken mixture over the tortillas. Top with 1/2 cup enchilada sauce and 2/3 cup shredded cheese, distributing evenly.
06 - Repeat with 4 more tortillas, the remaining chicken mixture, 1/2 cup enchilada sauce, and another 2/3 cup cheese.
07 - Top with the final 4 tortillas, remaining enchilada sauce, and the rest of the cheese, ensuring the top is evenly covered.
08 - Cover the baking dish with aluminum foil and bake for 20 minutes to heat through and meld flavors.
09 - Remove foil and bake an additional 10–15 minutes until cheese is bubbling and lightly golden brown.
10 - Let the casserole rest for 10 minutes before slicing into squares. Garnish with cilantro, sour cream, avocado, and lime wedges if desired.