.app-default, body {
    background-color: #f1f2f5;
}

[data-kt-app-layout=dark-sidebar] .app-sidebar {
    background-color: #273345 !important;
    border-right: 0;
}

.login-page{
    background-color: #273345 !important;
}

.btn.btn-dark {
    background-color: #273345 !important;
}

.btn.btn-dark:hover:not(.btn-active) {
    background-color: #36475d !important;
}

#kt_app_header .app-container {
    background-color: #d8e0ec !important;
    border-right: 0;
}

body {
    font-size: 16px !important;
    font-family: "Noto Sans Thai", sans-serif;
    font-optical-sizing: auto;
    /*font-weight: <weight>;*/
    font-style: normal;
    font-variation-settings: "wdth" 100;
}
h1, h2, h3, h4, h5, h6 {
    /*font-family: "Pridi", serif;*/
    font-family: "Noto Sans Thai", sans-serif;
}
.e-feed-color {
    color: #747474;
}
label {
    font-size: 15px !important;
    color: #4d5a6d !important;
}
.form-check-label {
    color: #4d5a6d !important;
}
.btn {
    font-family: "Noto Sans Thai", sans-serif;
    font-weight: 600 !important;
}
.menu-title {
    font-family: "Noto Sans Thai", sans-serif;
    font-weight: 400 !important;
    font-size: 16px !important;
}
.card-label {
    font-family: "Noto Sans Thai", sans-serif;
    font-size: 18px !important;
}

.custom-card{
    margin-top: -35px;
}
@media (max-width: 990px) {
    .custom-card {
        margin-top: 15px;
    }
}

.form-control {
    font-family: "Noto Sans Thai", sans-serif;
    font-size: 16px !important;
}
.separator {
    border-top: 1px solid #ccc;
    margin: 20px 0;
    width: 100%;
}
.th-bg th{
    /*background-color: #747474 !important;*/
    /*color: #ffffff !important;*/
    font-size: 14px !important;
    font-family: "Noto Sans Thai", sans-serif;
}
tr td {
    font-size: 14px !important;
}
.btn-manage {
    color: #00b050 !important;
    font-weight: 700 !important;
    border: 1px solid #00b050 !important;
    background-color: #fff !important;
    box-shadow: none !important;
}
.btn-manage i {
    color: #00b050 !important;
}
.btn-manage:hover,
.btn-manage:focus {
    background-color: #00b050 !important;
    color: #fff !important;
    border-color: #00b050 !important;
}
.btn-manage:hover i,
.btn-manage:focus i {
    color: #fff !important;
}
[data-bs-theme=light] {
    --bs-header-link-bg-color: linear-gradient(180deg, #0cf09c 0%, #00a15e 100%);
}
.app-header-menu .menu>.menu-item>.menu-link {
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    width: 120px;
    height: 80px
}

.select2-selection--multiple {
    height: auto !important;
}

@media (min-width: 992px) {
    .header {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-pack: justify;
        -ms-flex-pack: justify;
        justify-content: space-between;
        -webkit-transition: height 0.3s ease;
        transition: height 0.3s ease;
        position: relative;
        z-index: 2;
    }
    .header .header-top {
        height: 70px;
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-align: stretch;
        -ms-flex-align: stretch;
        align-items: stretch;
        background-color: #0057B8;
    }
    .header .header-top .container,
    .header .header-top .container-fluid,
    .header .header-top .container-sm,
    .header .header-top .container-md,
    .header .header-top .container-lg,
    .header .header-top .container-xl,
    .header .header-top .container-xxl {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-align: stretch;
        -ms-flex-align: stretch;
        align-items: stretch;
        -webkit-box-pack: justify;
        -ms-flex-pack: justify;
        justify-content: space-between;
    }
    .header .header-bottom {
        height: 55px;
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-align: stretch;
        -ms-flex-align: stretch;
        align-items: stretch;
        background-color: #ffffff;
    }
    .header .header-bottom .container,
    .header .header-bottom .container-fluid,
    .header .header-bottom .container-sm,
    .header .header-bottom .container-md,
    .header .header-bottom .container-lg,
    .header .header-bottom .container-xl,
    .header .header-bottom .container-xxl {
        display: -webkit-box;
        display: -ms-flexbox;
        display: flex;
        -webkit-box-align: stretch;
        -ms-flex-align: stretch;
        align-items: stretch;
        -webkit-box-pack: justify;
        -ms-flex-pack: justify;
        justify-content: space-between;
    }
    .header-fixed .header {
        position: fixed;
        top: 0;
        right: 0;
        left: 0;
        z-index: 97;
        height: 70px;
        -webkit-box-shadow: none;
        box-shadow: none;
    }
    .header-fixed.header-bottom-enabled .header {
        height: 145px;
        -webkit-box-shadow: 0px 10px 30px 0px rgba(82, 63, 105, 0.08);
        box-shadow: 0px 10px 30px 0px rgba(82, 63, 105, 0.08);
    }
}

header-fixed .wrapper {
    padding-top: 0px;
}

.header-bottom {
    background-color: #FFFFFF !important;

}
@media (min-width: 992px) {
    .header-bottom {
        background-color: #17c653 !important;
    }
}

/* พื้นหลัง header เต็มจอ */
.header-bottom {
    width: 100% !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* Container ด้านใน */
.header-bottom .container-fluid {
    width: 100% !important;
    max-width: 100% !important;
    padding: 0 !important;
}

/* เมนูจัดกึ่งกลางทั้งแนวนอนและแนวตั้ง */
#kt_header_menu {
    display: flex !important;
    justify-content: center !important; /* กึ่งกลางซ้าย-ขวา */
    align-items: center !important;    /* กึ่งกลางบน-ล่าง */
    width: 100% !important;
    height: 100% !important;
}

/* เมนูไอเท็ม */
#kt_header_menu .menu-item {
    margin: 0 8px; /* ระยะห่างซ้าย-ขวา */
}

