/**
 * BJFR single-column footer for OJS 3.4.0-10.
 */

:root {
	--bjfr-navy: #001a33;
	--bjfr-blue: #1fa9ff;
	--bjfr-white: #ffffff;
}

/* Keep the footer at the viewport bottom without removing it from flow. */
html,
body {
	min-height: 100%;
}

body {
	display: flex;
	flex-direction: column;
	min-height: 100vh;
}

.pkp_structure_page {
	display: flex;
	flex: 1 0 auto;
	flex-direction: column;
	width: 100%;
	min-height: 100vh;
}

.pkp_structure_content {
	flex: 1 0 auto;
}

.pkp_structure_footer_wrapper {
	flex-shrink: 0;
	margin-top: auto;
}

.pkp_structure_footer_wrapper,
.pkp_structure_footer,
.bjfr-footer {
	width: 100%;
	margin: 0;
	padding: 0;
	background: var(--bjfr-navy) !important;
}

.pkp_structure_footer_wrapper {
	position: relative;
	border-top: 1px solid var(--bjfr-blue);
	box-shadow:
		0 -1px 0 rgba(31, 169, 255, 0.85),
		0 -8px 28px rgba(31, 169, 255, 0.16);
}

.pkp_structure_footer_wrapper::before {
	content: "";
	position: absolute;
	top: -1px;
	left: 50%;
	width: min(72%, 960px);
	height: 1px;
	background: var(--bjfr-blue);
	box-shadow: 0 0 18px rgba(31, 169, 255, 0.75);
	transform: translateX(-50%);
	pointer-events: none;
}

.bjfr-footer {
	padding: 52px 24px 30px;
	border: 0;
	color: rgba(255, 255, 255, 0.88);
	font-family: "Noto Sans", "Segoe UI", Arial, sans-serif;
	font-size: 15px;
	line-height: 1.85;
	text-align: center;
}

.bjfr-footer__inner {
	width: 100%;
	max-width: 980px;
	margin-right: auto;
	margin-left: auto;
	box-sizing: border-box;
}

.bjfr-footer__content {
	display: flex;
	flex-direction: column;
	align-items: center;
	width: 100%;
}

.bjfr-footer__content > * {
	max-width: 100%;
}

/* Journal title supplied through the OJS footer editor */
.bjfr-footer h1,
.bjfr-footer h2,
.bjfr-footer h3 {
	margin: 0 0 14px;
	color: var(--bjfr-white);
	font-family: inherit;
	font-size: clamp(1.65rem, 3vw, 2.25rem);
	font-weight: 750;
	letter-spacing: -0.025em;
	line-height: 1.25;
}

.bjfr-footer h4,
.bjfr-footer h5,
.bjfr-footer h6 {
	margin: 0 0 10px;
	color: var(--bjfr-white);
	font-family: inherit;
	font-size: 1rem;
	line-height: 1.5;
}

.bjfr-footer p,
.bjfr-footer address {
	margin: 0 0 7px;
	color: inherit;
	font-style: normal;
}

.bjfr-footer strong,
.bjfr-footer b {
	color: var(--bjfr-white);
	font-weight: 700;
}

.bjfr-footer a {
	color: var(--bjfr-blue);
	text-decoration: none;
	text-underline-offset: 3px;
	transition: color 0.2s ease, text-decoration-color 0.2s ease;
}

.bjfr-footer a:hover,
.bjfr-footer a:focus {
	color: var(--bjfr-white);
	text-decoration: underline;
	text-decoration-color: rgba(255, 255, 255, 0.7);
}

.bjfr-footer a:focus-visible {
	outline: 2px solid var(--bjfr-blue);
	outline-offset: 4px;
	border-radius: 2px;
}

.bjfr-footer img {
	max-width: 100%;
	height: auto;
}

.bjfr-footer ul,
.bjfr-footer ol {
	margin: 0 0 10px;
	padding: 0;
	list-style: none;
}

.bjfr-footer li {
	display: inline;
}

/*
 * OJS preserves custom HTML from the footer editor. A final paragraph, list,
 * nav, or explicit footer-links block becomes the bottom policy-links row.
 */
.bjfr-footer__content > :last-child:has(a),
.bjfr-footer nav,
.bjfr-footer .footer-links,
.bjfr-footer .bjfr-footer__links {
	width: 100%;
	margin-top: 24px;
	margin-bottom: 0;
	padding-top: 18px;
	border-top: 1px solid rgba(255, 255, 255, 0.12);
	color: rgba(255, 255, 255, 0.68);
	font-size: 0.92rem;
	letter-spacing: 0.01em;
}

.bjfr-footer__content > :last-child:has(a) a,
.bjfr-footer nav a,
.bjfr-footer .footer-links a,
.bjfr-footer .bjfr-footer__links a {
	display: inline-block;
	margin: 0 7px;
	color: rgba(255, 255, 255, 0.78);
}

.bjfr-footer__content > :last-child:has(a) a:hover,
.bjfr-footer__content > :last-child:has(a) a:focus,
.bjfr-footer nav a:hover,
.bjfr-footer nav a:focus,
.bjfr-footer .footer-links a:hover,
.bjfr-footer .footer-links a:focus,
.bjfr-footer .bjfr-footer__links a:hover,
.bjfr-footer .bjfr-footer__links a:focus {
	color: var(--bjfr-blue);
}

@media (max-width: 767px) {
	.bjfr-footer {
		padding: 42px 18px 26px;
		font-size: 14px;
	}

	.bjfr-footer h1,
	.bjfr-footer h2,
	.bjfr-footer h3 {
		font-size: clamp(1.4rem, 7vw, 1.8rem);
	}

	.bjfr-footer__content > :last-child:has(a),
	.bjfr-footer nav,
	.bjfr-footer .footer-links,
	.bjfr-footer .bjfr-footer__links {
		margin-top: 20px;
		padding-top: 16px;
		line-height: 2;
	}
}

@media (prefers-reduced-motion: reduce) {
	.bjfr-footer a {
		transition: none;
	}
}
