@import url(../../var.less);

@time-panel-prefix: ~"@{prefix}time-panel";

.@{time-panel-prefix}{
  margin: 8px 0;
  border: solid 1px @datepicker-border-color;
  background-color: @color-white;
  box-shadow: @box-shadow-light;
  border-radius: 2px;
  position: absolute;
  width: 194px;
  left: 0;
  z-index: @z-index-top;
  user-select: none;
  box-sizing: content-box;

  &__content {
    font-size: 0;
    position: relative;
    overflow: hidden;

    &::after, &::before {
      content: "";
      top: 50%;
      position: absolute;
      margin-top: -9px;
      height: 22px;
      z-index: -1;
      left: 0;
      right: 0;
      box-sizing: border-box;
      text-align: left;
      background-color: @background-primary-light-9;
    }

    &::after {
      left: 50%;
    }

    &::before {
      padding-left: 50%;
    }

    &.has-seconds {
      &::after {
        left: calc(100% / 3 * 2);
      }

      &::before {
        padding-left: calc(100% / 3);
      }
    }
  }

  &__footer {
    border-top: 1px solid @datepicker-inner-border-color;
    padding: 4px;
    height: 36px;
    line-height: 25px;
    text-align: right;
    box-sizing: border-box;
  }

  &__custom-footer {
    border-top: 1px solid @datepicker-inner-border-color;
    padding: 4px;
    height: 36px;
    line-height: 25px;
    box-sizing: border-box;
  }

  &__btn {
    border: none;
    line-height: 28px;
    padding: 0 5px;
    margin: 0 5px;
    cursor: pointer;
    background-color: transparent;
    outline: none;
    font-size: 12px;
    color: @primary-text-color;

    &.confirm {
      font-weight: 800;
      color: @datepicker-active-color;
    }

    &.now {
      float: left;
      color: @primary-color;
    }
  }
}