/* WordPress 论坛插件样式 */

/* 基础样式 */
.wp-forum-container {
    max-width: 1440px;
    margin: 0 auto;
    padding: 20px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

/* 论坛头部 */
.wp-forum-header {
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.forum-header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.forum-title h1 {
    margin: 0;
    color: #2c3e50;
    font-size: 2em;
    font-weight: 600;
}

.forum-tools {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
}

.wp-forum-header .forum-search {
    display: flex;
    align-items: center;
}

.wp-forum-search-form {
    position: relative;
    width: 100%;
    max-width: 520px; /* 增加30%：400px * 1.3 = 520px */
}

.wp-forum-search-form .search-wrapper {
    position: relative;
    display: flex;
    align-items: center;
    background: #fff;
    border: 2px solid #e5e7eb;
    border-radius: 25px;
    transition: all 0.3s ease;
    overflow: hidden;
    padding-right: 130px; /* 为两个按钮留出足够空间，增加宽度以容纳文字 */
}

.wp-forum-search-form .search-wrapper:focus-within {
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.wp-forum-search-form .search-input {
    flex: 1;
    padding: 12px 16px;
    border: none;
    outline: none;
    font-size: 14px;
    background: transparent;
    color: #374151;
    padding-right: 8px; /* 减少右侧内边距 */
}

.wp-forum-search-form .search-input::placeholder {
    color: #9ca3af;
}

.wp-forum-search-form .search-btn {
    padding: 8px 16px;
    border: none;
    background: #3b82f6;
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px; /* 图标和文字之间的间距 */
    border-radius: 0 23px 23px 0;
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 80px; /* 增加宽度以容纳文字 */
    height: 100%; /* 占满高度 */
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
}

.wp-forum-search-form .search-btn:hover {
    background: #2563eb;
}

.wp-forum-search-form .search-btn .dashicons {
    width: 16px;
    height: 16px;
    font-size: 16px;
    line-height: 1;
    flex-shrink: 0;
}

.wp-forum-search-form .search-btn .search-btn-text {
    font-size: 14px;
    line-height: 1;
}

.wp-forum-search-form .search-clear-btn {
    padding: 0;
    border: none;
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    color: white;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 6px;
    position: absolute;
    right: 84px; /* 调整位置，定位在搜索按钮左侧，留4px间距 */
    top: 50%;
    transform: translateY(-50%);
    width: 36px; /* 固定宽度 */
    height: 36px; /* 固定高度 */
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
    z-index: 10;
}

.wp-forum-search-form .search-clear-btn:hover {
    background: linear-gradient(135deg, #ff5252 0%, #d84315 100%);
    box-shadow: 0 4px 15px rgba(255, 107, 107, 0.4);
    transform: translateY(-50%) scale(1.05);
}

.wp-forum-search-form .search-clear-btn:active {
    transform: translateY(-50%) scale(0.95);
    box-shadow: 0 2px 6px rgba(255, 107, 107, 0.4);
}

.wp-forum-search-form .search-clear-btn:focus {
    outline: none;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3), 0 0 0 3px rgba(255, 107, 107, 0.2);
}

.wp-forum-search-form .search-clear-btn .dashicons {
    width: 16px;
    height: 16px;
    font-size: 16px;
    line-height: 1;
}

/* 搜索结果下拉 */
.wp-forum-search-form .search-results {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    z-index: 1000;
    max-height: 400px;
    overflow-y: auto;
    margin-top: 4px;
}

.wp-forum-search-form .search-result-item {
    padding: 12px 16px;
    border-bottom: 1px solid #f3f4f6;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.wp-forum-search-form .search-result-item:hover {
    background: #f9fafb;
}

.wp-forum-search-form .search-result-item:last-child {
    border-bottom: none;
}

.wp-forum-search-form .search-result-title {
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 4px;
    font-size: 14px;
}

.wp-forum-search-form .search-result-excerpt {
    color: #6b7280;
    font-size: 12px;
    line-height: 1.4;
}

.wp-forum-search-form .search-result-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 6px;
    font-size: 11px;
    color: #9ca3af;
}

.wp-forum-search-form .search-no-results {
    padding: 20px;
    text-align: center;
    color: #6b7280;
    font-size: 14px;
}

/* 搜索高亮 */
.wp-forum-search-form .search-highlight {
    background: #fef3c7;
    color: #92400e;
    padding: 1px 2px;
    border-radius: 2px;
}

/* 搜索加载状态 */
.wp-forum-search-form .search-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    color: #6b7280;
}

.wp-forum-search-form .search-loading::before {
    content: "";
    width: 16px;
    height: 16px;
    border: 2px solid #e5e7eb;
    border-top-color: #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-right: 8px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 匿名选项激活状态 */
.anonymous-active {
    background: #fff3cd;
    border-color: #ffeaa7;
}

.anonymous-active label {
    color: #856404;
}

/* 改进的提示消息 */
.forum-message {
    padding: 15px 20px;
    margin: 20px 0;
    border-radius: 8px;
    border-left: 4px solid;
    position: relative;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}



.forum-message::before {
    content: '';
    position: absolute;
    top: 15px;
    right: 15px;
    width: 6px;
    height: 6px;
    border-radius: 50%;
}

.forum-message.success {
    background: #d4edda;
    color: #155724;
    border-color: #28a745;
}

.forum-message.success::before {
    background: #28a745;
    box-shadow: 0 0 0 3px rgba(40, 167, 69, 0.3);
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.5);
        opacity: 0.7;
    }
    100% {
        transform: scale(1);
        opacity: 1;
    }
}

.forum-message.error {
    background: #f8d7da;
    color: #721c24;
    border-color: #dc3545;
}

.forum-message.error::before {
    background: #dc3545;
    box-shadow: 0 0 0 3px rgba(220, 53, 69, 0.3);
    animation: pulse 2s infinite;
}

.forum-message.info {
    background: #d1ecf1;
    color: #0c5460;
    border-color: #17a2b8;
}

.forum-message.info::before {
    background: #17a2b8;
    box-shadow: 0 0 0 3px rgba(23, 162, 184, 0.3);
    animation: pulse 2s infinite;
}

/* 创建帖子页面的响应式设计 */
@media (max-width: 768px) {
    .create-post-container {
        padding: 15px;
        margin: 15px;
        border-radius: 8px;
    }
    
    .create-post-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .form-section {
        padding: 20px 15px;
        margin-bottom: 20px;
    }
    
    .form-section:hover {
        transform: none;
    }
    
    .form-row {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .form-actions {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }
    
    .action-buttons {
        width: 100%;
        justify-content: center;
    }
    
    .editor-toolbar {
        flex-wrap: wrap;
        gap: 3px;
        padding: 6px 8px;
    }
    
    .toolbar-btn {
        padding: 5px 8px;
        font-size: 11px;
    }
}

@media (max-width: 480px) {
    .create-post-container {
        padding: 10px;
        margin: 10px;
    }
    
    .form-section {
        padding: 15px 10px;
    }
    
    .create-post-container .btn {
        padding: 10px 20px;
        font-size: 14px;
    }

    .wp-forum-header .forum-search {
        width: 100%;
    }
    
    .wp-forum-header .forum-search input[type="text"] {
        flex: 1;
        min-width: 0;
    }
}

/* 加载更多容器优化 */
.load-more-container {
    text-align: center;
    margin: 30px 0;
    padding: 20px;
}

.load-more-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 12px 32px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.3);
}

