Supreme Court Justice Ruth Bader Ginsburg blamed the polarization of the nation’s judicial confirmation process on a lack of bipartisanship and collegiality in Congress during a public appearance Wednesday in Washington.

She highlighted the philosophy and approach of her former colleague, retired justice Sandra Day O’Connor, who Ginsburg said put “country above party and self-interest” and “worked collaboratively to solve problems.”

Collegiality, Ginsburg said, “means understanding the institution you work for is more important than the egos of the individuals.”

Ginsburg’s remarks came during a discussion Wednesday night at the federal courthouse in the District one day after O’Connor’s announcement that she is withdrawing from public life because she suffers from dementia.

The appearance was a homecoming of sorts for Ginsburg to the court where she served for more than a dozen years before her 1993 elevation to the Supreme Court.

At the event, Ginsburg was interviewed by Judge David S. Tatel, who took her spot on the U.S. Court of Appeals for the D.C. Circuit after President Bill Clinton nominated her to the high court.

Ginsburg did not mention by name the Supreme Court’s newest justice and a former member of the D.C. appeals court, Brett M. Kavanaugh. But she alluded to the bitter process that ended this month with his confirmation by one of the narrowest margins in history. Kavanaugh had the support of only one Democratic senator.

In contrast, Ginsburg noted that the late justice Antonin M. Scalia was confirmed unanimously. The Senate voted 96-3 to confirm Ginsburg.

“What a difference in time that was from what we are witnessing today,” she said.

On the polarization, she said, “to me, the obvious culprit is Congress,” and she lamented the lack of effort to “reach across the aisle.”

The high court’s second female justice and a feminist icon drew a record crowd to the courthouse across the street from the National Gallery of Art. More than an hour before the scheduled 5 p.m. start, long lines formed for the chance to hear her speak.

More than 900 people sought tickets for the appearance at the courthouse’s ceremonial courtroom that holds 330. Six overflow rooms with audio and video were set up to accommodate those who could not get seats in court.

Among those in the courtroom were more than 20 federal judges, including the D.C. Circuit’s Chief Judge Merrick Garland, whose nomination to the Supreme Court by President Obama was stymied by Republicans.

Ginsburg’s status as the “Notorious R.B.G.” has been solidified by a recent documentary about her life and upcoming feature film starring Felicity Jones as “Ruth.”

She was escorted to her seat Wednesday night by her personal physical trainer, Bryant Johnson, who also works as a clerk at the courthouse. In addition to asking Ginsburg about the “art of judging,” Tatel quizzed Ginsburg about her workout regimen.

Twenty push-ups, the justice said, with a break after 10, “so I can breathe.” And she can hold a front plank for 30 seconds.

Ginsburg, who is 85, maintains a busy schedule of public lectures and events that included stops this summer in Israel and Italy, according to the website SCOTUSMap that tracks the justices’ appearances. The outspoken senior justice of the court’s liberal wing has at times drawn criticism for being too loose with her opinions.

Tatel asked Ginsburg Wednesday about her dissent in the Supreme Court’s decision in Shelby County v. Holder, in which she predicted the return of voter suppression.

The ruling freed certain states with a history of discrimination from a Voting Rights Act requirement that they receive federal approval before changing voting rules.

“Sadly, what I predicted,” Ginsburg said, happened “almost immediately.” States quickly enacted voting restrictions, she said, that never would have passed muster under the previous version of the federal law.

Tatel closed by describing Ginsburg as an optimist and asked whether she believes her court colleagues are “open to persuasion” despite predictions of “rough seas ahead” on issues such as workers’ rights and abortion.

Ginsburg pointed to examples of cases — involving the Miranda rights of suspects and the Family Medical Leave Act, in which the late chief justice William Rehnquist had surprised her in voting in favor of outcomes he had previously criticized.

“As long as we live and listen,” she said, “we can learn.”

Robert Barnes contributed to this report.