/**
 * Одиночная запись блога: сетка, обложка, типографика, оглавление, сайдбар.
 */

/* Сетка: контент + сайдбар (одиночная запись и лента блога) */
.blog-single--layout .blog-single__grid,
.blog-archive--layout .blog-archive__grid {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 300px;
	gap: clamp(1.75rem, 4vw, 2.75rem);
	align-items: start;
	max-width: 1180px;
	margin-inline: auto;
	padding-bottom: clamp(2.5rem, 6vw, 4rem);
}

.blog-single__main,
.blog-archive__main {
	min-width: 0;
}

@media (max-width: 960px) {
	.blog-single--layout .blog-single__grid,
	.blog-archive--layout .blog-archive__grid {
		grid-template-columns: 1fr;
	}
}

/* Обложка над заголовком */
.blog-single-hero-thumb {
	margin: 0 0 1.5rem;
	padding: 0;
	border-radius: 20px;
	overflow: hidden;
	box-shadow: 0 18px 48px rgba(61, 68, 73, 0.12);
	border: 1px solid rgba(0, 121, 121, 0.12);
}

.blog-single-hero-thumb__img {
	display: block;
	width: 100%;
	height: auto;
	vertical-align: middle;
}

/* Сайдбар: липкий, с отступом от фиксированной шапки (не залезает под меню) */
.blog-single-sidebar__sticky {
	position: sticky;
	top: calc(var(--header-h, 72px) + 1.75rem);
	display: flex;
	flex-direction: column;
	gap: 1.25rem;
}

.admin-bar .blog-single-sidebar__sticky {
	top: calc(32px + var(--header-h, 72px) + 1.75rem);
}

@media screen and (max-width: 782px) {
	.admin-bar .blog-single-sidebar__sticky {
		top: calc(46px + var(--header-h-mobile, 64px) + 1.75rem);
	}
}

@media (max-width: 960px) {
	.blog-single-sidebar__sticky {
		position: static;
	}
}

.blog-sidebar-card {
	padding: 1.25rem 1.2rem;
	background: #fff;
	border-radius: 16px;
	border: 1px solid rgba(0, 121, 121, 0.12);
	box-shadow: 0 8px 28px rgba(61, 68, 73, 0.06);
}

.blog-sidebar-card--cta {
	background: linear-gradient(145deg, rgba(0, 121, 121, 0.08) 0%, rgba(242, 208, 107, 0.15) 100%);
	border-color: rgba(0, 121, 121, 0.2);
}

.blog-sidebar-card__title {
	margin: 0 0 0.55rem;
	font-size: 1rem;
	font-weight: 800;
	color: #1a2226;
	letter-spacing: -0.02em;
}

.blog-sidebar-card__text {
	margin: 0 0 1rem;
	font-size: 0.88rem;
	line-height: 1.5;
	color: #5c6468;
}

.blog-sidebar-card__btn {
	width: 100%;
	justify-content: center;
}

.blog-sidebar-links {
	list-style: none;
	margin: 0;
	padding: 0;
}

.blog-sidebar-links li + li {
	margin-top: 0.45rem;
}

.blog-sidebar-links__a {
	display: block;
	padding: 0.45rem 0;
	font-size: 0.88rem;
	font-weight: 600;
	color: #007979;
	text-decoration: none;
	border-bottom: 1px solid rgba(0, 121, 121, 0.1);
	transition: color 0.2s ease, padding-left 0.2s ease;
}

.blog-sidebar-links__a:hover {
	color: #005a5a;
	padding-left: 0.25rem;
}

.blog-sidebar-recent {
	list-style: none;
	margin: 0;
	padding: 0;
}

.blog-sidebar-recent__item + .blog-sidebar-recent__item {
	margin-top: 0.65rem;
	padding-top: 0.65rem;
	border-top: 1px solid rgba(61, 68, 73, 0.08);
}

.blog-sidebar-recent__link {
	display: flex;
	gap: 0.65rem;
	align-items: flex-start;
	text-decoration: none;
	color: inherit;
	transition: opacity 0.2s ease;
}

.blog-sidebar-recent__link:hover {
	opacity: 0.85;
}

