/* Product page — Figma 226:399 (PC) / 121:2 (mobile) */

body.std-product-page .std-product-crumbs-host,
body.std-product-page #breadcrumbs {
	display: none !important;
}

/* Убираем старую рамку #content — в макете белый фон без бордеров */
body.std-product-page #content {
	padding: 40px 0 60px !important;
	margin: 0 !important;
	background: #fff !important;
	border: 0 !important;
	box-shadow: none !important;
}

/* ПК: сайдбар 305 + контент, gap 20 */
@media (min-width: 992px) {
	body.std-product-page #content > .row-fluid {
		display: flex !important;
		align-items: flex-start;
		gap: 20px;
		width: 100% !important;
		margin: 0 !important;
	}
	body.std-product-page #content #sidebar {
		display: block !important;
		float: none !important;
		width: 305px !important;
		max-width: 305px !important;
		flex: 0 0 305px;
		margin: 0 !important;
		padding: 0 !important;
	}
	body.std-product-page #content #middlecol,
	body.std-product-page #content #middlecol.sidebar_left,
	body.std-product-page #content #middlecol.sidebar_right {
		float: none !important;
		width: auto !important;
		max-width: none !important;
		flex: 1 1 0;
		min-width: 0;
		margin: 0 !important;
		padding: 0 !important;
		clear: none !important;
	}
	body.std-product-page #content #middlecol .inside,
	body.std-product-page #content #sidebar .inside {
		padding: 0 !important;
		margin: 0 !important;
	}
}

/* ——— Сайдбар «Категории» (Figma: заголовок 28px + список) ——— */
body.std-product-page #sidebar .sidebar_module {
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
}
body.std-product-page #sidebar .sidebar_module_heading,
body.std-product-page #sidebar .module-title,
body.std-product-page #sidebar h3 {
	margin: 0 0 30px !important;
	padding: 0 !important;
	background: transparent !important;
	border: 0 !important;
	font-family: Arial, Helvetica, sans-serif !important;
	font-size: 28px !important;
	font-weight: 700 !important;
	line-height: 1.2 !important;
	color: #1a1a1a !important;
}
body.std-product-page #sidebar .sidebar_module_heading span,
body.std-product-page #sidebar .module-title span {
	font: inherit !important;
	color: inherit !important;
}
body.std-product-page #sidebar .sidebar_module_content {
	padding: 0 !important;
	margin: 0 !important;
}

/* JoomShopping category menu: div.jshop_menu_level_* */
body.std-product-page #sidebar [class*="jshop_menu_level"] {
	margin: 0 !important;
	padding: 0 !important;
	border-bottom: 1px solid #d9d9d9;
	list-style: none;
	background: transparent !important;
}
body.std-product-page #sidebar [class*="jshop_menu_level"] > a {
	display: flex !important;
	flex-direction: row;
	justify-content: flex-start;
	align-items: center;
	gap: 10px;
	min-height: 60px;
	padding: 10px 15px !important;
	font-family: Arial, Helvetica, sans-serif !important;
	font-size: 16px !important;
	font-weight: 400 !important;
	line-height: 1.6 !important;
	color: #8a8a8a !important;
	text-align: left !important;
	text-decoration: none !important;
	background: transparent !important;
}
body.std-product-page #sidebar [class*="jshop_menu_level"] > a:hover {
	color: #1a1a1a !important;
}
body.std-product-page #sidebar [class*="jshop_menu_level"] img {
	order: -1; /* в DOM картинка после текста — ставим слева */
	width: 40px !important;
	height: 40px !important;
	max-width: 40px !important;
	object-fit: cover;
	border-radius: 4px;
	flex-shrink: 0;
	background: #f2f2f2;
	margin: 0 !important;
	float: none !important;
}
/* Только активный родительский раздел — серый фон как «Двери» */
body.std-product-page #sidebar .jshop_menu_level_0_a > a {
	min-height: 52px;
	font-weight: 700 !important;
	color: #707070 !important;
	background: #d9d9d9 !important;
}
body.std-product-page #sidebar .jshop_menu_level_0_a > a img {
	display: none !important;
}
body.std-product-page #sidebar .jshop_menu_level_1_a > a {
	color: #1a1a1a !important;
}
body.std-product-page #sidebar .jshop_menu_level_1 > a,
body.std-product-page #sidebar .jshop_menu_level_1_a > a,
body.std-product-page #sidebar .jshop_menu_level_2 > a,
body.std-product-page #sidebar .jshop_menu_level_2_a > a {
	padding-left: 15px !important;
	padding-right: 15px !important;
}
body.std-product-page #sidebar .jshop_menu_level_0_a {
	background: transparent !important;
}

