/* ============================================================
   Good Nutrition Only — slide-out cart drawer
   Opens from the RIGHT side.
   ============================================================ */

/* Header cart icon + count badge */
.gno-icon { position: relative; }
.gno-cart-count {
	position: absolute; top: -7px; right: -9px;
	min-width: 16px; height: 16px; padding: 0 4px;
	background: var(--gno-white); color: var(--gno-black);
	border-radius: 999px; font-size: 10px; font-weight: 700; line-height: 1;
	display: flex; align-items: center; justify-content: center;
	font-family: var(--gno-font-body);
}
.gno-cart-count:empty { display: none; }

/* Overlay */
.gno-cart-overlay {
	position: fixed; inset: 0; background: rgba(0,0,0,.55);
	opacity: 0; visibility: hidden;
	transition: opacity .35s ease, visibility .35s; z-index: 1500;
}

/* Drawer shell — RIGHT side */
.gno-cart-drawer {
	position: fixed; top: 0; right: 0; height: 100vh; width: 420px; max-width: 92vw;
	background: var(--gno-black); border-left: 1px solid var(--gno-border);
	box-shadow: -24px 0 60px rgba(0,0,0,.45);
	transform: translateX(100%); transition: transform .4s cubic-bezier(.22,1,.36,1);
	z-index: 1600; display: flex; flex-direction: column; color: var(--gno-text-muted);
}
body.gno-cart-open { overflow: hidden; }
body.gno-cart-open .gno-cart-overlay { opacity: 1; visibility: visible; }
body.gno-cart-open .gno-cart-drawer { transform: translateX(0); }

/* Header */
.gno-cart-drawer__head {
	flex: 0 0 auto; display: flex; align-items: center; justify-content: space-between;
	padding: var(--gno-space-5) var(--gno-space-6); border-bottom: 1px solid var(--gno-border);
}
.gno-cart-drawer__title {
	font-family: var(--gno-font-heading); font-weight: 700; text-transform: uppercase;
	letter-spacing: .06em; color: var(--gno-white); font-size: var(--gno-fs-lg);
}
.gno-cart-drawer__close {
	background: none; border: 1px solid var(--gno-border); color: var(--gno-white);
	width: 34px; height: 34px; border-radius: 999px;
	display: flex; align-items: center; justify-content: center;
	font-size: 1.4rem; line-height: 1; cursor: pointer;
	transition: background .25s ease, border-color .25s ease;
	flex-shrink: 0;
}
.gno-cart-drawer__close:hover { background: rgba(255,255,255,.1); border-color: var(--gno-border-strong); }

/* Body = mini-cart content. Flex column that fills all remaining height so the
   subtotal + buttons pin to the very bottom of the drawer. */
.gno-cart-drawer__body {
	flex: 1 1 auto; min-height: 0; display: flex; flex-direction: column; padding: 0;
}

/* Empty state */
.gno-cart-drawer__body .woocommerce-mini-cart__empty-message {
	flex: 1 1 auto; display: flex; align-items: center; justify-content: center; text-align: center;
	padding: var(--gno-space-9) var(--gno-space-6); margin: 0; color: var(--gno-gray);
}

/* Item list (scrolls; grows to push subtotal/buttons down) */
.gno-cart-drawer ul.cart_list {
	flex: 1 1 auto; min-height: 0; overflow-y: auto;
	list-style: none; margin: 0; padding: var(--gno-space-4) var(--gno-space-6);
}
.gno-cart-drawer ul.cart_list li {
	position: relative; padding: var(--gno-space-4) var(--gno-space-7) var(--gno-space-4) 0;
	border-bottom: 1px solid var(--gno-border); overflow: hidden; list-style: none;
}
.gno-cart-drawer ul.cart_list li:last-child { border-bottom: 0; }
.gno-cart-drawer ul.cart_list li > a:not(.remove) {
	display: block; color: var(--gno-white); text-decoration: none;
	font-family: var(--gno-font-body); font-size: var(--gno-fs-sm); line-height: 1.4;
}
.gno-cart-drawer ul.cart_list li img {
	width: 60px; height: 60px; object-fit: cover; float: left;
	margin: 0 var(--gno-space-4) 0 0; border-radius: var(--gno-radius); border: 1px solid var(--gno-border);
}
.gno-cart-drawer ul.cart_list li .quantity {
	display: block; margin-top: var(--gno-space-2); color: var(--gno-gray); font-size: var(--gno-fs-sm);
}
.gno-cart-drawer ul.cart_list li .quantity .amount { color: var(--gno-white); }
.gno-cart-drawer ul.cart_list li a.remove {
	position: absolute; top: var(--gno-space-4); right: 0;
	width: 22px; height: 22px; line-height: 20px; text-align: center;
	border: 1px solid var(--gno-border); border-radius: 999px;
	color: var(--gno-gray) !important; font-size: 15px; text-decoration: none;
	transition: all .25s ease;
}
.gno-cart-drawer ul.cart_list li a.remove:hover {
	color: var(--gno-black) !important; background: var(--gno-white); border-color: var(--gno-white);
}

/* Subtotal — pinned just above the buttons at the bottom */
.gno-cart-drawer .woocommerce-mini-cart__total {
	flex: 0 0 auto; margin-top: auto; display: flex; align-items: center; justify-content: space-between;
	padding: var(--gno-space-5) var(--gno-space-6);
	border-top: 1px solid var(--gno-border);
	color: var(--gno-white); font-family: var(--gno-font-heading); font-weight: 700;
	text-transform: uppercase; letter-spacing: .05em; font-size: var(--gno-fs-base);
}
.gno-cart-drawer .woocommerce-mini-cart__total .amount { font-family: var(--gno-font-body); color: var(--gno-white); }

/* View Cart / Checkout buttons pinned at the very bottom */
.gno-cart-drawer .woocommerce-mini-cart__buttons {
	flex: 0 0 auto; display: flex; flex-direction: column; gap: var(--gno-space-3);
	margin: 0; padding: 0 var(--gno-space-6) var(--gno-space-6); list-style: none;
}
.gno-cart-drawer .woocommerce-mini-cart__buttons a {
	display: inline-flex; align-items: center; justify-content: center; width: 100%; margin: 0;
	padding: .95em 1.5em; border: 1px solid transparent; border-radius: var(--gno-radius-pill);
	font-family: var(--gno-font-body); font-weight: 600; font-size: var(--gno-fs-sm);
	letter-spacing: .06em; text-transform: uppercase; text-decoration: none;
	transition: background .25s ease, color .25s ease, border-color .25s ease;
}
.gno-cart-drawer .woocommerce-mini-cart__buttons a.checkout {
	background: var(--gno-white) !important; color: var(--gno-black) !important; border-color: var(--gno-white) !important;
}
.gno-cart-drawer .woocommerce-mini-cart__buttons a.checkout:hover {
	background: #e6e6e6 !important; border-color: #e6e6e6 !important;
}
.gno-cart-drawer .woocommerce-mini-cart__buttons a:not(.checkout) {
	background: transparent !important; color: var(--gno-white) !important; border-color: var(--gno-border-strong) !important;
}
.gno-cart-drawer .woocommerce-mini-cart__buttons a:not(.checkout):hover {
	background: rgba(255,255,255,.10) !important; border-color: var(--gno-white) !important;
}

@media (max-width: 480px) { .gno-cart-drawer { width: 90vw; } }
