/* 生产与成本管理页面样式 */

/* 解决方案区块样式 */
.solution-block {
    background: #fff;
    border-radius: 16px;
    border: 2px solid #f0f6ff;
    overflow: hidden;
    transition: all 0.3s ease;
    margin-bottom: 40px;
    position: relative;
}

.solution-block:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
}

/* 区块1样式 - 成本核算与优化 */
.block-1 {
    border-top: 8px solid rgba(255, 107, 107, 0.1);
    border-right: 2px solid rgba(255, 107, 107, 0.1);
    border-bottom: 2px solid rgba(255, 107, 107, 0.1);
    border-left: 2px solid rgba(255, 107, 107, 0.1);
}

.block-1:hover {
    border-top: 8px solid #FF6B6B;
    border-right: 2px solid #FF6B6B;
    border-bottom: 2px solid #FF6B6B;
    border-left: 2px solid #FF6B6B;
}

.block-1 .icon-circle {
    background: rgba(255, 107, 107, 0.1);
}

/* 区块2样式 - 生产订单与进度管理 */
.block-2 {
    border-top: 8px solid rgba(78, 205, 196, 0.1);
    border-right: 2px solid rgba(78, 205, 196, 0.1);
    border-bottom: 2px solid rgba(78, 205, 196, 0.1);
    border-left: 2px solid rgba(78, 205, 196, 0.1);
}

.block-2:hover {
    border-top: 8px solid #4ECDC4;
    border-right: 2px solid #4ECDC4;
    border-bottom: 2px solid #4ECDC4;
    border-left: 2px solid #4ECDC4;
}

.block-2 .icon-circle {
    background: rgba(78, 205, 196, 0.1);
}

/* 区块3样式 - 质量控制与合规 */
.block-3 {
    border-top: 8px solid rgba(106, 5, 114, 0.1);
    border-right: 2px solid rgba(106, 5, 114, 0.1);
    border-bottom: 2px solid rgba(106, 5, 114, 0.1);
    border-left: 2px solid rgba(106, 5, 114, 0.1);
}

.block-3:hover {
    border-top: 8px solid #6A0572;
    border-right: 2px solid #6A0572;
    border-bottom: 2px solid #6A0572;
    border-left: 2px solid #6A0572;
}

.block-3 .icon-circle {
    background: rgba(106, 5, 114, 0.1);
}

/* 区块头部 */
.block-header {
    padding: 30px 30px 20px;
    border-bottom: 2px solid #f0f6ff;
    position: relative;
    background: linear-gradient(135deg, rgba(248, 249, 250, 0.5), rgba(233, 236, 239, 0.3));
}

.block-number {
    position: absolute;
    top: 20px;
    right: 30px;
    font-size: 4rem;
    font-weight: 800;
    color: rgba(0, 0, 0, 0.05);
    line-height: 1;
}

.block-header h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: #1D2129;
    margin: 0;
    line-height: 1.3;
    position: relative;
    z-index: 1;
}

/* 区块主体 */
.block-body {
    padding: 30px;
}

/* 功能网格布局 */
.feature-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin-bottom: 30px;
}

.feature-item {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 20px;
    border-radius: 12px;
    border: 2px solid transparent;
    transition: all 0.3s ease;
    position: relative;
}

.feature-item:hover {
    border-color: rgba(255, 107, 107, 0.2);
    background: rgba(248, 249, 250, 0.5);
    transform: translateY(-3px);
}

.block-1 .feature-item:hover {
    border-color: rgba(255, 107, 107, 0.3);
    background: rgba(255, 107, 107, 0.05);
}

.block-2 .feature-item:hover {
    border-color: rgba(78, 205, 196, 0.3);
    background: rgba(78, 205, 196, 0.05);
}

.block-3 .feature-item:hover {
    border-color: rgba(106, 5, 114, 0.3);
    background: rgba(106, 5, 114, 0.05);
}

.feature-icon {
    display: flex;
    align-items: center;
    gap: 15px;
}

.icon-circle {
    width: 50px;
    height: 50px;
    min-width: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: all 0.3s ease;
}

.icon-symbol {
    font-size: 1.5rem;
    line-height: 1;
}

.feature-item:hover .icon-circle {
    transform: scale(1.1);
}

.block-1 .feature-item:hover .icon-circle {
    background: rgba(255, 107, 107, 0.2);
}

.block-2 .feature-item:hover .icon-circle {
    background: rgba(78, 205, 196, 0.2);
}

.block-3 .feature-item:hover .icon-circle {
    background: rgba(106, 5, 114, 0.2);
}

.feature-content {
    flex-grow: 1;
}

.feature-content h4 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1D2129;
    margin: 0 0 8px 0;
    line-height: 1.3;
}

.feature-content p {
    font-size: 0.875rem;
    color: #666;
    line-height: 1.6;
    margin: 0;
}

/* 功能标签 */
.feature-tag {
    align-self: flex-start;
    padding: 4px 12px;
    background: rgba(255, 107, 107, 0.1);
    color: #FF6B6B;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    margin-top: 5px;
    transition: all 0.3s ease;
}