.load-more-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.4);
    color: white;
}

.load-more-btn:disabled {
    background: #e9ecef;
    color: #6c757d;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* 分页优化 */
.posts-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin: 30px 0;
}

.posts-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px 12px;
    margin: 0 2px;
    text-decoration: none;
    color: #4a5568;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.3s ease;
    min-width: 40px;
    height: 40px;
}

.posts-pagination .page-numbers:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(102, 126, 234, 0.2);
}

.posts-pagination .page-numbers.current {
    background: #667eea;
    color: white;
    border-color: #667eea;
    cursor: default;
}

.posts-pagination .page-numbers.dots {
    background: transparent;
    border: none;
    color: #a0aec0;
}

.posts-pagination .page-numbers.dots:hover {
    background: transparent;
    color: #a0aec0;
    transform: none;
    box-shadow: none;
}

/* 右侧小工具 */
.wp-forum-widgets {
    display: flex;
    flex-direction: column;
    gap: 32px; /* 增加小部件之间的间距 */
    position: sticky;
    top: 20px;
    max-height: calc(100vh - 40px);
    overflow-y: auto;
    padding-right: 5px;
}

.widget {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    border: 1px solid #f0f0f0;
    transition: all 0.3s ease;
}

.widget:hover {
    box-shadow: 0 4px 15px rgba(0,0,0,0.12);
    transform: translateY(-2px);
}

.widget-title {
    margin: 0 0 15px 0;
    font-size: 1.1em;
    font-weight: 600;
    color: #2d3748;
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f7fafc;
}

.widget-icon {
    color: #667eea;
    font-size: 18px;
}

/* 热门帖子小工具 */
.hot-posts-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.hot-post-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.3s ease;
}

.hot-post-item:hover {
    background: rgba(102, 126, 234, 0.05);
    margin: 0 -12px;
    padding: 12px;
    border-radius: 8px;
}

.post-rank {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 24px;
    height: 24px;
    background: #e2e8f0;
    color: #4a5568;
    font-size: 12px;
    font-weight: 600;
    border-radius: 50%;
    flex-shrink: 0;
    margin-top: 2px;
}

.hot-post-item:nth-child(1) .post-rank {
    background: #ffd700;
    color: #b7791f;
}

.hot-post-item:nth-child(2) .post-rank {
    background: #c0c0c0;
    color: #666;
}

.hot-post-item:nth-child(3) .post-rank {
    background: #cd7f32;
    color: #8b4513;
}

.hot-post-item .post-content {
    flex: 1;
    min-width: 0;
}

.hot-post-item .post-title {
    margin: 0 0 4px 0;
    font-size: 14px;
    line-height: 1.4;
}

.hot-post-item .post-title a {
    color: #2d3748;
    text-decoration: none;
    transition: color 0.3s ease;
}

.hot-post-item .post-title a:hover {
    color: #667eea;
}

.post-meta-mini {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 11px;
    color: #a0aec0;
}

/* 服务商小工具 */
.providers-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.provider-item {
    margin-bottom: 10px;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    overflow: hidden;
    transition: transform 0.2s ease;
}

.provider-item:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.provider-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    text-decoration: none;
    color: #2d3748;
    transition: all 0.3s ease;
    background: #fff;
}

.provider-link:hover {
    background: #fff;
    color: #2d3748;
}

.provider-image {
    flex-shrink: 0;
    width: 33.33%;
    max-width: 60px;
}

.provider-image img {
    width: 100%;
    height: 36px;
    border-radius: 4px;
    object-fit: cover;
    border: 1px solid #e2e8f0;
}

.provider-info {
    flex: 1;
    min-width: 0;
}

