/*
Theme Name: Frank Endersby Art
Description: Bespoke block theme for frankendersbyart.co.uk. A faithful rebuild of the 2014-2021 Bridge design using core blocks only.
Author: Sentinel Infrastructure
Version: 1.0.0
Requires at least: 6.6
Requires PHP: 7.4
License: GPLv2 or later
Text Domain: frankendersby
*/

/* ---------- Header ---------- */

.fe-header {
	background: #fff;
}
.fe-header__inner {
	height: 100px;
	align-items: center;
}
.fe-logo {
	display: block;
	line-height: 0;
}
.fe-logo img {
	height: 67px;
	width: auto;
}
.fe-logo__light {
	display: none;
}

.fe-nav .wp-block-navigation__container,
.fe-nav.wp-block-navigation {
	gap: 33px;
}
.fe-nav .wp-block-navigation-item__content {
	font-size: 13px;
	font-weight: 600;
	letter-spacing: 1px;
	text-transform: uppercase;
	color: #9d9d9d;
	text-decoration: none;
}
.fe-nav .wp-block-navigation-item__content:hover,
.fe-nav .current-menu-item > .wp-block-navigation-item__content {
	color: #303030;
}

/* Over a banner: transparent, white logo and menu */
.fe-header--overlay {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	z-index: 20;
	background: transparent;
}
.admin-bar .fe-header--overlay {
	top: 32px;
}
.fe-header--overlay .fe-logo__light {
	display: block;
}
.fe-header--overlay .fe-logo__dark {
	display: none;
}
.fe-header--overlay .fe-nav .wp-block-navigation-item__content {
	color: #fff;
}
.fe-header--overlay .fe-nav .wp-block-navigation-item__content:hover {
	color: #fff;
	opacity: 0.75;
}

/* Small screens: solid white bar, centred dark logo, menu button on the left (as the old theme) */
@media (max-width: 999px) {
	.fe-header--overlay {
		position: static;
		background: #fff;
	}
	.fe-header--overlay .fe-logo__light {
		display: none;
	}
	.fe-header--overlay .fe-logo__dark {
		display: block;
	}
	.fe-header__inner {
		height: 78px;
		position: relative;
		justify-content: center !important;
	}
	.fe-logo img {
		height: 50px;
	}
	.fe-nav {
		position: absolute;
		left: 0;
		top: 50%;
		transform: translateY(-50%);
	}
	.fe-nav .wp-block-navigation__responsive-container-open {
		display: flex !important;
		color: #9d9d9d;
	}
	.fe-nav .wp-block-navigation__responsive-container:not(.is-menu-open) {
		display: none !important;
	}
}
@media (max-width: 782px) {
	.admin-bar .fe-header--overlay {
		top: 46px;
	}
}

/* The opened mobile menu */
.fe-nav .wp-block-navigation__responsive-container.is-menu-open {
	background: #fff;
	padding: 30px;
}
.fe-nav .is-menu-open .wp-block-navigation__container {
	gap: 22px;
}
.fe-nav .is-menu-open .wp-block-navigation-item__content,
.fe-header--overlay .fe-nav .is-menu-open .wp-block-navigation-item__content {
	color: #303030;
	font-size: 15px;
}

/* ---------- Banner + intro band ---------- */

.fe-hero {
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}
.wp-block-image.fe-hero img {
	display: block;
	width: 100%;
	height: var(--fe-hero-h, 31.5vw);
	object-fit: cover;
}
.fe-hero--home { --fe-hero-h: 31.5vw; }
.fe-hero--books { --fe-hero-h: 27.8vw; }
.fe-hero--cards { --fe-hero-h: 33vw; }
.fe-hero--contact { --fe-hero-h: 34.7vw; }

.fe-intro {
	background: var(--wp--preset--color--purple);
	padding: 31px 30px !important;
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}
.fe-intro--pink {
	background: var(--wp--preset--color--pink);
}
.fe-intro h1 {
	color: #fff;
	text-align: center;
	font-size: clamp(20px, 3.4vw, 30px);
	margin: 0;
}
.fe-intro .fe-intro__sub {
	color: var(--wp--preset--color--beige);
	text-align: center;
	font-size: clamp(13px, 2.3vw, 20px);
	margin: 0;
}

/* ---------- Home ---------- */

.fe-canvas {
	padding: 20px 30px 25px !important;
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}
.fe-cols.wp-block-columns {
	gap: 30px;
	margin: 0 auto;
}
.fe-canvas .wp-block-column > .wp-block-image {
	margin: 20px 0 0;
}
.fe-contact-inline {
	padding: 20px 0;
}
.fe-contact-inline h4 {
	margin: 0;
}

.fe-prof {
	display: flex;
	flex-wrap: nowrap;
	align-items: flex-end;
}
.fe-prof figure {
	margin: 0;
}
.fe-prof img {
	display: block;
	width: 100%;
	height: auto;
}
.fe-prof__photo {
	flex: 0 0 30%;
}
.fe-prof__note {
	flex: 0 0 70%;
}
@media (max-width: 419px) {
	.fe-prof {
		flex-wrap: wrap;
	}
	.fe-prof__photo,
	.fe-prof__note {
		flex: 0 0 100%;
		max-width: 200px;
	}
}

