/* 参与项目样式 */
.project-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 30px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 20px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    display: flex;
    align-items: center;
    gap: 15px;
}

.stat-icon {
    font-size: 2rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #3b82f6;
    border-radius: 50%;
    color: white;
}

.stat-info {
    text-align: left;
}

.stat-number {
    font-size: 1.8rem;
    font-weight: bold;
    color: #1f2937;
    margin: 0;
}

.stat-label {
    color: #6b7280;
    margin: 0;
    font-size: 0.9rem;
}

/* 项目筛选器 */
.project-filter {
    display: flex;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.project-filter .filter-btn {
    background: rgba(255, 255, 255, 0.8);
    border: 2px solid #3b82f6;
    color: #3b82f6;
    padding: 8px 16px;
    border-radius: 20px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s ease;
}

.project-filter .filter-btn.active,
.project-filter .filter-btn:hover {
    background: #3b82f6;
    color: white;
}

/* 项目网格布局 */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 80px;
}

.project-item {
    opacity: 1;
    transform: translateY(0);
    transition: all 0.3s ease;
}

.project-item.hidden {
    opacity: 0;
    transform: translateY(20px);
    pointer-events: none;
}

/* 项目卡片 */
.project-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 20px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    height: 70%; /* 从80%减少到70% */
    display: flex;
    flex-direction: column;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.project-header {
    display: flex;
    align-items: flex-start;
    gap: 15px;
    margin-bottom: 15px;
}

.project-icon {
    font-size: 2.5rem;
    width: 60px;
    height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #3b82f6, #1d4ed8);
    border-radius: 12px;
    color: white;
}

.project-meta {
    flex: 1;
}

.project-title {
    font-size: 1.3rem;
    font-weight: bold;
    color: #1f2937;
    margin: 0 0 5px 0;
}

.project-date {
    color: #6b7280;
    font-size: 0.9rem;
}

.project-description {
    margin-bottom: 10px;
    flex: 1;
}

.project-description p {
    color: #4b5563;
    line-height: 1.3;
    margin: 0;
}

.project-tech {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 15px;
}

.tech-tag {
    background: #e0f2fe;
    color: #0369a1;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: 500;
}

.project-actions {
    display: flex;
    gap: 10px;
}

.action-btn {
    flex: 1;
    padding: 8px 16px;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.view-btn {
    background: #3b82f6;
    color: white;
}

.view-btn:hover {
    background: #2563eb;
}

.code-btn {
    background: #10b981;
    color: white;
}

.code-btn:hover {
    background: #059669;
}

.demo-btn {
    background: #f59e0b;
    color: white;
}

.demo-btn:hover {
    background: #d97706;
}

.app-btn {
    background: #8b5cf6;
    color: white;
}

.app-btn:hover {
    background: #7c3aed;
}

.report-btn {
    background: #ef4444;
    color: white;
}

.report-btn:hover {
    background: #dc2626;
}

.api-btn {
    background: #06b6d4;
    color: white;
}

.api-btn:hover {
    background: #0891b2;
}

.community-btn {
    background: #ec4899;
    color: white;
}

.community-btn:hover {
    background: #db2777;
}

/* 响应式设计 */
@media (max-width: 768px) {
    .project-stats {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
    }

    .project-filter {
        justify-content: center;
    }

    .project-actions {
        flex-direction: column;
    }
}
.project-card {
    background: rgba(255, 255, 255, 0.95);
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;

    /* 新增背景图片样式 */
    background-image: var(--project-bg-image);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    border: 2px solid white; /* 白色描边 */
    position: relative;
}

/* 添加半透明遮罩，确保文字可读性 */
.project-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.85);
    border-radius: 13px;
    z-index: 1;
}

/* 确保内容在遮罩上方 */
.project-header,
.project-description,
.project-tech,
.project-actions {
    position: relative;
    z-index: 2;
}