player-topbar {
  display: flex;
  flex-wrap: nowrap;
  align-items: stretch;
  white-space: nowrap;
  overflow: hidden;
}

player-topbar .live-label {
  margin: 0 .5rem;
  line-height: 48px;
  font-size: var(--header3-font-size);
  color: transparent;
  display: none;
}
player-topbar #trenutni-komad {
  margin: 0;
  font-size: var(--header4-font-size);
}

/* gumb za predvajanje / pavzo (tudi v seekbaru) */
player-topbar > button,
.player-vrstica > button {
  display: block;
  margin: 0 .8rem 0 0;
  padding: 0;
  width: var(--header-height);
  height: var(--header-height);
  background-color: #000000;
  border: none;
  align-self: center;
  cursor: pointer;
}

.player-vrstica > button {
  margin-right: 0;
}

player-topbar > button:before,
.player-vrstica > button:before {
  display: block;
  width: var(--header-height);
  height: var(--header-height);
  background-position: center;
  background-size: 100% 100%;
}
player-topbar > button.svg-icon-loading:before,
.player-vrstica > button.svg-icon-loading:before {
  background-size: 75% 75%;
}
[temna-tema] .player-vrstica > button:before {
  filter: contrast(2);
}

/* pasica za stanje predvajanja spodaj */
player-topbar .player-vrstica {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  /*left: var(--header-height);*/
  /*width: calc(100% - var(--header-height));*/
  height: var(--header-height);
  background-color: white;

  display: none;
  flex: 1;
  color: black;
  overflow: visible;
  align-items: center;
  justify-content: space-between;
  line-height: 20px;
  border-top: var(--stroke-width) solid black;
  cursor: pointer;
}
.player-vrstica > button {
  filter: saturate(0) invert(1);
  z-index: 1000;
  position: relative;
  /* margin-left: calc(var(--header-height) * -1) */;
  box-sizing: content-box;
  border-top: var(--stroke-width) solid white;
  border-right: var(--stroke-width) solid white;
}
.gin--vertical-toolbar player-topbar .player-vrstica {
  left: calc(var(--gin-toolbar-x-offset));
  width: calc(100% - var(--gin-toolbar-x-offset));
  /*left: calc(var(--gin-toolbar-x-offset) + var(--header-height));*/
  /*width: calc(100% - var(--gin-toolbar-x-offset) - var(--header-height));*/
}

.player-vrstica {
  --link-normal-color: var(--header-text-color);
  -webkit-user-select: none;
  user-select: none;
  position: relative;
}

.player-vrstica .seekbar {
  flex-grow: 1;
  min-width: 0;
  height: 100%;
  position: relative;
  display: flex;
  align-items: center;
}

/* "zatiček", ki indicira predvajanje */
.player-vrstica .seekbar:before {
  content: '';

  /*width: 100%;*/
  height: 1.5rem;
  width: 1.5rem;

  position: absolute;
  left: 0;
  left: calc(var(--player-time) / var(--player-duration) * 100% - .75rem);
  top: -.75rem;
  background: black;
  border: .2rem solid white;
  border-radius: 2rem;
  z-index: 2000;
  border-bottom-left-radius: 0;
  rotate: -45deg;
}

/* obarvano ozadje trajanja */
.player-vrstica .seekbar:after {
  content: '';
  width: 100%;
  transform-origin: left center;
  transform: scaleX(calc(var(--player-time) / var(--player-duration) * 100%));
  position: absolute;
  left: 0;
  top: calc(-1 * var(--stroke-width));
  height: calc(100% + var(--stroke-width));
  mix-blend-mode: difference;
  background: white;
  z-index: 1000;
  pointer-events: none;
}

.player-vrstica .close-player {
  position: absolute;
  top: -.7rem;
  right: -.7rem;
  width: 1.25rem;
  height: 1.25rem;
  background: black;
  border-radius: 2rem;
  border: var(--stroke-width) solid white;
}
.player-vrstica .close-player:after {
  content: '✕';
  color: white;
  position: relative;
  left: 1px;
  font-size: 18px;
  top: -2px;
}
[is-playing] .player-vrstica .close-player {
  display: none;
}

.player-vrstica .prispevek-link {
  border-left: var(--stroke-width) solid black;
}
.player-vrstica .prispevek-link .fa {
  font-size: 22px;
}

[show-seekbar] player-topbar .player-vrstica {
  display: flex;
}

player-topbar .nowplaying {
  flex: 1;
  z-index: 1;
  padding: .5rem 0.2rem;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  pointer-events: none;
  text-align: center;
  justify-content: center;
  user-select: none;
}

player-topbar .curtime,
player-topbar .remtime {
  margin: 0 .7rem;
  z-index: 1;
  font-size: 14px;
  font-weight: bold;
  overflow: hidden;
  white-space: nowrap;
  text-overflow: ellipsis;
  pointer-events: none;
  user-select: none;
  font-variant-numeric: tabular-nums;
}

player-topbar .remtime {
  left: auto;
  right: 3rem;
}

player-topbar .prispevek-link {
  padding: 1rem;
}

.svg-icon-play:before,
.svg-icon-pause:before,
.svg-icon-playpause:before,
.svg-icon-loading:before,
.svg-icon-stop:before {
  content: "";
  background-repeat: no-repeat;
}

.svg-icon-loading:before {
  animation: 2s linear infinite loading-spin;
}

audio-file {
  cursor: pointer;
  display: inline-block;
}

/* trenutni komad */
#trenutni-komad {
  display: flex;
  flex-direction: row;
  align-items: center;
}

.svg-icon-play:before {
  background-image: url("/themes/custom/ereshnv/images/icons-svg/Play Črn II_dark.svg");
}
.svg-icon-pause:before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23ff0' d='M14,19H18V5H14M6,19H10V5H6V19Z'%3E%3C/path%3E%3C/svg%3E"); }
.svg-icon-playpause:before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23ff0' d='M3,5V19L11,12M13,19H16V5H13M18,5V19H21V5'%3E%3C/path%3E%3C/svg%3E"); }
.svg-icon-loading:before { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='%23ff0' d='M12,2A10,10,0,0,0,2,12A10,10,0,0,0,12,22A10,10,0,0,0 22,12H20A8,8,0,0,1,12,20A8,8,0,0,1,4,12A8,8,0,0,1,12,4V2Z'%3E%3C/path%3E%3C/svg%3E"); }

/* kvadratek v stop gumbu */
.svg-icon-stop {
  position: relative;
}
.svg-icon-stop:after {
  content: '';
  background: var(--header-bg-color);
  position: absolute;
  top: 25%;
  left: 25%;
  height: 50% !important;
  width: 50% !important;
}

@keyframes loading-spin {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@media screen and (max-width: 640px) {
  .player-vrstica .remtime {
    display: none;
  }
}
