/*
 * Casagres footer V3.
 * Isolated light closure; the frozen header remains outside this namespace.
 */

/*
 * Global page-end contract.
 *
 * Bricks already lays out its direct body children as a vertical flex stack.
 * Only pages that actually render this footer participate: Bricks content and
 * the native Woo product main can grow on short pages, while the footer keeps
 * the same measured separation after long content. The non-:has fallback below
 * still preserves that separation.
 */
@supports selector(body:has(> .cg-site-footer--v3)) {
	body:has(> .cg-site-footer--v3) {
		min-block-size: 100vh;
		min-block-size: 100dvh;
	}

	body:has(> .cg-site-footer--v3) > :is(#brx-content, #primary) {
		flex: 1 0 auto;
	}
}

.cg-site-footer.cg-site-footer--v3 {
	background: #fafbf9;
	border-top: 0;
	color: #383d3b;
	font-family: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display", "Segoe UI", sans-serif;
	margin-block-start: clamp(32px, 4vw, 48px);
	padding-top: 28px;
}

.cg-site-footer--v3,
.cg-site-footer--v3 * {
	box-sizing: border-box;
}

.cg-site-footer--v3 .cg-site-footer-inner {
	padding-bottom: calc(22px + env(safe-area-inset-bottom, 0px));
}

.cg-site-footer--v3 .cg-footer-top {
	--cg-liquid-panel-radius: 28px;
	align-items: center;
	display: grid;
	gap: 28px;
	grid-template-columns: minmax(0, 1fr) minmax(290px, 360px);
	padding: 24px !important;
}

.cg-site-footer--v3 .cg-footer-brand {
	display: grid;
	gap: 9px;
}

.cg-site-footer--v3 .cg-footer-brand a {
	display: block;
	width: fit-content;
}

.cg-site-footer--v3 .cg-footer-brand img {
	display: block;
	filter: none !important;
	height: auto;
	max-width: none;
	width: 208px;
}

.cg-site-footer--v3 .cg-footer-brand > p {
	color: #656c69;
	font-size: 15px;
	font-weight: 400 !important;
	line-height: 1.45;
	margin: 0;
	max-width: 42ch;
}

.cg-site-footer--v3 .cg-footer-intro-actions {
	display: grid;
	gap: 9px;
	grid-template-columns: 1fr;
	width: 100%;
}

.cg-site-footer--v3 .cg-footer-whatsapp {
	align-items: center;
	background: #fff;
	border: 0;
	border-radius: 22px;
	box-shadow: 0 9px 26px rgba(28, 33, 31, 0.08);
	color: #1a1d1c !important;
	display: grid;
	gap: 14px;
	grid-template-columns: 54px minmax(0, 1fr) 20px;
	min-height: 82px;
	padding: 11px 16px 11px 13px;
	text-decoration: none !important;
	width: 100%;
}

.cg-site-footer--v3 .cg-footer-whatsapp:hover {
	background: #fff;
	box-shadow: 0 12px 30px rgba(28, 33, 31, 0.12);
	color: #1a1d1c !important;
}

.cg-site-footer--v3 .cg-footer-whatsapp:focus-visible,
.cg-site-footer--v3 .cg-footer-map:focus-visible,
.cg-site-footer--v3 .cg-footer-bottom a:focus-visible,
.cg-site-footer--v3 .cg-footer-version summary:focus-visible {
	outline: 2px solid #1a1d1c;
	outline-offset: 3px;
}

