/* ========================================
   LOTR Forum Layout Optimization v2.0
   精确定位主题布局结构
   ======================================== */

/* 1. 调整侧边栏宽度 - 从 311px 增加到 380px */
.sidebar {
    width: 380px !important;
    margin-left: -380px !important;
}

/* 2. 调整主内容区域右边距 - 适配新的侧边栏宽度 */
.site-layout-2 .content-layout {
    margin-right: calc(380px + 20px) !important;
}

/* 左侧边栏布局 */
.site-layout-3 .content-layout {
    margin-left: calc(380px + 20px) !important;
}

/* 3. 优化侧边栏内部间距和样式 */
.sidebar {
    padding-left: 15px;
}

.sidebar .widget,
.sidebar .card-widget {
    margin-bottom: 18px;
    border-radius: 10px;
    overflow: hidden;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.25);
    transition: all 0.3s ease;
}

.sidebar .widget:hover,
.sidebar .card-widget:hover {
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.35);
    transform: translateY(-2px);
}

/* 4. 优化侧边栏标题样式 */
.sidebar .widget-title,
.sidebar .title {
    font-size: 16px;
    font-weight: 700;
    padding: 15px 18px;
    margin: 0;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15) 0%, rgba(37, 99, 235, 0.1) 100%);
    border-left: 4px solid #3b82f6;
    color: #e2e8f0;
}

/* 5. 优化侧边栏内容区域 */
.sidebar .widget-body,
.sidebar .card-body {
    padding: 15px 18px;
    background: #1e293b;
    color: #cbd5e1;
    font-size: 14px;
    line-height: 1.7;
}

/* 6. 优化列表样式 */
.sidebar ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.sidebar li {
    padding: 10px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    transition: all 0.2s ease;
}

.sidebar li:last-child {
    border-bottom: none;
}

.sidebar li:hover {
    padding-left: 8px;
    color: #60a5fa;
}

/* 7. 优化链接样式 */
.sidebar a {
    color: #94a3b8;
    text-decoration: none;
    transition: color 0.2s ease;
}

.sidebar a:hover {
    color: #60a5fa;
}

/* 8. 状态标签优化 - 更大更醒目 */
.sidebar .badge,
.sidebar .label {
    display: inline-flex;
    align-items: center;
    padding: 5px 12px;
    border-radius: 6px;
    font-weight: 600;
    font-size: 12px;
    margin: 3px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

/* 成功/已解决 - 绿色 */
.sidebar .badge-success,
.sidebar .label-success {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: #fff;
}

/* 危险/无法解决 - 红色 */
.sidebar .badge-danger,
.sidebar .label-danger {
    background: linear-gradient(135deg, #ef4444 0%, #dc2626 100%);
    color: #fff;
}

/* 警告/推荐 - 橙色 */
.sidebar .badge-warning,
.sidebar .label-warning {
    background: linear-gradient(135deg, #f59e0b 0%, #d97706 100%);
    color: #fff;
}

/* 信息/已关闭 - 灰色 */
.sidebar .badge-secondary,
.sidebar .label-secondary {
    background: linear-gradient(135deg, #6b7280 0%, #4b5563 100%);
    color: #fff;
}

/* 主要/必填 - 蓝色 */
.sidebar .badge-primary,
.sidebar .label-primary {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    color: #fff;
}

/* 9. 优化按钮样式 */
.sidebar .btn {
    border-radius: 6px;
    padding: 8px 16px;
    font-weight: 600;
    transition: all 0.3s ease;
}

.sidebar .btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
}

/* 10. 优化标签云样式 */
.sidebar .tag-cloud-link,
.sidebar .tagcloud a {
    display: inline-block;
    padding: 6px 14px;
    margin: 4px;
    background: rgba(59, 130, 246, 0.15);
    border: 1px solid rgba(59, 130, 246, 0.3);
    border-radius: 20px;
    color: #93c5fd;
    font-size: 13px;
    transition: all 0.3s ease;
}

.sidebar .tag-cloud-link:hover,
.sidebar .tagcloud a:hover {
    background: rgba(59, 130, 246, 0.25);
    border-color: rgba(59, 130, 246, 0.5);
    color: #60a5fa;
    transform: scale(1.05);
}

/* 11. 响应式布局 - 平板和手机 */
@media (max-width: 992px) {
    .sidebar {
        width: 100% !important;
        margin-left: 0 !important;
        padding-left: 0;
        margin-top: 30px;
    }

    .site-layout-2 .content-layout,
    .site-layout-3 .content-layout {
        margin-right: 0 !important;
        margin-left: 0 !important;
    }
}

/* 12. 滚动条美化 */
.sidebar::-webkit-scrollbar {
    width: 8px;
}

.sidebar::-webkit-scrollbar-track {
    background: #1e293b;
    border-radius: 4px;
}

.sidebar::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    border-radius: 4px;
}

.sidebar::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
}
