/* Блог: hero-пост, рубрики, теги, сетка статей */
body.blog, body.category, body.tag { background: var(--c-warm-50); }

.b-hero {
	position: relative; height: 601px;
	display: flex; align-items: flex-end; justify-content: flex-start;
	padding: 10px 20px;
}
.b-hero__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.b-hero__card {
	position: relative; width: 500px;
	display: flex; flex-direction: column; gap: 30px;
	padding: 16px; border-radius: 4px; background: var(--c-white);
}
.b-hero__top { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.b-hero__date { display: flex; align-items: center; gap: 8px; font-weight: 500; font-size: 14px; letter-spacing: -.01em; }
.b-hero__date .eyebrow__dot { background: var(--c-accent); }
.b-hero__titles { display: flex; flex-direction: column; gap: 16px; }
.b-hero__titles a:hover { color: var(--c-accent); }
.b-hero__bottom { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.b-hero__chips { display: flex; gap: 6px; flex-wrap: wrap; }

.blog-page { padding-bottom: 60px; display: flex; flex-direction: column; gap: 40px; }
.blog__head { display: flex; flex-direction: column; gap: 20px; }

.b-filters { display: flex; flex-direction: column; gap: 20px; }
.b-filters__bar { display: flex; align-items: center; justify-content: space-between; gap: 20px; }
.b-filters__toggle { display: none; }
.b-filters__left { display: flex; align-items: center; gap: 20px; }
.b-tabs { display: flex; align-items: center; gap: 12px; padding: 4px; border-radius: 4px; background: var(--c-white); }
.b-tabs__i { padding: 12px; border-radius: 2px; font-size: 14px; line-height: 1.4; letter-spacing: -.02em; white-space: nowrap; }
.b-tabs__i:hover { color: var(--c-accent); }
.b-tabs__i.is-active { background: var(--c-black); color: var(--c-white); }
.b-filters__count { font-size: 14px; line-height: 1.4; color: rgba(18, 40, 73, .5); white-space: nowrap; }
.b-filters__right { display: flex; align-items: center; gap: 20px; }
.b-search { display: flex; align-items: center; gap: 8px; padding: 12px; color: var(--c-charcoal-500); }
.b-search svg { width: 12px; height: 12px; flex: none; }
.b-search input {
	width: 165px; border: 0; background: none; outline: 0; padding: 0;
	font-size: 14px; line-height: 1.4; letter-spacing: -.02em; font-weight: 300;
	border-bottom: 1px solid transparent; transition: border-color var(--t) var(--ease), width var(--t) var(--ease);
}
.b-search input:focus { border-bottom-color: var(--c-line); width: 200px; }
.b-search input::placeholder { color: var(--c-charcoal-500); }

.b-tags { display: flex; flex-wrap: wrap; gap: 12px; }
.b-tag { position: relative; cursor: pointer; }
.b-tag input { position: absolute; opacity: 0; pointer-events: none; }
.b-tag span, .b-tag--clear {
	display: inline-flex; align-items: center; padding: 8px 12px;
	border: 1px solid var(--c-line); border-radius: 2px;
	font-size: 14px; line-height: 1.4; letter-spacing: -.02em;
	transition: background var(--t) var(--ease), color var(--t) var(--ease);
}
.b-tag:hover span { border-color: var(--c-charcoal-500); }
.b-tag input:checked + span { background: var(--c-black); color: var(--c-white); }
.b-tag input:focus-visible + span { outline: 1px solid var(--c-accent); outline-offset: 2px; }
.b-tag--clear { border-color: var(--c-accent); color: var(--c-accent); }
.b-tag--clear:hover { background: var(--c-accent); color: var(--c-white); }

.blog__grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); column-gap: 10px; row-gap: 40px; }

.b-card { position: relative; display: flex; flex-direction: column; gap: 24px; padding: 16px; min-width: 0; }
.b-card__media { position: relative; display: block; height: 300px; overflow: hidden; background: var(--c-gray-300); }
.b-card__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; transition: transform .6s var(--ease); }
.b-card:hover .b-card__img { transform: scale(1.03); }
.b-card__chips { position: absolute; left: 12px; top: 12px; display: flex; gap: 4px; }
.b-card__body { display: flex; flex-direction: column; gap: 12px; }
.b-card__meta { display: flex; align-items: center; gap: 16px; font-size: 12px; line-height: 1.2; letter-spacing: -.01em; font-weight: 400; }
.b-card__dot { width: 4px; height: 4px; border-radius: 50%; background: rgba(18, 40, 73, .5); }
.b-card__title { font-family: var(--f-head); font-weight: 500; font-size: 24px; line-height: 1.2; letter-spacing: -.03em; text-transform: uppercase; }
.b-card__title:hover { color: var(--c-accent); }

@media (max-width: 1023px) {
	.b-hero { height: auto; flex-direction: column; align-items: stretch; padding: 0; }
	.b-hero__img { position: static; height: 280px; }
	.b-hero__card { width: auto; border-radius: 0; padding: 16px 20px 20px; gap: 24px; }

	.blog-page { gap: 40px; }
	.b-filters__bar { flex-wrap: wrap; }
	.b-filters__toggle { display: flex; pointer-events: auto; order: 1; }
	.b-filters__right { order: 2; }
	.b-filters__right .b-search { display: none; }
	.b-filters__left { order: 3; width: 100%; display: none; flex-direction: column; align-items: stretch; gap: 12px; }
	.b-filters[data-open] .b-filters__left { display: flex; }
	.b-filters[data-open] .b-filters__right .b-search { display: flex; order: 4; width: 100%; }
	.b-filters[data-open] .b-filters__right { width: 100%; flex-direction: column; align-items: stretch; order: 4; }
	.b-tabs { flex-wrap: wrap; }
	.b-filters__div, .b-tags { display: none; }
	.b-filters[data-open] .b-tags { display: flex; }

	.blog__grid { grid-template-columns: repeat(2, minmax(0, 1fr)); padding-inline: var(--gutter); }
	.b-card { padding: 0; gap: 16px; }
	.b-card__media { height: 180px; }
	.b-card__chips { left: 8px; top: 8px; }
	.b-card__chips .tag-chip { font-size: 10px; padding: 3px 6px; }
	.b-card__chips .tag-chip + .tag-chip { display: none; }
	.b-card__time, .b-card__dot { display: none; }
	.b-card__title { font-size: 16px; }
}
