fixed initially hidden elements flashing on page load/refresh