* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    background: linear-gradient(135deg, #e0e5ec 0%, #f5f7fa 100%);
    color: #333;
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.page-wrapper {
    flex: 1;
    display: flex;
    flex-direction: column;
}

/* 头部样式 */
.header {
    background: #e0e5ec;
    box-shadow: 0 2px 8px rgba(163, 177, 198, 0.4);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.header-logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

.logo {
    max-height: 45px;
    max-width: 150px;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: all 0.3s ease;
}

.logo:hover {
    transform: scale(1.05);
}

.header-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: #e0e5ec;
    box-shadow: 4px 4px 8px rgba(163, 177, 198, 0.6),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 13px;
    color: #333;
    text-decoration: none;
    transition: all 0.3s;
    white-space: nowrap;
    position: relative;
}

.header-btn:hover {
    box-shadow: 2px 2px 4px rgba(163, 177, 198, 0.6),
                -2px -2px 4px rgba(255, 255, 255, 0.5);
    transform: translateY(-1px);
}

.header-btn:active {
    box-shadow: inset 2px 2px 4px rgba(163, 177, 198, 0.6),
                inset -2px -2px 4px rgba(255, 255, 255, 0.5);
    transform: translateY(0);
}

.header-btn .badge {
    position: absolute;
    top: -4px;
    right: -4px;
    background: #ff4d4f;
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
}

.search-box {
    flex: 1;
    max-width: 500px;
}

.search-box input {
    width: 100%;
    padding: 10px 15px;
    background: #e0e5ec;
    box-shadow: inset 4px 4px 8px rgba(163, 177, 198, 0.6),
                inset -4px -4px 8px rgba(255, 255, 255, 0.5);
    border: none;
    border-radius: 20px;
    font-size: 14px;
    transition: all 0.3s;
}

.search-box input:focus {
    outline: none;
    box-shadow: inset 6px 6px 12px rgba(163, 177, 198, 0.6),
                inset -6px -6px 12px rgba(255, 255, 255, 0.5);
}

.announcement-badge {
    background: #ff4d4f;
    color: white;
    padding: 5px 12px;
    border-radius: 12px;
    font-size: 12px;
    cursor: pointer;
    white-space: nowrap;
}

.header-center {
    display: flex;
    gap: 15px;
    flex: 1;
    justify-content: center;
    align-items: center;
}

.nav-link {
    color: #333;
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 6px;
    transition: all 0.3s;
    font-size: 14px;
    white-space: nowrap;
}

.nav-link:hover {
    background: rgba(24, 144, 255, 0.1);
    color: #1890ff;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-shrink: 0;
}

.btn {
    padding: 8px 20px;
    background: #e0e5ec;
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
    border: none;
    border-radius: 12px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s;
    text-decoration: none;
    display: inline-block;
    color: #333;
}

.btn:hover {
    box-shadow: 4px 4px 8px rgba(163, 177, 198, 0.6),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
}

.btn:active {
    box-shadow: inset 4px 4px 8px rgba(163, 177, 198, 0.6),
                inset -4px -4px 8px rgba(255, 255, 255, 0.5);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 6px 6px 12px rgba(102, 126, 234, 0.4),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
}

.btn-primary:hover {
    box-shadow: 4px 4px 8px rgba(102, 126, 234, 0.4),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
}

.btn-outline {
    background: #e0e5ec;
    color: #667eea;
}

.btn-outline:hover {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
}

.user-menu {
    position: relative;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    cursor: pointer;
    object-fit: cover;
    border: 2px solid #e0e5ec;
    transition: all 0.3s;
}

.user-avatar:hover {
    border-color: #1890ff;
    transform: scale(1.05);
}

.dropdown {
    position: absolute;
    top: 50px;
    right: 0;
    background: white;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    min-width: 180px;
    display: none;
    z-index: 1001;
}

.dropdown.show {
    display: block;
    animation: fadeIn 0.2s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.dropdown-item {
    padding: 12px 20px;
    cursor: pointer;
    transition: background 0.3s;
    border-bottom: 1px solid #f0f0f0;
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background: #f5f5f5;
}

/* 主内容区 */
.main-container {
    max-width: 1600px;
    margin: 20px auto;
    padding: 0 20px 20px 20px;
    display: grid;
    grid-template-columns: 250px 1fr 280px;
    gap: 20px;
    flex: 1 0 auto;
    position: relative;
}

/* 固定侧边栏 */
.sidebar-left,
.sidebar-right {
    position: sticky;
    top: 80px;
    height: fit-content;
    max-height: calc(100vh - 100px);
    overflow-y: auto;
}

/* 侧边栏 */
.sidebar {
    background: #e0e5ec;
    box-shadow: 9px 9px 16px rgba(163, 177, 198, 0.6),
                -9px -9px 16px rgba(255, 255, 255, 0.5);
    border-radius: 12px;
    padding: 20px;
    height: fit-content;
}

.sidebar h3 {
    margin-bottom: 15px;
    font-size: 16px;
    color: #333;
}

.hot-list {
    list-style: none;
}

.hot-item {
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
    transition: color 0.3s;
}

.hot-item:hover {
    color: #1890ff;
}

.hot-item:last-child {
    border-bottom: none;
}

.hot-rank {
    display: inline-block;
    width: 20px;
    height: 20px;
    line-height: 20px;
    text-align: center;
    border-radius: 4px;
    margin-right: 8px;
    font-size: 12px;
    font-weight: bold;
}

.hot-rank.top3 {
    background: linear-gradient(135deg, #ff6b6b, #ffa07a);
    color: white;
}

/* 资源网格 - 4列布局 */
.resource-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

@media (max-width: 1400px) {
    .resource-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    .resource-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .resource-grid {
        grid-template-columns: 1fr;
    }
}

.resource-card {
    background: #e0e5ec;
    box-shadow: 9px 9px 16px rgba(163, 177, 198, 0.6),
                -9px -9px 16px rgba(255, 255, 255, 0.5);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    cursor: pointer;
}

.resource-card:hover {
    transform: translateY(-4px);
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
}

.resource-card.pinned {
    border: 2px solid #ff4d4f;
    position: relative;
}

.pinned-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #ff4d4f;
    color: white;
    padding: 4px 10px;
    border-radius: 4px;
    font-size: 12px;
    z-index: 1;
}

.resource-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
    background: #f0f0f0;
    display: block;
}

.resource-info {
    padding: 15px;
}

.resource-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.resource-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #999;
}

