/* =========================================================================
   Invest-enligne — Header
   Every rule is scoped under #ieh-header (id specificity) so the theme/kit
   global styles (e.g. `.elementor-kit-6 a {font-weight:700;font-size:18px}`)
   cannot bleed in. The header is position:fixed so page content never shifts.
   ========================================================================= */

:root {
	--ieh-navy: #0b1546;
	--ieh-navy-2: #11184A;
	--ieh-accent: #F18815;
	--ieh-ink: #2a3257;
	--ieh-muted: #737b98;
	--ieh-line: #e9ecf5;
	--ieh-soft: #f4f6fb;
	--ieh-bar-h: 76px;
	--ieh-max: 1380px;
	--ieh-radius: 16px;
	--ieh-shadow: 0 10px 34px rgba(11, 21, 70, .07);
	--ieh-font: "Plus Jakarta Sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

#ieh-header,
#ieh-header * {
	box-sizing: border-box;
}

/* Reset anything the global theme/kit forces onto our anchors/buttons/lists */
#ieh-header a,
#ieh-header button {
	font-family: var(--ieh-font);
	text-decoration: none;
	border: 0;
	background: none;
	box-shadow: none;
	letter-spacing: normal;
	-webkit-tap-highlight-color: transparent;   /* no grey flash box on mobile tap */
}
#ieh-header a::before,
#ieh-header a::after,
#ieh-header .profil-txt::before,
#ieh-header .profil-txt::after {
	content: none !important;
}
#ieh-header ul {
	list-style: none;
	margin: 0;
	padding: 0;
}

#ieh-header {
	position: fixed;
	top: 0;
	left: 0;
	right: 0;
	z-index: 9990;
	font-family: var(--ieh-font);
	-webkit-font-smoothing: antialiased;
}

/* ---- The shell: ONE white floating box that holds the bar AND the mega-menu.
        When a tab opens, the shell simply grows taller to reveal the products
        (no separate panel, no seam). ---- */
#ieh-header .ieh-shell {
	max-width: var(--ieh-max);
	margin: 26px auto 0;
	background: #fff;
	border-radius: var(--ieh-radius);
	box-shadow: var(--ieh-shadow);
	transition: margin-top .25s ease, box-shadow .25s ease;
}
#ieh-header.is-scrolled .ieh-shell {
	/* keep the bar position fixed on scroll (no upward shift = no "retract") */
	box-shadow: 0 14px 40px rgba(11, 21, 70, .14);
}
#ieh-header.is-panel-open .ieh-shell {
	box-shadow: 0 30px 54px -14px rgba(11, 21, 70, .22);
}

/* Top bar = the flex row only; the white box is the shell around it */
#ieh-header .ieh-bar {
	position: relative;
	height: var(--ieh-bar-h);
	display: flex;
	align-items: center;
	gap: 34px;
	padding: 0 30px;
}

/* Collapsible region — JS sets an explicit height so it animates open, closed,
   AND morphs between sections of different heights. */
#ieh-header .ieh-expand-inner {
	position: relative;
	overflow: hidden;
	height: 0;
	transition: height .32s cubic-bezier(.4, 0, .2, 1);
}

#ieh-header .ieh-logo {
	display: inline-flex;
	align-items: center;
	flex: 1 1 0;          /* equal side -> nav stays truly centered */
	min-width: 0;
}
#ieh-header .ieh-logo img {
	width: auto;
	height: auto;
	max-width: 198px; /* +25 % (était 158px) */
	display: block;
}

/* ---- Primary nav ---- */
#ieh-header .ieh-nav {
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 6px;
	flex: 0 0 auto;
}
#ieh-header .ieh-tab {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	padding: 10px 14px;
	font-size: 15px;
	font-weight: 500;
	color: var(--ieh-navy);
	border-radius: 10px;
	line-height: 1;
	cursor: pointer;
	white-space: nowrap;
	transition: color .15s ease, background .15s ease;
}
#ieh-header .ieh-tab:hover,
#ieh-header .ieh-tab.is-active {
	color: var(--ieh-accent);
	background: var(--ieh-soft);
}
#ieh-header .ieh-chevron {
	width: 7px;
	height: 7px;
	border-right: 2px solid currentColor;
	border-bottom: 2px solid currentColor;
	transform: rotate(45deg);
	transition: transform .2s ease;
	opacity: .55;
	margin-top: -3px;
}
#ieh-header .ieh-tab.is-active .ieh-chevron {
	transform: rotate(-135deg);
	margin-top: 2px;
}

