What part of GTK3 theme determines Calc row/column header border color?

As in this question, I would like to change the appearance of the row and column headers in Calc.

I am using Ubuntu with Gnome and observed that changing the “Legacy Applications” theme in Tweaks changes the styling of the headers. Thus, my question is which part of the theme is used to style the headers. In other words, which GTK3 classes would I need to change the CSS styling of to change the appearance of the headers? I am interested mostly in the dividers/borders between header boxes.

I understand that this will change the appearance of UI elements outside Calc, so I will be careful. I also understand that the eventual use of libadwaita may obsolete any modifications I make. Any guidance on GTK4 classes and libadwaita would be welcome as well.

Purpose of question

I think the heavy borders I get in Gnome distract from the content (e.g. row numbers) and are also just not pretty:
CalcHeaderBorder

System

Ubuntu 22.04
Gnome Shell 42.2
Theme: default

About LO

Version: 7.3.4.2 / LibreOffice Community
Build ID: 30(Build:2)
CPU threads: 8; OS: Linux 5.15; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
Ubuntu package version: 1:7.3.4~rc2-0ubuntu0.22.04.1~lo1
Calc: threaded

image

Add this to the end of your theme. Use “red” as color for testing.

/home/YOURUSER/.themes/YOURTHEME/gtk-3.0/gtk.css

/* libreoffice  */
/* lines */
.view:disabled {
  color: #eeeeee;
}

/* numbers/letters */
.background {
  color: #4d4d4c;
}

If you don’t want these modificatiosn to be “global”, clone your theme and add the modifications then GTK_THEME='custom theme name' libreoffice --calc