/* Chatcom Service Savings Audit */

:root {
	--fc-ink: #0a0a0a;
	--fc-navy: #1c244b;
	--fc-text: #324a6d;
	--fc-muted: #5a6f8a;
	--fc-accent: #467ff7;
	--fc-accent-dark: #3468d9;
	--fc-offwhite: #f4f4f2;
	--fc-line: rgba(28, 36, 75, 0.1);
	--fc-shadow: 0 -8px 40px rgba(18, 24, 47, 0.16);
	--fc-ease: cubic-bezier(0.22, 1, 0.36, 1);
	--fc-dock-h: 64px;
	--fc-radius: 16px;
}

.chatcom-fc {
	font-family: "Poppins", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
	-webkit-font-smoothing: antialiased;
}

/* ---------- Closed dock ---------- */

.chatcom-fc__dock {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 99999;
	background: linear-gradient(105deg, #0f1733 0%, #1c244b 42%, #2f5bd8 78%, #467ff7 100%);
	background-size: 200% 100%;
	animation: chatcom-fc-dock-shine 7s ease-in-out infinite;
	color: #fff;
	box-shadow:
		0 -10px 40px rgba(18, 24, 47, 0.28),
		0 0 0 1px rgba(255, 255, 255, 0.08) inset;
	border-top: 1px solid rgba(255, 255, 255, 0.14);
	transform: translateY(0);
	transition: transform 0.35s var(--fc-ease), box-shadow 0.3s ease;
	cursor: pointer;
}

.chatcom-fc__dock::before {
	content: "";
	position: absolute;
	inset: 0;
	pointer-events: none;
	background: linear-gradient(
		110deg,
		transparent 30%,
		rgba(255, 255, 255, 0.14) 48%,
		transparent 62%
	);
	transform: translateX(-120%);
	animation: chatcom-fc-sheen 3.8s ease-in-out infinite;
}

.chatcom-fc__dock.is-nudge {
	animation:
		chatcom-fc-dock-shine 7s ease-in-out infinite,
		chatcom-fc-nudge 0.7s var(--fc-ease) 2;
}

.chatcom-fc.is-open .chatcom-fc__dock {
	transform: translateY(110%);
	pointer-events: none;
}

.chatcom-fc__dock-inner {
	position: relative;
	z-index: 1;
	max-width: 1120px;
	margin: 0 auto;
	min-height: var(--fc-dock-h);
	padding: 12px 18px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
}

.chatcom-fc__dock-copy {
	margin: 0;
	font-size: 15px;
	font-weight: 600;
	letter-spacing: -0.015em;
	line-height: 1.35;
	color: #fff;
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}

.chatcom-fc__badge {
	display: inline-flex;
	align-items: center;
	margin-right: 10px;
	padding: 4px 10px;
	border-radius: 999px;
	background: #ffe566;
	color: #12182f;
	font-size: 11px;
	font-weight: 700;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	vertical-align: 2px;
	box-shadow: 0 0 0 0 rgba(255, 229, 102, 0.55);
	animation: chatcom-fc-badge-glow 1.8s ease-out infinite;
}

@keyframes chatcom-fc-badge-glow {
	0% {
		box-shadow: 0 0 0 0 rgba(255, 229, 102, 0.55);
	}
	70% {
		box-shadow: 0 0 0 10px rgba(255, 229, 102, 0);
	}
	100% {
		box-shadow: 0 0 0 0 rgba(255, 229, 102, 0);
	}
}

.chatcom-fc__bolt {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 28px;
	height: 28px;
	margin-right: 8px;
	border-radius: 999px;
	background: rgba(255, 220, 80, 0.2);
	box-shadow: 0 0 0 0 rgba(255, 214, 70, 0.55);
	animation: chatcom-fc-bolt-pulse 1.8s ease-out infinite;
	vertical-align: -6px;
}

button.chatcom-fc__dock-btn,
button.chatcom-fc__submit {
	appearance: none !important;
	border: 0 !important;
	cursor: pointer;
	border-radius: 999px !important;
	background: #fff !important;
	color: var(--fc-navy) !important;
	font: inherit;
	font-size: 14px !important;
	font-weight: 700 !important;
	letter-spacing: -0.01em;
	padding: 12px 20px !important;
	white-space: nowrap;
	width: auto !important;
	box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22) !important;
	transition: transform 0.2s var(--fc-ease), background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease;
	animation: chatcom-fc-btn-pulse 2.2s ease-in-out infinite;
}

