/* Custom styles for Excel Column Mapper */

body {
    background-color: #f8f9fa;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

.navbar-brand {
    font-weight: 600;
}

.card {
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    border-radius: 0.5rem;
}

.card-header {
    border-bottom: 1px solid rgba(0, 0, 0, 0.125);
    border-radius: 0.5rem 0.5rem 0 0 !important;
    font-weight: 600;
}

.btn {
    border-radius: 0.375rem;
    font-weight: 500;
}

.btn-lg {
    padding: 0.75rem 1.5rem;
    font-size: 1.1rem;
}

.form-control, .form-select {
    border-radius: 0.375rem;
    border: 1px solid #ced4da;
}

.form-control:focus, .form-select:focus {
    border-color: #86b7fe;
    box-shadow: 0 0 0 0.25rem rgba(13, 110, 253, 0.25);
}

.badge {
    font-size: 0.8em;
    padding: 0.5em 0.75em;
}

.list-group-item {
    border: 1px solid rgba(0, 0, 0, 0.125);
    border-radius: 0.375rem !important;
    margin-bottom: 0.25rem;
}

.list-group-item:hover {
    background-color: #f8f9fa;
}

.table {
    border-radius: 0.375rem;
    overflow: hidden;
}

.table thead th {
    border-bottom: 2px solid #dee2e6;
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.875rem;
    letter-spacing: 0.05em;
}

.table-striped > tbody > tr:nth-of-type(odd) > td {
    background-color: rgba(0, 0, 0, 0.025);
}

.table-hover > tbody > tr:hover > td {
    background-color: rgba(0, 0, 0, 0.075);
}

.sticky-top {
    position: sticky;
    top: 0;
    z-index: 1020;
}

.data-table-container {
    max-height: 600px;
    overflow-y: auto;
    border-radius: 0.375rem;
}

/* Sample data preview styling */
.sample-data-container {
    max-height: 400px;
    overflow-y: auto;
}

/* Alert styling */
.alert {
    border: none;
    border-radius: 0.5rem;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

/* Custom hover effects */
.card:hover {
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
    transition: box-shadow 0.15s ease-in-out;
}

/* Responsive improvements */
@media (max-width: 768px) {
    .container-fluid {
        padding-left: 15px;
        padding-right: 15px;
    }
    
    .data-table-container {
        max-height: 400px;
    }
    
    .table th, .table td {
        font-size: 0.875rem;
        padding: 0.5rem;
    }
    
    .btn-lg {
        padding: 0.5rem 1rem;
        font-size: 1rem;
    }
}

/* Loading spinner for async operations */
.spinner-border-sm {
    width: 1rem;
    height: 1rem;
}

/* Progress bar styling */
.progress {
    border-radius: 0.375rem;
    height: 0.5rem;
}

/* Custom scrollbar for webkit browsers */
.data-table-container::-webkit-scrollbar,
.sample-data-container::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

.data-table-container::-webkit-scrollbar-track,
.sample-data-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 4px;
}

.data-table-container::-webkit-scrollbar-thumb,
.sample-data-container::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 4px;
}

.data-table-container::-webkit-scrollbar-thumb:hover,
.sample-data-container::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Pagination styling */
.pagination .page-link {
    border-radius: 0.375rem;
    margin: 0 2px;
    border: 1px solid #dee2e6;
}

.pagination .page-item.active .page-link {
    background-color: #0d6efd;
    border-color: #0d6efd;
}

.pagination .page-item.disabled .page-link {
    background-color: #e9ecef;
    border-color: #dee2e6;
}

.pagination .page-link:hover {
    background-color: #e9ecef;
    border-color: #dee2e6;
}

/* Per page selector styling */
.per-page-selector {
    width: auto !important;
    display: inline-block;
}

/* Duplicate highlighting */
.table-warning {
    background-color: rgba(255, 193, 7, 0.15) !important;
}

.table-danger {
    background-color: rgba(220, 53, 69, 0.15) !important;
}

.badge-duplicate {
    background-color: #ffc107 !important;
    color: #212529 !important;
}

/* Duplicate highlighting styles */
.alert-duplicate {
    border-left: 4px solid #dc3545;
    background-color: #f8d7da;
    border-color: #f5c6cb;
}

/* Targeted duplicates within range (yellow) */
.table-warning {
    background-color: rgba(255, 193, 7, 0.2) !important;
}

/* Duplicates outside range (blue) */
.table-info {
    background-color: rgba(13, 202, 240, 0.15) !important;
}

/* Search result indicators */
.duplicate-in-range {
    color: #ff6b00;
    font-weight: bold;
}

.duplicate-outside-range {
    color: #0dcaf0;
    font-weight: bold;
}

/* Sort and filter controls */
.controls-row {
    background-color: #f8f9fa;
    padding: 1rem;
    border-radius: 0.5rem;
    margin-bottom: 1rem;
}

/* Duplicate count badge in header */
.duplicate-badge {
    background-color: #dc3545 !important;
    animation: pulse 2s infinite;
}

@keyframes pulse {
    0% { opacity: 1; }
    50% { opacity: 0.7; }
    100% { opacity: 1; }
}

/* Animation for page transitions */
.fade-in {
    animation: fadeIn 0.3s ease-in;
}

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

/* Success/Error state styling */
.border-success {
    border-color: #198754 !important;
}

.border-info {
    border-color: #0dcaf0 !important;
}

.border-warning {
    border-color: #ffc107 !important;
}

.border-danger {
    border-color: #dc3545 !important;
}