:root {
    --crm-primary: #3459e6;
    --crm-primary-dark: #2443bb;
    --crm-surface: #ffffff;
    --crm-canvas: #f5f7fb;
    --crm-border: #e7ebf3;
    --crm-text: #182230;
    --crm-muted: #667085;
    --crm-radius: 14px;
    --crm-shadow: 0 8px 28px rgba(16, 24, 40, .07);
}

html { scroll-behavior: smooth; }
body { background: var(--crm-canvas); color: var(--crm-text); overflow-x: hidden; }
.card { border: 1px solid var(--crm-border); border-radius: var(--crm-radius); box-shadow: var(--crm-shadow); }
.btn { min-height: 40px; border-radius: 9px; font-weight: 600; }
.btn-primary { background: var(--crm-primary); border-color: var(--crm-primary); }
.btn-primary:hover, .btn-primary:focus { background: var(--crm-primary-dark); border-color: var(--crm-primary-dark); }
.form-control, .form-select, .select2-container .select2-selection { min-height: 42px; border-color: #d8deea; border-radius: 9px; }
.form-control:focus, .form-select:focus { border-color: var(--crm-primary); box-shadow: 0 0 0 .2rem rgba(52, 89, 230, .13); }
.table { --bs-table-bg: transparent; }
.table > :not(caption) > * > * { padding: .9rem .8rem; vertical-align: middle; }
.table-responsive { border-radius: 0 0 var(--crm-radius) var(--crm-radius); }
.page-header { gap: 1rem; flex-wrap: wrap; }
.page-header-right, .page-header-right-items, .page-header-right-items-wrapper { max-width: 100%; flex-wrap: wrap; }
.badge { letter-spacing: .01em; }
img { max-width: 100%; }

@media (max-width: 991.98px) {
    .nxl-container { width: 100%; }
    .main-content { padding: 18px 14px; }
    .page-header { padding-left: 14px; padding-right: 14px; }
    .card-body { padding: 1rem; }
    .auth-cover-content-inner { display: none !important; }
    .auth-cover-sidebar-inner { width: 100% !important; min-height: 100vh; }
    .auth-cover-card-wrapper { padding: 20px; }
}

@media (max-width: 767.98px) {
    .page-header-title h5 { font-size: 1.1rem; }
    .page-header-right, .page-header-right-items, .page-header-right-items-wrapper { width: 100%; }
    .page-header-right .btn, .page-header-right-items-wrapper > .btn { flex: 1 1 auto; }
    .table-responsive { overflow-x: auto; -webkit-overflow-scrolling: touch; }
    .table { min-width: 720px; }
    .modal-dialog { margin: .75rem; }
    .row.g-4 { --bs-gutter-x: 1rem; }
    .nxl-content .col-lg-3, .nxl-content .col-lg-4, .nxl-content .col-lg-6 { min-width: 0; }
}

@media (max-width: 575.98px) {
    .main-content { padding: 12px 10px; }
    .card { border-radius: 11px; }
    .card-body { padding: .85rem; }
    .btn { width: 100%; }
    .btn-group .btn, .hstack .btn, .input-group .btn { width: auto; }
    .d-flex.gap-2, .d-flex.gap-3 { flex-wrap: wrap; }
    .auth-cover-card { padding: 1.25rem !important; }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
