while i agree that both situations can be considered bookable fouls (and that it indeed was stupid of the player), you can't just ignore the context while evaluating the situation:
- first of all, those were his only two offences.
- secondly, it's very early in the match and sending a player off obviously is a very impactful decision - the ref easily could have issued a stern last warning, which is the usual (and correct) way to treat these kind of situations.
- thirdly, the ref seems to have different standards for different players, otherwise bellerin should have been booked as well.
if you consider all this (which really should not be difficult for a veteran football fan) and not just look at it with a simplistic 'possible yellow, so he can't complain' attitude, you'll inevitably come to the conclusion that it was very harsh and unlucky for atlético.