跳到正文

科技·工程

stylus修改-洛谷

ylj_yylc约 83 分钟
原文

这是 2026年10月6日 存档的第 4 版,不是当前版本。查看当前版本

文章信息与版本

文章信息

发布
2026年9月8日
收录
2026年9月11日
更新
2026年11月19日
篇幅
约 83 分钟

版本

  1. v5当前
  2. v4
  3. v3
  4. v2
更早的 1 个版本
  1. v1
C++
/* ==UserStyle==
@name         乐正绫主题洛谷
@version     2026.9.24.1559756867371511099
@namespace    userstyles.world/user/acerkaio
@author       ylj_yylc(御绫军_阴雨鎏尘)
@license      CC BY-NC-SA
==/UserStyle== */

/* ============================================================
   主站(首页/讨论区等)
   ============================================================ */

@-moz-document regexp("https://www.luogu(.org|.com.cn)/(?!blog).*") {
/* --- 背景图(保持你原设定) --- */
html > body{
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/dnr6trms.png)!important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    
    text-shadow: 0 1px 1px rgba(238, 0, 0, 0.6);
    opacity:.4!important;
}

.main-container.lside-nav{
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/dnr6trms.png)!important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    
    text-shadow: 0 1px 1px rgba(238, 0, 0, 0.6);
    }

html,


.theme-page {
    background: transparent !important;
}

.theme-page::before {
    position: fixed !important;
    inset: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    background-position: center center !important;
    background-size: cover !important;
    background-repeat: no-repeat !important;
    -webkit-mask-image: none !important;
    mask-image: none !important;
    pointer-events: none !important;
}

.sidebar,
.lside.bar {
    background: var(--nav-glass) !important;
    -webkit-backdrop-filter: var(--blur-nav) !important;
    backdrop-filter: var(--blur-nav) !important;
    border: none !important;
    box-shadow: none !important;
    transform: translate3d(0, 0, 0);
}
.user-nav.rside.show.nav-scrollbar{
        display:none;
}
top-bar,
.top-bar {
    background: linear-gradient( to bottom, rgba(20, 35, 56, 0.24) 0%, rgba(20, 35, 56, 0.20) 55%, rgba(20, 35, 56, 0.12) 82%, rgba(20, 35, 56, 0.06) 100% ) !important;
    -webkit-backdrop-filter: var(--blur-nav) !important;
    backdrop-filter: var(--blur-nav) !important;
    border: none !important;
    box-shadow: none !important;
}

top-bar::after,
.top-bar::after {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    bottom: -16px;
    height: 16px;
    background: linear-gradient( to bottom, rgba(20, 35, 56, 0.06), transparent );
    pointer-events: none;
}
/* --- 字体防模糊:加粗 + 无发光阴影 --- */
html > body, p, div, span, li, td, th, h1, h2, h3, h4, h5, h6 {
    font-weight: 600 !important;
    text-shadow: none !important;
}
    .row>*.l-card {
      background-image: linear-gradient(135deg, rgba(51, 204, 255, .8), rgba(255, 0, 0, 0.8)); 
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 16px !important;
    color: #FFFFFF !important;
    text-shadow: none !important;

}
    .sidebar-container.layout>*.side>*.l-card{
       background-image: linear-gradient(135deg, rgba(51, 204, 255, .8), rgba(255, 0, 0, 0.8)); 
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 16px !important;
    color: #FFFFFF !important;
    text-shadow: none !important;
    }
    /* --- 修复 benben 讨论区字体隐身问题(针对浅色背景强制深色字) --- */
.lg-content-table-left,
.lg-content-table-left *,
.am-comment-main,
.am-comment-main *,
.center > .am-comment-avatar + div,
.benben-container,
.benben-container * {
    color: #3E2723 !important; /* 深褐色,与浅色背景对比清晰 */
    text-shadow: none !important;
}
    
/* 确保里面超链接的颜色和悬停效果不受影响 */
.lg-content-table-left a,
.am-comment-main a {
    color: #005C97 !important;
}
.lg-content-table-left a:hover,
.am-comment-main a:hover {
    color: #fa4b4b !important;
}

/* 补全评论区域原本的白字边缘设定(若原意是想在深色底显示) */
/* 如果实际背景是白色,则上面那行已经生效;若是深色,请忽略此条 */
/* 卡片内白字加粗无阴影 */

body:has(:where(main > .full-container.columba-content-wrap > .l-card) > .user-header-top) .user-header-bottom {
    background: rgba(238, 243, 248, 0.20) !important;
    -webkit-backdrop-filter: blur(18px) saturate(120%) !important;
    backdrop-filter: blur(18px) saturate(120%) !important;
    border: none !important;
    box-shadow: none !important;
}
    
