/*
 * Tarot Arabi — P11-A paths
 *
 * The learning-path library and one learning path.
 *
 * This is a composition layer, not a new design language: tokens, buttons,
 * badges, icon chips, breadcrumbs and icons all come from the global layers, and
 * the hub hero mirrors the approved Page-family hero geometry so the path section
 * is unmistakably part of the same site. What is its own is the path object — a
 * stage card that states a position in the curriculum, and an ordered step rail
 * that reads as a journey rather than as a database list.
 *
 * Loaded only on path surfaces: the homepage, the Learn family, the card library,
 * the spread family, the course family and the book family each keep their own
 * system, and none of them receives these rules.
 *
 * There is no path script. The reveal gate the other families use is scoped to a
 * class their own script adds, and the global `ta-js` marker is already present on
 * every request — hiding path content behind it without an observer to reveal it
 * would leave the page invisible. Path pages therefore ship no motion and no
 * script, and every path is visible immediately.
 */

/* ============================================================== Foundation */

.ta-paths {
	/* The hub hero mirrors the approved Page-family hero geometry. */
	--ta-paths-hero-top: clamp(28px, 3.4vw, 48px);
	--ta-paths-hero-copy: 540px;
	--ta-paths-hero-arc: clamp(380px, 30vw, 440px);
	--ta-paths-hero-arc-bite: 105px;

	--ta-paths-line: 1px solid var(--color-border);
	--ta-paths-shadow: 0 4px 18px rgba(23, 79, 58, 0.06);
	--ta-paths-shadow-hover: 0 10px 26px rgba(23, 79, 58, 0.1);
	--ta-paths-reading: 780px;

	background-color: var(--color-bg);
	color: var(--color-text);
	overflow-x: clip; /* the hero field may bleed; the page never scrolls sideways */
}

/*
 * The family's own content wrapper. The shared `.ta-ec-wrap` primitive lives in
 * the Learn layer, which this family does not load, so the complete definition
 * lives here: without the auto margins and the gutter the content would sit flush
 * against the physical right edge of the viewport.
 */
.ta-paths-wrap {
	inline-size: 100%;
	max-inline-size: 1264px; /* ~1200px of content at 1440 */
	margin-inline: auto;
	padding-inline: clamp(20px, 2.2vw, 32px);
}

/*
 * The approved eyebrow treatment, stated locally.
 *
 * `.ta-eyebrow`'s typography base lives in the homepage and Learn layers, so a
 * family that loads neither must restate it or inherit the body's 400 weight and
 * loose leading.
 */
.ta-paths .ta-eyebrow {
	margin: 0;
	color: var(--color-gold-action);
	font-size: clamp(14px, 1.05vw, 16px);
	font-weight: var(--weight-bold);
	line-height: 1.45;
}

/*
 * The badge list primitive also lives in the homepage layer, so the family
 * restates the list itself and then unifies the badge surface: every path fact is
 * metadata, so none of them may wear an action-like brass outline.
 */
.ta-paths .ta-badges {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-2);
	margin: 0;
	padding: 0;
	list-style: none;
}

.ta-paths .ta-badge {
	min-block-size: 28px;
	padding-block: 0;
	padding-inline: 10px;
	border: 1px solid var(--color-border);
	border-radius: var(--radius-xs);
	background-color: var(--color-surface);
	color: var(--color-green-900);
	font-size: 13px;
	font-weight: var(--weight-bold);
	line-height: 1;
}

.ta-paths .ta-badge--level,
.ta-paths .ta-badge--category {
	background-color: var(--color-sage-100);
	border-color: transparent;
}

/*
 * The base layer's global `li + li` rhythm would offset the second badge and the
 * second row in a family list. Inside the family's own flex/grid lists the
 * container's own gap owns the spacing, so the base rule is cancelled where it
 * leaks.
 */
.ta-paths .ta-badges > li + li,
.ta-paths .ta-paths-rows > li + li,
.ta-paths .ta-paths-steps__list > li + li {
	margin-block-start: 0;
}

/*
 * ONE canonical major-section gap, owned by the section below it, so a boundary
 * is the token and nothing else. Spacing inside a section is internal.
 */
.ta-paths > article > * {
	padding-block: 0;
}

.ta-paths > article > .ta-paths-hero,
.ta-paths > article > .ta-paths-detail-hero {
	padding-block-start: var(--ta-paths-hero-top);
}

