/* КМП — современные скругления: карточки товаров, кнопки, варианты фасовки.
   Подключается в шапке темы после stylesheet_min.css. Правки темы не затрагиваются. */

/* ---------- Карточки товаров ---------- */
.product-thumb{
  border:1px solid #e7eef7;
  border-radius:18px;
  padding:14px 14px 16px;
  box-shadow:0 2px 10px rgba(17,29,45,.04);
  -webkit-transition:box-shadow .25s ease, transform .25s ease, border-color .25s ease;
  transition:box-shadow .25s ease, transform .25s ease, border-color .25s ease;
}
.product-thumb:hover{
  border-color:#cfe0fb;
  box-shadow:0 16px 34px rgba(47,124,246,.16);
  -webkit-transform:translateY(-3px);
  transform:translateY(-3px);
}
.product-thumb .image,
.product-thumb .image .item,
.product-thumb .image .owl-stage-outer{border-radius:14px}
.product-thumb .image img{border-radius:14px}
.product-thumb .caption{padding:6px 2px 0}
.product-thumb .fapanel .zakaz a,
.product-thumb .fapanel .rev_wish a,
.product-thumb .fapanel .rev_srav a{border-radius:10px}

/* Карточка в списке и в связанных товарах */
.product-list .product-thumb,
.product_related .product-thumb{border-radius:18px}

/* ---------- Кнопки ---------- */
.btn,
.button-group .btn{
  border-radius:12px;
  -webkit-transition:background-color .2s ease, border-color .2s ease, box-shadow .2s ease, transform .2s ease;
  transition:background-color .2s ease, border-color .2s ease, box-shadow .2s ease, transform .2s ease;
}
.btn-default{border-color:#dfe6ee;background:#fff}
.btn-default:hover,.btn-default:focus{border-color:#b9cbe0;background:#f7fafd}
.btn-primary{border-radius:12px;box-shadow:0 6px 16px rgba(47,124,246,.20)}
.btn-primary:hover{box-shadow:0 10px 22px rgba(47,124,246,.28)}
.btn-lg{border-radius:14px}
.btn-sm{border-radius:10px}
.btn-xs{border-radius:8px}

/* «Купить» и кнопки в карточке товара */
.product-info #button-cart{border-radius:14px}
.product-info #button-cart:hover{-webkit-transform:translateY(-1px);transform:translateY(-1px)}
.product-info .btn-group .btn,
.product-info .btn-wishlist,
.product-info .btn-compare{border-radius:12px}
#button-cart, .btn-cart, .product-thumb .btn{border-radius:12px}

/* ---------- Варианты фасовки (вес в опциях) ---------- */
.product-info .radio,
.product-info .checkbox,
.options_no_buy .radio{
  display:inline-block;
  margin:0 8px 8px 0;
  vertical-align:top;
}
.product-info .radio input[type='radio'] + label.btn,
.product-info .checkbox input[type='checkbox'] + label.btn,
.options_no_buy input[type='radio'] + label.btn,
.product-info input[type='radio'] + label,
.product-info input[type='checkbox'] + label{
  display:inline-flex;
  align-items:center;
  gap:6px;
  padding:8px 16px;
  margin:0;
  border:1px solid #dbe4ee;
  border-radius:999px;
  background:#f7f9fc;
  color:#2b3a4a;
  font-size:13px;
  line-height:1.25;
  box-shadow:none;
  -webkit-transition:background-color .2s ease, border-color .2s ease, box-shadow .2s ease, color .2s ease;
  transition:background-color .2s ease, border-color .2s ease, box-shadow .2s ease, color .2s ease;
}
.product-info .radio input[type='radio'] + label.btn:hover,
.product-info .checkbox input[type='checkbox'] + label.btn:hover,
.product-info input[type='radio'] + label:hover,
.product-info input[type='checkbox'] + label:hover{
  background:#eef4ff;
  border-color:#b9cdf0;
  box-shadow:0 2px 8px rgba(47,124,246,.10);
}
.product-info .radio input[type='radio']:checked + label.btn,
.product-info .checkbox input[type='checkbox']:checked + label.btn,
.product-info input[type='radio']:checked + label,
.product-info input[type='checkbox']:checked + label{
  padding-right:26px;
  border-color:#2f7cf6;
  background:#eaf2ff;
  color:#1d2b3a;
  box-shadow:0 2px 10px rgba(47,124,246,.16);
}
.product-info .radio input[type='radio']:checked + label.btn span.option_price,
.product-info .checkbox input[type='checkbox']:checked + label.btn span.option_price,
.product-info input[type='radio']:checked + label span.option_price,
.product-info input[type='checkbox']:checked + label span.option_price{color:#2f7cf6}
.product-info .radio input[type='radio'] + label.btn span.option_price,
.product-info .checkbox input[type='checkbox'] + label.btn span.option_price,
.product-info input[type='radio'] + label span.option_price,
.product-info input[type='checkbox'] + label span.option_price{color:#7c8a99;font-size:12px}
/* галочка выбранного варианта — справа внутри «пилюли» */
.product-info .radio input[type='radio']:checked + label.btn .fa,
.product-info .checkbox input[type='checkbox']:checked + label.btn .fa,
.product-info input[type='radio']:checked + label .fa,
.product-info input[type='checkbox']:checked + label .fa{
  display:block;
  position:absolute;
  right:9px;
  bottom:50%;
  margin-bottom:-5px;
  font-size:9px;
  color:#2f7cf6;
}
@media (max-width:520px){
  .product-info .radio input[type='radio'] + label.btn,
  .product-info input[type='radio'] + label,
  .product-info input[type='checkbox'] + label{padding:7px 13px;font-size:12px}
  .product-info .radio input[type='radio']:checked + label.btn,
  .product-info input[type='radio']:checked + label{padding-right:23px}
}

/* Страховка от «пустой страницы»: тема ставит <html class="opacity_minus"> (opacity:0)
   и снимает класс только по window.load. Если JS не сработал/задержался — страница остаётся невидимой. */
html.opacity_minus{opacity:1 !important}
