Train services have been delayed after a lorry struck a railway bridge before driving off but the line has since reopened.