/* =========================================================================
   КУЗНЯ КАВИ — кошик-drawer
   Токени з kk-header.css (:root)
   ========================================================================= */

.kk-cart-overlay {
	position: fixed; inset: 0; z-index: 340;
	background: rgba(20,18,16,.5);
	opacity: 0; visibility: hidden;
	transition: opacity var(--kk-ease), visibility var(--kk-ease);
}
.kk-cart-overlay[hidden] { display: block; } /* керуємо через клас, не hidden */
body.kk-cart-open .kk-cart-overlay { opacity: 1; visibility: visible; }

.kk-cart-drawer {
	position: fixed; top: 0; right: 0; bottom: 0;
	width: min(100%, 460px);
	background: #F6F2E9;
	z-index: 350;
	transform: translateX(100%);
	transition: transform var(--kk-ease);
	display: flex; flex-direction: column;
	box-shadow: -20px 0 60px rgba(0,0,0,.25);
}
body.kk-cart-open .kk-cart-drawer { transform: translateX(0); }
body.kk-cart-open { overflow: hidden; }

/* Шапка */
.kk-cart-drawer__head {
	flex: 0 0 auto;
	display: flex; align-items: center; justify-content: space-between;
	padding: 22px 24px 18px;
}
.kk-cart-drawer__title { margin: 0; font-size: 26px; font-weight: 800; color: var(--kk-text-dark); }
.kk-cart-title-count { font-weight: 800; }
.kk-cart-close {
	width: 40px; height: 40px; border: 0; background: transparent; cursor: pointer;
	color: var(--kk-text-dark); border-radius: 50%;
	display: inline-flex; align-items: center; justify-content: center;
	transition: background var(--kk-ease); padding: 0;
}
.kk-cart-close:hover { background: rgba(27,26,24,.08); }
.kk-cart-close svg { width: 24px; height: 24px; display: block; }

/* Внутрішній флекс */
.kk-cart-drawer__inner { flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; }
.kk-cart-scroll { flex: 1 1 auto; overflow-y: auto; padding: 0 24px; }

