You booked the ticket at the time when the requirement didn't exist and it's not mandated by law (therefore it's not force majeure), so I'm inclined to believe it counts as denied boarding under 261. But it will be an uphill battle, enforcement of the regulation leaves a lot to be desired and in this case, TAP's definitely gonna try to get out of paying anything, since it's not completely clear case.