/**
 * LTC Insights Article — editorial single-post template (2026-08-09).
 *
 * Only enqueued on "post" post type singles — see
 * ltc_child_enqueue_insights_styles() in functions.php. Reuses
 * .ltc-card-insight / .ltc-insight-grid (ltc-home.css, loaded
 * site-wide) for the related-articles strip rather than redefining a
 * card component; everything else here is specific to the article
 * hero, reading column, table of contents and closing continuation
 * area, so it lives in its own file per this theme's existing
 * one-file-per-page-type convention (ltc-contact.css,
 * ltc-programmes.css, ltc-resource-detail.css).
 */

/* =========================================================
   Hero
   ========================================================= */

.ltc-article-hero__inner {
	max-width: 800px;
}

.ltc-article-hero__title {
	margin-top: var(--ltc-space-4);
}

.ltc-article-hero__excerpt {
	margin-top: var(--ltc-space-5);
	max-width: 62ch;
	color: var(--ltc-text-muted);
	font-size: var(--ltc-type-body-lg);
	line-height: var(--ltc-leading-body-lg);
}

.ltc-article-hero__media {
	margin-top: var(--ltc-space-7);
}

.ltc-article-hero__image {
	width: 100%;
	aspect-ratio: 16 / 9;
	object-fit: cover;
	object-position: center;
	border-radius: var(--ltc-radius-image);
	box-shadow: var(--ltc-shadow-elevated);
}

/* =========================================================
   Reading layout
   ========================================================= */

.ltc-article-layout {
	display: grid;
	gap: var(--ltc-space-9);
}

.ltc-article-layout--with-toc {
	grid-template-columns: 260px minmax(0, 1fr);
	align-items: start;
}

.ltc-article-layout--plain {
	grid-template-columns: minmax(0, 1fr);
}

.ltc-article-body {
	max-width: var(--ltc-article-width);
}

.ltc-article-layout--plain .ltc-article-body {
	margin-inline: auto;
}

/* =========================================================
   Table of contents
   ========================================================= */

.ltc-article-toc {
	position: sticky;
	top: 104px;
	max-height: calc(100vh - 140px);
	overflow-y: auto;
}

.ltc-article-toc__disclosure {
	padding: var(--ltc-space-5);
	background: var(--ltc-white);
	border: 1px solid var(--ltc-stone-200);
	border-radius: var(--ltc-radius-card);
}

.ltc-article-toc__summary {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: var(--ltc-space-3);
	cursor: pointer;
	list-style: none;
	font-size: var(--ltc-type-eyebrow);
	font-weight: var(--ltc-weight-heading);
	text-transform: uppercase;
	letter-spacing: var(--ltc-tracking-eyebrow);
	color: var(--ltc-teal-700);
}

.ltc-article-toc__summary::-webkit-details-marker {
	display: none;
}

.ltc-article-toc__chevron {
	transition: transform var(--ltc-duration-standard) var(--ltc-ease);
}

.ltc-article-toc__disclosure[open] .ltc-article-toc__chevron {
	transform: rotate(180deg);
}

.ltc-article-toc__list {
	margin: var(--ltc-space-4) 0 0;
	padding: 0;
	list-style: none;
	display: flex;
	flex-direction: column;
	gap: var(--ltc-space-2);
}

.ltc-article-toc__item a {
	display: block;
	padding: var(--ltc-space-1) 0;
	color: var(--ltc-ink-900);
	font-size: 0.875rem;
	line-height: 1.45;
	text-decoration: none;
	border-left: 2px solid transparent;
	padding-left: var(--ltc-space-3);
}

.ltc-article-toc__item a:hover,
.ltc-article-toc__item a:focus-visible {
	color: var(--ltc-teal-700);
	border-left-color: var(--ltc-teal-500);
}

.ltc-article-toc__item--h3 a {
	padding-left: var(--ltc-space-6);
	color: var(--ltc-text-muted);
	font-size: 0.8125rem;
}

/* =========================================================
   Article body typography
   ========================================================= */

.ltc-article-body {
	font-size: 1.125rem;
	line-height: 1.75;
	color: var(--ltc-ink-900);
}

.ltc-article-body > * + * {
	margin-top: var(--ltc-space-5);
}

.ltc-article-body h2 {
	margin-top: var(--ltc-space-8);
	font-family: var(--ltc-font-sans);
	font-weight: var(--ltc-weight-heading);
	font-size: 1.75rem;
	line-height: 1.25;
	color: var(--ltc-ink-950);
	scroll-margin-top: 104px;
}

.ltc-article-body h3 {
	margin-top: var(--ltc-space-7);
	font-family: var(--ltc-font-sans);
	font-weight: var(--ltc-weight-heading);
	font-size: 1.375rem;
	line-height: 1.3;
	color: var(--ltc-ink-950);
	scroll-margin-top: 104px;
}

