/* ========== 我的笔记 - 日记气泡风格 ========== */

/* 笔记页：去除顶部背景装饰，使用浅灰实心背景 */
.biji-page .main-content { background: #f5f6f8; }
.biji-page .right-hero-bg,
.biji-page .right-hero-overlay { display: none; }
.biji-page .content-wrapper { padding-top: 24px; }

/* 页面标题区 */
.biji-page .page-header {
    margin-bottom: 20px;
}

/* 分类筛选板块下方间距 */
.biji-page .filter-section {
    margin-bottom: 24px;
}

/* ========== 两列布局：主内容区 + 右侧精选/收藏 ========== */
.biji-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

.biji-main {
    flex: 1;
    min-width: 0;
}

.biji-sidebar {
    width: 300px;
    flex-shrink: 0;
    position: sticky;
    top: 20px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ========== 主内容区搜索框 ========== */
.biji-search {
    background: #fff;
    border-radius: 14px;
    padding: 16px;
    margin-bottom: 24px;
    border: 1px solid #f3f4f6;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.biji-search-row {
    display: flex;
    gap: 10px;
    position: relative;
}

.biji-search-icon {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #9ca3af;
    pointer-events: none;
    z-index: 2;
    display: flex;
    align-items: center;
}

.biji-search-input {
    flex: 1;
    height: 42px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    padding: 0 14px 0 40px;
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    background: #f9fafb;
}

.biji-search-input:focus {
    border-color: #6366f1;
    background-color: #fff;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.12);
}

/* 浏览器 autofill 时保持背景透明，不覆盖图标 */
.biji-search-input:-webkit-autofill,
.biji-search-input:-webkit-autofill:hover,
.biji-search-input:-webkit-autofill:focus {
    -webkit-text-fill-color: #111827;
    -webkit-box-shadow: 0 0 0 1000px #fff inset;
    transition: background-color 5000s ease-in-out 0s;
}

/* 搜索历史下拉框：宽度对齐输入框，不覆盖搜索按钮 */
.biji-search-row .search-history-dropdown {
    left: 0;
    right: 118px; /* 留出搜索按钮宽度 */
    width: auto;
}

.biji-search-btn {
    padding: 0 22px;
    height: 42px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.biji-search-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 6px 18px rgba(99, 102, 241, 0.35);
}

.biji-search-kw {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    flex-wrap: wrap;
    font-size: 12px;
}

.biji-search-kw-label {
    color: #9ca3af;
}

.biji-search-kw a {
    color: #6b7280;
    text-decoration: none;
    padding: 3px 10px;
    background: #f5f6f8;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.biji-search-kw a:hover {
    background: #eef2ff;
    color: #6366f1;
}

/* ========== 笔记气泡流 ========== */
.biji-notes {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 24px;
}

/* 单条笔记：宽度占满主内容区，给评论区留足空间 */
.biji-note {
    width: 100%;
    min-width: 0;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
}

/* 笔记头部：头像 + 发布者 + 时间 */
.biji-note-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
    padding: 0 4px;
}

.biji-note-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    background: linear-gradient(135deg, #e0e7ff, #ede9fe);
}

.biji-note-author-info {
    display: flex;
    flex-direction: column-reverse; /* 反转：日期在上（加粗大字），发布者在下 */
    gap: 2px;
    min-width: 0;
}

.biji-note-author {
    font-size: 13px;
    line-height: 1.4;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.biji-note-author-icon {
    color: #6366f1;
    flex-shrink: 0;
}

.biji-note-author-name {
    color: #4b5563;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 110px;
}

.biji-note-group-icon {
    height: 15px;
    width: auto;
    flex-shrink: 0;
    display: inline-block;
    vertical-align: middle;
    border-radius: 2px;
}

.biji-note-date {
    font-size: 12px;
    color: #9ca3af;
    line-height: 1.4;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.biji-note-date svg {
    flex-shrink: 0;
}

/* 气泡：白底圆角 */
.biji-note-bubble {
    background: #fff;
    border-radius: 18px;
    padding: 20px 22px;
    border: 1px solid #f3f4f6;
    box-shadow: 0 2px 12px rgba(0,0,0,0.05);
    position: relative;
    width: 100%;
    box-sizing: border-box;
}

/* 气泡左侧小三角（指向头像） */
.biji-note-bubble::before {
    content: '';
    position: absolute;
    top: 20px;
    left: -7px;
    width: 12px;
    height: 12px;
    background: #fff;
    border-left: 1px solid #f3f4f6;
    border-bottom: 1px solid #f3f4f6;
    transform: rotate(45deg);
    z-index: 0;
}

.biji-note-bubble > * {
    position: relative;
    z-index: 1;
}

/* 笔记标题（a 标签版，点击跳详情） */
.biji-note-title {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: #111827;
    line-height: 1.4;
    margin: 0 0 10px;
    word-break: break-word;
    text-decoration: none;
    transition: color 0.2s ease;
}

.biji-note-title:hover {
    color: #6366f1;
}

/* 笔记分类 + 类型（a 标签版，点击筛选） */
.biji-note-tags {
    display: flex;
    gap: 6px;
    margin-bottom: 12px;
    flex-wrap: wrap;
}

.biji-note-tag {
    display: inline-flex;
    align-items: center;
    padding: 3px 10px;
    font-size: 11px;
    font-weight: 500;
    border-radius: 6px;
    line-height: 1.4;
    text-decoration: none;
    transition: all 0.2s ease;
}

.biji-note-tag:hover {
    transform: translateY(-1px);
    box-shadow: 0 3px 8px rgba(0,0,0,0.08);
}

.biji-note-tag-cat {
    background: rgba(99, 102, 241, 0.08);
    color: #6366f1;
}

.biji-note-tag-type {
    background: rgba(16, 185, 129, 0.08);
    color: #059669;
}

/* ===== 主体：左内容 + 右评论 两栏布局 ===== */
.biji-note-body {
    position: relative;
    display: flex;
    gap: 16px;
    margin-bottom: 12px;
}

.biji-note-content-area {
    flex: 0 0 calc((100% - 16px) * 2 / 3);
    min-width: 0;
}

.biji-note-comment-area {
    position: absolute;
    top: 0;
    right: 0;
    bottom: 0;
    width: calc((100% - 16px) / 3);
    background: #fafafa;
    border-radius: 12px;
    padding: 14px;
    box-sizing: border-box;
    display: flex;
    flex-direction: column;
    border: 1px solid #f0f0f0;
}

/* 评论区头部 */
.biji-comment-header {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 1px solid #eee;
}

.biji-comment-title {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 14px;
    font-weight: 600;
    color: #1f2937;
}

.biji-comment-title svg {
    color: #2563eb;
}

.biji-comment-count {
    font-size: 12px;
    color: #9ca3af;
}

/* 我要评论 链接 */
.biji-comment-goto {
    margin-left: auto;
    font-size: 12px;
    color: #2563eb;
    font-weight: 500;
    padding: 3px 12px;
    background: #eff6ff;
    border-radius: 12px;
    text-decoration: none;
    transition: all 0.15s;
    white-space: nowrap;
}
.biji-comment-goto:hover {
    background: #2563eb;
    color: #fff;
}

/* 评论列表 */
.biji-comment-list {
    flex: 1;
    overflow-y: hidden;             /* 超出部分隐藏，由渐变遮罩提示 */
    min-height: 0;
    position: relative;
    /* 隐藏滚动条但保留滚轮滚动 */
    scrollbar-width: none;          /* Firefox */
    -ms-overflow-style: none;       /* IE/Edge */
}
.biji-comment-list::-webkit-scrollbar {
    display: none;                  /* Chrome/Safari */
}

.biji-comment-item {
    display: flex;
    gap: 10px;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
}

.biji-comment-item:last-child {
    border-bottom: none;
}

.biji-comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    background: #e5e7eb;
}

.biji-comment-body {
    min-width: 0;
    flex: 1;
}

.biji-comment-head {
    display: flex;
    align-items: baseline;
    gap: 8px;
    margin-bottom: 4px;
}

.biji-comment-name {
    font-size: 13px;
    font-weight: 700;
    color: #1f2937;
}

.biji-comment-date {
    font-size: 11.5px;
    color: #9ca3af;
}

.biji-comment-text {
    font-size: 13px;
    color: #374151;
    line-height: 1.6;
    word-break: break-word;
}

/* 评论中的原评论引用：内联显示，用户名蓝色 */
.biji-comment-text .original_comment {
    display: inline;
    color: #374151;
}
.biji-comment-text .original_comment .user_name {
    color: #2563eb;
    font-weight: 600;
    text-decoration: none;
}
/* 回复气泡中不重复显示原评论（原内容已在上方评论展示） */
.biji-reply-text .original_comment {
    display: none;
}
/* 覆盖 YZMCMS 内嵌的评论/回复作者名颜色（橙色 → 蓝色） */
.biji-comment-text > .user_name strong[style],
.biji-reply-text > .user_name strong[style] {
    color: #2563eb !important;
}

.biji-comment-empty {
    font-size: 13px;
    color: #9ca3af;
    text-align: center;
    padding: 24px 0;
}

/* 评论底部操作按钮 */
.biji-comment-actions {
    display: flex;
    gap: 18px;
    margin-top: 8px;
}
.biji-comment-action {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #9ca3af;
    cursor: pointer;
    transition: color 0.15s;
}
.biji-comment-action:hover {
    color: #2563eb;
}
.biji-comment-action svg {
    stroke: currentColor;
}

/* 回复列表 - 灰底气泡（只读展示） */
.biji-comment-replies {
    margin-top: 8px;
    display: flex;
    flex-direction: column;
    gap: 6px;
    width: 100%;
    box-sizing: border-box;
}
.biji-reply-bubble {
    width: 100%;
    box-sizing: border-box;
    background: #f5f5f5;
    border-radius: 8px;
    padding: 8px 12px;
    font-size: 13px;
    line-height: 1.6;
}
.biji-reply-name {
    display: none;
}
.biji-reply-text {
    color: #374151;
    word-break: break-word;
}
/* 覆盖 YZMCMS 内嵌的回复作者名颜色（橙色 → 蓝色） */
.biji-reply-text > .user_name strong[style] {
    color: #2563eb !important;
}

/* 评论版块底部渐变遮罩（仅当评论内容超出时显示） */
.biji-note-comment-area.has-overflow::after {
    content: '';
    position: absolute;
    left: 14px;
    right: 14px;
    bottom: 14px;
    height: 40px;
    background: linear-gradient(to bottom, rgba(250,250,250,0), #fafafa);
    pointer-events: none;
    z-index: 2;
    border-radius: 0 0 12px 12px;
}

/* 图片集：一排最多4张 */
.biji-note-images {
    display: flex;
    gap: 6px;
    margin: 10px 0 12px;
    flex-wrap: wrap;
}

.biji-note-images img {
    max-width: 150px;
	min-width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    transition: transform 0.2s ease;
    background: #f3f4f6;
}

.biji-note-images img:hover {
    transform: scale(1.04);
}

/* 笔记缘起/问题框（content 前方，浅色圆角线框） */
.biji-note-wenti {
    max-width: 100%;
    box-sizing: border-box;
    margin-bottom: 12px;
    padding: 12px 14px;
    background: #f0f5ff;
    border: 1px solid #d6e0ff;
    border-radius: 10px;
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 13px;
    line-height: 1.7;
    color: #5b6b8e;
    word-break: break-word;
}

.biji-wenti-icon {
    flex-shrink: 0;
    margin-top: 2px;
    color: #8195d6;
    display: flex;
    align-items: center;
    justify-content: center;
}

.biji-wenti-text {
    flex: 1;
    min-width: 0;
}

.biji-wenti-text p {
    margin: 0;
}

/* 笔记正文：限高300px，超出渐变隐藏 */
.biji-note-content {
    font-size: 14px;
    line-height: 1.75;
    color: #4b5563;
    word-break: break-word;
    max-height: 600px; /* 从 300px 提到 600px，让富文本预览能展示更多内容 */
    overflow: hidden;
    position: relative;
    transition: max-height 0.3s ease;
}

.biji-note-content.expanded {
    max-height: 2000px;
}

/* 渐变遮罩（仅在收起时显示） */
.biji-note-content.has-more:not(.expanded)::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background: linear-gradient(to bottom, rgba(255,255,255,0), #fff);
    pointer-events: none;
}

.biji-note-content p {
    margin: 0 0 10px;
}

.biji-note-content p:last-child {
    margin-bottom: 0;
}

/* ===== 笔记正文富文本元素样式 =====
   覆盖 h2/h3/h4、img、blockquote、pre、code、ol/ul/li、hr、a、table
   全部限定在 .biji-note-content 作用域内，避免污染气泡外部样式 */

/* 标题：层级清晰，颜色比正文更深 */
.biji-note-content h2,
.biji-note-content h3,
.biji-note-content h4 {
    color: #111827;
    font-weight: 700;
    line-height: 1.4;
    margin: 18px 0 10px;
    word-break: break-word;
}

.biji-note-content h2 {
    font-size: 18px;
    padding-bottom: 8px;
    border-bottom: 1px solid #f0f1f3;
}

.biji-note-content h3 {
    font-size: 16px;
}

.biji-note-content h4 {
    font-size: 14.5px;
    color: #374151;
}

.biji-note-content h2:first-child,
.biji-note-content h3:first-child,
.biji-note-content h4:first-child {
    margin-top: 0;
}

/* 图片：圆角 + 限宽不超出父级 + 限高避免图片吃掉预览高度预算 */
.biji-note-content img {
    max-width: 100%;
    max-height: 280px;
    width: auto;
    height: auto;
    border-radius: 10px;
    margin: 10px 0 12px;
    display: block;
    background: #f3f4f6;
    object-fit: contain;
}

/* 引用块：左侧主色竖条 + 浅底 */
.biji-note-content blockquote {
    margin: 12px 0;
    padding: 10px 14px;
    background: #f9fafb;
    border-left: 3px solid #6366f1;
    border-radius: 0 8px 8px 0;
    color: #4b5563;
    font-size: 13.5px;
    line-height: 1.7;
}

.biji-note-content blockquote p {
    margin: 0 0 6px;
}

.biji-note-content blockquote p:last-child {
    margin-bottom: 0;
}

/* 代码块：深色背景 + 圆角 + 横向滚动 */
.biji-note-content pre {
    margin: 12px 0;
    padding: 14px 16px;
    background: #1f2937;
    color: #e5e7eb;
    border-radius: 10px;
    font-family: "JetBrains Mono", "Fira Code", "Consolas", monospace;
    font-size: 12.5px;
    line-height: 1.6;
    -webkit-overflow-scrolling: touch;
    white-space: pre-wrap;
}

.biji-note-content pre code {
    background: transparent;
    padding: 0;
    color: inherit;
    font-size: inherit;
    border-radius: 0;
}

/* 行内 code：浅底圆角 */
.biji-note-content code {
    font-family: "JetBrains Mono", "Fira Code", "Consolas", monospace;
    font-size: 12.5px;
    padding: 2px 6px;
    background: #f3f4f6;
    color: #db2777;
    border-radius: 4px;
    word-break: break-word;
}

.biji-note-content em {
    font-size: 12.5px;
    padding: 2px 6px;
    background: #f3f4f6;
    color: #6366f1;
    border-radius: 4px;
    word-break: break-word;
	font-style: normal;
	font-weight: bold;
}

/* 列表：统一缩进，主色 marker */
.biji-note-content ul,
.biji-note-content ol {
    margin: 10px 0 12px;
    padding-left: 24px;
    line-height: 1.75;
}

.biji-note-content ul {
    list-style: disc;
}

.biji-note-content ol {
    list-style: decimal;
}

.biji-note-content li {
    margin: 4px 0;
}

.biji-note-content li > ul,
.biji-note-content li > ol {
    margin: 4px 0 0;
}

.biji-note-content li::marker {
    color: #6366f1;
}

/* 分隔线 */
.biji-note-content hr {
    border: 0;
    border-top: 1px solid #f0f1f3;
    margin: 16px 0;
    height: 0;
}

/* 链接：主色 + 半透明下划线 */
.biji-note-content a {
    color: #6366f1;
    text-decoration: underline;
    text-decoration-color: rgba(99, 102, 241, 0.4);
    text-underline-offset: 2px;
    transition: color 0.2s ease;
    word-break: break-word;
}

.biji-note-content a:hover {
    color: #4f46e5;
    text-decoration-color: #4f46e5;
}

/* 表格：兼容粘贴内容 */
.biji-note-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 12px 0;
    font-size: 13px;
    display: block;
    overflow-x: auto;
}

.biji-note-content th,
.biji-note-content td {
    border: 1px solid #e5e7eb;
    padding: 8px 10px;
    text-align: left;
    vertical-align: top;
}

.biji-note-content th {
    background: #f9fafb;
    color: #1f2937;
    font-weight: 600;
}

.biji-note-content tr:nth-child(even) td {
    background: #fafbfc;
}

/* 强制换行：覆盖内容中可能粘贴的 nowrap 内联样式
   （text-wrap-mode:nowrap / white-space:nowrap 都强制改为可换行） */
.biji-note-content [style*="nowrap"] {
    text-wrap-mode: wrap !important;
    white-space: normal !important;
    word-break: break-word;
    overflow-wrap: break-word;
}

/* more 按钮 */
.biji-note-more {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    margin-top: 10px;
    color: #6366f1;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    user-select: none;
    background: none;
    border: none;
    padding: 4px 0;
    transition: color 0.2s ease;
}

.biji-note-more:hover {
    color: #4f46e5;
}

.biji-note-more svg {
    transition: transform 0.2s ease;
}

.biji-note-more.expanded svg {
    transform: rotate(180deg);
}

/* 查看原文链接：放在 footer 最右侧，仅有外部链接的笔记显示 */
.biji-note-source {
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12.5px;
    font-weight: 500;
    color: #6366f1;
    text-decoration: none;
    padding: 4px 10px;
    border-radius: 8px;
    background: rgba(99, 102, 241, 0.08);
    transition: all 0.2s ease;
    align-self: center;
}

.biji-note-source:hover {
    color: #4f46e5;
    background: rgba(99, 102, 241, 0.15);
}

.biji-note-source svg {
    width: 12px;
    height: 12px;
    flex-shrink: 0;
}

/* 笔记底部：灰色横线 + 评论/收藏/分享 + 查看原文 */
.biji-note-footer {
    margin-top: 14px;
    padding-top: 12px;
    border-top: 1px solid #f0f1f3;
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: nowrap;
    color: #9ca3af;
    font-size: 13px;
}

.biji-note-action {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    cursor: pointer;
    user-select: none;
    transition: color 0.2s ease;
    flex-shrink: 0;
}

.biji-note-action:hover {
    color: #6366f1;
}

.biji-note-action.active {
    color: #ef4444;
}

.biji-note-action.faved {
    color: #ef4444;
}

.biji-note-action.faved svg {
    fill: #ef4444;
}

.biji-note-action.shared {
    color: #10b981;
}

.biji-note-action svg {
    flex-shrink: 0;
}

/* ========== 右侧侧栏板块 ========== */
.biji-side-section {
    background: #fff;
    border-radius: 16px;
    padding: 20px;
    border: 1px solid #f3f4f6;
    box-shadow: 0 2px 12px rgba(0,0,0,0.04);
}

.biji-side-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 16px;
    line-height: 1.3;
}

.biji-side-title svg {
    color: #6366f1;
}

.biji-side-title .biji-side-more {
    margin-left: auto;
    font-size: 12px;
    color: #9ca3af;
    text-decoration: none;
    font-weight: 500;
}

.biji-side-title .biji-side-more:hover {
    color: #6366f1;
}

.biji-side-list {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.biji-side-item {
    display: flex;
    align-items: center;
    gap: 10px;
    text-decoration: none;
    color: inherit;
    padding: 8px;
    border-radius: 10px;
    transition: background 0.2s ease;
}

.biji-side-item:hover {
    background: #f9fafb;
}

.biji-side-empty {
    padding: 20px 10px;
    text-align: center;
    color: #9ca3af;
    font-size: 13px;
    line-height: 1.6;
}

/* 排名徽章 */
.biji-side-rank {
    width: 22px;
    height: 22px;
    border-radius: 6px;
    background: #f3f4f6;
    color: #6b7280;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.biji-side-rank.top1 {
    background: linear-gradient(135deg, #f59e0b, #ef4444);
    color: #fff;
}

.biji-side-rank.top2 {
    background: linear-gradient(135deg, #6b7280, #4b5563);
    color: #fff;
}

.biji-side-rank.top3 {
    background: linear-gradient(135deg, #d97706, #b45309);
    color: #fff;
}

/* 缩略图 */
.biji-side-thumb {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    object-fit: cover;
    flex-shrink: 0;
    background: #f3f4f6;
}

.biji-side-info {
    flex: 1;
    min-width: 0;
}

.biji-side-name {
    font-size: 13px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 3px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.biji-side-desc {
    font-size: 11px;
    color: #9ca3af;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 4px;
}

.biji-side-tag {
    display: inline-block;
    padding: 1px 6px;
    background: rgba(99, 102, 241, 0.08);
    color: #6366f1;
    border-radius: 4px;
    font-size: 10px;
    font-weight: 500;
}

/* 收藏图标徽章 */
.biji-side-fav-icon {
    width: 32px;
    height: 32px;
    border-radius: 8px;
    background: linear-gradient(135deg, #fef3c7, #fde68a);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #b45309;
}

/* 响应式：缩窗时侧栏挪到主内容下方平铺，不再隐藏 */
@media (max-width: 1100px) {
    /* 缩窗时侧栏不隐藏，挪到主内容下方平铺，避免内容缺失 */
    .biji-layout { flex-direction: column; }
    .biji-sidebar {
        width: 100%;
        position: static;
        flex-direction: row;
        flex-wrap: wrap;
    }
    .biji-side-section {
        flex: 1 1 280px;
    }
    .biji-note { min-width: 0; width: 100%; }
}

@media (max-width: 640px) {
    /* 真移动端：侧栏再恢复为纵向堆叠 */
    .biji-sidebar { flex-direction: column; }
    .biji-side-section { flex: none; }
}

@media (max-width: 640px) {
    .biji-page .content-wrapper { padding: 16px; }
    .biji-note-bubble { padding: 16px; }
    .biji-note-images img { width: 64px; height: 64px; }
    .biji-search { padding: 12px; }
}

/* ========== 图片放大灯箱 ========== */
.biji-lightbox {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.88);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    cursor: zoom-out;
    animation: biji-fade-in 0.2s ease;
}

.biji-lightbox.active {
    display: flex;
}

@keyframes biji-fade-in {
    from { opacity: 0; }
    to { opacity: 1; }
}

.biji-lightbox-img {
    max-width: 90vw;
    max-height: 88vh;
    object-fit: contain;
    border-radius: 8px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    user-select: none;
    pointer-events: none;
}

.biji-lightbox-close {
    position: absolute;
    top: 20px;
    right: 24px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 24px;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.2s ease;
    border: none;
    padding: 0;
}

.biji-lightbox-close:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* 左右切换按钮 */
.biji-lightbox-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    border: none;
    cursor: pointer;
    display: none;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 10;
}

.biji-lightbox-nav.show {
    display: flex;
}

.biji-lightbox-nav:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: translateY(-50%) scale(1.05);
}

.biji-lightbox-prev { left: 32px; }
.biji-lightbox-next { right: 32px; }

@media (max-width: 768px) {
    .biji-note-body {
        flex-direction: column;
    }
    .biji-note-content-area {
        flex: 0 0 100%;
    }
    .biji-note-comment-area {
        position: static;
        width: 100%;
        margin-top: 4px;
    }
    .biji-lightbox-prev { left: 8px; }
    .biji-lightbox-next { right: 8px; }
    .biji-lightbox-nav { width: 44px; height: 44px; }
}

.biji-lightbox-caption {
    position: absolute;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    color: rgba(255, 255, 255, 0.85);
    font-size: 13px;
    background: rgba(0, 0, 0, 0.4);
    padding: 6px 14px;
    border-radius: 20px;
    max-width: 80vw;
    text-align: center;
}

/* ============================================================
   ========== 笔记详情页（show_biji）样式 ==========
   ============================================================ */

/* ---------- 两栏布局 ---------- */
.biji-detail-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
    margin-top: 8px;
}

.biji-detail-main {
    flex: 1;
    min-width: 0;
    max-width: 800px;
}

.biji-detail-sidebar {
    width: 300px;
    flex-shrink: 0;
    position: sticky;
    top: 20px;
    align-self: flex-start;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* ---------- 笔记主体卡片 ---------- */
.biji-detail-card {
    background: #fff;
    border-radius: 16px;
    padding: 36px 44px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
    margin-bottom: 24px;
    border: 1px solid #f3f4f6;
}

/* 分类标签 */
.biji-detail-tags {
    display: flex;
    gap: 8px;
    margin-bottom: 16px;
}

.biji-detail-tag {
    display: inline-flex;
    align-items: center;
    padding: 3px 12px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 500;
}

.biji-detail-tag.cat {
    background: #eef2ff;
    color: #6366f1;
}

.biji-detail-tag.type {
    background: #f0fdf4;
    color: #16a34a;
}

/* 标题 */
.biji-detail-title {
    font-size: 26px;
    font-weight: 700;
    color: #1a1a2e;
    line-height: 1.5;
    margin: 0 0 20px;
    letter-spacing: 0.3px;
}

/* 作者信息条 */
.biji-detail-author-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
    border-top: 1px solid #f0f0f5;
    border-bottom: 1px solid #f0f0f5;
    margin-bottom: 28px;
    gap: 16px;
}

.biji-detail-author-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.biji-detail-author-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 2px solid #f0f0f5;
}

.biji-detail-author-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    min-width: 0;
}

.biji-detail-author-name {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 600;
    color: #1f2937;
}

.biji-detail-group-icon {
    width: 16px;
    height: 16px;
    border-radius: 50%;
}

.biji-detail-meta {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 12.5px;
    color: #9ca3af;
    flex-wrap: wrap;
}

.biji-detail-meta-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.biji-detail-meta-item svg {
    color: #d1d5db;
}

.biji-detail-author-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.biji-detail-external-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 7px 14px;
    background: #f5f6f8;
    color: #6b7280;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    transition: all 0.2s ease;
}

