/* Custom Styles for Smart Collection Dashboard */

:root {
    --primary-color: #2563eb;
    --secondary-color: #64748b;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #3b82f6;
    --light-color: #f8fafc;
    --dark-color: #1e293b;
}

body {
    font-family: 'Cairo', sans-serif;
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
}

/* Navigation Styles */
.nav-link {
    @apply px-3 py-2 rounded-md text-sm font-medium text-gray-600 hover:text-gray-900 hover:bg-gray-100 transition-colors duration-200;
}

.nav-link.active {
    @apply text-blue-600 bg-blue-50 border-b-2 border-blue-600;
}

/* Cards */
.kpi-card {
    @apply bg-white rounded-lg shadow-md p-6 transition-all duration-300 hover:shadow-lg;
}

/* Status Badges */
.status-badge {
    @apply px-2 py-1 text-xs font-semibold rounded-full;
}

.status-paid {
    @apply bg-green-100 text-green-800;
}

.status-overdue {
    @apply bg-red-100 text-red-800;
}

.status-warning {
    @apply bg-yellow-100 text-yellow-800;
}

.status-normal {
    @apply bg-blue-100 text-blue-800;
}

/* Progress Bars */
.progress-bar {
    @apply w-full bg-gray-200 rounded-full h-2;
}

.progress-fill {
    @apply h-2 rounded-full transition-all duration-300;
}

.progress-success {
    @apply bg-green-500;
}

.progress-warning {
    @apply bg-yellow-500;
}

.progress-danger {
    @apply bg-red-500;
}

/* Tables */
.table-container {
    @apply overflow-x-auto bg-white rounded-lg shadow;
}

.data-table {
    @apply min-w-full divide-y divide-gray-200;
}

.data-table th {
    @apply px-6 py-3 text-right text-xs font-medium text-gray-500 uppercase tracking-wider bg-gray-50;
}

.data-table td {
    @apply px-6 py-4 whitespace-nowrap text-sm text-gray-900;
}

.data-table tr:hover {
    @apply bg-gray-50;
}

/* Charts */
.chart-container {
    @apply bg-white p-4 rounded-lg shadow;
}

/* Loading States */
.loading-skeleton {
    @apply animate-pulse bg-gray-200 rounded;
}

/* Dark Mode */
.dark-mode {
    background: linear-gradient(135deg, #1e293b 0%, #334155 100%);
    color: #e2e8f0;
}

.dark-mode .bg-white {
    background-color: #1e293b;
    color: #e2e8f0;
}

.dark-mode .text-gray-900 {
    color: #f8fafc;
}

.dark-mode .text-gray-600 {
    color: #cbd5e1;
}

.dark-mode .border-gray-200 {
    border-color: #475569;
}

.dark-mode .bg-gray-50 {
    background-color: #334155;
}

/* Responsive Design */
@media (max-width: 768px) {
    .kpi-card {
        @apply p-4;
    }
    
    .chart-container {
        @apply p-2;
    }
}

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

.animate-fadeInUp {
    animation: fadeInUp 0.5s ease-out;
}

/* Floating Action Button */
.fab {
    @apply fixed bottom-6 right-6 bg-blue-600 text-white rounded-full p-4 shadow-lg hover:bg-blue-700 transition-colors duration-300;
}

/* Filters */
.filter-section {
    @apply bg-white rounded-lg shadow p-4 mb-4;
}

.filter-input {
    @apply border border-gray-300 rounded-md px-3 py-2 text-sm focus:outline-none focus:ring-2 focus:ring-blue-500;
}

/* Alerts */
.alert {
    @apply p-4 rounded-md border-l-4 mb-4;
}

.alert-info {
    @apply bg-blue-50 border-blue-400 text-blue-700;
}

.alert-success {
    @apply bg-green-50 border-green-400 text-green-700;
}

.alert-warning {
    @apply bg-yellow-50 border-yellow-400 text-yellow-700;
}

.alert-danger {
    @apply bg-red-50 border-red-400 text-red-700;
}

/* AI Recommendations */
.ai-recommendation {
    @apply bg-gradient-to-r from-purple-50 to-blue-50 border border-purple-200 rounded-lg p-4 mb-4;
}

/* Heatmap */
.project-heatmap {
    @apply grid grid-cols-3 gap-4 p-4;
}

.project-cell {
    @apply rounded-lg p-4 text-center transition-all duration-300 hover:scale-105;
}

.project-cell.excellent {
    @apply bg-green-100 border border-green-300;
}

.project-cell.good {
    @apply bg-blue-100 border border-blue-300;
}

.project-cell.warning {
    @apply bg-yellow-100 border border-yellow-300;
}

.project-cell.danger {
    @apply bg-red-100 border border-red-300;
}

/* Payment Form */
.payment-form {
    @apply bg-white rounded-lg shadow p-6;
}

.payment-input {
    @apply border border-gray-300 rounded-md px-3 py-2 w-full focus:outline-none focus:ring-2 focus:ring-blue-500;
}

/* Export Buttons */
.export-btn {
    @apply inline-flex items-center px-4 py-2 border border-gray-300 rounded-md shadow-sm text-sm font-medium text-gray-700 bg-white hover:bg-gray-50;
}

.export-btn.excel {
    @apply bg-green-50 text-green-700 border-green-300 hover:bg-green-100;
}

.export-btn.pdf {
    @apply bg-red-50 text-red-700 border-red-300 hover:bg-red-100;
}

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

::-webkit-scrollbar-track {
    @apply bg-gray-100;
}

::-webkit-scrollbar-thumb {
    @apply bg-gray-400 rounded;
}

::-webkit-scrollbar-thumb:hover {
    @apply bg-gray-500;
}