Cristiano Ronaldo scored a stunning winner before being sent off for a dive in Real Madrid's Supercopa de Espana first-leg triumph over Barcelona.
The Portugal star came off the bench to blast home the third goal of the visitors' 3-1 win at Camp Nou but earned a second yellow card for going to ground in the penalty area two minutes later, having earlier been booked for taking his shirt off in celebration.
Zinedine Zidane's side took the lead early in the second half through an own goal from Gerard Pique but Barca levelled thanks to Lionel Messi's penalty, which was won in controversial fashion by Luis Suarez.
Ronaldo put Madrid back ahead with a spectacular strike but was dismissed within two minutes of that goal and risked further punishment when he pushed the referee in the back before departing the field.
Barca pushed for a second equaliser late on but were undone by Marco Asensio's brilliant strike on the break, meaning they have it all to do at the Santiago Bernabeu next Wednesday in the first Supercopa tie between these sides since 2012.
-- LaLiga (@LaLiga) August 13, 2017
Barca had the upper hand in the early exchanges, with Suarez testing Keylor Navas from just inside the area and Dani Carvajal was perhaps fortunate to escape being penalised for handball when blocking Gerard Deulofeu's cross.
Neither side looked prepared to commit to the attack in a rather tepid first half and Gareth Bale saw the clearest chance saved by Marc-Andre ter Stegen from inside the penalty area following Isco's jinking run.
Pique - who scored the winner when these teams met in the International Champions Cup last month - had been booked for attempting to punch the ball towards goal following a corner in the first half and it was another moment of ignominy for the centre-back that gave Madrid the lead five minutes after the break.
1 - Gerard Pique is the first Barcelona player to score an own goal in El Clasico in the 21st century (all competitions). Misfortune. pic.twitter.com/qExt3f5Ewa-- OptaJose (@OptaJose) August 13, 2017
Marcelo ran onto Isco's pass down the left and sent a low cross into box, and Pique steered the ball into his own net on the slide as he attempted to clear it for a corner.
Barca suddenly looked unsteady at the back and it took a brilliant sliding block from Jordi Alba to prevent Carvajal from making it 2-0 after some brilliant work from Karim Benzema.
Valverde introduced Denis Suarez from the bench and the move almost paid off immediately, the midfielder's corner headed goalwards by Luis Suarez only for Navas to make a fine one-handed save.
Ronaldo, on in place of Benzema, had a shot blocked behind by Pique and the assistant referee's raised flag denied him when he did find the net following Casemiro's throughball.
The 32-year-old took full advantage of his next chance, though, playing a one-two with Isco to set up a counter-attack before cutting inside Pique and firing into the top-right corner from 20 yards.
Ronaldo was booked for removing his shirt and then stunningly dismissed after being adjudged to have gone to ground too easily in the area under pressure from Samuel Umtiti.
But the incident could not prevent Madrid seizing control of the tie, Asensio rifling home an unstoppable third from the edge of the area to get watching president Florentino Perez onto his feet.