.ltc-article-body h4 {
	margin-top: var(--ltc-space-6);
	font-family: var(--ltc-font-sans);
	font-weight: var(--ltc-weight-subhead);
	font-size: 1.125rem;
	color: var(--ltc-ink-950);
	scroll-margin-top: 104px;
}

.ltc-article-body h2 + h3,
.ltc-article-body h2 + h4,
.ltc-article-body h3 + h4 {
	margin-top: var(--ltc-space-3);
}

.ltc-article-body p {
	color: var(--ltc-ink-900);
}

.ltc-article-body ul,
.ltc-article-body ol {
	padding-left: 1.4em;
}

.ltc-article-body li + li {
	margin-top: var(--ltc-space-2);
}

.ltc-article-body li::marker {
	color: var(--ltc-teal-600);
}

.ltc-article-body a {
	color: var(--ltc-ink-900);
	text-decoration-line: underline;
	text-decoration-color: var(--ltc-stone-200);
	text-underline-offset: 3px;
	transition: text-decoration-color var(--ltc-duration-fast) var(--ltc-ease);
}

.ltc-article-body a:hover,
.ltc-article-body a:focus-visible {
	text-decoration-color: var(--ltc-teal-600);
}

/* Some existing articles embed their own already-styled Button blocks
   (background colour + radius set via the block's own inline style —
   e.g. the "Contact us" button in "How To Build A High Performance
   Team From Scratch?"). The generic underline above is for plain text
   links; a pill-shaped button should not get one. */
.ltc-article-body a.wp-element-button {
	text-decoration: none;
}

.ltc-article-body img {
	max-width: 100%;
	height: auto;
	border-radius: var(--ltc-radius-image);
}

.ltc-article-body figure {
	margin: 0;
}

.ltc-article-body figcaption {
	margin-top: var(--ltc-space-2);
	color: var(--ltc-text-muted);
	font-size: 0.875rem;
	text-align: center;
}

.ltc-article-body hr {
	border: none;
	border-top: 1px solid var(--ltc-stone-200);
	margin: var(--ltc-space-7) 0;
}

.ltc-article-body blockquote {
	margin: var(--ltc-space-6) 0;
	padding: var(--ltc-space-2) 0 var(--ltc-space-2) var(--ltc-space-6);
	border-left: 3px solid var(--ltc-teal-500);
	font-family: var(--ltc-font-serif);
	font-style: italic;
	font-size: 1.25rem;
	line-height: 1.6;
	color: var(--ltc-teal-700);
}

.ltc-article-body blockquote p {
	color: inherit;
}

.ltc-article-body table {
	width: 100%;
	border-collapse: collapse;
	font-size: 0.9375rem;
}

.ltc-article-body th,
.ltc-article-body td {
	padding: var(--ltc-space-3);
	border: 1px solid var(--ltc-stone-200);
	text-align: left;
}

/* =========================================================
   Continuation area
   ========================================================= */

.ltc-article-continuation__related + .ltc-article-continuation__cta {
	margin-top: var(--ltc-space-9);
	padding-top: var(--ltc-space-8);
	border-top: 1px solid var(--ltc-stone-200);
}

.ltc-article-continuation__cta {
	max-width: 68ch;
}

.ltc-article-continuation__cta p {
	margin-top: var(--ltc-space-3);
	color: var(--ltc-text-muted);
	font-size: var(--ltc-type-body);
	line-height: var(--ltc-leading-body);
}

.ltc-article-continuation__cta-actions {
	margin-top: var(--ltc-space-5);
	display: flex;
	align-items: center;
	gap: var(--ltc-space-6);
	flex-wrap: wrap;
}

/* =========================================================
   Responsive
   ========================================================= */

@media (max-width: 1023px) {
	.ltc-article-layout--with-toc {
		grid-template-columns: minmax(0, 1fr);
	}

	.ltc-article-toc {
		position: static;
		max-height: none;
	}

	/* A long TOC (some articles have 15+ headings) would otherwise push
	   the article itself a full screen or more down on a stacked
	   mobile/tablet layout — an internal scroll keeps the box compact
	   while the full list stays reachable. */
	.ltc-article-toc__list {
		max-height: 260px;
		overflow-y: auto;
	}

	.ltc-article-body {
		max-width: none;
	}
}

@media (max-width: 767px) {
	.ltc-article-hero__title {
		max-width: none;
	}

	.ltc-article-body {
		font-size: 1.0625rem;
	}

	.ltc-article-body h2 {
		font-size: 1.5rem;
	}

	.ltc-article-body h3 {
		font-size: 1.25rem;
	}

	.ltc-article-continuation__cta-actions {
		flex-direction: column;
		align-items: flex-start;
		gap: var(--ltc-space-4);
	}
}
