/* Category pages (/category/...): the posts as clean cards in the site's copper style.
   Loaded only on category archives by mu-plugins/category-cards.php. */

/* page header: copper band, white Lora title, gold rule */
.archive.category .main > .loop-meta-wrap {
	background: radial-gradient(ellipse at 50% 40%, rgba(201, 164, 92, .22), transparent 65%), linear-gradient(120deg, #94562a, #5a3118) !important;
	border-bottom: 3px solid #c9a45c;
}
.archive.category .loop-meta {
	padding: 34px 0 30px;
}
.archive.category .loop-meta .archive-title {
	margin: 0;
	font-family: Lora, Georgia, serif;
	font-weight: 600;
	font-size: 2.2rem;
	line-height: 1.2;
	color: #fff;
}
.archive.category .loop-meta .archive-title::after {
	content: "";
	display: block;
	width: 64px;
	height: 2px;
	margin: 14px auto 0;
	background: #c9a45c;
}
.archive.category .loop-meta .archive-description {
	margin: 12px auto 0;
	max-width: 620px;
	font-size: .78rem;
	font-weight: 600;
	letter-spacing: .16em;
	text-transform: uppercase;
	color: #e9d3a6;
}
.archive.category .loop-meta .archive-description p { margin: 0; }

/* the grid: the newest post as a wide card (photo beside the text), then three columns of small cards */
.archive.category #archive-wrap {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 20px 18px;
	margin: 8px 0 10px;
}
.archive.category #archive-wrap > article.entry {
	float: none !important;
	width: auto !important;
	clear: none !important;
	margin: 0 !important;
	padding: 0 !important;
	position: relative;
	display: flex;
}
.archive.category #archive-wrap > article.mixedunit-big { grid-column: 1 / -1; }

/* the card */
.archive.category #archive-wrap .entry-grid {
	display: flex !important;
	flex-direction: column;
	width: 100%;
	max-width: none;
	margin: 0;
	padding: 0 !important;
	background: #fff;
	border-radius: 10px;
	overflow: hidden;
	border-top: 3px solid #c9a45c;
	box-shadow: 0 1px 3px rgba(31, 27, 22, .08), 0 8px 24px rgba(31, 27, 22, .08);
	transition: box-shadow .25s ease, transform .25s ease;
}
.archive.category #archive-wrap > article:hover .entry-grid,
.archive.category #archive-wrap > article:focus-within .entry-grid {
	transform: translateY(-3px);
	box-shadow: 0 2px 6px rgba(31, 27, 22, .10), 0 16px 36px rgba(31, 27, 22, .16);
}

/* image: a fixed shape so every card lines up */
.archive.category #archive-wrap .entry-featured-img-wrap {
	margin: 0 !important;
	padding: 0;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	background: #f6ede2;
}
/* the wide card: photo on the left, text on the right */
.archive.category #archive-wrap > article.mixedunit-big .entry-grid { flex-direction: row; }
.archive.category #archive-wrap > article.mixedunit-big .entry-featured-img-wrap { flex: 0 0 52%; aspect-ratio: 16 / 9; }
.archive.category #archive-wrap .entry-featured-img-wrap a,
.archive.category #archive-wrap .entry-featured-img-wrap img {
	display: block;
	width: 100% !important;
	height: 100% !important;
	max-width: none;
	margin: 0 !important;
	object-fit: cover;
	border: 0;
	border-radius: 0;
	box-shadow: none;
}
.archive.category #archive-wrap .entry-featured-img-wrap img { transition: transform .5s ease; }
.archive.category #archive-wrap > article:hover .entry-featured-img-wrap img { transform: scale(1.03); }

/* no photo: a copper panel with a gold diamond instead */
.archive.category #archive-wrap > article:not(.has-post-thumbnail) .entry-grid::before {
	content: "\25C6";
	display: flex;
	align-items: center;
	justify-content: center;
	aspect-ratio: 16 / 9;
	background: radial-gradient(circle at 50% 45%, rgba(201, 164, 92, .28), transparent 60%), linear-gradient(135deg, #94562a, #4a2814);
	color: #c9a45c;
	font-size: 1.4rem;
}
.archive.category #archive-wrap > article.mixedunit-big:not(.has-post-thumbnail) .entry-grid::before { flex: 0 0 52%; }

