@use "../colors" as c;
@use "../mixins" as m;

.detail-learningmaterials {
  @include m.detail-container(c.$orange);

  .detail-learningmaterials-header {
    @include m.detail-container-header;
  }

  .title {
    @include m.detail-container-title;
  }

  .detail-learningmaterials-actions {
    @include m.detail-container-actions;
  }

  .learningmaterial-search {
    flex-grow: 2;
    margin: 0 0.5rem;

    input {
      width: 100%;
    }

    .search-box {
      margin-bottom: 0;
    }

    .lm-search-results {
      @include m.ilios-selectable-list;
      background-color: c.$white;
      border: 1px solid c.$blueMunsell;
      margin: 0;
      max-height: 15rem;
      overflow-y: scroll;
      position: absolute;
      z-index: 10;

      li {
        border-bottom: 1px solid c.$culturedGrey;
        min-height: 3.25rem;
        position: relative;

        button.result {
          @include m.ilios-button-reset;
          text-align: left;
        }

        &:hover {
          background: c.$culturedGrey;
        }
      }

      .learning-material-title {
        @include m.ilios-heading-h4;
        color: inherit;
        display: block;
        margin: 0;
      }

      .learning-material-description {
        color: c.$davysGrey;
        display: block;
        @include m.font-size("small");
      }

      .learning-material-status {
        color: c.$crimson;
        @include m.font-size("small");
        position: absolute;
        right: 5px;
        top: 0;
      }

      .learning-material-properties {
        li {
          border: 0;
          color: c.$davysGrey;
          cursor: inherit;
          display: list-item;
          @include m.font-size("small");
          margin: 0;
          min-height: 0;
          padding: 0 0 0 0.75rem;
        }
      }
    }
  }

  .detail-learningmaterials-content {
    @include m.detail-container-content;

    table {
      td {
        ul {
          @include m.ilios-list-reset;
        }
      }
      .lm-title {
        @include m.ilios-link-button;
      }
    }

    .icon-button {
      @include m.ilios-button-reset;
      color: c.$blueMunsell;
      &.remove {
        color: c.$crimson;
      }
    }
  }
}
