I did this last year....same flight to MAD. My flight to IBZ was on Iberia. I had plenty of time....and since Iberia was not affiliated with CO, I still had time to get my baggage, go through immigration and customs, and do some shopping. You should be fine.