/* Footer of the RUB web components (design/README.md): Hellblau 50 with
   rounded upper corners, "Built to change" large in RUB Blau, link groups
   with → arrows, a bottom row with the university and the legal links.
   Markup: parts/footer.html. Part of the RUB Chair theme. */

.rub-footer {
	/* Full width; the content lines up with the page and the header (menu.css). */
	--rub-edge: max(var(--rub-page-margin), (100% - var(--wp--style--global--content-size, 1248px)) / 2);

	background-color: var(--rub-light);
	border-radius: var(--rub-radius-bar) var(--rub-radius-bar) 0 0;
	color: var(--rub-blue);
	font-size: 0.9375rem;
	line-height: 1.6;
	padding: 4rem var(--rub-edge) 1.5rem;
}

/* WordPress pads groups; the edge above replaces it. */
.wp-block-group.rub-footer {
	padding-inline: var(--rub-edge);
}

.rub-footer .wp-block-columns {
	gap: 2rem;
	margin: 0;
}

/* The claim, large and extra bold as in the RUB's footer. */
.rub-footer__claim {
	font-size: clamp(2.5rem, 4.5vw, 3.625rem);
	font-weight: 800;
	line-height: 1;
	margin: 0;
	max-width: 7ch;
}

.rub-footer h2 {
	color: var(--rub-blue);
	font-size: 0.9375rem;
	font-weight: 800;
	line-height: 1.6;
	margin: 0 0 0.25rem;
}

.rub-footer p {
	margin: 0;
}

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

.rub-footer a {
	color: var(--rub-blue);
	text-decoration: none;
}

.rub-footer a:hover {
	text-decoration: underline;
}

/* Links semi-bold and without arrows, as in the RUB's footer. */
.rub-footer__group li a {
	font-weight: 600;
}

/* Bottom row: the university on the left, the legal links on the right.
   The space on the right is kept free for the fixed "To top" button. */
.rub-footer__bottom {
	border-top: 1px solid var(--rub-frame);
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem 2rem;
	justify-content: space-between;
	margin-top: 3rem;
	padding: 1.25rem 6.5rem 0 0;
}

.rub-footer__legal {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.5rem;
}

.rub-footer__bottom a {
	text-decoration: underline;
	text-decoration-color: var(--rub-underline);
	text-underline-offset: 0.2em;
}

@media (min-width: 782px) {
	.rub-footer__brand {
		flex: 1.3 1 0 !important;
	}
}

@media (max-width: 781.98px) {
	.rub-footer {
		border-radius: var(--rub-radius) var(--rub-radius) 0 0;
		padding-top: 3rem;
	}

	/* Phones: the links large, one under the other, easy to tap. */
	.rub-footer__group li a,
	.rub-footer__legal a {
		display: inline-block;
		font-size: 1.125rem;
		font-weight: 600;
		padding-block: 0.3rem;
	}

	.rub-footer__legal {
		flex-direction: column;
	}

	.rub-footer__bottom {
		padding-right: 0;
		padding-bottom: 4rem;
	}
}
