You have three good options for travel to the Alps before heading to Zurich for your flight. All start from MIlan, which you can reach easily from Florence by train, either Trenitalia or Italo. In order of my perceived scenic value:
1) Train from MIlan to Tirano, changing there to a Swiss train over Bernina Pass. This is the only train route that actually goes over the Alps instead of tunneling under at least part of the way. This route takes you to the Engadine area, with the villages of Pontresina and St. Moritz. If you are starting the day in Florence, I suggest you go only as far as Varenna on Lake Como ( an hour's ride from MIlan) and overnight there. This is a charming lakeside village and a good place for your farewell to Italy.
Next day you continue North to Tirano on the Swiss border, and change there to a Swiss train over the Bernina Pass. This is in my view the most scenic of the so-called scenic train routes in Switzerland. You can ride the named Bernina Express or a regular regional train on the same tracks; the scenery is the same. Head to Pontresina, St. Moritz, or one of the smaller villages close by and overnight there.
Day Three you have some choices. You can take the Glacier Express from St. Moritz to Zermatt and spend 3-4 nights there. Or you can head to Luzern as suggested above. Or you can go to the Berner Oberland (Lauterbrunnen, Mürren, etc.) for the remaining time in the Alps. Zermatt and the Lauterbrunnen area both offer excellent hiking. You only need to leave one night for Zurich, before your flight. Or you can spend your final night in Luzern if your flight home is noon or later.
2) From MIlan, take the train to Luzern, spend a night or two there, and then talk the Golden Pass train route to the Berner Oberland. The fast train to Luzern uses a deep tunnel, but you can choose instead a combination of regional trains that go over the old Gotthard Pass route, with a much shorter tunnel. Or you can move to Lugano and ride the named Gotthard Panorama Express, which uses the higher route and combines it with a boat ride from Flüelen to Luzern.
https://www.sbb.ch/en/leisure-holidays/travel-in-switzerland/panoramareisen/gotthard-panorama-express.html
Note that the Gotthard Panorama Express stops running Oct. 20, and before then does not run on Mondays.
3) From MIlan you can take the fast train through the Simplon tunnel under the Alps to Brig, and change trains there to head either to Zermatt or to the Berner Oberland.