/**
 * Dropdown de secções de notícias (listagem + homepage).
 */

.fcf-news-filter {
	position: relative;
	z-index: 2;
	width: 100%;
}

.fcf-news-filter__trigger {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 16px;
	width: 100%;
	min-height: 48px;
	padding: 12px 18px;
	border: 1px solid rgba(255, 255, 255, 0.72);
	border-radius: 0;
	background: transparent;
	color: #fff;
	font-family: var(--fcf-font-display, "korolev-compressed", sans-serif);
	font-size: 0.9375rem;
	font-weight: 500;
	letter-spacing: 0.05em;
	line-height: 1.2;
	text-align: left;
	text-transform: uppercase;
	cursor: pointer;
	transition: border-color 0.2s ease, background 0.2s ease;
}

.fcf-news-filter__trigger:hover,
.fcf-news-filter__trigger:focus-visible {
	border-color: #edca57;
	outline: none;
}

.fcf-news-filter.is-open .fcf-news-filter__trigger {
	border-color: #edca57;
	background: rgba(255, 255, 255, 0.04);
}

.fcf-news-filter__label {
	flex: 1 1 auto;
	min-width: 0;
	font-weight: 700;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.fcf-news-filter__chevron {
	flex: 0 0 auto;
	width: 10px;
	height: 10px;
	border-right: 1.5px solid currentColor;
	border-bottom: 1.5px solid currentColor;
	transform: rotate(45deg) translateY(-2px);
	transition: transform 0.25s cubic-bezier(0.22, 1, 0.36, 1);
}

.fcf-news-filter.is-open .fcf-news-filter__chevron {
	transform: rotate(225deg) translateY(2px);
}

.fcf-news-filter__panel {
	position: absolute;
	top: calc(100% + 8px);
	left: 0;
	right: 0;
	z-index: 50;
	overflow: hidden;
	border: 1px solid rgba(255, 255, 255, 0.28);
	background: linear-gradient(180deg, rgba(24, 62, 103, 0.98) 0%, rgba(18, 51, 87, 0.98) 100%);
	box-shadow: 0 20px 48px rgba(5, 30, 51, 0.42);
	backdrop-filter: blur(10px);
}

.fcf-news-filter__panel[hidden] {
	display: none;
}

.fcf-news-filter.is-open .fcf-news-filter__panel {
	animation: fcf-news-filter-panel-in 0.28s cubic-bezier(0.22, 1, 0.36, 1) both;
}

@keyframes fcf-news-filter-panel-in {
	from {
		opacity: 0;
		transform: translate3d(0, -8px, 0);
	}

	to {
		opacity: 1;
		transform: translate3d(0, 0, 0);
	}
}

.fcf-news-filter__list {
	max-height: min(420px, 58vh);
	margin: 0;
	padding: 8px 0;
	overflow-y: auto;
	list-style: none;
}

.fcf-news-filter__item {
	margin: 0;
	padding: 0;
}

.fcf-news-filter__option {
	display: block;
	box-sizing: border-box;
	width: 100%;
	margin: 0;
	padding: 11px 18px;
	border: 0;
	border-radius: 0;
	background: transparent;
	color: rgba(255, 255, 255, 0.86);
	font-family: var(--fcf-font-display, "korolev-compressed", sans-serif);
	font-size: 0.875rem;
	font-weight: 500;
	letter-spacing: 0.05em;
	line-height: 1.2;
	text-align: left;
	text-decoration: none;
	text-transform: uppercase;
	cursor: pointer;
	transition: color 0.2s ease, background 0.2s ease;
}

.fcf-news-filter__option::before {
	content: "";
	display: inline-block;
	width: 1.1em;
	margin-right: 0.35em;
}

.fcf-news-filter__option.is-selected {
	color: #edca57;
}

.fcf-news-filter__option.is-selected::before {
	content: "✓";
	width: auto;
	margin-right: 0.5em;
}

.fcf-news-filter__option:hover,
.fcf-news-filter__option:focus-visible {
	background: rgba(255, 255, 255, 0.08);
	color: #fff;
	outline: none;
}

.fcf-news-filter__option.is-selected:hover,
.fcf-news-filter__option.is-selected:focus-visible {
	color: #edca57;
}

.fd-latest-news__picker .fcf-news-filter {
	min-width: 0;
}

@media (max-width: 689.98px) {
	.fcf-news-filter__trigger {
		min-height: 44px;
		padding: 10px 12px;
		gap: 10px;
		font-size: 0.8125rem;
	}
}

@media (prefers-reduced-motion: reduce) {
	.fcf-news-filter.is-open .fcf-news-filter__panel {
		animation: none;
	}
}