.std-product {
	display: flex;
	flex-direction: column;
	gap: 40px;
	font-family: Arial, Helvetica, sans-serif;
	color: #1a1a1a;
	box-sizing: border-box;
}
.std-product *,
.std-product *::before,
.std-product *::after {
	box-sizing: border-box;
}
.std-product a { text-decoration: none; }
.std-product img { max-width: 100%; height: auto; }

.std-product__plugin-sink,
.std-product__badges,
.std-product .std-ef-badges,
.std-product .std-ef-badges-list,
.std-product img[src*="img_wishboxextrafieldvalues"] {
	display: none !important;
}

.std-product__crumbs {
	margin: 0;
	font-size: 16px;
	line-height: 1.6;
	color: #8a8a8a;
}
.std-product__crumbs a { color: #8a8a8a; }
.std-product__crumbs a:hover { color: #1a1a1a; }
.std-product__crumbs-sep { margin: 0 4px; color: #8a8a8a; }

.std-product__form {
	display: flex;
	flex-direction: column;
	gap: 40px;
	margin: 0;
}

.std-product__top {
	display: flex;
	gap: 20px;
	align-items: flex-start;
	margin: 0;
}
.std-product__gallery {
	width: 305px;
	flex-shrink: 0;
	display: flex;
	flex-direction: column;
	gap: 15px;
}
.std-product__stage {
	position: relative;
	width: 100%;
	height: 420px;
	border: 1px solid #d9d9d9;
	border-radius: 5px;
	overflow: hidden;
	display: flex;
	align-items: center;
	justify-content: center;
	background: #fff;
}
.std-product__stage .lightbox,
.std-product__main-link {
	/* display управляет JS/inline (showImage) — не форсируем !important */
	align-items: center;
	justify-content: center;
	width: 100%;
	height: 100%;
	margin: 0;
	padding: 10px;
	box-sizing: border-box;
}
.std-product__stage .lightbox.is-visible {
	display: flex !important;
}
.std-product__stage img {
	display: block;
	max-width: 100%;
	max-height: 100%;
	width: auto;
	height: auto;
	object-fit: contain;
	margin: 0 auto;
}
.std-product__stage .text_zoom { display: none !important; }
.std-product__counter {
	position: absolute;
	right: 14px;
	bottom: 14px;
	z-index: 2;
	padding: 5px 10px;
	border-radius: 20px;
	background: #f2f2f2;
	font-size: 16px;
	line-height: 1.6;
	color: #8a8a8a;
}
.std-product__thumbs-row {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 10px;
	width: 100%;
	height: auto;
}
.std-product__thumb {
	display: block;
	width: 100%;
	aspect-ratio: 1 / 1;
	height: auto;
	min-width: 0;
	padding: 0;
	margin: 0;
	border: 1px solid #d9d9d9;
	border-radius: 5px;
	overflow: hidden;
	background: #fff;
	cursor: pointer;
}
.std-product__thumb.is-active { border-color: #0088cc; }
.std-product__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.std-product__info {
	flex: 1 1 auto;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 20px;
}
.std-product__title-block {
	display: flex;
	flex-direction: column;
	gap: 5px;
}
.std-product__title {
	margin: 0;
	font-size: 28px;
	font-weight: 700;
	line-height: 1.2;
	color: #1a1a1a;
}
.std-product__code {
	margin: 0;
	font-size: 16px;
	line-height: 1.6;
	color: #8a8a8a;
}

.std-product__attrs {
	display: flex;
	flex-direction: column;
	gap: 20px;
}
.std-product__attr {
	display: flex;
	flex-direction: column;
	gap: 10px;
}
.std-product__attr-name {
	margin: 0;
	font-size: 16px;
	line-height: 1.6;
	font-weight: 400;
	color: #8a8a8a;
}
.std-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	align-items: flex-start;
}
.std-chip {
	display: inline-flex;
	align-items: center;
	margin: 0;
	padding: 10px 15px;
	border: 1px solid #d9d9d9;
	border-radius: 5px;
	background: #fff;
	cursor: pointer;
	font-size: 16px;
	line-height: 1.6;
	color: #1a1a1a;
	transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.std-chip__input {
	position: absolute;
	opacity: 0;
	pointer-events: none;
	width: 0;
	height: 0;
}
.std-chip__label {
	display: inline-flex;
	align-items: center;
	gap: 8px;
}
.std-chip__img {
	width: 24px;
	height: 24px;
	object-fit: contain;
}
.std-chip.is-active,
.std-chip:has(.std-chip__input:checked) {
	background: #1b8fc0;
	border-color: #1b8fc0;
	color: #fff;
}

.std-product__buy {
	border: 1px solid #d9d9d9;
	border-radius: 5px;
	padding: 20px;
	display: flex;
	flex-direction: column;
	gap: 15px;
	background: #fff;
	box-sizing: border-box;
	overflow: hidden;
}
.std-product__buy > * {
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}
.std-product__price,
.std-product__buy .prod_price.jshop_price {
	margin: 0 !important;
	padding: 0 !important;
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0 6px;
	background: transparent !important;
	border: 0 !important;
	color: inherit !important;
	font: inherit !important;
}
.std-product__price-value,
.std-product__buy #block_price {
	display: inline;
	margin: 0 !important;
	padding: 0 !important;
	font-family: Arial, Helvetica, sans-serif !important;
	font-size: 28px !important;
	font-weight: 700 !important;
	line-height: 1.2 !important;
	color: #1a1a1a !important;
}
.std-product__price-note {
	display: inline;
	margin: 0 !important;
	padding: 0 !important;
	font-family: Arial, Helvetica, sans-serif !important;
	font-size: 12px !important;
	font-weight: 400 !important;
	line-height: 1.2 !important;
	color: #8a8a8a !important;
}
.std-product__old-price {
	font-size: 16px;
	color: #8a8a8a;
	text-decoration: line-through;
}
.std-product__meta {
	display: flex;
	flex-direction: column;
	width: 100%;
	margin: 0;
	padding: 0;
}
.std-product__meta-row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	width: 100%;
	margin: 0;
	padding: 5px 0;
	box-sizing: border-box;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 16px;
	line-height: 1.6;
	border: 0;
}
.std-product__meta-row + .std-product__meta-row {
	border-top: 1px solid #d9d9d9;
}
.std-product__meta-label {
	color: #8a8a8a;
	flex: 0 1 auto;
}
.std-product__meta-value {
	color: #1a1a1a;
	text-align: right;
	font-weight: 400;
	flex: 0 1 auto;
}
.std-product__actions,
.std-product__buy .prod_buttons {
	display: flex !important;
	align-items: center;
	gap: 15px;
	width: 100%;
	margin: 0 !important;
	padding: 0 !important;
	background: transparent !important;
	border: 0 !important;
	box-shadow: none !important;
}
.std-product__qty {
	display: flex;
	align-items: center;
	width: 120px;
	height: 45px;
	border: 1px solid #d9d9d9;
	border-radius: 5px;
	overflow: hidden;
	background: #fff;
	flex-shrink: 0;
	box-sizing: border-box;
}
.std-product__qty-btn {
	width: 45px;
	height: 45px;
	padding: 0;
	border: 0;
	background: transparent;
	color: #0088cc;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}
.std-product__qty-btn img {
	display: block;
	width: 25px;
	height: 25px;
}
.std-product__qty-input,
.std-product__qty input.std-product__qty-input[type="text"],
.std-product__buy .prod_buttons input#quantity {
	flex: 1 1 auto;
	width: 30px !important;
	min-width: 0 !important;
	height: 45px !important;
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	box-shadow: none !important;
	text-align: center;
	font-family: Arial, Helvetica, sans-serif;
	font-size: 16px !important;
	font-weight: 700;
	line-height: 45px !important;
	color: #1a1a1a;
	background: transparent !important;
}
.std-product__cart-btn,
.std-product__buy .button_buy {
	flex: 1 1 auto;
	height: 45px;
	padding: 0 20px !important;
	border: 0 !important;
	border-radius: 5px;
	background: #0088cc !important;
	color: #fff !important;
	font-family: Arial, Helvetica, sans-serif !important;
	font-size: 18px !important;
	font-weight: 700 !important;
	line-height: 45px !important;
	cursor: pointer;
	box-shadow: none !important;
}
.std-product__cart-btn--in {
	background: #fff !important;
	color: #0088cc !important;
	border: 1px solid #0088cc !important;
}
.std-product__cart-btn--in:hover {
	background: #f2f8fc !important;
}
.std-product__actions.is-in-cart .std-product__cart-btn--add {
	display: none !important;
}
.std-product__actions:not(.is-in-cart) .std-product__cart-btn--in {
	display: none !important;
}
.std-product__cart-btn:hover,
.std-product__buy .button_buy:hover {
	background: #0077b5 !important;
}
.std-product__cart-btn--in:hover {
	background: #f2f8fc !important;
}
.std-product__buy .not_available:empty,
.std-product__buy .not_available[hidden],
.std-product__buy #jshop_image_loading,
.std-product__buy .button_wishlist[hidden] {
	display: none !important;
}
.std-product .not_available:empty { display: none; }

.std-product__about,
.std-product__materials,
.std-product__consult,
.std-product__related,
.std-product__arrivals {
	margin: 0;
}
.std-product__section-title {
	margin: 0 0 20px;
	font-size: 20px;
	font-weight: 700;
	line-height: 1.2;
	color: #1a1a1a;
}
.std-product__about-body {
	font-size: 16px;
	line-height: 2;
	color: #1a1a1a;
}
.std-product__field {
	margin: 0;
	line-height: 2;
}
.std-product__field strong,
.std-product__about-body strong {
	font-weight: 700;
}
.std-product__description p { margin: 0; line-height: 2; }
.std-product__description ul {
	margin: 0 0 0 1.4em;
	padding: 0;
}
.std-product__description li { line-height: 2; }

.std-product__materials {
	padding: 40px 0 0;
}
.std-product__materials .std-product__section-title {
	margin-bottom: 20px;
}
.std-product__materials-grid {
	display: flex;
	flex-wrap: wrap;
	column-gap: 20px;
	row-gap: 0;
}
.std-product__material {
	box-sizing: border-box;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	width: calc(50% - 10px);
	padding: 15px 0;
	border-top: 1px solid #f2f2f2;
	color: #1a1a1a;
	font-size: 16px;
	font-weight: 400;
	line-height: 1.6;
	text-decoration: none;
}
.std-product__material:nth-child(-n+2) { border-top: 0; }
.std-product__material span {
	flex: 1 1 auto;
	min-width: 0;
}
.std-product__material img {
	flex: 0 0 25px;
	width: 25px;
	height: 25px;
	display: block;
}
.std-product__material:hover { color: #0088cc; }

.std-product__consult-card {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 30px;
	padding: 30px;
	border-radius: 16px;
	background: #f2f2f2;
}
.std-product__consult-lead {
	display: flex;
	align-items: center;
	gap: 30px;
	min-width: 0;
}
.std-product__consult-ico {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	width: 70px;
	height: 70px;
	padding: 0;
	border-radius: 0;
	background: transparent;
}
.std-product__consult-ico img {
	display: block;
	width: 70px;
	height: 70px;
}
.std-product__consult-text {
	margin: 0;
	font-size: 16px;
	line-height: 1.6;
	color: #1a1a1a;
}
.std-product__consult-actions {
	display: flex;
	align-items: center;
	gap: 55px;
	flex-shrink: 0;
}
.std-product__consult-phone {
	font-size: 20px;
	font-weight: 700;
	line-height: 1.2;
	color: #1a1a1a !important;
	white-space: nowrap;
}
.std-product__consult-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 275px;
	height: 55px;
	padding: 0 20px;
	border-radius: 5px;
	background: #1b8fc0;
	color: #fff !important;
	font-size: 16px;
	font-weight: 700;
	line-height: 1.4;
	white-space: nowrap;
}
.std-product__consult-btn:hover { background: #1679a3; color: #fff !important; }

/* Carousel */
.std-carousel__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	margin-bottom: 20px;
}
.std-carousel__head .std-product__section-title { margin: 0; }
.std-carousel__arrows { display: flex; gap: 10px; }
.std-carousel__arrow {
	width: 45px;
	height: 45px;
	padding: 0;
	border: 1px solid #d9d9d9;
	border-radius: 25px;
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}
.std-carousel__arrow:hover { border-color: #0088cc; }
.std-carousel__viewport {
	overflow-x: auto;
	overflow-y: hidden;
	scroll-behavior: auto;
	scroll-snap-type: x mandatory;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
}
.std-carousel__viewport::-webkit-scrollbar { display: none; }
.std-carousel__track {
	display: flex;
	gap: 20px;
	width: max-content;
}
.std-carousel__slide {
	width: 305px;
	flex: 0 0 305px;
	scroll-snap-align: start;
	scroll-snap-stop: normal;
}
.std-carousel__slide .stdoors-product-card {
	width: 100%;
	height: 100%;
}
.std-carousel .stdoors-product-card__title {
	margin: 0 !important;
	min-height: 4.4em;
}
.std-carousel .stdoors-product-card__title a {
	display: -webkit-box;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 4;
	overflow: hidden;
	line-height: 1.4;
}
.std-carousel .stdoors-product-card__body {
	padding: 15px 10px 0 !important;
	gap: 10px;
}
.std-carousel .stdoors-product-card__price-value,
.std-carousel .stdoors-product-card__currency {
	font-size: 20px;
}
.std-carousel .stdoors-product-card__btn {
	min-height: 35px;
	padding: 8px 12px;
	font-size: 13px;
	border-radius: 5px;
}
.std-carousel .stdoors-product-card__btn--detail {
	border: 1px solid #d9d9d9;
}
.std-carousel__bar {
	margin-top: 16px;
	height: 5px;
	border-radius: 2px;
	background: #d9d9d9;
	overflow: hidden;
}
.std-carousel__bar-fill {
	display: block;
	height: 5px;
	border-radius: 2px;
	background: #0088cc;
	width: 40%;
}

/* Новые поступления — после консультации (как в макете ПК) */
body.std-product-page #jshopping_module_bottom {
	margin-top: 40px !important;
	overflow: visible !important;
	padding: 0 !important;
}
body.std-product-page #jshopping_module_bottom .moduletable {
	margin: 0 !important;
	padding: 0 !important;
	border: 0 !important;
	background: transparent !important;
	box-shadow: none !important;
	text-align: left !important;
	overflow: visible !important;
}
/* Заголовок уже внутри std-carousel__head */
body.std-product-page #jshopping_module_bottom .moduletable:has(.std-arrivals-carousel) > h3,
#jshopping_module_bottom .moduletable:has(.std-arrivals-carousel) > h3 {
	display: none !important;
}
body.std-product-page #jshopping_module_bottom .std-product__arrivals {
	padding: 40px 0 0;
}
body.std-product-page #jshopping_module_bottom .jshopping_product,
body.std-product-page #jshopping_module_bottom .stdoors-product-card {
	padding: 0 !important;
	margin: 0 !important;
	text-align: left !important;
}

