/* glass-style.css - 增强版 */

/* 为主要内容区域添加玻璃效果，使用 !important 提高优先级 */
#aside-content .card-widget,
#recent-posts > .recent-post-item,
#page-header:not(.full_page), /* 对非全屏的顶部图也生效 */
.layout > div:first-child:not(.recent-posts) > .card-widget,
#post > .post-info, /* 文章信息卡片 */
#post > .post-copyright, /* 版权信息卡片 */
#related-posts, /* 相关文章卡片 */
#comments > .card-widget { /* 评论区卡片 */
    background: rgba(35, 35, 35, 0.5) !important;
    -webkit-backdrop-filter: blur(15px) saturate(180%);
    backdrop-filter: blur(15px) saturate(180%);
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.1);
    box-shadow: 0 4px 30px rgba(0, 0, 0, 0.1);
}

/* 导航栏和页脚的玻璃效果 */
#nav, #footer {
    background: rgba(25, 25, 25, 0.4) !important;
    -webkit-backdrop-filter: blur(15px) saturate(180%) !important;
    backdrop-filter: blur(15px) saturate(180%) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
}

/* 其他美化修复 */
#footer a { color: #F09022 !important; }
#recent-posts > .recent-post-item,
#aside-content .card-widget { margin-bottom: 20px; }

/* ---------------------------------- */
/*  [修复] 强制代码块内容自动换行  */
/* ---------------------------------- */

/* 
 *  选择所有预格式化文本（通常是代码块）和代码标签 
 *  并强制它们打破长单词和URL进行换行。
 */
pre, code {
  white-space: pre-wrap !important; /* 允许换行 */
  word-wrap: break-word !important; /* 在单词内部换行 */
  word-break: break-all !important; /* 对于非CJK字符，允许在任意点换行 */
}

/* 
 *  Butterfly主题的代码块通常有一个 .code-container 的外层容器，
 *  我们也为它内部的代码区域设置规则，双重保险。
 */
.code-container .highlight pre {
  white-space: pre-wrap !important;
  word-wrap: break-word !important;
}
