
/* UI Elements - Start -------------------------------------------------------------------- */

.daexthefu-button{
  background: $primary-wordpress-100;
  color: $neutral-grey-0;
  height: 22px;
  line-height: 22px;
  padding: 4px 12px;
  border: 1px solid rgba($neutral-branded-800, 0.2);
  font-size: $fs-2;
  border-radius: $radius-md;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
  transition-property: background, border, box-shadow;
}

.daexthefu-button:hover{
  background: $primary-wordpress-500;
  color: $neutral-grey-0;
}

.daexthefu-admin-page-button{

  height: 40px;
  padding: 0 16px !important;
  border-radius: $radius-md !important;

  &:hover {
    //background-color: lighten($primary-50, 2%);
    border-color: $primary-wordpress;
    color: $primary-wordpress;
  }
  &:focus {
    //background-color: lighten($primary-50, 2%);
    outline: $outline;
    color: $primary-wordpress;
  }

}

/* Style for primary and secondary buttons - Start -------------------------------------------------------- */

.daexthefu-btn{
  border-width: 1px;
  border-style: solid;
  line-height: 22px;
  padding: 8px 16px;
  font-size: $fs-2;
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
  transition-property: background, border, box-shadow;
  margin: 0;
}

.daexthefu-btn:hover{
  cursor: pointer;
}

.daexthefu-btn-primary{
  background: $primary-wordpress-100;
  color: $neutral-grey-0;
  border-color: rgba($neutral-branded-800, 0.2);
}

.daexthefu-btn-primary:hover{
  background: $primary-wordpress-500;
  color: $neutral-grey-0;
}

.daexthefu-btn-secondary{
  background: transparent;
  color: $primary-wordpress-100 !important;
  border-color: $primary-wordpress-100;
}

.daexthefu-btn-secondary:hover{
  background-color: $neutral-branded-100;
}

.daexthefu-btn:disabled{
  background-color: $neutral-branded-150;
  border-color: $neutral-branded-200;
  color: $neutral-branded-400 !important;
  transition: none;
  pointer-events: none;
  box-shadow: none;
}

/* Style for primary and secondary buttons - End -------------------------------------------------------- */

/*

Style for input type="file" button - Start --------------------------------------------------------

Ref:

- https://stackoverflow.com/questions/572768/styling-an-input-type-file-button
- https://stackoverflow.com/questions/2189615/how-to-get-file-name-when-user-select-a-file-via-input-type-file

*/

.daexthefu-input-wrapper{
  padding-top: 16px;
  padding-right: 16px;
  padding-bottom: 16px;
  padding-left: 16px;
  border-width: 1px;
  border-style: solid;
  border-color: $neutral-branded-300;
  border-radius: 6px;
  display: flex;
  gap: 16px;
}

.daexthefu-upload-submit-container{
  margin: 24px 0;
}

.custom-file-upload-input {
  display: none;
}

.custom-file-upload {
  border-width: 1px;
  border-style: solid;
  line-height: 22px;
  padding: 8px 16px;
  font-size: $fs-2;
  border-radius: 6px;
  text-decoration: none;
  transition: all 0.2s ease-in-out;
  transition-property: background, border, box-shadow;
  background: transparent;
  color: $primary-wordpress-100 !important;
  border-color: $primary-wordpress-100;
  cursor: pointer;
}

.custom-file-upload-text{
  font-size: 14px;
  line-height: 20px;
  padding: 10px 0;
}

/* Style for input type="file" button - End --------------------------------------------- */

/* UI Elements - End -------------------------------------------------------------------- */


/* Select Element Style - Start ----------------------------------------------------------------- */

select{
  height: 40px;
  border-radius: $radius-md !important;
  background-color: $neutral-grey-0 !important;
  border-color: $neutral-branded-300 !important;
  box-shadow: $elevation-1 !important;
  color: $neutral-branded-700 !important;
}

/* Select Element Style - End ----------------------------------------------------------------- */



/* Toggle Switch - Start ----------------------------------------------------------------- */

.switch {
  position: relative;
  display: inline-block;
  width: 42px;
  height: 24px;
}

.switch input {
  opacity: 0;
  width: 0;
  height: 0;
}

.slider {
  position: absolute;
  cursor: pointer;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: $neutral-grey-500;
  -webkit-transition: .4s;
  transition: .4s;
}

.slider:before {
  position: absolute;
  content: "";
  height: 20px;
  width: 20px;
  left: 2px;
  bottom: 2px;
  background-color: $neutral-grey-0;
  -webkit-transition: .4s;
  transition: .4s;
}

input:checked + .slider {
  background-color: $primary-wordpress-100;
}

input:focus + .slider {
  box-shadow: 0 0 1px $primary-branded-100;
}

input:checked + .slider:before {
  -webkit-transform: translateX(18px);
  -ms-transform: translateX(18px);
  transform: translateX(18px);
}

/* Rounded sliders */
.slider.round {
  border-radius: 12px;
  width: 42px;
  height: 24px;
}