.fe-publishers {
	background: #fff;
	padding: 66px 30px 67px !important;
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}
.fe-publishers h3 {
	color: var(--wp--preset--color--purple);
	text-align: center;
	margin: 0;
}
.fe-logos {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 10px 30px;
	margin-top: 35px !important;
}
.fe-logos figure {
	margin: 0;
}
.fe-logos img {
	width: 180px;
	height: auto;
	filter: grayscale(1);
	opacity: 0.65;
	transition: filter 0.2s, opacity 0.2s;
}
.fe-logos a:hover img,
.fe-logos a:focus img {
	filter: none;
	opacity: 1;
}

.fe-croc {
	margin: 0 auto !important;
	padding-top: 10px;
	text-align: center;
}
.fe-croc img {
	display: inline-block;
	width: 100%;
	max-width: 1170px;
	height: auto;
	vertical-align: bottom;
}

/* ---------- Galleries ---------- */

.wp-block-gallery.fe-gallery {
	--wp--style--unstable-gallery-gap: 30px;
	gap: 30px;
	padding: 30px 15px !important;
	margin-top: 0 !important;
	margin-bottom: 0 !important;
}
.wp-block-gallery.fe-gallery figure.wp-block-image {
	flex-grow: 0;
}
.wp-block-gallery.fe-gallery figure.wp-block-image img {
	aspect-ratio: 1;
	object-fit: cover;
}
.fe-gallery--bordered figure.wp-block-image img {
	border: 1px solid var(--wp--preset--color--border);
}
@media (min-width: 600px) and (max-width: 999px) {
	.wp-block-gallery.fe-gallery figure.wp-block-image {
		width: calc(50% - 15px) !important;
	}
}
@media (max-width: 599px) {
	.wp-block-gallery.fe-gallery figure.wp-block-image {
		width: 100% !important;
	}
}

/* ---------- Contact ---------- */

.fe-contact {
	padding: 30px 0 70px !important;
}
.fe-contact h3 {
	margin: 0 0 15px;
}
.fe-greybox {
	position: relative;
	background: var(--wp--preset--color--slate);
	color: #fff;
	padding: 15px !important;
}
.fe-greybox a {
	color: #fff;
	font-weight: 700;
	text-decoration: none;
}
.fe-greybox a:hover {
	color: var(--wp--preset--color--beige);
}
.fe-greybox figure.fe-hang {
	position: absolute;
	right: -40px;
	bottom: 0;
	margin: 0;
	transform: translateY(100%);
	pointer-events: none;
}
.fe-greybox figure.fe-hang img {
	width: auto;
	max-height: 400px;
}
@media (min-width: 1001px) {
	.fe-greybox figure.fe-hang img {
		max-height: 540px;
	}
}
@media (max-width: 781px) {
	.fe-greybox figure.fe-hang {
		display: none;
	}
}
.fe-side-img {
	position: relative;
	z-index: 10;
	margin: 0 !important;
}
.fe-side-img img {
	display: block;
	width: 100%;
	height: auto;
}
.fe-quote.wp-block-quote {
	position: relative;
	z-index: 10;
	background: #fff;
	border: 0;
	margin: 0;
	padding: 24px !important;
	font-size: 14px;
	font-style: italic;
	font-weight: 600;
	text-align: center;
	text-transform: uppercase;
}
.fe-quote p {
	max-width: 25rem;
	margin: 0 auto;
}
.fe-quote cite {
	display: block;
	max-width: 25rem;
	margin: 10px auto 0;
	font-size: 13px;
	font-style: italic;
	text-align: right;
}

/* ---------- Default pages (privacy, cookies) ---------- */

.fe-main:not(.fe-main--hero) {
	padding-top: 33px;
	padding-bottom: 80px;
}
.fe-page-title.wp-block-post-title,
h1.fe-page-title {
	font-size: 17px;
	font-weight: 600;
	letter-spacing: 1px;
	line-height: 1.3;
	text-transform: uppercase;
	margin: 0 0 70px;
}
.fe-page-title::after {
	content: "";
	display: block;
	width: 22px;
	height: 2px;
	margin-top: 15px;
	background: var(--wp--preset--color--heading);
}
.fe-main ul {
	margin: 0;
	padding-left: 19px;
}
.fe-main p {
	margin: 0;
}

/* ---------- Footer ---------- */

.fe-footer__top {
	background: var(--wp--preset--color--footer);
	padding: 55px 30px 70px !important;
}
.fe-footer-nav.wp-block-navigation,
.fe-footer-nav .wp-block-navigation__container {
	gap: 17px;
}
.fe-footer-nav .wp-block-navigation-item__content {
	color: var(--wp--preset--color--text);
	font-size: 14px;
	line-height: 22px;
	text-decoration: none;
}
.fe-footer-nav .wp-block-navigation-item__content:hover {
	color: #bdbdbd;
}
.fe-footer__bottom {
	background: var(--wp--preset--color--footer-deep);
	min-height: 30px;
}

@media (max-width: 599px) {
	.fe-logos img {
		width: 130px;
	}
}