body:has(:is(.md-blog, .markdown-body, .blog-content)) main,
body:has(article) main,
body:has(:is(.md-blog, .markdown-body, .blog-content)) .columba-content-wrap,
body:has(article) .columba-content-wrap,
body:has(:is(.md-blog, .markdown-body, .blog-content)) .l-container,
body:has(article) .l-container,
body:has(:is(.md-blog, .markdown-body, .blog-content)) .container,
body:has(article) .container,
body:has(:is(.md-blog, .markdown-body, .blog-content)) .row,
body:has(article) .row {
    background: transparent !important;
    box-shadow: none !important;
    border: none !important;
}

/* 去掉文章页底部可能残留的深色/模糊块 */

body:has(:is(.md-blog, .markdown-body, .blog-content)) footer,
body:has(article) footer,
body:has(:is(.md-blog, .markdown-body, .blog-content)) .l-footer,
body:has(article) .l-footer,
body:has(:is(.md-blog, .markdown-body, .blog-content)) .l-footer-bg-background,
body:has(article) .l-footer-bg-background {
    background: transparent !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
    filter: none !important;
    box-shadow: none !important;
    border: none !important;
}

/* 专栏正文主卡片:大气泡 */

body:has(.md-blog) .l-card:has(.md-blog),
body:has(.markdown-body) .l-card:has(.markdown-body),
body:has(.blog-content) .l-card:has(.blog-content),
body:has(article) .l-card:has(article),
body:has(.md-blog) article,
body:has(.markdown-body) article,
body:has(.blog-content) .blog-content {
    background: rgba(248, 251, 255, 0.92) !important;
    -webkit-backdrop-filter: blur(18px) saturate(120%) !important;
    backdrop-filter: blur(18px) saturate(120%) !important;
    border: none !important;
    border-radius: 12px !important;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.10) !important;
    overflow: hidden !important;
}

/* 正文内部不要再自己铺底 */

body:has(.md-blog) .l-card:has(.md-blog) > *,
body:has(.markdown-body) .l-card:has(.markdown-body) > *,
body:has(.blog-content) .l-card:has(.blog-content) > *,
body:has(article) .l-card:has(article) > *,
body:has(.md-blog) .md-blog,
body:has(.markdown-body) .markdown-body,
body:has(.blog-content) .blog-content {
    background: transparent !important;
}

/* 正文文字颜色加深,保证可读性 */

body:has(.md-blog) .md-blog,
body:has(.markdown-body) .markdown-body,
body:has(.blog-content) .blog-content,
body:has(article) article {
    color: rgba(32, 36, 42, 0.96) !important;
}

/* 标题和元信息也不要太淡 */

body:has(:is(.md-blog, .markdown-body, .blog-content)) h1,
body:has(article) h1,
body:has(:is(.md-blog, .markdown-body, .blog-content)) h2,
body:has(article) h2,
body:has(:is(.md-blog, .markdown-body, .blog-content)) .header {
    color: rgba(28, 32, 38, 0.96) !important;
}

/* 代码块、引用块单独浅底,否则正文会发飘 */



/* 左侧点赞/收藏这一列,也改成小玻璃 */

body:has(:is(.md-blog, .markdown-body, .blog-content)) .side,
body:has(article) .side {
    background: rgba(246, 249, 253, 0.78) !important;
    -webkit-backdrop-filter: blur(14px) saturate(120%) !important;
    backdrop-filter: blur(14px) saturate(120%) !important;
    border: none !important;
    border-radius: 12px !important;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08) !important;
}

/* 右侧栏保持玻璃,但不要比正文更重 */

body:has(:is(.md-blog, .markdown-body, .blog-content)) aside .l-card,
body:has(article) aside .l-card,
body:has(:is(.md-blog, .markdown-body, .blog-content)) .right-wrap .l-card,
body:has(article) .right-wrap .l-card {
    background: rgba(244, 248, 252, 0.82) !important;
    -webkit-backdrop-filter: blur(14px) saturate(118%) !important;
    backdrop-filter: blur(14px) saturate(118%) !important;
    border: none !important;
    border-radius: 12px !important;
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08) !important;
}
body:has(:where(main > .full-container.columba-content-wrap > .l-card) > .user-header-top) #rating-chart + .tooltip {
    z-index: 2147483647 !important;
    pointer-events: none !important;
}

/* 避免上层容器裁剪 tooltip */


/* 避免正文区域下方再出现额外深色叠层 */



/* --- 卡片背景(完全复原你的设定) --- */
.wrapper.wrapped.lfe-body.header-layout.tiny {
   height: 60px;
   z-index: 999;
   background-color: #ffffff4a !important;
   -webkit-backdrop-filter: blur(20px) !important;
   backdrop-filter: blur(20px) !important;
   font-weight:bolder;
}
.background[data-v-43a0de31] {
    background: #33ccff !important;
}
   
.am-slides> * {
    display: none !important;
}

.am-direction-nav> * {
    display: none !important;
}
 .am-control-nav.am-control-paging>* {
    display: none !important;
}
  