/* 分页 */
.pagination {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 30px;
}

.page-btn {
    padding: 8px 12px;
    border: 1px solid #ddd;
    background: white;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s;
}

.page-btn:hover {
    border-color: #1890ff;
    color: #1890ff;
}

.page-btn.active {
    background: #1890ff;
    color: white;
    border-color: #1890ff;
}

/* 底部 - 更小更简洁 */
.footer {
    background: #e0e5ec;
    box-shadow: 0 -4px 8px rgba(163, 177, 198, 0.4),
                0 4px 8px rgba(255, 255, 255, 0.3);
    margin-top: auto;
    padding: 10px 0;
    flex-shrink: 0;
}

.footer-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 20px;
    text-align: center;
}

.footer-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.footer-left .logo {
    max-height: 40px;
}

.footer-center {
    text-align: center;
    color: #666;
    font-size: 14px;
}

.footer-right {
    display: flex;
    gap: 15px;
}

/* 模态框 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.5);
    z-index: 2000;
    justify-content: center;
    align-items: center;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: #e0e5ec;
    box-shadow: 9px 9px 16px rgba(163, 177, 198, 0.6),
                -9px -9px 16px rgba(255, 255, 255, 0.5);
    border-radius: 12px;
    padding: 30px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.modal-title {
    font-size: 20px;
    font-weight: 600;
}

.close-btn {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #999;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input,
.form-group textarea {
    width: 100%;
    padding: 10px;
    background: #e0e5ec;
    box-shadow: inset 4px 4px 8px rgba(163, 177, 198, 0.6),
                inset -4px -4px 8px rgba(255, 255, 255, 0.5);
    border: none;
    border-radius: 8px;
    font-size: 14px;
}

.form-group input:focus,
.form-group textarea:focus {
    outline: none;
    box-shadow: inset 6px 6px 12px rgba(163, 177, 198, 0.6),
                inset -6px -6px 12px rgba(255, 255, 255, 0.5);
}

/* 评论区 */
.comments-section {
    background: #e0e5ec;
    box-shadow: 9px 9px 16px rgba(163, 177, 198, 0.6),
                -9px -9px 16px rgba(255, 255, 255, 0.5);
    border-radius: 12px;
    padding: 20px;
    margin-top: 20px;
}

