/*
* This is the default JabRef theme.
* It will automatically use the OS color scheme, of not overridden inside JavaFX.
*
* Contains all JabRef colors and overrides the JavaFX variables and components with it.
*/

@media (prefers-color-scheme: light) {
    * {
        -jr-theme: #50618F;
        -jr-accent: #A3B7E6;
        -jr-accent-alt: derive(-jr-accent, 15%);

        -jr-row-odd-background: -fx-control-inner-background-alt;
        -jr-row-even-background: -fx-control-inner-background;

        -jr-checked: -jr-theme;
        -jr-selected: -jr-accent;

        -jr-hover: #0002;

        -jr-base: #ebebeb;

        -jr-background-alt: -fx-background;
        -jr-search-background: derive(-jr-base, 80%);

        -jr-menu-background: derive(-jr-base, 46%);
        -jr-menu-forground-active: -fx-dark-text-color;

        -jr-text-foreground: -fx-dark-text-color;
        -jr-toolbar: derive(-jr-base, 46%);

        -jr-icon-background: transparent;
        -jr-icon-background-active: #0001;
        -jr-icon-background-armed: #0002;

        -jr-group-hits-bg: derive(-jr-sidepane-background, -50%);
        -jr-group-hits-fg: ladder(
                -jr-group-hits-bg,
                -fx-light-text-color 45%,
                -fx-dark-text-color 46%,
                -fx-dark-text-color 59%,
                -fx-mid-text-color 60%
        );

        -jr-tooltip-bg: -jr-accent;
        -jr-tooltip-fg: #000;

        -jr-sidepane-background: #DDDDDD;
        -jr-sidepane-header-background: #DDDDDD;

        -jr-scrollbar-thumb: derive(-fx-outer-border, -30%);
        -jr-scrollbar-track: derive(-fx-control-inner-background, -10%);

        -jr-separator: derive(-fx-color, -5%);

        -jr-drag-target: -jr-purple;
        -jr-drag-target-hover: derive(-jr-purple, 80%);

        -jr-inner-bg: derive(-fx-base, 95%);
        -jr-mid-text-color: #404040;
        -jr-light-text-color: #ffffff;
        -jr-outer-border: derive(-fx-color, -5%);

        -jr-blue: #1703fc;
        -jr-purple: #7559C2;
        -jr-green: #10ac84;
        -jr-light-green: #1dd1a1;
        -jr-red: #ee5253;
        -jr-light-red: #ff6b6b;
        -jr-orange: #b55f21;
        -jr-light-orange: #ff9f43;
        -jr-turquoise: #07ada2;
    }
}

@media (prefers-color-scheme: dark) {
    * {
        -jr-theme: #2C9490;

        -jr-accent: #255652;
        -jr-accent-alt: derive(-jr-accent, 15%);

        -jr-row-odd-background: #272b38;
        -jr-row-even-background: #212330;

        -jr-checked: -jr-theme;
        -jr-selected: -jr-accent;

        -jr-hover: #fff1;

        -jr-base: #141824;

        -jr-background-alt: #151924;
        -jr-sidepane-background: #212330;
        -jr-search-background: #2C2E3B;

        -jr-menu-background: #141824;
        -jr-menu-forground-active: derive(-fx-light-text-color, 50%);

        -jr-text-foreground: -fx-light-text-color;
        -jr-toolbar: -jr-menu-background;

        -jr-icon-background: transparent;
        -jr-icon-background-active: -jr-hover;
        -jr-icon-background-armed: #fff2;

        -jr-group-hits-bg: -jr-background-alt;
        -jr-group-hits-fg: -fx-light-text-color;

        -jr-tooltip-bg: -jr-accent;
        -jr-tooltip-fg: derive(-fx-light-text-color, 50%);

        -jr-sidepane-header-background: -jr-background-alt;

        -jr-scrollbar-thumb: -fx-light-text-color;
        -jr-scrollbar-track: derive(-fx-control-inner-background, -90%);

        -jr-separator: #333744;

        -jr-drag-target: -jr-accent;
        -jr-drag-target-hover: -jr-accent;

        -jr-inner-bg: #272b38;
        -jr-mid-text-color: #7d8591;
        -jr-light-text-color: #e5e7ea;
        -jr-outer-border: #424758;

        -jr-blue: #5345ff;
        -jr-purple: #b72486;
        -jr-green: #1cb631;
        -jr-light-green: #28d93c;
        -jr-red: #b71c1f;
        -jr-light-red: #db1d2b;
        -jr-orange: #b77620;
        -jr-light-orange: #b77620;
        -jr-turquoise: #07ada2;
    }
}

