Extended thermodynamics in the early universe