/* ==========================================================================
   רבנו ספרים — Conversion funnel layer (PDP / cart / checkout) + heter iska.
   Reversible: enqueued by mu-plugin rabenu-conversion.php (kill: RABENU_CONVERSION=false).
   Loads AFTER rabenu-redesign. RTL. Honest only (no fabricated proof).
   ========================================================================== */

/* ---- PDP: savings badge ---- */
.rbrc-save {
  display: inline-flex;
  align-items: baseline;
  gap: .35em;
  margin: var(--sp-2) 0 var(--sp-3);
  padding: .3em .7em;
  background: color-mix(in srgb, var(--sale) 12%, #fff);
  color: var(--sale);
  border: 1px solid color-mix(in srgb, var(--sale) 30%, #fff);
  border-radius: var(--r-pill);
  font-family: var(--font-body);
  font-weight: 800;
  font-size: var(--fs-sm);
  line-height: 1;
}

/* ---- PDP: free-ship line + heter ---- */
.rbrc-pdpline {
  margin: var(--sp-3) 0 0;
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  color: var(--brand-800);
  font-weight: 600;
}

/* ---- Heter iska notice (shared PDP/cart/checkout) ---- */
.rbrc-heter {
  display: flex;
  align-items: center;
  gap: var(--sp-3);
  margin: var(--sp-4) 0 0;
  padding: var(--sp-3) var(--sp-4);
  background: var(--surface-2, #f7f5f0);
  border: 1px dashed var(--brand-200, #cbb79a);
  border-radius: var(--r-md);
  font-family: var(--font-body);
  font-size: var(--fs-xs);
  line-height: 1.45;
  color: var(--ink-2, #4a4a4a);
}
.rbrc-heter__ico { flex: 0 0 auto; color: var(--brand-700); display: grid; place-items: center; }
.rbrc-heter__ico svg { width: 26px; height: 26px; }
.rbrc-heter__txt strong { color: var(--brand-900, #2a2a2a); }
.rbrc-heter a { color: var(--brand-700); font-weight: 700; text-decoration: underline; }
.rbrc-heter a:hover { color: var(--brand-800); }
.rbrc-heter--checkout { margin-top: var(--sp-3); }
.rbrc-heter-row td { padding: var(--sp-2) 0 0 !important; border: 0 !important; }

/* ---- Free-shipping progress bar (cart + checkout) ---- */
.rbrc-ship {
  margin: 0 0 var(--sp-5);
  padding: var(--sp-4);
  background: var(--brand-50);
  border: 1px solid var(--brand-100);
  border-radius: var(--r-lg);
}
.rbrc-ship__msg {
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--brand-900);
  margin-bottom: var(--sp-3);
  text-align: center;
}
.rbrc-ship__msg strong { color: var(--gold-800); }
.rbrc-ship__bar {
  position: relative;
  height: 10px;
  border-radius: var(--r-pill);
  background: color-mix(in srgb, var(--brand-200) 45%, #fff);
  overflow: hidden;
}
.rbrc-ship__fill {
  position: absolute;
  inset-block: 0;
  inset-inline-start: 0;
  background: linear-gradient(90deg, var(--gold-500), var(--gold-700));
  border-radius: var(--r-pill);
  transition: width .4s ease;
}

/* cart: center the trust strip wrapper spacing */
.rbrc-note { margin-bottom: var(--sp-5); }

/* ---- Checkout: secure payment + phone reassurance ---- */
.rbrc-secure {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: .5em;
  margin-top: var(--sp-3);
  font-family: var(--font-body);
  font-size: var(--fs-sm);
  font-weight: 600;
  color: var(--brand-800);
  text-align: center;
}
.rbrc-secure svg { width: 18px; height: 18px; flex: 0 0 auto; color: var(--brand-700); }
.rbrc-secure--phone { font-weight: 500; color: var(--ink-2); }
.rbrc-secure--phone a { color: var(--brand-700); font-weight: 800; text-decoration: none; }

/* ---- Cart cross-sell recommendations ---- */
.rbrc-recs { margin: var(--sp-7) 0 var(--sp-4); }
.rbrc-recs > h2 {
  font-family: var(--font-head);
  font-size: var(--fs-lg);
  margin: 0 0 var(--sp-4);
}
.rbrc-recs__grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--sp-4);
}
.rbrc-rec {
  display: flex;
  flex-direction: column;
  gap: var(--sp-2);
  text-decoration: none;
  color: inherit;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--r-md);
  padding: var(--sp-3);
  transition: transform .15s ease, box-shadow .15s ease, border-color .15s ease;
}
.rbrc-rec:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-3);
  border-color: var(--brand-200);
}
.rbrc-rec__img { aspect-ratio: 1/1; display: grid; place-items: center; background: var(--surface-2); border-radius: var(--r-sm); overflow: hidden; }
.rbrc-rec__img img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; mix-blend-mode: multiply; }
.rbrc-rec__t {
  font-size: var(--fs-sm);
  font-weight: 700;
  line-height: 1.3;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
.rbrc-rec__p { color: var(--gold-800); font-weight: 800; font-size: var(--fs-sm); margin-top: auto; }
.rbrc-rec__p del { color: var(--ink-3); font-weight: 500; font-size: .8em; margin-inline-end: .3em; }

/* ---- Responsive ---- */
@media (max-width: 900px) { .rbrc-recs__grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 600px) {
  .rbrc-recs__grid { grid-template-columns: repeat(2, 1fr); }
  .rbrc-heter { font-size: 11px; }
}