/* JavaFX CSS overwrites with our JabRef colors. */
.root {
    -fx-base: -jr-base;

    -fx-background: derive(-fx-base, 26%);

    -fx-control-inner-background: -jr-inner-bg;
    -fx-control-inner-background-alt: derive(-fx-control-inner-background, -5%);

    -fx-dark-text-color: #000;
    -fx-mid-text-color: -jr-mid-text-color;
    -fx-light-text-color: -jr-light-text-color;

    -fx-accent: red;

    -fx-default-button: derive(-jr-accent, 50%);

    -fx-focus-color: -jr-accent;
    -fx-faint-focus-color: derive(-jr-accent, 50%);

    -fx-color: -fx-base;

    -fx-hover-base: derive(-fx-base, 30%);

    -fx-pressed-base: derive(-fx-base, -6%);

    -fx-box-border: derive(-fx-color, -5%);

    -fx-text-box-border: derive(-fx-background, -15%);

    -fx-shadow-highlight-color: rgba(255, 255, 255, 0.07) 70%;

    -fx-outer-border: -jr-outer-border;

    -fx-inner-border: derive(-fx-color, 65%);
    -fx-inner-border-horizontal: derive(-fx-color, 65%);
    -fx-inner-border-bottomup: derive(-fx-color, 65%);

    -fx-body-color: derive(-fx-color, 20%);
    -fx-body-color-bottomup: derive(-fx-color, 20%);
    -fx-body-color-to-right: derive(-fx-color, 20%);

    -fx-mark-color: -fx-text-base-color;
    -fx-mark-highlight-color: transparent;

    -fx-selection-bar: -jr-accent;

    -fx-selection-bar-non-focused: lightgrey;

    -fx-selection-bar-text: -fx-text-background-color;

    -fx-cell-focus-inner-border: derive(-fx-selection-bar, 30%);

    -fx-focused-text-base-color: -fx-light-text-color;
    -fx-focused-mark-color: -fx-focused-text-base-color;
}

/* JavaFX Button-like */
.button,
.toggle-button,
.menu-button,
.choice-box,
.combo-box-base,
.combo-box-base:editable > .arrow-button {
    -fx-background-color: transparent;
    -fx-background-insets: 0;
    -fx-background-radius: 0.25em;
    -fx-text-fill: -fx-text-base-color;
}

/* JavaFX Focus */
.scroll-pane:focused,
.split-pane:focused,
.list-view:focused,
.tree-view:focused,
.table-view:focused,
.tree-table-view:focused {
    -fx-background-color: -fx-control-inner-background;
    -fx-background-insets: 0;
    -fx-background-radius: 0;
}

/* JavaFX Layout container */
.scroll-pane,
.scroll-pane > .viewport,
.split-pane {
    -fx-background-color: transparent;
    -fx-background-insets: 0, 0;
    -fx-padding: 0;
}

/* JavaFX Dialog */
.dialog-pane {
    -fx-font-size: 1em;
    -fx-background-color: -fx-control-inner-background;
}

/* JavaFX TextFlow / HyperLink */
TextFlow > Text {
    -fx-fill: -fx-text-background-color;
}

TextFlow > .hyperlink,
.hyperlink {
    -fx-padding: 0;
    -fx-underline: false;
    -fx-border-style: null;
    -fx-border-color: null;
    -fx-text-fill: -jr-theme;
    -fx-fill: -jr-theme;
}

TextFlow > .hyperlink:visited,
.hyperlink:visited {
    -fx-text-fill: -jr-accent;
    -fx-fill: -jr-accent;
}

.TextFlow > .hyperlink:hover,
.hyperlink:hover {
    -fx-underline: true;
}

TextFlow > .tooltip-text-bold {
    -fx-font-weight: bold;
}

