/**
 * Cart page — checkout-flow step indicator.
 */

.oten-cart-steps {
	padding: 20px 16px;
	background: #fff;
}

.oten-cart-steps__list {
	display: flex;
	align-items: flex-start;
	justify-content: center;
	list-style: none;
	margin: 0;
	padding: 0;
}

.oten-cart-steps__item {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	flex: 0 0 auto;
}

.oten-cart-steps__link {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 8px;
	text-decoration: none;
	cursor: pointer;
}

.oten-cart-steps__link:hover .oten-cart-steps__label {
	color: #610f25;
}

.oten-cart-steps__link:focus-visible {
	outline: 2px solid #610f25;
	outline-offset: 4px;
}

.oten-cart-steps__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	flex-shrink: 0;
}

.oten-cart-steps__item.is-active .oten-cart-steps__icon {
	width: 32px;
	height: 32px;
}

.oten-cart-steps__icon-svg {
	display: block;
	width: 28px;
	height: 28px;
	flex-shrink: 0;
}

/* Active + done steps: tint the inline SVG to brand purple (#610f25). Fill-based
 * icons (shipping/payment) get fill; stroke-based icons (cart) get stroke.
 * Paths without that attribute are left alone so e.g. the cart never fills. */
.oten-cart-steps__item.is-active .oten-cart-steps__icon-svg path[fill]:not([fill='none']),
.oten-cart-steps__item.is-done .oten-cart-steps__icon-svg path[fill]:not([fill='none']),
.oten-cart-steps__item.is-active .oten-cart-steps__icon-svg circle[fill]:not([fill='none']),
.oten-cart-steps__item.is-done .oten-cart-steps__icon-svg circle[fill]:not([fill='none']),
.oten-cart-steps__item.is-active .oten-cart-steps__icon-svg rect[fill]:not([fill='none']),
.oten-cart-steps__item.is-done .oten-cart-steps__icon-svg rect[fill]:not([fill='none']) {
	fill: #610f25;
}

.oten-cart-steps__item.is-active .oten-cart-steps__icon-svg path[stroke]:not([stroke='none']),
.oten-cart-steps__item.is-done .oten-cart-steps__icon-svg path[stroke]:not([stroke='none']),
.oten-cart-steps__item.is-active .oten-cart-steps__icon-svg circle[stroke]:not([stroke='none']),
.oten-cart-steps__item.is-done .oten-cart-steps__icon-svg circle[stroke]:not([stroke='none']),
.oten-cart-steps__item.is-active .oten-cart-steps__icon-svg rect[stroke]:not([stroke='none']),
.oten-cart-steps__item.is-done .oten-cart-steps__icon-svg rect[stroke]:not([stroke='none']) {
	stroke: #610f25;
}

.oten-cart-steps__label {
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 11px;
	font-weight: 500;
	color: #8a8a8a;
	white-space: nowrap;
}

.oten-cart-steps__item.is-active .oten-cart-steps__label,
.oten-cart-steps__item.is-done .oten-cart-steps__label {
	color: #610f25;
	font-weight: 700;
	font-size: 12px;
}

.oten-cart-steps__connector {
	flex: 0 0 48px;
	height: 1px;
	margin: 16px 8px 0;
	background: #e1e1e1;
	align-self: flex-start;
}

.oten-cart-steps__connector.is-filled {
	background: #610f25;
}

@media (min-width: 768px) {
	.oten-cart-steps {
		padding: 40px 16px 32px;
	}

	.oten-cart-steps__icon {
		width: 40px;
		height: 40px;
	}

	.oten-cart-steps__item.is-active .oten-cart-steps__icon {
		width: 40px;
		height: 40px;
	}

	.oten-cart-steps__icon-svg {
		width: 36px;
		height: 36px;
	}

	.oten-cart-steps__label {
		font-size: 13px;
	}

	.oten-cart-steps__item.is-active .oten-cart-steps__label {
		font-size: 15px;
	}

	.oten-cart-steps__connector {
		flex: 0 0 120px;
		margin-top: 20px;
	}
}