button.chatcom-fc__dock-btn:hover,
button.chatcom-fc__dock-btn:focus-visible {
	background: #ffe566 !important;
	color: #12182f !important;
	transform: translateY(-2px) scale(1.03);
	box-shadow: 0 10px 24px rgba(0, 0, 0, 0.28) !important;
	outline: none;
	animation: none;
}

button.chatcom-fc__submit {
	animation: none;
	background: var(--fc-accent) !important;
	color: #fff !important;
	width: 100% !important;
}

button.chatcom-fc__submit:hover,
button.chatcom-fc__submit:focus-visible {
	background: var(--fc-accent-dark) !important;
	color: #fff !important;
	transform: translateY(-1px);
}

@keyframes chatcom-fc-dock-shine {
	0%,
	100% {
		background-position: 0% 50%;
	}
	50% {
		background-position: 100% 50%;
	}
}

@keyframes chatcom-fc-sheen {
	0%,
	55%,
	100% {
		transform: translateX(-120%);
	}
	70% {
		transform: translateX(120%);
	}
}

@keyframes chatcom-fc-bolt-pulse {
	0% {
		box-shadow: 0 0 0 0 rgba(255, 214, 70, 0.55);
	}
	70% {
		box-shadow: 0 0 0 12px rgba(255, 214, 70, 0);
	}
	100% {
		box-shadow: 0 0 0 0 rgba(255, 214, 70, 0);
	}
}

@keyframes chatcom-fc-btn-pulse {
	0%,
	100% {
		transform: scale(1);
		box-shadow: 0 6px 18px rgba(0, 0, 0, 0.22);
	}
	50% {
		transform: scale(1.04);
		box-shadow: 0 10px 26px rgba(70, 127, 247, 0.45);
	}
}

@keyframes chatcom-fc-nudge {
	0%,
	100% {
		transform: translateY(0);
	}
	30% {
		transform: translateY(-8px);
	}
	60% {
		transform: translateY(-2px);
	}
}

/* Keep page content clear of the dock */
body:has(.chatcom-fc) {
	padding-bottom: calc(var(--fc-dock-h) + 12px);
}

/* Lift WhatsApp + cookie revisit above the dock */
body:has(.chatcom-fc) .chatcom-whatsapp {
	bottom: calc(var(--fc-dock-h) + 18px) !important;
}

body:has(.chatcom-fc) .cky-btn-revisit-wrapper,
body:has(.chatcom-fc) .cookieadmin-revisit {
	bottom: calc(var(--fc-dock-h) + 18px) !important;
}

body.chatcom-fc-open {
	overflow: hidden;
}

/* ---------- Overlay + drawer ---------- */

.chatcom-fc__scrim {
	position: fixed;
	inset: 0;
	z-index: 100000;
	background: rgba(10, 12, 24, 0.52);
	opacity: 0;
	pointer-events: none;
	transition: opacity 0.3s ease;
}

.chatcom-fc.is-open .chatcom-fc__scrim {
	opacity: 1;
	pointer-events: auto;
}

.chatcom-fc__drawer {
	position: fixed;
	left: 0;
	right: 0;
	bottom: 0;
	z-index: 100001;
	max-height: min(92vh, 860px);
	background: var(--fc-offwhite);
	border-radius: 22px 22px 0 0;
	box-shadow: 0 -20px 60px rgba(0, 0, 0, 0.28);
	transform: translateY(105%);
	transition: transform 0.4s var(--fc-ease);
	display: flex;
	flex-direction: column;
	overflow: hidden;
}

.chatcom-fc.is-open .chatcom-fc__drawer {
	transform: translateY(0);
}

