/**
 * PVGroup Blog Archive (v3.65.0)
 * Ladowany na is_home() / is_category() / is_tag() / is_author() / is_date().
 * Paleta: navy #1B2A4A, orange #F28C00, IBM Plex Sans — spojne ze sklepem.
 *
 * WAZNE — kolejnosc arkuszy na produkcji:
 * astra-child/functions.php wypisuje inline <style id="pvgroup-design"> na
 * wp_head PRIORYTET 999, czyli PO wszystkich wp_enqueue_style (wp_head:8).
 * Tamten blok zawiera m.in.:
 *   a { color:#F28C00 !important }
 *   h1,h2,.entry-title { font-weight:300 !important }
 *   .ast-separate-container .ast-article-post { border-radius:0 !important;
 *                                               box-shadow:none !important }
 * Wnioski, ktore ten plik respektuje:
 *   1. Karty projektujemy PLASKO — obramowanie zamiast cienia. Nie walczymy
 *      !important-ami o box-shadow, bo i tak przegramy (pozniejszy arkusz).
 *   2. Kolor linku i wage naglowka nadpisujemy SPECYFICZNOSCIA (klasa + element),
 *      nie samym !important — (0,2,x) bije (0,0,1).
 *
 * Siatke daje Astra z wp-content/uploads/astra/astra-theme-dynamic-css-home.css:
 *   .ast-row { display:flex; flex-wrap:wrap }
 *   .ast-blog-layout-4-grid .ast-article-post { width:33.33% }
 * Nie przejmujemy jej — tylko dokladamy breakpointy i zdejmujemy padding 3em.
 */

.npv-blog-archive {
	--npv-navy: #1B2A4A;
	--npv-navy-2: #2A3F6A;
	--npv-navy-20: #B0BDD0;
	--npv-navy-40: #6B82A8;
	--npv-orange: #F28C00;
	--npv-orange-dark: #D97B00;
	--npv-text: #525252;
	--npv-muted: #8a92a6;
	--npv-border: #e0e0e0;
	--npv-border-soft: #f0f2f6;
	--npv-tray: #f4f4f4;
}

/* =========================================================
   1. HERO
   ========================================================= */

