/* Smart Discounts - Front */

/* ---------- Precio original tachado + precio rebajado destacado ---------- */
.product-prices .regular-price,
.product-miniature .regular-price,
.product-price-and-shipping .regular-price,
.sd-regular-price {
  text-decoration: line-through;
  color: #8a8a8a;
  font-weight: 400;
  opacity: 1;
  margin-right: .5em;
}
.sd-regular-price:not([hidden]) { display: inline-block; }

.product-prices .has-discount .current-price-value,
.product-prices .has-discount.product-price,
.product-prices .has-discount .current-price,
.product-price-and-shipping .regular-price ~ .price,
.product-miniature .regular-price ~ .price,
.sd-discounted .current-price-value,
.sd-discounted .current-price,
.sd-discounted .price,
.sd-discounted [itemprop="price"] {
  color: var(--sd-sale-color, #d0021b) !important;
  font-weight: 700;
}
.product-prices .has-discount .current-price-value,
.sd-discounted .current-price-value,
.sd-discounted [itemprop="price"] {
  font-size: calc(1em * var(--sd-sale-scale, 1.3));
}

/* ---------- Fin de oferta en ficha de producto ---------- */
.sd-offer-end { display: inline-flex; flex-wrap: wrap; gap: .5rem; align-items: center; margin: .5rem 0; padding: .35rem .75rem;
  border-radius: 4px; background: #fff4e5; color: #8a4b00; font-size: .875rem; }
.sd-offer-end__countdown { font-weight: 700; font-variant-numeric: tabular-nums; }

/* ---------- Precio por cantidad ---------- */
.sd-tiers { margin: .75rem 0; border: 1px solid #e5e5e5; border-radius: 6px; overflow: hidden; font-size: .9rem; max-width: 460px; }
.sd-tiers__title { padding: .5rem .75rem; background: #f6f6f6; font-weight: 700; text-transform: uppercase; letter-spacing: .03em; font-size: .75rem; }
.sd-tiers__list { list-style: none; margin: 0; padding: 0; }
.sd-tiers__row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; padding: .5rem .75rem; border-top: 1px solid #eee; }
.sd-tiers__qty { min-width: 7.5em; }
.sd-tiers__price { flex: 1; }
.sd-tiers__save { color: var(--sd-sale-color, #d0021b); font-weight: 700; min-width: 3.5em; text-align: right; }
.sd-tiers__pick { border: 1px solid currentColor; background: transparent; border-radius: 4px; padding: .2rem .6rem; cursor: pointer; font-size: .8rem; }
.sd-tiers__pick:hover { background: #111; color: #fff; border-color: #111; }
.sd-tiers__row.is-active { background: #fff6f6; }
.sd-tiers__row.is-active .sd-tiers__price strong, .sd-tiers__row.is-active .sd-tiers__price { color: var(--sd-sale-color, #d0021b); }

/* ---------- Selector de unidades ---------- */
.sd-qty { display: inline-flex; align-items: stretch; border: 1px solid #cfcfcf; border-radius: 4px; overflow: hidden; margin: 0 .5rem .5rem 0; vertical-align: middle; height: 44px; }
.sd-qty__btn { width: 40px; border: 0; background: #f4f4f4; font-size: 1.25rem; line-height: 1; cursor: pointer; }
.sd-qty__btn:hover { background: #e6e6e6; }
.sd-qty input { width: 64px; border: 0; text-align: center; font-size: 1rem; font-weight: 700; -moz-appearance: textfield; }
.sd-qty input::-webkit-outer-spin-button, .sd-qty input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

/* ---------- Etiqueta "-X %" ---------- */
.product-flags .product-flag.sd-discount,
.product-flag.sd-discount,
.sd-badge {
  background: var(--sd-badge-bg, #d0021b) !important;
  color: var(--sd-badge-fg, #fff) !important;
  font-weight: 700;
  font-size: .95rem;
  line-height: 1;
  padding: .4rem .55rem;
  border-radius: 3px;
  text-transform: none;
  letter-spacing: 0;
  min-width: 0;
  box-shadow: 0 1px 2px rgba(0, 0, 0, .15);
}
.sd-badge { position: absolute; top: .6rem; left: .6rem; z-index: 5; pointer-events: none; }
.sd-badge-host { position: relative; }

/* ---------- Página precios especiales ---------- */
.sd-specials-header { margin-bottom: 1rem; }
.sd-specials-header h1 { margin: 0; }
.sd-specials-intro { margin-top: .5rem; }
.sd-specials-filters { margin: 0 0 1rem; border: 1px solid #e5e5e5; border-radius: 6px; padding: .5rem .75rem; background: #fff; }
.sd-specials-filters > summary { cursor: pointer; font-weight: 700; text-transform: uppercase; font-size: .8rem; letter-spacing: .04em; }
.sd-specials-filters #search_filters { display: flex; flex-wrap: wrap; gap: 1rem 2rem; padding: .5rem 0 0; margin: 0; background: transparent; box-shadow: none; }
.sd-specials-filters #search_filters > .h6, .sd-specials-filters #search_filters > p.text-uppercase { flex-basis: 100%; display: none; }
.sd-specials-filters .facet { min-width: 160px; max-height: 260px; overflow: auto; }
