/*
  Page template: single.php — article read view.
  Figma: D-Article Read (34:2387).

  Layout (desktop):
  ┌───────────────────────────────────────────────────────────────────┐
  │              full-bleed featured image hero (636px)               │
  └───────────────────────────────────────────────────────────────────┘
   [meta + share rail]   [article body]            [Të tjera sidebar]
                                                   (4 horizontal cards)
   ─────────────────── related grid 4×2 ───────────────────
*/

.c-single { display: contents; }

/* ---------- Hero ---------- */
.c-single__hero {
	position: relative;
	height: 636px;
	background: var(--c-grey-medium) center / cover no-repeat;
	color: var(--c-light);
	margin-bottom: var(--space-12);
	isolation: isolate;
}
.c-single__hero-overlay {
	position: absolute;
	inset: 0;
	background: linear-gradient(
		to bottom,
		rgba(0, 0, 0, 0.15) 0%,
		rgba(0, 0, 0, 0) 30%,
		rgba(0, 0, 0, 0) 55%,
		rgba(0, 0, 0, 0.85) 100%
	);
	z-index: 1;
	pointer-events: none;
}
.c-single__hero-inner {
	position: relative;
	z-index: 2;
	height: 100%;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	padding-block: 55px 64px;
}
.c-single__hero-bar {
	display: flex;
	align-items: flex-start;
	gap: var(--space-4);
}
.c-single__hero-title {
	margin: 0;
	margin-left: 308px; /* lines up with the article body column (218 rail + 90 gap) */
	max-width: 955px;
	font-size: var(--fs-hero);
	line-height: var(--lh-hero);
	font-weight: var(--fw-bold);
	letter-spacing: -1.92px;
	color: var(--c-light);
}

.c-single__back {
	display: inline-flex;
	width: 54px;
	height: 54px;
	align-items: center;
	justify-content: center;
	color: var(--c-light);
	text-decoration: none;
	transition: transform 200ms ease;
}
.c-single__back:hover { transform: translateX(-3px); }

.c-single__cat {
	display: inline-flex;
	align-items: center;
	padding: 8px 14px;
	border: 1px solid var(--c-light);
	border-radius: var(--radius-md);
	color: var(--c-light);
	font-size: var(--fs-heading-14);
	line-height: var(--lh-heading-14);
	font-weight: var(--fw-semibold);
	letter-spacing: -0.42px;
	text-transform: uppercase;
	text-decoration: none;
}

/* ---------- 3-col content grid ---------- */
.c-single__layout {
	display: grid;
	grid-template-columns: 218px minmax(0, 628px) 1fr;
	gap: 90px;
	align-items: start;
	margin-bottom: var(--space-16);
}

/* Left rail (meta + share) — sticky. */
.c-single__rail {
	position: sticky;
	top: 120px; /* header height + a little */
	display: flex;
	flex-direction: column;
	gap: var(--space-6);
}
.c-single__meta {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: var(--fs-label-12);
	line-height: var(--lh-label-12);
	color: var(--c-fg);
}
.c-single__meta time { white-space: nowrap; }
.c-single__read-time {
	position: relative;
	padding-left: 26px;
	min-width: 80px;
}
.c-single__read-time::before {
	content: "";
	position: absolute;
	left: 0;
	top: 50%;
	transform: translateY(-50%);
	width: 14px;
	height: 1px;
	background: var(--c-fg);
}
/* Sticky share rail — Figma 122:2230 (42×42 targets, 28px icons, vertical stack). */
.c-single__share {
	display: flex;
	flex-direction: column;
	gap: 10px;
	list-style: none;
	margin: 0;
	padding: 0;
}
.c-single__share-item {
	margin: 0;
	padding: 0;
}
.c-single__share-btn {
	all: unset;
	box-sizing: border-box;
	display: inline-flex;
	width: 42px;
	height: 42px;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	text-decoration: none;
	transition: opacity 150ms ease, transform 150ms ease;
}
.c-single__share-btn:hover {
	opacity: 0.82;
	transform: scale(1.04);
}
.c-single__share-btn:focus-visible {
	outline: 2px solid var(--c-accent);
	outline-offset: 2px;
}
.c-single__share-btn.is-copied {
	opacity: 0.55;
}
.c-single__share-btn svg {
	display: block;
	flex-shrink: 0;
}

/* ---------- Article body ---------- */
.c-single__main {
	min-width: 0;
}

.c-single__engagement {
	display: flex;
	gap: var(--space-4);
	align-items: center;
	font-size: var(--fs-link-14);
	line-height: var(--lh-link-14);
	color: var(--c-fg);
	margin-bottom: var(--space-4);
}
.c-single__likes,
.c-single__shares {
	display: inline-flex;
	align-items: center;
	gap: 4px;
	color: var(--c-fg);
}

