/**
 * GB — Prestations. Design « premium industriel » GB Couverture.
 * Thème cible : Mediverse.
 * Version: 2.0.2
 */

.gb-sv.gb-sv :where(h1, h2, h3, h4, h5, h6, p) { margin: 0; padding: 0; letter-spacing: normal; text-transform: none; }
.gb-sv.gb-sv :where(a, button, input, select, textarea, label) { text-transform: none; letter-spacing: normal; }
.gb-sv [hidden] { display: none !important; }
.gb-sv * { min-width: 0; }

.gb-sv {
	--gb-sv-cols: 4;
	--gb-sv-gap: 24px;
	--gb-sv-pad: 24px;
	--gb-sv-radius: 24px;
	--gb-sv-align: left;
	--gb-sv-or: #10529c;
	--gb-sv-or-clair: #4a86cc;
	--gb-sv-encre: #1e2a4b;
	--gb-sv-gris: #5a6a8a;
	--gb-sv-blanc: #ffffff;
	--gb-sv-creme: #eef4fb;
	--gb-sv-filet: rgba(16, 82, 156, 0.32);
	--gb-sv-titre-sombre: #ffffff;
	--gb-sv-ico: 1.3rem;
	--gb-sv-img-h: 170px;
	--gb-sv-bt-py: 11px;
	--gb-sv-bt-radius: 999px;
	--gb-sv-bt-bg1: #10529c;
	--gb-sv-bt-bg2: #1e2a4b;
	--gb-sv-bt-txt: #ffffff;
	--gb-sv-ease: cubic-bezier(0.22, 0.7, 0.25, 1);
	overflow-x: clip;
	color: var(--gb-sv-encre);
	text-align: var(--gb-sv-align);
}

/* ---- Grille / carrousel ---- */
.gb-sv__piste {
	display: grid;
	grid-template-columns: repeat(var(--gb-sv-cols), minmax(0, 1fr));
	gap: var(--gb-sv-gap);
	align-items: stretch;
}
.gb-sv--carrousel .gb-sv__piste {
	flex-wrap: nowrap;
	display: flex;
	overflow-x: auto;
	scroll-snap-type: x mandatory;
	scrollbar-width: none;
	padding-bottom: 6px;
}
.gb-sv--carrousel .gb-sv__piste::-webkit-scrollbar { display: none; }
.gb-sv--carrousel .gb-sv__carte {
	flex: 0 0 calc((100% - (var(--gb-sv-cols) - 1) * var(--gb-sv-gap)) / var(--gb-sv-cols));
	scroll-snap-align: start;
}
.gb-sv__piste:focus-visible { outline: 2px solid var(--gb-sv-or); outline-offset: 4px; border-radius: var(--gb-sv-radius); }

/* ---- Carte ---- */
.gb-sv__carte {
	position: relative;
	display: flex;
	flex-direction: column;
	overflow: hidden;
	background: var(--gb-sv-blanc);
	border: 1px solid var(--gb-sv-filet);
	border-radius: var(--gb-sv-radius);
	box-shadow: 0 22px 44px -30px rgba(30, 42, 75, 0.35);
	color: inherit;
	text-decoration: none;
	transition: transform 260ms var(--gb-sv-ease), box-shadow 260ms var(--gb-sv-ease);
}
.gb-sv__carte:hover { transform: translateY(-5px); box-shadow: 0 30px 54px -28px rgba(16, 82, 156, 0.45); }
.gb-sv__visuel { position: relative; height: var(--gb-sv-img-h); overflow: hidden; background: var(--gb-sv-creme); }
.gb-sv__visuel img { width: 100%; height: 100%; min-height: 100%; max-width: none; object-fit: cover; display: block; transition: transform 700ms var(--gb-sv-ease); }
.gb-sv__carte:hover .gb-sv__visuel img { transform: scale(1.07); }
.gb-sv__visuel::after {
	content: '';
	position: absolute;
	inset: 0;
	background: linear-gradient(135deg, rgba(16, 82, 156, 0.28), rgba(30, 42, 75, 0.42));
	pointer-events: none;
}