.blog-sidebar-recent__thumb {
	flex-shrink: 0;
	width: 52px;
	height: 52px;
	border-radius: 10px;
	overflow: hidden;
	background: rgba(0, 121, 121, 0.08);
}

.blog-sidebar-recent__thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.blog-sidebar-recent__body {
	min-width: 0;
}

.blog-sidebar-recent__title {
	display: block;
	font-size: 0.88rem;
	font-weight: 700;
	line-height: 1.35;
	color: #1a2226;
}

.blog-sidebar-recent__time {
	display: block;
	margin-top: 0.2rem;
	font-size: 0.75rem;
	color: #5c6468;
}

/* Тело статьи */
.blog-single-prose {
	font-size: 1.05rem;
	line-height: 1.75;
	color: #1a2226;
}

.blog-single-prose > * + * {
	margin-top: 1.1rem;
}

.blog-single-prose h2 {
	margin-top: 2rem;
	margin-bottom: 0.75rem;
	font-size: clamp(1.35rem, 2.5vw, 1.55rem);
	font-weight: 800;
	letter-spacing: -0.02em;
	color: #007979;
	scroll-margin-top: calc(var(--header-h, 72px) + 1rem);
}

.blog-single-prose h2:first-of-type {
	margin-top: 0.5rem;
}

.blog-single-prose a {
	color: #007979;
	font-weight: 600;
	text-decoration: underline;
	text-underline-offset: 3px;
}

.blog-single-prose a:hover {
	color: #005a5a;
}

.blog-single-prose ul {
	padding-left: 1.25rem;
}

.blog-single-prose .intro-lead {
	font-size: 1.12rem;
	line-height: 1.65;
	color: #3d4449;
}

/* Оглавление */
.post-toc {
	margin: 1.5rem 0 2rem;
	padding: 1.1rem 1.2rem;
	background: linear-gradient(135deg, rgba(0, 121, 121, 0.06) 0%, rgba(242, 208, 107, 0.12) 100%);
	border: 1px solid rgba(0, 121, 121, 0.14);
	border-radius: 14px;
}

.post-toc__title {
	margin: 0 0 0.6rem;
	font-size: 0.78rem;
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	color: #007979;
}

.post-toc__list {
	margin: 0;
	padding-left: 1.2rem;
	font-size: 0.92rem;
	font-weight: 600;
}

.post-toc__list a {
	text-decoration: none;
}

.post-toc__list a:hover {
	text-decoration: underline;
}

.post-checklist li {
	margin-bottom: 0.35rem;
}

.post-pullquote {
	margin: 1.5rem 0;
	padding: 1rem 1.15rem 1rem 1.1rem;
	border-left: 4px solid #f2d06b;
	background: rgba(0, 121, 121, 0.04);
	border-radius: 0 12px 12px 0;
}

.post-pullquote p {
	margin: 0;
	font-size: 1.02rem;
	font-style: italic;
	color: #3d4449;
}

/* Иллюстрации в теле статьи */
.post-figure {
	margin: 1.75rem 0;
	padding: 0;
	border-radius: 18px;
	overflow: hidden;
	border: 1px solid rgba(0, 121, 121, 0.12);
	box-shadow: 0 14px 40px rgba(61, 68, 73, 0.1);
	background: #fff;
}

.post-figure__img {
	display: block;
	width: 100%;
	height: auto;
	vertical-align: middle;
}

.post-figure__caption {
	margin: 0;
	padding: 0.65rem 1rem 0.85rem;
	font-size: 0.88rem;
	line-height: 1.45;
	color: #5c6468;
	text-align: center;
	background: linear-gradient(180deg, rgba(0, 121, 121, 0.03) 0%, transparent 100%);
}

/* Анимация появления основной колонки */
@media (prefers-reduced-motion: no-preference) {
	.blog-single--layout .blog-single__main,
	.blog-archive--layout .blog-archive__main {
		animation: blogSingleMainIn 0.75s cubic-bezier(0.23, 1, 0.32, 1) both;
	}

	.blog-single-sidebar {
		animation: blogSingleMainIn 0.75s 0.08s cubic-bezier(0.23, 1, 0.32, 1) both;
	}
}

