/* =========================================================
   Net Pay Advance — Blog Listing Template Styles
   Built from Figma spec. Scope: all rules prefixed .npa- to
   avoid clashing with Astra / astra-child theme styles.
   ========================================================= */
.ast-container {
	display: block !important; /* override Astra's default flex layout for the main container */
}

.npa-blog-listing {
	--npa-cerulean: #003366;     /* Blue-Dark-Cerulean, shorthand #036 */
	--npa-primary: #004699;      /* Primary-Color — buttons / accents */
	--npa-secondary-text: #555;  /* Secondary-Text-Color */
	--npa-stroke: #DFE4EA;       /* Stroke */
	--npa-white: #FFFFFF;        /* Neutrals-White */
	--npa-gray: #F9FAFB;         /* Gray-Gray */
	--npa-green: #0A7F53;        /* Green-Kelly-Green */
	--npa-radius: 12px;
	--npa-shadow: 0 4px 16px rgba(0, 0, 0, 0.03);

	color: var(--npa-secondary-text);
	font-family: 'Inter', sans-serif;
}

.npa-blog-listing * {
	box-sizing: border-box;
	font-family: 'Inter', sans-serif;
}

.npa-container {
	max-width: 1200px;
	margin: 0 auto;
	padding: 0 20px;
}

/* ---------- Hero banner (not specced — kept minimal/neutral) ---------- */