/* 设置卡片样式 */
.am-u-md-12 {
    width: 100% !important;  
}
.am-u-md-12 >*.lg-article {
   transition: box-shadow .5s ease, border-radius .5s ease; /* 只允许阴影和圆角过渡 */
    background-position: center !important;  /* 固定背景位置 */
}/* 隐藏子元素内部原有内容 */
.am-u-md-12 >*.lg-article{
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/mi2706j0.png) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
}
    /* 修复主页卡片:取消图片覆盖,恢复红蓝渐变 */
.lg-article {
   transition: box-shadow .5s ease, border-radius .5s ease;
    background-position: center !important;
}
.lg-article{
    background-image: linear-gradient(135deg, rgba(255, 0, 0, 0.8), rgba(51, 204, 255, .8)) !important; /* 恢复红蓝渐变 */
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
}
   .lg-article.lg-index-stat{
          border-radius: 12px;        /* 圆角大小,可自定义 */
    overflow: hidden;           /* 防止内部内容超出圆角 */
    background-image: linear-gradient(135deg, rgba(51, 204, 255, .8), rgba(255, 0, 0, 0.8)); /* 蓝 -> 红 */ /* 红 -> 蓝 -> 红 -> 蓝 */
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    }

    .lg-article.lg-index-stat{
   transition: box-shadow .5s ease, border-radius .5s ease; /* 只允许阴影和圆角过渡 */
    background-position: center !important;  /* 固定背景位置 */
}
.lg-article.lg-index-stat {
    border-radius: 12px !important;
    overflow: hidden;
    background-image: linear-gradient(135deg, rgba(51, 204, 255, .8), rgba(255, 0, 0, 0.8)) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}
.am-panel.lg-index-contest.am-panel-primary {
    background-image: linear-gradient(135deg, rgba(255, 0, 0, 0.8), rgba(51, 204, 255, .8)) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}
.am-panel.lg-index-contest.am-panel-primary:hover {
    background-image: linear-gradient(135deg, rgba(51, 204, 255, .8), rgba(255, 0, 0, 0.8)) !important;
}

/* --- 侧栏图片与下拉菜单 --- */
#app > .lfe-body > div:first-of-type {
    opacity: 1 !important;
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/dnr6trms.png) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 30px !important;
    background-attachment: revert;
}
.dropdown.hown {
    opacity: 1 !important;
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/dnr6trms.png) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 30px !important;
}

/* --- 移除主体白底遮挡(关键修复) --- */
.main-container {
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/dnr6trms.png) !important;
    background-repeat: no-repeat !important;
    background-size: cover !important;
    background-position: center !important;
    background-attachment: fixed !important;
    background-color: transparent !important;
}
.main-container > main.lfe-body,
.main-container > .lfe-body,
.main-container > main,
#app,
#app > .lfe-body,
.lfe-body,
.background,
.background[data-v-7958fe72] {
    background: transparent !important;
    background-color: transparent !important;
}
.main-container > .header-layout .background { display: none !important; }

