/* ========================================
   步骤页面样式 - 专业版 v2.0
   ======================================== */

/* ==================== 步骤1: 案件类型选择 ==================== */
.case-type-container {
    display: grid;
    gap: 36px;
    margin-bottom: 36px;
}

.case-category {
    background: linear-gradient(135deg, #fafbfc 0%, var(--white) 100%);
    border-radius: var(--radius-xl);
    padding: 36px;
    border: 2px solid var(--gray-200);
    box-shadow: var(--shadow-sm);
    transition: all var(--transition-base);
}

.case-category:hover {
    border-color: var(--primary-300);
    box-shadow: var(--shadow-md);
}

.category-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 28px;
    padding-bottom: 20px;
    border-bottom: 3px solid var(--primary-500);
}

.category-icon {
    width: 36px;
    height: 36px;
    color: var(--primary-600);
    stroke-width: 2.5;
}

.category-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--primary-700);
    letter-spacing: -0.3px;
}

.case-cards {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
}

.case-card {
    background: var(--white);
    border: 3px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 28px;
    cursor: pointer;
    transition: all var(--transition-base);
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-xs);
}

.case-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-600) 0%, var(--primary-500) 100%);
    transform: scaleX(0);
    transition: transform var(--transition-base);
}

.case-card:hover {
    border-color: var(--primary-500);
    transform: translateY(-6px);
    box-shadow: 0 16px 32px rgba(59, 130, 246, 0.2);
}

.case-card:hover::before {
    transform: scaleX(1);
}

.case-card.selected {
    border-color: var(--primary-600);
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.05) 0%, rgba(147, 197, 253, 0.05) 100%);
    box-shadow: 0 12px 24px rgba(59, 130, 246, 0.25);
}

.case-card.selected::before {
    transform: scaleX(1);
}

.case-card-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary-600) 0%, var(--primary-500) 100%);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 18px;
    color: var(--white);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
    transition: all var(--transition-base);
}

.case-card:hover .case-card-icon {
    transform: scale(1.1) rotate(5deg);
}

.case-card-icon svg {
    width: 32px;
    height: 32px;
    stroke-width: 2.5;
}

.case-card-title {
    font-size: 19px;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 10px;
    letter-spacing: -0.2px;
}

.case-card-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
    font-weight: 500;
}

.case-card-badge {
    position: absolute;
    top: 18px;
    right: 18px;
    width: 28px;
    height: 28px;
    border: 3px solid var(--gray-300);
    border-radius: var(--radius-full);
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-xs);
}

.case-card.selected .case-card-badge {
    background: var(--primary-600);
    border-color: var(--primary-600);
    box-shadow: 0 2px 8px rgba(59, 130, 246, 0.4);
}

.case-card-badge svg {
    width: 18px;
    height: 18px;
    color: var(--white);
    display: none;
    stroke-width: 3;
}

.case-card.selected .case-card-badge svg {
    display: block;
}

/* ==================== 步骤2: 当事人信息 ==================== */
.party-section {
    margin: 36px 0;
    padding: 28px;
    background: linear-gradient(135deg, var(--gray-50) 0%, var(--white) 100%);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
}

.party-title {
    font-size: 19px;
    font-weight: 700;
    margin-bottom: 24px;
    color: var(--gray-900);
    display: flex;
    align-items: center;
    gap: 10px;
    letter-spacing: -0.3px;
}

.required-mark {
    color: var(--danger);
    font-size: 18px;
}

.party-list {
    display: flex;
    flex-direction: column;
    gap: 18px;
    margin-bottom: 18px;
}

.party-card {
    background: var(--white);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 24px;
    position: relative;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-xs);
}

.party-card:hover {
    border-color: var(--primary-400);
    box-shadow: var(--shadow-md);
}

.party-card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--gray-200);
}

