/* Appearance of switches */

switch slider {
    background-image: none;
    background-color: @selected_bg_color;
    border-radius: 3px;
}

switch image {
    background-color: -gtk-win32-color(button, 10);
    border-radius: 1px;
}


/* Menu appearance */

menu separator {
    border-bottom-width: 1px;
    border-bottom-style: solid;
    margin-left: 5px;
    margin-right: 5px;
}

toolbar separator {
    border-bottom-width: 1px;
    border-bottom-style: solid;
    margin: 2px;
}

menuitem arrow {
    min-width: 10px;
    min-height: 10px;
}

menuitem arrow.right {
    -gtk-icon-source: -gtk-icontheme("pan-end-symbolic");
}

menuitem arrow.left {
    -gtk-icon-source: -gtk-icontheme("pan-start-symbolic");
}


/* Add margin to images */

widget>box>image,
toolbar button image {
    margin: 2px;
}


/* Style spinbuttons, GTK style (see discussion in https://gitlab.com/inkscape/inkscape/-/issues/762) */

spinbutton {
    background-image: none;
}

spinbutton button {
    margin-top: 0px;
    margin-bottom: 0px;
    background-size: 20px 100%;
    border-width: 1px;
    border-style: solid;
    background-image: none;
    color: black;
    background-color: white;
    border-color: shade(-gtk-win32-color(button, menu), 0.6);
}

spinbutton button.down {
    margin-right: 15px;
}

spinbutton button:hover {
    background-image: -gtk-win32-theme-part(button, 1, 2);
    background-size: 200% 200%;
    ;
    background-position: center;
    border-color: #add8e6;
}

spinbutton button:disabled {
    background-color: blue;
}

spinbutton entry:not(:disabled) {
    border: 1px solid shade(-gtk-win32-color(button, menu), 0.6);
    background-color: white;
}

spinbutton entry:disabled,
spinbutton button:disabled {
    background-color: -gtk-win32-color(button, 4);
}

spinbutton entry:disabled {
    border-width: 1px;
    border-style: solid;
}


/* Fix height of sliders in F&S dialog */

#InkSpinScale spinbutton {
    padding-top: 10px;
    padding-bottom: 10px;
}


/* Fix colors in LPE dialog */

@define-color theme_fg_color black;
#LPEDialogSelector separator {
    border-color: black;
    border-right: 1px solid;
    margin: 2px;
}


/* Fix hidden palette */

#InkscapePanel #PreviewHolderGrid {
    padding-bottom: 20px;
}


/* Fix right button of horizontal scrollbar */

scrollbar.horizontal:hover button.down:disabled {
    background-image: -gtk-win32-theme-part(scrollbar, 1, 16);
}

scrollbar.horizontal:hover button.down:active {
    background-image: -gtk-win32-theme-part(scrollbar, 1, 15);
}


/* Make room for the scroll bar of the dialog region*/

#DockBox {
    margin-right: 15px;
}

#InkSpinScale spinbutton {
    margin-right: 5px;
}

/* Fix text contrast issues while hovering */

treeview.view:selected {
    color: #000;
}

treeview.view:selected:focus {
    background-color: #a0d4fc;
}

/*fix context-menu decoration */

.popup decoration {
    all: unset;
}

/*add expander arrow*/

expander arrow {
    -gtk-icon-source: -gtk-icontheme("pan-end-symbolic");
}

expander arrow:dir(rtl) {
    -gtk-icon-source: -gtk-icontheme("pan-end-symbolic-rtl");
}

expander arrow:checked {
    -gtk-icon-source: -gtk-icontheme("pan-down-symbolic");
}
