Coupon code on checkout process

I'm creating a shopping cart with the option to use a Coupon for discounts, but some doubts came to my mind. I was reading a study case where the web site had problems with users leaving the page on the checkout process to look for a Coupon, and the order was never finished.

So where should I put my Coupon box? During item selections (img 01) or during checkout (img 02)? Or what other solution/method should I use?

Img 01

enter image description here

Img 02

enter image description here

As far as I know, both situations may have the same issue, since users can leave the page at any moment to look for a new Coupon.

Partial solution (?)

As a complementary design to this I was thinking about using a helper to tell users 'How to get a Coupon?'. Since we only provide Coupons via birthdate, amount of purchases (ex.: after 10 purchases you win 50%) and Facebook promotions, for example. So, after clicking on the ? icon, a dialog box shows up explaning how to get a Coupon.

enter image description here