W4 6011 then A3 1777 at Madrid
Rome → Madrid → Lisbon
Timetable, Madrid time
08:40W4 6011 from Rome at the gate
21:10A3 1777 to Lisbon leaves the gate
12 h 30 apart on the timetable
A3 1777 leaves 12 h 30 after W4 6011 arrives on the timetable: more than half a day, so not a connection we count.