/* ==========================================================================
   Combecom Theme — Single Article Template
   File: assets/css/pages/article.css
   Enqueued ONLY on is_single() — depends on assets/css/global/theme.css

   ✦ Integration rule: NO independent palette here. Every color, easing and
     surface is an ALIAS of the global tokens defined in theme.css
     (--ink-*, --brand-*, --neon-*, --mist-*, --card-bg, --line, --ease).
   ✦ Containers use the GLOBAL .cx class; the reading-progress bar reuses the
     GLOBAL .header-progress element that already lives in site-header.
   ✦ Scope: everything lives under .page-single-post — zero global leakage.
   ========================================================================== */

.page-single-post {
	/* ---- aliases → global tokens (theme.css) ---- */
	--sp-bg: var(--ink-900);
	--sp-bg-2: var(--ink-850);
	--sp-card: var(--card-bg);
	--sp-card-solid: var(--ink-800);
	--sp-border: var(--line);
	--sp-brand: var(--brand-400);
	--sp-brand-soft: var(--brand-300);
	--sp-neon: var(--neon-400);
	--sp-neon-soft: var(--neon-300);
	--sp-text: #ffffff;
	--sp-text-2: var(--mist-400);
	--sp-text-3: var(--mist-500);

	/* exact global recipes */
	--sp-gradient: linear-gradient(120deg, var(--brand-500) 10%, var(--brand-600) 55%, #4f8dff 130%); /* same as .btn-primary */
	--sp-grad-text: linear-gradient(100deg, var(--brand-300), var(--neon-400));                      /* same as .head-title .grad */
	--sp-grad-v: linear-gradient(180deg, var(--brand-500), var(--neon-500));                         /* same as scrollbar thumb */
	--sp-glow: color-mix(in srgb, var(--brand-500) 28%, transparent);
	--sp-glow-strong: color-mix(in srgb, var(--brand-500) 65%, transparent);
	--sp-ease: var(--ease);

	direction: rtl;
	text-align: right;
	background-color: var(--sp-bg);
	color: var(--sp-text);
	overflow-x: clip;
	padding-bottom: 96px;
}

/* ==========================================================================
   Reading progress
   ⟹ handled by the GLOBAL .header-progress inside .site-header (theme.css),
     driven from assets/js/pages/article.js — no page-level bar here.
   ========================================================================== */

/* ==========================================================================
   Article header  (template-parts/single/article-header.php)
   ========================================================================== */

.single-post-intro {
	position: relative;
	padding: 120px 4vw 46px;
	text-align: center;
}

.single-post-intro__inner {
	max-width: 820px;
	margin-inline: auto;
	position: relative;
	z-index: 1;
}

.single-post-breadcrumb {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	gap: 8px;
	margin-bottom: 26px;
	font-size: 0.8rem;
	color: var(--sp-text-3);
}

.single-post-breadcrumb a {
	color: var(--sp-text-3);
	transition: color 0.3s ease;
}

.single-post-breadcrumb a:hover {
	color: var(--sp-neon-soft);
}

.single-post-breadcrumb svg {
	width: 13px;
	height: 13px;
	opacity: 0.5;
}

.single-post-breadcrumb [aria-current="page"] {
	color: var(--sp-text-2);
	font-weight: 600;
}

.single-post-intro__title {
	margin: 0;
	font-size: clamp(1.9rem, 4.4vw, 3.15rem);
	font-weight: 850;
	line-height: 1.35;
	letter-spacing: -0.01em;
	color: var(--sp-text);
	text-wrap: balance;
}

.single-post-intro__title .title-accent {
	background: var(--sp-grad-text);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: transparent;
}

.single-post-intro__excerpt {
	margin: 16px auto 0;
	max-width: 640px;
	font-size: clamp(0.95rem, 1.6vw, 1.08rem);
	line-height: 2;
	color: var(--sp-text-2);
}

/* ==========================================================================
   Featured image + meta row
   ========================================================================== */

.single-post-hero {
	margin-top: 10px;
}

.single-post-hero__frame {
	position: relative;
	border-radius: 22px;
	overflow: hidden;
	border: 1px solid var(--sp-border);
	box-shadow:
		0 30px 80px rgba(0, 0, 0, 0.5),
		0 0 90px color-mix(in srgb, var(--brand-500) 14%, transparent);
}

.single-post-hero__frame::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, transparent 62%, color-mix(in srgb, var(--ink-900) 55%, transparent) 100%);
	pointer-events: none;
}

