@namespace url(http://www.mozilla.org/keymaster/gatekeeper/there.is.only.xul);

/* Smart Stop/Reload/Go Button
	Version: 4
	Licence: CC0 1.0 Universal (or later); http://creativecommons.org/publicdomain/zero/1.0/

   Requirements for this style:
	0. This style, installed in Stylish
	1. ‘Smart Stop/Reload’ extension: https://addons.mozilla.org/en-US/firefox/addon/7401
	2. ‘userChromeJS’ extension: http://userchromejs.mozdev.org/
	3. ‘Smart Stop-Reload-Go Button.uc.js’ script for userChrome.js: http://forums.mozillazine.org/viewtopic.php?p=6326595#p6326595

    Notes
	• If the Stop and Reload buttons disappear for some reason, add them back to the toolbar and restart Firefox (or create a new window).
	• If the height of the button is off for your GTK+ theme, tweak the values at the end of the style (as is indicated there).
• Not needed in Firefox 4!
*/

/* Show the throbber for the transition state. */
#main-window[stylish-application-version^="3"] #urlbar-icons #stop-button[disabled="true"] {
	list-style-image: url(chrome://global/skin/icons/loading_16.png) !important;
	-moz-image-region: auto !important;
}

/* Ensure small versions of Stop and Reload are used, for consistency with other “lucky charms”. */
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #stop-button:not([disabled="true"]),
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #reload-button {
	list-style-image: url(chrome://browser/skin/Toolbar-small.png) !important;
}
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #reload-button {				-moz-image-region: rect( 0px 64px 16px 48px) !important; }
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #reload-button:hover {			-moz-image-region: rect(16px 64px 32px 48px) !important; }
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #stop-button:not([disabled="true"]) {	-moz-image-region: rect( 0px 48px 16px 32px) !important; }
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #stop-button:not([disabled="true"]):hover {	-moz-image-region: rect(16px 48px 32px 32px) !important; }

#main-window[stylish-application-version^="3"][stylish-platform^="Linux"] #urlbar-icons #stop-button:not([disabled="true"]) {	list-style-image: url(moz-icon://stock/gtk-stop?size=menu) !important; }
#main-window[stylish-application-version^="3"][stylish-platform^="Linux"] #urlbar-icons #reload-button {				list-style-image: url(moz-icon://stock/gtk-refresh?size=menu) !important; }

/* Give the the smart button a Consistent appearance… */
#main-window[stylish-application-version^="3"] #urlbar-icons,
#stop-reload-container {
	padding: 0px !important;
}

/* …on Windows… */
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #stop-button,
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #reload-button,
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons > #go-button {
	-moz-appearance: none;
	-moz-binding: url(chrome://global/content/bindings/autocomplete.xml#history-dropmarker);
	border-color: transparent;
	border-style: solid;
	border-width: 0px 1px;
	margin: -0.666667px 0px;
	padding: 1.66667px 4px !important;
}
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #stop-button:hover,
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #reload-button:hover,
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons > #go-button:hover {
	background-color: -moz-dialog;
	background-image: url(chrome://browser/skin/navbar-textbox-buttons.png);
	background-position: 0px -60px;
	border-color: ThreeDShadow;
}
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #stop-button:hover:active,
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons #reload-button:hover:active,
#main-window[stylish-application-version^="3"]:not([stylish-platform^="Linux"]) #urlbar-icons > #go-button:hover:active {
	background-position: 0px -120px;
}

/* …and on GTK+. */
#main-window[stylish-application-version^="3"][stylish-platform^="Linux"] #urlbar-icons #stop-button,
#main-window[stylish-application-version^="3"][stylish-platform^="Linux"] #urlbar-icons #reload-button,
#main-window[stylish-application-version^="3"][stylish-platform^="Linux"] #urlbar-icons > #go-button {
	-moz-appearance: toolbarbutton;
	-moz-binding: url(chrome://global/content/bindings/toolbarbutton.xml#toolbarbutton);
	margin: -4px 0px !important;
	height: 28px !important;
	/* This ↑↑ value may need tweaking, depending on your GTK+ theme, followed by the value below. */
}
#main-window[stylish-application-version^="3"][stylish-platform^="Linux"] #urlbar-icons > #go-button > image {
	margin: 1.5px 1.5px;
	/* This ↑↑↑ value will also need tweaking, if you modify the value above. */
}