.comment-item {
    padding: 15px 0;
    border-bottom: 1px solid #f0f0f0;
}

.comment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.comment-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
}

.comment-author {
    font-weight: 600;
    font-size: 14px;
}

.comment-role {
    background: #1890ff;
    color: white;
    padding: 2px 8px;
    border-radius: 4px;
    font-size: 12px;
}

.comment-content {
    margin-left: 46px;
    color: #666;
    font-size: 14px;
}

.comment-actions {
    margin-left: 46px;
    margin-top: 8px;
    display: flex;
    gap: 15px;
    font-size: 12px;
    color: #999;
}

.comment-action {
    cursor: pointer;
    transition: color 0.3s;
}

.comment-action:hover {
    color: #1890ff;
}

/* 拟态风格 */
.neumorphic {
    background: #e0e5ec;
    box-shadow: 9px 9px 16px rgba(163, 177, 198, 0.6),
                -9px -9px 16px rgba(255, 255, 255, 0.5);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.neumorphic-inset {
    background: #e0e5ec;
    box-shadow: inset 6px 6px 12px rgba(163, 177, 198, 0.6),
                inset -6px -6px 12px rgba(255, 255, 255, 0.5);
    border-radius: 12px;
}

.neumorphic:hover {
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
}

/* 应用拟态风格到卡片 */
.card.neumorphic-style,
.resource-card.neumorphic-style {
    background: #e0e5ec;
    box-shadow: 9px 9px 16px rgba(163, 177, 198, 0.6),
                -9px -9px 16px rgba(255, 255, 255, 0.5);
    border: none;
}

.card.neumorphic-style:hover,
.resource-card.neumorphic-style:hover {
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
}

/* 拟态按钮 */
.btn.neumorphic-style {
    background: #e0e5ec;
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
    border: none;
}

.btn.neumorphic-style:active {
    box-shadow: inset 4px 4px 8px rgba(163, 177, 198, 0.6),
                inset -4px -4px 8px rgba(255, 255, 255, 0.5);
}

/* 拟态输入框 */
input.neumorphic-style,
textarea.neumorphic-style,
select.neumorphic-style {
    background: #e0e5ec;
    box-shadow: inset 4px 4px 8px rgba(163, 177, 198, 0.6),
                inset -4px -4px 8px rgba(255, 255, 255, 0.5);
    border: none;
}

input.neumorphic-style:focus,
textarea.neumorphic-style:focus,
select.neumorphic-style:focus {
    box-shadow: inset 6px 6px 12px rgba(163, 177, 198, 0.6),
                inset -6px -6px 12px rgba(255, 255, 255, 0.5);
}

/* 响应式 */
@media (max-width: 1200px) {
    .main-container {
        grid-template-columns: 1fr;
    }
    
    .sidebar {
        display: none;
    }
}

@media (max-width: 768px) {
    .header-container {
        flex-wrap: wrap;
    }
    
    .header-center {
        order: 3;
        width: 100%;
        margin-top: 10px;
    }
    
    .resource-grid {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    }
}

/* 拟态UI增强样式 */
.dropdown {
    background: #e0e5ec;
    box-shadow: 9px 9px 16px rgba(163, 177, 198, 0.6),
                -9px -9px 16px rgba(255, 255, 255, 0.5);
    border-radius: 12px;
}

.dropdown-item {
    transition: all 0.3s ease;
}

.dropdown-item:hover {
    background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%);
}

.user-avatar {
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
}

.user-avatar:hover {
    box-shadow: 4px 4px 8px rgba(163, 177, 198, 0.6),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
}

.comment-avatar {
    box-shadow: 4px 4px 8px rgba(163, 177, 198, 0.6),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
}

.page-btn {
    background: #e0e5ec;
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
    border: none;
    transition: all 0.3s ease;
}

.page-btn:hover {
    box-shadow: 4px 4px 8px rgba(163, 177, 198, 0.6),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
}

.page-btn.active {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: inset 4px 4px 8px rgba(102, 126, 234, 0.6),
                inset -4px -4px 8px rgba(118, 75, 162, 0.5);
}