.single-post-hero__frame img {
	width: 100%;
	height: auto;
	aspect-ratio: 21 / 9;
	object-fit: cover;
}

/* ---------- meta (author/date/reading time) — below hero ---------- */

.single-post-below-hero {
	margin-top: 26px;
}

.article-meta {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: center;
	gap: 14px 30px;
}

.article-meta__author {
	display: inline-flex;
	align-items: center;
	gap: 12px;
}

.article-meta__avatar {
	width: 46px;
	height: 46px;
	border-radius: 50%;
	display: grid;
	place-items: center;
	font-size: 1.05rem;
	font-weight: 800;
	color: #ffffff;
	background: var(--sp-gradient);
	box-shadow:
		0 0 0 2px color-mix(in srgb, var(--brand-400) 35%, transparent),
		0 6px 18px var(--sp-glow);
	flex-shrink: 0;
}

.article-meta__who {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
	gap: 2px;
}

.article-meta__name {
	font-size: 0.95rem;
	font-weight: 700;
	color: var(--sp-text);
}

.article-meta__role {
	font-size: 0.78rem;
	color: var(--sp-text-3);
}

.article-meta__sep {
	width: 1px;
	height: 30px;
	background: var(--sp-border);
}

.article-meta__item {
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 0.88rem;
	color: var(--sp-text-2);
	white-space: nowrap;
}

.article-meta__item svg {
	width: 17px;
	height: 17px;
	color: var(--sp-brand);
	flex-shrink: 0;
}

/* ==========================================================================
   Layout — main column (right) + TOC column (left, sticky)
   گرید دو ستونه: فرزند اول محتوا (راست)، فرزند دوم «در این مقاله» (چپ).
   ========================================================================== */

.single-post-layout {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 280px;
	gap: 52px;
	margin-top: 68px;
	align-items: start;
}

/* قرارگیری صریح ستون‌ها — مستقل از ترتیب DOM */
.page-single-post .single-post-main {
	grid-column: 1;
	grid-row: 1;
	min-width: 0;
}

.page-single-post .article-toc {
	grid-column: 2;
	grid-row: 1;
}

.single-post-layout--no-toc {
	grid-template-columns: minmax(0, 1fr);
}

/* ---------- TOC — sticky sidebar (desktop) ---------- */

.article-toc {
	position: sticky;
	top: 118px;
	background: var(--sp-card);
	border: 1px solid var(--sp-border);
	border-radius: 22px;
	padding: 24px 22px;
}

.article-toc__title {
	display: flex;
	align-items: center;
	gap: 10px;
	margin: 0 0 18px;
	padding-bottom: 16px;
	border-bottom: 1px solid var(--sp-border);
	font-size: 0.98rem;
	font-weight: 800;
	color: var(--sp-text);
}

.article-toc__title svg {
	width: 18px;
	height: 18px;
	color: var(--sp-brand);
}

.article-toc__list {
	display: flex;
	flex-direction: column;
	gap: 2px;
	max-height: 54vh;
	overflow-y: auto;
	scrollbar-width: thin;
}

.article-toc__link {
	position: relative;
	display: block;
	padding: 9px 16px 9px 8px;
	font-size: 0.86rem;
	line-height: 1.7;
	color: var(--sp-text-3);
	border-radius: 10px;
	transition: color 0.3s ease, background-color 0.3s ease;
}

.article-toc__link::before {
	content: "";
	position: absolute;
	inset-inline-start: 0;
	top: 50%;
	width: 3px;
	height: 0;
	border-radius: 4px;
	background: var(--sp-grad-v);
	box-shadow: 0 0 10px var(--sp-glow);
	transform: translateY(-50%);
	transition: height 0.35s var(--sp-ease);
}

