/* PDF Processor Specific Styles */

/* Upload Section */
.upload-section {
    padding: 3rem;
}

.upload-area {
    border: 3px dashed #e2e8f0;
    border-radius: 16px;
    padding: 4rem 2rem;
    text-align: center;
    background: #f8fafc;
    transition: all 0.3s ease;
    cursor: pointer;
    position: relative;
}

.upload-area:hover,
.upload-area.dragover {
    border-color: #667eea;
    background: #f1f5f9;
    transform: scale(1.02);
}

.upload-content svg {
    color: #94a3b8;
    margin-bottom: 1rem;
}

.upload-content h3 {
    font-size: 1.5rem;
    margin-bottom: 0.5rem;
    color: #1e293b;
}

.upload-content p {
    color: #64748b;
    font-size: 1rem;
}

#fileInput {
    position: absolute;
    inset: 0;
    opacity: 0;
    cursor: pointer;
}

/* Uploaded Files Display */
.uploaded-files {
    margin-top: 2rem;
    background: #f8fafc;
    border-radius: 12px;
    padding: 1.5rem;
    border: 1px solid #e2e8f0;
}

.uploaded-files h4 {
    margin-bottom: 1rem;
    color: #1e293b;
    font-size: 1.2rem;
}

.files-list {
    display: grid;
    gap: 0.75rem;
}

.file-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: white;
    padding: 1rem;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.file-info {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.file-icon {
    width: 32px;
    height: 32px;
    background: #667eea;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.75rem;
    font-weight: 600;
}

.file-details h5 {
    margin: 0;
    color: #1e293b;
    font-size: 0.9rem;
    word-break: break-all;
}

.file-details span {
    color: #64748b;
    font-size: 0.8rem;
}

.file-remove {
    background: #ef4444;
    color: white;
    border: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.file-remove:hover {
    background: #dc2626;
}

/* Processing Options */
.processing-section {
    padding: 2rem 3rem;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
}

.processing-section h3 {
    text-align: center;
    color: #1e293b;
    margin-bottom: 2rem;
    font-size: 1.5rem;
}

.options-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
    margin-bottom: 2rem;
}

.option-card {
    position: relative;
}

.option-checkbox {
    display: none;
}

.option-label {
    display: flex;
    align-items: center;
    gap: 1rem;
    background: white;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    cursor: pointer;
    transition: all 0.3s ease;
    height: 100%;
}

.option-label:hover {
    border-color: #667eea;
    box-shadow: 0 4px 12px rgba(102, 126, 234, 0.15);
}

.option-checkbox:checked + .option-label {
    border-color: #667eea;
    background: linear-gradient(135deg, #667eea, #764ba2);
    color: white;
}

.option-checkbox:checked + .option-label .option-content p {
    color: rgba(255, 255, 255, 0.9);
}

.option-icon {
    font-size: 2rem;
    line-height: 1;
    min-width: 40px;
    text-align: center;
}

.option-content h4 {
    margin: 0 0 0.25rem 0;
    font-size: 1.1rem;
    color: inherit;
}

.option-content p {
    margin: 0;
    font-size: 0.9rem;
    color: #64748b;
    line-height: 1.4;
}

.select-all-card .option-label {
    background: #10b981;
    border-color: #10b981;
    color: white;
}

.select-all-card .option-label:hover {
    background: #059669;
    border-color: #059669;
}

.select-all-card .option-content p {
    color: rgba(255, 255, 255, 0.9);
}

.process-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
    margin-top: 2rem;
}

/* Progress Section */
.progress-section {
    padding: 2rem 3rem;
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
}

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

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

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea, #764ba2);
    transition: width 0.3s ease;
    width: 0%;
}

#progressText {
    color: #64748b;
    font-weight: 500;
}

/* Results Section */
.results-section {
    padding: 2rem 3rem 3rem;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.results-header h3 {
    color: #1e293b;
    margin: 0;
    font-size: 1.5rem;
}

.results-grid {
    display: grid;
    gap: 1.5rem;
    margin-bottom: 2rem;
}

.result-category {
    background: #f8fafc;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    overflow: hidden;
}

.result-category-header {
    background: #667eea;
    color: white;
    padding: 1rem 1.5rem;
    font-weight: 600;
    font-size: 1.1rem;
}

.result-files {
    padding: 1.5rem;
}

.result-file {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: white;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 0.75rem;
}

.result-file:last-child {
    margin-bottom: 0;
}

.result-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.result-icon {
    width: 36px;
    height: 36px;
    background: #10b981;
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 0.8rem;
    font-weight: 600;
}

.result-details h6 {
    margin: 0 0 0.25rem 0;
    color: #1e293b;
    font-size: 0.9rem;
}

.result-details .result-meta {
    color: #64748b;
    font-size: 0.8rem;
}

.result-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.8rem;
    border-radius: 4px;
    border: none;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-download {
    background: #10b981;
    color: white;
}

.btn-download:hover {
    background: #059669;
}

.btn-preview {
    background: #3b82f6;
    color: white;
}

.btn-preview:hover {
    background: #2563eb;
}

.results-actions {
    text-align: center;
}

/* File size badges */
.size-badge {
    display: inline-block;
    background: #e2e8f0;
    color: #64748b;
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
}

.size-reduced {
    background: #d1fae5;
    color: #059669;
}

/* Loading states */
.processing .option-label {
    opacity: 0.6;
    pointer-events: none;
}

.processing .process-actions button {
    opacity: 0.6;
    pointer-events: none;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .upload-section,
    .processing-section,
    .results-section {
        padding: 2rem 1.5rem;
    }
    
    .options-grid {
        grid-template-columns: 1fr;
    }
    
    .process-actions {
        flex-direction: column;
        align-items: center;
    }
    
    .results-header {
        flex-direction: column;
        gap: 1rem;
        align-items: stretch;
    }
    
    .result-file {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .result-info {
        width: 100%;
    }
    
    .result-actions {
        width: 100%;
        justify-content: flex-end;
    }
    
    .file-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .file-info {
        width: 100%;
    }
}