.npa-blog-hero {
	padding: 65px 0;
	text-align: center;
	background: linear-gradient(186deg, #DCF3FF 3.68%, #FFF 100.34%);
}

.npa-blog-hero__title {
	color: var(--npa-cerulean);
	font-family: 'Inter', sans-serif;
	font-size: 2.45rem;
	font-weight: 700;
	margin-bottom: 12px !important;
    text-align: center;
    padding: 0 !important;
}

.npa-blog-hero__subtitle {
	color: var(--npa-secondary-text);
	font-size: 1rem;
	max-width: 560px;
	margin: 0 auto;
}

.npa-blog-hero__subtitle p {
	margin: 0;
}

/* ---------- Featured article section ---------- */

.npa-featured {
	padding: 65px 0;
}

.npa-featured__label {
	color: var(--npa-cerulean);
	font-family: 'Inter', sans-serif;
	font-size: 25px;
	font-weight: 700;
	line-height: normal;
	letter-spacing: 1px;
	text-transform: uppercase;
	margin-bottom: 24px;
}

.npa-featured__grid {
	display: grid;
	grid-template-columns: 1.6fr 1fr;
	gap: 40px;
	align-items: start;
}

/* Left column card */

.npa-featured__main {
	position: relative;
	box-shadow: 0 4px 16px 0 rgba(0, 0, 0, 0.03);
    border-radius: 12px;
    border: 1px solid #DFE4EA;
}

.npa-featured__image-link {
	display: block;
	border-radius: 12px;
	overflow: hidden;
}

.npa-featured__image {
	display: block;
	width: 100%;
	height: 340px;
	object-fit: cover;
}

.npa-featured__content {
	display: flex;
	flex-direction: column;
	gap: 16px;
	padding: 24px;
}

.npa-featured__title {
	color: var(--npa-cerulean);
	font-family: 'Inter', sans-serif;
	font-size: 28px;
	font-weight: 700;
	line-height: 36px;
	margin: 0;
}

.npa-featured__title a {
	color: inherit;
	text-decoration: none;
}

/* Whole-card clickable area: stretched link from the title anchor */
.npa-featured__title a::after {
	content: '';
	position: absolute;
	inset: 0;
	z-index: 0;
}

.npa-featured__excerpt {
	color: var(--npa-secondary-text);
	font-family: 'Inter', sans-serif;
	font-size: 15px;
	font-weight: 400;
	line-height: 22px;
	margin: 0 !important;
}

.npa-featured__footer {
	display: flex;
	align-items: center;
	justify-content: space-between;
	border-top: 1px solid var(--npa-stroke);
	padding-top: 16px;
	flex-wrap: wrap;
	gap: 12px;
}

.npa-featured__meta {
	display: flex;
	align-items: center;
	gap: 8px;
}

.npa-featured__meta img {
	border-radius: 50%;
	width: 32px;
	height: 32px;
	object-fit: cover;
}

.npa-featured__meta .npa-author-name {
	color: var(--npa-cerulean);
	font-family: 'Inter', sans-serif;
	font-size: 13px;
	font-weight: 600;
	line-height: normal;
}

.npa-featured__meta .npa-post-date {
	color: var(--npa-secondary-text);
	font-family: 'Inter', sans-serif;
	font-size: 13px;
	font-weight: 400;
	line-height: normal;
}

.npa-featured__cta {
	position: relative;
	z-index: 1; /* sits above the stretched link so it stays independently clickable/hoverable */
	color: var(--npa-green);
	font-family: 'Inter', sans-serif;
	font-size: 14px;
	font-weight: 600;
	line-height: normal;
	text-decoration: none;
	white-space: nowrap;
}

.npa-featured__cta:hover {
	text-decoration: underline;
}

/* Right column: 4 SEPARATE bordered/shadowed cards, spaced with a gap */

.npa-featured__sidebar {
	display: flex;
	flex-direction: column;
	gap: 16px;
}

.npa-sidebar-item {
	position: relative; /* anchor for its own stretched link */
	display: flex;
	gap: 14px;
	border-radius: 12px;
	border: 1px solid var(--npa-stroke);
	background: var(--npa-white);
	box-shadow: var(--npa-shadow);
	padding: 16px;
}

.npa-sidebar-item__image-link {
	flex: 0 0 auto;
	display: block;
	border-radius: 8px;
	overflow: hidden;
	width: 120px;
	height: 100px;
}

.npa-sidebar-item__image {
	display: block;
	width: 120px;
	height: 100px;
	object-fit: cover;
}

.npa-sidebar-item__body {
	display: flex;
	flex-direction: column;
	gap: 8px;
	min-width: 0;
	width: 100%;
}

.npa-sidebar-item__title {
	margin: 0;
	overflow: hidden;
	text-overflow: ellipsis;
	color: var(--npa-cerulean);
	font-size: 18px;
	font-weight: 600;
	line-height: 22px;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
}

.npa-sidebar-item__title a {
	color: inherit;
	text-decoration: none;
}

.npa-sidebar-item__title a::after {
	content: '';
	position: absolute;
	inset: 0;
}

.npa-sidebar-item__date {
	color: var(--npa-secondary-text);
	font-family: 'Inter', sans-serif;
	font-size: 12px;
	font-weight: 400;
	line-height: normal;
}

/* ---------- Shared badge + meta-dot ---------- */

.npa-blog-card__badge {
	display: inline-block;
	border: 1px solid var(--npa-stroke);
	border-radius: 5px;
	background: var(--npa-gray);
	padding: 6px 12px;
	font-family: 'Inter', sans-serif;
	font-size: 12px;
	font-weight: 600;
	color: var(--npa-cerulean);
	width: fit-content;
}

.npa-blog-card__dot {
	color: var(--npa-stroke);
}

/* ---------- Filter bar ---------- */

.npa-filter-bar {
	padding: 0;
	background: #F3F4F6;
	border-bottom: 1px solid #DFE4EA;
}

.npa-filter-bar .npa-container {
	padding: 32px 20px;
}

input#npa-blog-search:focus {
    border: unset;
}

.npa-filter-bar__categories {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 12px 20px;
	margin-bottom: 20px;
}

.npa-filter-bar__label {
	color: var(--npa-cerulean);
	font-family: 'Inter', sans-serif;
	font-weight: 600;
	font-size: 0.85rem;
	letter-spacing: 0.02em;
}

.npa-pill {
	border-radius: 5px;
	border: 1px solid var(--npa-stroke);
	background: var(--npa-gray);
	padding: 8px 24px;
	font-family: 'Inter', sans-serif;
	font-size: 0.88rem;
	font-weight: 600;
	color: var(--npa-cerulean);
	cursor: pointer;
	transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
	flex: 0 0 auto;
	width: auto;
	white-space: nowrap;
}

