/* בורר וריאציות חכם - כרטיס מוצר בארכיון */

.einav-picker {
	display: flex;
	flex-direction: column;
	gap: 6px;
}

/* ===== שכבת מידות על התמונה ===== */

.einav-sizes {
	position: absolute;
	inset-inline-start: 0;
	top: 50%;
	transform: translateY(-50%);
	display: flex;
	flex-direction: column;
	z-index: 3;
	opacity: 0;
	transition: opacity .18s ease;
	pointer-events: none;
}

/* מציגים בריחוף במחשב, תמיד בנייד */
.einav-card:hover .einav-sizes,
.einav-card:focus-within .einav-sizes {
	opacity: 1;
	pointer-events: auto;
}

.einav-size {
	display: block;
	min-width: 38px;
	padding: 7px 10px;
	background: rgba(255, 255, 255, .92);
	color: #1C244B;
	font-size: 13px;
	line-height: 1;
	text-align: center;
	text-decoration: none;
	border-bottom: 1px solid rgba(0, 0, 0, .07);
	transition: background .15s ease;
}

.einav-size:last-child {
	border-bottom: 0;
}

.einav-size:hover,
.einav-size:focus-visible {
	background: #1C244B;
	color: #fff;
}

.einav-size.is-out {
	color: rgba(28, 36, 75, .38);
	text-decoration: line-through;
}

.einav-size.is-out:hover {
	background: rgba(255, 255, 255, .92);
	color: rgba(28, 36, 75, .38);
}

/* מצבי הוספה מהירה */
.einav-size.is-loading {
	opacity: .5;
	pointer-events: none;
}

.einav-size.is-added {
	background: #1F7A5A;
	color: #fff;
}

.einav-size.is-added::after {
	content: " ✓";
}

/* ===== צ'יפי תמונה ===== */

.einav-swatches {
	position: static;
	display: flex;
	flex-wrap: wrap;
	gap: 5px;
	margin-top: 4px;
}

.einav-swatch {
	display: block;
	width: 26px;
	height: 26px;
	overflow: hidden;
	border: 1px solid rgba(0, 0, 0, .12);
	border-radius: 50%;
	line-height: 0;
	transition: border-color .15s ease;
}

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

.einav-swatch.is-active,
.einav-swatch:hover,
.einav-swatch:focus-visible {
	border-color: #1C244B;
}

.einav-swatch.is-out {
	opacity: .45;
}

/* ===== יחס תמונה קבוע לכרטיס ===== */

.einav-card .einav-media,
.einav-card .einav-media.e-con {
	position: relative !important;
}

.einav-card .einav-media > .elementor-widget-shortcode {
	position: static;
	width: 0;
	height: 0;
	margin: 0;
	padding: 0;
}

.einav-card .einav-media img {
	aspect-ratio: 2 / 3;
	width: 100%;
	height: auto;
	object-fit: cover;
	object-position: center top;
	display: block;
}

/* ===== נייד ===== */

@media (max-width: 767px) {
	.einav-sizes {
		opacity: 1;
		pointer-events: auto;
	}

	.einav-size {
		min-width: 30px;
		padding: 5px 7px;
		font-size: 11px;
	}

	.einav-swatch {
		width: 22px;
		height: 22px;
	}

	.einav-swatches {
		gap: 4px;
		margin-top: 3px;
	}
}

/* ===== ריבונים על כרטיס המוצר ===== */

.einav-badges {
	position: absolute;
	top: 8px;
	inset-inline-start: 8px;
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 5px;
	z-index: 4;
	pointer-events: none;
}

.einav-badge {
	display: inline-block;
	padding: 4px 10px;
	border-radius: 2px;
	font-size: 11px;
	font-weight: 500;
	line-height: 1.45;
	letter-spacing: .01em;
	color: #fff;
	white-space: nowrap;
}

.einav-badge--navy  { background: #1C244B; }
.einav-badge--pink  { background: #D4537E; }
.einav-badge--black { background: #14141A; }
.einav-badge--sale  { background: #A32D2D; }
.einav-badge--muted {
	background: rgba(255, 255, 255, .94);
	color: #1C244B;
	border: 1px solid rgba(28, 36, 75, .14);
}

@media (max-width: 767px) {
	.einav-badges {
		top: 6px;
		inset-inline-start: 6px;
		gap: 4px;
	}

	.einav-badge {
		padding: 3px 8px;
		font-size: 10px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.einav-sizes,
	.einav-size,
	.einav-swatch {
		transition: none;
	}
}

/* ===== הגנה: סמל הנגישות נשאר צמוד למסך =====
   רכיבי ממשק צפים חייבים להיות מעוגנים לחלון ולא לאלמנט
   כלשהו בעמוד, אחרת הם זזים ממקומם. */

body > .ea11y-widget,
body > [class*="ea11y-widget"],
#ea11y-widget,
.ea11y-widget__toggle-button {
	position: fixed !important;
	z-index: 99999;
}
