/*
Theme Name:   Avada Child – CATIE Center
Description:  Child theme for noviceinterpreters.org. Holds custom templates (GTC Resource Library results) so they survive Avada updates.
Author:       CATIE Center, St. Catherine University
Template:     Avada
Version:      1.0.1
Text Domain:  Avada
*/

/* ---------- GTC Resource Library results (search-filter/results.php) ---------- */

.gtc-results__count {
	margin: 0 0 16px;
	font-size: 15px;
	color: #4f4c4d;
}
.gtc-results__count strong { color: #231f20; }

.gtc-results__list {
	display: flex;
	flex-direction: column;
	gap: 16px;
	margin: 0 0 24px;
	padding: 0;
	list-style: none;
}

.gtc-result {
	position: relative;
	display: flex;
	gap: 20px;
	align-items: flex-start;
	margin: 0;
	padding: 20px;
	background: #fff;
	border: 1px solid #e7e4e2;
	border-radius: 12px;
}
.gtc-result:hover { box-shadow: 0 6px 18px rgba(71, 35, 128, .12); }
.gtc-result:focus-within { outline: 3px solid #502d7f; outline-offset: 2px; }

.gtc-result__thumb {
	flex: 0 0 160px;
	width: 160px;
	aspect-ratio: 4 / 3;
	border-radius: 8px;
	overflow: hidden;
	background: #efebf4;
}
.gtc-result__thumb img {
	display: block;
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.gtc-result__body { flex: 1 1 auto; min-width: 0; }

.gtc-result__title {
	margin: 0 0 8px !important;
	font-size: 20px !important;
	line-height: 1.3 !important;
}
.gtc-result__title a {
	color: #472380;
	text-decoration: none;
}
/* Whole card is clickable; the title link stays the one real link. */
.gtc-result__title a::after {
	content: "";
	position: absolute;
	inset: 0;
	border-radius: 12px;
}
.gtc-result__title a:focus-visible { outline: none; }

.gtc-result__meta {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 0 0 10px;
	padding: 0;
	list-style: none;
}
.gtc-result__meta li {
	margin: 0;
	padding: 2px 10px;
	border-radius: 999px;
	font-size: 13px;
	line-height: 1.6;
	color: #231f20;
	background: #e7e4e2;
}
.gtc-result__meta li.is-audience { background: #efebf4; }
.gtc-result__meta li.is-language { background: #e9f0f6; }
.gtc-result__meta li.is-time     { background: #f4f5e0; }
.gtc-result__meta .gtc-sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

.gtc-result__excerpt {
	margin: 0;
	font-size: 15px;
	line-height: 1.55;
	color: #4f4c4d;
}

.gtc-results__empty {
	padding: 24px;
	background: #fdf8dc;
	border-left: 5px solid #7a6855;
	border-radius: 8px;
}
.gtc-results__empty p { margin: 0; }

/* Numbered pagination (class "pagination" kept so Search & Filter's AJAX picks up the links) */
.gtc-results .pagination {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin: 8px 0 0;
}
.gtc-results .pagination .page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 44px;
	min-height: 44px;
	padding: 0 12px;
	border: 2px solid #502d7f;
	border-radius: 999px;
	color: #502d7f;
	font-weight: 700;
	text-decoration: none;
	box-sizing: border-box;
}
.gtc-results .pagination .page-numbers.current {
	background: #502d7f;
	color: #fff;
}
.gtc-results .pagination .page-numbers.dots {
	border-color: transparent;
	min-width: 24px;
}

@media (max-width: 640px) {
	.gtc-result { flex-direction: column; padding: 16px; }
	.gtc-result__thumb { flex-basis: auto; width: 100%; }
}
