/* =========================================================
   【CNBLOGS 修复版 CSS】
   策略：保留基础布局 + 应用最新特效 + 去除冗余冲突
   ========================================================= */

/* ------------------- 1. 基础布局与背景 (必须保留！) ------------------- */
/* 核心容器 */
#home {
    margin: 0 auto;
    width: 80%;
    min-width: 980px;
    background-color: rgba(245, 245, 245, 0.7);
    padding: 30px;
    margin-top: 50px;
    margin-bottom: 50px;
    box-shadow: 0 2px 6px rgba(100, 100, 100, 0.3);
}

/* 全局背景图 */
body {
    background: rgba(12, 100, 129, 1) url('https://img2024.cnblogs.com/blog/2929380/202602/2929380-20260205234411153-1269412029.png') fixed no-repeat;
    background-position: 50% 5%;
    background-size: cover;
}

/* 主内容区宽度 */
#main { min-width: 640px; }

/* 飘雪特效 */
#Snow {
    position: fixed; top: 0; left: 0; width: 100%; height: 100%;
    z-index: 99999; background: rgba(125,137,95,0.1); pointer-events: none;
}

/* ------------------- 2. 文章列表与内容样式 (之前误删的部分) ------------------- */
/* 文章标题左侧的蓝色竖线 */
.postTitle {
    border-left: 8px solid rgba(111, 198, 232, 0.68);
    margin-left: 10px; margin-bottom: 10px;
    font-size: 20px; float: right; width: 100%; clear: both;
}
.postTitle a:link, .postTitle a:visited, .postTitle a:active {
    color: #21759b; transition: all 0.4s linear 0s;
}
.postTitle a:hover {
    margin-left: 30px; color: #0f3647; text-decoration: none;
}

/* 文章摘要区域 */
.postCon {
    float: right; line-height: 1.5em; width: 100%; clear: both; padding: 10px 0;
}

/* 每日文章容器 */
.day { background: rgba(255, 255, 255, 0.5); }
.day .postTitle a { padding-left: 10px; }

/* 文章底部信息 (发布时间等) */
.postDesc {
    background: url(images/posted_time.png) no-repeat 0 1px;
    color: #757575; float: left; width: 100%; clear: both;
    text-align: left; font-family: "微软雅黑" , "宋体" , "黑体" ,Arial;
    font-size: 13px; padding-right: 20px; margin-top: 20px;
    line-height: 1.8; padding-bottom: 35px;
}

/* 侧边栏各个模块的背景 */
.newsItem, .catListEssay, .catListLink, .catListNoteBook, .catListTag, .catListPostCategory,
.catListPostArchive, .catListImageCategory, .catListArticleArchive, .catListView,
.catListFeedback, .mySearch, .catListComment, .catListBlogRank, .catList, .catListArticleCategory ,#blog-calendar {
    background: rgba(255, 255, 255, 0.5); margin-bottom: 35px; word-wrap: break-word;
}

/* 其他基础组件背景调整 */
.CalTitle { background: rgba(255, 255, 255, 0); }
.catListTitle { background-color: rgba(56, 184, 223, 0.466); }
#topics { background: rgba(255, 255, 255, 0.5); }
.c_ad_block { display: none; }
#tbCommentBody { width: 100%; height: 200px; background: rgba(255, 255, 255, 0.5); }
#q { background: rgba(255, 255, 255, 0); }
.CalNextPrev { background: rgba(255, 255, 255, 0); }
.cnblogs_code { background: rgba(255, 255, 255, 0); }
.cnblogs_code div { background: rgba(255, 255, 255, 0); }
.cnblogs_code_toolbar { background: rgba(255, 255, 255, 0); }
.entrylist { background: rgba(255, 255, 255, 0.5); }

