/* rp-bundle (snippets/rp-bundle.php): "leve mais, pague menos" na página do produto. */
.rp-bundle { display: block; margin: 4px 0 14px; }

.rp-bundle__head { display: flex; align-items: baseline; flex-wrap: wrap; gap: 2px 10px; margin: 0 0 12px; }
/* "Black Friday" na fonte da marca, no mesmo dourado em degradê dos títulos e chamadas da home. */
.rp-bundle__label {
  margin: 0;
  font-family: "RP Awesome Serif Trial", Georgia, "Times New Roman", serif;
  font-size: 20px;
  font-weight: 500;
  line-height: 1.15;
  letter-spacing: normal;
}
.rp-bundle__label-text {
  display: inline-block;
  padding: 0 .05em;
  background: linear-gradient(100deg, #b5914f 0%, #d9b56e 45%, #a9843f 75%, #c9a45c 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  color: transparent;
}
.rp-bundle__label em { font-family: inherit; font-style: italic; font-weight: 400; }
.rp-bundle__title { font-size: 13px; font-weight: 500; color: #2b1720; }

.rp-bundle__tiers { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; }
.rp-bundle .rp-bundle__tier {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  min-height: 0;
  margin: 0;
  padding: 16px 6px 10px;
  border: 1.5px solid #efd5d9;
  border-radius: 6px;
  background: #fff;
  color: #2b1720;
  font: inherit;
  text-align: center;
  cursor: pointer;
  box-shadow: none;
  transition: border-color .2s ease, background-color .2s ease, transform .2s ease;
}
.rp-bundle .rp-bundle__tier:hover { border-color: #e48a95; }
.rp-bundle .rp-bundle__tier.is-active { border-color: #2b1720; background: #fff6f7; }
.rp-bundle .rp-bundle__tier:focus-visible { outline: 2px solid #2b1720; outline-offset: 2px; }
.rp-bundle__tag {
  position: absolute;
  top: -9px;
  left: 50%;
  padding: 2px 8px;
  border-radius: 3px;
  background: linear-gradient(90deg, #c4566a, #e48a95);
  color: #fff;
  font-size: 9px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  white-space: nowrap;
  transform: translateX(-50%);
}
.rp-bundle__qty { font-size: 12px; font-weight: 500; }
.rp-bundle__price { font-size: 19px; font-weight: 600; line-height: 1.2; }
.rp-bundle__each { min-height: 15px; font-size: 11px; color: #7a6870; }
.rp-bundle__each s { color: #a8979e; }
.rp-bundle__save {
  margin-top: 3px;
  padding: 2px 7px;
  border-radius: 3px;
  background: #fbe9ec;
  color: #b23a52;
  font-size: 10.5px;
  font-weight: 600;
}

.rp-bundle__pick { margin-top: 12px; }
.rp-bundle__slots { display: flex; flex-wrap: wrap; gap: 6px; margin: 0; padding: 0; list-style: none; }
.rp-bundle .rp-bundle__slot {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 0;
  margin: 0;
  padding: 5px 10px 5px 6px;
  border: 1.5px solid #efd5d9;
  border-radius: 6px;
  background: #fff;
  color: #2b1720;
  font: inherit;
  font-size: 12px;
  line-height: 1.2;
  cursor: pointer;
  box-shadow: none;
}
.rp-bundle .rp-bundle__slot.is-active { border-color: #2b1720; box-shadow: 0 0 0 3px rgba(228, 138, 149, .25); }
.rp-bundle .rp-bundle__slot.is-empty { border-style: dashed; color: #7a6870; }
.rp-bundle__dot {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: var(--rp-shade, #fff);
  box-shadow: inset 0 0 0 1px rgba(43, 23, 32, .14);
}
.rp-bundle__slot.is-empty .rp-bundle__dot { background: repeating-linear-gradient(45deg, #f6e8ea 0 3px, #fff 3px 6px); }
.rp-bundle__num { font-weight: 600; }
.rp-bundle__hint { min-height: 17px; margin: 8px 0 0; font-size: 12px; color: #b23a52; }
.rp-bundle.is-nudge .rp-bundle__slot.is-active,
.rp-bundle.is-nudge .rp-bundle__hint { animation: rp-bundle-nudge .5s ease 2; }
.rp-bundle__extra { margin: 10px 0 0; font-size: 12px; color: #7a6870; }

/* Paletas ("visual": "palette", como o Glow Maximizer): cada unidade é uma mini paleta de 4 cores, como as do seletor
   (--rp-shade com 4 camadas, em rp-shade-colors.php), com as divisões, a moldura e o brilho por cima. */
.rp-bundle__stack { display: flex; align-items: center; justify-content: center; height: 30px; margin: 2px 0 6px; }
.rp-bundle__pal,
.rp-bundle--palette .rp-bundle__dot {
  position: relative;
  flex: none;
  box-sizing: border-box;
  width: 24px;
  height: 24px;
  border-radius: 5px;
  background: var(--rp-shade, #f3e6e8);
  box-shadow: 0 1px 3px rgba(43, 23, 32, .2);
}
.rp-bundle__pal::before,
.rp-bundle--palette .rp-bundle__dot::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background:
    linear-gradient(90deg, transparent calc(50% - .75px), rgba(255, 255, 255, .95) calc(50% - .75px), rgba(255, 255, 255, .95) calc(50% + .75px), transparent calc(50% + .75px)),
    linear-gradient(180deg, transparent calc(50% - .75px), rgba(255, 255, 255, .95) calc(50% - .75px), rgba(255, 255, 255, .95) calc(50% + .75px), transparent calc(50% + .75px)),
    linear-gradient(135deg, rgba(255, 255, 255, .65) 0%, rgba(255, 255, 255, 0) 36%, rgba(255, 255, 255, 0) 64%, rgba(255, 255, 255, .35) 100%);
  box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .9);
}
/* Em leque: 2 ou 3 paletas uma sobre a outra, a do meio por cima. */
.rp-bundle__pal + .rp-bundle__pal { margin-left: -6px; }
.rp-bundle__stack[data-n="2"] .rp-bundle__pal:first-child { transform: rotate(-8deg); }
.rp-bundle__stack[data-n="2"] .rp-bundle__pal:last-child { transform: rotate(8deg) translateY(-1px); }
.rp-bundle__stack[data-n="3"] .rp-bundle__pal:first-child { transform: rotate(-12deg) translateY(2px); }
.rp-bundle__stack[data-n="3"] .rp-bundle__pal:nth-child(2) { z-index: 1; transform: translateY(-2px); }
.rp-bundle__stack[data-n="3"] .rp-bundle__pal:last-child { transform: rotate(12deg) translateY(2px); }
/* A paleta que ainda falta escolher: contorno tracejado e um "+". */
.rp-bundle__pal.is-empty,
.rp-bundle--palette .rp-bundle__slot.is-empty .rp-bundle__dot {
  border: 1.5px dashed #e3b6bd;
  background: #fff;
  box-shadow: none;
}
.rp-bundle__pal.is-empty::before,
.rp-bundle--palette .rp-bundle__slot.is-empty .rp-bundle__dot::before {
  content: "+";
  display: grid;
  place-items: center;
  background: none;
  box-shadow: none;
  color: #c4566a;
  font-size: 14px;
  font-weight: 600;
  line-height: 1;
}
.rp-bundle__pal.is-pop { animation: rp-bundle-pop .35s ease; }
/* As unidades da promoção lado a lado, cada uma com a sua paleta, o número e o nome do tom. */
.rp-bundle--palette .rp-bundle__slots { display: grid; grid-auto-flow: column; grid-auto-columns: minmax(0, 1fr); gap: 6px; }
.rp-bundle.rp-bundle--palette .rp-bundle__slot {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  width: 100%;
  height: 100%;
  padding: 10px 6px 8px;
  gap: 6px;
  text-align: center;
}
.rp-bundle--palette .rp-bundle__dot { width: 30px; height: 30px; border-radius: 6px; }
.rp-bundle--palette .rp-bundle__num { position: absolute; top: 5px; left: 7px; font-size: 10px; color: #a8979e; }
.rp-bundle--palette .rp-bundle__slot.is-active .rp-bundle__num { color: #2b1720; }
.rp-bundle--palette .rp-bundle__name { font-size: 11px; line-height: 1.25; }

/* Quantas vezes a cor entrou na promoção, em cima da bolinha do seletor. Na mini paleta (rp-shade--quad), o ::before
   já desenha as divisões e o brilho, então o número vai no ::after. */
.rp-mp .rp-shade:not(.rp-shade--quad)[data-rp-bundle-count]::before,
.rp-mp .rp-shade--quad[data-rp-bundle-count]::after {
  content: attr(data-rp-bundle-count);
  position: absolute;
  top: -6px;
  right: -6px;
  z-index: 1;
  display: grid;
  place-items: center;
  min-width: 16px;
  height: 16px;
  padding: 0 3px;
  border-radius: 999px;
  background: #2b1720;
  color: #fff;
  font-size: 9.5px;
  font-weight: 600;
  line-height: 1;
}

@keyframes rp-bundle-nudge {
  0%, 100% { transform: translateX(0); }
  30% { transform: translateX(-4px); }
  60% { transform: translateX(4px); }
}
/* A paleta que acabou de ganhar cor: cresce um pouco e volta (no "translate" e no "scale", sem mexer no leque). */
@keyframes rp-bundle-pop {
  0% { scale: .6; }
  60% { scale: 1.15; }
  100% { scale: 1; }
}

@media (prefers-reduced-motion: reduce) {
  .rp-bundle .rp-bundle__tier { transition: none; }
  .rp-bundle.is-nudge .rp-bundle__slot.is-active,
  .rp-bundle.is-nudge .rp-bundle__hint,
  .rp-bundle__pal.is-pop { animation: none; }
}

/* Aviso da promoção na gaveta do carrinho (snippets/rp-bundle-cart.php). */
.rp-bundle-cart {
  display: block;
  margin: 0 0 12px;
  padding: 12px 14px;
  border: 1px solid #f0e3e5; /* como os cartões da gaveta */
  border-radius: 8px;
  background: #fff;
}
.rp-bundle-cart .rp-bundle-cart__label { font-size: 18px; }
.rp-bundle-cart__text { margin: 2px 0 6px; font-size: 13px; line-height: 1.45; color: #2b1720; }
.rp-bundle-cart .rp-bundle-cart__more {
  min-height: 0;
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: #2b1720;
  font: inherit;
  font-size: 12px;
  font-weight: 500;
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: #c9a45c;
  cursor: pointer;
  box-shadow: none;
}
