ebay doesn't normally have pop up ads so it is likely some type of malware that was picked up on your browser. A few things to try...
Clear your browser history and cache
Do a virus scan
Do a malware scan with a product such as malwarebytes
One of the users here often recommends a program called CCleaner