/**
 * Site footer — see footer.php's top comment for the exact Figma
 * measurements/breakpoints this reproduces. Sitewide (loaded on every
 * page, see intobi_scripts() in functions.php) — companion to
 * css/base.css and css/header.css.
 *
 * @package intobi
 */

.site-footer {
	
}

.footer__container {
	display: flex;
	flex-direction: column;
	gap: 32px;
	padding-top: 32px;
	padding-bottom: 64px;
}

@media (min-width: 1024px) {
	.footer__container {
		gap: 64px;
		padding-top: 64px;
		padding-bottom: 128px;
	}
}

/* ---------------------------------------------------------------
   Upper — contact-rep form card + heading/contacts. Stacked through
   the 1024-wide frame (Form is still full-width there, Info stacked
   below it) — 2-column (card left, text right) only starts at 1240,
   where Form narrows to 568px beside a 480px Info column. Confirmed
   against both frames' own coordinates, node 2001:6916.
------------------------------------------------------------------ */

.footer__upper {
	display: flex;
	flex-direction: column-reverse;
	gap: 64px;
}

@media (min-width: 1240px) {
	.footer__upper {
		flex-direction: row;
		align-items: stretch;
	}
}

.footer__form-card {
	background: var(--io-bg);
	border: 1px solid var(--io-border);
	border-radius: var(--io-radius-card);
	padding: var(--io-space-2);
}

@media (min-width: 1240px) {
	.footer__form-card {
		flex: 1 1 0%;
		min-width: 0;
	}
}

.footer__rep {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 32px;
	padding: 16px 24px;
}

.footer__rep-photo {
	width: 72px;
	object-fit: cover;
	flex-shrink: 0;
	display: block;
	margin-top: -3%;
}

.footer__rep-photo--placeholder {
	background: var(--io-surface);
}

