.danhsachchitiet {
    position: relative;
    padding-top: 17px;
}

.main-form {
    background: #ffffff;

    padding: 10px 20px !important;

    margin-bottom: 15px;

}

#themtem {
    margin-bottom: 20px;
    max-width: 600px;
}

#reader {
    max-height: 400px !important;
    max-width: 400px;
}

.QrAction {
    width: 400px;
    left: 0px;
    top: 0px;
    position: absolute;
    z-index: 999;
}


.dataTables_wrapper td,
.dataTables_wrapper th {
    vertical-align: middle !important;
    text-align: left !important;
}

.table>tbody>tr>td,
.table>tbody>tr>th,
.table>tfoot>tr>td,
.table>tfoot>tr>th,
.table>thead>tr>td,
.table>thead>tr>th {
    vertical-align: middle;
    border-top: 1px solid #ebeef0;
    padding: 8px 12px !important;
    line-height: 1.42857143;
}

.control-label {
    font-weight: 500;

}

input.form-control,
.ui-select-wrapper {
    margin-bottom: 10px;
}

.header-form {
    background: #4f5a67;
    padding: 5px 20px;
    border-radius: 0px;
    font-size: 17px;
    font-weight: bold;
    color: #fff;
}

.form-actions.form-actions-fixed-bottom {
    position: fixed;
    bottom: 0;
    left: 235px;
    right: 0;
    z-index: 999;
    background-color: #fff;
    border-bottom: 1px solid #ccc;
    box-shadow: 0 2px 2px -2px rgba(0, 0, 0, .5);
    text-align: right;
    padding: 5px 20px;
}

.t_header_table {
    background: #f2f2f2;
    padding: 5px 0px 0px 10px;
    border-radius: 5px 5px 0px 0px;
    position: relative;
    color: #000;
    text-transform: uppercase;
    border-bottom: 2px solid #0b98a7;
    font-size: 14px;
    box-decoration-break: cle;
    clear: both;
    overflow: hidden;
}

.group.group-start {
    font-weight: bold;
    background: #f8f9fa !important;
    font-size: 105%;
}

.t_table_app {
    position: relative;
}

.t_table_app .dataTables_wrapper thead {
    background: #e5e5e5 !important;
}

.t-btn-group {
    position: absolute;
    right: 6px;
    z-index: 1;
    top: 5px;
}

.t_button_item {
    font-size: 13px;
    padding: 4px 7px;
    background: #36c6d3;
    margin: 2px;
    border-radius: 3px;
    color: #fff;
    text-decoration: none;
}

.t_button_item:hover {
    opacity: 0.8;
}

.danhsachchitiet_crm {
    margin-top: 85px;
}

.chitietxuatkho {
    position: relative;
}

@media (min-width: 992px) {
    .page-sidebar.collapse {
        display: block;
        max-height: none !important;
        box-shadow: 0px 0px 10px #e5e5e5;
    }
}

.loading {
    position: absolute;
    width: 100%;
    height: 100%;
    text-align: center;
    z-index: 9;
    background: transparent;
    color: #000;
    top: 100px;
}
.avatar-body .loading {display: none!important;}


.danhsachchitiet .dataTables_filter {
    padding: 0;
    display: block;
    float: left;
    position: relative;
    top: 0px;
    left: 0px;
    right: auto;
    z-index: 1;
}

.danhsachchitiet .dataTables_filter input[type="search"] {
    margin-top: 3px;
    height: 26px;
    width: 250px;
    padding-right: 30px;
}

/*QR code*/
.input-wrapper {
    position: relative;
    margin-bottom: 20px;
    max-width: 300px;
}

.qr-icon {
    position: absolute;
    top: 50px;
    right: 23px;
    transform: translateY(-50%);
    cursor: pointer;
    font-size: 20px;
}

.input-wrapper .qr-icon {
    top: 17px;
    right: 9px;
}

#reader-container {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    /* Toàn bộ chiều rộng màn hình */
    height: 100vh;
    /* Toàn bộ chiều cao màn hình */
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

#reader {
    width: 100%;
    /* Chiều rộng video */
    height: 100%;
    /* Chiều cao video */
    background: white;
    border-radius: 10px;
    margin: 0px auto;
    margin-top: 40px;
}

#close-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    background: red;
    color: white;
    border: none;
    z-index: 9000;
    padding: 10px;
    border-radius: 5px;
    cursor: pointer;
}

.page-content .dataTables_wrapper th {
    outline: none !important;
    color: #3c4043;
    font-size: 13px !important;
    border-left: 1px solid #e5e5e5;
}

.page-content .dataTables_wrapper td {
    outline: none !important;
    color: #3c4043;
    font-size: 13px !important;
    border-left: 0px solid #e5e5e5;
}

.page-content .dataTables_wrapper tr td:last-child {
    border-right: 1px solid #e5e5e5;
}

.table>tbody>tr>td,
.table>tbody>tr>th,
.table>tfoot>tr>td,
.table>tfoot>tr>th,
.table>thead>tr>td,
.table>thead>tr>th {
    vertical-align: middle;
    border-top: 1px solid #ebeef0;
    padding: 5px 13px !important;
    line-height: 29px;
}

.status-label1 {
    font-weight: normal;
}

.da_kich_hoat_bao_hanh.status-label1 {
    color: green;
}

/* CSS tùy chỉnh */
table.dataTable td {
    white-space: nowrap;
    /* Bắt buộc nội dung không xuống dòng */
    overflow: hidden;
    /* Ẩn nội dung nếu quá dài */
    text-overflow: ellipsis;
    /* Hiển thị "..." nếu nội dung bị cắt */
}

table.dataTable th {
    white-space: nowrap;
}

.page-content .dataTables_wrapper .dt-buttons .btn {
    padding: 6px 10px;
    font-size: 15px;
    line-height: 1.5;
    background: transparent;
    border-color: #e5e5e5;
    color: #000 !important;
    border-radius: 3px;
}

@media screen and (max-width: 767px) {
    .page-content .table-responsive .table.dataTable {
        min-width: 585px
    }

    .page-content .table-responsive .dataTables_wrapper .dt-buttons {
        margin-top: 10px;
        float: right;
        margin-right: 10px;
    }

    .page-content .table-responsive .dataTables_wrapper .dataTables_filter {
        max-width: 215px;
        position: absolute;
        top: 4px;
    }

    .dataTables_filter label::after {
        font: normal normal normal 14px/1 Font Awesome\ 5 Free;
        font-weight: normal;
        line-height: 1;
        content: "\F002";
        position: absolute;
        right: -4px;
        top: 2px;
        width: 40px;
        height: 30px;
        line-height: 30px;
        text-align: center;
        color: #495057;
        font-weight: 900;
    }

    .table-has-actions .dataTables_filter,
    .table-has-filter .dataTables_filter {
        left: 3px !important;
    }

    .page-content .dataTables_wrapper .dt-buttons .btn span span {
        display: inline-flex;
        /* Đảm bảo biểu tượng và text nằm trên một dòng */
        align-items: center;
    }

    .page-content .dataTables_wrapper .dt-buttons .btn span span> :not(i) {
        display: none;
        /* Ẩn tất cả phần tử con không phải <i> */
    }

    .page-content-wrapper .page-content {
        padding: 0px !important;
        overflow: hidden;
    }

    .page-header.navbar .top-menu {
        background-color: #5e6672;
        display: none !important;
    }

}

.dropdown-header-name {
    color: #000 !important;
    font-size: 13px;
    font-weight: 300;
}

.page-header.navbar .top-menu .navbar-nav>li.dropdown-user>.dropdown-toggle>.username {
    color: #000;
}

.btn-primary {
    background: var(--primary-color);
    border-color: var(--primary-color);
}

.t_table_app .table-responsive {
    overflow-x: scroll !important;
}

.cho {
    color: rgb(218, 122, 0);
}

.da_chuan_bi_hang_xong {
    color: rgb(124, 0, 255);
}

.dachuanbihangxong {
    background: rgb(124, 0, 255) !important;
}

.xuatthieu {
    color: red;
    font-weight: bold;
}

.xuatdu {
    color: green;
    font-weight: bold;
}

.page-header.navbar .menu-toggler.responsive-toggler {
    float: right;
    margin: 10px 0px 0px 0px;
    color: #333;
    border: 0px solid #e5e5e5;
    width: 46px;
    text-align: center;
    font-size: 22px;
    border-radius: 4px;
    height: 35px;
}

.form-actions.form-actions-fixed-bottom {
    position: fixed;
    bottom: 0;
    left: 0 !important;
    right: 0 !important;
    z-index: 1000;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    box-shadow: 0 -5px 25px rgba(0, 0, 0, 0.1);
    padding: 10px 0;
    display: flex;
    justify-content: center;
    height: auto;
    box-sizing: border-box;
}

.form-actions.form-actions-fixed-bottom .btn-set {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    width: 100%;
    max-width: 100%;
    justify-content: center;
    padding: 0 15px;
    box-sizing: border-box;
    scrollbar-width: none;
    -ms-overflow-style: none;
}

.form-actions.form-actions-fixed-bottom .btn-set::-webkit-scrollbar {
    display: none;
    /* Chrome/Safari */
}

@media (max-width: 768px) {
    .form-actions.form-actions-fixed-bottom .btn-set {
        justify-content: flex-start;
        /* Cuộn ngang trên mobile */
    }
}

.f-reload {
    width: 46px;
    text-align: center;
    display: block;
    float: right;
    border: 1px solid #e5e5e5;
    margin-top: 10px;
    border-radius: 4px;
    color: #fff;
    margin-right: 3px;
    font-size: 20px;
}

@media (max-width: 991px) {
    .page-header.navbar .page-logo img {
        margin-left: -16px !important;
    }

    .page-header-inner.col-12 {
        padding-right: 0px !important;
    }

    #list_widgets {
        margin-top: 5px;
        padding: 10px 15px;
    }

}

#qr-scanner-container {
    position: fixed;
    top: 0px;
    left: 0px;
    background: rgba(0, 0, 0, 0.8);
    padding: 0px;
    box-shadow: 0px 4px 10px rgba(0, 0, 0, 0.2);
    border-radius: 8px;
    z-index: 1000;
    display: none;
    text-align: center;
    width: 100%;
    height: 100%;
}

#qr-video {
    width: 100%;
    height: 400px;

}

#camera-selection {
    margin-bottom: 10px;
    width: 100%;
}

#close-scanner {
    margin-top: 10px;
    padding: 8px 12px;
    background: #f44336;
    color: #fff;
    border: none;
    cursor: pointer;
    border-radius: 5px;
    position: absolute;
    right: 0px;
    bottom: 0px;
}

#close-scanner:hover {
    background: #d32f2f;
}

.baohanhdientu_action {
    display: inline-block !important;
}

.baohanhdientu_action,
.baohanhdientu_action1,
.baohanhdientu_submit {
    font-size: 12px;
}

.baohanhdientu_action i {
    display: block !important;
}

.baohanhdientu_formaction i {
    display: block !important;
}

.baohanhdientu_action1 i {
    display: block !important;
}

.baohanhdientu_submit {
    display: inline-block !important;
}

.baohanhdientu_submit i {
    display: block !important;
}

#main {
    padding-bottom: 50px;
}

.page_category #main {
    padding-bottom: 0px;
}

.scroll-to-top {
    display: none !important;
}

.lich_su_thao_tac {
    padding: 20px;
    background: #e5e5e5;
    margin-top: 45px;
    font-size: 13px;
    line-height: 20px;
}

.lich_su_thao_tac p {
    margin: 0px;
}

.textover {
    width: 320px;
    background: transparent;
    height: auto;
    margin-bottom: 0px;
}

.textover1 {
    width: 250px;
    overflow-y: hidden;
    overflow-x: hidden;
    background: transparent;
    height: 40px;
    margin-bottom: -10px;
}

.textover1::-webkit-scrollbar {
    width: 1px;
    /* Remove scrollbar space */

    background: transparent;
    /* Optional: just make scrollbar invisible */
}

table.dataTable td.multiline {
    white-space: normal;
    word-break: break-word;
    line-height: 16px;
    margin: 0px !important;
    padding: 0px 5px !important;
}

.table-wrapper .portlet.portlet-no-padding .portlet-title {
    min-height: 55px;
    margin-bottom: 0;
    z-index: 888;
    padding-left: 11px;
    position: absolute !important;
}

@media (min-width: 992px) {

    .modal-lg,
    .modal-xl {
        max-width: 1500px !important;
    }

    .modal-lg {
        width: 90% !important;
    }

    .modal-dialog {

        margin: 10px auto 30px auto !important;
    }
}

.info_line {
    font-size: 13px;
}

.info_line label {
    width: 150px;
    font-weight: bold;
}

.thanhcong {
    color: #fff;
    background-color: #28a745;
    border-color: #28a745;
    padding: 2px;
    border-radius: 2px;
}

.container-fluid.dt-bootstrap4 {
    max-width: none !important;
    padding: 0 !important;
}

.da_xhd,
.da_ghep {
    color: #0069d9;
}

.cho_ncc {
    color: rgb(218, 122, 0);

}

.ko_hd {
    color: rgb(204, 11, 11);
}

.red {
    color: red;
}

.ClickView.da_ghep {
    color: #fff;
    background: #0069d9;
    padding: 2px;
    border-radius: 2px;
}

.chuyendoima {
    color: #0b98a7;
}

.hoan_thanh {
    color: #28a745;
}

.ClickView.hoan_thanh {
    color: #fff;
    background: #28a745;
    padding: 2px;
    border-radius: 2px;
}

.da_xuat_nhap {
    color: #0b98a7;
}

.ClickView.da_xuat_nhap {
    color: #fff;
    background: #0b98a7;
    padding: 2px;
    border-radius: 2px;
}

#cms-core-page,
#cms-core-media {
    display: none;
}

.status-label1.dang_ban {
    color: #fff;
    background: #28a745;
    padding: 2px;
    border-radius: 2px;
}

.status-label1.dang_ban a {
    color: #fff;
}

.select-search-full-ajax {
    width: 100%;
}

.suggestion-box {
    position: absolute;
    width: 700px;
    max-height: 500px;
    background: #fff;
    border: 1px solid #ddd;
    overflow-y: auto;
    z-index: 999;
    display: none;
}

#suggestion-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.suggestion-item {
    padding: 10px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
}