/* เมนูหลัก ปกติ */
#kt_header_menu > .menu-item > a.menu-link,
#kt_header_menu > .menu-item > span.menu-link {
    color: #ffffff !important;
    background-color: #17c653 !important;
}

/* เมนูหลัก Hover */
#kt_header_menu > .menu-item > a.menu-link:hover,
#kt_header_menu > .menu-item > span.menu-link:hover {
    color: #4b5675 !important;
    background-color: #ffffff !important;
}

/* เมนูหลัก Active (ป้องกันไม่ให้กลายเป็นสีม่วง) */
#kt_header_menu .menu-link.active {
    color: #ffffff !important;
    background-color: #17c653 !important;
}

/* เมนูย่อย ปกติ */
#kt_header_menu .menu-sub .menu-item > a.menu-link,
#kt_header_menu .menu-sub .menu-item > span.menu-link {
    color: #4b5675 !important;
    background-color: #ffffff !important;
}

/* เมนูย่อย Hover */
#kt_header_menu .menu-sub .menu-item > a.menu-link:hover,
#kt_header_menu .menu-sub .menu-item > span.menu-link:hover {
    color: #ffcc00 !important;
    background-color: #E4E6EF !important;
}

/* เมนูย่อย Active */
#kt_header_menu .menu-sub .menu-item > a.menu-link.active,
#kt_header_menu .menu-sub .menu-item.show > a.menu-link {
    color: #ffcc00 !important;
    background-color: #E4E6EF !important;
}

.dropzone {
    border: 2px dashed #009ef7;
    border-radius: 1rem;
    background-color: #f9f9f9 !important;
    min-height: 250px;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 20px;
    transition: background-color 0.2s ease-in-out, border-color 0.2s;
}

.dropzone:hover {
    background-color: #eef9ff;
    border-color: #0d6efd;
}

.dropzone .dz-message {
    margin: 0;
}

.table-fixed {
    table-layout: fixed;
    min-width: 600px;
    width: 100%;
}

.table-fixed th,
.table-fixed td {
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.table-fixed .col-index   { width: 80px; text-align: center; }
.table-fixed .col-action  { width: 100px; text-align: center; }
.table-fixed .col-actionGrp  { width: 170px; text-align: center; }
.table-fixed .col-main    { width: auto; }

/* ====== ThaID Modal Style ====== */
.thaid-modal{
    --bs-modal-bg: transparent; /* ตัดพื้นหลังขาวเดิมของ modal-content */
    background: #2F5DA6;        /* น้ำเงินโทนใกล้ภาพ */
    color: #fff;
    box-shadow: 0 12px 40px rgba(0,0,0,.25);
    border: 1px solid rgba(255,255,255,.15);
}

.thaid-modal-body{ position: relative; }

/* กล่อง QR พื้นขาวกรอบบาง */
.thaid-qr{
    background:#fff;
    padding: .9rem;
    border-radius: .35rem;
    box-shadow: 0 2px 10px rgba(0,0,0,.12);
    border: 1px solid rgba(0,0,0,.05);
}
.thaid-qr img{
    width: 260px; height: 260px; object-fit: contain; display: block;
}

/* คำอธิบายและเวอร์ชัน */
.thaid-caption{ font-size: .92rem; opacity: .95; }
.thaid-version{ position:absolute; right:.5rem; bottom:.3rem; font-size:.8rem; opacity:.8; }

/*register*/

.choice{
    cursor:pointer; display:flex;
    flex-direction:column;
    border:1px solid var(--bs-gray-200);
    border-radius:.8rem;
    padding:1rem 1rem 1.25rem;
    min-width:200px; background:#fff;
    transition:box-shadow .15s ease,
    transform .15s ease;
}
.choice:hover{ transform:translateY(-1px); box-shadow:0 8px 20px rgba(0,0,0,.08); }

.choice-box{
    border:2px dashed #d7d7d7; border-radius:.8rem; min-height:128px;
    display:flex; align-items:center; justify-content:center; background:#fff;
}

.icon-circle{
    width:74px; height:74px; border-radius:50%;
    background:#111; display:flex; align-items:center; justify-content:center;
}

.choice-foot{
    display:flex; align-items:center; gap:.5rem; margin-top: .9rem; padding-left:.25rem;
}
.choice .form-check-input{ width:18px; height:18px; border-width:2px; }
.choice-title{ font-weight:600; color:#2b2b2b; }

.choice:has(.choice-radio:checked) .choice-box{
    border-color: var(--bs-gray-400);
    box-shadow: inset 0 0 0 2px rgba(0,0,0,.02);
}

@media (max-width: 575.98px){ .choice{ min-width:100%; } }

.form-label-custom {
    font-weight: bolder;
    color: #000000;
    margin-bottom: .5rem;
    font-size: 1.05rem;
}

.btn-custom-form-sm {
    min-height: calc(1.5em + 1.1rem + 2px)!important;
    padding: .55rem .75rem;
    font-size: .95rem;
    border-radius: .425rem
}