/* EH Editorial : article du journal */

/* ═══ Progression de lecture ═══ */
.eh-ar-progress {
	display: none;
}

@supports (animation-timeline: scroll()) {
	.eh-ar-progress {
		position: fixed;
		top: 0;
		left: 0;
		right: 0;
		z-index: 100001;
		display: block;
		height: 2px;
		pointer-events: none;
	}

	.eh-ar-progress span {
		display: block;
		height: 100%;
		background: #111;
		transform: scaleX(0);
		transform-origin: left;
		animation: eh-ar-grow linear both;
		animation-timeline: scroll(root);
	}
}

@keyframes eh-ar-grow {
	to {
		transform: scaleX(1);
	}
}

/* ═══ Ouverture ═══ */
.eh-ar-hero {
	--p: 0;
	--t: clamp(0, calc(var(--p) / 0.7), 1);
	position: relative;
	height: 190vh;
	background: #fff;
}

.eh-ar-hero__sticky {
	position: sticky;
	top: 0;
	height: 100vh;
	height: 100svh;
	overflow: hidden;
}

#eh-ed .eh-ar-hero__media {
	position: absolute;
	inset: 0;
	margin: 0;
	overflow: hidden;
	clip-path: inset(calc(var(--t) * 9%) calc(var(--t) * 6%) calc(var(--t) * 9%) calc(var(--t) * 6%) round calc(var(--t) * 28px));
	will-change: clip-path;
}

#eh-ed .eh-ar-hero__media img {
	width: 100%;
	height: 100% !important;
	object-fit: cover;
	transform: scale(calc(1.14 - var(--t) * 0.14));
	will-change: transform;
}

.eh-ar-hero__media::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, rgba(14, 12, 10, 0.25) 0%, rgba(14, 12, 10, 0.05) 35%, rgba(14, 12, 10, 0.7) 100%);
	opacity: calc(1 - var(--t) * 0.9);
}

.eh-ar-hero__intro {
	position: absolute;
	left: var(--pad);
	right: var(--pad);
	bottom: clamp(3rem, 10vh, 6.5rem);
	z-index: 2;
	max-width: 62rem;
	color: #fff;
	opacity: calc(1 - var(--t) * 1.6);
	transform: translateY(calc(var(--t) * -70px));
}

.eh-ar-crumbs {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem;
	margin-bottom: 1.5rem;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.2em;
	text-transform: uppercase;
}

.eh-ar-crumbs a {
	color: rgba(255, 255, 255, 0.82) !important;
	text-decoration: none !important;
}

.eh-ar-crumbs a:hover {
	color: #fff !important;
}

.eh-ar-crumbs span {
	color: rgba(255, 255, 255, 0.45);
}

#eh-ed .eh-ar-hero__title {
	margin-bottom: 1.5rem;
	color: #fff;
	font-size: clamp(2.6rem, 6.4vw, 6.25rem);
	font-weight: 400;
	line-height: 0.98;
	letter-spacing: -0.045em;
	text-wrap: balance;
}

#eh-ed .eh-ar-hero__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1.5rem;
	color: rgba(255, 255, 255, 0.78);
	font-size: 0.9rem;
}

.eh-ar-hero__meta a {
	color: #fff !important;
	text-decoration: none !important;
}

.eh-ar-hero__hint {
	position: absolute;
	right: var(--pad);
	bottom: clamp(3rem, 10vh, 6.5rem);
	z-index: 2;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 0.75rem;
	color: rgba(255, 255, 255, 0.78);
	font-size: 10px;
	font-weight: 600;
	letter-spacing: 0.24em;
	text-transform: uppercase;
	opacity: calc(1 - var(--t) * 3);
}

.eh-ar-hero__hint::after {
	content: "";
	width: 1px;
	height: 48px;
	background: linear-gradient(rgba(255, 255, 255, 0.8), rgba(255, 255, 255, 0));
}

/* ═══ Chapeau ═══ */
.eh-ar-lead {
	max-width: 60rem;
	margin: 0 auto;
	padding: clamp(3rem, 7vw, 6rem) var(--pad) clamp(3.5rem, 7vw, 6rem);
	text-align: center;
}