.ta-paths > article > .ta-paths-section {
	padding-block-start: var(--ta-section-gap);
}

.ta-paths > article > :last-child {
	padding-block-end: var(--ta-section-gap);
}

/* ------------------------------------------------------------ Section head */

/*
 * One heading cluster, stacked: eyebrow, heading, then the line that belongs to
 * it — never a heading on one physical edge and its own count on the other.
 */
.ta-paths-head {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
	margin-block-end: clamp(28px, 3vw, 40px);
}

.ta-paths-head__cluster {
	max-inline-size: 760px;
}

.ta-paths-head .ta-eyebrow {
	margin: 0 0 10px;
}

.ta-paths-h2 {
	margin: 0;
	color: var(--color-heading);
	font-family: var(--font-heading);
	font-size: clamp(30px, 3vw, 44px);
	font-weight: var(--weight-bold);
	line-height: 1.18;
	text-wrap: balance;
}

.ta-paths-head__count {
	margin: 12px 0 0;
	color: var(--color-text-muted);
	font-size: 15px;
	font-weight: var(--weight-bold);
	line-height: 1.5;
}

/* --------------------------------------------------- Neutral media plate */

/*
 * The neutral plate: a plain Sage → Ivory surface that never imitates artwork and
 * carries no generated symbol. It is decorative for assistive technology, and the
 * author-facing marker is added only for someone who can fix it.
 */
.ta-paths-plate {
	position: relative;
	display: block;
	inline-size: 100%;
	block-size: 100%;
	min-block-size: 100%;
	background-color: var(--color-sage-100);
	background-image: linear-gradient(160deg, var(--color-sage-100) 0%, var(--color-ivory) 55%, var(--color-surface-warm) 100%);
}

.ta-paths-plate__label {
	position: absolute;
	inset-block-end: 12%;
	inset-inline: 12%;
	color: rgba(23, 79, 58, 0.42);
	font-family: var(--font-heading);
	font-size: clamp(13px, 0.95vw, 14px);
	font-weight: var(--weight-bold);
	line-height: 1.4;
	text-align: center;
	text-wrap: balance;
}

/* ============================================================== Hub hero */

.ta-paths-hero {
	position: relative;
	min-block-size: clamp(400px, 30vw, 440px);
}

.ta-paths-hero__wrap {
	position: relative;
	z-index: 2;
}

.ta-paths-hero__body {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
	max-inline-size: var(--ta-paths-hero-copy);
	margin-inline-end: auto; /* RTL: the copy keeps the page grid's right edge */
}

.ta-paths-hero__eyebrow {
	margin: clamp(20px, 1.6vw, 22px) 0 0;
}

.ta-paths-hero__title {
	margin: clamp(14px, 1.1vw, 16px) 0 0;
	max-inline-size: 520px;
	color: var(--color-heading);
	font-family: var(--font-heading);
	font-size: clamp(46px, 4.3vw, 62px);
	font-weight: var(--weight-bold);
	line-height: 1.14;
	text-wrap: balance;
}

.ta-paths-hero__lead {
	margin: clamp(16px, 1.3vw, 18px) 0 0;
	max-inline-size: 520px;
	color: var(--color-text-muted);
	font-size: clamp(17px, 1.25vw, 19px);
	line-height: 1.8;
}

/* The photographic field: out of flow, so it can reach the physical left
   viewport edge while the copy keeps the centred grid. */
.ta-paths-hero__media {
	position: absolute;
	z-index: 1;
	inset-block: 0;
	inset-inline-end: 0; /* RTL: the physical left edge */
	inline-size: min(
		55.5vw,
		calc(100% - var(--ta-paths-hero-copy) - clamp(20px, 2.2vw, 32px) - 16px)
	);
}

.ta-paths-hero__frame {
	position: relative;
	display: block;
	block-size: 100%;
	overflow: hidden;
	border-radius: 18px 0 0 18px; /* physical left corners only */
	background-color: var(--color-surface);
}

html[dir="ltr"] .ta-paths-hero__frame {
	border-radius: 0 18px 18px 0;
}

.ta-paths-hero__image {
	display: block;
	inline-size: 100%;
	block-size: 100%;
	object-fit: cover;
}

/*
 * The transition: one oversized Ivory disc whose centre sits well inside the
 * photograph, so only a shallow arc brushes into it. Pure layout geometry.
 */
