/* EasyPaper Art hub and collection listings. Tokens from BUILD-SPEC §2.2. */

.ep-listing {
	--ep-ink: #14213d;
	--ep-red: #d1301f;
	--ep-yellow: #ffc532;
	--ep-blue: #2b59c3;
	--ep-ground: #f3f6fc;
	--ep-line: #d9e1f0;
	--ep-muted: #4a5670;
	color: var(--ep-ink);
	margin-block: 2rem;
}

.ep-section {
	margin-block: 2.5rem;
}

.ep-section h2 {
	margin-bottom: 1rem;
}

.ep-grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
	gap: 1rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

/* One folded corner: the paper motif. */
.ep-card {
	position: relative;
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	padding: 1rem;
	background: #fff;
	border: 1px solid var(--ep-line);
	border-radius: 20px;
	clip-path: polygon(0 0, calc(100% - 28px) 0, 100% 28px, 100% 100%, 0 100%);
}

.ep-card::after {
	content: "";
	position: absolute;
	top: 0;
	right: 0;
	width: 28px;
	height: 28px;
	background: var(--ep-yellow);
	border-bottom-left-radius: 8px;
}

.ep-card__link {
	display: flex;
	flex-direction: column;
	gap: 0.5rem;
	color: inherit;
	text-decoration: none;
	min-height: 44px;
}

.ep-card__link:hover .ep-card__title,
.ep-card__link:focus-visible .ep-card__title {
	color: var(--ep-blue);
	text-decoration: underline;
}

.ep-card__link img {
	width: 100%;
	height: auto;
	border-radius: 12px;
}

.ep-card__title {
	font-weight: 700;
	font-size: 1.05rem;
}

.ep-card__meta {
	margin: 0;
	color: var(--ep-muted);
	font-size: 0.9rem;
}

/* Level pills always carry text, never colour alone. */
.ep-level {
	align-self: flex-start;
	padding: 0.15rem 0.6rem;
	border-radius: 999px;
	font-size: 0.8rem;
	font-weight: 700;
}

.ep-level--easy {
	background: #e3f5ec;
	color: #11643f;
}

.ep-level--medium {
	background: #fff1cc;
	color: #7a5300;
}

.ep-level--tricky {
	background: #fde3e0;
	color: #9b2317;
}

.ep-links {
	display: flex;
	flex-wrap: wrap;
	gap: 0.5rem 1rem;
	list-style: none;
	margin: 0;
	padding: 0;
}

.ep-links a,
.ep-backlink a {
	color: var(--ep-blue);
}

.ep-empty {
	color: var(--ep-muted);
}

/* Model Credits page: lesson names in columns */
.ep-credits {
	columns: 4 160px;
	column-gap: 28px;
	padding-left: 18px;
}

.ep-credits li {
	break-inside: avoid;
	margin-bottom: 4px;
}


/* Learn hub: guides in groups */
.ep-guidegroup h2 {
	margin-bottom: 0.25rem;
}

.ep-guidegroup__blurb {
	margin: 0 0 1rem;
	color: var(--ep-muted);
}

.ep-guidegroup .ep-card__title {
	padding-right: 1.5rem;
}
