Portugal became the first country to win the UEFA Nations League twice after they came from behind in each half to draw 2-2 with Spain before dethroning their Iberian neighbours 5-3 on penalties.