/* ------------------- 3. 顶部导航 (磨砂玻璃版 - 替换旧版) ------------------- */
#header {
    background-color: rgba(255, 255, 255, 0.5) !important;
    backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px);
    border-radius: 15px !important; border: 1px solid rgba(255, 255, 255, 0.6);
    box-shadow: 0 8px 32px 0 rgba(31, 38, 135, 0.1);
    margin: 20px !important; padding: 0 !important; width: auto !important; position: relative;
}
#blogTitle {
    background: transparent !important; text-align: center;
    padding: 30px 0 10px 0; height: auto !important; margin-bottom: 0 !important;
}
#blogTitle h1 { margin: 0; line-height: 1.2; }
#blogTitle h1 a {
    color: #222 !important; font-family: "Georgia", "Times New Roman", "Songti SC", serif;
    font-size: 36px !important; font-weight: normal !important;
    letter-spacing: 1px; text-decoration: none; text-shadow: 0 1px 1px rgba(255,255,255,0.5);
}
#blogTitle h2 { display: none !important; }

#navigator {
    background-color: transparent !important; height: auto !important;
    text-align: center; margin-top: 0 !important; padding-bottom: 20px; border: none !important;
}
#navList { float: none !important; display: inline-block !important; margin: 0 !important; padding: 0 !important; }
#navList li { float: left; margin: 0 20px; background: none !important; border: none !important; }
#navList li a {
    font-family: "Georgia", "Times New Roman", serif; font-size: 18px !important; color: #333 !important;
    padding: 5px 0 !important; background: transparent !important; text-decoration: none !important;
    border: none !important; transition: all 0.3s ease; position: relative; text-shadow: 0 1px 0 rgba(255,255,255,0.4);
}
#navList li a::after {
    content: ''; position: absolute; width: 0; height: 2px; bottom: 0; left: 50%;
    background-color: #000; transition: all 0.3s ease;
}
#navList li a:hover { color: #000 !important; }
#navList li a:hover::after { width: 100%; left: 0; }

/* ------------------- 4. 字体与排版 (最新版) ------------------- */
@import url('https://fonts.loli.net/css2?family=Noto+Serif+SC:wght@300;400;700&display=swap');

body, div, p, span, a, li, input, button, textarea, .postBody, .cnblogs_post_body {
    font-family: "Noto Serif SC", "Source Han Serif SC", "SimSun", serif !important;
    -webkit-font-smoothing: antialiased;
}
pre, code, .cnblogs_code, .cnblogs_code_body {
    font-family: "Consolas", "Monaco", monospace !important;
}
h1, h2, h3, h4, h5, h6, .postTitle a {
    font-family: "Noto Serif SC", "Source Han Serif SC", serif !important;
    font-weight: 700 !important; letter-spacing: 1px !important;
}
.postBody {
    line-height: 1.85 !important; font-size: 17px !important;
    text-align: justify !important; letter-spacing: 0.5px !important; color: #222 !important;
}
.postBody span, .postBody p { font-variant-numeric: oldstyle-nums; }

