/* 
 * Global Cairo Font Force
 * Ultimate override to ensure Cairo is applied everywhere
 * This file should be loaded LAST to override any conflicting styles
 */

/* ========================================
 * ULTIMATE CAIRO FORCE - GLOBAL OVERRIDE
 * ======================================== */

/* Force Cairo on ALL text elements with maximum specificity */
body, html,
div:not(.fa):not(.fas):not(.far):not(.fab):not(.glyphicon):not([class*="icon-"]):not(.btn):not([class*="btn-"]):not(.pagination):not([class*="pagination"]):not(.select2-container):not([class*="select2"]):not(.dt-buttons):not([class*="dt-"]):not(.DTTT):not([class*="DTTT"]),
span:not(.fa):not(.fas):not(.far):not(.fab):not(.glyphicon):not([class*="icon-"]):not(.btn):not([class*="btn-"]):not(.pagination):not([class*="pagination"]):not(.select2-container):not([class*="select2"]):not(.dt-buttons):not([class*="dt-"]):not(.DTTT):not([class*="DTTT"]),
p, h1, h2, h3, h4, h5, h6,
label, .form-label, .control-label,
td, th, li, ul, ol,
input:not([type="button"]):not([type="submit"]):not([type="reset"]),
textarea, select,
.content, .main-content, .page-content,
.box-body, .panel-body, .card-body,
.modal-body, .alert, .list-group-item,
.navbar-nav > li > a,
.sidebar-menu > li > a,
.treeview-menu > li > a,
.breadcrumb li,
.table thead th, .table tbody td,
.dataTables_info,
.content-header h1, .box-title, .panel-title {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * SETTINGS PAGE SPECIFIC FORCE
 * ======================================== */

/* Force Cairo on settings page elements */
.settings-form,
.company-settings,
.business-settings,
.settings-card,
.settings-panel,
.settings-section,
.settings-group,
.form-section {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

.settings-form *:not(.fa):not(.fas):not(.far):not(.fab):not(.glyphicon):not([class*="icon-"]):not([class*="btn-"]):not(.btn):not(.pagination):not([class*="pagination"]):not(.select2-container):not([class*="select2"]):not(.dt-buttons):not([class*="dt-"]):not(.DTTT):not([class*="DTTT"]) {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * FORM ELEMENTS FORCE
 * ======================================== */

/* Force Cairo on all form elements */
.form-control,
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="tel"],
input[type="url"],
input[type="search"],
textarea,
select,
option {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* Input groups */
.input-group-addon {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* Help text */
.help-block,
.form-text,
.text-muted,
small,
.help-text {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * DROPDOWN FORCE
 * ======================================== */

/* Force Cairo on select2 elements */
.select2-container .select2-selection--single .select2-selection__rendered,
.select2-container .select2-selection--multiple .select2-selection__choice,
.select2-results__option,
.select2-search__field {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * NAVIGATION FORCE
 * ======================================== */

/* Force Cairo on navigation elements */
.navbar-brand,
.navbar-nav > li > a,
.nav-tabs > li > a,
.nav-pills > li > a,
.breadcrumb > li,
.sidebar-menu > li > a,
.treeview-menu > li > a {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * CONTENT FORCE
 * ======================================== */

/* Force Cairo on content areas */
.main-content,
.content-wrapper,
.page-content,
.box-content,
.panel-content {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * TABLE FORCE
 * ======================================== */

/* Force Cairo on table content */
.table,
.table th,
.table td,
.table caption,
.dataTables_wrapper,
.dataTables_info {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * MODAL FORCE
 * ======================================== */

/* Force Cairo on modal content */
.modal-title,
.modal-body,
.modal-body p,
.modal-body label,
.modal-body span,
.modal-body div {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * ALERT FORCE
 * ======================================== */

/* Force Cairo on alerts */
.alert,
.alert p,
.alert span,
.alert div {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * ICON PROTECTION - MAINTAIN EXCLUSIONS
 * ======================================== */

/* Ensure icons remain with icon fonts */
.fa, .fas, .far, .fab, .fal, .fad,
.glyphicon, .icon, .material-icons,
[class*="fa-"], [class*="glyphicon-"], [class*="icon-"],
i:not([class*="text-"]) {
    font-family: 'Font Awesome 5 Free', 'Font Awesome 5 Brands', 'FontAwesome', 
                 'Glyphicons Halflings', 'Ionicons', 'Material Icons' !important;
}

/* ========================================
 * BUTTON CAIRO APPLICATION
 * ======================================== */

/* Apply Cairo to button text while keeping functionality */
.btn, button,
input[type="button"],
input[type="submit"],
input[type="reset"] {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
    font-weight: 500 !important;
}

/* Button text elements */
.btn span,
.btn div,
button span,
button div {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* Specific button types */
.btn-primary,
.btn-success,
.btn-info,
.btn-warning,
.btn-danger,
.btn-default,
.btn-secondary {
    font-family: 'Cairo', 'Tahoma', 'Arial', sans-serif !important;
}

/* DataTables and pagination buttons - keep system font for layout */
.dt-button, .DTTT_button,
.pagination > li > a,
.pagination > li > span {
    font-family: 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * SELECT2 PROTECTION - MAINTAIN EXCLUSIONS
 * ======================================== */

/* Select2 container should remain with system font for proper display */
.select2-container,
.select2-dropdown,
.select2-search {
    font-family: 'Tahoma', 'Arial', sans-serif !important;
}

/* ========================================
 * DATATABLES PROTECTION - MAINTAIN EXCLUSIONS
 * ======================================== */

/* DataTables controls should remain with system font */
.dt-buttons,
.dataTables_paginate,
.dataTables_length,
.dataTables_filter {
    font-family: 'Tahoma', 'Arial', sans-serif !important;
}