.article-toc__link:hover {
	color: var(--sp-text-2);
}

.article-toc__link.is-active {
	color: var(--sp-text);
	background: color-mix(in srgb, var(--brand-500) 10%, transparent);
	font-weight: 600;
}

.article-toc__link.is-active::before {
	height: 62%;
}

.article-toc__link--sub {
	padding-inline-start: 32px;
	font-size: 0.8rem;
}

.article-toc__link--sub::before {
	inset-inline-start: 14px;
}

/* ---------- TOC — accordion (mobile) ---------- */

.article-toc-accordion {
	display: none;
	background: var(--sp-card);
	border: 1px solid var(--sp-border);
	border-radius: 20px;
	margin-bottom: 40px;
	overflow: hidden;
}

.article-toc-accordion__btn {
	width: 100%;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 18px 20px;
	font-size: 0.95rem;
	font-weight: 800;
	color: var(--sp-text);
	cursor: pointer;
}

.article-toc-accordion__btn .toc-label {
	display: inline-flex;
	align-items: center;
	gap: 10px;
}

.article-toc-accordion__btn .toc-label svg {
	width: 18px;
	height: 18px;
	color: var(--sp-brand);
}

.article-toc-accordion__chevron {
	width: 18px;
	height: 18px;
	color: var(--sp-text-3);
	transition: transform 0.4s var(--sp-ease);
}

.article-toc-accordion.is-open .article-toc-accordion__chevron {
	transform: rotate(180deg);
	color: var(--sp-neon);
}

.article-toc-accordion__panel {
	display: grid;
	grid-template-rows: 0fr;
	transition: grid-template-rows 0.45s var(--sp-ease);
}

.article-toc-accordion.is-open .article-toc-accordion__panel {
	grid-template-rows: 1fr;
}

.article-toc-accordion__inner {
	overflow: hidden;
	min-height: 0;
}

.article-toc-accordion__list {
	display: flex;
	flex-direction: column;
	gap: 2px;
	padding: 4px 20px 20px;
}

/* ==========================================================================
   Article content  (template-parts/single/article-content.php)
   ========================================================================== */

.article-content {
	min-width: 0;
}

.article-content p {
	margin: 0 0 26px;
	font-size: 1.06rem;
	line-height: 2.1;
	color: var(--sp-text-2);
}

.article-content p.article-lead {
	font-size: 1.18rem;
	line-height: 2.05;
	color: var(--sp-text);
	font-weight: 500;
}

.article-content strong {
	color: var(--sp-text);
	font-weight: 700;
}

.article-content a {
	color: var(--sp-neon-soft);
	font-weight: 600;
	background-image: linear-gradient(90deg, var(--neon-400), var(--brand-500));
	background-repeat: no-repeat;
	background-size: 0% 1.5px;
	background-position: 100% 100%;
	transition: background-size 0.4s var(--sp-ease), color 0.3s;
	padding-bottom: 2px;
}

.article-content a:hover {
	background-size: 100% 1.5px;
}

/* ----- headings ----- */

.article-content h2 {
	position: relative;
	margin: 56px 0 22px;
	padding-inline-start: 18px;
	font-size: clamp(1.35rem, 2.6vw, 1.68rem);
	font-weight: 850;
	line-height: 1.6;
	color: var(--sp-text);
	scroll-margin-top: 130px;
}

.article-content h2::before {
	content: "";
	position: absolute;
	inset-inline-start: 0;
	top: 0.32em;
	bottom: 0.32em;
	width: 4px;
	border-radius: 4px;
	background: var(--sp-grad-v);
	box-shadow: 0 0 14px var(--sp-glow);
}

.article-content h3 {
	position: relative;
	margin: 40px 0 16px;
	padding-inline-start: 20px;
	font-size: clamp(1.08rem, 2vw, 1.24rem);
	font-weight: 800;
	line-height: 1.7;
	color: var(--sp-text);
	scroll-margin-top: 130px;
}

.article-content h3::before {
	content: "";
	position: absolute;
	inset-inline-start: 2px;
	top: 0.72em;
	width: 8px;
	height: 8px;
	border-radius: 2px;
	background: var(--sp-gradient);
	transform: rotate(45deg);
	box-shadow: 0 0 10px var(--sp-glow);
}

