/**
 * Phase 5.10 — Staff Picks editorial magazine (ground-up).
 * Scoped to #nds-staff-picks / .nds-spm only.
 */

#nds-staff-picks.nds-spm {
	--spm-ink: #0a1218;
	--spm-mute: #5c656e;
	--spm-soft: #8a929a;
	--spm-accent: #0b5f69;
	--spm-line: rgba(10, 18, 24, 0.08);
	--spm-surface: #ffffff;
	--spm-wash: #f3f6f7;
	--spm-ease: cubic-bezier(0.22, 1, 0.36, 1);
	padding: 3.25rem 0 3.4rem;
	margin: 0;
	background:
		radial-gradient(90% 70% at 100% 0%, rgba(11, 95, 105, 0.05), transparent 55%),
		linear-gradient(180deg, #eef3f5 0%, var(--spm-wash) 42%, #ffffff 100%);
	border-top: 1px solid var(--spm-line);
	color: var(--spm-ink);
}

.nds-spm__head {
	display: grid;
	grid-template-columns: minmax(0, 1fr) auto;
	align-items: end;
	gap: 1rem 2rem;
	margin-bottom: 1.85rem;
	padding-bottom: 1.15rem;
	border-bottom: 1px solid var(--spm-line);
}

.nds-spm__eyebrow {
	margin: 0 0 0.4rem;
	font-size: 0.68rem;
	font-weight: 750;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--spm-accent);
}

.nds-spm__title {
	margin: 0 0 0.45rem;
	font-family: var(--nds-font-display);
	font-size: clamp(1.75rem, 2.8vw, 2.35rem);
	font-weight: 650;
	letter-spacing: -0.035em;
	line-height: 1.08;
	color: var(--spm-ink);
}

.nds-spm__lede {
	margin: 0;
	max-width: 44ch;
	font-size: 1rem;
	line-height: 1.5;
	color: var(--spm-mute);
}

.nds-spm__all {
	display: inline-flex;
	align-items: center;
	gap: 0.35rem;
	padding-bottom: 0.2rem;
	font-size: 0.92rem;
	font-weight: 650;
	color: var(--spm-accent);
	text-decoration: none;
	border-bottom: 1px solid transparent;
	white-space: nowrap;
	transition: color 0.2s ease, border-color 0.2s ease;
}

.nds-spm__all:hover,
.nds-spm__all:focus-visible {
	color: var(--spm-ink);
	border-bottom-color: currentColor;
}

.nds-spm__all span {
	display: inline-block;
	transition: transform 0.25s var(--spm-ease);
}

.nds-spm__all:hover span,
.nds-spm__all:focus-visible span {
	transform: translateX(3px);
}

/* —— Stage: featured magazine + supporting rail —— */
.nds-spm__stage {
	display: grid;
	grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
	gap: 1.5rem 1.75rem;
	align-items: start;
}