/* 图片美化 */
#cnblogs_post_body img {
    border-radius: 8px; box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1); transition: all 0.3s ease;
}
#cnblogs_post_body img:hover { transform: scale(1.02); box-shadow: 0 8px 16px rgba(0, 0, 0, 0.15); }
::selection { background: #97c7d3; color: #000000; }
::-moz-selection { background: #97c7d3; color: #000000; }

/* ------------------- 5. 左侧画笔工具栏 (最新版) ------------------- */
#global-mark-canvas { position: absolute; top: 0; left: 0; z-index: 9998; display: block; background: transparent; }

#paint-center-dock {
    position: fixed; left: 20px; top: 50%; transform: translateY(-50%); z-index: 9999;
    display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 15px 8px;
    background: rgba(255, 255, 255, 0.75);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.8); border-radius: 30px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
}
.paint-btn {
    width: 36px; height: 36px; display: flex; align-items: center; justify-content: center;
    border-radius: 50%; cursor: pointer; transition: all 0.2s cubic-bezier(0.25, 0.8, 0.25, 1);
    background: rgba(255, 255, 255, 0.4);
}
.paint-btn:hover { transform: scale(1.15); background: #fff; box-shadow: 0 4px 12px rgba(0,0,0,0.1); }
.paint-btn.active {
    background: #fff; transform: scale(1.1); box-shadow: 0 4px 15px rgba(33, 117, 155, 0.2);
    border: 1px solid rgba(0,0,0,0.05);
}
.btn-icon { font-size: 20px; line-height: 1; user-select: none; }
.paint-divider { width: 20px; height: 2px; background: rgba(0, 0, 0, 0.1); margin: 2px 0; }
.paint-btn[data-tool="red-pen"].active .btn-icon { filter: drop-shadow(0 0 2px rgba(231, 76, 60, 0.5)); }

@keyframes trash-shake {
    0% { transform: scale(1) rotate(0deg); background-color: rgba(255,255,255,0.4); }
    25% { transform: scale(1.2) rotate(-15deg); background-color: #ffcccc; }
    50% { transform: scale(1.2) rotate(15deg); background-color: #ffcccc; }
    75% { transform: scale(1.2) rotate(-5deg); background-color: #ffcccc; }
    100% { transform: scale(1) rotate(0deg); background-color: rgba(255,255,255,0.4); }
}
.trash-effect { animation: trash-shake 0.4s ease-in-out; box-shadow: 0 0 15px rgba(255, 0, 0, 0.4) !important; }

/* ------------------- 6. 隐藏与净化 (隐藏推荐模块与广告) ------------------- */
/* 强制隐藏底部的推荐/反对模块 */
#div_digg, .diggit, .buryit, #digg-group {
    display: none !important; width: 0 !important; height: 0 !important; opacity: 0 !important; pointer-events: none !important;
}

/* 隐藏其他多余元素 */
#blog_nav_sitehome, #blog_nav_rss, .blogStats, #widget_my_google, #nav_next_page, .topicListFooter,
#under_post_card1, #under_post_card2, #HistoryToday, #under_post_kb, #under_post_news,
a[href*="cnblogs.vip"], .commentbox_title_left > span[style*="color:Red"] {
    display: none !important;
}

/* 评论区美化 */
.commentbox_title_right, .commentbox_title_right * { background: transparent !important; border: none !important; box-shadow: none !important; }
.comment_icon { filter: grayscale(100%) opacity(0.6) !important; width: 22px !important; height: 22px !important; transition: all 0.2s ease !important; margin: 0 4px !important; }
.comment_icon:hover { filter: grayscale(0%) opacity(1) !important; transform: scale(1.1); cursor: pointer; }
#comment_form_container, #comment_form, .commentbox_main, .commentbox_title, #tbCommentBody { width: 100% !important; max-width: 100% !important; box-sizing: border-box !important; }



/* =========================================================
   【最终强力去广】根据截图精准屏蔽 (cnblogs_ch & blog_c1)
   ========================================================= */
#cnblogs_ch,              /* 截图中的：文字广告 (键帽/AI/科研) */
#blog_c1,                 /* 截图中的：横幅图片广告 */
#ad_text_under_commentbox,/* 评论框下方的隐藏文字广告 */
#opt_under_post,          /* 底部其他推广位 */
#under_post_card1,        /* 底部推荐卡片1 */
#under_post_card2,        /* 底部推荐卡片2 */
#under_post_kb,           /* 知识库推荐 */
#under_post_news,         /* 新闻推荐 */
.c_ad_block               /* 通用广告块 */
{
    display: none !important;       /* 彻底不显示 */
    visibility: hidden !important;  /*以此为备用，防止占位 */
    height: 0 !important;           /* 高度压扁 */
    width: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
    opacity: 0 !important;
    pointer-events: none !important; /* 防止误触 */
    overflow: hidden !important;     /* 确保没有任何内容溢出 */
}








/* =========================================================
   【CNBLOGS 最终修复版 v6】
   包含：学术字体 + 极简侧边栏 + 隐藏推荐 + 极光扇形菜单 + 圆点同步
   修复：画布遮挡放大图片 (Z-index Fix: Canvas⬇️ Image⬆️)
   ========================================================= */

/* 1. 基础净化 */
@import url('https://fonts.loli.net/css2?family=Noto+Serif+SC:wght@300;400;700&display=swap');
body {
    font-family: "Noto Serif SC", serif !important;
    background: rgba(12, 100, 129, 1) url('https://img2024.cnblogs.com/blog/2929380/202602/2929380-20260205234411153-1269412029.png') fixed no-repeat;
    background-size: cover;
}
#home {
    margin: 50px auto; width: 80%; min-width: 980px;
    background-color: rgba(245, 245, 245, 0.7); padding: 30px;
    box-shadow: 0 2px 6px rgba(100, 100, 100, 0.3);
}
#div_digg, .diggit, .buryit, #digg-group, #blog_nav_sitehome, #blog_nav_rss, .c_ad_block,
#under_post_card1, #under_post_card2, #HistoryToday, #under_post_kb, #under_post_news { display: none !important; }

/* 2. 【核心修复 A】画布层级降级 */
/* 只要是非负数，且晚于 #home 加载，它自然会在文字上面 */
/* 设置为 0 或 1 足够安全，绝不与弹窗抢风头 */
#global-mark-canvas { 
    position: absolute; 
    top: 0; left: 0; 
    z-index: 0; /* 降到底 */
    background: transparent; 
}

/* 3. 【核心修复 B】强制提升放大图片层级 */
/* medium-zoom 插件在放大时会添加 --opened 类，我们把它顶到最高 */
.medium-zoom-overlay,
.medium-zoom-image--opened {
    z-index: 2147483647 !important; /* CSS 允许的最大值，确保在最顶层 */
    position: relative; /* 配合 z-index 生效 */
}


/* =========================================================
   【极光版转盘菜单】Aurora Sector Style
   ========================================================= */
#light-dial-menu {
    position: fixed; z-index: 10000; width: 50px; height: 50px;
    user-select: none; margin-left: -25px; margin-top: -25px; 
}
/* 1. 中心触发器 */
.dial-trigger {
    position: absolute; left: 0; top: 0; width: 50px; height: 50px;
    border-radius: 50%; background: #fff; color: #555;
    display: flex; align-items: center; justify-content: center;
    box-shadow: 0 4px 15px rgba(0,0,0,0.15); cursor: grab; z-index: 10;
    transition: all 0.3s ease;
    border: 1px solid rgba(255,255,255,0.8);
}
.dial-trigger:active { cursor: grabbing; transform: scale(0.9); }
.dial-trigger .icon { font-size: 24px; }

