/* =========================================================
 *  הנחה סיטונאית – עיצוב צד לקוח
 *  הצבעים מוגדרים כמשתנים כדי שיהיה קל לשנות
 * ========================================================= */
.wsd-box {
	--wsd-blue: #3d5afe;
	--wsd-blue-dark: #3146d6;
	--wsd-yellow: #f5c33b;
	--wsd-yellow-dark: #eab92e;
	--wsd-body-bg: #eef1fc;
	--wsd-text: #2b3046;
	--wsd-muted: #8b93a8;

	direction: rtl;
	text-align: right;
	max-width: 100%;
	margin: 22px 0;
	border: 1px solid #e3e7f2;
	border-radius: 14px;
	overflow: hidden;
	box-shadow: 0 2px 12px rgba(40, 60, 120, .07);
	font-family: inherit;
	background: #fff;
}

/* ---- כותרת ---- */
.wsd-box .wsd-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 13px 18px !important;
	background: var(--wsd-blue);
	color: #fff;
	cursor: pointer;
	user-select: none;
}

.wsd-box .wsd-header-main {
	display: flex;
	align-items: center;
	gap: 10px;
}
.wsd-box .wsd-badge,
.wsd-box .wsd-chevron {
	display: inline-flex;
	align-items: center;
}
.wsd-box .wsd-badge .wsd-logo {
	display: block;
	height: 26px;
	width: auto;
}
.wsd-box .wsd-title {
	font-size: 18px;
	font-weight: 700;
	line-height: 1;
}
.wsd-box .wsd-chevron {
	transition: transform .25s ease;
	margin-left: 10px !important;
}

/* מצב מכווץ */
.wsd-box.wsd-collapsed .wsd-body { display: none; }
.wsd-box.wsd-collapsed .wsd-chevron { transform: rotate(-90deg); }

/* ---- גוף ---- */
.wsd-box .wsd-body {
	background: var(--wsd-body-bg);
	padding: 18px 20px 20px;
}
.wsd-box .wsd-subtitle {
	margin: 0 0 16px;
	color: var(--wsd-muted);
	font-size: 15px;
	line-height: 1.5;
}

/* ---- בוחרי וריאציה ---- */
.wsd-box .wsd-variations {
	display: flex;
	flex-wrap: wrap;
	gap: 10px;
	margin: 0 0 14px;
}
.wsd-box .wsd-variation {
	flex: 1 1 160px;
	min-width: 140px;
	padding: 9px 12px;
	padding-left: 46px !important;
	border: 1px solid #cdd4e6;
	border-radius: 7px;
	-webkit-appearance: none !important;
	-moz-appearance: none !important;
	appearance: none !important;
	background-color: #fff;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%238b93a8' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") !important;
	background-repeat: no-repeat !important;
	background-position: left 22px center !important;
	background-size: 12px 8px !important;
	color: var(--wsd-text);
	font-size: 15px;
	font-family: inherit;
	cursor: pointer;
}
.wsd-box .wsd-variation.wsd-variation-missing {
	border-color: #e05a5a;
	box-shadow: 0 0 0 2px rgba(224, 90, 90, .15);
}
.wsd-box .wsd-variation-note {
	display: none;
	margin: -6px 0 14px;
	color: #c0392b;
	font-size: 13px;
	font-weight: 600;
}
.wsd-box.wsd-show-note .wsd-variation-note {
	display: block;
}

/* ---- שורת מדרגה ---- */
.wsd-box .wsd-tier {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 27px;
	padding: 9px 0;
	flex-direction: row-reverse;
}
.wsd-box .wsd-tier + .wsd-tier {
	border-top: 1px solid rgba(40, 60, 120, .08);
}
.wsd-box .wsd-tier-text {
	flex: 0 1 auto;
	color: var(--wsd-text);
	font-size: 16px;
	font-weight: 600;
}
.wsd-box .wsd-tier-text .woocommerce-Price-amount {
	font-weight: 700;
	white-space: nowrap;
}

/* ---- קישור "מעבר לעמוד תשלום" שווקומרס מוסיף אחרי ההוספה לסל ---- */
/* מבטל את padding-top: 0.5em שמגיע מהחוק .woocommerce a.added_to_cart */
.woocommerce .wsd-box a.added_to_cart,
.wsd-box a.added_to_cart {
	padding-top: 0 !important;
}
body .wsd-box .wsd-tier a.added_to_cart,
.elementor .wsd-box .wsd-tier a.added_to_cart,
.woocommerce .wsd-box .wsd-tier a.added_to_cart.wc-forward,
.wsd-box .wsd-tier .added_to_cart {
	display: inline-flex !important;
	align-items: center !important;
	align-self: center !important;
	margin: 0 !important;
	padding: 0 !important;
	background: none !important;
	border: none !important;
	box-shadow: none !important;
	height: auto !important;
	min-height: 0 !important;
	color: #2b3046 !important;
	font-size: 16px !important;
	font-weight: 600 !important;
	line-height: 1.4 !important;
	text-decoration: underline;
}
body .wsd-box .wsd-tier a.added_to_cart:hover,
.elementor .wsd-box .wsd-tier a.added_to_cart:hover,
.wsd-box .wsd-tier .added_to_cart:hover {
	color: #1b1f30 !important;
}

/* ---- כפתור הוספה לסל ---- */
body .wsd-box button.wsd-add-btn,
.elementor .wsd-box button.wsd-add-btn,
.wsd-box .wsd-add-btn {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	padding: 10px 18px;
	background: var(--wsd-yellow) !important;
	color: #3a3000 !important;
	border: none !important;
	border-radius: 7px !important;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	white-space: nowrap;
	transition: background .15s ease, transform .05s ease;
}

/* רדיוס גם לכפתור הוספה לסל הרגיל של WooCommerce בעמוד מוצר */
.woocommerce div.product form.cart .single_add_to_cart_button,
.woocommerce div.product form.cart button.single_add_to_cart_button,
form.cart .single_add_to_cart_button {
	border-radius: 7px !important;
}
.wsd-box .wsd-add-btn:hover { background: var(--wsd-yellow-dark) !important; }
.wsd-box .wsd-add-btn:active {
	transform: scale(.97);
	background: #3d5afe !important;
	color: #fff;
}
.wsd-box .wsd-add-btn.wsd-loading {
	opacity: 1;
	cursor: default;
	background: #3d5afe !important;
	color: #fff;
}
.wsd-box .wsd-add-btn svg { flex-shrink: 0; }

/* ---- מובייל ---- */
@media (max-width: 480px) {
	.wsd-box .wsd-tier {
		flex-direction: column;
		align-items: stretch;
		gap: 10px;
	}
	.wsd-box .wsd-add-btn { justify-content: center; }
}

/* כשיש בעמוד טופס וריאציות של WooCommerce – התיבה עוקבת אחרי הבחירה שם
   ואין צורך בבוחרי וריאציה כפולים בתוך התיבה. */
.wsd-box.wsd-follow-form .wsd-variations {
	display: none !important;
}
