/* Shipping Buddy — checkout enhancements.
 *
 * The legacy `bba-*` selectors are kept alongside the new `sb-*` ones so
 * a cached cart fragment rendered by the pre-0.3.0 plugin still picks up
 * the styling after the upgrade. checkout.js reads either attribute too.
 */

.sb-shipping-fee,
.bba-shipping-fee {
  position: relative;
  cursor: help;
  border-bottom: 1px dotted #6b7280;
}

.sb-shipping-fee[data-sb-tooltip]:hover::after,
.sb-shipping-fee[data-sb-fee-tooltip]:hover::after,
.bba-shipping-fee[data-bba-tooltip]:hover::after,
.bba-shipping-fee[data-bba-fee-tooltip]:hover::after {
  content: attr(data-sb-tooltip, attr(data-sb-fee-tooltip, attr(data-bba-tooltip, attr(data-bba-fee-tooltip))));
  position: absolute;
  right: 0;
  bottom: 100%;
  margin-bottom: 6px;
  background: #111827;
  color: #fff;
  font-size: 12px;
  padding: 6px 8px;
  border-radius: 4px;
  white-space: pre-line;
  z-index: 10;
  min-width: 200px;
  max-width: 320px;
  pointer-events: none;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
}

.sb-shipping-eta,
.bba-shipping-eta {
  color: #6b7280;
  font-size: 12px;
  margin-left: 6px;
  font-style: italic;
}

.sb-shipping-eta:empty,
.bba-shipping-eta:empty {
  display: none;
}
