/*
Theme Name: Reseau CEMEA
Theme URI: https://reseau.cemea.org/
Author: Gwendoline
Description: Thème de blocs du site Reseau CEMEA — reprise sans Elementor de la page d'accueil d'origine.
Version: 1.0.3
Requires at least: 7.0
Requires PHP: 8.0
License: GPLv3
Text Domain: reseau
*/

/* ==========================================================================
   Base
   ========================================================================== */

html {
	scroll-behavior: auto;
}

body {
	margin: 0;
	font-family: var(--wp--preset--font-family--roboto);
	font-size: 22px;
	line-height: 1.8;
	color: #7a7a7a;
	background: #ffffff;
}

/* WordPress pose un margin-block-start sur * + * : dans une grille et entre
   les parties de gabarit, cela crée des décalages et des bandes blanches. */
.wp-site-blocks > *,
.wp-site-blocks > .wp-block-template-part,
main.wp-block-group,
.hero > *,
.cartes > * {
	margin-block-start: 0;
}

/* ==========================================================================
   Bandeau (hero)
   ========================================================================== */

.hero {
	position: relative;
	isolation: isolate;
	padding: 30px 0 205px;
	background-position: bottom center;
	background-size: cover;
	background-repeat: no-repeat;
	overflow: hidden;
}

/* Dégradé bleu -> rose posé sur la photo, comme la section Elementor d'origine */
.hero::before {
	content: "";
	position: absolute;
	inset: 0;
	background-image: linear-gradient(250deg, #3b5998 0%, #f12184 94%);
	opacity: 0.81;
	z-index: -1;
}

/* Courbe blanche du bas (même tracé que le divider Elementor) */
.hero .hero-shape {
	position: absolute;
	left: 50%;
	bottom: 0;
	transform: translateX(-50%);
	width: calc(200% + 1.3px);
	height: 470px;
	pointer-events: none;
	z-index: 0;
}

.hero .hero-shape svg {
	display: block;
	width: 100%;
	height: 100%;
	fill: #ffffff;
}

.hero .hero-inner {
	position: relative;
	z-index: 1;
	max-width: 1000px;
	margin-inline: auto;
	text-align: center;
}

.hero .hero-inner img {
	display: inline-block;
	width: 438px;
	max-width: 80%;
	height: auto;
	margin: 0 auto 20px;
}

.hero .hero-titre {
	margin: 0 0 20px;
	padding: 0;
	font-family: var(--wp--preset--font-family--roboto-slab);
	font-size: 65px;
	font-weight: 400;
	line-height: 1;
	color: #ffffff;
	text-align: center;
}

.hero .filet {
	width: 56px;
	margin: 0 auto;
	padding-block: 24px;
	border: 0;
	background: transparent;
}

.hero .filet::after {
	content: "";
	display: block;
	height: 3px;
	background: #ffffff;
}

/* ==========================================================================
   Les deux cartes
   ========================================================================== */

.cartes {
	position: relative;
	z-index: 2;
	max-width: 1000px;
	margin: -180px auto 0;
	padding: 0 0 90px;
	display: grid;
	grid-template-columns: 420px 460px;
	column-gap: 60px;
	align-items: start;
	justify-content: center;
	background: transparent;
}

.carte {
	background: #ffffff;
	border-radius: 5px;
	text-align: center;
}

.carte > * {
	margin-block-start: 0;
}

/* Carte de gauche : fond porté par le bloc, ombre marquée, marge haute */
.carte--zourit {
	margin-block-start: 20px !important;
	padding: 40px 20px;
	box-shadow: 0 0 10px 0 rgba(0, 0, 0, 0.5);
}

/* Carte de droite : padding plus large, bordure fine, ombre diffuse */
.carte--mallette {
	padding: 60px 40px 62px;
	border: 1px solid #d8d8d8;
	box-shadow: 0 0 30px 0 rgba(0, 0, 0, 0.1);
}

.carte figure {
	margin: 0 auto 15px;
	display: flex;
	justify-content: center;
}

/* Le pourcentage doit porter sur le lien (le <a> est en display:block et
   prend 100 % de la largeur) : posé sur l'img, il se calcule sur le lien
   lui-même et l'image tombe à 43 % de 43 %. */
.carte--zourit figure a {
	display: block;
	width: 43%;
	max-width: 163px;
}

.carte--mallette figure a {
	display: block;
	width: 49%;
	max-width: 185px;
}

.carte figure img {
	width: 100%;
	height: auto;
}

.carte h2 {
	margin: 51px 0 22px;
	font-size: 37.125px;
	font-weight: 600;
	line-height: 1.2;
	color: #3b5998;
	text-align: center;
}

.carte h2 a {
	color: inherit;
	text-decoration: none;
}

.carte p {
	margin: 0;
	font-size: 22px;
	line-height: 1.8;
	color: #a0a0a0;
	text-align: center;
}

/* ==========================================================================
   En-tête et pied de page des autres gabarits
   ========================================================================== */

.entete,
.pied {
	padding-block: 24px;
	background: #3b5998;
	color: #ffffff;
}

.entete {
	margin-bottom: 0;
}

.entete a,
.pied a {
	color: #ffffff;
	text-decoration: none;
}

.entete .wp-block-site-title {
	margin: 0;
	font-size: 26px;
	font-weight: 600;
}

.entete .wp-block-site-title a:hover,
.pied a:hover {
	text-decoration: underline;
}

.pied {
	margin-top: 0;
	font-size: 16px;
	line-height: 1.6;
}

.contenu-page {
	padding-block: 60px;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 1024px) {
	.cartes {
		grid-template-columns: minmax(0, 420px) minmax(0, 460px);
		column-gap: 40px;
		padding: 0 20px 65px;
	}
}

@media (max-width: 767px) {
	.hero {
		padding: 85px 20px 210px;
	}

	.hero .hero-inner {
		padding: 0 10px;
	}

	.hero .hero-inner img {
		max-width: 100%;
	}

	.hero .hero-titre {
		font-size: 47px;
	}

	.cartes {
		display: block;
		margin-top: -200px;
		padding: 0 20px 20px;
	}

	.carte--zourit {
		margin-block-start: 0 !important;
		margin-bottom: 30px;
	}

	.carte--zourit,
	.carte--mallette {
		padding: 40px 20px;
	}
}
