/**
 * HeroGate-CSMM: página pública de Em breve e Manutenção.
 *
 * Tudo vem das variáveis --herogate-* impressas pela página. Os seletores
 * levam .herogate-body para ganhar do CSS do tema quando o wp_head está ligado.
 */

/* ------------------------------------------------------------------
 * Base
 * ---------------------------------------------------------------- */
html.herogate-html,
body.herogate-body {
	margin: 0;
	padding: 0;
	min-height: 100%;
}

.herogate-body,
.herogate-body *,
.herogate-body *::before,
.herogate-body *::after {
	box-sizing: border-box;
}

body.herogate-body {
	position: relative;
	min-height: 100vh;
	min-height: 100dvh;
	overflow-x: hidden;
	background: var(--herogate-bg-color, #0b1020);
	color: var(--herogate-text, #d6def5);
	font-family: var(--herogate-font, system-ui, sans-serif);
	font-size: var(--herogate-base, 18px);
	line-height: 1.6;
	-webkit-font-smoothing: antialiased;
	text-rendering: optimizeLegibility;
}

[hidden] {
	display: none !important;
}

/* ------------------------------------------------------------------
 * Fundo
 * ---------------------------------------------------------------- */
.herogate-bg {
	position: fixed;
	inset: 0;
	z-index: 0;
	overflow: hidden;
	background: var(--herogate-bg-color, #0b1020);
	will-change: transform;
}

.herogate-bg--gradient {
	background: linear-gradient(var(--herogate-grad-angle, 135deg), var(--herogate-grad-from, #0b1020), var(--herogate-grad-to, #1e3a8a));
}

.herogate-bg--animated {
	background-size: 300% 300%;
	animation: herogate-gradient 18s ease-in-out infinite;
}

.herogate-bg--parallax {
	inset: -40px;
}

.herogate-bg__layer {
	position: absolute;
	inset: 0;
	background-size: var(--herogate-bg-size, cover);
	background-position: var(--herogate-bg-position, center center);
	background-repeat: no-repeat;
	filter: blur(var(--herogate-bg-blur, 0));
}

/* O desfoque "vaza" nas bordas; o zoom leve esconde a moldura clara. */
.herogate-bg__layer[style] {
	transform: scale(1.04);
}

.herogate-bg__slide {
	opacity: 0;
	transition: opacity 1.4s ease;
}

.herogate-bg__slide.is-active {
	opacity: 1;
}

.herogate-bg--kenburns .herogate-bg__slide.is-active {
	animation: herogate-kenburns 24s ease-out both;
}

.herogate-bg__video {
	width: 100%;
	height: 100%;
	object-fit: cover;
}

.herogate-overlay {
	position: fixed;
	inset: 0;
	z-index: 1;
	background: var(--herogate-overlay, transparent);
	pointer-events: none;
}

.herogate-grain {
	position: fixed;
	inset: -50%;
	z-index: 1;
	pointer-events: none;
	opacity: 0.09;
	background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
	animation: herogate-grain 1.2s steps(6) infinite;
}

.herogate-particles {
	position: fixed;
	inset: 0;
	width: 100%;
	height: 100%;
	pointer-events: none;
}

.herogate-particles--back {
	z-index: 2;
}

.herogate-particles--front {
	z-index: 4;
}

/* ------------------------------------------------------------------
 * Layout
 * ---------------------------------------------------------------- */
.herogate-main {
	position: relative;
	z-index: 3;
	display: flex;
	align-items: center;
	justify-content: center;
	min-height: 100vh;
	min-height: 100dvh;
	padding: clamp(16px, 5vw, 64px) clamp(16px, 4vw, 48px);
}

.herogate-pos-top .herogate-main {
	align-items: flex-start;
}

.herogate-pos-bottom .herogate-main {
	align-items: flex-end;
}

.herogate-pos-left .herogate-main {
	justify-content: flex-start;
}

.herogate-pos-right .herogate-main {
	justify-content: flex-end;
}

.herogate-panel {
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 22px;
	width: min(100%, var(--herogate-width, 760px));
	text-align: center;
}

.herogate-align-left .herogate-panel {
	align-items: flex-start;
	text-align: left;
}

.herogate-align-right .herogate-panel {
	align-items: flex-end;
	text-align: right;
}

.herogate-has-panel .herogate-panel {
	padding: min(var(--herogate-panel-padding, 48px), 7vw);
	border: 1px solid rgba(255, 255, 255, 0.1);
	border-radius: var(--herogate-panel-radius, 24px);
	background: var(--herogate-panel-bg, rgba(11, 16, 32, 0.4));
	box-shadow: 0 24px 80px rgba(0, 0, 0, 0.28);
	-webkit-backdrop-filter: blur(var(--herogate-panel-blur, 14px));
	backdrop-filter: blur(var(--herogate-panel-blur, 14px));
}

.herogate-block {
	width: 100%;
	max-width: 100%;
}

.herogate-align-center .herogate-block {
	display: flex;
	flex-direction: column;
	align-items: center;
}

.herogate-align-left .herogate-block {
	display: flex;
	flex-direction: column;
	align-items: flex-start;
}

.herogate-align-right .herogate-block {
	display: flex;
	flex-direction: column;
	align-items: flex-end;
}

.herogate-block--elementor {
	display: block !important;
}

/* ------------------------------------------------------------------
 * Blocos
 * ---------------------------------------------------------------- */
.herogate-body .herogate-image {
	display: block;
	max-width: 100%;
	height: auto;
}

.herogate-body .herogate-heading {
	margin: 0;
	color: var(--herogate-heading, #fff);
	font-family: var(--herogate-heading-font, inherit);
	font-size: clamp(calc(var(--herogate-size, 56px) * 0.56), 7vw, var(--herogate-size, 56px));
	font-weight: var(--herogate-heading-weight, 700);
	line-height: 1.08;
	letter-spacing: -0.02em;
	text-wrap: balance;
}

.herogate-body .herogate-heading--gradient {
	background: linear-gradient(100deg, var(--herogate-heading, #fff) 20%, var(--herogate-accent, #5eead4));
	-webkit-background-clip: text;
	background-clip: text;
	color: transparent;
}

.herogate-body .herogate-text {
	max-width: 62ch;
	font-size: clamp(15px, calc(var(--herogate-size, 19px) * 0.92), var(--herogate-size, 19px));
	text-wrap: pretty;
}

.herogate-body .herogate-text p,
.herogate-body .herogate-text ul,
.herogate-body .herogate-text ol,
.herogate-body .herogate-text blockquote {
	margin: 0 0 0.8em;
}

.herogate-body .herogate-text > :last-child {
	margin-bottom: 0;
}

.herogate-body .herogate-text a,
.herogate-body .herogate-html a {
	color: var(--herogate-accent, #5eead4);
}

/* Contador */
.herogate-countdown__items {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: clamp(6px, 1.8vw, 16px);
}

.herogate-align-left .herogate-countdown__items {
	justify-content: flex-start;
}

.herogate-align-right .herogate-countdown__items {
	justify-content: flex-end;
}

.herogate-countdown__item {
	position: relative;
	display: flex;
	flex-direction: column;
	align-items: center;
	justify-content: center;
	min-width: clamp(56px, 15.5vw, 96px);
}

.herogate-countdown__value {
	color: var(--herogate-heading, #fff);
	font-family: var(--herogate-heading-font, inherit);
	font-size: clamp(24px, 6vw, 46px);
	font-weight: 700;
	line-height: 1.1;
	font-variant-numeric: tabular-nums;
}

.herogate-countdown__label {
	margin-top: 4px;
	font-size: 12px;
	letter-spacing: 0.12em;
	text-transform: uppercase;
	opacity: 0.75;
}

.herogate-countdown--boxes .herogate-countdown__item {
	padding: 14px clamp(4px, 1.5vw, 10px) 12px;
	border: 1px solid rgba(255, 255, 255, 0.14);
	border-radius: 16px;
	background: rgba(255, 255, 255, 0.07);
}

.herogate-countdown--minimal .herogate-countdown__item + .herogate-countdown__item::before {
	content: "";
	position: absolute;
	top: 18%;
	left: calc(clamp(6px, 1.8vw, 16px) / -2);
	height: 44%;
	border-left: 1px solid rgba(255, 255, 255, 0.2);
}

.herogate-countdown--circles .herogate-countdown__item {
	width: clamp(58px, 16vw, 104px);
	height: clamp(58px, 16vw, 104px);
	min-width: 0;
}

.herogate-countdown--circles .herogate-countdown__value {
	font-size: clamp(17px, 4.6vw, 32px);
}

.herogate-countdown--circles .herogate-countdown__label {
	margin-top: 0;
	font-size: 10px;
}

.herogate-countdown__ring {
	position: absolute;
	inset: 0;
	width: 100%;
	height: 100%;
	transform: rotate(-90deg);
}

.herogate-countdown__track,
.herogate-countdown__bar {
	fill: none;
	stroke-width: 5;
}

.herogate-countdown__track {
	stroke: rgba(255, 255, 255, 0.14);
}

.herogate-countdown__bar {
	stroke: var(--herogate-accent, #5eead4);
	stroke-linecap: round;
	stroke-dasharray: 282.743;
	stroke-dashoffset: 0;
	transition: stroke-dashoffset 0.6s ease;
}

.herogate-countdown__end {
	margin: 0;
	color: var(--herogate-accent, #5eead4);
	font-size: 1.25em;
	font-weight: 600;
}

/* Botão */
.herogate-body .herogate-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	gap: 8px;
	padding: 14px 28px;
	border: 2px solid transparent;
	border-radius: 999px;
	font-weight: 600;
	line-height: 1.2;
	text-decoration: none;
	transition: transform 0.2s ease, filter 0.2s ease, background-color 0.2s ease;
}

.herogate-body .herogate-button:hover,
.herogate-body .herogate-button:focus-visible {
	transform: translateY(-1px);
	filter: brightness(1.06);
}

.herogate-body .herogate-button--solid {
	background: var(--herogate-accent, #5eead4);
	color: var(--herogate-accent-contrast, #0b1020);
}

.herogate-body .herogate-button--outline {
	border-color: var(--herogate-accent, #5eead4);
	color: var(--herogate-accent, #5eead4);
	background: transparent;
}

.herogate-body .herogate-button--ghost {
	background: rgba(255, 255, 255, 0.1);
	color: var(--herogate-heading, #fff);
}

/* Redes sociais */
.herogate-social {
	display: flex;
	flex-wrap: wrap;
	justify-content: center;
	gap: 12px;
	margin: 0;
	padding: 0;
	list-style: none;
}

.herogate-align-left .herogate-social {
	justify-content: flex-start;
}

.herogate-align-right .herogate-social {
	justify-content: flex-end;
}

.herogate-social a {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	color: var(--herogate-heading, #fff);
	transition: background-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.herogate-social svg {
	display: block;
	width: var(--herogate-icon, 22px);
	height: var(--herogate-icon, 22px);
}

.herogate-social--circle a {
	width: calc(var(--herogate-icon, 22px) * 2.1);
	height: calc(var(--herogate-icon, 22px) * 2.1);
	border: 1px solid rgba(255, 255, 255, 0.16);
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.07);
}

.herogate-social a:hover,
.herogate-social a:focus-visible {
	transform: translateY(-2px);
	color: var(--herogate-accent, #5eead4);
}

.herogate-social--circle a:hover,
.herogate-social--circle a:focus-visible {
	background: var(--herogate-accent, #5eead4);
	color: var(--herogate-accent-contrast, #0b1020);
}

/* Progresso */
.herogate-progress {
	width: min(100%, 460px);
}

.herogate-progress__head {
	display: flex;
	justify-content: space-between;
	margin-bottom: 8px;
	font-size: 14px;
	opacity: 0.85;
}

.herogate-progress__track {
	overflow: hidden;
	height: 10px;
	border-radius: 999px;
	background: rgba(255, 255, 255, 0.12);
}

.herogate-progress__track span {
	display: block;
	height: 100%;
	border-radius: inherit;
	background: linear-gradient(90deg, var(--herogate-accent, #5eead4), var(--herogate-heading, #fff));
	transform-origin: left center;
	animation: herogate-progress 1.6s cubic-bezier(0.2, 0.7, 0.2, 1) both 0.4s;
}

.herogate-elementor {
	width: 100%;
	text-align: initial;
}

/* Rodapé */
.herogate-footer {
	position: fixed;
	right: 0;
	bottom: 14px;
	left: 0;
	z-index: 5;
	display: flex;
	justify-content: center;
	gap: 16px;
	padding: 0 16px;
	font-size: 13px;
	opacity: 0.72;
}

.herogate-footer a {
	color: inherit;
}

/* ------------------------------------------------------------------
 * Animação de entrada
 * ---------------------------------------------------------------- */
.herogate-entrance-fade .herogate-block,
.herogate-entrance-rise .herogate-block,
.herogate-entrance-zoom .herogate-block {
	animation-duration: 0.9s;
	animation-timing-function: cubic-bezier(0.2, 0.7, 0.2, 1);
	animation-fill-mode: both;
	animation-delay: calc(var(--herogate-i, 0) * 90ms + 120ms);
}

.herogate-entrance-fade .herogate-block {
	animation-name: herogate-fade;
}

.herogate-entrance-rise .herogate-block {
	animation-name: herogate-rise;
}

.herogate-entrance-zoom .herogate-block {
	animation-name: herogate-zoom;
}

/* ------------------------------------------------------------------
 * Keyframes
 * ---------------------------------------------------------------- */
@keyframes herogate-fade {
	from {
		opacity: 0;
	}
	to {
		opacity: 1;
	}
}

@keyframes herogate-rise {
	from {
		opacity: 0;
		transform: translateY(18px);
	}
	to {
		opacity: 1;
		transform: none;
	}
}

@keyframes herogate-zoom {
	from {
		opacity: 0;
		transform: scale(0.94);
	}
	to {
		opacity: 1;
		transform: none;
	}
}

@keyframes herogate-gradient {
	0%,
	100% {
		background-position: 0% 50%;
	}
	50% {
		background-position: 100% 50%;
	}
}

@keyframes herogate-kenburns {
	from {
		transform: scale(1.04) translate3d(0, 0, 0);
	}
	to {
		transform: scale(1.16) translate3d(-1.5%, -1%, 0);
	}
}

@keyframes herogate-grain {
	0% {
		transform: translate(0, 0);
	}
	20% {
		transform: translate(-5%, 4%);
	}
	40% {
		transform: translate(4%, -6%);
	}
	60% {
		transform: translate(-3%, 7%);
	}
	80% {
		transform: translate(6%, 2%);
	}
	100% {
		transform: translate(0, 0);
	}
}

@keyframes herogate-progress {
	from {
		transform: scaleX(0);
	}
	to {
		transform: scaleX(1);
	}
}

/* ------------------------------------------------------------------
 * Movimento reduzido
 * ---------------------------------------------------------------- */
@media (prefers-reduced-motion: reduce) {
	.herogate-bg--animated,
	.herogate-grain,
	.herogate-bg--kenburns .herogate-bg__slide.is-active,
	.herogate-progress__track span,
	.herogate-entrance-fade .herogate-block,
	.herogate-entrance-rise .herogate-block,
	.herogate-entrance-zoom .herogate-block {
		animation: none !important;
	}

	.herogate-bg__slide {
		transition: none;
	}
}

@media (max-width: 600px) {
	.herogate-panel {
		gap: 18px;
	}

	.herogate-footer {
		position: relative;
		bottom: auto;
		padding: 0 16px 16px;
	}
}
