/* AD Cart Drawer — accordiondoor.cloudnineweb.dev (2026-09).
   Shell adapted from Builders United's site-cart-drawer. Rem base on this
   site is 10px, but this widget is specced in px to stay independent. */

.acd-toggle {
	position: fixed;
	right: 22px;
	bottom: 22px;
	z-index: 99998;
	width: 56px;
	height: 56px;
	border-radius: 50%;
	border: none;
	background: #1f2937;
	color: #fff;
	cursor: pointer;
	display: flex;
	align-items: center;
	justify-content: center;
	box-shadow: 0 6px 20px rgba(15, 23, 42, 0.35);
	transition: background 0.15s, transform 0.15s;
}
.acd-toggle:hover { background: #111827; transform: translateY(-1px); }
.acd-toggle .acd-icon { width: 24px; height: 24px; fill: currentColor; }
.acd-count {
	position: absolute;
	top: -4px;
	right: -4px;
	min-width: 20px;
	height: 20px;
	padding: 0 5px;
	border-radius: 10px;
	background: #e11d48;
	color: #fff;
	font-size: 12px;
	font-weight: 700;
	line-height: 20px;
	text-align: center;
	box-shadow: 0 0 0 2px #fff;
}

.acd-overlay {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(15, 23, 42, 0.5);
	opacity: 0;
	transition: opacity 0.25s;
}
.acd-overlay.acd-visible { opacity: 1; }

.acd-drawer {
	position: fixed;
	top: 0;
	right: 0;
	bottom: 0;
	z-index: 100000;
	width: min(380px, calc(100vw - 32px));
	background: #fff;
	display: flex;
	flex-direction: column;
	transform: translateX(100%);
	transition: transform 0.28s ease;
	box-shadow: -8px 0 30px rgba(15, 23, 42, 0.18);
}
.acd-drawer.acd-open { transform: translateX(0); }

.acd-head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 16px 18px;
	border-bottom: 1px solid #e5e7eb;
}
.acd-head .acd-title { font-size: 17px; font-weight: 700; color: #111827; }
.acd-close {
	border: none;
	background: none;
	font-size: 26px;
	line-height: 1;
	color: #6b7280;
	cursor: pointer;
	padding: 4px 8px;
}
.acd-close:hover { color: #111827; }

.acd-body { flex: 1; overflow-y: auto; padding: 6px 0; }
.acd-body .acd-empty { padding: 32px 20px; text-align: center; color: #6b7280; font-size: 14px; }

.acd-item {
	display: flex;
	gap: 12px;
	padding: 12px 18px;
	border-bottom: 1px solid #f3f4f6;
	align-items: flex-start;
}
.acd-item-main { flex: 1; min-width: 0; }
.acd-item-title { font-weight: 600; font-size: 14px; color: #111827; }
.acd-item-sub { font-size: 12.5px; color: #6b7280; margin-top: 2px; line-height: 1.45; }
.acd-item-price { font-weight: 700; font-size: 14px; color: #111827; white-space: nowrap; }
.acd-item-remove {
	border: none;
	background: none;
	color: #9ca3af;
	font-size: 18px;
	line-height: 1;
	cursor: pointer;
	padding: 2px 4px;
}
.acd-item-remove:hover { color: #e11d48; }

.acd-foot {
	border-top: 1px solid #e5e7eb;
	padding: 14px 18px 16px;
	background: #fafafa;
}
.acd-subtotal-row { display: flex; justify-content: space-between; align-items: baseline; }
.acd-subtotal-label { font-size: 13px; color: #6b7280; font-weight: 600; text-transform: uppercase; letter-spacing: 0.04em; }
.acd-subtotal { font-size: 19px; font-weight: 800; color: #111827; }
.acd-tax-note { margin: 4px 0 10px; font-size: 11.5px; color: #9ca3af; }
.acd-checkout {
	width: 100%;
	padding: 12px;
	border: none;
	border-radius: 6px;
	background: #1f2937;
	color: #fff;
	font-size: 15px;
	font-weight: 700;
	cursor: pointer;
	transition: background 0.15s;
}
.acd-checkout:hover { background: #111827; }
.acd-checkout[disabled] { background: #d1d5db; cursor: not-allowed; }
.acd-continue {
	display: block;
	margin-top: 10px;
	text-align: center;
	font-size: 13px;
	color: #6b7280;
	text-decoration: underline;
	cursor: pointer;
}
.acd-continue:hover { color: #111827; }

.acd-toast {
	position: fixed;
	right: 22px;
	bottom: 90px;
	z-index: 100001;
	background: #111827;
	color: #fff;
	font-size: 13px;
	padding: 8px 14px;
	border-radius: 6px;
	box-shadow: 0 4px 14px rgba(15, 23, 42, 0.3);
	opacity: 0;
	transition: opacity 0.2s;
}
.acd-toast.acd-visible { opacity: 1; }

/* Thin visible scrollbar for the item list (same treatment as BU site). */
.acd-body {
	scrollbar-width: thin;
	scrollbar-color: #b6bec9 #eef1f5;
}
.acd-body::-webkit-scrollbar { width: 8px; }
.acd-body::-webkit-scrollbar-thumb { background: #b6bec9; border-radius: 4px; }
.acd-body::-webkit-scrollbar-track { background: #eef1f5; border-radius: 4px; }
