jquery delay() doesn't delay attr() in the queue - Stack Overflow: "To have the .attr() call affected, you have to add it as a callback to that same queue using .queue(), like this:
$('#myDiv').fadeOut(500)
.delay(600)
.queue(function(next) { $(this).attr('class','myClass'); next(); })
.delay(600)
.fadeIn(500); "
'via Blog this'