﻿/* =========== © 2026 Centroarts - https://m1r.ru =========== */

:root {
	--post-gap: var(--g-sect);
	--post-foot-gap: 8px;
	--post-section-gap: 16px;
}
@media (min-width: 768px) {
	:root {
		--post-foot-gap: 12px;
		--post-section-gap: 20px;
	}
}
.post + .post { margin-top: var(--post-gap); }

.post-head { margin-bottom: var(--post-section-gap); }
.post-head .title { font-size: var(--fs-title-post); line-height: var(--lh-title-post); white-space: normal; margin-bottom: 0; }

.post-img { display: block; border-radius: var(--rd-box); position: relative; z-index: 1; }
.post-img:not(.cover) img { height: auto; width: 100%; vertical-align: top; border-radius: var(--rd-box); }

.post-img.cover { aspect-ratio: 16/9; border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.post-img.cover img { aspect-ratio: inherit; border-radius: 0; }

.post-img .btn-group { position: absolute; inset: 0; top: auto; padding: 20px; pointer-events: none; }
.post-img .btn-group .btn { pointer-events: all; }
.post-hero .post-img .cover { display: block; border-radius: inherit; }

@media (max-width: 575px) {
	.post-hero .post-img { margin-left: var(--wrp-p-inv); margin-right: var(--wrp-p-inv); }
	.post-hero .post-img .cover { height: 260px; border-radius: 0px; }
	.post-hero .post-img .btn-group { padding: var(--wrp-p); }
	.post-hero .post-img .btn-group .btn { flex: 1; }
}

.post-footer { font-size: var(--fs-1); margin-top: var(--post-section-gap); white-space: nowrap; }
.post-footer-first, .post-footer-second { display: flex; align-items: center; gap: var(--post-foot-gap); }

@media (max-width: 575px) {
	.post-footer-second { margin-top: 8px; }
}
@media (min-width: 576px) {
	.post-footer { display: flex; align-items: center; gap: var(--post-foot-gap); }
	.post-footer-second { flex: 1 1 auto; }
}

.m-date { margin-right: auto; }

.atext .post-slider, .atext .post-img { margin-bottom: var(--atext-gap); }
.post-slider a, .post-img a { opacity: 1 !important; }
.post-slider-line { display: flex; align-items: stretch; margin: 0; padding: 0; border-radius: var(--rd-box); --hscroll-take: 0; }
.post-slider-line img { flex-shrink: 0; height: auto; object-fit: cover; width: 100%; }

@media (max-width: 479px) {
	.atext .post-slider, .atext .post-img {
		margin-left: var(--wrp-p-inv); margin-right: var(--wrp-p-inv);
		border-radius: 0;
	}
	.atext .post-slider img, .atext .post-img img, .atext .post-slider-line { border-radius: 0; }
}

.article-head .link-back *:not(:first-child):not(:last-child) { display: none; }

/* Article Author */
.article-author { font-size: var(--fs); margin: var(--g-sect) 0; }
.article-author .avatar { --avatar-size: 40px; }
.article-author a { display: flex; gap: 8px; opacity: 1 !important; color: inherit !important; line-height: 20px; }
.article-author a .muted { font-size: var(--fs-1); }
.article-author a .cont { flex: 1 1 auto; }
.article-author a .cont * { display: block; }

/* Post Grid */
.post-grid { border-radius: var(--rd-box); min-width: 280px; display: flex; flex-direction: column; }
.post-grid::after {
	content: ""; position: absolute; inset: 0; z-index: 1; border-radius: inherit; pointer-events: none;
	box-shadow: inset 0 0 0 1px var(--c-border);
}
.post-meta { display: flex; align-items: center; gap: 12px; font-size: var(--fs-1); margin-top: 16px; }
.post-grid .cover-overlay::after { box-shadow: none; }
.post-cont { padding: 20px; flex: 1 1 auto; display: flex; flex-direction: column; }
.post-cont .title {
	font-size: var(--fs-title-post-grid); line-height: var(--lh-title-post-grid);
	font-weight: bold; white-space: normal; flex: 1 1 auto;
}
.post-cont .title .text-clamp {
	height: var(--text-clamp-maxh);

	--text-clamp-maxh: calc(var(--lh-title-post-grid) * 3);
	--text-clamp-h: var(--lh-title-post-grid);
	--text-clamp-rows: 3;
}