.biji-detail-external-btn:hover {
    background: #eef2ff;
    color: #6366f1;
}

/* ---------- 正文 ---------- */
.biji-detail-body {
    margin-bottom: 24px;
}

.biji-detail-intro {
    font-size: 15px;
    color: #4b5563;
    line-height: 1.8;
    padding: 14px 18px;
    background: linear-gradient(135deg, #f9fafb, #f5f6f8);
    border-left: 3px solid #6366f1;
    border-radius: 0 10px 10px 0;
    margin: 0 0 24px;
}

.biji-detail-content {
    font-size: 15px;
    line-height: 1.85;
    color: #374151;
    word-break: break-word;
}

.biji-detail-content > *:first-child { margin-top: 0; }
.biji-detail-content > *:last-child { margin-bottom: 0; }

.biji-detail-content p { margin: 14px 0; }

.biji-detail-content h2,
.biji-detail-content h3,
.biji-detail-content h4 {
    color: #1f2937;
    font-weight: 700;
    margin: 28px 0 14px;
    line-height: 1.4;
}

.biji-detail-content h2 { font-size: 20px; }
.biji-detail-content h3 { font-size: 17px; }
.biji-detail-content h4 { font-size: 15px; }

.biji-detail-content img {
    max-width: 100%;
    height: auto;
    border-radius: 10px;
    margin: 14px 0;
    cursor: zoom-in;
}

.biji-detail-content blockquote {
    margin: 16px 0;
    padding: 12px 18px;
    background: #f9fafb;
    border-left: 3px solid #c7d2fe;
    border-radius: 0 8px 8px 0;
    color: #6b7280;
}

.biji-detail-content blockquote p { margin: 0; }

.biji-detail-content em{
    padding: 2px 6px;
    margin: 0 3px;
    background: #f3f4f6;
    color: #6366f1;
    border-radius: 4px;
    word-break: break-word;
    font-style: normal;
}

.biji-detail-content pre {
    background: #1e293b;
    color: #e2e8f0;
    padding: 16px 18px;
    border-radius: 10px;
    overflow-x: auto;
    font-size: 13px;
    line-height: 1.6;
    margin: 16px 0;
}

.biji-detail-content pre code {
    background: none;
    padding: 0;
    color: inherit;
}

.biji-detail-content code {
    background: #f1f5f9;
    color: #e11d48;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 13px;
}

.biji-detail-content ul,
.biji-detail-content ol {
    padding-left: 22px;
    margin: 12px 0;
}

.biji-detail-content li { margin: 6px 0; }

.biji-detail-content a {
    color: #6366f1;
    text-decoration: underline;
    text-decoration-color: rgba(99, 102, 241, 0.4);
    word-break: break-word;
}

.biji-detail-content a:hover { color: #4f46e5; }

.biji-detail-content hr {
    border: 0;
    border-top: 1px solid #f0f1f3;
    margin: 20px 0;
}

.biji-detail-content table {
    width: 100%;
    border-collapse: collapse;
    margin: 14px 0;
    font-size: 13px;
    display: block;
    overflow-x: auto;
}

.biji-detail-content th,
.biji-detail-content td {
    border: 1px solid #e5e7eb;
    padding: 8px 12px;
    text-align: left;
}

.biji-detail-content th {
    background: #f9fafb;
    font-weight: 600;
}

/* 私密提示 */
.biji-detail-private-tip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 20px;
    padding: 6px 14px;
    background: #fef3c7;
    color: #b45309;
    border-radius: 8px;
    font-size: 13px;
}

.biji-detail-private-block {
    text-align: center;
    padding: 60px 20px;
}

.biji-detail-private-icon {
    width: 64px;
    height: 64px;
    margin: 0 auto 16px;
    border-radius: 50%;
    background: #f3f4f6;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
}

.biji-detail-private-text {
    font-size: 16px;
    color: #6b7280;
    margin: 0 0 8px;
    font-weight: 600;
}

.biji-detail-private-sub {
    font-size: 13px;
    color: #9ca3af;
    margin: 0;
}

/* ---------- 关键词标签 ---------- */
.biji-detail-keywords {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 24px;
    padding-top: 20px;
    border-top: 1px dashed #f0f1f3;
}

.biji-detail-keyword {
    display: inline-block;
    padding: 4px 12px;
    background: #f5f6f8;
    color: #6b7280;
    border-radius: 6px;
    font-size: 12.5px;
    text-decoration: none;
    transition: all 0.2s ease;
}

.biji-detail-keyword:hover {
    background: #eef2ff;
    color: #6366f1;
}

/* ---------- 互动栏 ---------- */
.biji-detail-actions {
    display: flex;
    gap: 12px;
    padding-top: 20px;
    border-top: 1px solid #f0f0f5;
}

.biji-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 18px;
    background: #f5f6f8;
    border: none;
    border-radius: 10px;
    color: #6b7280;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.biji-action-btn:hover {
    background: #eef2ff;
    color: #6366f1;
    transform: translateY(-1px);
}