.provider-name {
    font-size: 14px;
    font-weight: 600;
    margin: 0 0 2px 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

.provider-desc {
    font-size: 12px;
    color: #718096;
    margin: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 100%;
}

/* 无内容状态 */
.no-content {
    text-align: center;
    padding: 30px 20px;
    color: #a0aec0;
    font-size: 14px;
    border: 2px dashed #e2e8f0;
    border-radius: 8px;
}

/* 额外的响应式优化 */
@media (max-width: 1200px) {
    .wp-forum-main {
        grid-template-columns: 250px 1fr 280px;
        gap: 20px;
    }
}

@media (max-width: 1024px) {
    .wp-forum-main {
        grid-template-columns: 1fr 280px;
        gap: 16px;
    }
}

@media (max-width: 768px) {
    .wp-forum-container {
        padding: 10px;
    }
    
    .wp-forum-main {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .wp-forum-sidebar,
    .wp-forum-widgets {
        order: 2;
        position: static;
    }
    
    .wp-forum-widgets {
        gap: 24px; /* 在平板端适当减少间距 */
    }
    
    .forum-header-container {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
    }
    
    .forum-tools {
        justify-content: center;
    }
    
    .categories-list {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
        gap: 8px;
        margin-bottom: 20px;
    }
    
    .hot-posts-list,
    .providers-list {
        display: grid;
        grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
        gap: 10px;
    }
}

@media (max-width: 480px) {
    .wp-forum-container {
        padding: 5px;
    }
    
    .wp-forum-header,
    .wp-forum-content,
    .wp-forum-sidebar,
    .widget {
        border-radius: 6px;
    }
    
    .wp-forum-widgets {
        gap: 20px; /* 在手机端保持适中的间距 */
    }
    
    .categories-list {
        grid-template-columns: 1fr;
    }
    
    .hot-posts-list,
    .providers-list {
        grid-template-columns: 1fr;
    }
}

/* ==================== MJZJ 风格样式 ==================== */

/* 主容器 */
.mjzj-posts-container {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 0;
    margin: 0 auto;
    max-width: 1200px;
}

/* 头部区域 */
.mjzj-posts-header {
    background: #fff;
    border-radius: 8px 8px 0 0;
    padding: 20px 24px;
    border-bottom: 1px solid #e9ecef;
}

.posts-header-info {
    margin-bottom: 20px;
}

.posts-main-title {
    font-size: 24px;
    font-weight: 600;
    color: #2c3e50;
    margin: 0 0 16px 0;
}

/* 分类标签过滤 */
.posts-filter-tabs {
    margin-top: 16px;
}

.filter-tabs-wrapper {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.filter-label {
    color: #6c757d;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
}

.filter-tabs {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.filter-tab {
    display: inline-block;
    padding: 6px 12px;
    background: #f8f9fa;
    color: #6c757d;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    transition: all 0.2s ease;
    border: 1px solid transparent;
}

.filter-tab:hover {
    background: #e9ecef;
    color: #495057;
    text-decoration: none;
}

.filter-tab.active {
    background: #007bff;
    color: #fff;
    border-color: #007bff;
}

/* 控制栏 */
.posts-controls-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.status-filters select,
.sort-controls-new select {
    padding: 6px 12px;
    border: 1px solid #ced4da;
    border-radius: 4px;
    font-size: 14px;
    background: #fff;
    color: #495057;
    min-width: 120px;
}

.status-filters select:focus,
.sort-controls-new select:focus {
    outline: none;
    border-color: #007bff;
    box-shadow: 0 0 0 2px rgba(0, 123, 255, 0.25);
}

/* 帖子列表 */
.mjzj-posts-list {
    background: #fff;
    padding: 0;
}

/* 帖子卡片 */
.mjzj-post-card {
    position: relative;
    padding: 20px 24px;
    border-bottom: 1px solid #e9ecef;
    transition: background-color 0.2s ease;
}

.mjzj-post-card:hover {
    background: #f8f9fa;
}

.mjzj-post-card:last-child {
    border-bottom: none;
}

/* 悬赏角标 - 改为内联显示 */
.bounty-corner-badge {
    display: inline-block;
    background: #ff6b35;
    color: #fff;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 12px;
    font-weight: 600;
    margin-right: 8px;
    position: relative;
}

.bounty-corner-badge::before {
    content: "悬赏";
    margin-right: 4px;
}

/* 悬赏状态样式 */
.bounty-corner-badge.completed {
    background: #28a745;
}

.bounty-corner-badge.completed::before {
    content: "已完成";
}

.bounty-corner-badge.expired {
    background: #dc3545;
}

.bounty-corner-badge.expired::before {
    content: "已过期";
}

.bounty-status-indicator {
    display: block;
    font-size: 10px;
    margin-top: 2px;
    opacity: 0.9;
}

/* 帖子内容 */
.post-card-content {
    position: relative;
    z-index: 2;
}

/* 标题区域 */
.post-title-section {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 12px;
    gap: 16px;
}

/* 移除悬赏帖子标题区域的预留空间 */

.mjzj-post-title {
    margin: 0;
    flex: 1;
}

.post-title-link {
    color: #2c3e50;
    text-decoration: none;
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    display: block;
}

.post-title-link:hover {
    color: #007bff;
    text-decoration: none;
}



/* 状态标签区域 - 现在包含悬赏角标和状态标签 */
.post-status-tags {
    display: flex;
    gap: 8px;
    align-items: center;
    flex-shrink: 0;
}



.status-tag {
    display: inline-block;
    padding: 4px 8px;
    font-size: 12px;
    font-weight: 500;
    border-radius: 4px;
    white-space: nowrap;
}

.status-tag.pinned {
    background: #28a745;
    color: #fff;
}

.status-tag.answered {
    background: #17a2b8;
    color: #fff;
}

/* 内容摘要 */
.post-summary {
    color: #6c757d;
    font-size: 14px;
    line-height: 1.5;
    margin-bottom: 16px;
}

/* 底部信息栏 */
.post-meta-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

/* 作者信息 */
.post-author-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.author-avatar img {
    border-radius: 50%;
    width: 24px;
    height: 24px;
}

.anonymous-avatar {
    width: 24px;
    height: 24px;
    background: #6c757d;
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
}

/* 用户头像 - 显示用户名首字符 */
.user-avatar {
    width: 24px;
    height: 24px;
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: #fff;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.author-details {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.author-name {
    font-size: 14px;
    font-weight: 500;
    color: #495057;
}

.post-time {
    font-size: 12px;
    color: #6c757d;
}

/* 统计信息 */
.post-stats-info {
    display: flex;
    align-items: center;
    gap: 16px;
    flex-wrap: wrap;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    color: #6c757d;
}

.stat-item.answers .stat-number {
    font-weight: 600;
    color: #007bff;
}

.stat-item.bounty .stat-number {
    font-weight: 600;
    color: #ff6b35;
}

.stat-item.deadline .deadline-countdown {
    font-weight: 600;
    color: #dc3545;
}

.stat-item.views .stat-number {
    font-weight: 500;
}

/* 悬赏状态样式 */
.stat-item.bounty-status .status-text {
    font-weight: 600;
}

.stat-item.bounty-status.completed .status-text {
    color: #28a745;
}

.stat-item.bounty-status.expired .status-text {
    color: #dc3545;
}

.stat-item.deadline.active .deadline-countdown {
    color: #fd7e14;
    font-weight: 600;
}

.stat-item.category {
    background: #e9ecef;
    padding: 2px 8px;
    border-radius: 12px;
}

.category-link {
    color: #495057;
    text-decoration: none;
    font-size: 12px;
}

.category-link:hover {
    color: #007bff;
    text-decoration: none;
}

/* 无内容状态 */
.mjzj-no-posts {
    padding: 60px 24px;
    text-align: center;
    background: #fff;
}

.no-posts-content h3 {
    color: #6c757d;
    margin: 0 0 16px 0;
    font-size: 18px;
    font-weight: 500;
}

.btn-create-first {
    display: inline-block;
    padding: 10px 20px;
    background: #007bff;
    color: #fff;
    text-decoration: none;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    transition: background-color 0.2s ease;
}

.btn-create-first:hover {
    background: #0056b3;
    text-decoration: none;
    color: #fff;
}

/* 加载更多 */
.mjzj-load-more {
    padding: 24px;
    text-align: center;
    background: #fff;
    border-top: 1px solid #e9ecef;
}

.load-more-button {
    padding: 10px 24px;
    background: #fff;
    color: #007bff;
    border: 1px solid #007bff;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.load-more-button:hover {
    background: #007bff;
    color: #fff;
}

.loading-text {
    padding: 10px 24px;
    background: #fff;
    color: #6c757d;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    display: inline-block;
}

/* 底部信息 */
.mjzj-posts-footer {
    padding: 16px 24px;
    background: #f8f9fa;
    border-radius: 0 0 8px 8px;
    border-top: 1px solid #e9ecef;
    text-align: center;
}

.posts-count-info {
    color: #6c757d;
    font-size: 14px;
    margin-bottom: 8px;
}

.empty-state-note {
    color: #adb5bd;
    font-size: 12px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .mjzj-posts-container {
        margin: 0 -16px;
        border-radius: 0;
    }
    
    .mjzj-posts-header {
        padding: 16px;
        border-radius: 0;
    }
    
    .posts-controls-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    
    .filter-tabs-wrapper {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }
    
    .filter-tabs {
        justify-content: flex-start;
    }
    
    .mjzj-post-card {
        padding: 16px;
    }
    
    .post-title-section {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .post-meta-bar {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    
    .post-stats-info {
        justify-content: flex-start;
        gap: 12px;
    }
    
    /* 移动端状态标签区域保持水平布局 */
    .post-status-tags {
        flex-wrap: wrap;
        gap: 6px;
    }
}

@media (max-width: 480px) {
    .mjzj-posts-header {
        padding: 12px;
    }
    
    .posts-main-title {
        font-size: 20px;
    }
    
    .mjzj-post-card {
        padding: 12px;
    }
    
    .post-title-link {
        font-size: 15px;
    }
    
    .post-stats-info {
        gap: 8px;
    }
    
    .stat-item {
        font-size: 11px;
    }
    
    .filter-tabs {
        gap: 4px;
    }
    
    .filter-tab {
        padding: 4px 8px;
        font-size: 12px;
    }
    
    /* 移动端悬赏角标和状态标签样式调整 */
    .bounty-corner-badge {
        font-size: 11px;
        padding: 3px 6px;
        margin-right: 6px;
    }
    
    .status-tag {
        font-size: 11px;
        padding: 2px 6px;
    }
}

/* 动画效果 */
.fade-in-up {
    animation: fadeInUp 0.6s ease-out forwards;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.7;
    }
}

/* 隐藏元素 */
.mjzj-hidden {
    display: none !important;
}



/* 过滤结果为空 */
.filter-no-results {
    text-align: center;
    padding: 40px 20px;
    color: #6c757d;
    font-size: 16px;
}

/* 错误消息 */
.error-message {
    text-align: center;
    padding: 40px 20px;
    color: #dc3545;
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    border-radius: 8px;
    margin: 20px;
}

/* 没有更多帖子 */
.no-more-posts {
    text-align: center;
    padding: 20px;
    color: #6c757d;
    font-size: 14px;
    border-top: 1px solid #e9ecef;
}

/* ===== 相关推荐区域样式优化 ===== */
#related-posts {
    margin-top: 20px;
}

#related-posts .mjzj-post-card {
    margin-bottom: 16px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    transition: box-shadow 0.2s ease;
    background: #fff;
}

#related-posts .mjzj-post-card:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

#related-posts .mjzj-post-title {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.4;
    margin: 0;
}

#related-posts .post-title-link {
    color: #1f2937;
    text-decoration: none;
    transition: color 0.2s ease;
}

#related-posts .post-title-link:hover {
    color: #3b82f6;
}

