$banner-height: var(--banner-height);
$info-bg: rgba(0, 0, 0, 0.5);
$info-fg: rgba(255, 255, 255, 0.9);
$description-toggle-bg: linear-gradient(180deg, rgb(105, 105, 105) 0%, rgb(50, 50, 50) 50%);
$description-bg: linear-gradient(0deg, rgba(70, 70, 70, 0.95) 0%, rgba(20, 20, 20, 0.95) 50%);
$description-fg: rgba(255, 255, 255, 0.9);
$description-btn-height: 1.5em;
$description-shadow-color: rgba(50, 50, 50, 0.95);

@include until($tablet) {
  .playlist-container, .channel {
    --banner-height: 5em;
  }
}

@include from($tablet) {
  .playlist-container, .channel {
    --banner-height: 100px;
  }
}

.header {
  border-bottom: $default-border-2;
  margin-bottom: 0.5em;
  position: relative;
  overflow-y: auto;

  .banner {
    height: $banner-height;
    display: flex;
    background-color: black;
    justify-content: center;

    img {
      max-width: 800px;
      max-height: 100%;
      flex: 1;
    }
  }

  .image {
    height: 100px;
    margin-right: 1em;

    img {
      height: 100%;
      border-radius: 50%;
    }
  }

  .row {
    display: flex;

    @include from($desktop) {
      flex-direction: row;
    }

    .info {
      display: flex;
      flex-direction: column;
      align-items: center;
      height: 100%;
      background-color: $info-bg;

      .row {
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: center;
        flex: 1;
        padding: 0 0.5em;
      }
    }
  }

  .info-container {
    position: absolute;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: $info-bg;
    color: $info-fg;
    display: flex;
    flex-direction: column;

    a {
      color: $info-fg !important;

      &:hover {
        color: $default-hover-fg !important;
      }
    }

    .title {
      letter-spacing: 0.1em;
      color: $info-fg !important;
    }

    .n-items {
      /* Align to the right */
      margin-left: auto;
      padding: 0 0.5em;
    }
  }

  .title-container {
    max-height: var(--banner-height);
    overflow-y: hidden;
    display: flex;
    align-items: center;
  }

  .title {
    height: 100%;
    align-content: center;
    color: $default-fg-2;
    font-size: 1.7em;
    font-weight: bold;
    margin: 0.5em 0;
    text-decoration: dotted;

    &:hover {
      color: $default-hover-fg;
    }
  }

}

.description-container {
  width: 100%;
  min-height: $description-btn-height;
  position: absolute;
  top: $banner-height;
  left: 0;
  z-index: 5;

  .description-toggle {
    width: 100%;
    height: $description-btn-height;
    background: $description-toggle-bg;

    button {
      width: 100%;
      height: $description-btn-height;
      background: none;
      color: $description-fg;
      margin: 0;
      padding: 0;
      cursor: pointer;

      i {
        font-size: 0.75em;
      }
    }
  }

  .description {
    background: $description-bg;
    color: $description-fg;
    font-size: 0.9em;
    max-height: 10em;
    overflow: auto;
    padding: 0.5em;
    border-radius: 0 0 1em 1em;
    box-shadow: 0 3px 2px -1px $description-shadow-color;
  }
}

.media-results {
  height: calc(100% - #{$banner-height} - 1em);
}