.l_suggestion-item {
    padding: 10px;
    border-bottom: 1px solid #eee;
    cursor: pointer;
}

.suggestion-item:hover {
    background-color: #f1f1f1;
}

.editable-pre-wrapped {
    white-space: normal !important;
}

.editable-input .form-control {
    height: 34px;
    min-width: 200px;
}

.editable-input textarea.form-control {
    min-height: 250px;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: transparent;
}

.btn.btn-success.btn-themsp {
    position: absolute;
    right: -168px;
    top: 0px;
}

.lech.status-label1 {
    color: red;
}

/* Hiển thị menu con khi di chuột vào menu cha */


.divA,
.ui-select-wrapper {
    float: right;
    position: relative;
    width: calc(100% - 180px);
}

.filter_list .ui-select-wrapper {
    float: left;
}

.ui-select-wrapper .divA {
    float: right;
    width: 100%;
}

.btn-themmoi {
    position: absolute;
    right: 13px;
    top: 1px;
    z-index: 2;
    font-size: 23px;
    cursor: pointer;
    background: #fff;
    color: #28a745;
}

.btn-viewselect {
    position: absolute;
    right: 40px;
    top: 1px;
    z-index: 2;
    font-size: 23px;
    cursor: pointer;
    background: #fff;
    color: #28a745;
}

.suggestion-item img {
    max-width: 40px;
    float: left;
    margin-right: 17px;
}

.suggestion-item span.price {
    color: red;
}

.suggestion-item .compare_at_price {
    text-decoration: line-through;
    color: #ccc;
}

.portlet.light.bordered>.portlet-title {
    border-bottom: 0px solid #eef1f5 !important;
}

.tencongty {
    position: absolute;
    left: 361px;
    top: 12px;
    font-size: 17px;
    color: #e5e5e5e5;
    font-weight: bold;
}

.portlet.light.bordered {
    border: 1px solid #e7ecf1 !important;
    border-radius: 0px;
    background: #fff;
    box-shadow: 0px 0px 3px #ccc;
}

.form-body .control-label {
    font-weight: normal;
    background: transparent;
    width: 176px;
    margin-top: 0px;
    padding-left: 0px;
    border-radius: 5px;
    height: 26px;
    padding-top: 4px;
}

.info_fieldset {
    background: #fff;
    border: 1px solid #e5e5e5 !important;
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
}

.info_legend {
    width: auto;
    padding: 0px 20px;
    margin: 16px 20px;
    font-size: 18px;
    font-weight: bold;
}

.form-control {
    display: block;
    width: 100%;
    height: calc(1.5em + .75rem + 2px);
    padding: .375rem .75rem;
    font-size: 1rem;
    font-weight: 400;
    line-height: 1.5;
    color: #495057;
    background-color: #fff;
    background-clip: padding-box;
    border: 1px solid #ced4da;
    transition: border-color .15s ease-in-out, box-shadow .15s ease-in-out;
}

.ui-select-wrapper {
    border-width: 0px 0px 1px 0px !important;
}

.bootstrap-datetimepicker-widget {
    z-index: 9999 !important;
}

.table.table-bordered thead>tr>th {
    border-bottom: 0;
    background: #e5e5e5;
    color: #000;
    font-weight: bold;
}

.status-label1.dang_thuc_hien,
.ClickView.dang_thuc_hien {
    color: #0a53be;
}

.status-label1.that_bai,
.ClickView.that_bai {
    color: #fff;
    background: #ccc;
    padding: 2px;
    font-weight: normal;
    border-radius: 2px;
}

.status-label1.chuyen_lich,
.ClickView.chuyen_lich {
    color: #fff;
    background: deeppink;
    padding: 2px;
    font-weight: normal;
    border-radius: 2px;
}

.status-label1.thanh_cong,
.ClickView.thanh_cong {
    color: #fff;
    background: var(--primary-color);
    padding: 2px;
    font-weight: normal;
    border-radius: 2px;
}

.status-label1.canhbao {
    color: #fff;
    background: red;
    padding: 2px;
    font-weight: normal;
    border-radius: 2px;
}

.status-label1.kiemtra {
    color: #fff;
    background: rgb(3, 123, 228);
    padding: 2px;
    font-weight: normal;
    border-radius: 2px;
}

.status-label1 i {
    padding-right: 5px;
}

@media (min-width: 992px) {
    .form-actions.form-actions-fixed-bottom {
        padding: 8px 10px;
    }

    #baohanh_modal .form-actions.form-actions-fixed-bottom {
        position: fixed;
        bottom: 0;
        left: 0px !important;
        right: 0;
        z-index: 999;
        background-color: #fff;
        border-bottom: 1px solid #ccc;
        box-shadow: 0px 0px 5px #e5e5e5;
        text-align: right;
        padding: 0px 20px;
        padding-bottom: 0px;
        width: calc(100%) !important;
        border-radius: 4px;
    }

    #baohanh_modal form {
        margin-bottom: 0px;
    }
}

.btn.btn-search {
    background: #ccc;
    font-weight: bold;
}

.btn.btn-search.active {
    background: var(--primary-color);
    color: #fff;
    position: relative;
}

.btn.btn-search.active i {
    color: red;
    position: absolute;
    top: -5px;
    right: -4px;
    cursor: pointer;
}

.mt-radio-list {
    display: flex;
    gap: 8px;
    flex-wrap: wrap
}

.mt-radio-list input[type="radio"] {
    position: absolute;
    /* ẩn nhưng vẫn truy cập được */
    opacity: 0;
    pointer-events: none;
}

.mt-radio-list label {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    user-select: none;
    transition: .15s;
}

.mt-radio-list label:hover {
    border-color: #999
}

.mt-radio-list label:has(input[type="radio"]:checked) {
    border-color: #28a745;
    background: rgba(40, 167, 69, .08);
}

.mt-radio-list label:has(input[type="radio"]:focus-visible) {
    outline: 2px solid #2563eb;
    outline-offset: 2px;
}

.mt-radio-list label:has(input[disabled]) {
    opacity: .6;
    pointer-events: none;
}

.viewlink {
    margin-left: 11px;
}

.textover_t {
    height: auto;
    width: 300px;
    line-height: 15px;
    padding: 5px;
}

.ngung_chay.status-label1 {
    background: #ccc;
    padding: 2px;
    color: #fff;
    border-radius: 3px;
}

.dang_chay.status-label1 {
    background: green;
    padding: 2px;
    color: #fff;
    border-radius: 3px;
}

.status-label1.da_co_sdt,
.ClickView.da_co_sdt {
    background: purple;
    padding: 2px;
    color: #fff;
    border-radius: 3px;
}

.cho_sx.status-label1,
.cho_san_xuat.status-label1,
.cho_giao_hang.status-label1 {
    color: rgb(218, 122, 0);
}

.da_gui_yeu_cau.status-label1 {
    color: rgb(218, 122, 0);
}

.thieu.status-label1 {
    background: red;
    padding: 2px;
    font-weight: normal;
    color: #fff;
    border-radius: 3px;
}

.da_du.status-label1,
.hoan_thanh.status-label1 {
    background: #fff;
    padding: 0px;
    color: green;
    font-weight: normal;
    border-radius: 3px;
}

.status-label1 i {
    padding-right: 0px;
}

.huy.status-label1 {
    background: #ccc;
    padding: 2px;
    color: #fff;
    font-weight: normal;
    border-radius: 3px;
}

.dang_giao_hang.status-label1 {

    color: #0b2880;

}

.kxd {

    font-weight: normal;
    border-radius: 3px;
}

@media (min-width: 768px) {
    .modal-dialog {
        width: 900px;
        min-width: 900px !important;
        margin: 80px auto 30px auto;
    }
}

.f-reload {
    width: 39px;
    text-align: center;
    display: block;
    float: right;
    border: 0px solid #ccc;
    margin-top: 10px;
    border-radius: 4px;
    color: #333;
    margin-right: 0px;
    font-size: 20px;
    height: 35px;
    opacity: 0.7;
}

@media (min-width: 768px) {
    .page-content .breadcrumb {
        margin-bottom: 20px;
        position: absolute;
        top: -46px;
        z-index: 333;
    }
}

.table-wrapper {
    position: relative;
}

.bocloc {
    position: absolute;
    left: 503px;
    top: 11px;
}

/* Button từ thứ 2 trở đi */
.dt-buttons button:nth-child(n+2) span {

    /* Ẩn text node */
}

/* Giữ icon hiển thị */
.dt-buttons button:nth-child(n+2) span i {
    font-size: 14px;
}

.datatables-responsive::-webkit-scrollbar {
    width: 8px;
    height: 4px;
}

.datatables-responsive::-webkit-scrollbar-track {
    background: #f1f1f1;
}

.datatables-responsive::-webkit-scrollbar-thumb {
    background: #bbb;
    border-radius: 4px;
}

.datatables-responsive::-webkit-scrollbar-thumb:hover {
    background: #888;
}

@media (min-width: 992px) {
    .page-content-wrapper .page-content {
        margin-left: 190px;
        margin-top: 0;
        padding: 0px;

    }
}
@media (min-width: 992px) {
    .page-sidebar {
        width: 190px;
        float: left;
        position: relative;
        margin-right: -100%;
    }
}

#import-form {
    display: block;
    align-items: center;
    gap: 12px;
    padding: 16px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, .04);

}

/* input file */
#import-form input[type="file"] {
    padding: 8px;
    border: 1px dashed #16a34a;
    border-radius: 6px;
    background: #f0fdf4;
    cursor: pointer;
    color: #166534;
}

/* nút submit */
#import-form button[type="submit"] {
    padding: 10px 18px;
    border: none;
    border-radius: 6px;
    background: #2563eb;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: background .2s ease;
}

#import-form button[type="submit"]:hover {
    background: #1d4ed8;
}

.portlet.light>.portlet-title>.caption>.caption-subject {
    text-transform: uppercase;
    font-size: 15px;
    display: block;
    padding-top: 0px;
    padding-left: 22px;
    font-weight: bold;
}

@media (max-width: 768px) {
    .table-wrapper .portlet.portlet-no-padding .portlet-title {
        min-height: 55px;
        margin-bottom: 0;
        padding-left: 0px;
        display: block;
        position: relative !important;
    }

    .table-wrapper .portlet.light>.portlet-title>.caption>.caption-subject {
        text-transform: uppercase;
        font-size: 16px;
        display: block;
        padding-top: 0px;
        padding-left: 0px;
        font-weight: bold;
    }

    .page-content .table-responsive .dataTables_wrapper .dataTables_filter {
        max-width: 100%;
        position: relative;
        top: auto;
        width: 100%;
    }

    .top {
        display: block;
        justify-content: right;
    }

    .page-content .table-responsive .dataTables_wrapper .dt-buttons {
        margin-top: 10px;
        float: none;
        margin-right: 10px;
        margin-left: 10px;
    }

    .page-content .table-responsive .dataTables_wrapper .dataTables_filter {
        max-width: 100%;
        position: relative;
        top: auto;
        text-align: left;
        width: 100% !important;
    }

    .dataTables_filter input[type="search"] {
        margin-top: 3px;
        height: 36px;
        width: 100% !important;
        padding-right: 0px;

    }

    div.dataTables_wrapper div.dataTables_filter label {
        font-weight: normal;
        white-space: nowrap;
        text-align: left;
        width: 92%;
    }

    .dataTables_filter label::after {
        font: normal normal normal 14px/1 Font Awesome\ 5 Free;
        font-weight: normal;
        line-height: 1;
        font-weight: normal;
        line-height: 1;
        content: "\F002";
        position: absolute;
        right: 17px;
        top: 6px;
        width: 40px;
        height: 30px;
        line-height: 30px;
        text-align: center;
        color: #495057;
        font-weight: 900;
    }

    .page-content .breadcrumb {
        margin-bottom: 0px;
        display: none;
    }

}

.baohanhdientu_formaction,
.baohanhdientu_submit,
.baohanhdientu_action,
.baohanhdientu_action1,
.baohanhdientu_url,
.baohanhdientu_formaction1 {
    display: flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    /* Ưu tiên thẳng hàng từ trên xuống */
    background: transparent !important;
    border: none !important;
    padding: 0 4px !important;
    width: 85px !important;
    /* Cố định chiều rộng để thẳng hàng dọc */
    min-width: 85px !important;
    color: #4a5568 !important;
    font-size: 11px !important;
    font-weight: 500 !important;
    text-decoration: none !important;
    transition: all 0.2s ease;
    text-align: center;
    white-space: nowrap;
    /* Không cho xuống dòng làm lệch chiều cao */
}

.baohanhdientu_formaction:hover,
.baohanhdientu_action:hover,
.baohanhdientu_action1:hover,
.baohanhdientu_submit:hover {
    transform: translateY(-2px);
    color: #1a202c !important;
}

.baohanhdientu_formaction i,
.baohanhdientu_submit i,
.baohanhdientu_action i,
.baohanhdientu_action1 i,
.baohanhdientu_url i,
.baohanhdientu_formaction1 i {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    width: 31px !important;
    height: 31px !important;
    border-radius: 50% !important;
    color: #fff !important;
    font-size: 14px !important;
    margin-bottom: 3px !important;
    box-shadow: 0 3px 8px rgba(0, 0, 0, 0.12);
    background: #28a745;
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    padding: 0 !important;
    line-height: 1 !important;
    font-style: normal !important;
}

/* Biến thể màu sắc Gradient cho từng hành động */
.baohanhdientu_submit i {
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%) !important;
}

