/* ============================================================
   Programs Filter — Main Stylesheet
   ============================================================ */

/* Visually hidden — accessible to screen readers */
.pf-sr-only {
	position: absolute;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

/* Wrap */
.pf-wrap {
	max-width: 1200px;
	margin: 0 auto;
	font-family: inherit;
}

/* ── Filter Box ─────────────────────────────────────────── */
.pf-filter-box {
	background: #fff;
	border-radius: 4px;
	box-shadow: 0 8px 32px rgba(0, 0, 0, 0.22), 0 2px 8px rgba(0, 0, 0, 0.12);
	padding: 32px 36px 24px;
	margin-bottom: 56px;
	background: #071d49;
}

.pf-filter-title {
	font-size: 1.25rem;
	font-weight: 700;
	color: #fff;
	margin: 0 0 20px;
}

/* Dropdowns row */
.pf-filter-dropdowns {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 16px;
	margin-bottom: 16px;
}

.pf-filter-label {
	display: block;
	font-size: 0.6875rem;
	font-weight: 700;
	letter-spacing: 0.08em;
	text-transform: uppercase;
	color: #a0b4cc;
	margin-bottom: 6px;
}

.pf-select-wrap {
	position: relative;
}

.pf-select-wrap::after {
	content: '';
	position: absolute;
	right: 14px;
	top: 50%;
	transform: translateY(-50%);
	width: 0;
	height: 0;
	border-left: 5px solid transparent;
	border-right: 5px solid transparent;
	border-top: 6px solid #6b7280;
	pointer-events: none;
}

.pf-select-wrap select {
	width: 100%;
	appearance: none;
	-webkit-appearance: none;
	background: #fff;
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 4px;
	padding: 10px 36px 10px 14px;
	font-size: 0.9375rem;
	color: #1a1f36;
	cursor: pointer;
	outline: none;
	transition: border-color 0.15s;
}

.pf-select-wrap select:focus {
	border-color: rgba(255, 255, 255, 0.4);
}

/* Search */
.pf-filter-search {
	position: relative;
	margin-bottom: 14px;
}

.pf-search-icon {
	position: absolute;
	left: 14px;
	top: 50%;
	transform: translateY(-50%);
	color: #9ca3af;
	display: flex;
	align-items: center;
}

#pf-search {
	width: 100%;
	background: #fff;
	border: 1px solid rgba(255, 255, 255, 0.15);
	border-radius: 4px;
	padding: 10px 14px 10px 42px;
	font-size: 0.9375rem;
	color: #1a1f36;
	outline: none;
	transition: border-color 0.15s;
	box-sizing: border-box;
}

#pf-search:focus {
	border-color: rgba(255, 255, 255, 0.4);
}

#pf-search::placeholder {
	color: #9ca3af;
}

#pf-search::placeholder {
	color: #9ca3af;
}

/* Visible count */
.pf-visible-count {
	font-size: 0.875rem;
	color: #a0b4cc;
	margin: 0;
}

/* ── Sections ────────────────────────────────────────────── */
.pf-section {
	margin-bottom: 60px;
}

.pf-section--hidden {
	display: none;
}

.pf-section__header {
	margin-bottom: 28px;
}

.pf-section__title {
	font-size: 1.625rem;
	font-weight: 700;
	color: #071d49;
	margin: 0;
	line-height: 1.2;
}

.pf-section__subtitle {
	font-size: 0.875rem;
	color: #6b7280;
	margin: 0;
}

.pf-section__count {
	display: inline-block;
	background: #f3f4f6;
	border-radius: 20px;
	padding: 4px 14px;
	font-size: 0.8125rem;
	font-weight: 700;
	color: #4b5563;
	white-space: nowrap;
	margin: 8px 0;
}

/* ── Card Grid ───────────────────────────────────────────── */
.pf-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	column-gap: 16px;
	row-gap: 16px;
}

/* ── Cards ───────────────────────────────────────────────── */
.pf-card {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	padding: 20px 24px;
	text-decoration: none;
	color: inherit;
	transition: box-shadow 0.15s;
}

/* Override theme resets on <a> elements */
#programs-filter .pf-card {
	border: 1px solid #e5e7eb !important;
	border-radius: 20px !important;
}

#programs-filter .pf-card:hover {
	text-decoration: none !important;
	box-shadow: 0 2px 12px rgba(0, 0, 0, 0.08);
}

#programs-filter .pf-card:hover .pf-card__title {
	color: #ce202f !important;
}

.pf-card__body {
	flex: 1;
	min-width: 0;
}

.pf-card__title {
	font-weight: 700;
	color: #071d49;
	line-height: 1.35;
	margin-bottom: 3px;
	transition: color 0.15s;
}

#programs-filter .pf-card__title {
	font-size: 1.2rem !important;
}

.pf-card__degree {
	font-size: 0.8125rem;
	color: #6b7280;
	margin-bottom: 8px;
	line-height: 1.3;
}

.pf-card__badges {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
}

.pf-badge {
	display: inline-block;
	font-size: 0.75rem;
	color: #374151;
	background: #f3f4f6;
	border: 1px solid #e5e7eb;
	border-radius: 3px;
	padding: 2px 8px;
	line-height: 1.5;
}

.pf-card__areas {
	display: flex;
	flex-wrap: wrap;
	gap: 6px;
	margin-top: 8px;
}

.pf-pill {
	display: inline-block;
	font-size: 0.75rem;
	font-weight: 700;
	border-radius: 999px;
	padding: 3px 10px;
	line-height: 1.5;
}

.pf-pill--default {
	background: #f3f4f6;
	color: #374151;
	border: 1px solid #e5e7eb;
}

.pf-card__chevron {
	flex-shrink: 0;
	font-size: 1.25rem;
	color: #9ca3af;
	line-height: 1;
}

/* ── No Results ──────────────────────────────────────────── */
.pf-no-results {
	text-align: center;
	color: #6b7280;
	padding: 40px 0;
	font-size: 1rem;
}

/* ── Loading state ───────────────────────────────────────── */
.pf-wrap.is-loading #pf-results {
	opacity: 0.5;
	pointer-events: none;
	transition: opacity 0.2s;
}

/* ── Responsive ──────────────────────────────────────────── */
@media ( max-width: 900px ) {
	.pf-grid {
		grid-template-columns: repeat(2, 1fr);
		column-gap: 32px;
	}

	.pf-filter-dropdowns {
		grid-template-columns: 1fr;
	}

	.pf-filter-box {
		padding: 28px 24px 20px;
	}
}

@media ( max-width: 600px ) {
	.pf-wrap {
		padding: 0 16px;
	}

	.pf-filter-box {
		padding: 24px 20px 20px;
	}

	.pf-grid {
		grid-template-columns: 1fr;
	}
}