.npv-blog-hero {
	background: var(--npv-navy, #1B2A4A);
	color: #fff;
	padding: 48px 40px 42px;
}

.npv-blog-hero__crumb {
	font-size: 13px;
	margin-bottom: 16px;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	align-items: center;
	color: var(--npv-navy-40, #6B82A8);
}

.npv-blog-hero__crumb a {
	color: var(--npv-navy-20, #B0BDD0) !important;
	text-decoration: none;
}

.npv-blog-hero__crumb a:hover {
	color: var(--npv-orange, #F28C00) !important;
}

.npv-blog-hero__eyebrow {
	display: flex;
	align-items: center;
	gap: 12px;
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--npv-orange, #F28C00);
	margin: 0 0 16px;
}

.npv-blog-hero__eyebrow::before {
	content: '';
	width: 24px;
	height: 1px;
	background: var(--npv-orange, #F28C00);
	flex: 0 0 auto;
}

/* Specyficznosc (0,2,0) bije h1{font-weight:300!important} z child theme
   tylko przy rownym !important — stad !important tutaj. */
.npv-blog-archive .npv-blog-hero__title {
	color: #fff !important;
	font-size: clamp(28px, 4vw, 44px) !important;
	font-weight: 300 !important;
	line-height: 1.14 !important;
	letter-spacing: -0.5px;
	margin: 0 !important;
	max-width: 20ch;
}

.npv-blog-archive .npv-blog-hero__title strong {
	font-weight: 600 !important;
	color: var(--npv-orange, #F28C00) !important;
}

.npv-blog-hero__lead {
	margin-top: 18px;
	max-width: 64ch;
	color: var(--npv-navy-20, #B0BDD0);
	font-size: 16px;
	line-height: 1.65;
}

.npv-blog-hero__lead p {
	margin: 0;
}

.npv-blog-hero__lead p + p {
	margin-top: 10px;
}

.npv-blog-hero__meta {
	margin: 24px 0 0;
	padding-top: 18px;
	border-top: 1px solid var(--npv-navy-2, #2A3F6A);
	font-size: 12px;
	letter-spacing: 0.3px;
	color: var(--npv-navy-40, #6B82A8);
	font-variant-numeric: tabular-nums;
}

/* =========================================================
   2. PASEK KATEGORII
   ========================================================= */

.npv-cat-nav {
	background: #fff;
	border-bottom: 1px solid var(--npv-border, #e0e0e0);
	padding: 0 40px;
	margin-bottom: 32px;
}

/* Mobile: przewijanie poziome przez flex + overflow-x.
   SWIADOMIE NIE display:block + white-space:nowrap — to anti-pattern
   wywolujacy overflow calej strony na iOS Safari (patrz .pvg-legal-content). */
.npv-cat-nav__list {
	display: flex;
	gap: 4px;
	margin: 0;
	padding: 0;
	list-style: none;
	flex-wrap: nowrap;
	overflow-x: auto;
	scroll-snap-type: x proximity;
	-webkit-overflow-scrolling: touch;
	scrollbar-width: none;
}

.npv-cat-nav__list::-webkit-scrollbar {
	display: none;
}

.npv-cat-nav__item {
	flex: 0 0 auto;
	scroll-snap-align: start;
	display: inline-flex;
	align-items: center;
	gap: 6px;
	padding: 14px 16px;
	color: var(--npv-navy, #1B2A4A) !important;
	font-size: 14px;
	font-weight: 500;
	line-height: 1.2;
	white-space: nowrap;
	text-decoration: none !important;
	border-bottom: 3px solid transparent;
	transition: color 0.15s ease, border-color 0.15s ease;
}

.npv-cat-nav__item:hover {
	color: var(--npv-orange, #F28C00) !important;
}

.npv-cat-nav__item.is-active {
	border-bottom-color: var(--npv-orange, #F28C00);
	color: var(--npv-orange, #F28C00) !important;
}

/* Kategoria bez wpisow — <span>, nie <a>. Zero sciezki crawlowania
   do thin contentu, zero martwego linku dla usera. */
.npv-cat-nav__item.is-empty {
	color: #c6c6c6 !important;
	cursor: default;
}

.npv-cat-nav__count {
	font-size: 12px;
	font-weight: 400;
	color: var(--npv-muted, #8a92a6);
	font-variant-numeric: tabular-nums;
}

.npv-cat-nav__item.is-active .npv-cat-nav__count {
	color: var(--npv-orange, #F28C00);
}

@media (min-width: 1024px) {
	.npv-cat-nav__list {
		flex-wrap: wrap;
		overflow: visible;
	}
}

/* =========================================================
   3. SIATKA — neutralizacja Astry + breakpointy
   ========================================================= */

/* Astra: .ast-separate-container .ast-article-post { padding:3em } — 48px
   paddingu wewnatrz kazdej karty potegowalo wrazenie pustki. */
.npv-blog-archive .ast-article-post {
	padding: 0 1em 2em !important;
	background: transparent !important;
	border-bottom: 0;
}

/* Astra daje width:33.33% bez media queries — dokladamy responsywnosc. */
@media (max-width: 1023px) {
	.npv-blog-archive .ast-blog-layout-4-grid .ast-article-post,
	.npv-blog-archive.ast-blog-layout-4-grid .ast-article-post {
		width: 50%;
	}
}

@media (max-width: 639px) {
	.npv-blog-archive .ast-blog-layout-4-grid .ast-article-post,
	.npv-blog-archive.ast-blog-layout-4-grid .ast-article-post {
		width: 100%;
	}
}

/* Pusty <div class="entry-content clear"> renderowany przez Astre w kazdej
   karcie dawal fantomowy margines pod trescia. */
.npv-blog-archive .ast-article-post .entry-content.clear:empty {
	display: none !important;
}

/* =========================================================
   4. KARTA
   ========================================================= */

.npv-blog-archive .ast-article-inner {
	background: #fff;
	border: 1px solid var(--npv-border, #e0e0e0);
	height: 100%;
	display: flex;
	flex-direction: column;
	overflow: hidden;
	transition: border-color 0.15s ease, transform 0.15s ease;
}

.npv-blog-archive .ast-article-inner:hover {
	border-color: #c6c6c6;
	transform: translateY(-2px);
}

.npv-blog-archive .post-content {
	display: flex;
	flex-direction: column;
	flex: 1 1 auto;
	min-width: 0;
}

/* --- Miniatura ---
   Zrodla to rendery produktowe na bialym tle o roznych proporcjach
   (1024x1024 oraz 864x905), wstawiane w rozmiarze 'large'. Bez kontroli
   proporcji dawaly ~1000px wysokosci na karte — stad "gigantyczne zdjecia".
   object-fit:contain, NIE cover: cover ucina falownik, a obciety produkt
   czyta sie jak blad renderowania. Szara taca #f4f4f4 = ten sam idiom co
   karta produktu w sklepie (shop-v2.css), wiec bialy produkt przestaje
   plywac w pustce. */
.npv-blog-archive .post-thumb-img-content,
.npv-blog-archive .ast-blog-featured-section {
	display: block;
	margin: 0;
	background: var(--npv-tray, #f4f4f4);
	border-bottom: 1px solid var(--npv-border, #e0e0e0);
}

.npv-blog-archive .post-thumb-img-content img,
.npv-blog-archive .ast-blog-featured-section img {
	display: block;
	width: 100%;
	height: auto;
	aspect-ratio: 16 / 10;
	object-fit: contain;
	padding: 18px;
	box-sizing: border-box;
}

.npv-card-thumb--empty {
	aspect-ratio: 16 / 10;
	background: linear-gradient(135deg, var(--npv-navy, #1B2A4A) 0%, var(--npv-navy-2, #2A3F6A) 100%);
	border-bottom: 1px solid var(--npv-border, #e0e0e0);
}

.npv-card-thumb--empty a {
	display: flex;
	width: 100%;
	height: 100%;
	align-items: center;
	justify-content: center;
	text-decoration: none;
}

.npv-card-thumb__label {
	color: var(--npv-orange, #F28C00);
	font-size: 12px;
	font-weight: 600;
	letter-spacing: 1.5px;
	text-transform: uppercase;
}

/* --- Kategoria --- */
.npv-blog-archive .ast-taxonomy-container {
	display: block;
	padding: 18px 20px 0;
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 1px;
	text-transform: uppercase;
	line-height: 1.4;
}

.npv-blog-archive .ast-taxonomy-container a {
	color: var(--npv-orange, #F28C00) !important;
	text-decoration: none !important;
}

/* --- Tytul ---
   (0,2,0) + !important bije h2/.entry-title{font-weight:300!important}
   z inline CSS child theme. Cienki tytul gubil sie w karcie. */
.npv-blog-archive .ast-article-post .entry-title {
	padding: 8px 20px 0;
	margin: 0 !important;
	font-size: 18px !important;
	font-weight: 600 !important;
	line-height: 1.35 !important;
	letter-spacing: -0.1px;
	word-break: break-word;
}

.npv-blog-archive .ast-article-post .entry-title a {
	color: var(--npv-navy, #1B2A4A) !important;
	text-decoration: none !important;
	transition: color 0.15s ease;
}

.npv-blog-archive .ast-article-inner:hover .entry-title a {
	color: var(--npv-orange, #F28C00) !important;
}

/* --- Meta (autor/data) --- */
.npv-blog-archive .ast-article-post .entry-header {
	padding: 0 20px;
	margin: 0;
}

.npv-blog-archive .ast-article-post .entry-meta,
.npv-blog-archive .ast-article-post .entry-meta * {
	font-size: 12px;
	color: var(--npv-muted, #8a92a6) !important;
	line-height: 1.5;
}

/* Autor to bot publikujacy — w karcie zjada linie i nic nie wnosi.
   Na single zostaje (sygnal E-E-A-T). */
.npv-blog-archive .ast-article-post .entry-meta .author,
.npv-blog-archive .ast-article-post .entry-meta .posted-by {
	display: none;
}

/* --- Zajawka --- */
.npv-blog-archive .ast-excerpt-container {
	padding: 10px 20px 0;
	color: var(--npv-text, #525252);
	font-size: 14px;
	line-height: 1.6;
	flex: 1 1 auto;
	word-break: break-word;
}

.npv-blog-archive .ast-excerpt-container p {
	margin-bottom: 0;
}

/* --- Stopka karty --- */
.npv-card-footer {
	margin-top: auto;
	padding: 16px 20px 18px;
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	border-top: 1px solid var(--npv-border-soft, #f0f2f6);
}

.npv-card-time {
	font-size: 12px;
	color: var(--npv-muted, #8a92a6);
	white-space: nowrap;
	font-variant-numeric: tabular-nums;
}

.npv-card-cta {
	font-size: 13px;
	font-weight: 600;
	color: var(--npv-orange, #F28C00) !important;
	text-decoration: none !important;
	white-space: nowrap;
}

.npv-card-cta::after {
	content: '\2192';
	margin-left: 6px;
	display: inline-block;
	transition: transform 0.15s ease;
}

.npv-blog-archive .ast-article-inner:hover .npv-card-cta::after {
	transform: translateX(3px);
}

/* =========================================================
   5. KAFLE WYPELNIAJACE
   Przy 2 wpisach trzecia kolumna swiecila pustka. Zamiast dziury —
   CTA B2B i kafel dokumentacji: rzad jest pelny, a ogon niesie
   realny internal linking.
   ========================================================= */

.npv-blog-card--filler .npv-filler {
	height: 100%;
	display: flex;
	flex-direction: column;
	padding: 28px 24px;
	border: 1px solid var(--npv-border, #e0e0e0);
}

.npv-filler--cta {
	background: var(--npv-navy, #1B2A4A);
	border-color: var(--npv-navy, #1B2A4A) !important;
}

.npv-filler--docs {
	background: var(--npv-tray, #f4f4f4);
}

.npv-filler__label {
	font-size: 11px;
	font-weight: 600;
	letter-spacing: 1.5px;
	text-transform: uppercase;
	color: var(--npv-orange, #F28C00);
	margin: 0 0 12px;
}

.npv-filler__title {
	font-size: 19px;
	font-weight: 500;
	line-height: 1.3;
	margin: 0 0 10px;
	color: var(--npv-navy, #1B2A4A);
}

.npv-filler--cta .npv-filler__title {
	color: #fff;
}

.npv-filler__text {
	font-size: 13px;
	line-height: 1.6;
	margin: 0 0 22px;
	color: var(--npv-text, #525252);
}

.npv-filler--cta .npv-filler__text {
	color: var(--npv-navy-20, #B0BDD0);
}

.npv-filler__btn {
	display: inline-flex;
	align-items: center;
	align-self: flex-start;
	margin-top: auto;
	padding: 11px 22px;
	background: var(--npv-orange, #F28C00) !important;
	color: #fff !important;
	font-size: 14px;
	font-weight: 500;
	text-decoration: none !important;
}

.npv-filler__btn:hover {
	background: var(--npv-orange-dark, #D97B00) !important;
}

.npv-filler__link {
	align-self: flex-start;
	margin-top: auto;
	font-size: 14px;
	font-weight: 600;
	color: var(--npv-navy, #1B2A4A) !important;
	text-decoration: none !important;
	box-shadow: inset 0 -1px 0 rgba(242, 140, 0, 0.45);
}

.npv-filler__link:hover {
	color: var(--npv-orange, #F28C00) !important;
}

/* =========================================================
   6. STAN PUSTY
   Dotyczy zaseedowanych kategorii, ktore nie maja jeszcze wpisow.
   ========================================================= */

.npv-blog-empty {
	width: 100%;
	margin: 8px 1em 0;
	padding: 52px 24px;
	text-align: center;
	background: var(--npv-tray, #f4f4f4);
	border: 1px solid var(--npv-border, #e0e0e0);
}

.npv-blog-empty__title {
	font-size: 20px;
	font-weight: 600;
	color: var(--npv-navy, #1B2A4A);
	margin: 0 0 10px;
}

.npv-blog-empty__text {
	font-size: 15px;
	line-height: 1.65;
	color: var(--npv-text, #525252);
	max-width: 480px;
	margin: 0 auto 26px;
}

.npv-blog-empty__actions {
	display: flex;
	gap: 16px;
	justify-content: center;
	align-items: center;
	flex-wrap: wrap;
	margin: 0;
}

.npv-blog-empty__actions .npv-filler__btn,
.npv-blog-empty__actions .npv-filler__link {
	margin-top: 0;
	align-self: auto;
}

/* =========================================================
   7. PAGINACJA (markup Astry: div.ast-pagination)
   ========================================================= */

.npv-blog-archive .ast-pagination {
	margin-top: 24px;
	padding-top: 28px;
	border-top: 1px solid var(--npv-border, #e0e0e0);
}

.npv-blog-archive .ast-pagination .nav-links {
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	justify-content: center;
}

.npv-blog-archive .ast-pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 10px;
	border: 1px solid var(--npv-border, #e0e0e0);
	background: #fff;
	color: var(--npv-navy, #1B2A4A) !important;
	font-size: 14px;
	font-weight: 500;
	text-decoration: none !important;
	font-variant-numeric: tabular-nums;
	transition: border-color 0.15s ease, background 0.15s ease;
}

.npv-blog-archive .ast-pagination .page-numbers:hover {
	border-color: var(--npv-navy, #1B2A4A);
}

.npv-blog-archive .ast-pagination .page-numbers.current {
	background: var(--npv-navy, #1B2A4A);
	border-color: var(--npv-navy, #1B2A4A);
	color: #fff !important;
}

.npv-blog-archive .ast-pagination .page-numbers.dots {
	border-color: transparent;
}

/* =========================================================
   8. RESPONSYWNOSC
   ========================================================= */

@media (max-width: 921px) {
	.npv-blog-hero {
		padding: 36px 20px 32px;
	}

	.npv-cat-nav {
		padding: 0 20px;
		margin-bottom: 24px;
	}
}

/* Guard iOS Safari — kaskada max-width + word-break zamiast
   display:block + white-space:nowrap (anti-pattern projektu). */
@media (max-width: 640px) {
	.npv-blog-archive,
	.npv-blog-archive .ast-row,
	.npv-blog-archive .ast-article-post,
	.npv-blog-archive .ast-article-inner {
		max-width: 100%;
		box-sizing: border-box;
	}

	.npv-blog-archive .entry-title,
	.npv-blog-archive .ast-excerpt-container {
		word-break: break-word;
		overflow-wrap: anywhere;
	}

	.npv-blog-archive .ast-pagination .page-numbers {
		min-width: 36px;
		height: 36px;
		font-size: 13px;
	}
}
