I thought that the location extended twelve feet, not eighteen inches, above grade!
Of all the "haz-loc" fluids, gasoline has the widest range of flamability, due to the fact that it is a "soup" of everything from lighter fluid to wax. Even the use of cordless tools is questionable.
An extension cord, passing through a zone without connections, should be OK.
Going to an "extreme," as is typically done in refineries, you would use air-powered tools and non-sparking hand tools. That might be why the refining industry has the best safety record around.