/* ---- Right-side actions ---- */
#ieh-header .ieh-actions {
	display: flex;
	align-items: center;
	justify-content: flex-end;
	gap: 14px;
	flex: 1 1 0;          /* equal side -> nav stays truly centered */
	min-width: 0;
}

/* Auth buttons (logged out) */
#ieh-header .ieh-auth {
	display: flex;
	align-items: center;
	gap: 10px;
}
#ieh-header .ieh-btn {
	display: inline-flex;
	align-items: center;
	height: 44px;
	padding: 0 22px;
	border-radius: 999px;
	font-size: 14.5px;
	font-weight: 600;
	line-height: 1;
	transition: all .15s ease;
	white-space: nowrap;
}
#ieh-header .ieh-btn--ghost {
	color: var(--ieh-navy);
	box-shadow: inset 0 0 0 1.5px var(--ieh-line);
}
#ieh-header .ieh-btn--ghost:hover {
	box-shadow: inset 0 0 0 1.5px var(--ieh-navy);
}
#ieh-header .ieh-btn--solid {
	color: #fff;
	background: var(--ieh-accent);
}
#ieh-header .ieh-btn--solid:hover {
	background: #d9760a;
}

/* Account control (logged in) — one cohesive pill. DER badge attaches here. */
#ieh-header .ieh-account {
	position: relative;     /* the dropdown aligns to the profile pill */
}
#ieh-header .ieh-account-toggle {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	height: 48px;
	padding: 0 16px 0 6px;
	background: var(--ieh-soft);
	border-radius: 999px;
	font-size: 14.5px;
	font-weight: 600;
	color: var(--ieh-navy);
	line-height: 1;
	cursor: pointer;
	white-space: nowrap;
	transition: background .15s ease, box-shadow .15s ease;
	/* never overflow:hidden — the DER badge span flows inline */
}
#ieh-header .ieh-account-toggle:hover {
	background: #e9eefa;
}
/* Navy circular avatar with white person glyph (the only filled element) */
#ieh-header .ieh-account-ico {
	width: 36px;
	height: 36px;
	border-radius: 50%;
	flex: 0 0 auto;
	order: -1;
	background: var(--ieh-navy) no-repeat center / 19px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='white' d='M12 12a5 5 0 1 0-5-5 5 5 0 0 0 5 5zm0 2c-4 0-9 2-9 5v1h18v-1c0-3-5-5-9-5z'/%3E%3C/svg%3E");
}
#ieh-header .ieh-account .ieh-chevron {
	opacity: .6;
}
/* Profile dropdown — sized to its content, drops right from the profile pill */
#ieh-header .ieh-account-menu {
	position: absolute;
	top: calc(100% + 8px);       /* emerges just under the profile button */
	right: 0;                    /* aligned with the profile pill */
	width: max-content;
	min-width: 184px;
	max-width: 280px;
	background: #fff;
	border: 1px solid var(--ieh-line);
	border-radius: 14px;
	box-shadow: 0 22px 46px -16px rgba(11, 21, 70, .28);
	padding: 7px;
	opacity: 0;
	visibility: hidden;
	transform-origin: top right;
	transform: translateY(-8px) scale(.95);
	transition: opacity .18s ease, transform .24s cubic-bezier(.2, .8, .3, 1), visibility .24s;
	z-index: 40;
}
#ieh-header .ieh-account.is-open .ieh-account-menu {
	opacity: 1;
	visibility: visible;
	transform: none;
}

/* Items with icons */
#ieh-header .ieh-mi {
	display: flex;
	align-items: center;
	gap: 11px;
	padding: 11px 12px;
	border-radius: 10px;
	color: var(--ieh-ink);
	font-size: 14px;
	font-weight: 600;
	line-height: 1;
}
#ieh-header .ieh-mi svg { width: 18px; height: 18px; flex: 0 0 auto; color: var(--ieh-muted); transition: color .15s ease; }
#ieh-header .ieh-mi:hover { background: var(--ieh-soft); color: var(--ieh-navy); }
#ieh-header .ieh-mi:hover svg { color: var(--ieh-accent); }
#ieh-header .ieh-mi-sep { display: block; height: 1px; background: var(--ieh-line); margin: 6px 10px; }
/* Déconnexion in red */
#ieh-header .ieh-mi--danger,
#ieh-header .ieh-mi--danger svg { color: #d7263d; }
#ieh-header .ieh-mi--danger:hover { background: #fdecef; color: #d7263d; }
#ieh-header .ieh-mi--danger:hover svg { color: #d7263d; }

/* ---- Mega panel content. Panels are stacked (absolute) so changing section
        CROSS-FADES the cards (appear/disappear) instead of popping. ---- */