.feature-item:hover .feature-tag {
    background: rgba(255, 107, 107, 0.2);
    transform: translateY(-2px);
}

/* 区块2标签样式 */
.block-2 .feature-tag {
    background: rgba(78, 205, 196, 0.1);
    color: #4ECDC4;
}

.block-2 .feature-item:hover .feature-tag {
    background: rgba(78, 205, 196, 0.2);
}

/* 区块3标签样式 */
.block-3 .feature-tag {
    background: rgba(106, 5, 114, 0.1);
    color: #6A0572;
}

.block-3 .feature-item:hover .feature-tag {
    background: rgba(106, 5, 114, 0.2);
}

/* 预览缩略图 */
.feature-preview {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-top: 12px;
    padding: 8px 12px;
    background: rgba(0, 0, 0, 0.02);
    border-radius: 8px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.feature-item:hover .feature-preview {
    background: rgba(255, 107, 107, 0.05);
    border-color: rgba(255, 107, 107, 0.2);
    transform: translateX(5px);
}

.preview-thumbnail {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #f0f6ff, #e6f7ff);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.preview-label {
    font-size: 0.75rem;
    color: #666;
    font-weight: 500;
}

/* 成本拆分图 */
.cost-breakdown {
    padding: 30px;
    background: linear-gradient(135deg, rgba(255, 107, 107, 0.05), rgba(106, 5, 114, 0.05));
    border-radius: 12px;
    border: 2px solid rgba(255, 107, 107, 0.1);
    margin-top: 30px;
}

.cost-breakdown h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1D2129;
    margin: 0 0 20px 0;
    text-align: center;
    position: relative;
    padding-bottom: 15px;
}

.cost-breakdown h4:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 3px;
    background: linear-gradient(90deg, #FF6B6B, #6A0572);
    border-radius: 2px;
}

.breakdown-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    margin-bottom: 30px;
}

.bar-chart, .donut-chart {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.chart-title {
    font-size: 1rem;
    font-weight: 600;
    color: #1D2129;
    margin-bottom: 20px;
    text-align: center;
}

.bars {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    height: 200px;
    padding: 0 20px;
}

.bar-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    flex: 1;
    max-width: 80px;
}

.bar-fill {
    width: 100%;
    border-radius: 6px 6px 0 0;
    transition: all 0.5s ease;
    min-height: 10px;
}

.bar-item:hover .bar-fill {
    transform: scaleY(1.1);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
}

.bar-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #1D2129;
    text-align: center;
}

