/**
 * 案例详情弹窗样式
 * 上下结构卡片：上方图片展示，下方项目详情
 */

.case-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.case-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.case-modal {
    background: #fff;
    border-radius: var(--radius-xl, 16px);
    max-width: 640px;
    width: 100%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s ease;
}

.case-modal-overlay.active .case-modal {
    transform: scale(1) translateY(0);
}

.case-modal-image-wrap {
    width: 100%;
    height: 320px;
    background: var(--gray-100, #f1f5f9);
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.case-modal-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.case-modal-image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: var(--gray, #94a3b8);
    font-size: 16px;
    background: linear-gradient(135deg, var(--gray-100, #f1f5f9) 0%, var(--gray-200, #e2e8f0) 100%);
}

.case-modal-image-placeholder svg {
    width: 64px;
    height: 64px;
    margin-bottom: 12px;
    fill: var(--gray, #94a3b8);
}

.case-modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    border-radius: 50%;
    cursor: pointer;
    transition: all 0.2s;
    color: var(--dark-60, #475569);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
    z-index: 10;
}

.case-modal-close:hover {
    background: #fff;
    color: var(--dark, #0f172a);
    transform: scale(1.05);
}

.case-modal-close svg {
    width: 20px;
    height: 20px;
    fill: currentColor;
}

.case-modal-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

.case-modal-header {
    padding: 24px 24px 16px;
    border-bottom: 1px solid var(--border, #e2e8f0);
}

.case-modal-type {
    display: inline-block;
    padding: 5px 12px;
    background: var(--primary-100, rgba(26, 86, 219, 0.08));
    color: var(--primary, #1a56db);
    font-size: 12px;
    font-weight: 600;
    border-radius: 50px;
    margin-bottom: 10px;
}

.case-modal-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--dark, #0f172a);
    line-height: 1.3;
}

.case-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 20px 24px;
}

.case-modal-section {
    margin-bottom: 20px;
}

.case-modal-section:last-child {
    margin-bottom: 0;
}

.case-modal-section-title {
    font-size: 13px;
    font-weight: 600;
    color: var(--dark-60, #475569);
    margin-bottom: 10px;
}

.case-modal-desc {
    color: var(--dark-80, #1e293b);
    font-size: 14px;
    line-height: 1.7;
}

.case-modal-features {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.case-modal-feature-item {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    font-size: 14px;
    color: var(--dark-80, #1e293b);
}

.case-modal-feature-item svg {
    width: 16px;
    height: 16px;
    fill: var(--success, #059669);
    flex-shrink: 0;
    margin-top: 2px;
}

.case-modal-tech {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.case-modal-tech .tech-badge {
    padding: 5px 10px;
    background: var(--gray-100, #f1f5f9);
    color: var(--dark-60, #475569);
    font-size: 12px;
    font-weight: 500;
    border-radius: 4px;
}

.case-modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border, #e2e8f0);
    background: var(--gray-100, #f8fafc);
}

.case-modal-footer a {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 12px 24px;
    background: var(--primary, #1a56db);
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--radius, 8px);
    transition: all 0.2s;
}

.case-modal-footer a:hover {
    background: var(--primary-dark, #1e40af);
    color: #fff;
}

.case-modal-footer a svg {
    width: 16px;
    height: 16px;
    fill: currentColor;
}

.case-card {
    cursor: pointer;
}

@media (max-width: 640px) {
    .case-modal-overlay {
        padding: 10px;
    }

    .case-modal-image-wrap {
        height: 240px;
    }

    .case-modal-header {
        padding: 20px 20px 14px;
    }

    .case-modal-body {
        padding: 16px 20px;
    }

    .case-modal-footer {
        padding: 14px 20px;
    }

    .case-modal-title {
        font-size: 18px;
    }
}
