/*
Theme Name: E-Digital
Theme URI: https://e-digital.fr/
Author: Jean-Luc Houédanou
Author URI: https://e-digital.fr/
Description: Converti par Jean-Luc Houédanou. Thème WordPress de l'agence E-Digital — agence de création de sites internet et d'applications mobiles à Paris. Thème block-ready (Gutenberg) construit à partir du site statique Mokko personnalisé pour E-Digital. Toutes les pages sont éditables dans l'éditeur de blocs.
Version: 1.0.0
Requires at least: 6.0
Tested up to: 6.5
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: http://www.gnu.org/licenses/gpl-2.0.html
Text Domain: edigital
Tags: agency, portfolio, blog, full-width-template, custom-menu, editor-style, block-styles, wide-blocks, featured-images
*/

/*
 * Les styles visuels complets sont chargés depuis assets/css/style.css et les
 * feuilles fournisseur via functions.php. Ce fichier sert uniquement d'en-tête
 * de thème et de point d'extension pour quelques correctifs spécifiques à
 * l'éditeur de blocs.
 */

.edigital-gutenberg-content > * + * { margin-top: 1.2em; }
.edigital-hero { position: relative; padding: 120px 0 80px; text-align: center; }
.edigital-hero h1 { font-size: clamp(2rem, 5vw, 4rem); }

/* ============================================================
 * CORRECTIFS CIBLÉS — chargés globalement, après assets/css/style.css
 * (handle « edigital-theme », dernier dans la file d'attente).
 * ============================================================ */

/* [Correctif 1] Page Contact — boutons réseaux sociaux toujours visibles.
 * Cause : le style de .contact-social-btn n'était injecté que sous la condition
 * is_page('contact') (inc/contact-form.php) — fausse depuis le slug SEO
 * « contact-devis-numerisation-78-75 ». Les liens existaient mais s'affichaient
 * en texte brut. On rend le style autonome (indépendant du slug et du conteneur),
 * avec une pastille de marque visible sur fond clair comme sombre et une couleur
 * d'icône explicite (jamais identique au fond). */
.contact-social-row {
	display: flex;
	flex-wrap: wrap;
	gap: 12px;
	margin-top: 24px;
}
.contact-social-btn {
	display: inline-flex !important;
	align-items: center;
	gap: 8px;
	background: #e31414;
	color: #fff !important;
	padding: 10px 18px;
	border-radius: 30px;
	font-size: .9rem;
	font-weight: 600;
	line-height: 1;
	text-decoration: none !important;
	transition: background .25s ease, transform .25s ease;
}
.contact-social-btn:hover {
	background: #b71010;
	color: #fff !important;
	transform: translateY(-2px);
}
.contact-social-btn i,
.contact-social-btn .fab,
.contact-social-btn .fa-brands {
	color: #fff !important;
	font-size: 1em;
	line-height: 1;
}

/* [Correctif 2] Page d'accueil — réduction du H1 du hero (bloc parallax-hero,
 * .ms-hero.four). La taille effective était 60px !important, imposée globalement
 * par inc/services-styles.php, ce qui « gelait » aussi le responsive prévu dans
 * assets/css/style.css. On rétablit une taille réduite et fluide (clamp) qui
 * reste lisible du mobile au desktop. Valeur ajustable si besoin. */
.ms-main .ms-page-content .ms-hero.four .ms-hc .ms-hero-title {
	font-size: clamp(1.6rem, 4vw, 2.9rem) !important;
	line-height: 1.15;
}

/* [Correctif 3] Page Contact — disposition 2 colonnes robuste.
 * Depuis que [edigital_devis] rend le vrai formulaire (large) dans la colonne
 * Gutenberg, la sidebar « Parlons de votre projet » s'écrasait en un filet
 * vertical. Cause : la largeur de la sidebar était définie sur
 * `.wp-block-column.contact-info-col` (inc/services-styles.php) ou sur le
 * `.contact-info-col` à 38 % (assets/css/style.css) — or la classe
 * `.contact-info-col` est portée par le <aside> INTERNE, pas par la colonne.
 * La colonne infos n'avait donc aucune largeur stable et passait sous le
 * formulaire en se réduisant. On cible ici la structure réellement rendue :
 * formulaire fluide + sidebar à largeur fixe, repli en pleine largeur en mobile. */
