/* Mon Partenaire Tech : feuille commune à toutes les pages. */

@font-face {
	font-family: "Lexend";
	src: url("../fonts/lexend-latin-wght-normal.woff2") format("woff2");
	font-weight: 100 900;
	font-display: swap;
}
@font-face {
	font-family: "Source Sans 3";
	src: url("../fonts/source-sans-3-latin-wght-normal.woff2") format("woff2");
	font-weight: 200 900;
	font-display: swap;
}
@font-face {
	font-family: "Source Sans 3";
	src: url("../fonts/source-sans-3-latin-wght-italic.woff2") format("woff2");
	font-weight: 200 900;
	font-style: italic;
	font-display: swap;
}

:root {
	--encre: #0f172a;
	--encre-2: #1e293b;
	--texte: #1f2a3d;
	--texte-doux: #475569;
	--bleu: #1e3a8a;
	--bleu-clair: #93c5fd;
	--ambre: #b45309;
	--ambre-clair: #f59e0b;
	--fond: #f8fafc;
	--fond-2: #eef2f7;
	--blanc: #fff;
	--trait: #d8dfe9;
	--erreur: #b91c1c;
	--ok: #166534;
	--rayon: 12px;
	--rayon-petit: 8px;
	--ombre: 0 1px 2px rgb(15 23 42 / 6%), 0 8px 24px rgb(15 23 42 / 7%);
	--largeur: 1180px;
	--gouttiere: clamp(16px, 4vw, 40px);
	--titres: "Lexend", system-ui, sans-serif;
	--corps: "Source Sans 3", system-ui, sans-serif;
	--duree: 180ms;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
	margin: 0;
	background: var(--fond);
	color: var(--texte);
	font: 400 1.125rem/1.6 var(--corps);
	overflow-wrap: break-word;
}
[hidden] { display: none !important; }
img, svg, canvas { display: block; max-width: 100%; }
img { height: auto; }
h1, h2, h3 { color: var(--encre); font-family: var(--titres); font-weight: 600; line-height: 1.18; letter-spacing: -.012em; margin: 0 0 .6em; }
h1 { font-size: clamp(2rem, 1.4rem + 2.6vw, 3.25rem); }
h2 { font-size: clamp(1.45rem, 1.2rem + 1vw, 2rem); }
h3 { font-size: 1.2rem; }
p, ul, ol { margin: 0 0 1em; }
a { color: var(--bleu); text-underline-offset: .16em; }
a:hover { color: var(--ambre); }
:focus-visible { outline: 3px solid var(--ambre-clair); outline-offset: 3px; border-radius: 3px; }
main:focus { outline: none; }

.conteneur { width: min(100%, calc(var(--largeur) + 2 * var(--gouttiere))); margin-inline: auto; padding-inline: var(--gouttiere); }
.visuellement-cache { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; }
.lien-evitement { position: absolute; left: 12px; top: -80px; z-index: 100; padding: .7em 1em; background: var(--blanc); color: var(--encre); border-radius: var(--rayon-petit); }
.lien-evitement:focus { top: 12px; }