.baohanhdientu_action1 i {
    background: linear-gradient(135deg, #6366f1 0%, #4338ca 100%) !important;
    /* Xanh Indigo cho nút In */
}

/* Lưu */
.baohanhdientu_formaction.datiepnhanh i {
    background: linear-gradient(135deg, #4299e1 0%, #3182ce 100%) !important;
}

/* Tiếp nhận */
.baohanhdientu_formaction.dangthuchien i {
    background: linear-gradient(135deg, #0b2880 0%, #001a4d 100%) !important;
}

/* Thực hiện */
.baohanhdientu_formaction.du_ton_kho i {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%) !important;
}

/* Tồn kho */
.baohanhdientu_formaction.chohangve i {
    background: linear-gradient(135deg, #f6ad55 0%, #ed8936 100%) !important;
}

/* Chờ hàng */
.baohanhdientu_formaction.hoanthanh i {
    background: linear-gradient(135deg, #f56565 0%, #e53e3e 100%) !important;
}

/* Huỷ - dùng đỏ cho nổi bật */
.baohanhdientu_formaction.suathongtin i {
    background: linear-gradient(135deg, #4fd1c5 0%, #38b2ac 100%) !important;
}

/* Sửa */
.baohanhdientu_formaction.cho_xac_nhan_xu_ly i {
    background: linear-gradient(135deg, #a0aec0 0%, #718096 100%) !important;
}

/* Chờ xử lý */
.baohanhdientu_formaction1 i {
    background: linear-gradient(135deg, #1a202c 0%, #2d3748 100%) !important;
}

/* In (Màu tối) */

.baohanhdientu_formaction.hoanthanh[data-value="hoan_thanh"] i {
    background: linear-gradient(135deg, #68d391 0%, #48bb78 100%) !important;
}

/* Hoàn thành thực sự */

.baohanhdientu_formaction:active i {
    transform: scale(0.92);
}

@media (max-width: 992px) {
    .form-actions.form-actions-fixed-bottom {
        text-align: left;
    }

    .form-actions.form-actions-fixed-bottom {
        padding: 0px;
    }
}

@media (min-width: 992px) {

    /* Thiết lập cho container chính chiếm toàn bộ chiều cao màn hình và không scroll tổng */
    .page_category .page-container {
        height: calc(100vh - 50px);
        position: fixed;
        width: 100%;
        z-index: 9;
    }

    /*   .page-sidebar-wrapper {
           position: absolute;
           height: 100%;
           overflow: scroll;
       }
       .page_dashboard .page-content-wrapper .page-content  {
           overflow: scroll;
           position: absolute;
           height: 100%;width: calc(100% - 45px);

       }
    .page_form  .page-content-wrapper .page-content #main  {
           overflow: scroll;
           position: absolute;
           height: 100%;width: calc(100% - 45px);
       }*/

}

.status-label1.ket_thuc,
.ClickView.ket_thuc {
    color: #fff;
    background: #333;
    padding: 2px;
    font-weight: normal;
    border-radius: 2px;
}

.status-label1.dang_thuc_hien,
.ClickView.dang_thuc_hien {
    color: #fff;
    background: #0a53be;
    padding: 2px;
    font-weight: normal;
    border-radius: 2px;
}

/* Tùy chỉnh thanh cuộn cho bảng - Tăng độ dày lên gấp 4 lần */
.datatables-responsive::-webkit-scrollbar {
    height: 32px;
    /* Độ dày thanh cuộn ngang */
    width: 12px;
    /* Độ dày thanh cuộn đứng */
}

.datatables-responsive::-webkit-scrollbar-track {
    background: #f8f9fa;
    border-radius: 16px;
    border: 1px solid #e9ecef;
}

.datatables-responsive::-webkit-scrollbar-thumb {
    background-color: #adb5bd;
    border-radius: 16px;
    border: 6px solid #f8f9fa;
    /* Tạo khoảng đệm xung quanh thanh kéo */
    box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.1);
}

.datatables-responsive::-webkit-scrollbar-thumb:hover {
    background-color: #6c757d;
}

/* Hỗ trợ cho Firefox */
.datatables-responsive {
    scrollbar-width: auto;
    scrollbar-color: #adb5bd #f8f9fa;
}

.mt-radio-list .invalid-feedback {
    display: none;
    width: 100%;
    margin-top: .25rem;
    font-size: 80%;
    color: #dc3545;
    position: absolute;
    bottom: 0px;
}

/* LX Premium UI Standardized Elements */
.lx-dashboard {
    background-color: #f4f6f8;

    padding: 20px;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: #334155;
}

.lx-editable,
.lx-fake-editable {
    color: #2563eb;
    text-decoration: none;
    border-bottom: 1px dashed #93c5fd;
    cursor: pointer;
    transition: all 0.2s;
    font-weight: 500;
}

.lx-editable:hover,
.lx-fake-editable:hover {
    color: #1d4ed8;
    border-bottom-color: #2563eb;
    background: #eff6ff;
}

.lx-editable-empty {
    color: #94a3b8;
    border-bottom-style: dotted;
    font-weight: 400;
    font-style: italic;
}

.lx-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #ffffff;
    padding: 15px 25px;
    border-bottom: 1px solid #e2e8f0;
    margin: -20px -20px 20px -20px;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.lx-toolbar .toolbar-left {
    display: flex;
    align-items: center;
    gap: 15px;
}

.lx-toolbar .toolbar-left .back-btn {
    color: #64748b;
    font-size: 20px;
    cursor: pointer;
    text-decoration: none;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 8px;
    transition: 0.2s;
}

.lx-toolbar .toolbar-left .back-btn:hover {
    background: #f1f5f9;
    color: #0f172a;
}

.lx-toolbar .toolbar-left h4 {
    margin: 0;
    font-weight: 700;
    font-size: 18px;
    color: #0f172a;
    display: flex;
    align-items: center;
    gap: 10px;
}

.lx-toolbar .toolbar-right {
    display: flex;
    align-items: center;
    gap: 10px;
}

.lx-btn {
    font-weight: 600;
    padding: 6px 14px;
    font-size: 13px;
    border-radius: 6px;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: 0.2s;
    border: 1px solid transparent;
}

.lx-btn-primary {
    background: #2563eb;
    color: #fff;
    box-shadow: 0 1px 2px rgba(37, 99, 235, 0.2);
}

.lx-btn-primary:hover {
    background: #1d4ed8;
    color: #fff;
}

.lx-btn-warning {
    background: #f59e0b;
    color: #fff;
    box-shadow: 0 1px 2px rgba(245, 158, 11, 0.2);
}

.lx-btn-warning:hover {
    background: #d97706;
    color: #fff;
}

.lx-btn-success {
    background: #10b981;
    color: #fff;
    box-shadow: 0 1px 2px rgba(16, 185, 129, 0.2);
}

.lx-btn-success:hover {
    background: #059669;
    color: #fff;
}

.lx-btn-danger {
    background: #ef4444;
    color: #fff;
    box-shadow: 0 1px 2px rgba(239, 68, 68, 0.2);
}

.lx-btn-danger:hover {
    background: #b91c1c;
    color: #fff;
}

.lx-btn-info {
    background: #0ea5e9;
    color: #fff;
    box-shadow: 0 1px 2px rgba(14, 165, 233, 0.2);
}

.lx-btn-info:hover {
    background: #0284c7;
    color: #fff;
}

/* ==========================================================
   LARAMERLX PREMIUM CIRCULAR UI (UI Dạng Tròn Nghệ Thuật)
   ========================================================== */
.toolbar-right a.baohanhdientu_formaction,
.toolbar-right a.baohanhdientu_action,
.toolbar-right a.baohanhdientu_action1,
.toolbar-right a.baohanhdientu_url {
    display: inline-flex !important;
    flex-direction: column;
    align-items: center;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    color: #64748b !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    padding: 0 4px !important;
    gap: 6px;
    text-transform: none;
    text-decoration: none;
    min-width: 60px;
    transition: all 0.2s;
}

.toolbar-right a.baohanhdientu_formaction:hover,
.toolbar-right a.baohanhdientu_action:hover,
.toolbar-right a.baohanhdientu_action1:hover {
    transform: translateY(-2px);
    opacity: 0.9;
    color: #1e293b !important;
}

.toolbar-right a.baohanhdientu_formaction i,
.toolbar-right a.baohanhdientu_action i,
.toolbar-right a.baohanhdientu_action1 i,
.toolbar-right a.baohanhdientu_url i {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    color: #fff !important;
    font-size: 13px !important;
    margin: 0 auto;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

/* Colors for Circular Icons & Text */
.toolbar-right a.btn-warning,
.toolbar-right a.lx-btn-warning {
    color: #f59e0b !important;
}

.toolbar-right a.btn-warning i,
.toolbar-right a.lx-btn-warning i {
    background-color: #f59e0b !important;
    color: #fff !important;
}

.toolbar-right a.btn-success,
.toolbar-right a.lx-btn-success {
    color: #10b981 !important;
}

.toolbar-right a.btn-success i,
.toolbar-right a.lx-btn-success i {
    background-color: #10b981 !important;
    color: #fff !important;
}

.toolbar-right a.btn-danger,
.toolbar-right a.lx-btn-danger {
    color: #dc2626 !important;
}

.toolbar-right a.btn-danger i,
.toolbar-right a.lx-btn-danger i {
    background-color: #dc2626 !important;
    color: #fff !important;
}

.toolbar-right a.btn-info,
.toolbar-right a.lx-btn-info {
    color: #3b82f6 !important;
}

.toolbar-right a.btn-info i,
.toolbar-right a.lx-btn-info i {
    background-color: #3b82f6 !important;
    color: #fff !important;
}

.toolbar-right a.btn-primary,
.toolbar-right a.lx-btn-primary {
    color: #0d6efd !important;
}

.toolbar-right a.btn-primary i,
.toolbar-right a.lx-btn-primary i {
    background-color: #0d6efd !important;
    color: #fff !important;
}

.toolbar-right a.btn-purple,
.toolbar-right a.lx-btn-purple {
    color: #8b5cf6 !important;
}

.toolbar-right a.btn-purple i,
.toolbar-right a.lx-btn-purple i {
    background-color: #8b5cf6 !important;
    color: #fff !important;
}

.toolbar-right a.btn-secondary,
.toolbar-right a.lx-btn-secondary {
    color: #64748b !important;
}

.toolbar-right a.btn-secondary i,
.toolbar-right a.lx-btn-secondary i {
    background-color: #64748b !important;
    color: #fff !important;
}



.lx-btn-purple {
    background: #8b5cf6;
    color: #fff;
    box-shadow: 0 1px 2px rgba(139, 92, 246, 0.2);
}

.lx-btn-purple:hover {
    background: #7c3aed;
    color: #fff;
}

.lx-btn-secondary {
    background: #ffffff;
    border-color: #cbd5e1;
    color: #475569;
}

.lx-btn-secondary:hover {
    background: #f8fafc;
    color: #0f172a;
    border-color: #94a3b8;
}

.lx-card {
    background: #ffffff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05), 0 1px 2px rgba(0, 0, 0, 0.03);
    border: 1px solid #e2e8f0;
    overflow: hidden;
}

.lx-card-body {
    padding: 25px;
}

.lx-summary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 60px;
}

.lx-summary-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px dashed #e2e8f0;
}

.lx-summary-item:last-child {
    border-bottom: none;
}

.lx-summary-label {
    color: #64748b;
    font-weight: 500;
    font-size: 13px;
}

.lx-summary-val {
    color: #1e293b;
    font-weight: 600;
    font-size: 14px;
    text-align: right;
}

.lx-payment-box {
    background: #f8fafc;
    border-radius: 6px;
    padding: 15px;
    border: 1px solid #e2e8f0;
}

.lx-payment-row {
    display: flex;
    justify-content: space-between;
    padding: 6px 0;
    font-size: 14px;
    color: #475569;
}

.lx-payment-row.lx-total {
    font-weight: 700;
    font-size: 16px;
    color: #dc2626;
    border-top: 1px solid #e2e8f0;
    padding-top: 10px;
    margin-top: 4px;
}

.lx-payment-val {
    font-weight: 600;
    color: #0f172a;
}

/* Dashboard Tables */
.lx-dashboard table.lx-datatable {
    border-collapse: separate !important;
    border-spacing: 0 !important;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    overflow: hidden;
}

.lx-dashboard table.lx-datatable thead th {
    background: #f8fafc !important;
    padding: 10px 12px !important;
    font-size: 12.5px;
    font-weight: 600;
    color: #475569;
    border-bottom: 1px solid #cbd5e1 !important;
    border-top: none !important;
    white-space: nowrap !important;
}

.lx-dashboard table.lx-datatable tbody td {
    padding: 10px 12px !important;
    font-size: 13px;
    vertical-align: middle !important;
    border-bottom: 1px solid #e2e8f0 !important;
    color: #1e293b;
}

.lx-dashboard table.lx-datatable tbody tr:last-child td {
    border-bottom: none !important;
}

.lx-dashboard table.lx-datatable tbody tr:hover {
    background-color: #f1f5f9 !important;
}

.lx-header-table {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #f8fafc;
    padding: 6px 20px;
    border: 1px solid #e2e8f0;
    border-bottom: none;
    border-radius: 8px 8px 0 0;
    margin-bottom: 0 !important;
    position: relative;
    z-index: 10;
    min-height: 48px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.lx-header-table .control-label {
    font-size: 15px !important;
    font-weight: 700 !important;
    color: #0f172a !important;
    letter-spacing: 0.5px;
    margin: 0 !important;
}

.lx-header-table .lx-btn-group {
    display: flex;
    gap: 8px;
}

.lx-header-table .lx-btn-group .lx-btn-action {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background-color: #2563eb !important;
    border-color: #2563eb !important;
    color: #fff !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    padding: 6px 14px !important;
    border-radius: 4px;
    transition: 0.2s;
    text-decoration: none;
}

.lx-header-table .lx-btn-group .lx-btn-action:hover {
    background-color: #1d4ed8 !important;
    box-shadow: 0 2px 4px rgba(37, 99, 235, 0.2);
}

/* Table Wrapper Elements */
.lx-table-wrapper .dataTables_wrapper {
    border: 1px solid #e2e8f0;
    border-top: none;
    border-radius: 0 0 8px 8px;
    background: #fff;
    padding: 0;
    position: relative;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
}

.lx-table-wrapper .dataTables_wrapper .dataTables_filter {
    position: absolute;
    top: -44px;
    left: 328px;
    z-index: 20;
    margin: 0;
}

.lx-table-wrapper .dataTables_wrapper .dataTables_filter label {
    font-size: 0;
    margin: 0;
}

.lx-table-wrapper .dataTables_wrapper .dataTables_filter input {
    border: 1px solid #cbd5e1;
    border-radius: 20px;
    padding: 5px 15px 5px 35px;
    margin: 0;
    vertical-align: middle;
    outline: none;
    transition: all .3s;
    width: 220px;
    font-size: 13px;
    background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%2394a3b8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='11' cy='11' r='8'%3E%3C/circle%3E%3Cline x1='21' y1='21' x2='16.65' y2='16.65'%3E%3C/line%3E%3C/svg%3E") no-repeat 12px center;
}

.lx-table-wrapper .dataTables_wrapper .dataTables_filter input:focus {
    border-color: #36c6d3;
    box-shadow: 0 0 0 2px rgba(54, 198, 211, 0.2);
    width: 260px;
}

@media (max-width: 768px) {
    .lx-table-wrapper .dataTables_wrapper .dataTables_filter {
        position: static;
        width: 100%;
        margin-bottom: 15px;
        padding: 10px 15px 0 15px;
        text-align: left;
        box-sizing: border-box;
    }

    .lx-table-wrapper .dataTables_wrapper .dataTables_filter label {
        display: block;
        width: 100%;
        box-sizing: border-box;
    }

    .lx-table-wrapper .dataTables_wrapper .dataTables_filter input {
        width: 100%;
        box-sizing: border-box;
    }

    .lx-table-wrapper .dataTables_wrapper .dataTables_filter input:focus {
        width: 100%;
        box-sizing: border-box;
    }

    .lx-table-wrapper .dataTables_wrapper .dataTables_info {
        float: none !important;
        text-align: center !important;
        margin-bottom: 10px !important;
        padding-top: 10px !important;
    }

    .lx-table-wrapper .dataTables_wrapper .dataTables_paginate {
        float: none !important;
        text-align: center !important;
        display: flex;
        justify-content: center;
        padding-bottom: 15px !important;
    }
}

.lx-table-wrapper .dataTables_wrapper .dataTables_length {
    margin: 15px;
}

.lx-table-wrapper .dataTables_wrapper .dataTables_info,
.lx-table-wrapper .dataTables_wrapper .dataTables_paginate {
    color: #475569 !important;
    font-size: 13.5px;
}

/* Modifier to remove default datatable style */
.lx-table-wrapper table.lx-datatable {
    border-radius: 0 !important;
    border-left: none !important;
    border-right: none !important;
    margin-top: 0 !important;
}

/* Customizing Input Wrapper & QR Code & Them SP Button - NO HTML CHANGE REQUIRED */
.lx-dashboard .qr-code-input {
    display: flex;
    align-items: center;
    gap: 15px;
    /* Keeps nice distance between input and button */
    max-width: none !important;
    /* Removes earlier 300px restriction */
    width: 100%;
}

.lx-dashboard .qr-code-input input#themtem {
    width: 300px !important;
    min-width: 300px;
    flex: none;
    /* Fixed width */
    margin-bottom: 0 !important;
    height: 36px !important;
}

.lx-dashboard .qr-code-input .qr-icon {
    position: absolute !important;
    left: 270px !important;
    /* Pin internally to the 300px input */
    right: auto !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    color: #2563eb !important;
    /* Matches theme */
    display: flex;
    align-items: center;
    justify-content: center;
    pointer-events: none;
    /* Make click trigger input perfectly */
}

.lx-dashboard .qr-code-input .suggestion-box {
    top: 100% !important;
    left: 0 !important;
    width: 300px !important;
    /* Match input width accurately */
}

.lx-dashboard .qr-code-input .btn.btn-themsp {
    position: static !important;
    /* Discards old rigid absolute pos */
    background-color: #2563eb !important;
    border-color: #2563eb !important;
    color: #fff !important;
    height: 38px !important;
    line-height: normal !important;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    margin: 0 !important;
    box-shadow: 0 1px 2px rgba(37, 99, 235, 0.2) !important;
    border-radius: 6px;
    padding: 0 16px !important;
    font-weight: 600;
}

.lx-dashboard .qr-code-input .btn.btn-themsp:hover {
    background-color: #1d4ed8 !important;
}

/* Soft badge utility */
.lx-badge-soft-primary {
    background: #dbeafe;
    color: #1e40af;
    padding: 4px 8px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 11px;
}

/* Mobile query */
@media (max-width: 768px) {
    .lx-dashboard {
        padding: 10px;
        margin: -10px;
    }

    .lx-toolbar {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
        padding: 15px;
        margin: -10px -10px 15px -10px;
    }

    .lx-toolbar .toolbar-right {
        flex-wrap: wrap;
    }

    .lx-summary-grid {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .lx-card-body {
        padding: 15px;
    }

    .lx-header-table {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        height: auto;
        padding: 12px 15px;
    }

    .lx-header-table .lx-btn-group {
        align-self: flex-start;
    }

    .lx-table-wrapper .dataTables_wrapper .dataTables_filter {
        position: static;
        margin: 15px;
        float: none;
        text-align: left;
    }

    .lx-table-wrapper .dataTables_wrapper .dataTables_filter label {
        justify-content: flex-start;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
    }

    .lx-table-wrapper .dataTables_wrapper .dataTables_filter input {
        width: 100%;
        min-width: 100%;
        margin-left: 0;
    }

    .lx-table-wrapper .dataTables_wrapper .dataTables_filter input:focus {
        width: 100%;
    }

    .qr-code-input {
        display: flex;
        flex-direction: column;
        gap: 10px;
    }

    .qr-code-input .btn-themsp {
        width: 100%;
        text-align: center;
        position: static !important;
    }
}

/* ==========================================================
   LARAMERLX MOBILE OPTIMIZATION
   ========================================================== */
@media (max-width: 767px) {

    /* 1. HIDE LOGO AND MOVE TOGGLERS TO TOOLBAR ROW */
    body.lx-has-dashboard .page-header.navbar {
        min-height: 0 !important;
        height: 0 !important;
        border: none !important;
        background: transparent !important;
    }

    body.lx-has-dashboard .page-header.navbar .page-logo,
    body.lx-has-dashboard .page-header.navbar .top-menu {
        display: none !important;
    }

    body.lx-has-dashboard .page-content-wrapper .page-content {
        padding-top: 5px !important;
    }

    /* Remove togglers from old header entirely */
    body.lx-has-dashboard .page-header.navbar .responsive-toggler,
    body.lx-has-dashboard .page-header.navbar .f-reload {
        display: none !important;
    }

    /* Style new HTML native togglers */
    body.lx-has-dashboard .lx-mobile-togglers {
        display: flex !important;
        align-items: center;
        gap: 20px;
    }

    body.lx-has-dashboard .lx-mobile-togglers a {
        color: #333;
        font-size: 20px;
        text-decoration: none;
    }

    /* 2. RE-CSS KHUNG BÁO GIÁ ĐỂ KHÔNG CĂN LỀ VÀ NỀN ĐẸP HƠN */
    body.lx-has-dashboard .lx-dashboard {
        background: #fff;
        margin: -15px -15px 0 -15px !important;
        /* touches edges */
        padding: 0 !important;
    }

    body.lx-has-dashboard .lx-toolbar {
        padding: 10px !important;
        /* Giảm padding tiêu đề */
        background: #fff;
        border-bottom: 1px solid #e2e8f0;
        margin: 0 !important;
        border-radius: 0;
        display: block;
    }

    body.lx-has-dashboard .lx-toolbar .toolbar-left h4 {
        margin: 0;
        font-size: 16px;
    }

    body.lx-has-dashboard .lx-toolbar .toolbar-right {
        margin-top: 10px;
        padding-top: 10px;
        border-top: 1px dashed #e2e8f0;
        justify-content: flex-start;
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
    }

    body.lx-has-dashboard .lx-card {
        margin: 0 !important;
        border-radius: 0 !important;
        border: none !important;
        box-shadow: none !important;
        background: transparent !important;
    }

    body.lx-has-dashboard .lx-card-body {
        padding: 10px !important;
        /* Giảm padding thẻ body */
    }

    body.lx-has-dashboard .lx-summary-grid {
        background: transparent !important;
        border-radius: 0;
        padding: 0;
        /* Xóa lề đôi do lx-card-body đã có */
        box-shadow: none;
        border: none;
        display: flex;
        flex-direction: column;
    }

    body.lx-has-dashboard .col-left,
    body.lx-has-dashboard .col-right {
        width: 100% !important;
        padding: 0 !important;
        border: none !important;
    }

    body.lx-has-dashboard .lx-summary-item {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        padding: 7px 0;
        /* Giảm khoảng cách */
        border-bottom: 1px dotted #cbd5e1;
        min-height: auto;
    }

    body.lx-has-dashboard .lx-summary-label {
        color: #64748b;
        font-size: 13px;
        margin-bottom: 0;
        width: 40%;
        text-align: left;
    }

    body.lx-has-dashboard .lx-summary-val {
        width: 60%;
        text-align: right;
        font-size: 14px;
        font-weight: 500;
        color: #1e293b;
    }

    body.lx-has-dashboard .lx-payment-box {
        margin-top: 10px;
        padding: 15px 0;
        border-radius: 0;
        background: transparent !important;
        /* Bỏ màu nền */
        border: none;
        border-top: 1px dashed #cbd5e1;
    }

    body.lx-has-dashboard .lx-table-wrapper table.lx-datatable td,
    body.lx-has-dashboard .lx-table-wrapper table.lx-datatable th,
    body.lx-has-dashboard .lx-table-wrapper table.dataTable td,
    body.lx-has-dashboard .lx-table-wrapper table.dataTable th {
        white-space: nowrap !important;
    }


    /* Mở rộng bảng tràn viền (Edge-to-edge) */
    body.lx-has-dashboard .l_table_app {
        border: none !important;
        border-radius: 0 !important;
        margin-left: -10px !important;
        margin-right: -10px !important;
        padding-left: 0 !important;
        padding-right: 0 !important;
        background: transparent !important;
    }

    body.lx-has-dashboard .l_table_app>label,
    body.lx-has-dashboard .l_table_app>span,
    body.lx-has-dashboard .l_table_app>.qr-code-input {
        padding-left: 10px !important;
        padding-right: 10px !important;
    }

    /* Unstick blockages: Any parent with overflow hidden destroys position: sticky */
    body.lx-has-dashboard .page-content-wrapper,
    body.lx-has-dashboard .page-content,
    body.lx-has-dashboard #main,
    body.lx-has-dashboard .lx-dashboard,
    body.lx-has-dashboard .lx-card,
    body.lx-has-dashboard .lx-card-body,
    body.lx-has-dashboard .l_table_app {
        overflow: visible !important;
    }

    body.lx-has-dashboard .lx-header-table {
        padding: 10px !important;
        margin-bottom: 0 !important;
        position: -webkit-sticky !important;
        /* Dành cho iOS */
        position: sticky !important;
        top: 0 !important;
        z-index: 50 !important;
        background: #fff !important;
        border-bottom: 1px dashed #cbd5e1 !important;
        box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
        /* Bóng nhẹ */
    }

    body.lx-has-dashboard .lx-table-wrapper {
        border-radius: 0 !important;
        border-left: none !important;
        border-right: none !important;
        border-bottom: 1px solid #e2e8f0 !important;
        border-top: 1px dashed #cbd5e1 !important;
    }

    body.lx-has-dashboard .lx-table-wrapper th,
    body.lx-has-dashboard .lx-table-wrapper td {
        border-left: none !important;
        border-right: none !important;
    }
}

/* Kích thước cột Đa dòng trên mọi thiết bị (đặc biệt là Desktop) */
@media (min-width: 768px) {
    body.lx-has-dashboard table td.multiline {
        white-space: normal !important;
        max-width: 250px !important;
        min-width: 150px !important;
        word-break: break-word !important;
    }
}

/* =====================================================================
   LX POPUP MODAL FORM - Style chuyÃªn nghiá»‡p (dÃ¹ng chung)
   Ãp dá»¥ng tá»± Ä‘á»™ng cho #formview_modal khi load form AJAX
   ===================================================================== */

/* Modal header */
#formview_modal .modal-header.bg-info {
    background: linear-gradient(135deg, #1e3a5f 0%, #2563eb 100%) !important;
    padding: 14px 20px;
    border-bottom: none;
}

#formview_modal .modal-title strong {
    color: #fff;
    font-size: 15px;
    font-weight: 600;
    letter-spacing: 0.3px;
}

#formview_modal .modal-header .close {
    color: rgba(255, 255, 255, 0.85) !important;
    text-shadow: none !important;
    opacity: 1;
    font-size: 22px;
}

#formview_modal .modal-header .close:hover {
    color: #fff !important;
    opacity: 1;
}

/* Modal body: scrollable, padding há»£p lÃ½ */
#formview_modal .modal-body.with-padding {
    max-height: calc(100vh - 220px);
    overflow-y: auto;
    overflow-x: hidden;
    padding: 20px 25px;
    background: #fff;
}

/* áº¨n breadcrumb vÃ  page title khÃ´ng cáº§n trong popup */
#formview_modal .page-bar,
#formview_modal .page-breadcrumb,
#formview_modal .breadcrumb,
#formview_modal .page-title {
    display: none !important;
}

/* áº¨n sidebar panel (col-md-3 chá»©a nÃºt Xuáº¥t báº£n) trong popup */
#formview_modal .col-md-3.col-sm-12 .panel.panel-default {
    display: none !important;
}

/* Má»Ÿ rá»™ng pháº§n form chÃ­nh chiáº¿m toÃ n bá»™ chiá»u rá»™ng trong popup */
#formview_modal .col-md-9.col-sm-12 {
    width: 100% !important;
    flex: 0 0 100% !important;
    max-width: 100% !important;
}