.npa-pill:hover {
	border-color: var(--npa-primary);
}

.npa-pill.is-active {
	background: var(--npa-primary);
	border-color: var(--npa-primary);
	color: var(--npa-white);
}

.npa-filter-bar__row {
	display: grid;
	grid-template-columns: 1fr 220px;
	gap: 16px;
}

.npa-filter-bar__search {
	display: flex;
	height: 48px;
	align-items: center;
	gap: 10px;
	flex: 1 0 0;
	padding: 12px 16px;
	border: 1px solid var(--npa-stroke);
	border-radius: 8px;
	background: var(--npa-white);
}

.npa-filter-bar__search svg {
	flex: 0 0 auto;
	color: var(--npa-secondary-text);
}

.npa-filter-bar__search input {
	flex: 1;
	border: none;
	outline: none;
	font-family: 'Inter', sans-serif;
	font-size: 0.95rem;
	color: var(--npa-secondary-text);
	background: transparent;
}

.npa-filter-bar__subject {
	display: flex;
	height: 48px;
	flex-direction: column;
	align-items: flex-start;
	gap: 5px;
}

.npa-filter-bar__subject select {
	width: 100%;
	height: 100%;
	padding: 0 36px 0 16px;
	border: 1px solid var(--npa-stroke);
	border-radius: 8px;
	font-family: 'Inter', sans-serif;
	font-size: 0.95rem;
	color: var(--npa-secondary-text);
	background-color: var(--npa-white);
	appearance: none;
	-webkit-appearance: none;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%23555555' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 12px center;
}

.npa-filter-bar__search:focus-within,
.npa-filter-bar__subject select:focus {
	outline: none;
	border-color: var(--npa-primary);
}

/* ---------- Latest articles grid ---------- */
.npa-latest {
	padding: 65px 0;
}
.npa-latest__title {
	color: var(--npa-cerulean);
	font-family: 'Inter', sans-serif;
	font-size: 24px;
	font-weight: 700;
	line-height: normal;
	margin: 0 0 24px;
}

.npa-blog-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 32px;
}

.npa-blog-card {
	position: relative; /* anchor for the full-card stretched link */
	border-radius: 12px;
	border: 1px solid var(--npa-stroke);
	background: var(--npa-white);
	box-shadow: var(--npa-shadow);
	overflow: hidden;
	display: flex;
	flex-direction: column;
}

.npa-blog-card__image-link {
	display: block;
	width: 100%;
	height: 180px;
}

.npa-blog-card__image {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.npa-blog-card__body {
	display: flex;
	flex-direction: column;
	gap: 12px;
	padding: 20px;
	height: 100%;
}

.npa-blog-card__title {
	margin: 0;
	color: var(--npa-cerulean);
	font-size: 18px !important;
	font-weight: 600;
	line-height: 24px;
}

.npa-blog-card__title a {
	color: inherit;
	text-decoration: none;
}

/* Whole-card clickable area: stretched link from the title anchor */
.npa-blog-card__title a::after {
	content: '';
	position: absolute;
	inset: 0;
	z-index: 0;
}

.npa-blog-card__excerpt {
	color: var(--npa-secondary-text);
	font-family: 'Inter', sans-serif;
	font-size: 14px;
	font-weight: 400;
	line-height: 20px;
	margin: 0 !important;
}

.npa-blog-card__meta {
	display: flex;
	align-items: center;
	gap: 8px;
	margin-top: auto;
}

.npa-blog-card__avatar {
	border-radius: 50%;
	width: 26px;
	height: 26px;
	object-fit: cover;
}

.npa-blog-card__author {
	color: var(--npa-cerulean);
	font-family: 'Inter', sans-serif;
	font-size: 13px;
	font-weight: 600;
	line-height: normal;
}

.npa-blog-card__date {
	color: var(--npa-secondary-text);
	font-family: 'Inter', sans-serif;
	font-size: 13px;
	font-weight: 400;
	line-height: normal;
}

.npa-no-results {
	grid-column: 1 / -1;
	text-align: center;
	color: var(--npa-secondary-text);
	padding: 40px 0;
}

/* ---------- Load more ---------- */

.npa-load-more-wrap {
	text-align: center;
	margin: 40px 0 0;
}

.npa-load-more {
	border-radius: 6px;
	border: 1px solid var(--npa-primary);
	background: var(--npa-primary);
	color: var(--npa-white);
	padding: 12px 28px;
	font-family: 'Inter', sans-serif;
	font-size: 0.95rem;
	font-weight: 600;
	cursor: pointer;
	transition: opacity 0.15s ease;
	transition: 0.5s ease;
	margin-bottom: 0 ;
}

.npa-load-more:hover {
	color: #fff;
	transform: scale(1.05);
}

.npa-load-more:disabled {
	opacity: 0.6;
	cursor: default;
}

/* ---------- Meet Our Authors ---------- */

.npa-authors {
	background: var(--npa-gray);
	padding: 65px 0;
}

.npa-authors-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 32px;
}