/* Прогрес доставки */
.kk-cart-ship { padding: 14px 24px 20px; width: calc(100% + 48px); margin: 0px -24px; background: var(--kk-text); border-top: 1px solid rgba(27,26,24,.1); border-bottom: 1px solid rgba(27,26,24,.1); }
.kk-cart-ship__text { margin: 0 0 12px; font-size: 15px; line-height: 1.4; color: var(--kk-text-dark); }
.kk-cart-ship__amt { color: #56694C; font-weight: 700; }
.kk-cart-ship__bar { height: 10px; background: #E4DFD2; border-radius: 999px; overflow: hidden; }
.kk-cart-ship__bar span { display: block; height: 100%; background: #56694C; border-radius: 999px; transition: width .3s ease; }

/* Позиція */
.kk-cart-item { display: flex; gap: 16px; padding: 22px 0; border-top: 1px solid rgba(27,26,24,.1); }
.kk-cart-item:first-child { border: unset; }
.kk-cart-item__thumb { flex: 0 0 auto; width: 76px; }
.kk-cart-item__thumb img { width: 76px; height: 76px; object-fit: cover; border-radius: 8px; display: block; }
.kk-cart-item__main { flex: 1 1 auto; min-width: 0; }

.kk-cart-item__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.kk-cart-item__name { font-size: 17px; font-weight: 700; color: var(--kk-text-dark); line-height: 1.2; }
.kk-cart-item__remove {
	flex: 0 0 auto; width: 30px; height: 30px; border: 0; background: transparent; cursor: pointer;
	color: var(--kk-text-dark); display: inline-flex; align-items: center; justify-content: center;
	transition: color var(--kk-ease);
}
.kk-cart-item__remove:hover { color: #b3261e; }
.kk-cart-item__remove svg { width: 18px; height: 18px; display: block; }

/* Варіації */
.kk-cart-item__variations { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin-bottom: 14px; }
.kk-cart-var { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.kk-cart-var__label { font-size: 14px; font-weight: 600; color: var(--kk-text-dark); }
.kk-cart-var__select {
	width: 100%;
	appearance: none; -webkit-appearance: none;
	background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%231B1A18' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center;
	border: 1px solid rgba(27,26,24,.18);
	border-radius: 8px;
	padding: 10px 32px 10px 12px;
	font-size: 15px; color: var(--kk-text-dark);
	cursor: pointer; outline: none;
}
.kk-cart-var__select:focus { border-color: var(--kk-text-dark); }

/* Ціна + кількість */
.kk-cart-item__bottom { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.kk-cart-item__price { font-size: 17px; color: var(--kk-text-dark); }
.kk-cart-item__price .amount { font-weight: 500; }

.kk-qty { display: inline-flex; align-items: center; gap: 8px; }
.kk-qty__btn {
	width: 30px; height: 28px; border: 1px solid rgba(27,26,24,.18);
	background: #fff; color: var(--kk-text-dark);
	border-radius: 8px; cursor: pointer; font-size: 18px; line-height: 1;
	display: inline-flex; align-items: center; justify-content: center;
	transition: background var(--kk-ease), border-color var(--kk-ease); padding: 0;
}
.kk-qty__btn:hover { border-color: var(--kk-text-dark); }
.kk-qty__btn--plus { background: #56694C; border-color: #56694C; color: #fff; }
.kk-qty__btn--plus:hover { background: #4a5b41; }
input.kk-qty__input {
	width: 50px; height: 28px; text-align: center;
	border: 1px solid rgba(27,26,24,.18); border-radius: 8px;
	background: #fff; color: var(--kk-text-dark); font-size: 15px; outline: none;
	-webkit-appearance: none; appearance: none;
}

/* Підвал */
.kk-cart-foot { flex: 0 0 auto; padding: 8px 24px 24px; background: #F6F2E9; }
.kk-cart-clear {
	display: block; width: calc(100% + 48px);
	border: 0; border-top: 1px solid rgba(27,26,24,.1); border-bottom: 1px solid rgba(27,26,24,.1);
	background: transparent; cursor: pointer;
	padding: 10px 0; font-size: 15px; font-weight: 700; color: var(--kk-text-dark);
	transition: color var(--kk-ease); margin: 0px -24px 30px;
}
.kk-cart-clear:hover { color: #b3261e; }

.kk-cart-foot__row { display: flex; align-items: center; justify-content: space-between; gap: 14px; margin: 6px 0 4px; }
.kk-cart-promo { display: flex; gap: 8px; flex: 0 1 auto; }
input.kk-cart-promo__input {
	width: 150px; max-width: 100%;
	border: 1px solid rgba(27,26,24,.18); border-radius: 8px;
	padding: 4px 12px; font-size: 14px; background: #fff; color: var(--kk-text-dark); outline: none;
}
.kk-cart-promo__btn {
	border: 1px solid var(--kk-text-dark); background: #000000; color: var(--kk-text);
	border-radius: 8px; padding: 0 16px; cursor: pointer; font-weight: 700; font-size: 14px;
	transition: background var(--kk-ease), color var(--kk-ease);
}
.kk-cart-promo__btn:hover { background: #1a1a1a; color: #fff; }
.kk-cart-total { font-size: 15px; color: var(--kk-text-dark); white-space: nowrap; }
.kk-cart-total strong { font-size: 17px; }

.kk-cart-coupon-msg { min-height: 0; color: #b3261e; font-size: 13px; margin: 4px 0 0; }
.kk-cart-coupon-msg:empty { display: none; }

.kk-cart-checkout {
	display: block; text-align: center; text-decoration: none;
	margin-top: 16px;
	background: #111; color: #fff; font-weight: 700; font-size: 16px;
	padding: 10px 18px; border-radius: var(--kk-pill);
	transition: background var(--kk-ease);
}
.kk-cart-checkout:hover { background: #000; }

/* Порожній стан */
.kk-cart-empty {
	flex: 1 1 auto; display: flex; flex-direction: column;
	align-items: center; justify-content: center; gap: 22px; text-align: center; padding: 24px;
}
.kk-cart-empty__text { margin: 0; font-size: 20px; font-weight: 700; color: var(--kk-text-dark); }
.kk-cart-empty .kk-btn {
	display: inline-flex; align-items: center; justify-content: center;
	background: #111; color: #fff; text-decoration: none; font-weight: 700;
	padding: 16px 34px; border-radius: var(--kk-pill);
	transition: background var(--kk-ease);
}
.kk-cart-empty .kk-btn:hover { background: #000; }

/* Стан завантаження */
.kk-cart-drawer.is-loading .kk-cart-drawer__inner { opacity: .55; pointer-events: none; }

/* Мобілка */
@media (max-width: 420px) {
	.kk-cart-item__variations { grid-template-columns: 1fr; }
	.kk-cart-foot__row { flex-direction: column; align-items: stretch; }
	.kk-cart-promo { width: 100%; }
	.kk-cart-promo__input { flex: 1 1 auto; width: auto; }
	.kk-cart-total { text-align: right; }
}

/* ================= Override'и (батч) ================= */
.kk-cart-drawer { background: #F3F3E9; }
.kk-cart-foot { flex: 0 0 auto; padding: 8px 24px 24px; background: #F3F3E9; }
.kk-cart-close:hover { background: unset; color: #DB8622; }
.kk-cart-var__select { width: 100%; appearance: none; -webkit-appearance: none; background: #FAFAF2 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%231B1A18' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E") no-repeat right 12px center; border: 1px solid rgba(27, 26, 24, .18); border-radius: 8px; padding: 4px 32px 4px 12px; font-size: 14px; color: var(--kk-text-dark); cursor: pointer; outline: none; line-height: 1; }
.kk-cart-item__remove { flex: 0 0 auto; width: 30px; height: 30px; border: 0; background: transparent; cursor: pointer; color: var(--kk-text-dark); align-items: center; justify-content: center; transition: color var(--kk-ease); padding: 0px; display: none; }
.kk-cart-item__remove:hover { color: #DB8622; background: unset; }
.kk-cart-item:hover .kk-cart-item__remove { display: inline-flex; }
.kk-cart-item:hover { background: #FAFAF2; }
input.kk-cart-promo__input { width: 150px; max-width: 100%; border: 1px solid rgba(27, 26, 24, .18); border-radius: 8px; padding: 2px 12px; font-size: 12px; background: #FAFAF2; color: var(--kk-text-dark); outline: none; }
.kk-cart-clear:hover { color: var(--kk-text-dark); background: unset; }
.kk-cart-checkout:hover { background: #000; color: #fff; }
input.kk-qty__input { width: 50px; height: 24px; text-align: center; border: 1px solid rgba(27, 26, 24, .18); border-radius: 8px; background: #FAFAF2; color: var(--kk-text-dark); font-size: 14px; outline: none; -webkit-appearance: none; appearance: none; }
.kk-qty__btn { width: 30px; height: 24px; border: 1px solid rgba(27, 26, 24, .18); background: #FAFAF2; color: var(--kk-text-dark); border-radius: 8px; cursor: pointer; font-size: 14px; line-height: 1; display: inline-flex; align-items: center; justify-content: center; transition: background var(--kk-ease), border-color var(--kk-ease); padding: 0; }

/* Позиція кошика — на всю ширину + ім'я з обмеженням */
.kk-cart-item { display: flex; gap: 16px; padding: 22px 24px; border-top: 1px solid rgba(27, 26, 24, .1); margin: 0 -24px; }
.kk-cart-item__name { font-size: 17px; font-weight: 700; color: var(--kk-text-dark); line-height: 1.2; max-width: calc(100% - 40px); }
