/* Latest News Pro — scoped styles, prefixed with .lnp- so it never clashes with theme CSS */

.lnp-wrapper {
	box-sizing: border-box;
	margin: 0 0 24px;
}
.lnp-wrapper * {
	box-sizing: border-box;
}

.lnp-header {
	display: flex;
	align-items: center;
	justify-content: space-between;
	margin-bottom: 14px;
	border-bottom: 2px solid currentColor;
	padding-bottom: 8px;
}
.lnp-title {
	margin: 0;
	font-size: 1.15rem;
	font-weight: 700;
}

/* Tabs */
.lnp-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin-bottom: 14px;
}
.lnp-tab {
	background: transparent;
	border: 1px solid rgba(0,0,0,0.15);
	border-radius: 999px;
	padding: 5px 14px;
	font-size: 0.85rem;
	cursor: pointer;
	transition: background 0.15s ease;
}
.lnp-tab.active,
.lnp-tab:hover {
	background: rgba(0,0,0,0.08);
}

/* Items container */
.lnp-items {
	display: block;
}

/* GRID layout */
.lnp-layout-grid .lnp-items {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 18px;
}
.lnp-layout-grid .lnp-item {
	display: flex;
	flex-direction: column;
	position: relative;
}
.lnp-layout-grid .lnp-thumb,
.lnp-layout-grid .lnp-thumb-placeholder {
	width: 100%;
	aspect-ratio: 16 / 10;
	object-fit: cover;
	border-radius: 6px;
	background: #e5e5e5;
	display: block;
}

/* HERO card — first item in a grid block, spans full width, bigger everything */
.lnp-has-hero .lnp-items {
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
}
.lnp-item.lnp-hero {
	grid-column: 1 / -1;
	flex-direction: row;
	gap: 18px;
}
.lnp-item.lnp-hero .lnp-thumb-link {
	flex: 1.3;
	min-width: 0;
}
.lnp-item.lnp-hero .lnp-thumb,
.lnp-item.lnp-hero .lnp-thumb-placeholder {
	aspect-ratio: 16 / 10;
	border-radius: 8px;
}
.lnp-item.lnp-hero .lnp-content {
	flex: 1;
	justify-content: center;
	margin-top: 0;
}
.lnp-item.lnp-hero .lnp-item-title {
	font-size: 1.4rem;
	line-height: 1.3;
	font-weight: 800;
}
.lnp-item.lnp-hero .lnp-category {
	font-size: 0.78rem;
}
@media (max-width: 640px) {
	.lnp-item.lnp-hero {
		flex-direction: column;
	}
	.lnp-item.lnp-hero .lnp-item-title {
		font-size: 1.15rem;
	}
}

/* LIST layout */
.lnp-layout-list .lnp-item {
	display: flex;
	gap: 12px;
	padding: 10px 0;
	border-bottom: 1px solid rgba(0,0,0,0.08);
	position: relative;
}
.lnp-layout-list .lnp-item:last-child {
	border-bottom: none;
}
.lnp-layout-list .lnp-thumb,
.lnp-layout-list .lnp-thumb-placeholder {
	width: 90px;
	height: 64px;
	object-fit: cover;
	border-radius: 4px;
	flex-shrink: 0;
	background: #e5e5e5;
}

/* Shared item internals */
.lnp-thumb-link {
	position: relative;
	display: block;
	text-decoration: none;
}
.lnp-content {
	display: flex;
	flex-direction: column;
	gap: 4px;
	margin-top: 8px;
	min-width: 0;
}
.lnp-layout-list .lnp-content {
	margin-top: 0;
	justify-content: center;
}
.lnp-category {
	font-size: 0.72rem;
	font-weight: 700;
	text-transform: uppercase;
	letter-spacing: 0.03em;
	opacity: 0.65;
}
.lnp-item-title {
	margin: 0;
	font-size: 0.95rem;
	line-height: 1.35;
}
.lnp-item-title a {
	text-decoration: none;
	color: inherit;
}
.lnp-item-title a:hover {
	text-decoration: underline;
}
.lnp-time {
	font-size: 0.75rem;
	opacity: 0.6;
}