/* 2. 圆盘面板 */
.dial-disc {
    position: absolute; top: 50%; left: 50%; width: 180px; height: 180px;
    background: rgba(255, 255, 255, 0.65); border-radius: 50%;
    transform: translate(-50%, -50%) scale(0) rotate(-90deg);
    transform-origin: center center;
    transition: transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    z-index: 5; box-shadow: 0 8px 32px rgba(31, 38, 135, 0.1);
    backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.4);
    overflow: hidden;
}
#light-dial-menu.open .dial-disc { transform: translate(-50%, -50%) scale(1) rotate(0deg); }
#light-dial-menu.open .dial-trigger { 
    background: #fff; color: #ff4757; transform: none; 
    box-shadow: 0 4px 20px rgba(255, 71, 87, 0.3); 
}

/* 3. 【极光扇形】 */
#active-wedge {
    position: absolute; top: 50%; left: 50%; width: 180px; height: 180px;
    border-radius: 50%; z-index: 1;
    background: conic-gradient(from 324deg, transparent 0deg, rgba(0, 180, 255, 0.1) 10deg, rgba(0, 180, 255, 0.25) 36deg, rgba(0, 180, 255, 0.1) 62deg, transparent 72deg);
    pointer-events: none; transition: transform 0.3s cubic-bezier(0.25, 1, 0.5, 1);
}

