/* Google Font: Kanit - Thai/English */
@import url('https://fonts.googleapis.com/css2?family=Kanit:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap');

/* Apply Kanit font to all elements (exclude icon fonts) */
body,
html {
    font-family: 'Kanit', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif !important;
}

/* Override AdminLTE default font */
.wrapper,
.content-wrapper,
.main-sidebar,
.main-header,
.main-footer,
.sidebar,
.brand-link,
.brand-text,
.nav-sidebar,
.user-panel {
    font-family: 'Kanit', sans-serif !important;
}

/* Cards */
.card,
.card-header,
.card-body,
.card-footer,
.card-title,
.card-tools {
    font-family: 'Kanit', sans-serif !important;
}

/* Buttons and Forms */
.btn,
.form-control,
.form-group,
.input-group,
.input-group-text,
.custom-select,
.custom-file-label,
.custom-control-label {
    font-family: 'Kanit', sans-serif !important;
}

/* Navigation */
.nav-link,
.nav-item,
.navbar,
.dropdown-menu,
.dropdown-item,
.breadcrumb,
.breadcrumb-item,
.pagination {
    font-family: 'Kanit', sans-serif !important;
}

/* Modal */
.modal,
.modal-header,
.modal-body,
.modal-footer,
.modal-title {
    font-family: 'Kanit', sans-serif !important;
}

/* Alerts and Badges */
.alert,
.badge,
.toast,
.tooltip,
.popover {
    font-family: 'Kanit', sans-serif !important;
}

/* Tables */
.table,
.table th,
.table td,
table,
th,
td {
    font-family: 'Kanit', sans-serif !important;
}

/* Typography - exclude i tag for icons */
h1, h2, h3, h4, h5, h6,
.h1, .h2, .h3, .h4, .h5, .h6,
p, span, div, a, label,
input, select, textarea, button,
small, strong, em, b {
    font-family: 'Kanit', sans-serif !important;
}

/* DataTables */
.dataTables_wrapper,
.dataTables_info,
.dataTables_filter,
.dataTables_filter input,
.dataTables_length,
.dataTables_length select,
.dataTables_paginate,
.paginate_button,
table.dataTable {
    font-family: 'Kanit', sans-serif !important;
}

/* SweetAlert2 */
.swal2-popup,
.swal2-title,
.swal2-html-container,
.swal2-content,
.swal2-confirm,
.swal2-cancel,
.swal2-deny,
.swal2-input,
.swal2-textarea {
    font-family: 'Kanit', sans-serif !important;
}

/* Select2 */
.select2-container,
.select2-selection,
.select2-selection__rendered,
.select2-results,
.select2-results__option,
.select2-search__field {
    font-family: 'Kanit', sans-serif !important;
}

/* Summernote Editor */
.note-editor,
.note-editable,
.note-statusbar,
.note-placeholder {
    font-family: 'Kanit', sans-serif !important;
}

/* CKEditor */
.cke,
.cke_inner,
.cke_contents,
.cke_editable {
    font-family: 'Kanit', sans-serif !important;
}

/* Info Box and Small Box (AdminLTE) */
.info-box,
.info-box-content,
.info-box-text,
.info-box-number,
.small-box,
.small-box h3,
.small-box p {
    font-family: 'Kanit', sans-serif !important;
}

/* Timeline */
.timeline,
.timeline-item,
.timeline-header,
.timeline-body,
.timeline-footer {
    font-family: 'Kanit', sans-serif !important;
}

/* Callout */
.callout,
.callout h5,
.callout p {
    font-family: 'Kanit', sans-serif !important;
}

/* Login/Register Pages */
.login-page,
.register-page,
.login-box,
.register-box,
.login-card-body,
.register-card-body {
    font-family: 'Kanit', sans-serif !important;
}

/* ========================================
   PRESERVE ICON FONTS - DO NOT OVERRIDE
   ======================================== */

/* Font Awesome */
.fa,
.fas,
.far,
.fal,
.fad,
.fab,
[class^="fa-"],
[class*=" fa-"] {
    font-family: "Font Awesome 5 Free", "Font Awesome 5 Brands", "FontAwesome" !important;
}

/* Font Awesome 5 specific */
.fa-solid,
.fa-regular,
.fa-light,
.fa-thin,
.fa-duotone,
.fa-brands {
    font-family: "Font Awesome 5 Free", "Font Awesome 5 Brands", "FontAwesome" !important;
}

/* Ionicons */
.ion,
[class^="ion-"],
[class*=" ion-"] {
    font-family: "Ionicons" !important;
}

/* Glyphicons (Bootstrap 3) */
.glyphicon,
[class^="glyphicon-"],
[class*=" glyphicon-"] {
    font-family: "Glyphicons Halflings" !important;
}

/* Material Icons */
.material-icons,
.material-icons-outlined,
.material-icons-round,
.material-icons-sharp,
.material-icons-two-tone {
    font-family: "Material Icons" !important;
}

/* Feather Icons */
.feather,
[data-feather] {
    font-family: "feather" !important;
}

/* Simple Line Icons */
.icon-,
[class^="icon-"],
[class*=" icon-"] {
    font-family: "simple-line-icons" !important;
}

/* Print styles - exclude icons */
@media print {
    body,
    .wrapper,
    .content-wrapper,
    p, span, div, a, label,
    h1, h2, h3, h4, h5, h6,
    table, th, td {
        font-family: 'Kanit', sans-serif !important;
    }
}