#eh-ed .eh-ar-lead p {
	color: var(--ink);
	font-size: clamp(1.45rem, 2.8vw, 2.4rem);
	font-weight: 400;
	line-height: 1.28;
	letter-spacing: -0.025em;
	text-wrap: balance;
}

/* ═══ Corps et sommaire ═══ */
.eh-ar-layout {
	display: grid;
	grid-template-columns: minmax(180px, 240px) minmax(0, 720px);
	justify-content: center;
	gap: clamp(3rem, 7vw, 7rem);
	max-width: var(--max);
	margin: 0 auto;
	padding: 0 var(--pad) clamp(4rem, 8vw, 7rem);
}

.eh-ar-layout:not(:has(.eh-ar-toc)) {
	grid-template-columns: minmax(0, 720px);
}

.eh-ar-toc {
	position: sticky;
	top: 110px;
	align-self: start;
}

#eh-ed .eh-ar-toc__title {
	margin-bottom: 1rem;
	color: var(--muted);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.22em;
	text-transform: uppercase;
}

#eh-ed .eh-ar-toc ol {
	border-left: 1px solid var(--line);
}

.eh-ar-toc a {
	position: relative;
	display: grid;
	grid-template-columns: 1.75rem 1fr;
	padding: 0.55rem 0 0.55rem 1rem;
	color: var(--muted) !important;
	font-size: 0.875rem;
	line-height: 1.4;
	text-decoration: none !important;
	transition: color 0.3s ease;
}

.eh-ar-toc a span {
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.08em;
	font-variant-numeric: tabular-nums;
}

.eh-ar-toc a::before {
	content: "";
	position: absolute;
	top: 0;
	bottom: 0;
	left: -1px;
	width: 1px;
	background: var(--ink);
	transform: scaleY(0);
	transition: transform 0.4s var(--ease);
}

.eh-ar-toc a:hover,
.eh-ar-toc a.is-active {
	color: var(--ink) !important;
}

.eh-ar-toc a.is-active::before {
	transform: scaleY(1);
}

#eh-ed .eh-ar-body {
	min-width: 0;
	color: rgba(17, 17, 17, 0.78);
	font-size: 1.125rem;
	line-height: 1.8;
}

#eh-ed .eh-ar-body .eh-lp,
#eh-ed .eh-ar-body .eh-lp__section,
#eh-ed .eh-ar-body .eh-lp__split {
	display: block;
	max-width: none;
	margin: 0;
	padding: 0;
}

#eh-ed .eh-ar-body .eh-lp__section {
	margin-bottom: clamp(3.5rem, 7vw, 5.5rem);
	scroll-margin-top: 110px;
}

#eh-ed .eh-ar-body .eh-lp__section:last-of-type {
	margin-bottom: 0;
}

#eh-ed .eh-ar-body h2 {
	margin: 0 0 1.25rem;
	color: var(--ink);
	font-size: clamp(1.75rem, 3vw, 2.5rem);
	font-weight: 400;
	line-height: 1.1;
	letter-spacing: -0.03em;
	text-wrap: balance;
}

#eh-ed .eh-ar-body h3 {
	margin: 2rem 0 0.75rem;
	color: var(--ink);
	font-size: 1.3rem;
	font-weight: 500;
	letter-spacing: -0.015em;
}

#eh-ed .eh-ar-body p {
	margin: 0 0 1.25em;
}

#eh-ed .eh-ar-body strong {
	color: var(--ink);
	font-weight: 600;
}

#eh-ed .eh-ar-body a:not(.eh-lp__btn) {
	color: var(--ink) !important;
	text-decoration: underline !important;
	text-decoration-color: rgba(17, 17, 17, 0.3) !important;
	text-decoration-thickness: 1px !important;
	text-underline-offset: 4px;
	transition: text-decoration-color 0.3s ease;
}

#eh-ed .eh-ar-body a:not(.eh-lp__btn):hover {
	text-decoration-color: var(--ink) !important;
}

#eh-ed .eh-ar-body ul,
#eh-ed .eh-ar-body ol {
	margin: 0 0 1.5em;
	padding-left: 1.25em;
}

#eh-ed .eh-ar-body ul {
	list-style: disc;
}

