:root {
    --bs-primary: #005F3A !important;
}

.text-primary {
    color: #005F3A !important;
}

.btn-primary {
    color: #fff;
    background-color: #005F3A;
    border-color: #005F3A;
    box-shadow: none;
}

.btn-excel {
    color: #fff;
    background-color: #005F3A;
    border-color: #005F3A;
    box-shadow: none;
}

.btn-outline-excel {
    color: #005F3A;
    border-color: #005F3A;
}
/* pace color */
.pace .pace-progress {
    background: rgb(51, 139, 147) !important;
}

.circle-bg {
    background-color: #FFE3E3 !important;
}

/* Card Design */
.card {
    border-radius: 15px;
}

.login-card-body,
.register-card-body {
    border-radius: 15px;
}

/* Custom */

.login-page,
.register-page {
    /* background-color: #f6f9ff; */
    /* background:  #015A36; */

    background: linear-gradient(to right, rgb(182, 244, 146), rgb(51, 139, 147));
}

.bg-white-custom {
    background-color: #f6f9ff;
    color: #000000;
}

.bg-sidebar-white-custom {
    background: #C70000;
    color: #ffffff;
}

/* Navbar */
.main-header {
    border-bottom: none !important;
}

/* Sidebar */
.sidebar {
    padding-left: 0.8rem !important;
    padding-right: 0.8rem !important;
}

.sidebar-light-white-custom .nav-sidebar>.nav-item>.nav-link.active {
    /* background-color: rgba(199, 0, 0); */
    /* background:  #015A36; */
    /* background: linear-gradient(to right, rgb(51, 139, 147), rgb(182, 244, 146)); */
    background: linear-gradient(89deg, #005F3A 0.1%, #0D3E29 51.5% 100.2%);
    color: white;
}

.nav-sidebar .nav-item>.nav-link {
    padding: 10px;
}

/* เผื่ออยากแก้ตอน Hover Side Menu */
/* [class*=sidebar-light-] .nav-sidebar>.nav-item.menu-open>.nav-link,
        [class*=sidebar-light-] .nav-sidebar>.nav-item:hover>.nav-link {
            background-color: #f6f9ff;
            color: #4154f1;
        } */

[class*=sidebar-light-] .nav-sidebar>.nav-item>.nav-link.active {
    box-shadow: none !important;
}

[class*=sidebar-light-] .sidebar a {
    color: #000000;
}

[class*=sidebar-light-] .nav-treeview>.nav-item>.nav-link {
    color: #000000;
}

[class*=sidebar-light-] .nav-treeview>.nav-item>.nav-link.active,
[class*=sidebar-light-] .nav-treeview>.nav-item>.nav-link.active:hover {
    background-color: rgba(0, 0, 0, 0);
    color: #005F3A;

    /* font-size: 16px; */
}

[class*=sidebar-light-] .nav-treeview>.nav-item>.nav-link:focus,
[class*=sidebar-light-] .nav-treeview>.nav-item>.nav-link:hover {
    background-color: rgba(0, 0, 0, .1);
    color: rgb(51, 139, 147);
}

/* Sidebar menu tree */
.custom-icon {
    font-size: 5px;
    text-align: center;
    vertical-align: middle;
    /* ปรับขนาดตามที่คุณต้องการ */
}

.navbar-white-custom {
    background-color: #f6f9ff;
}

.shadow-custom {
    box-shadow: 0px 2px 20px rgba(1, 41, 112, 0.1);
}

/* Bg */
.bg-custom {
    /* background-color: #C70000; */
    /* background: linear-gradient(to right, rgb(51, 139, 147), rgb(182, 244, 146)); */
    background: linear-gradient(89deg, #005F3A 0.1%, #0D3E29 51.5% 100.2%);

    /* background: linear-gradient(89deg, rgb(21, 74, 189) 0.1%, rgb(26, 138, 211) 51.5%, rgb(72, 177, 234) 100.2%); */
    /* background:  #015A36; */
    /* background: linear-gradient(109.6deg, rgba(114, 231, 159, 0.8) 11.2%, rgb(100, 178, 249) 91.1%); */
    color: white !important;
}

.card-primary.card-outline {
    border-top: 3px solid #005F3A;
}

/* text-color */
.text-custom {
    color: rgb(51, 139, 147);
}

/* Btn Design */
/* .btn {
    border-radius: 0.5rem;
} */

/* Modal Design */
.modal-content {
    border: 0 !important;
    border-radius: 15px !important;
}

/* Border radius Custom */
.border-custom {
    border-radius: 15px !important;
}

/* Search Box */
.group {
    display: flex;
    line-height: 28px;
    align-items: center;
    position: relative;
    max-width: 190px;
}

.input-search {
    width: 100%;
    height: 40px;
    line-height: 28px;
    padding: 0 1rem;
    padding-left: 2.5rem;
    border: 2px solid transparent;
    border-radius: 8px;
    outline: none;
    background-color: #f3f3f4;
    color: #0d0c22;
    transition: .3s ease;
}

.input-search::placeholder {
    color: #9e9ea7;
}

/* input:hover {
    outline: none;
    border-color: rgba(234, 76, 137, 0.4);
    background-color: #fff;
    box-shadow: 0 0 0 4px rgb(234 76 137 / 10%);
} */

.input-custom {
    width: 100%;
    height: 40px;
    line-height: 28px;
    padding: 0 1rem;
    /* padding-left: 2.5rem; */
    border: 2px solid transparent;
    border-radius: 8px;
    outline: none;
    background-color: #f3f3f4;
    color: #0d0c22;
    transition: .3s ease;
}

.input-custom::placeholder {
    color: #9e9ea7;
}

/* .input-custom:focus,
input:hover {
    outline: none;
    border-color: rgba(234, 76, 137, 0.4);
    background-color: #fff;
    box-shadow: 0 0 0 4px rgb(234 76 137 / 10%);
} */

.icon {
    position: absolute;
    left: 1rem;
    fill: #9e9ea7;
    width: 1rem;
    height: 1rem;
}

.select2-container--default .select2-selection--multiple .select2-selection__choice {
    background-color: rgb(72, 177, 234);
    border-color: rgb(26, 138, 211) !important;
}

/*
        .form-control-sm {
            border-radius: 0.5rem;
        }

        .form-control {
            border-radius: 0.5rem;
        } */

div:where(.swal2-container) div:where(.swal2-popup) {
    border-radius: 15px !important;
}

/* ********************************* end custom ********************************* */

/* The switch - the box around the slider */
.switch {
    font-size: 17px;
    position: relative;
    display: inline-block;
    width: 3em;
    height: 1.5em;
}

/* Hide default HTML checkbox */
.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

/* The slider */
.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cc1100;
    transition: .4s;
    border-radius: 6px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 1em;
    width: 1em;
    border-radius: 4px;
    left: 0.25em;
    bottom: 0.25em;
    transform: rotate(270deg);
    background-color: rgb(255, 255, 255);
    transition: .4s;
}

.switch input:checked+.slider {
    background-color: #4bc6ff;
}

.switch input:checked+.slider:before {
    transform: translateX(1.5em);
}

/* switch 2 */

.switch2 {
    font-size: 13px;
    position: relative;
    display: inline-block;
    width: 3.5em;
    height: 2em;
}

/* Hide default HTML checkbox */
.switch2 input {
    opacity: 0;
    width: 0;
    height: 0;
}

/* The slider */
.slider2 {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    border-radius: 30px;
    box-shadow: 0 0 0 2px #508D69;
    border: 4px solid transparent;
    overflow: hidden;
    transition: .4s;
    background: transparent;
}

.slider2:before {
    position: absolute;
    content: "";
    width: 100%;
    height: 100%;
    border-radius: 30px;
    background-color: #508D69;
    transform: translateX(-50%);
    transition: .4s;
}

input:checked+.slider2 {
    background-color: rgb(182, 244, 146);
}

input:focus:checked+.slider2 {
    box-shadow: 0 0 0 2px #508D69, 0 0 4px #777;
}

input:checked+.slider2:before {
    transform: translateX(1.5em);
}

/* Dropzone */
.dropzone .dz-preview .dz-image img {
    width: 100% !important;
    display: block;
}

/* .fa-exclamation-triangle:before,
        .fa-triangle-exclamation:before,
        .fa-warning:before,
        .fa-bell:before {
            color: white !important;
        } */

/* CKEditor */
.ck-editor__editable[role="textbox"] {
    /* editing area */
    min-height: 200px;
}

/* Sidebar menu tree */
.custom-icon {
    font-size: 5px;
    text-align: center;
    vertical-align: middle;
    /* ปรับขนาดตามที่คุณต้องการ */
}

/* datatable */
table {
    width: 100% !important;
}

.table thead th {
    border-bottom: 0.3px solid #dee2e69f;
}

div.dataTables_scrollBody {
    border-left: 0px !important;
}

.table td {
    vertical-align: 0;
    border-top: 0.3px solid #dee2e69f;
}

.table th {
    border-top: 0;
}

body {
    /* font-family: kanit !important; */
    font-family: 'Inter', sans-serif;
}

.uploadBox {
    width: 100px;
    height: auto;
}
.select2-selection--single {
    height: 38px !important;
    padding-top: 0.6rem !important;
    width: 100% !important;
}
.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 35px !important;
}
.select2-container {
    display: block !important;
}

