/**
 * Optional Product Integration Section Styles
 *
 * @package Eryvium
 * @since Eryvium 1.0.0
 */

/* ============================================
   SECTION
   ============================================ */

.optional-product-integration-section {
	position: relative;
	padding: clamp(80px, 12vw, 160px) 0;
	background: linear-gradient(180deg, #FFFFFF 0%, #CCE3FB 100%);
}

.optional-product-integration-container {
	width: 100%;
	max-width: 1300px;
	margin: 0 auto;
	padding: 0 var(--container-padding);
}

.optional-product-integration-title {
	text-align: center;
	margin-bottom: 16px;
}

.optional-product-integration-subtitle {
	font-family: var(--font-body);
	font-size: 16px;
	font-weight: 400;
	line-height: 24px;
	color: var(--color-text);
	text-align: center;
	margin-bottom: clamp(40px, 6vw, 80px);
}

/* ============================================
   CARDS
   ============================================ */

.optional-product-integration-cards {
	--stack-cards-gap: 32px;
	width: 100%;
	display: flex;
	flex-direction: column;
	gap: 140px; /* Большой gap для скролла */
	align-items: center;
	list-style: none;
	padding: 0;
	margin: 0;
}

/* Card Item - Sticky */
.optional-product-card {
	position: sticky;
	top: 150px;
	height: 514px;
	transform-origin: center top;
	overflow: hidden;
	width: 100%;
	max-width: 1300px;
	border-radius: var(--border-radius-lg);
	will-change: transform, opacity;
	transition: opacity 0.2s ease-out;
	opacity: 1;
}

/* Inner content absolute positioning */
.optional-product-card > * {
	position: absolute;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
}

.optional-product-card__inner {
	display: flex;
	width: 100%;
	height: 514px;
	border-radius: var(--border-radius-lg);
	overflow: hidden;
	box-shadow: var(--shadow-lg);
}

.optional-product-card__left {
	width: 388px;
	background-color: var(--color-true-black);
	color: var(--color-pure-white);
	padding: 44px;
	display: flex;
	flex-direction: column;
	gap: 24px;
	flex-shrink: 0;
}

.optional-product-card__right {
	width: 912px;
	background-color: var(--color-pure-white);
	color: var(--color-text);
	padding: 44px;
	display: flex;
	flex-direction: column;
	gap: 32px;
	flex: 1;
}

/* ============================================
   LEFT BLOCK (BLACK)
   ============================================ */

.optional-product-card__code-block {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-bottom: 24px;
}

.optional-product-card__code-label {
	font-family: var(--font-body);
	font-size: 12px;
	font-weight: 400;
	line-height: 1.4;
	color: rgba(255, 255, 255, 0.6);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin: 0;
}

.optional-product-card__code {
	font-family: var(--font-heading);
	font-size: 24px;
	font-weight: 500;
	line-height: 36px;
	color: var(--color-sky-pulse);
	margin: 0;
}

.optional-product-card__name-block {
	display: flex;
	flex-direction: column;
	gap: 8px;
	margin-bottom: 24px;
}

.optional-product-card__name {
	font-family: var(--font-heading);
	font-size: 24px;
	font-weight: 500;
	line-height: 36px;
	color: var(--color-pure-white);
	margin: 0;
}

.optional-product-card__description {
	font-family: var(--font-body);
	font-size: 16px;
	font-weight: 400;
	line-height: 24px;
	color: rgba(255, 255, 255, 0.8);
	margin: 0;
}

.optional-product-card__specifications {
	display: flex;
	flex-direction: column;
	gap: 16px;
	margin-top: auto;
}

.optional-product-card__specifications-title {
	font-family: var(--font-body);
	font-size: 12px;
	font-weight: 400;
	line-height: 1.4;
	color: rgba(255, 255, 255, 0.6);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin-bottom: 8px;
}

.optional-product-card__specifications-list {
	display: flex;
	flex-direction: column;
	gap: 0;
}

.optional-product-card__spec-item {
	display: flex;
	justify-content: space-between;
	align-items: flex-start;
	gap: 16px;
	padding: 14px 0;
	position: relative;
}

.optional-product-card__spec-item:not(:last-child)::after {
	content: '';
	position: absolute;
	bottom: 0;
	left: 0;
	right: 0;
	height: 1px;
	background-color: rgba(255, 255, 255, 0.2);
}

.optional-product-card__spec-label {
	font-family: var(--font-body);
	font-size: 16px;
	font-weight: 400;
	line-height: 24px;
	color: rgba(255, 255, 255, 0.8);
}

.optional-product-card__spec-value {
	font-family: var(--font-body);
	font-size: 16px;
	font-weight: 400;
	line-height: 24px;
	color: var(--color-pure-white);
	text-align: right;
}

/* ============================================
   RIGHT BLOCK (WHITE)
   ============================================ */

.optional-product-card__applications {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.optional-product-card__applications-title {
	font-family: var(--font-body);
	font-size: 12px;
	font-weight: 400;
	line-height: 1.4;
	color: var(--color-text);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin-bottom: 8px;
}

.optional-product-card__applications-chips {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
}

.optional-product-card__chip {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 8px 14px;
	background-color: #E8F4FD;
	border-radius: 50px;
}

.optional-product-card__chip-icon {
	width: 20px;
	height: 20px;
	flex-shrink: 0;
	display: flex;
	align-items: center;
	justify-content: center;
}

.optional-product-card__chip-icon img {
	width: 100%;
	height: 100%;
	object-fit: contain;
}

.optional-product-card__chip-text {
	font-family: var(--font-body);
	font-size: 14px;
	font-weight: 400;
	line-height: 1.5;
	color: var(--color-text);
}

.optional-product-card__product-forms {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.optional-product-card__product-forms-title {
	font-family: var(--font-body);
	font-size: 12px;
	font-weight: 400;
	line-height: 1.4;
	color: var(--color-text);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin-bottom: 8px;
}

.optional-product-card__product-forms-text {
	font-family: var(--font-body);
	font-size: 16px;
	font-weight: 400;
	line-height: 24px;
	color: var(--color-text);
	margin: 0;
}

.optional-product-card__platform-integration {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.optional-product-card__platform-integration-title {
	font-family: var(--font-body);
	font-size: 12px;
	font-weight: 400;
	line-height: 1.4;
	color: var(--color-text);
	text-transform: uppercase;
	letter-spacing: 0.5px;
	margin-bottom: 8px;
}

.optional-product-card__platform-integration-text {
	font-family: var(--font-body);
	font-size: 16px;
	font-weight: 400;
	line-height: 24px;
	color: var(--color-text);
	margin: 0;
}

.optional-product-card__link {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-family: var(--font-body);
	font-size: 16px;
	font-weight: 500;
	line-height: 1.5;
	color: var(--color-sky-pulse);
	text-decoration: none;
	transition: color 0.3s ease;
}

.optional-product-card__link:hover {
	color: var(--color-sky-pulse);
	opacity: 0.8;
}

.optional-product-card__link svg {
	flex-shrink: 0;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 1024px) {
	.optional-product-integration-container {
		width: 100%;
		max-width: 1300px;
		margin: 0 auto;
		padding: 0;
		max-width: var(--container-max-width);
	}
	
	.optional-product-card__left {
		width: 40%;
	}
}

@media (max-width: 1200px) {
	.optional-product-card {
		flex-direction: column;
	}
	
	.optional-product-card__left {
		width: 40%;
	}
	
	.optional-product-card__right {
		width: 100%;
	}
}

@media (max-width: 768px) {
	.optional-product-integration-section {
		padding: clamp(60px, 10vw, 120px) 0;
	}
	
	.optional-product-integration-cards {
		display: flex;
		flex-direction: column;
		gap: 32px;
	}
	
	.optional-product-card {
		position: relative;
		top: auto;
		height: auto;
		will-change: auto;
		opacity: 1;
	}
	
	.optional-product-card > * {
		position: relative;
		top: auto;
		left: auto;
		width: 100%;
		height: auto;
	}
	
	.optional-product-card__inner {
		position: relative;
		height: auto;
		flex-direction: column;
	}
	
	.optional-product-card__left {
		width: 100%;
		padding: 24px;
	}
	
	.optional-product-card__right {
		width: 100%;
		padding: 24px;
	}
	
	.optional-product-card__code {
		font-size: 36px;
	}
	
	.optional-product-card__name {
		font-size: 24px;
	}
	
	.optional-product-card__applications-chips {
		flex-direction: column;
	}
}

@media (max-width: 320px) {
	.optional-product-integration-section {
		padding: 60px 16px;
	}
}