.npa-author-card {
	text-align: center;
	background: var(--npa-white);
	border: 1px solid var(--npa-stroke);
	border-radius: var(--npa-radius);
	box-shadow: var(--npa-shadow);
	padding: 32px 20px;
}

.npa-author-card__avatar {
	width: 88px;
	height: 88px;
	border-radius: 50%;
	object-fit: cover;
	margin: 0 auto 16px;
	display: block;
}

.npa-author-card__name {
	color: var(--npa-cerulean);
	font-size: 18px;
	font-weight: 700;
	margin: 0 0 4px;
}

.npa-author-card__role {
	color: var(--npa-secondary-text);
	font-size: 14px;
	margin: 0 0 12px;
}

.npa-author-card__link {
	color: var(--npa-green);
	font-size: 14px;
	font-weight: 600;
	text-decoration: none;
}

.npa-author-card__link:hover {
	text-decoration: underline;
}

/* ---------- Trailing page content (Page's own editor content) ---------- */

.npa-page-content {
	padding: 65px 0;
	color: #1F2A37;
	font-size: 16px;
	line-height: 160%;
}

.npa-page-content p {
	margin: 0 0 20px;
}

.npa-page-content p:last-child {
	margin-bottom: 0;
}

.npa-page-content h2 {
	color: var(--npa-cerulean);
	font-size: 22px;
	font-weight: 700;
	margin: 32px 0 16px;
}

/* ---------- Responsive ---------- */
@media (max-width: 480px) {
	.npa-filter-bar__label {
		width: 100%;
		margin-bottom: 4px;
	}
}
@media (max-width: 900px) {
	.npa-featured__grid {
		grid-template-columns: 1fr;
	}

	.npa-blog-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.npa-authors-grid {
		grid-template-columns: repeat(2, 1fr);
	}

	.npa-filter-bar__row {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 600px) {
	.npa-blog-hero {
		padding: 40px 0 0;
	}
	.npa-featured, .npa-latest, .npa-authors {
		padding: 40px 0;
	}
	.npa-blog-hero__title {
		font-size: 28px !important;
	}

	.npa-featured__title {
		font-size: 22px;
	}

	.npa-sidebar-item__title {
		font-size: 16px;
	}

	.npa-featured__label, .npa-latest__title {
		font-size: 20px;
	}

	.npa-featured__title, .npa-sidebar-item__title, .npa-featured__label, .npa-latest__title {
		line-height: normal;
	}

	.npa-blog-grid {
		grid-template-columns: 1fr;
	}

	.npa-blog-card__excerpt, .npa-blog-card__avatar {
		display: none; /* hide excerpt on small screens to save space */
	}

	.npa-authors-grid {
		grid-template-columns: 1fr;
	}

	.npa-featured__image {
		height: 220px;
	}

	.npa-featured__content {
		padding: 20px;
	}
	.npa-pill {
		font-size: 12px;
		padding: 8px 12px;
	}
}
