$dracula_color: #675ed5;
$dracula_color_light: lighten($dracula_color, 10%);
$dracula_color_dark: darken($dracula_color, 10%);

.zero-opacity {
  opacity: 0;
}

.dracula-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 12px;
  border-radius: 0.25rem;
  font-size: 0.875rem;
  font-weight: 500;
  color: #fff;
  cursor: pointer;
  transition: all 0.2s ease-in-out;
  border: none;
  background: #000;
  user-select: none;
  line-height: normal;

  i {
    margin-right: 0.5rem;
  }

  &:hover {
    background-color: #0091c2;
    border-color: #0091c2;
  }

  &:focus {
    outline: none;
  }

  &:disabled {
    opacity: 0.5;
    cursor: not-allowed;
  }

  &.btn-primary {
    background-color: $dracula_color;

    &:hover {
      background-color: $dracula_color_dark;
    }
  }

  &.btn-purple {
    background-color: #7c5dee;
    border-color: #7c5dee;

    &:hover {
      background-color: #6f4dda;
      border-color: #6f4dda;
    }
  }

  &.btn-secondary {
    background-color: #fff;
    border-color: #fff;

    &:hover {
      background-color: #f5f5f5;
      border-color: #f5f5f5;
    }
  }

  &.btn-success {
    background-color: #28a745;
    border-color: #28a745;

    &:hover {
      background-color: #28a745;
      border-color: #28a745;
    }
  }

  &.btn-warning {
    background-color: #f9d6b7;
    color: #a65300;

    &:hover {
      background-color: #ffcc99;
    }
  }

  &.btn-danger {
    background-color: #f8d7da;
    color: #d8000c;

    .dracula-btn-icon {
      background: #d8000c;
    }

    &:hover {
      background-color: #f5c6cb;
    }
  }

  &.btn-info {
    background-color: #b4d8e7;
    color: #1f4e6e;

    .dracula-btn-icon {
      background: #1f4e6e;
    }

    &:hover {
      background-color: #00a5e6;
    }
  }

  &.btn-light {
    background-color: #f8f9fa;
    border-color: #f8f9fa;
    color: #000;

    &:hover {
      background-color: #f8f9fa;
      border-color: #f8f9fa;
    }
  }

  &.btn-dark {
    background-color: #343a40;
    border-color: #343a40;
    color: #fff;

    &:hover {
      background-color: #343a40;
      border-color: #343a40;
    }
  }

  &.btn-link {
    background-color: transparent;
    border-color: transparent;
    color: #00a0d2;

    &:hover {
      background-color: transparent;
      border-color: transparent;
      color: #0091c2;
    }
  }

  &.btn-outline-primary {
    background-color: #fff;
    border: 1px solid $dracula_color_light;
    color: $dracula_color;

    &:hover {
      background-color: $dracula_color;
      border-color: $dracula_color_light;
      color: #fff;
    }
  }

  &.btn-outline-secondary {
    background-color: transparent;
    border-color: #fff;
    color: #fff;

    &:hover {
      background-color: transparent;
      border-color: #f5f5f5;
      color: #f5f5f5;
    }
  }

  &.btn-outline-success {
    background-color: transparent;
    border: 1px solid #28a745;
    color: #28a745;

    &:hover {
      background-color: #28a745;
      color: #fff;
    }
  }

  &.btn-outline-danger {
    background-color: #fff;
    border: 1px solid #eb5757;
    color: #eb5757;

    &:hover {
      background-color: #eb5757;
      color: #fff;
    }
  }

  &.btn-outline-warning {
    background-color: transparent;
    border-color: #ffc107;
    color: #ffc107;

    &:hover {
      background-color: transparent;
      border-color: #ffc107;
      color: #ffc107;
    }
  }

  &.btn-outline-info {
    background-color: #fff;
    border: 1px solid #17a2b8;
    color: #17a2b8;

    &:hover {
      background-color: #17a2b8;
      color: #fff;
    }
  }

  &.btn-outline-light {
    background-color: transparent;
    border-color: #f8f9fa;
    color: #f8f9fa;

    &:hover {
      background-color: transparent;
      border-color: #f8f9fa;
      color: #f8f9fa;
    }
  }

  &.btn-outline-dark {
    background-color: transparent;
    border-color: #343a40;
    color: #343a40;

    &:hover {
      background-color: transparent;
      border-color: #343a40;
      color: #343a40;
    }
  }

  &.btn-outline-link {
    background-color: transparent;
    border-color: #00a0d2;
    color: #00a0d2;

    &:hover {
      background-color: transparent;
      border-color: #0091c2;
      color: #0091c2;
    }
  }

  &.btn-outline-dark {
    background-color: transparent;
    border-color: #343a40;
    color: #343a40;

    &:hover {
      background-color: transparent;
      border-color: #343a40;
      color: #343a40;
    }
  }

  &.is-busy {
    pointer-events: none;
  }
}