TextFlow > .tooltip-text-italic {
    -fx-font-style: italic;
}

TextFlow > .tooltip-text-monospaced {
    -fx-font-family: monospace;
}

/* JavaFX Tooltip */
.tooltip {
    -fx-background: -jr-tooltip-bg;
    -fx-background-color: -fx-background;
    -fx-opacity: 95%;
    -fx-text-fill: -jr-tooltip-fg;
    -fx-font-size: 1em;
    -fx-show-delay: 300ms;
    -fx-hide-delay: 300ms;
}

.tooltip > TextFlow > Text {
    -fx-font-size: 1em;
}

/* JavaFX Button */
.button {
    -fx-border-color: -fx-outer-border; /* rgba(0, 0, 0, 0.23); */
    -fx-border-width: 0.062em;
    -fx-padding: 0.5em 1em 0.5em 1em;
}

.button:hover {
    -fx-background-color: rgba(0, 0, 0, 0.12);
}

.button:focused,
.button:pressed {
    -fx-background-color: rgba(0, 0, 0, 0.3);
}

.button:default {
    -fx-background-color: -fx-default-button;
}

.button:default:hover {
    -fx-background-color: derive(-fx-default-button, -10%);
}

.button:default:focused,
.button:default:pressed {
    -fx-background-color: derive(-fx-default-button, -20%);
}

/* JavaFX ToggleButton */
.toggle-button:hover,
.toggle-button:selected:hover {
    -fx-background-color: -jr-icon-background-active;
}

.toggle-button:selected {
    -fx-background-color: -jr-icon-background-active;
    -fx-text-fill: -jr-selected;
    -fx-fill: -jr-selected;
}

/* JavaFX CheckBox */
.check-box {
    -fx-label-padding: 0.0em 0.0em 0.0em 0.75em;
    -fx-text-fill: -fx-text-background-color;
}

.check-box > .box {
    -fx-background-color: transparent;
    -fx-background-insets: 0;
    -fx-background-radius: 0;
    -fx-text-fill: -fx-text-base-color;
    -fx-border-color: -fx-outer-border; /* rgba(0, 0, 0, 0.54); */
    -fx-border-width: 0.125em;
    -fx-border-radius: 0.062em;
    -fx-padding: 0.1em 0.1em 0.2em 0.2em;
}

.check-box:selected > .box {
    -fx-background-insets: 0.125em;
    -fx-border-color: -jr-checked;
    -fx-background-color: -jr-checked;
}

.check-box > .box > .mark {
    -fx-padding: 0.2em 0.2em 0.2em 0.2em;
}

.check-box:selected > .box > .mark {
    -fx-background-color: -fx-control-inner-background;
    -fx-shape: "M6.61 11.89L3.5 8.78 2.44 9.84 6.61 14l8.95-8.95L14.5 4z";
    -fx-stroke-width: 5;
}

/* JavaFX RadioButton */
.radio-button > .radio {
    -fx-background-radius: 1.0em; /* large value to make sure this remains circular */
    -fx-padding: 0.35em; /* padding from outside edge to the inner dot */
    -fx-background-color: rgba(0, 0, 0, 0.54), -fx-control-inner-background;
    -fx-background-insets: 0, 0.125em;
    -fx-text-fill: -fx-text-base-color;
}

.radio-button:selected > .radio {
    -fx-background-color: -jr-checked, -fx-background;
}

.radio-button > .radio > .dot {
    -fx-padding: 0.25em; /* radius of the inner dot when selected */
    -fx-background-insets: 0;
}

.radio-button:selected > .radio > .dot {
    -fx-background-color: -jr-checked;
}

/* JavaFX ColorPicker */
.color-picker:armed,
.color-picker:hover,
.color-picker:focused,
.color-picker {
    -fx-background-color: transparent, transparent, transparent, transparent;
    -fx-background-radius: 0;
    -fx-background-insets: 0;
    -fx-effect: null;
}

.color-palette {
    -fx-background-color: -fx-background;
    -fx-background-radius: 0;
    -fx-background-insets: 0;
}

.color-palette-region .button {
    -fx-border-width: 0;
}

.custom-color-dialog {
    -fx-background-color: -fx-control-inner-background;
}