/* ----- lists ----- */

.article-content ul,
.article-content ol {
	margin: 0 0 28px;
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.article-content ul li,
.article-content ol li {
	position: relative;
	padding-inline-start: 30px;
	font-size: 1.02rem;
	line-height: 1.95;
	color: var(--sp-text-2);
}

.article-content ul li::before {
	content: "";
	position: absolute;
	inset-inline-start: 4px;
	top: 0.78em;
	width: 9px;
	height: 9px;
	border-radius: 2.5px;
	background: var(--sp-gradient);
	transform: rotate(45deg);
	box-shadow: 0 0 8px var(--sp-glow);
}

.article-content ol {
	counter-reset: sp-ol;
}

.article-content ol li {
	counter-increment: sp-ol;
	padding-inline-start: 46px;
}

.article-content ol li::before {
	content: counter(sp-ol);
	position: absolute;
	inset-inline-start: 0;
	top: 0.28em;
	width: 30px;
	height: 30px;
	display: grid;
	place-items: center;
	font-size: 0.85rem;
	font-weight: 700;
	color: var(--sp-brand-soft);
	background: color-mix(in srgb, var(--brand-500) 10%, transparent);
	border: 1px solid color-mix(in srgb, var(--brand-400) 35%, transparent);
	border-radius: 9px;
}

/* ----- blockquote ----- */

.article-content blockquote {
	position: relative;
	margin: 40px 0;
	padding: 30px 34px 30px 30px;
	background: var(--sp-bg-2);
	border: 1px solid var(--sp-border);
	border-radius: 20px;
	overflow: hidden;
}

.article-content blockquote::before {
	content: "";
	position: absolute;
	inset-inline-start: 0;
	top: 0;
	bottom: 0;
	width: 4px;
	background: var(--sp-grad-v);
	box-shadow: 0 0 18px var(--sp-glow);
}

.article-content blockquote p {
	margin: 0;
	font-size: 1.14rem;
	font-weight: 600;
	line-height: 2;
	color: var(--sp-text);
}

.article-content blockquote .quote-mark {
	position: absolute;
	top: 6px;
	inset-inline-end: 18px;
	font-size: 5.4rem;
	font-weight: 900;
	line-height: 1;
	font-family: Georgia, serif;
	background: var(--sp-grad-text);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: transparent;
	opacity: 0.28;
	pointer-events: none;
}

/* ----- inline code & code blocks ----- */

.article-content code {
	font-family: "JetBrains Mono", "Courier New", monospace;
	font-size: 0.85em;
	font-weight: 600;
	direction: ltr;
	unicode-bidi: embed;
	color: var(--sp-brand-soft);
	background: color-mix(in srgb, var(--brand-500) 10%, transparent);
	border: 1px solid color-mix(in srgb, var(--brand-400) 28%, transparent);
	border-radius: 7px;
	padding: 3px 8px;
}

.article-content .code-block {
	direction: ltr;
	text-align: left;
	margin: 36px 0;
	border-radius: 20px;
	border: 1px solid var(--sp-border);
	background: var(--sp-bg-2);
	overflow: hidden;
	box-shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
}

.code-block__head {
	display: flex;
	align-items: center;
	gap: 8px;
	padding: 13px 18px;
	background: var(--sp-card);
	border-bottom: 1px solid var(--sp-border);
}

.code-block__dot {
	width: 11px;
	height: 11px;
	border-radius: 50%;
	background: color-mix(in srgb, var(--mist-200) 14%, transparent);
}

.code-block__dot--brand {
	background: var(--sp-gradient);
	box-shadow: 0 0 8px var(--sp-glow);
}

.code-block__lang {
	margin-inline-start: auto;
	font-family: "JetBrains Mono", monospace;
	font-size: 0.68rem;
	font-weight: 600;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: var(--sp-text-3);
}

.code-block pre {
	margin: 0;
	padding: 22px 24px;
	overflow-x: auto;
	font-family: "JetBrains Mono", "Courier New", monospace;
	font-size: 0.84rem;
	line-height: 1.85;
	color: var(--sp-text-2);
	scrollbar-width: thin;
}

.code-block .tok-tag { color: var(--brand-300); }
.code-block .tok-var { color: var(--mist-200); }
.code-block .tok-str { color: var(--neon-300); }
.code-block .tok-com { color: var(--sp-text-3); font-style: italic; }
.code-block .tok-kw  { color: var(--brand-400); font-weight: 600; }

/* ----- images & figures ----- */

/* ----- images & figures ----- */

.article-content figure,
.article-content .wp-block-image {
	margin: 42px 0;
	max-width: 100% !important; /* جلوگیری از بزرگ شدن کادر نگهدارنده توسط وردپرس */
	box-sizing: border-box;
}

.article-content img {
	max-width: 100% !important; /* غلبه قطعی بر ابعاد داخلی عکس‌های وردپرس */
	height: auto !important;
	display: block;
	box-sizing: border-box;
	border-radius: 20px;
	border: 1px solid var(--sp-border);
	box-shadow:
		0 24px 60px rgba(0, 0, 0, 0.45),
		0 0 60px color-mix(in srgb, var(--brand-500) 10%, transparent);
}

.article-content figcaption {
	margin-top: 12px;
	text-align: center;
	font-size: 0.85rem;
	color: var(--sp-text-3);
}

/* جلوگیری از اسکرول افقی کدهای طولانی یا جداول که ممکن است روی فهرست بروند */
.article-content {
	min-width: 0;
	overflow-wrap: break-word;
	word-wrap: break-word;
}
/* ==========================================================================
   Share  (template-parts/single/article-share.php)
   ========================================================================== */

.article-share {
	margin-top: 56px;
	padding: 30px;
	background: var(--sp-card);
	border: 1px solid var(--sp-border);
	border-radius: 22px;
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	justify-content: space-between;
	gap: 20px;
}

.article-share__label {
	display: inline-flex;
	align-items: center;
	gap: 10px;
	font-size: 0.98rem;
	font-weight: 800;
	color: var(--sp-text);
}

.article-share__label svg {
	width: 18px;
	height: 18px;
	color: var(--sp-brand);
}

.article-share__actions {
	display: flex;
	align-items: center;
	gap: 10px;
	flex-wrap: wrap;
}

.article-share__btn {
	width: 42px;
	height: 42px;
	display: grid;
	place-items: center;
	border-radius: 12px;
	border: 1px solid var(--sp-border);
	background: color-mix(in srgb, var(--mist-200) 3%, transparent);
	color: var(--sp-text-2);
	cursor: pointer;
	transition: transform 0.35s var(--sp-ease), background 0.35s var(--sp-ease),
		color 0.35s ease, box-shadow 0.35s var(--sp-ease), border-color 0.35s ease;
}

.article-share__btn svg {
	width: 17px;
	height: 17px;
}

.article-share__btn:hover {
	background: var(--sp-gradient);
	border-color: transparent;
	color: #ffffff;
	transform: translateY(-3px);
	box-shadow: 0 10px 34px -10px var(--sp-glow-strong);
}

.article-share__copy {
	height: 42px;
	padding: 0 18px;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	font-size: 0.85rem;
	font-weight: 700;
	color: #ffffff;
	background: var(--sp-gradient);
	border-radius: 13px;
	cursor: pointer;
	transition: transform 0.35s var(--sp-ease), box-shadow 0.35s var(--sp-ease);
	box-shadow: 0 10px 34px -10px var(--sp-glow-strong),
		inset 0 1px 0 rgb(255 255 255 / 0.22);
}

.article-share__copy:hover {
	transform: translateY(-3px);
	box-shadow: 0 18px 46px -12px color-mix(in srgb, var(--neon-500) 55%, transparent),
		inset 0 1px 0 rgb(255 255 255 / 0.28);
}

.article-share__copy svg {
	width: 15px;
	height: 15px;
}

/* ==========================================================================
   Related articles  (template-parts/single/related-posts.php)
   ========================================================================== */

.single-related {
	margin-top: 88px;
}

.single-related__head {
	display: flex;
	align-items: flex-end;
	justify-content: space-between;
	gap: 20px;
	margin-bottom: 34px;
}

.single-related__title {
	position: relative;
	margin: 0;
	padding-bottom: 14px;
	font-size: clamp(1.3rem, 2.4vw, 1.6rem);
	font-weight: 850;
	color: var(--sp-text);
}

.single-related__title::after {
	content: "";
	position: absolute;
	bottom: 0;
	inset-inline-start: 0;
	width: 64px;
	height: 3px;
	border-radius: 4px;
	background: var(--sp-gradient);
	box-shadow: 0 0 12px var(--sp-glow);
}

.single-related__more {
	display: inline-flex;
	align-items: center;
	gap: 7px;
	font-size: 0.88rem;
	font-weight: 600;
	color: var(--sp-text-2);
	transition: color 0.3s ease;
	white-space: nowrap;
}

.single-related__more svg {
	width: 16px;
	height: 16px;
	transition: transform 0.3s var(--sp-ease);
}

.single-related__more:hover {
	color: var(--sp-neon-soft);
}

.single-related__more:hover svg {
	transform: translateX(-4px);
}

.single-related__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 20px;
}

