/* ==========================================================================
   Karaaslan Tarım — Sepet drawer (sağdan kayan panel): overlay, satırlar,
   stepper, toplam, butonlar, boş durum
   ========================================================================== */

.ka-cart-overlay {
	position: fixed;
	inset: 0;
	background: rgba(18, 14, 20, .45);
	z-index: 90;
}

.ka-cart-overlay[hidden] {
	display: none;
}

.ka-cart-drawer {
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	width: 400px;
	max-width: 92vw;
	background: #fff;
	z-index: 95;
	box-shadow: -22px 0 60px rgba(0, 0, 0, .28);
	display: flex;
	flex-direction: column;
	animation: kaSlide .28s ease both;
}

.ka-cart-drawer[hidden] {
	display: none;
}

.ka-cart-drawer.is-busy {
	pointer-events: none;
	opacity: .7;
}

/* ---- Başlık ---- */

.ka-cart-drawer-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 20px 24px;
	border-bottom: 1px solid #eee7da;
	flex: none;
}

.ka-cart-drawer-title {
	font-weight: 600;
	font-size: 18px;
	margin: 0;
}

.ka-cart-drawer-count {
	color: var(--ka-faint);
	font-weight: 500;
	font-size: 14px;
}

.ka-cart-drawer-close {
	background: none;
	border: none;
	font-size: 21px;
	color: var(--ka-ink);
	line-height: 1;
	padding: 4px;
	transition: color .15s ease;
}

.ka-cart-drawer-close:hover,
.ka-cart-drawer-close:focus-visible {
	color: var(--ka-magenta);
}

/* ---- Gövde ---- */

.ka-cart-drawer-body {
	flex: 1;
	overflow-y: auto;
	padding: 18px 24px;
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.ka-cart-empty {
	text-align: center;
	color: var(--ka-faint);
	font-size: 14.5px;
	padding: 60px 10px;
}

/* ---- Sepet satırı ---- */

.ka-cart-item {
	display: flex;
	gap: 14px;
	align-items: center;
	border: 1px solid #f0e9dc;
	border-radius: 10px;
	padding: 12px 14px;
}

.ka-cart-item-text {
	flex: 1;
	min-width: 0;
}

.ka-cart-item-title {
	font-weight: 600;
	font-size: 14.5px;
	color: var(--ka-ink);
	overflow: hidden;
	text-overflow: ellipsis;
	white-space: nowrap;
}

.ka-cart-item-amount {
	font-size: 11.5px;
	color: var(--ka-orange-hover);
	font-weight: 600;
	margin: 2px 0;
}

.ka-cart-item-price {
	font-size: 12.5px;
	color: var(--ka-faint);
}

.ka-cart-item-price .woocommerce-Price-amount {
	font-size: 12.5px;
	color: var(--ka-faint);
}

.ka-cart-item-stepper {
	display: flex;
	align-items: center;
	gap: 9px;
	flex: none;
}

.ka-cart-item-dec,
.ka-cart-item-inc {
	width: 28px;
	height: 28px;
	border-radius: 50%;
	border: none;
	font-size: 15px;
	font-weight: 700;
	transition: background-color .15s ease;
}

.ka-cart-item-dec {
	background: var(--ka-cream-3);
	color: var(--ka-orange-hover);
}

.ka-cart-item-dec:hover {
	background: #f6ddc2;
}

.ka-cart-item-inc {
	background: var(--ka-orange);
	color: #fff;
}

.ka-cart-item-inc:hover {
	background: var(--ka-orange-hover);
}

.ka-cart-item-qty {
	font-size: 14px;
	font-weight: 700;
	min-width: 16px;
	text-align: center;
	color: var(--ka-ink);
}

.ka-cart-item-line {
	font-weight: 700;
	font-size: 14px;
	color: var(--ka-magenta);
	min-width: 76px;
	text-align: right;
	flex: none;
}

.ka-cart-item-line .woocommerce-Price-amount {
	font-size: 14px;
	font-weight: 700;
	color: var(--ka-magenta);
}

.ka-cart-item-remove {
	background: none;
	border: none;
	color: var(--ka-faint);
	font-size: 14px;
	line-height: 1;
	padding: 4px;
	flex: none;
	transition: color .15s ease;
}

.ka-cart-item-remove:hover,
.ka-cart-item-remove:focus-visible {
	color: var(--ka-magenta);
}

/* ---- Footer: toplam + ödeme ---- */

.ka-cart-drawer-footer {
	border-top: 1px solid #eee7da;
	padding: 20px 24px;
	flex: none;
}

.ka-cart-drawer-footer[hidden] {
	display: none;
}

.ka-cart-total-row {
	display: flex;
	justify-content: space-between;
	font-size: 16px;
	margin-bottom: 14px;
}

.ka-cart-total-label {
	font-weight: 600;
}

.ka-cart-total-amount {
	font-weight: 700;
	color: var(--ka-magenta);
}

.ka-cart-total-amount .woocommerce-Price-amount {
	font-weight: 700;
	color: var(--ka-magenta);
}

.ka-cart-checkout-btn {
	display: block;
	width: 100%;
	text-align: center;
	background: var(--ka-magenta);
	color: #fff;
	border: none;
	border-radius: 999px;
	padding: 15px;
	font-size: 15px;
	font-weight: 600;
	transition: background-color .15s ease;
}

.ka-cart-checkout-btn:hover,
.ka-cart-checkout-btn:focus-visible {
	background: var(--ka-magenta-hover);
	color: #fff;
}

/* ---- Body scroll-lock ---- */

body.ka-cart-is-open {
	overflow: hidden;
}

/* ---- Responsive ---- */

@media (max-width: 480px) {
	.ka-cart-drawer {
		width: 100%;
		max-width: 100vw;
	}

	.ka-cart-drawer-head,
	.ka-cart-drawer-body,
	.ka-cart-drawer-footer {
		padding-left: 18px;
		padding-right: 18px;
	}
}
