/**
 * 讲道信息页：筛选区 + 列表（参考 Sermons Overview 布局）
 */

.ccgc-sermons-page {
	background: #f4f4f4;
}

.ccgc-sermons {
	padding: 48px 0 72px;
}

.ccgc-sermons__header {
	margin-bottom: 28px;
}

.ccgc-sermons__crumb {
	margin: 0 0 12px;
	font-size: 13px;
	color: #777;
}

.ccgc-sermons__crumb a {
	color: #666;
	text-decoration: none;
}

.ccgc-sermons__crumb a:hover,
.ccgc-sermons__crumb a:focus {
	color: #222;
	text-decoration: underline;
}

.ccgc-sermons__title {
	margin: 0;
	font-size: clamp(2.25rem, 4vw, 3.25rem);
	font-weight: 700;
	line-height: 1.15;
	color: #111;
	font-family: "Noto Sans", "Noto Sans SC", sans-serif;
}

/* ---------- 筛选 ---------- */
.ccgc-sermons__filters {
	display: flex;
	flex-direction: column;
	gap: 12px;
	margin-bottom: 36px;
}

.ccgc-sermons__filters-row {
	display: grid;
	grid-template-columns: 1fr 1fr;
	gap: 12px;
}

.ccgc-sermons__filters-row--time {
	grid-template-columns: 1fr 1fr 1fr;
	max-width: 720px;
}

.ccgc-sermons__filters-row--scripture {
	grid-template-columns: 1.4fr 0.8fr 0.8fr auto;
	align-items: center;
}

.ccgc-sermons__filters input[type="search"],
.ccgc-sermons__filters input[type="text"],
.ccgc-sermons__filters select {
	width: 100%;
	height: 48px;
	padding: 0 14px;
	border: 1px solid #ddd;
	border-radius: 4px;
	background-color: #fff;
	color: #333;
	font-size: 15px;
	appearance: none;
	-webkit-appearance: none;
}

/* appearance:none 后用 SVG 补回下拉箭头 */
.ccgc-sermons__filters select {
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath fill='%23666' d='M1 1l5 5 5-5'/%3E%3C/svg%3E");
	background-repeat: no-repeat;
	background-position: right 14px center;
	background-size: 12px 8px;
	padding-right: 36px;
	cursor: pointer;
}

.ccgc-sermons__actions {
	display: flex;
	align-items: center;
	gap: 16px;
	justify-content: flex-end;
	white-space: nowrap;
}

.ccgc-sermons__clear {
	color: #555;
	font-size: 14px;
	text-decoration: none;
}

.ccgc-sermons__clear:hover,
.ccgc-sermons__clear:focus {
	color: #111;
	text-decoration: underline;
}

.ccgc-sermons__submit {
	min-width: 110px;
	height: 48px;
	padding: 0 22px;
	border: 0;
	border-radius: 999px;
	background: #3a3a3a;
	color: #fff;
	font-size: 15px;
	font-weight: 600;
	cursor: pointer;
}

.ccgc-sermons__submit:hover,
.ccgc-sermons__submit:focus {
	background: #222;
}

/* ---------- 结果列表 ---------- */
.ccgc-sermons__results {
	background: #fff;
	border-radius: 4px;
	padding: 28px 32px 8px;
}

.ccgc-sermons__status {
	margin: 0 0 8px;
	font-size: 13px;
	color: #888;
	letter-spacing: 0.02em;
}

.ccgc-sermons__list {
	list-style: none;
	margin: 0;
	padding: 0;
}

.ccgc-sermon-item {
	border-top: 1px solid #e8e8e8;
	margin: 0;
}

.ccgc-sermon-item:first-child {
	border-top: 0;
}

.ccgc-sermon-item__link {
	display: grid;
	grid-template-columns: 88px 1fr;
	gap: 20px;
	align-items: center;
	padding: 22px 0;
	color: inherit;
	text-decoration: none;
}

.ccgc-sermon-item__link:hover .ccgc-sermon-item__title,
.ccgc-sermon-item__link:focus .ccgc-sermon-item__title {
	text-decoration: underline;
}

.ccgc-sermon-item__thumb {
	position: relative;
	overflow: hidden;
}

.ccgc-sermon-item__thumb,
.ccgc-sermon-item__thumb img,
.ccgc-sermon-item__thumb-placeholder {
	width: 88px;
	height: 88px;
	border-radius: 8px;
	object-fit: cover;
	display: block;
}