/* ----- related card — same language as .plain-card in theme.css ----- */

.related-card {
	position: relative;
	display: flex;
	flex-direction: column;
	background: var(--sp-card);
	border: 1px solid var(--sp-border);
	border-radius: 22px;
	overflow: hidden;
	transition: transform 0.5s var(--sp-ease), border-color 0.4s ease, box-shadow 0.5s var(--sp-ease);
}

.related-card:hover {
	transform: translateY(-4px);
	border-color: color-mix(in srgb, var(--neon-400) 34%, transparent);
	box-shadow: 0 24px 60px rgba(0, 0, 0, 0.45),
		0 0 44px color-mix(in srgb, var(--brand-500) 16%, transparent);
}

.related-card__thumb {
	position: relative;
	display: block;
	aspect-ratio: 16 / 10;
	overflow: hidden;
}

.related-card__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.7s var(--sp-ease);
}

.related-card:hover .related-card__thumb img {
	transform: scale(1.07);
}

.related-card__thumb::after {
	content: "";
	position: absolute;
	inset: 0;
	background: linear-gradient(180deg, transparent 55%, color-mix(in srgb, var(--ink-800) 85%, transparent) 100%);
}

.related-card__cat {
	position: absolute;
	top: 14px;
	inset-inline-start: 14px;
	z-index: 1;
	font-size: 0.7rem;
	font-weight: 700;
	color: #ffffff;
	padding: 5px 13px;
	border-radius: 999px;
	background: color-mix(in srgb, var(--ink-950) 65%, transparent);
	border: 1px solid color-mix(in srgb, var(--brand-400) 50%, transparent);
	backdrop-filter: blur(8px);
}

