/* 160Foals Sale Lots: catalogue pages (/catalogue/foals/ and /catalogue/embryos/).
   Builds on lot-single.css (same variables, header, buttons and sale card). */

.f160-cat__switch {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 10px;
	margin: 0 0 clamp(20px, 3vw, 34px);
}

.f160-cat a.f160-cat__pill,
.f160-cat a.f160-cat__pill:visited {
	display: inline-block;
	padding: 10px 22px;
	border: 1px solid var(--f160-line);
	border-radius: 999px;
	font-size: 12px;
	font-weight: 500;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	text-decoration: none;
	color: var(--f160-muted);
	background: transparent;
	transition: border-color 0.2s, color 0.2s, background 0.2s;
}

.f160-cat a.f160-cat__pill:hover,
.f160-cat a.f160-cat__pill:focus-visible {
	border-color: var(--f160-gold);
	color: var(--f160-gold-soft);
}

.f160-cat a.f160-cat__pill[aria-current="page"] {
	border-color: var(--f160-gold);
	background: var(--f160-gold-btn);
	color: var(--f160-ink);
}

.f160-cat a.f160-cat__pill--live {
	border-color: rgba(201, 169, 97, 0.5);
	color: var(--f160-gold);
}

/* Grid */
.f160-cat__grid {
	display: grid;
	grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr));
	gap: 24px;
	margin-top: 0 !important;
}

.f160-cat__card {
	display: flex;
	flex-direction: column;
	overflow: hidden;
	border: 1px solid rgba(255, 255, 255, 0.08);
	border-radius: 24px;
	background: linear-gradient(180deg, #1B1714 0%, #141110 100%);
	transition: border-color 0.25s, transform 0.25s;
}

.f160-cat__card:hover {
	border-color: rgba(201, 169, 97, 0.45);
	transform: translateY(-2px);
}

.f160-cat__media {
	position: relative;
	display: block;
	aspect-ratio: 3 / 2;
	overflow: hidden;
	background: #161210;
}

.f160-cat .f160-cat__img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
	transition: transform 0.5s;
}

.f160-cat__card:hover .f160-cat__img {
	transform: scale(1.03);
}

.f160-cat .f160-cat__media .f160-lot__badge {
	left: 16px;
	bottom: 16px;
}

.f160-cat__body {
	position: relative;
	display: flex;
	flex: 1 1 auto;
	flex-direction: column;
	gap: 10px;
	padding: clamp(20px, 2.4vw, 28px);
}

.f160-cat .f160-cat__name {
	margin: 0;
	font-family: var(--f160-serif);
	font-style: italic;
	font-weight: 300;
	font-size: clamp(28px, 3vw, 36px);
	line-height: 1.1;
	color: var(--f160-gold-soft);
}

.f160-cat .f160-cat__name a,
.f160-cat .f160-cat__name a:visited {
	color: inherit;
	text-decoration: none;
}

.f160-cat__line {
	font-family: var(--f160-serif);
	font-style: italic;
	font-weight: 300;
	font-size: 17px;
	color: var(--f160-muted);
}

.f160-cat__line em {
	font-style: italic;
	color: var(--f160-gold-soft);
}

.f160-cat__line--dam {
	font-size: 15px;
	color: rgba(250, 248, 244, 0.6);
}

.f160-cat .f160-cat__stats {
	display: flex;
	flex-direction: column;
	gap: 6px;
	margin: 4px 0 0;
	padding: 12px 0 0;
	border-top: 1px solid var(--f160-line);
	list-style: none;
	font-size: 14px;
	color: var(--f160-muted);
}

.f160-cat__stats strong {
	font-family: var(--f160-serif);
	font-size: 22px;
	font-weight: 300;
	color: var(--f160-gold-soft);
}

.f160-cat__stats small {
	font-size: 12px;
	color: rgba(250, 248, 244, 0.5);
}

.f160-cat__tag {
	display: inline-block;
	min-width: 46px;
	margin-right: 4px;
	padding: 3px 9px;
	border: 1px solid var(--f160-gold);
	border-radius: 999px;
	font-size: 10px;
	font-weight: 500;
	letter-spacing: 0.18em;
	text-align: center;
	color: var(--f160-gold);
}

.f160-cat__lead {
	display: -webkit-box;
	overflow: hidden;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 4;
	font-size: 14px;
	line-height: 1.55;
	color: rgba(250, 248, 244, 0.66);
}

.f160-cat a.f160-cat__more,
.f160-cat a.f160-cat__more:visited {
	margin-top: auto;
	padding-top: 6px;
	font-size: 12px;
	font-weight: 500;
	letter-spacing: 0.2em;
	text-transform: uppercase;
	text-decoration: none;
	color: var(--f160-gold);
}

.f160-cat a.f160-cat__more:hover,
.f160-cat a.f160-cat__more:focus-visible {
	color: var(--f160-gold-soft);
}

/* Embryo card with a photo: same picture block as a foal card, but not a link (embryos have no page). */
.f160-cat__card--photo:hover .f160-cat__img {
	transform: none;
}

.f160-cat__card--photo .f160-cat__body {
	z-index: 1;
}

/* Embryo cards without a photo: a large outlined lot number carries the card. */
.f160-cat__card--embryo {
	min-height: 100%;
}

.f160-cat__lotno {
	position: absolute;
	top: -18px;
	right: 14px;
	z-index: 0;
	font-family: var(--f160-serif);
	font-weight: 300;
	font-size: 150px;
	line-height: 1;
	color: transparent;
	-webkit-text-stroke: 1px rgba(201, 169, 97, 0.22);
	pointer-events: none;
	user-select: none;
}

.f160-cat__card--embryo {
	position: relative;
	background:
		radial-gradient(260px 200px at 100% 0%, rgba(201, 169, 97, 0.10), transparent 70%),
		linear-gradient(180deg, #1B1714 0%, #141110 100%);
}

.f160-cat__card--embryo .f160-cat__body {
	z-index: 1;
}

.f160-cat .f160-cat__name--dam {
	font-size: clamp(26px, 2.6vw, 32px);
}

.f160-cat__empty {
	padding: 48px 0;
	text-align: center;
	color: var(--f160-muted);
}

@media (max-width: 640px) {
	.f160-cat__grid {
		gap: 18px;
	}

	.f160-cat__lotno {
		font-size: 120px;
	}
}

@media (prefers-reduced-motion: reduce) {
	.f160-cat__card,
	.f160-cat .f160-cat__img {
		transition: none;
	}
}

/* A card that shows the sire's photo (the dam has none yet) says so. */
.f160-cat .f160-cat__who {
	position: absolute;
	top: 16px;
	left: 16px;
	max-width: calc(100% - 32px);
	padding: 6px 14px;
	border: 1px solid var(--f160-gold);
	border-radius: 999px;
	background: rgba(22, 18, 16, 0.82);
	font-size: 10px;
	font-weight: 500;
	letter-spacing: 0.22em;
	text-transform: uppercase;
	color: var(--f160-gold);
}