.party-card-title {
    font-weight: 700;
    color: var(--gray-800);
    font-size: 17px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.party-card-title-icon {
    width: 22px;
    height: 22px;
    color: var(--primary-600);
    stroke-width: 2.5;
}

.entity-type-selector {
    margin-bottom: 24px;
    padding: 18px;
    background: var(--gray-50);
    border-radius: var(--radius-md);
    border: 2px solid var(--gray-200);
}

.entity-type-label {
    display: block;
    font-size: 16px;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 14px;
}

.entity-fields {
    animation: fadeInUp 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.upload-identity-icon {
    width: 56px;
    height: 56px;
    margin: 0 auto 16px;
    color: var(--gray-400);
    transition: all var(--transition-base);
}

.upload-identity-area:hover .upload-identity-icon {
    color: var(--primary-600);
    transform: translateY(-4px);
}

.upload-identity-text {
    font-size: 16px;
    font-weight: 600;
    color: var(--gray-800);
    margin-bottom: 8px;
}

.upload-identity-hint {
    font-size: 13px;
    color: var(--text-secondary);
    font-weight: 500;
}

.identity-file-info {
    background: var(--gray-50);
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-md);
    padding: 18px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.identity-file-name {
    font-size: 15px;
    color: var(--gray-800);
    font-weight: 600;
}

.btn-remove-file {
    background: none;
    border: none;
    color: var(--danger);
    cursor: pointer;
    padding: 6px 12px;
    font-size: 13px;
    font-weight: 600;
    border-radius: var(--radius-sm);
    transition: all var(--transition-base);
}

.btn-remove-file:hover {
    background: var(--danger-light);
}

/* ==================== 步骤3: 证据材料 ==================== */
.upload-section {
    margin-bottom: 36px;
}

.section-subtitle {
    font-size: 17px;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 18px;
    letter-spacing: -0.2px;
}

/* ==================== 步骤4: 案情与诉求 ==================== */
.case-field-group {
    background: var(--white);
    border: 2px solid var(--gray-200);
    border-radius: var(--radius-lg);
    padding: 24px;
    margin-bottom: 24px;
    transition: all var(--transition-base);
    box-shadow: var(--shadow-xs);
}

.case-field-group:hover {
    border-color: var(--primary-400);
    box-shadow: var(--shadow-md);
}

.case-field-group label {
    font-size: 16px;
    font-weight: 700;
    color: var(--gray-800);
    margin-bottom: 12px;
    display: block;
}

.case-field-group textarea {
    width: 100%;
    min-height: 120px;
    padding: 14px 16px;
    border: 2px solid var(--gray-300);
    border-radius: var(--radius-md);
    font-size: 15px;
    line-height: 1.7;
    resize: vertical;
    transition: all var(--transition-base);
}

.case-field-group textarea:hover {
    border-color: var(--gray-400);
}

.case-field-group textarea:focus {
    outline: none;
    border-color: var(--primary-600);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.1);
}

/* ==================== 案件类型标签 ==================== */
.case-type-badge {
    background: linear-gradient(135deg, var(--primary-50) 0%, var(--primary-100) 100%);
    border: 3px solid var(--primary-500);
    border-radius: var(--radius-xl);
    padding: 20px 28px;
    margin-bottom: 28px;
    display: flex;
    align-items: center;
    gap: 18px;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.2);
    animation: slideDown 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.case-type-badge-icon {
    width: 56px;
    height: 56px;
    background: linear-gradient(135deg, var(--primary-600) 0%, var(--primary-500) 100%);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.case-type-badge-icon svg {
    width: 32px;
    height: 32px;
    color: var(--white);
    stroke-width: 2.5;
}

.case-type-badge-content {
    flex: 1;
}

.case-type-badge-label {
    font-size: 13px;
    color: var(--primary-700);
    font-weight: 600;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.case-type-badge-name {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-800);
    letter-spacing: -0.3px;
}

.case-type-badge-change {
    background: var(--white);
    border: 2px solid var(--primary-600);
    color: var(--primary-600);
    padding: 10px 20px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 700;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all var(--transition-base);
    flex-shrink: 0;
    box-shadow: var(--shadow-xs);
}

.case-type-badge-change:hover {
    background: var(--primary-600);
    color: var(--white);
    transform: translateX(-3px);
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

.case-type-badge-change svg {
    width: 18px;
    height: 18px;
    stroke-width: 2.5;
}

/* ==================== 结果页面 ==================== */
.result-actions {
    margin-top: 48px;
    text-align: center;
}

#btnNewCase {
    background: var(--white);
    color: var(--primary-600);
    border: 3px solid var(--primary-600);
    padding: 16px 48px;
    font-size: 17px;
    font-weight: 700;
    border-radius: var(--radius-lg);
    cursor: pointer;
    transition: all var(--transition-base);
    display: inline-flex;
    align-items: center;
    gap: 12px;
    box-shadow: var(--shadow-sm);
}

#btnNewCase:hover {
    background: var(--primary-600);
    color: var(--white);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(59, 130, 246, 0.3);
}

#btnNewCase svg {
    width: 22px;
    height: 22px;
    stroke-width: 2.5;
}

/* ==================== 响应式调整 ==================== */
@media (max-width: 768px) {
    .case-cards {
        grid-template-columns: 1fr;
    }

    .case-card {
        padding: 22px;
    }

    .case-category {
        padding: 24px;
    }

    .category-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .case-type-badge {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
        padding: 20px;
    }

    .case-type-badge-icon {
        width: 48px;
        height: 48px;
    }

    .case-type-badge-icon svg {
        width: 28px;
        height: 28px;
    }

    .case-type-badge-name {
        font-size: 18px;
    }

    .case-type-badge-change {
        width: 100%;
        justify-content: center;
    }
}