/* Hero Headline — body title + lede (48 / 60 / 700 / -1.92px). */
.c-single__title,
.c-single__lede {
	margin: 0 0 var(--space-4);
	color: var(--c-dark, #000);
	font-size: var(--fs-hero);
	line-height: var(--lh-hero);
	font-weight: var(--fw-bold);
	letter-spacing: -1.92px;
}

.c-single__lede {
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

/* Read Article — 21px / 600 / 150% lh (Figma body copy). */
.c-single__content {
	color: var(--c-dark, #000);
	font-size: var(--fs-read);
	line-height: var(--lh-read);
	font-weight: var(--fw-semibold);
}
.c-single__content p iframe {
	width: 100%;
}
.c-single__content > * + * { margin-top: var(--space-4); }
.c-single__content p {
	margin: 0 0 var(--space-4);
	font-size: inherit;
	line-height: inherit;
	font-weight: inherit;
	color: inherit;
}
.c-single__content p + p { margin-top: 0; }
.c-single__content p:last-child { margin-bottom: 0; }
.c-single__content h2     { font-size: 28px; line-height: 1.2; font-weight: var(--fw-bold); margin-top: var(--space-8); }
.c-single__content h3     { font-size: 22px; line-height: 1.3; font-weight: var(--fw-bold); margin-top: var(--space-6); }
.c-single__content a      { color: var(--c-accent); text-decoration: underline; text-underline-offset: 2px; }
.c-single__content img,
.c-single__content figure { border-radius: var(--radius-md); overflow: hidden; max-width: 100%; height: auto; }
.c-single__content blockquote {
	margin: var(--space-6) 0;
	padding: 16px 20px;
	border-left: 4px solid var(--c-accent);
	font-style: italic;
	font-size: 22px;
	line-height: 1.4;
}
.c-single__content ul,
.c-single__content ol {
	padding-left: 1.4em;
	list-style: revert;
}
.c-single__content ul li,
.c-single__content ol li { margin-block: 6px; }

.c-single__tags {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: var(--space-8);
}
.c-single__tags a {
	display: inline-flex;
	padding: 6px 12px;
	background: var(--c-grey-light);
	border-radius: var(--radius-pill);
	color: var(--c-fg);
	font-size: var(--fs-link-14);
	font-weight: var(--fw-semibold);
	text-decoration: none;
}
.c-single__tags a:hover { background: var(--c-fg); color: var(--c-light); }

.c-single__comments { margin-top: var(--space-12); }

/* ---------- Sidebar (Figma 40:1872) ---------- */
.c-single__sidebar {
	display: flex;
	flex-direction: column;
	gap: var(--space-4);
	max-width: 225px;
}
.c-single__sidebar-title {
	margin: 0;
	font-size: var(--fs-h3);
	line-height: var(--lh-h3);
	font-weight: var(--fw-semibold);
	color: var(--c-dark, #000);
}
.c-single__sidebar-list {
	display: flex;
	flex-direction: column;
	gap: var(--space-4);
}
.c-single__sidebar-list .c-card-horizontal + .c-card-horizontal {
	border: 0;
	padding: 0;
}

/* ---------- Related ---------- */
.c-single__related {
	margin-block: var(--space-12);
	display: flex;
	flex-direction: column;
	gap: var(--space-6);
}
.c-card-grid--gap-tall { row-gap: var(--space-8); }

/* ---------- Firmat (single-firmat.php) hero ---------- */
.c-firmat-hero {
	display: grid;
	grid-template-columns: minmax(0, 630fr) minmax(0, 630fr);
	gap: 20px;
	padding-block: var(--space-8) var(--space-12);
}
.c-firmat-hero__media {
	min-width: 0;
}
.c-firmat-hero__media .c-hero-half { aspect-ratio: 630 / 588; }
.c-firmat-hero__profile {
	padding: var(--space-4) 0;
	display: flex;
	flex-direction: column;
	gap: var(--space-4);
}
.c-firmat-hero__profile-head h2 {
	margin: 0;
	font-size: var(--fs-h3);
	line-height: var(--lh-h3);
	font-weight: var(--fw-semibold);
	color: var(--c-fg-muted);
	padding-bottom: var(--space-4);
	border-bottom: 1px solid var(--c-border);
}
.c-firmat-hero__rows {
	margin: 0;
	display: flex;
	flex-direction: column;
}
.c-firmat-hero__row {
	display: flex;
	gap: 4px;
	align-items: baseline;
	padding-block: 12px;
	border-bottom: 1px solid var(--c-border);
	font-size: 18px;
	line-height: 1.4;
}
.c-firmat-hero__row dt {
	margin: 0;
	font-weight: var(--fw-bold);
	color: var(--c-fg);
}
.c-firmat-hero__row dd {
	margin: 0;
	color: var(--c-fg);
	font-weight: var(--fw-semibold);
}

@media (max-width: 1024px) {
	.c-firmat-hero { grid-template-columns: 1fr; gap: var(--space-6); }
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
	.c-single__layout {
		grid-template-columns: minmax(0, 1fr) 320px;
		gap: var(--space-8);
	}
	.c-single__rail {
		grid-column: 1 / -1;
		flex-direction: row;
		justify-content: space-between;
		align-items: center;
		position: static;
	}
	.c-single__share { flex-direction: row; }
}
@media (max-width: 1100px) {
	.c-single__hero-title {
		margin-left: 0;
		max-width: none;
	}
}
@media (max-width: 768px) {
	.c-single__hero  { height: 380px; }
	.c-single__hero-inner { padding-block: 32px 40px; }
	.c-single__hero-title,
	.c-single__title,
	.c-single__lede { font-size: 32px; line-height: 38px; letter-spacing: -1px; }
	.c-single__layout { grid-template-columns: 1fr; }
	.c-single__sidebar {
		margin-top: var(--space-8);
		max-width: none;
	}
}