.announcement-badge {
    background: linear-gradient(135deg, #ff6b6b 0%, #ffa07a 100%);
    box-shadow: 6px 6px 12px rgba(255, 107, 107, 0.4),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
}

.announcement-badge:hover {
    box-shadow: 4px 4px 8px rgba(255, 107, 107, 0.4),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
}

.pinned-badge {
    background: linear-gradient(135deg, #ff6b6b 0%, #ffa07a 100%);
    box-shadow: 4px 4px 8px rgba(255, 107, 107, 0.4),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
}

.comment-role {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    box-shadow: 4px 4px 8px rgba(102, 126, 234, 0.4),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
}

/* 动画效果 */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes slideIn {
    from {
        transform: translateX(-100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

@keyframes shimmer {
    0% {
        background-position: -1000px 0;
    }
    100% {
        background-position: 1000px 0;
    }
}

.resource-card {
    animation: fadeIn 0.5s ease-out;
}

.resource-card:nth-child(1) { animation-delay: 0.1s; }
.resource-card:nth-child(2) { animation-delay: 0.2s; }
.resource-card:nth-child(3) { animation-delay: 0.3s; }
.resource-card:nth-child(4) { animation-delay: 0.4s; }
.resource-card:nth-child(5) { animation-delay: 0.5s; }
.resource-card:nth-child(6) { animation-delay: 0.6s; }

.modal.show .modal-content {
    animation: fadeIn 0.3s ease-out;
}

.dropdown.show {
    animation: fadeIn 0.2s ease-out;
}

.hot-item {
    transition: all 0.3s ease;
}

.hot-item:hover {
    transform: translateX(5px);
    color: #667eea;
}

.nav-link {
    position: relative;
    overflow: hidden;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* 图片加载动画 */
.resource-image {
    position: relative;
    overflow: hidden;
}

.resource-image::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        90deg,
        rgba(255, 255, 255, 0) 0%,
        rgba(255, 255, 255, 0.3) 50%,
        rgba(255, 255, 255, 0) 100%
    );
    background-size: 200% 100%;
    animation: shimmer 2s infinite;
}

.resource-image[src] {
    animation: fadeIn 0.5s ease-out;
}

/* Logo动画 */
.logo {
    transition: all 0.3s ease;
}

.logo:hover {
    transform: scale(1.05) rotate(2deg);
}

/* 搜索框动画 */
.search-box {
    position: relative;
}

.search-box input {
    transition: all 0.3s ease;
}

.search-box input:focus {
    transform: scale(1.02);
}

/* 卡片悬停效果增强 */
.resource-card {
    position: relative;
    overflow: hidden;
}

.resource-card::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 ease;
}

.resource-card:hover::before {
    left: 100%;
}

/* 按钮点击效果 */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:active::after {
    width: 300px;
    height: 300px;
}

/* 滚动条样式 */
::-webkit-scrollbar {
    width: 10px;
    height: 10px;
}

::-webkit-scrollbar-track {
    background: #e0e5ec;
    box-shadow: inset 2px 2px 4px rgba(163, 177, 198, 0.6),
                inset -2px -2px 4px rgba(255, 255, 255, 0.5);
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 5px;
    box-shadow: 2px 2px 4px rgba(102, 126, 234, 0.4);
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(135deg, #764ba2 0%, #667eea 100%);
}

/* 加载动画 */
.loading {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(102, 126, 234, 0.3);
    border-radius: 50%;
    border-top-color: #667eea;
    animation: spin 1s ease-in-out infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* 图片错误占位符样式 */
img[src=""],
img:not([src]) {
    background: linear-gradient(135deg, #e0e5ec 0%, #f5f7fa 100%);
    display: block;
}

/* 响应式动画优化 */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

/* 返回顶部按钮 */
.back-to-top {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
    z-index: 999;
}

.back-to-top:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.6);
}

/* 图标按钮 */
.btn-icon {
    width: 40px;
    height: 40px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.btn-icon .badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ff4d4f;
    color: white;
    border-radius: 10px;
    padding: 2px 6px;
    font-size: 10px;
    font-weight: bold;
    min-width: 18px;
    text-align: center;
}

/* 底部优化 */
.footer {
    padding: 15px 0;
    margin-top: auto;
}

.footer-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 20px;
}

.footer-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.footer-section {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-logo {
    max-height: 30px;
    width: auto;
}

.footer-center {
    flex-direction: column;
    gap: 5px;
    text-align: center;
}

.footer-center p {
    margin: 0;
    font-size: 12px;
    color: #666;
}

.footer-links {
    gap: 10px;
}

.btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

/* 下拉菜单优化 */
.dropdown-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dropdown-item svg {
    flex-shrink: 0;
}

/* 搜索输入框 */
.search-input {
    width: 100%;
    padding: 12px 15px;
    font-size: 16px;
    border: none;
    border-radius: 8px;
    background: #e0e5ec;
    box-shadow: inset 4px 4px 8px rgba(163, 177, 198, 0.6),
                inset -4px -4px 8px rgba(255, 255, 255, 0.5);
}

.search-input:focus {
    outline: none;
    box-shadow: inset 6px 6px 12px rgba(163, 177, 198, 0.6),
                inset -6px -6px 12px rgba(255, 255, 255, 0.5);
}

.btn-block {
    width: 100%;
    margin-top: 15px;
}

/* 分页信息 */
.pagination-info {
    text-align: center;
    margin-top: 15px;
    color: #666;
    font-size: 14px;
}

/* 资源卡片优化 - 显示完整信息 */
.resource-card {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.resource-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

/* 无图片时的占位符 */
.resource-placeholder {
    width: 100%;
    height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 48px;
    font-weight: bold;
}

/* 响应式优化 */
@media (max-width: 1200px) {
    .main-container {
        grid-template-columns: 1fr;
    }
    
    .sidebar-left,
    .sidebar-right {
        position: static;
        max-height: none;
    }
}

/* 搜索栏样式 */
.search-bar {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 15px;
    border-radius: 12px;
    margin-bottom: 15px;
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
}

.search-bar input[type="text"] {
    padding: 10px 15px;
    border: none;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(5px);
    font-size: 14px;
}

.search-bar input[type="text"]:focus {
    outline: none;
    background: rgba(255, 255, 255, 0.3);
}

/* 分类筛选样式 */
.category-filter {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    padding: 15px;
    border-radius: 12px;
    margin-bottom: 20px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
}

/* 返回顶部按钮（可拖动） */
.back-to-top-draggable {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: move;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    transition: transform 0.2s ease;
    z-index: 9999;
    user-select: none;
}

.back-to-top-draggable:hover {
    transform: scale(1.1);
}

.back-to-top-draggable:active {
    cursor: grabbing;
}

/* 用户菜单优化 */
.user-menu {
    position: relative;
    cursor: pointer;
}

.user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    box-shadow: 4px 4px 8px rgba(163, 177, 198, 0.6),
                -4px -4px 8px rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
}

.user-avatar:hover {
    transform: scale(1.05);
}

.dropdown {
    position: absolute;
    top: 50px;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    min-width: 150px;
    display: none;
    z-index: 1000;
}

.dropdown.show {
    display: block;
    animation: fadeIn 0.2s ease;
}

.dropdown-item {
    padding: 12px 20px;
    cursor: pointer;
    transition: background 0.3s;
    border-bottom: 1px solid rgba(0,0,0,0.05);
}

.dropdown-item:last-child {
    border-bottom: none;
}

.dropdown-item:hover {
    background: rgba(102, 126, 234, 0.1);
}

/* 聊天窗口玻璃态效果 */
.chat-container,
.conversation-list,
.chat-window,
.message-input-container {
    background: rgba(255, 255, 255, 0.15) !important;
    backdrop-filter: blur(15px);
    -webkit-backdrop-filter: blur(15px);
    border: 1px solid rgba(255, 255, 255, 0.25);
}

/* 资源卡片参考图布局 */
.resource-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.resource-card {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 6px 6px 12px rgba(163, 177, 198, 0.6),
                -6px -6px 12px rgba(255, 255, 255, 0.5);
    transition: all 0.3s ease;
    cursor: pointer;
    display: flex;
    flex-direction: column;
}

.resource-card:hover {
    transform: translateY(-5px);
    box-shadow: 8px 8px 16px rgba(163, 177, 198, 0.7),
                -8px -8px 16px rgba(255, 255, 255, 0.6);
}

.resource-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
    display: block;
}

.resource-placeholder {
    width: 100%;
    height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    font-size: 48px;
    font-weight: bold;
}

.resource-info {
    padding: 15px;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.resource-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    line-height: 1.4;
}

.resource-meta {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #999;
}

/* 响应式布局 */
@media (max-width: 1400px) {
    .resource-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    .resource-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .main-container {
        grid-template-columns: 1fr;
    }
    
    .sidebar-left,
    .sidebar-right {
        display: none;
    }
}

@media (max-width: 768px) {
    .resource-grid {
        grid-template-columns: 1fr;
    }
}

/* 头部按钮样式 */
.header-btn {
    display: flex;
    align-items: center;
    gap: 5px;
    padding: 6px 12px;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 13px;
    transition: all 0.3s;
    color: #333;
    text-decoration: none;
    white-space: nowrap;
    position: relative;
}

.header-btn:hover {
    background: rgba(255, 255, 255, 0.4);
    transform: translateY(-1px);
}

.header-btn .badge {
    position: absolute;
    top: -5px;
    right: -5px;
    background: #ff4d4f;
    color: white;
    border-radius: 10px;
    padding: 2px 5px;
    font-size: 10px;
    min-width: 16px;
    text-align: center;
}

.header-logo-link {
    display: flex;
    align-items: center;
    text-decoration: none;
}

/* 底部样式优化 */
.footer {
    background: #e0e5ec;
    box-shadow: 0 -2px 8px rgba(163, 177, 198, 0.4);
    margin-top: auto;
    padding: 12px 0;
    flex-shrink: 0;
}

.footer-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.footer-left,
.footer-center,
.footer-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.footer-logo {
    max-height: 30px;
    width: auto;
}

.footer-center {
    flex-direction: column;
    gap: 2px;
    text-align: center;
}

.footer-center p {
    margin: 0;
    font-size: 11px;
    color: #666;
}

.btn-sm {
    padding: 5px 10px;
    font-size: 12px;
}

/* 资源网格 - 固定4列，每页16个 */
.resource-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

/* 响应式 */
@media (max-width: 1400px) {
    .resource-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 1024px) {
    .resource-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .header-center {
        display: none;
    }
}

@media (max-width: 768px) {
    .resource-grid {
        grid-template-columns: 1fr;
    }
    
    .header-left .header-btn span,
    .footer-left,
    .footer-right {
        display: none;
    }
}

/* 底部样式 - 简洁紧凑 */
.footer {
    background: #e0e5ec;
    box-shadow: 0 -2px 8px rgba(163, 177, 198, 0.4);
    margin-top: auto;
    padding: 15px 0;
}

.footer-container {
    max-width: 1600px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.footer-left {
    display: flex;
    align-items: center;
}

.footer-logo {
    max-height: 35px;
    max-width: 120px;
    width: auto;
    height: auto;
    object-fit: contain;
}

.footer-center {
    flex: 1;
    text-align: center;
}

.footer-center p {
    margin: 3px 0;
    font-size: 12px;
    color: #666;
}

.footer-right {
    display: flex;
    gap: 10px;
}

.btn-sm {
    padding: 6px 14px;
    font-size: 12px;
}

/* 模态框样式 */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 2000;
    align-items: center;
    justify-content: center;
}

.modal.show {
    display: flex;
}

.modal-content {
    background: white;
    border-radius: 12px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid #f0f0f0;
}

.modal-header h3 {
    margin: 0;
    font-size: 18px;
}

.close-btn {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #999;
    line-height: 1;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s;
}

.close-btn:hover {
    color: #333;
}

.modal-content > div:last-child {
    padding: 20px;
}

/* 返回顶部按钮 */
.back-to-top-draggable {
    position: fixed;
    right: 30px;
    bottom: 30px;
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: move;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.4);
    transition: all 0.3s;
    z-index: 999;
}

.back-to-top-draggable:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(102, 126, 234, 0.5);
}

/* 徽章样式 */
.badge {
    background: #ff4d4f;
    color: white;
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 18px;
    text-align: center;
    display: inline-block;
}

/* 响应式调整 */
@media (max-width: 1024px) {
    .header-center {
        display: none;
    }
    
    .header-left {
        gap: 8px;
    }
    
    .header-btn span {
        display: none;
    }
    
    .header-btn {
        padding: 8px;
    }
}

@media (max-width: 768px) {
    .footer-container {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .footer-left,
    .footer-center,
    .footer-right {
        width: 100%;
    }
}

/* 资源占位符 */
.resource-placeholder {
    width: 100%;
    height: 200px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    font-weight: bold;
    color: white;
}

/* 分页信息 */
.pagination-info {
    text-align: center;
    margin-top: 15px;
    color: #666;
    font-size: 14px;
}

/* 评论区样式 */
.comments-section {
    background: white;
    border-radius: 8px;
    padding: 30px;
}

.comment-item {
    padding: 20px 0;
    border-bottom: 1px solid #f0f0f0;
}

.comment-item:last-child {
    border-bottom: none;
}

.comment-header {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

.comment-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
}

.comment-author {
    font-weight: 600;
    color: #333;
}

.comment-role {
    font-size: 12px;
    padding: 2px 8px;
    border-radius: 4px;
    background: #e6f7ff;
    color: #1890ff;
}

.comment-content {
    margin-left: 50px;
    line-height: 1.8;
    color: #666;
    margin-bottom: 10px;
}

.comment-actions {
    margin-left: 50px;
    display: flex;
    gap: 20px;
    font-size: 13px;
    color: #999;
}

.comment-action {
    cursor: pointer;
    transition: color 0.3s;
}

.comment-action:hover {
    color: #1890ff;
}

/* 表单样式 */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 10px 15px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: #1890ff;
}

.btn-block {
    width: 100%;
    display: block;
}

/* 消息提示 */
.message {
    position: fixed;
    top: 80px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 2001;
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        transform: translateX(400px);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

.message.success {
    background: #52c41a;
    color: white;
}

.message.error {
    background: #ff4d4f;
    color: white;
}

.message.info {
    background: #1890ff;
    color: white;
}

.message.warning {
    background: #faad14;
    color: white;
}


/* 用户操作悬浮菜单 */
#userActionMenu {
    animation: menuFadeIn 0.2s ease-out;
    border: 1px solid #e8e8e8;
}

@keyframes menuFadeIn {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.menu-item {
    padding: 10px 16px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #333;
}

.menu-item:hover {
    background: #f5f5f5;
    padding-left: 20px;
}

.menu-item:active {
    background: #e8e8e8;
}

.menu-item span {
    width: 20px;
    text-align: center;
    font-size: 16px;
}

.menu-item.danger {
    color: #ff4d4f;
}

.menu-item.danger:hover {
    background: #fff1f0;
}

.menu-item.disabled {
    color: #999;
    cursor: not-allowed;
    opacity: 0.6;
}

.menu-item.disabled:hover {
    background: transparent;
    padding-left: 16px;
}


/* 菜单淡出动画 */
@keyframes menuFadeOut {
    from {
        opacity: 1;
        transform: translateY(0);
    }
    to {
        opacity: 0;
        transform: translateY(-10px);
    }
}

/* 聊天头像样式 */
.chat-avatar {
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.chat-avatar:hover {
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

/* 图片预览容器动画 */
#imagePreviewContainer {
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 消息气泡动画 */
.message-bubble {
    animation: messageFadeIn 0.3s ease-out;
}

@keyframes messageFadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 按钮悬停效果 */
.btn {
    transition: all 0.3s ease;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.btn:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}


/* 脉冲动画 */
@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        opacity: 1;
    }
    50% {
        transform: scale(1.1);
        opacity: 0.8;
    }
}


/* 卡片淡入动画 */
@keyframes cardFadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/* 主页网格淡入动画 */
@keyframes gridFadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

/* 卡片滑入动画 */
@keyframes cardSlideIn {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 徽章脉冲动画 */
@keyframes badgePulse {
    0%, 100% {
        transform: scale(1);
    }
    50% {
        transform: scale(1.05);
    }
}

/* 资源卡片悬停效果增强 */
.resource-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.resource-card:hover {
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 12px 24px rgba(0,0,0,0.15);
}

.resource-card:active {
    transform: translateY(-4px) scale(1.01);
}

/* 热度榜项目动画 */
.hot-item {
    transition: all 0.3s ease;
}

.hot-item:hover {
    transform: translateX(5px);
    background: linear-gradient(90deg, #f5f5f5 0%, transparent 100%);
}
