Yes, 2N3904 is fine. I understand the reason to move the resistor, but I think that is a bad idea. You could make it work by splitting the resistor. In the best case, that will give an additional 5V headroom, but you'll make the circuit more dependant on other factors (arduino supply voltage and output high dropout, choice of divider total resistance, ...). And 3904 isn't more expensive than 2222. My advice is: keep it simple.