.wp-block-columns.contact-layout {
	align-items: flex-start;
	gap: 40px !important;
}
.wp-block-columns.contact-layout > .wp-block-column.contact-form-col {
	flex: 1 1 0 !important;
	width: auto !important;
	min-width: 0 !important; /* le formulaire peut rétrécir → pas de retour à la ligne forcé */
}
.wp-block-columns.contact-layout > .wp-block-column:not(.contact-form-col) {
	flex: 0 0 360px !important;
	width: 360px !important;
	max-width: 360px !important;
}
/* L'aside infos remplit sa colonne (annule le width:38% hérité). */
.wp-block-columns.contact-layout > .wp-block-column:not(.contact-form-col) .contact-info-col {
	width: 100% !important;
}
@media (max-width: 860px) {
	.wp-block-columns.contact-layout > .wp-block-column.contact-form-col,
	.wp-block-columns.contact-layout > .wp-block-column:not(.contact-form-col) {
		flex: 1 1 100% !important;
		width: 100% !important;
		max-width: 100% !important;
	}
}

/* ============================================================
 * [Refonte IA — nov. 2026] Nouveaux blocs : accueil, page
 * « Automatisation & Agents IA », étude de cas, formulaire court.
 * ============================================================ */

/* Bouton rouge réutilisable (liens dans le contenu). */
.edigital-btn-ia,
.edigital-diagnostic__btn {
	display: inline-block;
	background: #e31414;
	color: #fff !important;
	padding: 16px 32px;
	font-weight: 700;
	letter-spacing: .3px;
	text-decoration: none !important;
	border-radius: 6px;
	line-height: 1.35;
	transition: transform .3s ease, box-shadow .3s ease;
}
.edigital-btn-ia:hover,
.edigital-diagnostic__btn:hover {
	transform: translateY(-2px);
	box-shadow: 0 12px 28px rgba(227, 20, 20, .35);
}