/* áº¨n form-actions gá»‘c (Ä‘Ã£ chuyá»ƒn xuá»‘ng footer) */
#formview_modal .modal-body .form-actions.lx-moved {
    display: none !important;
}

/* Modal footer: nÃºt lÆ°u cá»‘ Ä‘á»‹nh á»Ÿ dÆ°á»›i cÃ¹ng */
#formview_modal .modal-footer {
    padding: 12px 20px;
    border-top: 1px solid #e2e8f0;
    background: #f8fafc;
    display: flex !important;
    justify-content: flex-end;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    border-radius: 0 0 4px 4px;
    min-height: 58px;
}

/* NÃºt trong footer */
#formview_modal .modal-footer .btn {
    min-width: 110px;
    font-weight: 600;
    border-radius: 6px;
    font-size: 13px;
    padding: 8px 22px;
    transition: all 0.2s ease;
}

#formview_modal .modal-footer .btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(0, 0, 0, 0.15);
}

#formview_modal .modal-footer .btn-primary,
#formview_modal .modal-footer .btn-success {
    background: linear-gradient(135deg, #2563eb, #1d4ed8);
    border-color: #1d4ed8;
    color: #fff;
}

#formview_modal .modal-footer .btn-primary:hover,
#formview_modal .modal-footer .btn-success:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af);
    border-color: #1e40af;
}

