/* ==========================================================================
 * SARANSH DAINIK — LISTING PAGES (category / tag / search / reading list)
 * Scoped public design system for the listing family only (loaded via
 * $listing_page flag in _header.php). Matches the homepage (home-v2.css) and
 * article (article-detail.css) visual identity.
 *
 * Palette: navy #07152f · red #c8102e · gold #f5b301 · teal #0494b1
 *          text #16191f · meta #6b7076 / #9aa0a8 · surface #eef0f3
 * ========================================================================== */

/* ---------- Page header / breadcrumb ---------- */
#main .page-breadcrumb { margin-top: 16px; }
#main .page-breadcrumb .breadcrumb {
	background: transparent; padding: 0; margin: 0; border-radius: 0;
	font-size: 13px; color: #6b7076;
}
#main .page-breadcrumb .breadcrumb .breadcrumb-item a { color: #0494b1; }
#main .page-breadcrumb .breadcrumb .breadcrumb-item.active { color: #9aa0a8; }
#main .content .page-title {
	font-size: 23px; font-weight: 700; line-height: 1.3; color: #07152f;
	margin: 18px 0 20px; padding-left: 12px; border-left: 4px solid #c8102e;
}

/* ---------- Card grid: equal-height flex rows ---------- */
#main .posts-boxed > .row { display: flex; flex-wrap: wrap; }
#main .posts-boxed > .row > .item-boxed-cnt {
	float: none; display: flex; padding-left: 10px; padding-right: 10px; margin-bottom: 20px;
}

/* ---------- Card ---------- */
#main .posts-boxed .post-item-boxed {
	width: 100%;
	display: flex;
	flex-direction: column;
	background: #ffffff;
	border: 1px solid #e6edf3;
	border-radius: 6px;
	overflow: hidden;
	box-shadow: 0 1px 4px rgba(7, 21, 47, .05);
	transition: transform .15s ease, box-shadow .15s ease;
}
#main .posts-boxed .post-item-boxed:hover {
	box-shadow: 0 8px 20px rgba(7, 21, 47, .12);
	transform: translateY(-2px);
}

/* Media frame: consistent 5:3 ratio, editorial cover (photos, not brand marks) */
#main .posts-boxed .post-item-boxed .item-image {
	position: relative;
	width: 100%;
	height: auto;
	aspect-ratio: 5 / 3;
	overflow: hidden;
	background: #eef0f3;
	display: block;
}
#main .posts-boxed .post-item-boxed .item-image img:not(.post-icon),
#main .posts-boxed .post-item-boxed .item-image .img-responsive,
#main .posts-boxed .post-item-boxed .item-image .external-image-container {
	position: absolute; inset: 0; width: 100%; height: 100%;
}
#main .posts-boxed .post-item-boxed .item-image img {
	object-fit: cover;
}
#main .posts-boxed .post-item-boxed .item-image .post-icon { z-index: 5; }

/* Category label — brand red */
#main .posts-boxed .label-post-category {
	background: #c8102e; color: #ffffff; font-size: 11px; font-weight: 600;
	height: auto; line-height: 1; padding: 5px 10px; border-radius: 2px;
	left: 10px; top: 10px; z-index: 10; white-space: nowrap;
}

/* Card body */
#main .posts-boxed .post-item-boxed .item-content {
	display: flex; flex-direction: column; flex: 1;
	padding: 14px 16px 16px;
}
#main .posts-boxed .post-item-boxed .title {
	font-size: 18px; font-weight: 700; line-height: 1.35; margin: 0 0 7px;
}
#main .posts-boxed .post-item-boxed .title a {
	color: #16191f; text-decoration: none;
	display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
#main .posts-boxed .post-item-boxed .title a:hover { color: #c8102e; }

#main .posts-boxed .post-item-boxed .post-meta { margin-bottom: 2px; }
#main .posts-boxed .post-item-boxed .post-meta .post-meta-inner span,
#main .posts-boxed .post-item-boxed .post-meta .post-meta-inner a {
	font-size: 12px; color: #9aa0a8; margin-right: 12px;
}
#main .posts-boxed .post-item-boxed .summary {
	font-size: 13.5px; line-height: 1.55; color: #6b7076; margin: 7px 0 12px;
	display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden;
}
#main .posts-boxed .post-item-boxed .post-buttons { margin-top: auto; padding-top: 4px; }
#main .posts-boxed .post-item-boxed .post-buttons .read-more {
	color: #c8102e; font-weight: 600; font-size: 13px; float: none; display: inline-block;
}
#main .posts-boxed .post-item-boxed .post-buttons .read-more:hover { color: #07152f; }

