/* Base Styles */
:root {
    --primary: #321fdb;
    --secondary: #9da5b1;
    --success: #2eb85c;
    --info: #39f;
    --warning: #f9b115;
    --danger: #e55353;
    --light: #ebedef;
    --dark: #4f5d73;
    --body-bg: #f0f2f5;
}

body {
    background-color: var(--body-bg);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    line-height: 1.6;
    color: #333;
}

.app {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Header */
.app-header {
    background-color: #fff;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    padding: 1.5rem 0;
    margin-bottom: 2rem;
}

.logo h1 {
    font-size: 1.75rem;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 0.25rem;
}

/* Upload Section */
.upload-section {
    margin-bottom: 2rem;
}

.upload-area {
    border: 2px dashed #d1d7dc;
    border-radius: 8px;
    padding: 3rem 1rem;
    transition: all 0.3s ease;
    cursor: pointer;
    background-color: #f8f9fa;
}

.upload-area:hover, .upload-area.dragover {
    border-color: var(--primary);
    background-color: rgba(50, 31, 219, 0.05);
}

.upload-icon {
    font-size: 3.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

/* Options Section */
.options-section .card {
    height: 100%;
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    border-radius: 8px;
    overflow: hidden;
}

.card-header {
    background-color: #fff;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    padding: 1rem 1.25rem;
}

.card-body {
    padding: 1.5rem;
}

/* File List */
.file-list {
    max-height: 300px;
    overflow-y: auto;
    margin-bottom: 1rem;
    border: 1px solid #e9ecef;
    border-radius: 4px;
    padding: 0.5rem;
}

.file-item {
    display: flex;
    align-items: center;
    padding: 0.5rem;
    border-bottom: 1px solid #e9ecef;
}

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

.file-icon {
    margin-right: 0.75rem;
    color: var(--primary);
}

.file-info {
    flex: 1;
    min-width: 0;
}

.file-name {
    font-weight: 500;
    margin-bottom: 0.25rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-size {
    font-size: 0.8rem;
    color: var(--secondary);
}

.file-remove {
    color: var(--danger);
    background: none;
    border: none;
    padding: 0.25rem;
    cursor: pointer;
}

/* Progress Bar */
.progress {
    height: 10px;
    border-radius: 5px;
    background-color: #e9ecef;
    margin: 1rem 0;
    overflow: hidden;
}

.progress-bar {
    height: 100%;
    background-color: var(--primary);
    transition: width 0.3s ease;
}

/* How It Works */
.how-it-works {
    padding: 3rem 0;
    background-color: #fff;
    border-radius: 8px;
    margin: 2rem 0;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.05);
}

.step-card {
    padding: 1.5rem;
    height: 100%;
    transition: transform 0.3s ease;
}

.step-card:hover {
    transform: translateY(-5px);
}

.step-number {
    width: 40px;
    height: 40px;
    background-color: var(--primary);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin: 0 auto 1rem;
}

.step-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

/* FAQ Section */
.faq-section {
    padding: 3rem 0;
}

.accordion-button:not(.collapsed) {
    background-color: rgba(50, 31, 219, 0.1);
    color: var(--primary);
}

.accordion-button:focus {
    box-shadow: 0 0 0 0.25rem rgba(50, 31, 219, 0.25);
    border-color: var(--primary);
}

/* Footer */
.app-footer {
    background-color: #2a3042;
    color: #fff;
    padding: 3rem 0 1.5rem;
    margin-top: auto;
}

.app-footer h5 {
    color: #fff;
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

.app-footer a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.2s;
}

.app-footer a:hover {
    color: #fff;
    text-decoration: none;
}

.social-links a {
    display: inline-block;
    width: 36px;
    height: 36px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    text-align: center;
    line-height: 36px;
    margin-right: 0.5rem;
    transition: all 0.3s ease;
}

.social-links a:hover {
    background-color: var(--primary);
    transform: translateY(-3px);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .app-header {
        padding: 1rem 0;
    }
    
    .logo h1 {
        font-size: 1.5rem;
    }
    
    .upload-area {
        padding: 2rem 1rem;
    }
    
    .upload-icon {
        font-size: 2.5rem;
    }
    
    .how-it-works, .faq-section {
        padding: 2rem 0;
    }
    
    .step-card {
        margin-bottom: 1.5rem;
    }
}

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

.fade-in {
    animation: fadeIn 0.5s ease-out forwards;
}

/* Custom styles for PDF to Image Converter */

/* Converted Files Grid */
.converted-files-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.converted-file-item {
    border: 1px solid #dee2e6;
    border-radius: 8px;
    padding: 1rem;
    text-align: center;
    background: #fff;
    transition: all 0.3s ease;
}

.converted-file-item:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    transform: translateY(-2px);
}

.file-preview {
    width: 100%;
    height: 120px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 10px;
}

.file-preview.html-preview {
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
    border: 2px dashed #dee2e6;
    object-fit: initial;
}

.html-icon {
    text-align: center;
    color: #6c757d;
}

.file-info {
    margin-bottom: 0.75rem;
}

.file-name {
    font-size: 0.875rem;
    font-weight: 500;
    color: #495057;
    margin-bottom: 0.25rem;
    word-break: break-word;
}

.file-size {
    font-size: 0.75rem;
    color: #6c757d;
}

.file-actions {
    display: flex;
    gap: 0.5rem;
    justify-content: center;
}

.btn-sm {
    padding: 0.25rem 0.5rem;
    font-size: 0.75rem;
}

/* Custom Checkbox and Radio Buttons */
.btn-check:checked + .btn-outline-primary {
    background-color: var(--primary);
    color: white;
}

/* Custom Scrollbar */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}
