/* MegaMasterok — site footer (global). Slice 5. Template: template-parts/footer/site-footer.php. */

/* GeneratePress' footer wrapper stays; it only hosts the MegaMasterok footer. */
.site-footer {
	background: none;
}

.megam-footer {
	margin-top: clamp(40px, 4vw, 56px);
	border-top: 1px solid var(--megam-line);
	background: color-mix(in srgb, var(--megam-surface-alt) 60%, #fff);
	color: var(--megam-text);
	font-family: var(--megam-font);
}

/* The homepage's last section already ends with its own bottom spacing. */
.megam-front .megam-footer {
	margin-top: 0;
}

.megam-footer__main {
	display: grid;
	grid-template-columns: minmax(250px, 1.15fr) minmax(0, 3.4fr);
	gap: 28px clamp(28px, 3vw, 48px);
	align-items: start;
	padding-top: 28px;
	padding-bottom: 26px;
}

.megam-footer__main--stub {
	grid-template-columns: minmax(250px, 1.15fr) minmax(0, 3.4fr) minmax(250px, 1.2fr);
}

/* Brand ------------------------------------------------------------------- */

.megam-footer__brand {
	min-width: 0;
}

.megam-footer .megam-brand__mark {
	width: 44px;
	height: 40px;
}

.megam-footer .megam-brand__name {
	font-size: 1.5rem;
}

.megam-footer__statement {
	max-width: 26em;
	margin: 14px 0 0;
	color: var(--megam-muted);
	font-size: var(--megam-fs-sm);
	line-height: 1.45;
}

/* Navigation -------------------------------------------------------------- */

.megam-footer__nav {
	display: grid;
	grid-template-columns: repeat(4, minmax(0, 1fr));
	gap: 20px 24px;
	min-width: 0;
}

.megam-footer .megam-footer__heading {
	margin: 0 0 10px;
	color: var(--megam-ink);
	font-size: var(--megam-fs-sm);
	font-weight: 700;
	line-height: 1.3;
}

.megam-footer__links {
	display: grid;
	gap: 6px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.megam-footer__links li {
	margin: 0;
	font-size: var(--megam-fs-sm);
	line-height: 1.35;
}

.megam-footer__links a {
	display: inline-block;
	color: var(--megam-text);
	font-size: var(--megam-fs-sm);
	line-height: 1.35;
	text-decoration: none;
}

.megam-footer__links a:hover {
	color: var(--megam-accent-strong);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.megam-footer a:focus-visible {
	outline: none;
	border-radius: 4px;
	box-shadow: var(--megam-focus);
}

/*
 * Newsletter: local/development visual stub only (never rendered in
 * production). Dashed, muted and non-interactive so it cannot read as a
 * working form.
 */
.megam-footer__newsletter {
	min-width: 0;
	cursor: help;
}

.megam-footer .megam-footer__heading--stub {
	color: var(--megam-muted);
	text-decoration: underline dashed var(--megam-line-strong);
	text-underline-offset: 4px;
}

.megam-footer__newsletter-row {
	display: flex;
	min-width: 0;
}

.megam-footer__newsletter-field,
.megam-footer__newsletter-button {
	display: flex;
	align-items: center;
	box-sizing: border-box;
	height: 42px;
	border: 1px dashed var(--megam-line-strong);
	font-size: var(--megam-fs-sm);
	white-space: nowrap;
}

.megam-footer__newsletter-field {
	flex: 1 1 auto;
	min-width: 0;
	padding: 0 12px;
	border-right: 0;
	border-radius: var(--megam-radius) 0 0 var(--megam-radius);
	background: var(--megam-surface);
	color: var(--megam-subtle);
}

.megam-footer__newsletter-button {
	flex: none;
	padding: 0 16px;
	border-radius: 0 var(--megam-radius) var(--megam-radius) 0;
	background: var(--megam-placeholder);
	color: var(--megam-muted);
	font-weight: 600;
}

/* Bottom bar -------------------------------------------------------------- */

.megam-footer__bar {
	border-top: 1px solid var(--megam-line);
}

.megam-footer__bar-inner {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 8px 24px;
	padding-top: 14px;
	padding-bottom: 16px;
}

.megam-footer .megam-footer__copy {
	margin: 0;
	color: var(--megam-muted);
	font-size: var(--megam-fs-xs);
	line-height: 1.4;
}

.megam-footer__top {
	color: var(--megam-muted);
	font-size: var(--megam-fs-xs);
	text-decoration: none;
}

.megam-footer__top:hover {
	color: var(--megam-accent-strong);
	text-decoration: underline;
	text-underline-offset: 3px;
}

/* Responsive -------------------------------------------------------------- */

/* The newsletter stub drops below the navigation before the columns get cramped. */
@media (max-width: 1200px) {
	.megam-footer__main--stub {
		grid-template-columns: minmax(230px, 1fr) minmax(0, 3fr);
	}

	.megam-footer__newsletter {
		grid-column: 2;
		max-width: 420px;
	}
}

/* Tablet: brand above, four navigation columns across the full width. */
@media (max-width: 900px) {
	.megam-footer__main,
	.megam-footer__main--stub {
		grid-template-columns: minmax(0, 1fr);
		gap: 24px;
		padding-top: 28px;
		padding-bottom: 24px;
	}

	.megam-footer__newsletter {
		grid-column: auto;
	}

	.megam-footer__statement {
		margin-top: 10px;
	}
}

/* Mobile: two navigation columns; 44 px tap rows. */
@media (max-width: 600px) {
	.megam-footer .megam-brand__mark {
		width: 36px;
		height: 33px;
	}

	.megam-footer .megam-brand__name {
		font-size: 1.3125rem;
	}

	.megam-footer__nav {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 18px 16px;
	}

	.megam-footer .megam-footer__heading {
		margin-bottom: 2px;
	}

	.megam-footer__links {
		gap: 0;
	}

	.megam-footer__links a {
		display: flex;
		align-items: center;
		min-height: 40px;
	}
}