#related-posts .post-summary {
    font-size: 14px;
    color: #6b7280;
    margin-top: 8px;
    margin-bottom: 12px;
    line-height: 1.5;
}

#related-posts .post-meta-bar {
    font-size: 13px;
}

#related-posts .author-name {
    font-weight: 500;
    color: #374151;
}

#related-posts .post-time {
    color: #9ca3af;
}

#related-posts .stat-label {
    color: #6b7280;
}

#related-posts .stat-number {
    font-weight: 600;
    color: #374151;
}

/* 相关推荐区域的悬赏角标样式调整 */
#related-posts .bounty-corner-badge {
    font-size: 12px;
    padding: 4px 8px;
    border-radius: 4px;
}

#related-posts .bounty-amount {
    font-weight: 600;
}

#related-posts .bounty-status-indicator {
    font-size: 11px;
    margin-left: 4px;
}

/* 相关推荐标题样式 */
.related-posts-title {
    font-size: 20px;
    font-weight: 600;
    color: #1f2937;
    margin-bottom: 20px;
    padding-bottom: 8px;
    border-bottom: 2px solid #e5e7eb;
}

/* 相关推荐无内容提示 */
#related-posts .text-center {
    padding: 40px 20px;
    background: #f9fafb;
    border-radius: 8px;
    color: #6b7280;
    font-size: 16px;
    text-align: center;
}

/* 相关推荐响应式优化 */
@media (max-width: 768px) {
    #related-posts .mjzj-post-card {
        margin-bottom: 12px;
    }
    
    #related-posts .mjzj-post-title {
        font-size: 15px;
    }
    
    #related-posts .post-summary {
        font-size: 13px;
        margin-bottom: 10px;
    }
    
    #related-posts .post-meta-bar {
        font-size: 12px;
    }
    
    #related-posts .bounty-corner-badge {
        font-size: 11px;
        padding: 3px 6px;
    }
    
    .related-posts-title {
        font-size: 18px;
        margin-bottom: 16px;
    }
}

@media (max-width: 480px) {
    #related-posts .post-title-section {
        gap: 12px;
    }
    
    #related-posts .post-stats-info {
        gap: 12px;
    }
    
    #related-posts .stat-item {
        font-size: 11px;
    }
    
    #related-posts .text-center {
        padding: 30px 15px;
        font-size: 15px;
    }
}

