/*
Theme Name: Esprit Allié
Author: Esprit Allié
Description: Thème bloc sur mesure pour Esprit Allié.
Version: 0.1.0
Requires at least: 6.6
Requires PHP: 8.1
Text Domain: esprit-allie
*/

:root {
	--ea-header-height: 69px;
}

/* Visible keyboard focus everywhere (accessibility requirement). */
:where(a, button, input, select, textarea, summary):focus-visible {
	outline: 2px solid var(--ea-focus, var(--wp--preset--color--purple));
	outline-offset: 3px;
}

/* The purple outline has too little contrast on the navy header and footer; use white instead (the legal row text is grey). */
.site-header,
.site-footer {
	--ea-focus: var(--wp--preset--color--white);
}

/* Dropdown items sit on a white card inside the dark header: white would vanish. */
.site-header .wp-block-navigation__submenu-container {
	--ea-focus: var(--wp--preset--color--navy);
}

/* The sticky header must not cover anchor targets. */
html {
	scroll-padding-top: var(--ea-header-height);
}

/* Footer links inherit the light footer text color. */
.site-footer a {
	color: inherit;
}

/* Sticky dark header bar, as on the mockup. */
.site-header {
	position: sticky;
	top: 0;
	z-index: 50;
	min-height: var(--ea-header-height);
	isolation: isolate;
}

/* The translucent blurred background lives on a pseudo-element: a backdrop-filter on the header itself would make it
   the containing block of the fixed mobile menu overlay. */
.site-header::before {
	content: "";
	position: absolute;
	inset: 0;
	z-index: -1;
	background: rgb(12 35 47 / 0.88);
	backdrop-filter: blur(8px);
}

/* Below 601px WordPress makes the admin bar position:absolute, so the header stays at the top. */
@media (min-width: 601px) {
	.admin-bar .site-header {
		top: var(--wp-admin--admin-bar--height, 32px);
	}
}

.site-header__bar {
	min-height: var(--ea-header-height);
	align-items: center;
}

.site-logo {
	margin: 0;
}

.site-logo img {
	display: block;
	height: auto;
}

.site-header .wp-block-button__link {
	white-space: nowrap;
}

@media (max-width: 599px) {
	.site-header .wp-block-button__link {
		padding: 0.5rem 1rem;
		font-size: 0.875rem;
	}
}

.site-footer {
	padding-block: 64px 40px;
}

.site-footer__columns.is-layout-grid {
	/* The grid's column-width calc reads the block gap: set it there, not with a plain gap. */
	--wp--style--block-gap: 40px;
}

.site-footer__columns .wp-block-group > * + * {
	margin-block-start: 0;
}

.site-footer__title {
	margin-block: 0 10px;
	color: var(--wp--preset--color--yellow);
	font-size: 17px;
	font-style: italic;
	font-weight: 800;
}

.site-footer__columns .site-footer__brand p {
	max-width: 240px;
	margin-block: 20px 0;
	color: var(--wp--preset--color--purple-200);
	font-size: var(--wp--preset--font-size--small);
}

.site-footer .wp-block-buttons .wp-block-button,
.site-footer .wp-block-buttons .wp-block-button__link {
	display: block;
	width: 100%;
	box-sizing: border-box;
	text-align: center;
}

.site-footer__legal p {
	margin-block: 0;
}

.site-footer__legal {
	margin-top: 24px;
	padding-top: 20px;
	border-top: 1px solid var(--wp--preset--color--navy-700);
	font-family: var(--wp--preset--font-family--mono);
	font-size: 0.8125rem;
	color: var(--wp--preset--color--grey-200);
}

/* Mockup: compact, regular-weight link lists; legal links follow the muted legal row. */
.site-footer .wp-block-navigation,
.site-footer .wp-block-navigation__container {
	gap: 7px;
	font-size: 15px;
	line-height: 1.35;
}

.site-footer__legal .wp-block-navigation,
.site-footer__legal .wp-block-navigation__container {
	gap: 0.75rem;
}

.site-footer__legal .wp-block-navigation .wp-block-navigation-item__content {
	font-size: 0.8125rem;
}
