/* Additions that keep the homepage design and style the rest of the theme. */

.skip-link,
.screen-reader-text,
.nav-toggle,
.search-toggle {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.skip-link:focus {
	position: fixed !important;
	top: 12px;
	left: 12px;
	width: auto;
	height: auto;
	margin: 0;
	clip: auto;
	padding: 10px 14px;
	background: var(--ink);
	color: #fff;
	border-radius: 99px;
	z-index: 100000;
	font-size: 13px;
	font-weight: 700;
}

a:focus-visible,
button:focus-visible,
input:focus-visible,
textarea:focus-visible,
.nav-toggle:focus-visible ~ .nav .menu,
.search-toggle:focus-visible ~ .nav .search-icon {
	outline: 2px solid var(--coral);
	outline-offset: 3px;
}

label.search-icon,
label.menu {
	cursor: pointer;
	user-select: none;
}

label.search-icon {
	display: grid;
	place-items: center;
	padding: 0;
	line-height: 1;
}

.search-toggle:checked ~ .search-panel {
	display: block;
}

header {
	position: sticky;
}

footer .brand {
	color: #fff;
}

.links a:hover,
.links a:focus-visible,
.footcol a:hover,
.footcol a:focus-visible {
	opacity: 1;
	color: #fff;
}

.links a:hover,
.links a:focus-visible {
	color: inherit;
}

.hero-art > img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.story-main > a {
	display: block;
	position: relative;
	min-height: 360px;
	height: 100%;
	overflow: hidden;
}

a.pick-img,
.side-story > a {
	display: block;
	text-decoration: none;
}

.side-story > a {
	line-height: 0;
}

.pick-img img {
	display: block;
}

.story-main img {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	object-fit: cover;
	min-height: 0;
}

.story-content h3 a,
.side-story h4 a,
.pick h3 a {
	color: inherit;
	text-decoration: none;
	border-bottom: 0;
	padding-bottom: 0;
	margin-top: 0;
}

.story-content h3,
.story-content h3 a {
	font: 600 32px/1.12 "Space Grotesk", sans-serif;
	letter-spacing: -0.045em;
}

.side-story h4,
.side-story h4 a {
	font: 600 19px/1.2 "Space Grotesk", sans-serif;
	letter-spacing: -0.04em;
}

.pick {
	transition: transform 0.25s;
}

.pick:hover {
	transform: translateY(-4px);
}

.section h1 {
	font: 600 clamp(32px, 4vw, 48px) / 1.04 "Space Grotesk", sans-serif;
	letter-spacing: -0.06em;
	margin: 10px 0 0;
}

h1,
h2,
h3,
h4 {
	overflow-wrap: break-word;
}

.archive-desc,
.section-head .archive-desc {
	max-width: 460px;
	color: var(--muted);
	font-size: 14px;
	line-height: 1.6;
	margin: 12px 0 0;
}

.archive-desc p {
	margin: 0;
}

.result-count {
	margin: 8px 0 0;
	color: var(--muted);
	font-size: 13px;
}

.navigation.pagination,
.page-links {
	margin-top: 28px;
}

.nav-links {
	display: flex;
	gap: 8px;
	flex-wrap: wrap;
}

.page-numbers,
.page-links a,
.page-links > span {
	min-width: 40px;
	height: 40px;
	border-radius: 99px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	border: 1px solid var(--line);
	background: var(--white);
	font-size: 12px;
	font-weight: 700;
	padding: 0 12px;
}

.page-numbers.current,
.page-links > span:not(.page-links-title) {
	background: var(--ink);
	color: #fff;
	border-color: var(--ink);
}

.entry {
	padding-bottom: 20px;
}

.entry-wrap {
	width: min(860px, calc(100% - 48px));
	margin: 0 auto;
	padding: 48px 0 10px;
}

.entry-kicker {
	font-size: 11px;
	letter-spacing: 0.16em;
	text-transform: uppercase;
	color: var(--muted);
	font-weight: 700;
	text-decoration: none;
}

.entry-title {
	font: 600 clamp(36px, 5vw, 64px) / 1.02 "Space Grotesk", sans-serif;
	letter-spacing: -0.06em;
	margin: 14px 0 16px;
}

.entry-deck {
	font-size: 18px;
	line-height: 1.6;
	color: #35443c;
	margin: 0 0 18px;
}

.entry-meta {
	color: var(--muted);
	font-size: 12px;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	font-weight: 700;
	margin: 0 0 26px;
}

.entry-meta a {
	text-decoration: none;
	border-bottom: 1px solid var(--line);
}

.entry-hero {
	margin: 0 0 32px;
	border-radius: 24px;
	overflow: hidden;
	background: #e9e6dc;
}

.entry-hero img {
	display: block;
	width: 100%;
	max-height: 540px;
	object-fit: cover;
}

.entry-content {
	font-size: 17px;
	line-height: 1.75;
	color: #24312e;
}

.entry-content > * {
	margin: 0 0 1.15em;
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
	font-family: "Space Grotesk", sans-serif;
	font-weight: 600;
	letter-spacing: -0.04em;
	line-height: 1.15;
	color: var(--ink);
	margin-top: 1.5em;
}

.entry-content h2 {
	font-size: clamp(28px, 3vw, 36px);
}

.entry-content h3 {
	font-size: 26px;
}

.entry-content h4 {
	font-size: 20px;
}

.entry-content a {
	text-decoration: underline;
	text-underline-offset: 3px;
}

.entry-content ul,
.entry-content ol {
	padding-left: 1.25em;
}

.entry-content li {
	margin: 0.35em 0;
}

.entry-content img {
	max-width: 100%;
	height: auto;
	border-radius: 16px;
}

.entry-content figure {
	margin: 1.6em 0;
}

.entry-content figcaption {
	color: var(--muted);
	font-size: 12px;
	margin-top: 8px;
}

.entry-content blockquote {
	margin: 1.6em 0;
	padding: 4px 0 4px 18px;
	border-left: 3px solid var(--coral);
	font-size: 22px;
	line-height: 1.4;
	letter-spacing: -0.03em;
}

.entry-content table {
	width: 100%;
	border-collapse: collapse;
	font-size: 14px;
	background: var(--white);
}

.entry-content th,
.entry-content td {
	border-bottom: 1px solid var(--line);
	padding: 12px 14px;
	text-align: left;
	vertical-align: top;
}

.entry-content th {
	font-family: "Space Grotesk", sans-serif;
	font-size: 12px;
	letter-spacing: 0.04em;
}

.entry-content .wp-block-table {
	overflow-x: auto;
	border: 1px solid var(--line);
	border-radius: 16px;
	background: var(--white);
}

.entry-content iframe,
.entry-content video {
	max-width: 100%;
}

.entry-tags {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 28px;
}

.entry-tags a {
	background: var(--white);
	border: 1px solid var(--line);
	border-radius: 99px;
	padding: 8px 12px;
	font-size: 11px;
	font-weight: 700;
	text-decoration: none;
}

.post-nav {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
	margin-top: 36px;
}

.post-nav a {
	background: var(--white);
	border-radius: 16px;
	padding: 16px 18px;
	display: block;
	border: 1px solid var(--line);
	text-decoration: none;
	min-height: 100%;
}

.post-nav small {
	display: block;
	color: var(--muted);
	font-size: 10px;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	font-weight: 700;
}

.post-nav strong {
	display: block;
	margin-top: 8px;
	font: 600 16px / 1.3 "Space Grotesk", sans-serif;
	letter-spacing: -0.03em;
}

.post-nav .next {
	text-align: right;
}

.related {
	background: #e7e9e2;
}

.comments-area {
	width: min(860px, calc(100% - 48px));
	margin: 10px auto 70px;
}

.comments-title,
.comment-reply-title {
	font: 600 28px / 1.1 "Space Grotesk", sans-serif;
	letter-spacing: -0.05em;
}

.comment-list {
	list-style: none;
	margin: 20px 0;
	padding: 0;
}

.comment-list .children {
	list-style: none;
	margin: 12px 0 0;
	padding-left: 22px;
}

.comment-body {
	background: var(--white);
	border: 1px solid var(--line);
	border-radius: 16px;
	padding: 16px 18px;
	margin-bottom: 12px;
}

.comment-meta {
	font-size: 12px;
	color: var(--muted);
	margin-bottom: 8px;
}

.comment-meta a {
	text-decoration: none;
}

.comment-author .fn {
	font-family: "Space Grotesk", sans-serif;
	font-style: normal;
	font-weight: 600;
	color: var(--ink);
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea,
.post-password-form input[type="password"],
.searchform input[type="search"] {
	width: 100%;
	border: 1px solid var(--line);
	background: var(--white);
	border-radius: 16px;
	padding: 14px 16px;
}

.comment-form textarea {
	min-height: 140px;
}

.comment-form .submit,
.post-password-form input[type="submit"] {
	border: 0;
	cursor: pointer;
	margin-top: 8px;
}

.form-note {
	font-size: 13px;
	margin: 10px 0 0;
}

.form-note.ok {
	color: #1e4d32;
}

.form-note.bad {
	color: #8a2a1f;
}

.hp-field {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

.news-action {
	width: min(440px, 100%);
}

.news-action .newsform {
	width: 100%;
}

.story-grid.is-single {
	grid-template-columns: 1fr;
}

.pick-fallback,
.media-fallback {
	display: block;
	width: 100%;
	height: 100%;
	background: linear-gradient(145deg, #d7f36b, #c9dff2 55%, #f6c7b7);
}

.story-main .media-fallback {
	position: absolute;
	inset: 0;
}

.side-story .media-fallback {
	width: 112px;
	height: 112px;
	border-radius: 14px;
	position: static;
}

.entry-content .alignleft {
	float: left;
	margin: 0.3em 1.2em 1em 0;
}

.entry-content .alignright {
	float: right;
	margin: 0.3em 0 1em 1.2em;
}

.entry-content .aligncenter {
	display: block;
	margin-left: auto;
	margin-right: auto;
}

.empty-state {
	background: var(--white);
	border: 1px solid var(--line);
	border-radius: 24px;
	padding: 32px;
	max-width: 640px;
}

.empty-state h2 {
	font: 600 32px / 1.1 "Space Grotesk", sans-serif;
	letter-spacing: -0.05em;
	margin: 0 0 8px;
}

.empty-state p {
	color: var(--muted);
	margin: 0 0 18px;
}

.lost {
	padding: 48px 0 70px;
}

.lost .hero-copy {
	min-height: 420px;
}

.lost h1 {
	font: 600 clamp(48px, 6vw, 76px) / 0.98 "Space Grotesk", sans-serif;
	letter-spacing: -0.07em;
	margin: 22px 0 16px;
}

.lost .search-inner {
	margin-top: 22px;
}

.lost .search-inner input {
	background: #fff;
}

body.admin-bar header {
	top: 32px;
}

@media (max-width: 782px) {
	body.admin-bar header {
		top: 46px;
	}
}

@media (max-width: 680px) {
	.nav-toggle:checked ~ .nav .links {
		display: flex;
	}

	.story-main > a {
		min-height: 220px;
		height: 220px;
	}

	.entry-wrap,
	.comments-area {
		width: calc(100% - 30px);
	}

	.entry-title {
		font-size: clamp(34px, 10vw, 48px);
	}

	.post-nav {
		grid-template-columns: 1fr;
	}

	.post-nav .next {
		text-align: left;
	}

	.comment-list .children {
		padding-left: 12px;
	}

	.lost .hero-copy {
		min-height: 0;
	}

	.news-action,
	.news-action .newsform {
		width: 100%;
	}

	.side-story .media-fallback {
		width: 90px;
		height: 90px;
	}
}

@media (prefers-reduced-motion: reduce) {
	html {
		scroll-behavior: auto;
	}

	.ticker-inner,
	.cat,
	.pick {
		animation: none !important;
		transition: none;
	}
}

/* Light / dark and the tablet + phone layout. */

html {
	color-scheme: light;
}

html[data-theme="dark"] {
	color-scheme: dark;
	--ink: #e7eee9;
	--muted: #9eaea8;
	--paper: #101614;
	--white: #1b2623;
	--line: #31403c;
}

.theme-toggle {
	width: 40px;
	height: 40px;
	border-radius: 50%;
	border: 1px solid var(--line);
	background: transparent;
	color: var(--ink);
	display: grid;
	place-items: center;
	padding: 0;
	cursor: pointer;
	font-size: 16px;
	line-height: 1;
}

html:not([data-theme="dark"]) .theme-icon-sun,
html[data-theme="dark"] .theme-icon-moon {
	display: none;
}

.ticker-inner {
	display: flex;
	width: min(1240px, calc(100% - 48px));
	margin: 0 auto;
}

.ticker-group {
	display: flex;
	align-items: center;
	justify-content: space-around;
	gap: 28px;
	flex: 1;
}

.ticker-extra {
	display: none;
}

[data-theme="dark"] .topline,
[data-theme="dark"] .ticker,
[data-theme="dark"] footer,
[data-theme="dark"] .story-main,
[data-theme="dark"] .primary,
[data-theme="dark"] .newsform button {
	background: #172321;
	color: #fff;
}

[data-theme="dark"] .search-inner button {
	background: #e7eee9;
	color: #121a18;
}

[data-theme="dark"] .nav-cta,
[data-theme="dark"] .page-numbers.current,
[data-theme="dark"] .page-links > span:not(.page-links-title) {
	background: #e7eee9;
	color: #121a18;
}

[data-theme="dark"] header {
	border-bottom-color: rgba(255, 255, 255, 0.08);
}

[data-theme="dark"] .hero-copy,
[data-theme="dark"] .method,
[data-theme="dark"] .newsbox,
[data-theme="dark"] .cat,
[data-theme="dark"] .pick-badge {
	color: #172321;
}

[data-theme="dark"] .featured,
[data-theme="dark"] .related {
	background: #18211e;
}

[data-theme="dark"] .hero-feature {
	background: rgba(16, 22, 20, 0.88);
	color: #e7eee9;
}

[data-theme="dark"] .entry-deck {
	color: #c5d2cc;
}

[data-theme="dark"] .entry-content {
	color: #d5e0db;
}

[data-theme="dark"] .entry-hero {
	background: #24302c;
}

[data-theme="dark"] .search-inner input,
[data-theme="dark"] .comment-form input,
[data-theme="dark"] .comment-form textarea,
[data-theme="dark"] .post-password-form input {
	background: var(--white);
	color: var(--ink);
}

[data-theme="dark"] .lost .search-inner input {
	background: #fff;
	color: #172321;
}

@keyframes ern-marquee {
	from {
		transform: translateX(0);
	}
	to {
		transform: translateX(-50%);
	}
}

@media (max-width: 1080px) {
	.nav-cta {
		display: none;
	}

	.picks-grid {
		grid-template-columns: 1fr 1fr;
	}

	.footgrid {
		grid-template-columns: 1fr 1fr;
	}

	.footbrand {
		grid-column: span 2;
	}

	.ticker {
		overflow: hidden;
	}

	.ticker-inner {
		width: max-content;
		max-width: none;
		margin: 0;
		animation: ern-marquee 28s linear infinite;
	}

	.ticker-group {
		flex: none;
		justify-content: flex-start;
		padding-right: 36px;
	}

	.ticker-extra {
		display: flex;
	}
}

@media (max-width: 980px) {
	.menu {
		display: block;
	}

	.links {
		display: none;
		position: absolute;
		top: 78px;
		left: 0;
		right: 0;
		z-index: 30;
		background: var(--paper);
		padding: 18px 22px 24px;
		flex-direction: column;
		align-items: flex-start;
		gap: 16px;
		border-bottom: 1px solid var(--line);
	}

	.nav-toggle:checked ~ .nav .links {
		display: flex;
	}
}

@media (max-width: 860px) {
	.hero-grid {
		grid-template-columns: 1fr;
		min-height: 0;
	}

	.hero h1 {
		font-size: clamp(46px, 8vw, 68px);
	}

	.hero-copy,
	.hero-art {
		min-height: 0;
	}

	.hero-art {
		min-height: 420px;
	}

	.story-main {
		grid-template-columns: 1fr;
	}

	.story-main > a {
		min-height: 260px;
		height: 260px;
	}

	.method,
	.newsbox {
		grid-template-columns: 1fr;
		flex-direction: column;
		align-items: flex-start;
	}

	.news-action,
	.news-action .newsform {
		width: 100%;
	}

	.method {
		gap: 24px;
	}
}

@media (max-width: 680px) {
	.topline {
		letter-spacing: 0.04em;
	}

	.topline .wrap span {
		text-align: center;
		line-height: 1.5;
	}

	.links,
	.search-panel {
		top: 66px;
	}

	.picks-grid {
		grid-template-columns: 1fr;
	}

	.hero-note {
		flex-direction: column;
		align-items: flex-start;
		gap: 8px;
	}

	.theme-toggle,
	label.search-icon {
		width: 36px;
		height: 36px;
	}
}

@media (max-width: 640px) {
	.method-steps {
		grid-template-columns: 1fr;
	}
}

@media (max-width: 420px) {
	.nav {
		gap: 8px;
	}

	.nav-right {
		gap: 8px;
	}

	.brand {
		font-size: 16px;
		letter-spacing: -0.8px;
		gap: 8px;
	}

	.hero-feature {
		padding: 16px;
	}

	.hero-feature strong {
		font-size: 18px;
	}
}

/* Category photos sit in the open middle of each pastel card. */

.category-grid .cat {
	justify-content: flex-start;
}

.cat-photo {
	display: block;
	width: 100%;
	height: 86px;
	flex: none;
	margin-top: 14px;
	object-fit: cover;
	border-radius: 14px;
}

.category-grid .cat:nth-child(-n + 3) .cat-photo {
	height: 108px;
}

.cat-copy {
	margin-top: auto;
	padding-top: 14px;
	padding-right: 32px;
}

@media (max-width: 900px) {
	.category-grid .cat:nth-child(-n + 3) .cat-photo,
	.cat-photo {
		height: 92px;
	}
}

@media (max-width: 680px) {
	.category-grid .cat {
		min-height: 220px;
	}
}

@media (max-width: 390px) {
	.category-grid .cat {
		min-height: 0;
	}

	.cat-photo,
	.category-grid .cat:nth-child(-n + 3) .cat-photo {
		height: 148px;
	}
}

/* Header dropdowns. Top-level links stay in the row; children open underneath. */

header,
.nav,
.links {
	overflow: visible;
}

.links {
	align-items: center;
	gap: 32px;
}

.links > a,
.nav-item > a {
	display: inline-flex;
	align-items: center;
	line-height: 1;
}

.nav-item {
	position: relative;
	display: flex;
	align-items: center;
	gap: 4px;
}

.sub-toggle {
	width: 14px;
	height: 14px;
	margin: 0 -18px 0 0;
	padding: 0;
	border: 1px solid transparent;
	border-radius: 50%;
	background: transparent;
	color: inherit;
	cursor: pointer;
	display: grid;
	place-items: center;
	flex: none;
}

.sub-toggle span {
	width: 5px;
	height: 5px;
	border-right: 1.5px solid currentColor;
	border-bottom: 1.5px solid currentColor;
	transform: rotate(45deg) translateY(-1px);
	display: block;
}

.nav-item.is-open > .sub-toggle,
.sub-toggle:hover,
.sub-toggle:focus-visible {
	border-color: var(--line);
	background: var(--white);
}

.nav-item.is-open > .sub-toggle span {
	transform: rotate(225deg) translateY(1px);
}

.submenu {
	display: none;
	position: absolute;
	top: calc(100% + 16px);
	left: 50%;
	transform: translateX(-50%);
	width: max-content;
	min-width: 220px;
	padding: 8px;
	background: var(--white);
	color: var(--ink);
	border: 1px solid var(--line);
	border-radius: 16px;
	box-shadow: 0 18px 40px rgba(23, 35, 33, 0.12);
	z-index: 40;
	flex-direction: column;
	gap: 2px;
	max-height: calc(100vh - 130px);
	overflow-y: auto;
	overscroll-behavior: contain;
}

.submenu::before {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	top: -16px;
	height: 16px;
}

.nav-item.has-sub::after {
	content: "";
	position: absolute;
	left: 0;
	right: 0;
	top: 100%;
	height: 16px;
}

.nav-item.is-open > .submenu {
	display: flex;
}

.submenu a {
	display: block;
	opacity: 1;
	padding: 10px 12px;
	border-radius: 10px;
	color: var(--ink);
	white-space: nowrap;
}

.submenu a.submenu-nested {
	padding-left: 22px;
	font-weight: 500;
}

.submenu a:hover,
.submenu a:focus-visible {
	background: var(--paper);
	color: var(--ink);
	opacity: 1;
}

@media (min-width: 981px) and (hover: hover) {
	.nav-item.has-sub:hover > .submenu {
		display: flex;
	}
}

@media (max-width: 980px) {
	.links {
		gap: 16px;
	}

	.sub-toggle {
		width: 32px;
		height: 32px;
		margin: 0;
	}

	.nav-item,
	.nav-item.has-sub {
		flex-wrap: wrap;
		width: 100%;
	}

	.nav-item.has-sub > a {
		flex: 1;
	}

	.nav-item.has-sub::after {
		display: none;
	}

	.submenu {
		position: static;
		top: auto;
		left: auto;
		transform: none;
		width: 100%;
		min-width: 0;
		max-height: none;
		margin-top: 6px;
		padding: 4px 0 4px 8px;
		overflow: visible;
		border: 0;
		border-radius: 0;
		box-shadow: none;
		background: transparent;
	}

	.submenu::before {
		display: none;
	}

	.submenu a {
		white-space: normal;
		padding: 8px 10px;
	}
}

/* Hero call-to-action: keep the arrow on the same line as the label. */

.hero-actions .primary {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	flex: none;
	width: max-content;
	max-width: 100%;
	line-height: 1;
	padding: 14px 18px;
	white-space: nowrap;
}

.hero-actions .primary b {
	display: block;
	font-size: 15px;
	font-weight: 500;
	line-height: 1;
}

/* Buy buttons kept from imported reviews. */

a.kt-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	margin: 8px 0;
	padding: 12px 18px;
	background: #172321;
	color: #fff;
	border-radius: 99px;
	font-size: 13px;
	font-weight: 700;
	line-height: 1;
}

a.kt-button:hover,
a.kt-button:focus-visible {
	opacity: 0.88;
	color: #fff;
}

[data-theme="dark"] a.kt-button {
	background: #e7eee9;
	color: #121a18;
}

[data-theme="dark"] a.kt-button:hover,
[data-theme="dark"] a.kt-button:focus-visible {
	color: #121a18;
}
