SniperFox / E-Hentai Black Theme

// ==UserScript==
// @name          E-Hentai Black Theme
// @license     MPL-2.0
// @description    A simple Black theme for E-Hentai.org galleris
// @author        SniperFox
// @homepage      https://openuserjs.org/users/SniperFox
// @copyright   2018, SniperFox (https://openuserjs.org/users/SniperFox)
// @include       http://e-hentai.org/*
// @include       https://e-hentai.org/*
// @include       http://*.e-hentai.org/*
// @include       https://*.e-hentai.org/*
// @include       http://g.e-hentai.org*
// @run-at        document-start
// @version       42
// ==/UserScript==
(function() {var css = [
	"@namespace url(http://www.w3.org/1999/xhtml);",
	"/* Fonts */",
	"    body, div, th, td, h1, .stdinput {font-family: Ubuntu,arial,helvetica,sans-serif !important;  font-size: 12px !important; line-height: 12px !important;}",
	"",
	"    /* Iframes only serve ads */",
	"    iframe {display: none !important;}",
	"    ",
	"    /* Black out all backgrounds */",
	"    body, div, table, th, td, img, h1, input.stdbtn, .stdinput {background-color: black !important; color: #999999 !important; border-color: #999999 !important;}",
	"    ",
	"    /* White Links */",
	"    a {color: White !important; text-decoration: none !important;}",
	"    a:hover, td:hover {color: White !important; text-decoration: underline !important;}",
	"    ",
	"    /* Un-3D buttons */",
	"    input.stdbtn {border: solid 1px #999999 !important;}",
	"",
	"    /* list page (thumbnail view) */",
	"    #dmo, div.ppo, div.ppi{float:none !important; width: auto !important; margin: 0 !important;  padding: 0 !important; overflow: visible !important;}",
	"    div.ido, div.itg{max-width: inherit !important; border:none !important;width:100% !important; padding: 0 !important;}",
	"    body div.ido div.c{clear: none !important;}",
	"    div.itd1{width: auto !important; margin:2px !important; min-height:340px !important;}",
	"    div#dmi{display: none;}",
	"    div.id1{border: solid 1px #333333 !important; border-radius: 4px !important; margin:1px !important; width: auto !important;}",
	"    div.id2 a{font-weight: normal !important;}",
	"    div.id44{width:74px !important;}",
	"    ",
	"    /* gallery pages */",
	"    div.gm{border:none !important; background:inherit !important;}",
	"    div#gdt{max-width: inherit !important; border:none !important; background:inherit !important;}",
	"    div.gdtl{width: auto !important; margin:2px !important; min-height:320px !important;}",
	"    ",
	"    /* view single image */",
	"    div.sni{min-width:100% !important;}"
].join("\n");
if (typeof GM_addStyle != "undefined") {
	GM_addStyle(css);
} else if (typeof PRO_addStyle != "undefined") {
	PRO_addStyle(css);
} else if (typeof addStyle != "undefined") {
	addStyle(css);
} else {
	var node = document.createElement("style");
	node.type = "text/css";
	node.appendChild(document.createTextNode(css));
	var heads = document.getElementsByTagName("head");
	if (heads.length > 0) {
		heads[0].appendChild(node);
	} else {
		// no head yet, stick it whereever
		document.documentElement.appendChild(node);
	}
}
})();