/* ===== 论坛搜索框响应式优化 ===== */
@media (max-width: 768px) {
    .wp-forum-search-form {
        max-width: 100%;
    }
    
    .wp-forum-search-form .search-wrapper {
        border-radius: 20px;
        padding-right: 90px; /* 调整移动端按钮空间 */
    }
    
    .wp-forum-search-form .search-input {
        font-size: 14px;
        padding: 10px 14px;
        padding-right: 6px;
    }
    
    .wp-forum-search-form .search-btn {
        width: 44px;
        padding: 0; /* 移动端移除内边距 */
        border-radius: 0 18px 18px 0;
    }
    
    .wp-forum-search-form .search-btn .dashicons {
        width: 16px;
        height: 16px;
        font-size: 16px;
    }
    
    .wp-forum-search-form .search-btn .search-btn-text {
        display: none; /* 移动端隐藏文字 */
    }
    
    .wp-forum-search-form .search-clear-btn {
        right: 48px; /* 调整清空按钮位置 */
        width: 32px;
        height: 32px;
    }
    
    .wp-forum-search-form .search-clear-btn .dashicons {
        width: 14px;
        height: 14px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .wp-forum-search-form .search-wrapper {
        border-radius: 18px;
        padding-right: 78px; /* 调整小屏幕按钮空间 */
    }
    
    .wp-forum-search-form .search-input {
        font-size: 13px;
        padding: 8px 12px;
        padding-right: 4px;
    }
    
    .wp-forum-search-form .search-btn {
        width: 40px;
        padding: 0; /* 小屏幕移除内边距 */
        border-radius: 0 16px 16px 0;
    }
    
    .wp-forum-search-form .search-btn .dashicons {
        width: 14px;
        height: 14px;
        font-size: 14px;
    }
    
    .wp-forum-search-form .search-btn .search-btn-text {
        display: none; /* 小屏幕隐藏文字 */
    }
    
    .wp-forum-search-form .search-clear-btn {
        right: 44px;
        width: 28px;
        height: 28px;
    }
    
    .wp-forum-search-form .search-clear-btn .dashicons {
        width: 12px;
        height: 12px;
        font-size: 12px;
    }
    
    .wp-forum-search-form .search-results {
        margin-top: 2px;
        border-radius: 6px;
    }
}

/* 用户区域样式 */
.forum-user-area {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-info {
    display: flex;
    align-items: center;
    gap: 8px;
}

.user-info img {
    border-radius: 50%;
}

.username {
    font-weight: 500;
    color: #2c3e50;
}

.user-points {
    background: #f39c12;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.login-prompt {
    display: flex;
    align-items: center;
    gap: 10px;
}

.login-tip {
    color: #7f8c8d;
    font-size: 14px;
}

/* 按钮样式 */
.btn {
    display: inline-block;
    padding: 8px 16px;
    border-radius: 4px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
}

.btn-primary {
    background: #3498db;
    color: white;
}

.btn-primary:hover {
    background: #2980b9;
    color: white;
}

.btn-outline {
    background: transparent;
    color: #3498db;
    border: 1px solid #3498db;
}

.btn-outline:hover {
    background: #3498db;
    color: white;
}

/* 主要布局 */
.wp-forum-main {
    display: grid;
    grid-template-columns: 280px 1fr 320px;
    gap: 24px;
    align-items: start;
    max-width: 1400px;
    margin: 0 auto;
}

/* 左侧边栏 */
.wp-forum-sidebar {
    background: #fff;
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    position: sticky;
    top: 20px;
    min-width: 280px;
}

.categories-sidebar .sidebar-title {
    margin: 0 0 15px 0;
    color: #2c3e50;
    font-size: 1.2em;
    font-weight: 600;
    padding-bottom: 10px;
    border-bottom: 2px solid #ecf0f1;
}

.categories-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.category-item {
    margin-bottom: 5px;
}

.category-link {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 15px;
    text-decoration: none;
    color: #34495e;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.category-link:hover {
    background: #ecf0f1;
    color: #2c3e50;
}

.category-item.active .category-link {
    background: #3498db;
    color: white;
}

.category-name {
    font-weight: 500;
}

.post-count {
    background: #bdc3c7;
    color: white;
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 500;
}

.category-item.active .post-count {
    background: rgba(255,255,255,0.3);
}

.category-desc {
    padding: 5px 15px;
    color: #7f8c8d;
    font-size: 12px;
    line-height: 1.4;
}

/* 中间内容区 */
.wp-forum-content {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    overflow: hidden;
    min-width: 0; /* 允许内容缩放 */
}

.wp-forum-content.full-width {
    grid-column: 1 / -1;
}

/* 帖子列表容器优化 */
.posts-list-container {
    background: transparent;
}

/* 帖子列表头部优化 */
.posts-header {
    background: #ffffff;
    border-radius: 16px;
    padding: 24px;
    margin-bottom: 24px;
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.04);
    border: 1px solid #e1e8ed;
}

.posts-info h2 {
    margin: 0 0 8px 0;
    color: #2d3748;
    font-size: 1.8em;
    font-weight: 700;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.posts-count {
    color: #718096;
    font-size: 14px;
    font-weight: 500;
    background: rgba(102, 126, 234, 0.1);
    padding: 4px 12px;
    border-radius: 20px;
    display: inline-block;
}

/* 控制面板优化 */
.posts-controls {
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    margin-top: 16px;
}

.sort-controls, .filter-controls {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sort-controls label, .filter-controls label {
    color: #4a5568;
    font-weight: 500;
    font-size: 14px;
}

.sort-select, .filter-select {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    padding: 8px 16px;
    font-size: 14px;
    color: #2d3748;
    transition: all 0.3s ease;
    cursor: pointer;
    min-width: 120px;
}

.sort-select:hover, .filter-select:hover {
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.sort-select:focus, .filter-select:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.2);
}

/* 空状态优化 */
.no-posts {
    background: #ffffff;
    border-radius: 16px;
    padding: 48px 24px;
    text-align: center;
    border: 2px dashed #e2e8f0;
    margin: 24px 0;
}

.no-posts-icon {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    box-shadow: 0 8px 25px rgba(102, 126, 234, 0.3);
}

.no-posts-icon i {
    font-size: 32px;
    color: white;
}

.no-posts h3 {
    margin: 0 0 12px 0;
    color: #2d3748;
    font-size: 1.5em;
    font-weight: 600;
}

.no-posts p {
    color: #718096;
    font-size: 16px;
    line-height: 1.6;
    margin: 0 0 24px 0;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
}

.create-post-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 12px 24px;
    border-radius: 12px;
    border: none;
    font-weight: 600;
    font-size: 16px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.create-post-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.5);
    color: white;
}

/* 帖子项目 */
.posts-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

