Preheat & Prep: Heat your oven to 375°F (190°C). Grease a medium baking dish (9x9 or similar) with butter.
Make the Sauce: In a saucepan over medium heat, melt the butter and sauté the garlic for 1 minute until fragrant. Whisk in the flour and cook for 1-2 minutes until bubbling. Slowly pour in the milk/cream while whisking constantly to avoid lumps. Simmer for 1 minute until thickened. Remove from heat; stir in 1 cup of Gruyère and all the Parmesan until smooth.
Layer: Arrange a layer of slightly overlapping zucchini slices in the dish. Season with salt and pepper. Pour over one-third of the cheese sauce. Sprinkle with a bit of Gruyère and herbs. Repeat for 2–3 layers until all zucchini and sauce are used.
Bake: Top with the remaining Gruyère and herbs. Bake for 25–30 minutes until the zucchini is tender and the top is golden brown and bubbly.
Serve: Let the dish rest for 5 minutes before serving to allow the sauce to thicken and set.