/**
 * Floating contact FAB — Shikeri-style.
 */

.contact-fab {
	--fab-primary: #7b1e1e;
	--fab-primary-dark: #5a1515;
	--fab-text: #2d2d2d;
	--fab-inset-x: 1.25rem;
	--fab-bottom: 1.5rem;
	--fab-mobile-inset-x: 1rem;
	--fab-mobile-bottom: 1rem;
	position: fixed;
	bottom: var(--fab-bottom);
	z-index: 900;
}

.contact-fab--left {
	left: var(--fab-inset-x);
	right: auto;
}

.contact-fab--right {
	right: var(--fab-inset-x);
	left: auto;
}

.contact-fab__toggle {
	display: flex;
	align-items: center;
	justify-content: center;
	position: relative;
	width: 3.25rem;
	height: 3.25rem;
	padding: 0;
	border: none;
	border-radius: 50%;
	background: var(--fab-toggle-bg, var(--fab-primary));
	color: #fff;
	cursor: pointer;
	box-shadow: 0 6px 20px rgba(123, 30, 30, 0.35);
	transition: transform 0.25s ease, box-shadow 0.25s ease, background 0.2s ease;
	flex-shrink: 0;
}

.contact-fab__toggle:hover,
.contact-fab__toggle:focus-visible {
	background: var(--fab-toggle-bg-hover, var(--fab-primary-dark));
	transform: translateY(-2px);
	box-shadow: 0 8px 24px rgba(123, 30, 30, 0.42);
	outline: none;
}

.contact-fab.is-open .contact-fab__toggle {
	background: var(--fab-toggle-bg-hover, var(--fab-primary-dark));
}

.contact-fab__toggle-icon {
	width: 1.5rem;
	height: 1.5rem;
	transition: opacity 0.2s ease, transform 0.25s ease;
}

.contact-fab__toggle-icon--close {
	position: absolute;
	opacity: 0;
	transform: rotate(-90deg) scale(0.6);
}

.contact-fab__toggle-icon--open {
	opacity: 1;
	transform: rotate(0) scale(1);
}

.contact-fab.is-open .contact-fab__toggle-icon--open {
	opacity: 0;
	transform: rotate(90deg) scale(0.6);
}

.contact-fab.is-open .contact-fab__toggle-icon--close {
	opacity: 1;
	transform: rotate(0) scale(1);
}

.contact-fab__panel {
	position: absolute;
	bottom: calc(100% + 0.875rem);
	width: min(17.5rem, calc(100vw - 2.5rem));
	background: #fff;
	border-radius: 1rem;
	box-shadow: 0 12px 40px rgba(45, 45, 45, 0.16);
	overflow: hidden;
	transform: translateY(1.25rem) scale(0.92);
	opacity: 0;
	visibility: hidden;
	pointer-events: none;
	transition:
		transform 0.38s cubic-bezier(0.34, 1.2, 0.64, 1),
		opacity 0.28s ease,
		visibility 0.28s ease;
}

.contact-fab--left .contact-fab__panel {
	left: 0;
	right: auto;
	transform-origin: bottom left;
}

.contact-fab--right .contact-fab__panel {
	right: 0;
	left: auto;
	transform-origin: bottom right;
}

.contact-fab.is-open .contact-fab__panel {
	transform: translateY(0) scale(1);
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}

.contact-fab__item {
	display: flex;
	align-items: center;
	gap: 0.875rem;
	padding: 0.9375rem 1.125rem;
	color: inherit;
	text-decoration: none;
	border-bottom: 1px solid rgba(123, 30, 30, 0.1);
	transition: background 0.2s ease;
	width: 100%;
	box-sizing: border-box;
	background: transparent;
	border-top: 0;
	border-left: 0;
	border-right: 0;
	font: inherit;
	text-align: left;
	cursor: pointer;
}

.contact-fab__item:last-child {
	border-bottom: none;
}

.contact-fab__item:hover {
	background: rgba(123, 30, 30, 0.04);
	color: inherit;
}

.contact-fab__icon {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 2.25rem;
	height: 2.25rem;
	flex-shrink: 0;
	background: #fce8e6;
	border-radius: 0.5rem;
	color: var(--fab-primary);
}

.contact-fab__icon svg {
	width: 1.125rem;
	height: 1.125rem;
}

.contact-fab__text {
	display: flex;
	flex-direction: column;
	gap: 0.125rem;
	min-width: 0;
}

.contact-fab__label {
	font-size: 0.9375rem;
	font-weight: 600;
	color: var(--fab-text);
	line-height: 1.2;
}

.contact-fab__detail {
	font-size: 0.8125rem;
	font-weight: 600;
	color: var(--fab-primary);
	line-height: 1.25;
	word-break: break-word;
}

.contact-fab.is-open .contact-fab__item {
	animation: suyeswp-contact-fab-item-in 0.4s cubic-bezier(0.34, 1.1, 0.64, 1) both;
}

.contact-fab.is-open .contact-fab__item:nth-child(1) { animation-delay: 0.04s; }
.contact-fab.is-open .contact-fab__item:nth-child(2) { animation-delay: 0.08s; }
.contact-fab.is-open .contact-fab__item:nth-child(3) { animation-delay: 0.12s; }
.contact-fab.is-open .contact-fab__item:nth-child(4) { animation-delay: 0.16s; }

@keyframes suyeswp-contact-fab-item-in {
	from {
		opacity: 0;
		transform: translateY(0.75rem);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

/* Mobile position / offsets (independent from desktop) */
@media (max-width: 767px) {
	.contact-fab {
		bottom: var(--fab-mobile-bottom);
	}

	.contact-fab--mobile-left {
		left: var(--fab-mobile-inset-x);
		right: auto;
	}

	.contact-fab--mobile-right {
		right: var(--fab-mobile-inset-x);
		left: auto;
	}

	.contact-fab--mobile-left .contact-fab__panel {
		left: 0;
		right: auto;
		transform-origin: bottom left;
	}

	.contact-fab--mobile-right .contact-fab__panel {
		right: 0;
		left: auto;
		transform-origin: bottom right;
	}

	.contact-fab__toggle {
		width: 3rem;
		height: 3rem;
	}
}