/* 帖子卡片 - 三层结构重新设计 */
.post-item {
    background: #ffffff;
    border: 1px solid #e1e8ed;
    border-radius: 8px;
    padding: 16px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    margin-bottom: 0;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.post-item:hover {
    border-color: #cbd6ee;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

/* 置顶帖子样式优化 */
.post-item.pinned {
    border-color: #ffeaa7;
    background: linear-gradient(135deg, #fff9e6 0%, #ffffff 100%);
}

/* 悬赏标签 - 右上角定位 */
.post-bounty-corner {
    position: absolute;
    top: -16px;
    right: -16px;
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    color: white;
    padding: 6px 16px 6px 20px;
    border-radius: 0 8px 0 12px;
    font-size: 12px;
    font-weight: 600;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
    z-index: 2;
    display: flex;
    align-items: center;
    gap: 4px;
}

.post-bounty-corner i {
    font-size: 14px;
}

/* 第一排：标题区域 */
.post-title-row {
    margin-bottom: 12px;
}

.post-title {
    margin: 0;
    font-size: 18px;
    line-height: 1.4;
    font-weight: 600;
    color: #2d3748;
}

.post-title a {
    color: inherit;
    text-decoration: none;
    transition: color 0.3s ease;
}

.post-title a:hover {
    color: #667eea;
}

/* 第二排：内容区域 */
.post-content-row {
    margin-bottom: 16px;
}

.post-excerpt {
    color: #718096;
    line-height: 1.6;
    font-size: 14px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin: 0;
}

/* 第三排：用户信息和统计数据 */
.post-footer-row {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12px;
    color: #718096;
    flex-wrap: wrap;
    min-height: 24px;
}

/* 用户头像 - 20px大小 */
.post-user-avatar {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    flex-shrink: 0;
}

.post-user-avatar img {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    border: 1px solid #e2e8f0;
}

.anonymous-avatar-small {
    width: 20px;
    height: 20px;
    background: linear-gradient(135deg, #a29bfe 0%, #6c5ce7 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-weight: 600;
    font-size: 10px;
    border: 1px solid #e2e8f0;
}

/* 用户昵称 */
.post-username {
    font-weight: 500;
    color: #4a5568;
    font-size: 12px;
}

/* 统计数据项 */
.post-stat-item {
    display: flex;
    align-items: center;
    gap: 3px;
    color: #a0aec0;
    font-size: 11px;
}

.post-stat-item i {
    font-size: 12px;
}

.post-stat-number {
    font-weight: 600;
    color: #4a5568;
}

/* 悬赏信息 */
.post-bounty-info {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    color: white;
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 3px;
}

.post-bounty-info i {
    font-size: 11px;
}

/* 悬赏到期时间 */
.post-bounty-deadline {
    background: #ffeaa7;
    color: #856404;
    padding: 2px 6px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 3px;
    margin-left: 4px;
}

.post-bounty-deadline i {
    font-size: 10px;
}

/* 状态标识 */
.post-status-badges {
    display: flex;
    gap: 4px;
    margin-left: auto;
}

.status-badge {
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 9px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.status-badge.pinned {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.status-badge.locked {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #b8daff;
}

/* 分类标签 */
.post-category-info {
    background: #f7fafc;
    color: #4a5568;
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 10px;
    font-weight: 500;
    border: 1px solid #e2e8f0;
    text-decoration: none;
    transition: all 0.3s ease;
}

.post-category-info:hover {
    background: #667eea;
    color: white;
    border-color: #667eea;
}

/* 分隔符 */
.post-separator {
    color: #e2e8f0;
    margin: 0 2px;
    font-size: 10px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .post-item {
        padding: 12px;
        margin-bottom: 8px;
    }
    
    .post-title {
        font-size: 16px;
    }
    
    .post-excerpt {
        font-size: 13px;
        -webkit-line-clamp: 1;
    }
    
    .post-footer-row {
        gap: 8px;
        font-size: 12px;
        flex-wrap: wrap;
    }
    
    .post-stat-item {
        font-size: 11px;
    }
    
    .post-bounty-corner {
        top: -12px;
        right: -12px;
        padding: 4px 12px 4px 16px;
        font-size: 11px;
    }
    
    /* 在移动端，某些项目换行显示 */
    .post-status-badges {
        margin-left: 0;
        margin-top: 4px;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .post-footer-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    
    .post-user-info {
        display: flex;
        align-items: center;
        gap: 8px;
        width: 100%;
    }
    
    .post-stats-info {
        display: flex;
        align-items: center;
        gap: 12px;
        width: 100%;
    }
    
    .post-bounty-info,
    .post-bounty-deadline {
        margin-top: 4px;
    }
}



/* 动画效果 */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.slide-in {
    animation: slideIn 0.3s ease-out;
}

@keyframes slideIn {
    from { transform: translateX(-20px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

/* 状态指示 */
.status-enabled {
    color: #27ae60;
    font-weight: 500;
}

.status-disabled {
    color: #e74c3c;
    font-weight: 500;
}

/* 工具提示 */
.tooltip {
    position: relative;
    cursor: help;
}

.tooltip::after {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: #2c3e50;
    color: white;
    padding: 5px 8px;
    border-radius: 4px;
    font-size: 12px;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    z-index: 1000;
}

.tooltip:hover::after {
    opacity: 1;
}

/* 创建帖子页面样式 */
.create-post-container {
    padding: 20px;
    max-width: 800px;
    margin: 0 auto;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.1);
    position: relative;
}

.create-post-container::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, #3498db, #2ecc71, #f39c12);
    border-radius: 12px 12px 0 0;
}

.create-post-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    padding-bottom: 15px;
    border-bottom: 2px solid #ecf0f1;
}

.create-post-header h2 {
    margin: 0;
    color: #2c3e50;
}

.user-points-display {
    background: #f39c12;
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: 500;
}

.form-section {
    margin-bottom: 30px;
    padding: 25px;
    background: #f8f9fa;
    border-radius: 12px;
    border: 1px solid #e9ecef;
    transition: all 0.3s ease;
    position: relative;
}

.form-section::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: linear-gradient(135deg, #3498db, #2ecc71);
    border-radius: 12px 0 0 12px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.form-section:hover::before {
    opacity: 1;
}

.form-section:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
}

.form-section h3 {
    margin: 0 0 20px 0;
    color: #34495e;
    font-size: 1.2em;
    font-weight: 600;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 500;
    color: #34495e;
}

.required {
    color: #e74c3c;
}

.form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.3s ease;
    background: #fff;
    box-sizing: border-box;
}

.form-control:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
    transform: translateY(-1px);
}

.form-control:hover:not(:focus) {
    border-color: #bdc3c7;
}

.form-help {
    margin-top: 5px;
    font-size: 12px;
    color: #7f8c8d;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    margin-bottom: 10px;
}

.checkbox-label input[type="checkbox"] {
    margin-right: 8px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.bounty-options {
    margin-top: 15px;
    padding: 15px;
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 8px;
}

.form-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #ecf0f1;
}

.action-buttons {
    display: flex;
    gap: 15px;
}

.form-notice {
    max-width: 300px;
}

.form-notice p {
    margin: 0;
    font-size: 12px;
    color: #7f8c8d;
    line-height: 1.4;
}

.char-counter {
    font-size: 12px;
    color: #7f8c8d;
    margin-top: 5px;
}

.char-counter.warning {
    color: #e74c3c;
    font-weight: 500;
}

/* 编辑器样式 */
.content-editor {
    border: 1px solid #ddd;
    border-radius: 4px;
    overflow: hidden;
}

.editor-toolbar {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 8px 12px;
    background: #f8f9fa;
    border-bottom: 1px solid #ddd;
}

.toolbar-btn {
    padding: 6px 10px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 3px;
    cursor: pointer;
    font-size: 12px;
    color: #555;
    transition: all 0.2s ease;
}

.toolbar-btn:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

.toolbar-btn:active {
    background: #dee2e6;
    transform: translateY(1px);
}

.content-editor .form-control {
    border: none;
    border-radius: 0;
    resize: vertical;
}

.content-editor .form-control:focus {
    box-shadow: none;
}

/* 改善按钮样式 */
.create-post-container .btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: 6px;
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.create-post-container .btn:before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.2), transparent);
    transition: left 0.5s;
}

.create-post-container .btn:hover:before {
    left: 100%;
}

.create-post-container .btn-primary {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    box-shadow: 0 4px 15px 0 rgba(52, 152, 219, 0.3);
}

.create-post-container .btn-primary:hover {
    background: linear-gradient(135deg, #2980b9, #1f5f8b);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px 0 rgba(52, 152, 219, 0.4);
    color: white;
}

.create-post-container .btn-primary:disabled {
    background: #bdc3c7;
    color: #7f8c8d;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.create-post-container .btn-outline {
    background: transparent;
    color: #3498db;
    border: 2px solid #3498db;
}

.create-post-container .btn-outline:hover {
    background: #3498db;
    color: white;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px 0 rgba(52, 152, 219, 0.3);
}

/* 加载状态样式 */
.btn-loading {
    position: relative;
    color: transparent !important;
}

.btn-loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid #fff;
    border-top-color: transparent;
    border-radius: 50%;
    animation: button-spin 0.8s linear infinite;
}

@keyframes button-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* 匿名模式样式 */
.anonymous-active {
    background: #fff3cd;
    border-color: #ffeaa7;
}

.anonymous-active label {
    color: #856404;
}

/* 编辑话题页面样式 */
.edit-post-container {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    overflow: hidden;
}

.edit-post-container .create-post-header h2 {
    color: #2c3e50;
}

.edit-post-container .form-section {
    border-left: 4px solid #3498db;
}

.edit-post-container .form-section:hover {
    border-left-color: #2980b9;
}

.bounty-info {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 16px;
    margin-top: 8px;
}

.bounty-info h4 {
    margin: 0 0 12px 0;
    color: #495057;
    font-size: 16px;
}

.bounty-info p {
    margin: 8px 0;
    color: #6c757d;
}

.bounty-note {
    color: #dc3545 !important;
    font-weight: 500;
    font-style: italic;
}

/* 标签样式 */
.tags-input-container {
    position: relative;
}

.tags-display {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 8px;
    min-height: 32px;
    padding: 4px;
    border: 1px solid #ddd;
    border-radius: 4px;
    background: #fff;
}

.tag-item {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 4px 8px;
    background: #e3f2fd;
    color: #1976d2;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 500;
}

.tag-item .remove-tag {
    cursor: pointer;
    font-weight: bold;
    color: #f44336;
    font-size: 14px;
    line-height: 1;
}

.tag-item .remove-tag:hover {
    color: #d32f2f;
}

.tags-input {
    border: none !important;
    box-shadow: none !important;
    padding: 8px 12px;
}

.tags-input:focus {
    border: 1px solid #3498db !important;
    box-shadow: 0 0 0 2px rgba(52, 152, 219, 0.2) !important;
}

/* 上传工具栏样式 */
.custom-upload-toolbar {
    display: flex;
    gap: 8px;
    padding: 8px 12px;
    background: #f8f9fa;
    border-bottom: 1px solid #dee2e6;
    border-radius: 4px 4px 0 0;
}

.upload-btn {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 6px 12px;
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 4px;
    color: #495057;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.upload-btn:hover {
    background: #e9ecef;
    border-color: #adb5bd;
    color: #212529;
}

.upload-btn .dashicons {
    font-size: 14px;
}

.upload-progress {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.9);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.progress-bar {
    width: 200px;
    height: 4px;
    background: #e9ecef;
    border-radius: 2px;
    overflow: hidden;
    margin-bottom: 8px;
}

.progress-fill {
    height: 100%;
    background: #3498db;
    width: 0%;
    transition: width 0.3s ease;
    animation: progress-animation 2s ease-in-out infinite;
}

@keyframes progress-animation {
    0% { width: 0%; }
    50% { width: 70%; }
    100% { width: 100%; }
}

.progress-text {
    font-size: 12px;
    color: #6c757d;
}

/* 字符计数样式 */
.char-counter {
    font-size: 12px;
    color: #6c757d;
    margin-top: 4px;
    text-align: right;
}

.char-counter.warning {
    color: #e74c3c;
    font-weight: 500;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .edit-post-container .form-section {
        padding: 16px;
    }
    
    .custom-upload-toolbar {
        flex-wrap: wrap;
        gap: 6px;
    }
    
    .upload-btn {
        padding: 4px 8px;
        font-size: 11px;
    }
    
    .tags-display {
        gap: 6px;
    }
    
    .tag-item {
        font-size: 11px;
        padding: 3px 6px;
    }
}

@media (max-width: 480px) {
    .edit-post-container .create-post-header {
        padding: 16px;
    }
    
    .edit-post-container .form-section {
        padding: 12px;
    }
    
    .bounty-info {
        padding: 12px;
    }
    
    .custom-upload-toolbar {
        padding: 6px 8px;
    }
    
    .upload-btn {
        flex: 1;
        justify-content: center;
    }
}

/* 我的话题页面样式 */
.my-posts-container {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    overflow: hidden;
}

.my-posts-container .posts-header-info h2 {
    display: flex;
    align-items: center;
    gap: 12px;
    color: #2c3e50;
    font-size: 24px;
    font-weight: 600;
    margin-bottom: 8px;
}

.my-posts-container .posts-header-info h2 .dashicons {
    color: #3498db;
    font-size: 26px;
}

.posts-count {
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 14px;
    font-weight: 500;
    margin-left: 8px;
    box-shadow: 0 2px 6px rgba(52, 152, 219, 0.3);
}

.my-posts-container .posts-controls-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 16px;
    padding: 20px 0;
    border-bottom: 2px solid #f8f9fa;
}

.my-posts-actions {
    display: flex;
    gap: 12px;
    align-items: center;
}

.btn-sm {
    padding: 8px 16px;
    font-size: 13px;
    border-radius: 6px;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: all 0.3s ease;
}

.btn-sm:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.btn-sm .dashicons {
    font-size: 16px;
}

/* 我的话题卡片样式 */
.my-post-card {
    position: relative;
    background: #ffffff;
    border: 1px solid #e9ecef;
    border-radius: 10px;
    overflow: hidden;
    transition: all 0.3s ease;
    margin-bottom: 20px;
}

.my-post-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
    border-color: #d0d3d6;
}

