Preheat your oven to 375 degrees Fahrenheit. Generously grease a 9 by 13 inch baking dish with butter, ensuring the sides are well coated to prevent the cheese from sticking during the long bake time.
Using a mandoline or a very sharp chef knife, slice all the root vegetables into uniform rounds about one eighth of an inch thick. Consistency is key here to ensure that all the vegetables soften at the same rate in the oven.
In a medium saucepan over low heat, combine the heavy cream, minced garlic, thyme, rosemary, nutmeg, vegetable broth, and apple cider vinegar. Let the mixture simmer gently for about five minutes to infuse the flavors, but do not let it reach a rolling boil. Season with salt and pepper.
Arrange a layer of the sliced vegetables in the prepared baking dish, slightly overlapping them. Sprinkle a portion of the Gruyere and cheddar cheese over the layer. Repeat this process until all vegetables are used, then pour the warm cream mixture evenly over the top, allowing it to seep into the layers.
Cover the dish tightly with aluminum foil. Place it in the oven and bake for 45 minutes. Covering the dish is essential to steam the dense root vegetables so they become tender without the top burning.
Remove the foil and sprinkle any remaining cheese over the top. Return the dish to the oven for another 15 to 20 minutes, or until the sauce is bubbling and the top is a deep golden brown. For an extra crispy finish, you can place it under the broiler for the final two minutes.