#ieh-header .ieh-panel {
	position: absolute;
	top: 0;
	left: 0;
	right: 0;
	opacity: 0;
	visibility: hidden;
	transition: opacity .18s ease, visibility .18s;
	pointer-events: none;
}
#ieh-header .ieh-panel.is-open {
	opacity: 1;
	visibility: visible;
	pointer-events: auto;
}
/* Cards/blocks rise + fade in, staggered (replaces the flat cross-fade) */
#ieh-header .ieh-panel.is-open .ieh-card,
#ieh-header .ieh-panel.is-open .ieh-block {
	animation: ieh-rise .5s cubic-bezier(.2, .7, .3, 1) both;
}
/* The shared contact panel animates once when the menu OPENS, but stays put
   when switching sections (is-panel-open persists across switches). */
#ieh-header.is-panel-open .ieh-contact {
	animation: ieh-rise .5s cubic-bezier(.2, .7, .3, 1) both;
	animation-delay: .04s;
}
@keyframes ieh-rise {
	from { opacity: 0; transform: translateY(20px); }
	to   { opacity: 1; transform: none; }
}
#ieh-header .ieh-panel.is-open .ieh-card:nth-child(1) { animation-delay: .02s; }
#ieh-header .ieh-panel.is-open .ieh-card:nth-child(2) { animation-delay: .055s; }
#ieh-header .ieh-panel.is-open .ieh-card:nth-child(3) { animation-delay: .09s; }
#ieh-header .ieh-panel.is-open .ieh-card:nth-child(4) { animation-delay: .125s; }
#ieh-header .ieh-panel.is-open .ieh-card:nth-child(5) { animation-delay: .16s; }
#ieh-header .ieh-panel.is-open .ieh-card:nth-child(6) { animation-delay: .195s; }
#ieh-header .ieh-panel.is-open .ieh-card:nth-child(7) { animation-delay: .23s; }
#ieh-header .ieh-panel.is-open .ieh-block:nth-child(2) { animation-delay: .07s; }
/* Layout: cards (left, swap per section) + shared contact (right).
   Divider hairline between the bar and the products. */
#ieh-header .ieh-expand-grid {
	border-top: 1px solid var(--ieh-line);
	padding: 30px 32px 34px;
	display: grid;
	grid-template-columns: 1fr 330px;
	gap: 34px;
	align-items: start;
}
#ieh-header .ieh-panels {
	position: relative;   /* stacked card panels are absolute within this */
	min-width: 0;
}
/* When the profile dropdown opens, the mega yields space on the right (no close).
   NOTE: padding is intentionally NOT transitioned — JS measures height right
   after toggling the squeeze; a transition would make that measurement stale. */
#ieh-header.is-squeezed .ieh-expand-grid {
	padding-right: 286px;
}

/* Cards */
#ieh-header .ieh-cards {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
}
#ieh-header .ieh-card {
	display: flex;
	align-items: flex-start;
	gap: 14px;
	padding: 18px 20px;
	border: 1px solid var(--ieh-line);
	border-radius: 14px;
	background: #fff;
	transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
	position: relative;
}
#ieh-header .ieh-card:hover {
	border-color: transparent;
	box-shadow: 0 14px 30px rgba(11, 21, 70, .1);
	background: #fff;
}
#ieh-header .ieh-card-ico {
	flex: 0 0 auto;
	width: 44px;
	height: 44px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: var(--ieh-soft);
	border-radius: 12px;
}
#ieh-header .ieh-card-ico img { width: 24px; height: 24px; }
#ieh-header .ieh-card-body { display: flex; flex-direction: column; gap: 5px; padding-right: 10px; }
#ieh-header .ieh-card-title {
	font-size: 15px;
	font-weight: 700;
	color: var(--ieh-navy);
	letter-spacing: -0.01em;
}
#ieh-header .ieh-card-desc {
	font-size: 13px;
	font-weight: 400;
	line-height: 1.5;
	color: var(--ieh-muted);
}
#ieh-header .ieh-card-arrow {
	position: absolute;
	right: 14px;
	bottom: 14px;
	width: 24px;
	height: 24px;
	border-radius: 50%;
	background: var(--ieh-soft);
	opacity: 0;
	transition: opacity .15s ease;
}
#ieh-header .ieh-card-arrow::after {
	content: "";
	position: absolute;
	inset: 0;
	-webkit-mask: no-repeat center/11px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M5 12h12l-5-5 1.4-1.4L21 12l-7.6 6.4L12 17l5-5H5z'/%3E%3C/svg%3E");
	mask: no-repeat center/11px url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath fill='black' d='M5 12h12l-5-5 1.4-1.4L21 12l-7.6 6.4L12 17l5-5H5z'/%3E%3C/svg%3E");
	background: var(--ieh-accent);
}
#ieh-header .ieh-card:hover .ieh-card-arrow { opacity: 1; }