/* Thème sombre : en-tête, pied, haut de l'accueil et appels */
.theme-sombre { background: var(--encre); color: #d7dee9; }
.theme-sombre h1, .theme-sombre h2, .theme-sombre h3 { color: var(--fond); }
.theme-sombre a:not(.bouton) { color: var(--bleu-clair); }
.theme-sombre a:not(.bouton):hover { color: var(--ambre-clair); }

/* Boutons */
.bouton {
	display: inline-flex; align-items: center; justify-content: center; gap: .5em;
	min-height: 48px; padding: .55em 1.25em;
	border: 2px solid transparent; border-radius: var(--rayon-petit);
	font: 500 1rem/1.2 var(--titres); text-align: center; text-decoration: none; cursor: pointer;
	transition: background-color var(--duree), border-color var(--duree), color var(--duree), transform var(--duree);
}
.bouton:active { transform: translateY(1px); }
.bouton--accent { background: var(--ambre-clair); color: var(--encre); }
.bouton--accent:hover { background: #fbbf24; color: var(--encre); }
.bouton--contour { border-color: currentcolor; background: transparent; color: var(--bleu); }
.bouton--contour:hover { color: var(--ambre); }
.theme-sombre .bouton--contour { color: var(--fond); }
.theme-sombre .bouton--contour:hover { color: var(--ambre-clair); }

/* En-tête */
.entete { position: sticky; top: 0; z-index: 50; background: var(--encre); color: var(--fond); border-bottom: 1px solid rgb(255 255 255 / 9%); }
.entete__barre { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 68px; }
.entete__logo { display: block; flex: 0 1 auto; min-width: 0; padding-block: 8px; }
.entete__logo img { width: auto; height: 44px; }
.nav-large { display: none; }
.nav a { color: inherit; text-decoration: none; }
.nav a:not(.bouton):hover, .nav summary:hover { color: var(--ambre-clair); }
.nav a[aria-current="page"] { color: var(--ambre-clair); }

.nav-mobile { flex: none; }
.nav-mobile > summary {
	display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 0 10px;
	border: 1px solid rgb(255 255 255 / 28%); border-radius: var(--rayon-petit);
	font: 500 .95rem var(--titres); cursor: pointer; list-style: none;
}
.nav-mobile > summary::-webkit-details-marker, .nav__offres > summary::-webkit-details-marker { display: none; }
.nav-mobile[open] .nav {
	position: absolute; inset: 100% 0 auto; max-height: calc(100dvh - 68px); overflow-y: auto;
	display: flex; flex-direction: column; gap: 2px;
	padding: 12px var(--gouttiere) 24px; background: var(--encre); border-bottom: 1px solid rgb(255 255 255 / 12%);
}
.nav-mobile .nav > a:not(.bouton), .nav-mobile .nav__offres > summary { display: flex; align-items: center; min-height: 48px; font-family: var(--titres); }
.nav-mobile .nav .bouton { margin-top: 12px; }
.nav__offres > summary { cursor: pointer; list-style: none; }
.nav__offres > summary::after { content: ""; display: inline-block; width: .5em; height: .5em; margin-left: .55em; border: solid currentcolor; border-width: 0 2px 2px 0; transform: translateY(-.15em) rotate(45deg); transition: transform var(--duree); }
.nav__offres[open] > summary::after { transform: translateY(.05em) rotate(-135deg); }
.nav__offres ul { margin: 0; padding: 0; list-style: none; }
.nav-mobile .nav__offres li a { display: flex; align-items: center; min-height: 44px; padding-left: 14px; color: #cbd5e1; }

@media (min-width: 1120px) {
	.nav-mobile { display: none; }
	.nav-large { display: block; }
	.nav { display: flex; align-items: center; gap: clamp(14px, 1.6vw, 24px); font: 400 .98rem var(--titres); white-space: nowrap; }
	.nav > a:not(.bouton), .nav__offres > summary { display: inline-flex; align-items: center; min-height: 44px; }
	.nav__offres { position: relative; }
	.nav__offres ul {
		position: absolute; top: calc(100% + 8px); left: -14px; min-width: 330px; padding: 8px;
		background: var(--encre-2); border: 1px solid rgb(255 255 255 / 12%); border-radius: var(--rayon); box-shadow: 0 16px 40px rgb(0 0 0 / 35%);
	}
	.nav__offres li a { display: block; padding: 10px 12px; border-radius: 6px; white-space: normal; }
	.nav__offres li a:hover { background: rgb(255 255 255 / 7%); }
}

/* Haut des pages */
.tete-page { padding-block: clamp(36px, 6vw, 72px) clamp(28px, 4vw, 48px); background: var(--fond-2); border-bottom: 1px solid var(--trait); }
.surtitre { margin: 0 0 .7em; color: var(--ambre); font: 500 .9rem var(--titres); letter-spacing: .04em; text-transform: uppercase; }
.theme-sombre .surtitre { color: var(--ambre-clair); }
.chapo { max-width: 46rem; margin-bottom: 0; color: var(--texte-doux); font-size: clamp(1.15rem, 1.05rem + .4vw, 1.35rem); line-height: 1.5; }
.theme-sombre .chapo { color: #c6d0de; }
.tete-page__actions { margin: 1.4em 0 0; }

/* Contenu courant */
.contenu { padding-block: clamp(32px, 5vw, 64px); }
.contenu > * { max-width: 46rem; }
.contenu > .deux-colonnes, .contenu > .trois-colonnes, .contenu > .methode { max-width: none; }
.contenu h2 { margin-top: 1.7em; }
.contenu > h2:first-child { margin-top: 0; }
.contenu li { margin-bottom: .4em; }
.contenu--legal { font-size: 1.05rem; }
.contenu--legal h2 { font-size: 1.3rem; }
.a-completer { padding: .8em 1em; background: #fef3c7; border-left: 4px solid var(--ambre-clair); color: #5b3a06; }

.engagement { position: relative; padding: .9em 1.1em .9em 1.3em; background: var(--blanc); border: 1px solid var(--trait); border-left: 4px solid var(--ambre-clair); border-radius: 0 var(--rayon-petit) var(--rayon-petit) 0; color: var(--encre); font-weight: 500; }
.note { color: var(--texte-doux); font-size: 1rem; }

.deux-colonnes, .trois-colonnes { display: grid; gap: 20px; margin-block: 1.5em; }
@media (min-width: 720px) { .deux-colonnes { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 860px) { .trois-colonnes { grid-template-columns: repeat(3, 1fr); } }
.carte { padding: 22px; background: var(--blanc); border: 1px solid var(--trait); border-radius: var(--rayon); }
.carte > :last-child { margin-bottom: 0; }

.liste-coches { padding: 0; list-style: none; }
.liste-coches li { position: relative; padding-left: 1.7em; }
.liste-coches li::before { content: ""; position: absolute; left: .15em; top: .42em; width: .85em; height: .45em; border: solid var(--ambre); border-width: 0 0 2.5px 2.5px; transform: rotate(-45deg); }

.etapes-courtes { padding: 0; list-style: none; counter-reset: etape; }
.etapes-courtes li { position: relative; padding: 0 0 .8em 2.5em; counter-increment: etape; }
.etapes-courtes li::before { content: counter(etape); position: absolute; left: 0; top: 0; width: 1.8em; height: 1.8em; display: grid; place-items: center; background: var(--encre); color: var(--fond); border-radius: 50%; font: 500 .85rem var(--titres); }

.methode { display: grid; gap: 14px; padding: 0; list-style: none; counter-reset: methode; }
.methode li { position: relative; margin: 0; padding: 20px 22px 20px 74px; background: var(--blanc); border: 1px solid var(--trait); border-radius: var(--rayon); counter-increment: methode; }
.methode li::before { content: counter(methode); position: absolute; left: 20px; top: 20px; width: 38px; height: 38px; display: grid; place-items: center; background: var(--encre); color: var(--ambre-clair); border-radius: 50%; font: 600 1rem var(--titres); }
.methode h2 { margin: 0 0 .25em; font-size: 1.2rem; }
.methode p { margin: 0; }
@media (min-width: 860px) { .methode { grid-template-columns: repeat(2, 1fr); } .methode li:last-child { grid-column: 1 / -1; } }

/* Appel au devis */
.appel { padding-block: clamp(36px, 6vw, 64px); }
.appel__grille { display: grid; gap: 24px; align-items: center; }
.appel h2 { margin-bottom: .4em; }
.appel p { max-width: 42rem; margin: 0; }
@media (min-width: 860px) { .appel__grille { grid-template-columns: 1fr auto; gap: 56px; } }

.autres-offres { padding-block: clamp(32px, 5vw, 56px); }
.autres-offres h2 { font-size: 1.25rem; }
.autres-offres ul { display: grid; gap: 4px 28px; margin: 0; padding: 0; list-style: none; }
.autres-offres a { display: flex; align-items: center; min-height: 44px; }
@media (min-width: 720px) { .autres-offres ul { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .autres-offres ul { grid-template-columns: repeat(3, 1fr); } }

/* Réalisations */
.grille-projets { display: grid; gap: 20px; padding-bottom: clamp(40px, 6vw, 72px); }
@media (min-width: 900px) { .grille-projets { grid-template-columns: repeat(3, 1fr); } }
.projet { display: flex; flex-direction: column; padding: 24px; background: var(--blanc); border: 1px solid var(--trait); border-radius: var(--rayon); }
/* Logo IAboutique : texte blanc, il ne se lit que sur fond sombre. */
img[src*="realisations/iaboutique"] { padding: 6px 10px; background: var(--encre); border-radius: var(--rayon-petit); }
.projet img { width: auto; max-width: 220px; height: 56px; margin-bottom: 18px; object-fit: contain; object-position: left center; }
.projet h2 { font-size: 1.25rem; margin-bottom: .4em; }
.projet ul { padding-left: 1.1em; }
.projet > :last-child { margin-top: auto; margin-bottom: 0; }

/* Formulaire */
.devis { display: grid; gap: clamp(28px, 5vw, 56px); padding-block: clamp(32px, 5vw, 64px); }
@media (min-width: 960px) { .devis { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); align-items: start; } }
.devis__formulaire { padding: clamp(20px, 3vw, 32px); background: var(--blanc); border: 1px solid var(--trait); border-radius: var(--rayon); }
.devis__aparte h2 { font-size: 1.3rem; }
.champ { margin-bottom: 20px; border: 0; padding: 0; min-width: 0; }
.champ > label:not(.case), .champ > legend { display: block; margin-bottom: 6px; padding: 0; color: var(--encre); font-weight: 600; }
.champ input[type="text"], .champ input[type="email"], .champ input[type="tel"], .champ input[type="url"], .champ select, .champ textarea {
	width: 100%; min-height: 48px; padding: 10px 12px;
	background: var(--blanc); border: 1.5px solid #94a3b8; border-radius: var(--rayon-petit);
	color: var(--encre); font: inherit;
}
.champ textarea { min-height: 150px; resize: vertical; }
.champ input:focus, .champ select:focus, .champ textarea:focus { border-color: var(--bleu); outline: 2px solid var(--bleu); outline-offset: 0; }
.champ__aide { margin: 6px 0 0; color: var(--texte-doux); font-size: 1rem; }
.champ__erreur { margin: 6px 0 0; color: var(--erreur); font-weight: 600; font-size: 1rem; }
.champ [aria-invalid="true"] { border-color: var(--erreur); }
.choix { display: flex; flex-wrap: wrap; gap: 8px 12px; }
.choix label, .case { display: flex; align-items: flex-start; gap: 10px; min-height: 44px; padding: 10px 14px; border: 1.5px solid var(--trait); border-radius: var(--rayon-petit); cursor: pointer; font-weight: 400; }
.choix input, .case input { flex: none; width: 20px; height: 20px; min-height: 0; margin: 3px 0 0; padding: 0; accent-color: var(--bleu); }
.requis { color: var(--erreur); }
.champ-piege { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.message { margin-bottom: 22px; padding: 14px 16px; border-radius: var(--rayon-petit); border: 1.5px solid; }
.message--ok { background: #f0fdf4; border-color: var(--ok); color: #14532d; }
.message--erreur { background: #fef2f2; border-color: var(--erreur); color: #7f1d1d; }
.message > :last-child { margin-bottom: 0; }

/* Pied */
.pied { padding-block: clamp(40px, 6vw, 64px) 28px; background: var(--encre); color: #cbd5e1; font-size: 1.02rem; }
.pied__grille { display: grid; gap: 32px; }
.pied img { width: auto; height: 40px; margin-bottom: 14px; }
.pied h2 { margin-bottom: .7em; color: var(--fond); font-size: 1rem; }
.pied ul { margin: 0; padding: 0; list-style: none; }
.pied a { display: inline-flex; align-items: center; min-height: 36px; color: #cbd5e1; text-decoration: none; }
.pied a:hover { color: var(--ambre-clair); }
.pied__legal { margin-top: 32px; padding-top: 18px; color: #94a3b8; font-size: .95rem; }
@media (min-width: 720px) { .pied__grille { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1040px) { .pied__grille { grid-template-columns: 1.5fr 1.3fr 1fr 1.2fr; } }

@media (prefers-reduced-motion: reduce) {
	html { scroll-behavior: auto; }
	*, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; }
}