.biji-action-btn svg { flex-shrink: 0; }

.biji-action-count { font-weight: 500; }

/* ============================================================
   ========== 评论区（详情页专用，biji-dc-* 前缀避免与列表页冲突） ==========
   ============================================================ */
.biji-dc-section {
    background: #fff;
    border-radius: 16px;
    padding: 32px 44px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
    border: 1px solid #f3f4f6;
}

.biji-dc-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 18px;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 24px;
}

.biji-dc-title-text {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.biji-dc-title-text svg { color: #6366f1; }

.biji-dc-count {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 24px;
    height: 22px;
    padding: 0 8px;
    background: #eef2ff;
    color: #6366f1;
    border-radius: 11px;
    font-size: 12.5px;
    font-weight: 600;
}

.biji-dc-tip {
    margin-left: auto;
    font-size: 12px;
    color: #d1d5db;
    font-weight: 400;
}

/* 评论表单 */
.biji-dc-form-wrap {
    margin-bottom: 28px;
}

.biji-dc-form-inner {
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    overflow: hidden;
    transition: border-color 0.2s ease;
}

.biji-dc-form-inner:focus-within {
    border-color: #6366f1;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.biji-dc-textarea {
    width: 100%;
    box-sizing: border-box;
    border: none;
    outline: none;
    resize: vertical;
    padding: 14px 16px;
    font-size: 14px;
    line-height: 1.6;
    color: #374151;
    min-height: 80px;
    font-family: inherit;
    display: block;
}

.biji-dc-textarea::placeholder { color: #9ca3af; }

.biji-dc-form-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    background: #f9fafb;
    border-top: 1px solid #f0f1f3;
    gap: 10px;
}

.biji-dc-form-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.biji-dc-code-wrap {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.biji-dc-code-img {
    height: 30px;
    border-radius: 5px;
    cursor: pointer;
    border: 1px solid #e5e7eb;
}

.biji-dc-code-input {
    width: 70px;
    height: 30px;
    box-sizing: border-box;
    border: 1px solid #e5e7eb;
    border-radius: 6px;
    padding: 0 8px;
    font-size: 13px;
    outline: none;
}

.biji-dc-submit {
    padding: 7px 20px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.biji-dc-submit:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
}

/* 评论列表 */
.biji-dc-list { display: flex; flex-direction: column; gap: 20px; }

.biji-dc-item {
    display: flex;
    gap: 12px;
}

.biji-dc-avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid #f0f1f3;
}

.biji-dc-body { flex: 1; min-width: 0; }

.biji-dc-head {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 5px;
}

.biji-dc-name {
    font-size: 13.5px;
    font-weight: 600;
    color: #1f2937;
}

.biji-dc-time {
    font-size: 12px;
    color: #9ca3af;
}

.biji-dc-text {
    font-size: 14px;
    line-height: 1.7;
    color: #4b5563;
    word-break: break-word;
}

.biji-dc-item-actions {
    margin-top: 6px;
}

.biji-dc-reply-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 12.5px;
    color: #9ca3af;
    text-decoration: none;
    cursor: pointer;
    transition: color 0.2s ease;
}

.biji-dc-reply-btn:hover { color: #6366f1; }

.biji-dc-reply-form-wrap {
    margin-top: 12px;
    padding: 12px;
    background: #fafbfc;
    border-radius: 10px;
    border: 1px solid #f0f1f3;
}

/* 评论中的原评论引用（.original_comment） */
.biji-dc-text .original_comment {
    display: block;
    padding: 8px 12px;
    margin-bottom: 10px;
    background: #f9fafb;
    border-left: 3px solid #e5e7eb;
    border-radius: 0 8px 8px 0;
    color: #9ca3af;
    font-size: 13px;
    line-height: 1.6;
}

.biji-dc-text .original_comment .user_name {
    color: #6b7280;
    font-weight: 600;
    text-decoration: none;
}

/* 回复内容气泡（灰底，与原评论区分） */
.biji-dc-reply-bubble {
    margin-top: 10px;
    padding: 10px 14px;
    background: #f3f4f6;
    border-radius: 10px;
    font-size: 14px;
    line-height: 1.7;
    color: #374151;
    word-break: break-word;
}

.biji-dc-reply-bubble .user_name {
    color: #de4c1c;
    font-weight: 600;
    text-decoration: none;
}

.biji-dc-empty {
    text-align: center;
    padding: 40px 20px;
    color: #9ca3af;
    font-size: 14px;
}

/* ============================================================
   ========== 右侧：作者信息卡片 ==========
   ============================================================ */
.biji-author-card {
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
    border: 1px solid #f3f4f6;
}

.biji-author-card-header {
    height: 72px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    position: relative;
}

.biji-author-card-body {
    padding: 0 20px 20px;
    text-align: center;
}

.biji-author-card-avatar {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    margin-top: -32px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 2;
}

.biji-author-card-name {
    margin-top: 10px;
    font-size: 16px;
    font-weight: 700;
    color: #1f2937;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
}

.biji-author-card-group {
    width: 16px;
    height: 16px;
    border-radius: 50%;
}

.biji-author-card-motto {
    margin-top: 6px;
    font-size: 12.5px;
    color: #9ca3af;
    line-height: 1.5;
    padding: 0 8px;
}

.biji-author-card-intro {
    margin-top: 12px;
    padding: 10px 12px;
    background: #f9fafb;
    border-radius: 8px;
    font-size: 12.5px;
    color: #6b7280;
    line-height: 1.6;
    text-align: left;
}

.biji-author-card-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-top: 16px;
    gap: 0;
}

.biji-author-stat {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 20px;
}

.biji-author-stat-num {
    font-size: 18px;
    font-weight: 700;
    color: #1f2937;
}

.biji-author-stat-label {
    font-size: 12px;
    color: #9ca3af;
    margin-top: 2px;
}

.biji-author-stat-divider {
    width: 1px;
    height: 28px;
    background: #f0f1f3;
}

.biji-author-card-btns {
    display: flex;
    gap: 10px;
    margin-top: 16px;
}

.biji-author-follow-btn,
.biji-author-pm-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    height: 36px;
    border: none;
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.biji-author-follow-btn {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
}

.biji-author-follow-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(99, 102, 241, 0.35);
}

