.wc-eprel {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  margin: 0 0 1em;
}

.wc-eprel__label {
  display: inline-block;
  margin-right: 10px;
  line-height: 0;
  cursor: pointer;
}

.wc-eprel .wc-eprel-arrow {
  display: block;
  width: 66px;
  height: 36px;
}

.wc-eprel__sheet {
  font-size: 0.875em;
  text-decoration: underline;
  cursor: pointer;
}

.wc-eprel--price {
  display: inline-flex;
  align-items: center;
  margin: -12px 0 -12px 10px;
  line-height: 0;
  vertical-align: middle;
}

.wc-eprel--price .wc-eprel-arrow {
  width: 58px;
  height: 32px;
}

.wc-eprel--price .wc-eprel__sheet {
  margin-left: 8px;
  line-height: 1.2;
}

/* Product page below 769px: the price is left aligned with room, so the
   sheet link is on the price line and the separate line is hidden. */
@media only screen and (max-width: 768px) {
  .wc-eprel--single {
    display: none;
  }
}

@media only screen and (min-width: 769px) {
  .wc-eprel--price .wc-eprel__sheet {
    display: none;
  }
}

.wc-eprel--price .wc-eprel__label {
  margin: 0;
}

.wc-eprel--single {
  clear: both;
  margin: 0 0 0.5em;
  padding-top: 4px;
  line-height: 1.2;
}

/* superstore product page from 769px: title 74.5% and price 25% side by side.
   The price column takes the width of price and arrow. If both do not fit
   next to the title, the price line moves below the title. */
@media only screen and (min-width: 769px) {
  .single-product .wc-eprel-has-label .summary > .product_title {
    width: 59.5%;
  }

  .single-product .wc-eprel-has-label .summary .price {
    width: auto;
    white-space: nowrap;
  }

  .single-product .wc-eprel-has-label .wc-eprel--single {
    justify-content: flex-end;
  }
}

.wc-eprel--loop {
  margin: 0.5em 0;
}

.wc-eprel--loop .wc-eprel-arrow {
  width: 55px;
  height: 30px;
}

/* Themes that show the list price as a badge on the image (superstore):
   arrow and sheet link in the bottom right corner of the image. */
.img-wrap .wc-eprel--loop {
  position: absolute;
  right: 0.4em;
  bottom: 0.4em;
  flex-direction: column;
  align-items: flex-end;
  margin: 0;
}

.img-wrap .wc-eprel--loop .wc-eprel__label {
  margin: 0 0 3px;
}

.img-wrap .wc-eprel--loop .wc-eprel__sheet {
  padding: 1px 4px;
  font-size: 10px;
  line-height: 1.3;
  background: rgba(255, 255, 255, 0.9);
}

/* Energy label preview on mouse over (assets/wc-eprel.js). Size and position
   are set by the script; the label image is 1:2. */
.wc-eprel-popover {
  position: fixed;
  z-index: 100000;
  box-sizing: border-box;
  padding: 6px;
  background: #fff;
  border: 1px solid #ccc;
  border-radius: 4px;
  box-shadow: 0 6px 24px rgba(0, 0, 0, 0.25);
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.15s ease, visibility 0.15s ease;
}

.wc-eprel-popover--visible {
  opacity: 1;
  visibility: visible;
}

.wc-eprel-popover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.wc-eprel-popover--loading {
  background: #fff linear-gradient(90deg, #f3f3f3, #fff, #f3f3f3);
}

.wc-eprel-popover--loading img {
  visibility: hidden;
}
