/*
Theme Name: Anticipe
Description: Thème du site anticipe.io. Il reprend l'apparence de l'ancien thème Avada avec les blocs natifs de WordPress, sans constructeur de pages.
Version: 1.0.4
Requires at least: 7.0
Tested up to: 7.1
Requires PHP: 7.4
Author: Four Data
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: anticipe
*/

/* Icônes : polices Font Awesome 5 Free (SIL OFL 1.1, icônes CC BY 4.0), reprises de l'ancien thème */
@font-face {
	font-family: "Anticipe Icons";
	font-style: normal;
	font-weight: 900;
	font-display: block;
	src: url(assets/fonts/fa-solid-900.woff2) format("woff2");
}
@font-face {
	font-family: "Anticipe Icons";
	font-style: normal;
	font-weight: 400;
	font-display: block;
	src: url(assets/fonts/fa-regular-400.woff2) format("woff2");
}

/* Une icône s'ajoute en donnant la classe icon-xxx à un titre (Avancé > Classes CSS additionnelles) */
.icon-glass-whiskey { --anticipe-icon: "\f7a0"; }
.icon-battery-full { --anticipe-icon: "\f240"; }
.icon-wifi { --anticipe-icon: "\f1eb"; }
.icon-bell { --anticipe-icon: "\f0f3"; }
.icon-brain { --anticipe-icon: "\f5dc"; }
.icon-hands { --anticipe-icon: "\f2a3"; }
.icon-warning { --anticipe-icon: "\f071"; }
.icon-signature { --anticipe-icon: "\f573"; }
.icon-globe { --anticipe-icon: "\f57c"; }
.icon-truck { --anticipe-icon: "\f0d1"; }
.icon-copy { --anticipe-icon: "\f0c5"; --anticipe-icon-weight: 400; }
.icon-shower { --anticipe-icon: "\f2cc"; }

/* En-tête, contenu et pied de page se touchent, comme sur l'ancien site */
body .wp-site-blocks > * + * {
	margin-block-start: 0;
}

/* ---------- En-tête ---------- */

.anticipe-topbar {
	background: rgba(101, 188, 123, 0.09);
	border-bottom: 1px solid #e5e5e5;
}
.anticipe-topbar p {
	margin: 0;
	font-size: 12px;
	line-height: 44px;
}
.anticipe-topbar a {
	color: var(--wp--preset--color--text);
}

html {
	scroll-behavior: smooth;
}
.entry-content [id] {
	scroll-margin-top: 75px;
}

.anticipe-header {
	background: #fff;
}
.anticipe-header__inner {
	min-height: 133px;
	align-items: center;
	transition: min-height 0.2s;
}

/* Au défilement, l'en-tête passe en position fixe et se réduit ; son emplacement garde sa hauteur */
@media (min-width: 782px) {
	.wp-site-blocks > header {
		min-height: 178px;
	}
	.wp-site-blocks > header.is-stuck .anticipe-header {
		position: fixed;
		top: var(--wp-admin--admin-bar--height, 0px);
		left: 0;
		right: 0;
		z-index: 100;
		box-shadow: 0 1px 3px rgba(0, 0, 0, 0.12);
	}
	.wp-site-blocks > header.is-stuck .anticipe-header__inner {
		min-height: 75px;
	}
}
.anticipe-logo {
	margin: 0;
	flex-shrink: 0;
}

.anticipe-nav {
	font-family: var(--wp--preset--font-family--maven-pro);
	font-size: 13px;
	font-weight: 700;
	letter-spacing: 1px;
	color: var(--wp--preset--color--heading);
	gap: 0;
}
.anticipe-nav .wp-block-navigation__container {
	gap: 0;
	align-items: center;
}
.anticipe-nav .wp-block-navigation__container > .wp-block-navigation-item {
	padding-right: 45px;
}
.anticipe-nav .wp-block-navigation__container > .wp-block-navigation-item:last-child {
	padding-right: 0;
}
.anticipe-nav .wp-block-navigation-item__content:hover,
.anticipe-nav .wp-block-navigation-item__content.is-current {
	color: var(--wp--preset--color--brand);
}
.anticipe-nav .wp-block-navigation__submenu-icon {
	display: none;
}
.anticipe-nav .wp-block-navigation__responsive-container:not(.is-menu-open) .wp-block-navigation__submenu-container {
	min-width: 180px !important;
	background: #f2efef !important;
	border: 0 !important;
	border-top: 3px solid var(--wp--preset--color--brand) !important;
	box-shadow: 1px 1px 30px rgba(0, 0, 0, 0.06);
	font-family: var(--wp--preset--font-family--pt-sans);
	font-weight: 400;
	letter-spacing: 0;
	top: calc(100% + 45px) !important;
}
.anticipe-nav .wp-block-navigation__responsive-container:not(.is-menu-open) .wp-block-navigation__submenu-container .wp-block-navigation-item__content {
	padding: 7px 20px !important;
	border-bottom: 1px solid #dcdadb;
	width: 100%;
}

