/* ========================================================
   Footer — fixed four-column layout
   Order: base → layout → components → media queries
   ======================================================== */

/* Base
   ------------------------------------------------------------------ */

.site-footer {
	background: var(--color-footer);
	color: var(--color-footer-text);
}

/* Kadence only resets link underlines for headings and .entry-content, so
   footer links would otherwise fall back to the browser default underline. */
.site-footer a {
	color: var(--color-footer-text);
	text-decoration: none;
}

.site-footer a:hover,
.site-footer a:focus {
	color: var(--color-coral);
	text-decoration: underline;
}

.site-footer a:focus-visible {
	outline: 2px solid var(--color-coral);
	outline-offset: 2px;
}

.site-footer h1,
.site-footer h2,
.site-footer h3,
.site-footer h4,
.site-footer h5,
.site-footer h6,
.site-footer .widget-title {
	color: var(--color-white);
	font-family: var(--font-head);
}

.site-footer ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

/* Layout
   ------------------------------------------------------------------ */

.site-bottom-footer-wrap {
	background: var(--color-footer-bar);
}

.footer-main__inner.site-container {
	max-width: var(--max-width);
	margin: 0 auto;
	padding: var(--space-xl) var(--space-md);
	display: grid;
	grid-template-columns: 1fr;
	gap: var(--space-md);
}

.footer-bottom.site-container {
	max-width: var(--max-width);
	margin: 0 auto;
	padding: var(--space-sm) var(--space-md);
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: var(--space-xs);
	font-size: var(--font-size-sm);
}

/* Components
   ------------------------------------------------------------------ */

/* Brand column */
.footer-main__logo {
	max-width: 200px;
	height: auto;
}

/* Text stand-in shown only if the logo attachment is missing */
.footer-main__wordmark {
	margin: 0;
	font-family: var(--font-head);
	font-size: var(--font-size-lg);
	color: var(--color-white);
}

.footer-main__tagline {
	margin: var(--space-xs) 0 0;
}

/* Column headings */
.footer-main__title {
	margin: 0 0 var(--space-sm);
	font-family: var(--font-head);
	font-size: var(--font-size-md);
	color: var(--color-white);
}

/* Recent posts */
.footer-posts__item {
	margin-bottom: var(--space-md);
}

.footer-posts__item:last-child {
	margin-bottom: 0;
}

/* Base link colour is white here, not the dimmer --color-footer-text; hover/
   focus still fall through to the shared .site-footer a:hover coral. */
.footer-posts__item a {
	color: var(--color-white);
}

.footer-posts__date {
	display: block;
	font-size: var(--font-size-sm);
	opacity: 0.75;
}

/* Contact */
.footer-contact__item {
	display: flex;
	gap: var(--space-xs);
	align-items: flex-start;
	margin-bottom: var(--space-sm);
}

.footer-contact__item:last-child {
	margin-bottom: 0;
}

.footer-contact__icon {
	flex-shrink: 0;
	width: 1.25em;
	text-align: center;
}

/* Legal */
.footer-legal__item {
	margin-bottom: var(--space-xs);
}

.footer-legal__item:last-child {
	margin-bottom: 0;
}

/* Bottom bar */
.footer-bottom__copy,
.footer-bottom__credit {
	margin: 0;
}

/* Media queries
   ------------------------------------------------------------------ */

@media (min-width: 600px) {
	.footer-main__inner.site-container {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.footer-bottom.site-container {
		flex-direction: row;
		justify-content: space-between;
	}
}

@media (min-width: 992px) {
	.footer-main__inner.site-container {
		grid-template-columns: repeat(4, minmax(0, 1fr));
	}
}