/* text */
.archive.category #archive-wrap .entry-grid-content {
	flex: 1;
	display: flex;
	flex-direction: column;
	float: none;
	width: auto;
	padding: 13px 15px 14px !important;
	text-align: left;
}
.archive.category #archive-wrap .entry-header { margin: 0; }
.archive.category #archive-wrap .entry-title {
	margin: 0;
	font-family: Lora, Georgia, serif;
	font-weight: 600;
	font-size: 1rem;
	line-height: 1.3;
	color: #1f1b16;
}
.archive.category #archive-wrap > article.mixedunit-big .entry-title { font-size: 1.3rem; }
.archive.category #archive-wrap > article.mixedunit-big .entry-grid-content { padding: 18px 20px !important; justify-content: center; }
.archive.category #archive-wrap .entry-title a { color: inherit; text-decoration: none; }
/* the whole card is the link */
.archive.category #archive-wrap .entry-title a::after {
	content: "";
	position: absolute;
	inset: 0;
	z-index: 1;
}
.archive.category #archive-wrap .entry-byline.empty { display: none; }
.archive.category #archive-wrap .entry-summary {
	flex: 1;
	display: flex;
	margin: 6px 0 0;
	font-size: .84rem;
	line-height: 1.5;
	color: #5b5249;
}
.archive.category #archive-wrap .entry-summary p {
	display: flex;
	flex-direction: column;
	margin: 0;
}
.archive.category #archive-wrap .more-link {
	display: block;
	margin-top: auto;
	padding-top: 9px;
}
.archive.category #archive-wrap .more-link a {
	position: relative;
	z-index: 2;
	display: inline-block;
	padding: 0;
	background: none !important;
	border: 0;
	font-size: .68rem;
	font-weight: 600;
	letter-spacing: .1em;
	text-transform: uppercase;
	color: #94562a !important;
}
.archive.category #archive-wrap .more-link a::after { content: " \2192"; }

/* pagination as copper pills */
.archive.category .pagination { margin: 26px 0 8px; text-align: center; }
.archive.category .pagination .nav-links { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; }
.archive.category .pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 40px;
	height: 40px;
	padding: 0 14px;
	margin: 0;
	border: 1.5px solid #e2cfb4;
	border-radius: 999px;
	background: #fff;
	color: #94562a;
	font-weight: 600;
	font-size: .9rem;
	text-decoration: none;
	transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.archive.category .pagination a.page-numbers:hover,
.archive.category .pagination a.page-numbers:focus-visible { background: #94562a; border-color: #94562a; color: #fff; }
.archive.category .pagination .page-numbers.current { background: #94562a; border-color: #94562a; color: #fff; }
.archive.category .pagination .page-numbers.dots { border: 0; background: none; min-width: 0; padding: 0 4px; }

/* sidebar: the section menu and the Explore menu (mu-plugins/category-cards.php) */
.jo-secmenu ul { list-style: none; margin: 0; padding: 0; border: 1px solid #ecdcc4; border-radius: 8px; background: #fff; overflow: hidden; }
.jo-secmenu li { margin: 0; padding: 0; border-top: 1px solid #f1e6d6; }
.jo-secmenu li:first-child { border-top: 0; }
.jo-secmenu a {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 10px;
	padding: 9px 12px;
	font-size: .9rem;
	line-height: 1.35;
	color: #3a332c;
	text-decoration: none;
	transition: background .2s ease, color .2s ease;
}
.jo-secmenu a::after { content: "\203A"; flex: none; font-size: 1.1rem; line-height: 1; color: #c9a45c; }
.jo-secmenu a:hover, .jo-secmenu a:focus-visible { background: #faf6f0; color: #94562a; }
.jo-secmenu a[aria-current] { background: #f6ede2; color: #94562a; font-weight: 600; }
.jo-secmenu a.jo-ext::after { content: "\2197"; font-size: .85rem; }
.jo-secmenu .jo-up a { font-size: .78rem; font-weight: 600; letter-spacing: .08em; text-transform: uppercase; color: #94562a; background: #faf6f0; }
.jo-secmenu .jo-up a::after { content: ""; }
.jo-secmenu .jo-up a::before { content: "\2039"; font-size: 1.1rem; line-height: 1; margin-right: -4px; }
.jo-secmenu .jo-up a { justify-content: flex-start; }

@media (max-width: 900px) {
	.archive.category #archive-wrap { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
	.archive.category #archive-wrap { grid-template-columns: 1fr; gap: 16px; }
	.archive.category #archive-wrap > article.mixedunit-big .entry-grid { flex-direction: column; }
	.archive.category #archive-wrap > article.mixedunit-big .entry-featured-img-wrap,
	.archive.category #archive-wrap > article.mixedunit-big:not(.has-post-thumbnail) .entry-grid::before { flex: none; }
	.archive.category #archive-wrap > article.mixedunit-big .entry-title { font-size: 1.12rem; }
	.archive.category #archive-wrap > article.mixedunit-big .entry-grid-content { padding: 13px 15px 14px !important; }
	.archive.category .loop-meta .archive-title { font-size: 1.75rem; }
}
@media (prefers-reduced-motion: reduce) {
	.archive.category #archive-wrap .entry-grid,
	.archive.category #archive-wrap .entry-featured-img-wrap img { transition: none; }
	.archive.category #archive-wrap > article:hover .entry-grid,
	.archive.category #archive-wrap > article:hover .entry-featured-img-wrap img { transform: none; }
}