#eh-ed .eh-ar-body ol {
	list-style: decimal;
}

#eh-ed .eh-ar-body li {
	margin-bottom: 0.5em;
	padding-left: 0.25em;
}

#eh-ed .eh-ar-body li::marker {
	color: rgba(17, 17, 17, 0.4);
}

/* En bref */
#eh-ed .eh-ar-body .eh-lp__brief {
	max-width: none;
	margin: 0 0 clamp(3.5rem, 7vw, 5.5rem);
	padding: clamp(1.75rem, 3.5vw, 2.75rem);
	border-radius: 24px;
	background: var(--cream);
}

#eh-ed .eh-ar-body .eh-lp__brief h2 {
	margin-bottom: 1.25rem;
	color: var(--muted);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.22em;
	text-transform: uppercase;
}

#eh-ed .eh-ar-body .eh-lp__brief ul {
	margin: 0;
	padding: 0;
	list-style: none;
}

#eh-ed .eh-ar-body .eh-lp__brief li {
	position: relative;
	margin: 0;
	padding: 0.85rem 0 0.85rem 1.75rem;
	border-top: 1px solid rgba(17, 17, 17, 0.08);
	font-size: 1rem;
	line-height: 1.6;
}

#eh-ed .eh-ar-body .eh-lp__brief li:first-child {
	border-top: 0;
	padding-top: 0;
}

#eh-ed .eh-ar-body .eh-lp__brief li::before {
	content: "";
	position: absolute;
	left: 0;
	top: 1.45rem;
	width: 0.6rem;
	height: 0.6rem;
	border-radius: 50%;
	background: var(--ink);
}

#eh-ed .eh-ar-body .eh-lp__brief li:first-child::before {
	top: 0.6rem;
}

#eh-ed .eh-ar-body .eh-lp__toc {
	display: none;
}

/* Photos */
#eh-ed .eh-ar-body figure {
	margin: clamp(2rem, 4vw, 3rem) 0;
}

#eh-ed .eh-ar-body .eh-lp__split--rev > figure {
	margin-top: 0;
}

#eh-ed .eh-ar-body figure img {
	display: block;
	width: 100%;
	height: auto;
	max-height: 78vh;
	object-fit: cover;
	border-radius: 20px;
}

#eh-ed .eh-ar-body figcaption {
	margin-top: 0.9rem;
	color: var(--muted);
	font-size: 0.8125rem;
	line-height: 1.5;
	text-align: center;
}

@supports (animation-timeline: view()) {
	@media (prefers-reduced-motion: no-preference) {
		#eh-ed .eh-ar-body figure img {
			animation: eh-ar-reveal linear both;
			animation-timeline: view();
			animation-range: entry 0% cover 35%;
		}

		#eh-ed .eh-ar-body .eh-lp__section h2 {
			animation: eh-ar-rise linear both;
			animation-timeline: view();
			animation-range: entry 0% entry 100%;
		}
	}
}

@keyframes eh-ar-reveal {
	from {
		opacity: 0.4;
		clip-path: inset(8% 6% round 32px);
		transform: scale(1.06);
	}
	to {
		opacity: 1;
		clip-path: inset(0 round 20px);
		transform: none;
	}
}

@keyframes eh-ar-rise {
	from {
		opacity: 0;
		transform: translateY(24px);
	}
	to {
		opacity: 1;
		transform: none;
	}
}

/* Liens vers la collection */
#eh-ed .eh-ar-body .eh-lp__cta {
	display: flex;
	flex-wrap: wrap;
	justify-content: flex-start;
	gap: 0.75rem;
	margin: clamp(2.5rem, 5vw, 3.5rem) 0 0;
	padding-top: clamp(2rem, 4vw, 2.75rem);
	border-top: 1px solid var(--line);
}

#eh-ed .eh-ar-body .eh-lp__btn {
	display: inline-flex;
	align-items: center;
	min-height: 52px;
	padding: 0 1.75rem;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-decoration: none !important;
	background: var(--ink);
	color: #fff;
	border: 1px solid var(--ink);
	transition: background-color 0.3s ease, color 0.3s ease;
}

#eh-ed .eh-ar-body .eh-lp__btn--ghost {
	background: transparent;
	color: var(--ink);
}

