/**
 * Licensed to the Apache Software Foundation (ASF) under one
 * or more contributor license agreements.  See the NOTICE file
 * distributed with this work for additional information
 * regarding copyright ownership.  The ASF licenses this file
 * to you under the Apache License, Version 2.0 (the
 * "License"); you may not use this file except in compliance
 * with the License.  You may obtain a copy of the License at
 *
 *     http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */


@toolbar-context-menu-width: 40px;
@toolbar-padding: 10px;

.log-file-search-popup {
  .modal-body {
    overflow: hidden;
  }
}

.log-file-search-toolbar {
  border: 1px solid #ddd;
  margin-bottom: 20px;
  overflow: hidden;
  background: #e6f1f6;

  .toolbar-row {
    margin-bottom: 5px;

    input {
      margin: 0;
    }
    &:last-child {
      padding-bottom: @toolbar-padding;
      margin-bottom: 0;
    }
  }

  .filter-block {
    width: calc(~"100%" - @toolbar-context-menu-width + 4px);
    padding: @toolbar-padding;
    box-sizing: border-box;
    margin-bottom: -400px;
    padding-bottom: 400px;

    input {
      height: 16px;
    }

    .date-filter {
      margin-left: 10px;

      input {
        width: 100px;
      }
    }
  }

  .levels-filter-block {
    .level-checkbox {
      margin-right: 20px;
    }
  }

  .include-exclude-filter-block {
    .keywords-list {
      display: inline-block;

      .keyword-item {
        font-size: 12px;
        display: inline-block;
        padding: 2px;
        border-radius: 0;

        .close {
          color: black;
          font-size: 16px;
          margin-left: 4px;
        }
      }
    }
  }

  .context-menu {
    width: @toolbar-context-menu-width;
    border-left: 2px solid #ddd;
    margin-bottom: -400px;
    padding-bottom: 400px;
    text-align: center;

    .icon-external-link,
    .move-to-top,
    .move-to-bottom {
      display: block;
      font-size: 28px;
      color: grey;
    }

    .move-to-top {
      line-height: 20px;
    }
    .move-to-bottom {
      line-height: 18px;
    }

    .icon-external-link {
      margin-top: 5px;
      font-size: 20px;
      padding-left: 4px;
    }
  }
}

.log-file-search-content {
  &.container {
    width: 100%;
    height: 300px;
    overflow-y: auto;
    border: 1px solid #ddd;
  }

  .log-data-item {
    border-bottom: 1px solid #ddd;

    &:nth-child(2n) {
      background: #f2f2f2;
    }

    .log-data-date {
      border-right: 2px solid #ddd;
      width: 7%;
      padding-left: 4px;
    }
    .log-data-message {
      width: 91%;
    }
  }

  #infinite-scroll-append {
    text-align: center;
    margin-top: 10px;

    .icon-spinner {
      font-size: 33px;
    }
  }
}
