01 - In a large heavy-bottomed pot, melt unsalted butter over medium-low heat. Add sliced onions and a pinch of salt. Stir frequently until onions are deeply caramelized and golden brown, about 25 to 30 minutes.
02 - Add minced garlic and chopped celery; sauté for 2 minutes until fragrant and softened.
03 - Stir in sliced mushrooms, cooking until tender and lightly browned, about 8 minutes.
04 - Pour in dry white wine (if using), scraping any browned bits from the bottom. Let the wine reduce by half, about 2 minutes.
05 - Add vegetable broth, fresh thyme, and bay leaf. Bring to a gentle simmer and cook uncovered for 10 minutes, allowing flavors to meld.
06 - Remove bay leaf. Lower heat and stir in heavy cream. Simmer for 2 to 3 minutes without boiling. Taste and adjust with salt and freshly ground black pepper.
07 - If desired, ladle soup into oven-safe bowls, top each with a toasted baguette slice, sprinkle with grated Gruyère, and broil until cheese is bubbly and golden.
08 - Sprinkle with chopped parsley before serving.