Milan - 2 nights
Lucca - 2 nights (Tuscany country side)
Porto Venere (Cinque Terre area) - 4 nights
Florence - 4 nights
Sorrento - 2 nights
Amalfi - 3 nights
Rome - 5 nights
I like all the places you have chosen but would suggest a different allocation of nights.
Milan 2
Lucca 2- no day trips from here
Porto Venere- 3 nights (give night to Sorrento)
Florence 4 nights with 1 or 2 day trips, depending n how much you want to see/do IN Florence
Sorrento- 3 nights- it's going to take you most of the day to get here with at least 2 changes.
On arrival to Sorento just enjoy the town
Next 2 days you have your choice of 2 day trips Pompeii, Naples or Capri
Amalfi 3 nights- see Ravello, Positano from here
That utilizes the transportation hubs in both Sorrento and Amalfi and means less travel back and forth from either of your locations in this area. And eliminates one of your 2 night stays.
Rome 5- you can never have enough time in Rome- and your first day is half gone by the time you get there.
(From Amalfi take ferry to Salerno- great views along there!- walk about 10 min up to train station and catch a direct fast train to Rome)