FR 7873 then FR 3009 at Madrid
Palermo → Madrid → Milan
Timetable, Madrid time
12:55FR 7873 from Palermo at the gate
09:15FR 3009 to Milan leaves the gate
20 h 20 apart on the timetable, overnight
FR 3009 leaves 20 h 20 after FR 7873 arrives on the timetable: more than half a day, so not a connection we count.