/* Reportly Custom Styles - Multisaas */

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

/* Dark mode support */
[data-bs-theme="dark"] {
    --light-bg: #1a1a1a;
    --dark-bg: #f8f9fa;
}

/* Body and Layout */
body {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
}

main {
    flex: 1;
}

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

.navbar-brand i {
    margin-right: 0.5rem;
}

/* Cards */
.stat-card {
    border: none;
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s, box-shadow 0.2s;
}

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

.report-card {
    border-radius: 10px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.report-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.report-icon {
    font-size: 3rem;
}

/* Tables */
.table-responsive {
    border-radius: 8px;
}

.table thead th {
    position: sticky;
    top: 0;
    z-index: 10;
}

/* Light mode table headers */
.table-dark thead th {
    background-color: #212529 !important;
    color: #ffffff !important;
}

/* Dark mode table headers - ensure good contrast */
[data-bs-theme="dark"] .table-dark thead th {
    background-color: #0d6efd !important;
    color: #ffffff !important;
}

[data-bs-theme="dark"] .table thead th {
    background-color: #0d6efd !important;
    color: #ffffff !important;
}

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

.table tbody tr:hover {
    background-color: rgba(13, 110, 253, 0.1);
}

/* Charts */
canvas {
    max-height: 400px;
}

/* Loading Spinner */
.spinner-border {
    width: 2rem;
    height: 2rem;
}

/* Buttons */
.btn {
    border-radius: 6px;
    padding: 0.5rem 1.5rem;
    font-weight: 500;
    transition: all 0.2s;
}

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

.btn i {
    margin-right: 0.5rem;
}

/* Badges */
.badge {
    padding: 0.5rem 0.75rem;
    font-weight: 500;
}

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

.footer-text {
    color: #495057;
    font-weight: 500;
}

/* Dark mode footer */
[data-bs-theme="dark"] .footer {
    background-color: #212529;
    border-top: 1px solid #495057;
}

[data-bs-theme="dark"] .footer-text {
    color: #adb5bd;
}

/* Dark Mode Toggle */
#themeToggle {
    border: 1px solid rgba(255, 255, 255, 0.3);
}

#themeToggle:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

/* Responsive Design */
@media (max-width: 768px) {
    .stat-card {
        margin-bottom: 1rem;
    }
    
    .navbar-brand {
        font-size: 1.2rem;
    }
    
    .display-4 {
        font-size: 2rem;
    }
    
    .display-5 {
        font-size: 1.75rem;
    }
    
    .table {
        font-size: 0.875rem;
    }
}

/* Currency Formatting */
.text-currency {
    font-family: 'Courier New', monospace;
    font-weight: 600;
}

/* Status Indicators */
.status-positive {
    color: var(--success-color);
}

.status-negative {
    color: var(--danger-color);
}

/* Card Headers */
.card-header {
    background-color: var(--light-bg);
    border-bottom: 2px solid var(--primary-color);
    font-weight: 600;
}

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

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

/* Alert Styling */
.alert {
    border-radius: 8px;
    border-left: 4px solid;
}

.alert-danger {
    border-left-color: var(--danger-color);
}

.alert-success {
    border-left-color: var(--success-color);
}

.alert-warning {
    border-left-color: var(--warning-color);
}

.alert-info {
    border-left-color: var(--info-color);
}

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

::-webkit-scrollbar-track {
    background: var(--light-bg);
}

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

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

/* Print Styles */
@media print {
    .navbar,
    .footer,
    .btn,
    #reportForm {
        display: none;
    }
    
    .card {
        border: 1px solid #000;
        box-shadow: none;
    }
    
    .table {
        font-size: 0.75rem;
    }
}



