/* GBA Calculator Frontend Styles */

/* CSS Reset and Base Styles */
.gba-calculator * {
    box-sizing: border-box;
}

.gba-calculator {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    line-height: 1.6;
    color: #2c3e50;
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Step Container */
.gba-calc-step, .gba-step {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.gba-calc-step.active, .gba-step.active {
    box-shadow: 0 8px 30px rgba(52, 152, 219, 0.15);
}

/* Hide inactive steps */
.gba-step:not(.active) {
    display: none;
}

/* Step Headers */
.step-header, .gba-step-header {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    padding: 30px;
    text-align: center;
    position: relative;
}

.step-header h2, .gba-step-header h2, .gba-step-title {
    margin: 0 0 10px 0;
    font-size: 28px;
    font-weight: 600;
}

.step-description, .gba-step-description {
    margin: 0;
    font-size: 16px;
    opacity: 0.9;
}

.step-header-actions {
    position: absolute;
    right: 30px;
    top: 50%;
    transform: translateY(-50%);
}

.step-header-content {
    max-width: 600px;
    margin: 0 auto;
}

/* Progress Bar */
.gba-progress {
    background: #ecf0f1;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
    margin: 20px 0;
}

.gba-progress-fill {
    background: linear-gradient(90deg, #3498db 0%, #2ecc71 100%);
    height: 100%;
    border-radius: 4px;
    transition: width 0.5s ease;
    position: relative;
}

.gba-progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(90deg, transparent 0%, rgba(255,255,255,0.3) 50%, transparent 100%);
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-100%); }
    100% { transform: translateX(100%); }
}

/* Step Navigation */
.step-navigation, .gba-step-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

.gba-step-actions {
    justify-content: flex-end;
    gap: 15px;
}

/* Buttons */
.gba-button {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    position: relative;
    overflow: hidden;
}

.gba-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(52, 152, 219, 0.3);
}

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