/* JavaFX Progress Indicator */
.progress-indicator {
    -fx-progress-color: -jr-theme;
    -fx-border-width: 0;
    -fx-background-color: -jr-icon-background;
}

.progress-indicator:hover {
    -fx-background-color: -jr-icon-background-active;
}

/* JavaFX MenuBar / MenuItem */
.menu-bar {
    -fx-background-color: -jr-menu-background;
    -fx-background-insets: 0;
    -fx-background-radius: 0;
}

.menu-bar > .container > .menu-button > .label {
    -fx-padding: 0.41777em 0.41777em 0.41777em 0.41777em;
}

.menu-bar > .menu {
    -fx-padding: 0.0em 0.666667em 0.0em 0.666667em;
}

.menu-bar .menu-button {
    -fx-border-color: transparent;
    -fx-border-width: 0;
    -fx-border-radius: 0;
}


.menu-bar > .container {
    -fx-border-width: 0;
}

.menu-bar > .container > .menu-button:hover,
.menu-bar > .container > .menu-button:focused,
.menu-bar > .container > .menu-button:showing {
    -fx-background-color: -jr-hover;
    -fx-background: -jr-hover;
}

.menu-bar > .container > .menu-button:hover > .label,
.menu-bar > .container > .menu-button:focused > .label,
.menu-bar > .container > .menu-button:showing > .label {
    -fx-text-fill: -jr-menu-forground-active;
}

.menu-item {
    -fx-padding: 0.5em 0.41777em 0.5em 0.41777em;
}

.menu-item > .label {
    -fx-text-fill: -jr-text-foreground;
}

.menu-item:focused {
    -fx-text-fill: -jr-hover;
    -fx-background: -jr-hover;
    -fx-background-color: -jr-hover;
}

.menu-item:focused > .label {
    -fx-text-fill: -jr-menu-forground-active;
}

.menu-button > .label {
    -fx-padding: 0 8 0 8;
}

/* JavaFX ContextMenu */
.context-menu {
    -fx-border-color: -fx-outer-border;
    -fx-border-width: 1;
}

/* JavaFX Separator */
.separator:horizontal .line {
    -fx-border-color: -jr-separator;
    -fx-border-width: 0.3;
    -fx-border-insets: 1 15 0 20;
}

.separator:vertical .line {
    -fx-border-color: -jr-separator;
    -fx-border-width: 1;
    -fx-border-insets: 5 15 5 15;
}

/* JavaFX TabPane */
.tab-pane {
    -fx-open-tab-animation: NONE;
    -fx-close-tab-animation: NONE;
}

.tab-pane > .tab-header-area > .headers-region > .tab {
    -fx-background-insets: 0;
    -fx-background-radius: 0;
    -fx-background-color: -jr-background-alt;
    -fx-border-color: -fx-outer-border;
    -fx-border-width: 0.5 0.5 0.5 0.5;
    -fx-padding: 0.3em 0.9em 0.3em 0.9em;
    -fx-pref-height: 3em;
}

.tab-pane > .tab-header-area > .headers-region > .tab .tab-label {
    -fx-text-fill: -fx-mid-text-color;
}

.tab-pane > .tab-header-area > .headers-region > .control-buttons-tab {
    -fx-border-color: -jr-theme;
    -fx-fill: -jr-theme;
    -fx-text-fill: -jr-theme;
}

.tab-pane > .tab-header-area > .headers-region > .tab:selected {
    -fx-background-color: -fx-control-inner-background;
    -fx-border-color: -jr-theme;
    -fx-border-width: 3 0 0 0;
}

.tab-pane > .tab-header-area > .headers-region > .tab:selected .tab-label {
    -fx-fill: -jr-theme;
    -fx-text-fill: -jr-theme;
}

.tab-pane > .tab-header-area > .headers-region > .tab:selected .tab-close-button {
    -fx-background-color: -jr-theme;
}

.tab-pane > .tab-header-area > .headers-region > .tab:selected .glyph-icon {
    -fx-fill: -fx-mid-text-color;
    -fx-text-fill: -fx-mid-text-color;
}