.ta-paths-hero__media::after {
	content: "";
	position: absolute;
	z-index: 2;
	inset-block-start: 54%;
	inset-inline-start: calc(var(--ta-paths-hero-arc-bite) - var(--ta-paths-hero-arc));
	inline-size: var(--ta-paths-hero-arc);
	block-size: var(--ta-paths-hero-arc);
	border-radius: 50%;
	background-color: var(--color-bg);
	transform: translateY(-50%);
	pointer-events: none;
}

/* =========================================================== Stage cards */

/*
 * The three stages: equal width, one card per stage, three across on desktop and
 * two then one as the usable width falls away. They are deliberately taller than
 * a product tile — the stage marker, the path's own identity, the facts it really
 * stores and one action — so the row reads as a curriculum rather than a pricing
 * table.
 */
.ta-paths-grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr);
	gap: clamp(16px, 1.5vw, 22px);
	align-items: stretch;
}

@media (min-width: 700px) {
	.ta-paths-grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}
}

@media (min-width: 1100px) {
	.ta-paths-grid {
		grid-template-columns: repeat(3, minmax(0, 1fr));
	}
}

.ta-paths-card {
	display: flex;
	min-inline-size: 0;
}

.ta-paths-card__link {
	display: flex;
	flex-direction: column;
	inline-size: 100%;
	overflow: hidden;
	padding: clamp(20px, 1.8vw, 26px);
	border: var(--ta-paths-line);
	border-radius: var(--radius-2xl);
	background-color: var(--color-surface);
	color: inherit;
	text-decoration: none;
	box-shadow: var(--ta-paths-shadow);
	transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1), box-shadow 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

.ta-paths-card__link:hover {
	transform: translateY(-2px);
	box-shadow: var(--ta-paths-shadow-hover);
}

.ta-paths-card__link:focus-visible {
	outline: 2px solid var(--color-gold-action);
	outline-offset: 3px;
}

/*
 * The stage marker: the path's real position in the approved sequence. The
 * numeral is a drawn disc rather than a badge, so it never reads as a status
 * chip, and the ordinal beside it states the position in words.
 */
.ta-paths-card__stage {
	display: flex;
	align-items: center;
	gap: var(--space-3);
}

.ta-paths-card__number {
	display: inline-grid;
	place-items: center;
	inline-size: 44px;
	block-size: 44px;
	border-radius: var(--radius-pill);
	background-color: var(--color-sage-100);
	color: var(--color-green-900);
	font-family: var(--font-heading);
	font-size: 20px;
	font-weight: var(--weight-bold);
	line-height: 1;
}

.ta-paths-card__stage-label {
	color: var(--color-gold-action);
	font-size: clamp(14px, 1.05vw, 16px);
	font-weight: var(--weight-bold);
	line-height: 1.45;
}

.ta-paths-card__body {
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
	min-inline-size: 0;
	margin-block-start: clamp(16px, 1.5vw, 20px);
}

/*
 * The title is the card's identity: it wraps naturally and is never clamped or
 * ellipsised, so a long Arabic title stays whole.
 */
.ta-paths-card__title {
	margin-block-start: 12px;
	color: var(--color-heading);
	font-family: var(--font-heading);
	font-size: clamp(24px, 1.9vw, 29px);
	font-weight: var(--weight-bold);
	line-height: 1.3;
	text-wrap: balance;
}

.ta-paths-card__facts {
	display: flex;
	flex-wrap: wrap;
	gap: var(--space-2);
	margin-block-start: 14px;
}

.ta-paths-card__text {
	margin-block-start: 12px;
	color: var(--color-text-muted);
	font-size: 16px;
	line-height: 1.85;
}

.ta-paths-card__meta {
	margin-block-start: 12px;
	color: var(--color-text-muted);
	font-size: 14px;
	font-weight: var(--weight-bold);
	line-height: 1.5;
}

/*
 * The one action, pinned to the bottom of the card so a row's actions line up
 * while the card above them is free to grow. A hairline separates the action from
 * the card's body, and the approved circular affordance sits at the inline-end.
 */
.ta-paths-card__cta {
	display: flex;
	align-items: center;
	gap: var(--space-3);
	inline-size: 100%;
	margin-block-start: auto;
	padding-block-start: clamp(20px, 2vw, 26px);
	border-block-start: var(--ta-paths-line);
	color: var(--color-gold-action);
	font-size: 15px;
	font-weight: var(--weight-bold);
}