@keyframes blogSingleMainIn {
	from {
		opacity: 0;
		transform: translateY(18px);
	}
	to {
		opacity: 1;
		transform: translateY(0);
	}
}

@media (prefers-reduced-motion: reduce) {
	.blog-single--layout .blog-single__main,
	.blog-archive--layout .blog-archive__main,
	.blog-single-sidebar {
		animation: none;
	}
}

/* Старый max-width одиночной — переопределяем для layout */
.blog-single--layout .blog-single__wrap,
.blog-single--layout.blog-single .blog-single__wrap {
	max-width: none;
}

/* Таблица цен в статье */
.post-prices-table-wrap {
	margin: 1.25rem 0;
	overflow-x: auto;
	border-radius: 14px;
	border: 1px solid rgba(0, 121, 121, 0.14);
	box-shadow: 0 8px 24px rgba(61, 68, 73, 0.06);
}

.post-prices-table {
	width: 100%;
	min-width: 320px;
	border-collapse: collapse;
	font-size: 0.95rem;
}

.post-prices-table--wide {
	min-width: 480px;
}

.post-prices-table thead th {
	padding: 0.85rem 1rem;
	text-align: left;
	font-size: 0.78rem;
	font-weight: 800;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	color: #fff;
	background: #007979;
}

.post-prices-table tbody td {
	padding: 0.75rem 1rem;
	border-top: 1px solid rgba(0, 121, 121, 0.1);
}

.post-prices-table tbody tr:nth-child(even) td {
	background: rgba(0, 121, 121, 0.04);
}

.post-prices-table tbody td:last-child {
	font-weight: 700;
	color: #007979;
	white-space: nowrap;
}

/* FAQ в теле статьи */
.post-blog-faq {
	margin: 2rem 0 1.5rem;
	padding: 1.25rem 1.2rem;
	background: rgba(0, 121, 121, 0.04);
	border-radius: 16px;
	border: 1px solid rgba(0, 121, 121, 0.12);
}

.post-blog-faq__list {
	display: flex;
	flex-direction: column;
	gap: 0.65rem;
}

.post-blog-faq__item {
	background: #fff;
	border-radius: 12px;
	border: 1px solid rgba(0, 121, 121, 0.1);
	overflow: hidden;
}

.post-blog-faq__summary {
	padding: 0.9rem 1rem;
	font-weight: 700;
	cursor: pointer;
	list-style: none;
}

.post-blog-faq__summary::-webkit-details-marker {
	display: none;
}

.post-blog-faq__panel {
	padding: 0 1rem 1rem;
	font-size: 0.94rem;
	line-height: 1.65;
	color: #3d4449;
}

.post-blog-faq__panel p {
	margin: 0;
}

/* CTA перед «Полезными ссылками» */
.blog-post-end-cta {
	margin: 2.5rem 0 2rem;
	padding: clamp(1.35rem, 3vw, 1.75rem);
	border-radius: 18px;
	background: linear-gradient(145deg, rgba(0, 121, 121, 0.1) 0%, rgba(242, 208, 107, 0.18) 100%);
	border: 1px solid rgba(0, 121, 121, 0.2);
}

.blog-post-end-cta__title {
	margin: 0 0 0.65rem;
	font-size: clamp(1.2rem, 2.5vw, 1.45rem);
	font-weight: 800;
	color: #1a2226;
}

.blog-post-end-cta__text {
	margin: 0 0 1rem;
	font-size: 0.95rem;
	line-height: 1.6;
	color: #3d4449;
}

.blog-post-end-cta__phone {
	margin: 0 0 1.1rem;
	font-size: 1.05rem;
	font-weight: 700;
}

.blog-post-end-cta__phone a {
	color: #007979;
	text-decoration: none;
}

.blog-post-end-cta__phone a:hover {
	text-decoration: underline;
}

.blog-post-end-cta__messengers {
	display: inline-block;
	margin-left: 0.25rem;
	font-size: 0.88rem;
	font-weight: 500;
	color: #5c6468;
}

.blog-post-end-cta__actions {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
}

.blog-post-end-cta__btn {
	display: inline-flex;
	align-items: center;
	gap: 0.45rem;
}

.blog-post-end-cta__btn--secondary {
	background: transparent;
	border: 2px solid #007979;
	color: #007979;
}
