A rebuild of the motor would cost $2.5-3K, however you can get a JDM H22 from a 4th gen for about $1k+ shipping. But it isn't just a drop in, you'd have to swap some of the sensors from your motor to the new motor(4th gen = OBDI; 5th = OBDII). Still much cheaper.
Just food for though. Take it easy man.