/**
 * Page builder: the base of every layout, on the site and in the editor.
 * Each element's own place and look come inline with the page (render.php).
 */

.bbz {
	position: relative;
	width: 100%;
	overflow-x: clip;
}

.bbz-s {
	position: relative;
	isolation: isolate;
	width: 100%;
	overflow: hidden;
	background-repeat: no-repeat;
}

.bbz-ov {
	position: absolute;
	z-index: -1;
	inset: 0;
	pointer-events: none;
}

/* The grid as wide as the screen layout in use, centred — and still centred
   when the window is narrower than it. */
.bbz-grid {
	position: relative;
	width: 1200px;
	height: 100%;
	margin-left: calc(50% - 600px);
}

@media (max-width: 1199px) {
	.bbz-grid {
		width: 960px;
		margin-left: calc(50% - 480px);
	}
}

@media (max-width: 959px) {
	.bbz-grid {
		width: 640px;
		margin-left: calc(50% - 320px);
	}
}

@media (max-width: 639px) {
	.bbz-grid {
		width: 480px;
		margin-left: calc(50% - 240px);
	}
}

@media (max-width: 479px) {
	.bbz-grid {
		width: 320px;
		margin-left: calc(50% - 160px);
	}
}

.bbz-e {
	box-sizing: border-box;
	margin: 0;
	padding: 0;
	color: #111111;
	text-decoration: none;
}

/* Only a free section places its elements by coordinates. */
.bbz-grid > .bbz-e {
	position: absolute;
}

/* A word longer than its text box widens the box instead of breaking, as
   Tilda's Zero Block does. */
.bbz-grid > .bbz-t-text {
	min-width: min-content;
}

a.bbz-e {
	display: block;
}

/*
 * Grid sections: rows of columns in the page flow (render.php, "Grid
 * sections"). Defaults only, at zero weight with :where(), so each element's,
 * row's and column's own rules always win. The wrapper, rows and columns are
 * not positioned, so an element set over the flow "in the section" is
 * measured from the section; a column holding one set "in the column" gets
 * position: relative of its own.
 */
:where(.bbz-f) {
	box-sizing: border-box;
	padding: 96px 20px;
}

:where(.bbz-wrap) {
	display: flex;
	flex-direction: column;
	row-gap: 48px;
	width: 100%;
	max-width: 1160px;
	margin: 0 auto;
}

:where(.bbz-row) {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: 32px;
	align-items: stretch;
}

:where(.bbz-col) {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 16px;
	min-width: 0;
	box-sizing: border-box;
	background-repeat: no-repeat;
}

:where(.bbz-fe) {
	position: relative;
	align-self: stretch;
	max-width: 100%;
	height: auto;
}

:where(.bbz-fe.bbz-t-button, .bbz-fe.bbz-t-icon) {
	align-self: auto;
	flex: none;
}

:where(.bbz-fe.bbz-t-video, .bbz-fe.bbz-t-gallery) {
	aspect-ratio: 16 / 9;
}

:where(.bbz-fe.bbz-t-shape) {
	height: 2px;
}

.bbz .bbz-fe .bbz-btn {
	padding: 0 32px;
	white-space: nowrap;
}

/* Text: the tag only sets the outline; the look is the element's. */
.bbz .bbz-t-text .bbz-in {
	margin: 0;
	padding: 0;
	font: inherit;
	color: inherit;
	letter-spacing: inherit;
	text-align: inherit;
	text-transform: none;
	word-wrap: break-word;
}

.bbz .bbz-t-text .bbz-in p,
.bbz .bbz-t-text .bbz-in div {
	margin: 0;
}

.bbz .bbz-t-text a {
	color: inherit;
	text-decoration: underline;
}

/* Text taken over from Tilda (class "bbz-plain-links"): its links unmarked, as there. */
.bbz .bbz-t-text.bbz-plain-links a {
	text-decoration: none;
}

.bbz-t-image,
.bbz-t-video {
	overflow: hidden;
}

.bbz-img {
	display: block;
	width: 100%;
	height: 100%;
	max-width: none;
	object-fit: cover;
}

