:root {
	--fcp-primary: #7f54b3;
	--fcp-badge: #e63946;
	--fcp-panel-bg: #ffffff;
	--fcp-text: #1d1d1d;
	--fcp-bubble-width: 58px;
	--fcp-bubble-height: 58px;
}

#fcp-root {
	position: fixed;
	bottom: 24px;
	z-index: 99999;
	font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}
#fcp-root.fcp-pos-right { right: 24px; }
#fcp-root.fcp-pos-left { left: 24px; }

#fcp-bubble {
	position: relative;
	width: var(--fcp-bubble-width);
	height: var(--fcp-bubble-height);
	border-radius: 50%;
	background: var(--fcp-primary);
	color: #fff;
	border: none;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	box-shadow: 0 4px 16px rgba(0,0,0,.25);
	transition: transform .2s ease;
}
#fcp-bubble:hover { transform: scale(1.06); }
#fcp-bubble.fcp-bounce { animation: fcp-bounce .5s ease; }

.fcp-bubble-icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: calc(min(var(--fcp-bubble-width), var(--fcp-bubble-height)) * 0.45);
	height: calc(min(var(--fcp-bubble-width), var(--fcp-bubble-height)) * 0.45);
	flex-shrink: 0;
}
.fcp-bubble-icon svg {
	width: 100%;
	height: 100%;
}

@keyframes fcp-bounce {
	0% { transform: scale(1); }
	30% { transform: scale(1.25); }
	60% { transform: scale(0.92); }
	100% { transform: scale(1); }
}

.fcp-badge {
	position: absolute;
	top: -4px;
	right: -4px;
	background: var(--fcp-badge);
	color: #fff;
	font-size: 12px;
	font-weight: 700;
	min-width: 20px;
	height: 20px;
	border-radius: 10px;
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 0 5px;
	box-shadow: 0 0 0 2px #fff;
}
.fcp-hidden { display: none !important; }

#fcp-overlay {
	position: fixed;
	inset: 0;
	background: rgba(0,0,0,.4);
	opacity: 0;
	pointer-events: none;
	transition: opacity .25s ease;
	z-index: 99998;
}
#fcp-root.fcp-open #fcp-overlay {
	opacity: 1;
	pointer-events: auto;
}

#fcp-panel {
	position: fixed;
	top: 0;
	right: -420px;
	width: 400px;
	max-width: 92vw;
	height: 100%;
	background: var(--fcp-panel-bg);
	color: var(--fcp-text);
	box-shadow: -6px 0 24px rgba(0,0,0,.15);
	display: flex;
	flex-direction: column;
	transition: right .3s cubic-bezier(.2,.8,.2,1);
	z-index: 99999;
}
#fcp-root.fcp-pos-left #fcp-panel {
	right: auto;
	left: -420px;
	box-shadow: 6px 0 24px rgba(0,0,0,.15);
	transition: left .3s cubic-bezier(.2,.8,.2,1);
}
#fcp-root.fcp-open #fcp-panel { right: 0; }
#fcp-root.fcp-pos-left.fcp-open #fcp-panel { left: 0; right: auto; }

.fcp-panel-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 18px 20px;
	border-bottom: 1px solid #eee;
}
.fcp-panel-header h3 { margin: 0; font-size: 18px; }
#fcp-close {
	background: none;
	border: none;
	font-size: 26px;
	line-height: 1;
	cursor: pointer;
	color: var(--fcp-text);
}

.fcp-free-shipping {
	padding: 12px 20px 0;
}
.fcp-fs-text { font-size: 13px; margin-bottom: 6px; }
.fcp-fs-bar {
	height: 6px;
	border-radius: 3px;
	background: #eee;
	overflow: hidden;
}
.fcp-fs-bar-fill {
	height: 100%;
	background: var(--fcp-primary);
	transition: width .35s ease;
}