.gba-button:disabled {
    background: #bdc3c7;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.gba-button-secondary {
    background: linear-gradient(135deg, #95a5a6 0%, #7f8c8d 100%);
}

.gba-button-success {
    background: linear-gradient(135deg, #2ecc71 0%, #27ae60 100%);
}

.gba-button-danger {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.gba-button-info {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
}

.gba-button-warning {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
}

/* Loading States */
.gba-loading {
    display: none; /* Hidden by default */
    align-items: center;
    gap: 10px;
}

.gba-loading.show {
    display: inline-flex; /* Show when needed */
}

.gba-loading-spinner {
    width: 20px;
    height: 20px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-placeholder, .gba-loading-placeholder {
    display: none; /* Hidden by default */
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: #7f8c8d;
    flex-direction: column;
    gap: 15px;
}

.loading-placeholder.show, .gba-loading-placeholder.show {
    display: flex; /* Show when needed */
}

.loading-placeholder .loading-spinner, .gba-loading-placeholder .gba-loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid #ecf0f1;
    border-top: 3px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.gba-loading-placeholder p {
    margin: 0;
    font-size: 16px;
    color: #7f8c8d;
}

/* File Upload Areas */
.gba-dropzone {
    border: 2px dashed #3498db;
    border-radius: 12px;
    padding: 40px 20px;
    text-align: center;
    background: #f8f9fa;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

.gba-dropzone:hover,
.gba-dropzone.dragover {
    border-color: #2980b9;
    background: #ebf3fd;
    transform: scale(1.02);
}

.gba-dropzone.uploading {
    pointer-events: none;
    opacity: 0.7;
}

.upload-icon {
    font-size: 48px;
    color: #3498db;
    margin-bottom: 15px;
}

.dz-message h4 {
    margin: 0 0 10px 0;
    font-size: 18px;
    color: #2c3e50;
}

.dz-message .note {
    margin: 8px 0;
    font-size: 14px;
    color: #7f8c8d;
}

.dz-message .size-limit {
    margin: 5px 0 0 0;
    font-size: 12px;
    color: #95a5a6;
}

/* Upload Progress */
.upload-progress {
    margin-top: 20px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
}

.progress-bar {
    height: 6px;
    background: #ecf0f1;
    border-radius: 3px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #3498db 0%, #2ecc71 100%);
    border-radius: 3px;
    transition: width 0.3s ease;
}

.progress-text {
    font-size: 14px;
    font-weight: 600;
    color: #2c3e50;
}

/* Form Controls */
.gba-form-group {
    margin-bottom: 25px;
}

.gba-form-label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
}

.gba-form-control {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
    background: white;
}

.gba-form-control:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.gba-form-control:invalid {
    border-color: #e74c3c;
}

/* Radio Groups */
.gba-radio-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.gba-radio-option {
    display: flex;
    align-items: flex-start;
    padding: 20px;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    position: relative;
}

.gba-radio-option:hover {
    border-color: #3498db;
    background: #f8f9fa;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
}

.gba-radio-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.gba-radio-option input[type="radio"]:checked + .radio-content {
    border-left: 4px solid #3498db;
    padding-left: 16px;
}

.gba-radio-option input[type="radio"]:checked ~ .radio-indicator {
    background: #3498db;
    border-color: #3498db;
}

.gba-radio-option input[type="radio"]:checked ~ .radio-indicator::after {
    opacity: 1;
    transform: scale(1);
}

.radio-content {
    flex: 1;
    padding-left: 20px;
}

.radio-title {
    display: block;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 5px;
}

.radio-description {
    display: block;
    font-size: 14px;
    color: #7f8c8d;
}

.radio-indicator {
    width: 20px;
    height: 20px;
    border: 2px solid #bdc3c7;
    border-radius: 50%;
    position: relative;
    transition: all 0.3s ease;
    flex-shrink: 0;
    margin-top: 2px;
}

.radio-indicator::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    transition: all 0.3s ease;
}

/* PCB Color Options */
.color-options {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    margin-top: 10px;
}

.color-option {
    position: relative;
}

.color-option input[type="radio"] {
    position: absolute;
    opacity: 0;
    cursor: pointer;
}

.color-label {
    display: block;
    padding: 12px 20px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    border: 2px solid transparent;
    position: relative;
    overflow: hidden;
}

.color-label::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 10px;
    width: 16px;
    height: 16px;
    border-radius: 3px;
    transform: translateY(-50%);
    border: 1px solid rgba(0, 0, 0, 0.2);
}

/* Color-specific styles */
.color-green { background: #27ae60; color: white; }
.color-green::before { background: #27ae60; }

.color-purple { background: #8e44ad; color: white; }
.color-purple::before { background: #8e44ad; }

.color-red { background: #e74c3c; color: white; }
.color-red::before { background: #e74c3c; }

.color-yellow { background: #f1c40f; color: #2c3e50; }
.color-yellow::before { background: #f1c40f; }

.color-blue { background: #3498db; color: white; }
.color-blue::before { background: #3498db; }

.color-white { background: #ecf0f1; color: #2c3e50; border-color: #bdc3c7; }
.color-white::before { background: #ffffff; }

.color-black { background: #2c3e50; color: white; }
.color-black::before { background: #2c3e50; }

.color-option input[type="radio"]:checked + .color-label {
    border-color: #2c3e50;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transform: scale(1.05);
}

/* Tables */
.gba-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    margin: 20px 0;
}

.gba-table th {
    background: linear-gradient(135deg, #34495e 0%, #2c3e50 100%);
    color: white;
    padding: 16px 12px;
    text-align: left;
    font-weight: 600;
    font-size: 14px;
    border-bottom: 1px solid #2c3e50;
}

.gba-table td {
    padding: 14px 12px;
    border-bottom: 1px solid #ecf0f1;
    font-size: 14px;
}

.gba-table tr:hover {
    background: #f8f9fa;
}

.gba-table tr:last-child td {
    border-bottom: none;
}

/* Price Cards */
.summary-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.summary-card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s ease;
    border-left: 4px solid #3498db;
}

.summary-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.summary-card.pcb-cost {
    border-left-color: #3498db;
}

.summary-card.bom-cost {
    border-left-color: #2ecc71;
}

.summary-card.additional-cost {
    border-left-color: #f39c12;
}

.summary-card.grand-total {
    border-left-color: #e74c3c;
    background: linear-gradient(135deg, #fff5f5 0%, #ffffff 100%);
}

.card-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 15px;
}

.card-header i {
    font-size: 24px;
    color: #3498db;
}

.card-header h4 {
    margin: 0;
    font-size: 16px;
    color: #2c3e50;
}

.cost-value {
    font-size: 32px;
    font-weight: 700;
    color: #2c3e50;
    margin-bottom: 5px;
}

.cost-value.grand {
    font-size: 36px;
    color: #e74c3c;
}

.cost-details {
    font-size: 14px;
    color: #7f8c8d;
}

/* Tooltips */
.gba-tooltip {
    position: relative;
    display: inline-block;
}

.gba-tooltip .tooltip-text {
    visibility: hidden;
    background: #2c3e50;
    color: white;
    text-align: center;
    border-radius: 6px;
    padding: 8px 12px;
    position: absolute;
    z-index: 1000;
    bottom: 125%;
    left: 50%;
    margin-left: -60px;
    width: 120px;
    font-size: 12px;
    opacity: 0;
    transition: opacity 0.3s;
}

.gba-tooltip .tooltip-text::after {
    content: "";
    position: absolute;
    top: 100%;
    left: 50%;
    margin-left: -5px;
    border-width: 5px;
    border-style: solid;
    border-color: #2c3e50 transparent transparent transparent;
}

.gba-tooltip:hover .tooltip-text {
    visibility: visible;
    opacity: 1;
}

/* Alerts and Messages */
.gba-alert {
    padding: 16px 20px;
    border-radius: 8px;
    margin: 20px 0;
    border-left: 4px solid;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.gba-alert-success {
    background: #d5f4e6;
    border-left-color: #2ecc71;
    color: #1e7e34;
}

.gba-alert-warning {
    background: #fff3cd;
    border-left-color: #f39c12;
    color: #856404;
}

.gba-alert-error {
    background: #f8d7da;
    border-left-color: #e74c3c;
    color: #721c24;
}

.gba-alert-info {
    background: #d1ecf1;
    border-left-color: #3498db;
    color: #0c5460;
}

/* Responsive Design */
@media (max-width: 768px) {
    .gba-calculator {
        padding: 10px;
    }
    
    .step-header {
        padding: 20px;
    }
    
    .step-header h2 {
        font-size: 24px;
    }
    
    .step-navigation {
        padding: 20px;
        flex-direction: column;
        gap: 15px;
    }
    
    .gba-button {
        width: 100%;
        justify-content: center;
        padding: 16px 24px;
    }
    
    .summary-cards {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .gba-radio-group {
        gap: 10px;
    }
    
    .gba-radio-option {
        padding: 15px;
    }
    
    .color-options {
        justify-content: center;
    }
    
    .color-label {
        padding: 10px 16px;
        font-size: 14px;
    }
}

@media (max-width: 480px) {
    .gba-calculator {
        padding: 5px;
    }
    
    .step-header {
        padding: 15px;
    }
    
    .step-header h2 {
        font-size: 20px;
    }
    
    .cost-value {
        font-size: 24px;
    }
    
    .cost-value.grand {
        font-size: 28px;
    }
    
    .gba-table th,
    .gba-table td {
        padding: 10px 8px;
        font-size: 12px;
    }
}

/* Dark Mode Support */
@media (prefers-color-scheme: dark) {
    .gba-calc-step {
        background: #2c3e50;
        color: #ecf0f1;
    }
    
    .gba-form-control {
        background: #34495e;
        border-color: #4a6741;
        color: #ecf0f1;
    }
    
    .gba-radio-option {
        background: #34495e;
        border-color: #4a6741;
    }
    
    .summary-card {
        background: #34495e;
        color: #ecf0f1;
    }
}

/* Animation Classes */
.fade-in {
    animation: fadeIn 0.5s ease-in;
}

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

.slide-in-right {
    animation: slideInRight 0.5s ease-out;
}

@keyframes slideInRight {
    from { opacity: 0; transform: translateX(50px); }
    to { opacity: 1; transform: translateX(0); }
}

.pulse {
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { transform: scale(1); }
    50% { transform: scale(1.05); }
    100% { transform: scale(1); }
}

/* Print Styles */
@media print {
    .gba-calculator {
        box-shadow: none;
        padding: 0;
    }
    
    .step-navigation {
        display: none;
    }
    
    .gba-button {
        display: none;
    }
    
    .summary-card {
        break-inside: avoid;
        page-break-inside: avoid;
    }
}

/* Enhanced BOM Column Mapping Styles */
.gba-modal.active {
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from { opacity: 0; transform: scale(0.9); }
    to { opacity: 1; transform: scale(1); }
}

/* Column items with confidence indicators */
.column-item {
    background: #fff;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.column-item:hover {
    border-color: #007cba;
    transform: translateX(2px);
}

.column-item.high-confidence {
    border-color: #46b450;
    background: #f8fff8;
}

.column-item.medium-confidence {
    border-color: #ffb900;
    background: #fffbf0;
}

.column-item.low-confidence {
    border-color: #dc3232;
    background: #ffeee8;
}

.column-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.column-name {
    font-weight: 600;
    font-size: 14px;
    color: #1e1e1e;
}

.confidence-badge {
    font-size: 11px;
    padding: 2px 6px;
    border-radius: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.confidence-badge.high {
    background: #46b450;
    color: white;
}

.confidence-badge.medium {
    background: #ffb900;
    color: white;
}

.confidence-badge.low {
    background: #dc3232;
    color: white;
}

.column-preview {
    font-size: 12px;
    color: #666;
    line-height: 1.3;
    font-family: monospace;
    background: #f6f7f7;
    padding: 4px 6px;
    border-radius: 4px;
    max-height: 32px;
    overflow: hidden;
}

/* Mapping completeness indicator */
.mapping-completeness {
    background: #f6f7f7;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 12px;
    margin: 15px 0;
}

.completeness-label {
    font-size: 13px;
    font-weight: 600;
    color: #1e1e1e;
    margin-bottom: 8px;
}

.completeness-count {
    color: #007cba;
}

.completeness-bar-container {
    background: #e1e5e9;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
}

.completeness-bar {
    height: 100%;
    background: #007cba;
    transition: all 0.3s ease;
    border-radius: 4px;
}

.completeness-bar.partial {
    background: linear-gradient(90deg, #ffb900, #007cba);
}

.completeness-bar.complete {
    background: #46b450;
}

/* Enhanced mapping row styles */
.mapping-row {
    transition: all 0.3s ease;
    border-radius: 6px;
    padding: 8px;
    margin-bottom: 8px;
}

.mapping-row.mapped-successfully {
    background: #f8fff8;
    border: 1px solid #46b450;
}

.mapping-row.attention-needed {
    background: #fff8dc;
    border: 1px solid #ffb900;
    animation: gentlePulse 2s ease-in-out infinite;
}

@keyframes gentlePulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); }
}

.mapping-select.auto-mapped {
    border-color: #46b450;
    background: #f8fff8;
}

.mapping-select.suggested-mapping {
    border-color: #ffb900;
    background: #fffbf0;
}

.mapping-select option.suggested {
    background: #fffbf0;
    font-weight: 600;
}

/* Enhanced preview table */
.preview-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    font-size: 13px;
}

.preview-table th {
    background: #f6f7f7;
    padding: 8px 10px;
    text-align: left;
    font-weight: 600;
    border: 1px solid #ddd;
    font-size: 12px;
}

.preview-table th .required {
    color: #dc3232;
}

.preview-table td {
    padding: 8px 10px;
    border: 1px solid #ddd;
    max-width: 150px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.preview-table td.required-field {
    background: #f8fff8;
    border-left: 3px solid #46b450;
}

.preview-table-container {
    max-height: 200px;
    overflow-y: auto;
    border: 1px solid #ddd;
    border-radius: 6px;
}

/* Modal animations and improvements */
.gba-modal-content {
    max-width: 900px;
    max-height: 90vh;
    overflow-y: auto;
}

.mapping-container {
    display: grid;
    grid-template-columns: 1fr auto 2fr;
    gap: 20px;
    align-items: start;
    margin: 20px 0;
}

.mapping-arrows {
    align-self: center;
    font-size: 24px;
    color: #007cba;
    padding: 20px 0;
}

.column-list {
    max-height: 400px;
    overflow-y: auto;
    padding-right: 8px;
}

.column-mapping-list {
    max-height: 400px;
    overflow-y: auto;
}

/* Upload status improvements */
.upload-status.warning {
    background: #fffbf0;
    color: #a67c00;
    border-color: #ffb900;
}

.upload-status.warning::before {
    content: "⚠️ ";
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .mapping-container {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .mapping-arrows {
        transform: rotate(90deg);
        padding: 10px 0;
    }
    
    .gba-modal-content {
        max-width: 95vw;
        margin: 20px auto;
    }
} 

/* Gerber Analysis Section */
.gerber-analysis-section {
    padding: 30px;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.gerber-analysis-section h3 {
    margin: 0 0 20px 0;
    font-size: 20px;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.gerber-analysis-section h3::before {
    content: "⚙️";
    font-size: 22px;
}

.analysis-results {
    background: white;
    border-radius: 8px;
    min-height: 120px;
    padding: 20px;
}

.analysis-summary {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 15px;
    background: #f8f9fa;
    border-radius: 6px;
    border-left: 3px solid #3498db;
}

.summary-label {
    font-weight: 600;
    color: #34495e;
    font-size: 14px;
}

.summary-value {
    color: #3498db;
    font-weight: 500;
    font-size: 14px;
}

/* PCB Configuration Form */
.pcb-config-container {
    padding: 0;
}

.pcb-basic-config {
    padding: 30px;
}

.pcb-basic-config h3 {
    margin: 0 0 25px 0;
    font-size: 20px;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.pcb-basic-config h3::before {
    content: "⚡";
    font-size: 22px;
}

.config-row {
    display: flex;
    gap: 30px;
    margin-bottom: 25px;
}

.config-field {
    flex: 1;
    min-width: 200px;
}

.config-field label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #34495e;
    font-size: 14px;
}

.pcb-config-input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.3s ease;
    background: white;
}

.pcb-config-input:focus {
    outline: none;
    border-color: #3498db;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

/* Dimensions Field */
.dimensions-field {
    flex: 1.5;
}

.dimensions-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
}

.dimensions-inputs input {
    flex: 1;
    min-width: 80px;
}

.dimension-separator {
    font-size: 18px;
    font-weight: bold;
    color: #7f8c8d;
}

.dimension-unit {
    font-size: 14px;
    color: #7f8c8d;
    font-weight: 500;
}

.calculated-area {
    margin-top: 8px;
    font-size: 12px;
    color: #3498db;
    font-weight: 500;
}

/* Quantity Dropdown */
.qty-dropdown-container {
    position: relative;
}

.qty-dropdown {
    appearance: none;
    background-image: url('data:image/svg+xml;charset=US-ASCII,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 4 5"><path fill="%23666" d="M2 0L0 2h4zm0 5L0 3h4z"/></svg>');
    background-repeat: no-repeat;
    background-position: right 12px center;
    background-size: 12px;
    padding-right: 35px;
}

/* PCB Specifications */
.pcb-specifications {
    padding: 30px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

.pcb-specifications h3 {
    margin: 0 0 25px 0;
    font-size: 20px;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.pcb-specifications h3::before {
    content: "📋";
    font-size: 22px;
}

/* Responsive Design */
@media (max-width: 768px) {
    .config-row {
        flex-direction: column;
        gap: 20px;
    }
    
    .config-field {
        min-width: auto;
    }
    
    .dimensions-inputs {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .dimension-separator {
        display: none;
    }
    
    .gerber-analysis-section,
    .pcb-basic-config,
    .pcb-specifications {
        padding: 20px;
    }
} 

/* Toast Notification System */
.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    max-width: 400px;
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: flex-start;
    background: white;
    border-radius: 8px;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.12);
    margin-bottom: 10px;
    padding: 16px;
    transform: translateX(100%);
    opacity: 0;
    transition: all 0.3s cubic-bezier(0.68, -0.55, 0.265, 1.55);
    pointer-events: auto;
    min-width: 300px;
    border-left: 4px solid #3498db;
}

.toast.toast-show {
    transform: translateX(0);
    opacity: 1;
}

.toast.toast-hide {
    transform: translateX(100%);
    opacity: 0;
}

.toast-success {
    border-left-color: #27ae60;
}

.toast-error {
    border-left-color: #e74c3c;
}

.toast-warning {
    border-left-color: #f39c12;
}

.toast-info {
    border-left-color: #3498db;
}

.toast-icon {
    margin-right: 12px;
    margin-top: 2px;
    font-size: 18px;
}

.toast-success .toast-icon {
    color: #27ae60;
}

.toast-error .toast-icon {
    color: #e74c3c;
}

.toast-warning .toast-icon {
    color: #f39c12;
}

.toast-info .toast-icon {
    color: #3498db;
}

.toast-content {
    flex: 1;
}

.toast-message {
    font-size: 14px;
    color: #2c3e50;
    line-height: 1.4;
    margin: 0;
}

.toast-close {
    background: none;
    border: none;
    color: #95a5a6;
    cursor: pointer;
    font-size: 14px;
    margin-left: 12px;
    padding: 4px;
    transition: color 0.2s ease;
}

.toast-close:hover {
    color: #7f8c8d;
}

/* Upload Progress Modal */
.upload-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.upload-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
}

.upload-modal-content {
    position: relative;
    background: white;
    border-radius: 16px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-width: 500px;
    width: 90%;
    max-height: 90vh;
    overflow: hidden;
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.8) translateY(-50px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.upload-modal-header {
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    color: white;
    padding: 20px 30px;
    text-align: center;
}

.upload-modal-header h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.upload-modal-body {
    padding: 30px;
}

.upload-stage {
    display: flex;
    align-items: center;
    margin-bottom: 25px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 12px;
    border: 2px solid transparent;
    transition: all 0.3s ease;
}

.upload-stage.stage-complete {
    border-color: #27ae60;
    background: #d5f4e6;
}

.upload-stage.stage-error {
    border-color: #e74c3c;
    background: #fdeaea;
}

.stage-icon {
    margin-right: 20px;
    font-size: 24px;
    color: #7f8c8d;
    width: 40px;
    text-align: center;
}

.stage-complete .stage-icon {
    color: #27ae60;
}

.stage-error .stage-icon {
    color: #e74c3c;
}

.stage-content {
    flex: 1;
}

.stage-content h4 {
    margin: 0 0 10px 0;
    font-size: 16px;
    color: #2c3e50;
}

.stage-progress {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
}

.stage-progress .progress-bar {
    flex: 1;
    height: 8px;
    background: #ecf0f1;
    border-radius: 4px;
    overflow: hidden;
}

.stage-progress .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #3498db 0%, #2ecc71 100%);
    border-radius: 4px;
    transition: width 0.3s ease;
    position: relative;
}

.stage-progress .progress-text {
    font-size: 12px;
    color: #7f8c8d;
    font-weight: 600;
    min-width: 35px;
}

.stage-status {
    font-size: 13px;
    color: #7f8c8d;
    font-style: italic;
}

.upload-overall {
    margin-top: 30px;
    padding-top: 25px;
    border-top: 1px solid #e9ecef;
}

.overall-progress {
    text-align: center;
}

.overall-progress .progress-bar {
    height: 12px;
    background: #ecf0f1;
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 10px;
}

.overall-progress .progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #3498db 0%, #2ecc71 100%);
    border-radius: 6px;
    transition: width 0.5s ease;
}

.overall-text {
    font-size: 14px;
    color: #34495e;
    font-weight: 600;
}

.upload-modal-open {
    overflow: hidden;
}

/* Responsive Design for Modals */
@media (max-width: 768px) {
    .toast-container {
        right: 10px;
        left: 10px;
        max-width: none;
    }
    
    .toast {
        min-width: auto;
    }
    
    .upload-modal-content {
        width: 95%;
        margin: 20px;
    }
    
    .upload-modal-body {
        padding: 20px;
    }
    
    .upload-stage {
        padding: 15px;
        margin-bottom: 15px;
    }
    
    .stage-icon {
        margin-right: 15px;
        font-size: 20px;
    }
} 

/* ===== STEP 1 REDESIGN STYLES ===== */

/* Step Header Enhanced */
.gba-step-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0;
    position: relative;
    overflow: hidden;
}

.gba-step-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><defs><pattern id="grain" width="100" height="100" patternUnits="userSpaceOnUse"><circle cx="25" cy="25" r="1" fill="rgba(255,255,255,0.1)"/><circle cx="75" cy="75" r="1" fill="rgba(255,255,255,0.05)"/></pattern></defs><rect width="100" height="100" fill="url(%23grain)"/></svg>');
    opacity: 0.5;
}

.step-header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 40px;
    position: relative;
    z-index: 2;
}

.step-progress-indicator {
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 24px;
    font-weight: 700;
    opacity: 0.9;
}

.step-number {
    background: rgba(255, 255, 255, 0.2);
    padding: 10px 15px;
    border-radius: 50%;
    min-width: 50px;
    text-align: center;
}

.gba-step-content {
    
    padding: 40px;
}

/* Upload Section */
.upload-section {
    /* Takes up main content area */
}

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

.upload-card {
    background: white;
    border-radius: 16px;
    border: 2px solid #e9ecef;
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.upload-card:hover {
    border-color: #3498db;
    transform: translateY(-2px);
    box-shadow: 0 10px 30px rgba(52, 152, 219, 0.1);
}

.upload-card-header {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 20px 25px;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.upload-card .upload-icon {
    width: 50px;
    height: 50px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: white;
}

.gerber-upload .upload-icon {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.bom-upload .upload-icon {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.upload-card h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    flex: 1;
}

.required-badge {
    background: #e74c3c;
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
}

.upload-dropzone {
    padding: 30px 25px;
    min-height: 200px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.upload-dropzone:hover {
    background: #f8f9fa;
}

.upload-visual {
    font-size: 48px;
    color: #bdc3c7;
    margin-bottom: 15px;
}

.upload-dropzone h4 {
    margin: 0 0 10px 0;
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

.upload-description {
    margin: 0 0 20px 0;
    color: #7f8c8d;
    font-size: 14px;
    line-height: 1.4;
}

.upload-note {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 0 15px 0;
    padding: 12px 16px;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    font-size: 13px;
    color: #495057;
}

.upload-note i {
    color: #17a2b8;
    flex-shrink: 0;
}

.upload-constraints {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.constraint-item {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-size: 13px;
    color: #95a5a6;
}

.constraint-item i {
    color: #27ae60;
}

.upload-help {
    padding: 15px 25px;
    border-top: 1px solid #f1f2f6;
}

.help-link {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #3498db;
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: color 0.2s ease;
}

.help-link:hover {
    color: #2980b9;
}

/* Requirements Section */
.requirements-section {
    margin-bottom: 30px;
}

.section-title {
    display: flex;
    align-items: center;
    gap: 12px;
    margin: 0 0 25px 0;
    font-size: 24px;
    color: #2c3e50;
    font-weight: 600;
}

.requirements-grid {
    display: grid;
    gap: 30px;
}

.requirement-card {
    background: white;
    border-radius: 16px;
    border: 2px solid #e9ecef;
    overflow: hidden;
}

.requirement-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 25px;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.requirement-header h4 {
    margin: 0;
    font-size: 18px;
    color: #2c3e50;
    font-weight: 600;
}

.help-tooltip {
    position: relative;
    cursor: help;
}

.help-tooltip i {
    color: #95a5a6;
    font-size: 16px;
}

.tooltip-content {
    position: absolute;
    top: 100%;
    right: 0;
    background: #2c3e50;
    color: white;
    padding: 10px 15px;
    border-radius: 8px;
    font-size: 13px;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 10;
}

.help-tooltip:hover .tooltip-content {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Option Grid */
.option-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    padding: 25px;
}

.option-card {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.option-card:hover {
    border-color: #3498db;
    background: #ebf3fd;
    transform: translateY(-2px);
}

.option-card.selected {
    border-color: #3498db;
    background: #ebf3fd;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.option-icon {
    font-size: 32px;
    color: #3498db;
    margin-bottom: 15px;
}

.option-card h5 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

.option-card p {
    margin: 0 0 15px 0;
    font-size: 14px;
    color: #7f8c8d;
    line-height: 1.4;
}

/* Hidden: Option prices removed from Step 1 */
.option-price {
    display: none !important;
}

/* Timeline Options */
.timeline-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 20px;
    padding: 25px;
}

.timeline-card {
    background: #f8f9fa;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.timeline-card:hover {
    border-color: #3498db;
    background: #ebf3fd;
    transform: translateY(-2px);
}

.timeline-card.selected {
    border-color: #3498db;
    background: #ebf3fd;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.timeline-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: #3498db;
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 15px;
}

.timeline-badge.expedited {
    background: #f39c12;
}

.timeline-badge.rush {
    background: #e74c3c;
}

.timeline-card h5 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

.timeline-card p {
    margin: 0 0 15px 0;
    font-size: 14px;
    color: #7f8c8d;
}

/* Hidden: Timeline prices removed from Step 1 */
.timeline-price {
    display: none !important;
}

/* ===============================
   STEP 2 - PCB Configuration
   =============================== */

/* Compact PCB Info */
.pcb-info-compact {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 20px;
    border-left: 4px solid #2c5aa0;
}

.pcb-info-compact .info-items {
    display: flex;
    gap: 30px;
    align-items: center;
}

.pcb-info-compact .info-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
}

.pcb-info-compact .info-item i {
    color: #2c5aa0;
    width: 16px;
}

.pcb-info-compact .label {
    font-weight: 600;
    color: #495057;
}

.pcb-info-compact .value {
    color: #28a745;
    font-weight: 500;
}

/* PCB Qty Grid - 7 items per row */
.qty-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 8px;
    margin-bottom: 15px;
}

.qty-item {
    background: #ffffff;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    padding: 8px 12px;
    text-align: center;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    font-size: 14px;
}

.qty-item:hover {
    border-color: #2c5aa0;
    background: #f8f9fa;
}

.qty-item.selected {
    background: #2c5aa0;
    border-color: #2c5aa0;
    color: white;
}

/* Custom Qty Section */
.custom-qty-section {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #e9ecef;
}

.custom-qty-input {
    display: flex;
    gap: 10px;
    align-items: center;
}

.custom-qty-input input {
    flex: 1;
    padding: 8px 12px;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    font-size: 14px;
}

.custom-qty-input .btn-confirm {
    background: #28a745;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: background 0.2s ease;
}

.custom-qty-input .btn-confirm:hover {
    background: #218838;
}

/* Compact Material Cards */
.material-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
    gap: 12px;
}

.material-card {
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 2px solid #e9ecef;
    background: white;
}

.material-card:hover {
    border-color: #2c5aa0;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(44, 90, 160, 0.1);
}

.material-card.selected {
    border-color: #2c5aa0;
    background: linear-gradient(135deg, #f8f9fa 0%, #e3f2fd 100%);
}

.material-info h4 {
    font-size: 14px;
    margin: 5px 0 3px 0;
    color: #2c3e50;
}

.material-info p {
    font-size: 12px;
    color: #6c757d;
    margin: 0;
}

.material-badge.popular {
    background: #ff6b6b;
    color: white;
    font-size: 10px;
    padding: 2px 8px;
    border-radius: 12px;
    margin-top: 5px;
    display: inline-block;
}

/* Product Type Grid */
.product-type-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.product-type-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.product-type-option:hover {
    border-color: #2c5aa0;
}

.product-type-option.selected {
    border-color: #2c5aa0;
    background: #f8f9fa;
}

.product-type-option h5 {
    font-size: 14px;
    margin: 0 0 5px 0;
    color: #2c3e50;
}

.product-type-option p {
    font-size: 12px;
    color: #6c757d;
    margin: 0;
}

/* Different Design Grid */
.design-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

.design-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    padding: 12px;
    text-align: center;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.design-option:hover {
    border-color: #2c5aa0;
}

.design-option.selected {
    background: #2c5aa0;
    border-color: #2c5aa0;
    color: white;
}

/* Delivery Format Grid */
.delivery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 12px;
}

.delivery-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.delivery-option:hover {
    border-color: #2c5aa0;
}

.delivery-option.selected {
    border-color: #2c5aa0;
    background: #f8f9fa;
}

.delivery-option h5 {
    font-size: 13px;
    margin: 0 0 4px 0;
    color: #2c3e50;
}

.delivery-option p {
    font-size: 11px;
    color: #6c757d;
    margin: 0;
}

/* Silkscreen Grid */
.silkscreen-grid {
    display: flex;
    gap: 15px;
}

.silkscreen-option {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    padding: 10px;
    border-radius: 6px;
    border: 2px solid #e9ecef;
    transition: all 0.2s ease;
}

.silkscreen-option:hover {
    border-color: #2c5aa0;
}

.silkscreen-option.selected {
    border-color: #2c5aa0;
    background: #f8f9fa;
}

.silkscreen-preview {
    width: 40px;
    height: 40px;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: 600;
}

/* Via Size Grid */
.via-size-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 8px;
}

.via-size-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    padding: 10px 8px;
    text-align: center;
    font-size: 12px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.via-size-option:hover {
    border-color: #2c5aa0;
}

.via-size-option.selected {
    background: #2c5aa0;
    border-color: #2c5aa0;
    color: white;
}

/* Mark Grid */
.mark-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.mark-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 12px;
    cursor: pointer;
    transition: all 0.2s ease;
}

.mark-option:hover {
    border-color: #2c5aa0;
}

.mark-option.selected {
    border-color: #2c5aa0;
    background: #f8f9fa;
}

.mark-option h5 {
    font-size: 13px;
    margin: 0 0 4px 0;
    color: #2c3e50;
}

.mark-option p {
    font-size: 11px;
    color: #6c757d;
    margin: 0;
}

/* Binary Option Grids (Gold Finger, Castellated, etc.) */
.gold-finger-grid,
.castellated-grid,
.edge-plating-grid,
.blind-slots-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    max-width: 200px;
}

.gold-finger-option,
.castellated-option,
.edge-plating-option,
.blind-slots-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 6px;
    padding: 10px;
    text-align: center;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.gold-finger-option:hover,
.castellated-option:hover,
.edge-plating-option:hover,
.blind-slots-option:hover {
    border-color: #2c5aa0;
}

.gold-finger-option.selected,
.castellated-option.selected,
.edge-plating-option.selected,
.blind-slots-option.selected {
    background: #2c5aa0;
    border-color: #2c5aa0;
    color: white;
}

/* Responsive Design for Step 2 */
@media (max-width: 768px) {
    .qty-grid {
        grid-template-columns: repeat(4, 1fr);
    }
    
    .material-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .product-type-grid,
    .delivery-grid {
        grid-template-columns: 1fr;
    }
    
    .design-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .mark-grid {
        grid-template-columns: 1fr;
    }
}

/* Step Sidebar */
.step-sidebar {
    /* Takes up sidebar area */
}

.sidebar-card {
    background: white;
    border-radius: 16px;
    border: 2px solid #e9ecef;
    padding: 25px;
    position: sticky;
    top: 20px;
}

.sidebar-card h4 {
    margin: 0 0 20px 0;
    font-size: 18px;
    color: #2c3e50;
    font-weight: 600;
    padding-bottom: 15px;
    border-bottom: 1px solid #e9ecef;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f1f2f6;
}

.summary-item:last-of-type {
    border-bottom: none;
}

.summary-label {
    font-size: 14px;
    color: #7f8c8d;
    font-weight: 500;
}

.summary-value {
    font-size: 14px;
    color: #2c3e50;
    font-weight: 600;
}

.summary-status {
    display: flex;
    align-items: center;
    gap: 8px;
}

.status-count {
    background: #f39c12;
    color: white;
    padding: 4px 8px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
}

.status-text {
    font-size: 14px;
    color: #7f8c8d;
}

/* Hidden: Estimated cost section removed from Step 1 */
.estimated-cost {
    display: none !important;
}

.cost-label {
    font-size: 14px;
    color: #7f8c8d;
    margin-bottom: 8px;
}

.cost-value {
    font-size: 28px;
    color: #27ae60;
    font-weight: 700;
}

/* Step Actions Enhanced */
.gba-step-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 30px 40px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

.actions-left {
    display: flex;
    align-items: center;
}

.upload-progress-info {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #27ae60;
    font-size: 14px;
}

.actions-right {
    display: flex;
    gap: 15px;
}

/* Upload Status States */
.upload-status {
    padding: 15px 25px;
    text-align: center;
    display: none;
}

.upload-status.success {
    display: block;
    background: #d5f4e6;
    color: #27ae60;
    border-top: 1px solid #a8e6cf;
}

.upload-status.error {
    display: block;
    background: #fdeaea;
    color: #e74c3c;
    border-top: 1px solid #f5b7b1;
}

/* Responsive Design for Step 1 */
@media (max-width: 1200px) {
    .gba-step-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }
    
    .step-sidebar {
        order: -1;
    }
    
    .sidebar-card {
        position: static;
    }
}

@media (max-width: 768px) {
    .step-header-content {
        flex-direction: column;
        gap: 20px;
        padding: 30px 20px;
        text-align: center;
    }
    
    .gba-step-content {
        padding: 20px;
    }
    
    .upload-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .option-grid,
    .timeline-options {
        grid-template-columns: 1fr;
        gap: 15px;
        padding: 20px;
    }
    
    .gba-step-actions {
        flex-direction: column;
        gap: 20px;
        padding: 20px;
    }
    
    .actions-right {
        width: 100%;
        justify-content: center;
    }
} 

/* ===== STEP 2 REDESIGN STYLES ===== */

/* Analysis Section */
.analysis-section {
    margin-bottom: 40px;
}

.analysis-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.analysis-card {
    background: white;
    border-radius: 12px;
    border: 2px solid #e9ecef;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    transition: all 0.3s ease;
}

.analysis-card:hover {
    border-color: #3498db;
    transform: translateY(-1px);
}

.analysis-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    flex-shrink: 0;
}

.analysis-content {
    flex: 1;
}

.analysis-label {
    font-size: 14px;
    color: #7f8c8d;
    margin-bottom: 5px;
}

.analysis-value {
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
}

/* Config Section */
.config-section {
    margin-bottom: 40px;
}

.config-group {
    margin-bottom: 30px;
}

.config-label {
    display: block;
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 15px;
}

.config-label .required {
    color: #e74c3c;
    margin-left: 5px;
}

/* Material Cards */
.material-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
}

.material-card {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
}

.material-card:hover {
    border-color: #3498db;
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(52, 152, 219, 0.1);
}

.material-card.selected {
    border-color: #3498db;
    background: #ebf3fd;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.material-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 28px;
    margin-bottom: 15px;
}

.material-info h4 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: #2c3e50;
    font-weight: 600;
}

.material-info p {
    margin: 0;
    font-size: 14px;
    color: #7f8c8d;
}

.material-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #e74c3c;
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    text-transform: uppercase;
}

.material-badge.popular {
    background: #27ae60;
}

/* Layers Grid */
.layers-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(60px, 1fr));
    gap: 10px;
    max-width: 600px;
}

.layer-button {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 15px 10px;
    text-align: center;
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    cursor: pointer;
    transition: all 0.3s ease;
    min-height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.layer-button:hover {
    border-color: #3498db;
    background: #f8f9fa;
}

.layer-button.selected {
    border-color: #3498db;
    background: #3498db;
    color: white;
}

.layer-button.more {
    background: #f8f9fa;
    color: #7f8c8d;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
}

/* Dimensions Input */
.dimensions-input {
    display: flex;
    align-items: center;
    gap: 15px;
    max-width: 400px;
}

.dimension-field {
    flex: 1;
}

.dimension-field input {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    text-align: center;
    transition: border-color 0.3s ease;
}

.dimension-field input:focus {
    outline: none;
    border-color: #3498db;
}

.dimension-separator {
    font-size: 20px;
    font-weight: 600;
    color: #7f8c8d;
}

.dimension-unit select {
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    background: white;
    min-width: 80px;
}

.dimension-info {
    margin-top: 10px;
}

.calculated-area {
    font-size: 14px;
    color: #7f8c8d;
}

/* Quantity Selection */
.qty-selection select {
    padding: 12px 15px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 16px;
    background: white;
    min-width: 120px;
    transition: border-color 0.3s ease;
}

.qty-selection select:focus {
    outline: none;
    border-color: #3498db;
}

/* Expandable Sections */
.expandable-section {
    background: white;
    border-radius: 16px;
    border: 2px solid #e9ecef;
    margin-bottom: 20px;
    overflow: hidden;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    background: #f8f9fa;
    cursor: pointer;
    transition: background 0.3s ease;
}

.section-header:hover {
    background: #e9ecef;
}

.section-header .section-title {
    margin: 0;
    font-size: 18px;
    color: #2c3e50;
    font-weight: 600;
}

.expand-icon {
    width: 30px;
    height: 30px;
    border-radius: 50%;
    background: #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #7f8c8d;
    transition: all 0.3s ease;
}

.expand-icon i {
    transition: transform 0.3s ease;
}

.expandable-section.expanded .expand-icon {
    background: #3498db;
    color: white;
}

.expandable-section.expanded .expand-icon i {
    transform: rotate(180deg);
}

.section-content {
    padding: 25px;
    border-top: 1px solid #e9ecef;
}

/* Spec Groups */
.spec-group {
    margin-bottom: 30px;
}

.spec-label {
    display: block;
    font-size: 16px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 15px;
}

/* Thickness Options */
.thickness-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 10px;
    max-width: 600px;
}

.thickness-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 15px 10px;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: #2c3e50;
    cursor: pointer;
    transition: all 0.3s ease;
}

.thickness-option:hover {
    border-color: #3498db;
    background: #f8f9fa;
}

.thickness-option.selected {
    border-color: #3498db;
    background: #3498db;
    color: white;
}

/* Color Chips */
.color-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 15px;
    max-width: 600px;
}

.color-chip {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 15px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.color-chip:hover {
    border-color: #3498db;
    transform: translateY(-2px);
}

.color-chip.selected {
    border-color: #3498db;
    background: #ebf3fd;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.color-preview {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    margin: 0 auto 10px auto;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.color-chip span {
    font-size: 14px;
    font-weight: 600;
    color: #2c3e50;
}

/* Finish Options */
.finish-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.finish-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.finish-option:hover {
    border-color: #3498db;
    background: #f8f9fa;
}

.finish-option.selected {
    border-color: #3498db;
    background: #ebf3fd;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.finish-option h5 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

.finish-option p {
    margin: 0;
    font-size: 14px;
    color: #7f8c8d;
}

/* Via Options */
.via-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    gap: 15px;
}

.via-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.via-option:hover {
    border-color: #3498db;
    background: #f8f9fa;
}

.via-option.selected {
    border-color: #3498db;
    background: #ebf3fd;
    box-shadow: 0 0 0 3px rgba(52, 152, 219, 0.1);
}

.via-option h5 {
    margin: 0 0 8px 0;
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

.via-option p {
    margin: 0;
    font-size: 14px;
    color: #7f8c8d;
}

/* Copper Options */
.copper-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(80px, 1fr));
    gap: 10px;
    max-width: 400px;
}

.copper-option {
    background: white;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    padding: 15px 10px;
    text-align: center;
    font-size: 14px;
    font-weight: 600;
    color: #2c3e50;
    cursor: pointer;
    transition: all 0.3s ease;
}

.copper-option:hover {
    border-color: #3498db;
    background: #f8f9fa;
}

.copper-option.selected {
    border-color: #3498db;
    background: #3498db;
    color: white;
}

/* Pricing Sidebar */
.pricing-breakdown {
    margin-bottom: 20px;
}

.pricing-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f1f2f6;
}

.pricing-item:last-child {
    border-bottom: none;
}

.pricing-label {
    font-size: 14px;
    color: #7f8c8d;
    font-weight: 500;
}

.pricing-value {
    font-size: 14px;
    color: #2c3e50;
    font-weight: 600;
}

.pricing-divider {
    height: 1px;
    background: #e9ecef;
    margin: 15px 0;
}

.pricing-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    background: #f8f9fa;
    margin: 0 -25px;
    padding-left: 25px;
    padding-right: 25px;
}

.total-label {
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

.total-value {
    font-size: 20px;
    color: #27ae60;
    font-weight: 700;
}

.pricing-details {
    margin-bottom: 20px;
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.detail-label {
    font-size: 13px;
    color: #95a5a6;
}

.detail-value {
    font-size: 13px;
    color: #2c3e50;
    font-weight: 600;
}

.delivery-info {
    padding-top: 20px;
    border-top: 1px solid #e9ecef;
}

.delivery-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 13px;
    color: #7f8c8d;
}

.delivery-item i {
    color: #27ae60;
    width: 16px;
}

/* Actions Center */
.actions-center {
    flex: 1;
    display: flex;
    justify-content: center;
    align-items: center;
}

.config-summary {
    background: #f8f9fa;
    padding: 10px 20px;
    border-radius: 20px;
    border: 1px solid #e9ecef;
}

.config-summary span {
    font-size: 14px;
    color: #7f8c8d;
}

/* Responsive Design for Step 2 */
@media (max-width: 1200px) {
    .analysis-grid {
        grid-template-columns: 1fr;
    }
    
    .material-grid {
        grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    }
    
    .layers-grid {
        grid-template-columns: repeat(auto-fit, minmax(50px, 1fr));
    }
}

@media (max-width: 768px) {
    .dimensions-input {
        flex-direction: column;
        gap: 10px;
        max-width: 100%;
    }
    
    .material-grid {
        grid-template-columns: 1fr;
    }
    
    .layers-grid {
        grid-template-columns: repeat(5, 1fr);
    }
    
    .color-grid {
        grid-template-columns: repeat(3, 1fr);
    }
    
    .finish-grid,
    .via-grid {
        grid-template-columns: 1fr;
    }
    
    .actions-center {
        display: none;
    }
} 

/* ===== STEP 3 BOM ANALYSIS STYLES ===== */

/* BOM Status Section */
.bom-status-section {
    margin-bottom: 30px;
}

.status-card {
    background: white;
    border-radius: 12px;
    border: 2px solid #e9ecef;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 20px;
}

.status-icon {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 28px;
    flex-shrink: 0;
}

.status-info {
    flex: 1;
}

.status-info h4 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: #2c3e50;
    font-weight: 600;
}

.status-info p {
    margin: 0;
    font-size: 14px;
    color: #7f8c8d;
}

.status-actions {
    display: flex;
    gap: 10px;
}

/* BOM Tabs Section */
.bom-tabs-section {
    background: white;
    border-radius: 12px;
    border: 2px solid #e9ecef;
    margin-bottom: 30px;
    overflow: hidden;
}

.bom-tabs {
    display: flex;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.bom-tab {
    flex: 1;
    background: transparent;
    border: none;
    padding: 20px 15px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    min-width: 140px;
}

.bom-tab:hover {
    background: #e9ecef;
}

.bom-tab.active {
    background: white;
    border-bottom: 3px solid #3498db;
    color: #3498db;
}

.bom-tab.warning.active {
    border-bottom-color: #f39c12;
    color: #f39c12;
}

.bom-tab.info.active {
    border-bottom-color: #9b59b6;
    color: #9b59b6;
}

.bom-tab i {
    font-size: 16px;
}

.bom-tab span {
    font-size: 14px;
    font-weight: 600;
}

.tab-count {
    background: #e9ecef;
    color: #2c3e50;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
    min-width: 20px;
    text-align: center;
}

.bom-tab.active .tab-count {
    background: #3498db;
    color: white;
}

.bom-tab.warning.active .tab-count {
    background: #f39c12;
    color: white;
}

.bom-tab.info.active .tab-count {
    background: #9b59b6;
    color: white;
}

/* Tab Actions */
.tab-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #f8f9fa;
}

.bulk-actions {
    display: flex;
    gap: 10px;
}

.search-box {
    position: relative;
    min-width: 250px;
}

.search-box input {
    width: 100%;
    padding: 10px 15px 10px 40px;
    border: 2px solid #e9ecef;
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.search-box input:focus {
    outline: none;
    border-color: #3498db;
}

.search-box i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #7f8c8d;
    font-size: 16px;
}

/* BOM Table Section */
.bom-table-section {
    /* Main table container */
}

.parts-section {
    background: white;
    border-radius: 12px;
    border: 2px solid #e9ecef;
    margin-bottom: 30px;
    overflow: hidden;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.section-title {
    margin: 0;
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title i {
    font-size: 18px;
}

.section-count {
    color: #7f8c8d;
    font-weight: 500;
    font-size: 14px;
    margin-left: 5px;
}

.section-actions {
    display: flex;
    gap: 10px;
}

/* BOM Table */
.bom-table-container {
    overflow-x: auto;
    overflow-y: visible;
    -webkit-overflow-scrolling: touch;
    max-width: 100%;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.bom-table {
    width: 100%;
    min-width: 800px; /* Ensure minimum width for proper display */
    border-collapse: collapse;
    font-size: 14px;
    background: white;
}

.bom-table th {
    background: #f8f9fa;
    padding: 15px 12px;
    text-align: left;
    font-weight: 600;
    color: #2c3e50;
    border-bottom: 2px solid #e9ecef;
    white-space: nowrap;
    position: sticky;
    top: 0;
    z-index: 10;
}

.bom-table td {
    padding: 15px 12px;
    border-bottom: 1px solid #f1f2f6;
    vertical-align: middle;
}

.bom-table tr:hover {
    background: #f8f9fa;
}

/* Table Columns */
.col-select {
    width: 50px;
    text-align: center;
}

.col-comment {
    min-width: 150px;
}

.col-footprint {
    min-width: 120px;
}

.col-designator {
    min-width: 100px;
}

.col-part-detail {
    min-width: 200px;
}

.col-availability {
    min-width: 120px;
}

.col-quantity {
    min-width: 100px;
    text-align: center;
}

.col-cost {
    min-width: 100px;
    text-align: right;
}

.col-actions {
    min-width: 120px;
    text-align: center;
}

/* Part Detail Cells */
.part-detail {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.part-number {
    font-weight: 600;
    color: #2c3e50;
}

.part-description {
    font-size: 13px;
    color: #7f8c8d;
}

.part-package {
    font-size: 12px;
    color: #95a5a6;
}

/* Availability Status */
.availability-status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
}

.availability-status.in-stock {
    background: #d5f4e6;
    color: #27ae60;
}

.availability-status.low-stock {
    background: #ffeaa7;
    color: #f39c12;
}

.availability-status.out-of-stock {
    background: #fab1a0;
    color: #e74c3c;
}

.availability-status.sourcing {
    background: #ddd6fe;
    color: #9b59b6;
}

/* Quantity Input */
.quantity-input {
    width: 80px;
    padding: 8px 10px;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    text-align: center;
    font-size: 14px;
}

.quantity-input:focus {
    outline: none;
    border-color: #3498db;
}

/* Cost Display */
.cost-display {
    font-weight: 600;
    color: #27ae60;
}

.cost-unit {
    font-size: 12px;
    color: #7f8c8d;
    display: block;
}

/* Action Buttons */
.action-button {
    background: transparent;
    border: 1px solid #e9ecef;
    padding: 6px 10px;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 12px;
    margin: 0 2px;
}

.action-button:hover {
    background: #f8f9fa;
}

.action-button.add {
    color: #27ae60;
    border-color: #27ae60;
}

.action-button.add:hover {
    background: #27ae60;
    color: white;
}

.action-button.remove {
    color: #e74c3c;
    border-color: #e74c3c;
}

.action-button.remove:hover {
    background: #e74c3c;
    color: white;
}

.action-button.alternatives {
    color: #3498db;
    border-color: #3498db;
}

.action-button.alternatives:hover {
    background: #3498db;
    color: white;
}

/* Alternatives Section */
.alternatives-section {
    background: white;
    border-radius: 12px;
    border: 2px solid #e9ecef;
    margin-bottom: 30px;
    overflow: hidden;
}

.close-alternatives {
    background: transparent;
    border: none;
    padding: 8px;
    cursor: pointer;
    color: #7f8c8d;
    transition: color 0.3s ease;
    border-radius: 4px;
}

.close-alternatives:hover {
    color: #e74c3c;
    background: #f8f9fa;
}

.alternatives-content {
    padding: 25px;
}

/* BOM Stats in Sidebar */
.bom-stats {
    margin-bottom: 25px;
}

.stat-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 0;
    border-bottom: 1px solid #f1f2f6;
}

.stat-item:last-child {
    border-bottom: none;
}

.stat-icon {
    width: 40px;
    height: 40px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #e9ecef;
    color: #7f8c8d;
    font-size: 18px;
    flex-shrink: 0;
}

.stat-icon.success {
    background: #d5f4e6;
    color: #27ae60;
}

.stat-icon.warning {
    background: #ffeaa7;
    color: #f39c12;
}

.stat-content {
    flex: 1;
}

.stat-label {
    font-size: 14px;
    color: #7f8c8d;
    margin-bottom: 5px;
}

.stat-value {
    font-size: 18px;
    font-weight: 700;
    color: #2c3e50;
}

/* Pricing Summary */
.pricing-summary {
    margin-bottom: 25px;
}

.pricing-summary h5 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

/* Completion Status */
.completion-status {
    /* Already styled in previous steps */
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #3498db 0%, #27ae60 100%);
    transition: width 0.3s ease;
    width: 0%;
}

.progress-text {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    color: #7f8c8d;
}

.progress-text span:first-child {
    font-weight: 600;
    color: #2c3e50;
}

/* BOM Progress Info */
.bom-progress-info {
    display: flex;
    align-items: center;
    gap: 15px;
    background: #f8f9fa;
    padding: 15px 20px;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.progress-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #3498db;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 16px;
}

.progress-details {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.progress-label {
    font-size: 14px;
    color: #2c3e50;
    font-weight: 600;
}

.progress-status {
    font-size: 13px;
    color: #7f8c8d;
}

/* Button Variants */
.gba-button-sm {
    padding: 8px 16px;
    font-size: 13px;
    border-radius: 6px;
}

.gba-button-success {
    background: #27ae60;
    color: white;
    border: 1px solid #27ae60;
}

.gba-button-success:hover {
    background: #219a52;
    border-color: #219a52;
}

.gba-button-warning {
    background: #f39c12;
    color: white;
    border: 1px solid #f39c12;
}

.gba-button-warning:hover {
    background: #e67e22;
    border-color: #e67e22;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 40px 20px;
    color: #7f8c8d;
}

.empty-state i {
    font-size: 48px;
    margin-bottom: 15px;
    color: #bdc3c7;
}

.empty-state h4 {
    margin: 0 0 10px 0;
    font-size: 18px;
    color: #2c3e50;
}

.empty-state p {
    margin: 0;
    font-size: 14px;
}

/* Responsive Design for Step 3 */
@media (max-width: 1200px) {
    .bom-tabs {
        flex-wrap: wrap;
    }
    
    .bom-tab {
        min-width: 120px;
    }
    
    .search-box {
        min-width: 200px;
    }
}

@media (max-width: 768px) {
    .tab-actions {
        flex-direction: column;
        gap: 15px;
    }
    
    .bulk-actions {
        justify-content: center;
    }
    
    .search-box {
        min-width: 100%;
    }
    
    .bom-tabs {
        flex-direction: column;
    }
    
    .bom-tab {
        min-width: 100%;
        justify-content: flex-start;
        padding: 15px 20px;
    }
    
    .bom-table-container {
        font-size: 12px;
    }
    
    .bom-table th,
    .bom-table td {
        padding: 10px 8px;
    }
    
    .col-comment,
    .col-footprint,
    .col-part-detail {
        min-width: 120px;
    }
    
    .status-card {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .stat-item {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
} 

/* ===== STEP 4 FINAL QUOTE STYLES ===== */

/* Quote Header Section */
.quote-header-section {
    margin-bottom: 30px;
}

.quote-info-card {
    background: white;
    border-radius: 12px;
    border: 2px solid #e9ecef;
    padding: 25px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    position: relative;
}

.quote-info-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px 12px 0 0;
}

.quote-header-content {
    flex: 1;
}

.quote-header-content h3 {
    margin: 0 0 15px 0;
    font-size: 24px;
    color: #2c3e50;
    font-weight: 700;
}

.quote-meta {
    display: flex;
    gap: 30px;
    flex-wrap: wrap;
}

.quote-meta > div {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.quote-meta .label {
    font-size: 14px;
    color: #7f8c8d;
    font-weight: 500;
}

.quote-meta .value {
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

.quote-status {
    display: flex;
    align-items: center;
}

.status-badge {
    padding: 8px 16px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.status-badge.draft {
    background: #f093fb;
    color: white;
}

.status-badge.pending {
    background: #ffeaa7;
    color: #d63031;
}

.status-badge.approved {
    background: #d5f4e6;
    color: #27ae60;
}

/* Project Summary Section */
.project-summary-section {
    margin-bottom: 40px;
}

.summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 25px;
}

.summary-card {
    background: white;
    border-radius: 12px;
    border: 2px solid #e9ecef;
    overflow: hidden;
    transition: all 0.3s ease;
}

.summary-card:hover {
    border-color: #3498db;
    transform: translateY(-2px);
    box-shadow: 0 5px 20px rgba(52, 152, 219, 0.1);
}

.summary-header {
    background: #f8f9fa;
    padding: 20px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    align-items: center;
    gap: 15px;
}

.summary-icon {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #3498db, #2980b9);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 20px;
    flex-shrink: 0;
}

.summary-header h5 {
    margin: 0;
    font-size: 18px;
    color: #2c3e50;
    font-weight: 600;
}

.summary-content {
    padding: 20px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f1f2f6;
}

.summary-item:last-child {
    border-bottom: none;
}

.item-label {
    font-size: 14px;
    color: #7f8c8d;
    font-weight: 500;
}

.item-value {
    font-size: 14px;
    color: #2c3e50;
    font-weight: 600;
}

/* Section Titles */
.section-title {
    margin: 0 0 25px 0;
    font-size: 20px;
    color: #2c3e50;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-title i {
    font-size: 22px;
    color: #3498db;
}

/* Pricing Breakdown Section */
.pricing-breakdown-section {
    margin-bottom: 40px;
}

.pricing-table {
    background: white;
    border-radius: 12px;
    border: 2px solid #e9ecef;
    overflow: hidden;
}

.pricing-category {
    border-bottom: 1px solid #e9ecef;
}

.pricing-category:last-child {
    border-bottom: none;
}

.category-title {
    margin: 0;
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 20px 25px;
    background: #f8f9fa;
    border-bottom: 1px solid #e9ecef;
}

.category-title i {
    font-size: 18px;
    color: #3498db;
}

.pricing-items {
    padding: 0 25px;
}

.pricing-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 0;
    border-bottom: 1px solid #f1f2f6;
}

.pricing-item:last-child {
    border-bottom: none;
}

.item-description {
    flex: 1;
}

.item-name {
    font-size: 14px;
    color: #2c3e50;
    font-weight: 500;
    display: block;
    margin-bottom: 3px;
}

.item-details {
    font-size: 12px;
    color: #7f8c8d;
}

.item-cost {
    font-size: 16px;
    color: #27ae60;
    font-weight: 600;
    min-width: 80px;
    text-align: right;
}

.category-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    background: #f8f9fa;
    border-top: 1px solid #e9ecef;
}

.total-label {
    font-size: 14px;
    color: #2c3e50;
    font-weight: 600;
}

.total-value {
    font-size: 16px;
    color: #2c3e50;
    font-weight: 700;
}

/* Grand Total */
.grand-total {
    background: #f8f9fa;
    padding: 25px;
    border-top: 2px solid #e9ecef;
}

.total-breakdown {
    margin-bottom: 20px;
}

.total-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    font-size: 14px;
}

.total-item.discount .total-label {
    color: #e74c3c;
}

.total-item.discount .total-value {
    color: #e74c3c;
}

.final-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-top: 2px solid #e9ecef;
}

.final-label {
    font-size: 18px;
    color: #2c3e50;
    font-weight: 700;
}

.final-value {
    font-size: 24px;
    color: #27ae60;
    font-weight: 700;
}

/* Terms Section */
.terms-section {
    margin-bottom: 40px;
}

.terms-content {
    background: white;
    border-radius: 12px;
    border: 2px solid #e9ecef;
    padding: 25px;
}

.terms-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 25px;
}

.term-item {
    /* Terms item styling */
}

.term-item h6 {
    margin: 0 0 10px 0;
    font-size: 14px;
    color: #2c3e50;
    font-weight: 600;
}

.term-item p {
    margin: 0;
    font-size: 13px;
    color: #7f8c8d;
    line-height: 1.5;
}

/* Quote Actions Sidebar */
.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 25px;
}

.full-width {
    width: 100%;
}

.quote-validity {
    margin-bottom: 25px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border: 1px solid #e9ecef;
}

.validity-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

.validity-info i {
    font-size: 18px;
    color: #f39c12;
}

.validity-text {
    flex: 1;
}

.validity-label {
    font-size: 13px;
    color: #7f8c8d;
    display: block;
    margin-bottom: 3px;
}

.validity-date {
    font-size: 14px;
    color: #2c3e50;
    font-weight: 600;
}

.contact-info {
    border-top: 1px solid #e9ecef;
    padding-top: 20px;
}

.contact-info h5 {
    margin: 0 0 15px 0;
    font-size: 16px;
    color: #2c3e50;
    font-weight: 600;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 14px;
    color: #7f8c8d;
}

.contact-item i {
    font-size: 16px;
    color: #3498db;
    width: 18px;
    text-align: center;
}

.contact-item a {
    color: #3498db;
    text-decoration: none;
}

.contact-item a:hover {
    text-decoration: underline;
}

/* Quote Completion */
.quote-completion {
    display: flex;
    align-items: center;
    gap: 15px;
    background: #d5f4e6;
    padding: 15px 20px;
    border-radius: 8px;
    border: 1px solid #27ae60;
}

.completion-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #27ae60;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 18px;
    flex-shrink: 0;
}

.completion-text {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.completion-label {
    font-size: 14px;
    color: #27ae60;
    font-weight: 600;
}

.completion-message {
    font-size: 13px;
    color: #1e8449;
}

/* Responsive Design for Step 4 */
@media (max-width: 1200px) {
    .summary-grid {
        grid-template-columns: 1fr;
    }
    
    .terms-grid {
        grid-template-columns: 1fr;
    }
    
    .quote-meta {
        gap: 20px;
    }
}

@media (max-width: 768px) {
    .quote-info-card {
        flex-direction: column;
        gap: 20px;
    }
    
    .quote-meta {
        flex-direction: column;
        gap: 15px;
    }
    
    .summary-grid {
        grid-template-columns: 1fr;
    }
    
    .pricing-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .item-cost {
        align-self: flex-end;
    }
    
    .category-total,
    .final-total {
        flex-direction: column;
        gap: 10px;
        text-align: center;
    }
    
    .final-total {
        align-items: center;
    }
    
    .terms-grid {
        grid-template-columns: 1fr;
    }
    
    .quote-completion {
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }
    
    .completion-text {
        align-items: center;
    }
} 

/* Enhanced Testing Options Styles */
.sub-options {
    margin-top: 20px;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid #007cba;
}

.sub-options h5 {
    font-size: 14px;
    font-weight: 600;
    color: #1e1e1e;
    margin-bottom: 12px;
}

.time-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
}

.time-card {
    background: white;
    border: 2px solid #e1e5e9;
    border-radius: 8px;
    padding: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.time-card:hover {
    border-color: #007cba;
    transform: translateY(-2px);
}

.time-card.selected {
    border-color: #007cba;
    background: linear-gradient(135deg, #f8fcff 0%, #e8f4fd 100%);
    box-shadow: 0 4px 12px rgba(0, 124, 186, 0.15);
}

.time-input-group {
    margin-bottom: 8px;
}

.time-input-group label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #1e1e1e;
    margin-bottom: 5px;
}

.time-input-group input {
    width: 70px;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    text-align: center;
}

.time-input-group .unit {
    font-size: 12px;
    color: #666;
    margin-left: 5px;
}

.time-badge {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: #007cba;
    color: white;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 8px;
    width: fit-content;
}

.time-card h6 {
    font-size: 14px;
    font-weight: 600;
    color: #1e1e1e;
    margin: 0 0 4px 0;
}

.time-card p {
    font-size: 12px;
    color: #666;
    margin: 0;
    line-height: 1.4;
}

/* Assembly Time Options */
.assembly-time-options {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

.time-option-card {
    background: white;
    border: 2px solid #e1e5e9;
    border-radius: 12px;
    padding: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.time-option-card:hover {
    border-color: #007cba;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 124, 186, 0.1);
}

.time-option-card.selected {
    border-color: #007cba;
    background: linear-gradient(135deg, #f8fcff 0%, #e8f4fd 100%);
    box-shadow: 0 6px 20px rgba(0, 124, 186, 0.15);
}

.time-input-section label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #1e1e1e;
    margin-bottom: 10px;
}

.input-group {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
}

.input-group input {
    width: 80px;
    padding: 8px 12px;
    border: 2px solid #e1e5e9;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    transition: border-color 0.3s ease;
}

.input-group input:focus {
    outline: none;
    border-color: #007cba;
}

.input-group .unit {
    font-size: 14px;
    color: #666;
    font-weight: 500;
}

.time-display {
    text-align: center;
}

.time-display .time-badge {
    margin: 0 auto 12px auto;
    background: linear-gradient(135deg, #007cba 0%, #005a87 100%);
}

.time-display h6 {
    font-size: 16px;
    font-weight: 600;
    color: #1e1e1e;
    margin: 0 0 8px 0;
}

.time-display p {
    font-size: 14px;
    color: #666;
    margin: 0;
    line-height: 1.4;
}

/* Updated option cards for new testing options */
.option-card[data-value="no-test"] .option-icon {
    background: linear-gradient(135deg, #e74c3c 0%, #c0392b 100%);
}

.option-card[data-value="customer-tools"] .option-icon {
    background: linear-gradient(135deg, #f39c12 0%, #e67e22 100%);
}

.option-card[data-value="mvn-investment"] .option-icon {
    background: linear-gradient(135deg, #9b59b6 0%, #8e44ad 100%);
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .time-options,
    .assembly-time-options {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .time-card,
    .time-option-card {
        padding: 15px;
    }
    
    .input-group input {
        width: 60px;
        padding: 6px 8px;
        font-size: 14px;
    }
    
    .sub-options {
        padding: 12px;
    }
    
    .time-badge {
        font-size: 11px;
        padding: 6px 10px;
    }
}

/* BOM Mapping Modal Enhancements */
.modal-open {
    overflow: hidden;
}

.gba-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
}

.gba-modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(2px);
}

.gba-modal-content {
    position: relative;
    width: 95%;
    max-width: 1200px;
    margin: 30px auto;
    background: white;
    border-radius: 12px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    max-height: 85vh;
    overflow-y: auto;
}

.gba-modal-header {
    padding: 20px 25px;
    border-bottom: 1px solid #e9ecef;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.gba-modal-header .modal-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #2c3e50;
    display: flex;
    align-items: center;
    gap: 10px;
}

.gba-modal-close {
    background: none;
    border: none;
    font-size: 20px;
    color: #7f8c8d;
    cursor: pointer;
    padding: 5px;
    border-radius: 4px;
    transition: all 0.3s ease;
}

.gba-modal-close:hover {
    background: #f8f9fa;
    color: #2c3e50;
}

.gba-modal-body {
    padding: 25px;
}

.gba-modal-footer {
    padding: 20px 25px;
    border-top: 1px solid #e9ecef;
    display: flex;
    justify-content: flex-end;
    gap: 15px;
}

.mapping-description {
    font-size: 13px;
    color: #7f8c8d;
    margin-bottom: 15px;
    line-height: 1.4;
}

.mapping-completeness {
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    padding: 12px 15px;
    margin-bottom: 15px;
}

.completeness-label {
    font-size: 14px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 10px;
}

.completeness-count {
    color: #007cba;
    margin-left: 5px;
}

.completeness-bar-container {
    background: #e9ecef;
    height: 8px;
    border-radius: 4px;
    overflow: hidden;
}

.completeness-bar {
    height: 100%;
    background: linear-gradient(90deg, #007cba 0%, #27ae60 100%);
    transition: width 0.3s ease;
    border-radius: 4px;
}

.mapping-container {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 20px;
    align-items: start;
}

.mapping-section h4 {
    font-size: 16px;
    color: #2c3e50;
    margin-bottom: 8px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.mapping-section h4 i {
    color: #007cba;
    font-size: 14px;
}

.section-description {
    font-size: 13px;
    color: #7f8c8d;
    margin-bottom: 15px;
    line-height: 1.4;
    font-style: italic;
}

.mapping-example {
    background: #e8f4f8;
    border: 1px solid #bee5eb;
    border-radius: 6px;
    padding: 10px 12px;
    margin-bottom: 15px;
    font-size: 12px;
}

.example-content {
    color: #0c5460;
    line-height: 1.4;
}

.column-list {
    max-height: 450px;
    overflow-y: auto;
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 12px;
    background: #fafbfc;
}

.column-mapping-list {
    max-height: 450px;
    overflow-y: auto;
}

.mapping-row {
    margin-bottom: 15px;
    padding: 12px;
    border: 1px solid #e9ecef;
    border-radius: 6px;
    background: #f8f9fa;
}

.mapping-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #2c3e50;
    margin-bottom: 8px;
}

.mapping-label .required {
    color: #e74c3c;
    margin-left: 2px;
}

.mapping-select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 13px;
    background: white;
    transition: border-color 0.3s ease;
}

.mapping-select:focus {
    outline: none;
    border-color: #007cba;
}

.mapping-arrows {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    gap: 6px;
    font-size: 20px;
    color: #007cba;
    text-align: center;
}

.mapping-direction {
    font-size: 12px;
    font-weight: 600;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

@media (max-width: 768px) {
    .gba-modal-content {
        width: 95%;
        margin: 20px auto;
        max-height: 90vh;
    }
    
    .mapping-container {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .mapping-arrows {
        transform: rotate(90deg);
        margin: 10px 0;
    }
    
    .mapping-direction {
        transform: rotate(-90deg);
        margin-top: 5px;
    }
    
    .gba-modal-header,
    .gba-modal-body,
    .gba-modal-footer {
        padding: 15px 20px;
    }
    
    .section-description {
        font-size: 12px;
        margin-bottom: 12px;
    }
} 

/* BOM Column Mapping Enhancements */
.loading-state {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 48px 24px;
    color: #64748b;
    font-size: 16px;
    gap: 12px;
}

.loading-state i {
    font-size: 20px;
    color: #3b82f6;
    animation: spin 1s linear infinite;
}

/* Mapping confidence feedback */
.gba-modal .mapping-row.mapped-successfully {
    background: rgba(16, 185, 129, 0.05);
    border-left: 4px solid #10b981;
}

.gba-modal .mapping-row.mapped-partial {
    background: rgba(245, 158, 11, 0.05);
    border-left: 4px solid #f59e0b;
}

/* Enhanced column list styling */
.column-list .column-item {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 12px;
    transition: all 0.2s;
    position: relative;
}

.column-list .column-item:hover {
    border-color: #cbd5e1;
    background: #f1f5f9;
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 124, 186, 0.1);
}

.column-list .column-item.high-confidence {
    border-left: 4px solid #27ae60;
}

.column-list .column-item.medium-confidence {
    border-left: 4px solid #f39c12;
}

.column-list .column-item.low-confidence {
    border-left: 4px solid #95a5a6;
}

.column-list .column-header {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    flex-wrap: wrap;
}

.column-list .column-name {
    font-weight: 600;
    color: #2c3e50;
    font-size: 14px;
    flex: 1;
    min-width: 0;
}

.column-index {
    background: #007cba;
    color: white;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 8px;
    border-radius: 12px;
    white-space: nowrap;
}

.confidence-badge {
    font-size: 10px;
    padding: 2px 6px;
    border-radius: 8px;
    font-weight: 600;
    text-transform: uppercase;
    white-space: nowrap;
}

.confidence-badge.high {
    background: #d5f4e6;
    color: #27ae60;
}

.confidence-badge.medium {
    background: #fef9e7;
    color: #f39c12;
}

.confidence-badge.low {
    background: #f4f6f7;
    color: #95a5a6;
}

.column-list .column-preview {
    font-size: 12px;
    color: #64748b;
    line-height: 1.4;
    background: #e2e8f0;
    padding: 8px 10px;
    border-radius: 6px;
    border-left: 3px solid #cbd5e1;
}

.column-list .column-preview strong {
    color: #34495e;
    font-weight: 600;
}

/* BOM Template Confirmation Modal */
.template-notification {
    display: flex;
    flex-direction: column;
    gap: 20px;
    align-items: center;
    text-align: center;
    background: #f8f9fa;
    border: 1px solid #e9ecef;
    border-radius: 12px;
    padding: 32px 24px;
    margin-bottom: 20px;
}

.notification-icon {
    flex-shrink: 0;
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #3498db 0%, #2980b9 100%);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 24px;
    box-shadow: 0 4px 16px rgba(52, 152, 219, 0.25);
}

.notification-content {
    max-width: 500px;
}

.notification-content h4 {
    margin: 0 0 16px 0;
    color: #2c3e50;
    font-size: 20px;
    font-weight: 600;
}

.notification-content p {
    margin: 0 0 12px 0;
    color: #5a6c7d;
    line-height: 1.6;
    font-size: 15px;
}

.notification-content p:last-child {
    margin-bottom: 0;
}

@media (max-width: 768px) {
    .template-notification {
        padding: 24px 20px;
        gap: 16px;
    }
    
    .notification-icon {
        width: 56px;
        height: 56px;
        font-size: 20px;
    }
    
    .notification-content h4 {
        font-size: 18px;
    }
    
    .notification-content p {
        font-size: 14px;
    }
}

/* Detection Source Indicators */
.detection-source {
    display: inline-block;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 3px;
    margin-left: 8px;
    vertical-align: middle;
    text-transform: uppercase;
    letter-spacing: 0.3px;
}

.detection-source.outline {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.detection-source.auto {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.detection-source.default {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.detection-source.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* BOM Pricing Summary Styles */
.bom-pricing-section {
    margin-bottom: 30px;
}

.pricing-summary-card {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    padding: 25px;
    color: white;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.pricing-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
}

.pricing-item {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

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

.pricing-item.pricing-total {
    background: rgba(255, 255, 255, 0.2);
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.pricing-icon {
    font-size: 24px;
    color: rgba(255, 255, 255, 0.9);
    min-width: 40px;
    text-align: center;
}

.pricing-details {
    flex: 1;
}

.pricing-label {
    display: block;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.8);
    margin-bottom: 5px;
}

.pricing-value {
    display: block;
    font-size: 24px;
    font-weight: 700;
    color: white;
    line-height: 1;
}

.pricing-total .pricing-value {
    font-size: 28px;
    color: #fff;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

/* Responsive adjustments for pricing */
@media (max-width: 768px) {
    .pricing-grid {
        grid-template-columns: 1fr;
    }
    
    .pricing-item {
        padding: 12px;
    }
    
    .pricing-value {
        font-size: 20px;
    }
    
    .pricing-total .pricing-value {
        font-size: 24px;
    }
}

/* ===================================
   STEP 4: FINAL QUOTE SUMMARY
   =================================== */

/* Final Quote Main Container */
.final-quote-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0;
}

/* Quote Summary Grid */
.quote-summary-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin-bottom: 32px;
}

/* Quote Summary Cards */
.quote-summary-card {
    background: #ffffff;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.07);
    border: 1px solid #e5e7eb;
    overflow: hidden;
    transition: all 0.3s ease;
}

.quote-summary-card:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

/* Card Headers */
.quote-summary-card .card-header {
    padding: 20px 24px 16px;
    border-bottom: 1px solid #f3f4f6;
    display: flex;
    align-items: center;
    gap: 16px;
}

.quote-summary-card .card-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #ffffff;
}

.pcb-card .card-icon {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.bom-card .card-icon {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
}

.service-card .card-icon {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

.shipping-card .card-icon {
    background: linear-gradient(135deg, #43e97b 0%, #38f9d7 100%);
}

.quote-summary-card .card-title h3 {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
    line-height: 1.3;
}

.quote-summary-card .card-subtitle {
    margin: 4px 0 0;
    font-size: 14px;
    color: #6b7280;
}

/* Card Content */
.quote-summary-card .card-content {
    padding: 16px 24px 24px;
}

.pricing-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #f9fafb;
}

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

.pricing-row.total-row {
    margin-top: 8px;
    padding-top: 16px;
    border-top: 2px solid #e5e7eb;
    border-bottom: none;
    font-weight: 600;
}

.pricing-row .label {
    font-size: 14px;
    color: #374151;
    flex: 1;
}

.pricing-row .value {
    font-size: 14px;
    font-weight: 500;
    color: #1f2937;
    text-align: right;
}

.pricing-row.total-row .value {
    font-size: 16px;
    font-weight: 700;
    color: #059669;
}

/* Production Summary */
.production-summary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 12px;
    padding: 24px;
    margin-bottom: 32px;
    color: #ffffff;
}

.production-summary .summary-header h3 {
    margin: 0 0 16px;
    font-size: 20px;
    font-weight: 600;
    color: #ffffff;
}

.production-summary .summary-row {
    display: flex;
    gap: 32px;
    flex-wrap: wrap;
}

.production-summary .summary-item {
    flex: 1;
    min-width: 150px;
    text-align: center;
}

.production-summary .item-label {
    display: block;
    font-size: 14px;
    opacity: 0.9;
    margin-bottom: 4px;
}

.production-summary .item-value {
    display: block;
    font-size: 20px;
    font-weight: 700;
    color: #ffffff;
}

/* Final Price Summary */
.final-price-summary {
    background: #ffffff;
    border-radius: 16px;
    padding: 32px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
    border: 2px solid #e5e7eb;
    margin-bottom: 32px;
}

.price-breakdown {
    max-width: 600px;
    margin: 0 auto;
}

.breakdown-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    border-bottom: 1px solid #f3f4f6;
    font-size: 16px;
}

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

.breakdown-row.total-breakdown {
    margin-top: 16px;
    padding-top: 20px;
    border-top: 3px solid #e5e7eb;
    border-bottom: none;
}

.breakdown-label {
    font-weight: 500;
    color: #374151;
}

.breakdown-value {
    font-weight: 600;
    color: #1f2937;
}

.breakdown-row.total-breakdown .breakdown-label {
    font-size: 20px;
    font-weight: 700;
    color: #1f2937;
}

.breakdown-row.total-breakdown .breakdown-value {
    font-size: 24px;
    font-weight: 800;
    color: #059669;
}

/* Submit Section */
.submit-section {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    border-radius: 16px;
    padding: 32px;
    text-align: center;
    color: #ffffff;
    margin-bottom: 32px;
}

.submit-section .submit-info h3 {
    margin: 0 0 12px;
    font-size: 24px;
    font-weight: 700;
    color: #ffffff;
}

.submit-section .submit-info p {
    margin: 0 0 24px;
    font-size: 16px;
    opacity: 0.95;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.submit-actions {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

.submit-actions .btn {
    padding: 14px 28px;
    font-size: 16px;
    font-weight: 600;
    border-radius: 8px;
    border: none;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    min-width: 160px;
    justify-content: center;
}

.submit-actions .btn-secondary {
    background: rgba(255, 255, 255, 0.2);
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.submit-actions .btn-secondary:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: translateY(-2px);
}

.submit-actions .btn-primary {
    background: #ffffff;
    color: #f5576c;
    border: 2px solid #ffffff;
}

.submit-actions .btn-primary:hover {
    background: #f8f9fa;
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

/* Submit Quote Modal */
.gba-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    background: #ffffff;
    border-radius: 16px;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2);
    width: 100%;
    max-width: 600px;
    max-height: 90vh;
    overflow: hidden;
    animation: modalSlideIn 0.3s ease;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-header {
    padding: 24px 32px 16px;
    border-bottom: 1px solid #e5e7eb;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-header h3 {
    margin: 0;
    font-size: 20px;
    font-weight: 600;
    color: #1f2937;
}

.modal-close {
    background: none;
    border: none;
    font-size: 20px;
    color: #6b7280;
    cursor: pointer;
    padding: 8px;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.modal-close:hover {
    background: #f3f4f6;
    color: #374151;
}

.modal-body {
    padding: 24px 32px;
    max-height: 60vh;
    overflow-y: auto;
}

.modal-footer {
    padding: 16px 32px 24px;
    border-top: 1px solid #e5e7eb;
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* Form Styles */
.form-row {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
}

.form-group {
    flex: 1;
    margin-bottom: 16px;
}

.form-group label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #374151;
    margin-bottom: 6px;
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.1);
}

.form-group textarea {
    resize: vertical;
    min-height: 80px;
}

/* Checkbox Group */
.checkbox-group {
    margin-bottom: 0;
}

.checkbox-label {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    font-size: 14px;
    color: #374151;
    cursor: pointer;
    line-height: 1.5;
}

.checkbox-label input[type="checkbox"] {
    width: auto;
    margin: 0;
}

.checkbox-label a {
    color: #667eea;
    text-decoration: none;
}

.checkbox-label a:hover {
    text-decoration: underline;
}

/* Loading State */
.loading-state {
    text-align: center;
    padding: 60px 20px;
}

.loading-content {
    max-width: 300px;
    margin: 0 auto;
}

.loading-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid #f3f4f6;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 16px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-content p {
    margin: 0;
    font-size: 16px;
    color: #6b7280;
}

/* Step 4 Responsive Design */
@media (max-width: 768px) {
    .quote-summary-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .quote-summary-card .card-header {
        padding: 16px 20px 12px;
    }
    
    .quote-summary-card .card-content {
        padding: 12px 20px 20px;
    }
    
    .production-summary {
        padding: 20px;
    }
    
    .production-summary .summary-row {
        flex-direction: column;
        gap: 16px;
    }
    
    .final-price-summary {
        padding: 24px 20px;
    }
    
    .submit-section {
        padding: 24px 20px;
    }
    
    .submit-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .submit-actions .btn {
        width: 100%;
        max-width: 280px;
    }
    
    .form-row {
        flex-direction: column;
        gap: 0;
    }
    
    .modal-content {
        margin: 10px;
        max-width: calc(100vw - 20px);
    }
    
    .modal-header {
        padding: 20px 24px 12px;
    }
    
    .modal-body {
        padding: 20px 24px;
    }
    
    .modal-footer {
        padding: 12px 24px 20px;
        flex-direction: column;
    }
    
    .modal-footer .btn {
        width: 100%;
    }
}