.my-post-card .post-card-content {
    padding: 24px;
}

.my-post-card .post-title-section {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
}

.my-post-card .mjzj-post-title {
    flex: 1;
    margin: 0;
    padding-right: 20px;
}

.my-post-card .post-title-link {
    color: #2c3e50;
    text-decoration: none;
    font-weight: 600;
    font-size: 18px;
    line-height: 1.4;
    display: block;
    transition: color 0.2s ease;
}

.my-post-card .post-title-link:hover {
    color: #3498db;
}

.my-post-card .post-summary {
    color: #6c757d;
    line-height: 1.6;
    margin-bottom: 20px;
    font-size: 14px;
}

.my-post-card .post-meta-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 16px;
    border-top: 1px solid #f1f3f4;
}

.my-post-card .post-meta-info {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
}

.my-post-card .meta-item {
    display: flex;
    align-items: center;
    gap: 4px;
    color: #6c757d;
    font-size: 13px;
}

.my-post-card .meta-item .dashicons {
    font-size: 14px;
    color: #95a5a6;
}

.my-post-card .meta-item.category {
    color: #7b68ee;
    font-weight: 500;
}

.my-post-card .meta-item.time {
    color: #95a5a6;
}

.my-post-card .meta-item.views {
    color: #2ecc71;
}

.my-post-card .meta-item.comments {
    color: #f39c12;
}

.my-post-card .meta-item.upvotes {
    color: #e74c3c;
}

/* 操作按钮样式 */
.my-post-card .post-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    font-size: 12px;
    border: 1.5px solid #dee2e6;
    background: #ffffff;
    color: #6c757d;
    text-decoration: none;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    font-weight: 500;
    outline: none;
}