/* Bandeau d'accueil : lien secondaire sous le bouton + titres longs. */
.ms-slide-secondary { margin: 18px auto 0; max-width: 620px; text-align: center; }
.ms-slide-secondary a {
	color: #fff;
	font-size: 1rem;
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 4px;
}
.ms-slide-secondary a:hover { color: #ff5a5a; }
.banner-horizental .ms-sc--t { font-size: clamp(2rem, 5.2vw, 5rem); line-height: 1.08; }
.banner-horizental .ms-sc--text { max-width: 640px; }
.banner-horizental .ms-cont__btn .btn { white-space: normal; height: auto; }

/* Sections IA de l'accueil. */
.edigital-ia-accueil,
.edigital-pourquoi,
.edigital-ia-section {
	max-width: 1320px;
	margin: 0 auto;
	padding: 0 24px;
}
.edigital-ia-accueil { padding-top: 90px; padding-bottom: 90px; }
.edigital-ia-accueil > p:first-child {
	text-transform: uppercase;
	letter-spacing: 2px;
	font-weight: 700;
	font-size: .85rem;
	color: #e31414;
	margin: 0;
}
.edigital-ia-accueil .project-area { padding: 20px 0 0 !important; }
.edigital-ia-accueil .project-area h2 { margin-top: 10px !important; }
.edigital-ia-accueil .service-text-grid { margin-bottom: 50px; }
.edigital-ia-accueil > p { font-size: 1.1rem; }
.edigital-pourquoi { padding-bottom: 100px; }
.edigital-pourquoi .service-text-grid { margin-top: 0; }

/* Tableau « Vous reconnaissez-vous ? ». */
.edigital-ia-section { padding-bottom: 40px; }
.edigital-ia-table { margin: 0; overflow-x: auto; }
.edigital-ia-table table { width: 100%; border-collapse: collapse; font-size: 1rem; }
.edigital-ia-table th {
	background: #111;
	color: #fff;
	text-align: left;
	padding: 16px 20px;
	font-weight: 700;
}
.edigital-ia-table td {
	padding: 18px 20px;
	border-bottom: 1px solid #e6e6e6;
	vertical-align: top;
	line-height: 1.6;
}
.edigital-ia-table td:first-child { font-weight: 700; color: #111; }
.edigital-ia-table td:last-child { color: #e31414; font-weight: 600; }
[data-theme="dark"] .edigital-ia-table td { border-color: #333; }
[data-theme="dark"] .edigital-ia-table td:first-child { color: #fff; }
@media (max-width: 767px) {
	.edigital-ia-table thead { display: none; }
	.edigital-ia-table tr { display: block; padding: 18px 0; border-bottom: 1px solid #e6e6e6; }
	.edigital-ia-table td { display: block; border: 0; padding: 4px 0; }
}

/* FAQ. */
.edigital-faq { max-width: 900px; padding-bottom: 90px; }
.edigital-faq details {
	border-bottom: 1px solid #e0e0e0;
	padding: 22px 0;
}
.edigital-faq summary {
	cursor: pointer;
	font-size: 1.15rem;
	font-weight: 700;
	list-style: none;
	position: relative;
	padding-right: 40px;
}
.edigital-faq summary::-webkit-details-marker { display: none; }
.edigital-faq summary::after {
	content: "+";
	position: absolute;
	right: 4px;
	top: -4px;
	font-size: 1.8rem;
	font-weight: 400;
	color: #e31414;
}
.edigital-faq details[open] summary::after { content: "–"; }
.edigital-faq details p { margin: 14px 0 0; line-height: 1.75; color: #555; }
.edigital-faq details a { color: #e31414; text-decoration: underline; }
[data-theme="dark"] .edigital-faq details p { color: #bbb; }

/* Bloc « Diagnostic gratuit » (remplace la newsletter sur l'accueil). */
.edigital-diagnostic {
	background: #111;
	color: #fff;
	padding: 90px 0;
	text-align: center;
}
.edigital-diagnostic__titre { color: #fff; font-size: clamp(1.7rem, 3.4vw, 2.6rem); margin-bottom: 18px; }
.edigital-diagnostic__texte { color: #cfcfcf; max-width: 720px; margin: 0 auto 32px; font-size: 1.05rem; line-height: 1.7; }

/* Boutons téléphone longs : retour à la ligne propre sur mobile. */
.service-cta .btn-cta,
.pricing-card .btn { white-space: normal; line-height: 1.35; height: auto; }
.pricing-card .btn { padding: 14px 18px; }

/* Étude de cas. */
.edigital-cas-enbref {
	background: #f8f8f8;
	border-left: 4px solid #e31414;
	padding: 28px 32px;
	margin-bottom: 40px;
	border-radius: 0 12px 12px 0;
}
.edigital-cas-enbref h3 { margin-top: 0; }
.edigital-cas-enbref ul { margin: 0; padding-left: 20px; }
.edigital-cas-enbref li { margin-bottom: 8px; line-height: 1.6; }
.entry-content .wp-block-quote {
	border-left: 5px solid #e31414;
	padding: 28px 32px;
	background: #f9f9f9;
	border-radius: 0 10px 10px 0;
	margin: 40px 0;
}
.entry-content .wp-block-quote p { font-size: 1.5rem; font-weight: 700; font-style: italic; margin: 0 0 10px; }
.entry-content .wp-block-quote cite { font-style: normal; color: #666; }
.edigital-cas-cta {
	background: #111;
	color: #fff;
	padding: 40px 32px;
	border-radius: 16px;
	text-align: center;
	margin-top: 50px;
}
.edigital-cas-cta h3 { color: #fff; margin-top: 0; }
[data-theme="dark"] .edigital-cas-enbref,
[data-theme="dark"] .entry-content .wp-block-quote { background: #1a1a1a; }

/* Formulaire de contact court. */
.ms-optional { margin: 10px 0 24px; }
.ms-optional > summary { cursor: pointer; font-weight: 600; color: #e31414; margin-bottom: 18px; }
.ms-step-subtitle a { color: #e31414; font-weight: 700; white-space: nowrap; }

/* Les groupes des nouveaux blocs ne doivent pas être bridés à la largeur de texte (810px). */
.edigital-ia-accueil .wp-block-group__inner-container > *,
.edigital-pourquoi .wp-block-group__inner-container > *,
.edigital-ia-section .wp-block-group__inner-container > * { max-width: none !important; }

/* Tarifs : titre lisible sur la carte noire, prix moins encombrant. */
.pricing-card[style*="background: #000"] h4 { color: #fff; }
.pricing-card .price { font-size: 2rem !important; line-height: 1.25; }

/* Bandeau : titre et bouton toujours visibles sur la diapo affichée, même si
 * l'animation d'entrée ne se déclenche pas (mobile, onglet en arrière-plan).
 * Le fondu entre diapos reste géré par l'opacité de la diapo elle-même. */
.banner-horizental .swiper-slide .ms-sc--t,
.banner-horizental .swiper-slide .ms-cont__btn { opacity: 1 !important; }
@media (max-width: 767px) {
	.banner-horizental .ms-sc--text { font-size: 1.05rem; line-height: 1.5; }
	.banner-horizental .ms-cont__btn .btn { font-size: 1rem; padding: 14px 18px; }
	.ms-slide-secondary a { font-size: .9rem; }
}
.banner-horizental .ms-sc--t { hyphens: none; -webkit-hyphens: none; word-break: normal; overflow-wrap: normal; }
@media (max-width: 480px) { .banner-horizental .ms-sc--t { font-size: 1.75rem; } }
