/* ==UserStyle== @name E-Hentai Forums Dark @namespace meiyongai.eh-forums-dark @version 1.1.1 @description A quiet dark theme for E-Hentai Forums, matching HentaiVerse Dark. @author MeiYongAI @homepageURL https://github.com/MeiYongAI/JPX-PLUS @updateURL https://raw.githubusercontent.com/MeiYongAI/JPX-PLUS/main/E-Hentai-Forums-Dark.user.css ==/UserStyle== */ @-moz-document domain("forums.e-hentai.org") { @media screen { html:root { color-scheme: dark; --ehf-bg: #191b1e; --ehf-panel: #202226; --ehf-surface: #292c31; --ehf-field: #24272b; --ehf-text: #e5e0d8; --ehf-muted: #b4afa7; --ehf-link: #e2bc8c; --ehf-border: #5a534c; --ehf-divider: #41464e; --ehf-control-border: #858b94; --ehf-heading: #30353d; --ehf-row-hover: #2d3239; --ehf-link-hover: #f5d4ac; --ehf-hover: #3d3933; --ehf-code: #1b1e22; --ehf-red: #ff9295; --ehf-green: #8cd6a3; --ehf-blue: #93baff; background: var(--ehf-bg) !important; scrollbar-color: var(--ehf-border) var(--ehf-bg); } html:root body { background: var(--ehf-bg) !important; color: var(--ehf-text); } html:root :is(table, tr, td, th) { color: var(--ehf-text); border-color: var(--ehf-border); } html:root :is(a:link, a:visited, a:active) { color: var(--ehf-link); } html:root a:hover { color: var(--ehf-link-hover); } html:root ::selection { background: #65503b; color: #fff4e5; } html:root :is(hr, fieldset) { border-color: var(--ehf-border); } /* Recolor forum chrome; retain the original table layout and spacing. */ html:root :is(.tablebg, .round, .round2, .page, .borderwrap, .borderwrapm, .plainborder, .tablefill, .tablepad, .activeusers, .activeuserstrip, .newslink, .bar, .barb, .barc, .catend, .fullimagewrap, .posticons, .fieldwrap, .ruleswrap, .mya-back, .mya-content, #ipbwrapper, #ucpmenu, #ucpcontent, #gfooter, #userlinks, #userlinksguest, #redirectwrap, #pmnotewrap, .errorwrap, .calmonths, .calday, .calweekday, .celldate, .celltoday, .mcelldate, .mcelltoday) { background: var(--ehf-panel); color: var(--ehf-text); border-color: var(--ehf-border); } html:root :is(.row1, .row3, .post1, .post2, .bg1, .bg3, .darkrow1, .formtable td, .pformleft, .pformleftw, .pformright, .borderwrap p) { background: var(--ehf-panel); color: var(--ehf-text); border-color: var(--ehf-border); } html:root :is(.row2, .darkrow3, .row2shaded, .row4shaded, .post1shaded, .post2shaded, .info, .cellblank, .mcellblank) { background: var(--ehf-field); color: var(--ehf-text); border-color: var(--ehf-border); } html:root :is(.maintitle, .maintitle2, .maintitlecollapse, .mainhead, .mainfoot, .mainnav, .mainpagef, .subtitle, .subtitlediv, .postlinksbar, .formsubtitle, .formtable td.formtitle, .formtable td.formstrip, .borderwrap h3, .borderwrap h4, .fieldwrap h4, .errorwrap h4, #pmnotewrap h4, #pmnotewrap .pmnotefoot, #redirectwrap h4, #redirectwrap .redirectfoot, #logostrip, #submenu, table th, #print h3, #print h4) { background: var(--ehf-surface); color: var(--ehf-text); border-color: var(--ehf-border); } html:root :is(#gfooter td, .errorwrap p, #pmnotewrap p) { color: var(--ehf-text); } html:root :is(#navstrip, #livechat, .postdetails, .desc, .forumdesc, .lastaction, .edit, .copyright, .signature, .toplinks, .normalname, .newslink span, .bar p, .barb p, .barc p) { color: var(--ehf-muted); } html:root :is(#navstrip, #submenu, #gfooter, #pmnotewrap, .maintitle, .maintitle2, .maintitlecollapse, .subtitle, .subtitlediv, .borderwrap th) a:any-link { color: var(--ehf-link); } html:root :is(#navstrip, #submenu, #gfooter, #pmnotewrap, .maintitle, .maintitle2, .maintitlecollapse, .subtitle, .subtitlediv, .borderwrap th) a:hover { color: var(--ehf-link-hover); } /* Cellspacing is the native grid: give its one-pixel gaps a visible tone. */ html:root #ipbwrapper .borderwrap:has(> table):not(:where(.postcolor *, .signature *)) { background: var(--ehf-divider); border-color: var(--ehf-divider); } html:root #ipbwrapper :is(.mainhead, .maintitle, .maintitlecollapse) { background: var(--ehf-heading); color: var(--ehf-text); } html:root #ipbwrapper .mainhead .maintitle2 { background: transparent; } html:root :is(.forumdesc, .desc) a:any-link { color: var(--ehf-link); } html:root :is(.forumdesc, .desc) a:hover { color: var(--ehf-link-hover); } html:root .borderwrap > table > tbody > tr:has(> td > .forumdesc):is(:hover, :focus-within) > :is(.row1, .row2) { background: var(--ehf-row-hover); } /* Ambience index headers: replace wide empty image caps with a title bar. Scope to real category containers; do not reshape post or editor tables. */ html:root #ipbwrapper div[id^=fo_] > table > tbody > tr > .mainhead { height: 34px; background: var(--ehf-heading); box-shadow: inset 0 1px var(--ehf-divider); } html:root div[id^=fo_] > table > tbody > tr > .mainhead:is(:first-child, :last-child) { width: 12px; } html:root div[id^=fo_] > table > tbody > tr > .mainhead:first-child { border-radius: 6px 0 0 0; } html:root div[id^=fo_] > table > tbody > tr > .mainhead:last-child { border-radius: 0 6px 0 0; } html:root div[id^=fo_] > table .mainhead img:is([src$="/cat_top_ls.gif"], [src$="/cat_top_rs.gif"]) { width: 12px; height: 1px; } html:root div[id^=fo_] > table .maintitle2 { text-align: left; } html:root div[id^=fo_] > table .mainhead a:has(> img:is([src$="/exp_plus.gif"], [src$="/exp_minus.gif"])) { display: inline-flex; align-items: center; justify-content: center; min-width: 24px; min-height: 24px; border-radius: 4px; } html:root div[id^=fo_] > table .mainhead a:has(> img:is([src$="/exp_plus.gif"], [src$="/exp_minus.gif"])):hover { background: var(--ehf-hover); } html:root #ipbwrapper div[id^=fo_] + table .mainfoot { height: 8px; line-height: 0; background: var(--ehf-panel); } html:root div[id^=fo_] + table .mainfoot img { height: 8px; } /* Keep homepage search usable and scroll only the wide forum grid on phones. */ @media (max-width: 700px) { html:root .newslink:has(input[type=image][src$="/login-button.gif"]) > tbody > tr, html:root .newslink:has(input[type=image][src$="/login-button.gif"]) > tbody > tr > td { display: block; text-align: left; } html:root .newslink form:has(input[type=image][src$="/login-button.gif"]) { display: flex; align-items: center; gap: 8px; } html:root .newslink form:has(input[type=image][src$="/login-button.gif"]) input[type=text] { flex: 1; min-width: 0; margin: 0; } html:root .newslink input[type=image][src$="/login-button.gif"] { flex: none; margin: 0; } html:root #ipbwrapper div[id^=fo_] > .borderwrap:has(.forumdesc) { max-width: calc(100vw - 32px); overflow-x: auto; } html:root #ipbwrapper div[id^=fo_] > .borderwrap:has(.forumdesc) > table { min-width: 700px; } } html:root :is(.formbuttonrow, .formbuttonrow1, .thumbwrap p, .thumbwrapp p, .thumbwrap p.alt, .thumbwrapp p.alt) { background: var(--ehf-field) !important; color: var(--ehf-text); border-color: var(--ehf-border) !important; } html:root :is(.thumbwrap, .thumbwrapp, .thumbwrap h4, .thumbwrapp h4, .thin, #phototitle) { background: var(--ehf-surface); color: var(--ehf-text); border-color: var(--ehf-border) !important; } html:root .thumbwrapp p.pin { background: #422c30 !important; } /* Quotes stay distinct from code, including nested quotes and signatures. */ html:root :is(.quotetop, .codetop, .sqltop, .htmltop) { color: var(--ehf-link); } html:root :is(.quotemain, #QUOTE) { background: var(--ehf-surface); color: var(--ehf-text); border-color: #80705f; } html:root :is(.codemain, .sqlmain, .htmlmain, #CODE) { background: var(--ehf-code); color: #cbdac8; border-color: var(--ehf-border); } html:root :is(.searchlite, mark) { background: #55412a; color: #ffe2ac; } html:root .warngood { color: var(--ehf-green); } html:root .warnbad { color: var(--ehf-red); } /* Native fields, quick reply and the BBCode editor. */ html:root :is(input:not(:where([type=hidden], [type=image])), textarea, select, option, button, .textarea, .searchinput, .button, .gobutton, .codebuttons, .helpbox, .dny-edit-title) { background: var(--ehf-field); color: var(--ehf-text); border-color: var(--ehf-border); color-scheme: dark; accent-color: var(--ehf-link); caret-color: var(--ehf-link); } html:root :where(.newslink) input.button { color: var(--ehf-text); } html:root :is(input:not(:where([type=hidden], [type=image], [type=checkbox], [type=radio])), textarea, select, button, .textarea, .searchinput, .button, .gobutton, .codebuttons, .helpbox, .dny-edit-title) { border-color: var(--ehf-control-border); } /* This submit control contains a light GIF, not text. Filter only that asset. Keep the pre-filter surface light, otherwise inversion creates a white box. */ html:root input[type=image][src$="style_images/ambience/login-button.gif"] { background: #dce0e5; border-color: #78736b; filter: invert(1) hue-rotate(180deg) brightness(1.5) saturate(.55); cursor: pointer; } html:root input[type=image][src$="style_images/ambience/login-button.gif"]:enabled:hover { background: #c9c4bd; } html:root input[type=image][src$="style_images/ambience/login-button.gif"]:focus-visible { outline-color: #725330; } html:root :is(input, textarea)::placeholder { color: var(--ehf-muted); opacity: 1; } html:root :is(button, input[type=button], input[type=submit], input[type=reset], .button, .gobutton):enabled:hover { background: var(--ehf-hover); color: var(--ehf-link); } html:root :is(input, textarea, select, button):disabled { color: #98958f; cursor: not-allowed; } html:root :is(a, button, input, select, textarea, [tabindex]):focus-visible { outline: 2px solid var(--ehf-link); outline-offset: 2px; } html:root :is(.rteBack, .rtebuttonbar1, .rtebuttonbar2, .rtebottombutton, .rteiframe) { background: var(--ehf-field); color: var(--ehf-text); border-color: var(--ehf-border); } html:root :is(.rteimage:hover, .rteImageRaised, .rteImageLowered, .rtebottombuttonon) { background: var(--ehf-hover); color: var(--ehf-link); border-color: var(--ehf-link); } /* Put hover color behind filtered toolbar images, so it is not inverted. */ html:root :is(.rtebuttonbar1, .rtebuttonbar2) div:has(> img:is(.rteimage:hover, .rteImageRaised, .rteImageLowered)) { background: var(--ehf-hover); } html:root img:is(.rteimage:hover, .rteImageRaised, .rteImageLowered) { background: transparent; } html:root #loading-layer { background: var(--ehf-panel) !important; color: var(--ehf-text); border-color: var(--ehf-border) !important; } html:root :is(.celltoday, .mcelltoday) { border-color: var(--ehf-link) !important; } /* Equipment previews added to forum posts by the game translation helper. */ html:root .hv-tip { background: var(--ehf-panel); color: var(--ehf-text); border-color: var(--ehf-border); } html:root .hv-tip :is(.showequip > div:first-child, .ex) { border-color: var(--ehf-border); } html:root .hv-tip a:any-link { color: var(--ehf-link); } /* Menus and pagination use the same quiet active and hover colors. */ html:root :is(.popupmenu, .popupmenu-item, .popupmenu-item-last, .fauxbutton, .taboff, .pagelink, .pagelinklast, .minipagelink, .minipagelinklast, .toplinks span) { background: var(--ehf-field); color: var(--ehf-text); border-color: var(--ehf-border); } html:root :is(.popupmenu-category, .tabon, .pagecurrent) { background: var(--ehf-hover); color: var(--ehf-link); border-color: #927b61; } html:root :is(.tabon, .taboff) a:any-link { color: var(--ehf-link); } html:root .fauxbutton a:any-link { color: var(--ehf-link) !important; } html:root :is(.popupmenu-item, .popupmenu-item-last, .pagelink, .pagelinklast, .minipagelink, .minipagelinklast, .taboff, .fauxbutton):hover { background: var(--ehf-hover); } /* Ambience's frame tiles are decorative; never hide or invert user images. */ html:root :is(td, tr)[style*="style_images/ambience/"]:not(:where(.postcolor *, .signature *)) { background: var(--ehf-surface) !important; } html:root img[src*="style_images/ambience/"]:not(:where(.postcolor *, .signature *)):is( [src*="/ls_main_table_"], [src*="/rs_main_table_"], [src*="/cat_top_"], [src$="/expand_main_table.gif"], [src$="/extended_main_table_bottom.gif"]) { opacity: 0; } html:root img[src$="style_images/ambience/pip.gif"]:not(:where(.postcolor *, .signature *)) { opacity: .55; } html:root img[src*="style_images/"]:not(:where(.postcolor *, .signature *)):is( [src*="/ambi_header_nav_eh_"], [src$="/header_eh_textbar.jpg"], [src$="/t_reply.gif"], [src$="/t_new.gif"], [src$="/t_qr.gif"], [src$="/t_closed.gif"], [src$="/p_quote.gif"], [src$="/p_mq_add.gif"], [src$="/p_mq_remove.gif"], [src$="/p_edit.gif"], [src$="/p_delete.gif"], [src$="/p_report.gif"], [src$="/p_card.gif"], [src$="/p_pm.gif"], [src$="/p_up.gif"], [src$="/p_online.gif"], [src$="/p_offline.gif"], [src$="/nav.gif"], [src$="/nav_m.gif"], [src$="/menu_action_down.gif"], [src$="/menu_item.gif"], [src$="/to_post_off.gif"], [src$="/loading.gif"], [src$="/warn0.gif"], [src*="/folder_rte_images/"]) { filter: invert(1) hue-rotate(180deg) brightness(.9) saturate(.55); } /* Transparent navy status glyphs need their own treatment. Preserve the source silhouettes and the difference between read/new/locked states. */ html:root img[src*="style_images/ambience/"]:not(:where(.postcolor *, .signature *)):is( [src*="/bf_"], [src*="/bc_"]) { filter: invert(1) hue-rotate(180deg) brightness(.9) saturate(.55); } html:root img[src*="style_images/ambience/"]:not(:where(.postcolor *, .signature *)):is( [src$="/bf_readonly.gif"], [src*="/f_"], [src$="/exp_plus.gif"], [src$="/exp_minus.gif"], [src$="/attachicon.gif"], [src$="/pages_icon.gif"], [src$="/folder_post_icons/icon1.gif"], [src$="/folder_post_icons/icon6.gif"], [src$="/folder_post_icons/icon10.gif"]) { filter: invert(1) hue-rotate(180deg) brightness(1.4) saturate(.65); } /* These colorful status images are already light. Preserve their colors. */ html:root img[src*="style_images/ambience/"]:not(:where(.postcolor *, .signature *)):is( [src$="/user.gif"], [src$="/stats.gif"], [src$="/newpost.gif"]) { filter: brightness(.9) saturate(.85); } html:root img[src$="style_images/ambience/lastpost.gif"]:not(:where(.postcolor *, .signature *)) { filter: brightness(1.3); } /* Native quote-return and file-type controls live inside posts. Match their functional wrappers, not all images in user-written content. */ html:root .quotetop a[href*="act=findpost"] > img[src$="style_images/ambience/post_snapback.gif"], html:root a[href*="act=attach"] > img[src*="style_images/ambience/folder_mime_types/"] { filter: invert(1) hue-rotate(180deg) brightness(1.4) saturate(.65); } html:root * { scrollbar-color: var(--ehf-border) var(--ehf-bg); } html:root ::-webkit-scrollbar { width: 12px; height: 12px; } html:root ::-webkit-scrollbar-track { background: var(--ehf-bg); } html:root ::-webkit-scrollbar-thumb { background: var(--ehf-border); border: 3px solid var(--ehf-bg); border-radius: 8px; } html:root ::-webkit-scrollbar-thumb:hover { background: #927b61; } html:root ::-webkit-scrollbar-corner { background: var(--ehf-bg); } } }