.action-btn:hover {
    border-color: #3498db;
    color: #3498db;
    background: #f8fafb;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(52, 152, 219, 0.15);
}

.action-btn:active {
    transform: translateY(0);
}

.action-btn.edit-btn:hover {
    border-color: #27ae60;
    color: #27ae60;
    background: #f0fff4;
}

.action-btn.delete-btn:hover {
    border-color: #e74c3c;
    color: #e74c3c;
    background: #fef5f5;
}

.action-btn .dashicons {
    font-size: 14px;
    line-height: 1;
}

/* 登录提示样式 */
.wp-forum-login-required {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 400px;
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.login-prompt {
    text-align: center;
    padding: 40px;
    max-width: 400px;
}

.login-prompt h3 {
    color: #2c3e50;
    font-size: 24px;
    margin-bottom: 12px;
}

.login-prompt p {
    color: #6c757d;
    margin-bottom: 24px;
    line-height: 1.6;
}

.login-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
}

/* 消息提示样式 */
.forum-message {
    position: fixed;
    top: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 10000;
    padding: 16px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    opacity: 1;
    backdrop-filter: blur(10px);
    max-width: 90%;
    min-width: 300px;
    animation: gentleShake 0.6s ease-in-out;
}

/* 轻微晃动动画 */
@keyframes gentleShake {
    0% {
        transform: translateX(-50%) translateY(0);
    }
    25% {
        transform: translateX(-50%) translateY(-2px);
    }
    50% {
        transform: translateX(-50%) translateY(0);
    }
    75% {
        transform: translateX(-50%) translateY(-1px);
    }
    100% {
        transform: translateX(-50%) translateY(0);
    }
}

/* 移动端轻微晃动动画 */
@keyframes gentleShakeMobile {
    0% {
        transform: translateY(0);
    }
    25% {
        transform: translateY(-2px);
    }
    50% {
        transform: translateY(0);
    }
    75% {
        transform: translateY(-1px);
    }
    100% {
        transform: translateY(0);
    }
}

.forum-message.success {
    background: linear-gradient(135deg, #d4edda, #c3e6cb);
    border: 1px solid #badbcc;
    color: #0f5132;
}

.forum-message.error {
    background: linear-gradient(135deg, #f8d7da, #f5c6cb);
    border: 1px solid #f1aeb5;
    color: #721c24;
}

.message-content {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
    padding-right: 40px; /* 为关闭按钮留出空间 */
}

.message-content .dashicons {
    font-size: 18px;
}

/* 消息关闭按钮样式 */
.forum-message .message-close {
    position: absolute;
    top: 8px;
    right: 12px;
    background: none;
    border: none;
    color: inherit;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    padding: 0;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.2s ease;
    opacity: 0.7;
}

.forum-message .message-close:hover {
    opacity: 1;
    background: rgba(0, 0, 0, 0.1);
    transform: scale(1.1);
}

.forum-message .message-close:active {
    transform: scale(0.95);
}

/* 空状态样式 */
.mjzj-no-posts {
    text-align: center;
    padding: 60px 20px;
    background: #ffffff;
    border-radius: 12px;
    margin: 20px 0;
}

.no-posts-content {
    max-width: 400px;
    margin: 0 auto;
}

.no-posts-icon {
    font-size: 48px;
    margin-bottom: 20px;
    opacity: 0.7;
}

.no-posts-content h3 {
    color: #2c3e50;
    font-size: 22px;
    margin-bottom: 12px;
}

.no-posts-content p {
    color: #6c757d;
    margin-bottom: 24px;
    line-height: 1.6;
}

.btn-create-first {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(52, 152, 219, 0.3);
}

.btn-create-first:hover {
    background: linear-gradient(135deg, #2980b9, #1f5f8b);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(52, 152, 219, 0.4);
    color: white;
}

.btn-create-first .dashicons {
    font-size: 16px;
}

/* 头部按钮样式 */
.my-posts-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 16px;
    border: 2px solid #3498db;
    background: transparent;
    color: #3498db;
    text-decoration: none;
    border-radius: 6px;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 14px;
}

.my-posts-btn:hover {
    background: #3498db;
    color: white;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
}

.my-posts-btn .dashicons {
    font-size: 16px;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .my-posts-container .posts-controls-bar {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
    }
    
    .my-posts-actions {
        justify-content: center;
    }
    
    .my-post-card .post-meta-footer {
        flex-direction: column;
        align-items: stretch;
        gap: 16px;
    }
    
    .my-post-card .post-meta-info {
        justify-content: center;
        gap: 12px;
    }
    
    .my-post-card .post-actions {
        justify-content: center;
    }
    
    .my-post-card .post-title-section {
        flex-direction: column;
        gap: 12px;
    }
    
    .my-post-card .mjzj-post-title {
        padding-right: 0;
    }
}

@media (max-width: 480px) {
    .my-post-card {
        margin-bottom: 16px;
    }
    
    .my-post-card .post-card-content {
        padding: 16px;
    }
    
    .my-post-card .post-meta-info {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }
    
    .my-post-card .post-actions {
        flex-direction: column;
        gap: 8px;
    }
    
    .action-btn {
        width: 100%;
        justify-content: center;
    }
    
    .forum-message {
        top: 60px;
        left: 10px;
        right: 10px;
        transform: none;
        min-width: auto;
        max-width: none;
        animation: gentleShakeMobile 0.6s ease-in-out;
    }
    
    .login-buttons {
        flex-direction: column;
    }
} 

/* ===============================
   确保所有话题链接都在新窗口打开
   =============================== */

/* 主要的话题链接样式 */
.post-title-link,
a[href*="forum_action=view"],
a[href*="forum_post"] {
    /* 确保链接正常可点击 */
    pointer-events: auto !important;
    /* 添加新窗口打开的视觉提示 */
    position: relative;
}

/* 为新窗口链接添加视觉提示 */
.post-title-link::after {
    content: " ↗";
    font-size: 0.8em;
    color: #6c757d;
    opacity: 0.7;
    margin-left: 4px;
}

/* 移除hover状态下的视觉提示透明度 */
.post-title-link:hover::after {
    opacity: 1;
}

/* 确保搜索结果中的链接也正确 */
.search-result-item a,
.wp-forum-search-form a[href*="forum"] {
    display: block;
    color: inherit;
    text-decoration: none;
}

/* 链接状态样式 */
.post-title-link:visited,
.post-title-link:link,
.post-title-link:active {
    color: inherit;
    text-decoration: none;
}

/* 确保没有任何CSS会影响点击行为 */
.mjzj-post-card * {
    pointer-events: auto;
}

/* 用户选择行为 */
.mjzj-post-card {
    user-select: none;
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
}

.post-title-link {
    user-select: text;
    -webkit-user-select: text;
    -moz-user-select: text;
    -ms-user-select: text;
} 