.ccgc-sermon-item__thumb-placeholder {
	background: linear-gradient(145deg, #d8d8d8, #bdbdbd);
}

.ccgc-sermon-item__title {
	margin: 0 0 6px;
	font-size: 1.35rem;
	font-weight: 700;
	line-height: 1.3;
	color: #111;
}

.ccgc-sermon-item__meta {
	margin: 0;
	font-size: 14px;
	line-height: 1.5;
	color: #777;
}

.ccgc-sermon-item__meta--secondary {
	margin-top: 2px;
	font-size: 13px;
}

.ccgc-sermons__empty {
	padding: 32px 0 40px;
	color: #666;
}

/* 页底：跳转属灵资源 */
.ccgc-sermons__videos-cta {
	display: flex;
	justify-content: center;
	margin: 36px 0 8px;
	padding: 0 0 28px;
}

.ccgc-sermons__videos-btn.default-btn {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-width: 180px;
	text-align: center;
	text-transform: none;
	text-decoration: none;
}

.ccgc-sermons__pagination {
	padding: 16px 0 28px;
}

/* WP：ul 与页码 a/span 都带 .page-numbers，列表样式只绑 ul */
.ccgc-sermons__pagination ul.page-numbers {
	display: flex;
	flex-wrap: wrap;
	align-items: center;
	gap: 8px;
	list-style: none;
	margin: 0;
	padding: 0;
}

.ccgc-sermons__pagination ul.page-numbers > li {
	margin: 0;
	display: flex;
	align-items: center;
}

.ccgc-sermons__pagination a.page-numbers,
.ccgc-sermons__pagination span.page-numbers {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	box-sizing: border-box;
	min-width: 36px;
	height: 36px;
	padding: 0 12px;
	border-radius: 4px;
	color: #333;
	text-decoration: none;
	font-size: 14px;
	line-height: 1;
}

.ccgc-sermons__pagination span.dots {
	min-width: 0;
	height: auto;
	padding: 0 4px;
	color: #888;
}

.ccgc-sermons__pagination a.prev,
.ccgc-sermons__pagination a.next {
	min-width: auto;
	padding: 0 14px;
}

.ccgc-sermons__pagination .current {
	background: #3a3a3a;
	color: #fff;
}

.ccgc-sermon-single {
	background: #fff;
	border-radius: 4px;
	padding: 28px 32px 40px;
}

.ccgc-sermon-single__thumb {
	margin-bottom: 24px;
}

.ccgc-sermon-single__thumb img {
	width: 100%;
	height: auto;
	border-radius: 8px;
	display: block;
}

/* YouTube / 视频嵌入：16:9 响应式 */
.ccgc-sermon-video {
	margin: 0 0 28px;
}

.ccgc-sermon-video__frame {
	position: relative;
	width: 100%;
	aspect-ratio: 16 / 9;
	overflow: hidden;
	border-radius: 8px;
	background: #111;
}

.ccgc-sermon-video__frame iframe {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	border: 0;
	display: block;
}

.ccgc-sermon-video__link {
	margin: 0 0 24px;
}

.ccgc-sermon-video__link a {
	color: #1a5fb4;
	font-weight: 600;
	text-decoration: none;
}

.ccgc-sermon-video__link a:hover,
.ccgc-sermon-video__link a:focus {
	text-decoration: underline;
}

.ccgc-sermon-single__content {
	color: #333;
	line-height: 1.7;
}

/* 列表项：有视频时显示播放标记 */
.ccgc-sermon-item__play {
	position: absolute;
	inset: 0;
	display: flex;
	align-items: center;
	justify-content: center;
	background: rgba(0, 0, 0, 0.28);
	pointer-events: none;
}

.ccgc-sermon-item__play::before {
	content: "";
	width: 0;
	height: 0;
	border-style: solid;
	border-width: 8px 0 8px 14px;
	border-color: transparent transparent transparent #fff;
	margin-left: 2px;
}

.ccgc-sermon-item__link:hover .ccgc-sermon-item__play,
.ccgc-sermon-item__link:focus .ccgc-sermon-item__play {
	background: rgba(0, 0, 0, 0.4);
}

@media (max-width: 991px) {
	.ccgc-sermons__filters-row--scripture {
		grid-template-columns: 1fr 1fr;
	}

	.ccgc-sermons__actions {
		grid-column: 1 / -1;
		justify-content: flex-start;
	}
}

@media (max-width: 767px) {
	.ccgc-sermons {
		padding: 32px 0 48px;
	}

	.ccgc-sermons__filters-row,
	.ccgc-sermons__filters-row--time,
	.ccgc-sermons__filters-row--scripture {
		grid-template-columns: 1fr;
	}

	.ccgc-sermons__results {
		padding: 20px 16px 8px;
	}

	.ccgc-sermon-item__link {
		grid-template-columns: 64px 1fr;
		gap: 14px;
		padding: 16px 0;
	}

	.ccgc-sermon-item__thumb,
	.ccgc-sermon-item__thumb img,
	.ccgc-sermon-item__thumb-placeholder {
		width: 64px;
		height: 64px;
	}

	.ccgc-sermon-item__title {
		font-size: 1.1rem;
	}
}
