/* Amphorae – עמוד סל קניות לפי פיגמה (244:1349 דסקטופ, 248:2133 מובייל) */

.amph-cart {
	--amph-green: var(--amph-primary, #566B30);
	--amph-gold: var(--amph-accent, #CAAF6E);
	--amph-border: #AFAFAF;
	--amph-border-light: #C1C1C1;
	--amph-line-strong: rgba(0, 0, 0, .8);
	--amph-line-soft: rgba(0, 0, 0, .18);
	--amph-fs-body: clamp(13px, .9vw, 17px);
	--amph-fs-title: clamp(19px, 1.3vw, 25px);
	--amph-fs-small: clamp(12px, .73vw, 14px);
	--amph-sticky-top: 100px;

	direction: rtl;
	font-family: 'Assistant', sans-serif;
	color: #000;
	max-width: 1704px;
	margin: 0 auto;
	padding: clamp(16px, 2.5vw, 40px) clamp(16px, 2vw, 32px) clamp(40px, 4vw, 80px);
}

.amph-cart__form {
	display: flex;
	align-items: flex-start;
	gap: clamp(24px, 3vw, 56px);
}

.amph-cart__main {
	flex: 1 1 auto;
	min-width: 0;
	border-inline-end: 1px solid var(--amph-line-soft);
	padding-inline-end: clamp(20px, 2.7vw, 52px);
}

.amph-cart h1.amph-cart__title {
	font-size: var(--amph-fs-title);
	font-weight: 600;
	margin: 0 0 clamp(20px, 2vw, 36px);
	line-height: 1.2;
	color: #000;
}

/* כפתור עדכון הסל הנסתר — display:block גלובלי של אלמנטור דורס את מאפיין hidden */
.amph-cart button.amph-cart__update { display: none !important; }

/* ---- גריד משותף לכותרות ולשורות ----
   עמודות גמישות: העמוד יושב בקונטיינר אלמנטור (1300px) והרוחב לטבלה מוגבל */
.amph-cart__grid {
	display: grid;
	grid-template-columns: minmax(180px, 1fr) minmax(52px, 86px) minmax(44px, 76px) 100px minmax(60px, 96px) 32px;
	gap: clamp(6px, .7vw, 16px);
	align-items: center;
}

.amph-cart__head {
	font-size: var(--amph-fs-body);
	font-weight: 700;
	padding-bottom: 14px;
	border-bottom: 2px solid var(--amph-line-strong);
}

.amph-cart__head .amph-col--price,
.amph-cart__head .amph-col--discount,
.amph-cart__head .amph-col--qty {
	text-align: center;
}

/* ---- שורות מוצרים ---- */
.amph-cart__items {
	border-bottom: 2px solid var(--amph-line-strong);
	overflow-x: hidden;
}

.amph-cart--scroll .amph-cart__items {
	max-height: clamp(240px, 19vw, 330px);
	overflow-y: auto;
	scrollbar-width: thin;
	scrollbar-color: var(--amph-gold) #D5D5D5;
}
.amph-cart--scroll .amph-cart__items::-webkit-scrollbar { width: 8px; }
.amph-cart--scroll .amph-cart__items::-webkit-scrollbar-track { background: #D5D5D5; border-radius: 50px; }
.amph-cart--scroll .amph-cart__items::-webkit-scrollbar-thumb { background: var(--amph-gold); border-radius: 50px; }

.amph-cart__item {
	padding: clamp(16px, 1.5vw, 28px) 0;
	font-size: var(--amph-fs-body);
}
.amph-cart__item + .amph-cart__item { border-top: 1px solid var(--amph-line-soft); }

.amph-col--product {
	display: flex;
	align-items: center;
	gap: clamp(12px, 1.5vw, 28px);
	min-width: 0;
}

.amph-item__image { flex: 0 0 clamp(76px, 5.8vw, 110px); }
/* !important — ה-CSS של ווקומרס (img{height:auto}) נטען אחרינו ומבטל את הריבוע */
.amph-cart .amph-item__image img {
	width: clamp(76px, 5.8vw, 110px) !important;
	height: clamp(76px, 5.8vw, 110px) !important;
	object-fit: contain !important;
	mix-blend-mode: multiply; /* מעלים את הרקע הלבן של תמונות הבקבוקים */
	display: block;
}

.amph-item__name {
	line-height: 1.3;
	min-width: 0;
	overflow-wrap: break-word;
}
.amph-item__name a {
	color: #000;
	text-decoration: none;
	font-weight: 700;
	font-size: clamp(13px, .85vw, 16px);
}
.amph-item__name a:hover { color: var(--amph-green); }
.amph-item__name .variation { font-size: var(--amph-fs-small); font-weight: 300; margin: 4px 0 0; }

.amph-col--price, .amph-col--discount { text-align: center; }
.amph-col--subtotal { text-align: right; }
.amph-col--subtotal strong { font-weight: 700; }
.amph-dash { color: #000; }

/* כפתורי כמות */
.amph-qty {
	border-radius: var(--amph-radius, 0);
	overflow: hidden;
	display: flex;
	align-items: stretch;
	border: 1px solid rgba(0, 0, 0, .55);
	background: #F9F9F9;
	width: 96px;
	height: 28px;
	margin: 0 auto;
}
/* !important — הסגנון הגלובלי של אלמנטור (elementor-kit) צובע כל button */
.amph-cart button.amph-qty__btn {
	flex: 0 0 28px;
	width: 28px;
	min-width: 28px;
	background-color: #E8E8E8 !important;
	border: 0 !important;
	border-radius: var(--amph-radius, 0) !important;
	box-shadow: none !important;
	cursor: pointer;
	font-size: 16px !important;
	font-weight: 300 !important;
	line-height: 1 !important;
	color: #000 !important;
	padding: 0 !important;
	font-family: inherit;
}
.amph-cart button.amph-qty__btn:hover { background-color: #dcdcdc !important; }
/* !important — סגנונות שדות הקלט של אלמנטור מוסיפים padding וגובה שמועכים את הספרה */
.amph-cart .amph-qty__input {
	flex: 1 1 auto;
	width: 100%;
	min-width: 0;
	height: 100% !important;
	min-height: 0 !important;
	border: 0 !important;
	border-radius: var(--amph-radius, 0) !important;
	background: transparent !important;
	box-shadow: none !important;
	text-align: center;
	font-family: inherit;
	font-size: 13px !important;
	font-weight: 300;
	line-height: 1 !important;
	padding: 0 !important;
	margin: 0 !important;
	-moz-appearance: textfield;
	appearance: textfield;
}
.amph-qty__input::-webkit-outer-spin-button,
.amph-qty__input::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.amph-item__remove { display: inline-block; padding: 6px; }
.amph-item__remove img { display: block; opacity: .8; }
.amph-item__remove:hover img { opacity: 1; }

.amph-cart__continue {
	display: block;
	text-align: left;
	margin: clamp(16px, 1.6vw, 30px) 0 0;
	color: #000;
	font-size: var(--amph-fs-body);
	text-decoration: underline;
	text-underline-offset: 4px;
}
.amph-cart__continue:hover { color: var(--amph-green); }

/* ---- יינות נוספים ---- */
.amph-upsells { margin-top: clamp(28px, 3vw, 56px); }
.amph-cart h2.amph-upsells__title {
	font-size: var(--amph-fs-title);
	font-weight: 600;
	margin: 0 0 clamp(18px, 2vw, 38px);
	color: #000;
}
.amph-upsells__grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	gap: clamp(14px, 1.8vw, 34px);
	max-width: 820px;
}
/* קלף בגובה אחיד: השם מתמתח, כפתור ההוספה תמיד באותו קו */
.amph-upsell {
	min-width: 0;
	text-align: right;
	display: flex;
	flex-direction: column;
}
.amph-upsell__image { display: block; background: transparent; aspect-ratio: 1 / 1; border-radius: var(--amph-radius, 0); overflow: hidden; }
.amph-cart .amph-upsell__image img {
	width: 100% !important;
	height: 100% !important;
	object-fit: contain !important;
	mix-blend-mode: multiply;
	display: block;
}
.amph-upsell__name {
	margin: 10px 0 0;
	font-size: clamp(13px, .9vw, 16px); /* באותו סדר גודל של המחיר */
	line-height: 1.3;
	min-height: 2.6em;
	text-align: center;
	flex: 1 1 auto; /* דוחף את המחיר והכפתור לתחתית הקלף */
}
.amph-upsell__name a { color: #000; text-decoration: none; }
.amph-upsell__name strong { display: block; font-weight: 700; }
.amph-upsell__name span { display: block; font-weight: 300; font-size: .8em; }
.amph-upsell__price {
	margin: 8px 0 0;
	text-align: center;
	font-size: var(--amph-fs-body);
	font-weight: 600;
}
.amph-upsell__price del { opacity: .55; margin-inline-end: 6px; }
.amph-upsell__price ins { text-decoration: none; }
/* !important — צבע הלינקים של התבנית דורס את צבע הטקסט בכפתור */
.amph-cart a.amph-upsell__btn {
	border-radius: var(--amph-radius, 0);
	display: block;
	margin-top: 10px;
	border: 1px solid #000;
	text-align: center;
	padding: 6px 4px;
	color: #000 !important;
	font-size: clamp(12px, .73vw, 14px);
	font-weight: 300;
	text-decoration: none !important;
	transition: background .2s ease, color .2s ease;
}
.amph-cart a.amph-upsell__btn:hover,
.amph-cart a.amph-upsell__btn:focus {
	background: #000;
	color: #fff !important;
}

/* ---- סיידבר: פירוט סל הקניות ---- */
.amph-cart__sidebar {
	flex: 0 0 clamp(280px, 21.5vw, 400px);
	position: sticky;
	top: var(--amph-sticky-top);
}

.amph-cart h2.amph-sidebar__title {
	font-size: clamp(14px, .9vw, 17px);
	font-weight: 700;
	margin: 0 0 14px;
	padding-bottom: 14px;
	border-bottom: 2px solid var(--amph-line-strong);
	color: #000;
}

.amph-sidebar__row {
	display: flex;
	justify-content: space-between;
	align-items: baseline;
	font-size: var(--amph-fs-body);
	padding: 10px 0;
	border-bottom: 1px solid var(--amph-line-soft);
}
.amph-sidebar__row--total span:last-child { font-weight: 700; }
.amph-sidebar__row--fee.is-discount span:last-child { color: var(--amph-primary, #566B30); font-weight: 600; }

.amph-sidebar__required {
	margin: 14px 0 10px;
	font-size: var(--amph-fs-small);
}

.amph-shipping-toggle {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 8px;
}
.amph-cart button.amph-shipping-toggle__btn {
	height: clamp(42px, 2.8vw, 54px);
	border: 1px solid var(--amph-border-light) !important;
	border-radius: var(--amph-radius, 0) !important;
	box-shadow: none !important;
	background-color: transparent !important;
	font-family: inherit;
	font-size: var(--amph-fs-body) !important;
	color: #000 !important;
	padding: 0 !important;
	cursor: pointer;
	transition: background .15s ease, border-color .15s ease;
}
.amph-cart button.amph-shipping-toggle__btn:hover { border-color: #000 !important; }
.amph-cart button.amph-shipping-toggle__btn.is-active {
	background-color: #DEDEDE !important;
	border-color: #000 !important;
}

.amph-sidebar__checkout {
	border-radius: var(--amph-radius, 0);
	display: block;
	margin-top: clamp(14px, 1vw, 20px);
	background: var(--amph-green);
	color: var(--amph-btn-text, #fff) !important;
	text-align: center;
	font-size: var(--amph-fs-body);
	line-height: clamp(42px, 2.8vw, 54px);
	text-decoration: none !important;
	transition: background .2s ease;
}
.amph-sidebar__checkout:hover { filter: brightness(.85); }

/* ---- קופון ---- */
.amph-coupon { margin-top: clamp(18px, 1.5vw, 30px); }
.amph-coupon__label {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 8px;
	font-size: var(--amph-fs-body);
	font-weight: 700;
	margin: 0 0 12px;
	padding-bottom: 12px;
	border-bottom: 1px solid var(--amph-line-soft);
}
.amph-cart .amph-coupon__input,
.amph-cart button.amph-coupon__apply {
	display: block;
	width: 100% !important;
	height: clamp(42px, 2.8vw, 54px);
	border: 1px solid var(--amph-border) !important;
	border-radius: var(--amph-radius, 0) !important;
	box-shadow: none !important;
	font-family: inherit;
	font-size: var(--amph-fs-body) !important;
	padding: 0 16px !important;
	text-align: center;
}
.amph-cart .amph-coupon__input { background: #FBFBFB; margin-bottom: 13px; }
.amph-cart .amph-coupon__input::placeholder { color: var(--amph-border); }
.amph-cart button.amph-coupon__apply {
	background-color: #EDEDED !important;
	color: #6f6f6f !important;
	cursor: pointer;
	transition: background .15s ease, color .15s ease;
}
.amph-cart button.amph-coupon__apply:hover { background-color: #e2e2e2 !important; color: #000 !important; }

.amph-coupon__applied {
	display: flex;
	justify-content: space-between;
	font-size: var(--amph-fs-small);
	margin: 10px 0 0;
}
.amph-coupon__applied a { color: var(--amph-green); }

/* !important — ‎.woocommerce img ו-.elementor img (max-width:100%) ספציפיים יותר */
.amph-cart img.amph-sidebar__payments {
	display: block;
	width: 100%;
	max-width: 60% !important;
	height: auto;
	margin-top: clamp(16px, 1.6vw, 24px);
	margin-inline: auto; /* ממורכז */
	mix-blend-mode: multiply;
}

/* ---- סל ריק ---- */
.amph-cart--empty { text-align: center; padding-top: clamp(40px, 5vw, 90px); }
.amph-cart--empty .amph-cart__title { margin-bottom: 12px; }
.amph-cart__empty-msg { font-size: var(--amph-fs-body); margin: 0 0 26px; }
.amph-cart__empty-btn {
	display: inline-block;
	min-width: 260px;
	padding: 0 40px;
}

/* ---- הודעות ווקומרס בעמוד (עדכון סל, קופון, שגיאות) ---- */
.woocommerce-cart .woocommerce-message,
.woocommerce-cart .woocommerce-info,
.woocommerce-cart .woocommerce-error {
	font-family: 'Assistant', sans-serif;
	direction: rtl;
	max-width: 1704px;
	margin: 12px auto;
	padding: 14px 18px;
	list-style: none;
	background: #fff;
	border: 1px solid var(--amph-border, #AFAFAF);
	border-inline-start: 4px solid #CAAF6E;
	font-size: 16px;
	color: #000;
}
.woocommerce-cart .woocommerce-error { border-inline-start-color: #B3452F; }
.woocommerce-cart .woocommerce-error li { margin: 0; }
.woocommerce-cart .woocommerce-message .button,
.woocommerce-cart .woocommerce-info .button { display: none; }

/* ================= מובייל וטאבלט ================= */
@media (max-width: 980px) {
	.amph-cart__form { flex-direction: column; gap: 0; }
	.amph-cart__main {
		border-inline-end: 0;
		padding-inline-end: 0;
		width: 100%;
	}
	.amph-cart__sidebar {
		position: static;
		flex: 1 1 auto;
		width: 100%;
		margin-top: 34px;
	}
	.amph-cart__head { display: none; }
	.amph-cart__items { border-top: 1px solid var(--amph-line-strong); }
	.amph-cart--scroll .amph-cart__items { max-height: none; overflow: visible; }

	.amph-cart__grid {
		grid-template-columns: 1fr auto;
		grid-template-areas:
			"product product"
			"qty     price"
			"subtotal remove";
		gap: 10px 14px;
	}
	.amph-cart__item { position: relative; padding: 18px 0; }
	.amph-col--product { grid-area: product; }
	.amph-item__image, .amph-item__image img {
		width: 110px; height: 110px; flex-basis: 110px;
	}
	.amph-col--qty { grid-area: qty; }
	.amph-qty { margin: 0; }
	.amph-col--price { grid-area: price; text-align: left; }
	.amph-col--discount { display: none; }
	.amph-col--subtotal { grid-area: subtotal; }
	.amph-col--remove { grid-area: remove; text-align: left; }
	.amph-cell-label {
		display: inline-block;
		font-weight: 300;
		font-size: var(--amph-fs-small);
		margin-inline-end: 6px;
	}

	.amph-upsells__grid { grid-template-columns: repeat(3, 1fr); }
	.amph-upsell:nth-child(n+4) { display: none; }

	.amph-cart__continue { text-align: center; }
}

@media (min-width: 981px) {
	.amph-cell-label { display: none; }
}

@media (max-width: 480px) {
	.amph-cart { --amph-fs-body: 16px; --amph-fs-title: 24px; --amph-fs-small: 14px; }
	.amph-item__image, .amph-item__image img { width: 92px; height: 92px; flex-basis: 92px; }
}

/* כפתורי +/- בתוך הבורר נשארים ישרים; הרדיוס על המעטפת */
.amph-cart button.amph-qty__btn { border-radius: 0 !important; }