.navication {
    cursor: pointer;
}

.empty-data{
    text-align: center;
    color: #ccc;
}
    .empty-data::after {
        content: "- no data -";
    }

.custom-control.custom-switch .custom-control-label{
    cursor: pointer;
}

.bs.alert.alert-danger {
    color: #721c24;
    background-color: #f8d7da;
    border-color: #f5c6cb;
}
.bs.alert.alert-success {
    color: #155724;
    background-color: #d4edda;
    border-color: #c3e6cb;
}

#progress button {
    box-shadow: 0 0 1px rgba(0, 0, 0, .125), 0 1px 3px rgba(0, 0, 0, .2);
    padding: 12px;
}

/* width */
::-webkit-scrollbar {
    height: 5px;
    width: 5px;
}

/* Track */
::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

/* Handle */
::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 5px;
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
    background: #555;
}

/* Chrome, Safari, Edge, Opera */
.digit-group input::-webkit-outer-spin-button,
.digit-group input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

/* Firefox */
.digit-group input[type=number] {
    -moz-appearance: textfield;
}

table th, table td {
    white-space: nowrap;
}

input[readonly] {
    background-color: #fffffa !important;
    cursor: not-allowed;
}

input.decimal {
    text-align: right !important;
}

.js-delete {
    cursor: pointer;
}

.readonly {
    /* background-color: #EAF4F4 !important; */
    background-color: #fffffa !important;
    pointer-events: none;
}

table.dataTable > tbody > tr.selected > * {
    box-shadow: inset 0 0 0 9999px rgba(211, 211, 211, 0.3) !important;
    color: #000 !important;
}

table > tbody > tr.invalid > * {
    border-bottom: 1px solid red;
}
