  /* side bar */
  .sidebar {
    width: 100%;
    background-color: #fff;
    color: red;
    transition: all 0.3s;
  }
  
  .sidebar a {
    color: black;
    text-decoration: none;
    padding: 15px;
    display: block;
    transition: background 0.3s, color 0.3s;
  }
  
  .sidebar a:hover {
    background-color: #4E8E8B;
    color: #fff;
  }
  .sub-menu a:hover{
    background-color: #4E8E8B;
    color: #fff !important;
  }

  #side-menu a:hover{
    background-color: #4E8E8B;
    color: #fff !important;
  }
  .content {
    flex-grow: 1;
    padding: 20px;
    background-color: #f8f9fa;
  }
  
  .active-sidemenu {
    background-color: #40807D !important;
    color: #fff !important;
  }

  .mm-active .active {
    /* color: var(--bs-sidebar-menu-item-active-color) !important; */
    color: #fff !important;
}


  .card{
    border-radius: 1rem !important;
  }
  
  body[data-layout="horizontal"] {
    .container-fluid,
    .navbar-header {
        max-width: 100% !important;
    }
    }
    .active-sidemenu {
    background-color: #40807D !important;
    /* color: #fff !important; */
  }
  /* end side bar */

  
.main_card {
    background-color: rgba(231, 228, 227, 0.5);
    /* สีโปร่งใส 50% */
    border-radius: 1rem;
}


#sidebar-menu .mm-active > .has-arrow:after {
  -webkit-transform: rotate(90deg);
          transform: rotate(90deg);
}

#sidebar-menu .has-arrow:after {
  content: "\f0142";
  font-family: "Material Design Icons";
  display: block;
  float: right;
  -webkit-transition: -webkit-transform 0.2s;
  transition: -webkit-transform 0.2s;
  transition: transform 0.2s;
  transition: transform 0.2s, -webkit-transform 0.2s;
  font-size: 1.1rem;
  margin-left: -5px;
  margin-top: -2px;
}
body[data-sidebar-size=sm] .vertical-menu #sidebar-menu > ul > li > a.has-arrow:after {
  display: none;
}

body[data-sidebar-size=sm] #sidebar-menu .mm-active > .has-arrow:after {
  -webkit-transform: rotate(0deg);
          transform: rotate(0deg);
}

body[data-sidebar-size=md] .vertical-menu .has-arrow:after,
body[data-sidebar-size=md] .vertical-menu .badge,
body[data-sidebar-size=md] .vertical-menu .sidebar-alert {
display: none !important;
}
[dir=rtl] #sidebar-menu .has-arrow:after {
  content: "\f0141";
}



/* button download */
.floating-button {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 1040;
  border-radius: 50% !important;
  width: 50px;
  height: 50px;
  background-color: #40807D !important;
  color: white !important;
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  cursor: pointer;
  transition: transform 0.3s ease, background-color 0.3s ease;
}

.floating-button:hover {
  transform: scale(1.1);
  background-color: #31665c;
}

.floating-button span {
  font-size: 1.5rem;
  position: absolute;
  transition: transform 0.5s ease, opacity 0.5s ease;
}

.floating-button.open .fa-floppy-disk {
  transform: rotate(-90deg); /* rotate three points */
  opacity: 0; /* hide */
}

.floating-button.open .fa-times {
  transform: rotate(0deg); /* rotate back to normal */
  opacity: 1; /* แสดง */
}

.floating-button .fa-times {
  opacity: 0; /* hide the cross */
  transform: rotate(90deg); /* Set default settings */
  transition: transform 0.5s ease, opacity 0.5s ease;
}




.floating-button:hover {
  background-color: #9af0da !important; 
  color: #000000 !important;
}

#dropdown-menu {
  z-index: 1040; 
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); 
  --bs-dropdown-link-hover-bg: #40807D !important; 
  --bs-dropdown-link-hover-color: white !important;
  
}

#dropdown-menu a:hover {
  background-color: #40807D !important; 
  color: white !important;
}