.cg-site-footer--v3 .cg-footer-whatsapp-app {
	align-items: center;
	background: linear-gradient(180deg, #00f579 0%, #00d42c 100%);
	border-radius: 15px;
	display: flex;
	height: 54px;
	justify-content: center;
	overflow: hidden;
	width: 54px;
}

.cg-site-footer--v3 .cg-footer-whatsapp-app > span {
	-webkit-mask-image: var(--cg-footer-whatsapp-mask);
	-webkit-mask-position: center;
	-webkit-mask-repeat: no-repeat;
	-webkit-mask-size: contain;
	background: #fff;
	display: block;
	height: 38px;
	mask-image: var(--cg-footer-whatsapp-mask);
	mask-position: center;
	mask-repeat: no-repeat;
	mask-size: contain;
	width: 38px;
}

.cg-site-footer--v3 .cg-footer-whatsapp-name {
	font-size: 18px;
	font-weight: 400 !important;
	line-height: 1.2;
	text-align: left;
}

.cg-site-footer--v3 .cg-footer-chevron {
	color: #8e8e93;
	height: 20px;
	width: 20px;
}

.cg-site-footer--v3 .cg-footer-map {
	align-items: center;
	color: #383d3b !important;
	display: flex;
	font-size: 14px;
	font-weight: 500 !important;
	gap: 7px;
	justify-content: flex-end;
	line-height: 1.2;
	min-height: 44px;
	padding: 0 7px;
	text-decoration: none !important;
}

.cg-site-footer--v3 .cg-footer-map:hover {
	color: #1a1d1c !important;
	text-decoration: underline !important;
	text-underline-offset: 4px;
}

.cg-site-footer--v3 .cg-footer-content {
	display: grid;
	gap: clamp(30px, 5vw, 64px);
	grid-template-columns: minmax(140px, 0.8fr) minmax(170px, 0.9fr) minmax(280px, 1.3fr);
	padding: 34px 4px 31px;
}

.cg-site-footer--v3 .cg-footer-links,
.cg-site-footer--v3 .cg-footer-contact {
	align-content: start;
	display: grid;
	gap: 13px;
}

.cg-site-footer--v3 .cg-footer-links h2,
.cg-site-footer--v3 .cg-footer-contact h2 {
	color: #656c69;
	font-size: 13px;
	font-weight: 500 !important;
	letter-spacing: 0;
	line-height: 1.2;
	margin: 0;
	text-transform: none;
}

.cg-site-footer--v3 .cg-footer-links > div {
	display: grid;
	gap: 10px;
	grid-template-columns: 1fr;
}

.cg-site-footer--v3 .cg-footer-links a,
.cg-site-footer--v3 .cg-footer-contact-direct a,
.cg-site-footer--v3 .cg-footer-content .cg-footer-contact p {
	color: #383d3b;
	font-size: 15px;
	font-weight: 400 !important;
	line-height: 1.45;
	text-decoration: none;
}

.cg-site-footer--v3 .cg-footer-links a:hover,
.cg-site-footer--v3 .cg-footer-links a:focus-visible,
.cg-site-footer--v3 .cg-footer-contact-direct a:hover,
.cg-site-footer--v3 .cg-footer-contact-direct a:focus-visible {
	color: #1a1d1c;
	text-decoration: underline;
	text-underline-offset: 4px;
}

.cg-site-footer--v3 .cg-footer-content .cg-footer-contact {
	gap: 10px;
}

.cg-site-footer--v3 .cg-footer-content .cg-footer-contact p {
	margin: 0;
	max-width: 42ch;
}

.cg-site-footer--v3 .cg-footer-contact-direct {
	display: flex;
	flex-wrap: wrap;
	gap: 7px 18px;
	padding-top: 0;
}

.cg-site-footer--v3 .cg-footer-contact-direct a {
	color: #1a1d1c;
	font-weight: 500 !important;
}

.cg-site-footer--v3 .cg-footer-bottom {
	align-items: center;
	border-top: 1px solid rgba(26, 29, 28, 0.12);
	color: #656c69;
	display: flex;
	font-size: 13px;
	gap: 18px;
	justify-content: space-between;
	line-height: 1.45;
	padding-top: 18px;
}

.cg-site-footer--v3 .cg-footer-bottom > p {
	margin: 0;
}

.cg-site-footer--v3 .cg-footer-bottom nav {
	align-items: center;
	display: flex;
	flex-wrap: wrap;
	gap: 4px 18px;
	justify-content: flex-end;
}

.cg-site-footer--v3 .cg-footer-bottom a,
.cg-site-footer--v3 .cg-footer-version summary {
	color: #4f5653;
	font-size: 13px;
	font-weight: 500 !important;
	text-decoration: none;
}

.cg-site-footer--v3 .cg-footer-bottom a:hover,
.cg-site-footer--v3 .cg-footer-bottom a:focus-visible {
	color: #1a1d1c;
}

.cg-site-footer--v3 .cg-footer-bottom .cg-footer-cancellation {
	color: #1a1d1c;
	text-decoration: underline;
	text-decoration-thickness: 1px;
	text-underline-offset: 4px;
}

.cg-site-footer--v3 .cg-footer-version {
	position: relative;
}

.cg-site-footer--v3 .cg-footer-version summary {
	align-items: center;
	cursor: pointer;
	display: inline-flex;
	gap: 5px;
	list-style: none;
	min-height: 44px;
	padding: 0 2px;
	user-select: none;
}

.cg-site-footer--v3 .cg-footer-version summary::-webkit-details-marker {
	display: none;
}

.cg-site-footer--v3 .cg-footer-version summary svg {
	height: 14px;
	transition: transform 160ms ease;
	width: 14px;
}

.cg-site-footer--v3 .cg-footer-version[open] summary svg {
	transform: rotate(180deg);
}

.cg-site-footer--v3 .cg-footer-version-menu {
	background: #fff;
	border: 1px solid rgba(26, 29, 28, 0.12);
	border-radius: 18px;
	bottom: calc(100% + 10px);
	box-shadow: 0 18px 44px rgba(28, 33, 31, 0.16);
	color: #1a1d1c;
	padding: 14px;
	position: absolute;
	right: 0;
	width: min(280px, calc(100vw - 32px));
	z-index: 5;
}

.cg-site-footer--v3 .cg-footer-version-menu strong {
	display: block;
	font-size: 12px;
	font-weight: 500 !important;
	padding: 7px 2px;
}

.cg-site-footer--v3 .cg-footer-version-menu ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

.cg-site-footer--v3 .cg-footer-version-menu li {
	border-top: 1px solid rgba(26, 29, 28, 0.1);
	color: #656c69;
	display: grid;
	font-size: 12px;
	font-weight: 400 !important;
	gap: 8px;
	grid-template-columns: 46px 1fr;
	padding: 9px 2px;
}

.cg-site-footer--v3 .cg-footer-version-menu li span {
	color: #1a1d1c;
	font-weight: 500 !important;
}

@media (max-width: 700px) {
	.cg-site-footer.cg-site-footer--v3 {
		padding-top: 20px;
	}

	.cg-site-footer--v3 .cg-site-footer-inner {
		padding-bottom: calc(24px + env(safe-area-inset-bottom, 0px));
	}

	.cg-site-footer--v3 .cg-footer-top {
		--cg-liquid-panel-radius: 28px;
		gap: 19px;
		grid-template-columns: 1fr;
		padding: 20px !important;
	}

	.cg-site-footer--v3 .cg-footer-brand img {
		width: 184px;
	}

	.cg-site-footer--v3 .cg-footer-map {
		justify-content: flex-start;
	}

	.cg-site-footer--v3 .cg-footer-intro-actions {
		grid-template-columns: 1fr !important;
	}

	.cg-site-footer--v3 .cg-footer-content {
		gap: 26px 20px;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		padding: 28px 4px;
	}

	.cg-site-footer--v3 .cg-footer-contact {
		grid-column: 1 / -1;
	}

	.cg-site-footer--v3 .cg-footer-bottom {
		align-items: flex-start;
		flex-direction: column;
		gap: 12px;
	}

	.cg-site-footer--v3 .cg-footer-bottom nav {
		justify-content: flex-start;
	}

	.cg-site-footer--v3 .cg-footer-version-menu {
		left: 0;
		right: auto;
	}
}

@media (prefers-reduced-motion: reduce) {
	.cg-site-footer--v3 .cg-footer-version summary svg {
		transition: none;
	}
}

@media print {
	.cg-site-footer--v3 .cg-footer-version-menu {
		display: none !important;
	}
}
