/**
 * N3TW News Magazine Layout
 * Dedicated styling for /news/ archive matching Dark Fantasy theme
 *
 * @package N3TW
 */

.n3tw-news-magazine {
	background: transparent;
	color: var(--n3tw-text-primary, #f1f5f9);
	padding: 40px 0 60px;
	min-height: 80vh;
}

.n3tw-news-container {
	max-width: 1280px;
	margin: 0 auto;
	padding: 0 20px;
}

/* -------------------------------------------------------------------------
   Top Section: Hero + Sidebar (2 Columns)
   ------------------------------------------------------------------------- */
.n3tw-news-hero-section {
	display: grid;
	grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
	gap: 24px;
	align-items: stretch;
	margin-bottom: 40px;
}

/* Left: Siste Hovedsak (Hero Card) */
.n3tw-news-hero-card {
	background: var(--n3tw-card-bg, #141E2E);
	border: 1px solid var(--n3tw-border, rgba(148, 163, 184, 0.15));
	border-radius: 16px;
	overflow: hidden;
	box-shadow: 0 4px 20px rgba(0, 0, 0, 0.35);
	display: flex;
	flex-direction: column;
	transition: box-shadow 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.n3tw-news-hero-card:hover {
	border-color: rgba(249, 115, 22, 0.4);
	box-shadow: 0 8px 30px rgba(0, 0, 0, 0.5);
}

.n3tw-news-hero-media {
	position: relative;
	width: 100%;
	aspect-ratio: 16 / 9;
	background: #080D16;
	overflow: hidden;
}

.n3tw-news-hero-img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1);
}

.n3tw-news-hero-card:hover .n3tw-news-hero-img {
	transform: scale(1.02);
}

.n3tw-news-hero-badge {
	position: absolute;
	top: 16px;
	left: 16px;
	background: #ea580c;
	color: #ffffff;
	font-size: 0.72rem;
	font-weight: 800;
	letter-spacing: 0.06em;
	text-transform: uppercase;
	padding: 6px 14px;
	border-radius: 9999px;
	box-shadow: 0 2px 10px rgba(234, 88, 12, 0.5);
	z-index: 2;
}

.n3tw-news-hero-body {
	padding: 24px 28px 28px;
	display: flex;
	flex-direction: column;
	flex-grow: 1;
}

.n3tw-news-meta-row {
	display: flex;
	align-items: center;
	flex-wrap: wrap;
	gap: 10px;
	margin-bottom: 12px;
	font-size: 0.82rem;
	color: var(--n3tw-text-muted, #94a3b8);
}

.n3tw-news-cat-pill {
	background: rgba(234, 88, 12, 0.15);
	color: #fb923c;
	border: 1px solid rgba(234, 88, 12, 0.3);
	font-size: 0.72rem;
	font-weight: 700;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	padding: 3px 10px;
	border-radius: 6px;
	line-height: 1.3;
	display: inline-block;
}

.n3tw-news-date {
	color: var(--n3tw-text-muted, #94a3b8);
	font-weight: 500;
}

.n3tw-news-dot {
	color: var(--n3tw-text-dim, #64748b);
}

.n3tw-news-readtime {
	color: var(--n3tw-text-muted, #94a3b8);
	font-weight: 500;
}

.n3tw-news-hero-title {
	font-size: 1.85rem;
	line-height: 1.25;
	font-weight: 800;
	color: var(--n3tw-text-primary, #f1f5f9);
	margin: 0 0 14px;
	letter-spacing: -0.01em;
}

.n3tw-news-hero-title a {
	color: inherit;
	text-decoration: none;
	transition: color 0.15s ease;
}

.n3tw-news-hero-title a:hover {
	color: #fb923c;
}

.n3tw-news-hero-excerpt {
	color: #cbd5e1;
	font-size: 1rem;
	line-height: 1.6;
	margin: 0 0 24px;
	flex-grow: 1;
}

.n3tw-news-hero-cta {
	display: block;
	width: 100%;
	text-align: center;
	background: linear-gradient(135deg, #f97316 0%, #ea580c 100%);
	color: #ffffff !important;
	font-weight: 700;
	font-size: 0.88rem;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	padding: 13px 24px;
	border-radius: 8px;
	box-shadow: 0 4px 14px rgba(234, 88, 12, 0.3);
	text-decoration: none !important;
	transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
	margin-top: auto;
}

.n3tw-news-hero-cta:hover {
	transform: translateY(-1px);
	box-shadow: 0 6px 20px rgba(234, 88, 12, 0.45);
	background: linear-gradient(135deg, #fb923c 0%, #ea580c 100%);
	color: #ffffff !important;
}

/* -------------------------------------------------------------------------
   Right: + Hovedsaker (Sidebar)
   ------------------------------------------------------------------------- */
.n3tw-news-sidebar {
	display: flex;
	flex-direction: column;
}

.n3tw-news-sidebar-header {
	font-size: 0.85rem;
	font-weight: 800;
	color: #fb923c;
	text-transform: uppercase;
	letter-spacing: 0.06em;
	margin: 0 0 14px;
	display: flex;
	align-items: center;
	gap: 6px;
}

.n3tw-news-sidebar-list {
	display: flex;
	flex-direction: column;
	gap: 12px;
	flex-grow: 1;
	justify-content: space-between;
}

.n3tw-news-sidebar-item {
	display: flex;
	gap: 14px;
	align-items: center;
	background: var(--n3tw-card-bg, #141E2E);
	border: 1px solid var(--n3tw-border, rgba(148, 163, 184, 0.15));
	border-radius: 12px;
	padding: 12px 14px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
	text-decoration: none !important;
	transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.n3tw-news-sidebar-item:hover {
	transform: translateX(3px);
	background: var(--n3tw-card-bg-hover, #19263A);
	border-color: rgba(249, 115, 22, 0.4);
	box-shadow: 0 4px 16px rgba(0, 0, 0, 0.4);
}

.n3tw-news-sidebar-thumb {
	flex-shrink: 0;
	width: 104px;
	height: 72px;
	border-radius: 8px;
	overflow: hidden;
	background: #0f172a;
}

.n3tw-news-sidebar-thumb img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
}

.n3tw-news-sidebar-info {
	flex-grow: 1;
	min-width: 0;
	display: flex;
	flex-direction: column;
	gap: 6px;
}

.n3tw-news-sidebar-meta {
	display: flex;
	align-items: center;
	gap: 8px;
	font-size: 0.75rem;
}

.n3tw-news-sidebar-title {
	font-size: 0.92rem;
	font-weight: 700;
	line-height: 1.35;
	color: var(--n3tw-text-primary, #f1f5f9);
	margin: 0;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
	transition: color 0.15s ease;
}

.n3tw-news-sidebar-item:hover .n3tw-news-sidebar-title {
	color: #fb923c;
}

/* -------------------------------------------------------------------------
   Bottom Section: | Siste nytt (5 Columns Grid)
   ------------------------------------------------------------------------- */
.n3tw-news-recent-section {
	margin-top: 16px;
}

.n3tw-news-recent-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	margin-bottom: 18px;
}

.n3tw-news-recent-title-wrap {
	display: flex;
	align-items: center;
	gap: 10px;
}

.n3tw-news-accent-bar {
	width: 4px;
	height: 1.35rem;
	background: #ea580c;
	border-radius: 2px;
	display: inline-block;
}

.n3tw-news-recent-heading {
	font-size: 1.3rem;
	font-weight: 800;
	color: var(--n3tw-text-primary, #f1f5f9);
	margin: 0;
	letter-spacing: -0.01em;
}

.n3tw-news-see-all-link {
	color: #fb923c !important;
	font-weight: 700;
	font-size: 0.86rem;
	text-decoration: none !important;
	display: inline-flex;
	align-items: center;
	gap: 4px;
	transition: transform 0.15s ease, color 0.15s ease;
}

.n3tw-news-see-all-link:hover {
	color: #f97316 !important;
	transform: translateX(2px);
}

.n3tw-news-recent-grid {
	display: grid;
	grid-template-columns: repeat(5, 1fr);
	gap: 14px;
}

.n3tw-news-recent-card {
	background: var(--n3tw-card-bg, #141E2E);
	border: 1px solid var(--n3tw-border, rgba(148, 163, 184, 0.15));
	border-radius: 10px;
	padding: 14px 16px;
	box-shadow: 0 2px 10px rgba(0, 0, 0, 0.25);
	display: flex;
	flex-direction: column;
	gap: 10px;
	text-decoration: none !important;
	transition: transform 0.15s ease, border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
	min-height: 110px;
}

.n3tw-news-recent-card:hover {
	transform: translateY(-2px);
	background: var(--n3tw-card-bg-hover, #19263A);
	border-color: rgba(249, 115, 22, 0.4);
	box-shadow: 0 6px 18px rgba(0, 0, 0, 0.4);
}

.n3tw-news-recent-card-top {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 6px;
}

.n3tw-news-recent-card-date {
	color: var(--n3tw-text-muted, #94a3b8);
	font-size: 0.75rem;
	font-weight: 600;
}

.n3tw-news-recent-card-title {
	font-size: 0.88rem;
	font-weight: 700;
	line-height: 1.35;
	color: var(--n3tw-text-primary, #f1f5f9);
	margin: 0;
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
	transition: color 0.15s ease;
}

.n3tw-news-recent-card:hover .n3tw-news-recent-card-title {
	color: #fb923c;
}

/* -------------------------------------------------------------------------
   Pagination / Older Posts Fallback
   ------------------------------------------------------------------------- */
.n3tw-news-pagination-wrap {
	margin-top: 40px;
	display: flex;
	justify-content: center;
}

.n3tw-news-pagination-wrap .pagination {
	display: flex;
	gap: 8px;
	list-style: none;
	padding: 0;
}

.n3tw-news-pagination-wrap .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 12px;
	border-radius: 8px;
	background: var(--n3tw-card-bg, #141E2E);
	border: 1px solid var(--n3tw-border, rgba(148, 163, 184, 0.2));
	color: var(--n3tw-text-primary, #f1f5f9);
	font-weight: 600;
	text-decoration: none;
	transition: all 0.15s ease;
}

.n3tw-news-pagination-wrap .page-numbers.current,
.n3tw-news-pagination-wrap .page-numbers:hover {
	background: #ea580c;
	border-color: #ea580c;
	color: #ffffff;
}

/* -------------------------------------------------------------------------
   Responsive Breakpoints
   ------------------------------------------------------------------------- */
@media (max-width: 1024px) {
	.n3tw-news-hero-section {
		grid-template-columns: 1fr;
		gap: 30px;
	}

	.n3tw-news-recent-grid {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 768px) {
	.n3tw-news-magazine {
		padding: 24px 0 40px;
	}

	.n3tw-news-hero-body {
		padding: 18px 20px 22px;
	}

	.n3tw-news-hero-title {
		font-size: 1.45rem;
	}

	.n3tw-news-recent-grid {
		grid-template-columns: repeat(2, 1fr);
	}
}

@media (max-width: 520px) {
	.n3tw-news-recent-grid {
		grid-template-columns: 1fr;
	}

	.n3tw-news-sidebar-item {
		padding: 10px 12px;
		gap: 10px;
	}

	.n3tw-news-sidebar-thumb {
		width: 84px;
		height: 60px;
	}
}
