/* Custom styles for CleanPro Business Manager */

/* Clean Home Time Brand Colors */
:root {
    --cleanpro-primary: #16A34A;        /* Fresh eco-friendly green */
    --cleanpro-secondary: #0891B2;      /* Professional teal */
    --cleanpro-success: #10B981;        /* Success green */
    --cleanpro-info: #06B6D4;           /* Clean cyan */
    --cleanpro-warning: #F59E0B;        /* Warm amber */
    --cleanpro-danger: #EF4444;         /* Alert red */
    --cht-primary: #7ea691;
    --cht-text: #132739;
    --cht-background: #f0f4fa;
}

/* Force all table text to be legible dark color */
.table {
    --bs-secondary-color: var(--cht-text);
    color: var(--cht-text);
}

.table :is(.text-muted, .text-success, small, i) {
    color: var(--cht-text) !important;
}

.table tbody td {
    color: var(--cht-text);
}

.table tbody .text-muted,
.table tbody .text-success,
.table tbody small,
.table tbody i {
    color: var(--cht-text) !important;
}

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

.navbar-brand i {
    color: var(--bs-primary);
}

/* Card enhancements */
.card {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
    border: 1px solid rgba(0, 0, 0, 0.125);
}

.card-header {
    font-weight: 600;
}

/* Dashboard metrics cards */
.card .fa-2x {
    opacity: 0.8;
}

/* Table improvements */
.table th {
    font-weight: 600;
    border-top: none;
}

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

/* Form enhancements */
.form-label {
    font-weight: 500;
}

.form-label i {
    opacity: 0.7;
}

.required {
    color: var(--bs-danger);
}

/* Button styling */
.btn {
    font-weight: 500;
}

.btn i {
    opacity: 0.8;
}

/* Badge styling */
.badge {
    font-size: 0.75em;
    font-weight: 500;
}

/* Alert styling */
.alert {
    border: none;
    border-radius: 0.375rem;
}

.alert i {
    opacity: 0.8;
}

/* Progress bars */
.progress {
    height: 0.5rem;
    border-radius: 0.25rem;
}

/* Modal enhancements */
.modal-header {
    border-bottom: 1px solid rgba(0, 0, 0, 0.125);
}

.modal-footer {
    border-top: 1px solid rgba(0, 0, 0, 0.125);
}

/* Loading states */
.loading {
    opacity: 0.6;
    pointer-events: none;
}

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

/* Empty states */
.empty-state {
    padding: 3rem 1rem;
}

.empty-state i {
    opacity: 0.5;
}

/* Print styles */
@media print {
    .no-print {
        display: none !important;
    }
    
    .card {
        break-inside: avoid;
        border: 1px solid #dee2e6 !important;
        box-shadow: none !important;
    }
    
    .table {
        border: 1px solid #dee2e6;
    }
    
    .btn, .dropdown, .nav {
        display: none !important;
    }
}

/* Responsive improvements */
@media (max-width: 768px) {
    .table-responsive {
        font-size: 0.875rem;
    }
    
    .btn-group-sm .btn {
        padding: 0.25rem 0.5rem;
        font-size: 0.75rem;
    }
    
    .card-body {
        padding: 1rem;
    }
    
    .display-4 {
        font-size: 2rem;
    }
}

/* Dark theme adjustments */
[data-bs-theme="dark"] {
    --bs-body-bg: #212529;
    --bs-body-color: #adb5bd;
}

[data-bs-theme="dark"] .card {
    background-color: #343a40;
    border-color: #495057;
}

[data-bs-theme="dark"] .table {
    --bs-table-bg: #343a40;
    --bs-table-striped-bg: #3d444a;
}

[data-bs-theme="dark"] .border-start {
    border-left-color: var(--bs-primary) !important;
}

[data-bs-theme="dark"] .border-info {
    border-color: var(--bs-info) !important;
}

/* Utility classes */
.opacity-50 {
    opacity: 0.5 !important;
}

.opacity-75 {
    opacity: 0.75 !important;
}

.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

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

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.slide-in {
    animation: slideIn 0.3s ease-out;
}

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