The US imports <1% of its gasoline: https://www.eia.gov/dnav/pet/pet_sum_snd_a_epm0f_mbbl_a_cur.... (compare ~39M barrels of gasoline imported versus 3,477M barrels produced domestically). The US is in fact a net exporter of refined petroleum products, which means we (on net) buy crude oil to refine it in the country for other countries to use.
And our big refineries are often not in remote areas either.
If you look at the top 5 refineries[1] they're relatively near population centers in the hundreds of thousands to millions of people (ex. Baton Rouge, New Orleans, Houston), and 4 of them are a football field away from residential neighborhoods.