/**
 * Posts em destaque — Page Builder
 * CSS mínimo: progress bar das tabs, pagination pill, pré-init Swiper, fade da imagem principal.
 */

@keyframes cortex-pb-posts-em-destaque-progress {
	from {
		width: 0;
	}
	to {
		width: 100%;
	}
}

.cortex-pb-posts-em-destaque__tab.is-active {
	background-color: #f0f4f8;
}

.cortex-pb-posts-em-destaque__tab:hover:not(.is-active) {
	background-color: #f9fafb;
}

.cortex-pb-posts-em-destaque__tab.is-active .cortex-pb-posts-em-destaque__tab-progress {
	animation: cortex-pb-posts-em-destaque-progress var(--tab-duration, 5s) linear forwards;
}

.cortex-pb-posts-em-destaque__main-img {
	transition: opacity 0.35s ease;
}

.cortex-pb-posts-em-destaque__main-media,
.cortex-pb-posts-em-destaque__main-img {
	width: 100%;
	height: 100%;
}

.cortex-pb-posts-em-destaque__main-overlay {
	background: linear-gradient(
		to top,
		rgba(0, 0, 0, 0.92) 0%,
		rgba(0, 0, 0, 0.65) 55%,
		rgba(0, 0, 0, 0.3) 100%
	);
}

/* Pré-init Swiper mobile */
.cortex-pb-posts-em-destaque__swiper:not(.swiper-initialized) {
	overflow: hidden;
}

.cortex-pb-posts-em-destaque__swiper:not(.swiper-initialized) .swiper-wrapper {
	display: flex;
	flex-direction: row;
}

.cortex-pb-posts-em-destaque__swiper:not(.swiper-initialized) .swiper-slide {
	flex: 0 0 86.956%;
	width: 86.956%;
	margin-right: 16px;
}

/* Remove setas padrão do Swiper */
.cortex-pb-posts-em-destaque__swiper .swiper-button-prev::after,
.cortex-pb-posts-em-destaque__swiper .swiper-button-next::after {
	display: none;
}

.cortex-pb-posts-em-destaque__swiper .swiper-button-prev,
.cortex-pb-posts-em-destaque__swiper .swiper-button-next {
	position: static;
	margin: 0;
	transform: none;
}

.cortex-pb-posts-em-destaque__pagination.swiper-pagination {
	position: static !important;
	width: auto !important;
	display: flex !important;
	align-items: center;
	justify-content: center;
	gap: 6px;
}

.cortex-pb-posts-em-destaque__pagination .cortex-pb-posts-em-destaque__dot {
	display: block;
	flex-shrink: 0;
	width: 8px;
	height: 8px;
	border-radius: 40px;
	background: #d0d5dd;
	opacity: 1;
	cursor: pointer;
	padding: 0;
	margin: 0;
	border: none;
	transition: width 0.3s ease, background 0.3s ease;
}

.cortex-pb-posts-em-destaque__pagination .cortex-pb-posts-em-destaque__dot.is-active {
	width: 22px;
	background: var(--cortex-primary, #ff6b00);
}
