Catalyzes the reduction of benzophenanthridines, preferentially sanguinarine, to the corresponding dihydroalkaloids. Involved in detoxifying the phytoalexins produced by plant itself. The sanguinarine produced by intact cells upon elicitation, after excretion and binding to cell wall elements, is rapidly reabsorbed and reduced to the less toxic dihydrosanguinarine. Can work with both NAD(P) or NAD as a hydrogen donor, but at low concentrations, the reaction velocity with NAD(P)H is threefold higher than with NADH. However, chelerythrine shows maximum conversion rates with NADH. The substrate preference is sanguinarine > chelerythrine > chelirubine, macarpine or 10-OH-chelerythrine. No activity with berberine or phenanthridine cations. dihydrosanguinarine + NADP(+) = NADPH + sanguinarine dihydrosanguinarine + NAD(+) = NADH + sanguinarine dihydrochelirubine + NAD(+) = chelirubine + NADH dihydrochelirubine + NADP(+) = chelirubine + NADPH Inhibited by iodoacetamide and irreversibly by its product, dihydrosanguinarine. Optimum pH is 6.5-7.5. Monomer. Belongs to the NAD(P)-dependent epimerase/dehydratase family.