.nds-spm-feature {
	display: grid;
	grid-template-columns: minmax(0, 0.42fr) minmax(0, 0.58fr);
	gap: 1.35rem 1.5rem;
	align-items: stretch;
	min-width: 0;
	padding: 1.25rem;
	border-radius: 18px;
	background:
		linear-gradient(165deg, #ffffff 0%, #f7fafb 100%);
	border: 1px solid var(--spm-line);
	box-shadow:
		0 1px 2px rgba(10, 18, 24, 0.03),
		0 18px 40px rgba(10, 18, 24, 0.06);
}

.nds-spm-feature__media {
	position: relative;
	display: flex;
	align-items: center;
	justify-content: center;
	min-width: 0;
	padding: 1.15rem 0.85rem;
	border-radius: 14px;
	background:
		radial-gradient(120% 90% at 50% 0%, rgba(11, 95, 105, 0.08), transparent 55%),
		linear-gradient(165deg, #f4f8f9 0%, #e6eef1 100%);
}

.nds-spm-feature__badge {
	position: absolute;
	z-index: 2;
	top: 0.85rem;
	left: 0.85rem;
	padding: 0.28rem 0.65rem;
	border-radius: 999px;
	font-size: 0.62rem;
	font-weight: 800;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #fff;
	background: rgba(11, 95, 105, 0.94);
	box-shadow: 0 4px 14px rgba(11, 95, 105, 0.28);
}

.nds-spm-feature__cover {
	display: flex;
	align-items: center;
	justify-content: center;
	text-decoration: none;
	width: 100%;
}

.nds-spm-feature__cover img {
	display: block;
	width: auto;
	max-width: 100%;
	height: auto;
	max-height: 22rem;
	object-fit: contain;
	filter: drop-shadow(0 16px 28px rgba(10, 18, 24, 0.2));
	transition: transform 0.4s var(--spm-ease), filter 0.4s ease;
}

.nds-spm-feature__body {
	display: flex;
	flex-direction: column;
	gap: 0.65rem;
	min-width: 0;
	padding: 0.35rem 0.25rem 0.15rem 0;
}

.nds-spm-feature__rec {
	margin: 0;
	font-size: 0.78rem;
	font-weight: 650;
	line-height: 1.4;
	letter-spacing: 0.01em;
	color: var(--spm-accent);
}

.nds-spm-feature__meta {
	margin: 0;
	font-size: 0.68rem;
	font-weight: 700;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--spm-soft);
}

.nds-spm-feature__title {
	margin: 0;
	font-family: var(--nds-font-display);
	font-size: clamp(1.25rem, 1.7vw, 1.65rem);
	font-weight: 700;
	letter-spacing: -0.03em;
	line-height: 1.2;
}

.nds-spm-feature__title a {
	color: var(--spm-ink);
	text-decoration: none;
}

.nds-spm-feature__summary {
	margin: 0;
	font-size: 0.95rem;
	line-height: 1.5;
	color: var(--spm-mute);
	display: -webkit-box;
	-webkit-line-clamp: 3;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.nds-spm-feature__why {
	margin-top: 0.25rem;
	padding: 0.85rem 0.95rem;
	border-radius: 12px;
	background: rgba(11, 95, 105, 0.05);
	border: 1px solid rgba(11, 95, 105, 0.1);
}

.nds-spm-feature__why-label {
	margin: 0 0 0.35rem;
	font-size: 0.62rem;
	font-weight: 800;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	color: var(--spm-accent);
}

.nds-spm-feature__why-text {
	margin: 0;
	font-size: 0.86rem;
	line-height: 1.45;
	color: var(--spm-ink);
}

.nds-spm-feature__buy {
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
	margin-top: auto;
	padding-top: 0.55rem;
}

.nds-spm-feature__price {
	font-size: 1.35rem;
	font-weight: 750;
	letter-spacing: -0.025em;
	line-height: 1.1;
	color: var(--spm-ink);
}

.nds-spm-feature__actions {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 0.85rem 1.15rem;
}

.nds-spm-cta {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	height: 42px;
	padding: 0 1.15rem;
	border-radius: 11px;
	font-size: 0.86rem;
	font-weight: 700;
	line-height: 1;
	text-decoration: none;
	color: #fff !important;
	background: var(--spm-accent);
	border: 1px solid transparent;
	box-shadow: 0 1px 2px rgba(11, 95, 105, 0.18);
	transition: background-color 0.2s ease, box-shadow 0.2s ease;
}

.nds-spm-cta:hover,
.nds-spm-cta:focus-visible {
	background: #084f58;
	color: #fff !important;
	box-shadow: 0 6px 16px rgba(11, 95, 105, 0.24);
}

.nds-spm-link {
	display: inline-flex;
	align-items: center;
	gap: 0.28rem;
	font-size: 0.9rem;
	font-weight: 650;
	color: var(--spm-accent);
	text-decoration: none;
	border-bottom: 1px solid transparent;
	transition: color 0.2s ease, border-color 0.2s ease;
}

.nds-spm-link span {
	display: inline-block;
	transition: transform 0.25s var(--spm-ease);
}

.nds-spm-link:hover,
.nds-spm-link:focus-visible {
	color: var(--spm-ink);
	border-bottom-color: currentColor;
}

.nds-spm-link:hover span,
.nds-spm-link:focus-visible span {
	transform: translateX(3px);
}

/* —— Supporting editorial recommendations —— */
.nds-spm-rail {
	display: flex;
	flex-direction: column;
	gap: 0.85rem;
	min-width: 0;
}

.nds-spm-rec {
	display: grid;
	grid-template-columns: 4.75rem minmax(0, 1fr);
	gap: 0.85rem 1rem;
	align-items: center;
	min-width: 0;
	padding: 0.85rem 0.95rem 0.85rem 0.85rem;
	border-radius: 14px;
	background: var(--spm-surface);
	border: 1px solid var(--spm-line);
	box-shadow:
		0 1px 2px rgba(10, 18, 24, 0.025),
		0 8px 20px rgba(10, 18, 24, 0.04);
	transition:
		transform 0.3s var(--spm-ease),
		box-shadow 0.3s ease,
		border-color 0.3s ease;
}

.nds-spm-rec__media {
	display: flex;
	align-items: center;
	justify-content: center;
	align-self: stretch;
	width: 4.75rem;
	min-height: 6.25rem;
	padding: 0.2rem;
	text-decoration: none;
	overflow: hidden;
}

.nds-spm-rec__media img {
	display: block;
	width: 100%;
	height: auto;
	max-height: 6.4rem;
	object-fit: contain;
	border-radius: 5px;
	filter: drop-shadow(0 6px 12px rgba(10, 18, 24, 0.16));
	transition: transform 0.35s var(--spm-ease);
}

.nds-spm-rec__body {
	display: flex;
	flex-direction: column;
	gap: 0.28rem;
	min-width: 0;
}

.nds-spm-rec__subject {
	margin: 0;
	font-size: 0.58rem;
	font-weight: 750;
	letter-spacing: 0.1em;
	text-transform: uppercase;
	color: var(--spm-accent);
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.nds-spm-rec__title {
	margin: 0;
	font-family: var(--nds-font-display);
	font-size: 0.95rem;
	font-weight: 700;
	letter-spacing: -0.02em;
	line-height: 1.28;
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.nds-spm-rec__title a {
	color: var(--spm-ink);
	text-decoration: none;
}

.nds-spm-rec__note {
	margin: 0;
	font-size: 0.78rem;
	line-height: 1.4;
	color: var(--spm-mute);
	display: -webkit-box;
	-webkit-line-clamp: 2;
	-webkit-box-orient: vertical;
	overflow: hidden;
}

.nds-spm-rec__foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 0.75rem;
	margin-top: 0.25rem;
}

.nds-spm-rec__price {
	font-size: 0.95rem;
	font-weight: 750;
	letter-spacing: -0.015em;
	color: var(--spm-ink);
	line-height: 1.1;
	white-space: nowrap;
}

.nds-spm-rec__cta {
	display: inline-flex;
	align-items: center;
	gap: 0.22rem;
	font-size: 0.76rem;
	font-weight: 700;
	color: var(--spm-accent);
	text-decoration: none;
	white-space: nowrap;
	border-bottom: 1px solid transparent;
	transition: color 0.2s ease, border-color 0.2s ease;
}

.nds-spm-rec__cta span {
	display: inline-block;
	transition: transform 0.25s var(--spm-ease);
}

.nds-spm-rec__cta:hover,
.nds-spm-rec__cta:focus-visible {
	color: var(--spm-ink);
	border-bottom-color: currentColor;
}

.nds-spm-rec__cta:hover span,
.nds-spm-rec__cta:focus-visible span {
	transform: translateX(2px);
}

.nds-spm-ph {
	display: flex;
	align-items: center;
	justify-content: center;
	width: 100%;
	min-height: 10rem;
	font-size: 0.82rem;
	color: var(--spm-soft);
}

.nds-spm-ph--sm {
	min-height: 5rem;
	font-size: 0.72rem;
}

.nds-spm__all:focus-visible,
.nds-spm-cta:focus-visible,
.nds-spm-link:focus-visible,
.nds-spm-rec__cta:focus-visible,
.nds-spm-feature__title a:focus-visible,
.nds-spm-rec__title a:focus-visible,
.nds-spm-feature__cover:focus-visible,
.nds-spm-rec__media:focus-visible {
	outline: 2px solid var(--spm-accent);
	outline-offset: 2px;
}

@media (hover: hover) and (pointer: fine) {
	.nds-spm-feature:hover .nds-spm-feature__cover img {
		transform: translateY(-4px) scale(1.02);
		filter: drop-shadow(0 20px 32px rgba(10, 18, 24, 0.24));
	}

	.nds-spm-rec:hover {
		transform: translateY(-2px);
		border-color: rgba(11, 95, 105, 0.14);
		box-shadow:
			0 2px 4px rgba(10, 18, 24, 0.04),
			0 14px 28px rgba(10, 18, 24, 0.075);
	}

	.nds-spm-rec:hover .nds-spm-rec__media img {
		transform: scale(1.02);
	}
}

@media (max-width: 1100px) {
	.nds-spm__stage {
		gap: 1.25rem;
	}

	.nds-spm-feature {
		grid-template-columns: minmax(0, 0.4fr) minmax(0, 0.6fr);
		padding: 1.1rem;
	}

	.nds-spm-feature__cover img {
		max-height: 19rem;
	}
}

@media (max-width: 1024px) {
	.nds-spm__stage {
		grid-template-columns: 1fr;
		gap: 1.15rem;
	}

	.nds-spm-feature {
		grid-template-columns: minmax(0, 0.36fr) minmax(0, 0.64fr);
	}

	.nds-spm-rail {
		display: grid;
		grid-template-columns: repeat(2, minmax(0, 1fr));
		gap: 0.85rem;
	}
}

@media (max-width: 720px) {
	#nds-staff-picks.nds-spm {
		padding: 2.5rem 0 2.65rem;
	}

	.nds-spm__head {
		grid-template-columns: 1fr;
		align-items: start;
		gap: 0.75rem;
	}

	.nds-spm-feature {
		display: flex;
		flex-direction: column;
		padding: 1rem;
	}

	.nds-spm-feature__media {
		min-height: 16rem;
	}

	.nds-spm-feature__cover img {
		max-height: 17rem;
	}

	.nds-spm-rail {
		display: flex;
		flex-direction: column;
		gap: 0.75rem;
	}

	.nds-spm-rec {
		grid-template-columns: 4.4rem minmax(0, 1fr);
	}
}

@media (prefers-reduced-motion: reduce) {
	.nds-spm-feature__cover img,
	.nds-spm-rec,
	.nds-spm-rec__media img,
	.nds-spm__all span,
	.nds-spm-link span,
	.nds-spm-rec__cta span,
	.nds-spm-cta {
		transition: none !important;
	}

	.nds-spm-rec:hover {
		transform: none;
	}

	.nds-spm-feature:hover .nds-spm-feature__cover img,
	.nds-spm-rec:hover .nds-spm-rec__media img {
		transform: none;
	}
}