/* ---------- Standard (non-boxed) layout fallback ---------- */
#main .content .post-item .post-image { height: auto; aspect-ratio: 16 / 9; overflow: hidden; }
#main .content .post-item .post-image img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Pagination ---------- */
#main .content .pagination { margin: 24px 0 8px; display: flex; flex-wrap: wrap; }
#main .content .pagination > li > a,
#main .content .pagination > li > span {
	color: #3c4450; border: 1px solid #e3e7ec; margin: 0 3px;
	border-radius: 4px !important; font-size: 14px; font-weight: 500;
}
#main .content .pagination > li.active > a,
#main .content .pagination > li.active > span,
#main .content .pagination > li.active > a:hover,
#main .content .pagination > li.active > span:hover {
	background: #c8102e; border-color: #c8102e; color: #ffffff;
}
#main .content .pagination > li > a:hover,
#main .content .pagination > li > span:hover { background: #f2f4f7; color: #07152f; }

/* ---------- Full-width discovery (categories + tags) ---------- */
.sd-listing-more {
	margin-top: 30px; padding-top: 26px; border-top: 1px solid #e6edf3;
	display: grid; gap: 20px;
}
.sd-more-block {
	background: #ffffff; border: 1px solid #e6edf3; border-radius: 8px;
	padding: 18px 20px;
}
.sd-more-title {
	font-size: 15px; font-weight: 700; color: #07152f; margin: 0 0 12px;
	padding-left: 10px; border-left: 3px solid #c8102e;
}
.sd-more-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.sd-more-chip {
	display: inline-block; padding: 7px 15px; background: #eef0f3; color: #3c4450;
	border-radius: 20px; font-size: 13px; font-weight: 500; text-decoration: none;
	transition: background .15s ease, color .15s ease;
}
.sd-more-chip:hover { background: #c8102e; color: #ffffff; }
.sd-more-chip-tag { background: #f2f4f7; }

/* ---------- Empty state ---------- */
.sd-empty {
	text-align: center; padding: 48px 20px; background: #ffffff;
	border: 1px solid #e6edf3; border-radius: 8px; margin: 8px 0;
}
.sd-empty-title { font-size: 18px; font-weight: 700; color: #07152f; margin: 0 0 18px; }
.sd-empty-btn {
	display: inline-block; padding: 11px 24px; background: #c8102e; color: #ffffff;
	border-radius: 4px; font-size: 14px; font-weight: 600; text-decoration: none;
}
.sd-empty-btn:hover { background: #07152f; color: #ffffff; }

/* ---------- Compact sidebar spacing ---------- */
#main .sd-listing-sidebar .sidebar-widget { margin-bottom: 22px; }

/* Our Picks — compact horizontal rows in the listing sidebar (was 5 large
   full-width images ≈ 950px; now small thumbs + clamped titles ≈ 400px).
   Scoped to the listing sidebar only; article/homepage sidebars unchanged. */
#main .sd-listing-sidebar .w-our-picks-list li {
	display: flex; gap: 12px; margin-bottom: 14px; align-items: flex-start;
}
#main .sd-listing-sidebar .w-our-picks-list li .post-image {
	flex: 0 0 96px; width: 96px; height: 68px; overflow: hidden; position: relative;
	border-radius: 4px; background: #eef0f3; display: block;
}
#main .sd-listing-sidebar .w-our-picks-list li .post-image img {
	width: 100%; height: 100%; object-fit: cover; position: absolute; inset: 0;
}
#main .sd-listing-sidebar .w-our-picks-list li .post-image .label-post-category { display: none; }
#main .sd-listing-sidebar .w-our-picks-list li .title {
	font-size: 13.5px; font-weight: 600; line-height: 1.4; margin: 0; flex: 1; min-width: 0;
}
#main .sd-listing-sidebar .w-our-picks-list li .title a {
	color: #16191f; text-decoration: none;
	display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
#main .sd-listing-sidebar .w-our-picks-list li .title a:hover { color: #c8102e; }
#main .sd-listing-sidebar .w-our-picks-list li .post-meta { display: none; }

/* ---------- Mobile ---------- */
@media (max-width: 767px) {
	#main .posts-boxed > .row > .item-boxed-cnt { padding-left: 4px; padding-right: 4px; margin-bottom: 16px; }
	#main .posts-boxed .post-item-boxed .item-content { padding: 12px 14px 14px; }
	#main .posts-boxed .post-item-boxed .title { font-size: 18px; }
	#main .posts-boxed .post-item-boxed .summary { font-size: 13px; }
	#main .content .page-title { font-size: 20px; margin: 14px 0 16px; }
	.sd-listing-more { margin-top: 22px; padding-top: 18px; gap: 14px; }
	.sd-more-block { padding: 14px 14px; }
	.sd-empty { padding: 36px 16px; }
}