.std-product .jshop_prod_attributes,
.std-product hr,
.std-product .jshop_price_text,
.std-product .ratingandhits,
.std-product .button_back {
	display: none !important;
}
.std-product table.jshop_prod_attributes { display: none !important; }

/* ——— Mobile (Figma 121:2) ——— */
@media (max-width: 991px) {
	body.std-product-page #content {
		padding: 25px 0 40px !important;
	}
	body.std-product-page #content #sidebar {
		display: none !important;
	}
	body.std-product-page #content #middlecol,
	body.std-product-page #content #middlecol.sidebar_left,
	body.std-product-page #content #middlecol.sidebar_right {
		width: 100% !important;
		float: none !important;
	}

	.std-product {
		gap: 0;
	}
	.std-product__form {
		gap: 0;
	}
	.std-product__crumbs {
		padding: 0 0 15px;
	}
	.std-product__top {
		flex-direction: column;
		gap: 0;
	}
	.std-product__gallery {
		width: 100%;
		gap: 10px;
		padding: 0 0 20px;
	}
	.std-product__stage {
		height: 320px;
		border-radius: 12px;
	}
	.std-product__counter {
		font-size: 12px;
	}
	.std-product__thumbs-row {
		height: auto;
		gap: 8px;
	}
	.std-product__thumb {
		height: auto;
		aspect-ratio: 1 / 1;
		border-radius: 12px;
	}
	.std-product__info {
		width: 100%;
		gap: 20px;
		padding: 20px 0 25px;
	}
	.std-product__title { font-size: 28px; }
	.std-product__buy { padding: 15px; }
	.std-product__price-note { font-size: 14px; }
	.std-product__about,
	.std-product__related,
	.std-product__arrivals,
	.std-product__materials,
	.std-product__consult {
		padding: 25px 0;
	}
	.std-product__materials-grid { flex-direction: column; gap: 0; }
	.std-product__material {
		width: 100%;
		border-top: 1px solid #f2f2f2;
	}
	.std-product__material:first-child { border-top: 0; }
	.std-product__consult-card {
		flex-direction: column;
		align-items: stretch;
		gap: 20px;
		padding: 20px 20px 25px;
		border-radius: 16px;
	}
	.std-product__consult-lead { gap: 10px; }
	.std-product__consult-actions {
		flex-direction: column;
		align-items: stretch;
		gap: 10px;
	}
	.std-product__consult-btn {
		width: 100%;
		min-width: 0;
		height: 50px;
	}
	.std-carousel__arrows { display: none; }
	.std-carousel__track { gap: 10px; }
	.std-carousel__slide {
		width: 168px;
		flex: 0 0 168px;
		scroll-snap-align: start;
	}
	body.std-product-page #jshopping_module_bottom {
		margin-top: 0 !important;
		padding: 25px 0;
	}
	body.std-product-page #jshopping_module_bottom .std-product__arrivals {
		padding: 25px 0 0;
	}
}

@media (max-width: 767px) {
	.std-product__actions { gap: 10px; }
	.std-product__cart-btn { font-size: 16px; }
}
