body {
  font-size: 12px;
  user-select: unset; /*none*/
  overflow-y: hidden;
  background-color: #151515;
  color: #eeeeee;
  margin: 0;
}

@media screen and (orientation: portrait) {
  .hidden-div {
    display: none;
  }

  #chart {
    transform: scale(0.55) !important;
  }

}

@media screen and (max-height: 640px) {
  #chart {
    transform: scale(0.52) !important;
  }

}

text {
  font-family: Helvetica, Arial, sans-serif;
  pointer-events: none;
}

.wheel {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100vw;
  height: 100vh;
  user-select: none;
}

#chart::before {
  content: url(../img/arrow.png);
  transform: scale(0.582);
  position: absolute;
  width: 100%;
  height: 100%;
  margin: 0 -186px 0 0;
  top: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  align-items: end;
  justify-content: center;
  z-index: 800;
}


#chart {
  position: relative;
  width: 600px;
  height: 600px;
  top: 0;
  left: 0;
  /*user-select: none;*/
}


#chart::after {
  content: url(../img/wheel_fd.png?v1);
  transform: scale(0.582);
  position: absolute;
  width: 100%;
  height: 100%;
  margin: 2px 0 0 -23px;
  top: 0;
  left: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  z-index: 700;
}

/* #chart::before {
    content: url(../img/logo.png);
    transform: scale(0.25);
    position: absolute;
    width: 100%;
    height: 100%;
    margin: 2px 0 0 -18px;
    top: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
  }
   */
#question {
  display: flex;
  flex-direction: column;
  word-wrap: break-word;
  text-align: center;
  width: 100%;
  margin-bottom: 32px;
}

#question h1 {
  font-size: 30px;
  font-weight: bold;
  font-family: "Helvetica Neue", Helvetica, Arial, sans-serif;
}

.bar {
  position: fixed;
  top: 0;
  right: -430px;
  max-width: 88dvw;
  width: 380px;
  height: calc(100vh - 40px);
  background-color: #151515;
  border-left: 3px solid #eeeeee;
  padding: 50px 20px 20px 20px;
  font-size: 16px;
  /*animation: slideIn 1s forwards;*/
  overflow-y: auto;
  overflow-x: hidden;
  z-index: 1000;
  box-shadow: #000000cc -6px 0px 20px 3px;
}

@keyframes slideIn {
  0% {
    right: -400px;
    opacity: 0;
  }

  100% {
    right: 0px;
    opacity: 1;
  }
}

.fade-out {
  opacity: 0;
  pointer-events: none;
  animation: FadeOut 0.5s linear;
}

@keyframes FadeOut {
  0% {
    right: 0px;
    opacity: 1;
  }

  100% {
    right: -400px;
    opacity: 0;
  }
}

.fade-in {
  opacity: 1;
  animation: FadeIn 1s forwards;
}

@keyframes FadeIn {
  0% {
    right: -400px;
    opacity: 0;
  }

  100% {
    right: 0px;
    opacity: 1;
  }
}

.x-control {
  position: fixed;
  display: flex;
  justify-content: flex-end;
  align-items: flex-start;
  margin: 15px 20px 0 0;
  z-index: 2000;
  top: 0;
  right: 0;
  opacity: 1;
  transition: opacity 0.3s ease;
}

.listspin {
  width: 100%;
  font-size: 17.95px;
  resize: vertical;
  padding-left: 5px;
  line-height: 1.28;
}

.history {
  height: 200px;
  width: 100%;
  overflow: scroll;
  overflow-x: hidden;
  overflow-y: auto;
  border: 1px solid #3a3a3a;
  margin-top: 10px;
  margin-bottom: 3px;
}

.oldlist_spin {
  list-style-type: decimal;
}

/* CSS สำหรับปุ่มทั่วไป */
.btn {
  display: inline-block;
  padding: 10px 20px;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  text-align: center;
  text-decoration: none;
  color: #FFF;
  font-size: 16px;
  font-weight: bold;
}

.btn:disabled:not(.btn-warning) {
  background-color: #3a3a3a;
  color: rgb(134, 134, 134);
  cursor: default;
}

.btn:not(:disabled):not(.btn-warning):hover {
  filter: brightness(0.85);
  animation: brightnessFade 0.2s ease-in-out;
}

@keyframes brightnessFade {
  from {
    filter: brightness(1);
  }

  to {
    filter: brightness(0.85);
  }
}

.btn-warning {
  color: #000000;
  background-color: #f9da3b;
}

.btn-sm {
  padding: 5px 10px;
  font-size: 14px;
}

.btn-default {
  color: #000000;
  background-color: #eeeeee;
}

/* CSS สำหรับปุ่มสีแดง */
.btn-danger {
  background-color: #dc3545;
}

/* CSS สำหรับปุ่มสีเขียว */
.btn-success {
  background-color: #28a745;
}

/* CSS สำหรับปุ่มสีฟ้า */
.btn-info {
  background-color: #17a2b8;
}

.btn-warning {
  color: #000000;
  background-color: #f9da3b;
  cursor: default;
}

.toggle-switch {
  position: relative;
  width: 40px;
  height: 20px;
}

.toggle-switch::before {
  content: "หน้าต่างควบคุม";
  position: absolute;
  width: 85px;
  height: 18px;
  font-size: 12px;
  top: 0px;
  right: 38px;
}

.modeInfinity-switch {
  position: relative;
  width: 40px;
  height: 20px;
}