/* Ressources blocks */
#ieh-header .ieh-blocks { display: grid; grid-template-columns: repeat(2, 1fr); gap: 16px; }
#ieh-header .ieh-block {
	display: flex;
	flex-direction: column;
	gap: 6px;
	padding: 22px;
	border: 1px solid var(--ieh-line);
	border-radius: 14px;
	transition: box-shadow .15s ease, transform .15s ease;
}
#ieh-header .ieh-block:hover { box-shadow: 0 14px 30px rgba(11, 21, 70, .1); border-color: transparent; }
#ieh-header .ieh-block-title { font-weight: 700; color: var(--ieh-navy); font-size: 16px; }
#ieh-header .ieh-block-desc { color: var(--ieh-muted); font-size: 13px; font-weight: 400; }

/* Contact panel — compact so it never drives the dropdown height */
#ieh-header .ieh-contact {
	background: linear-gradient(160deg, #f4f7fc 0%, #eaf0f9 100%);
	border-radius: 14px;
	padding: 16px;
	display: flex;
	flex-direction: column;
	gap: 12px;
}
#ieh-header .ieh-contact-head {
	display: flex;
	align-items: flex-start;
	justify-content: space-between;
	gap: 12px;
}
#ieh-header .ieh-contact-headings { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
#ieh-header .ieh-contact-eyebrow { margin: 0; font-size: 15px; font-weight: 800; color: var(--ieh-navy); letter-spacing: -0.01em; line-height: 1.2; }
#ieh-header .ieh-contact-note { font-size: 11.5px; font-weight: 600; color: var(--ieh-muted); }

/* Avatars — inline with the heading, small */
#ieh-header .ieh-advisor-avatars { display: inline-flex; flex: 0 0 auto; }
#ieh-header .ieh-avatar {
	width: 32px;
	height: 32px;
	border-radius: 50%;
	border: 2px solid #fff;
	object-fit: cover;
	object-position: center 30%;
	margin-left: -10px;
	box-shadow: 0 2px 6px rgba(11, 21, 70, .14);
	background: #dde4f1;
}
#ieh-header .ieh-advisor-avatars .ieh-avatar:first-child { margin-left: 0; }

/* Three contact buttons: phone / rendez-vous / email — compact, single line */
#ieh-header .ieh-contact-actions { display: flex; flex-direction: column; gap: 7px; }
#ieh-header .ieh-cbtn {
	display: flex;
	align-items: center;
	gap: 9px;
	padding: 5px 9px;
	background: #fff;
	border: 1px solid rgba(11, 21, 70, .07);
	border-radius: 10px;
	transition: box-shadow .15s ease, transform .15s ease, border-color .15s ease;
}
#ieh-header .ieh-cbtn:hover {
	border-color: transparent;
	box-shadow: 0 8px 20px rgba(11, 21, 70, .12);
	transform: translateY(-1px);
}
#ieh-header .ieh-cbtn-ico {
	width: 26px;
	height: 26px;
	flex: 0 0 auto;
	border-radius: 8px;
	background: var(--ieh-soft);
	color: var(--ieh-navy);
	display: inline-flex;
	align-items: center;
	justify-content: center;
	transition: background .15s ease, color .15s ease;
}
#ieh-header .ieh-cbtn-ico svg { width: 15px; height: 15px; }
#ieh-header .ieh-cbtn:hover .ieh-cbtn-ico { background: var(--ieh-navy); color: #fff; }
#ieh-header .ieh-cbtn--rdv:hover .ieh-cbtn-ico { background: var(--ieh-accent); }
#ieh-header .ieh-cbtn-value { font-size: 13px; font-weight: 700; color: var(--ieh-navy); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }

