/*
 * Marchés financiers : page [buzzy_markets], bandeau, module de barre latérale
 * et encart fixe.
 *
 * Même procédé que fuel.css (voir docs/theme-variables.md) : chaque valeur lit
 * d'abord une variable du thème (Foxiz), avec une couleur de repli. Le mode
 * sombre de Foxiz redéfinit ces variables sur body[data-theme="dark"]. Tout est
 * scopé sous .wpb. Aucune taille de police de texte courant, aucune police à
 * empattement et aucun intitulé en capitales ne sont imposés : le rendu suit le
 * thème du site.
 */

.wpb {
	--wpb-bg: var(--solid-white, #ffffff);
	--wpb-ink: var(--body-fcolor, #16191d);
	--wpb-muted: var(--meta-fcolor, #5c6470);
	--wpb-line: var(--flex-gray-20, #e3e7ec);
	--wpb-soft: var(--flex-gray-7, #f5f7fa);
	--wpb-accent: var(--g-color, #1f6feb);
	--wpb-radius: var(--round-7, 12px);
	--wpb-font-title: var(--h2-family, var(--cs-heading-font, inherit));
	--wpb-up: #0a7d3b;
	--wpb-down: #c0392b;
	--wpb-flat: var(--wpb-muted);

	color: var(--wpb-ink);
}

/* The dark palette follows the theme (Foxiz body[data-theme="dark"]), never the
   visitor's system setting alone: a light theme keeps a light block. */
body[data-theme="dark"] .wpb {
	--wpb-bg: var(--solid-white, #14171c);
	--wpb-ink: var(--body-fcolor, #eef1f5);
	--wpb-muted: var(--meta-fcolor, #a2acba);
	--wpb-line: var(--flex-gray-20, #2a2f38);
	--wpb-soft: var(--flex-gray-7, #1b1f26);
	--wpb-up: #4ade80;
	--wpb-down: #f87171;
}

/* Texte réservé aux lecteurs d'écran. */
.wpb .wpb-sr {
	position: absolute;
	width: 1px;
	height: 1px;
	margin: -1px;
	padding: 0;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Variation : signe, flèche et couleur (jamais la couleur seule). */
.wpb .wpb-chg {
	font-variant-numeric: tabular-nums;
	white-space: nowrap;
}

.wpb .wpb-chg > span[aria-hidden] {
	font-size: .7em;
	vertical-align: .1em;
}

.wpb .wpb-up { color: var(--wpb-up); }
.wpb .wpb-down { color: var(--wpb-down); }
.wpb .wpb-flat { color: var(--wpb-flat); }

/* ---------- Page ---------- */

.wpb--page {
	max-width: 1000px;
	margin: 0 auto;
}

body .buzzy-page:has(.wpb--page) .buzzy-page__title {
	max-width: 1000px;
	font-size: clamp(2rem, 1.4rem + 2.2vw, 3rem);
	line-height: 1.15;
	text-align: left;
}

.wpb--page .wpb__intro {
	max-width: 760px;
	margin: 0 0 1.75em;
	font-size: 1.125em;
	line-height: 1.45;
	text-align: left;
}

.wpb--page .wpb__sec > p {
	line-height: 1.5;
}

.wpb--page .wpb__empty {
	padding: 2em 0;
	text-align: center;
	color: var(--wpb-muted);
}

.wpb--page .wpb__sec,
.wpb--page .wpb__related,
.wpb--page .wpb__sources {
	margin: 2.25em 0 0;
}

.wpb--page .wpb__h {
	margin: 0 0 .5em;
	font-family: var(--wpb-font-title);
	line-height: 1.2;
}

.wpb--page .wpb__date {
	margin: .5em 0 0;
	color: var(--wpb-muted);
	font-size: .8125em;
	font-style: italic;
	line-height: 1.4;
}

.wpb--page .wpb__scroll {
	margin-top: 1.25em;
	overflow-x: auto;
	border: 1px solid var(--wpb-line);
	border-radius: var(--wpb-radius);
}

.wpb--page .wpb__table {
	width: 100%;
	margin: 0;
	border: 0;
	border-collapse: collapse;
	background: var(--wpb-bg);
	font-variant-numeric: tabular-nums;
}

.wpb--page .wpb__table th,
.wpb--page .wpb__table td {
	padding: .65em .9em;
	border: 0;
	border-bottom: 1px solid var(--wpb-line);
	text-align: left;
	font-weight: inherit;
	background: transparent;
}

.wpb--page .wpb__table thead th {
	background: var(--wpb-soft);
	color: var(--wpb-muted);
	font-size: .875em;
	font-weight: 600;
}

.wpb--page .wpb__table tbody th {
	font-weight: 600;
}

.wpb--page .wpb__table tbody tr:last-child th,
.wpb--page .wpb__table tbody tr:last-child td {
	border-bottom: 0;
}

.wpb--page .wpb__table .wpb__num {
	text-align: right;
	white-space: nowrap;
}

.wpb--page .wpb__code {
	margin-left: .35em;
	color: var(--wpb-muted);
	font-size: .8125em;
	font-weight: 400;
}

.wpb--page .wpb__defs {
	margin: 1em 0 0;
}

.wpb--page .wpb__defs dt {
	margin: .9em 0 .15em;
	font-weight: 700;
}

.wpb--page .wpb__defs dd {
	margin: 0;
	color: var(--wpb-muted);
	line-height: 1.45;
}

.wpb--page .wpb__sources a {
	color: var(--wpb-accent);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.wpb--page .wpb__notice {
	margin: 2em 0 0;
	color: var(--wpb-muted);
	font-size: .875em;
}

/* Articles du site : image à la une et titre. Mobile : image à gauche. */
.wpb--page .wpb__relgrid {
	display: grid;
	grid-template-columns: 1fr;
	align-items: start;
	gap: .75rem;
	list-style: none !important;
	margin: 0 !important;
	padding: 0 !important;
}

.wpb--page .wpb__card {
	margin: 0 !important;
	padding: 0 !important;
	border: 1px solid var(--wpb-line);
	border-radius: var(--wpb-radius);
	background: var(--wpb-bg);
	overflow: hidden;
	transition: border-color .15s;
}

.wpb--page .wpb__card::before,
.wpb--page .wpb__card::marker {
	content: none;
	display: none;
}

.wpb--page .wpb__card:hover,
.wpb--page .wpb__card:focus-within {
	border-color: var(--wpb-accent);
}

.wpb--page a.wpb__cardlink {
	display: flex;
	align-items: stretch;
	color: var(--wpb-ink) !important;
	font-size: inherit !important;
	font-weight: inherit !important;
	text-decoration: none !important;
	background-image: none !important;
	padding: 0 !important;
}

.wpb--page .wpb__cardmedia {
	flex: 0 0 7rem;
	display: block;
	overflow: hidden;
	background: var(--wpb-line);
}

.wpb--page .wpb__cardmedia img.wpb__relimg {
	display: block;
	width: 100%;
	height: 100%;
	min-height: 5.5rem;
	margin: 0;
	object-fit: cover;
}

.wpb--page .wpb__cardtitle {
	display: block;
	align-self: center;
	padding: .75rem .875rem;
	font-family: var(--wpb-font-title);
	font-size: 1.0625rem;
	font-weight: 700;
	line-height: 1.25;
}

@media (min-width: 640px) {
	.wpb--page .wpb__relgrid {
		grid-template-columns: repeat(3, 1fr);
	}

	.wpb--page a.wpb__cardlink {
		flex-direction: column;
	}

	.wpb--page .wpb__cardmedia {
		flex: none;
		aspect-ratio: 16 / 9;
	}

	.wpb--page .wpb__cardmedia img.wpb__relimg {
		min-height: 0;
	}
}

/* ---------- Bandeau ---------- */

/* Hauteur fixe réservée : le bandeau ne décale jamais la page (pas de CLS). */
.wpb-ticker {
	display: flex;
	align-items: stretch;
	box-sizing: border-box;
	height: 40px;
	overflow: hidden;
	background: var(--wpb-soft);
	border-bottom: 1px solid var(--wpb-line);
	font-size: .875rem;
	line-height: 40px;
}

.wpb-ticker .wpb-ticker__label {
	flex: 0 0 auto;
	padding: 0 .9rem;
	background: var(--wpb-accent);
	color: #fff !important;
	font-weight: 700;
	text-decoration: none !important;
}

.wpb-ticker .wpb-ticker__view {
	flex: 1 1 auto;
	min-width: 0;
	overflow: hidden;
}

.wpb-ticker .wpb-ticker__track {
	display: flex;
	flex-wrap: nowrap;
	width: max-content;
	height: 100%;
	margin: 0;
	padding: 0;
	list-style: none;
}

/* La boucle ne tourne que quand le script a préparé la piste (copies du jeu
   d'éléments) ; sans lui, la bande reste fixe et se fait défiler à la main. */
.wpb-ticker.wpb-looping .wpb-ticker__track {
	animation: wpb-scroll var(--wpb-dur, 60s) linear infinite;
}

.wpb-ticker:not(.wpb-looping) .wpb-ticker__view {
	overflow-x: auto;
	overflow-y: hidden;
	scrollbar-width: thin;
}

.wpb-ticker .wpb-tk {
	flex: 0 0 auto;
	margin: 0;
	padding: 0 1.25rem 0 0;
	list-style: none;
	white-space: nowrap;
}

.wpb-ticker .wpb-tk::before,
.wpb-ticker .wpb-tk::marker {
	content: none;
}

.wpb-ticker .wpb-tk__name {
	font-weight: 700;
}

.wpb-ticker .wpb-tk__val {
	font-variant-numeric: tabular-nums;
}

.wpb-ticker .wpb-tk--post a {
	color: var(--wpb-ink);
	text-decoration: none;
}

.wpb-ticker .wpb-tk--post a::before {
	content: "\00b7\00a0";
	color: var(--wpb-muted);
}

.wpb-ticker .wpb-tk--post a:hover,
.wpb-ticker .wpb-tk--post a:focus-visible {
	color: var(--wpb-accent);
	text-decoration: underline;
}

.wpb-ticker.wpb-looping:hover .wpb-ticker__track,
.wpb-ticker.wpb-looping:focus-within .wpb-ticker__track {
	animation-play-state: paused;
}

@keyframes wpb-scroll {
	from { transform: translateX(0); }
	to { transform: translateX(-50%); }
}

/* Sans animation : la bande reste lisible et se fait défiler à la main ; la
   copies faites pour la boucle sont masquées. */
@media (prefers-reduced-motion: reduce) {
	.wpb-ticker .wpb-ticker__view {
		overflow-x: auto;
		overflow-y: hidden;
		scrollbar-width: thin;
	}

	.wpb-ticker.wpb-looping .wpb-ticker__track {
		animation: none;
	}

	.wpb-ticker .wpb-tk[aria-hidden="true"] {
		display: none;
	}
}

/* ---------- Module de barre latérale ---------- */

.wpb-side {
	margin: 0 0 1rem;
}

.wpb-side > .elementor-element + [data-wpb-body] {
	margin-top: var(--widgets-spacing-row, 20px);
}

.wpb-side .wpb-side__title {
	margin: 0 0 .4rem;
	font-family: var(--wpb-font-title);
	font-size: 1.0625rem;
	line-height: 1.25;
}

.wpb-side .wpb-side__list,
.wpb-sticky .wpb-sticky__list {
	margin: 0;
	padding: 0;
	list-style: none;
}

.wpb-side .wpb-side__list {
	border: 1px solid var(--wpb-line);
	border-radius: var(--wpb-radius);
	background: var(--wpb-bg);
}

/* Lignes compactes : une ligne par valeur, libellé à gauche, cours et variation
   à droite. */
.wpb-side .wpb-side__list li,
.wpb-sticky .wpb-sticky__list li {
	display: flex;
	flex-wrap: nowrap;
	align-items: baseline;
	gap: 0 .5rem;
	margin: 0;
	padding: .3rem .65rem;
	list-style: none;
	border-bottom: 1px solid var(--wpb-line);
	font-size: .875em;
	line-height: 1.3;
	font-variant-numeric: tabular-nums;
}

.wpb-side .wpb-side__list li::before,
.wpb-side .wpb-side__list li::marker,
.wpb-sticky .wpb-sticky__list li::before,
.wpb-sticky .wpb-sticky__list li::marker {
	content: none;
	display: none;
}

.wpb-side .wpb-side__list li:last-child,
.wpb-sticky .wpb-sticky__list li:last-child {
	border-bottom: 0;
}

.wpb .wpb-q__name {
	flex: 1 1 auto;
	min-width: 0;
	font-weight: 600;
}

.wpb .wpb-q__val {
	flex: none;
	margin-left: auto;
	text-align: right;
}

.wpb .wpb-q__chg {
	flex: none;
	min-width: 5.2em;
	font-size: .9em;
	text-align: right;
}

.wpb .wpb-q__fold {
	display: none;
}

.wpb-side .wpb-side__more,
.wpb-sticky .wpb-sticky__more {
	margin: .4rem 0 0;
	font-size: .875em;
}

.wpb-side .wpb-side__more a,
.wpb-sticky .wpb-sticky__more a {
	color: var(--wpb-accent);
	text-decoration: underline;
	text-underline-offset: 3px;
}

/* ---------- Encart fixe ---------- */

.wpb-sticky {
	display: none;
}

@media (min-width: 1024px) {
	.wpb-sticky {
		display: block;
		position: fixed;
		top: 50%;
		right: 0;
		z-index: 90;
		box-sizing: border-box;
		width: max-content;
		max-width: 16rem;
		transform: translateY(-50%);
		border: 1px solid var(--wpb-line);
		border-right: 0;
		border-radius: var(--wpb-radius) 0 0 var(--wpb-radius);
		background: var(--wpb-bg);
		box-shadow: 0 4px 18px rgba(0, 0, 0, .12);
		font-size: .8125rem;
		line-height: 1.3;
	}

	/* Sans JavaScript, ni bouton ni chiffres : seulement les libellés et les
	   flèches de tendance. */
	.wpb-sticky .wpb-sticky__toggle {
		display: none;
	}

	.wpb-sticky.wpb-js .wpb-sticky__toggle {
		display: flex;
		align-items: center;
		justify-content: space-between;
		gap: .5rem;
		width: 100%;
		margin: 0;
		padding: .3rem .65rem;
		border: 0;
		border-bottom: 1px solid var(--wpb-line);
		border-radius: var(--wpb-radius) 0 0 0;
		background: var(--wpb-soft);
		color: var(--wpb-ink);
		font: inherit;
		font-weight: 700;
		line-height: 1.3;
		text-align: left;
		text-transform: none;
		letter-spacing: normal;
		cursor: pointer;
	}

	.wpb-sticky .wpb-sticky__toggle:focus-visible {
		outline: 2px solid var(--wpb-accent);
		outline-offset: -2px;
	}

	/* Petite flèche : pointe vers la gauche (agrandir), vers la droite (replier). */
	.wpb-sticky .wpb-sticky__chev {
		display: inline-block;
		width: .45em;
		height: .45em;
		border-left: 2px solid currentColor;
		border-bottom: 2px solid currentColor;
		transform: rotate(45deg);
		transition: transform .15s;
	}

	.wpb-sticky .wpb-sticky__toggle[aria-expanded="true"] .wpb-sticky__chev {
		transform: rotate(-135deg);
	}

	.wpb-sticky .wpb-sticky__list li {
		padding: .25rem .65rem;
		gap: 0 .4rem;
	}

	.wpb-sticky .wpb-sticky__more {
		margin: 0;
		padding: .3rem .65rem;
		border-top: 1px solid var(--wpb-line);
	}

	/* Replié (par défaut, toutes largeurs) : le libellé en petit, la variation en
	   dessous en plus gros (ou la valeur du taux, qui n'a pas de variation). Ni
	   cours ni lien. */
	.wpb-sticky:not(.is-expanded) .wpb-q__val,
	.wpb-sticky:not(.is-expanded) .wpb-q__chg,
	.wpb-sticky:not(.is-expanded) .wpb-sticky__more {
		display: none;
	}

	.wpb-sticky:not(.is-expanded) .wpb-sticky__list li {
		flex-direction: column;
		align-items: flex-start;
		gap: .05rem;
		padding: .3rem .75rem;
	}

	.wpb-sticky:not(.is-expanded) .wpb-q__name {
		flex: none;
		font-size: .7rem;
		font-weight: 600;
		color: var(--wpb-muted);
	}

	.wpb-sticky:not(.is-expanded) .wpb-q__fold {
		display: block;
		font-size: 1rem;
		font-weight: 700;
		line-height: 1.2;
	}

	.wpb-sticky.is-expanded {
		width: 15rem;
	}
}

@media print {
	.wpb-ticker,
	.wpb-sticky {
		display: none !important;
	}
}