.chart-wrapper {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.chart-legend {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.legend-item {
    display: flex;
    align-items: center;
    gap: 10px;
}

.legend-color {
    width: 12px;
    height: 12px;
    border-radius: 3px;
}

.legend-label {
    font-size: 0.75rem;
    color: #666;
}

/* 成本预警 */
.cost-alert {
    background: #fff;
    border-radius: 12px;
    padding: 20px;
    border: 2px solid #FFD166;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.alert-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #f0f0f0;
}

.alert-header h5 {
    font-size: 1.125rem;
    font-weight: 600;
    color: #1D2129;
    margin: 0;
}

.alert-status {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.alert-warning {
    background: rgba(255, 209, 102, 0.2);
    color: #FF9E1F;
    border: 1px solid rgba(255, 209, 102, 0.3);
}

.cost-comparison {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.comparison-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
}

.comparison-label {
    font-size: 0.875rem;
    color: #666;
    margin-bottom: 8px;
}

.comparison-value {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1D2129;
}

.comparison-value.negative {
    color: #FF6B6B;
}

.alert-message {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    background: rgba(255, 209, 102, 0.1);
    border-radius: 8px;
    border-left: 4px solid #FFD166;
}

.alert-icon {
    font-size: 1.25rem;
}

/* 生产进度甘特图 */
.production-gantt {
    padding: 30px;
    background: linear-gradient(135deg, rgba(78, 205, 196, 0.05), rgba(255, 209, 102, 0.05));
    border-radius: 12px;
    border: 2px solid rgba(78, 205, 196, 0.1);
    margin-top: 30px;
}

.production-gantt h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1D2129;
    margin: 0 0 20px 0;
    text-align: center;
    position: relative;
    padding-bottom: 15px;
}

.production-gantt h4:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 3px;
    background: linear-gradient(90deg, #4ECDC4, #FFD166);
    border-radius: 2px;
}

.gantt-container {
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    margin-bottom: 20px;
}

.gantt-header {
    display: grid;
    grid-template-columns: 100px 1fr 100px 120px 1fr;
    background: linear-gradient(135deg, #4ECDC4, #FFD166);
    color: #fff;
    font-weight: 600;
    padding: 15px 20px;
}

.header-cell {
    padding: 0 10px;
}

.timeline-header {
    text-align: center;
}

.gantt-body {
    padding: 20px;
}

.gantt-row {
    display: grid;
    grid-template-columns: 100px 1fr 100px 120px 1fr;
    align-items: center;
    padding: 15px 20px;
    border-bottom: 1px solid #f0f0f0;
    transition: all 0.3s ease;
}

.gantt-row:hover {
    background: rgba(78, 205, 196, 0.05);
    transform: translateX(5px);
}

.gantt-row:last-child {
    border-bottom: none;
}

.row-cell {
    padding: 0 10px;
}

.order-number {
    font-weight: 600;
    color: #4ECDC4;
}

.order-product {
    font-weight: 500;
}

.order-quantity, .order-deadline {
    text-align: center;
    color: #666;
}

.timeline-track {
    position: relative;
    height: 30px;
    background: #f0f0f0;
    border-radius: 15px;
    overflow: hidden;
}

.timeline-period {
    position: absolute;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    cursor: pointer;
}

.timeline-period:hover {
    transform: scaleY(1.1);
    z-index: 2;
}

.period-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #fff;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

.timeline-progress {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: #e0e0e0;
    z-index: 1;
    transition: width 0.5s ease;
}

.timeline-progress::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: #4CAF50;
    width: var(--progress-width, 0%);
    transition: width 0.5s ease;
}

.gantt-legend {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.timeline-axis {
    position: relative;
    height: 30px;
    background: #f8f9fa;
    border-radius: 15px;
    margin-top: 20px;
}

.axis-marker {
    position: absolute;
    top: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.75rem;
    color: #666;
    font-weight: 500;
}

/* 合规文件管理 */
.compliance-management {
    padding: 30px;
    background: linear-gradient(135deg, rgba(106, 5, 114, 0.05), rgba(78, 205, 196, 0.05));
    border-radius: 12px;
    border: 2px solid rgba(106, 5, 114, 0.1);
    margin-top: 30px;
}

.compliance-management h4 {
    font-size: 1.25rem;
    font-weight: 600;
    color: #1D2129;
    margin: 0 0 20px 0;
    text-align: center;
    position: relative;
    padding-bottom: 15px;
}

.compliance-management h4:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 3px;
    background: linear-gradient(90deg, #6A0572, #4ECDC4);
    border-radius: 2px;
}

.compliance-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    margin-bottom: 20px;
}

.compliance-files {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.file-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: #fff;
    border-radius: 8px;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.file-item:hover {
    border-color: rgba(106, 5, 114, 0.3);
    transform: translateX(5px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.file-icon {
    font-size: 1.5rem;
    width: 50px;
    height: 50px;
    background: rgba(106, 5, 114, 0.1);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.file-info {
    flex: 1;
}

.file-name {
    font-weight: 600;
    color: #1D2129;
    margin-bottom: 4px;
}

.file-details {
    font-size: 0.75rem;
    color: #666;
}

.file-status {
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
}

.status-valid {
    background: rgba(149, 231, 126, 0.2);
    color: #4CAF50;
    border: 1px solid rgba(149, 231, 126, 0.3);
}

.status-warning {
    background: rgba(255, 209, 102, 0.2);
    color: #FF9E1F;
    border: 1px solid rgba(255, 209, 102, 0.3);
}

.compliance-stats {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.stat-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    border: 2px solid rgba(106, 5, 114, 0.1);
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
}

.stat-value {
    font-size: 2rem;
    font-weight: 700;
    color: #6A0572;
    line-height: 1;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 0.75rem;
    color: #666;
    text-align: center;
}

.compliance-alert {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 20px;
    background: rgba(255, 209, 102, 0.1);
    border-radius: 8px;
    border-left: 4px solid #FFD166;
}

.alert-icon {
    font-size: 1.5rem;
}

.alert-content {
    flex: 1;
    font-size: 0.875rem;
    color: #666;
}

.alert-content strong {
    color: #1D2129;
}

/* 响应式设计 */
@media (max-width: 1199px) {
    .feature-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }
    
    .section-title {
        font-size: 2.25rem;
    }
    
    .section-subtitle {
        font-size: 1.125rem;
    }
    
    .breakdown-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .compliance-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .gantt-header, .gantt-row {
        grid-template-columns: 80px 1fr 80px 100px 1fr;
    }
}

@media (max-width: 767px) {
    .feature-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .block-header {
        padding: 20px 20px 15px;
    }
    
    .block-body {
        padding: 20px;
    }
    
    .feature-item {
        gap: 12px;
        padding: 15px;
    }
    
    .icon-circle {
        width: 40px;
        height: 40px;
        min-width: 40px;
    }
    
    .cost-breakdown,
    .production-gantt,
    .compliance-management {
        padding: 20px;
    }
    
    .gantt-header, .gantt-row {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .gantt-header {
        display: none;
    }
    
    .gantt-row {
        border: 2px solid #f0f0f0;
        border-radius: 8px;
        margin-bottom: 15px;
        padding: 15px;
    }
    
    .cost-comparison {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .gantt-legend {
        gap: 10px;
    }
    
    .compliance-stats {
        grid-template-columns: repeat(2, 1fr);
    }
}
