/*
 * SleepBaby affiliate editorial V1: homepage reader-path system.
 * Scoped to the distinct 3.1.0 candidate and intentionally contains no
 * affiliate destination styling or URL behavior.
 */

.sb-hub--v3100 .sb-hub-hero {
	padding-block: clamp(48px, 6vw, 88px);
}

.sb-hub--v3100 .sb-hub-hero__layout {
	gap: clamp(30px, 5vw, 72px);
}

.sb-home-paths {
	position: relative;
	z-index: 2;
	padding: 0 0 clamp(52px, 7vw, 82px);
	background: #fffaf3;
}

.sb-home-paths__grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: clamp(12px, 2vw, 22px);
	margin-top: -24px;
}

.sb-home-path {
	position: relative;
	display: grid;
	min-width: 0;
	min-height: 154px;
	grid-template-columns: 52px minmax(0, 1fr) 24px;
	align-items: start;
	gap: 15px;
	padding: 24px 21px;
	border: 1px solid #d8c8d5;
	border-radius: 24px;
	color: #302532 !important;
	background: #fffdf9;
	box-shadow: 0 18px 44px rgba(69, 44, 70, .11);
	text-decoration: none;
}

.sb-home-path:hover {
	border-color: #8a6b8d;
	background: #fff;
	transform: translateY(-2px);
}

.sb-home-path:focus-visible {
	outline: 3px solid #714d78;
	outline-offset: 4px;
}

.sb-home-path__mark {
	position: relative;
	display: grid;
	width: 52px;
	height: 52px;
	place-items: center;
	border-radius: 18px;
	background: #f4d9e5;
}

.sb-home-path__mark i,
.sb-home-path__mark i::before,
.sb-home-path__mark i::after {
	position: absolute;
	display: block;
	content: "";
}

.sb-home-path--answer .sb-home-path__mark i {
	width: 22px;
	height: 22px;
	border: 3px solid #5a3a61;
	border-radius: 50%;
}

.sb-home-path--answer .sb-home-path__mark i::after {
	right: -6px;
	bottom: -5px;
	width: 10px;
	height: 3px;
	border-radius: 3px;
	background: #5a3a61;
	transform: rotate(45deg);
}

.sb-home-path--read .sb-home-path__mark {
	background: #dfe6fa;
}

.sb-home-path--read .sb-home-path__mark i {
	width: 25px;
	height: 29px;
	border: 2px solid #493e70;
	border-radius: 3px 8px 8px 3px;
}

.sb-home-path--read .sb-home-path__mark i::before,
.sb-home-path--read .sb-home-path__mark i::after {
	left: 5px;
	width: 14px;
	height: 2px;
	background: #493e70;
}

.sb-home-path--read .sb-home-path__mark i::before { top: 8px; }
.sb-home-path--read .sb-home-path__mark i::after { top: 15px; }

.sb-home-path--compare .sb-home-path__mark {
	background: #ffebbd;
}

.sb-home-path--compare .sb-home-path__mark i {
	left: 14px;
	top: 17px;
	width: 24px;
	height: 18px;
	border: 2px solid #604514;
	border-radius: 4px;
}

.sb-home-path--compare .sb-home-path__mark i::before {
	left: 4px;
	top: -7px;
	width: 12px;
	height: 7px;
	border: 2px solid #604514;
	border-bottom: 0;
	border-radius: 4px 4px 0 0;
}

.sb-home-path__copy {
	display: flex;
	min-width: 0;
	flex-direction: column;
}

.sb-home-path__copy small {
	color: #704f72;
	font-size: .76rem;
	font-style: normal;
	font-weight: 700;
	letter-spacing: .1em;
	line-height: 1.3;
	text-transform: uppercase;
}

.sb-home-path__copy strong {
	margin-top: 7px;
	color: #402b45;
	font-size: clamp(1.12rem, 1.6vw, 1.38rem);
	line-height: 1.08;
}

.sb-home-path__copy em {
	margin-top: 8px;
	color: #5b515c;
	font-size: .94rem;
	font-style: normal;
	line-height: 1.4;
}

.sb-home-path__arrow {
	align-self: center;
	color: #69466e;
	font-size: 1.35rem;
	font-weight: 700;
}

.sb-hub--v3100 .sb-hub-topics {
	padding-top: clamp(58px, 7vw, 88px);
}

.sb-hub--v3100 .sb-ranking-note {
	max-width: 570px;
	padding-left: 18px;
	border-left: 3px solid #bb87a6;
}

/* The feature no longer inherits a two-row stretch that left an empty body.
 * One lead story occupies seven columns, two supporting stories occupy its
 * remaining five-column rail, and the final three complete a full row. */
.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card--feature {
	grid-column: span 7;
	grid-row: span 2;
}

.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card:nth-child(2),
.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card:nth-child(3) {
	grid-column: span 5;
}

.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card:nth-child(n+4) {
	grid-column: span 4;
}

.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card--feature .sb-editorial-card__media {
	flex: 0 0 auto;
	aspect-ratio: 16 / 8.6;
}

.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card--feature .sb-editorial-card__body {
	justify-content: center;
}

.sb-hub--v3100 .sb-hub-section,
.sb-hub--v3100 .sb-hub-topics {
	padding-bottom: clamp(62px, 7vw, 94px);
}

@media (max-width: 1024px) {
	.sb-home-paths__grid {
		grid-template-columns: 1fr;
		max-width: 760px;
	}

	.sb-home-path {
		min-height: 0;
	}

	.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card--feature,
	.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card:nth-child(2),
	.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card:nth-child(3),
	.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card:nth-child(n+4) {
		grid-column: span 6;
		grid-row: auto;
	}
}

@media (max-width: 640px) {
	.sb-home-paths {
		padding-bottom: 54px;
	}

	.sb-home-paths__grid {
		margin-top: -14px;
	}

	.sb-home-path {
		grid-template-columns: 46px minmax(0, 1fr) 18px;
		gap: 12px;
		padding: 20px 17px;
		border-radius: 20px;
	}

	.sb-home-path__mark {
		width: 46px;
		height: 46px;
		border-radius: 15px;
	}

	.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card--feature,
	.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card:nth-child(2),
	.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card:nth-child(3),
	.sb-hub--v3100 .sb-editorial-grid--ranked .sb-editorial-card:nth-child(n+4) {
		grid-column: auto;
	}

	.sb-hub--v3100 .sb-ranking-note {
		padding-left: 14px;
	}
}

@media (max-width: 340px) {
	.sb-home-path {
		grid-template-columns: 42px minmax(0, 1fr);
	}

	.sb-home-path__mark {
		width: 42px;
		height: 42px;
	}

	.sb-home-path__arrow {
		display: none;
	}
}

@media (prefers-reduced-motion: reduce) {
	.sb-home-path {
		transform: none !important;
	}
}

@media (forced-colors: active) {
	.sb-home-path {
		border: 2px solid LinkText;
	}

	.sb-home-path__mark {
		forced-color-adjust: none;
	}
}
