The half-life of ranitidine (Zantac) is about 3 hours, so half of it is out of your system in 3 hours, leaving half. Half of the remaining half is out in the next 3 hours leaving 1/4. half of the remaining 1/4 is out in the next 3 hours leaving 1/8, etc.
We normally say that between 6-8 half-lives will leave it undetectable, so that's between 18-24 hours. Why are you concerned about Zantac?
Yes, those box warnings can sometimes be scary. They are required to print anything that ever happened to anyone in testing whether it could conceivably have come from the drug or not. Zantac has an excellent safety record. I've probably taken a pound of them over the years, and I'm still kicking :-)