.dracula-icon {
  width: 20px;
  height: 20px;
  display: inline-block;
  background: currentColor;

  &.icon-pro {
    mask: url("../images/icons/crown.svg") no-repeat center / contain;
  }

}

.dracula-pro-icon {
  width: 30px;
  height: 30px;
  margin-left: 5px;
  background: #ffc300;
  padding: 3px 5px;
  border-radius: 4px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  line-height: 1;

  .dracula-icon {
    background: #fff;
  }
}

.components-angle-picker-control {
  .components-input-control__backdrop {
    border-radius: 5px !important;
    border-color: #ddd !important;
  }

  .components-spacer {
    border: none !important;
    padding: 0 !important;
  }
}

.components-circular-option-picker__clear {
  border: 1px solid #ddd;
  border-radius: 5px;
}

.dracula-button-group.components-button-group,
.dracula-radio-group.components-button-group {
  background: #fff;
  padding: 7px 5px;
  width: max-content;
  border-radius: 10px;
  background: rgba(#675ed5, 0.05);
  border: 1px solid rgba(#ddd, 0.5);

  .dracula-btn-icon {
    background: $dracula_color;
  }

  button {
    color: $dracula_color;
    box-shadow: inset 0 0 0 1px rgba(#675ed5, 0.25) !important;
    margin: 0 2px !important;
    border-radius: 5px !important;
    transition: all 0.2s ease-in-out;
    padding: 10px;

    &:first-child {
      border-top-left-radius: 5px;
      border-bottom-left-radius: 5px;
    }

    &:last-child {
      border-top-right-radius: 5px;
      border-bottom-right-radius: 5px;
    }

    &.is-primary {
      z-index: auto;
      background: $dracula_color !important;
      color: #fff !important;
      border-color: $dracula_color_light !important;
      box-shadow: none;

      .dracula-btn-icon {
        background: #fff;
      }
    }

    &:hover:not(.is-primary) {
      background: rgba(#675ed5, 0.3) !important;
      color: $dracula_color;
    }
  }

  &.disabled {
    opacity: 0.5;
  }
}

.dracula-color-palette {
  border: 1px solid #e5e5e5;
  padding: 11px;
  border-radius: 10px;
  background: #fff;
  width: 400px;
  max-width: 100%;
  position: relative;

  legend {
    display: none;
  }

  .components-dropdown {
    width: max-content;
    max-width: 100%;

    & > button {
      width: 100px;
      height: 40px;
      border-radius: 5px;

      .components-truncate {
        display: none;
      }

      .components-color-palette__custom-color-value {
        text-overflow: ellipsis;
        white-space: nowrap;
        overflow: hidden;
      }
    }

    .components-popover {
      left: 0 !important;
      z-index: 99;

      .components-popover__content {
        outline-color: rgba(#ddd, 0.5);
        border-radius: 5px;
        box-shadow: rgba(0, 0, 0, 0.16) 0px 10px 36px 0px,
        rgba(0, 0, 0, 0.06) 0px 0px 0px 1px;

        .react-colorful {
          & + div {
            padding-top: 0;
            display: flex;

            & > div {
              &:first-child {
                width: auto;
                padding-right: 0;
                gap: 0;

                & > button {
                  margin-left: 5px;
                }
              }

              &:last-child {
                padding: 5px;
                flex: 1;

                .components-input-control__container {
                  width: 100%;

                  .components-spacer {
                    margin-left: 10px;
                  }

                  input {
                    height: 30px;
                    min-height: 30px;
                    padding-right: 5px;
                  }

                  .components-input-control__backdrop {
                    border-color: #ddd;
                    border-radius: 5px;
                  }
                }
              }
            }
          }
        }

        .react-colorful__saturation {
          height: 100px;
          margin-bottom: 10px;
        }

        /* width */
        &::-webkit-scrollbar {
          width: 5px;
          height: 5px;
        }

        /* Track */
        &::-webkit-scrollbar-track {
          background: #f1f1f1;
        }

        /* Handle */
        &::-webkit-scrollbar-thumb {
          background: #888;
        }

        /* Handle on hover */
        &::-webkit-scrollbar-thumb:hover {
          background: #555;
        }

        .components-select-control {
          width: unset;

          .components-select-control__input {
            height: unset !important;
          }
        }
      }
    }
  }

  .components-color-palette__custom-color-wrapper {
    width: 300px;
    max-width: 100%;
    height: 50px;
    overflow: hidden;

    .components-color-palette__custom-color-button {
      width: 100%;
      max-width: 100%;
      height: 100%;
      border-radius: 4px;
    }

    .components-color-palette__custom-color-text-wrapper {
      position: absolute;
      width: 100%;
      pointer-events: none;
      box-shadow: none;
    }
  }

  .components-circular-option-picker__custom-clear-wrapper {
    position: absolute;
    margin: 0;
    right: 14px;
    top: 17px;

    button {
      color: #fdb837;
      background: #fff;
      border: 1px solid rgba(#fdb837, 0.7);
      font-size: 12px;
      text-transform: capitalize;
      height: 30px;
      max-width: 60px;
      text-align: center;
      border-radius: 5px;
      padding: 5px 12px;
      transition: all 0.2s ease-in-out;
      outline: none !important;
      box-shadow: none !important;

      &:hover {
        background: darken(#fdb837, 10%) !important;
        color: #fff !important;
        border: 1px solid #fdb837 !important;
      }
    }
  }

  .components-circular-option-picker__option {
    &:before,
    &:after {
      width: auto;
      height: auto;
    }

    .components-tooltip {
      display: none;
    }
  }

  .components-select-control {
    .components-input-control__backdrop {
      display: block;
      border-color: #ddd !important;
      border-radius: 5px !important;
    }
  }

  &.disabled {
    opacity: 0.5;
  }

  @media (max-width: 768px) {
    width: 100%;

    .components-dropdown {
      width: 100%;

      .components-color-palette__custom-color-wrapper {
        width: 100%;
      }
    }
  }
}

.dracula-gradient-picker {
  position: relative;
  border: 1px solid #e5e5e5;
  padding: 11px;
  border-radius: 10px;
  background: #fff;

  .components-input-control__backdrop {
    display: block;
    border-color: #ddd !important;
    border-radius: 5px !important;
  }

  .components-custom-gradient-picker__gradient-bar {
    opacity: 1;
    border-radius: 10px;
  }

  .components-custom-gradient-picker__markers-container {
    z-index: 9;
  }

  .components-popover {
    left: 0 !important;

    .components-popover__content {
      outline-color: rgba(#ddd, 0.5);
      border-radius: 5px;
      box-shadow: rgba(0, 0, 0, 0.16) 0px 10px 36px 0px,
      rgba(0, 0, 0, 0.06) 0px 0px 0px 1px;

      .react-colorful {
        & + div {
          padding-top: 0;
          display: flex;

          & > div {
            &:first-child {
              width: auto;
              padding-right: 0;

              & > button {
                margin-left: 5px;
              }
            }

            &:last-child {
              padding: 5px;
              flex: 1;

              .components-input-control__container {
                width: 100%;

                .components-spacer {
                  margin-left: 10px;
                }

                input {
                  height: 30px;
                  min-height: 30px;
                  padding-right: 5px;
                }

                .components-input-control__backdrop {
                  border-color: #ddd;
                  border-radius: 5px;
                }
              }
            }
          }
        }
      }

      .react-colorful__saturation {
        height: 100px;
        margin-bottom: 10px;
      }

      /* width */
      &::-webkit-scrollbar {
        width: 5px;
      }

      /* Track */
      &::-webkit-scrollbar-track {
        background: #f1f1f1;
      }

      /* Handle */
      &::-webkit-scrollbar-thumb {
        background: #888;
      }

      /* Handle on hover */
      &::-webkit-scrollbar-thumb:hover {
        background: #555;
      }
    }
  }

  .components-custom-gradient-picker__ui-line {
    padding-right: 90px;
  }

  .components-circular-option-picker__custom-clear-wrapper {
    position: absolute;
    margin: 0;
    right: 10px;
    top: 102px;

    button {
      color: #675ed5 !important;
      background: #fff !important;
      border: 1px solid rgba(#675ed5, 0.25) !important;
      box-shadow: none;
      font-size: 0.875rem;
      height: 32px;
      width: 60px;
      text-align: center;
      border-radius: 5px;
      padding: 5px 12px;

      &:hover {
        color: #fff;
        background: #675ed5;
        border: 1px solid rgba(#675ed5, 0.25);
      }
    }
  }
}

.dracula-range-control {
  width: 400px;
  max-width: 100%;

  .components-base-control__field {
    margin-bottom: 0;
  }

  .components-range-control__mark {
    top: -6px;

    &-label {
      top: 26px;
      font-size: 14px;
      left: 14px;

      &:last-child {
        left: calc(100% - 14px);
      }
    }
  }

  .components-range-control__wrapper {
    margin-bottom: 0;
  }

  .components-range-control__slider {
    & + span {
      height: 7px !important;
    }
  }

  .components-range-control__track {
    background-color: $dracula_color !important;
    height: 7px;

    & + span {
      height: 15px !important;
      width: 15px !important;

      & > span {
        background-color: $dracula_color !important;
      }
    }
  }

  .components-range-control__mark {
    display: none;
  }

  .components-input-control__container {
    border-radius: 7px;

    .components-input-control__backdrop {
      border-color: rgba(#675ed5, 0.5);
    }
  }

  .components-range-control__reset {
    color: #fdb837;
    background: #fff;
    border: 1px solid rgba(#fdb837, 0.7);
    font-size: 0.875rem;
    height: 32px;
    width: 60px;
    text-align: center;
    border-radius: 5px;
    padding: 5px 12px;
    transition: all 0.2s ease-in-out;
    outline: none !important;
    box-shadow: none !important;

    &:hover {
      background: darken(#fdb837, 10%) !important;
      color: #fff !important;
      border: 1px solid #fdb837 !important;
    }
  }

  .components-range-control__tooltip {
    background-color: $dracula_color;
    bottom: 100%;
    font-size: 0.875rem;

    &:after {
      top: 100%;
      left: 50%;
      border: solid transparent;
      content: " ";
      height: 0;
      width: 0;
      position: absolute;
      pointer-events: none;
      border-color: rgba(136, 183, 213, 0);
      border-top-color: $dracula_color;
      border-width: 5px;
      margin-left: -5px;
    }
  }

  .components-number-control {
    margin-left: 10px !important;
  }

  .components-range-control__root {
    display: flex;
    align-items: center;
  }

  &.disabled {
    opacity: 0.5;
    pointer-events: none;
  }
}

.dracula-settings,
.dracula-toggle-builder,
.dracula-live-edit {
  .components-form-toggle {
    width: max-content;
    background: #fff;
    padding: 3px;
    border-radius: 15px;
    line-height: 1;
    height: auto;

    &__track {
      width: 44px;
      height: 22px;
      border-radius: 22px;
      background: #fff;
    }

    &__thumb {
      background: #675ed5;
      border: none;
      width: 15px;
      height: 15px;
      border-radius: 25px;
      top: 6px;
      left: 6px;
    }

    &.is-checked {
      .components-form-toggle__thumb {
        background: #fff;
        transform: translateX(22px);
      }

      .components-form-toggle__track {
        background: #675ed5;
      }
    }

    &.disabled {
      opacity: 0.5;
    }
  }

  .components-checkbox-control {
    .components-checkbox-control__input-container {
      margin-right: 5px;

      .components-checkbox-control__input {
        border-color: #ddd;
      }
    }

    .components-checkbox-control__label {
      text-transform: capitalize;
      font-size: 0.75rem;
      font-weight: 500;
      line-height: 1;
    }
  }

  // Select Control
  .components-base-control {
    &.components-select-control {
      width: 300px;
      max-width: 100%;

      .components-input-control__container {
        .components-select-control__input {
          border-color: #ddd !important;
          height: 40px !important;
        }

        .components-input-control__backdrop {
          border-radius: 5px !important;
          border-color: #ddd;
        }
      }
    }
  }
}

.dracula-btn-icon {
  width: 16px;
  height: 16px;
  margin-right: 5px;
  background: #fff;

  &.icon-color-dynamic {
    mask: url("../images/settings/color-dynamic.svg") no-repeat center / contain;
  }

  &.icon-color-presets {
    mask: url("../images/settings/color-presets.svg") no-repeat center / contain;
  }

  &.icon-color-custom {
    mask: url("../images/settings/color-custom.svg") no-repeat center / contain;
  }

  &.icon-position-left {
    mask: url("../images/settings/position-left.svg") no-repeat center / contain;
  }

  &.icon-position-right {
    mask: url("../images/settings/position-right.svg") no-repeat center /
      contain;
  }

  &.icon-position-center {
    mask: url("../images/settings/position-center.svg") no-repeat center /
      contain;
  }

  &.icon-custom {
    mask: url("../images/settings/position-custom.svg") no-repeat center /
      contain;
  }

  &.icon-size-small {
    mask: url("../images/settings/size-small.svg") no-repeat center / contain;
  }

  &.icon-size-normal {
    mask: url("../images/settings/size-normal.svg") no-repeat center / contain;
  }

  &.icon-size-large {
    mask: url("../images/settings/size-large.svg") no-repeat center / contain;
  }

  &.icon-export {
    mask: url("../images/settings/export.svg") no-repeat center / contain;
  }

  &.icon-import {
    mask: url("../images/settings/import.svg") no-repeat center / contain;
  }

  &.icon-reset {
    mask: url("../images/settings/reset.svg") no-repeat center / contain;
  }

  &.icon-select-elements {
    width: 20px;
    height: 20px;
    mask: url("../images/settings/select-elements.svg") no-repeat center /
      contain;
  }

  &.icon-add-image {
    margin: 0;
    mask: url("../images/settings/add-image.svg") no-repeat center / contain;
  }

  &.icon-add-video {
    width: 20px;
    height: 20px;
    margin: 0;
    mask: url("../images/settings/add-video.svg") no-repeat center / contain;
  }

  &.icon-upload {
    mask: url("../images/toggle-builder/upload-icon.svg") no-repeat center /
      contain;
  }

  &.icon-layout {
    mask: url("../images/toggle-builder/layout.svg") no-repeat center / contain;
  }

  &.icon-content {
    mask: url("../images/toggle-builder/content.svg") no-repeat center / contain;
  }

  &.icon-style {
    mask: url("../images/toggle-builder/style.svg") no-repeat center / contain;
  }

  &.icon-light {
    mask: url("../images/icons/1.svg") no-repeat center / contain;
  }

  &.icon-dark {
    mask: url("../images/icons/11.svg") no-repeat center / contain;
  }

  &.icon-mobile {
    mask: url("../images/settings/mobile.svg") no-repeat center / contain;
  }

  &.icon-tablet {
    mask: url("../images/settings/tablet.svg") no-repeat center / contain;
  }

  &.icon-desktop {
    mask: url("../images/settings/desktop.svg") no-repeat center / contain;
  }

  &.icon-floating-toggle {
    width: 22px;
    height: 22px;
    mask: url("../images/settings/floating-toggle.svg") no-repeat center /
      contain;
  }

  &.icon-custom-trigger {
    width: 22px;
    height: 22px;
    mask: url("../images/settings/custom-trigger.svg") no-repeat center /
      contain;
  }

  &.icon-reading-mode {
    width: 22px;
    height: 22px;
    mask: url("../images/settings/reading-mode.svg") no-repeat center / contain;
  }

  &.icon-reading-button {
    width: 22px;
    height: 22px;
    mask: url("../images/settings/reading-button.svg") no-repeat center /
      contain;
  }

  &.icon-reading-layout {
    width: 22px;
    height: 22px;
    mask: url("../images/settings/reading-layout.svg") no-repeat center /
      contain;
  }

  &.icon-menu-toggle {
    mask: url("../images/settings/menu-toggle.svg") no-repeat center / contain;
  }

  &.icon-img-replacement {
    mask: url("../images/settings/img-replacement.svg") no-repeat center /
      contain;
  }

  &.icon-img-behavior {
    mask: url("../images/settings/img-behavior.svg") no-repeat center / contain;
  }

  &.icon-video-replacement {
    mask: url("../images/settings/video-replacement.svg") no-repeat center /
      contain;
  }

  &.icon-video-behavior {
    mask: url("../images/settings/video-behavior.svg") no-repeat center /
      contain;
  }

  &.icon-eye {
    mask: url("../images/settings/eye.svg") no-repeat center / contain;
  }

  &.icon-reading-exclude {
    mask: url("../images/settings/excludes.svg") no-repeat center / contain;
  }
}

.loading-spinner {
  display: flex;
  justify-content: center;
  margin-top: 3rem;

  svg {
    width: 2.5rem;
    height: 2.5rem;
  }
}

/**---- Color Picker ----**/
.dracula-color-picker-wrapper {
  .color-holder-wrap {
    display: flex;
    align-items: center;

    .color-holder {
      width: 40px;
      height: 40px;
      border-radius: 50%;
      margin-right: 10px;
      border: 1px solid #ddd;
      cursor: pointer;
      position: relative;
      z-index: 1;
      overflow: hidden;
      background: repeating-linear-gradient(
                      45deg,
                      #e0e0e0 25%,
                      #0000 0,
                      #0000 75%,
                      #e0e0e0 0,
                      #e0e0e0
      ) 0 0 / 24px 24px,
      repeating-linear-gradient(
                      45deg,
                      #e0e0e0 25%,
                      #0000 0,
                      #0000 75%,
                      #e0e0e0 0,
                      #e0e0e0
      ) 12px 12px / 24px 24px;
    }

    .color-input {
      width: 120px !important;
      height: 38px !important;
      padding: 5px 7px;
      border: 1px solid #ddd;
      border-radius: 5px;
      margin-right: 10px;
    }

    .dashicons-edit {
      cursor: pointer;
    }
  }

  .components-color-picker {
    .components-select-control {
      width: auto;
      margin-left: 0;

      .components-input-control__container {
        width: 100%;

        select {
          height: 35px !important;
        }

        .components-input-control__backdrop {
          border-color: #ddd;
          height: 35px;
        }
      }
    }

    .components-input-control__input {
      height: 35px !important;
      min-height: auto !important;
    }

    .components-h-stack {
      padding: 0;
      margin-bottom: 7px;

      & + .components-flex {
        padding: 0;

        .components-input-control__container {
          width: 100%;

          .components-input-control__backdrop {
            border-color: #ddd;
            height: 40px;
          }
        }
      }
    }

    .react-colorful__saturation {
      height: 130px;
    }
  }
}

.dracula-popup-edit {
  color: #777;
  border: 1px solid #ddd;
  padding: 4px;
  height: 24px;
  width: 24px;
  font-size: 24px;
  box-sizing: content-box !important;
  cursor: pointer;
  background: #fff;
  border-radius: 3px;
  transition: all 0.2s ease-in-out;

  &-wrap {
    display: flex;
    align-items: center;
  }

  &:hover {
    background: #f9f9f9;
  }
}

/**--- Dracula Tooltip ---**/
.dracula-tooltip {
  z-index: 9999999 !important;

  &:before {
    z-index: -1 !important;
  }

  &.react-tooltip__show {
    opacity: 1 !important;
    visibility: visible !important;
  }

  &.dracula-toggle-tooltip {
    white-space: nowrap;
  }

  &.color-picker-tooltip {
    padding: 10px 10px 15px;
  }
}

.dracula-live-edit {
  .settings-field-content {
    .toggles {
      .toggle-wrap {
        .dracula-toggle-wrap {
          &:hover {
            .dracula-tooltip {
              display: none;
            }
          }

          .dracula-tooltip {
            display: none;
          }
        }
      }
    }
  }
}

.menu-item-type-dracula-dark-mode-switch .dracula-toggle-wrap,
.dracula-toggle-wrap.menu-item {
  &:hover {
    .dracula-tooltip {
      display: none;
    }
  }

  .dracula-tooltip {
    display: none;
  }
}

.dracula-toggle-wrap {
  position: relative;

  &:hover {
    .dracula-tooltip {
      display: block;
    }
  }

  .dracula-tooltip {
    position: absolute;
    top: 50%;
    right: calc(100% + 8px);
    transform: translateY(-50%);
    color: #fff;
    background: #222;
    border: 1px solid transparent;
    border-radius: 3px;
    padding: 8px 14px;
    display: none;
    white-space: nowrap;
    overflow: visible;
    width: max-content;
    font-size: 14px;

    &::after {
      content: "";
      width: 8px;
      height: 8px;
      position: absolute;
      background: #222;
      top: 50%;
      right: -4px;
      transform: translateY(-50%) rotate(45deg);
      z-index: -1;
    }
  }

  &.floating.position-left {
    .dracula-tooltip {
      left: calc(100% + 8px);

      &::after {
        left: -4px;
      }
    }
  }
}

html[data-dracula-scheme="dark"] {
  .dracula-tooltip {
    &::after {
      background: var(--dracula-secondary-bg-color);
    }

    &.type-light {
      &.place-top {
        &::after {
          //border-top-color: #FFF !important;
          background: #fff !important;
        }
      }

      &.place-bottom {
        &::after {
          //border-bottom-color: #FFF !important;
          background: #fff !important;
        }
      }

      &.place-left {
        &::after {
          //border-left-color: #FFF !important;
          background: #fff !important;
        }
      }

      &.place-right {
        &::after {
          //border-right-color: #FFF !important;
          background: #fff !important;
        }
      }
    }
  }

  .dracula-toggle-move {
    color: #fff;
  }

  .toggle-postfix-icon {
    background-color: #fff !important;
  }

  // classic editor icon
  .mce-dracula-toggle .mce-i-dracula_toggle {
    background-color: rgb(176, 169, 159) !important;
  }

  #dracula-settings-app {
    .dracula-settings {
      // Select Control
      .components-base-control {
        .components-select-control {
          .components-input-control__container {
            .components-select-control__input {
              background-color: rgb(24, 26, 27);
              color: #f8f8f2;

              & option {
                color: rgb(30, 30, 30) !important;
              }
            }
          }
        }
      }
    }
  }

  // Live Edit
  .dracula-live-edit-wrap {
    .dracula-settings-content {
      .settings-field {
        .image-replacements {
          .image-replacements-group {
            .group-item {
              .input-group {
                button {
                  background-color: #8d86e0;
                  border: none;

                  &:hover {
                    background-color: #675ed5;
                  }

                  .dracula-btn-icon {
                    background-color: #fff !important;
                  }
                }
              }
            }
          }
        }
      }

      .field-transition-animation {
        // Select Control
        .components-base-control {
          .components-select-control {
            .components-input-control__container {
              .components-select-control__input {
                // background-color: rgb(24, 26, 27) !important;
                color: #f8f8f2 !important;

                option {
                  color: rgb(30, 30, 30) !important;
                }
              }

              &.components-input-control__backdrop {
                color: rgb(30, 30, 30) !important;
              }
            }
          }
        }
      }
    }
  }
}

.pro-label {
  position: absolute;
  top: 5px;
  right: 5px;
  background: #fdb837;
  color: #fff;
  text-align: center;
  padding: 3px 5px;
  border-radius: 15px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  line-height: 1;

  .dracula-icon {
    width: 16px;
    margin-right: 3px;
  }

}

.dracula-text-control {
  width: 300px;

  .components-base-control__field {
    margin-bottom: 0;

    .components-text-control__input {
      border-radius: 5px;
      border-color: #ddd;
      height: 40px;
    }
  }

  @media (max-width: 768px) {
    width: 100%;
  }
}

.dracula-swal {
  z-index: 99999 !important;

  .swal2-confirm {
    background-color: $dracula_color !important;
  }

  .swal2-close {
    &:focus {
      background: transparent;
      color: inherit;
      box-shadow: none;
    }
  }

  .swal2-deny,
  .swal2-cancel {
    background-color: #f08080 !important;
  }

  &.save-settings-toast {
    .swal2-popup {
      display: flex !important;
      padding: 10px;

      .swal2-html-container {
        margin-left: 5px;
      }
    }
  }

  .swal2-input {
    width: auto !important;
  }

  // Title
  .swal2-title {
    font-size: 1.2rem;
    font-weight: 500;
  }

  &:not(.dracula-feedback-swal) {
    .swal2-title {
      color: #333;
    }
  }

  // Text
  .swal2-html-container {
    font-size: 1rem;
    color: #555;
  }

  .swal2-textarea {
    &:focus {
      border-color: #ddd !important;
      box-shadow: none !important;
    }
  }

  &.dracula-review-remind-swal {
    .swal2-deny {
      background-color: #999 !important;
    }
  }

  &.dracula-rating-swal {
    .swal2-progress-steps {
      display: none !important;
    }

    .dracula-star-rating {
      i {
        width: 25px;
        height: 25px;
        font-size: 25px;
        cursor: pointer;

        &:hover,
        &.dashicons-star-filled {
          color: #ffaa00;
        }
      }
    }
  }

  &.dracula-pro-video-swal {
    .swal2-popup {
      background: #111;

      .swal2-title {
        color: #fff;
      }
    }
  }
}

// PROMO
.dm-pro-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  backdrop-filter: blur(3px);
}

.dm-pro-modal {
  width: 390px;
  background: #fff;
  border-radius: 18px;
  padding: 32px 28px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
  text-align: center;
  position: relative;
  animation: fadeIn 0.3s ease;


  .dm-pro-close {
    position: absolute;
    top: 12px;
    right: 14px;
    background: none;
    border: none;
    font-size: 26px;
    color: #777;
    cursor: pointer;
  }

  .dm-pro-badge img {
    width: 200px;
    margin-top: -100px;
  }

  .dm-pro-title {
    font-size: 1.4rem;
    font-weight: 700;
    margin: 18px 0 10px;
  }

  .dm-pro-text {
    font-size: 15px;
    color: #555;
    line-height: 1.6;
    margin-bottom: 22px;
  }

  .dm-pro-offer {
    margin-bottom: 20px;

    .label {
      display: inline-block;
      padding: 8px 16px;
      font-size: 15px;
      font-weight: 700;
      color: #4b43d1;
      border: 2px solid #4b43d1;
      border-radius: 10px;
      background: #f5f4ff;
    }
  }

  .dm-pro-timer {
    display: flex;
    justify-content: center;
    gap: 18px;
    margin-bottom: 25px;

    .timer-block {
      text-align: center;

      .num {
        font-size: 24px;
        font-weight: 700;
        padding: 10px 14px;
        background: #edf0ff;
        border-radius: 10px;
        border: 1px dashed rgba(75, 67, 209, 0.4);
      }

      .label {
        font-size: 11px;
        margin-top: 4px;
        color: #555;
      }
    }
  }

  .dm-pro-features {
    text-align: left;
    margin: 0 auto 25px;
    padding: 0;
    list-style: none;
    max-width: 260px;

    li {
      font-size: 14px;
      margin-bottom: 6px;
      color: #333;

      i {
        color: #4CAF51;
        margin-right: 8px;
      }
    }
  }

  .dm-pro-actions {
    display: flex;
    gap: 12px;
    justify-content: center;

    .dm-btn {
      padding: 12px 20px;
      border-radius: 10px;
      border: none;
      cursor: pointer;
      font-weight: 600;
      text-decoration: none;
      transition: 0.2s ease;
      display: flex;
      align-items: center;
      justify-content: center;
      font-size: 14px;

      i {
        margin-right: 5px;
        background: #fff;
      }

      &.video {
        background: #eceffb;
        color: #4b43d1;
      }

      &.primary {
        background: #4b43d1;
        color: #fff;
      }

      &:hover {
        opacity: 0.9;
      }
    }
  }

}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.95);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

