/*
 * Footer (UX Block "Footer EN/VI" + Flatsome absolute footer).
 *
 * Built on an 8px grid: every text row is 24px high with 8px gaps,
 * so rows line up across the three columns.
 */

.tipa-footer,
.absolute-footer {
	--tf-text: rgba(255, 255, 255, .86);
	--tf-muted: rgba(255, 255, 255, .56);
	--tf-line: rgba(255, 255, 255, .12);
	--tf-accent: var(--tipa-green-100);
	--tf-row: 24px;
	--tf-gap: 8px;
}

.tipa-footer {
	color: var(--tf-text);
	font-size: 15px;
	line-height: var(--tf-row);
}

.tipa-footer .col {
	padding-bottom: 0;
}

/* UX Builder wraps shortcodes in <p>, which leaves empty paragraphs */
.tipa-footer .col-inner > p:empty {
	display: none;
}

/* Titles: same size, weight and spacing in all columns */
.tipa-footer .tipa-footer__title {
	position: relative;
	margin: 0 0 32px;
	padding-bottom: 16px;
	color: #fff;
	font-size: 18px;
	font-weight: 700;
	line-height: var(--tf-row);
	text-transform: uppercase;
}

.tipa-footer .tipa-footer__title::after {
	content: "";
	position: absolute;
	left: 0;
	bottom: 0;
	width: 32px;
	height: 2px;
	background: var(--tf-accent);
}

/* Lists share the same rhythm */
.tipa-footer__menu,
.tipa-footer__info {
	margin: 0;
	padding: 0;
	list-style: none;
}

.tipa-footer .tipa-footer__menu li,
.tipa-footer .tipa-footer__info li {
	margin: 0 0 var(--tf-gap);
	padding: 0;
	list-style: none;
	line-height: var(--tf-row);
}

.tipa-footer .tipa-footer__menu li:last-child,
.tipa-footer .tipa-footer__info li:last-child {
	margin-bottom: 0;
}

.tipa-footer__menu a {
	display: inline-block;
	color: var(--tf-text);
	transition: color .2s ease, transform .2s ease;
}

.tipa-footer__menu a:hover {
	color: #fff;
	transform: translateX(4px);
}

/* Company info: labels and values in two aligned columns */
.tipa-footer__info li {
	display: grid;
	grid-template-columns: 136px 1fr;
	column-gap: 16px;
}

.tipa-footer__label {
	color: var(--tf-muted);
}

.tipa-footer__info a {
	color: var(--tf-text);
	border-bottom: 1px solid transparent;
	transition: color .2s ease, border-color .2s ease;
}

.tipa-footer__info a:hover {
	color: #fff;
	border-color: currentColor;
}

/* Badge: fixed size, aligned to the text column */
.tipa-footer .tipa-footer__badge {
	width: 160px;
	margin: 32px 0 0;
}

.tipa-footer .tipa-footer__badge .img-inner {
	margin: 0;
}

/* Bottom bar: copyright | follow us | policy links, follow us truly centred */
.absolute-footer {
	padding: 24px 0;
	border-top: 1px solid var(--tf-line);
	color: var(--tf-muted);
	font-size: 14px;
	line-height: var(--tf-row);
}

.absolute-footer > .container {
	display: grid;
	grid-template-columns: minmax(max-content, 1fr) auto minmax(max-content, 1fr);
	align-items: center;
	column-gap: 32px;
}

.absolute-footer > .container::before,
.absolute-footer > .container::after {
	display: none;
}

.absolute-footer .footer-secondary {
	display: contents;
}

.absolute-footer .footer-primary {
	grid-column: 1;
	grid-row: 1;
	float: none;
	padding: 0;
}

.absolute-footer .tipa-footer-follow {
	grid-column: 2;
	grid-row: 1;
}

.absolute-footer .footer-secondary .footer-text {
	grid-column: 3;
	grid-row: 1;
	justify-self: end;
	padding: 0;
}

.absolute-footer .copyright-footer {
	padding: 0;
}

.tipa-footer-follow {
	display: flex;
	align-items: center;
	gap: 12px;
}

.tipa-footer-follow .social-icons {
	display: flex;
	gap: 8px;
	margin: 0;
	font-size: 0;
}

.tipa-footer-follow .social-icons .icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 32px;
	height: 32px;
	margin: 0;
	padding: 0;
	border: 1px solid var(--tf-line);
	border-radius: 50%;
	color: var(--tf-text);
	font-size: 14px;
	line-height: 1;
	transition: background-color .2s ease, border-color .2s ease, color .2s ease;
}

.tipa-footer-follow .social-icons .icon:hover {
	background: var(--tf-accent);
	border-color: var(--tf-accent);
	color: var(--tipa-green-900);
}

.absolute-footer .tipa-footer__menu {
	margin: 0;
	padding: 0;
	border: 0;
	opacity: 1;
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-end;
	gap: 0 24px;
}

.absolute-footer .tipa-footer__menu li {
	margin: 0;
	white-space: nowrap;
}

.absolute-footer .tipa-footer__menu a {
	color: var(--tf-muted);
}

.absolute-footer .tipa-footer__menu a:hover {
	color: #fff;
	transform: none;
}

/* Tablet: company info on top, the two link lists side by side */
@media (max-width: 849px) {
	.tipa-footer .tipa-footer__col--company {
		order: -1;
		padding-bottom: 48px;
	}

	.absolute-footer {
		padding: 32px 0;
	}

	.absolute-footer > .container {
		grid-template-columns: 1fr;
		row-gap: 16px;
		justify-items: center;
		text-align: center;
	}

	.absolute-footer .tipa-footer-follow { grid-row: 1; grid-column: 1; }
	.absolute-footer .footer-secondary .footer-text { grid-row: 2; grid-column: 1; justify-self: center; }
	.absolute-footer .footer-primary { grid-row: 3; grid-column: 1; }

	.absolute-footer .tipa-footer__menu {
		justify-content: center;
	}
}

/* Mobile: single column, same spacing between blocks */
@media (max-width: 549px) {
	.tipa-footer .tipa-footer__col--company,
	.tipa-footer .tipa-footer__col--products {
		padding-bottom: 40px;
	}

	.tipa-footer__info li {
		grid-template-columns: 1fr;
	}

	.absolute-footer .tipa-footer__menu {
		gap: 0 16px;
	}
}