.related-card__body {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 22px;
	flex: 1;
}

.related-card__title {
	margin: 0;
	font-size: 1.05rem;
	font-weight: 800;
	line-height: 1.8;
	color: var(--sp-text);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	transition: color 0.3s ease;
}

.related-card:hover .related-card__title {
	color: var(--sp-neon-soft);
}

.related-card__excerpt {
	margin: 0;
	font-size: 0.86rem;
	line-height: 1.9;
	color: var(--sp-text-3);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.related-card__meta {
	display: flex;
	align-items: center;
	gap: 16px;
	margin-top: auto;
	padding-top: 14px;
	border-top: 1px solid var(--sp-border);
	font-size: 0.76rem;
	color: var(--sp-text-3);
}

.related-card__meta span {
	display: inline-flex;
	align-items: center;
	gap: 6px;
}

.related-card__meta svg {
	width: 14px;
	height: 14px;
	color: var(--sp-brand);
}

/* ==========================================================================
   Previous / Next navigation  (template-parts/single/article-navigation.php)
   ========================================================================== */

.single-post-nav {
	display: grid;
	grid-template-columns: repeat(2, minmax(0, 1fr));
	gap: 22px;
	margin-top: 88px;
}

.single-post-nav__link {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 10px;
	padding: 26px 28px;
	background: var(--sp-card);
	border: 1px solid var(--sp-border);
	border-radius: 20px;
	overflow: hidden;
	transition: transform 0.45s var(--sp-ease), border-color 0.4s ease, box-shadow 0.45s var(--sp-ease);
}

.single-post-nav__link::before {
	content: "";
	position: absolute;
	inset: 0;
	background: radial-gradient(420px 160px at 85% 0%, color-mix(in srgb, var(--brand-500) 16%, transparent), transparent 70%);
	opacity: 0;
	transition: opacity 0.45s ease;
}

.single-post-nav__link:hover {
	transform: translateY(-4px);
	border-color: color-mix(in srgb, var(--neon-400) 34%, transparent);
	box-shadow: 0 18px 48px rgba(0, 0, 0, 0.4),
		0 0 36px color-mix(in srgb, var(--brand-500) 14%, transparent);
}

.single-post-nav__link:hover::before {
	opacity: 1;
}

.single-post-nav__dir {
	position: relative;
	display: inline-flex;
	align-items: center;
	gap: 7px;
	font-size: 0.78rem;
	font-weight: 700;
	letter-spacing: 0.02em;
	color: var(--sp-brand-soft);
}

.single-post-nav__dir svg {
	width: 15px;
	height: 15px;
	transition: transform 0.35s var(--sp-ease);
}

.single-post-nav__link--prev:hover .single-post-nav__dir svg {
	transform: translateX(4px);
}

.single-post-nav__link--next:hover .single-post-nav__dir svg {
	transform: translateX(-4px);
}

.single-post-nav__title {
	position: relative;
	margin: 0;
	font-size: 1rem;
	font-weight: 800;
	line-height: 1.8;
	color: var(--sp-text);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.single-post-nav__link--next {
	text-align: left;
	align-items: flex-end;
}

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 1060px) {
	.single-post-layout {
		grid-template-columns: minmax(0, 1fr);
		gap: 0;
		margin-top: 54px;
	}

	.article-toc {
		display: none;
	}

	.article-toc-accordion {
		display: block;
	}

	.single-related__grid {
		grid-template-columns: repeat(2, minmax(0, 1fr));
	}

	.related-card:last-child {
		grid-column: 1 / -1;
	}
}

@media (max-width: 768px) {
	.page-single-post {
		padding-bottom: 64px;
	}

	.single-post-intro {
		padding: 104px 6vw 36px;
	}

	.article-meta {
		gap: 12px 20px;
		padding: 18px 20px;
		background: var(--sp-card);
		border: 1px solid var(--sp-border);
		border-radius: 16px;
		justify-content: center;
	}

	.article-meta__sep {
		display: none;
	}

	.single-post-hero__frame {
		border-radius: 18px;
	}

	.single-post-hero__frame img {
		aspect-ratio: 16 / 10;
	}

	.article-content p {
		font-size: 0.98rem;
	}

	.single-related__grid {
		grid-template-columns: minmax(0, 1fr);
	}

	.single-post-nav {
		grid-template-columns: minmax(0, 1fr);
		margin-top: 64px;
	}

	.single-post-nav__link--next {
		text-align: right;
		align-items: flex-start;
	}

	.article-share {
		flex-direction: column;
		align-items: flex-start;
		padding: 24px;
	}

	.single-related {
		margin-top: 64px;
	}
}

@media (max-width: 480px) {
	.article-content h2 {
		margin: 44px 0 18px;
	}

	.article-content blockquote {
		padding: 24px 22px;
	}

	.article-content blockquote p {
		font-size: 1.02rem;
	}

	.code-block pre {
		font-size: 0.78rem;
		padding: 18px;
	}

	.single-related__head {
		flex-direction: column;
		align-items: flex-start;
		gap: 12px;
	}

	.article-meta__who {
		max-width: 150px;
	}
}

@media (max-width: 340px) {
	.single-post-intro__title {
		font-size: 1.55rem;
	}

	.article-share__btn {
		width: 38px;
		height: 38px;
	}

	.article-meta {
		gap: 10px 16px;
	}
}