/* Scrollbar nháº¹ cho modal body */
#formview_modal .modal-body.with-padding::-webkit-scrollbar {
    width: 5px;
}

#formview_modal .modal-body.with-padding::-webkit-scrollbar-track {
    background: #f1f5f9;
}

#formview_modal .modal-body.with-padding::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
}

/* =====================================================================
   LX FORM POPUP WRAP â€” style cho custom form template (tietkiem/forms.blade.php)
   ===================================================================== */

/* Container chÃ­nh cá»§a form trong popup */
#formview_modal .lx-form-popup-wrap {
    padding: 5px 0;
}

/* áº¨n form-actions gá»‘c (Ä‘Ã£ move lÃªn modal-footer báº±ng JS) */
#formview_modal .form-actions.form-actions-default {
    display: none !important;
}

/* Style nÃºt LÆ°u trong modal-footer */
#formview_modal .modal-footer .lx-modal-save-btn,
#formview_modal .modal-footer .lx-submit-btn {
    background: linear-gradient(135deg, #2563eb, #1d4ed8) !important;
    border-color: #1d4ed8 !important;
    color: #fff !important;
    min-width: 120px;
    font-weight: 600;
    font-size: 14px;
    padding: 9px 24px;
    border-radius: 6px;
    letter-spacing: 0.3px;
    transition: all 0.2s ease;
    box-shadow: 0 2px 8px rgba(37, 99, 235, 0.3);
}

#formview_modal .modal-footer .lx-modal-save-btn:hover,
#formview_modal .modal-footer .lx-submit-btn:hover {
    background: linear-gradient(135deg, #1d4ed8, #1e40af) !important;
    transform: translateY(-1px);
    box-shadow: 0 4px 14px rgba(37, 99, 235, 0.4);
}

/* main-form trong popup: bá» shadow thá»«a */
#formview_modal .lx-form-popup-wrap .main-form {
    box-shadow: none !important;
    border: none !important;
    margin-bottom: 0 !important;
}

/* Label Ä‘áº¹p hÆ¡n trong popup */
#formview_modal .control-label {
    font-weight: 600;
    font-size: 13px;
    color: #374151;
    margin-bottom: 4px;
}

/* Input spacing trong popup */
#formview_modal .form-group,
#formview_modal .form-body>div {
    margin-bottom: 14px;
}

/* =====================================================================
   MOBILE: formview_modal chiáº¿m toÃ n mÃ n hÃ¬nh
   NÃºt Ä‘Ã³ng: mÅ©i tÃªn quay láº¡i thay vÃ¬ dáº¥u x
   ===================================================================== */

@media (max-width: 767px) {

    /* Modal chiáº¿m toÃ n mÃ n hÃ¬nh */
    #formview_modal .modal-dialog {
        margin: 0 !important;
        width: 100% !important;
        max-width: 100% !important;
        height: 100% !important;
        min-height: 100vh !important;
    }

    #formview_modal .modal-content {
        border-radius: 0 !important;
        height: 100vh !important;
        display: flex;
        flex-direction: column;
        border: none !important;
    }

    /* Body chiáº¿m pháº§n cÃ²n láº¡i, scroll Ä‘Æ°á»£c */
    #formview_modal .modal-body.with-padding {
        flex: 1;
        max-height: none !important;
        overflow-y: auto !important;
        -webkit-overflow-scrolling: touch;
        padding: 16px !important;
    }

    /* Footer cá»‘ Ä‘á»‹nh á»Ÿ Ä‘Ã¡y */
    #formview_modal .modal-footer {
        flex-shrink: 0;
        padding: 10px 16px !important;
    }

    /* Header full width */
    #formview_modal .modal-header.bg-info {
        border-radius: 0 !important;
        padding: 12px 16px !important;
    }

    /* NÃºt back (â†) lá»›n hÆ¡n trÃªn mobile */
    #formview_modal .lx-modal-back-btn {
        font-size: 20px !important;
        padding: 0 6px;
    }
}

/* NÃºt Ä‘Ã³ng dáº¡ng mÅ©i tÃªn (táº¥t cáº£ mÃ n hÃ¬nh) */
#formview_modal .modal-header .close {
    display: none !important;
    /* áº¨n nÃºt X gá»‘c */
}

#formview_modal .lx-modal-back-btn {
    background: none;
    border: none;
    color: rgba(255, 255, 255, 0.9);
    font-size: 18px;
    cursor: pointer;
    padding: 0 8px;
    line-height: 1;
    transition: color 0.2s;
    margin-left: auto;
}

#formview_modal .lx-modal-back-btn:hover {
    color: #fff;
}

/* Fix: Hiá»‡n láº¡i nÃºt Ã— gá»‘c (bá» display:none trÆ°á»›c) */
#formview_modal .modal-header .close {
    display: block !important;
    color: rgba(255, 255, 255, 0.85) !important;
    text-shadow: none !important;
    opacity: 1;
    font-size: 22px;
}

#formview_modal .modal-header .close:hover {
    color: #fff !important;
    opacity: 1;
}

/* Icon back â† bÃªn trÃ¡i tiÃªu Ä‘á» */
#formview_modal .lx-modal-back-icon {
    cursor: pointer;
    color: rgba(255, 255, 255, 0.9);
    font-size: 16px;
    margin-right: 10px;
    padding: 2px 6px;
    border-radius: 4px;
    transition: background 0.15s, color 0.15s;
    display: inline-block;
    vertical-align: middle;
}

#formview_modal .lx-modal-back-icon:hover {
    background: rgba(255, 255, 255, 0.15);
    color: #fff;
}

/* áº¨n icon cá»­a sá»• .til_img gá»‘c */
#formview_modal .til_img {
    display: none !important;
}

/* =====================================================================
   LX POPUP FORM: Layout 2 cá»™t, label trÃ¡i - input pháº£i
   ===================================================================== */

/* Grid 2 cá»™t cho form-body trong popup */
#formview_modal .lx-form-popup-wrap .form-body {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4px 20px;
}

/* Má»—i form-group: label trÃ¡i (cá»‘ Ä‘á»‹nh), input chiáº¿m pháº§n cÃ²n láº¡i */
#formview_modal .lx-form-popup-wrap .form-group {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px !important;
}

#formview_modal .lx-form-popup-wrap .form-group .control-label {
    width: 130px;
    min-width: 130px;
    flex-shrink: 0;
    margin-bottom: 0 !important;
    font-weight: 600;
    font-size: 13px;
    color: #374151;
    text-align: right;
}

#formview_modal .lx-form-popup-wrap .form-group>div,
#formview_modal .lx-form-popup-wrap .form-group .ui-select-wrapper,
#formview_modal .lx-form-popup-wrap .form-group input.form-control,
#formview_modal .lx-form-popup-wrap .form-group select.form-control,
#formview_modal .lx-form-popup-wrap .form-group textarea.form-control {
    flex: 1;
    min-width: 0;
    margin-bottom: 0 !important;
}

/* Chiá»u cao input gá»n hÆ¡n */
#formview_modal .lx-form-popup-wrap .form-group input.form-control,
#formview_modal .lx-form-popup-wrap .form-group select.form-control {
    height: 34px;
    padding: 4px 10px;
    font-size: 13px;
}

/* NhÃ£n báº¯t buá»™c * */
#formview_modal .lx-form-popup-wrap .form-group .control-label .required {
    color: #ef4444;
    margin-left: 2px;
}

/* CÃ¡c field cáº§n chiáº¿m toÃ n bá»™ hÃ ng (textarea, ghi chÃº) */
#formview_modal .lx-form-popup-wrap .form-group.lx-full-row {
    grid-column: 1 / -1;
}

/* Textarea */
#formview_modal .lx-form-popup-wrap .form-group textarea.form-control {
    height: auto !important;
    min-height: 70px;
    padding: 8px 10px;
}

/* Error message */
#formview_modal .lx-form-popup-wrap .form-group small.help-block,
#formview_modal .lx-form-popup-wrap .form-group .text-danger {
    font-size: 11px;
    display: block;
    margin-top: 2px;
}

/* Mobile: 1 cá»™t, label trÃªn */
@media (max-width: 767px) {
    #formview_modal .lx-form-popup-wrap .form-body {
        grid-template-columns: 1fr;
    }

    #formview_modal .lx-form-popup-wrap .form-group {
        flex-direction: column;
        align-items: flex-start;
    }

    #formview_modal .lx-form-popup-wrap .form-group .control-label {
        width: 100%;
        text-align: left;
        min-width: unset;
    }
}

/* =====================================================================
   LX POPUP FORM LAYOUT v2 â€” Form horizontal: label trÃ¡i, input pháº£i
   Gá»n, sáº¡ch, dá»… Ä‘á»c â€” 1 cá»™t, label cá»‘ Ä‘á»‹nh 150px
   ===================================================================== */

/* Bá» grid 2 cá»™t (Ä‘Ã£ thÃªm á»Ÿ CSS trÆ°á»›c) */
#formview_modal .lx-form-popup-wrap .form-body {
    display: block !important;
    grid-template-columns: unset !important;
}

/* Má»—i form-group: flex row â€” label trÃ¡i cá»‘ Ä‘á»‹nh, input pháº£i */
#formview_modal .lx-form-popup-wrap .form-group {
    display: flex !important;
    align-items: flex-start !important;
    gap: 0 !important;
    margin-bottom: 8px !important;
    flex-wrap: nowrap;
    min-height: 36px;
}

/* Label: cá»™t trÃ¡i cá»‘ Ä‘á»‹nh 150px, text cÄƒn pháº£i */
#formview_modal .lx-form-popup-wrap .form-group>label.control-label,
#formview_modal .lx-form-popup-wrap .form-group>.control-label:first-child {
    width: 150px !important;
    min-width: 150px !important;
    max-width: 150px !important;
    flex-shrink: 0 !important;
    text-align: right !important;
    padding-right: 12px !important;
    padding-top: 6px !important;
    margin-bottom: 0 !important;
    font-weight: 600 !important;
    font-size: 13px !important;
    color: #374151 !important;
    line-height: 1.4;
}

/* Input: chiáº¿m pháº§n cÃ²n láº¡i */
#formview_modal .lx-form-popup-wrap .form-group>input,
#formview_modal .lx-form-popup-wrap .form-group>select,
#formview_modal .lx-form-popup-wrap .form-group>textarea,
#formview_modal .lx-form-popup-wrap .form-group>div:not(.control-label) {
    flex: 1 !important;
    min-width: 0 !important;
    margin-bottom: 0 !important;
    width: auto !important;
}

/* Chiá»u cao input Ä‘á»u nhau */
#formview_modal .lx-form-popup-wrap .form-group input.form-control,
#formview_modal .lx-form-popup-wrap .form-group select.form-control {
    height: 34px !important;
    padding: 5px 10px !important;
    font-size: 13px !important;
    width: 100%;
}

/* Textarea */
#formview_modal .lx-form-popup-wrap .form-group textarea.form-control {
    height: auto !important;
    min-height: 70px;
    margin-bottom: 0 !important;
    width: 100%;
    font-size: 13px;
}

/* Radio / checkbox custom */
#formview_modal .lx-form-popup-wrap .form-group .radio,
#formview_modal .lx-form-popup-wrap .form-group .checkbox {
    margin: 0 !important;
    padding-top: 5px;
}

/* ThÃ´ng bÃ¡o lá»—i validation */
#formview_modal .lx-form-popup-wrap .form-group small.help-block {
    font-size: 11px;
    color: #dc2626;
    margin-top: 3px;
    display: block;
}

/* Divider nháº¹ giá»¯a cÃ¡c nhÃ³m cho dá»… nhÃ¬n */
#formview_modal .lx-form-popup-wrap .form-group {
    border-bottom: 1px solid #f1f5f9;
    padding-bottom: 8px;
}

#formview_modal .lx-form-popup-wrap .form-group:last-child {
    border-bottom: none;
}

/* Mobile: stacked */
@media (max-width: 767px) {
    #formview_modal .lx-form-popup-wrap .form-group {
        flex-direction: column !important;
        align-items: flex-start !important;
    }

    #formview_modal .lx-form-popup-wrap .form-group>label.control-label,
    #formview_modal .lx-form-popup-wrap .form-group>.control-label:first-child {
        width: 100% !important;
        min-width: unset !important;
        text-align: left !important;
        padding-right: 0 !important;
        padding-top: 0 !important;
        padding-bottom: 4px !important;
    }
}

/* Reset CSS flex sai Ä‘Ã£ thÃªm trÆ°á»›c (khÃ´ng dÃ¹ng flex cho form-group trong popup ná»¯a) */
#formview_modal .lx-form-popup-wrap .form-body {
    display: block !important;
}

#formview_modal .lx-form-popup-wrap .form-group {
    display: block !important;
    margin-bottom: 12px !important;
    border-bottom: none !important;
    padding-bottom: 0 !important;
    overflow: hidden;
    /* clearfix cho divA float */
}

/* Label dÃ¹ng style máº·c Ä‘á»‹nh cá»§a há»‡ thá»‘ng (khÃ´ng override flex) */
#formview_modal .lx-form-popup-wrap .form-group>label.control-label,
#formview_modal .lx-form-popup-wrap .form-group>.control-label {
    display: block !important;
    width: 180px !important;
    min-width: unset !important;
    max-width: unset !important;
    float: left !important;
    text-align: right !important;
    padding-right: 10px !important;
    padding-top: 6px !important;
    margin-bottom: 0 !important;
    font-size: 13px !important;
    font-weight: 600 !important;
    color: #374151 !important;
}

/* Fix X-Editable Popover bị ẩn sau Bootstrap Modal */
.editable-container.popover {
    z-index: 99999 !important;
}

/* Đảm bảo Select2 bên trong Popover cũng nổi lên trên */
.select2-container--open {
    z-index: 10001 !important;
}
/* ============================================================
   TikTok Shop Plugin — CSS riêng
   ============================================================ */

