/* ==UserStyle==
@name E-Hentai 主题切换
@name:en E-Hentai Theme Switcher
@namespace https://greasyfork.org/zh-CN/users/1508871-vesper233
@description E-Hentai 主题切换,支持暗色模式、亮色模式和自动模式(不适用于论坛)
@description:en E-Hentai Theme Switcher, support dark mode, light mode and auto mode (not for forums)
@version 5.3.2
@author Vesper233
@license MIT
@preprocessor stylus
==/UserStyle== */
/*
* 重要提示:此样式表仅适用于 E-Hentai 主站和上传页面
* 不应该应用到 forums.e-hentai.org 论坛页面
* Important: This stylesheet is only for E-Hentai main site and upload pages
* Should NOT be applied to forums.e-hentai.org forum pages
*/
@-moz-document url-prefix("https://e-hentai.org/"), url-prefix("http://e-hentai.org/"), url-prefix("https://upload.e-hentai.org/"), url-prefix("http://upload.e-hentai.org/") {
/*
* 域名检查 - 确保不在论坛页面应用样式
* 使用安全的方式检测论坛页面,避免隐藏整个页面
*/
/* 论坛页面检测 - 仅在确认为论坛页面时禁用样式 */
/* 注意:移除了危险的 display: none 规则,改用更安全的方式 */
/* =========================
* ExHentai 颜色变量
* ========================= */
:root {
/* ExHentai 真实颜色 */
--exh-bg-primary: #34353b; /* 主背景 */
/* --exh-bg-secondary: #4f535b; 内容框背景 */
--exh-bg-tertiary: #40454b; /* 表头背景 */
--exh-bg-row-odd: #363940; /* 奇数行 */
--exh-bg-row-even: #3c414b; /* 偶数行 */
--exh-bg-hover: #43464e; /* 悬停背景 */
--exh-bg-input: #34353b; /* 输入框背景 */
/* ExHentai 文字颜色 */
--exh-text-primary: #f1f1f1; /* 主要文字 */
--exh-text-secondary: #dddddd; /* 链接文字 */
--exh-text-muted: #aaaaaa; /* 导航栏文字 */
--exh-text-disabled: #8a8a8a; /* 禁用文字 */
--exh-text-visited: #bbbbbb; /* 已访问链接 */
--exh-text-hover: #eeeeee; /* 悬停文字 */
/* ExHentai 边框颜色 */
--exh-border-primary: #3c3c3c; /* 主要边框 */
--exh-border-secondary: #000000; /* 深色边框 */
--exh-border-table: #2a2a2a; /* 表格边框 */
--exh-border-input: #8d8d8d; /* 输入框边框 */
}
/* =========================
* 只在暗色模式下应用ExHentai样式
* 亮色模式完全使用原版E-Hentai样式
* ========================= */
/* 暗色模式选择器 */
html:not([data-eh-theme="light"]):not([data-eh-theme="auto"][data-system-dark="false"]) {
/* 基础页面颜色 */
html {
background: var(--exh-bg-primary) !important;
color: var(--exh-text-primary) !important;
}
body {
background: var(--exh-bg-primary) !important;
color: var(--exh-text-primary) !important;
}
/* 链接颜色 */
a {
color: var(--exh-text-secondary) !important;
}
a:hover {
color: var(--exh-text-hover) !important;
}
a:visited .glink,
a:active .glink {
color: var(--exh-text-visited) !important;
}
a:hover .glink {
color: var(--exh-text-hover) !important;
}
.glname a :not(.glink),
a .glname :not(.glink) {
color: var(--exh-text-secondary) !important;
}
/* 分隔线颜色 */
hr {
background: var(--exh-text-primary) !important;
}
/* 输入框和表单元素 */
input, select, option, optgroup, textarea {
color: var(--exh-text-primary) !important;
background-color: var(--exh-bg-input) !important;
}
input[type="button"], input[type="submit"] {
border-color: var(--exh-border-input) !important;
}
select {
border-color: var(--exh-border-input) !important;
}
input[type="button"]:enabled:hover,
input[type="submit"]:enabled:hover,
select:enabled:hover,
input[type="button"]:enabled:focus,
input[type="submit"]:enabled:focus,
select:enabled:focus {
background-color: var(--exh-bg-hover) !important;
border-color: #aeaeae !important;
}
input[type="text"], input[type="date"], input[type="password"], textarea {
border-color: var(--exh-border-input) !important;
}
input:disabled, select:disabled, textarea:disabled {
color: var(--exh-text-disabled) !important;
-webkit-text-fill-color: var(--exh-text-disabled) !important;
}
input::placeholder, textarea::placeholder {
color: var(--exh-text-disabled) !important;
-webkit-text-fill-color: var(--exh-text-disabled) !important;
}
input[type="text"]:enabled:hover,
input[type="date"]:enabled:hover,
input[type="password"]:enabled:hover,
textarea:enabled:hover,
input[type="text"]:enabled:focus,
input[type="date"]:enabled:focus,
input[type="password"]:enabled:focus,
textarea:enabled:focus {
background-color: var(--exh-bg-hover) !important;
}
/* 内容框 */
.stuffbox {
background: var(--exh-bg-secondary) !important;
border-color: var(--exh-border-secondary) !important;
}
.ido {
background: var(--exh-bg-secondary) !important;
border-color: var(--exh-border-secondary) !important;
}
/* 导航栏 */
#nb {
color: var(--exh-text-muted) !important;
}
#nb a {
color: var(--exh-text-secondary) !important;
}
/* 表格 */
div.itg {
border-top-color: var(--exh-border-primary) !important;
border-bottom-color: var(--exh-border-primary) !important;
}
table.itg {
border-color: var(--exh-border-primary) !important;
}
table.itg > tbody > tr > th {
background: var(--exh-bg-tertiary) !important;
color: var(--exh-text-primary) !important;
}
table.itg > tbody > tr:nth-child(2n+1),
table.itg > tbody > tr:nth-child(2n+1) .glthumb,
table.itg > tbody > tr:nth-child(2n+1) .glcut {
background: var(--exh-bg-row-odd) !important;
}
table.itg > tbody > tr:nth-child(2n+2),
table.itg > tbody > tr:nth-child(2n+2) .glthumb,
table.itg > tbody > tr:nth-child(2n+2) .glcut {
background: var(--exh-bg-row-even) !important;
}
.gl1t:nth-child(2n+1) {
background: var(--exh-bg-row-odd) !important;
}
.gl1t:nth-child(2n+2) {
background: var(--exh-bg-row-even) !important;
}
td.itd {
border-right-color: var(--exh-border-table) !important;
}
.gltc > tbody > tr > td,
.glte > tbody > tr > td {
border-right-color: var(--exh-border-table) !important;
}
.gltm > tbody > tr > td {
border-right-color: var(--exh-border-table) !important;
}
.gl1c, .gl2c, .gl3c, .gl4c, .glfc {
border-top-color: var(--exh-border-table) !important;
border-bottom-color: var(--exh-border-table) !important;
}
.gl1e, .gl2e, .glfe {
border-top-color: var(--exh-border-table) !important;
border-bottom-color: var(--exh-border-table) !important;
}
.gld {
border-left-color: var(--exh-border-table) !important;
}
.gl1t {
border-right-color: var(--exh-border-table) !important;
border-bottom-color: var(--exh-border-table) !important;
}
.gl4e {
border-left-color: var(--exh-border-table) !important;
}
table.mt {
border-color: var(--exh-border-secondary) !important;
background: var(--exh-bg-tertiary) !important;
}
table.mt > tbody > tr:nth-child(2n+1) {
background: var(--exh-bg-row-odd) !important;
}
table.mt > tbody > tr:nth-child(2n+2) {
background: var(--exh-bg-row-even) !important;
}
tr.gtr,
table.mt > tbody > tr:first-child {
background: var(--exh-bg-tertiary) !important;
}
/* 缩略图悬停效果 */
.glthumb {
border-color: var(--exh-border-table) !important;
}
.glthumb > div:nth-child(1) {
border-color: var(--exh-border-secondary) !important;
}
.gl1e > div {
border-color: var(--exh-border-secondary) !important;
}
.gl3t {
border-color: var(--exh-border-secondary) !important;
}
/* 登录框 */
div.d {
border-color: var(--exh-border-secondary) !important;
background: var(--exh-bg-secondary) !important;
}
div.ds {
border-color: var(--exh-border-secondary) !important;
background: var(--exh-bg-secondary) !important;
}
/* 索引页面 */
div.idi {
border-color: var(--exh-border-primary) !important;
}
/* 分页导航 */
table.ptt, table.ptb {
color: var(--exh-text-primary) !important;
}
table.ptt td, table.ptb td {
background: var(--exh-bg-primary) !important;
border-color: var(--exh-border-secondary) !important;
}
table.ptt td:hover, table.ptb td:hover {
color: #000000 !important;
background: var(--exh-bg-hover) !important;
}
table.ptt span, table.ptb span {
color: var(--exh-text-disabled) !important;
}
td.ptds {
color: #000000 !important;
background: var(--exh-bg-hover) !important;
}
td.ptdd {
color: var(--exh-text-disabled) !important;
}
td.ptdd:hover {
color: var(--exh-text-disabled) !important;
background: var(--exh-bg-primary) !important;
}
/* 画廊详情页 */
.gm {
background: var(--exh-bg-secondary) !important;
border-color: var(--exh-border-secondary) !important;
}
#gmid {
background: var(--exh-bg-secondary) !important;
}
#gd2 {
background: var(--exh-bg-secondary) !important;
}
#gdt {
background: var(--exh-bg-secondary) !important;
border-color: var(--exh-border-secondary) !important;
}
#gds {
background: var(--exh-bg-secondary) !important;
}
/* 标签 */
div.gt {
border-color: #989898 !important;
background: var(--exh-bg-secondary) !important;
color: var(--exh-text-primary) !important;
}
div.gtl {
border-color: #8c8c8c !important;
background: var(--exh-bg-secondary) !important;
color: var(--exh-text-primary) !important;
}
div.gtw {
border-color: #8c8c8c !important;
background: var(--exh-bg-secondary) !important;
color: var(--exh-text-primary) !important;
}
/* 评论区 */
div.c2 {
background: var(--exh-bg-primary) !important;
border-color: var(--exh-bg-secondary) !important;
}
/* 图片页面 */
div.sni {
background: var(--exh-bg-secondary) !important;
border-color: var(--exh-border-secondary) !important;
}
/* 搜索和导航 */
.searchnav {
color: var(--exh-text-primary) !important;
}
.searchnav a {
color: var(--exh-text-secondary) !important;
}
.searchnav div > span {
color: #777 !important;
}
/* 范围栏 */
#rangebar {
background: var(--exh-bg-tertiary) !important;
}
#rangebar div {
background: rgba(241, 241, 241, 0.24) !important;
}
#rangebar div[data-inrange] {
background: radial-gradient(rgba(241, 241, 241, 0.69), rgba(241, 241, 241, 0.59)) !important;
}
#rangebar a:hover > div {
background: var(--exh-text-primary) !important;
}
/* 其他元素 */
.ip {
color: var(--exh-text-primary) !important;
}
.ip a {
color: var(--exh-text-secondary) !important;
}
/* 收藏夹页面专用样式 */
/* 收藏夹分类按钮 - 匹配ExHentai真实样式 */
div.fp,
div.fp.eh-dark-favpill {
background: transparent !important;
border: 1px solid transparent !important;
color: var(--exh-text-primary) !important;
}
div.fp:hover,
div.fp.eh-dark-favpill:hover {
background: #43464e !important;
border: 1px solid #C2C1C1 !important;
}
/* Show All Favorites 按钮 - 默认有背景色 */
div.fp.fps,
div.fp.fps.eh-dark-favpill {
background: #43464e !important;
border: 1px solid #C2C1C1 !important;
color: var(--exh-text-primary) !important;
}
div.fp.fps:hover,
div.fp.fps.eh-dark-favpill:hover {
background: #43464e !important;
border: 1px solid #C2C1C1 !important;
}
/* 收藏夹操作选择框 */
select#favsel {
background: var(--exh-bg-input) !important;
border: 1px solid var(--exh-border-input) !important;
color: var(--exh-text-primary) !important;
}
select#favsel:hover,
select#favsel:focus {
background: var(--exh-bg-hover) !important;
border-color: var(--exh-border-input) !important;
}
/* 收藏夹操作区域 */
div#favact {
background: var(--exh-bg-primary) !important;
color: var(--exh-text-primary) !important;
}
/* 搜索导航选择框 */
.searchnav select {
background: var(--exh-bg-input) !important;
border: 1px solid var(--exh-border-input) !important;
color: var(--exh-text-primary) !important;
}
.searchnav select:hover,
.searchnav select:focus {
background: var(--exh-bg-hover) !important;
border-color: var(--exh-border-input) !important;
}
/* 收藏夹页面的复选框 - 匹配ExHentai真实样式 */
input[type="checkbox"] {
background: var(--exh-bg-input) !important;
border: 1px solid var(--exh-border-input) !important;
accent-color: var(--exh-text-secondary) !important;
}
/* 复选框标签容器 */
label.lc {
color: var(--exh-text-primary) !important;
}
/* 复选框自定义样式 - 匹配ExHentai */
.lc > span {
background-color: var(--exh-bg-primary) !important;
border: 2px solid var(--exh-border-input) !important;
}
.lc:hover input:enabled ~ span,
.lc input:enabled:focus ~ span {
background-color: var(--exh-bg-hover) !important;
border-color: #aeaeae !important;
}
.lc input:disabled ~ span {
border-color: #5c5c5c !important;
}
.lc > span:after {
border: solid var(--exh-text-primary) !important;
}
/* 收藏夹页面表单元素 */
form#favform input[type="text"],
form#favform input[type="submit"],
form#favform select {
background: var(--exh-bg-input) !important;
border: 1px solid var(--exh-border-input) !important;
color: var(--exh-text-primary) !important;
}
form#favform input[type="submit"]:hover,
input[name="apply"]:hover {
background: var(--exh-bg-hover) !important;
border-color: var(--exh-border-input) !important;
}
/* 确认按钮特殊样式 */
input[name="apply"] {
background: var(--exh-bg-input) !important;
border: 1px solid var(--exh-border-input) !important;
color: var(--exh-text-primary) !important;
}
/* 收藏夹搜索导航 */
.searchnav {
background: var(--exh-bg-primary) !important;
color: var(--exh-text-primary) !important;
}
/* 收藏夹页面的画廊列表容器 */
.itg.gld {
background: var(--exh-bg-primary) !important;
}
/* 收藏夹页面的画廊项目 */
.gl1t, .gl3t, .gl4t {
background: var(--exh-bg-secondary) !important;
border-color: var(--exh-border-table) !important;
}
.gl1t:hover, .gl3t:hover, .gl4t:hover {
background: var(--exh-bg-hover) !important;
}
/* 收藏夹页面的画廊名称 */
.glname {
color: var(--exh-text-primary) !important;
}
.glname a {
color: var(--exh-text-secondary) !important;
}
.glname a:hover {
color: var(--exh-text-hover) !important;
}
/* 收藏夹页面的画廊信息 */
.gl5t {
background: var(--exh-bg-secondary) !important;
color: var(--exh-text-primary) !important;
}
.gl6t {
background: var(--exh-bg-secondary) !important;
color: var(--exh-text-primary) !important;
}
/* 收藏夹页面的注释 */
.glfnote {
background: var(--exh-bg-tertiary) !important;
border-color: var(--exh-border-secondary) !important;
color: var(--exh-text-primary) !important;
}
/* 收藏夹页面选项组 */
optgroup {
background: var(--exh-bg-secondary) !important;
color: var(--exh-text-primary) !important;
}
option {
background: var(--exh-bg-input) !important;
color: var(--exh-text-primary) !important;
}
/* 收藏夹页面的内容容器 */
div.ido {
background: var(--exh-bg-primary) !important;
}
/* 评分颜色保持不变 */
a.tup, span.tup {
color: #00e639 !important;
}
a.tdn, span.tdn {
color: #ff3333 !important;
}
/* 错误信息颜色保持不变 */
.br {
color: #ff3333 !important;
}
} /* 结束暗色模式选择器 */
} /* 结束 @-moz-document */