/*
 * Global footer component.
 *
 * The theme owns the permanent shell, signup form, navigation and optional
 * focus presentation. Feature plugins provide data and behaviour only.
 */

.fse-site-footer {
	box-sizing: border-box;
	width: 100% !important;
	max-width: none !important;
	margin: 0 !important;
	padding: 0 !important;
	border-top: var(--fse-border);
	background: var(--fse-ink) !important;
	color: var(--fse-paper) !important;
	font-family: var(--fse-font-body);
}

html[data-fse-theme="dark"] .fse-site-footer {
	--fse-ink: #080808;
	--fse-paper: #f5f5f2;
}

.fse-site-footer *,
.fse-site-footer *::before,
.fse-site-footer *::after {
	box-sizing: border-box;
}

.fse-site-footer :where(a, p, h2, strong) { color: inherit; }
.fse-site-footer__grid {
	display: grid;
	grid-template-columns: minmax(280px, .72fr) minmax(0, 1.28fr);
	gap: clamp(56px, 8vw, 140px);
	width: 100%;
	margin: 0;
	padding: clamp(58px, 7vw, 104px) var(--fse-gutter);
}

.fse-site-footer__identity,
.fse-site-footer__navigation,
.fse-site-footer__navigation-group {
	margin: 0;
}

.fse-site-footer__identity {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	justify-content: space-between;
	gap: 48px;
}

.fse-site-footer__identity h2 {
	margin: 0;
	font-family: var(--fse-font-display);
	font-size: clamp(2.7rem, 4.5vw, 5rem);
	font-weight: 650;
	line-height: .84;
	letter-spacing: -.045em;
}

.fse-site-footer__identity h2 a { text-decoration: none; }
.fse-site-footer__identity h2 span { color: var(--fse-accent); }

.fse-site-footer__identity p {
	max-width: 28ch;
	margin: 0;
	color: rgba(255, 255, 255, .72);
	font-size: clamp(.95rem, 1.2vw, 1.15rem);
	line-height: 1.45;
}

.fse-site-footer__navigation {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	align-content: start;
	gap: clamp(30px, 4vw, 72px);
}

.fse-site-footer__navigation-group {
	display: flex;
	min-width: 0;
	flex-direction: column;
	align-items: flex-start;
	gap: 13px;
}

.fse-site-footer__navigation-group > p { display: contents; }

.fse-site-footer__navigation-group h2 {
	margin: 0 0 10px;
	color: rgba(255, 255, 255, .56);
	font-family: var(--fse-font-body);
	font-size: 11px;
	font-weight: 750;
	line-height: 1.2;
	letter-spacing: .11em;
	text-transform: uppercase;
}

.fse-site-footer__navigation-group > a,
.fse-site-footer__navigation-group > p > a {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 2px 0;
	color: var(--fse-paper);
	font-size: clamp(.95rem, 1.2vw, 1.12rem);
	font-weight: 500;
	line-height: 1.25;
	text-decoration: none;
	transition: color var(--fse-ui-transition-fast), transform var(--fse-ui-transition-fast);
}

.fse-site-footer__navigation-group > a:is(:hover, :focus-visible),
.fse-site-footer__navigation-group > p > a:is(:hover, :focus-visible) {
	color: var(--fse-accent);
	transform: translateX(4px);
}

.fse-site-footer__meta {
	display: flex;
	width: 100%;
	min-height: 78px;
	align-items: center;
	justify-content: space-between;
	gap: 28px 48px;
	margin: 0;
	padding: 22px var(--fse-gutter);
	border-top: 1px solid rgba(255, 255, 255, .72);
}

.fse-site-footer__meta p {
	margin: 0;
	font-size: clamp(.78rem, .9vw, .92rem);
}

.fse-site-footer__meta-navigation {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: clamp(18px, 2vw, 30px);
}

