.component-wrapper {
  .component-inner {
    margin: 20px;
    border: 1px solid $color-border;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    background-color: $white-100;

    &.ac-bg {
      background-color: transparent;
    }

    &.is-fullwidth {
      display: inherit;

      .ac-html-preview {
        width: 100%;

        i.is-block {
          color: $color-text;
        }

        .ac-navbar-area {
          position: inherit;
        }
      }

      .ac-code {
        width: 100%;
      }
    }

    &.ac-bg-dark {
      background-color: $primary-5;
    }

    .ac-html-preview {
      padding: 0 20px;
      width: 50%;
    }

    .ac-code {
      width: 50%;
      max-height: 400px;
      overflow: auto;

      &::-webkit-scrollbar {
        width: 7px;
      }

      /* Track */
      &::-webkit-scrollbar-track {
        background-color: #d1d4de;
        border-radius: 10px;
      }

      /* Handle */
      &::-webkit-scrollbar-thumb {
        background-color: $gray-50;
        border-radius: 10px;
      }

      /* Handle on hover */
      &::-webkit-scrollbar-thumb:hover {
        background-color: $gray-50;
      }

      .number {
        margin: 0;
        padding: 0;
        background-color: transparent;
      }

      &.is-full-height {
        max-height: 100%;
      }

      pre {
        margin: 0;
        border-radius: 0 4px 4px 0;

        .token {
          &.tag {
            background-color: transparent;
            font-size: inherit;
            display: inherit;
            padding: 0;
          }
        }
      }
    }
  }
}

.ac-code-preview-wrapper {
  border: 1px solid $color-border;
  border-radius: 4px;

  .ac-code-header {
    display: grid;
    grid-template-columns: auto auto;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
  }
}

// new code preview
.ac-components {
  margin: 20px;

  .single-component {
    // box-shadow: $ac-shadow-1;
    border: 1px solid $color-border;
    border-radius: 4px;
    margin-bottom: 25px;
    overflow: hidden;

    .component-header {
      display: flex;
      justify-content: space-between;
      border-bottom: 1px solid $color-border;
      background-color: $white-100;

      h3 {
        padding: 10px 20px;
        font-size: 16px;
        font-weight: 500;
        font-family: $font-paragraph;
        color: $color-text;
      }

      .component-switch {
        padding: 10px 15px;
        display: flex;
        align-items: center;

        .switch-label {
          font-size: 1rem;
          margin-right: 10px;
        }
      }
    }

    .component-body {
      padding: 20px;
      background-color: $white-100;

      .code-preview {
        position: relative;
        z-index: 1;
        max-height: 500px;
        overflow-y: auto;

        .copy-button {
          position: absolute;
          right: 5px;
          top: 5px;

          &:hover {
            box-shadow: none;
          }
        }

        pre {
          margin: 0;
          border-radius: 4px;
          font-size: 14px;

          .token {
            &.tag {
              background-color: transparent;
              font-size: inherit;
              display: inherit;
              padding: 0;
            }
          }
        }
      }
    }
  }
}

// new code preview
/****************************************
Responsive Classes
*****************************************/
// Extra small devices (portrait phones, less than 576px)
@media (max-width: 575.98px) {
  .component-wrapper {
    .component-inner {
      align-content: space-between;
      flex-wrap: wrap;
      align-items: inherit;
      justify-content: inherit;

      .ac-html-preview {
        padding-top: 15px;
        padding-bottom: 15px;
        width: 100%;
      }

      .ac-code {
        width: 100%;
      }
    }
  }
}

// Small devices (landscape phones, 576px and up)
@media (min-width: 576px) and (max-width: 767.98px) {
  .component-wrapper {
    .component-inner {
      align-content: space-between;
      flex-wrap: wrap;
      align-items: inherit;
      justify-content: inherit;

      .ac-html-preview {
        padding-top: 15px;
        padding-bottom: 15px;
        width: 100%;
      }

      .ac-code {
        width: 100%;
      }
    }
  }
}

// Medium devices (tablets, 768px and up)
@media (min-width: 768px) and (max-width: 991.98px) {
  .component-wrapper {
    .component-inner {
      align-content: space-between;
      flex-wrap: wrap;
      align-items: inherit;
      justify-content: inherit;

      .ac-html-preview {
        padding-top: 15px;
        padding-bottom: 15px;
        width: 100%;
      }

      .ac-code {
        width: 100%;
      }
    }
  }
}

// Large devices (desktops, 992px and up)
@media (min-width: 992px) and (max-width: 1199.98px) {
}

// Extra large devices (large desktops, 1200px and up)
@media (min-width: 1200px) {
}