.fcp-items {
	flex: 1;
	overflow-y: auto;
	padding: 12px 20px;
}
.fcp-loading { display: flex; justify-content: center; padding: 40px 0; }
.fcp-spinner {
	width: 28px; height: 28px;
	border: 3px solid #eee;
	border-top-color: var(--fcp-primary);
	border-radius: 50%;
	animation: fcp-spin .7s linear infinite;
	display: inline-block;
}
@keyframes fcp-spin { to { transform: rotate(360deg); } }

.fcp-empty { text-align: center; padding: 40px 10px; opacity: .7; font-size: 14px; }

.fcp-cart-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 12px 0;
	border-bottom: 1px solid #f0f0f0;
	animation: fcp-fade-in .25s ease;
}
@keyframes fcp-fade-in { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: translateY(0); } }

.fcp-item-thumb img { width: 56px; height: 56px; object-fit: cover; border-radius: 6px; }
.fcp-item-info { flex: 1; display: flex; flex-direction: column; gap: 4px; min-width: 0; }
.fcp-item-name { font-size: 13.5px; font-weight: 600; line-height: 1.3; }
.fcp-item-price { font-size: 12.5px; opacity: .7; }

.fcp-qty-stepper { display: flex; align-items: center; gap: 8px; margin-top: 2px; }
.fcp-qty-btn {
	width: 24px; height: 24px;
	border-radius: 4px;
	border: 1px solid #ddd;
	background: #fafafa;
	cursor: pointer;
	font-size: 14px;
	line-height: 1;
	display: flex; align-items: center; justify-content: center;
}
.fcp-qty-btn:disabled { opacity: .4; cursor: not-allowed; }
.fcp-qty-value { min-width: 18px; text-align: center; font-size: 13px; }

.fcp-item-remove {
	background: none; border: none; font-size: 20px; opacity: .5; cursor: pointer; color: var(--fcp-text);
}
.fcp-item-remove:hover { opacity: 1; }

.fcp-upsells { border-top: 1px solid #eee; padding: 14px 20px; }
.fcp-upsells-title { font-size: 13px; font-weight: 600; margin: 0 0 10px; opacity: .8; }
.fcp-upsells-list { display: flex; gap: 10px; overflow-x: auto; padding-bottom: 4px; }
.fcp-upsell-card {
	flex: 0 0 110px;
	position: relative;
	border: 1px solid #eee;
	border-radius: 8px;
	padding: 8px;
	text-align: center;
}
.fcp-upsell-thumb img { width: 100%; height: 70px; object-fit: cover; border-radius: 4px; }
.fcp-upsell-name {
	display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
	overflow: hidden;
	font-size: 11.5px;
	font-weight: 600;
	margin-top: 6px;
	color: var(--fcp-text);
	text-decoration: none;
}
.fcp-upsell-price { font-size: 11px; opacity: .7; display: block; margin-top: 2px; }
.fcp-upsell-add {
	position: absolute;
	top: 6px; right: 6px;
	width: 22px; height: 22px;
	border-radius: 50%;
	border: none;
	background: var(--fcp-primary);
	color: #fff;
	cursor: pointer;
	font-size: 15px;
	line-height: 1;
}

.fcp-panel-footer {
	padding: 16px 20px 20px;
	border-top: 1px solid #eee;
}
.fcp-total-row {
	display: flex;
	justify-content: space-between;
	font-size: 16px;
	font-weight: 700;
	margin-bottom: 12px;
}
.fcp-btn {
	display: block;
	text-align: center;
	padding: 12px;
	border-radius: 6px;
	text-decoration: none;
	font-weight: 600;
	font-size: 14px;
	margin-bottom: 8px;
	transition: opacity .2s ease;
}
.fcp-btn:hover { opacity: .85; }
.fcp-btn-primary { background: var(--fcp-primary); color: #fff; }
.fcp-btn-outline { background: transparent; color: var(--fcp-text); border: 1px solid #ddd; }

@media (max-width: 480px) {
	#fcp-panel { width: 100vw; max-width: 100vw; }
	#fcp-root.fcp-pos-right, #fcp-root.fcp-pos-left { right: 16px; left: auto; bottom: 16px; }
}