/* ---- Page-transition loader (expands from the header) ---- */
#ieh-loader {
	position: fixed;
	inset: 0;
	z-index: 100000;
	background: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	visibility: hidden;
	opacity: 0;
	clip-path: inset(0 0 100% 0);                 /* clipped to the top (hidden) */
	transition: clip-path .2s cubic-bezier(.76, 0, .24, 1), opacity .15s ease, visibility .2s;
}
#ieh-loader.is-active {
	visibility: visible;
	opacity: 1;
	clip-path: inset(0 0 0 0);                     /* expands down to cover */
}
#ieh-loader.is-instant { transition: none; }
.ieh-loader-inner {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 24px;
	opacity: 0;
	transform: translateY(6px) scale(.99);
	transition: opacity .2s ease .02s, transform .24s cubic-bezier(.2, .7, .3, 1) .02s;
}
#ieh-loader.is-active .ieh-loader-inner { opacity: 1; transform: none; }
.ieh-loader-logo { width: 230px; max-width: 58vw; height: auto; display: block; }
.ieh-loader-bar {
	position: relative;
	display: block;
	width: 170px;
	max-width: 60vw;
	height: 4px;
	border-radius: 4px;
	background: var(--ieh-line);
	overflow: hidden;
}
.ieh-loader-bar > span {
	display: block;
	height: 100%;
	width: 0;                       /* JS fills 0 -> 100% */
	border-radius: 4px;
	background: linear-gradient(90deg, var(--ieh-accent), #ffb255);
	transition: width .3s cubic-bezier(.4, 0, .2, 1);
}
@media (prefers-reduced-motion: reduce) {
	#ieh-loader, .ieh-loader-inner { transition-duration: .01ms; }
	.ieh-loader-bar > span { animation: none; }
}

/* ---- Burger / mobile ---- */
#ieh-header .ieh-burger {
	display: none;
	flex-direction: column;
	justify-content: center;
	align-items: center;        /* don't rely on the flex 'stretch' default (a global button{} rule overrides it) */
	gap: 5px;
	width: 46px;
	height: 46px;
	box-shadow: inset 0 0 0 1px var(--ieh-line);
	border-radius: 12px;
	background: #fff;
	cursor: pointer;
	padding: 0 11px;
}
#ieh-header .ieh-burger span {
	display: block;
	width: 22px;                /* explicit so the empty spans always show */
	height: 2px;
	background: var(--ieh-navy);
	border-radius: 2px;
	transition: transform .2s ease, opacity .2s ease;
}
#ieh-header.is-mobile-open .ieh-burger span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
#ieh-header.is-mobile-open .ieh-burger span:nth-child(2) { opacity: 0; }
#ieh-header.is-mobile-open .ieh-burger span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

#ieh-header .ieh-mobile {
	position: absolute;
	left: 0; right: 0;
	top: 100%;
	max-height: calc(100vh - 90px);
	overflow-y: auto;
	opacity: 0;
	visibility: hidden;
	transform: translateY(-10px);
	transition: opacity .24s ease, transform .3s cubic-bezier(.2, .7, .3, 1), visibility .3s;
	pointer-events: none;
}
#ieh-header .ieh-mobile-inner {
	max-width: var(--ieh-max);
	margin: 8px auto 0;
	background: #fff;
	border-radius: var(--ieh-radius);
	box-shadow: var(--ieh-shadow);
	padding: 14px;
}
#ieh-header.is-mobile-open .ieh-mobile { opacity: 1; visibility: visible; transform: none; pointer-events: auto; }

#ieh-header .ieh-mobile-menu li { border-bottom: 1px solid var(--ieh-line); }
#ieh-header .ieh-mobile-menu > li:last-child { border-bottom: 0; }
#ieh-header .ieh-mobile-menu a {
	display: block;
	padding: 14px 12px;
	color: var(--ieh-navy);
	font-weight: 600;
	font-size: 15px;
	border-radius: 8px;
	transition: background .15s ease;
}
#ieh-header .ieh-mobile-menu a:active { background: var(--ieh-soft); }   /* smooth tap feedback */
/* Accordion: animate the sub-menu open/closed (JS sets max-height to content) */
#ieh-header .ieh-mobile-menu .sub-menu { padding-left: 10px; max-height: 0; overflow: hidden; transition: max-height .3s ease; }
#ieh-header .ieh-mobile-menu .sub-menu a { font-weight: 500; color: var(--ieh-ink); font-size: 14px; padding: 11px 12px; }

/* ---- Responsive: mobile burger <= 1024px ---- */
@media (max-width: 1024px) {
	#ieh-header .ieh-nav,
	#ieh-header .ieh-auth,
	#ieh-header .ieh-account { display: none; }
	#ieh-header .ieh-burger { display: flex; }
	#ieh-header .ieh-bar { gap: 14px; }
	#ieh-header .ieh-actions { margin-left: auto; }
}
@media (min-width: 1025px) {
	#ieh-header .ieh-mobile { display: none !important; }
}
@media (max-width: 1440px) {
	#ieh-header .ieh-shell,
	#ieh-header .ieh-mobile-inner { margin-left: 18px; margin-right: 18px; }
}
@media (max-width: 560px) {
	#ieh-header .ieh-shell { margin-top: 10px; }
	#ieh-header .ieh-bar { padding: 0 16px; height: 66px; }
	#ieh-header .ieh-logo img { max-width: 165px; }
}