/* Menu mobile (plein écran) */
.anticipe-nav .wp-block-navigation__responsive-container.is-menu-open {
	--navigation-layout-justification-setting: flex-start;
	--navigation-layout-justify: flex-start;
	background: #fff;
	color: var(--wp--preset--color--heading);
	padding: 30px;
}
.anticipe-nav .is-menu-open .wp-block-navigation__responsive-container-content,
.anticipe-nav .is-menu-open .wp-block-navigation__container {
	align-items: flex-start !important;
	gap: 18px;
	font-size: 15px;
}
.anticipe-nav .is-menu-open .wp-block-navigation__container > .wp-block-navigation-item {
	padding-right: 0;
}
.anticipe-nav .is-menu-open .wp-block-navigation-submenu,
.anticipe-nav .is-menu-open .wp-block-navigation__submenu-container {
	align-items: flex-start !important;
	text-align: left;
}
.anticipe-nav .is-menu-open .wp-block-navigation__submenu-container {
	padding: 10px 0 0 20px !important;
	gap: 10px;
	font-family: var(--wp--preset--font-family--pt-sans);
	font-weight: 400;
	letter-spacing: 0;
}

/* Bouton « Connexion » du menu */
.anticipe-nav .anticipe-nav-button > .wp-block-navigation-item__content {
	display: inline-flex;
	align-items: center;
	background: var(--wp--preset--color--button);
	color: #fff;
	font-family: var(--wp--preset--font-family--pt-sans);
	font-weight: 400;
	letter-spacing: 0;
	text-transform: uppercase;
	line-height: 16px;
	padding: 11px 23px 11px 0;
	box-shadow: inset 0 1px 0 #fff, 0 3px 0 #54770f, 1px 5px 5px 3px rgba(0, 0, 0, 0.3);
}
.anticipe-nav .anticipe-nav-button > .wp-block-navigation-item__content::before {
	content: "\f1eb";
	font-family: "Anticipe Icons";
	font-weight: 900;
	font-size: 13px;
	padding: 0 12px 0 13px;
	margin: -11px 12px -11px 0;
	line-height: 38px;
	border-right: 1px solid rgba(255, 255, 255, 0.4);
}
.anticipe-nav .anticipe-nav-button > .wp-block-navigation-item__content:hover {
	background: var(--wp--preset--color--brand);
	color: #fff;
}

/* ---------- Contenu ---------- */

.anticipe-main {
	padding-bottom: 60px;
}
.anticipe-main:not(.is-front) {
	padding-top: 55px;
}
.anticipe-main.is-front {
	padding-top: 0;
	padding-bottom: 0;
}

/* Bandeau */
.wp-block-cover.anticipe-hero {
	align-items: flex-start;
	padding: 88px 30px 0;
}
.anticipe-hero .wp-block-cover__inner-container {
	width: 100%;
	max-width: 1100px;
	margin: 0 auto;
	color: #fff;
}
.anticipe-hero__title {
	background: rgba(0, 0, 0, 0.4);
	padding: 3px 15px 23px;
}
.anticipe-hero__title h1 {
	margin: 0;
	color: #fff;
	font-size: var(--wp--preset--font-size--hero);
	line-height: 1.333;
}
.anticipe-hero .wp-block-buttons {
	margin-top: 50px;
}

/* Titres de section et séparateurs */
.anticipe-section-title {
	margin: 0 0 42px;
}
.wp-block-separator.is-style-half {
	width: 48%;
	max-width: 528px;
	margin: 0 0 23px;
	border: 0;
	border-top: 1px solid #918f8e;
	opacity: 1;
}
.wp-block-separator.is-style-shadow {
	position: relative;
	height: 1px;
	margin: 0 auto 26px;
	border: 0;
	opacity: 1;
	background: linear-gradient(to right, rgba(150, 150, 150, 0) 0%, rgba(150, 150, 150, 0.65) 15%, #969696 50%, rgba(150, 150, 150, 0.65) 85%, rgba(150, 150, 150, 0) 100%);
}
.wp-block-separator.is-style-shadow::after {
	content: "";
	display: block;
	height: 6px;
	margin-top: 1px;
	background: radial-gradient(ellipse at 50% -50%, rgba(0, 0, 0, 0.35) 0, rgba(255, 255, 255, 0) 65%);
}

/* Introduction */
.entry-content > .anticipe-intro {
	margin-block-start: 0;
	padding-top: 55px;
	gap: 44px;
}
.anticipe-intro__title {
	color: var(--wp--preset--color--green);
	margin: 26px 0 23px;
}
.anticipe-lead {
	font-family: var(--wp--preset--font-family--antic-slab);
	font-size: 18px;
	line-height: 27px;
	color: var(--wp--preset--color--heading);
}

/* Blocs produits */
.entry-content > .anticipe-product {
	margin-block-start: 66px;
}
.entry-content > #jauge {
	margin-block-start: 42px;
}
.entry-content > #gps {
	margin-block-start: 82px;
}
.anticipe-product .wp-block-columns {
	gap: 44px;
	align-items: flex-start;
}
.anticipe-product figure {
	margin: 0;
}

