/* ProcureGenius Custom Styles */

:root {
    --primary-color: #0d6efd;
    --secondary-color: #6c757d;
    --success-color: #198754;
    --danger-color: #dc3545;
    --warning-color: #ffc107;
    --info-color: #0dcaf0;
    --light-color: #f8f9fa;
    --dark-color: #212529;
}

/* Navigation */
.navbar-brand {
    font-weight: 600;
    font-size: 1.5rem;
}

.navbar-nav .nav-link {
    font-weight: 500;
    padding: 0.5rem 1rem;
}

.navbar-nav .dropdown-menu {
    border: none;
    box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
}

/* Cards */
.card {
    border: none;
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    margin-bottom: 1.5rem;
}

.card-header {
    background-color: var(--light-color);
    border-bottom: 1px solid #dee2e6;
    font-weight: 600;
}

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

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

.btn-primary:hover {
    background-color: #0b5ed7;
    border-color: #0a58ca;
}

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

.table th {
    border-top: none;
    font-weight: 600;
    color: var(--dark-color);
}

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

.form-label {
    font-weight: 500;
    color: var(--dark-color);
}

/* Badges */
.badge {
    font-weight: 500;
}

/* Stats cards */
.stats-card {
    background: linear-gradient(135deg, var(--primary-color) 0%, #0b5ed7 100%);
    color: white;
    border-radius: 0.75rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
}

.stats-card .stats-icon {
    font-size: 2.5rem;
    opacity: 0.8;
}

.stats-card .stats-number {
    font-size: 2rem;
    font-weight: 700;
    margin: 0;
}

.stats-card .stats-label {
    font-size: 0.875rem;
    opacity: 0.9;
}

/* AI Assistant */
.ai-chat-container {
    height: 500px;
    border: 1px solid #dee2e6;
    border-radius: 0.375rem;
    background-color: #fff;
}

.ai-chat-messages {
    height: 400px;
    overflow-y: auto;
    padding: 1rem;
    background-color: #f8f9fa;
}

.ai-message {
    margin-bottom: 1rem;
    padding: 0.75rem;
    border-radius: 0.5rem;
    max-width: 80%;
}

.ai-message.user {
    background-color: var(--primary-color);
    color: white;
    margin-left: auto;
    text-align: right;
}

.ai-message.assistant {
    background-color: white;
    border: 1px solid #dee2e6;
}

.ai-chat-input {
    padding: 1rem;
    border-top: 1px solid #dee2e6;
}

/* Dashboard widgets */
.dashboard-widget {
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    background-color: white;
}

.dashboard-widget h6 {
    color: var(--secondary-color);
    font-weight: 600;
    margin-bottom: 1rem;
}

/* Status indicators */
.status-draft { color: var(--secondary-color); }
.status-pending { color: var(--warning-color); }
.status-approved { color: var(--success-color); }
.status-sent { color: var(--info-color); }
.status-paid { color: var(--success-color); }
.status-overdue { color: var(--danger-color); }

/* Responsive adjustments */
@media (max-width: 768px) {
    .navbar-nav .nav-link {
        padding: 0.25rem 1rem;
    }
    
    .stats-card {
        text-align: center;
        margin-bottom: 1rem;
    }
    
    .ai-message {
        max-width: 95%;
    }
}

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

/* Alerts */
.alert {
    border: none;
    border-radius: 0.5rem;
}

/* Footer */
footer {
    margin-top: auto;
    border-top: 1px solid #dee2e6;
}

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

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

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