/* 4. 菜单项 */
.dial-item {
    position: absolute; width: 40px; height: 40px;
    background: transparent; border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    cursor: pointer; top: 50%; left: 50%; margin-top: -20px; margin-left: -20px;
    z-index: 10;
}
.dial-item .icon {
    font-size: 20px; color: #777;
    transition: transform 0.2s cubic-bezier(0.25, 0.8, 0.25, 1), color 0.2s;
    display: inline-block;
}
.dial-item:hover .icon { color: #222; transform: scale(1.25); text-shadow: 0 2px 5px rgba(0,0,0,0.1); }
.dial-item.active .icon { color: #00a8ff; text-shadow: 0 0 10px rgba(0, 168, 255, 0.4); }

/* 布局 */
.item-1 { transform: rotate(-90deg) translate(65px) rotate(90deg); }
.item-2 { transform: rotate(-18deg) translate(65px) rotate(18deg); }
.item-3 { transform: rotate(54deg) translate(65px) rotate(-54deg); }
.item-4 { transform: rotate(126deg) translate(65px) rotate(-126deg); }
.item-5 { transform: rotate(198deg) translate(65px) rotate(-198deg); }

/* 圆点样式 */
.dot {
    position: absolute; 
    bottom: 2px; right: 2px;
    width: 8px; height: 8px;
    border-radius: 50%; border: 1px solid #fff; box-shadow: 0 1px 3px rgba(0,0,0,0.2);
    pointer-events: none;
}
.dial-trigger .dot { bottom: 8px; right: 8px; width: 10px; height: 10px; }

.trash-shake-anim { animation: trashShake 0.4s ease-out forwards !important; }
@keyframes trashShake {
    0% { transform: scale(1) rotate(0deg); color: #777; }
    25% { transform: scale(1.2) rotate(-15deg); color: #ff4757; }
    50% { transform: scale(1.2) rotate(15deg); color: #ff4757; }
    75% { transform: scale(1.2) rotate(-5deg); color: #ff4757; }
    100% { transform: scale(1) rotate(0deg); color: #777; }
}

/* 调色盘 */
#glass-palette {
    position: fixed; z-index: 10001; width: 160px; padding: 12px;
    background: rgba(255, 255, 255, 0.85); backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
    border-radius: 16px; box-shadow: 0 10px 40px rgba(0,0,0,0.15); border: 1px solid rgba(255,255,255,0.6);
    display: flex; flex-direction: column; gap: 10px;
    opacity: 0; pointer-events: none; transform: scale(0.9);
    transition: all 0.25s cubic-bezier(0.25, 0.8, 0.25, 1);
}
#glass-palette.show { opacity: 1; pointer-events: auto; transform: scale(1); }
.palette-title { font-size: 12px; color: #888; margin-left: 2px; font-weight: bold; }
.palette-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }
.color-swatch {
    width: 24px; height: 24px; border-radius: 50%; cursor: pointer; position: relative;
    border: 2px solid rgba(255,255,255,0.5); box-shadow: 0 2px 5px rgba(0,0,0,0.1);
    transition: transform 0.2s;
}
.color-swatch:hover { transform: scale(1.2); z-index: 2; border-color: #fff; }
.palette-custom {
    margin-top: 5px; padding-top: 8px; border-top: 1px solid rgba(0,0,0,0.05);
    text-align: center; cursor: pointer; font-size: 12px; color: #555; position: relative;
}
.palette-custom:hover { color: #1e90ff; }
.palette-custom input { position: absolute; top: 0; left: 0; width: 100%; height: 100%; opacity: 0; cursor: pointer; }