.bbz .bbz-btn {
	display: flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	width: 100%;
	height: 100%;
	padding: 0 12px;
	font: inherit;
	letter-spacing: inherit;
	color: #ffffff;
	text-align: center;
	text-decoration: none;
	cursor: pointer;
	transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

/* A button whose label fills it, as Tilda's had: no inner padding (inc/ads-import). */
.bbz .bbz-tight .bbz-btn {
	padding: 0;
}

.bbz a.bbz-btn:active {
	transform: scale(0.98);
}

.bbz-t-video iframe,
.bbz-t-video video {
	display: block;
	width: 100%;
	height: 100%;
	border: 0;
	object-fit: cover;
}

.bbz-t-form .wpcf7 {
	width: 100%;
}

/*
 * Forms. The builder's settings come as --bbz-f-* variables on the element
 * (render.php) and are handed to the theme's own form variables (inc/cf7.css),
 * so a form keeps the site's behaviour — errors, phone flags — in any look.
 * Unset, everything falls back to the site's form.
 */
.bbz .bbz-t-form .bbs-cf7 {
	--bbs-cf7-font: var(--bbz-f-font, 'ApercuPro', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif);
	--bbs-cf7-ink: var(--bbz-f-ink, #000000);
	--bbs-cf7-field-bg: var(--bbz-f-bg, #ffffff);
	--bbs-cf7-border: var(--bbz-f-bc, #000000);
	--bbs-cf7-height: var(--bbz-f-h, 50px);
	--bbs-cf7-gap: var(--bbz-f-gap, 20px);
	--bbs-cf7-size: var(--bbz-f-size, 16px);
	--bbs-cf7-button-bg: var(--bbz-f-btn, #1cb65a);
	--bbs-cf7-button-bg-hover: var(--bbz-f-btnh, #169c4c);
	--bbs-cf7-button-ink: var(--bbz-f-btni, #ffffff);
	--bbs-cf7-button-radius: var(--bbz-f-btnr, 15px);
	--bbs-cf7-button-align: var(--bbz-f-btna, center);
	--bbs-cf7-error: var(--bbz-f-err, #b3261e);

	display: var(--bbz-f-disp, grid);
	grid-template-columns: var(--bbz-f-cols, 1fr);
	flex-direction: row;
	align-items: end;
}

/* Two columns: what needs the width takes the whole row. */
.bbz .bbz-t-form .bbs-cf7 > :is(.bbs-cf7__submit, .bbs-cf7__choice, fieldset, :has(textarea), :has(.wpcf7-acceptance), :has(input[type="file"])) {
	grid-column: 1 / -1;
}

/* The same, for a form without the theme's wrapper. */
.bbz .bbz-t-form .wpcf7-form:not(:has(.bbs-cf7)) {
	display: var(--bbz-f-disp, grid);
	grid-template-columns: var(--bbz-f-cols, 1fr);
	align-items: end;
	gap: var(--bbz-f-gap, 20px);
	color: var(--bbz-f-ink, #000000);
	font-family: var(--bbz-f-font, 'ApercuPro', -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif);
	font-size: var(--bbz-f-size, 16px);
}

.bbz .bbz-t-form .wpcf7-form:not(:has(.bbs-cf7)) > :is(p:has(textarea), p:has(.wpcf7-submit), .wpcf7-response-output, p:has(.wpcf7-acceptance)) {
	grid-column: 1 / -1;
}

/* In one row (display: flex): fields share the width, the button takes its text's. */
.bbz .bbz-t-form :is(.bbs-cf7, .wpcf7-form:not(:has(.bbs-cf7))) > * {
	flex: 1 1 0;
	min-width: 0;
}

.bbz .bbz-t-form :is(.bbs-cf7, .wpcf7-form:not(:has(.bbs-cf7))) > :is(.bbs-cf7__submit, p:has(.wpcf7-submit)) {
	flex: 0 0 auto;
}

.bbz .bbz-t-form .wpcf7-form:not(:has(.bbs-cf7)) > :is(.wpcf7-response-output, .hidden-fields-container) {
	flex-basis: 100%;
}

/* The sending spinner floats under the button instead of taking room. */
.bbz .bbz-t-form :is(.bbs-cf7__submit, p:has(.wpcf7-submit)) {
	position: relative;
	flex-wrap: nowrap;
}

.bbz .bbz-t-form .wpcf7-spinner {
	position: absolute;
	top: 100%;
	left: 50%;
	margin: 6px 0 0 -12px;
}

.bbz .bbz-t-form .wpcf7-form:not(:has(.bbs-cf7)) p {
	margin: 0;
}

.bbz .bbz-t-form .wpcf7-form:not(:has(.bbs-cf7)) label {
	display: block;
	color: var(--bbz-f-lbl, inherit);
}

.bbz .bbz-t-form .wpcf7-form:not(:has(.bbs-cf7)) .wpcf7-form-control-wrap {
	display: block;
	margin-top: 4px;
}

/* Fields, either kind of form. */
.bbz .bbz-t-form .wpcf7 :is(input[type="text"], input[type="email"], input[type="tel"], input[type="number"], input[type="url"], input[type="date"], select, textarea) {
	width: 100%;
	height: var(--bbz-f-h, 50px);
	padding-right: var(--bbz-f-px, 20px);
	padding-left: var(--bbz-f-px, 20px);
	border-color: var(--bbz-f-bc, #000000);
	border-style: solid;
	border-width: var(--bbz-f-bw, 1px);
	border-radius: var(--bbz-f-r, 0);
	background-color: var(--bbz-f-bg, #ffffff);
	color: var(--bbz-f-ink, #000000);
	font-family: inherit;
	font-size: var(--bbz-f-size, 16px);
	box-shadow: none;
}

.bbz .bbz-t-form .wpcf7 textarea {
	height: auto;
	min-height: calc(var(--bbz-f-h, 50px) * 2.4);
	padding-top: 13px;
}

.bbz .bbz-t-form .wpcf7 .iti input.iti__tel-input {
	padding-right: var(--bbz-f-px, 20px);
}

.bbz .bbz-t-form .wpcf7 ::placeholder {
	color: var(--bbz-f-ph, var(--bbz-f-ink, #000000));
	opacity: var(--bbz-f-pho, 0.5);
}

.bbz .bbz-t-form .wpcf7 :is(input, select, textarea):focus {
	outline: none;
	box-shadow: 0 0 0 2px var(--bbz-f-focus, var(--bbz-f-btn, #1cb65a));
}

.bbz .bbz-t-form :is(.bbs-cf7__label, .wpcf7-list-item label, .wpcf7-acceptance) {
	color: var(--bbz-f-lbl, inherit);
}

.bbz .bbz-t-form .wpcf7 .wpcf7-submit {
	width: var(--bbz-f-btnw, auto);
	min-width: var(--bbz-f-btnmin, var(--bbz-f-btnw, 200px));
	height: var(--bbz-f-btnhg, var(--bbz-f-h, 50px));
	padding: 0 24px;
	border: 0;
	border-radius: var(--bbz-f-btnr, 15px);
	background: var(--bbz-f-btn, #1cb65a);
	box-shadow: var(--bbz-f-btnsh, none);
	color: var(--bbz-f-btni, #ffffff);
	font-family: inherit;
	font-size: var(--bbz-f-btns, 14px);
	font-weight: var(--bbz-f-btnwt, 700);
	text-transform: var(--bbz-f-btnt, uppercase);
	white-space: var(--bbz-f-ws, normal);
	cursor: pointer;
}

.bbz .bbz-t-form .wpcf7 .wpcf7-submit:hover {
	background: var(--bbz-f-btnh, #169c4c);
}

.bbz .bbz-t-form .bbs-cf7__submit {
	justify-content: var(--bbz-f-btna, center);
}

.bbz .bbz-t-form .wpcf7-form:not(:has(.bbs-cf7)) p:has(.wpcf7-submit) {
	display: flex;
	justify-content: var(--bbz-f-btna, flex-start);
}

/* List */
.bbz .bbz-list {
	margin: 0;
	padding: 0;
	list-style: none;
	counter-reset: bbz-n;
}

.bbz .bbz-list li {
	position: relative;
	margin: 0 0 var(--bbz-gap, 10px);
	padding-left: 1.6em;
}

.bbz .bbz-list li:last-child {
	margin-bottom: 0;
}

.bbz .bbz-list li::before {
	position: absolute;
	top: 0;
	left: 0;
	color: var(--bbz-mc, currentColor);
	font-weight: 700;
}

.bbz .bbz-m-dot li::before {
	content: "";
	top: 0.55em;
	left: 0.3em;
	width: 0.4em;
	height: 0.4em;
	border-radius: 50%;
	background: var(--bbz-mc, currentColor);
}

.bbz .bbz-m-check li::before {
	content: "";
	top: 0.3em;
	left: 0.25em;
	width: 0.35em;
	height: 0.65em;
	border: solid var(--bbz-mc, #1cb65a);
	border-width: 0 0.14em 0.14em 0;
	transform: rotate(45deg);
}

.bbz .bbz-m-dash li::before {
	content: "—";
}

.bbz .bbz-m-num li {
	counter-increment: bbz-n;
}

.bbz .bbz-m-num li::before {
	content: counter(bbz-n) ".";
}

.bbz .bbz-m-none li {
	padding-left: 0;
}

.bbz .bbz-m-none li::before {
	content: none;
}

/* Icon */
.bbz-icon {
	display: block;
	width: 100%;
	height: 100%;
}

/* Gallery */
.bbz-t-gallery {
	overflow: hidden;
}

.bbz-gal,
.bbz-gal-track {
	position: relative;
	width: 100%;
	height: 100%;
}

.bbz-gal-track {
	display: flex;
	transition: transform 0.5s ease;
	touch-action: pan-y;
}

.bbz-gal-s {
	flex: none;
	width: 100%;
	height: 100%;
}

.bbz-gal-s {
	position: relative;
}

/* A video's cover: a play button over it; the player takes its place. */
.bbz .bbz-gal-play {
	position: absolute;
	top: 50%;
	left: 50%;
	width: 70px;
	height: 70px;
	margin: -35px 0 0 -35px;
	border-radius: 50%;
	background: rgba(0, 0, 0, 0.35);
	transition: background-color 0.2s ease;
}

.bbz .bbz-gal-play::before {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	margin: -13px 0 0 -8px;
	border-style: solid;
	border-width: 13px 0 13px 22px;
	border-color: transparent transparent transparent #ffffff;
}

.bbz .bbz-gal-play:hover,
.bbz .bbz-gal-play:focus-visible {
	background: rgba(0, 0, 0, 0.55);
}

.bbz-gal-s iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
}

.bbz-gal-s.is-playing .bbz-gal-play {
	display: none;
}

.bbz .bbz-gal-prev,
.bbz .bbz-gal-next {
	position: absolute;
	top: 50%;
	width: 44px;
	height: 44px;
	margin-top: -22px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.9);
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.15);
	cursor: pointer;
}

.bbz .bbz-gal-prev {
	left: 12px;
}

.bbz .bbz-gal-next {
	right: 12px;
}

.bbz .bbz-gal-prev::before,
.bbz .bbz-gal-next::before {
	content: "";
	position: absolute;
	top: 50%;
	left: 50%;
	width: 10px;
	height: 10px;
	border: solid #111111;
	border-width: 0 2px 2px 0;
	transform: translate(-30%, -50%) rotate(135deg);
}

.bbz .bbz-gal-next::before {
	transform: translate(-70%, -50%) rotate(-45deg);
}

.bbz-gal-dots {
	position: absolute;
	right: 0;
	bottom: 12px;
	left: 0;
	display: flex;
	justify-content: center;
	gap: 8px;
}

.bbz .bbz-gal-dots button {
	width: 9px;
	height: 9px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.55);
	box-shadow: 0 0 0 1px rgba(0, 0, 0, 0.15);
	cursor: pointer;
}

.bbz .bbz-gal-dots button.is-on {
	background: #ffffff;
}

/* Timer */
.bbz-timer {
	display: flex;
	gap: 0.3em;
	justify-content: var(--bbz-ta, flex-start);
}

.bbz-tu {
	display: flex;
	flex-direction: column;
	align-items: center;
	min-width: 1.6em;
	padding: 0.12em 0.2em;
	border-radius: 0.15em;
}

.bbz-tu b {
	font-weight: inherit;
	font-variant-numeric: tabular-nums;
}

.bbz-tu span {
	font-size: 0.28em;
	font-weight: 400;
	line-height: 1.4;
	opacity: 0.75;
}

/* Accordion */
.bbz-acc-i {
	border-bottom: 1px solid var(--bbz-line, rgba(0, 0, 0, 0.15));
}

.bbz-acc-i summary {
	position: relative;
	padding: 0.8em 2em 0.8em 0;
	list-style: none;
	cursor: pointer;
}

.bbz-acc-i summary::-webkit-details-marker {
	display: none;
}

.bbz-acc-x {
	position: absolute;
	top: 50%;
	right: 0.2em;
	width: 0.8em;
	height: 0.8em;
	transform: translateY(-50%);
	transition: transform 0.2s ease;
}

.bbz-acc-x::before,
.bbz-acc-x::after {
	content: "";
	position: absolute;
	top: 50%;
	left: 0;
	width: 100%;
	height: 2px;
	margin-top: -1px;
	background: currentColor;
}

.bbz-acc-x::after {
	transform: rotate(90deg);
}

.bbz-acc-i[open] .bbz-acc-x {
	transform: translateY(-50%) rotate(45deg);
}

.bbz-acc-a {
	padding: 0 0 1em;
	color: var(--bbz-ac, inherit);
	font-size: 0.85em;
	font-weight: 400;
}

/* Hover effects */
.bbz-hv-lift,
.bbz-hv-zoom,
.bbz-hv-dim,
.bbz-hv-shadow {
	transition: translate 0.25s ease, scale 0.25s ease, opacity 0.25s ease, box-shadow 0.25s ease;
}

.bbz-hv-lift:hover {
	translate: 0 -6px;
}

.bbz-hv-zoom:hover {
	scale: 1.04;
}

.bbz-hv-dim:hover {
	opacity: 0.8;
}

.bbz-hv-shadow:hover {
	box-shadow: 0 16px 40px rgba(0, 0, 0, 0.18);
}

/* Appear on scroll: hidden only once front.js can reveal them. */
.bbz-js .bbz [data-anim] {
	transition-property: opacity, translate, scale;
	transition-duration: 0.8s;
	transition-timing-function: cubic-bezier(0.2, 0.7, 0.2, 1);
}

.bbz-js .bbz [data-anim]:not(.bbz-on) {
	opacity: 0;
}

.bbz-js .bbz [data-anim="up"]:not(.bbz-on) {
	translate: 0 40px;
}

.bbz-js .bbz [data-anim="down"]:not(.bbz-on) {
	translate: 0 -40px;
}

.bbz-js .bbz [data-anim="left"]:not(.bbz-on) {
	translate: 40px 0;
}

.bbz-js .bbz [data-anim="right"]:not(.bbz-on) {
	translate: -40px 0;
}

.bbz-js .bbz [data-anim="zoom"]:not(.bbz-on) {
	scale: 0.9;
}

@media (prefers-reduced-motion: reduce) {
	.bbz-js .bbz [data-anim] {
		transition: none;
	}

	.bbz-js .bbz [data-anim]:not(.bbz-on) {
		opacity: 1;
		translate: none;
		scale: none;
	}
}

/*
 * Sections as slides: sections in a row with the same "slider" name, one
 * at a time (render.php). Arrows and dots are the picture slider's.
 */
.bbz-sl {
	position: relative;
	overflow: hidden;
}

.bbz-sl-track {
	display: flex;
	align-items: flex-start;
	transition: transform 0.5s ease;
	touch-action: pan-y;
}

.bbz-sl-track > .bbz-s {
	flex: none;
	/* A slide keeps to itself, or its neighbours would show over it. */
	z-index: auto !important;
	overflow: hidden !important;
}

.bbz-sl .bbz-gal-dots {
	bottom: 16px;
}

.bbz .bbz-sl .bbz-gal-dots button {
	background: rgba(0, 0, 0, 0.2);
	box-shadow: none;
}

.bbz .bbz-sl .bbz-gal-dots button.is-on {
	background: #1cb65a;
}

/*
 * A section as a popup: over the page, opened by a link to its anchor,
 * closed by the cross, Esc or a click beside its content.
 */
.bbz-pop {
	position: fixed;
	z-index: 100000;
	inset: 0;
	display: flex;
	overflow-y: auto;
	overscroll-behavior: contain;
	background: rgba(0, 0, 0, 0.6);
	-webkit-backdrop-filter: blur(4px);
	backdrop-filter: blur(4px);
}

.bbz-pop[hidden] {
	display: none;
}

.bbz-pop-in {
	width: 100%;
	margin: auto 0;
}

.bbz .bbz-pop-x {
	position: fixed;
	z-index: 1;
	top: 16px;
	right: 20px;
	width: 44px;
	height: 44px;
	padding: 0;
	border: 0;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.95);
	color: #111111;
	font: 400 30px/44px Arial, sans-serif;
	cursor: pointer;
}

html.bbz-pop-open {
	overflow: hidden;
}
