/* style.css */


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

:root {
    --color1: #006A71;
    --color2: #48A6A7;
    --color3: #9ACBD0;
    --color4: #F2EFE7;

}
a {
    text-decoration: none;
}


/* ใช้ฟอนต์กับทั้งเว็บไซต์ */
body {
    /* font-family: "Sarabun", sans-serif; */
    font-family: "Prompt", sans-serif;
    background-color: #E6E6E6;
    /* font-size: 17px; */
}

.navbar {
    background-color: var(--color1);
    ;
    color: white;
}

.icon-fixed {
    width: 20px; /* กำหนดขนาดไอคอนให้เท่ากัน */
    text-align: center; /* จัดให้อยู่ตรงกลาง */
    margin-right: 10px; /* ระยะห่างระหว่างไอคอนกับข้อความ */
}


#sidebar {
    width: 250px;
    height: 100vh;
    /* Make sidebar full height */
    position: fixed;
    /* Fix sidebar position */
    top: 0;
    left: 0;
    transition: all 0.3s;
    white-space: nowrap;
    background-color: #fff;
    color: #9F9498;
}



#sidebar .nav .collapse .nav-link:hover {
    background-color: var(--color3);
    color: #fff;
    border-radius: 8px;
}


.collapsed-sidebar {
    display: none !important;
}

/* Default hide sidebar only on small screens */
@media (max-width: 768px) {
    #sidebar {
        display: none;
    }
}

.content-wrapper {
    margin-left: 250px;
    transition: margin-left 0.3s;
    width: calc(100% - 250px);
}

.content-wrapper.full-width {
    margin-left: 0;
    width: 100%;
}

.content-wrapper {
    background-color: #E6E6E6;
    min-height: 100vh;
    padding-bottom: 30px;
    /* Make sidebar full height */
}



.pagination-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    align-items: center;
    gap: 5px;
    margin-top: 20px;
}

.pagination-item {
    padding: 8px 12px;
    border: 1px solid var(--color4);
    background-color: var(--color4);
    cursor: pointer;
    text-decoration: none;
    color: black;
    display: inline-block;
}

.pagination-item.active {
    background-color: var(--color2);
    color: white;
    font-weight: bold;
}

.pagination-item.disabled {
    color: #ccc;
    pointer-events: none;
}


.textcolor1{
    color: var(--color1);
}

.btn-primary{background-color: var(--color2); border-color:  var(--color2);}
.btn-primary:hover{background-color: var(--color1); }

.btn-secondary{background-color: var(--color3); border-color:  var(--color3);}
.btn-secondary:hover{background-color: var(--color1); }


.table-primary {
    background-color: var(--color2) !important; /* ปรับสีให้เป็นม่วงเข้ม */
    color: white !important;
}
.table-primary th, .table-primary td {
    background-color: var(--color2) !important;
    border-color: #fff;
    color: white
}

.dt-input {
    margin-right: 10px; /* ปรับค่า px ตามต้องการ */
}

#sidebar h4 a {
    color: var(--color1); /* ใช้สีหลักจาก root */
    font-weight: bold;
}

h1{
    font-size: 24px;
    color: var(--color1); /* ใช้สีหลักจาก root */
}




    :root {
      --color1: #006A71;
      --color2: #48A6A7;
    }
    /* Floating chat button */
    #chat-button {
      position: fixed;
      bottom: 20px;
      right: 20px;
      background: var(--color2);
      color: #fff;
      width: 60px;
      height: 60px;
      border-radius: 50%;
      display: flex;
      align-items: center;
      justify-content: center;
      cursor: pointer;
      box-shadow: 0 2px 8px rgba(0,0,0,0.2);
      z-index: 1050;
    }
    /* Chat window (ซ่อนตั้งแต่ต้น) */
    #chat-window {
      position: fixed;
      bottom: 90px;
      right: 20px;
      width: 300px;
      max-height: 400px;
      background: #fff;
      border-radius: 8px;
      box-shadow: 0 2px 12px rgba(0,0,0,0.3);
      display: none; /* ซ่อน */
      overflow: hidden;
      z-index: 1050;
      flex-direction: column;
    }
    #chat-window.flex {
      display: flex;
    }
    #chat-window .chat-header {
      background: var(--color1);
      color: #fff;
      padding: 8px 12px;
      font-weight: bold;
      display: flex;
      justify-content: space-between;
      align-items: center;
    }
    #chat-window .chat-messages {
      flex: 1;
      padding: 8px;
      overflow-y: auto;
      font-size: 14px;
    }
    #chat-window .chat-messages .msg {
      margin-bottom: 8px;
      padding: 6px 10px;
      border-radius: 12px;
      display: inline-block;
      max-width: 80%;
      clear: both;
    }
    #chat-window .chat-messages .msg.user {
      background: var(--color2);
      color: #fff;
      float: right;
    }
    #chat-window .chat-messages .msg.bot {
      background: #f1f1f1;
      color: #333;
      float: left;
    }
    #chat-window .chat-messages .msg.typing {
      background: transparent;
      color: #999;
      font-style: italic;
      padding: 0;
      margin-bottom: 8px;
      float: left;
    }
    #chat-window .chat-input {
      padding: 8px;
      border-top: 1px solid #ddd;
      display: flex;
    }
    #chat-window .chat-input input {
      flex: 1;
    }