/* ═══ À lire ensuite ═══ */
.eh-ar-next {
	max-width: var(--max);
	margin: 0 auto;
	padding: clamp(4.5rem, 9vw, 8rem) var(--pad);
}

.eh-ar-next__head {
	display: grid;
	grid-template-columns: 1fr auto;
	align-items: end;
	gap: 0.5rem 2rem;
	margin-bottom: clamp(2rem, 4vw, 3rem);
}

#eh-ed .eh-ar-next__eyebrow {
	grid-column: 1 / -1;
	color: var(--muted);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.22em;
	text-transform: uppercase;
}

#eh-ed .eh-ar-next__title {
	font-size: clamp(2rem, 4vw, 3.5rem);
	font-weight: 400;
	line-height: 1;
	letter-spacing: -0.04em;
}

.eh-ar-next__all {
	padding-bottom: 2px;
	border-bottom: 1px solid currentColor;
	color: var(--ink) !important;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-decoration: none !important;
	text-transform: uppercase;
}

#eh-ed .eh-ar-next__list {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: clamp(1rem, 2.5vw, 2rem);
}

.eh-ar-card {
	display: flex;
	flex-direction: column;
	color: var(--ink) !important;
	text-decoration: none !important;
}

.eh-ar-card__img {
	display: block;
	aspect-ratio: 4 / 3;
	margin-bottom: 1.25rem;
	overflow: hidden;
	border-radius: 20px;
	background: var(--sand);
}

#eh-ed .eh-ar-card__img img {
	width: 100%;
	height: 100% !important;
	object-fit: cover;
	transition: transform 1s var(--ease);
}

.eh-ar-card:hover .eh-ar-card__img img {
	transform: scale(1.05);
}

.eh-ar-card__cat {
	margin-bottom: 0.5rem;
	color: var(--muted);
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.18em;
	text-transform: uppercase;
}

.eh-ar-card__title {
	margin-bottom: 1rem;
	font-size: clamp(1.15rem, 1.6vw, 1.4rem);
	line-height: 1.25;
	letter-spacing: -0.02em;
}

.eh-ar-card__more {
	align-self: flex-start;
	margin-top: auto;
	padding-bottom: 2px;
	border-bottom: 1px solid currentColor;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 0.16em;
	text-transform: uppercase;
}

/* ═══ Tablette et mobile ═══ */
@media (max-width: 1023px) {
	.eh-ar-layout {
		grid-template-columns: minmax(0, 720px);
	}

	.eh-ar-toc {
		display: none;
	}

	#eh-ed .eh-ar-next__list {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	#eh-ed .eh-ar-next__list > li:nth-child(3) {
		display: none;
	}
}

@media (max-width: 767px) {
	.eh-ar-hero {
		height: 150vh;
	}

	.eh-ar-hero__hint {
		display: none;
	}

	#eh-ed .eh-ar-hero__meta {
		gap: 0.25rem 1rem;
		font-size: 0.8125rem;
	}

	#eh-ed .eh-ar-body {
		font-size: 1.0625rem;
	}

	.eh-ar-next__head {
		grid-template-columns: 1fr;
	}

	.eh-ar-next__all {
		justify-self: start;
	}

	#eh-ed .eh-ar-next__list {
		display: flex;
		gap: 1rem;
		margin: 0 calc(var(--pad) * -1);
		padding: 0 var(--pad);
		overflow-x: auto;
		scroll-snap-type: x mandatory;
		scroll-padding-inline: var(--pad);
		scrollbar-width: none;
	}

	#eh-ed .eh-ar-next__list > li {
		flex: 0 0 78%;
		scroll-snap-align: start;
	}

	#eh-ed .eh-ar-next__list > li:nth-child(3) {
		display: block;
	}
}

@media (prefers-reduced-motion: reduce) {
	.eh-ar-hero {
		height: auto;
	}

	.eh-ar-hero__sticky {
		position: relative;
	}
}

/* ═══ Mouvement ═══ */
.eh-ar-hero__intro {
	will-change: transform, opacity;
}

#eh-ed .eh-ar-hero__media img {
	backface-visibility: hidden;
}
