/* 法律AI页面样式 */
.legal-ai-content {
    margin-top: 40px;
}

.legal-ai-intro {
    text-align: center;
    margin-bottom: 60px;
    padding: 40px;
    background: linear-gradient(135deg, rgba(243, 112, 34, 0.1), rgba(243, 112, 34, 0.05));
    border-radius: 15px;
}

.legal-ai-intro h3 {
    color: var(--primary-color);
    margin-bottom: 20px;
    font-size: 2.2rem;
    font-weight: 600;
}

.legal-ai-intro p {
    font-size: 1.2rem;
    color: var(--text-color);
    max-width: 800px;
    margin: 0 auto;
    line-height: 1.6;
}

.legal-ai-modules {
    display: flex;
    flex-direction: column;
    gap: 40px;
    margin-top: 50px;
}

.ai-module {
    display: flex;
    align-items: flex-start;
    background: white;
    border-radius: 0;
    padding: 40px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.ai-module:hover {
    transform: translateY(-5px);
}

.module-icon {
    flex: 0 0 350px;
    height: 350px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-left: 60px;
    position: relative;
    background: transparent;
    border-radius: 0;
}

.ai-module:first-child .module-icon {
    margin-left: 20px;
    margin-right: 90px;
}

.ai-module:nth-child(2) .module-icon {
    margin-left: 80px;
    margin-right: 30px;
}

.ai-module:nth-child(3) .module-icon {
    margin-left: 20px;
    margin-right: 90px;
}

.module-icon::after {
    display: none;
}

.module-icon i {
    display: none;
}

.module-icon {
    position: relative;
}

.module-icon img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 0;
    /* 移除边缘虚化遮罩，保持图片原始清晰边缘 */
}

/* 去掉覆盖的渐变层，避免造成视觉上的边缘虚化或朦胧效果 */
.module-icon::before { display: none; }

.module-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    height: 100%;
    order: 1; /* 确保内容在左侧 */
}

/* 招采合规审查模块（第二个）- 文字在左，图片在右 */
.ai-module:nth-child(2) .module-icon {
    order: 2;
}

.ai-module:nth-child(2) .module-content {
    order: 1;
}

/* 招投标全流程风险分析系统模块（第四个）- 与第二个保持一致：文字在左，图片在右 */
.ai-module:nth-child(4) .module-icon {
    order: 2;
    margin-left: 80px; /* 与第二个模块对齐 */
    margin-right: 30px;
}

.ai-module:nth-child(4) .module-content {
    order: 1;
}

.module-content h4 {
    color: var(--dark-color);
    font-size: 1.8rem;
    font-weight: 600;
    margin-bottom: 20px;
    position: relative;
}

.module-content h4::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--primary-color);
    border-radius: 2px;
}

.ai-module .module-content h4::after {
    display: none;
}

.module-description {
    flex: 1;
    margin-bottom: 30px;
}

.module-description p {
    color: var(--text-color);
    line-height: 1.8;
    margin-bottom: 15px;
    font-size: 1.05rem;
    text-align: justify;
}

.module-description .disclaimer {
    color: var(--warning-color);
    font-style: italic;
    font-size: 0.95rem;
    background: rgba(250, 173, 20, 0.1);
    padding: 10px 15px;
    border-radius: 8px;
    border-left: 4px solid var(--warning-color);
}

.module-action {
    align-self: flex-end;
}

.ai-action-btn {
    background: transparent;
    color: black;
    border: none;
    padding: 15px 30px;
    border-radius: 50px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 10px;
    min-width: 140px;
    justify-content: center;
    text-transform: none;
    letter-spacing: 0.5px;
}

.ai-action-btn:hover {
    background: transparent;
    color: var(--primary-color);
    transform: none;
    box-shadow: none;
}

.ai-action-btn:active {
    background: transparent;
    color: var(--primary-hover);
    transform: none;
}

.ai-action-btn i {
    font-size: 1.2rem;
}

.risk-scan-page {
    margin-top: 30px;
    background: #fff;
    border: 1px solid #eee;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.08);
    overflow: hidden;
}

.risk-scan-frame-wrap {
    width: 100%;
    height: 75vh;
    min-height: 620px;
}

.risk-scan-frame-wrap iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

/* 响应式设计 */
@media (max-width: 1024px) {
    .ai-module {
        padding: 30px;
    }
    
    .module-icon {
        flex: 0 0 200px;
        height: 200px;
        margin-left: 40px;
    }
    
    .ai-module:nth-child(2) .module-icon {
        margin-left: 0;
        margin-right: 40px;
    }

    @media (max-width: 1024px) {
        /* 第四个模块在中屏布局的反转与边距 */
        .ai-module:nth-child(4) .module-icon {
            margin-left: 0;
            margin-right: 40px;
        }
    }
    
    .module-icon i {
        font-size: 2.5rem;
    }
    
    .module-content h4 {
        font-size: 1.6rem;
    }
}

@media (max-width: 768px) {
    .legal-ai-intro {
        padding: 30px 20px;
    }
    
    .legal-ai-intro h3 {
        font-size: 1.8rem;
    }
    
    .legal-ai-intro p {
        font-size: 1.1rem;
    }
    
    .ai-module {
        flex-direction: column;
        text-align: center;
        padding: 30px 20px;
    }
    
    .module-icon {
        flex: none;
        margin: 0 auto 30px auto;
    }
    
    .module-action {
        align-self: center;
        margin-top: 20px;
    }
    
    .module-description p {
        text-align: left;
    }

    .risk-scan-frame-wrap {
        height: 65vh;
        min-height: 460px;
    }
}

@media (max-width: 480px) {
    .legal-ai-modules {
        gap: 30px;
    }
    
    .ai-module {
        padding: 25px 15px;
    }
    
    .module-icon {
        flex: 0 0 150px;
        height: 150px;
    }
    
    .module-icon i {
        font-size: 2rem;
    }
    
    .module-content h4 {
        font-size: 1.4rem;
    }
    
    .module-description p {
        font-size: 1rem;
    }
    
    .ai-action-btn {
        padding: 12px 25px;
        font-size: 1rem;
        min-width: 120px;
    }
}

/* 动画效果 */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ai-module {
    animation: fadeInUp 0.6s ease forwards;
}

.ai-module:nth-child(1) {
    animation-delay: 0.1s;
}

.ai-module:nth-child(2) {
    animation-delay: 0.2s;
}

.ai-module:nth-child(3) {
    animation-delay: 0.3s;
}

.ai-module:nth-child(4) {
    animation-delay: 0.4s;
}

/* 鼠标悬停效果增强 */

.ai-module:hover .module-content h4 {
    color: var(--primary-color);
}

.ai-module:hover .module-content h4::after {
    width: 80px;
}
