/* MedicalMag — карточка товара (редизайн 16.09.2026). Логика — lib.php, поведение — mm-product.js */

/* ---------- колонка покупки ---------- */
.mm-pf { display: grid; gap: 10px; }
.mm-pf__row { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 18px; }
.mm-pf__row > .grid-list__item { margin: 0; }
.mm-pf__links { font-size: 13px; }

.mm-credit-line {
	display: grid; grid-template-columns: 1fr; gap: 8px; align-items: start;
	padding: 12px 14px; border-radius: 8px; background: #f4f6f1;
}
.mm-credit-line__text { display: flex; flex-direction: column; min-width: 0; }
.mm-credit-line__title { font-size: 12px; line-height: 16px; color: #666; }
.mm-credit-line__lead { font-size: 16px; line-height: 22px; font-weight: 700; color: #172b21; }
.mm-credit-line__sub { font-size: 12px; line-height: 16px; color: #555; }
.mm-credit-line__btn {
	justify-self: start; min-height: 34px; padding: 0 12px; border: 1px solid #cfd6ca; border-radius: 8px; background: #fff;
	font: inherit; font-size: 13px; font-weight: 600; color: #172b21; cursor: pointer; white-space: nowrap;
}
.mm-credit-line__btn:hover { border-color: var(--mm-brand, #4c8945); color: var(--mm-brand, #4c8945); }
.mm-credit-line__note { grid-column: 1 / -1; font-size: 11px; line-height: 15px; color: #888; }
.mm-credit-line__note a { color: inherit; }

.mm-calc-link { display: inline-flex; align-items: center; gap: 8px; color: var(--mm-brand, #4c8945); font-size: 13px; font-weight: 600; text-decoration: none; }
.mm-calc-link:hover b, .mm-calc-link:hover > span:only-of-type { text-decoration: underline; }
.mm-calc-link--pb { align-items: flex-start; }
.mm-calc-link--pb svg { margin-top: 2px; }
.mm-calc-link--pb > span { display: flex; flex-direction: column; }
.mm-calc-link--pb small { font-size: 12px; font-weight: 400; color: #666; }

/* ---------- средняя колонка ---------- */
.mm-product-main { display: grid; gap: 16px; }
.mm-benefits__title { margin-bottom: 10px; font-size: 14px; font-weight: 600; color: #172b21; }
.mm-benefits__list { display: grid; grid-template-columns: 1fr; gap: 6px; margin: 0; padding: 0; list-style: none; }
.mm-benefits__list li { margin: 0; padding: 0; }
.mm-benefits__list li::before { display: none !important; content: none !important; }
.mm-benefits__list a, .mm-benefits__static {
	display: flex; gap: 10px; align-items: center; padding: 8px 12px; border-radius: 8px; background: #f4f6f1;
	color: #172b21; text-decoration: none; box-sizing: border-box;
}
.mm-benefits__list a:hover { background: #edf2e8; }
.mm-benefits__icon { flex: 0 0 22px; color: var(--mm-brand, #4c8945); line-height: 0; }
.mm-benefits__text { display: flex; flex-direction: column; min-width: 0; }
.mm-benefits__text b { font-size: 13px; line-height: 18px; font-weight: 600; }
.mm-benefits__text span { font-size: 12px; line-height: 16px; color: #666; }

.mm-brand { display: flex; align-items: center; gap: 14px; padding-top: 4px; }
.mm-brand__logo { flex: 0 0 auto; display: block; width: 96px; }
.mm-brand__logo img { display: block; max-width: 100%; max-height: 40px; object-fit: contain; }
.mm-brand__links { display: flex; flex-wrap: wrap; gap: 4px 16px; font-size: 13px; }
.mm-brand__links a { color: #555; text-decoration: none; border-bottom: 1px solid #d6dbd2; }
.mm-brand__links a:hover { color: var(--mm-brand, #4c8945); border-color: currentColor; }

/* ---------- галерея ---------- */
.detail-gallery-big-slider-main { position: relative; }
.mm-gallery-video {
	position: absolute; left: 12px; bottom: 12px; z-index: 5; display: inline-flex; align-items: center; gap: 8px;
	padding: 6px 14px 6px 6px; border: 0; border-radius: 20px; background: rgba(23, 43, 33, .82); color: #fff;
	font: inherit; font-size: 13px; font-weight: 600; cursor: pointer;
}
.mm-gallery-video__play { display: inline-flex; align-items: center; justify-content: center; width: 26px; height: 26px; border-radius: 50%; background: var(--mm-brand, #4c8945); }
.mm-gallery-video__play svg { margin-left: 2px; }

/* ---------- меню блоков ---------- */
.mm-block-nav-holder { margin: 48px 0 0; }
.mm-block-nav { position: relative; z-index: 20; background: #fff; border-bottom: 1px solid #e3e7df; }
.mm-block-nav.is-fixed { position: fixed; left: 0; right: 0; box-shadow: 0 4px 12px rgba(0, 0, 0, .06); }
.mm-block-nav.is-fixed .mm-block-nav__inner { max-width: 1344px; margin: 0 auto; padding: 0 48px; box-sizing: border-box; }
.mm-block-nav__inner { display: flex; gap: 4px; overflow-x: auto; scrollbar-width: none; }
.mm-block-nav__inner::-webkit-scrollbar { display: none; }
.mm-block-nav a { flex: 0 0 auto; padding: 14px 14px 12px; border-bottom: 2px solid transparent; font-size: 14px; font-weight: 600; color: #555; text-decoration: none; white-space: nowrap; }
.mm-block-nav a:hover { color: #172b21; }
.mm-block-nav a.is-active { color: #172b21; border-color: var(--mm-brand, #4c8945); }
.catalog-detail__bottom-info[data-mm-product] { margin-top: 32px !important; }

/* ---------- описание ---------- */
.mm-collapsible { position: relative; max-height: 420px; overflow: hidden; }
.mm-collapsible::after { content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 96px; background: linear-gradient(rgba(255,255,255,0), #fff); pointer-events: none; }
.mm-collapsible.is-open { max-height: none; }
.mm-collapsible.is-open::after { display: none; }
.mm-more-btn { margin-top: 12px; min-height: 38px; padding: 0 18px; border: 1px solid #cfd6ca; border-radius: 8px; background: #fff; font: inherit; font-size: 14px; font-weight: 600; color: #172b21; cursor: pointer; }
.mm-more-btn:hover { border-color: var(--mm-brand, #4c8945); color: var(--mm-brand, #4c8945); }

/* ---------- калькулятор ---------- */
.mm-calc .pc-wrap { display: none; }
.mm-calc.mm-calc-open .pc-wrap { display: block; }
.mm-calc.mm-calc-open .mm-calc__open { display: none; }
.mm-calc__intro { display: flex; align-items: center; justify-content: space-between; gap: 20px; padding: 20px 24px; border-radius: 12px; background: #f4f6f1; }
.mm-calc__intro div { display: flex; flex-direction: column; gap: 6px; flex: 1; min-width: 0; }
.mm-calc__icon { flex: 0 0 56px; width: 56px; height: 56px; border-radius: 16px; display: flex; align-items: center; justify-content: center; background: var(--mm-brand, #4c8945); color: #fff; }
.mm-calc__intro div > span { line-height: 20px; }
.mm-calc__intro b { font-size: 18px; color: #172b21; }
/* текст плашки — серый; иконку не задевает (раньше .mm-calc__intro span перекрашивал её в #555 — тёмное на зелёном) */
.mm-calc__intro div > span { font-size: 14px; color: #555; }
.mm-calc__intro .mm-calc__icon { color: #fff; }
.mm-calc__open { flex: 0 0 auto; min-height: 44px; padding: 0 22px; border: 0; border-radius: 8px; background: var(--mm-brand, #4c8945); color: #fff; font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; }
.mm-calc.mm-calc-open .mm-calc__intro { margin-bottom: 16px; }
.mm-calc__note { margin: 16px 0 0; font-size: 12px; line-height: 17px; color: #777; }

/* ---------- оплата и доставка (как блок рассрочки на главной) ---------- */
.mm-buyinfo { padding: 32px; border: 1px solid #e3e7df; border-radius: 16px; background: #fbfcfa; }
.mm-buyinfo__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 24px; margin-bottom: 24px; }
.mm-buyinfo__eyebrow { display: block; margin-bottom: 6px; font-size: 13px; font-weight: 700; letter-spacing: .03em; text-transform: uppercase; color: var(--mm-brand, #4c8945); }
.mm-buyinfo__title { margin: 0; font-size: 28px; line-height: 1.2; font-weight: 700; color: #172b21; }
.mm-buyinfo__lead { margin: 10px 0 0; font-size: 15px; line-height: 1.5; color: #555; }
.mm-buyinfo__actions { display: flex; align-items: center; gap: 18px; flex: 0 0 auto; }
.mm-buyinfo__btn { min-height: 46px; padding: 0 24px; border: 0; border-radius: 8px; background: var(--mm-brand, #4c8945); color: #fff; font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; }
.mm-buyinfo__btn:hover { background: #3f7539; }
.mm-buyinfo__link { font-size: 14px; font-weight: 600; color: var(--mm-brand, #4c8945); text-decoration: none; white-space: nowrap; }

.mm-pay-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 0; padding: 0; list-style: none; }
.mm-pay-card { display: flex; flex-direction: column; margin: 0; padding: 20px 20px 22px; border: 1px solid #e3e7df; border-radius: 12px; background: #fff; }
.mm-pay-card::before { display: none !important; }
.mm-pay-card--split { background: #faffed; }
.mm-pay-card--halva { background: #fffafa; }
.mm-pay-card--invoice { background: #f3f7fa; }
.mm-pay-brand { display: flex; align-items: center; gap: 12px; min-height: 64px; margin-bottom: 12px; }
.mm-pay-card__name { font-size: 16px; line-height: 1.3; font-weight: 700; color: #172b21; }
.mm-pay-brand__split { display: block; flex: 0 0 40px; width: 40px; height: 40px; }
.mm-pay-brand__split i { display: block; width: 20px; height: 20px; background: url('/local/templates/aspro-premier/images/svg/payment.svg') -1077px 0 no-repeat; transform: scale(2); transform-origin: top left; }
.mm-pay-brand__halva { display: block; width: 100px !important; max-width: 100px !important; height: auto; margin-left: auto; border-radius: 7px; box-shadow: 0 3px 10px rgba(25, 44, 35, .12); }
.mm-pay-brand__invoice { display: block; flex: 0 0 100px; width: 100px; height: 64px; margin-left: auto; }
.mm-pay-card__lead { margin-bottom: 6px; font-size: 20px; line-height: 1.25; font-weight: 700; color: #172b21; }
.mm-pay-card__text { font-size: 14px; line-height: 1.45; color: #555; }

.mm-pay-rows { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 16px; margin: 20px 0 0; padding: 20px 0 0; list-style: none; border-top: 1px solid #e3e7df; }
.mm-pay-rows li { display: flex; gap: 12px; align-items: flex-start; margin: 0; padding: 0; }
.mm-pay-rows li::before { display: none !important; }
.mm-pay-rows__icon { flex: 0 0 40px; width: 40px; height: 40px; border-radius: 10px; display: flex; align-items: center; justify-content: center; background: #edf2e8; color: var(--mm-brand, #4c8945); }
.mm-pay-rows li > span:last-child { display: flex; flex-direction: column; gap: 2px; }
.mm-pay-rows b { font-size: 14px; line-height: 1.35; color: #172b21; }
.mm-pay-rows li > span:last-child > span { font-size: 13px; line-height: 1.4; color: #666; }
.mm-buyinfo__note { margin: 20px 0 0; font-size: 12px; line-height: 1.5; color: #888; }
.mm-buyinfo__note a { color: inherit; }

/* ---------- полоса покупки ---------- */
.mm-sticky-buy {
	position: fixed; left: 0; right: 0; bottom: 0; z-index: 900; transform: translateY(110%); transition: transform .2s ease;
	background: #fff; box-shadow: 0 -6px 20px rgba(0, 0, 0, .08);
}
.mm-sticky-buy.is-visible { transform: none; }
.mm-sticky-buy__inner { display: flex; align-items: center; gap: 24px; max-width: 1344px; margin: 0 auto; padding: 12px 48px; box-sizing: border-box; }
.mm-sticky-buy__name { flex: 1; min-width: 0; font-size: 15px; font-weight: 600; color: #172b21; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.mm-sticky-buy__price { font-size: 20px; font-weight: 700; color: #172b21; white-space: nowrap; }
.mm-sticky-buy__btn { min-height: 44px; padding: 0 28px; border: 0; border-radius: 8px; background: var(--mm-brand, #4c8945); color: #fff; font: inherit; font-size: 15px; font-weight: 600; cursor: pointer; }

@media (max-width: 991px) {
	.mm-sticky-buy { display: none; }
	.mm-buyinfo__head { flex-direction: column; align-items: flex-start; }
	.mm-pay-cards, .mm-pay-rows { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 767px) {
	.mm-buyinfo { padding: 20px 16px; }
	.mm-buyinfo__title { font-size: 22px; }
	.mm-buyinfo__actions { flex-wrap: wrap; }
	.mm-pay-cards, .mm-pay-rows { grid-template-columns: 1fr; }
	.mm-benefits__list { grid-template-columns: 1fr 1fr; }
	.mm-benefits__list a, .mm-benefits__static { align-items: flex-start; height: 100%; box-sizing: border-box; }
	.mm-calc__intro { flex-direction: column; align-items: flex-start; }
	.mm-block-nav-holder { margin-top: 24px; }
	.mm-block-nav.is-fixed .mm-block-nav__inner { padding: 0 16px; }
	.mm-credit-line { grid-template-columns: 1fr; }
	.mm-credit-line__btn { justify-self: start; }
}

/* тема Aspro подчёркивает текст внутри ссылок */
.mm-benefits__list a, .mm-benefits__list a span, .mm-benefits__list a b,
.mm-block-nav a, .mm-calc-link, .mm-calc-link span,
.mm-credit-line__note a { text-decoration: none !important; border-bottom: 0 !important; }
.mm-credit-line__note a { text-decoration: underline !important; }

/* Aspro прячет значения краткого списка характеристик до 600 px (compact-hidden-t600), заголовок оставался пустым */
@media (max-width: 600px) {
	.catalog-detail__main .properties-wrapper .properties-heading { display: none; }
}

/* ---------- летающая иконка окупаемости (слева) ---------- */
.mm-pb-float {
	position: fixed; left: 24px; bottom: 32px; z-index: 950; display: flex; align-items: flex-start;
	opacity: 0; transform: translateY(20px); pointer-events: none; transition: opacity .35s ease, transform .35s ease, bottom .25s ease;
}
.mm-pb-float.is-shown { opacity: 1; transform: none; pointer-events: auto; }
.mm-pb-float.is-shown.is-hidden { opacity: 0; transform: translateY(20px); pointer-events: none; }
.mm-pb-float.is-raised { bottom: 96px; }
.mm-pb-float__main {
	display: flex; align-items: center; gap: 12px; padding: 0 20px 0 0; border: 0; background: none; cursor: pointer; font: inherit; text-align: left;
	animation: mm-pb-fly 3.2s ease-in-out infinite;
}
.mm-pb-float__icon {
	position: relative; flex: 0 0 64px; width: 64px; height: 64px; border-radius: 20px; display: flex; align-items: center; justify-content: center;
	background: linear-gradient(145deg, #5da154, var(--mm-brand, #4c8945) 55%, #3b7035); color: #fff;
	box-shadow: 0 10px 24px rgba(60, 112, 53, .35);
}
.mm-pb-float__icon::after {
	content: ""; position: absolute; inset: -6px; border-radius: 24px; border: 2px solid rgba(76, 137, 69, .45);
	animation: mm-pb-ring 2.4s ease-out infinite;
}
.mm-pb-float__text {
	display: flex; flex-direction: column; padding: 8px 14px; border-radius: 12px; background: #fff; color: #172b21;
	box-shadow: 0 6px 20px rgba(0, 0, 0, .12); white-space: nowrap;
}
.mm-pb-float__text small { font-size: 12px; line-height: 16px; color: #666; }
.mm-pb-float__text b { font-size: 16px; line-height: 20px; }
.mm-pb-float__main:hover .mm-pb-float__icon { box-shadow: 0 14px 30px rgba(60, 112, 53, .45); }
.mm-pb-float__close {
	width: 22px; height: 22px; margin-left: -14px; padding: 0; border: 0; border-radius: 50%; background: #fff; color: #888;
	font-size: 15px; line-height: 22px; cursor: pointer; box-shadow: 0 2px 8px rgba(0, 0, 0, .15);
}
.mm-pb-float__close:hover { color: #172b21; }
.mm-pb-float__badge { display: none; }
@keyframes mm-pb-fly { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-8px); } }
@keyframes mm-pb-ring { 0% { opacity: .9; transform: scale(.92); } 100% { opacity: 0; transform: scale(1.25); } }
@media (prefers-reduced-motion: reduce) {
	.mm-pb-float__main, .mm-pb-float__icon::after { animation: none; }
}
@media (max-width: 991px) {
	.mm-pb-float { left: 12px; bottom: 150px; }
	.mm-pb-float.is-raised { bottom: 150px; }
	.mm-pb-float__icon { flex-basis: 52px; width: 52px; height: 52px; border-radius: 16px; }
	/* на телефоне только иконка со значком срока — текстовая плашка закрывала кнопки */
	.mm-pb-float__text { display: none; }
	.mm-pb-float__main { padding: 0; }
	.mm-pb-float__close { margin-left: -10px; }
	.mm-pb-float__badge {
		display: block; position: absolute; left: 50%; bottom: -8px; transform: translateX(-50%); z-index: 1;
		padding: 1px 6px; border-radius: 8px; background: #fff; color: #172b21; font-size: 11px; font-weight: 700; line-height: 16px;
		white-space: nowrap; box-shadow: 0 2px 6px rgba(0, 0, 0, .18);
	}
	.mm-calc__intro { flex-wrap: wrap; }
}

/* ---------- отзывы с Яндекс Карт: карточка рейтинга в правой колонке блока отзывов ---------- */
#catalog_comments .comments-block__reviews-info.mm-reviews-column { display: flex !important; flex-direction: column; gap: 16px; flex: 0 0 355px; width: 355px; max-width: 100%; }
#catalog_comments .mm-reviews-column .sticky-block { position: static; }
.mm-ymaps-card { display: flex; flex-direction: column; gap: 14px; padding: 20px 22px; border: 1px solid #e3e7df; border-radius: 12px; background: #fff; }
.mm-ymaps-card__head { display: flex; align-items: center; gap: 8px; font-size: 13px; font-weight: 600; color: #555; }
.mm-ymaps-card__pin { position: relative; flex: 0 0 22px; width: 22px; height: 22px; border-radius: 50%; background: #fc3f1d; }
.mm-ymaps-card__pin::after { content: ""; position: absolute; left: 50%; top: 45%; width: 7px; height: 7px; border-radius: 50% 50% 50% 0; background: #fff; transform: translate(-50%, -50%) rotate(-45deg); }
.mm-ymaps-card__score { display: flex; align-items: center; gap: 12px; }
.mm-ymaps-card__score > b { font-size: 40px; line-height: 1; font-weight: 700; color: #172b21; }
.mm-ymaps-card__score > span { display: flex; flex-direction: column; gap: 2px; }
.mm-ymaps-card__stars { font-size: 18px; line-height: 20px; letter-spacing: 1px; color: #fc0; }
.mm-ymaps-card__score small { font-size: 13px; color: #666; }
.mm-ymaps-card__actions { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; }
.mm-ymaps-card__btn { display: inline-flex; align-items: center; min-height: 40px; padding: 0 18px; border: 1px solid #cfd6ca; border-radius: 8px; font-size: 14px; font-weight: 600; color: #172b21 !important; text-decoration: none !important; }
.mm-ymaps-card__btn:hover { border-color: var(--mm-brand, #4c8945); color: var(--mm-brand, #4c8945) !important; }
.mm-ymaps-card__link { font-size: 14px; font-weight: 600; color: var(--mm-brand, #4c8945) !important; text-decoration: none !important; border-bottom: 0 !important; }
@media (max-width: 991px) {
	#catalog_comments .comments-block__wrapper { flex-wrap: wrap; }
	#catalog_comments .comments-block__reviews-info.mm-reviews-column { flex-basis: 100%; width: 100%; order: 2; }
	#catalog_comments .comments-block__wrapper > .comments-block { order: 1; }
}

/* 22.09.2026: на телефоне плавающая иконка калькулятора вместе с виджетами WhatsApp и чата
   закрывала цену, кешбэк и блок рассрочки в верхней части карточки. На смартфонах её убираем —
   калькулятор остаётся доступен ссылкой «Рассчитать окупаемость» в колонке покупки и якорем
   в меню блоков. На планшетах (768–991px) иконка остаётся. */
@media (max-width: 767px) {
	.mm-pb-float {
		display: none !important;
	}
}

/* Результаты процедур (фото до/после, свойство MM_RESULTS) */
.mm-results__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.mm-results__item, .mm-results__item:hover { display: flex; flex-direction: column; text-decoration: none !important; color: inherit; border-bottom: 0; }
.mm-results__caption, .mm-docs__name { text-decoration: none; }
.mm-results__img { display: block; aspect-ratio: 4 / 3; border-radius: 12px; overflow: hidden; background: #f3f5f4; }
.mm-results__img img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .3s; }
.mm-results__item:hover .mm-results__img img { transform: scale(1.03); }
.mm-results__caption { margin-top: 10px; font-size: 14px; line-height: 1.45; color: var(--black_text_black, #1f2937); }
.mm-results__note { margin: 16px 0 0; font-size: 13px; line-height: 1.5; color: #64748b; }
@media (max-width: 991px) { .mm-results__grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 600px) {
	.mm-results__grid { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; gap: 12px; margin-right: -16px; padding-right: 16px; }
	.mm-results__item { flex: 0 0 82%; scroll-snap-align: start; }
}
