/* Shared Component Styles - Extracted from various view files */

/* CSS Variables for Components */
:root {
    /* Light Mode Variables */
    --white: #ffffff;
    --light-bg: #f8fafc;
    --border-color: #e2e8f0;
    --border-light: #f1f5f9;
    --text-primary: #1a202c;
    --text-secondary: #4a5568;
    --text-muted: #718096;
    --surface-color: #ffffff;
    --hover-bg: #f7fafc;
    --primary-color: #3182ce;
    --primary-gradient: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --primary-light: #ebf8ff;
    --primary-dark: #2c5282;
    --success-color: #38a169;
    --warning-color: #d69e2e;
    --danger-color: #e53e3e;
    --radius-sm: 6px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1);
}

/* Modern Button Styles */
.modern-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 20px;
    font-weight: 500;
    font-size: 14px;
    line-height: 1.5;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    cursor: pointer;
    transition: var(--transition);
    text-decoration: none;
    white-space: nowrap;
    user-select: none;
}

.modern-btn:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.modern-btn:active {
    transform: translateY(0);
}

.modern-btn.primary {
    background: var(--primary-gradient);
    color: var(--white);
    border-color: var(--primary-color);
}

.modern-btn.primary:hover {
    background: var(--primary-dark);
    color: var(--white);
}

.modern-btn.outline {
    background: transparent;
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.modern-btn.outline:hover {
    background: var(--primary-color);
    color: var(--white);
}

.modern-btn.ghost {
    background: transparent;
    color: var(--text-secondary);
    border-color: var(--border-color);
}

.modern-btn.ghost:hover {
    background: var(--light-bg);
    color: var(--text-primary);
    border-color: var(--border-light);
}

/* Modern Card Styles */
.modern-card {
    background: var(--surface-color);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
    overflow: hidden;
}

.modern-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.modern-card-header {
    padding: 20px 24px;
    border-bottom: 1px solid var(--border-color);
    background: var(--light-bg);
}

.modern-card-body {
    padding: 24px;
}

.modern-card-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-color);
    background: var(--light-bg);
}

/* File Upload Styles */
.file-upload-area {
    border: 2px dashed var(--border-color);
    border-radius: var(--radius-lg);
    background-color: var(--light-bg);
    transition: var(--transition);
    cursor: pointer;
    position: relative;
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    padding: 40px 20px;
}

.file-upload-area:hover {
    border-color: var(--primary-color);
    background-color: var(--primary-light);
}

.file-upload-area.dragover {
    border-color: var(--primary-dark);
    background-color: var(--primary-light);
    transform: scale(1.02);
}

.upload-icon {
    font-size: 48px;
    color: var(--text-muted);
    margin-bottom: 16px;
}

