@use '../../../styles/buttons';
@import '../../../styles/palette';

:host {
  width: 100%;
  height: 40px;
  margin-top: 16px;
  margin-bottom: 8px;

  .kafka-toolbar {
    height: 100%;
    width: 100%;
    display: flex;
    align-items: center;

    & > * {
      margin-right: 8px;
    }

  }

  .switch {
    color: $main-60;
    font-size: 14px;
    font-weight: 500;
    border-radius: $default-border-radius;
    height: 40px;
    padding: 0 8px;

    background: $main-0;
    border: 1px solid $main-20;

    &:hover {
      border: 1px solid $main-40;
    }

    ::ng-deep .mdc-form-field {
      padding-top: 10px;
    }

    ::ng-deep .mdc-form-field label {
      display: flex;
      flex-direction: row;
      align-items: center;
    }

    ::ng-deep .mdc-form-field .mdc-switch {
      background: $main-30;
      height: 16px;
      width: 30px;
      padding-right: 1px;
    }

    ::ng-deep .mat-slide-toggle-ripple {
      display: none;
    }

    ::ng-deep .mat-slide-toggle-thumb-container {
      height: 12px;
      margin-top: 5px;
      padding-left: 2px;
    }

    ::ng-deep .mat-slide-toggle-thumb {
      width: 11px;
      height: 11px;
      background: $main-0;
    }

    .circle {
      width: 6px;
      height: 6px;
      background: $main-40;
      border: 5px solid $main-10;
      border-radius: 50%;
      margin-left: 12px;
    }

    &.active {
      border: 1px solid $blue-30;
      background: $blue-0;
      color: $main-100;

      &:hover {
        border: 1px solid $blue-40;
      }

      .circle {
        background: $blue-60;
        border: 5px solid $blue-10;
      }

      ::ng-deep .mat-slide-toggle-bar {
        background: $blue-60;
      }

      ::ng-deep .mat-slide-toggle-thumb {
        background: $main-0;
      }
    }
  }

  .action-button-blue {
    @include buttons.button-blue;
  }

  .action-button-black {
    @include buttons.button-black;
  }

  .action-button-white {
    @include buttons.button-white;
  }

  .offset-wrapper {
    @media screen and (max-width: 1680px) {
      max-width: 175px;
    }

    @media screen and (max-width: 1440px) {
      max-width: 150px;
    }

    .offset-input {
      font-size: 14px;
      line-height: $default-line-height;
      min-width: 100px;
      max-width: 150px;
      padding: 0 8px;
    }

    .offset-search-button {
      min-width: 42px;
      max-width: 42px;
      border-radius: 0 $default-border-radius $default-border-radius 0;
      z-index: 1;

      .search-icon {
        color: white;
        left: 7px;
        top: 7px;
        font-size: 30px;
        margin: 0 !important;
        position: absolute;
      }
    }
  }
}