/**
 * Cart page — line items, order summary, related products.
 */
body.woocommerce-cart .site-main {
	background: #fff;
}

/* Hide WooCommerce's default blockUI overlay on cart AJAX updates. */
body.woocommerce-cart .blockUI,
body.woocommerce-cart .blockOverlay {
	display: none !important;
}

body.woocommerce-cart .processing {
	opacity: 1 !important;
	pointer-events: auto !important;
}

.oten-cart {
	display: flex;
	flex-direction: column;
	gap: 24px;
	padding: 0 16px 104px;
}

.oten-cart__items-form {
	display: flex;
	flex: 1 1 auto;
	min-width: 0;
	flex-direction: column;
}

.oten-cart__items {
	display: flex;
	flex-direction: column;
}

.oten-cart__update-trigger {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Line item — image | details+qty | price */
.oten-cart-item {
	display: flex;
	align-items: stretch;
	gap: 12px;
	padding: 16px 0;
	border-bottom: 1px solid #eee;
}

.oten-cart-item__media {
	display: block;
	flex-shrink: 0;
	align-self: center;
	width: 88px;
	height: 88px;
	overflow: hidden;
	background: #f5f5f5;
}

.oten-cart-item__image {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	object-position: top center;
}

.oten-cart-item__main {
	display: flex;
	flex: 1 1 auto;
	min-width: 0;
	flex-direction: column;
	align-items: flex-start;
	gap: 8px;
}

.oten-cart-item__title {
	margin: 0;
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 13px;
	line-height: 1.5;
	font-weight: 400;
	color: var(--oten-ink);
	text-decoration: none;
}

.oten-cart-item__title:hover,
.oten-cart-item__title:focus-visible {
	color: var(--oten-brand);
}

.oten-cart-item__meta {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 6px;
	font-family: IRANYekanX, Tahoma, sans-serif;
	font-size: 11px;
	color: #898989;
}

.oten-cart-item__meta b {
	font-weight: 500;
	color: var(--oten-ink);
}

.oten-cart-item__colors {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.oten-cart-item__swatches {
	display: inline-flex;
	align-items: center;
	gap: 4px;
}

.oten-cart-item__swatch {
	display: block;
	width: 12px;
	height: 12px;
	border-radius: 9999px;
	border: 1px solid rgba(0, 0, 0, 0.08);
}

.oten-cart-item__price-block {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	align-self: flex-end;
	gap: 8px;
	flex-shrink: 0;
	min-width: 0;
}

.oten-cart-item__price-block--sale {
	align-items: center;
}

.oten-cart-item__prices {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
	gap: 4px;
	min-width: 0;
}

.oten-cart-item__badge {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	min-width: 34px;
	min-height: 34px;
	padding: 4px 6px;
	border-radius: 6px;
	background: #e3352b;
	font-family: IRANYekanX, Tahoma, sans-serif;
	font-size: 12px;
	font-weight: 400;
	color: #fff;
	white-space: nowrap;
	line-height: 1;
}

.oten-cart-item__old-price {
	font-family: IRANYekanX, Tahoma, sans-serif;
	font-size: 12px;
	font-weight: 400;
	color: #9a9a9a;
	text-decoration: line-through;
	white-space: nowrap;
	line-height: 1;
}

.oten-cart-item__price-row {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.oten-cart-item__price {
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 15px;
	font-weight: 400;
	color: var(--oten-ink);
	white-space: nowrap;
	line-height: 1;
}

.oten-cart-item__price-currency {
	display: block;
	width: 16px;
	height: 16px;
	flex-shrink: 0;
}

/* Quantity stepper — LTR so remove/minus stays left, plus stays right in RTL pages */
.oten-cart-item__stepper {
	display: inline-flex;
	direction: ltr;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	gap: 14px;
	height: 32px;
	margin-top: 4px;
	padding: 0 12px;
	border: 1px solid #e1e1e1;
	border-radius: 4px;
	background: #fff;
	box-sizing: border-box;
	line-height: 0;
}

.oten-cart-item__stepper > * {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	flex-shrink: 0;
	margin: 0;
	padding: 0;
	line-height: 0;
	vertical-align: middle;
}

.oten-cart-item__qty-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 18px;
	height: 18px;
	padding: 0;
	margin: 0;
	border: 0;
	background: transparent;
	cursor: pointer;
	color: var(--oten-ink);
	text-decoration: none;
	line-height: 0;
	flex-shrink: 0;
	box-sizing: border-box;
}

.oten-cart-item__qty-btn:disabled {
	opacity: 0.35;
	cursor: not-allowed;
}

.oten-cart-item__stepper .product-remove,
.oten-cart-item__stepper .product-remove a,
.oten-cart-item__stepper a.oten-cart-item__qty-btn--remove {
	display: inline-flex !important;
	align-items: center;
	justify-content: center;
	width: 18px !important;
	height: 18px !important;
	min-width: 18px;
	min-height: 18px;
	max-width: 18px;
	max-height: 18px;
	margin: 0 !important;
	padding: 0 !important;
	font-size: 0 !important;
	font-weight: 400 !important;
	line-height: 0 !important;
	border: 0 !important;
	border-radius: 0 !important;
	background: transparent !important;
	color: var(--oten-ink) !important;
	text-decoration: none !important;
	box-shadow: none !important;
	float: none !important;
	position: static !important;
}

.oten-cart-item__stepper a.oten-cart-item__qty-btn--remove:hover,
.oten-cart-item__stepper a.oten-cart-item__qty-btn--remove:focus,
.oten-cart-item__stepper a.oten-cart-item__qty-btn--remove:focus-visible {
	color: var(--oten-ink) !important;
	background: transparent !important;
	opacity: 1;
}

.oten-cart-item__qty-icon {
	display: block;
	width: 14px;
	height: 14px;
	margin: 0;
	padding: 0;
	flex-shrink: 0;
}

.oten-cart-item__qty-icon--trash {
	width: 15px;
	height: 15px;
}

.oten-cart-item__qty-value {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 16px;
	height: 18px;
	margin: 0;
	padding: 0;
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 14px;
	font-weight: 400;
	color: var(--oten-ink);
	text-align: center;
	line-height: 1;
}

/* Order summary (coupon + totals + checkout) */
.oten-cart-summary {
	display: flex;
	flex-direction: column;
	gap: 20px;
	padding: 20px 16px;
	background: #fafafa;
}

.oten-cart-summary__coupon {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.oten-cart-summary__coupon-label {
	display: flex;
	align-items: center;
	gap: 8px;
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 13px;
	font-weight: 500;
	color: var(--oten-ink);
}

.oten-cart-summary__coupon-icon {
	display: block;
	flex-shrink: 0;
	width: 18px;
	height: 18px;
}

.oten-cart-summary__coupon-row {
	display: flex;
	align-items: stretch;
	gap: 8px;
}

.oten-cart-summary__coupon-input {
	flex: 1 1 auto;
	min-width: 0;
	height: 44px;
	padding: 0 14px;
	border: 1px solid #e1e1e1;
	background: #fff;
	font-family: IRANYekanX, Tahoma, sans-serif;
	font-size: 13px;
	color: var(--oten-ink);
}

.oten-cart-summary__coupon-input::placeholder {
	color: #b3b3b3;
}

.oten-cart-summary__coupon-input:focus-visible {
	outline: 2px solid var(--oten-brand);
	outline-offset: -2px;
}

.oten-cart-summary__coupon-submit {
	position: relative;
	flex-shrink: 0;
	min-width: 84px;
	height: 44px;
	padding: 0 16px;
	border: 1px solid var(--oten-brand);
	background: #fff;
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 13px;
	font-weight: 500;
	color: var(--oten-brand);
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease;
}

.oten-cart-summary__coupon-submit:hover,
.oten-cart-summary__coupon-submit:focus-visible {
	background: var(--oten-brand);
	color: #fff;
}

.oten-cart-summary__coupon-submit.is-loading {
	color: transparent;
	pointer-events: none;
	cursor: wait;
}

.oten-cart-summary__coupon-submit.is-loading:hover,
.oten-cart-summary__coupon-submit.is-loading:focus-visible {
	background: #fff;
	color: transparent;
}

.oten-cart-summary__coupon-submit.is-loading::after {
	content: '';
	position: absolute;
	inset-block-start: 50%;
	inset-inline-start: 50%;
	width: 16px;
	height: 16px;
	margin-block-start: -8px;
	margin-inline-start: -8px;
	border: 2px solid rgba(96, 15, 34, 0.25);
	border-block-start-color: var(--oten-brand);
	border-radius: 50%;
	animation: oten-cart-checkout-spin 0.7s linear infinite;
}

.oten-cart-summary__applied-coupons {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.oten-cart-summary__applied-coupon {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 8px;
	font-family: IRANYekanX, Tahoma, sans-serif;
	font-size: 12px;
	color: var(--oten-ink);
}

.oten-cart-summary__applied-coupon-label {
	min-width: 0;
	color: var(--oten-ink);
	font-weight: 500;
}

.oten-cart-summary__applied-coupon-details {
	display: inline-flex;
	align-items: center;
	justify-content: flex-end;
	gap: 10px;
	flex-shrink: 0;
}

.oten-cart-summary__applied-coupon-discount {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	color: #1f9254;
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-weight: 500;
}

.oten-cart-summary__applied-coupon .woocommerce-remove-coupon {
	position: relative;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 42px;
	color: #e3352b;
	text-decoration: none;
}

.oten-cart-summary__applied-coupon .woocommerce-remove-coupon.is-loading {
	color: transparent;
	pointer-events: none;
	cursor: wait;
}

.oten-cart-summary__applied-coupon .woocommerce-remove-coupon.is-loading::after {
	content: '';
	position: absolute;
	inset-block-start: 50%;
	inset-inline-start: 50%;
	width: 14px;
	height: 14px;
	margin-block-start: -7px;
	margin-inline-start: -7px;
	border: 2px solid rgba(227, 53, 43, 0.25);
	border-block-start-color: #e3352b;
	border-radius: 50%;
	animation: oten-cart-checkout-spin 0.7s linear infinite;
}

.oten-cart-summary__rows {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding-top: 16px;
	border-top: 1px solid #e8e8e8;
}

.oten-cart-summary__row {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	font-family: IRANYekanX, Tahoma, sans-serif;
	font-size: 13px;
	color: var(--oten-ink);
}

.oten-cart-summary__row-value {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-weight: 500;
}

.oten-cart-summary__row-value--discount {
	color: #1f9254;
}

.oten-cart-summary__row-currency {
	display: block;
	width: 12px;
	height: 12px;
	flex-shrink: 0;
}

.oten-cart-summary__row--total {
	padding-top: 12px;
	border-top: 1px solid #e8e8e8;
	font-weight: 700;
}

.oten-cart-summary__row--total .oten-cart-summary__row-value {
	font-size: 16px;
}

.oten-cart-summary__checkout-btn {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	padding: 14px 16px;
	border: 0;
	background: var(--oten-brand);
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 14px;
	font-weight: 500;
	color: #fff;
	text-decoration: none;
	transition: background-color 0.2s ease;
}

/* Beat WooCommerce `.wc-proceed-to-checkout a.checkout-button { padding: 1em; font-size: 1.25em }` */
body.woocommerce-cart .oten-cart-summary .wc-proceed-to-checkout a.checkout-button.oten-cart-summary__checkout-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	margin: 0;
	padding: 14px 16px;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.3;
	min-height: 0;
	height: auto;
	box-sizing: border-box;
}

.oten-cart-summary__checkout-btn:hover,
.oten-cart-summary__checkout-btn:focus-visible {
	background: var(--oten-brand-dark);
}

@media (max-width: 767px) {
	.oten-cart-summary__checkout {
		display: none;
	}
}

.oten-cart-summary__checkout-btn.is-loading,
.oten-cart-mobile-bar__cta.is-loading {
	color: transparent;
	pointer-events: none;
	cursor: wait;
}

.oten-cart-summary__checkout-btn.is-loading::after,
.oten-cart-mobile-bar__cta.is-loading::after {
	content: '';
	position: absolute;
	inset-block-start: 50%;
	inset-inline-start: 50%;
	width: 18px;
	height: 18px;
	margin-block-start: -9px;
	margin-inline-start: -9px;
	border: 2px solid rgba(255, 255, 255, 0.35);
	border-block-start-color: #fff;
	border-radius: 50%;
	animation: oten-cart-checkout-spin 0.7s linear infinite;
}

@keyframes oten-cart-checkout-spin {
	to {
		transform: rotate(360deg);
	}
}

/* Mobile sticky bar */
.oten-cart-mobile-bar {
	position: fixed;
	inset-inline: 0;
	bottom: 0;
	z-index: 20;
	display: flex;
	flex-direction: row-reverse;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 14px 24px;
	background: #fff;
	box-shadow: 0 -2px 12px rgba(0, 0, 0, 0.08);
}

.oten-cart-mobile-bar__price {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 3px;
	min-width: 0;
}

.oten-cart-mobile-bar__label {
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 11px;
	color: #898989;
}

.oten-cart-mobile-bar__value {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 16px;
	font-weight: 700;
	color: var(--oten-ink);
}

.oten-cart-mobile-bar__currency {
	display: block;
	width: 14px;
	height: 14px;
	flex-shrink: 0;
}

.oten-cart-mobile-bar__cta {
	position: relative;
	display: inline-flex;
	flex-shrink: 0;
	align-items: center;
	justify-content: center;
	min-width: 130px;
	padding: 12px 20px;
	background: var(--oten-brand);
	font-family: Kalameh, IRANYekanX, Tahoma, sans-serif;
	font-size: 13px;
	font-weight: 500;
	color: #fff;
	text-decoration: none;
}

.oten-cart-mobile-bar__cta:hover,
.oten-cart-mobile-bar__cta:focus-visible {
	background: var(--oten-brand-dark);
}

@media (min-width: 768px) {
	.oten-cart {
		flex-direction: row;
		align-items: flex-start;
		width: min(1200px, calc(100% - 60px));
		margin-inline: auto;
		padding: 0 0 64px;
		column-gap: 100px;
		row-gap: 32px;
		gap: 100px;
	}

	.oten-cart__items-form {
		flex: 1 1 auto;
		min-width: 0;
	}

	.oten-cart__items {
		flex: 1 1 auto;
		min-width: 0;
	}

	.oten-cart__summary {
		flex: 0 0 360px;
		margin-inline-start: 0;
	}

	body.woocommerce-cart .oten-cart-summary .wc-proceed-to-checkout a.checkout-button.oten-cart-summary__checkout-btn {
		padding: 11px 16px;
		font-size: 13px;
		line-height: 1.2;
		min-height: 46px;
		height: 46px;
	}

	.oten-cart-item {
		gap: 20px;
		padding: 24px 0;
		min-height: 120px;
	}

	.oten-cart-item__media {
		width: 110px;
		height: 110px;
	}

	.oten-cart-item__title {
		font-size: 15px;
	}

	.oten-cart-item__meta {
		font-size: 12px;
		gap: 8px;
	}

	.oten-cart-item__main {
		gap: 10px;
	}

	.oten-cart-item__stepper {
		margin-top: 8px;
		padding: 8px 14px;
		gap: 16px;
	}

	.oten-cart-item__price {
		font-size: 18px;
	}

	.oten-cart-item__price-currency {
		width: 18px;
		height: 18px;
	}

	.oten-cart-item__old-price {
		font-size: 12px;
	}

	.oten-cart-summary {
		padding: 24px;
	}

	.oten-cart-mobile-bar {
		display: none;
	}
}