.tab-pane:focused > .tab-header-area > .headers-region > .tab:selected .focus-indicator {
    -fx-border-width: 0;
    -fx-border-insets: 0;
    -fx-border-radius: 0;
}

.tab-pane > .tab-header-area > .headers-region > .tab.drop {
    -fx-border-color: -jr-drag-target;
    -fx-background-color: -jr-drag-target-hover;
    -fx-border-width: 3 1 1 1;
}

.tab-pane > .tab-header-area > .headers-region > .tab.drop .tab-label {
    -fx-fill: -jr-drag-target;
    -fx-text-fill: -jr-drag-target;
}

.tab-pane > .tab-header-area > .tab-header-background {
    -fx-background-color: -jr-background-alt;
}

.tab-pane > .tab-header-area > .headers-region > .tab .glyph-icon {
    -glyph-size: 0.812em;
    -fx-fill: -fx-mid-text-color;
    -fx-text-fill: -fx-mid-text-color;
}

.tab-pane > .tab-header-area > .headers-region > .tab:selected .glyph-icon {
    -fx-fill: -jr-theme;
    -fx-text-fill: -jr-theme;
}

.tab-pane > .tab-header-area {
    -fx-padding: 0 0 0 0;
}

.tab-pane.hide-tab-bar > .tab-header-area {
    -fx-min-height: 0;
    -fx-max-height: 0;
    -fx-pref-height: 0;
    -fx-padding: 0;
}

/* JavaFX SplitPane */
.split-pane > .split-pane-divider {
    -fx-background-color: -jr-sidepane-background;
    -fx-padding: 0 .5 0 .5;
}

/* JavaFX ComboBoxBase / ComboBox / DatePicker */
.combo-box-base {
    -fx-background-color: -fx-outer-border, -fx-control-inner-background;
    -fx-background-insets: 0, 1;
    -fx-background-radius: 0, 0;
}

.combo-box > .list-cell {
    -fx-background-color: -fx-outer-border, -fx-control-inner-background;
    -fx-background-insets: 0, 1 0 1 1;
    -fx-text-fill: -fx-text-base-color;
}

.combo-box-popup > .list-view {
    -fx-background-color: -fx-control-inner-background;
    -fx-background-insets: 0;
    -fx-effect: null;
    -fx-border-width: 1;
    -fx-border-color: -fx-outer-border;
    -fx-padding: 0;
}

.combo-box-popup > .list-view > .virtual-flow > .clipped-container > .sheet > .list-cell {
    -fx-padding: 4 0 4 5;
    /* No alternate highlighting */
    -fx-background: -fx-control-inner-background;
}

.combo-box-popup > .list-view > .placeholder > .label {
    -fx-text-fill: -fx-text-base-color;
}

.combo-box-popup > .list-view > .virtual-flow > .clipped-container > .sheet > .list-cell:filled:hover {
    -fx-background: -fx-selection-bar;
}

.combo-box-popup > .list-view > .virtual-flow > .clipped-container > .sheet > .list-cell:filled:selected,
.combo-box-popup > .list-view > .virtual-flow > .clipped-container > .sheet > .list-cell:filled:selected:hover {
    -fx-background: -fx-selection-bar;
}


.combo-box-base:editable > .text-field,
.date-picker > .text-field {
    -fx-background-color: -fx-outer-border, -fx-control-inner-background;
    -fx-background-insets: 0, 1;
    -fx-background-radius: 0;
}

.combo-box-base:editable:focused > .text-field,
.combo-box-base:editable > .text-field:focused,
.date-picker > .text-field:focused {
    -fx-background-color: -jr-accent, -fx-control-inner-background;
    -fx-background-insets: 0, 2;
    -fx-background-radius: 0;
}

.date-picker:focused > .text-field {
    -fx-background-color: -fx-control-inner-background;
    -fx-background-insets: 0;
}

.date-picker-popup > * > .spinner > .button > .left-arrow,
.date-picker-popup > * > .spinner > .button > .right-arrow {
    -fx-background: -jr-accent;
    -fx-background-color: -fx-background;
}

/* JavaFX Accordion / TitledPane */

.accordion .titled-pane {
    -fx-skin: "org.jabref.gui.util.CustomTitledPaneSkin";
    -fx-arrow-side: right;
}