/* 针对洛谷主页更新后新增的白色背景层,强制隐藏 */
.main-container > .lfe-body > .background,
.main-container > .background,
.lfe-body > .background {
    background: transparent !important;
    display: none !important;
}
/* --- 统计图颜色(原封不动保留) --- */
path.highcharts-area { color: white; background: white; fill: #33ccff; }
path.highcharts-point.highcharts-color-0 { fill: #ee0000; stroke: #ffffff; opacity: .45; }
rect.highcharts-point.highcharts-color-1 { fill: #ee0000; stroke: #ffffff; opacity: .65; }

/* --- 其他基础样式 --- */
.selected:not([data-v-66021821]) {
    color: #fff !important;
    background-image: linear-gradient(135deg, #ee0000 10%, #33ccff 100%);
    border-radius: 5px !important;
}
.selected > span { color: #fff !important; }
.am-comment-main { border-radius: 10px !important; border: #fff 10px solid !important; }
.am-modal-dialog > .am-modal-footer > .am-modal-btn:hover { background: #2bb0e5; color: #fff; }

/* --- 按钮颜色 --- */
.am-btn.am-btn-danger.am-btn-sm { background: linear-gradient(to right, rgb(255, 65, 108), rgb(255, 75, 43)); color: #FFF !important; }
.am-btn.am-btn-primary.am-btn-sm { background: #7f7fd5; color: #FFF !important; }
.am-btn.am-btn-success.am-btn-sm { background: #b993d6; color: #FFF !important; }

/* --- 侧栏 --- */
#app > .lfe-body {
    animation: clan 1s;
    backdrop-filter: blur(20px) !important;
    -webkit-backdrop-filter: blur(20px) !important;
    border-radius: 0px 30px 30px 0px;
    margin-left: 0px;
    margin-top: 10.5%;
    padding-bottom: 14px;
    height: 27em;
    background: #ffffff3b !important;
}
#app > .lfe-body > a { color: #61eee9f5 !important; }
img.avatar:hover { transform: translateY(-1px); box-shadow: 3px 4px 10px #6e757a; }

/* --- 超链接 --- */
a { transition: all .15s ease; color: #005C97; text-shadow: none !important; }
a:hover { color: #fa4b4b; }
a { position: relative; }
a:not(.exlg-dash-options)::after { content: ""; width: 0; height: 4px; background: rgba(255, 0, 0, .575); position: absolute; top: 100%; left: 50%; transition: all .3s; }
a:not(.exlg-dash-options):hover::after { left: 0%; width: 100%; }

/* --- 圆角化(完整保留原有尺寸) --- */
.am-btn.am-btn-sm { border-radius: 20px !important; }
.lfe-caption.tag.status-name[data-v-43a42535] { border-radius: 20px !important; }
.card.padding-default { border-radius: 20px !important; box-shadow: 0px 0px 0px #8f8f8f; }
.lg-article { animation: slowshow .5s 1; transition: all 0.5s ease; border-radius: 20px !important; box-shadow: 0px 0px 0px #8f8f8f; }
.dropdown > .center { border-radius: 10px !important; box-shadow: 5px 5px 17px #525252cc; }
.popup[data-v-1d675dd8] { animation: showAPP .5s 1; box-shadow: 5px 5px 17px #8f8f8f7a; margin-left: 3px; width: 11.4em; height: 13.7em; background: #fff; background-clip: border-box; border-radius: 10px !important; border: 0px solid rgba(0, 0, 0, .2); transition: all 1s; }
.apps a[data-v-1d675dd8] { padding: .3em; color: #333; border-radius: 99px !important; }
.padding-none[data-v-f9624136] { border-radius: 30px !important; }
.user-nav[data-v-2dfcfd35] { animation: showUI 1s 1; transition: all .5s ease; margin-top: 20px; border-radius: 20px !important; opacity: .9; }
.card.problem-card.padding-default { animation: slowshow .5s 1; border-radius: 20px !important; box-shadow: 0px 0px 0px #8f8f8f; }
.card.padding-default { transition: all .5s ease; border-radius: 20px !important; box-shadow: 0px 0px 0px #8f8f8f; }
.inner-card { border-radius: 10px; box-shadow: 1px 1px 10px #00000036; }
.card.user-header-container.padding-0 { width: 100%; border-radius: 20px !important; box-shadow: 0px 0px 0px #8f8f8f; height: 400px; }
.card.float-card.padding-0[data-v-f9624136] { border-radius: 30px !important; transition: 1s ease; }
.card.float-card.padding-0[data-v-f9624136]:hover { border-radius: 30px !important; }
.card.user-header-container.padding-0 > .user-header-top { height: 320px; }
.select-button.lfe-form-sz-small { border-radius: 10px !important; }
.progress-frame > div[data-v-47712372] { width: 100%; height: 100%; border-radius: 10px 0 0 10px; background: linear-gradient(to right, rgb(142, 45, 226), rgb(74, 0, 224)) !important; }
.color-default > .lfe-caption { border-radius: 20px !important; }
.tag.color-none > .lfe-caption { border-radius: 20px !important; transition: all .4s; }
.tag.color-none > .lfe-caption:hover { transform: translateY(-2px) !important; }
.selected[data-v-66021821] { border-radius: 10px !important; }
.bottom.float-bottom { animation: slowshow 1s 1; margin-bottom: 4px; border-radius: 20px !important; z-index: 999; }
.card.float-card.padding-0 { border-radius: 5px !important; box-shadow: 1px 1px 20px #5c5c5c !important; }
}

/* ============================================================
   私信页
   ============================================================ */
@-moz-document url-prefix("https://www.luogu.com.cn/chat") {
.l-card.wrapper{
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/53e5czbf.webp) !important;
    border-radius: 10px !important;
    -webkit-backdrop-filter: blur(20px) !important;
    backdrop-filter: blur(20px) !important;
    box-shadow: 0px 0px 30px #000;
}
    /*
.message-block.right > .message[data-v-5c0627c6] {
    background-color: #33ccff !important;
    color: #fff !important;
    text-align: center;
}*/
html > body {
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}
.item[data-v-4d6dca7a]:hover {
    border-radius: 10px;
    transition: all .3s ease;
    background-color: #7a0ad9a6 !important;
    color: #fff;
}

}

@-moz-document url-prefix("https://www.luogu.com.cn/user/notification") {
.l-card.wrapper{
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/vjxsagwn.webp) !important;
    border-radius: 10px !important;
    -webkit-backdrop-filter: blur(20px) !important;
    backdrop-filter: blur(20px) !important;
    box-shadow: 0px 0px 30px #000;
    
}
    /*
.message-block.right > .message[data-v-5c0627c6] {
    background-color: #33ccff !important;
    color: #fff !important;
    text-align: center;
}*/
html > body {
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    opacity:0.7;
}
.item[data-v-4d6dca7a]:hover {
    border-radius: 10px;
    transition: all .3s ease;
    background-color: #7a0ad9a6 !important;
    color: #fff;
}
}
@-moz-document regexp("https://www.luogu(.org|.com.cn)/problem/.*") {
/*luogu题目*/
/*--------------------------用户自设部分--------------------------*/
/*图片背景*/
html > body {
    background-image:
        url(https://cdn.luogu.com.cn/upload/image_hosting/vjxsagwn.webp);
    background-repeat: no-repeat, no-repeat;
    background-size: cover, cover;
    background-position: center, center;
    background-attachment: fixed, fixed;
    opacity:0.7;
    /* 如果 GIF 是黑色背景,可加上 mix-blend-mode: screen; 但需谨慎 */
}
   
 .theme-page.theme-mid-full{
        opacity:1;
        background-image:
        url(https://cdn.luogu.com.cn/upload/image_hosting/6s0hd10r.webp);
       opacity:.0.7;
    }
    .panel-layout.layout-horizontal.ide-container{
        background-image: linear-gradient(135deg, rgba(255, 0, 0, 0.8), rgba(51, 204, 255, .8)); /* 红 -> 蓝 */
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    }
  .main>* .l-card.main{
    background-image:
        url(https://cdn.luogu.com.cn/upload/image_hosting/qx4kr26w.webp);/* 红 -> 蓝 */
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    }
    .sidebar-container.reverse.layout>*.main>*.l-card.problem{
        background-image:
        url(https://cdn.luogu.com.cn/upload/image_hosting/8i2l3da9.webp);
        background-repeat: no-repeat;
        background-size: cover;
        background-position: center;
        border-radius: 16px !important;
        color: #66CCFF;
    }
    .main>*.l-card{
        background-image:
        url(https://cdn.luogu.com.cn/upload/image_hosting/53e5czbf.webp);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
           border-radius: 16px !important;
    }
    .panel.panel-a>*.problem{
        background-image:
        url(https://cdn.luogu.com.cn/upload/image_hosting/53e5czbf.webp);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
           border-radius: 16px !important;
        color: #E00!important;
        text-shadow: 0 1px 1px #6CF;
        font-weight: 400 !important;
    }
    .l-card.header-card{
        background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/7nqwae4e.png) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
    }


/* 第1个卡片 */
.side>*.l-card:nth-child(1) {
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/r4dojdwm.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
     color: #E00!important;
        text-shadow: 0 1px 1px #6CF;
        font-weight: 400 !important;
}

/* 第2个卡片 */
.side>*.l-card:nth-child(2) {
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/i2sflnfw.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;

}

/* 第3个卡片 */
.side>*.l-card:nth-child(3) {
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/9ypxmgf0.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;

}
    .side>*.l-card:nth-child(4) {
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/hdbpj35y.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    }
}
    /* ============================================================
       题目页专属:取消卡片级防窥屏,鼠标触碰即全部显示
       ============================================================ */
    /* 强制题目页所有卡片和容器完全显示 */
    .lg-article, .card, .popup[data-v-1d675dd8], .user-nav[data-v-2dfcfd35],
    .am-panel.lg-index-contest, .lg-content-table-left, .am-comment-main,
    .dropdown.hown, #app > .lfe-body, .l-card, .side>*.l-card,
    .panel.panel-a, .user-header-bottom, .wrapper > .test-case {
        opacity: 1 !important;
        transition: none !important; /* 取消过渡,避免闪烁 */
    }

    /* 保证鼠标悬停或移入页面时,页面整体保持完全可见 */
    html > body {
        transition: opacity .35s ease !important;
        opacity: 1 !important;
    }
    html:hover > body {
        opacity: 1 !important;
    }
@-moz-document regexp("https://www.luogu(.org|.com.cn)/problem/list") {
/*luogu题目列表*/
/*--------------------------用户自设部分--------------------------*/
/*图片背景*/
html > body {
    background-image:
        url(https://cdn.luogu.com.cn/upload/image_hosting/dnr6trms.png);
    background-repeat: no-repeat, no-repeat;
    background-size: cover, cover;
    background-position: center, center;
    background-attachment: fixed, fixed;
    opacity:.0.5;
    /* 如果 GIF 是黑色背景,可加上 mix-blend-mode: screen; 但需谨慎 */
}
   
 
 .main>* .l-card.main{
    background-image:
        url(https://cdn.luogu.com.cn/upload/image_hosting/qx4kr26w.webp);/* 红 -> 蓝 */
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    }
    .main>*.l-card{
        background-image:
        url(https://cdn.luogu.com.cn/upload/image_hosting/53e5czbf.webp);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
           border-radius: 16px !important;
    }
}

   @-moz-document regexp("https://www.luogu.com.cn/article/.*") {
/*luogu文章*/
/*--------------------------用户自设部分--------------------------*/
/*图片背景*/
/* 清除正文外层白底 */
body:has(#article-title) main.lcolor-bg-background.main > div[style*="background-color: rgb(255, 255, 255)"] {
    background: transparent !important;
}

/* 标题玻璃:上方 16px,下方 20px */
body:has(#article-title) .article-banner.columba-content-wrap.wrapper {
    background: rgba(238, 244, 250, 0.32) !important;
    -webkit-backdrop-filter: blur(16px) saturate(120%) !important;
    backdrop-filter: blur(16px) saturate(120%) !important;
    border: none !important;
    border-radius: 13px !important;
    box-shadow: 0 8px 26px rgba(0, 0, 0, 0.10) !important;
    overflow: visible !important;
    margin-bottom: 20px !important;
    margin-top: 16px !important;
}

/* 标题内部透明 */
body:has(#article-title) .article-banner .banner-content {
    background: transparent !important;
}

/* 标题文字 */
body:has(#article-title) #article-title {
    color: rgb(25, 28, 33) !important;
    opacity: 1 !important;
    text-shadow: none !important;
}

/* 作者、发布时间与分类 */
body:has(#article-title) .article-banner .meta,
body:has(#article-title) .article-banner .meta span,
body:has(#article-title) .article-banner .meta time {
    color: rgb(50, 54, 61) !important;
    opacity: 1 !important;
    text-shadow: none !important;
}

/* 正文外层:清除顶部和左右留白 */
body:has(#article-title) .article-content.columba-content-wrap.wrapper {
    background: transparent !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
    border: none !important;
    box-shadow: none !important;
    overflow: visible !important;
    box-sizing: border-box !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
}

/* 清除正文外壳伪元素 */
body:has(#article-title) .article-content.columba-content-wrap.wrapper::before,
body:has(#article-title) .article-content.columba-content-wrap.wrapper::after {
    content: none !important;
    display: none !important;
}

/* 正文玻璃:左右内边距 24px */
body:has(#article-title) .article-content > .lfe-marked-wrap {
    box-sizing: border-box !important;
    padding: 28px 24px !important;
    background: rgba(242, 247, 252, 0.55) !important;
    -webkit-backdrop-filter: blur(18px) saturate(115%) !important;
    backdrop-filter: blur(18px) saturate(115%) !important;
    border: none !important;
    border-radius: 13px 13px 0 0 !important;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.09) !important;
    overflow: visible !important;
    width: 100% !important;
    max-width: none !important;
    min-width: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    margin-top: 0 !important;
}

/* 正文内容 */
body:has(#article-title) .article-content > .lfe-marked-wrap > .lfe-marked {
    background: transparent !important;
    margin: 0 !important;
    width: auto !important;
    max-width: none !important;
    min-width: 0 !important;
}

/* 下方信息:与正文玻璃衔接 */
body:has(#article-title) .article-content > .update-info {
    box-sizing: border-box !important;
    padding: 12px 24px 24px !important;
    background: rgba(242, 247, 252, 0.55) !important;
    -webkit-backdrop-filter: blur(18px) saturate(115%) !important;
    backdrop-filter: blur(18px) saturate(115%) !important;
    border: none !important;
    border-radius: 0 0 13px 13px !important;
    margin-top: -1px !important;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.09) !important;
    color: rgb(70, 74, 81) !important;
    text-shadow: none !important;
    width: 100% !important;
    max-width: none !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

/* 正文文字 */
body:has(#article-title) .article-content .lfe-marked,
body:has(#article-title) .article-content .lfe-marked p,
body:has(#article-title) .article-content .lfe-marked li {
    color: rgb(25, 29, 35) !important;
    opacity: 1 !important;
    text-shadow: none !important;
}

/* 正文各级标题 */
body:has(#article-title) .article-content .lfe-marked h1,
body:has(#article-title) .article-content .lfe-marked h2,
body:has(#article-title) .article-content .lfe-marked h3,
body:has(#article-title) .article-content .lfe-marked h4,
body:has(#article-title) .article-content .lfe-marked h5,
body:has(#article-title) .article-content .lfe-marked h6 {
    color: rgb(20, 23, 28) !important;
    opacity: 1 !important;
    text-shadow: none !important;
}

/* 收藏与点赞:向左偏移 28px */
body:has(#article-title) .article-content > .actions.left-mode {
    z-index: 50 !important;
    translate: -28px 0 !important;
    background: rgba(248, 250, 253, 0.86) !important;
    -webkit-backdrop-filter: blur(12px) saturate(115%) !important;
    backdrop-filter: blur(12px) saturate(115%) !important;
    border: none !important;
    border-radius: 10px !important;
    box-shadow: 0 5px 16px rgba(0, 0, 0, 0.10) !important;
}

/* 操作按钮内部透明 */
body:has(#article-title) .article-content > .actions.left-mode .button-2line {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
}

/* 隐藏底部重复操作按钮 */
body:has(#article-title) .article-content > .actions:not(.left-mode) {
    display: none !important;
}

/* 目录外壳:向右偏移 16px */
body:has(#article-title) .article-content > .toc-wrapper {
    background: transparent !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
    border: none !important;
    border-radius: 0 !important;
    box-shadow: none !important;
    overflow: visible !important;
    translate: 16px 0 !important;
}

/* 清除目录外壳伪元素 */
body:has(#article-title) .article-content > .toc-wrapper::before,
body:has(#article-title) .article-content > .toc-wrapper::after {
    content: none !important;
    display: none !important;
}

/* 目录玻璃:加宽 8px,透明度 0.7 */
body:has(#article-title) .article-content > .toc-wrapper > .toc.with-top {
    box-sizing: border-box !important;
    padding: 18px 20px !important;
    background: rgba(241, 246, 251, 0.7) !important;
    -webkit-backdrop-filter: blur(14px) saturate(112%) !important;
    backdrop-filter: blur(14px) saturate(112%) !important;
    border: none !important;
    border-radius: 10px !important;
    box-shadow: 0 5px 18px rgba(0, 0, 0, 0.08) !important;
    color: rgb(45, 49, 56) !important;
    text-shadow: none !important;
    width: calc(100% + 8px) !important;
    max-width: none !important;
}

/* 清除目录玻璃伪元素 */
body:has(#article-title) .article-content > .toc-wrapper > .toc.with-top::before,
body:has(#article-title) .article-content > .toc-wrapper > .toc.with-top::after {
    content: none !important;
    display: none !important;
    box-shadow: none !important;
}

/* 目录列表 */
body:has(#article-title) .article-content > .toc-wrapper > .toc.with-top > ul {
    background: transparent !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
    border: none !important;
    box-shadow: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* 目录项目 */
body:has(#article-title) .article-content > .toc-wrapper > .toc.with-top li {
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    color: rgb(49, 53, 60) !important;
    text-shadow: none !important;
}

/* 目录链接与文字 */
body:has(#article-title) .article-content > .toc-wrapper > .toc.with-top li span,
body:has(#article-title) .article-content > .toc-wrapper > .toc.with-top li a {
    color: rgb(49, 53, 60) !important;
    opacity: 1 !important;
    text-shadow: none !important;
}

/* 评论区 */
body:has(#article-title) .article-comment.columba-content-wrap.wrapper {
    background: rgba(242, 247, 252, 0.55) !important;
    -webkit-backdrop-filter: blur(16px) saturate(115%) !important;
    backdrop-filter: blur(16px) saturate(115%) !important;
    border: none !important;
    border-radius: 13px !important;
    box-shadow: 0 8px 28px rgba(0, 0, 0, 0.09) !important;
    margin-top: 20px !important;
}

/* 页脚 */
body:has(#article-title) footer {
    background: transparent !important;
    -webkit-backdrop-filter: none !important;
    backdrop-filter: none !important;
    filter: none !important;
    border: none !important;
    box-shadow: none !important;
}

/* 清除页脚伪元素 */
body:has(#article-title) footer::before,
body:has(#article-title) footer::after {
    content: none !important;
}

/* 页脚内容透明 */
body:has(#article-title) footer > * {
    background: transparent !important;
}

/* 窄窗口允许横向滚动 */
body:has(#article-title) {
    overflow-x: auto !important;
}
}
.l-card.header-card{
     background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/9ypxmgf0.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
     color: #E00!important;
        text-shadow: 0 1px 1px #6CF;
        font-weight: 400 !important;
}

@-moz-document regexp("https://www.luogu.com.cn/user/.*") {
/*luogu用户主页*/
/*--------------------------用户自设部分--------------------------*/
/*图片背景*/
html > body {
 
    /* 如果 GIF 是黑色背景,可加上 mix-blend-mode: screen; 但需谨慎 */
   .side>*.l-card:nth-child(1) {
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/mi2706j0.png) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
     color: #E00!important;
        text-shadow: 0 1px 1px #6CF;
        font-weight: 400 !important;
}
.side>*.l-card:nth-child(3) {
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/9ypxmgf0.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    color: #E00!important;
        text-shadow: 0 1px 1px #6CF;
        font-weight: 400 !important;
}
    .side>*.l-card:nth-child(2 ){
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/r4dojdwm.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    }
    color: #6CF!important;
        text-shadow: 0 1px 1px #6CF;
        font-weight: 400 !important;
}
    .l-flex-info-row{
        color: #6CF!important;
        text-shadow: 0 1px 1px #E00;
        font-weight: 400 !important;
    }
   .user-header-bottom{
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/6s0hd10r.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}
  .sidebar-container>*.main>*.l-card:nth-child(1) {
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/7nqwae4e.png) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
}
.sidebar-container>*.main>*.l-card:nth-child(2) {
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/um17b89i.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
}
    .sidebar-container>*.main>*.l-card:nth-child(3) {
  background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/53e5czbf.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
}
}
   .l-card.burger
    {
        background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/r4dojdwm.webp) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 20px !important;
    overflow: hidden;
    min-height: 150px;
    margin: 5px;
    opacity:1 !important;
    }
    body .l-card:has(> .user-header-top) {
    background: var(--profile-frame-glass) !important;
    -webkit-backdrop-filter: blur(18px) saturate(135%) !important;
    backdrop-filter: blur(18px) saturate(135%) !important;
    border: 1px solid rgba(255, 255, 255, 0.32) !important;
    border-radius: 14px !important;
    box-shadow: 0 10px 32px rgba(0, 0, 0, 0.16), inset 0 1px 0 rgba(255, 255, 255, 0.24) !important;
    overflow: hidden !important;
}

@-moz-document regexp("https://www.luogu.com.cn/discuss/.*") {
html > body {
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/dnr6trms.png);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    opacity: .6;
    font-weight: 600 !important;
    text-shadow: none !important;
}
.l-card {
    background-image: linear-gradient(135deg, rgba(255, 0, 0, 0.8), rgba(51, 204, 255, .8)) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 16px !important;
    color: #FFFFFF !important;
    text-shadow: none !important;
}
}

@-moz-document regexp("https://www.luogu.com.cn/discuss*") {
html > body {
    background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/dnr6trms.png);
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    opacity: .6;
    font-weight: 600 !important;
    text-shadow: none !important;
}
.l-card {
    background-image: linear-gradient(135deg, rgba(255, 0, 0, 0.8), rgba(51, 204, 255, .8)) !important;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    border-radius: 16px !important;
    color: #FFFFFF !important;
    text-shadow: none !important;
}
}


@-moz-document regexp("https://www.luogu(.org|.com.cn)/(?!blog).*") {
    /* 对比赛相关面板应用更大的圆角 */
    .am-panel.lg-index-contest.am-panel-primary,
    .am-panel.lg-index-contest.am-panel-danger,
    .am-panel.lg-index-contest.am-panel-success {
        border-radius: 24px !important; /* 原为10px,加大到24px */
        overflow: hidden !important;
    }
}


@-moz-document regexp("https://www.luogu(.org|.com.cn)/.*") {
    /* 对全局字体应用红色光晕 */
    body, p, div, span, li, td, th, h1, h2, h3, h4, h5, h6, a, .lfe-h1 {
        text-shadow: 0 0 1px #ee0000, 0 0 1px rgba(238, 0, 0, 0.3) !important;
    }
}
@-moz-document regexp("https://www.luogu(.org|.com.cn)/.*") {
    html > body {
        transition: opacity .35s ease !important;
    }

    html:not(:hover) > body {
        opacity: 0!important; /* 透明度:0 全透明,1 不透明,可自己调 */
    }
}

@-moz-document regexp("https://www.luogu(.org|.com.cn)/problem/.*") {
    /* 1. 强制题目页所有卡片和容器完全显示,取消卡片级防窥屏 */
    .lg-article, .card, .popup[data-v-1d675dd8], .user-nav[data-v-2dfcfd35],
    .am-panel.lg-index-contest, .lg-content-table-left, .am-comment-main,
    .dropdown.hown, #app > .lfe-body, .l-card, .side>*.l-card,
    .panel.panel-a, .user-header-bottom, .wrapper > .test-case,
    .card.wrapper.padding-none, .message-block, .item[data-v-4d6dca7a],
    /* 题目页可能出现的 IDE / 代码编辑器 / 题目内容容器 */
    .ide-editor, .ide-container, .problem-content, .problem-body,
    .code-editor, .editor-container, [class*="ide"], [class*="problem"] {
        opacity: 1 !important;
        transition: none !important;
    }

    /* 2. 鼠标在页面内时,整个 body 完全显示(不透明) */
    html > body {
        opacity: 1 !important;
        transition: opacity .35s ease !important;
    }

    /* 3. 鼠标移出整个浏览器窗口时,可保留防窥效果 */
    /* 如果不想防窥,把下面的 opacity 改成 1 即可 */
    html:not(:hover) > body {
        opacity: 0 !important;
    }
}

@-moz-document regexp("https://www.luogu.com.cn/record/.*") {
    html>body{
    .main>*.l-card{
        background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/r4dojdwm.webp);
        background-repeat: no-repeat;
        background-position: center;
         background-size: cover;
        background-attachment: fixed;
        opacity: .6;
        text-shadow: none !important;
    }
    .side>*.l-card{
        background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/r4dojdwm.webp);
        background-repeat: no-repeat;
        background-position: center;
         background-size: cover;
        background-attachment: fixed;
        opacity: .6;
        text-shadow: none !important;
    }
    .columba-content-wrap.main-content>*.l-card{
            background-image: url(https://cdn.luogu.com.cn/upload/image_hosting/um17b89i.webp);
        background-repeat: no-repeat;
        background-position: center;
         background-size: cover;
        background-attachment: fixed;
         opacity: .6;
        text-shadow: none !important;
    }

}
}