.upload-content h4 {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.upload-content p {
    font-size: 14px;
    color: var(--text-secondary);
    margin: 0;
}

/* File Item Styles */
.file-item {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 12px 16px;
    margin-bottom: 8px;
    background-color: var(--surface-color);
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: var(--transition);
}

.file-item:hover {
    background-color: var(--light-bg);
    border-color: var(--border-light);
}

.file-info {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
}

.file-icon {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 14px;
    font-weight: bold;
    flex-shrink: 0;
}

.file-icon.pdf {
    background: linear-gradient(135deg, #dc2626 0%, #ef4444 100%);
}

.file-icon.docx,
.file-icon.doc {
    background: linear-gradient(135deg, #2563eb 0%, #3b82f6 100%);
}

.file-icon.csv,
.file-icon.xls,
.file-icon.xlsx {
    background: linear-gradient(135deg, #16a34a 0%, #22c55e 100%);
}

.file-icon.pptx {
    background: linear-gradient(135deg, #ea580c 0%, #f97316 100%);
}

.file-icon.txt {
    background: linear-gradient(135deg, #d97706 0%, #f59e0b 100%);
}

.file-icon.jpg,
.file-icon.jpeg,
.file-icon.png,
.file-icon.gif {
    background: linear-gradient(135deg, #7c3aed 0%, #8b5cf6 100%);
}

.file-name {
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 2px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.file-size {
    font-size: 12px;
    color: var(--text-muted);
}

.file-actions {
    display: flex;
    gap: 8px;
    align-items: center;
}

.file-action-btn {
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 4px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.file-action-btn:hover {
    color: var(--text-primary);
    background: var(--light-bg);
}

.file-action-btn.danger:hover {
    color: var(--danger-color);
    background: rgba(239, 68, 68, 0.1);
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    z-index: 1050;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.custom-modal {
    background: var(--surface-color);
    border-radius: var(--radius-lg);
    max-width: 600px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
    animation: modalSlideUp 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    flex-direction: column;
}

@keyframes modalSlideUp {
    from {
        opacity: 0;
        transform: translateY(30px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px;
    border-bottom: 1px solid var(--border-color);
    background: var(--surface-color);
}

.modal-title {
    font-size: 18px;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.modal-close {
    background: none;
    border: none;
    color: var(--text-muted);
    font-size: 24px;
    cursor: pointer;
    padding: 4px;
    border-radius: var(--radius-sm);
    transition: var(--transition);
}

.modal-close:hover {
    color: var(--text-primary);
    background: var(--light-bg);
}

.modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 24px;
}

.modal-footer {
    padding: 16px 24px;
    border-top: 1px solid var(--border-color);
    background: var(--light-bg);
    display: flex;
    gap: 12px;
    justify-content: flex-end;
}

/* Progress Bar Styles */
.progress-modern {
    height: 8px;
    background-color: var(--light-bg);
    border-radius: 50px;
    overflow: hidden;
    margin-top: 8px;
}

.progress-bar-modern {
    height: 100%;
    background: var(--primary-gradient);
    border-radius: 50px;
    transition: width 0.3s ease;
    position: relative;
}

.progress-bar-modern::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background-image: linear-gradient(
        -45deg,
        rgba(255, 255, 255, 0.2) 25%,
        transparent 25%,
        transparent 50%,
        rgba(255, 255, 255, 0.2) 50%,
        rgba(255, 255, 255, 0.2) 75%,
        transparent 75%,
        transparent
    );
    background-size: 50px 50px;
    animation: move 2s linear infinite;
}

@keyframes move {
    0% {
        background-position: 0 0;
    }
    100% {
        background-position: 50px 50px;
    }
}

/* Alert Styles */
.alert-modern {
    padding: 16px 20px;
    border-radius: var(--radius-md);
    border: 1px solid transparent;
    margin-bottom: 16px;
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.alert-modern.info {
    background-color: rgba(59, 130, 246, 0.1);
    border-color: rgba(59, 130, 246, 0.2);
    color: #1e40af;
}

.alert-modern.success {
    background-color: rgba(16, 185, 129, 0.1);
    border-color: rgba(16, 185, 129, 0.2);
    color: #065f46;
}

.alert-modern.warning {
    background-color: rgba(245, 158, 11, 0.1);
    border-color: rgba(245, 158, 11, 0.2);
    color: #92400e;
}

.alert-modern.error {
    background-color: rgba(239, 68, 68, 0.1);
    border-color: rgba(239, 68, 68, 0.2);
    color: #991b1b;
}

.alert-icon {
    font-size: 20px;
    flex-shrink: 0;
    margin-top: 2px;
}

.alert-content {
    flex: 1;
}

.alert-title {
    font-weight: 600;
    margin-bottom: 4px;
}

.alert-message {
    margin: 0;
    line-height: 1.5;
}

/* Loading Spinner */
.spinner-modern {
    width: 24px;
    height: 24px;
    border: 2px solid var(--border-color);
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

.spinner-modern.large {
    width: 40px;
    height: 40px;
    border-width: 3px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    background: var(--surface-color);
    border-radius: var(--radius-lg);
    border: 1px solid var(--border-color);
}

.empty-state-icon {
    font-size: 4rem;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.empty-state-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 12px 0;
}

.empty-state-description {
    font-size: 1rem;
    color: var(--text-secondary);
    margin: 0 0 24px 0;
    max-width: 400px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.6;
}

/* Badge Styles */
.badge-modern {
    display: inline-flex;
    align-items: center;
    padding: 4px 12px;
    font-size: 12px;
    font-weight: 500;
    border-radius: 50px;
    line-height: 1;
}

.badge-modern.primary {
    background: var(--primary-light);
    color: var(--primary-color);
}

.badge-modern.success {
    background: rgba(16, 185, 129, 0.1);
    color: #059669;
}

.badge-modern.warning {
    background: rgba(245, 158, 11, 0.1);
    color: #d97706;
}

.badge-modern.danger {
    background: rgba(239, 68, 68, 0.1);
    color: #dc2626;
}

/* Responsive Design */
@media (max-width: 768px) {
    .modern-btn {
        padding: 10px 16px;
        font-size: 14px;
    }
    
    .modern-card-body,
    .modal-body {
        padding: 16px;
    }
    
    .file-upload-area {
        min-height: 150px;
        padding: 30px 15px;
    }
    
    .upload-icon {
        font-size: 36px;
    }
} 