/* Row click cursor & hover */
.dataTable tbody tr[data-edit-url] {
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.dataTable tbody tr[data-edit-url]:hover {
    background: #f0f9ff !important;
}

/* Product image thumbnail */
.dataTable tbody tr td img {
    border: 1px solid #e2e8f0;
    box-shadow: 0 1px 2px rgba(0,0,0,0.06);
}

/* Badge status refinements */
.badge.bg-success {
    background-color: #22c55e !important;
}
.badge.bg-danger {
    background-color: #ef4444 !important;
}
.badge.bg-warning {
    background-color: #f59e0b !important;
    color: #1a1a1a !important;
}
.badge.bg-secondary {
    background-color: #94a3b8 !important;
}

/* ============================================================
   Product Edit View — inside iframe
   ============================================================ */
.tts-product-edit .card {
    border: none;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
    border-radius: 8px;
    margin-bottom: 16px;
}

.tts-product-edit .card-header {
    background: linear-gradient(135deg, #1a1a2e, #16213e);
    color: #fff;
    border-radius: 8px 8px 0 0 !important;
    padding: 10px 16px;
}

.tts-product-edit .card-header h5 {
    margin: 0;
    font-size: 14px;
    font-weight: 600;
}

.tts-product-edit .info-table {
    width: 100%;
}

.tts-product-edit .info-table td {
    padding: 8px 12px;
    vertical-align: top;
    border-bottom: 1px solid #f1f5f9;
}

.tts-product-edit .info-table td.label-col {
    width: 35%;
    color: #64748b;
    font-weight: 500;
    font-size: 13px;
}

.tts-product-edit .info-table td.value-col {
    color: #1e293b;
    font-size: 13px;
}

.tts-product-edit .product-image-main {
    max-width: 100%;
    max-height: 300px;
    object-fit: contain;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
}

.tts-product-edit .status-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tts-product-edit .status-badge.active {
    background: #dcfce7;
    color: #166534;
}

.tts-product-edit .status-badge.inactive {
    background: #f1f5f9;
    color: #475569;
}

.tts-product-edit .status-badge.draft {
    background: #fef3c7;
    color: #92400e;
}

.tts-product-edit .status-badge.deleted {
    background: #fee2e2;
    color: #991b1b;
}

.tts-product-edit .raw-data-pre {
    background: #1e293b;
    color: #e2e8f0;
    padding: 16px;
    border-radius: 6px;
    font-size: 12px;
    max-height: 400px;
    overflow-y: auto;
    white-space: pre-wrap;
    word-break: break-all;
}

/* Price highlight */
.tts-price {
    font-size: 18px;
    font-weight: 700;
    color: #dc2626;
}

/* Stock indicator */
.tts-stock-ok {
    color: #16a34a;
    font-weight: 600;
}

.tts-stock-out {
    color: #dc2626;
    font-weight: 600;
}

/* ============================================================
   LX Layout System — đồng bộ phong cách hppcrm
   ============================================================ */

/* Dashboard wrapper */
.lx-dashboard {
    background-color: #f4f6f9;
    margin: -20px;
    padding: 20px;
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    min-height: calc(100vh - 60px);
}

/* Toolbar */
.lx-toolbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    padding: 12px 20px;
    border-bottom: 1px solid #e0e0e0;
    margin: -20px -20px 20px -20px;
}

.lx-toolbar .toolbar-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.lx-toolbar .toolbar-left .back-btn {
    color: #555;
    font-size: 18px;
    text-decoration: none;
    transition: color 0.2s;
}

.lx-toolbar .toolbar-left .back-btn:hover {
    color: #0369a1;
}

.lx-toolbar .toolbar-left h4 {
    margin: 0;
    font-weight: 600;
    font-size: 18px;
    color: #1a1a1a;
}

.lx-toolbar .toolbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Card */
.lx-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

.lx-card-body {
    padding: 20px;
}

/* Summary Grid — layout 2 cột */
.lx-summary-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0 30px;
}

.lx-summary-grid .col-left,
.lx-summary-grid .col-right {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.lx-summary-item {
    display: flex;
    align-items: flex-start;
    padding: 6px 0;
    border-bottom: 1px solid #f1f5f9;
}

.lx-summary-item:last-child {
    border-bottom: none;
}

.lx-summary-label {
    flex: 0 0 140px;
    font-size: 12px;
    color: #7f8c8d;
    font-weight: 500;
    padding-top: 6px;
}

.lx-summary-val {
    flex: 1;
}

.lx-summary-val .form-control-sm {
    font-size: 13px;
    padding: 4px 8px;
    border: 1px solid #e2e8f0;
    border-radius: 4px;
    transition: border-color 0.2s;
}

.lx-summary-val .form-control-sm:focus {
    border-color: #0369a1;
    box-shadow: 0 0 0 2px rgba(3, 105, 161, 0.1);
}

/* Badge */
.lx-badge-soft-primary {
    display: inline-block;
    padding: 3px 10px;
    font-size: 12px;
    font-weight: 600;
    color: #0369a1;
    background: #e0f2fe;
    border-radius: 4px;
    margin-left: 6px;
}

/* Buttons */
.lx-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 16px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 6px;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.lx-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.12);
}