.accordion .titled-pane .title {
    -fx-background-color: transparent;
    -fx-border-color: transparent;
    -fx-background-insets: 5 5 5 5;
}

.accordion .titled-pane > *.content {
    -fx-background-color: transparent;
    -fx-border-color: transparent;
}

/*
 * Default (left-side) arrow: give it a bit more breathing room
 * before the title text, e.g. the entry editor's collapsible
 * field sections (which aren't hosted in an .accordion).
 */
.titled-pane > .title > .arrow-button {
    -fx-padding: 0.0em 0.4em 0.0em 0.0em;
}

/*
 * The arrow button has some right padding that's added
 * by "modena.css". This simply puts the padding on the
 * left since the arrow is positioned on the right.
 * Only .accordion sets -fx-arrow-side to "right" (see rule
 * above), so this more specific selector only wins there.
 */
.accordion .titled-pane > .title > .arrow-button {
    -fx-padding: 0.0em 0.0em 0.0em 1.0em;
}

/* JavaFX ScrollBar / ScrollPane */
.scroll-bar {
    -fx-background-color: transparent;
    -fx-opacity: 0.3;
}

.scroll-bar:horizontal .track,
.scroll-bar:vertical .track {
    -fx-background-color: -jr-scrollbar-track;
    -fx-opacity: 0.6;
    -fx-background-radius: 0em;
}


.scroll-bar:horizontal .thumb,
.scroll-bar:vertical .thumb {
    -fx-background-color: -jr-scrollbar-thumb;
    -fx-background-insets: 0, 0, 0;
    -fx-background-radius: 0em;
}

.scroll-bar .thumb:hover,
.scroll-bar .thumb:pressed {
    -fx-background-color: derive(-jr-scrollbar-thumb, -30%);
}

/* Hide increment and decrement buttons */
.scroll-bar > .increment-button,
.scroll-bar > .decrement-button {
    -fx-background-color: null;
    -fx-background-radius: 0;
    -fx-background-insets: 0;
    -fx-padding: 0;
}

/* Hide increment and decrement arrows */
.scroll-bar:horizontal > .decrement-button > .decrement-arrow,
.scroll-bar:horizontal > .increment-button > .increment-arrow,
.scroll-bar:vertical > .decrement-button > .decrement-arrow,
.scroll-bar:vertical > .increment-button > .increment-arrow {
    -fx-background-color: null;
    -fx-background-radius: 0;
    -fx-background-insets: 0;
    -fx-shape: null;
    -fx-padding: 0;
}

/* Need some padding since otherwise no scroll-bar is displayed at all */
.scroll-bar:horizontal > .decrement-button > .decrement-arrow {
    -fx-padding: 0.333em 0.167em 0.333em 0.167em; /* 4 2 4 2 */
}

.scroll-bar:vertical > .decrement-button > .decrement-arrow {
    -fx-padding: 0em 0.333em 0em 0.333em; /* 2 4 2 4 */
}

/* Restore full visibility of scrollbars for active elements */
.list-view:hover .scroll-bar,
.tree-view:hover .scroll-bar,
.table-view:hover .scroll-bar,
.tree-table-view:hover .scroll-bar,
.text-input:hover .scroll-bar,
.scroll-pane:hover .scroll-bar {
    -fx-opacity: 1;
}

/* JavaFX TextInput / TextField / TextArea */

.text-input {
    -fx-background-color: -fx-outer-border, -fx-control-inner-background;
    -fx-background-insets: 0, 1;
    -fx-prompt-text-fill: #808080;
}

.text-input:focused {
    -fx-highlight-fill: derive(-jr-accent, 20%);
    -fx-background-color: -jr-accent, -fx-control-inner-background;
    -fx-background-insets: 0, 2;
    -fx-highlight-text-fill: -fx-text-inner-color;
}

.text-area {
    -fx-background-color: -fx-control-inner-background;
}

.text-area .content {
    -fx-background-color: -fx-outer-border, -fx-control-inner-background;
    -fx-background-insets: 0, 1;
    -fx-padding: 0.333333em 0.583em 0.333333em 0.583em;
    -fx-background-radius: 0;
}

