/**
 * Single blog post reading aids.
 * All selectors are prefixed with body.single-post (or .lk-has-post-toc).
 * Intentionally does not target welcome-offer / cookie overlay UI.
 */

/* Measured sticky header ~61px on mobile; desktop sticky header typically ~70–90px.
   Use a safe offset so in-page H2 targets are not covered. */
body.single-post .c-post__content h2[id],
body.single-post .c-post__content .lk-post-toc,
body.single-post .c-post__content #lk-post-top {
	scroll-margin-top: 96px;
}

@media (max-width: 767px) {
	body.single-post .c-post__content h2[id],
	body.single-post .c-post__content .lk-post-toc,
	body.single-post .c-post__content #lk-post-top {
		scroll-margin-top: 76px;
	}
}

body.single-post .lk-post-top-anchor {
	display: block;
	height: 0;
	width: 0;
	overflow: hidden;
}

/* ----- TOC ----- */
body.single-post .lk-post-toc {
	box-sizing: border-box;
	margin: 0 0 1.75rem;
	padding: 0.85rem 1rem 0.95rem;
	border: 1px solid #e6e2dc;
	border-radius: 8px;
	background: #fbfaf7;
	color: #243447;
}

body.single-post .lk-post-toc__summary {
	cursor: pointer;
	font-family: "Jost", sans-serif;
	font-weight: 600;
	font-size: 0.95rem;
	letter-spacing: 0.04em;
	text-transform: uppercase;
	color: #16191f;
	list-style: none;
}

body.single-post .lk-post-toc__summary::-webkit-details-marker {
	display: none;
}

body.single-post .lk-post-toc__summary::before {
	content: "";
	display: inline-block;
	width: 0.45em;
	height: 0.45em;
	margin-right: 0.55em;
	border-right: 1.5px solid currentColor;
	border-bottom: 1.5px solid currentColor;
	transform: rotate(-45deg);
	vertical-align: 0.15em;
	transition: transform 0.15s ease;
}

body.single-post .lk-post-toc__details[open] > .lk-post-toc__summary::before {
	transform: rotate(45deg);
	vertical-align: 0.35em;
}

body.single-post .lk-post-toc__list {
	margin: 0.75rem 0 0;
	padding: 0 0 0 1.15rem;
	font-family: "Jost", sans-serif;
	font-size: 0.95rem;
	line-height: 1.45;
}

body.single-post .lk-post-toc__item + .lk-post-toc__item {
	margin-top: 0.35rem;
}

body.single-post .lk-post-toc__link {
	color: #234f8c;
	text-decoration: none;
}

body.single-post .lk-post-toc__link:hover,
body.single-post .lk-post-toc__link:focus {
	text-decoration: underline;
	text-underline-offset: 0.15em;
}

/* ----- Tables: scroll inside container, never force page-wide zoom ----- */
body.single-post .c-post__content .lk-post-table-scroll {
	box-sizing: border-box;
	width: 100%;
	max-width: 100%;
	margin: 1.25rem 0;
	overflow-x: auto;
	-webkit-overflow-scrolling: touch;
	overscroll-behavior-x: contain;
}

body.single-post .c-post__content .lk-post-table-scroll:focus {
	outline: 2px solid #234f8c;
	outline-offset: 2px;
}

body.single-post .c-post__content .lk-post-table-scroll table {
	width: max-content;
	min-width: 100%;
	margin: 0;
	border-collapse: collapse;
}

/* ----- End-of-article nav ----- */
body.single-post .lk-post-end-nav {
	margin: 1.5rem 0 0.5rem;
	font-family: "Jost", sans-serif;
	font-size: 0.9rem;
	color: #64748b;
}

body.single-post .lk-post-end-nav__link {
	color: #234f8c;
	text-decoration: none;
}

body.single-post .lk-post-end-nav__link:hover,
body.single-post .lk-post-end-nav__link:focus {
	text-decoration: underline;
}

/* ----- Floating back-to-top: low z-index, clear of bottom storefront overlays ----- */
body.single-post.lk-has-post-toc .lk-post-backtop {
	position: fixed;
	right: 16px;
	bottom: 96px; /* sits above typical bottom storefront overlays */
	z-index: 40; /* stay below welcome-offer / cookie overlays */
	box-sizing: border-box;
	padding: 0.45rem 0.7rem;
	border: 1px solid #e6e2dc;
	border-radius: 999px;
	background: rgba(251, 250, 247, 0.96);
	color: #243447;
	font-family: "Jost", sans-serif;
	font-size: 0.8rem;
	font-weight: 500;
	letter-spacing: 0.02em;
	text-decoration: none;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.06);
	opacity: 0;
	pointer-events: none;
	transform: translateY(6px);
	transition: opacity 0.2s ease, transform 0.2s ease;
}

body.single-post.lk-has-post-toc .lk-post-backtop.is-visible {
	opacity: 1;
	pointer-events: auto;
	transform: translateY(0);
}

body.single-post.lk-has-post-toc .lk-post-backtop:hover,
body.single-post.lk-has-post-toc .lk-post-backtop:focus {
	color: #16191f;
	border-color: #d2ccc2;
}

/* ----- Article-end product cards: show full titles (single-post only) ----- */
body.single-post .lakazur-related-content--products .woocommerce-loop-product__title {
	display: block !important;
	height: auto !important;
	max-height: none !important;
	overflow: visible !important;
	white-space: normal !important;
	text-overflow: unset !important;
	-webkit-line-clamp: unset !important;
	line-clamp: unset !important;
	-webkit-box-orient: unset !important;
}

@supports (height: 1lh) {
	body.single-post .lakazur-related-content--products .woocommerce-loop-product__title {
		height: auto !important;
	}
}

/* ----- Tighten excess blank space at article end (single-post only) ----- */
body.single-post .c-post__container.l-section--bottom-margin {
	margin-bottom: 28px;
}

body.single-post .lakazur-related-content--products {
	margin-top: 0.75rem;
	margin-bottom: 1.25rem;
}

body.single-post .lakazur-related-content--products .c-product__products-title {
	margin-top: 0;
	margin-bottom: 0.75rem;
}

body.single-post .c-post__bottom {
	margin-top: 1rem;
	margin-bottom: 0.75rem;
}

/* 2026-11-14: "width: max-content" made tables with sentence-length cells 1,000–1,900px wide,
   so they scrolled sideways even on desktop. Fit the content column and let text wrap;
   keep a 560px floor so narrow phones scroll a little instead of squeezing words. */
body.single-post .c-post__content .lk-post-table-scroll table {
	width: 100%;
	min-width: 560px;
}
body.single-post .c-post__content .lk-post-table-scroll table {
	table-layout: auto;
}
body.single-post .c-post__content .lk-post-table-scroll th,
body.single-post .c-post__content .lk-post-table-scroll td {
	padding: 8px 14px;
	font-size: 15px;
	line-height: 1.55;
	vertical-align: top;
}
