‘Casting a long shadow’ used as a figurative expression suggests something has a bad/unhappy effect on a situation over a long period. A war can cast a long shadow over a country even when it is over because of the bad consequences. In a literal sense a tall building in the sun will project a long shadow on the ground when the sun is low in the sky.
'Have the edge ’ is often used without a preposition suggesting that someone/something is superior to another person/thing as in: This make of car has the edge when it is question of acceleration. Charlie has the edge when it comes to general knowledge.