.text-area:focused .content {
    -fx-background-color: -jr-accent, -fx-control-inner-background;
    -fx-background-insets: 0, 2;
    -fx-background-radius: 0;
}

.text-area > .scroll-pane > .corner {
    -fx-background-radius: 0 0 0 0;
    -fx-background-color: -fx-background;
}

/* JavaFX ProgressBar */
.progress-bar > .bar {
    -fx-background-color: -jr-theme;
}

.progress-bar:indeterminate > .bar {
    -fx-background-color: -jr-theme;
}

.progress-bar > .track {
    -fx-background-color: -jr-accent;
}

/* JavaFX Cell Container */
.table-view,
.tree-table-view {
    -fx-background-insets: 0;
    -fx-padding: 0;
    -fx-border-width: 0;
    -fx-border-insets: 0;
    -fx-table-cell-border-color: transparent;
}

.table-view:focused,
.tree-table-view:focused {
    -fx-background-insets: 0;
}

.table-cell,
.tree-table-cell {
    -fx-cell-size: 4.0em;
    -fx-padding: 0.5em 1em 0.5em 1em;
    -fx-fill: -fx-text-background-color;
    -fx-text-fill: -fx-text-background-color;
}

.table-row-cell:filled:hover,
.tree-table-row-cell:filled:hover,
.table-row-cell:filled:hover,
.tree-table-row-cell:filled:hover {
    -fx-background-color: -jr-hover;
    -fx-fill: -fx-focused-text-base-color;
    -fx-text-fill: -fx-focused-text-base-color;
}

.tree-table-row-cell:selected > .tree-table-cell > .glyph-icon {
    -fx-fill: white;
    -fx-text-fill: white;
}

.table-view > .virtual-flow > .clipped-container > .sheet > .table-row-cell .table-cell:filled:selected,
.tree-table-view > .virtual-flow > .clipped-container > .sheet > .tree-table-row-cell .tree-table-cell:filled:selected {
    -fx-border-color: transparent;
    -fx-background-insets: 0;
}

/* Selected rows */
.list-view:focused > .virtual-flow > .clipped-container > .sheet > .list-cell:filled:selected,
.tree-view:focused > .virtual-flow > .clipped-container > .sheet > .tree-cell:filled:selected,
.table-view:focused > .virtual-flow > .clipped-container > .sheet > .table-row-cell:filled:selected,
.tree-table-view:focused > .virtual-flow > .clipped-container > .sheet > .tree-table-row-cell:filled:selected,
.table-view:focused > .virtual-flow > .clipped-container > .sheet > .table-row-cell .table-cell:filled:selected,
.tree-table-view:focused > .virtual-flow > .clipped-container > .sheet > .tree-table-row-cell .tree-table-cell:filled:selected {
    -fx-background: -jr-selected;
    -fx-background-color: -jr-selected;
    -fx-table-cell-border-color: transparent;
}

/* Selected when control is not focused
 * In the context of the MainTable: an element is focused at a double click. A single click "just" selects it.
 */
.list-cell:filled:selected,
.tree-cell:filled:selected,
.table-row-cell:filled:selected,
.tree-table-row-cell:filled:selected,
.table-row-cell:filled > .table-cell:filled:selected,
.tree-table-row-cell:filled > .tree-table-cell:filled:selected {
    -fx-background: -jr-selected;
    -fx-background-color: -jr-selected;
    -fx-table-cell-border-color: transparent;
}

.column-header-background {
    -fx-background-color: -fx-control-inner-background;
    -fx-border-width: 0;
}

.column-header-background:hover {
    -fx-background-color: -fx-outer-border;
}

.column-header,
.table-view .filler,
.tree-table-view .filler {
    -fx-background-color: transparent, -fx-control-inner-background;
    -fx-background-insets: 0, 0 0.02em 0 0.02em;
    -fx-font-weight: bold;
    -fx-size: 3em;
    -fx-border-width: 0 0 1 0;
    -fx-border-color: -fx-outer-border;
}

.column-header > .label {
    -fx-padding: 0 1em 0 1em;
    -fx-alignment: center-left;
    -fx-text-fill: -fx-text-inner-color;
}

/* JavaFX WebView */
.web-view {
    -fx-page-fill: -jr-light-text-color;
}
