$white: $white;

$nypr-player-primary-color                   : $white;
$nypr-player-background-color                : darken($denim-blue, 2%);
$nypr-player-accent-color                    : $white;

$nypr-player-button-color                    : $white;
$nypr-player-button-hover-color              : rgba($white, 0.8);
$nypr-player-button-active-color             : $white;
$nypr-player-slider-handle-color             : $white;

$nypr-player-info-text-color                 : $white;
$nypr-player-link-underline-color            : $white;
$nypr-player-timelabel-color                 : $white;
$nypr-player-timelabel-total-color           : rgba($white, 0.6);

$nypr-player-backdrop-color                  : rgba($white, 0.75);
$nypr-player-progress-played-color           : $white;
$nypr-player-progress-downloaded-color       : darken($denim-blue, 20%);

.jukebox-player {
  display: grid;
  grid-template-columns: calc(50% - 45px) 90px calc(50% - 90px);
  grid-template-rows: 33% 33% 33%;
  color: #FFF;

  width: 100%;
  height: 85px;
  padding-bottom: 15px;
  position: fixed;
  bottom: -5px;
  z-index: 1200;
  box-sizing: border-box;
  padding: 10px 15px;
  background-color: $nypr-player-background-color!important;

  @include media('<medium') {
    display: grid;
    grid-template-columns: 1fr 50px;
    grid-template-rows: 33% 33% 33%;
  }
}

.jukebox-player .secondary-metadata-toggle-box {
  width: 100%;
}

.jukebox-player-show {
  grid-column-start: 1;
  grid-column-end: 2;
  grid-row-start: 1;
  grid-row-end: span 3;

  align-self: center;
  justify-self: right;

  text-transform: uppercase;
  text-align: right;

  @include media("<medium"){
    grid-column-start: 1;
    grid-column-end: 1;
    grid-row-start: 1;
    grid-row-end: span 1;
    align-self: center;
    justify-self: left;

    // position: absolute;
    white-space: nowrap;
  }
}

  .jukebox-player-show-title {
    font-weight: normal;
    font-family: $font-body-bold;
    font-size: 10px;
    letter-spacing: 1px;
    max-width: 250px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    width: 100%;

    @include media("<medium") {
      text-align: left;
    }
  }

.jukebox-player-listen-button {
  grid-column-start: 2;
  grid-column-end: 3;
  grid-row-start: 1;
  grid-row-end: span 3;

  align-self: center;
  justify-self: center;

  text-align: center;
  width: 55px;
  margin: 0 20px;

  @include media("<medium") {
    width: 48px;

    grid-column-start: 2;
    grid-column-end: 2;
    align-self: center;
    justify-self: flex-start;
    margin: 0;
  }
}

.jukebox-player-controls {
  @include media("<medium") {
    display: none;
  }

  position: absolute;
  top: 0;
  bottom: 0;
  right: 0;
  justify-content: flex-end;
  align-items: center;
  background-color: $nypr-player-background-color;
  height: 100%;

  .nypr-player-volume-slider-track::after {
    z-index: 0;
  }

  .nypr-player-volume-control {
    display: flex;
    flex-direction: row;
    justify-content: flex-end;
    align-items: center;
    padding-right: 10px;
    margin-right: -20px;
  }

  .nypr-player-volume-slider-wrapper {
    height: 30px;
  }

  .nypr-player-volume.is-muted {
    .mod-volume-unmuted {
      display: none;
    }
    .mod-volume-muted {
      display: inline-block;
    }
  }

  .nypr-player-volume {
    margin-left: 0;
    margin-right: 0;
    padding-right: 20px;
    @include media("<medium") {
      margin-right: -10px;
    }

    .mod-volume-unmuted {
      display: inline-block;
    }
    .mod-volume-muted {
      display: none;
    }
  }

  .nypr-player-button.mod-volume {
    order: -1;
    display: flex;
    justify-content: center;
    align-items: center;
    text-align: center;
    flex-basis: 0;
    margin-right: -5px;

    svg {
      position: relative;
      top: 0;
      left: 0;
    }
  }
}

.jukebox-player-track {
  grid-column-start: 3;
  grid-column-end: 3;
  grid-row-start: 1;
  grid-row-end: span 3;

  line-height: 1.22;
  align-self: center;
  justify-content: left;
  flex-shrink: 2;
  text-align: left;
  height: 50px;
  display: flex;
  flex-direction: column;
  justify-content: space-around;
  align-content: flex-start;
  text-align: left;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  width: 100%;

  @include media("<medium"){
    margin-top: -5px;
    grid-column-start: 1;
    grid-column-end: span 1;
    grid-row-start: 2;
    grid-row-end: span 3;
    width: 100%;
    align-self: center;
    justify-content: space-around;
    position: relative;
  }
}

  .jukebox-player-track .toggle-box__label {
    line-height: 1.22;
    text-align: left;
    min-width: 30%;
    height: 50px;
    display: flex;
    flex-direction: column;
    justify-content: space-around;
    align-content: flex-start;
    align-items: flex-start;
  }

  .jukebox-player-track-title {
    font-family: $font-body;
    line-height: 1.22;
    font-size: 12px;
    font-weight: normal;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    width: 100%;

    @include toggleBoxCaret(8px, #FFF);
    @include media("<medium") {
      width: 100%;
    }
  }

  .jukebox-player-track-composer {
    font-family: $font-heading;
    font-weight: bold;
    font-size: 18px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    width: 100%;

    @include media("<medium") {
      width: 100%;
    }
  }