.chatcom-fc__drawer[hidden],
.chatcom-fc__scrim[hidden] {
	display: block !important;
}

.chatcom-fc__drawer-head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 16px;
	padding: 20px 22px 12px;
	border-bottom: 1px solid var(--fc-line);
	background: rgba(255, 255, 255, 0.72);
}

.chatcom-fc__eyebrow {
	margin: 0 0 4px;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--fc-accent);
}

.chatcom-fc__title {
	margin: 0;
	font-size: clamp(20px, 2.4vw, 28px);
	font-weight: 600;
	letter-spacing: -0.03em;
	color: var(--fc-navy);
	line-height: 1.15;
}

.chatcom-fc__close {
	width: 40px;
	height: 40px;
	border: 0;
	border-radius: 999px;
	background: rgba(28, 36, 75, 0.06);
	color: var(--fc-navy);
	font-size: 28px;
	line-height: 1;
	cursor: pointer;
	flex-shrink: 0;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background 0.2s ease;
}

.chatcom-fc__close:hover,
.chatcom-fc__close:focus-visible {
	background: rgba(28, 36, 75, 0.12);
	outline: none;
}

.chatcom-fc__drawer-body {
	padding: 18px 22px 28px;
	overflow-y: auto;
	-webkit-overflow-scrolling: touch;
}

.chatcom-fc__grid {
	display: grid;
	grid-template-columns: minmax(0, 1.35fr) minmax(260px, 0.9fr);
	gap: 18px;
	align-items: start;
}

.chatcom-fc__controls,
.chatcom-fc__results,
.chatcom-fc__form {
	background: #fff;
	border: 1px solid var(--fc-line);
	border-radius: var(--fc-radius);
	padding: 18px;
}

.chatcom-fc__field {
	display: block;
	margin-bottom: 18px;
}

.chatcom-fc__field:last-child {
	margin-bottom: 0;
}

.chatcom-fc__label {
	display: flex;
	align-items: baseline;
	justify-content: space-between;
	gap: 12px;
	margin-bottom: 10px;
	font-size: 13px;
	font-weight: 500;
	color: var(--fc-text);
}

.chatcom-fc__label strong {
	color: var(--fc-navy);
	font-weight: 600;
	font-variant-numeric: tabular-nums;
}

.chatcom-fc__field input[type="range"] {
	width: 100%;
	accent-color: var(--fc-accent);
	cursor: pointer;
}

.chatcom-fc__ticks {
	display: flex;
	justify-content: space-between;
	margin-top: 6px;
	font-size: 11px;
	color: var(--fc-muted);
}

.chatcom-fc__spend {
	display: flex;
	align-items: center;
	gap: 8px;
	border: 1px solid var(--fc-line);
	border-radius: 12px;
	padding: 10px 12px;
	background: var(--fc-offwhite);
}

.chatcom-fc__spend span {
	font-weight: 600;
	color: var(--fc-navy);
}

.chatcom-fc__spend input,
.chatcom-fc__form input {
	width: 100%;
	border: 0;
	background: transparent;
	font: inherit;
	font-size: 16px;
	color: var(--fc-ink);
	outline: none;
}

