Gold logs a gain as focus turns to U.S. presidential debate