/**
 * Styles for the free Textures & Overlays page
 *
 * @copyright   2026, ON1
 */

/* !- Page navigation */
#page-navigation {
	background: var(--bg-800);
}

#page-navigation .nav-item {
	margin: 0 0.75rem 0 0;
}

#page-navigation .nav-item:last-child {
	margin-right: 0;
}

#page-navigation .nav-link {
	border-bottom: 3px solid transparent;
	color: var(--text-300);
	font-size: var(--text-xs);
	font-weight: 500;
	padding: 1rem 0.75rem;
}

#page-navigation .nav-link.active,
#page-navigation .nav-link:hover {
	border-color: var(--blue-500);
	color: var(--text-100);
}

/* !- Hero */
#hero {
	align-items: center;
	/* Subject sits right of center - keep her face in frame when cover crops the sides on narrow screens */
	background-image: image-set(url(https://ononesoft.cachefly.net/images/free/textures/hero--textures.jpg) 1x, url(https://ononesoft.cachefly.net/images/free/textures/hero--textures@2x.jpg) 2x);
	background-position: 62% center;
	background-repeat: no-repeat;
	background-size: cover;
	/* Re-resolve the color inherited from body against this section's pinned-dark tokens */
	color: var(--text-200);
	display: flex;
	min-height: 420px;
	padding: 4rem 0;
	position: relative;
}

/* Scrim so the copy stays legible over the photo */
#hero::before {
	background: linear-gradient(to bottom, rgba(0, 0, 0, 0.62) 0%, rgba(0, 0, 0, 0.56) 100%);
	content: "";
	inset: 0;
	pointer-events: none;
	position: absolute;
	z-index: 1;
}

#hero .container {
	position: relative;
	width: 100%;
	z-index: 2;
}

#hero .breadcrumb {
	color: var(--text-200);
	font-size: var(--text-mini);
}

#hero .breadcrumb .separator {
	margin: 0 0.25rem;
}

#hero .breadcrumb a {
	color: var(--text-200);
	text-decoration: none;
}

#hero .breadcrumb a:hover {
	color: var(--text-50);
	text-decoration: underline;
}

#hero .breadcrumb .here {
	color: var(--text-50);
}

#hero .list-inline,
#hero .list-inline-item {
	margin-bottom: 0;
}

#hero .works-with {
	margin-bottom: 2rem;
}

#hero .works-with .rounded-pill {
	background: var(--bg-800);
	border: 1px solid var(--bg-700);
	color: var(--text-200);
	font-size: var(--text-micro);
	font-weight: 500;
	padding: 0.375rem 0.75rem;
}

#hero .btn {
	padding: 0.9375rem 1.875rem;
}

#hero .hero-note {
	color: var(--text-200);
	font-size: var(--text-mini);
	margin-left: 0.75rem;
}

@media (min-width: 992px) {
	/* 2.5:1 by width, but a floor rather than aspect-ratio - an explicit min-height
	   stops an aspect-ratio box from growing, and the copy can outgrow it at lg */
	#hero {
		min-height: max(420px, 40vw);
		padding: 5rem 0;
	}

	/* Copy is left-aligned on wide screens, so weight the scrim left and let the subject on the right breathe */
	#hero::before {
		background: linear-gradient(to right, rgba(0, 0, 0, 0.62) 0%, rgba(0, 0, 0, 0.56) 45%, rgba(0, 0, 0, 0.3) 68%, rgba(0, 0, 0, 0.08) 88%, rgba(0, 0, 0, 0) 100%);
	}
}

/* 2.5:1 runs to 800px tall on a 2000px window - hold the height it reaches at 1400 */
@media (min-width: 1400px) {
	#hero {
		min-height: 560px;
	}
}

/* !- Texture packs */
#textures .filter-pills {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	margin-bottom: 1.5rem;
}

#textures .filter-pill {
	background: var(--bg-800);
	border: none;
	border-radius: 50rem;
	color: var(--text-300);
	cursor: pointer;
	font-size: var(--text-mini);
	font-weight: 500;
	padding: 0.375rem 0.9375rem;
}

#textures .filter-pill.active {
	background: var(--blue-500);
	color: var(--white);
	font-weight: 600;
}

#textures .filter-pill:hover {
	color: var(--text-100);
}

#textures .filter-pill.active:hover {
	color: var(--white);
}

#textures #textureGrid>.col {
	display: flex;
}

#textures .texture-card {
	background: var(--bg-800);
	border-radius: var(--border-radius);
	display: flex;
	flex: 1;
	flex-direction: column;
}

/* The count badge sits over the pack shot, so the media box anchors it */
#textures .texture-media {
	position: relative;
}

#textures .texture-media img {
	border-top-left-radius: var(--border-radius);
	border-top-right-radius: var(--border-radius);
}

#textures .texture-count {
	background: rgba(0, 0, 0, 0.55);
	border-radius: var(--border-radius);
	color: var(--white);
	font-size: var(--text-micro);
	font-weight: 700;
	left: 0.75rem;
	letter-spacing: 0.06em;
	margin-bottom: 0;
	padding: 0.25rem 0.5rem;
	position: absolute;
	text-transform: uppercase;
	top: 0.75rem;
}

#textures .texture-wrap {
	display: flex;
	flex: 1;
	flex-direction: column;
	gap: 0.5rem;
	padding: 1.5rem;
}

#textures .texture-name {
	color: var(--text-100);
	font-size: var(--text-lg);
	font-weight: 700;
	line-height: 1.5;
	margin-bottom: 0;
}

#textures .texture-desc {
	color: var(--text-500);
	flex: 1;
	font-size: var(--text-xs);
	line-height: 1.5;
	margin-bottom: 0.75rem;
}

#textures .texture-actions .btn {
	font-size: var(--text-xs);
	font-weight: 600;
	padding: 0.75rem;
	width: 100%;
}

/* !- How to use */
#how-to {
	background: var(--bg-800);
}

#how-to .section-intro {
	margin-bottom: 1.75rem;
}

#how-to .num-list {
	counter-reset: num;
	display: flex;
	flex-direction: column;
	gap: 0.75rem;
}

#how-to .num-item {
	align-items: center;
	background: var(--bg-900);
	border-radius: var(--border-radius);
	counter-increment: num;
	display: flex;
	font-size: var(--text-sm);
	line-height: 1.5;
	margin-bottom: 0;
	padding: 1rem 1.5rem;
}

#how-to .num-item::before {
	align-items: center;
	background: var(--blue-500);
	border-radius: 50%;
	color: var(--white);
	content: counter(num);
	display: flex;
	flex-shrink: 0;
	font-size: var(--text-sm);
	font-weight: 700;
	height: 2rem;
	justify-content: center;
	margin-right: 0.75rem;
	width: 2rem;
}

#how-to .how-to-note {
	font-size: var(--text-sm);
	margin: 1.25rem 0 0 0;
}