/* Hide the default submenu */
.submenu_dash {
  max-height: 0; 
  overflow: hidden;
  list-style: none; 
  margin: 0; 
  padding: 0; 
  transition: max-height 0.3s ease-out; 
}

/* Change color when Hover */
.submenu_dash a:hover {
  background-color: #f7f7f7 !important; 
  color: rgb(97, 190, 175) !important; 
}

/* Show sub-menu when opened */
.submenu_dash.show {
  max-height: 200px; 
  transition: max-height 0.3s ease-in; 
}

.custom-tooltip {
  font-size: 16px;
  font-weight: bold;
  color: #333;
  background: rgba(255, 255, 255, 0.9);
  padding: 5px;
  border-radius: 5px;
  border: 1px solid #ccc;
  font-family: 'Anuphan';
}
/* end button download */

.card-title {
  font-size: 1.25rem !important;
}

.card-subtitle{
  font-size: 1rem !important;
}


.btn-close {
  --bs-btn-close-focus-shadow: 0 0 0 0.15rem rgb(25 121 108 / 25%) !important;
}


.layer-select-container-2col {
  display: grid;
  grid-template-columns: repeat(2, 1fr); /* Arrange in 2 columns */
  gap: 10px; /* Distance between boxes */
  padding: 10px 0; /* Inner distance */
}

.layer-select-container-2col label {
  display: flex;
  align-items: center; /* Align the center of each option */
  gap: 5px; /* The distance between the radio button and the message */
  font-size: 1rem; /* Font size */
}


.layer-select-container-3col {
  display: grid;
  grid-template-columns: repeat(3, 1fr); /* Arrange in 2 columns */
  gap: 10px; /* Distance between boxes */
  padding: 10px 0; /* Inner distance */
}

.layer-select-container-3col label {
  display: flex;
  align-items: center; /* Align the center of each option */
  gap: 5px; /* The distance between the radio button and the message */
  font-size: 1rem; /* Font size */
}


.tag_nationwide {
  position: absolute !important;
  top: 15px;
  right: 10px;
  background-color: rgba(179, 229, 219, 0.5);
  color: #4B908E;
  padding: 5px 5px;
  font-weight: bold;
  border-radius: 5px;
}


/* tag_nationwide for screen */
@media (max-width: 1600px) {
  .tag_nationwide {
    font-size: 12px;
    top: 10px;
    right: 5px;
    padding: 3px 4px;
  }
}

@media (max-width: 768px) {
  .tag_nationwide {
    font-size: 11px;
    top: 10px;
    right: 5px;
    padding: 3px 4px;
  }
}

@media (max-width: 480px) {
  .tag_nationwide {
    font-size: 10px;
    top: 8px;
    right: 3px;
    padding: 2px 3px;
  }
}

@media (max-width: 320px) {
  .tag_nationwide {
    font-size: 9px;
    top: 5px;
    right: 2px;
    padding: 1px 2px;
  }
}

/* DarkMode */
[data-bs-theme=dark] {
  .card_le {
    border: 0.2rem solid rgb(44, 48, 46) !important;
  }

  .main_card {
    background-color: rgb(52, 54, 53);

  }

  .header_dash_left {
    background-color: #2C302E;
    border-radius: 1rem;
  }

  .tag_nationwide {
    background-color: rgba(179, 229, 219, 0.1);
    color: #4B908E;
    padding: 5px 5px;
    font-weight: bold;
    border-radius: 5px;
  }

  .expand-button {
    color: #4B908E;
  }

  .card_rd_r {
    background-color: #b3e5dba8 !important;
  }

  .card_rd_l {
    background-color: #e5b3b3bb !important;
  }

  .submenu_dash a:hover {
    background-color: rgba(121, 121, 121, 0.199) !important;
  }

  .table-striped>tbody>tr:nth-child(odd)>td,
  .table-striped>tbody>tr:nth-child(odd)>th {
    background-color: #7dfff61f;
  }

  .group-bg-1 td {
    background-color: #7dfff61f !important;
    /* border-bottom: 1px solid #dee2e6; */
  }
}