/* Meta row: author + time + read time */
.lnp-meta-row {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 8px;
	font-size: 0.75rem;
	opacity: 0.75;
}
.lnp-meta-row > span:not(:last-child)::after {
	content: "·";
	margin-left: 8px;
	opacity: 0.6;
}
.lnp-author {
	display: inline-flex;
	align-items: center;
	gap: 5px;
}
.lnp-avatar {
	border-radius: 50%;
	width: 18px;
	height: 18px;
	object-fit: cover;
}
.lnp-readtime {
	white-space: nowrap;
}

/* Tags */
.lnp-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin-top: 2px;
}
.lnp-tag {
	font-size: 0.7rem;
	opacity: 0.7;
}

/* Share row */
.lnp-share-row {
	display: flex;
	gap: 8px;
	margin-top: 4px;
}
.lnp-share {
	width: 26px;
	height: 26px;
	border-radius: 50%;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	background: rgba(0,0,0,0.06);
	transition: background 0.15s ease, transform 0.1s ease;
}
.lnp-share:hover {
	background: rgba(0,0,0,0.14);
	transform: translateY(-1px);
}
.lnp-share svg {
	fill: currentColor;
}
.lnp-share-whatsapp { color: #25d366 !important; }
.lnp-share-twitter { color: #1da1f2 !important; }
.lnp-share-facebook { color: #1877f2 !important; }

/* Bookmark button */
.lnp-bookmark-btn {
	position: absolute;
	top: 8px;
	right: 8px;
	width: 30px;
	height: 30px;
	border: none;
	border-radius: 50%;
	background: rgba(0,0,0,0.45);
	color: #fff;
	display: flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
	padding: 0;
	transition: background 0.15s ease, transform 0.1s ease;
}
.lnp-bookmark-btn:hover {
	background: rgba(0,0,0,0.65);
	transform: scale(1.05);
}
.lnp-bookmark-btn svg {
	fill: none;
	stroke: currentColor;
	stroke-width: 2;
}
.lnp-bookmark-btn.lnp-bookmarked svg {
	fill: #ffce00;
	stroke: #ffce00;
}
.lnp-layout-list .lnp-bookmark-btn {
	position: static;
	width: 26px;
	height: 26px;
	background: transparent;
	color: rgba(0,0,0,0.4);
	align-self: flex-start;
	margin-left: auto;
	order: 3;
}
.lnp-layout-list .lnp-bookmark-btn.lnp-bookmarked svg {
	fill: #f5a623;
	stroke: #f5a623;
}

/* Badges (NEW / LIVE / trending / editor's pick) */
.lnp-badges {
	position: absolute;
	top: 8px;
	left: 8px;
	display: flex;
	gap: 5px;
	z-index: 1;
}
.lnp-badge {
	display: inline-flex;
	align-items: center;
	font-size: 0.65rem;
	font-weight: 700;
	letter-spacing: 0.03em;
	padding: 2px 8px;
	border-radius: 3px;
	line-height: 1.6;
	color: #fff;
}
.lnp-badge-new {
	background: #e0263d;
}
.lnp-badge-live {
	background: #d1001f;
	animation: lnp-live-pulse 1.6s infinite;
}
.lnp-badge-trending {
	background: #ff8a00;
	padding: 2px 6px;
}
.lnp-badge-pick {
	background: #1a1a2e;
	color: #ffce00;
	align-self: flex-start;
}
@keyframes lnp-live-pulse {
	0%, 100% { opacity: 1; }
	50% { opacity: 0.55; }
}

/* Video play overlay */
.lnp-video-overlay {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
}
.lnp-video-overlay::after {
	content: "";
	width: 40px;
	height: 40px;
	border-radius: 50%;
	background: rgba(0,0,0,0.55) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='white'%3E%3Cpath d='M8 5v14l11-7z'/%3E%3C/svg%3E") center/16px no-repeat;
}
.lnp-layout-list .lnp-video-overlay::after {
	width: 26px;
	height: 26px;
}
.lnp-layout-list .lnp-video-overlay::after {
	background-size: 12px;
}

/* Load more */
.lnp-load-more-wrap {
	margin-top: 18px;
	text-align: center;
}
.lnp-load-more-btn {
	background: #1a1a2e;
	color: #fff;
	border: none;
	padding: 10px 28px;
	font-size: 0.85rem;
	font-weight: 600;
	border-radius: 4px;
	cursor: pointer;
	transition: opacity 0.15s ease;
}
.lnp-load-more-btn:hover {
	opacity: 0.85;
}

/* Skeleton loader */
.lnp-skeleton-group {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 18px;
	margin-top: 18px;
}
.lnp-skeleton-item {
	display: flex;
	flex-direction: column;
	gap: 8px;
}
.lnp-skeleton-thumb,
.lnp-skeleton-line {
	border-radius: 4px;
	background: linear-gradient(90deg, #e8e8e8 25%, #f2f2f2 37%, #e8e8e8 63%);
	background-size: 400% 100%;
	animation: lnp-shimmer 1.4s ease infinite;
}
.lnp-skeleton-thumb {
	aspect-ratio: 16 / 10;
	width: 100%;
}
.lnp-skeleton-line {
	height: 12px;
	width: 90%;
}
.lnp-skeleton-line.short {
	width: 55%;
}
@keyframes lnp-shimmer {
	0% { background-position: 100% 50%; }
	100% { background-position: 0 50%; }
}

/* TICKER layout */
.lnp-layout-ticker {
	display: flex;
	align-items: center;
	background: #111;
	color: #fff;
	overflow: hidden;
	border-radius: 4px;
	padding: 0;
}
.lnp-layout-ticker::before {
	content: "BREAKING";
	flex-shrink: 0;
	background: #e0263d;
	color: #fff;
	font-size: 0.72rem;
	font-weight: 800;
	letter-spacing: 0.04em;
	padding: 8px 14px;
}
.lnp-layout-ticker .lnp-items {
	flex: 1;
	overflow: hidden;
	position: relative;
	height: 34px;
}
.lnp-layout-ticker .lnp-item {
	position: absolute;
	white-space: nowrap;
	display: flex;
	align-items: center;
	height: 34px;
	animation: lnp-ticker-scroll linear infinite;
	animation-duration: 18s;
}
.lnp-layout-ticker .lnp-item-title {
	font-size: 0.85rem;
	padding: 0 16px;
}
.lnp-layout-ticker .lnp-item-title a {
	color: #fff;
}
@keyframes lnp-ticker-scroll {
	from { transform: translateX(100%); }
	to { transform: translateX(-100%); }
}

.lnp-empty {
	opacity: 0.7;
	font-style: italic;
}

/* Fade-in for AJAX-refreshed items */
.lnp-item.lnp-fresh {
	animation: lnp-fade-in 0.5s ease;
}
@keyframes lnp-fade-in {
	from { opacity: 0; transform: translateY(-4px); }
	to { opacity: 1; transform: translateY(0); }
}

/* Infinite scroll sentinel — invisible trigger element, no visual footprint */
.lnp-infinite-sentinel {
	height: 1px;
	width: 100%;
}

/* Numbered + Prev/Next pagination */
.lnp-pagination {
	display: flex;
	align-items: center;
	justify-content: center;
	flex-wrap: wrap;
	gap: 6px;
	margin-top: 20px;
}
.lnp-page-btn,
.lnp-page-num {
	min-width: 40px;
	min-height: 40px;
	padding: 0 12px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border: 1px solid rgba(0,0,0,0.15);
	background: #fff;
	border-radius: 4px;
	font-size: 0.85rem !important;
	font-weight: 600 !important;
	line-height: 1.4 !important;
	color: #1a1a2e !important;
	text-indent: 0 !important;
	text-transform: none !important;
	overflow: visible !important;
	white-space: nowrap !important;
	opacity: 1 !important;
	visibility: visible !important;
	cursor: pointer;
	transition: background 0.15s ease, opacity 0.15s ease;
}
.lnp-page-btn:hover:not(:disabled),
.lnp-page-num:hover:not(.active) {
	background: rgba(0,0,0,0.06);
}
.lnp-page-btn:disabled {
	opacity: 0.4 !important;
	cursor: default;
}
.lnp-page-num.active {
	background: #1a1a2e;
	color: #fff !important;
	border-color: #1a1a2e;
}
.lnp-page-numbers {
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	justify-content: center;
}
.lnp-page-ellipsis {
	display: inline-flex;
	align-items: center;
	padding: 0 4px;
	opacity: 0.5;
}
.lnp-pagination-prevnext {
	justify-content: space-between;
}

/* Trending / Popular Posts — [lnp_trending] */
.lnp-trending-wrapper {
	margin: 0 0 24px;
}
.lnp-trending-list {
	list-style: none;
	margin: 0;
	padding: 0;
}
.lnp-trending-item {
	display: flex;
	align-items: center;
	gap: 12px;
	padding: 10px 0;
	border-bottom: 1px solid rgba(0,0,0,0.08);
}
.lnp-trending-item:last-child {
	border-bottom: none;
}
.lnp-trending-rank {
	flex-shrink: 0;
	width: 28px;
	font-size: 1.4rem;
	font-weight: 800;
	line-height: 1;
	opacity: 0.25;
	text-align: center;
}
.lnp-trending-numbered .lnp-trending-item:nth-child(-n+3) .lnp-trending-rank {
	opacity: 1;
	color: #e0263d;
}
.lnp-trending-thumb-link {
	flex-shrink: 0;
	display: block;
}
.lnp-trending-thumb,
.lnp-trending-thumb-link .lnp-thumb-placeholder {
	width: 60px;
	height: 60px;
	object-fit: cover;
	border-radius: 4px;
	background: #e5e5e5;
	display: block;
}
.lnp-trending-content {
	min-width: 0;
	flex: 1;
}
.lnp-trending-item-title {
	margin: 0 0 3px;
	font-size: 0.88rem;
	line-height: 1.35;
}
.lnp-trending-item-title a {
	color: inherit;
	text-decoration: none;
}
.lnp-trending-item-title a:hover {
	text-decoration: underline;
}
.lnp-trending-time {
	font-size: 0.72rem;
	opacity: 0.6;
}

/* Multi-category widget */
.lnp-multicat-tabs {
	display: flex;
	flex-wrap: wrap;
	gap: 4px;
	margin-bottom: 12px;
	border-bottom: 1px solid rgba(0,0,0,0.1);
}
.lnp-mc-tab {
	background: none;
	border: none;
	border-bottom: 2px solid transparent;
	padding: 7px 10px;
	font-size: 0.8rem;
	font-weight: 600;
	cursor: pointer;
	opacity: 0.6;
}
.lnp-mc-tab.active {
	opacity: 1;
	border-bottom-color: currentColor;
}
.lnp-mc-panel {
	display: none;
}
.lnp-mc-panel.active {
	display: block;
}
.lnp-mc-panel .lnp-wrapper {
	margin-bottom: 0;
}

/* Responsive */
@media (max-width: 600px) {
	.lnp-layout-grid .lnp-items,
	.lnp-skeleton-group {
		grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
		gap: 12px;
	}
	.lnp-meta-row {
		font-size: 0.7rem;
	}
	.lnp-share {
		width: 24px;
		height: 24px;
	}
	.lnp-page-numbers {
		max-width: 100%;
		overflow-x: auto;
		flex-wrap: nowrap;
		-webkit-overflow-scrolling: touch;
		padding-bottom: 2px;
	}
	.lnp-page-num {
		flex-shrink: 0;
	}
	.lnp-pagination-prevnext {
		justify-content: space-between;
	}
	.lnp-page-btn {
		flex: 1;
		max-width: 48%;
	}
}