.footer__rep-info {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.footer__rep-name {
	font-family: var(--io-font-heading);
	font-size: 24px;
	line-height: 1.25;
	color: var(--io-body);
	margin: 0;
}

.footer__rep-position {
	font-family: var(--io-font-heading);
	font-size: 20px;
	color: var(--io-muted);
	margin: 0;
}

.footer__form-embed {
	padding: 0 8px 8px;
}

.footer__info {
	display: flex;
	flex-direction: column;
	gap: 64px;
}

@media (min-width: 768px) {
	.footer__rep {
		flex-direction: row;
		align-items: center;
	}
}

@media (min-width: 1240px) {
	.footer__info {
		flex: 1 1 0%;
		min-width: 0;
		max-width: 480px;
		justify-content: center;
		gap: 96px;
	}

	.footer__form-embed {
		padding: 0 24px 24px;
	}
	
	.footer__rep-photo {
		margin-top: -5%;
		width: 128px;
	}
}

/**
 * Same "Let's discuss your product" phrasing/wavy-underline pattern as
 * the Hero form card (template-parts/blocks/hero_block/block.css) —
 * bigger here (32px mobile → 56px desktop vs the Hero card's flat
 * 32px), per the Figma text node at each width.
 */
.footer__heading {
	font-family: var(--io-font-heading);
	font-size: 32px;	
	color: var(--io-ink);
	margin: 0;
	max-width: 480px;
}

.footer__heading .io-wavy-underline {
	--io-wave-thickness: 30px;
	--io-wave-offset: 36px;
}

@media (min-width: 768px) {
	.footer__heading {
		font-size: 56px;
		line-height: 1;
		letter-spacing: -5.6px;
	}
}

/* Wave shape/rendering now comes from the shared .io-wavy-underline
   class (css/base.css, added alongside this one in footer.php) — see
   that class's own comment for why a native `text-decoration-style:
   wavy` was replaced. This rule just sets this instance's own color. */
.footer__heading-highlight {
	--io-wave-color: var(--io-brand);
}

.footer__contacts {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.footer__contacts p {
	font-size: 20px;
	font-weight: 500;
	margin: 0;
}

.footer__contacts p span {
	white-space: nowrap;
}

.footer__contacts a {
	font-family: var(--io-font-body);
	font-weight: 500;
	font-size: 20px;
	color: var(--io-body);
	text-decoration: none;
}

.footer__contacts a:hover {
	color: var(--io-primary-dark);
}

/* ---------------------------------------------------------------
   Link columns — one per registered footer menu. 1 column below
   768px, 3 side-by-side (equal width, 32px gap) at/above it — the
   wider last column and 64px gap are a further step at 1240.
------------------------------------------------------------------ */

.footer__columns {
	display: flex;
	flex-direction: column;
	gap: 32px;
}

.footer__column {
	display: flex;
	flex-direction: column;
	gap: 16px;
	min-width: 200px;
}

@media (min-width: 768px) {
	.footer__columns {
		flex-direction: row;
		align-items: flex-start;
	}
	.footer__column {
		flex: 1 1 0%;
	}
}

/* Figma: still 3 equal-width columns (32px gap, same as the 768
   breakpoint above) at the 1024-wide frame — the wider last column
   (480px, matching the Mobile App menu's own longer link labels) and
   the bigger 64px gap only appear at 1240. Confirmed against both
   frames' own coordinates, node 2001:6916. */
@media (min-width: 1240px) {
	.footer__columns {
		gap: 64px;
	}
	.footer__column:last-child {
		flex: 0 1 480px;
	}
}

/* Now the column's own first menu item (a real link) — see
   intobi_footer_menu_first_item() / footer.php — so this needs the
   <a> reset a <p> never did (block layout, no underline) on top of
   its existing text styling. */
.footer__column-heading:visited,
.footer__column-heading {
	display: block;
	font-family: var(--io-font-body);
	font-weight: 500;
	font-size: 20px;
	color: var(--io-muted);
	text-decoration: none;
	margin: 0;
}

.footer__column-heading:hover {
	color: var(--io-primary-dark);
}

.footer__column-list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
}

.footer__column-list a {
	display: block;
	padding: 12px 0;
	font-family: var(--io-font-body);
	font-weight: 600;
	font-size: 16px;
	color: var(--io-ink);
	text-decoration: none;
	text-transform: capitalize;
}

.footer__column-list a:hover {
	color: var(--io-primary-dark);
}

.footer__divider {
	height: 1px;
	width: 100%;
	background: var(--io-border);
}

/* ---------------------------------------------------------------
   Bottom contact row — two phone/email callouts + CTA/socials.
   Stacked below 1240px, 3-way row at/above it. The CTA+socials pair
   itself wraps to two lines below 768px (Figma's 414/360 frames).
------------------------------------------------------------------ */

.footer__contact-row {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 24px;
}

/* Figma: the two contact callouts + CTA/socials stay stacked (each
   full-width) through the 1024-wide frame — the 3-way row only forms
   at 1240. Confirmed against both frames' own coordinates, node
   2001:6916. */
@media (min-width: 1240px) {
	.footer__contact-row {
		flex-direction: row;
		align-items: center;
		gap: 64px;
	}
}

.footer__contact-callout {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

@media (min-width: 1240px) {
	.footer__contact-callout {
		flex: 1 1 0%;
		min-width: 0;
	}
}

/* Base styling now comes from the shared .io-caption class (css/base.css)
   added alongside this one in footer.php — only the reset stays here. */
.footer__contact-label {
	margin: 0;
}

.footer__contact-value {
	font-family: var(--io-font-heading);
	font-size: 24px;
	line-height: 1.25;
	color: var(--io-body);
	margin: 0;
}

.footer__contact-actions {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 16px;
	width: 100%;
}

@media (min-width: 768px) {
	.footer__contact-actions {
		flex-direction: row;
		align-items: center;
		width: auto;
	}
}

@media (min-width: 1240px) {
	.footer__contact-actions {
		flex: 0 0 480px;
		justify-content: flex-end;
	}
	.footer__contact-value {
		font-size: 20px;
	}
}

@media (min-width: 1440px) {
	.footer__contact-value {
		font-size: 24px;
	}
}

/* max-width + no padding on the links let all 8 icons shrink to fit a
   360px screen; the fixed-size flex box still centres each icon. */
.footer__socials {
	display: flex;
	align-items: center;
	max-width: 100%;
}

.footer__social {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	border-radius: var(--io-radius-btn);
}

@media (min-width: 414px) {
	.footer__social {
		width: 48px;
		height: 48px;
	}
}

.footer__social:hover {
	background: var(--io-surface);
}

.footer__social .icon {
	width: 24px;
	height: 24px;
	display: inline-flex;
}

/* ---------------------------------------------------------------
   Legal — disclaimer, Privacy/Cookie links, copyright.
------------------------------------------------------------------ */

.footer__legal {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.footer__disclaimer {
	font-size: 16px;
	color: var(--io-muted);
	margin: 0;
}

.footer__legal-links {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
}

.footer__legal-links a {
	padding: 12px 0;
	font-family: var(--io-font-body);
	font-weight: 600;
	font-size: 16px;
	color: var(--io-ink);
	text-decoration: none;
	text-transform: capitalize;
}

.footer__legal-links a:hover {
	color: var(--io-primary-dark);
}

/* "Cookie settings" — a button (it opens the cookie banner) styled like the
   legal links next to it. */
.footer__cookie-settings {
	padding: 12px 0;
	border: 0;
	background: none;
	font-family: var(--io-font-body);
	font-weight: 600;
	font-size: 16px;
	line-height: inherit;
	color: var(--io-ink);
	cursor: pointer;
}

.footer__cookie-settings:hover {
	color: var(--io-primary-dark);
}

.footer__cookie-settings[hidden] {
	display: none;
}

/* ---------------------------------------------------------------
   Cookie banner (inc/analytics.php + js/cookie-consent.js). Fixed to
   the bottom of the viewport, so showing it shifts no content (no CLS).
   It lives here because footer.css loads on every page.
------------------------------------------------------------------ */

.cookie-consent {
	position: fixed;
	right: 16px;
	bottom: 16px;
	left: 16px;
	z-index: 1000;
	display: flex;
	flex-direction: column;
	gap: 16px;
	max-width: 560px;
	padding: 24px;
	border: 1px solid var(--io-border-dark);
	border-radius: var(--io-radius-card);
	background: var(--io-bg);
	box-shadow: 0 8px 32px rgba(var(--io-ink-rgb), 0.12);
}

.cookie-consent[hidden] {
	display: none;
}

.cookie-consent__text {
	margin: 0;
	font-family: var(--io-font-body);
	font-size: 14px;
	line-height: 1.5;
	color: var(--io-body);
}

.cookie-consent__text a {
	color: var(--io-primary-dark);
	font-weight: 600;
}

.cookie-consent__actions {
	display: flex;
	gap: 8px;
}

.cookie-consent__actions .io-btn {
	flex: 1 1 0;
}

@media (min-width: 768px) {
	.cookie-consent {
		right: auto;
		bottom: 24px;
		left: 24px;
	}
}

.footer__copyright {
	font-size: 14px;
	line-height: 1.125;
	color: var(--io-muted);
	margin: 0;
}

/* ---------------------------------------------------------------
   CF7 field styling — same approach as the Hero form card (see
   template-parts/blocks/hero_block/block.css), duplicated rather than
   shared per this theme's per-file CSS architecture (see the project
   plan's "CSS and JS" section).
------------------------------------------------------------------ */

.footer__form-embed .footer__form-row {
	display: flex;
	flex-direction: column;
   gap: 8px;
	width: 100%;
}

@media (min-width: 768px) {
	.footer__form-embed .footer__form-row {
		flex-direction: row;
	}
}

@media (min-width: 1240px) {
	.footer__form-embed .footer__form-row {
		flex-direction: column;
	}
}

@media (min-width: 1440px) {
	.footer__form-embed .footer__form-row {
		flex-direction: row;
	}
}

.footer__form-embed .wpcf7-form-control-wrap {
	flex: 1 1 100%;
	display: flex;
	flex-direction: column;
	width: 100%;
}
.footer__form-embed .wpcf7-form-control {
	width: 100%;
	background: var(--io-surface);
	border: 1px solid var(--io-border);
	border-radius: var(--io-radius-btn);
	padding: 12px 16px;
	font-family: var(--io-font-body);
	font-size: 16px;
	color: var(--io-ink);
}

.footer__form-embed .wpcf7-form-control::placeholder {
	color: var(--io-muted);
}

.footer__form-embed textarea.wpcf7-form-control {
	min-height: 96px;
	resize: vertical;
}

/* No more CF7-generated <p> to hang spacing on (autop is filtered off
   sitewide — see inc/template/forms.php) — flex+gap on the form
   itself spaces out whatever element each field/the submit button/the
   response message actually is, without assuming a specific wrapper
   tag. */
.footer__form-embed form {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: var(--io-space-2);
}

.footer__form-embed input[type="submit"].wpcf7-form-control {
	width: auto;
	background: var(--io-primary);
	color: #fff;
	font-weight: 600;
	cursor: pointer;
	border: none;
	height: 48px;
	transition: background-color 0.15s ease;
}

.footer__form-embed input[type="submit"].wpcf7-form-control:hover {
	background: var(--io-primary-dark);
}

.footer__form-embed .wpcf7-not-valid-tip {
	font-size: 14px;
	color: var(--io-red);
	margin: 0;
	padding: 8px 16px;
}

.footer__form-embed .wpcf7-response-output {
	border-radius: var(--io-radius-btn);
	font-size: 14px;
	margin: 0; /* spacing now comes from the form's own flex `gap` above */
}

.wpcf7-spinner {
	position: absolute;
}