An agent for treating keratinous fibers, in particular human hair, containing in a cosmetically acceptable carrier (a) at least one amphiphilic, cationic polymer, comprising in each case at least one structural unit of formulae (I) to (IV), wherein R1, R2, R3, R4, R5, R6, R7, X1, X2, A1, and A2 are defined as in the 1st claim, and (b) at least one copolymer comprising at least one structural unit of formula (A1), at least one structural unit of formula (A2), and at least one structural unit of formula (A3), wherein R1, R3, and R7 independently of each other stand for a hydrogen atom or a methyl group, R2 stands for a (C1 to C4) alkyl group, R4 stands for a hydroxy (C2 to C6) alkyl group. Additionally, use of the agent for temporary shaping of hair and for hair conditioning, in particular as an aerosol hairspray or aerosol hair mousse.