.lx-btn-primary {
    background: linear-gradient(135deg, #0369a1, #0284c7);
    color: #fff;
}

.lx-btn-primary:hover {
    background: linear-gradient(135deg, #075985, #0369a1);
    color: #fff;
}

.lx-btn-secondary {
    background: #f1f5f9;
    color: #475569;
}

.lx-btn-secondary:hover {
    background: #e2e8f0;
    color: #1e293b;
}

/* Header table section */
.lx-header-table {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

/* Responsive */
@media (max-width: 768px) {
    .lx-summary-grid {
        grid-template-columns: 1fr;
    }

    .lx-toolbar {
        flex-direction: column;
        gap: 10px;
        align-items: flex-start;
    }

    .lx-toolbar .toolbar-right {
        width: 100%;
        justify-content: flex-end;
    }
}
.breadcrumb{
    display: none;
}
.top {
    display: flex;
    justify-content: left;
    padding-top: 11px;
    height: 46px;
    overflow: visible;
}
.page-content .dataTables_wrapper .dt-buttons .btn {
    padding: 7px 9px;
    font-size: 14px;
    line-height: 1.5;
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: #fff !important;
}
.dataTable thead th {
    background-color: #e5e5e5 !important;
    color: #475569 !important;
    font-size: 11.5px !important;
    font-weight: 700 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.04em !important;
    border-top: none !important;
    border-bottom: 1px solid #e2e8f0 !important;
    border-left: none !important;
    border-right: none !important;
    padding: 9px 16px !important;
    white-space: nowrap;    line-height: 19px!important;
}
.tts-erp-tabs-container {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 0px;
    margin-bottom: 0;
    position: relative;
    z-index: 5;
}
.tts-erp-tab-item {
    color: #64748b;
    font-size: 13px;
    font-weight: 600;
    position: relative;
    padding: 9px 18px;
    margin-right: 4px;
    border-top-left-radius: 10px !important;
    border-top-right-radius: 10px !important;
    border-bottom-left-radius: 0 !important;
    border-bottom-right-radius: 0 !important;
    transition: all 0.2s ease-in-out;
    text-decoration: none !important;
    border: 1px solid transparent;
    border-bottom: none !important;
}
.tts-erp-tab-item:hover {
    color: #0f172a;
    background: #ffffff;
    border-color: #cbd5e1;
}
.tts-erp-tab-item.active {
    color: #ffffff !important;
    background: #2563eb !important;
    font-weight: 700;
    border-color: #2563eb !important;
    box-shadow: 0 -2px 10px rgba(37, 99, 235, 0.25);
}
.tts-erp-tab-item .badge {
    background-color: #cbd5e1;
    color: #334155;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 10px;
    transition: all 0.2s ease;
}
.tts-erp-tab-item.active .badge {
    background-color: #ffffff !important;
    color: #2563eb !important;
}

/* Hiển thị tất cả dữ liệu bảng DataTable trên 1 hàng (không xuống dòng) */
.dataTable th,
.dataTable td,
.table-wrapper .dataTable th,
.table-wrapper .dataTable td {
    white-space: nowrap !important;
    word-break: keep-all !important;
}
.dataTable tbody td {
    padding: 4px 10px !important;
    vertical-align: middle !important;
    font-size: 12px !important;
    border-top: none !important;
    border-bottom: 1px solid #f1f5f9 !important;
    border-left: none !important;
    border-right: none !important;
}


/* --- CHUNGTU FORM CSS --- */

/* ============================================================
   HppCRM - Chứng từ Form Styles (Pro Accounting Style)
   Phong cách phần mềm kế toán chuyên nghiệp
   ============================================================ */

/* ---------- BẢNG CHI TIẾT (Spreadsheet style) ---------- */
.ct-table-wrap {
    border: 1px solid #c0c0c0;
    border-radius: 0;
    overflow-x: auto;
    overflow-y: visible;
    background: #fff;
    min-height: 280px;
    width: 100%;
}

.ct-table {
    width: 100% !important;
    border-collapse: collapse;
    font-size: 13px;
    margin: 0;
}

.ct-table thead th {
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    padding: 10px 8px;
    font-size: 12px;
    font-weight: 600;
    color: #475569;
    text-align: center;
    white-space: nowrap;
    position: sticky;
    top: 0;
    z-index: 2;
    user-select: none;
}

.ct-table tbody td {
    border: 1px solid #e2e8f0;
    padding: 0;
    vertical-align: middle;
    height: 32px;
    position: relative;
}

.ct-table tbody tr:hover {
    background: #f1f5f9 !important;
}

.ct-table tbody tr.ct-row-active {
    background: #dbeafe !important;
}

.ct-table tbody tr:nth-child(even) {
    background: #f8fafc;
}

/* Cell inputs - borderless spreadsheet style */
.ct-table .ct-cell-input {
    width: 100%;
    height: 100%;
    border: none;
    outline: none;
    padding: 4px 8px;
    font-size: 13px;
    background: transparent;
    box-sizing: border-box;
}

.ct-table .ct-cell-input:focus {
    background: #fff;
    box-shadow: inset 0 0 0 2px #2563eb;
}

.ct-table .ct-cell-input.text-right {
    text-align: right;
}

.ct-table .ct-cell-select {
    width: 100%;
    height: 100%;
    border: none;
    outline: none;
    padding: 2px 4px;
    font-size: 13px;
    background: transparent;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6'%3E%3Cpath d='M0 0l5 6 5-6z' fill='%23666'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 6px center;
    padding-right: 20px;
}

.ct-table .ct-cell-select:focus {
    box-shadow: inset 0 0 0 2px #2563eb;
}

/* STT column */
.ct-table .ct-stt {
    text-align: center;
    color: #666;
    font-size: 12px;
    padding: 4px;
    background: #f5f5f5;
    width: 32px;
}

/* Mã hàng cell */
.ct-table .ct-mahv-cell {
    position: relative;
}

.ct-table .ct-mahv-cell .ct-cell-input {
    font-weight: 600;
    color: #1a56db;
}

.ct-table .td-ten {
    color: #333;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.ct-table td.td-ten {
    padding: 4px 8px;
}

.ct-table td.td-ten:has(input) {
    padding: 0;
}

/* ĐVT */
.ct-table .td-dvt {
    text-align: center;
    padding: 4px 8px;
    color: #666;
    font-size: 12px;
}

/* Số tiền cells */
.ct-table .td-tien {
    text-align: right;
    padding: 4px 8px;
    font-weight: 600;
    color: #1e293b;
    font-variant-numeric: tabular-nums;
}

/* Delete button */
.ct-table .ct-del-btn {
    text-align: center;
    padding: 4px;
}

.ct-table .ct-del-btn a {
    color: #dc2626;
    opacity: 0.3;
    font-size: 13px;
    transition: opacity .15s;
}

.ct-table tbody tr:hover .ct-del-btn a {
    opacity: 1;
}

/* Footer tổng */
.ct-table tfoot td {
    border: 1px solid #cbd5e1;
    padding: 10px 8px;
    font-weight: 700;
    font-size: 13px;
    background: #f8fafc;
    color: #1e293b;
}

/* ---------- TOOLBAR DÒNG ---------- */
.ct-toolbar {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 12px;
    background: #ffffff;
    border: 1px solid #cbd5e1;
    border-bottom: none;
}

.ct-toolbar-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    background: #ffffff;
    color: #475569;
    cursor: pointer;
    font-size: 13px;
    transition: all .2s ease;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.ct-toolbar-btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.08);
}

.ct-toolbar-btn.btn-add {
    color: #10b981;
}

.ct-toolbar-btn.btn-add:hover {
    background: #ecfdf5;
    border-color: #a7f3d0;
    color: #059669;
}

.ct-toolbar-btn.btn-del {
    color: #ef4444;
}

.ct-toolbar-btn.btn-del:hover {
    background: #fef2f2;
    border-color: #fecaca;
    color: #dc2626;
}

.ct-toolbar-btn.btn-up,
.ct-toolbar-btn.btn-down {
    color: #3b82f6;
}

.ct-toolbar-btn.btn-up:hover,
.ct-toolbar-btn.btn-down:hover {
    background: #eff6ff;
    border-color: #bfdbfe;
    color: #2563eb;
}

.ct-toolbar-sep {
    width: 1px;
    height: 18px;
    background: #e2e8f0;
    margin: 0 4px;
}

.ct-toolbar-info {
    margin-left: auto;
    font-size: 12px;
    color: #666;
}

.ct-toolbar-info b {
    color: #c00;
}

/* ---------- Autocomplete Dropdown (Pro) ---------- */
.ct-dropdown {
    display: none;
    position: absolute;
    left: 0;
    top: 0;
    z-index: 99999;
    min-width: 1300px !important;
    width: 1300px;
    height: 280px;
    background: #fff;
    border: 1px solid #c0c0c0;
    box-shadow: 0 4px 16px rgba(0, 0, 0, .15);
    margin-top: 0;
    resize: both;
    overflow: visible;
    border-radius: 4px;
}

.ct-dropdown-inner {
    width: 100%;
    height: 100%;
    overflow: auto;
    border-radius: 4px;
}

.ct-dd-table th {
    position: sticky;
    top: 0;
    background: #f8fafc;
    z-index: 10;
    box-shadow: inset 0 -1px 0 #cbd5e1;
}

.ct-dropdown::before {
    content: '';
    position: absolute;
    top: -7px;
    left: 30px;
    border-width: 0 7px 7px;
    border-style: solid;
    border-color: #c0c0c0 transparent;
    display: block;
    width: 0;
    z-index: 1051;
}

.ct-dropdown::after {
    content: '';
    position: absolute;
    top: -6px;
    left: 30px;
    border-width: 0 7px 7px;
    border-style: solid;
    border-color: #fff transparent;
    display: block;
    width: 0;
    z-index: 1052;
}

.ct-dropdown.show {
    display: block;
    animation: ctSlide .12s ease;
}

@keyframes ctSlide {
    from {
        opacity: 0;
        transform: translateY(-2px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.ct-dd-table {
    width: 100%;
    border-collapse: collapse;
    table-layout: fixed;
    background: #fff;
    margin: 0;
}

.ct-dd-table thead th {
    background: linear-gradient(180deg, #f0f0f0 0%, #e0e0e0 100%);
    border: 1px solid #ccc;
    padding: 5px 8px;
    font-size: 11px;
    font-weight: 700;
    color: #444;
    position: sticky;
    top: 0;
    z-index: 10;
    text-align: left;
    white-space: nowrap;
    user-select: none;
}

.ct-dd-item {
    cursor: pointer;
    transition: background .08s;
}

.ct-dd-table tbody td {
    border: 1px solid #eee;
    padding: 5px 8px;
    font-size: 12px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    vertical-align: middle;
}

.ct-dd-item:hover {
    background: #cce5ff;
}

.ct-dd-item.ct-dd-active {
    background: #0d6efd;
    color: #fff;
}

.ct-dd-item.ct-dd-active td {
    color: #fff !important;
}

.ct-dd-ma {
    font-weight: 700;
    color: #1a56db;
}

.ct-dd-ten {
    color: #333;
}

.ct-dd-dvt {
    color: #666;
    text-align: center;
}

.ct-dd-gia {
    text-align: right;
    color: #059669;
    font-weight: 600;
}

.ct-dd-empty {
    padding: 14px;
    text-align: center;
    color: #999;
    font-size: 12px;
}

/* ---------- FOOTER TỔNG CỘNG (Accounting style) ---------- */
.ct-footer-summary {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0;
    margin-top: 0;
    border: 1px solid #c0c0c0;
    border-top: none;
    background: #fff;
    font-size: 13px;
}

.ct-footer-left {
    border-right: 1px solid #c0c0c0;
    padding: 10px 12px;
}

.ct-footer-right {
    padding: 0;
}

.ct-footer-row {
    display: grid;
    grid-template-columns: 1fr 130px 100px;
    border-bottom: 1px solid #e0e0e0;
}

.ct-footer-row.ct-footer-4col {
    grid-template-columns: 1fr 130px 1fr 130px;
}

.ct-footer-row:last-child {
    border-bottom: none;
}

.ct-footer-row.ct-footer-total {
    background: linear-gradient(180deg, #f8f8f8 0%, #f0f0f0 100%);
    font-weight: 700;
    color: #c00;
}

.ct-footer-row>span {
    padding: 5px 10px;
    border-right: 1px solid #e0e0e0;
}

.ct-footer-row>span:last-child {
    border-right: none;
}

.ct-footer-row>span:nth-child(2),
.ct-footer-row>span:nth-child(4) {
    text-align: right;
    font-variant-numeric: tabular-nums;
}

.ct-footer-label {
    color: #444;
    font-weight: 500;
}

/* ---------- ACTION BUTTONS (Bottom) ---------- */
.ct-action-bar {
    display: flex;
    justify-content: flex-end;
    gap: 8px;
    padding: 12px 0;
    margin-top: 12px;
}

.ct-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 20px;
    border: 1px solid #bbb;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all .15s;
}

.ct-action-btn.btn-save-add {
    background: linear-gradient(180deg, #6b7280 0%, #4b5563 100%);
    color: #fff;
    border-color: #374151;
}

.ct-action-btn.btn-save-add:hover {
    background: linear-gradient(180deg, #7b8290 0%, #5b6573 100%);
}

.ct-action-btn.btn-save {
    background: linear-gradient(180deg, #ef4444 0%, #dc2626 100%);
    color: #fff;
    border-color: #b91c1c;
}

.ct-action-btn.btn-save:hover {
    background: linear-gradient(180deg, #f87171 0%, #ef4444 100%);
}

.ct-action-btn.btn-exit {
    background: linear-gradient(180deg, #f3f4f6 0%, #e5e7eb 100%);
    color: #333;
}

.ct-action-btn.btn-exit:hover {
    background: linear-gradient(180deg, #e5e7eb 0%, #d1d5db 100%);
}

.ct-action-btn .ct-key {
    font-size: 11px;
    opacity: .7;
}

/* ---------- Scrollbar ---------- */
.ct-dropdown::-webkit-scrollbar {
    width: 8px;
}

.ct-dropdown::-webkit-scrollbar-track {
    background: #f0f0f0;
}

.ct-dropdown::-webkit-scrollbar-thumb {
    background: #bbb;
    border-radius: 0;
}

.ct-dropdown::-webkit-scrollbar-thumb:hover {
    background: #999;
}

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
    .ct-footer-summary {
        grid-template-columns: 1fr;
    }

    .ct-dropdown {
        min-width: 300px;
    }

    .ct-dd-header,
    .ct-dd-item {
        grid-template-columns: 80px 1fr 60px;
    }

    .ct-dd-dvt {
        display: none;
    }

    /* Fieldset stack dọc */
    .ct-fieldset-container {
        flex-direction: column;
    }

    .ct-fieldset.left-box {
        min-width: auto !important;
    }

    .ct-fieldset.right-box {
        min-width: auto !important;
    }

    /* Mỗi row wrap xuống dòng */
    .ct-fieldset-row {
        flex-wrap: wrap;
    }

    .ct-fieldset-col {
        flex: 1 1 100% !important;
        min-width: 0;
    }

    .ct-field-label {
        min-width: 70px;
    }
}

/* ---------- Column Resize Handle ---------- */
.ct-resize-handle {
    position: absolute;
    right: 0;
    top: 0;
    bottom: 0;
    width: 5px;
    cursor: col-resize;
    background: transparent;
    z-index: 5;
}

.ct-resize-handle:hover,
.ct-resize-handle:active {
    background: #4a90d9;
}

/* Table layout - buộc bảng luôn chiếm 100% container */
.ct-table {
    table-layout: fixed;
    width: 100% !important;
    min-width: 100% !important;
}

/* ---------- Move Up/Down Buttons ---------- */
.ct-toolbar-btn.btn-up,
.ct-toolbar-btn.btn-down {
    color: #2563eb;
    font-size: 12px;
}

/* ---------- Hide Spin Buttons on Number Inputs ---------- */
input[type=number]::-webkit-outer-spin-button,
input[type=number]::-webkit-inner-spin-button {
    -webkit-appearance: none;
    appearance: none;
    margin: 0;
}

input[type=number] {
    -moz-appearance: textfield;
    appearance: textfield;
}

/* ---------- TABS CHI TIẾT ---------- */
.ct-tabs {
    display: flex;
    border: 1px solid #cbd5e1;
    border-bottom: none;
    background: #f8fafc;
    margin-top: 16px;
    border-radius: 6px 6px 0 0;
    overflow: hidden;
}

.ct-tab {
    padding: 8px 20px;
    font-size: 12px;
    color: #64748b;
    border-right: 1px solid #cbd5e1;
    cursor: pointer;
    background: #f1f5f9;
    font-weight: 600;
    transition: all 0.2s ease;
}

.ct-tab:hover {
    color: #1e293b;
    background: #e2e8f0;
}

.ct-tab.active {
    background: #ffffff;
    color: #2563eb;
    /* Royal Blue */
    font-weight: 700;
    position: relative;
    border-bottom: 2px solid #2563eb;
    /* highlight line Royal Blue */
}

/* ---------- FIELDSET HEADER LAYOUT ---------- */
.ct-fieldset-container {
    display: flex;
    gap: 16px;
    margin-bottom: 16px;
    font-family: inherit;
    flex-wrap: wrap;
    /* responsive */
}

.ct-fieldset {
    border: 1px solid #cbd5e1 !important;
    border-radius: 6px;
    background: #ffffff;
    padding: 14px 16px !important;
    margin: 0;
}

.ct-fieldset.left-box {
    flex: 3;
    min-width: 580px;
}

.ct-fieldset.right-box {
    flex: 1.1;
    min-width: 320px;
}

.ct-fieldset legend {
    width: auto;
    font-size: 13px !important;
    font-weight: 700 !important;
    color: #334155 !important;
    padding: 0 8px !important;
    margin: 0;
    border-bottom: none !important;
}

/* Row-Col Grid inside Fieldset */
.ct-fieldset-row {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 10px;
}

.ct-fieldset-row:last-child {
    margin-bottom: 0;
}

.ct-fieldset-col {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
}

.ct-col-flex2 {
    flex: 2;
}

.ct-col-flex3 {
    flex: 3;
}

.ct-field-label {
    min-width: 90px;
    font-size: 12px;
    color: #475569;
    font-weight: 600;
    white-space: nowrap;
}

/* Control wrap group */
.ct-field-group {
    display: flex;
    align-items: center;
    width: 100%;
}

.ct-field-group .form-control,
.ct-field-group select {
    border: 1px solid #cbd5e1;
    border-radius: 4px;
    height: 30px !important;
    padding: 4px 10px !important;
    font-size: 13px;
    color: #0f172a;
    background-color: #ffffff;
    width: 100%;
    outline: none;
    box-shadow: none;
    transition: all 0.15s ease-in-out;
    flex: 1 1 auto !important;
}

.ct-field-group .form-control:focus,
.ct-field-group select:focus {
    border-color: #2563eb !important;
    box-shadow: 0 0 0 1px #2563eb !important;
}

.ct-field-group input[type="date"] {
    position: relative;
    padding-right: 28px !important;
}

.ct-field-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 30px;
    background: transparent;
    border: none;
    color: #10b981;
    font-size: 18px;
    cursor: pointer;
    padding: 0;
    margin-left: 4px;
    transition: color 0.15s ease;
    flex-shrink: 0 !important;
}

.ct-field-btn:hover {
    color: #059669;
}

.ct-field-btn.baohanhdientu_formaction {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 28px !important;
    height: 30px !important;
    background: transparent !important;
    border: none !important;
    color: #10b981 !important;
    font-size: 18px !important;
    cursor: pointer !important;
    padding: 0 !important;
    margin: 0 0 0 4px !important;
    box-shadow: none !important;
    text-shadow: none !important;
    border-radius: 0 !important;
    flex-shrink: 0 !important;
}

.ct-field-btn.baohanhdientu_formaction:hover {
    color: #059669 !important;
}

/* Shared circular toolbar actions for plugin buttons. */
.toolbar-right button.lx-form-action {
    display: inline-flex !important;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-width: 52px;
    padding: 2px 6px !important;
    gap: 4px;
    border: 0 !important;
    background: transparent !important;
    color: #16a34a !important;
    font-size: 11px !important;
    font-weight: 600 !important;
    line-height: 1.2;
    text-align: center;
}
.toolbar-right button.lx-form-action:hover { transform: translateY(-2px); opacity: .9; }
.toolbar-right button.lx-form-action i {
    display: flex !important;
    align-items: center;
    justify-content: center;
    width: 32px !important;
    height: 32px !important;
    margin: 0 auto;
    border-radius: 50% !important;
    background: #16a34a !important;
    color: #fff !important;
    font-size: 13px !important;
    box-shadow: 0 2px 4px rgba(0,0,0,.1);
}

/* Fix Header Navbar & Dropdowns Z-Index & Overflow */
.page-header.navbar,
.page-header.navbar.navbar-static-top,
.page-header.navbar.navbar-fixed-top {
    z-index: 1005 !important;
}
.page-header.navbar .top-menu,
.page-header.navbar .top-menu .navbar-nav,
.page-header.navbar .page-header-inner {
    overflow: visible !important;
}
.tts-header-dropdown {
    position: relative !important;
    z-index: 1010 !important;
}
.tts-header-dropdown-menu {
    z-index: 99999 !important;
    position: absolute !important;
}

/* Iframe Modal Display Isolation - Auto hide header & top-menu & sidebars inside iframe */
html.in-iframe .page-header,
html.in-iframe .page-header-inner,
html.in-iframe .top-menu,
html.in-iframe header,
html.in-iframe nav.navbar,
html.in-iframe .page-sidebar-wrapper,
html.in-iframe .page-sidebar,
html.in-iframe .mobile_menu,
html.in-iframe .page-footer,
html.in-iframe .page-breadcrumb,
html.in-iframe .page-bar,
html.in-iframe .breadcrumb,
html.in-iframe .tts-header-dropdown,
html.in-iframe #vacom-mobile-fab,
html.in-iframe #vacom-sync-tasks-container,
html.in-iframe .f-reload {
    display: none !important;
}
html.in-iframe .page-container {
    margin-top: 0 !important;
    padding-top: 0 !important;
}
html.in-iframe .page-content-wrapper {
    margin-left: 0 !important;
    margin-top: 0 !important;
    padding-top: 0 !important;
    width: 100% !important;
}
html.in-iframe .page-content-wrapper .page-content,
html.in-iframe .page-content {
    margin-left: 0 !important;
    padding: 10px 16px !important;
    margin: 0 !important;
    background: #f8fafc !important;
    min-height: auto !important;
}
html.in-iframe body {
    padding-top: 0 !important;
    background: #f8fafc !important;
}
html.in-iframe .lx-dashboard {
    padding: 0 !important;
    background: transparent !important;
}

/* =========================================================
   MISA AMIS Enterprise Global UI & Button Suite (Inheritable by all tables)
   ========================================================= */

/* 1. MISA Action Buttons (Compact, elegant, smaller text & icon, tight spacing) */
.misa-btn {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    height: 31px !important;
    padding: 0 10px !important;
    font-size: 12px !important;
    line-height: 1 !important;
    border-radius: 5px !important;
    transition: all 0.15s ease-in-out !important;
    cursor: pointer !important;
    text-decoration: none !important;
    white-space: nowrap !important;
    border: 1px solid transparent !important;
    user-select: none !important;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
}

.misa-btn span,
.misa-btn strong,
.misa-btn b {
    font-size: 12px !important;
    font-weight: 400 !important;
}

/* Icon nhỏ gọn (font-size: 11.5px), KHÔNG gán font-weight để FontAwesome tự hiển thị chuẩn */
.misa-btn i,
.header-misa-actions .btn i,
.header-actions .btn i,
.table-wrapper .dataTables_wrapper .dt-buttons .btn i,
.table-wrapper .dataTables_wrapper .dt-buttons .action-item i {
    font-size: 11.5px !important;
    margin-right: 0 !important;
    line-height: 1 !important;
    display: inline-block;
}

/* Fallbacks for older FA4 icon class names */
.fa-sliders:before,
.fas.fa-sliders:before {
    content: "\f1de" !important;
}
.fa-refresh:before,
.fas.fa-refresh:before {
    content: "\f021" !important;
}

.misa-btn:focus,
.misa-btn:active {
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15) !important;
}

/* Standard Outline Button (Crisp White Card with subtle border) */
.misa-btn-outline,
.misa-btn-primary {
    background-color: #ffffff !important;
    border-color: #d1d5db !important;
    color: #374151 !important;
}
.misa-btn-outline:hover,
.misa-btn-primary:hover {
    background-color: #f9fafb !important;
    border-color: #9ca3af !important;
    color: #111827 !important;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.08) !important;
}

/* Accent Button (Soft Lavender Tint) */
.misa-btn-accent {
    background-color: #f5f3ff !important;
    border-color: #ddd6fe !important;
    color: #6d28d9 !important;
}
.misa-btn-accent:hover {
    background-color: #ede9fe !important;
    border-color: #c4b5fd !important;
    color: #5b21b6 !important;
    box-shadow: 0 2px 5px 0 rgba(109, 40, 217, 0.15) !important;
}

/* MISA Icon Button (Square 31x31) */
.misa-btn-icon {
    width: 31px !important;
    height: 31px !important;
    min-width: 31px !important;
    padding: 0 !important;
    border-radius: 5px !important;
    background-color: #ffffff !important;
    border: 1px solid #d1d5db !important;
    color: #4b5563 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
    font-size: 11.5px !important;
}
.misa-btn-icon:hover {
    background-color: #f9fafb !important;
    border-color: #9ca3af !important;
    color: #111827 !important;
}

/* Header Actions container for all tables */
.header-misa-actions {
    display: flex !important;
    align-items: center !important;
    gap: 5px !important;
    flex-wrap: wrap !important;
}

/* Kế thừa cho các nút trong header-actions của bất kỳ table nào */
.header-misa-actions .btn,
.header-actions .btn {
    border-radius: 5px !important;
    font-size: 12px !important;
    height: 31px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    padding: 0 10px !important;
}

.header-misa-actions .btn span,
.header-actions .btn span,
.header-misa-actions .btn strong,
.header-actions .btn strong {
    font-size: 12px !important;
    font-weight: 400 !important;
}

/* 2. Global Table Container Card */
.table-wrapper {
    background: #ffffff !important;
    border-radius: 0px !important;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.08), 0 1px 2px -1px rgba(0, 0, 0, 0.08) !important;
    border: -1px solid #e2e8f0 !important;
    overflow: hidden !important;
    position: relative !important;
}

.portlet-title,
.table-wrapper .portlet.portlet-no-padding .portlet-title {
    display: none !important;
}

.table-wrapper .portlet-body {
    padding: 0 !important;
    position: relative !important;
}

/* 3. Global MISA ERP Tabs Bar Styling */
.tts-erp-tabs-container {
    background: transparent !important;
    border-bottom: 1px solid #e2e8f0 !important;
    padding: 0px 7px 0 -1px !important;
    margin-bottom: 0 !important;
    position: relative !important;
    z-index: 5 !important;
}
.tts-erp-tab-item {
    color: #64748b !important;
    font-size: 12.5px !important;
    font-weight: 400 !important;
    position: relative !important;
    padding: 7px 14px !important;
    margin-right: 3px !important;
    border-radius: 5px 5px 0 0 !important;
    transition: all 0.15s ease-in-out !important;
    text-decoration: none !important;
    border: 1px solid transparent !important;
    border-bottom: none !important;
    background: transparent !important;
}
.tts-erp-tab-item:hover {
    color: #1e293b !important;
    background: #f8fafc !important;
}
.tts-erp-tab-item.active {
    color: #2563eb !important;
    background: #eff6ff !important;
    font-weight: 500 !important;
    border: 1px solid #bfdbfe !important;
    border-bottom: 2px solid #2563eb !important;
    box-shadow: none !important;
}
.tts-erp-tab-item .badge {
    background-color: #f1f5f9 !important;
    color: #475569 !important;
    font-size: 11px !important;
    font-weight: 400 !important;
    padding: 2px 6px !important;
    border-radius: 10px !important;
    transition: all 0.15s ease !important;
    border: 1px solid #e2e8f0 !important;
}
.tts-erp-tab-item.active .badge {
    background-color: #dbeafe !important;
    color: #1e40af !important;
    border-color: #bfdbfe !important;
    font-weight: 500 !important;
}

/* 4. Global DataTable Toolbar (.top), Smart Search & Buttons */
.table-wrapper .dataTables_wrapper .top {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    padding: 6px 12px !important;
    background: #ffffff !important;
    border-bottom: 1px solid #f1f5f9 !important;
    min-height: 44px !important;
    height: auto !important;
    gap: 8px !important;
    flex-wrap: wrap !important;
}

.table-wrapper .dataTables_wrapper .dataTables_filter {
    position: relative !important;
    margin: 0 !important;
    padding: 0 !important;
    float: none !important;
    max-width: 320px !important;
    width: 100% !important;
    top: auto !important;
    left: auto !important;
}
.table-wrapper .dataTables_wrapper .dataTables_filter label {
    margin: 0 !important;
    width: 100% !important;
    position: relative !important;
    display: flex !important;
    align-items: center !important;
    font-weight: 400 !important;
}
.table-wrapper .dataTables_wrapper .dataTables_filter input[type="search"] {
    width: 100% !important;
    height: 31px !important;
    padding: 0 34px 0 30px !important; /* Chừa 34px lề phải để icon lọc không đè chữ */
    font-size: 12px !important;
    color: #1e293b !important;
    background: #ffffff !important;
    border: 1px solid #d1d5db !important;
    border-radius: 5px !important;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
    transition: all 0.15s ease-in-out !important;
    outline: none !important;
    margin: 0 !important;
    font-weight: 400 !important;
}
.table-wrapper .dataTables_wrapper .dataTables_filter input[type="search"]::placeholder {
    color: #94a3b8 !important;
    font-size: 12px !important;
    font-weight: 400 !important;
}
.table-wrapper .dataTables_wrapper .dataTables_filter input[type="search"]:focus {
    border-color: #2563eb !important;
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.15) !important;
}
.table-wrapper .dataTables_wrapper .dataTables_filter label::before {
    content: "\f002" !important;
    font-family: "FontAwesome", "Font Awesome 5 Free" !important;
    position: absolute !important;
    left: 9px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    color: #94a3b8 !important;
    font-size: 11.5px !important;
    pointer-events: none !important;
    z-index: 2 !important;
}
.table-wrapper .dataTables_wrapper .dataTables_filter label::after {
    display: none !important;
}

/* Định vị nút Lọc (fa-filter) cân đối hoàn hảo trong ô tìm kiếm hoặc toolbar */
.btn-show-table-options,
.btn.btn-primary.btn-show-table-options,
.table-wrapper .btn-show-table-options,
.table-wrapper .dataTables_filter .btn-show-table-options,
.table-wrapper .wrapper-action .btn-show-table-options {
    position: absolute !important;
    right: 8px !important;
    top: 50% !important;
    transform: translateY(-50%) !important;
    width: 22px !important;
    height: 22px !important;
    min-width: 22px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    background: transparent !important;
    border: none !important;
    box-shadow: none !important;
    color: #64748b !important;
    font-size: 11.5px !important;
    cursor: pointer !important;
    z-index: 5 !important;
    padding: 0 !important;
    margin: 0 !important;
    border-radius: 4px !important;
    transition: all 0.15s ease-in-out !important;
    line-height: 1 !important;
}

.btn-show-table-options:hover,
.btn.btn-primary.btn-show-table-options:hover,
.table-wrapper .btn-show-table-options:hover,
.table-wrapper .dataTables_filter .btn-show-table-options:hover,
.table-wrapper .wrapper-action .btn-show-table-options:hover {
    background: #f1f5f9 !important;
    color: #2563eb !important;
}

.btn-show-table-options i,
.btn.btn-primary.btn-show-table-options i {
    font-size: 11.5px !important;
    line-height: 1 !important;
    margin: 0 !important;
    padding: 0 !important;
    display: inline-block !important;
    color: inherit !important;
}

/* Nhóm nút icon vuông 31x31 trên toolbar (nếu nút lọc được chuyển vào toolbar) */
.table-wrapper .dataTables_wrapper .dt-buttons .btn.btn-show-table-options,
.table-wrapper .dataTables_wrapper .dt-buttons .btn-show-table-options {
    position: static !important;
    transform: none !important;
    width: 31px !important;
    height: 31px !important;
    min-width: 31px !important;
    padding: 0 !important;
    border-radius: 5px !important;
    background: #ffffff !important;
    border: 1px solid #d1d5db !important;
    color: #4b5563 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 11.5px !important;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
}
.table-wrapper .dataTables_wrapper .dt-buttons .btn.btn-show-table-options:hover,
.table-wrapper .dataTables_wrapper .dt-buttons .btn-show-table-options:hover {
    background: #f9fafb !important;
    border-color: #9ca3af !important;
    color: #111827 !important;
}

/* Toolbar Buttons group on the right */
.table-wrapper .dataTables_wrapper .dt-buttons {
    display: inline-flex !important;
    align-items: center !important;
    gap: 5px !important;
    float: none !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Toolbar Buttons: height 31px, font-size 12px, padding 0 10px */
.table-wrapper .dataTables_wrapper .dt-buttons .btn {
    height: 31px !important;
    padding: 0 10px !important;
    font-size: 12px !important;
    line-height: 1 !important;
    border-radius: 5px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
    transition: all 0.15s ease-in-out !important;
    margin: 0 !important;
    border: 1px solid #d1d5db !important;
    background: #ffffff !important;
    color: #374151 !important;
}
.table-wrapper .dataTables_wrapper .dt-buttons .btn span,
.table-wrapper .dataTables_wrapper .dt-buttons .btn strong,
.table-wrapper .dataTables_wrapper .dt-buttons .btn b {
    font-size: 12px !important;
    font-weight: 400 !important;
}

.table-wrapper .dataTables_wrapper .dt-buttons .btn:hover {
    background: #f9fafb !important;
    border-color: #9ca3af !important;
    color: #111827 !important;
}

/* Square Icon Buttons: reload, settings, filter toggle (31x31) */
.table-wrapper .dataTables_wrapper .dt-buttons .btn.buttons-reload,
.table-wrapper .dataTables_wrapper .dt-buttons .btn-column-settings,
.table-wrapper .dataTables_wrapper .dt-buttons .btn-show-table-options {
    width: 31px !important;
    height: 31px !important;
    min-width: 31px !important;
    padding: 0 !important;
    border-radius: 5px !important;
    background: #ffffff !important;
    border: 1px solid #d1d5db !important;
    color: #4b5563 !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 11.5px !important;
}
.table-wrapper .dataTables_wrapper .dt-buttons .btn.buttons-reload:hover,
.table-wrapper .dataTables_wrapper .dt-buttons .btn-column-settings:hover,
.table-wrapper .dataTables_wrapper .dt-buttons .btn-show-table-options:hover {
    background: #f9fafb !important;
    border-color: #9ca3af !important;
    color: #111827 !important;
}

/* Action items inside Toolbar (cùng style MISA Outline gọn gàng) */
.table-wrapper .dataTables_wrapper .dt-buttons .action-item {
    background: #ffffff !important;
    border: 1px solid #d1d5db !important;
    color: #374151 !important;
    padding: 0 10px !important;
    border-radius: 5px !important;
    height: 31px !important;
    font-size: 12px !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 4px !important;
    box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05) !important;
    transition: all 0.15s ease-in-out !important;
}
.table-wrapper .dataTables_wrapper .dt-buttons .action-item:hover {
    background: #f9fafb !important;
    border-color: #9ca3af !important;
    color: #111827 !important;
    box-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.08) !important;
}
.table-wrapper .dataTables_wrapper .dt-buttons .action-item span {
    color: #374151 !important;
    font-size: 12px !important;
    font-weight: 400 !important;
}
.table-wrapper .dataTables_wrapper .dt-buttons .action-item i {
    color: #2563eb !important;
    font-size: 11.5px !important;
}

/* 5. Global DataTable Table Styling */
.dataTable {
    margin-top: 0 !important;
    border-collapse: separate !important;
    border-spacing: 0 !important;
    width: 100% !important;
}
.dataTable thead th {
    background-color: #f8fafc !important;
    color: #475569 !important;
    font-size: 11.5px !important;
    font-weight: 600 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.04em !important;
    border-top: none !important;
    border-bottom: 1px solid #e2e8f0 !important;
    border-left: none !important;
    border-right: none !important;
    padding: 9px 12px !important;
    white-space: nowrap !important;
}
.dataTable tbody tr {
    transition: all 0.15s ease-in-out;
    border-bottom: 1px solid #f1f5f9;
}
.dataTable tbody tr:hover {
    background-color: #f0f9ff !important;
}
.dataTable tbody td {
    padding: 7px 12px !important;
    vertical-align: middle !important;
    font-size: 12.5px !important;
    border-top: none !important;
    border-bottom: 1px solid #f1f5f9 !important;
    border-left: none !important;
    border-right: none !important;
}
.dataTable tbody tr:last-child td {
    border-bottom: none !important;
}

/* Clean Monospace Code Link */
.tts-order-code-link {
    font-family: SFMono-Regular, Consolas, monospace !important;
    font-size: 12.5px !important;
    font-weight: 500 !important;
    color: #2563eb !important;
    text-decoration: none !important;
    background: transparent !important;
    border: none !important;
    padding: 0 !important;
}
.tts-order-code-link:hover {
    color: #1d4ed8 !important;
    text-decoration: underline !important;
}