.chatcom-fc__form input {
	border: 1px solid var(--fc-line);
	border-radius: 12px;
	background: var(--fc-offwhite);
	padding: 12px 14px;
	transition: border-color 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

.chatcom-fc__form input:focus {
	border-color: var(--fc-accent);
	background: #fff;
	box-shadow: 0 0 0 3px rgba(70, 127, 247, 0.16);
}

.chatcom-fc__results {
	display: grid;
	gap: 12px;
	background: transparent;
	border: 0;
	padding: 0;
}

.chatcom-fc__result-card {
	background: #fff;
	border: 1px solid var(--fc-line);
	border-radius: var(--fc-radius);
	padding: 18px;
}

.chatcom-fc__result-card--savings {
	background: linear-gradient(160deg, #1c244b 0%, #2a3a7a 100%);
	color: #fff;
	border: 0;
}

.chatcom-fc__result-label {
	margin: 0 0 6px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: var(--fc-muted);
}

.chatcom-fc__result-card--savings .chatcom-fc__result-label {
	color: rgba(255, 255, 255, 0.72);
}

.chatcom-fc__result-value {
	margin: 0;
	font-size: clamp(28px, 4vw, 36px);
	font-weight: 600;
	letter-spacing: -0.03em;
	color: var(--fc-navy);
	font-variant-numeric: tabular-nums;
}

.chatcom-fc__result-card--savings .chatcom-fc__result-value {
	color: #fff;
}

.chatcom-fc__result-value small {
	font-size: 0.45em;
	font-weight: 500;
	margin-left: 2px;
	color: var(--fc-muted);
}

.chatcom-fc__result-card--savings .chatcom-fc__result-value small {
	color: rgba(255, 255, 255, 0.7);
}

.chatcom-fc__breakdown {
	list-style: none;
	margin: 14px 0 0;
	padding: 14px 0 0;
	border-top: 1px solid var(--fc-line);
	display: grid;
	gap: 8px;
}

.chatcom-fc__breakdown li {
	display: flex;
	justify-content: space-between;
	gap: 12px;
	font-size: 13px;
	color: var(--fc-text);
}

.chatcom-fc__hint {
	margin: 8px 0 0;
	font-size: 12px;
	line-height: 1.45;
	color: rgba(255, 255, 255, 0.78);
}

.chatcom-fc__form {
	margin-top: 18px;
}

.chatcom-fc__form-title {
	margin: 0 0 14px;
	font-size: 15px;
	font-weight: 600;
	color: var(--fc-navy);
	letter-spacing: -0.02em;
}

.chatcom-fc__form-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 12px;
	margin-bottom: 14px;
}

.chatcom-fc__form label {
	display: grid;
	gap: 6px;
	font-size: 12px;
	font-weight: 500;
	color: var(--fc-text);
}

.chatcom-fc__submit {
	width: 100%;
	background: var(--fc-accent);
	color: #fff;
	padding: 14px 18px;
	font-size: 14px;
}

.chatcom-fc__submit:hover,
.chatcom-fc__submit:focus-visible {
	background: var(--fc-accent-dark);
	transform: translateY(-1px);
	outline: none;
}

.chatcom-fc__submit:disabled {
	opacity: 0.7;
	cursor: wait;
	transform: none;
}

.chatcom-fc__form-msg {
	margin: 12px 0 0;
	font-size: 13px;
	line-height: 1.45;
}

.chatcom-fc__form-msg.is-success {
	color: #0f7a3c;
}

.chatcom-fc__form-msg.is-error {
	color: #b42318;
}

@media (max-width: 900px) {
	.chatcom-fc__grid {
		grid-template-columns: 1fr;
	}

	.chatcom-fc__form-grid {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 700px) {
	:root {
		--fc-dock-h: auto;
	}

	.chatcom-fc__dock-inner {
		flex-direction: column;
		align-items: stretch;
		padding: 12px 14px;
		gap: 10px;
	}

	.chatcom-fc__dock-copy {
		font-size: 13px;
		text-align: center;
	}

	.chatcom-fc__dock-btn {
		width: 100%;
		text-align: center;
	}

	.chatcom-fc__drawer {
		max-height: 94vh;
		border-radius: 18px 18px 0 0;
	}

	.chatcom-fc__drawer-head,
	.chatcom-fc__drawer-body {
		padding-left: 14px;
		padding-right: 14px;
	}

	body:has(.chatcom-fc) .chatcom-whatsapp {
		bottom: 110px !important;
	}
}

@media (prefers-reduced-motion: reduce) {
	.chatcom-fc__dock,
	.chatcom-fc__drawer,
	.chatcom-fc__scrim,
	.chatcom-fc__dock-btn,
	.chatcom-fc__submit,
	.chatcom-fc__bolt,
	.chatcom-fc__badge,
	.chatcom-fc__dock::before {
		transition: none !important;
		animation: none !important;
	}
}
