/* 全局样式重置 */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #f5f7fa 0%, #e9ecef 100%);
    min-height: 100vh;
    color: #333;
}

/* 导航栏样式 */
.navbar {
    background: linear-gradient(135deg, #2c5282 0%, #1a365d 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar-container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 20px 40px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-title {
    color: white;
    font-size: 24px;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.user-icon {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    color: white;
}

.user-icon:hover {
    background: rgba(255, 255, 255, 0.25);
    transform: scale(1.05);
}

/* 主容器样式 */
.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 40px 40px;
}

/* 项目网格布局 */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
    gap: 30px;
    animation: fadeIn 0.6s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* 项目卡片样式 */
.project-card {
    background: white;
    border-radius: 16px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    cursor: pointer;
    position: relative;
    animation: slideIn 0.5s ease-out;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.project-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.15);
}

/* 卡片图片区域 */
.card-image {
    width: 100%;
    height: 200px;
    background: #f0f0f0; /* Fallback color */
    position: relative;
    overflow: hidden;
    border-bottom: 1px solid #e2e8f0;
}

.project-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.project-card:hover .project-img {
    transform: scale(1.1);
}

.card-image::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: radial-gradient(circle, rgba(255, 255, 255, 0.2) 0%, transparent 70%);
    animation: pulse 4s ease-in-out infinite;
    pointer-events: none;
    z-index: 1;
}

@keyframes pulse {
    0%, 100% {
        transform: translate(0, 0) scale(1);
    }
    50% {
        transform: translate(10%, 10%) scale(1.1);
    }
}

/* 移除旧的医疗图标样式 */
/* .medical-icon { ... } */

/* 卡片内容区域 */
.card-content {
    padding: 24px;
}

/* 卡片头部 */
.card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
}

.project-name {
    font-size: 22px;
    font-weight: 600;
    color: #2d3748;
    line-height: 1.3;
    flex: 1;
    padding-right: 12px;
}

/* 器械类型徽章 */
.device-type {
    background: linear-gradient(135deg, #f6d365 0%, #fda085 100%);
    color: #744210;
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
    box-shadow: 0 2px 8px rgba(253, 160, 133, 0.3);
    position: relative;
    overflow: hidden;
}

.device-type::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.3), transparent);
    transition: left 0.5s;
}

.project-card:hover .device-type::before {
    left: 100%;
}

/* 链接按钮容器 */
.card-links {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

/* 链接按钮样式 */
.link-button {
    flex: 1;
    min-width: 90px;
    padding: 10px 16px;
    border: 2px solid #e2e8f0;
    border-radius: 10px;
    background: white;
    color: #4a5568;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.link-button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(102, 126, 234, 0.1);
    transform: translate(-50%, -50%);
    transition: width 0.4s, height 0.4s;
}

.link-button:hover::before {
    width: 300px;
    height: 300px;
}

.link-button:hover {
    border-color: #667eea;
    color: #667eea;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.2);
}

.link-button:active {
    transform: translateY(0);
}

/* 技术特点按钮特殊样式 */
.link-button.tech {
    border-color: #48bb78;
}

.link-button.tech:hover {
    border-color: #48bb78;
    color: #48bb78;
    box-shadow: 0 4px 12px rgba(72, 187, 120, 0.2);
}

.link-button.tech::before {
    background: rgba(72, 187, 120, 0.1);
}

/* 国内市场按钮特殊样式 */
.link-button.domestic {
    border-color: #4299e1;
}

.link-button.domestic:hover {
    border-color: #4299e1;
    color: #4299e1;
    box-shadow: 0 4px 12px rgba(66, 153, 225, 0.2);
}

.link-button.domestic::before {
    background: rgba(66, 153, 225, 0.1);
}

/* 马来市场按钮特殊样式 */
.link-button.malaysia {
    border-color: #ed8936;
}

.link-button.malaysia:hover {
    border-color: #ed8936;
    color: #ed8936;
    box-shadow: 0 4px 12px rgba(237, 137, 54, 0.2);
}

.link-button.malaysia::before {
    background: rgba(237, 137, 54, 0.1);
}

/* 竞品信息按钮特殊样式 */
.link-button.competitor {
    border-color: #9f7aea;
}

.link-button.competitor:hover {
    border-color: #9f7aea;
    color: #9f7aea;
    box-shadow: 0 4px 12px rgba(159, 122, 234, 0.2);
}

.link-button.competitor::before {
    background: rgba(159, 122, 234, 0.1);
}

/* 临床优势按钮特殊样式 */
.link-button.clinical {
    border-color: #38b2ac;
}

.link-button.clinical:hover {
    border-color: #38b2ac;
    color: #38b2ac;
    box-shadow: 0 4px 12px rgba(56, 178, 172, 0.2);
}

.link-button.clinical::before {
    background: rgba(56, 178, 172, 0.1);
}

/* 演示文稿按钮特殊样式 */
.link-button.presentation {
    border-color: #e53e3e;
}

.link-button.presentation:hover {
    border-color: #e53e3e;
    color: #e53e3e;
    box-shadow: 0 4px 12px rgba(229, 62, 62, 0.2);
}

.link-button.presentation::before {
    background: rgba(229, 62, 62, 0.1);
}

/* 可行性分析按钮特殊样式 */
.link-button.feasibility {
    border-color: #9f7aea;
}

.link-button.feasibility:hover {
    border-color: #9f7aea;
    color: #9f7aea;
    box-shadow: 0 4px 12px rgba(159, 122, 234, 0.2);
}

.link-button.feasibility::before {
    background: rgba(159, 122, 234, 0.1);
}

/* 响应式设计 */
@media (max-width: 1200px) {
    .projects-grid {
        grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
        gap: 25px;
    }
}

@media (max-width: 768px) {
    .navbar-container {
        padding: 16px 20px;
    }

    .navbar-title {
        font-size: 20px;
    }

    .container {
        padding: 24px 20px;
    }

    .projects-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .card-links {
        flex-direction: column;
    }

    .link-button {
        flex: none;
        width: 100%;
    }
}

@media (max-width: 480px) {
    .navbar-container {
        padding: 12px 16px;
    }

    .navbar-title {
        font-size: 18px;
    }

    .container {
        padding: 20px 16px;
    }

    .card-content {
        padding: 20px;
    }

    .project-name {
        font-size: 20px;
    }

    .device-type {
        font-size: 12px;
        padding: 6px 12px;
    }
}

/* 空状态样式 */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: #718096;
    grid-column: 1 / -1;
}

.empty-state-icon {
    font-size: 64px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state-text {
    font-size: 18px;
    font-weight: 500;
}

/* з״̬ʽ */
.project-card.pending {
    position: relative;
    pointer-events: none;
    filter: grayscale(100%);
    opacity: 0.8;
}

.pending-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 10;
    border-radius: 20px;
}

.pending-overlay span {
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 10px 20px;
    border-radius: 30px;
    font-weight: bold;
    font-size: 1.2rem;
    letter-spacing: 2px;
    transform: rotate(-15deg);
    box-shadow: 0 4px 15px rgba(0,0,0,0.3);
}