/* Caractéristiques avec icône ronde : 3 colonnes (2 pour le bouton connecté), 1 sur mobile */
.wp-block-group.anticipe-features {
	gap: 40px 30px;
	grid-template-columns: repeat(3, minmax(0, 1fr));
}
.wp-block-group.anticipe-features.is-icon-top {
	grid-template-columns: repeat(4, minmax(0, 1fr));
}
.anticipe-feature > * {
	margin: 0;
}
.anticipe-feature h3 {
	display: flex;
	align-items: center;
	gap: 20px;
	min-height: 44px;
	margin-bottom: 15px;
}
.anticipe-feature h3::before {
	content: var(--anticipe-icon, "");
	flex: 0 0 42px;
	width: 42px;
	height: 42px;
	line-height: 42px;
	border: 1px solid var(--wp--preset--color--heading);
	border-radius: 50%;
	background: var(--wp--preset--color--icon);
	color: #fff;
	font-family: "Anticipe Icons";
	font-weight: var(--anticipe-icon-weight, 900);
	font-size: 21px;
	text-align: center;
}

/* Variante icône au-dessus, centrée (bouton connecté) */
.anticipe-features.is-icon-top .anticipe-feature {
	text-align: center;
}
.anticipe-features.is-icon-top .anticipe-feature h3 {
	flex-direction: column;
	gap: 13px;
	margin-bottom: 15px;
}

/* Variante icône sur fond gris (services) */
.anticipe-features.is-icon-boxed .anticipe-feature {
	text-align: center;
	font-family: var(--wp--preset--font-family--antic-slab);
	font-size: 18px;
	line-height: 35px;
	color: var(--wp--preset--color--heading);
}
.anticipe-features.is-icon-boxed .anticipe-feature::before {
	content: var(--anticipe-icon, "");
	display: block;
	width: 42px;
	height: 42px;
	margin: 0 auto 40px;
	line-height: 42px;
	border: 1px solid var(--wp--preset--color--heading);
	border-radius: 50%;
	background: rgba(211, 211, 211, 0.46);
	color: #2f7c34;
	font-family: "Anticipe Icons";
	font-weight: var(--anticipe-icon-weight, 900);
	font-size: 21px;
	text-align: center;
}
.anticipe-features.is-icon-boxed ul {
	margin: 0;
	padding: 0;
	list-style: none;
	text-align: left;
	font-size: 15px;
	line-height: 24px;
}
.anticipe-features.is-icon-boxed ul li::before {
	content: "–  ";
}

/* Services complémentaires */
.entry-content > .anticipe-services {
	margin-block-start: 153px;
}
.anticipe-services-title {
	color: var(--wp--preset--color--green);
	text-align: center;
	margin: 0 0 42px;
}
.anticipe-services-band {
	background-position: 50% 50%;
	background-size: cover;
	min-height: 527px;
}
.anticipe-services-intro {
	max-width: 1100px;
	margin: 0 auto 37px;
	text-align: center;
	font-family: var(--wp--preset--font-family--antic-slab);
	font-size: 18px;
	line-height: 27px;
	color: var(--wp--preset--color--muted);
}
.anticipe-services-box {
	background: rgba(255, 255, 255, 0.85);
	padding: 0 20px 40px;
	min-height: 413px;
}