.biji-author-pm-btn {
    background: #f5f6f8;
    color: #6b7280;
}

.biji-author-pm-btn:hover {
    background: #eef2ff;
    color: #6366f1;
}

.biji-author-home-btn {
    flex: 1;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 5px;
    height: 36px;
    border: 1px solid #e5e7eb;
    border-radius: 10px;
    font-size: 13.5px;
    font-weight: 600;
    background: #fff;
    color: #6b7280;
    cursor: pointer;
    transition: all 0.2s ease;
    text-decoration: none;
}

.biji-author-home-btn:hover {
    background: #f9fafb;
    color: #6366f1;
    border-color: #c7d2fe;
}

.biji-author-follow-btn.followed {
    background: #f3f4f6;
    color: #6b7280;
}

.biji-author-follow-btn.followed:hover {
    box-shadow: none;
    transform: none;
    background: #e5e7eb;
}

/* ============================================================
   ========== 右侧：历史发布记录 ==========
   ============================================================ */
.biji-history-card {
    background: #fff;
    border-radius: 16px;
    padding: 18px 20px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.05);
    border: 1px solid #f3f4f6;
}

.biji-history-header {
    margin-bottom: 12px;
}

.biji-history-title {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}

.biji-history-title svg { color: #6366f1; }

.biji-history-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.biji-history-item { margin: 0; }

.biji-history-link {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 4px;
    text-decoration: none;
    color: #4b5563;
    font-size: 13px;
    border-bottom: 1px solid #f9fafb;
    transition: all 0.15s ease;
}

.biji-history-item:last-child .biji-history-link { border-bottom: none; }

.biji-history-link:hover {
    color: #6366f1;
    background: #fafbff;
    border-radius: 6px;
}

.biji-history-dot {
    width: 5px;
    height: 5px;
    border-radius: 50%;
    background: #d1d5db;
    flex-shrink: 0;
}

.biji-history-link:hover .biji-history-dot { background: #6366f1; }

.biji-history-text {
    flex: 1;
    min-width: 0;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    line-height: 1.4;
}

.biji-history-date {
    font-size: 11.5px;
    color: #9ca3af;
    flex-shrink: 0;
}

.biji-history-empty {
    text-align: center;
    padding: 20px;
    color: #9ca3af;
    font-size: 13px;
}

/* ============================================================
   ========== 详情页响应式 ==========
   ============================================================ */
@media (max-width: 1180px) {
    .biji-detail-layout { flex-direction: column; }
    .biji-detail-sidebar {
        width: 100%;
        position: static;
        flex-direction: row;
        flex-wrap: wrap;
    }
    .biji-author-card,
    .biji-history-card { flex: 1 1 280px; }
}

@media (max-width: 768px) {
    .biji-detail-card,
    .biji-dc-section { padding: 20px 16px; }
    .biji-detail-title { font-size: 20px; }
    .biji-detail-author-bar { flex-direction: column; align-items: flex-start; }
    .biji-detail-sidebar { flex-direction: column; }
    .biji-dc-title { flex-wrap: wrap; }
    .biji-dc-tip { margin-left: 0; width: 100%; }
}

/* ========== 广告展示区（与导航页风格一致，5列） ========== */
.biji-ad-section {
    margin-bottom: 24px;
    padding: 20px;
    background: #fff;
    border-radius: 16px;
    border: 1px solid #f3f4f6;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
}
.biji-ad-section .ad-section-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
}
.biji-ad-section .ad-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 17px;
    font-weight: 700;
    color: #1f2937;
    margin: 0;
}
.biji-ad-section .ad-section-title::before {
    content: '';
    width: 4px;
    height: 18px;
    background: linear-gradient(180deg, #6366f1, #8b5cf6);
    border-radius: 2px;
}
.biji-ad-section .ad-section-tag {
    font-size: 11px;
    color: #9ca3af;
    background: #f3f4f6;
    padding: 2px 8px;
    border-radius: 4px;
    line-height: 1.4;
}
.biji-ad-section .ad-grid {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 14px;
}
.biji-ad-section .ad-item {
    position: relative;
    display: block;
    border-radius: 10px;
    overflow: hidden;
    background: #f3f4f6;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.biji-ad-section .ad-item a {
    display: block;
    text-decoration: none;
    color: inherit;
}
.biji-ad-section .ad-item img {
    width: 100%;
    aspect-ratio: 16 / 9;
    object-fit: cover;
    display: block;
}
.biji-ad-section .ad-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.1);
}
/* 广告角标：右下角「广告」小标签 */
.biji-ad-section .ad-item::after {
    content: '广告';
    position: absolute;
    right: 6px;
    bottom: 6px;
    font-size: 10px;
    color: rgba(255, 255, 255, 0.8);
    background: rgba(0, 0, 0, 0.25);
    padding: 1px 6px;
    border-radius: 3px;
    line-height: 1.4;
    pointer-events: none;
    z-index: 2;
}

