/* Candacy chat widget. Uses the Go Antigua theme tokens when present. */

.candacy {
	--c-ink: var(--ink, #0A2A33);
	--c-accent: var(--accent, #F5B83D);
	--c-surface: var(--surface-alt, #EEF6F6);
	--c-border: var(--border, #E1ECEE);
	--c-text: var(--text, #1D3A42);
	--c-muted: var(--muted, #3D5C65);
	position: fixed;
	right: 20px;
	bottom: 20px;
	z-index: 1050;
	font-family: var(--font-body, system-ui, sans-serif);
	font-size: 15px;
	line-height: 1.5;
	color: var(--c-text);
}

/* Keep Google's reCAPTCHA badge (booking form) clear of the launcher. */
.grecaptcha-badge {
	bottom: 86px !important;
}

.candacy .candacy__launcher {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	min-height: 52px;
	padding: 0 20px;
	border: 0;
	border-radius: 999px;
	background: var(--c-ink);
	color: #fff;
	font: inherit;
	font-weight: 700;
	box-shadow: 0 12px 30px rgba(10, 42, 51, .28);
	cursor: pointer;
}

.candacy .candacy__launcher:hover,
.candacy .candacy__launcher:focus-visible {
	background: var(--teal, #0B6E79);
	color: #fff;
}

.candacy .candacy__launcher-dot {
	width: 10px;
	height: 10px;
	border-radius: 50%;
	background: var(--c-accent);
}

.candacy.is-open .candacy__launcher {
	display: none;
}

.candacy .candacy__panel {
	display: flex;
	flex-direction: column;
	width: min(380px, calc(100vw - 24px));
	height: min(600px, calc(100vh - 40px));
	overflow: hidden;
	border-radius: 20px;
	background: #fff;
	box-shadow: 0 24px 60px rgba(10, 42, 51, .3);
}

.candacy .candacy__panel[hidden] {
	display: none;
}

.candacy .candacy__head {
	display: flex;
	align-items: center;
	justify-content: space-between;
	padding: 14px 16px;
	background: var(--c-ink);
	color: #fff;
}

.candacy .candacy__head strong {
	display: block;
	font-family: var(--font-heading, inherit);
	font-size: 17px;
}

.candacy .candacy__head span {
	display: block;
	color: var(--on-dark, #CFE3E6);
	font-size: 13px;
}

.candacy .candacy__close {
	width: 40px;
	height: 40px;
	padding: 0;
	border: 0;
	border-radius: 10px;
	background: rgba(255, 255, 255, .1);
	color: #fff;
	font-size: 24px;
	line-height: 1;
	cursor: pointer;
}

.candacy .candacy__test {
	margin: 0;
	padding: 6px 16px;
	background: #FFF4D6;
	color: #6B4E00;
	font-size: 12px;
	font-weight: 700;
}

.candacy .candacy__log {
	flex: 1;
	padding: 14px;
	overflow-y: auto;
	background: var(--c-surface);
}

.candacy .candacy__msg {
	max-width: 88%;
	margin: 0 0 10px;
	padding: 10px 13px;
	border-radius: 14px;
	overflow-wrap: anywhere;
}

.candacy .candacy__msg p {
	margin: 0 0 6px;
}

.candacy .candacy__msg p:last-child {
	margin-bottom: 0;
}

.candacy .candacy__msg ul {
	margin: 4px 0 6px;
	padding-left: 18px;
}

.candacy .candacy__msg--bot {
	border: 1px solid var(--c-border);
	border-bottom-left-radius: 4px;
	background: #fff;
}

.candacy .candacy__msg--user {
	margin-left: auto;
	border-bottom-right-radius: 4px;
	background: var(--c-ink);
	color: #fff;
}

.candacy .candacy__msg a {
	color: var(--teal, #0B6E79);
	font-weight: 700;
}

.candacy .candacy__msg.is-typing {
	color: var(--c-muted);
}

.candacy .candacy__options {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 0 0 10px;
}

.candacy .candacy__options button {
	min-height: 36px;
	padding: 6px 12px;
	border: 1px solid var(--teal, #0B6E79);
	border-radius: 999px;
	background: #fff;
	color: var(--teal, #0B6E79);
	font: inherit;
	font-size: 13px;
	font-weight: 700;
	line-height: 1.2;
	text-transform: none;
	letter-spacing: 0;
	cursor: pointer;
}

.candacy .candacy__options button:hover,
.candacy .candacy__options button:focus-visible {
	background: var(--teal, #0B6E79);
	color: #fff;
}

.candacy .candacy__handoff {
	display: block;
	padding: 9px 16px;
	border-top: 1px solid var(--c-border);
	background: #fff;
	color: var(--teal, #0B6E79);
	font-size: 14px;
	font-weight: 700;
	text-align: center;
	text-decoration: none;
}

.candacy .candacy__form {
	display: flex;
	gap: 8px;
	padding: 10px;
	border-top: 1px solid var(--c-border);
	background: #fff;
}

.candacy .candacy__form textarea {
	flex: 1;
	min-height: 44px;
	max-height: 120px;
	padding: 10px 12px;
	border: 1px solid var(--border-field, #CFE0E2);
	border-radius: 12px;
	background: var(--field, #F6FAFA);
	color: var(--c-text);
	font: inherit;
	resize: none;
}

.candacy .candacy__form button {
	min-width: 72px;
	min-height: 44px;
	padding: 0 14px;
	border: 0;
	border-radius: 12px;
	background: var(--c-accent);
	color: var(--c-ink);
	font: inherit;
	font-weight: 700;
	cursor: pointer;
}

.candacy .candacy__form button:disabled {
	opacity: .6;
	cursor: default;
}

.candacy .candacy__note {
	margin: 0;
	padding: 0 12px 10px;
	background: #fff;
	color: var(--c-muted);
	font-size: 12px;
}

@media (max-width: 600px) {
	.candacy {
		right: 12px;
		bottom: 12px;
	}

	.candacy.is-open {
		inset: 0;
	}

	.candacy.is-open .candacy__panel {
		width: 100%;
		height: 100%;
		border-radius: 0;
	}
}

@media (prefers-reduced-motion: no-preference) {
	.candacy .candacy__panel:not([hidden]) {
		animation: candacy-in 180ms ease-out;
	}

	@keyframes candacy-in {
		from {
			opacity: 0;
			transform: translateY(8px);
		}
	}
}
