Preheat the oven to 375°F (190°C).
Peel the potatoes and slice them thinly (about 1/8 inch thick) using a knife or mandoline. Place the sliced potatoes in a large mixing bowl and set aside.
In a medium saucepan, melt the butter over medium heat. Once melted, add the flour and whisk continuously for about 2 minutes until combined and bubbly.
Gradually pour in the milk and heavy cream while whisking constantly. Continue to whisk until the mixture thickens (about 5-7 minutes).
Stir in the garlic powder, onion powder, salt, and black pepper. Remove from heat.
In the baking dish, layer half of the sliced potatoes evenly across the bottom. Pour half of the cheese sauce over the potatoes. Sprinkle one cup of cheddar cheese on top.
Repeat with the remaining potatoes and cheese sauce, and top with the remaining cheddar cheese. If desired, add grated Parmesan cheese on top for an extra crispy crust.
Cover the baking dish with aluminum foil and bake in the preheated oven for 30 minutes.
Remove the foil and bake for an additional 15 minutes, or until the top is golden and the potatoes are tender when pierced with a fork.
Let it cool for a few minutes before serving. Garnish with fresh parsley if desired.