/**
 * Single product page — Figma №4
 */

.catalog-page--product .catalog-breadcrumbs {
	margin-bottom: 16px;
}

.product-single__title {
	margin: 0 0 18px;
	padding: 14px 16px;
	background: #ececec;
	font-size: 18px;
	font-weight: var(--font-weight-semibold);
	line-height: 1.35;
	color: var(--color-text);
}

.product-single__layout {
	display: grid;
	grid-template-columns: 1fr;
	gap: 24px;
	margin-bottom: 40px;
}

.product-single__main-image {
	aspect-ratio: 1;
	background: #e8e8e8;
	overflow: hidden;
}

.product-single__image {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.product-single__image--placeholder {
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 280px;
	color: var(--color-text-muted);
	font-size: 14px;
}

.product-single__thumbs {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: 10px;
	list-style: none;
	margin: 12px 0 0;
	padding: 0;
}

.product-single__thumb {
	display: block;
	width: 100%;
	aspect-ratio: 1;
	padding: 0;
	border: 1px solid transparent;
	background: #e8e8e8;
	overflow: hidden;
	cursor: pointer;
}

.product-single__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.product-single__thumb.is-active {
	border-color: var(--color-primary);
}

.product-single__thumb--empty {
	cursor: default;
	pointer-events: none;
}

.product-single__sku {
	margin: 0 0 10px;
	font-size: 13px;
	color: #9a9a9a;
}

.product-single__price {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 6px;
	margin: 0 0 18px;
	color: var(--color-primary);
	font-weight: var(--font-weight-bold);
	line-height: 1.2;
}

.product-single__price-prefix,
.product-single__price-suffix {
	font-size: 20px;
}

.product-single__price-amount {
	font-size: 28px;
	letter-spacing: -0.02em;
}

.product-single__price--request .product-single__price-request {
	font-size: 16px;
	color: var(--color-text-muted);
}

.product-single__buy {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 10px;
	margin-bottom: 22px;
}

.product-single__qty {
	display: inline-flex;
	align-items: center;
	height: 40px;
	border: 1px solid #d9d9d9;
	border-radius: 4px;
	background: #fff;
	overflow: hidden;
}

.product-single__qty-btn {
	width: 36px;
	height: 100%;
	border: none;
	background: #f5f5f5;
	color: var(--color-text);
	font-size: 18px;
	line-height: 1;
	cursor: pointer;
}

.product-single__qty-input {
	width: 56px;
	height: 100%;
	border: none;
	border-left: 1px solid #d9d9d9;
	border-right: 1px solid #d9d9d9;
	text-align: center;
	font-family: inherit;
	font-size: 15px;
	font-weight: var(--font-weight-semibold);
	color: var(--color-text);
	-moz-appearance: textfield;
}

.product-single__qty-input::-webkit-outer-spin-button,
.product-single__qty-input::-webkit-inner-spin-button {
	-webkit-appearance: none;
	margin: 0;
}

.product-single__btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 40px;
	padding: 0 18px;
	border: none;
	border-radius: 4px;
	background: var(--color-primary);
	color: var(--color-text-inverse);
	font-family: inherit;
	font-size: 14px;
	font-weight: var(--font-weight-semibold);
	text-decoration: none;
	cursor: pointer;
	white-space: nowrap;
}

.product-single__btn:hover {
	background: var(--color-primary-dark);
	color: var(--color-text-inverse);
}

.product-single__btn--request {
	min-width: 170px;
}

.product-single__icon-btn {
	width: 40px;
	height: 40px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	padding: 0;
	border: 1px solid #e0e0e0;
	border-radius: 4px;
	background: #fff;
	color: var(--color-primary);
	cursor: pointer;
}

.product-single__icon-btn.is-active svg {
	fill: currentColor;
}

.product-single__tabs {
	margin-top: 8px;
}

.product-single__tablist {
	display: flex;
	gap: 22px;
	border-bottom: 1px solid #e5e5e5;
	margin-bottom: 14px;
}

.product-single__tab {
	padding: 0 0 10px;
	border: none;
	border-bottom: 2px solid transparent;
	margin-bottom: -1px;
	background: transparent;
	font-family: inherit;
	font-size: 15px;
	font-weight: var(--font-weight-semibold);
	color: var(--color-text-muted);
	cursor: pointer;
}

.product-single__tab.is-active {
	color: var(--color-primary);
	border-bottom-color: var(--color-primary);
}

.product-single__tabpanel {
	font-size: 13px;
	line-height: 1.55;
	color: var(--color-text);
}

.product-single__tabpanel p {
	margin: 0 0 10px;
}

.product-related {
	margin-top: 12px;
	padding-top: 8px;
}

.product-related__title {
	margin: 0 0 18px;
	font-size: 22px;
	font-weight: var(--font-weight-bold);
	color: var(--color-text);
}

@media (min-width: 900px) {
	.product-single__layout {
		grid-template-columns: minmax(280px, 1.05fr) minmax(280px, 1fr);
		gap: 28px 32px;
		align-items: start;
	}
}

@media (min-width: 1024px) {
	.catalog-page--product .product-grid {
		grid-template-columns: repeat(4, 1fr);
	}
}