.ta-paths-card__cta-label {
	margin-inline-end: auto;
}

.ta-paths-card__arrow {
	display: inline-grid;
	place-items: center;
	flex: 0 0 auto;
	inline-size: 44px;
	block-size: 44px;
	border-radius: var(--radius-pill);
	background-color: var(--color-surface-warm);
	color: var(--color-green-900);
	transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

.ta-paths-card__link:hover .ta-icon--directional {
	transform: translateX(-4px);
}

html[dir="ltr"] .ta-paths-card__link:hover .ta-icon--directional {
	transform: translateX(4px);
}

/* ========================================================== Detail hero */

.ta-paths-detail-hero__grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) clamp(320px, 30vw, 430px);
	gap: clamp(40px, 5vw, 68px);
	align-items: center;
}

.ta-paths-detail-hero__body {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
	min-inline-size: 0;
}

.ta-paths-detail-hero__eyebrow {
	margin: clamp(18px, 1.5vw, 20px) 0 0;
}

.ta-paths-detail-hero__title {
	margin: clamp(12px, 1vw, 16px) 0 0;
	color: var(--color-heading);
	font-family: var(--font-heading);
	font-size: clamp(40px, 3.8vw, 58px);
	font-weight: var(--weight-bold);
	line-height: 1.16;
	text-wrap: balance;
}

.ta-paths-detail-hero__lead {
	margin: clamp(14px, 1.2vw, 18px) 0 0;
	max-inline-size: 62ch;
	color: var(--color-text-muted);
	font-size: clamp(17px, 1.25vw, 19px);
	line-height: 1.8;
}

.ta-paths-detail-hero__facts {
	margin-block-start: clamp(18px, 1.6vw, 22px);
}

/*
 * The media stage: a soft sage backing with one restrained offset layer, and an
 * editorial 16:10 frame inside it — a path is a curriculum, not a portrait
 * product, so its image is treated as an article image and never cropped into a
 * product shape.
 */
.ta-paths-detail-hero__stage {
	position: relative;
	display: flex;
	justify-content: center;
	min-inline-size: 0;
	padding: clamp(18px, 1.8vw, 26px);
	border-radius: var(--radius-2xl);
	background-color: var(--color-sage-100);
	background-image: linear-gradient(166deg, var(--color-sage-100) 0%, var(--color-ivory) 100%);
}

.ta-paths-detail-hero__stage::before {
	content: "";
	position: absolute;
	z-index: 0;
	inset-block-start: clamp(24px, 2.4vw, 34px);
	inset-inline-end: calc(-1 * clamp(10px, 1vw, 16px));
	inline-size: 62%;
	block-size: 74%;
	border-radius: var(--radius-xl);
	background-color: var(--color-surface-warm);
	opacity: 0.7;
}

html[dir="ltr"] .ta-paths-detail-hero__stage::before {
	inset-inline-end: auto;
	inset-inline-start: calc(-1 * clamp(10px, 1vw, 16px));
}

.ta-paths-detail-hero__frame {
	position: relative;
	z-index: 1;
	display: block;
	inline-size: min(100%, 380px);
	aspect-ratio: 16 / 10;
	overflow: hidden;
	border-radius: 12px;
	background-color: var(--color-surface);
	box-shadow: 0 14px 34px rgba(23, 79, 58, 0.16);
}

.ta-paths-detail-hero__image {
	display: block;
	inline-size: 100%;
	block-size: 100%;
	object-fit: cover;
}

.ta-paths-plate--cover {
	border-radius: 12px;
}

/* ================================================================ Steps */

/*
 * The journey rail: one numeral per step on a hairline that connects them, and
 * one contained card per step holding the type, the title, whatever the step
 * really stores and its single action. The rail is decoration for the eye only —
 * the list itself carries the order.
 */
.ta-paths-steps__list {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: clamp(14px, 1.4vw, 20px);
	max-inline-size: 980px;
	margin: 0;
	padding: 0;
	list-style: none;
	counter-reset: none;
}

.ta-paths-steps__item {
	position: relative;
	display: grid;
	grid-template-columns: auto minmax(0, 1fr);
	gap: clamp(14px, 1.4vw, 20px);
	align-items: start;
}