.slider.round:before {
  border-radius: 50%;
}

/* Toggle Switch - End ----------------------------------------------------------------- */



/* Toggle Switch container - Start ----------------------------------------------------------------- */

.switch-container{
  display: flex;
  flex-direction: row;
  gap: 12px;
  align-content: center;
}

.switch-left{
  height: 24px;
}

.switch-right label{
  margin: 0 !important;
  height: 24px;
  line-height: 24px !important;
}

p.description{
  margin: 6px 0 0;
  line-height: 18px;
  max-width: 574px;
  font-size: $fs-1;
}

/* Toggle Switch container - End ----------------------------------------------------------------- */

/* Pills - Start ----------------------------------------------------------------- */

.daexthefu-pills{
  border-radius: 4px;
}

.daexthefu-pill{
  border: 1px solid $neutral-branded-300;
  cursor: pointer;
  height: 26px;
  padding: 6px 16px;
  background: $neutral-grey-0;
  box-sizing: content-box;
  color: $neutral-branded-600;
  box-shadow: 0px 1px 2px rgba($neutral-branded-800, 0.1);
}

.daexthefu-pill:first-child{
  border-top-left-radius: 4px;
  border-bottom-left-radius: 4px;
}

.daexthefu-pill:first-child:dir(rtl){
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  border-top-right-radius: 4px;
  border-bottom-right-radius: 4px;
}

.daexthefu-pill:last-child{
  border-top-right-radius: 4px;
  border-bottom-right-radius: 4px;
}

.daexthefu-pill:last-child:dir(rtl){
  border-top-left-radius: 4px;
  border-bottom-left-radius: 4px;
  border-top-right-radius: 0;
  border-bottom-right-radius: 0;
}

.daexthefu-pill:not(:first-child){
  border-left: none;
}

.daexthefu-pill:dir(rtl):not(:first-child){
  border-left: 1px solid $neutral-branded-300;
  border-right: none;
}

.daexthefu-pill[data-checked="true"]{
  background: $neutral-branded-50;
  color: $primary-wordpress-100;
}

/* Pills - End ----------------------------------------------------------------- */

/* Input Range - Start ----------------------------------------------------------------- */

.daexthefu-main-form__daext-form-field input[type="range"] {
  -webkit-appearance: none;
  width: 100%;
  height: 4px;
  background: $neutral-grey-400;
  outline: none;
  opacity: 0.7;
  -webkit-transition: .2s;
  transition: opacity .2s;
  margin-top: 18px;
  border-radius: 2px;
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 12px;
  height: 12px;
  background: $primary-wordpress-100;
  cursor: pointer;
  border-radius: 6px;
}

input[type="range"]::-moz-range-thumb {
  width: 12px;
  height: 12px;
  background: $primary-wordpress-100;
  cursor: pointer;
  border-radius: 6px;
}

/* Input Range - End ----------------------------------------------------------------- */

/* Date Picker Component - Start ----------------------------------------------- */

.daexthefu-datepicker-container{
  position: relative;
}

.daexthefu-datepicker-selection-container{
  position: absolute;
  top: 0px;
  left: 0px;
  opacity: 1;
  transform: translateX(0px) translateY(48px) translateX(0em) scale(1) translateZ(0px);
  transform-origin: 100% 100% 0px;
  background: #fff;
  padding: 8px 12px;
  box-shadow: 0 5px 15px rgba(0,0,0,.3);
  border-radius: 8px;
}

.daexthefu-datepicker-trigger{
  border-radius: 4px;
  border: 1px solid $neutral-branded-300;
  cursor: pointer;
  height: 26px;
  padding: 6px 16px;
  background: $neutral-grey-0;
  box-sizing: content-box;
  color: $neutral-branded-600;
  box-shadow: 0px 1px 2px rgba($neutral-branded-800, 0.1);
  display: flex;
  align-items: center;
  gap: 8px;
}

.daexthefu-datepicker-trigger:hover{
  background: $neutral-branded-100;
}

.daexthefu-datepicker-date-input-fields{
    display: flex;
    gap: 8px;
}

.daexthefu-datepicker-date-input-fields input[type="text"]{
  box-sizing: border-box !important;
  height: 40px !important;
  padding-right: 12px !important;
  padding-left: 12px !important;
  font-size: 13px !important;
  background-color: #fff !important;
  border-color: #d0d6dd;
  box-shadow: 0px 1px 2px rgba(29, 40, 58, .1) !important;
  border-radius: 6px !important;
  color: #344255 !important;
  margin: 0 !important;
}

.daexthefu-datepicker-date-input-fields .components-base-control__field{
  margin-bottom: 8px !important;
}

.daexthefu-datepicker-date-input-fields input[type="text"]:focus{
  border-color: $primary-branded-200;
  box-shadow: $elevation-1;
  outline: 3px solid $neutral-branded-150;
}

.daexthefu-datepicker-selected input{
  border-color: $primary-branded-200 !important;
  box-shadow: $elevation-1;
  outline: 3px solid $neutral-branded-150;
}