/* Contact */
.entry-content > .anticipe-contact {
	margin-block-start: 20px;
}
.anticipe-contact {
	padding-top: 21px;
	padding-bottom: 18px;
	background-position: 50% 50%;
	background-size: cover;
}
.anticipe-contact .wp-block-columns {
	gap: 44px;
}
.anticipe-contact .wpcf7 p {
	margin: 0 0 20px;
}
.anticipe-contact .wpcf7 br {
	display: none;
}
.anticipe-contact .wpcf7 input[type="text"],
.anticipe-contact .wpcf7 input[type="email"],
.anticipe-contact .wpcf7 input[type="tel"],
.anticipe-contact .wpcf7 textarea {
	display: block;
	box-sizing: border-box;
	width: 100%;
	height: 35px;
	margin-bottom: 20px;
	padding: 6px 12px;
	border: 1px solid #ccc;
	border-radius: 5px;
	box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.075);
	background: #fff;
	color: #555;
	font: 14px/20px Arial, Helvetica, sans-serif;
}
.anticipe-contact .wpcf7 textarea {
	height: 120px;
}
.anticipe-contact .wpcf7 input[type="submit"] {
	border: 0;
	border-radius: 5px;
	padding: 11px 23px;
	background: var(--wp--preset--color--button);
	color: #fff;
	font: 13px/16px var(--wp--preset--font-family--pt-sans);
	text-transform: uppercase;
	cursor: pointer;
	box-shadow: inset 0 1px 0 #fff, 0 3px 0 #54770f, 1px 5px 5px 3px rgba(0, 0, 0, 0.3);
}
.anticipe-contact .wpcf7 input[type="submit"]:hover {
	background: var(--wp--preset--color--brand);
}
.anticipe-contact .wpcf7-response-output {
	color: #fff;
}
/* Champ piège anti-spam (functions.php) : hors de l'écran pour les visiteurs, rempli par les robots */
.wpcf7 .anticipe-hp {
	position: absolute !important;
	left: -9999px !important;
	width: 1px;
	height: 1px;
	overflow: hidden;
}
.anticipe-contact-info {
	text-align: center;
	color: #fff;
}
.anticipe-contact-info > * {
	margin: 0 0 18px;
}
.anticipe-contact-info h2 {
	color: #fff;
	font-size: 18px;
	line-height: 27px;
}
.anticipe-contact-info h3 {
	color: #fff;
	font-size: 16px;
	line-height: 24px;
}
.anticipe-contact-info a {
	color: #fff;
}
.anticipe-contact-info .wp-block-separator {
	width: 100%;
	border: 0;
	border-top: 1px solid rgba(255, 255, 255, 0.8);
	opacity: 1;
}

/* ---------- Pied de page ---------- */

.anticipe-footer {
	background: var(--wp--preset--color--footer);
	padding-top: 43px;
	padding-bottom: 73px;
	color: #8c8989;
	font-size: 13px;
	line-height: 19.5px;
}
.wp-block-group.anticipe-footer__grid {
	gap: 20px 30px;
	grid-template-columns: repeat(4, minmax(0, 1fr));
}
@media (max-width: 1023px) {
	.wp-block-group.anticipe-footer__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}
.anticipe-footer h4 {
	margin: 0 0 27px;
	font-family: var(--wp--preset--font-family--pt-sans);
	font-size: 13px;
	line-height: 19.5px;
	text-transform: uppercase;
	color: #ddd;
}
.anticipe-footer p,
.anticipe-footer ul {
	margin: 0;
}
.anticipe-footer__links {
	padding: 0;
	list-style: none;
}
.anticipe-footer a {
	color: #bfbfbf;
}
.anticipe-footer a:hover {
	color: var(--wp--preset--color--brand);
}
.anticipe-footer__social {
	justify-content: flex-start;
}
.anticipe-footer__social .wp-social-link {
	background: none !important;
	color: #bebdbd !important;
}
.anticipe-footer__social .wp-social-link svg {
	width: 16px;
	height: 16px;
	fill: currentColor;
}

.anticipe-copyright {
	background: var(--wp--preset--color--footer-dark);
	border-top: 1px solid #4b4c4d;
	padding-top: 18px;
	padding-bottom: 16px;
	color: #fff;
	font-size: 12px;
	line-height: 18px;
}
.anticipe-copyright p {
	margin: 0;
}

/* ---------- Petits écrans ---------- */

@media (max-width: 781px) {
	.wp-block-group.anticipe-features,
	.wp-block-group.anticipe-features.is-icon-top,
	.wp-block-group.anticipe-footer__grid {
		grid-template-columns: minmax(0, 1fr);
	}
	.anticipe-header__inner {
		min-height: 90px;
	}
	.anticipe-topbar p {
		text-align: center;
	}
	.wp-block-cover.anticipe-hero {
		min-height: 200px !important;
		padding-top: 40px;
		padding-bottom: 30px;
	}
	.anticipe-hero__title {
		padding-bottom: 8px;
	}
	.anticipe-hero__title h1 {
		font-size: 22px;
		line-height: 1.45;
	}
	.anticipe-hero .wp-block-buttons {
		margin-top: 25px;
	}
	.wp-block-separator.is-style-half {
		width: 100%;
	}
	.anticipe-product {
		margin-top: 50px;
	}
	.anticipe-services {
		margin-top: 70px;
	}
	.anticipe-nav .anticipe-nav-button > .wp-block-navigation-item__content {
		margin-top: 10px;
	}
}