/* The connector between two steps, drawn only where a step really follows one. */
.ta-paths-steps__item + .ta-paths-steps__item::before {
	content: "";
	position: absolute;
	inset-block-start: calc(-1 * clamp(14px, 1.4vw, 20px));
	inset-block-end: 50%;
	inset-inline-start: 21px;
	inline-size: 1px;
	background-color: var(--color-border);
}

.ta-paths-steps__marker {
	position: relative;
	z-index: 1;
	display: inline-grid;
	place-items: center;
	inline-size: 42px;
	block-size: 42px;
	border: var(--ta-paths-line);
	border-radius: var(--radius-pill);
	background-color: var(--color-surface);
	color: var(--color-green-900);
	font-family: var(--font-heading);
	font-size: 18px;
	font-weight: var(--weight-bold);
	line-height: 1;
}

.ta-paths-steps__card {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: clamp(14px, 1.4vw, 22px);
	padding: clamp(18px, 1.7vw, 24px);
	border: var(--ta-paths-line);
	border-radius: var(--radius-xl);
	background-color: var(--color-surface);
	color: inherit;
	text-decoration: none;
	transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1), box-shadow 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

.ta-paths-steps__card:hover {
	transform: translateY(-2px);
	box-shadow: var(--ta-paths-shadow-hover);
}

.ta-paths-steps__card:focus-visible {
	outline: 2px solid var(--color-gold-action);
	outline-offset: 3px;
}

.ta-paths-steps__body {
	display: flex;
	flex: 1 1 420px;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
	min-inline-size: 0;
}

.ta-paths-steps__type {
	color: var(--color-gold-action);
	font-size: 13px;
	font-weight: var(--weight-bold);
	line-height: 1.4;
}

.ta-paths-steps__stage {
	margin-inline-start: 8px;
	padding-inline-start: 8px;
	border-inline-start: 1px solid var(--color-border);
	color: var(--color-text-muted);
	font-weight: var(--weight-bold);
}

.ta-paths-steps__title {
	margin-block-start: 8px;
	color: var(--color-heading);
	font-family: var(--font-heading);
	font-size: clamp(20px, 1.6vw, 24px);
	font-weight: var(--weight-bold);
	line-height: 1.32;
}

.ta-paths-steps__text {
	margin-block-start: 8px;
	color: var(--color-text-muted);
	font-size: 16px;
	line-height: 1.8;
}

.ta-paths-steps__note {
	margin-block-start: 10px;
	padding-inline-start: 14px;
	border-inline-start: 3px solid var(--color-accent);
	color: var(--color-text-muted);
	font-size: 15px;
	line-height: 1.75;
}

.ta-paths-steps__required {
	margin-block-start: 10px;
	color: var(--color-green-900);
	font-size: 13px;
	font-weight: var(--weight-bold);
}

.ta-paths-steps__action {
	flex: 0 0 auto;
	margin-block-start: 0;
	padding-block-start: 0;
}

.ta-paths-steps__card:hover .ta-icon--directional {
	transform: translateX(-4px);
}

html[dir="ltr"] .ta-paths-steps__card:hover .ta-icon--directional {
	transform: translateX(4px);
}

/* ========================================================== Next region */

/*
 * One region for the relations the path really stores, and each one keeps its own
 * label so series, courses and the next path are never flattened into one
 * concept. The join between two modules is an internal gap; the canonical token
 * still owns the region's outer boundaries.
 */
.ta-paths-next__module + .ta-paths-next__module {
	margin-block-start: clamp(32px, 3vw, 48px);
}

.ta-paths-next__label {
	margin: 0 0 clamp(14px, 1.4vw, 18px);
	color: var(--color-heading);
	font-family: var(--font-heading);
	font-size: clamp(20px, 1.7vw, 24px);
	font-weight: var(--weight-bold);
	line-height: 1.3;
}

/* A compact contained panel: one secondary relation, not a new chapter. */
.ta-paths-next__panel {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: clamp(16px, 1.8vw, 28px);
	max-inline-size: 980px;
	padding: clamp(22px, 2vw, 28px) clamp(20px, 1.9vw, 28px);
	border: var(--ta-paths-line);
	border-radius: var(--radius-xl);
	background-color: var(--color-surface);
	color: inherit;
	text-decoration: none;
	transition: transform 220ms cubic-bezier(0.22, 1, 0.36, 1), box-shadow 220ms cubic-bezier(0.22, 1, 0.36, 1);
}

.ta-paths-next__panel--path {
	background-color: var(--color-sage-100);
}

