/* ===================================================================
   Internal links — auto-linked keywords + contextual callout
   
   Design goal: links should look completely native in the prose,
   not like injected SEO anchors. The only difference from a manual
   link is the dotted underline, which disappears on hover as the
   solid underline takes over.
   =================================================================== */

/* --- Auto-linked keywords ----------------------------------------- */
.tv-autolink {
	color: var(--tv-text, inherit);
	text-decoration: underline;
	text-decoration-style: dotted;
	text-decoration-color: var(--tv-border, #d0d0d0);
	text-underline-offset: 3px;
	text-decoration-thickness: 1px;
	transition: text-decoration-color 0.15s ease;
}

.tv-autolink:hover,
.tv-autolink:focus-visible {
	color: var(--tv-accent, #2563eb);
	text-decoration-style: solid;
	text-decoration-color: var(--tv-accent, #2563eb);
}

/* --- Contextual callout (in-content "also useful" box) ------------ */
.tv-ctx-callout {
	margin: var(--tv-space-6, 2rem) 0;
	padding: var(--tv-space-5, 1.25rem) var(--tv-space-6, 1.5rem);
	border: 1px solid var(--tv-border, #e2e2e2);
	border-radius: var(--tv-radius, 12px);
	background: var(--tv-surface, #fafafa);
}

.tv-ctx-callout__heading {
	margin: 0 0 var(--tv-space-3, 0.75rem);
	font-size: 0.8125rem;
	font-weight: 600;
	letter-spacing: 0.02em;
	color: var(--tv-text-muted, #6b6b6b);
}

.tv-ctx-callout__list {
	list-style: none;
	margin: 0;
	padding: 0;
	display: flex;
	flex-direction: column;
	gap: var(--tv-space-3, 0.75rem);
}

.tv-ctx-callout__list li {
	margin: 0;
	padding: 0;
}

.tv-ctx-callout__list a {
	display: block;
	color: var(--tv-text, #1a1a1a);
	text-decoration: none;
	font-size: 0.9375rem;
	line-height: 1.5;
	transition: color 0.15s ease;
}

.tv-ctx-callout__list a:hover,
.tv-ctx-callout__list a:focus-visible {
	color: var(--tv-accent, #2563eb);
}

.tv-ctx-callout__list a strong {
	font-weight: 600;
}

.tv-ctx-callout__list a span {
	color: var(--tv-text-muted, #6b6b6b);
	font-size: 0.875rem;
}

/* --- Category siblings section ------------------------------------ */
.tv-cat-explore {
	padding: var(--tv-space-5, 1.25rem) 0;
}

.tv-cat-explore__heading {
	font-size: 0.875rem;
	font-weight: 600;
	color: var(--tv-text-muted, #6b6b6b);
	margin-bottom: var(--tv-space-4, 1rem);
}

.tv-cat-explore__heading a {
	color: var(--tv-accent, #2563eb);
	text-decoration: none;
}

.tv-cat-explore__heading a:hover {
	text-decoration: underline;
}

.tv-cat-explore__grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
	gap: var(--tv-space-3, 0.75rem);
}

.tv-cat-explore__item {
	display: flex;
	align-items: baseline;
	gap: var(--tv-space-2, 0.5rem);
	padding: var(--tv-space-3, 0.75rem);
	border: 1px solid var(--tv-border, #e2e2e2);
	border-radius: var(--tv-radius-sm, 8px);
	text-decoration: none;
	color: var(--tv-text, #1a1a1a);
	font-size: 0.875rem;
	font-weight: 500;
	transition: border-color 0.15s ease, background 0.15s ease;
}

.tv-cat-explore__item:hover {
	border-color: var(--tv-accent, #2563eb);
	background: var(--tv-surface, #fafafa);
}

.tv-cat-explore__flow {
	font-size: 0.75rem;
	color: var(--tv-text-muted, #6b6b6b);
}