/* Médaillon rond chevauchant la photo */
.gb-sv .gb-sv__ico,
.gb-sv .gb-sv__medaillon {
	position: absolute;
	top: calc(var(--gb-sv-img-h) - 1.5em);
	left: var(--gb-sv-pad);
	z-index: 2;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 2.8em;
	height: 2.8em;
	font-size: var(--gb-sv-ico);
	color: #ffffff;
	background: linear-gradient(135deg, #10529c, #1e2a4b);
	border-radius: 50%;
	transition: transform 320ms var(--gb-sv-ease);
}
.gb-sv__carte:hover .gb-sv__ico,
.gb-sv__carte:hover .gb-sv__medaillon { transform: scale(1.08); }
.gb-sv .gb-sv__ico i, .gb-sv .gb-sv__ico svg,
.gb-sv .gb-sv__medaillon i, .gb-sv .gb-sv__medaillon svg { line-height: 1 !important; vertical-align: middle; }
.gb-sv .gb-sv__ico svg, .gb-sv .gb-sv__medaillon svg { width: 1em; height: 1em; }
.gb-sv__carte:not(:has(.gb-sv__visuel)) .gb-sv__ico,
.gb-sv__carte:not(:has(.gb-sv__visuel)) .gb-sv__medaillon { position: static; margin: var(--gb-sv-pad) var(--gb-sv-pad) 0; }

.gb-sv .gb-sv__badge {
	position: absolute;
	top: 14px;
	right: 14px;
	z-index: 2;
	padding: 5px 14px;
	background: #ca1e1e;
	color: #ffffff;
	border-radius: 999px;
	font-size: 0.76rem;
	font-weight: 700;
	letter-spacing: 0.04em;
}
.gb-sv .gb-sv__num {
	position: absolute;
	top: 10px;
	left: var(--gb-sv-pad);
	z-index: 2;
	color: rgba(255, 255, 255, 0.55);
	font-size: 1.8rem;
	font-weight: 900;
	line-height: 1;
}

.gb-sv__corps { display: flex; flex-direction: column; flex: 1 1 auto; padding: calc(var(--gb-sv-pad) + 14px) var(--gb-sv-pad) var(--gb-sv-pad); }
.gb-sv .gb-sv__titre {
	position: relative;
	padding-bottom: 12px;
	margin-bottom: 10px;
	font-size: 1.08rem;
	font-weight: 800;
}
.gb-sv .gb-sv__titre::after {
	content: '';
	position: absolute;
	left: 0;
	bottom: 0;
	width: 44px;
	height: 3px;
	border-radius: 2px;
	background: #ca1e1e;
	transition: width 320ms var(--gb-sv-ease);
}
.gb-sv__carte:hover .gb-sv__titre::after { width: 78px; }
.gb-sv .gb-sv__texte { color: var(--gb-sv-gris); line-height: 1.6; overflow-wrap: anywhere; }

/* Bouton pilule double anneau */
.gb-sv .gb-sv__btn {
	display: inline-flex;
	align-items: center;
	align-self: flex-start;
	margin-top: auto;
	padding: var(--gb-sv-bt-py, 11px) 22px;
	border: 0;
	border-radius: var(--gb-sv-bt-radius, 999px);
	background: linear-gradient(135deg, var(--gb-sv-bt-bg1, #10529c), var(--gb-sv-bt-bg2, #1e2a4b));
	box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.5);
	color: var(--gb-sv-bt-txt, #ffffff);
	font-weight: 700;
	font-size: 0.92rem;
	letter-spacing: normal;
	text-transform: none;
	text-decoration: none;
	cursor: pointer;
	transition: transform 220ms var(--gb-sv-ease), box-shadow 220ms var(--gb-sv-ease);
}
.gb-sv .gb-sv__btn:hover { transform: translateY(-2px); box-shadow: inset 0 0 0 3px rgba(255, 255, 255, 0.6), 0 14px 26px -14px rgba(16, 82, 156, 0.7); color: var(--gb-sv-bt-txt, #ffffff); }
.gb-sv--d-trame .gb-sv__btn, .gb-sv--d-esquisse .gb-sv__btn { background: transparent; box-shadow: none; padding-left: 0; color: var(--gb-sv-or); }
.gb-sv--d-trame .gb-sv__btn:hover, .gb-sv--d-esquisse .gb-sv__btn:hover { transform: none; color: #ca1e1e; }
.gb-sv .gb-sv__btn-fleche { display: inline-flex; margin-left: 10px !important; transition: transform 240ms var(--gb-sv-ease); }
.gb-sv .gb-sv__btn:hover .gb-sv__btn-fleche { transform: translateX(5px); }
.gb-sv .gb-sv__btn-fleche i, .gb-sv .gb-sv__btn-fleche svg { line-height: 1 !important; vertical-align: middle; }
.gb-sv .gb-sv__btn-txt { overflow-wrap: break-word; }

/* Média « image » : la photo remplace l'icône, même si une icône est saisie */
.gb-sv--m-image .gb-sv__ico { display: none; }
/* ---- Styles du bouton de carte (bt_style) ---- */
.gb-sv--b-lien .gb-sv__btn { background: transparent; box-shadow: none; padding-left: 0; padding-right: 0; color: var(--gb-sv-or); border-radius: 0; }
.gb-sv--b-lien .gb-sv__btn:hover { transform: none; box-shadow: none; color: #ca1e1e; }
.gb-sv--b-contour .gb-sv__btn { background: transparent; box-shadow: inset 0 0 0 2px var(--gb-sv-bt-bg1, #10529c); color: var(--gb-sv-bt-bg1, #10529c); }
.gb-sv--b-contour .gb-sv__btn:hover { background: linear-gradient(135deg, var(--gb-sv-bt-bg1, #10529c), var(--gb-sv-bt-bg2, #1e2a4b)); box-shadow: inset 0 0 0 2px rgba(255, 255, 255, 0.5); color: var(--gb-sv-bt-txt, #ffffff); }
.gb-sv--b-lien.gb-sv--p-marine .gb-sv__btn, .gb-sv--b-lien.gb-sv--d-zenith .gb-sv__btn { color: #8db4e8; }
.gb-sv--b-lien.gb-sv--p-marine .gb-sv__btn:hover, .gb-sv--b-lien.gb-sv--d-zenith .gb-sv__btn:hover { color: #ffffff; }

/* Pilotage carrousel : flèches groupées en bas à droite, puces à gauche */
.gb-sv__pilotage { display: flex; align-items: center; justify-content: space-between; margin-top: 18px; }
.gb-sv__puces { display: flex; gap: 8px; }
.gb-sv__puces button {
	width: 26px;
	height: 6px;
	padding: 0;
	border: 0;
	border-radius: 3px;
	background: var(--gb-sv-filet);
	cursor: pointer;
	transition: background 240ms var(--gb-sv-ease), width 240ms var(--gb-sv-ease);
}
.gb-sv__puces button[aria-selected='true'] { width: 42px; background: linear-gradient(90deg, #10529c, #1e2a4b); }
.gb-sv__puces button:focus-visible { outline: 2px solid var(--gb-sv-or); outline-offset: 3px; }
.gb-sv__fleches { display: flex; gap: 10px; }
.gb-sv__fleche {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 46px;
	height: 46px;
	border: 0;
	color: #ffffff;
	background: linear-gradient(135deg, #10529c, #1e2a4b);
	border-radius: 50%;
	cursor: pointer;
	transition: opacity 220ms var(--gb-sv-ease), transform 220ms var(--gb-sv-ease);
}
.gb-sv__fleche:hover { transform: translateY(-2px); }
.gb-sv__fleche:disabled { opacity: 0.35; cursor: default; transform: none; }
.gb-sv__fleche:focus-visible { outline: 2px solid var(--gb-sv-or); outline-offset: 3px; }
.gb-sv__fleche i, .gb-sv__fleche svg { line-height: 1 !important; vertical-align: middle; }

/* ---- Structures (designs) ---- */

/* Vedette : la première carte en grand */
@media (min-width: 901px) {
	.gb-sv--d-vedette .gb-sv__piste { grid-template-columns: repeat(var(--gb-sv-cols), minmax(0, 1fr)); }
	.gb-sv--d-vedette .gb-sv__piste > .gb-sv__carte:first-child {
		grid-column: span 2;
		grid-row: span 2;
	}
	.gb-sv--d-vedette .gb-sv__piste > .gb-sv__carte:first-child .gb-sv__visuel { height: calc(var(--gb-sv-img-h) * 1.9); }
	.gb-sv--d-vedette .gb-sv__piste > .gb-sv__carte:first-child .gb-sv__titre { font-size: 1.4rem; }
}

/* Chantier : structure de base */

/* Zénith : photo plein cadre, texte par-dessus */
.gb-sv--d-zenith .gb-sv__carte { min-height: 320px; justify-content: flex-end; }
.gb-sv--d-zenith .gb-sv__visuel { position: absolute; inset: 0; height: auto; }
.gb-sv--d-zenith .gb-sv__visuel::after { background: linear-gradient(135deg, rgba(16, 82, 156, 0.62), rgba(30, 42, 75, 0.8)); }
.gb-sv--d-zenith .gb-sv__corps { position: relative; z-index: 1; }
.gb-sv--d-zenith .gb-sv__titre { color: #ffffff; }
.gb-sv--d-zenith .gb-sv__texte { color: #d7e4f6; }

.gb-sv--d-zenith .gb-sv__ico, .gb-sv--d-zenith .gb-sv__medaillon { position: relative; top: auto; left: auto; margin: var(--gb-sv-pad) var(--gb-sv-pad) 0; z-index: 1; background: rgba(255, 255, 255, 0.16); }

/* Trame : filets, sans cartes */
.gb-sv--d-trame .gb-sv__carte { background: transparent; border: 0; border-radius: 0; box-shadow: none; border-top: 3px solid var(--gb-sv-filet); overflow: visible; }
.gb-sv--d-trame .gb-sv__carte:hover { transform: none; box-shadow: none; }
.gb-sv--d-trame .gb-sv__visuel { border-radius: var(--gb-sv-radius); margin-top: 16px; }
.gb-sv--d-trame .gb-sv__corps { padding-left: 0; padding-right: 0; }
.gb-sv--d-trame .gb-sv__ico, .gb-sv--d-trame .gb-sv__medaillon { top: calc(var(--gb-sv-img-h) + 16px - 1.5em); left: 14px; }

/* Esquisse : épuré */
.gb-sv--d-esquisse .gb-sv__carte { background: transparent; border: 0; box-shadow: none; overflow: visible; }
.gb-sv--d-esquisse .gb-sv__carte:hover { transform: none; box-shadow: none; }
.gb-sv--d-esquisse .gb-sv__visuel { display: none; }
.gb-sv--d-esquisse .gb-sv__ico, .gb-sv--d-esquisse .gb-sv__medaillon { position: static; margin: 0 0 12px; background: transparent; color: var(--gb-sv-or); clip-path: none; }
.gb-sv--d-esquisse .gb-sv__corps { padding: 0; }

/* Rivet : médaillon rond renforcé, double bordure */
.gb-sv--d-rivet .gb-sv__carte { border-width: 2px; border-color: var(--gb-sv-or); }
.gb-sv--d-rivet .gb-sv__ico, .gb-sv--d-rivet .gb-sv__medaillon { filter: drop-shadow(0 10px 18px rgba(16, 82, 156, 0.55)); }

/* ---- Palettes ---- */
.gb-sv--p-marine .gb-sv__carte { background: #1e2a4b; border-color: rgba(141, 180, 232, 0.28); }
.gb-sv--p-marine .gb-sv__titre { color: var(--gb-sv-titre-sombre); }
.gb-sv--p-marine .gb-sv__texte { color: #c9dbf4; }

.gb-sv--p-carmin .gb-sv__ico, .gb-sv--p-carmin .gb-sv__medaillon { background: linear-gradient(135deg, #ca1e1e, #8f1414); }
.gb-sv--p-carmin .gb-sv__titre::after { background: #10529c; }
.gb-sv--p-brume .gb-sv__carte { background: #f4f7fc; }
.gb-sv--p-givre .gb-sv__carte { background: var(--gb-sv-creme); }

/* ---- États du carrousel ---- */
.gb-sv__puces button.is-active { width: 42px; background: linear-gradient(90deg, #10529c, #1e2a4b); }
@media (prefers-reduced-motion: reduce) {
	.gb-sv__visuel img, .gb-sv__ico, .gb-sv__medaillon, .gb-sv__carte { transition: none; }
}

/* ---- Responsive ---- */
@media (max-width: 1100px) { .gb-sv__piste { grid-template-columns: repeat(2, minmax(0, 1fr)); } .gb-sv--carrousel .gb-sv__carte { flex-basis: calc((100% - var(--gb-sv-gap)) / 2); } }
@media (max-width: 640px) {
	.gb-sv__piste { grid-template-columns: minmax(0, 1fr); }
	.gb-sv--carrousel .gb-sv__carte { flex-basis: 100%; }
	.gb-sv--d-vedette .gb-sv__piste > .gb-sv__carte:first-child { grid-column: auto; grid-row: auto; }
}