.fse-site-footer__meta-navigation > a {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.fse-site-footer__link-icon {
	display: inline-flex;
	width: 15px;
	height: 15px;
	flex: 0 0 15px;
	align-items: center;
	justify-content: center;
	overflow: visible;
}

.fse-site-footer__link-icon svg {
	display: block;
	width: 100%;
	height: 100%;
	overflow: visible;
	fill: none;
	stroke: currentColor;
	stroke-width: 1.8;
	stroke-linecap: round;
	stroke-linejoin: round;
}

.fse-site-footer__link-icon path {
	transform-origin: center;
	transition: transform 320ms cubic-bezier(.2, .8, .2, 1), stroke-dashoffset 360ms ease;
}

.fse-site-footer__link-icon-corner {
	stroke-dasharray: 24;
	stroke-dashoffset: 0;
}

.fse-site-footer a:is(:hover, :focus-visible) .fse-site-footer__link-icon {
	animation: fse-footer-arrow-point 520ms cubic-bezier(.2, .8, .2, 1);
}

.fse-site-footer a:is(:hover, :focus-visible) .fse-site-footer__link-icon-corner {
	animation: fse-footer-arrow-draw 520ms ease;
}

@keyframes fse-footer-arrow-point {
	0%, 100% { transform: translate(0, 0); }
	42% { transform: translate(3px, -3px); }
	72% { transform: translate(1px, -1px); }
}

@keyframes fse-footer-arrow-draw {
	0% { stroke-dashoffset: 0; }
	45% { stroke-dashoffset: 24; }
	46% { stroke-dashoffset: -24; }
	100% { stroke-dashoffset: 0; }
}

.fse-site-footer__meta a {
	color: var(--fse-paper);
	text-decoration: none;
}

.fse-site-footer__meta a {
	text-decoration-color: transparent;
	text-underline-offset: 4px;
}

.fse-site-footer__meta a:hover {
	color: var(--fse-accent);
	text-decoration: underline;
}

/* Optional focus slot: FSE OS supplies only its content and behaviour. */
.fse-focus-footer {
	--fse-focus-bg: var(--fse-ui-surface-warm);
	--fse-focus-fg: var(--fse-ui-ink);
	width: 100%;
	margin: 0;
	background: var(--fse-ink);
	color: var(--fse-paper);
}

.fse-focus-footer[hidden],
.fse-focus-footer [hidden] { display: none !important; }

.fse-focus-footer__screen {
	position: relative;
	display: grid;
	grid-template-columns: minmax(0, 1.75fr) minmax(270px, 360px);
	gap: clamp(36px, 6vw, 96px);
	min-height: clamp(300px, 32vw, 420px);
	padding: clamp(42px, 5vw, 68px) var(--fse-gutter);
	background: var(--fse-focus-bg);
	color: var(--fse-focus-fg);
	cursor: pointer;
	transition: filter var(--fse-ui-transition-standard);
}

.fse-focus-footer__screen:hover,
.fse-focus-footer__screen:focus-visible {
	color: var(--fse-focus-fg);
	filter: saturate(1.03) brightness(.98);
}

.fse-focus-footer__screen:focus-visible {
	outline: 3px solid currentColor;
	outline-offset: -8px;
}

.fse-focus-footer__title {
	align-self: center;
	max-width: 1080px;
}

.fse-focus-footer__title :where(h2, em) {
	display: block;
	margin: 0;
	color: var(--fse-focus-fg);
	font-family: var(--fse-font-display);
	font-size: clamp(44px, 5.6vw, 82px);
	font-weight: 650;
	line-height: .92;
	letter-spacing: -.028em;
	white-space: pre-line;
}

.fse-focus-footer__title em { font-style: normal; }
.fse-focus-footer__details { align-self: end; }

.fse-focus-footer__details > p {
	margin: 0 0 46px;
	font-size: clamp(15px, 1.4vw, 18px);
	line-height: 1.6;
}

.fse-focus-footer__offer {
	display: grid;
	gap: 7px;
}

.fse-focus-footer__offer.has-meta {
	padding-top: 18px;
	border-top: 1px solid currentColor;
}

.fse-focus-footer__offer > strong {
	font-family: var(--fse-font-display);
	font-size: clamp(38px, 4vw, 56px);
	line-height: 1;
}

.fse-focus-footer__offer > span { font-size: 12px; }

.fse-focus-footer__offer > i {
	display: inline-flex;
	width: max-content;
	min-height: var(--fse-ui-control-height);
	align-items: center;
	gap: 8px;
	padding: 0 17px;
	border: 1.5px solid currentColor;
	border-radius: var(--fse-ui-radius-control);
	font-style: normal;
	font-weight: 800;
	transition: background var(--fse-ui-transition-fast), color var(--fse-ui-transition-fast);
}

.fse-focus-footer__offer.has-meta > i { margin-top: 30px; }
.fse-focus-footer__offer:not(.has-meta) > i { margin-top: 8px; }

.fse-focus-footer__screen:hover .fse-focus-footer__offer > i,
.fse-focus-footer__screen:focus-visible .fse-focus-footer__offer > i {
	background: var(--fse-focus-fg);
	color: var(--fse-focus-bg);
}

.fse-focus-footer__offer > i::after {
	content: "↗";
	font-size: 1.05em;
	line-height: 1;
}

.fse-focus-footer__noscript {
	padding: 30px;
	background: var(--fse-ink);
	color: var(--fse-paper);
	text-align: center;
}

.fse-focus-footer__noscript a {
	color: var(--fse-accent);
	font-weight: 800;
}

@media (max-width: 900px) {
	.fse-site-footer__grid,
	.fse-focus-footer__screen { grid-template-columns: 1fr; }

	.fse-site-footer__grid { gap: 64px; }
	.fse-site-footer__identity { gap: 26px; }
	.fse-site-footer__navigation { grid-template-columns: repeat(3, minmax(0, 1fr)); }

	.fse-focus-footer__screen {
		min-height: auto;
		gap: 48px;
	}

	.fse-focus-footer__title { align-self: start; }
}

@media (max-width: 640px) {
	.fse-site-footer__grid {
		gap: 52px;
		padding-top: 52px;
		padding-bottom: 52px;
	}

	.fse-site-footer__navigation {
		grid-template-columns: repeat(2, minmax(0, 1fr));
		row-gap: 42px;
	}

	.fse-site-footer__meta {
		align-items: flex-start;
		flex-direction: column;
		gap: 16px;
	}

	.fse-site-footer__meta-navigation {
		flex-wrap: wrap;
		justify-content: flex-start;
	}
}

@media (prefers-reduced-motion: reduce) {
	.fse-site-footer :where(a, button) { transition: none !important; }
	.fse-site-footer__link-icon,
	.fse-site-footer__link-icon path { animation: none !important; transition: none !important; }
}
