legacy/fx109-127/css/buttons/custom_backforward_connected_to_location_bar.css
/* Firefox userChrome.css tweaks ********************************************************/
/* Github: https://github.com/aris-t2/customcssforfx ************************************/
/****************************************************************************************/


#main-window .megabar {
  z-index: 3 !important;
}

#main-window #back-button {
  z-index: 4 !important;
  position: relative !important;
}

#main-window #nav-bar #forward-button {
  --toolbarbutton-border-radius: 0px !important;
}

#main-window #navigator-toolbox #nav-bar #nav-bar-customization-target #back-button > .toolbarbutton-icon,
#main-window #nav-bar #back-button > .toolbarbutton-icon {
  width: 100% !important;
  height: 100% !important;
  border-radius: 10000px !important;
  padding: 12px !important; 
  background-color: #e6e6e6 /*#f9f9fa*/ !important;
}

#main-window[uidensity=compact] #navigator-toolbox #nav-bar #nav-bar-customization-target #back-button > .toolbarbutton-icon,
#main-window[uidensity=compact] #nav-bar #back-button > .toolbarbutton-icon {
  padding: 10px !important; 
}

#main-window[uidensity=touch] #navigator-toolbox #nav-bar #nav-bar-customization-target #back-button > .toolbarbutton-icon,
#main-window[uidensity=touch] #nav-bar #back-button > .toolbarbutton-icon {
  padding: 14px !important;
}

#main-window #navigator-toolbox #nav-bar #nav-bar-customization-target #forward-button .toolbarbutton-icon,
#main-window #nav-bar #forward-button > .toolbarbutton-icon {
  width: 100% !important;
  /*height: 100% !important;*/
  padding: 8px 8px 8px 14px !important;
}


#main-window[uidensity=compact] #navigator-toolbox #nav-bar #nav-bar-customization-target #forward-button .toolbarbutton-icon,
#main-window[uidensity=compact] #nav-bar #forward-button > .toolbarbutton-icon {
  padding: 6px 6px 6px 12px !important; 
}

#main-window[uidensity=touch] #navigator-toolbox #nav-bar #nav-bar-customization-target #forward-button > .toolbarbutton-icon,
#main-window[uidensity=touch] #nav-bar #forward-button > .toolbarbutton-icon {
  padding: 9px 9px 9px 16px !important; 
}

#main-window:not([customizing=true]) #nav-bar #forward-button[disabled] {
  /*visibility: collapse !important;*/
  opacity: 0 !important;
  z-index: -100000 !important;
}

#main-window #nav-bar #forward-button[disabled] + #urlbar-container {
  margin-inline-start: -55px !important;
}

#main-window[uidensity=touch] #nav-bar #forward-button[disabled] + #urlbar-container {
  margin-inline-start: -60px !important;
}


#main-window #nav-bar #forward-button[disabled] + #urlbar-container #urlbar {
  padding-inline-start: 10px !important;
}

#main-window #nav-bar #back-button + #forward-button:not([disabled]) {
  margin-inline-start: -16px !important;
}

#main-window #nav-bar #forward-button:not([disabled]) + #urlbar-container {
  margin-inline-start: -2.5px !important;
}
#main-window[uidensity=compact] #nav-bar #forward-button:not([disabled]) + #urlbar-container {
  margin-inline-start: -3.5px !important;
}

#permissions-granted-icon,
.blocked-permission-icon,
#notification-popup-box>image,
#notification-popup-box>stack {
  margin-inline-start: 8px !important;
}
/*
#main-window #nav-bar #identity-box {
  padding-inline-end: 2px !important;
}
*/
#main-window #nav-bar #back-button .toolbarbutton-icon{
  opacity: 1 !important;
}

/* fix rounded urlbar when connected*/
#main-window #nav-bar #forward-button:not([disabled]) + #urlbar-container #urlbar-background {
  border-top-left-radius: 0px !important;
  border-bottom-left-radius: 0px !important;
}

/* override classic toolbar buttons code */
#main-window:not([customizing]) #nav-bar #back-button:not(#PlacesChevron)[disabled=true] > .toolbarbutton-icon,
#main-window:not([customizing]) #nav-bar #back-button:not(#PlacesChevron)[disabled=true]:is([open],[checked],:hover:active,:active) > .toolbarbutton-icon {
  background: #efefef !important; /* has to be solid or forward buttons left side will be partly visible */
}

@media (-moz-toolbar-prefers-color-scheme: dark), (prefers-color-scheme: dark) {

	#main-window #navigator-toolbox #nav-bar #nav-bar-customization-target #back-button > .toolbarbutton-icon,
	#main-window #nav-bar #back-button > .toolbarbutton-icon {
	  background-color: #383740 !important;
	}

	#main-window:not([customizing]) #nav-bar #back-button:not(#PlacesChevron)[disabled=true] > .toolbarbutton-icon,
	#main-window:not([customizing]) #nav-bar #back-button:not(#PlacesChevron)[disabled=true]:is([open],[checked],:hover:active,:active) > .toolbarbutton-icon {
	  background: #383740 !important; /* has to be solid or forward buttons left side will be partly visible */
	}

}