.modeInfinity-switch::before {
  content: "เอารายการออกเมื่อหมุนเสร็จ";
  position: absolute;
  width: 195px;
  height: 18px;
  font-size: 12px;
  top: 0px;
  left: 45px;
}

.audiomode-switch {
  position: relative;
  width: 40px;
  height: 20px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-content: flex-start;
  flex-wrap: wrap;
}

.audiomode-switch::before {
  content: "ใช้เสียง";
  position: absolute;
  width: 45px;
  height: 18px;
  font-size: 12px;
  top: 0px;
  left: 45px;
}

.toggle-input {
  display: none;
}

.toggle-label {
  display: block;
  width: 100%;
  height: 100%;
  background-color: gray;
  border-radius: 17px;
  cursor: pointer;
  position: relative;
  transition: background-color 0.3s ease;
}

.toggle-label:before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background-color: white;
  border-radius: 50%;
  transition: transform 0.3s ease;
}

.audiomode-label {
  display: block;
  width: 100%;
  height: 100%;
  background-color: gray;
  border-radius: 17px;
  cursor: pointer;
  position: relative;
  transition: background-color 0.3s ease;
  margin-right: 50px;
}

.audiomode-label:before {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background-color: white;
  border-radius: 50%;
  transition: transform 0.3s ease;
}

.toggle-input:checked+.toggle-label {
  background-color: #6ab04c;
}

.toggle-input:checked+.toggle-label:before {
  transform: translateX(20px);
}

.toggle-input:checked+.audiomode-label {
  background-color: #6ab04c;
}

.toggle-input:checked+.audiomode-label:before {
  transform: translateX(20px);
}

/* สไตล์สำหรับ input select */
.select-input {
  display: inline-block;
  position: relative;
  width: 100px;
  height: 28px;
  background-color: #fff;
  border: 1px solid #ced4da;
  border-radius: 4px;
  padding: 5px 5px;
  font-size: 12px;
  line-height: 1.42857143;
}

.select-input select {
  width: 100%;
  height: 100%;
  padding: 0;
  margin: 0;
  border: none;
  outline: none;
  background: none;
  -webkit-appearance: none;
  -moz-appearance: none;
  appearance: none;
}

.select-input::after {
  content: '\f0d7';
  font-family: "Font Awesome 5 Free";
  font-weight: 900;
  position: absolute;
  top: 50%;
  right: 10px;
  transform: translateY(-50%);
  pointer-events: none;
}

/* เมื่อเลือกตัวเลือก */
.select-input select:focus+::after {
  color: #007bff;
}

.bootstrap-style-input {
  display: block;
  width: 200px;
  padding: 7px 7px;
  font-size: 14px;
  line-height: 1.5;
  color: #495057;
  background-color: #fff;
  background-clip: padding-box;
  border: 1px solid #ced4da;
  border-radius: 0.25rem;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
  text-indent: -270px;
  -webkit-user-drag: none;
}

.bootstrap-style-input-bingo {
  display: block;
  width: 140px;
  padding: 7px 7px;
  font-size: 34px;
  line-height: 1.5;
  color: #495057;
  background-clip: padding-box;
  border: none;
  border-radius: 0.25rem;
  transition: border-color 0.15s ease-in-out, box-shadow 0.15s ease-in-out;
  text-indent: 0;
  -webkit-user-drag: none;
}

.bootstrap-style-input:focus {
  border-color: #306e00;
  outline: 0;
  box-shadow: 0 0 0 1px rgba(13, 255, 0, 0.25);
}

/* CSS Styling for Modal */
.modal {
  display: none;
  position: fixed;
  z-index: 900;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.4);
  animation: fade 0.3s ease-in-out;
  color: #000000;
}

.modal-content {
  background-color: #fefefe;
  margin: 0 auto;
  padding: 20px;
  border: 1px solid #888;
  width: 80%;
  max-width: 400px;
  position: relative;
  top: 50%;
  transform: translateY(-50%);
  animation: modal-fade 0.3s ease-in-out;
  border-radius: 30px;
}

.modal-footer {
  display: flex;
  padding: 15px;
  text-align: right;
  border-top: 1px solid #ccc;
  justify-items: center;
  align-items: center;
  justify-content: center;
}

.modal-footer>h6 {
  font-size: 15px;
  color: #151515;
  font-weight: bold;
}

.close {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

.remoteID {
  margin: 20px 0 20px 0;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  font-size: 15px;
  flex-direction: column;
}

.remoteID h1 {
  margin: 0;
}

.remoteID h6 {
  font-size: 12px;
  color: #151515;
  margin: 8px 0 0 0;
  font-weight: bold;
}

.qrcode {
  width: 200px;
  height: 200px;
  border: 1px dashed #000000;
  filter: blur(5px);
  transition: width 0.3s ease, height 0.3s ease, position 0.3s ease;
  cursor: zoom-in;
  user-select: none;
  -webkit-user-drag: none;
}

.qrcode:hover {
  filter: blur(0px);
  cursor: zoom-in;
}


/* Animation keyframes */
@keyframes fade {
  from {
    opacity: 0;
  }

  to {
    opacity: 1;
  }
}

@keyframes fade-mo-out {
  from {
    opacity: 1;
  }

  to {
    opacity: 0;
  }
}

@keyframes modal-fade {
  from {
    transform: translateY(-50%) scale(0.8);
    opacity: 0;
  }

  to {
    transform: translateY(-50%) scale(1);
    opacity: 1;
  }
}

.fade-in-modal {
  animation: fade 0.3s ease-in-out;
}

.fade-out-modal {
  animation: fade-mo-out 0.3s ease-in-out;
}