/* Custom Styles for Business Tracker */

:root {
    --primary-color: #0d6efd;
    --success-color: #198754;
    --danger-color: #dc3545;
    --info-color: #0dcaf0;
    --light-bg: #f8f9fa;
}

body {
    background-color: var(--light-bg);
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

/* Header Styles */
header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

header h1 {
    color: white;
}

header p {
    color: rgba(255, 255, 255, 0.9);
}

header .bi {
    color: white;
}

/* Card Styles */
.card {
    border: none;
    border-radius: 12px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.15) !important;
}

/* Stats Container */
.stats-container {
    padding: 0.5rem 0;
}

.stat-item {
    margin-bottom: 0.75rem;
}

.stat-item:last-child {
    margin-bottom: 0;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: 600;
    margin-top: 0.25rem;
}

/* Table Styles */
.table {
    margin-bottom: 0;
}

.table thead {
    background-color: #f8f9fa;
}

.table tbody tr {
    transition: background-color 0.2s;
}

.table tbody tr:hover {
    background-color: #f8f9fa;
}

/* Form Styles */
.form-control:focus,
.form-select:focus {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 0.2rem rgba(13, 110, 253, 0.25);
}

/* Button Styles */
.btn {
    border-radius: 8px;
    padding: 0.5rem 1.25rem;
    font-weight: 500;
    transition: all 0.2s;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.15);
}

.btn-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border: none;
}

.btn-primary:hover {
    background: linear-gradient(135deg, #5568d3 0%, #63408a 100%);
}

/* Badge Styles */
.badge {
    padding: 0.5rem 0.75rem;
    font-weight: 500;
    border-radius: 6px;
}

/* Toast Styles */
.toast {
    min-width: 300px;
}

/* Chart Container */
#revenueChart {
    max-height: 400px;
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .stat-value {
        font-size: 1.25rem;
    }
    
    header h1 {
        font-size: 1.75rem;
    }
    
    .table {
        font-size: 0.875rem;
    }
}

/* Loading Animation */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.loading {
    animation: pulse 1.5s ease-in-out infinite;
}

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

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 4px;
}

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

/* Print Styles */
@media print {
    .btn, .toast, header {
        display: none;
    }
    
    .card {
        box-shadow: none !important;
        border: 1px solid #dee2e6 !important;
    }
}

/* Pagination Styles */
#paginationControls {
    padding: 1rem 0;
}

#paginationControls .btn-group .btn {
    min-width: 90px;
}

#paginationControls .text-muted {
    font-size: 0.9rem;
}

@media (max-width: 768px) {
    #paginationControls .d-flex {
        flex-direction: column;
        gap: 1rem;
    }
    
    #paginationControls .btn-group .btn {
        min-width: auto;
        font-size: 0.8rem;
    }
    
    #paginationControls .btn-group .btn i {
        margin: 0 !important;
    }
    
    #paginationControls .btn-group .btn:not(:has(i)) {
        display: none;
    }
}