.ta-paths-next__panel:hover {
	transform: translateY(-2px);
	box-shadow: var(--ta-paths-shadow-hover);
}

.ta-paths-next__panel:focus-visible {
	outline: 2px solid var(--color-gold-action);
	outline-offset: 3px;
}

.ta-paths-next__body {
	display: flex;
	flex: 1 1 420px;
	flex-direction: column;
	align-items: flex-start;
	gap: 0;
	min-inline-size: 0;
}

.ta-paths-next__type {
	color: var(--color-gold-action);
	font-size: 13px;
	font-weight: var(--weight-bold);
	line-height: 1.4;
}

.ta-paths-next__title {
	margin-block-start: 8px;
	color: var(--color-heading);
	font-family: var(--font-heading);
	font-size: clamp(20px, 1.7vw, 24px);
	font-weight: var(--weight-bold);
	line-height: 1.32;
}

.ta-paths-next__text {
	margin-block-start: 8px;
	color: var(--color-text-muted);
	font-size: 16px;
	line-height: 1.8;
}

.ta-paths-next__action {
	flex: 0 0 auto;
	margin-block-start: 0;
	padding-block-start: 0;
	color: var(--color-gold-action-on-sage);
}

.ta-paths-next__panel:hover .ta-icon--directional {
	transform: translateX(-4px);
}

html[dir="ltr"] .ta-paths-next__panel:hover .ta-icon--directional {
	transform: translateX(4px);
}

