A late federal judge lionized for championing liberal causes from abortion rights to his support for same sex-marriage has been accused of sexual harassment by a former law clerk, highlighting what some experts call a pervasive problem within the chambers of America’s most powerful judges.

Stephen Reinhardt, a former federal judge from California who died in 2018 and was known for decisions hailed by the left – and often overturned by the US supreme court – was accused by a former clerk, Olivia Warren, of sexual harassment that began from the moment she entered his chambers.

In sworn testimony in a congressional hearing, Warren described how the judge regularly commented on women’s appearance. She described how he “routinely and frequently” made disparaging remarks about her physical appearance and views about feminism, and commented on her sexual relationship with her husband, which he questioned because he said he could not imagine her to be attractive to any man. He questioned whether her husband was gay and whether they had sex, she said.

“Judge Reinhardt made these comments to me when we were alone, and also in front of other members of chambers at times,” Warren said.

The Harvard Law graduate testified at a hearing to examine the protection of judicial employees from sexual harassment. The hearing follows the passage of new codes of conduct that call on judges and other employees to report misconduct, and for anyone reporting misconduct to be protected from retaliation, though Warren and others have said the changes do not go far enough.

Efforts to address the issue come years after another powerful judge, Alex Kozinski, who served as a mentor to Justice Brett Kavanaugh, was accused of harassing a number of his own female law clerks, including allegations that he showed them pornography, made lewd remarks and touched them. Kozinski resigned after allegations about his behavior became public in 2017, and apologized for making his clerks feel “uncomfortable”.

Warren’s testimony on Thursday shed more light on how far law students from the most elite universities in the US believe they must go in order to win prestigious clerkships with senior judges.

The clerkships, which are usually obtained with support and encouragement from the university, are seen as a path to lucrative careers and seen as necessary for any law student who wants to become a judge or sit on the supreme court.

In testimony, Warren described how her mentor at Harvard Law had warned her never to let Judge Reinhardt down, and emphasized how the judge liked to “keep things fun”.

“None of this prepared me for the profane atmosphere I entered when I began my clerkship,” Warren said. On her first day, Warren noticed a chart that had been drawn to explain a concept to the judge, which appeared to resemble breasts with nipples.

She recalled being told with a laugh by a colleague that the judge had added the nipples himself.

“Two days later … as he was leaving my office, [Reinhardt] asked me if I had noticed the drawing and whether I liked it,” she said in written testimony. “He asked me a question about whether or not it was ‘accurate’. Based on his tone and demeanor, I understood his question to be asking whether or not the drawing looked like my breasts.”

Warren said she first attempted to formally report the harassment on 1 August 2018 at a meeting of several members of Harvard Law School. She said she described feeling misled by the “institutional push to clerk” and that there were systematic reasons why students were rarely informed about negative experiences.

“Nobody has communicated with me since that meeting what, if any, steps Harvard has taken to address the issues,” she said.

Harvard Law School did not respond to a request for comment.

Reinhardt was married to Ramona Ripston, a former executive director of the ACLU of Southern California, who died in November 2018, a few months after the judge.

At the time of his death, Reinhardt was hailed as a champion of justice by many former clerks, including Ben Wizner, an attorney for Edward Snowden and a top official at the ACLU. He was described as a man who was often a solitary voice in dissent, especially on cases involving the death penalty.

Writing at the time of Reinhardt’s death, Wizner recalled how the judge “pulled no punches when talking to anyone” and how a “thick skin” could be a valuable attribute in his chambers.

“While we sometimes joke that clerking for Judge Reinhardt was the price one paid for the lifelong privilege of being his former clerk, the truth is that we were all in awe of his brilliance, his drive, and his commitment to using the law to protect the powerless,” Wizner wrote.

Wizner was not immediately available to comment on Warren’s testimony.

A press officer for US courts issued a statement following the testimony.

It said: “No Judiciary employee should suffer the kind of harassment described by former law clerk Olivia Warren today. We are deeply concerned about the new information we have learned through Ms Warren’s statement to the House judiciary subcommittee this morning, and we take her statement very seriously. We are committed to addressing this new information and continuing to refine our processes and procedures for protecting our employees and addressing misconduct.”