/* ============================================================
   ========== 底部悬浮发布按钮 ==========
   ============================================================ */
.biji-fab-wrap {
    position: fixed;
    right: 32px;
    bottom: 32px;
    z-index: 9000;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 12px;
}

.biji-fab-btn {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 13px 24px;
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: #fff;
    text-decoration: none;
    border-radius: 28px;
    font-size: 15px;
    font-weight: 600;
    box-shadow: 0 6px 20px rgba(99, 102, 241, 0.35);
    transition: all 0.25s ease;
    cursor: pointer;
}

.biji-fab-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 28px rgba(99, 102, 241, 0.45);
}

.biji-fab-btn:active {
    transform: translateY(0);
}

.biji-fab-btn svg {
    flex-shrink: 0;
}

/* 说明卡片（hover 展开） */
.biji-fab-card {
    background: #fff;
    border-radius: 14px;
    padding: 16px 18px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    border: 1px solid #f0f0f5;
    max-width: 320px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px) scale(0.95);
    transform-origin: bottom right;
    transition: all 0.25s ease;
    pointer-events: none;
}

.biji-fab-wrap:hover .biji-fab-card {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) scale(1);
    pointer-events: auto;
}

.biji-fab-card-icon {
    flex-shrink: 0;
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: linear-gradient(135deg, #eef2ff, #f5f3ff);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #6366f1;
}

.biji-fab-card-body {
    flex: 1;
    min-width: 0;
}

.biji-fab-card-title {
    font-size: 15px;
    font-weight: 700;
    color: #1f2937;
    margin-bottom: 4px;
}

.biji-fab-card-desc {
    font-size: 12.5px;
    line-height: 1.6;
    color: #6b7280;
}

/* 响应式：小屏适配 */
@media (max-width: 768px) {
    .biji-fab-wrap {
        right: 16px;
        bottom: 16px;
    }
    .biji-fab-btn {
        padding: 11px 20px;
        font-size: 14px;
    }
    .biji-fab-card {
        max-width: 260px;
    }
}
@media (max-width: 900px) {
    .biji-ad-section .ad-grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 600px) {
    .biji-ad-section .ad-grid { grid-template-columns: repeat(2, 1fr); }
}