/* Compact text-led rows, used for alternative courses. */
.ta-paths-rows {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: clamp(10px, 1vw, 14px);
	max-inline-size: 980px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.ta-paths-rows__item {
	display: flex;
	min-inline-size: 0;
}

.ta-paths-rows__link {
	display: flex;
	flex-direction: column;
	gap: 4px;
	inline-size: 100%;
	padding: clamp(14px, 1.4vw, 18px) clamp(16px, 1.5vw, 20px);
	border: var(--ta-paths-line);
	border-radius: var(--radius-lg);
	background-color: var(--color-surface);
	color: inherit;
	text-decoration: none;
	transition: border-color 180ms ease, transform 180ms ease;
}

.ta-paths-rows__link:hover {
	transform: translateY(-2px);
	border-color: var(--color-gold-action);
}

.ta-paths-rows__link:focus-visible {
	outline: 2px solid var(--color-gold-action);
	outline-offset: 2px;
}

.ta-paths-rows__type {
	color: var(--color-gold-action);
	font-size: 13px;
	font-weight: var(--weight-bold);
}

.ta-paths-rows__title {
	color: var(--color-heading);
	font-size: 15px;
	font-weight: var(--weight-bold);
	line-height: 1.5;
}

/* ================================================== Editor-only states */

.ta-paths-preview-state {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: var(--space-4);
	max-inline-size: var(--ta-paths-reading);
	padding: clamp(18px, 1.6vw, 22px);
	border: 1px dashed var(--color-border);
	border-radius: var(--radius-lg);
	background-color: var(--color-surface);
}

.ta-paths-preview-state__icon {
	display: inline-flex;
	color: var(--color-gold-action);
}

.ta-paths-preview-state__body {
	flex: 1 1 260px;
}

.ta-paths-preview-state__title {
	margin: 0;
	color: var(--color-heading);
	font-size: 15px;
	font-weight: var(--weight-bold);
}

.ta-paths-preview-state__text {
	margin: 6px 0 0;
	color: var(--color-text-muted);
	font-size: 14px;
	line-height: 1.7;
}

.ta-paths-preview-state__action {
	display: inline-flex;
	align-items: center;
	gap: var(--space-2);
	color: var(--color-gold-action);
	font-size: 14px;
	font-weight: var(--weight-bold);
	text-decoration: none;
}

.ta-paths-preview-state__action:hover .ta-icon--directional {
	transform: translateX(-4px);
}

/* ======================================================= Article language */

.ta-paths-prose {
	max-inline-size: 780px;
	color: var(--color-text);
	font-size: 18px;
	line-height: 1.92;
}

.ta-paths-prose > * + * {
	margin-block-start: 1.1em;
}

.ta-paths-prose h2 {
	margin-block-start: 1.5em;
	color: var(--color-heading);
	font-family: var(--font-heading);
	font-size: clamp(32px, 2.8vw, 40px);
	font-weight: var(--weight-bold);
	line-height: 1.2;
}

.ta-paths-prose h3 {
	margin-block-start: 1.4em;
	color: var(--color-heading);
	font-family: var(--font-heading);
	font-size: clamp(24px, 2vw, 29px);
	font-weight: var(--weight-bold);
	line-height: 1.24;
}

.ta-paths-prose ul,
.ta-paths-prose ol {
	padding-inline-start: 1.4em;
}

.ta-paths-prose li + li {
	margin-block-start: 0.5em;
}

.ta-paths-prose a {
	color: var(--color-gold-action);
	text-decoration: underline;
	text-underline-offset: 3px;
}

.ta-paths-prose blockquote {
	margin: 1.5em 0;
	padding-inline-start: 20px;
	border-inline-start: 3px solid var(--color-accent);
	color: var(--color-text-muted);
}

.ta-paths-prose figure {
	margin: 1.6em 0;
}

.ta-paths-prose img {
	inline-size: 100%;
	block-size: auto;
	border-radius: var(--radius-lg);
}

.ta-paths-prose figcaption {
	margin-block-start: 10px;
	color: var(--color-text-muted);
	font-size: 14px;
	text-align: center;
}

/* ================================================================= Motion */

@media (prefers-reduced-motion: reduce) {
	.ta-paths-card__link,
	.ta-paths-card__arrow,
	.ta-paths-steps__card,
	.ta-paths-next__panel,
	.ta-paths-rows__link {
		transition: none;
	}

	.ta-paths-card__link:hover,
	.ta-paths-steps__card:hover,
	.ta-paths-next__panel:hover,
	.ta-paths-rows__link:hover {
		transform: none;
	}

	.ta-paths-card__link:hover .ta-icon--directional,
	.ta-paths-steps__card:hover .ta-icon--directional,
	.ta-paths-next__panel:hover .ta-icon--directional,
	.ta-paths-preview-state__action:hover .ta-icon--directional {
		transform: none;
	}
}

/* ============================================================ Responsive */

@media (max-width: 1119px) {
	.ta-paths-hero__media {
		inline-size: 46vw;
	}
}

@media (max-width: 1023px) {
	.ta-paths-hero {
		display: flex;
		flex-direction: column;
		min-block-size: 0;
	}

	.ta-paths-hero__wrap {
		order: 1;
	}

	.ta-paths-hero__media {
		position: relative;
		order: 2;
		inline-size: 100%;
		margin-block-start: clamp(28px, 4vw, 40px);
		block-size: clamp(220px, 34vw, 300px);
	}

	.ta-paths-hero__media::after {
		display: none;
	}

	.ta-paths-hero__frame,
	html[dir="ltr"] .ta-paths-hero__frame {
		border-radius: 0;
	}

	.ta-paths-detail-hero__grid {
		grid-template-columns: minmax(0, 1fr) clamp(280px, 30vw, 340px);
		gap: clamp(28px, 3.6vw, 44px);
	}
}

@media (max-width: 899px) {
	/* Below this width the split hero stops being comfortable, so the copy leads
	   and the media stage follows it. */
	.ta-paths-detail-hero__grid {
		grid-template-columns: minmax(0, 1fr);
		gap: clamp(28px, 4vw, 40px);
	}

	.ta-paths-detail-hero__stage {
		order: 2;
		max-inline-size: 460px;
	}
}

@media (max-width: 699px) {
	.ta-paths-rows {
		grid-template-columns: minmax(0, 1fr);
	}
}

@media (max-width: 559px) {
	.ta-paths-hero__title {
		font-size: clamp(34px, 9vw, 40px);
	}

	.ta-paths-detail-hero__title {
		font-size: clamp(34px, 10.5vw, 42px);
	}

	.ta-paths-detail-hero__stage {
		/* A definite width, not a max: the frame is sized as a percentage of the
		   stage, so a stage that shrank to its content would collapse it. */
		inline-size: min(100%, 360px);
		margin-inline: auto;
	}

	/* One step per row: the rail narrows so the card keeps its measure. */
	.ta-paths-steps__item {
		grid-template-columns: minmax(0, 1fr);
	}

	.ta-paths-steps__marker {
		inline-size: 36px;
		block-size: 36px;
		font-size: 16px;
	}

	.ta-paths-steps__item + .ta-paths-steps__item::before {
		inset-inline-start: 18px;
	}
}
